motion
Sets the rules for presets, wrappers, reduced motion and performance so animation is consistent and 60 fps.
looks for
- library animation calls scattered through pages
- animating width, height, top, left or box-shadow
- no prefers-reduced-motion handling
- heavy animation libraries in the main bundle
- scroll-jacking or parallax on every section
outputs
- → presets file and wrapper components
- → a reduced-motion path that still looks finished
- → performance notes (what loads where)
SKILL.md
Motion
Motion explains change: where something came from, what it relates to, what just happened. If it explains nothing, cut it.
1. Presets, not ad-hoc values
Keep one presets file ({{MOTION_DIR}}/presets) with named recipes, e.g.
fadeUp, stagger, reveal, parallax, plus durations and easings.
Each theme or product picks a feel:
| Feel | Durations | Easing | Use for |
|---|---|---|---|
| Calm | 200–400 ms | ease-out | studio, content sites |
| Playful | spring, slight overshoot | spring | games, consumer apps |
| Precise | 120–200 ms | sharp ease-in-out | tools, dashboards |
2. Thin wrappers
Pages assemble wrappers instead of calling libraries directly:
<Reveal>, <Stagger>, <ScrollScene> (pin + scrub), <Marquee>, <Counter>.
Swapping a library later touches only the wrappers.
3. Reduced motion is a first-class design
- Read
prefers-reduced-motion(e.g.useReducedMotion,gsap.matchMedia). - When set: no parallax, no smooth-scroll hijack, no auto-play, no large movement. Fades ≤ 150 ms or none.
- The reduced version must still look finished, not broken.
4. Performance
- Animate only
transformandopacity. Never width/height/top/left/margin. - Heavy libraries (scroll timelines, 3D, Lottie) load via dynamic import only on pages that use them.
- No layout thrash: read then write; avoid animating during scroll handlers without rAF/IntersectionObserver.
- Target 60 fps on a mid-range phone and Lighthouse mobile ≥
{{LIGHTHOUSE_TARGET}}. - The LCP element is real HTML text/image, never behind an entrance animation.
5. Taste rules
- One hero moment per page; everything else is quiet.
- Enter: ease-out. Exit: ease-in and faster than enter.
- Stagger lists by 30–60 ms; cap the total under ~600 ms.
- Hover feedback ≤ 150 ms. Never delay a click response for an animation.
- Scroll-pinned sections only where they tell a story; never on every section.
- Nothing flashes more than 3 times per second.
Review checklist
- Uses presets and wrappers only
- transform/opacity only
- Reduced-motion path checked in the browser
- Heavy libs dynamically imported
- 60 fps in a performance trace; Lighthouse target met
Customize for your project
{{MOTION_DIR}}, {{MOTION_LIBRARY}} (e.g. Motion, GSAP), the feel per
theme, {{LIGHTHOUSE_TARGET}} (e.g. 90).
pairs with
- skilltrueorfalse
accessibility
Checks and fixes semantics, keyboard, focus, contrast, labels and motion against WCAG 2.2 AA.
- div or span used as a button
- custom controls (switch, tabs, menu, dialog, combobox)
- icon-only buttons
Claude · Codex · ChatGPT - skilltrueorfalse
design-system
Gives implementers a working checklist so every screen uses primitives and tokens instead of one-off styles.
- raw hex colours, px spacing or font sizes in a component
- a new UI library or icon set being added
- a component duplicated across two screens
Claude · Codex · ChatGPT - skilltrueorfalse
ui-hig
Checks a screen against platform guidelines and the Laws of UX and names the specific rule each problem breaks.
- a new screen or flow being designed
- small or crowded tap targets
- too many choices on one screen
Claude · Codex · ChatGPT