Re: when do transitions occur?

On Wednesday 2011-09-14 03:03 -0700, Tab Atkins Jr. wrote:
> On Tue, Sep 13, 2011 at 7:30 PM, Jennifer Yu <Jennifer.Yu@microsoft.com> wrote:
> > And what happens when a shorthand property is changed and a transition is
> > kicked off? Is it a single transition with 1 event thrown for the shorthand,
> > or are the longhands transitioning with an event thrown for each? Or are
> > they all transitioning, with 1 event thrown for the shorthand and an event
> > thrown for each transitioning longhand?
> 
> Not sure about the intent of this one.

There should be events for each longhand.  The starting of
transitions is based on detecting changes in computed values, which
is past the point where there's a distinction between longhands and
shorthands.

And there are also plenty of cases where it doesn't make sense to
distinguish.  For example, changing an element so that it switches
from applying these declarations:
  border-bottom: medium solid green;
to these:
  border-bottom-width: thin;
  border-bottom-style: dashed;
  border-bottom-color: blue;
is changing both shorthands and longhands, but there's only one set
of computed values changing.

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla Corporation               http://www.mozilla.com/   𝄂

Received on Wednesday, 14 September 2011 15:20:53 UTC