Re: [css3-animations] multiple 'animation-name' and cascading

On Saturday 2011-04-02 11:44 +1100, Dean Jackson wrote:
> 
> On 01/04/2011, at 12:08 PM, L. David Baron wrote:
> 
> > The css3-animations spec should mention what happens when multiple
> > animations (i.e., multiple items in the 'animation-name' list) both
> > animate the same properties.
> > 
> > I presume that it should say that the last animation in the list
> > wins.
> 
> Yeah.

And, actually, in order to define that, it also needs to define when
an animation is animating a property.  I presume it is doing so when
the property is present in either of the neighboring keyframes for
the current time (where current time is defined on the 0%-100% axis,
not actual time, in order to account for the fun interaction of
animation-fill-mode and possibly-fractional animation-duration).
That allows two neighboring keyframes to have the same value but
still cause the animation to override the lower rules, but also
allows animations to override each other somewhat reasonably.

(Alternatively, I suppose one could check for whether the property
is specified in any keyframe -- though that's a bit more work.)

-David

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

Received on Tuesday, 12 April 2011 04:09:40 UTC