W3C home > Mailing lists > Public > public-css-archive@w3.org > September 2019

[csswg-drafts] [scroll-animations] ScrollTimeline fill-mode has asymmetric interaction with animation fill modes. (#4325)

From: Robert Flack via GitHub <sysbot+gh@w3.org>
Date: Tue, 17 Sep 2019 15:40:42 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-494702268-1568734841-sysbot+gh@w3.org>
flackr has just created a new issue for https://github.com/w3c/csswg-drafts:

== [scroll-animations] ScrollTimeline fill-mode has asymmetric interaction with animation fill modes. ==
ScrollTimeline's fill mode is a bit awkward to use. See this demo here:
https://jsbin.com/haworeb/edit?html,output

The ScrollTimeline is active from scroll offset 25 to 75 to observe the asymmetric behavior:
* Before the ScrollTimeline range, if the ScrollTimeline has `fill: both` or `fill: before` the currentTime is 0 so regardless of the effect's fill, the effect has it's initial value.
* After the ScrollTimeline range, if the ScrollTimeline has `fill: both` or `fill: after` the currentTime is the effect duration which means that the effect's fill mode decides whether the last value fills.
* If ScrollTimeline has `fill: none` the effect's fill mode doesn't matter.

I think this makes the fill on ScrollTimeline difficult to use since you need to pair it with the effect. I think that as a developer it would be easier if ScrollTimeline didn't have fill, and just exceeded the time range (i.e. < 0 or > timeRange) when it was outside of the scroll range. This way I would only have to worry about the effect's fill. Do you think there are use cases for separately wanting to rely on the scroll timeline's fill?

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4325 using your GitHub account
Received on Tuesday, 17 September 2019 15:40:43 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:53 UTC