crucıble

Cinder

A falling-ember background: a parallax field of hot embers, each an incandescent core in an additive-glow halo, stretched into a soft motion-blur streak as it drifts and flickers down. Near embers big/bright/fast, far ones dim/slow. 2D canvas with additive blending, seeded PRNG for deterministic spawn layout, honors prefers-reduced-motion.

canvasfree

Installation

CLI

npx shadcn@latest add @crucible/cinder

Props

PropTypeDefaultDescription
densitynumber28Number of embers in the field. Clamped 6–120.
anglenumber18Fall angle in degrees, measured from vertical (0 = straight down, positive tilts right). Cinder falls steep by default.
speednumber1Fall speed multiplier. 1 = default, 2 = twice as fast.
colorsstring[]a heat paletteEmber colors, hottest → coolest, mapped across the depth field.
pausedbooleanFreeze the shower at its current frame.
seednumberDeterministic seed for spawn layout — same seed always renders the same field.
dprnumber2devicePixelRatio ceiling.
Also accepts all props of React.ComponentPropsWithoutRef<"div">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.