Bootstrap5 Range Selection
To set up a range selection, you can add type="range" to the input element and use the .form-range
class:
Range Selection:
Example
<label for="customRange" class="form-label">Custom range</label>
<input type="range" class="form-range" id="customRange">
Step Size
By default, the step size is 1, which can be set using the step attribute:
Example
<input type="range" class="form-range" step="10">
Minimum and Maximum Values
By default, the minimum value is 0 and the maximum value is 100, which can be set using the min (minimum) or max (maximum) attributes:
Example
<input type="range" class="form-range" min="0" max="4">