Toolbar

A container for grouping a set of controls, like buttons, toggles or menus.

Props#

Toolbar Props#

The Toolbar renders a ButtonGroup and accepts all ButtonGroup properties.

ToolbarButton Props#

PropTypeDefaultDescription
labelrequiredstring
iconReactElement<any, string | JSXElementConstructor<any>>
iconSpacingResponsiveValue<number | "px" | (string & {}) | "-moz-initial" | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | "auto" | "1" | "-1" | "2" | "-2" | "3" | "-3" | "4" | "-4" | "5" | "-5" | ... 54 more ... | "-3.5">The space between the button icon and label.
isActivebooleanfalseIf true, the button will be styled in its active state.
isDisabledbooleanfalseIf true, the button will be disabled.
isLoadingbooleanfalseIf true, the button will show a spinner.
leftIconReactElement<any, string | JSXElementConstructor<any>>If added, the button will show an icon before the button's label.
loadingTextstring | number | bigint | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal | Promise<...>The label to show in the button when isLoading is true If no text is passed, it only shows the spinner
rightIconReactElement<any, string | JSXElementConstructor<any>>If added, the button will show an icon after the button's label.
spinnerReactElement<any, string | JSXElementConstructor<any>>Replace the spinner component when isLoading is set to true
spinnerPlacement"start" | "end"startIt determines the placement of the spinner when isLoading is true
tooltipPropsOmit<TooltipProps, "children">

ToolbarGroup Props#

The ToolbarGroup renders a ButtonGroup and accepts all ButtonGroup properties.

ToolbarToggleGroup Props#

PropTypeDefaultDescription
defaultValuestring | string[]
isAttachedbooleanfalseIf true, the borderRadius of button that are direct children will be altered to look flushed together
isDisabledbooleanfalseIf true, all wrapped button will be disabled
onChange(value: string | string[]) => void
spacingResponsiveValue<number | "px" | (string & {}) | "-moz-initial" | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | "auto" | "1" | "-1" | "2" | "-2" | "3" | "-3" | "4" | "-4" | "5" | "-5" | ... 54 more ... | "-3.5">'0.5rem'The spacing between the buttons
type"radio" | "checkbox"
valuestring | string[]

ToolbarToggleButton Props#

PropTypeDefaultDescription
labelrequiredstring
iconReactElement<any, string | JSXElementConstructor<any>>
iconSpacingResponsiveValue<number | "px" | (string & {}) | "-moz-initial" | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | "auto" | "1" | "-1" | "2" | "-2" | "3" | "-3" | "4" | "-4" | "5" | "-5" | ... 54 more ... | "-3.5">The space between the button icon and label.
isActivebooleanfalseIf true, the button will be styled in its active state.
isCheckedboolean
isDisabledbooleanfalseIf true, the button will be disabled.
isLoadingbooleanfalseIf true, the button will show a spinner.
leftIconReactElement<any, string | JSXElementConstructor<any>>If added, the button will show an icon before the button's label.
loadingTextstring | number | bigint | boolean | ReactElement<any, string | JSXElementConstructor<any>> | Iterable<ReactNode> | ReactPortal | Promise<...>The label to show in the button when isLoading is true If no text is passed, it only shows the spinner
rightIconReactElement<any, string | JSXElementConstructor<any>>If added, the button will show an icon after the button's label.
spinnerReactElement<any, string | JSXElementConstructor<any>>Replace the spinner component when isLoading is set to true
spinnerPlacement"start" | "end"startIt determines the placement of the spinner when isLoading is true
tooltipPropsOmit<TooltipProps, "children">
type"radio" | "checkbox"
valuestring

Was this helpful?