Slider
Pick a value or range by dragging. Optional value bubbles and formatted aria-valuetext.
Needs the @dumb registry in components.json and the style tokens. See Installation.
API reference
Props marked “extra” are Dumb UI additions. Everything else matches shadcn/ui.
Slider
| Prop | Type | Default |
|---|---|---|
| showValueextra | boolean | "interaction"Shows each thumb's value; "interaction" only while hovered, focused or dragged. | false |
| formatValueextra | (value: number) => stringFormats the bubble and aria-valuetext. | String |
| aria-label | stringForwarded to every thumb (with minimum/maximum suffixes for ranges). | - |
- ArrowLeftArrowDown
- Decreases by one step.
- ArrowRightArrowUp
- Increases by one step.
- PageUpPageDown
- Moves by a larger step.
- HomeEnd
- Jumps to min or max.