Re: [csswg-drafts] [css-animations-2] Move scroll and event animation triggers to independent namespace (#12336)

> > I might be derailing the conversation here (sorry 🙈), but [@flackr](https://github.com/flackr)'s thoughts also gave me another idea. What if we removed timeline triggers altogether? Then we only deal with stateless events, and we don't have to differentiate them from another thing, and it should simplify the rest. What if we actually had a viewenter and viewleave DOM events which map exactly to what view() does, but without the state? (And I must say I think I'd love to have those anyway). The only thing that we'd be missing is ranges - which we ought to keep - so probably imagine these would go in the options object if set programmatically, like: .addEventListener('viewenter', (e) => {...}, { range: 'contain' }). After all, with the upcoming pointer() timeline we may as well settle for just using pointerenter and pointerleave events.
>
> I think that would mean moving the `-timeline`, `-range-start`, `-range-end`, `-continue-start`, and `-continue-end` properties to the `event-trigger` namespace, which I don't think we want as they are not generally relevant to event triggers.
It feels like we'll soon agree on the exact set of properties within the independent namespace format.

Not really, I mean that if we do adopt these new events, we won't need timeline triggers at all. We'll have just event triggers, and then we don't need to differentiate them from timeline triggers, we could just have that be the only way to define triggers.

But if we did, we'd still need a way to specify ranges. So if these were events we'd need some way to modify them. This feels like something very specific to these 2 events, but then OTOH, also `timeline-trigger` with `view()` seems very specific compared to `event-trigger`.

-- 
GitHub Notification of comment by ydaniv
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12336#issuecomment-3161280455 using your GitHub account


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

Received on Wednesday, 6 August 2025 19:07:34 UTC