Agent skill Web motion
Animate
Design, implement or review motion on the web.
Install the skill
Run the command from your project root with Node.js and npm.
npx skills@latest add delphi-ai/animate-skill --skill animate --agent claude-code --yesCheck this file in your project.claude/skills/animate/SKILL.md
Other ways to install
Choose an assistant interactively
npx skills@latest add delphi-ai/animate-skill --skill animateSelect your assistant and choose the project installation scope.
Official instructions
The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. Use React and the Motion dependency already installed. The publisher example uses react-use-measure to observe inner content dimensions.
View operation manualWhat this skill helps with
- Design, implement or review motion on the web.
Good for
- Web motion and transitions
- Publisher
- delphi-ai
- Controls
- examples/animate-height.tsx · measured inner · animated outer · 0.3s
- Result
- The wrapper ends at the actual content height and the trigger state matches expansion.
- Skill name
animate- Repository
delphi-ai/animate-skill
Common pitfall
Avoid this prompt
Observe and animate the same box, or swap to zero height before the initial measurement exists.
Separate layout measurement from animation so the observer tracks real content and the initial state stays visible.
Use these steps
- Read the source and set up the example
- Implement the documented behavior
- Inspect the actual result
Project walkthrough
Animate a disclosure’s measured height while keeping its inner content readable.
Animate a disclosure’s measured height while keeping its inner content readable.
Read the source and set up the example
Use React and the Motion dependency already installed. The publisher example uses react-use-measure to observe inner content dimensions.
Prompt · Step 1Use Delphi Animate on [my details panel]. Read examples/animate-height.tsx. Locate the real trigger, the summary that stays visible, and the region that grows. Match the project’s installed Motion import and its measurement helper.Implement the documented behavior
Animate a disclosure’s measured height while keeping its inner content readable.
Prompt · Step 2Measure the inner content using the publisher’s react-use-measure example or an existing ResizeObserver-based equivalent. Animate the outer wrapper to that height over 0.3s after measurement. Keep aria-expanded in sync, avoid hiding the initial summary before measurement, and update height immediately in reduced motion.Inspect the actual result
The wrapper ends at the actual content height and the trigger state matches expansion.
- The wrapper ends at the actual content height and the trigger state matches expansion.
Prompt · Step 3Open with the keyboard, compare inner and settled outer height, then change content length or viewport width and compare again. Close and check the summary and focus remain available. Repeat with reduced motion enabled.
Implementation lookup
Compare the required inputs with the local verification result.
Inspect the implementation controlsVerify
- Command or reference
examples/animate-height.tsx · measured inner · animated outer · 0.3s- Examples
- The wrapper ends at the actual content height and the trigger state matches expansion.
FAQ
What should I prepare first?
Use React and the Motion dependency already installed. The publisher example uses react-use-measure to observe inner content dimensions.
How do I verify the result?
The wrapper ends at the actual content height and the trigger state matches expansion.