Loading...
html.transitioning {
pointer-events: none;
}html:active-view-transition {
pointer-events: none;
}The pseudo-class matches only while the transition runs, so no class has to be added and removed in JavaScript.
:active-view-transition instead of a class added and removed by JavaScript.:active-view-transition-type() and types passed to startViewTransition().@media (prefers-reduced-motion: reduce).Pass types to startViewTransition({ update, types: ['slide'] }) and select them with :active-view-transition-type(slide).
For a document transition, the root element <html>. Style other parts with descendant selectors, like :active-view-transition header.