A fully customizable, accessible React multi-range slider component with keyboard support, mobile compatibility, and Tailwind CSS styling. Perfect for price ranges, filtering, data visualization, and any application requiring multiple value selection.
Built with accessibility in mind, featuring complete keyboard navigation, screen reader support, and mobile-first design. Highly customizable with Tailwind CSS classes and extensive prop options.
✨ Key Features
🎛️ Multiple Handles
Support for 2 or more handles with flexible value management and intuitive drag interactions.
⌨️ Keyboard Navigation
Complete keyboard support with arrow keys, home/end, page up/down, and shift modifiers for accessibility.
📱 Mobile Optimized
Touch events, responsive design, and mobile-friendly interactions for seamless mobile experiences.
♿ Accessibility First
ARIA labels, screen reader support, and WAI-ARIA guidelines compliance for inclusive design.
🎨 Fully Customizable
Colors, sizes, formatting, and behavior customization via props with Tailwind CSS integration.
🎯 Marks & Labels
Visual indicators with custom labels, value formatting, and flexible positioning options.
📦 Installation
npm install react-multi-slider-pro
# Using yarn
yarn add react-multi-slider-pro
🚀 Quick Start
Get started with MultiSliderPro in just a few lines of code:
Demo:
📋 Complete Props Reference
| Prop | Type | Default | Description |
|---|---|---|---|
values |
number[] |
[20, 80] |
Array of handle values |
min |
number |
0 |
Minimum value |
max |
number |
100 |
Maximum value |
step |
number |
1 |
Step size for value changes |
disabled |
boolean |
false |
Disable the slider |
onChange |
(values: number[]) => void |
- |
Called when values change |
onChangeCommitted |
(values: number[]) => void |
- |
Called when user finishes changing |
showLabels |
boolean |
false |
Show min/max labels and value chips |
showValueLabels |
boolean |
false |
Show value labels above handles |
formatLabel |
(value: number) => string |
- |
Custom value formatting function |
trackColor |
string |
'bg-gray-300' |
Tailwind class for track color |
rangeColor |
string |
'bg-blue-500' |
Tailwind class for range color |
handleColor |
string |
'bg-blue-500' |
Tailwind class for handle color |
labelColor |
string |
'text-white' |
Tailwind class for label text color |
marks |
Mark[] |
[] |
Array of marks to display |
allowCross |
boolean |
false |
Allow handles to cross each other |
pushable |
number |
0 |
Minimum distance between handles |
💡 Practical Examples
Price Range Selector
Perfect for e-commerce filtering with formatted currency values:
Three-Handle Custom Styling
Multiple handles with custom colors and sizing:
Slider with Visual Marks
Add visual indicators with custom labels:
API Integration Pattern
Separate real-time updates from API calls:
⌨️ Keyboard Navigation
| Key Combination | Action |
|---|---|
← ↓ |
Move handle left/down by step |
→ ↑ |
Move handle right/up by step |
Shift + ←↓→↑ |
Move handle by large step (10% of range) |
Home |
Move handle to minimum value |
End |
Move handle to maximum value |
Page Down |
Move handle down by large step |
Page Up |
Move handle up by large step |
Tab |
Navigate between handles |
♿ Accessibility Features
MultiSliderPro follows WAI-ARIA guidelines for maximum accessibility:
- ARIA Support: Each handle has
role="slider"with properaria-valuemin,aria-valuemax, andaria-valuenowattributes - Screen Reader Friendly: Descriptive labels and value announcements
- Keyboard Navigation: Complete keyboard support for handle manipulation
- Focus Management: Proper focus indicators and tabbing behavior
🎨 Styling Customization
Extensive customization options using Tailwind CSS classes:
Color Themes
Size Variations
🔧 Handle Behavior Configuration
Prevent Handle Crossing
Allow Handle Crossing
🌐 Browser Support
- ✅ Chrome/Chromium 60+
- ✅ Firefox 55+
- ✅ Safari 12+
- ✅ Edge 79+
- ✅ Mobile browsers (iOS Safari, Chrome Mobile)
🔍 Advanced Use Cases
Dynamic Value Formatting
Data Visualization Integration
💖 Support This Project
If you find MultiSliderPro helpful, please consider supporting its development!
💝 Sponsor on GitHub ⭐ Star on GitHub📝 TypeScript Support
While the component is written in JavaScript, TypeScript definitions can be easily added. The component exports clean interfaces for all props:
🎯 Best Practices
- Performance: Use
onChangeCommittedfor API calls to avoid excessive requests - Accessibility: Always provide meaningful
aria-labelvalues - UX: Use appropriate step sizes for your use case (e.g., step={0.1} for decimals)
- Mobile: Test touch interactions on various screen sizes
- Styling: Ensure sufficient color contrast for accessibility compliance
🚨 Common Gotchas
values prop and onChange handler.
allowCross={false}, handles will push each other. Use pushable to set minimum distance.
📚 Additional Resources
Feel free to open an issue on GitHub or reach out to the maintainer. Community contributions and feedback are always welcome!
MultiSliderPro v1.0.2 – Built with ❤️ for the React community
MIT License | Created by Andrei-Constantin Alexandru


