Direction-aware transition

Match enter and exit directions to navigation order and preserve context.

Preview

Navigation motion uses the route direction to choose opposing travel paths for forward and reverse actions.

Preview
Previous
Direction-aware transition

Implement Direction-aware transition: Match enter and exit directions to navigation order and preserve context. Use Duration 240ms, Distance 40px, Direction left, Easing soft. Trigger it once when state changes and keep it replayable. Use semantic HTML, scope CSS to .motion-demo--direction-aware-transition, and mount the provided vanilla JavaScript interaction runtime. Provide equivalent low-motion behavior for prefers-reduced-motion and .force-reduced-motion.

Learn more