- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Wed, 25 Sep 2013 15:25:28 -0700
- To: Dean Jackson <dino@apple.com>
- Cc: www-style list <www-style@w3.org>
On Sat, Sep 21, 2013 at 2:57 PM, Dean Jackson <dino@apple.com> wrote: > It’s about a year later and Tab was right: I'll never get tired of hearing that. > the genie is not going back into the bottle. Also, we have a Web Animations spec that is more fleshed out. Can we pick this discussion up again? Awesome. I'd love to. > I think it would be nice to see if we could come up with something that addresses many of the most common features with minimal additions to CSS, and then something that allows script hooks for more complicated things. For example, Tab proposed an "animation-timeline" property, which would allow CSS to use something other than the wall clock for a timeline. Now we’d just need some way to map scroll offset to the timeline (possibly with min/max bounds and some multiplier for offset (called "timeline-length" in Tab’s proposal)). > > That itself could be enough for the types of effects where, as you approach the end of an article, a link to related things flies in from the side of the page. Or having the background color of an element animate as you scroll. I’m not sure how to address the case of flipbook animations (many images that are swapped as you scroll - the pitchfork articles are a good example). > > Then there is the case where you want "really fancy shit" (official term) to happen as you scroll. I always like doing things in declarative form if possible, so it would be nice if you could describe as many parameters to the animation as possible in CSS, and just call script with a progress parameter. Yes. Now that Web Animations is more advanced and reasonable, I'd like to explore this by explaining it in terms of WA first, then backfill CSS syntax to allow more declarative handling of a bunch of it. (It's possible that my old proposal is actually sufficiently powerful, but most of the time when I come up with a big powerful declarative thing, it ends up not being powerful enough to be worth doing, and we have to break it up into primitives anyway.) > Lastly, something not addressed in Tab’s proposal was the ability to animate scrolling (i.e. the other way around). Many pages are calling scrollTo in a loop. It would be nice if there was some API where the browser would take care of the scrolling animation, given input of duration and easing. Smooth scrolling is already specced in CSSOM, as François said. If we need more control, we can extend that in the future, but I think you need a good argument to do more than what is currently allowed. ~TJ
Received on Wednesday, 25 September 2013 22:26:15 UTC