W3C home > Mailing lists > Public > www-style@w3.org > March 2014

[css-transitions] detecting style updates to existing transitions (was Re: Updates to css-transitions ED)

From: L. David Baron <dbaron@dbaron.org>
Date: Sun, 23 Mar 2014 13:15:20 -0700
To: www-style@w3.org
Cc: Shane Stephens <shans@google.com>
Message-ID: <20140323201520.GA2345@crum.dbaron.org>
On Tuesday 2013-11-12 16:32 +0800, L. David Baron wrote:
> I've recently completed a number of edits to the CSS Transitions
> Editor's Draft: http://dev.w3.org/csswg/css-transitions/
> 
> The changes are described in the changes section:
> http://dev.w3.org/csswg/css-transitions/#changes
> the most substantive of which are:
> 
>   * Define the model for starting of transitions and their
>     interaction with other animations more precisely:
>     
>     *   Define the before-change style and after-change style used
>         for the style comparison, using the new concept of a style
>         change event.
> 
>     *   Define that a CSS transition for a property does not affect
>         computed style when a CSS Animation for the same property is
>         running, but that the transition is still running in terms
>         of APIs.
> 
>     *   Add a note pointing out that the above definitions imply
>         that transitions can start simultaneously, from the same
>         change, on ancestors and descendants.
> 
>     *   Define that CSS transitions participate in CSS's cascading
>         and inheritance model 

As an issue in the spec points out, I'm still not sure how to edit
this model to describe how style changes interrupt an
already-running transition and put it on a different path.  In
particular, in this model, while a transition is running, no other
transition on that property will start in response to a style change
since the transition overrides that style change.

This isn't the desired behavior; instead, implementations should
start a transition to the new destination style (and apply the rules
for transition reversing if applicable) or cancel the existing
transition (if the style change is to the current transition
destination style).

I'm curious what those who have already implemented this new model
did to handle this case.

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                          https://www.mozilla.org/   𝄂
             Before I built a wall I'd ask to know
             What I was walling in or walling out,
             And to whom I was like to give offense.
               - Robert Frost, Mending Wall (1914)

Received on Sunday, 23 March 2014 20:15:46 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:51:20 UTC