W3C home > Mailing lists > Public > www-style@w3.org > April 2010

Re: transitions vs. animations

From: Brad Kemper <brad.kemper@gmail.com>
Date: Fri, 9 Apr 2010 07:20:44 -0700
Cc: "www-style@w3.org list" <www-style@w3.org>
Message-Id: <D895108E-6A26-41D5-81FE-F842181097EE@gmail.com>
To: H??kon Wium Lie <howcome@opera.com>

On Apr 9, 2010, at 1:25 AM, Håkon Wium Lie wrote:

>> 2b) 
>> foo { 
>> 	position:static; 
>> 	transition: position 1s / bounce 1s; 
>> }
>> foo:hover { position:relative; }
> I don't undertand how this example works. How does it make 'bounce' be
> played on hovering and un-hovering? Are you using the change in the
> 'position' property as a dummy just to trigger some change?

Yes. Since the non-zero rounds to one, the position should change to "relative' within one "frame" or millisecond or whatever after transition begins, thus allowing the 'transition-animation' (the part after the slash) to move.

At least, that's the theory. I could have done the same thing a transition between opacity:1 and opacity:0.999, or something else which would not be noticeable by a human. But that seemed more likely to illicit charges of being too-hackish, which I will probably now receive anyway.
Received on Friday, 9 April 2010 14:21:26 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:07:45 UTC