MtSlider component allows users to select a numeric value or range using an interactive slider.
Import
Props
The value of the slider. If
isRange is true, this should be an array with two values.Defines the label of the slider.
Defines the minimum value of the number.
Defines the maximum value of the number.
Defines the amount by which the number is increased or decreased per step.
Defines if it is a range slider.
Defines the minimum distance between the two sliders. Should be a multiple of the step.
Defines the amount of marks on the slider.
Disables the slider.
Marks the field as required.
Help text with additional information.
Toggles inheritance visualization.
Determines if the field is inheritable.
Events
Emitted when the slider value changes.
Emitted when inheritance is restored.
Emitted when inheritance is removed.
Slots
Additional hint content.
Usage
Basic Slider
Range Slider
Custom Step Size
With Minimum Distance
Custom Mark Count
Percentage Slider
Accessibility
- Uses native range input for accessibility
- Keyboard navigation (arrow keys to adjust value)
- Tooltip shows current value on hover
- Visual marks indicate scale
- Number fields allow direct input
- ARIA labels for screen readers
- Disabled state prevents interaction