$npx -y skills add educlopez/ui-craft --skill animateMotion design pass — adds purposeful animations or removes excessive ones, respecting MOTION_INTENSITY and the project's animation stack. Use when the user asks to add animation, "make it feel smoother", fix janky transitions, or trim motion that's distracting. Invoke when the us
| 1 | <!-- HARNESS MIRROR — do not edit here. Canonical source: skills/ or commands/. After editing source, copy into cli/assets/<harness>/ and repo-root harness mirrors. --> |
| 2 | |
| 3 | **Context:** this sub-skill is one lens of the broader `ui-craft` skill. If the `ui-craft` skill is also installed, read its SKILL.md first for Discovery + Anti-Slop + Craft Test, then apply the specific lens below. |
| 4 | |
| 5 | Add or fix animations in the target the user described. Load the `ui-craft` skill. |
| 6 | |
| 7 | **Step 1 — Decision Ladder**: run the Decision Ladder from `references/motion.md` first. Anything that fails it gets removed, not improved. |
| 8 | |
| 9 | **Step 2 — Pick the library**: |
| 10 | |
| 11 | - If user opted into a stack during Discovery → read `references/stack.md`. Use the matching section (Motion, GSAP, or Three.js). Never mix libraries on the same property. |
| 12 | - Otherwise → CSS transitions / `@keyframes` / `animation-timeline: view()` only. |
| 13 | |
| 14 | **Step 3 — Apply motion budget**: |
| 15 | |
| 16 | | Element | Budget | |
| 17 | |---|---| |
| 18 | | Color/opacity | 100-150ms | |
| 19 | | Small UI (tooltips, dropdowns) | 150-200ms | |
| 20 | | Medium UI (modals, panels) | 200-300ms | |
| 21 | | Large UI (page transitions, drawers) | 300-400ms | |
| 22 | |
| 23 | Exit ≈ 75% of entrance duration (shorter, same `ease-out` — or a flatter tail like `cubic-bezier(0.4, 0, 1, 1)` for a softer exit). Never `ease-in` on UI (see `references/motion.md`). `cubic-bezier(0.22, 1, 0.36, 1)` is a safe spring-like default. |
| 24 | |
| 25 | **Step 4 — Multi-stage sequences** → read `../examples/animation-storyboard.md`. Stagger 30-80ms, not 200ms. |
| 26 | |
| 27 | **Step 5 — Respect the knobs**: |
| 28 | - `MOTION_INTENSITY ≤ 3` → hover states only, no entrances, no scroll-triggered. |
| 29 | - `MOTION_INTENSITY 4-7` → standard entrances + hover, one scroll reveal max per section. |
| 30 | - `MOTION_INTENSITY 8+` → scroll-linked, page transitions, magnetic cursor OK (still honor reduced-motion). |
| 31 | |
| 32 | **Output**: edit code directly. After each file, print the Review Format table. Flag any animation you removed and why. |