Click spark

DarkInspect

A burst of sparks from wherever its content is pressed: a mouse press, a tap, or a key on a control inside it. The default is ours, the umlaut: each spark is the logo's two dots, flying out side by side in its green. Colours may be Cüte's tokens, read from the CSS at each burst. Reduced motion keeps a short, still burst.

Examples

Shapes

The umlaut, a dot, a line, a streak with a fading tail, and a twinkling star.

DarkInspect

API reference

PropTypeDefaultDescription
shape"umlaut" | "dot" | "line" | "streak" | "star""umlaut"Each spark's look; the umlaut is the logo's pair of dots.
sparkColorstring | string[]"var(--color-brand-green)"A colour, or a list mixed through each burst. Tokens work.
sparkCountnumber8Sparks in each burst.
sparkRadiusnumber30How far they travel from the press, in px.
sparkSizenumber14Each spark's length, in px.
sparkWidthnumber2Each spark's thickness, in px; a dot's radius follows it.
durationnumber500A burst's length, in ms.
easing"ease-out" | "ease-in-out" | "ease-in" | "linear" | "spring""ease-out"How the sparks slow; spring overshoots a little and settles.
randomnessnumber0.2Varies each spark's angle, length and speed, 0 to 1.
gravitynumber0Pulls the sparks down as they fly, 0 to 2.
spreadnumber360The angle they fan across, in degrees.
directionnumber0Where a partial spread points, in degrees; 0 is up.
glownumber0Soft light round each spark, 0 to 1.
ringbooleanfalseA thin ring expanding from the press.
layer"front" | "back""front"Over the content, or behind it so they burst out round it.
disabledbooleanfalseStops new bursts.
refRef<{ spark: (x?: number, y?: number) => void }>—spark() fires a burst from code, centred without x and y.