Slider

A component that allows users to make a selection from a range of values.

Thumb refers to the sliding bar; track refers to the lane the thumb is sliding on; tick refers to the little dots that split the track into equal sections.

  • The steps parameter controls the number of ticks in the slider, not including 2 ticks at the edges of the track. If steps is 3, there will be 5 ticks in total: 2 at the edge and 3 in the middle.
  • If steps is 0, there will be no ticks in the middle and any value is selectable.
  • The default thumb is actually a colored Spacer. The more you know!
Compose Multiplatform

Range Slider

A slider that lets the user select 2 values.

  • This type of slider works with FloatingPointRanges.
Compose Multiplatform

Color Customizations

Colors can be customized via SliderDefaults.colors().

Compose Multiplatform