Re: Are CSS animations a done deal?

On Tue, Mar 30, 2010 at 5:57 AM, Simon Fraser <smfr@me.com> wrote:

> Let me reiterate the reasons why we think declarative animation in CSS is a
> good idea:
>
> * Declarative animation is good for ease of authoring.
> * Declarative animation allows the user agent to make optimizations that
> are impossible with iterative animation via script (this is very important
> on lower-power devices).
> * Many CSS animations are presentational; ambient backgrounds animations,
> button that pulse when hovered etc.
>

I think this is the strongest argument for CSS Animation.


> * Animations operate on CSS properties, so it makes sense to declare the
> keyframes in CSS.
> * Given declarative animations in CSS, you can easily layer a JavaScript
> API on top (even via a JS library). It's not possible to do the reverse.
>

It is possible to layer a Javascript API on top of non-CSS declarative
animation, such as SVG animation.

* It would be odd to have presentational changes in the document (like
> animation via some non-CSS-based API) coming from a non-CSS source. What
> would getComputedStyle() return?
>

It's not that odd. You already support it with SVG animations --- and with
presentational attributes in general, both SVG and non-SVG.

My personal opinion is that CSS Animation makes sense for presentational
animations, but I don't want to see CSS Animation used for animations that
are essentially animated images (like most Flash ads). CSS Animation seems
pretty easy to implement once you've done Transitions, so the bar for its
acceptance need not be high.

Rob
-- 
"He was pierced for our transgressions, he was crushed for our iniquities;
the punishment that brought us peace was upon him, and by his wounds we are
healed. We all, like sheep, have gone astray, each of us has turned to his
own way; and the LORD has laid on him the iniquity of us all." [Isaiah
53:5-6]

Received on Monday, 29 March 2010 21:16:49 UTC