W3C home > Mailing lists > Public > www-style@w3.org > February 2013

Re: [css-transitions] starting of transitions.

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Wed, 20 Feb 2013 23:02:29 -0800
Message-ID: <CALRQH79HO5r5EgaYnoCXxZOJXe3XQZM=+28TcGeNjyVd9BzKmw@mail.gmail.com>
To: "L. David Baron" <dbaron@dbaron.org>
Cc: "www-style@w3.org" <www-style@w3.org>
On Wed, Feb 20, 2013 at 9:15 PM, L. David Baron <dbaron@dbaron.org> wrote:
> On Wednesday 2013-02-20 20:29 -0800, Andrew Fedoniouk wrote:
>> And so if I have these two rules:
>>
>> a:link { color:red;  }
>> a:link:hover { color:blue; transition: color 2s ease;  }
>>
>> then it will be no :hover -> :not(:hover) transition at all, correct?
>
> Correct.
>
>> But if  {initial} -> :hover transition will be canceled before its end
>> (so :hover -> :not(:hover) switch in 2 seconds)  then we will actually
>> see backward transition. Is this correct/desirable?
>
> In my opinion, no, which is why I object to the current rules of
> reversing of transitions.
>

If 'transition' would define not only the the way of how to get to that
state/value but also how to leave from there then current rollback
animation behavior is probably OK.

Let's assume that 'transition' is actually a shortcut of
transition-to and transition-from then current auto-rollback
logic fits there naturally.

So these:

  a { color:green; }
  a:hover { color:green; transition ease 1s; }

define transition of 'to :hover' and 'from :hover'.
"from" part uses exactly the same rules we use now for
the rollback. Therefore rollback and :hover to {normal}
use the same and consistent negated transition.

Most of the time transition used to define
animation from normal state to/from various
others - star alike graph with normal/initial state in the center.
Such setup is pretty practical I would say (in my implementation
I am using this to/from schema).

-- 
Andrew Fedoniouk.

http://terrainformatica.com
Received on Thursday, 21 February 2013 07:03:01 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:06 GMT