W3C home > Mailing lists > Public > www-style@w3.org > September 2011

Re: when do transitions occur?

From: Dean Jackson <dino@apple.com>
Date: Thu, 22 Sep 2011 06:17:42 +1000
Cc: "L. David Baron" <dbaron@dbaron.org>, Brian Manthos <brianman@microsoft.com>, "Tab Atkins Jr." <jackalmage@gmail.com>, "www-style@w3.org" <www-style@w3.org>
Message-id: <5E625190-F4AB-4D19-BEAE-2D2B9E3098F8@apple.com>
To: Jennifer Yu <Jennifer.Yu@microsoft.com>

On 16/09/2011, at 6:37 AM, Jennifer Yu wrote:

> Thanks for the responses Tab and David. I didn't realize that shorthands don't have a computed value since getComputedStyle seems to return a valid string for shorthands.
> 
> And just for clarification regarding zero duration transitions and animations (since I seem to have trouble finding the previous discussion of it), 0 duration transitions should not throw events if the delay is also 0. If the delay is positive, 0 duration transitions should throw an event. 0 duration animations, on the other hand, should throw events. Are those statements accurate?

We get a *LOT* of requests from developers asking for transitionend events to fire all the time, even if the property didn't change. This could be a 0/0 duration delay, or setting a property to the same value.

The use case is generally wanting to run a bunch of animations on children before changing a parent. Think of something like a slide-show where the text might slide off the page before the transition to the next screen.

Any opinions on this?

We're concerned about performance impact. An alternative would be to write an API that allows you to query the current state of all transitions on an element (or subtree). That way you'd know what is active.

Dean
Received on Wednesday, 21 September 2011 20:18:56 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:44 GMT