Re: [csswg-drafts] [view-transitions-2] Add method to get all animations of a ViewTransition object (#9908)

> > > how about adding a general selector property instead?
> > 
> > 
> > can you expand on that. I didn't follow. :)
> 
> Since we're setting `subtree: true` and we're getting animations from the entire subtree, use a selector to filter the elements from the subtree, instead of naming a single pseudo element. I think that could be handy in general.

Adding a generic selector filter is a pretty substantial additional bit of complexity for which you can usually use the querySelectorAll API, e.g. `elem.querySelectorAll(query).map(e => e.getAnimations())`, where specifying the pseudo is just giving you a way to specify the actual node for your getAnimations call in a similar way to getComputedStyle, where we also don't have a generic selector.

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


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

Received on Thursday, 13 June 2024 12:51:10 UTC