What problem does it solve?
It prevents jarring route changes by adding smooth, native-feeling transitions between page states without relying on heavy animation libraries.
Core Features & Use Cases
- View Transitions API Cross-Fade/Slide: Applies consistent animation to MPA navigations via the @view-transition CSS at-rule and to SPA navigations via document.startViewTransition().
- Shared Element Morphing: Creates card-to-detail “shared hero” morphs using view-transition-name so matching elements smoothly transition across pages.
- Framework Integration & Safety: Supports Next.js, Astro, and vanilla MPA patterns, includes prefers-reduced-motion handling, and provides fallback behavior for browsers without startViewTransition.
- Example: Animate an e-commerce product image morphing from the product list to the product detail page while surrounding content fades appropriately.
Quick Start
Use the page-transitions skill to implement View Transitions API animations for navigation in your app, using cross-fade for generic routes and shared-element morphs for matching elements.