- From: Estelle Weyl <estelle@weyl.org>
- Date: Sun, 27 Sep 2015 13:53:02 -0700
- To: www-style list <www-style@w3.org>
- Message-Id: <AFC0CDB2-222F-4533-9AF0-8A9A3AC12936@weyl.org>
I am taking a look at transition-delay, transition-duration and elapsedTime. The mozilla and blink implementations are very different. In the reverse direction in chrome the delay and duration are the full length of time, even if the transition in the normal direction did not finish. In Firefox, the delay is the full delay, but the transition duration is the same time that it spent going in the normal direction, not the full transition-duration time set. It seems like the FF implementation is correct. [ ] Taking http://codepen.io/estelle/pen/avZKEo <http://codepen.io/estelle/pen/avZKEo> as an example - with a delay of 1s and a transition-duration of 5s, if I mouseout .75s after the transition has started, Chrome waits the full delay, then takes the full duration - 5s - to revert back to the original state. [ ] Firefox waits the full delay, but takes only .75s to revert to the origianl state. [ ] The elapsedTime in Chrome is 5s, the elapsed time in FF is not exactly 0.75 seconds,… which seems to be a bug too. The elapsedTime issue is why I am mentioning transition-delay in this thread too. If the transition-delay is negative, I would assume the elapsedTime would be the transition-duration less the absolute value of the delay. If the delay is -1s with a 5s duration, i would assume the elapsedTime would be 4s. In chrome it’s 5s. In Firefox it is a number that makes no logical sense. The spec for ‘elapsedTime” reads “The amount of time the transition has been running, in seconds, when this event fired. Note that this value is not affected by the value of transition-delay.”, so definitely a positive value for a delay should have no effect. However, due to the “The amount of time the transition has been running”, i would assume that a negative delay DOES impact the elapsedTime, since it is how long the transition has been running. In the reverse direction, starting midway thru an animation, I would assume that the elapsedTime is only the time the transition has been running. In this case, 0.75s. That is not what I am seeing. If the elapsedTime is always the duration, as in the blink case, let’s change the spec to reflect that. However, I don’t think that is what the elapsedTime should be. I prefer FF’s implementation, even though the firing of the transitionend event seems to be a bit off in most cases (about 20 to 200ms off). -Estelle Estelle Weyl estelle@weyl.org http://www.standardista.com
Received on Sunday, 27 September 2015 20:53:36 UTC