Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for Position: Detecting UA Transitions #783

Open
khushalsagar opened this issue Apr 21, 2023 · 3 comments
Open

Request for Position: Detecting UA Transitions #783

khushalsagar opened this issue Apr 21, 2023 · 3 comments

Comments

@khushalsagar
Copy link

Request for Mozilla Position on an Emerging Web Specification

Other information

This API would help with issues like this. Chromium is planning to ship similar browser UX and we're looking forward to fixing this problem in an interoperable way.

@khushalsagar
Copy link
Author

Friendly ping. Would appreciate some feedback on this proposal.

@smaug---- IIRC, your feedback at the html triage meeting was wanting ensure this will work well if we choose to provide the functionality outlined in w3c/csswg-drafts#8747 which makes sense. This API was structured with that in mind, happy to answer any questions/concerns with this aspect.

That said, a proposal to disable UA transitions is lot more nuanced because of the need to introduce more concepts (around navigation triggers), and it's unclear whether there will be consensus on giving that kind of control to authors (and to what extent). We're aiming to ship this API earlier to give authors an easy immediate fix.

@smaug----
Copy link
Collaborator

I would expect there to be some easy way from JS, or at least some way, to disable the transition. whatwg/html#8782 doesn't provide that.
https://github.com/WICG/view-transitions/blob/main/default-ua-transitions.md does have the css rules for that, and makes sense from performance point of view that it is in css.

But I wonder, there is also the possibility to do this similarly to history.scrollRestoration. That was after all designed for very similar case. If the page is going to do its own scrolling / transition, then scrollRestoration should be set to "manual". The explainer doesn't explain why so different API is needed now.

@khushalsagar
Copy link
Author

Thanks for the feedback @smaug----! I left a comment here to keep the discussion on that issue. Hope that answers why the scroll restoration pattern doesn't work for transitions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants