Re: [csswg-drafts] [scroll-animations-1] Range for entire scroll range (#9367)

The CSS Working Group just discussed `[scroll-animations-1] Range for entire scroll range`, and agreed to the following:

* ``RESOLVED: Keyword is `scroll` ``
* `RESOLVED: It also applies to scroll timelines`

<details><summary>The full IRC log of that discussion</summary>
&lt;emilio> bramus: when you are specifying a view timeline which you use for animation, and attach it to a range or sub-range<br>
&lt;emilio> ... there's no way to specify the entire scroll range<br>
&lt;emilio> ... we came up with a bunch of keywords<br>
&lt;emilio> ... I think we settled on the world `scroll`<br>
&lt;emilio> ... since then there were some more suggestions<br>
&lt;emilio> ... like `fill` and `full-range`<br>
&lt;emilio> ... we also want to make this do something for scroll timelines<br>
&lt;emilio> ... to use this keywords in JS APIs<br>
&lt;emilio> ... when specifying ranges<br>
&lt;emilio> ... looking to adopt this keyword (personal preference being `scroll`) into the spec<br>
&lt;flackr> +1<br>
&lt;emilio> ... this would allow you to do animation-range: entry 0%, scroll 1000px<br>
&lt;dbaron> Present-<br>
&lt;emilio> ... so you can mix and match a range relative to the tracked subject and the second relative to the scroll range<br>
&lt;astearns> ack fantasai<br>
&lt;emilio> fantasai: so the scroll 1000px point might be before or after<br>
&lt;emilio> bramus: if you overshoot it flips<br>
&lt;emilio> fantasai: no going backwards<br>
&lt;emilio> q+<br>
&lt;fantasai> scribe+<br>
&lt;astearns> ack emilio<br>
&lt;emilio> bramus: consistent with explicit values<br>
&lt;fantasai> scribe+ TabAtkins<br>
&lt;TabAtkins> emilio: it woudl be well-defined if..<br>
&lt;TabAtkins> emilio: %s also need to care about the scroll range changing<br>
&lt;TabAtkins> bramus: if you use animation-range: 0% 100% on a scroll timeline, that's the same as animation-range: scroll 0% scroll 100%<br>
&lt;TabAtkins> bramus: %s are calculated in smae manner<br>
&lt;TabAtkins> emilio: as long as it's well-defined what happens when the scroll range changes (presuambly recompute on next frame), sounds good<br>
&lt;emilio> scribe+<br>
&lt;TabAtkins> astearns: i see we have a previous resolution on "add scroll, but bikeshed"<br>
&lt;emilio> astearns: is the bikeshed just settling on scroll?<br>
&lt;emilio> bramus: I think we settle on `scroll`<br>
&lt;emilio> ... looking at the replies<br>
&lt;astearns> `RESOLVED: add 'scroll' named range to view timelines, represents entire scroll range, bikeshed keyword in issue`<br>
&lt;emilio> flackr: did a short survey<br>
&lt;bramus> https://github.com/w3c/csswg-drafts/issues/9367#issuecomment-1904777189<br>
&lt;emilio> PROPOSAL: the keyword is `scroll`<br>
&lt;emilio> PROPOSAL: The keyword applies to scroll-timeline as well<br>
&lt;emilio> fantasai: isn't it a no-op for scroll-timeline?<br>
&lt;emilio> bramus: it becomes interesting in JS<br>
&lt;flackr> q+<br>
&lt;emilio> ... you pass an object into the range start property of the animation<br>
&lt;emilio> ... so you specify an object and range, and the range is `scroll`<br>
&lt;emilio> ydaniv: scroll timeline doesn't have range names<br>
&lt;bramus> ```<br>
&lt;bramus> anim.rangeStart: {<br>
&lt;bramus>   offset: CSS.px(100),<br>
&lt;bramus>   rangeName: 'none', // This needs to be `"none"`, but `none` is not defined in the spec as a valid `rangeName`.<br>
&lt;bramus> },<br>
&lt;bramus> ```<br>
&lt;bramus> (replace none with scroll)<br>
&lt;emilio> flackr: What this gives you is the ability to attach to a px offset<br>
&lt;emilio> ... I suppose ranges have that anyways<br>
&lt;emilio> ... nevermind<br>
&lt;emilio> RESOLVED: Keyword is `scroll`<br>
&lt;emilio> RESOLVED: It also applies to scroll timelines<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9367#issuecomment-2628525742 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Friday, 31 January 2025 22:48:03 UTC