Segmented Control

A set of interactive controls where only one can be selected at a time.

The Segmented Control component is made up of Root and Items, and is based on the Radix Toggle Group primitive. View source.

Contains items and provides the size styles.

PropTypeDefault
valuestring
defaultValuestring
disabledbooleanfalse
onValueChange(value: string) => void
sizeResponsive<"1" | "2" | "3">"2"

This component is based on the div element and supports common margin props m, mx, my, ml, mr, mt, mb.

The interactive button segment. Segmented Control supports no more than 5 items – consider using a Select component if you need more.

PropTypeDefault
valuestring

Use the size prop to control the size of the component.

Use the disabled prop to control whether the component is interactive.