전체 카탈로그
Data InputSlider22 props

Slider

A draggable control for selecting a numeric value or range within defined bounds. Supports single value and range selection, tick marks, custom value formatting, and vertical or...

공식 문서 열기
live previewData Input

Preview

Import

import {Slider} from '@astryxdesign/core/Slider';

Astryx 문서 권장 방식대로 root barrel이 아니라 컴포넌트 subpath에서 가져옵니다.

When to use

A draggable control for selecting a numeric value or range within defined bounds. Supports single value and range selection, tick marks, custom value formatting, and vertical or...

sliderrangeslidebartrackbarscrubberknobthumbrangeslider

Important props

valuenumber | [number, number]required
onChange(value: number) => void | (value: [number, number]) => voidoptional
onChangeEnd(value: number) => void | (value: [number, number]) => voidoptional
orientationhorizontal | verticaloptional

Theming targets

astryx-sliderastryx-slider-trackastryx-slider-thumb

Best practices

  • DoAlways provide a label, even if visually hidden, so the slider is accessible to screen readers.
  • DoFormat values with meaningful units like "$50" or "75%" instead of raw numbers.
  • Do notUse for precise numeric entry; pair with a text input or use NumberInput instead.
  • Do notSet a step size so large that only a few positions are possible; use SegmentedControl or radio buttons instead.