Skip to content

fix(router): avoid view transitions when the user agent provides one - #70140

Open
SkyZeroZx wants to merge 1 commit into
angular:mainfrom
SkyZeroZx:fix/router-ua-view-transition
Open

fix(router): avoid view transitions when the user agent provides one#70140
SkyZeroZx wants to merge 1 commit into
angular:mainfrom
SkyZeroZx:fix/router-ua-view-transition

Conversation

@SkyZeroZx

Copy link
Copy Markdown
Contributor

Preserve hasUAVisualTransition through Location and the Router navigation pipeline. This prevents withViewTransitions from starting an author transition after the browser has already performed one, including across redirects and when using experimental platform navigation.

References:

Note:

Note: By default Chrome on Android does not offer visual transitions for navigations invoked by a swipe gesture. This feature is in an experimental state and only available behind the chrome://flags/#back-forward-transitions feature flag.

Although the article mentions that swipe gestures are not a default behavior, this is not currently true in Chrome 150 on Android; the feature flag does not exist and it has become the default behavior.

What is the current behavior?

without_skip_router-ua-view-transition.mp4

What is the new behavior?

fixed_router-ua-view-transition.mp4

Preserve hasUAVisualTransition through Location and the Router navigation pipeline. This prevents withViewTransitions from starting an author transition after the browser has already performed one, including across redirects and when using experimental platform navigation.

References:

https://html.spec.whatwg.org/multipage/nav-history-apis.html#dom-popstateevent-hasuavisualtransition

https://html.spec.whatwg.org/multipage/nav-history-apis.html#dom-navigateevent-hasuavisualtransition

https://developer.chrome.com/docs/web-platform/view-transitions/same-document#integration-with-the-navigation-api-and-other-frameworks
@pullapprove
pullapprove Bot requested review from atscott and iteriani August 10, 2026 18:38
@angular-robot angular-robot Bot added area: router requires: TGP This PR requires a passing TGP before merging is allowed labels Aug 10, 2026
@ngbot ngbot Bot added this to the Backlog milestone Aug 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: router requires: TGP This PR requires a passing TGP before merging is allowed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant