Directory
- Welcome
Slider Component
The Slider component provides an intuitive way to select numeric values within a specified range. It’s perfect for settings, filters, and any interface where users need precise control over numeric inputs.
Key Features
-
Custom Styling: Multiple variants and sizes
-
Value Display: Optional value indicator
-
Form Integration: Native form support
-
Accessibility: Full keyboard and screen reader support
Basic Usage
Create a simple slider with a value and range:
<Slider min={0} max={100} value={50}/>
Variants
Default Style
Size Options
Enhanced Features
Add labels and value displays:
<Slider label="Volume Control" sublabel="Adjust system volume" showValue={true} min={0} max={100} value={75}/>
Slider Component Props API
Prop | Type | Default | Description |
---|---|---|---|
label | string | Label text for the slider | |
sublabel | string | Additional description text | |
showValue | boolean | false | Show current value display |
size | sm | default | lg | default | Size of the slider |
variant | default | filled | filled | Visual style variant |
Limited Time Launch Sale
Get our AstroJS starter template now and build stunning websites with professional-grade components like this customizable slider!
GET 60% OFF!