Crucible

Sandcast

Headline cast in fine gold sand: the text is sampled into grains that scatter with velocity and curl under the cursor, then trickle back home with staggered springs and a settling drift.

canvaspro

Installation

CLI

npx shadcn@latest add @crucible/sandcast

Props

PropTypeDefaultDescription
textstring"SANDCAST"Headline cast in sand (also emitted as sr-only text).
gapnumber3Sampling gap in px between grains — smaller = denser, more particles.
particleSizenumber1.7Base grain size in px (each grain jitters around it).
colorsstring[]warm goldsGrain palette, assigned per particle. Keep it a narrow single-hue ramp — the default is fine gold sand.
scatterRadiusnumber100Pointer repulsion radius in px.
strengthnumber1Pointer repulsion strength multiplier.
stiffnessnumber1Return-spring stiffness multiplier — how eagerly grains trickle home.
speednumber1Simulation-rate multiplier.
pausedbooleanfalseFreeze the simulation (grains hold their current positions).
seednumber5Deterministic seed for grain jitter and the entrance drift.
Also accepts all props of Omit<React.ComponentPropsWithoutRef<"div">, "children" | "color">they pass through to the underlying element.

Honors prefers-reduced-motion with a designed static fallback, pauses offscreen and on hidden tabs, and passes className through.