Compose the buttons and give it a name.
format-bar.tsx
Toolbar
<div>| Prop | Type | Default | Description |
|---|---|---|---|
| variant | "outline""plain" | "outline" | |
| class | string | — | |
From Base UIToolbar.RootBase UI docs | |||
| disabled | boolean | — | |
| orientation | "horizontal""vertical" | "horizontal" | The orientation of the toolbar. |
| loop | boolean | true | If true, using keyboard navigation will wrap focus to the other end of the toolbar once the end is reached. |
| ...props | <div> attributes | — | Every other attribute goes to the <div>, with a ref. |
ToolbarGroup
<div>| Prop | Type | Default | Description |
|---|---|---|---|
| class | string | — | |
From Base UIToolbar.GroupBase UI docs | |||
| disabled | boolean | false | When true all toolbar items in the group are disabled. |
| render | — | Allows you to replace the component's HTML element with a different tag, or compose it with another component. Accepts a ReactElement or a function that returns the element to render. | |
| style | — | Style applied to the element, or a function that returns a style object based on the component's state. | |
| ...props | <div> attributes | — | Every other attribute goes to the <div>, with a ref. |
ToolbarButton
<button>| Prop | Type | Default | Description | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| rounded | "default""full" | — | ||||||||||||
| size | "default""icon""icon-lg""icon-sm""icon-xs""lg""sm""xl""xs" | "sm" | ||||||||||||
| variant | "dashed""default""destructive""destructive-outline""ghost""link""media""outline""secondary" | "ghost" | ||||||||||||
| class | string | — | ||||||||||||
| unstyled | boolean | false | Drop the Button look and keep only className. Use it when render mounts a component with its own look (a Toggle, a ToggleGroupItem, a SelectTrigger), or the two looks mix. | |||||||||||
| chevron | boolean | false | Add a chevron after the content, for a button that opens a menu, a select, or a popover with its current value in front ("Heading 1", a list icon, the color "A"). See the JSDoc of ToolbarButton. Default false. | |||||||||||
From Base UIToolbar.ButtonBase UI docs | ||||||||||||||
| disabled | boolean | false | When true the item is disabled. | |||||||||||
| focusable | boolean | true | When true the item remains focusable when disabled. | |||||||||||
| render | — | Allows you to replace the component's HTML element with a different tag, or compose it with another component. Accepts a ReactElement or a function that returns the element to render. | ||||||||||||
| ||||||||||||||
| ...props | <button> attributes | — | Every other attribute goes to the <button>, with a ref. | |||||||||||
ToolbarLink
<div>| Prop | Type | Default | Description |
|---|---|---|---|
| rounded | "default""full" | — | |
| size | "default""icon""icon-lg""icon-sm""icon-xs""lg""sm""xl""xs" | "sm" | |
| variant | "dashed""default""destructive""destructive-outline""ghost""link""media""outline""secondary" | "ghost" | |
| class | string | — | |
| ...props | <div> attributes | — | Every other attribute goes to the <div>, with a ref. |
ToolbarInput
<input>| Prop | Type | Default | Description |
|---|---|---|---|
| rounded | "default""full" | — | |
| size | "default""lg""sm""xs" | "sm" | |
| surface | "default""group" | — | |
| class | string | — | |
From Base UIToolbar.InputBase UI docs | |||
| disabled | boolean | false | When true the item is disabled. |
| focusable | boolean | true | When true the item remains focusable when disabled. |
| default | string | number | readonly string[] | — | |
| ...props | <input> attributes | — | Every other attribute goes to the <input>, with a ref. |
ToolbarSeparator
<div>| Prop | Type | Default | Description |
|---|---|---|---|
| class | string | — | |
From Base UIToolbar.SeparatorBase UI docs | |||
| orientation | "horizontal""vertical" | — | The orientation of the separator. Defaults to the opposite of the toolbar's orientation, so a horizontal toolbar renders vertical separators. |
| render | — | Allows you to replace the component's HTML element with a different tag, or compose it with another component. Accepts a ReactElement or a function that returns the element to render. | |
| style | — | Style applied to the element, or a function that returns a style object based on the component's state. | |
| ...props | <div> attributes | — | Every other attribute goes to the <div>, with a ref. |
| Tab | Moves into the bar once, then out of it. |
|---|---|
| Left ArroworRight Arrow | Moves between items. Up and Down do it when vertical. |
| HomeorEnd | Goes to the first or the last item. |
Built with
Installs with Toolbar





