w3ctag / design-reviews

W3C specs and API reviews
Creative Commons Zero v1.0 Universal
318 stars 55 forks source link

View Transitions: list of types #908

Open vmpstr opened 8 months ago

vmpstr commented 8 months ago

こんにちは TAG-さん!

I'm requesting a TAG review of View Transitions: list of types.

The View Transitions feature allows developers to create transitions between DOM states. A significant portion of the transition is a declarative set up, followed by a script trigger. This works well for a single type of transition. However, developers have expressed interest to be able to declare multiple transitions in their CSS, and then trigger only one of them from script. The list of types proposal attempts to address this use case.

Further details:

LeaVerou commented 7 months ago

Hi @vmpstr,

We just took this up on our breakout A today, but we couldn't find a list of use cases in the explainer. There was this issue which is linked, but it was not clear to us whether that is the only use case, or whether there are more. It would also be useful to include any alternatives considered. Please take a look here for more advice on writing effective explainers.

vmpstr commented 7 months ago

Hi @LeaVerou,

Thank you for the feedback. The use-case described in https://github.com/w3c/csswg-drafts/issues/8960 is the same use-case described in the explainer, and is the main use-case for this API addition to the View Transitions feature.

We are also discussing using types for a similar use-case in the cross-document navigation case, where the polyfill is potentially harder to implement. We are early in the discussion of how types can be used in that case though.

I've added alternatives considered section that mentions this as well.