Metamorph

Morph Loader

A loader that keeps changing shape and ends on a check.

Preview

Installation

Terminal
npx @usefluid/cli add morph-loader

Usage

MorphLoader.tsx
import { MorphLoader } from "./MorphLoader";

<MorphLoader done={!loading} label="Loading orders" doneLabel="Orders loaded" />

API reference

PropTypeDefaultDescription
doneboolean—False while loading; true lands on the check.
labelstring"Loading"Announced while loading.
doneLabelstring"Done"Announced when done.

Keyboard and screen readers

A status region. Reduced motion shows a still shape.

Notes

It loops only while done is false, which is the one honest place for a loop.

Every colour comes from the --fluid-* variables, and the piece is yours to change.

How it is made

While loading, the same contour goes through several shapes with the morph engine. When it is done, it flows into a check. The change is announced through a status region, without depending on the animation.

For your agent

For your agent

Add Morph Loader to my project with the Fluid library. Use MorphLoader on loads that take longer than a second. Read my project first. Use my logo, my colours and my font through the --fluid-* variables. Keep 44px touch targets, visible focus and reduced motion. If I have no SVG logo, ask before making one up.