You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* * Adding so its possible to show steps
- Show step labels
- Show step marks on the track
- Customizable step labels, prefix and suffix styling et.
- Customizable styling for step container, step label and step markers
* Adding smooth-snapped
* Added docs
Copy file name to clipboardExpand all lines: README.md
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -86,15 +86,20 @@ Feel free to contribute to this part of the documentation.
86
86
| max | 10 | number | Maximum value available in the slider. |
87
87
| step | 1 | number | Step value of the slider. |
88
88
| optionsArray | | array of numbers | Possible values of the slider. Ignores min and max. |
89
-
| {container/track/selected/unselected/ markerContainer/marker/pressedMarker} Style | | style object | Styles for the slider |
89
+
| {container/track/selected/unselected/ markerContainer/marker/pressedMarker/step/stepLabel/StepMarker} Style | | style object | Styles for the slider |
90
90
| valuePrefix | | string | Prefix added to the value. |
91
91
| valueSuffix | | string | Suffix added to the value. |
92
92
| enabledOne | true | boolean | Enables the first cursor |
93
93
| enabledTwo | true | boolean | Enables the second cursor |
94
+
| stepsAs | [] | array of objects | Use stepsAs when you want to customize the steps-labels. stepsAs expects an array of objects [{index: number, stepLabel: string, prefix: string, suffix: string}]. Where index is for which step you want to customize, and all the other steps will show its index as its stepLabel. Both showSteps and showStepsLabels has to be enabled for stepsAs to be used. |
95
+
| showSteps | false | boolean | Show steps |
96
+
| showStepMarkers | true | boolean | Show steps-markers on the track, showSteps has to be enabled as well |
97
+
| showStepLabels | true | boolean | Show steps-labels underneath the track, showSteps has to be enabled as well |
94
98
| onToggleOne | undefined | function callback | Listener when first cursor toggles. |
95
99
| onToggleTwo | undefined | function callback | Listener when second cursor toggles. |
96
100
| allowOverlap | false | boolean | Allow the overlap within the cursors. |
97
101
| snapped | false | boolean | Use this when you want a fixed position for your markers, this will split the slider in N specific positions |
102
+
| smoothSnapped | false | boolean | Same as snapped but you can move the slider as usual. When released it will go to the nearest marker |
98
103
| vertical | false | boolean | Use vertical orientation instead of horizontal. |
99
104
| markerOffsetX | 0 | number | Offset the cursor(s) on the X axis |
100
105
| markerOffsetY | 0 | number | Offset the cursor(s) on the Y axis |
0 commit comments