Components
IconMorph
Icon with blur-crossfade morph animation between icon changes. Drop-in replacement for Icon when you need animated transitions. The icon stays in place while crossfading with a blur effect.
Usage
Best practices
Change
morphKeywhenevericonchanges (e.g. play↔pause) - the crossfade is keyed off it, so a stale key swaps the new glyph in with no morph.Use it as the animated drop-in for
Icon; for a plain static glyph stay onIconand skip the extraAnimatePresence/motion cost.Needs
ReducedMotionProviderfor the blur-crossfade to run and honour reduced motion; likeIconit rendersaria-hidden, so name the control elsewhere.
Props
Also exports
- interface
IconMorphProps
Composition
Builds on
Used by