Range sliders should only be used
when the precise value is not considered important. If
- the precise value does matter, add the showInput
prop or use
- a EuiFieldNumber
instead.
-
- While currently considered optional, the showLabels
property should
- be added to explicitly state the range to the user.
+ the precise value does matter, add the
+ The EuiDualRange accepts almost all the same props as the regular EuiRange, with
+ the exception of
- Two-value input[type=range]
elements are not part of the HTML5 specification.
- Because of this support gap, EuiDualRange
cannot expose a native value
property
- for native form
to consumption.
+ Two-value onChange
prop is the recommended method
+ The React
- EuiDualRange
does use native input
s to help validate step values
- and range limits. These may be used as form
values when showInput
is in use.
- The alternative is to store values in input[type=hidden]
.
+ EuiDualRange does use native inputs to help validate step values
+ and range limits. These may be used as form values when
+ The
+ Passing empty strings as the
+ To show clickable tick marks and labels at a given interval, add the prop
+ To pass completely custom tick marks, you can pass an array of objects that
+ require a
Spacing can get quite cramped with lots of ticks so we max out the number to 20.
+
+ To create colored indicators for certain intervals, pass an array of objects that
+ include a
+ Be sure to then add an
+ Other alterations you can add to the range are