Motion Tokens
Expanding the motion system with theme-driven animation presets, hover effects, enter/exit animations, and View Transitions API integration.
src/tokens/extensions/motion-fx.css
Proposed Motion Tokens
New tokens to add to the existing motion.css system.
| Token | Value |
|---|---|
--motion-hover-transform |
translateY(-2px) |
--motion-stagger-delay |
50ms |
--motion-bounce |
cubic-bezier(0.34, 1.56, 0.64, 1) |
--motion-snappy |
cubic-bezier(0.4, 0, 0.2, 1) |
--motion-smooth |
cubic-bezier(0.25, 0.1, 0.25, 1) |
--motion-elastic |
cubic-bezier(0.68, -0.55, 0.265, 1.55) |
Hover Effects
Reusable hover patterns that can be applied to cards, buttons, and interactive elements.
Lift
Raises with shadow
Glow
Subtle ring glow
Scale
Bouncy scale up
Border
Border appears
Tilt
3D perspective
Transition Presets
Different easing curves create different motion personalities. Hover each box to compare.
Enter/Exit Animations
Reusable keyframe animations for elements appearing and disappearing.
Fade In
Slide Up
Slide Down
Scale In
Pop In
Staggered Animations
Child elements animate in sequence using CSS custom properties for delay calculation.
Theme Motion Personalities
Each theme can have its own motion character. Hover the boxes to see different personalities.
Default
Smooth lift
Swiss
Linear, precise
Organic
Flowing, natural
Brutalist
Instant, raw
Cyber
Stepped, glitchy