Enter
Buttons

SquishButton

The library's base button. Press it and the surface compresses into the page, then springs back past its rest size before settling.

Circle
Magnetic
Disabled

Usage

<SquishButton
  variant="solid"
  size="md"
  intensity="normal"
  spring="smooth"
  extrude={4}
>
  Press me
</SquishButton>

How the motion works

Compression is volume-preserving: the Y axis squashes while X widens at a softened ratio, which is what reads as a squash rather than the element scaling away from the viewer. The extruded bottom edge is a hard shadow that shortens by the same amount the surface sinks, so the key's total silhouette height stays constant while held. Release runs on an under-damped spring, producing the overshoot.

usePressuseMagneticuseSpringValue

Props

PropTypeDefaultDescription
variant"solid" | "soft" | "outline" | "ghost" | "danger""solid"Visual treatment.
size"sm" | "md" | "lg""md"Control height and typography scale.
intensity"subtle" | "normal" | "strong""normal"Scales how far the surface squashes.
springSpringLike"bouncy"Release spring preset or explicit config.
circlebooleanfalseRenders as a 1:1 circle.
magneticbooleanfalsePulls toward the cursor while nearby.
extrudenumber4Height of the extruded bottom edge in px. 0 is flat.
radiusstringOverrides the token radius with any CSS length.
startIcon / endIconReactNodeContent rendered before or after the children.