API

The whole public surface, across two entry points. This page renders from the same list a test compares against the package's real exports — if it documented something that no longer exists, the test fails.

<gf-icon>

InputTypeDefault
iconDefAnimatedIconDefThe tree-shakeable path. Wins over name.
namestring''Requires provideIconCatalog. Unknown = renders nothing, doesn't throw.
animationstring'default'Which variant to play.
triggerAnimatedIconTrigger'group'When it animates.
sizenumber | string24The SVG's side length.
strokeWidthnumber | string2Stroke thickness.
loopbooleanfalseWith one-shot easings, the cut between loops shows.
delaynumber0Extra delay (ms), ADDED on top of each track's own.
viewOncebooleantrueOnly with trigger="view".
decorativebooleantrueSee Accessibility: label decides.
labelstringWith label, the icon is semantic.
respectReducedMotionbooleantrueStays static if the system asks for it.

Public methods on the component instance. They're what you need with trigger="manual":

  • play(variant?) — plays a variant; with no argument, the one from the animation input.
  • reverse() — returns to the starting pose animating, not all at once. Tracks only: reversing an autoDraw would UNdraw the icon, which is nobody's intent when the pointer leaves.
  • cancel() — cuts everything off and puts the shapes back in their original pose.

<gf-icon-morph>

InputTypeDefault
iconMorphIconThe binding IS the state. The first value renders static.
sizenumber | string24The SVG's side length.
strokeWidthnumber | string2Stroke thickness.
decorativebooleantrueSame contract as <gf-icon>.
labelstringWith label, the icon is semantic.
respectReducedMotionbooleantrueHere it JUMPS to the destination instead of staying still.
springSpringPreset | SpringConfig'smooth'smooth / snappy / bouncy, or your own { k, c }. Only decides timing, never geometry.
livebooleanfalseBaked (WAAPI, default) vs live (a real spring via requestAnimationFrame). Fixed after the first use — changing it later has no effect.

Exports from glyphflow

SymbolWhat it is
GfIconComponentcomponent The engine. Selector <gf-icon>. Standalone.
provideGfIconsfunction Optional global config. Today just durationScale.
GF_ICONS_CONFIGtoken The InjectionToken behind provideGfIcons, in case you want to provide it yourself.
provideIconCatalogfunction Registers the catalog so you can use name=. Opt-in: without this, name= renders nothing.
GF_ICON_CATALOGtoken The catalog's token. Without it, an unknown name renders empty, without throwing.
CURATED_ICONSconstant The 1767 with hand-authored choreography.
GENERATED_ICONSconstant The remaining 0 from Lucide, auto-draw only.
ANIMATED_ICONSconstant Curated + generated. Referencing it anchors the whole catalog in your bundle.
ANIMATED_ICON_NAMESconstant The catalog's keys. Same bundle cost as ANIMATED_ICONS.
ICON_ALIASESconstant Real Lucide renames (same glyph, new name).
resolveIconNamefunction Applies the aliases: old name → current name.
ICON_METAconstant Per-icon metadata: curated flag, source, search tags.
ICON_TAGSconstant Lucide's search synonyms per icon, without the geometry.
ICON_VARIANTSconstant Which animation variants each icon has, without the geometry. Always starts with draw.
SPRING_SMOOTHconstant ζ=1.00, critical, no overshoot. The house default for going from A to B.
SPRING_SNAPPYconstant ζ=0.73, fast with a subtle overshoot.
SPRING_BOUNCYconstant ζ=0.40, a real bounce.
MaxIconComponentdeprecatedcomponent The engine. Selector <gf-icon>. Standalone. Use GfIconComponent instead.
provideMaxIconsdeprecatedfunction Optional global config. Today just durationScale. Use provideGfIcons instead.
MAX_ICONS_CONFIGdeprecatedtoken The InjectionToken behind provideGfIcons, in case you want to provide it yourself. Use GF_ICONS_CONFIG instead.
MAX_ICON_CATALOGdeprecatedtoken The catalog's token. Without it, an unknown name renders empty, without throwing. Use GF_ICON_CATALOG instead.

Types

Type
AnimatedIconDefAn icon: geometry + its animation variants.
IconShapeAn SVG shape (path, circle, line…).
IconChoreographyA variant: per-shape tracks + autoDraw + reverseOnLeave.
MotionTrackKeyframes + WAAPI options for one shape.
AutoDrawAuto-draw config (speed, overlap, caps).
AnimatedIconTrigger'group' | 'hover' | 'tap' | 'view' | 'auto' | 'manual'.
GfIconsConfigWhat provideGfIcons receives.
IconMetaOne catalog icon's metadata. `tags` is always populated.

Exports from glyphflow/morph

SymbolWhat it is
GfIconMorphComponentcomponent Selector <gf-icon-morph>. Changing [icon] triggers the transition.
MaxIconMorphComponentdeprecatedcomponent Selector <gf-icon-morph>. Changing [icon] triggers the transition. Use GfIconMorphComponent instead.
morphKeyframesfunction Computes the discrete `d` keyframes between two icons. Doesn't animate anything.
runMorphfunction morphKeyframes + element.animate(). Returns the Animation so you can control it.
canonicalDfunction The already-resolved `d` of an icon — what renders when there's no transition.
morphAtfunction The exact morph pose at any t (0-1), with no animation — for scrubbers and manual control.
createLiveMorphfunction The live engine: a spring driven by requestAnimationFrame, instead of precomputed WAAPI keyframes.
SPRING_PRESETSconstant smooth (ζ=1.00), snappy (ζ=0.73), and bouncy (ζ=0.40). The last two actually overshoot.
STEPS_DEFAULTconstant 20 discrete poses. Decided in the Lab by comparing 10/15/20/30.
RESOLUTION_DEFAULTconstant 64 points per subpath.
SPRING_TAIL_DEFAULTconstant What to do with the spring's asymptotic tail.
correspondenceIsPoorfunction `true` when no matching algorithm would save the pair — the engine fades instead of deforming.
QUALITY_RESIDUAL_MAXconstant Procrustes residual threshold above which the correspondence counts as poor.
QUALITY_FRAGMENTATION_MAXconstant Subpath fragmentation threshold above which the correspondence counts as poor.
maxLinearDeviationfunction How far WAAPI's linear interpolation between baked poses strays from the real polar trajectory.
COPY_INTENTconstant Copy to clipboard: copy becomes check, snappy, and returns to rest on its own after 2 s.
THEME_INTENTconstant Light to dark: sun becomes moon, with smooth — a change of mood, not a confirmation.
PASSWORD_INTENTconstant Reveal or hide a password: eye becomes eye-off. Active means the password is visible.
PLAY_PAUSE_INTENTconstant Playback transport: play becomes pause. Active means it is playing, so the button offers to pause.
MENU_CLOSE_INTENTconstant Navigation menu: menu becomes x. Active means open, so the button offers to close.
EXPAND_COLLAPSE_INTENTconstant Expand and collapse: the chevron flips. Active means expanded, so it points up.
LIKE_INTENTconstant Remove a "like": heart becomes heart-off (broken by a slash, not filled). Active means it's already removed.
FAVORITE_INTENTconstant Favorite: star becomes star-off, fragmented by the same slash. Active means no longer favorited.
NOTIFY_INTENTconstant Notifications: bell becomes bell-off. Active means muted.
PIN_INTENTconstant Pin an item: mapPin becomes mapPin-off. Active means it's no longer pinned.
VOLUME_INTENTconstant Sound: volume2 (two waves) becomes volume-off. Active means muted — the one of the six whose curated pair had to be extended (volumeOff↔volume2 didn't exist, only volumeOff↔volume with no waves).
PASOS_DEFAULTdeprecatedconstant 20 discrete poses. Decided in the Lab by comparing 10/15/20/30. Use STEPS_DEFAULT instead.
RESOLUCION_DEFAULTdeprecatedconstant 64 points per subpath. Use RESOLUTION_DEFAULT instead.
COLA_DEFAULTdeprecatedconstant What to do with the spring's asymptotic tail. Use SPRING_TAIL_DEFAULT instead.

Types

Type
MorphIconWhat [icon] accepts: an AnimatedIconDef or its geometry.
MorphKeyframesmorphKeyframes' output: keyframes, duration, weight.
MorphKeyframesOptsSteps, resolution, tail, spring, overshoot.
RunMorphOptsThe above + loop, direction, and durationScale.
SpringConfigRaw spring: stiffness and damping.
SpringPresetThe names in SPRING_PRESETS: 'smooth' | 'snappy' | 'bouncy'.
LiveMorphcreateLiveMorph's handle: morphTo, set, destroy.
LiveMorphOptsspring and durationScale, same vocabulary as the baked engine.
MorphIntentA two-state gesture with its character already decided: the pair of figures, its spring, and whether the active state expires.
GfAsyncStateThe four moments of an async operation: idle, loading, success, error.

The icons

On top of the above, glyphflow exports one const per icon with an Icon suffix — bellIcon, trash2Icon, circleCheckIcon. That's the tree-shakeable path, which is why they're not listed one by one: there are ~1767 of them, and the browsable catalog lives at the icons page.

The const's name is the icon's name in camelCase plus Icon: trash-2trash2Icon, circle-checkcircleCheckIcon. Each icon's detail panel gives you the snippet already built.