- From: Khushal Sagar via GitHub <sysbot+gh@w3.org>
- Date: Fri, 18 Aug 2023 19:04:01 +0000
- To: public-css-archive@w3.org
Thanks for the feedback Nick! The use-cases you outlined make sense. There is a tradeoff about exposing a primitive to cache a DOM subtree as an image vs a higher level primitive for that use-case. Some thoughts below around that. - Gesture-linked animations where touch coordinates are used to position elements. That's a key use-case we've seen with transition UX. Breaking this down into the primitives needed: 1. A way to map the user's touch events to a gesture that animates a previous view/layer. 2. A way to cache an image of the view which can be instantly shown for this animation. This also means the site needs to do budgeting for all these images assuming there is a stack of layers as the user navigates through the site. 3. A way to persist the image while the view's DOM is re-generated. Exposing an API for 2 will require authors to do 1 and 3 manually. Ideal would be if the browser could provide a combined solution. For example, the edge swipe UX to navigate is one use-case where that's trivially possible, since the browser is aware of both the gesture and the navigation (so knows when to snapshot). We can provide a timeline that lets authors trivially set up an animation using that timeline. Does that sound like a reasonable path to consider? Or are there cases where letting the browser manage all of this is not the right call. - Caching snapshots of SPA views to provide previews while re-rendering previous content. Is this closely tied to the use-case above? User comes to a previous view via a gesture and now a cached snapshot has to be replaced with a live DOM. - Precomputing transition elements to enhance responsiveness Sorry I didn't completely follow this. Re: "keeping the page interactive can be difficult (though again not impossible) with the VT API especially if the transition only changes part of the page", I think [scoped transitions](https://github.com/WICG/view-transitions/blob/main/scoped-transitions.md) is the primitive you're looking for. -- GitHub Notification of comment by khushalsagar Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8830#issuecomment-1684326049 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 18 August 2023 19:04:03 UTC