morphing-icons

Build SVG icon components that morph between any two icons through three-line transformations.

3|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/langgenius/due-date-hq-jwl --skill morphing-icons-langgenius
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: morphing-icons
Source: https://github.com/langgenius/due-date-hq-jwl/tree/main/.claude/skills/morphing-icons
Command: npx skills add https://github.com/langgenius/due-date-hq-jwl --skill morphing-icons-langgenius

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Icon transitions in UI often rely on crossfades that look cheap and break visual continuity. This Skill provides a structured approach to building icon components where any icon morphs into any other through actual SVG line transformation, using a shared three-line structure. ## Core Features & Use Cases - Universal Morphing: Every icon is defined as exactly three SVG lines, so any icon can transform into any other without special pairing logic. - Rotation Groups: Rotational variants like arrows or plus/cross share line definitions and animate rotation with spring physics via Motion. - Audit Rules: Nine implementation rules (three-line constraint, collapsed lines, consistent viewbox, reduced motion, aria-hidden, and more) let you audit existing icon code with structured findings and severity summaries. - Use Case: Build a menu button that morphs into a close icon on toggle, or an arrow that rotates smoothly between directions in a carousel, all from one component. ## Quick Start Create a morphing icon component where a menu icon transforms into a close icon using the three-line SVG structure.

Frequently Asked Questions about morphing-icons

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I animate between two SVG icons in React?

Define every icon as exactly three SVG lines with shared coordinates, then animate the line endpoints with Motion. Icons needing fewer lines collapse extras to invisible center points, so any icon can morph into any other.

How to build a menu icon that morphs into a close icon?

Define the menu as three horizontal lines and the close icon using the same three-line structure repositioned into an X. Animate the line coordinates with an exponential ease-out transition of about 0.4 seconds for a smooth morph.

Why should icon transitions avoid crossfade animations?

Crossfades swap opacity between two separate icons, which looks disjointed and breaks visual continuity. Line transformation keeps the same strokes on screen, so the icon visibly reshapes itself into the target state.

How do I handle arrow icons pointing in different directions?

Give all arrow directions the same line definitions and group name, differing only by rotation value (0, 90, 180, -90). Use a spring-animated rotation so transitions between grouped arrows rotate smoothly instead of redrawing.

Does morphing icon animation support reduced motion preferences?

Yes, use the useReducedMotion hook from Motion and set the transition duration to zero when the user prefers reduced motion. This disables the morph animation while keeping the icon state change instant and accessible.