Skip to content
caliper ui pro docs

Elastic slider

A slider with give. Drag past either end and the track stretches toward your finger, the end icon leans with it, and both spring back when you let go. The value is always clamped; only the drawing stretches.

Pro
Brightness
Zoom

When to use

  • Volume, brightness, zoom and other values where the ends matter.
  • Touch-first controls where a hard stop feels dead.

When not to use

  • Precise numeric entry; pair a number field or use the scrub field.
  • Ranges with two thumbs; use the range slider.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/elastic-slider

Adds its 4 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.

API reference

ElasticSlider

10 props
PropTypeDefaultDescription
label *string—
value *number—
onValueChange *(value: number) => void—
minnumber0
maxnumber100
stepnumber1
startIconReactNode—
endIconReactNode—
format((value: number) => string)(v) => String(v)The visible and spoken value, such as "40%".
classNamestring—

rubberBand

0 props

No props of its own; it accepts the native props of its root element.

Keyboard

Home
Jumps to the first item or the minimum.
End
Jumps to the last item or the maximum.

Accessibility

It exposes slider semantics, with aria-hidden, aria-label, aria-valuemin, aria-valuemax, aria-valuenow and aria-valuetext kept in step with state.

Notes for AI

Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.

/docs/components/elastic-slider.md

The index of every part is at /llms.txt.

More in Playful fields