ToggleGroup
a collection of toggle buttons capable of being switched between two states: on or off.
The default selected value. When
multiple
is true, value should be an array.string
"option1"
array[string]
["option1", "option2"]
Whether to allow multiple options to be selected. When multiple is true, 'value' should be an array of selected options.
boolean
true
false
Function that will be called when the user selects an option.
function
({ value: nextValue }) => setValue(nextValue)
Options can be either an array of type string, or object. Each option is rendered as a single Button within ToggleGroup. The options that can be passed in can be icon, label, value, tip
string
["option1", "option2"]
array[object]
[ { icon: <Bold />, label: "Bold" value: "bold", tip: "bold" } ]
Any valid Box property for the ToggleGroup container.
object
{ round: 'xsmall', border: true, }