Button Group
A connected group of related buttons that share one size.
Show codeHide code
Installation
import { ButtonGroup, ButtonGroupButton } from "@makeplane/propel/components/button-group";Usage
ButtonGroup is a group-role container that shares its size with every ButtonGroupButton
inside via context. Name the group for assistive tech with aria-label.
import { ButtonGroup, ButtonGroupButton } from "@makeplane/propel/components/button-group";
import { Icon } from "@makeplane/propel/components/icon";
import { ClipboardOutline, CopyOutline, UndoOutline } from "@makeplane/propel/icons";
export default function BasicDemo() {
return (
<ButtonGroup size="sm" aria-label="Editing actions">
<ButtonGroupButton label="Undo" icon={<Icon icon={UndoOutline} />} />
<ButtonGroupButton label="Copy" icon={<Icon icon={CopyOutline} />} />
<ButtonGroupButton label="Paste" icon={<Icon icon={ClipboardOutline} />} />
</ButtonGroup>
);
}Examples
Sizes
The group’s size sizes every segment — a segment’s own size still wins. There is no lg
grouped button.
Show codeHide code
Disabled
A disabled segment is hard-disabled (not focusable) while its siblings stay interactive.
Show codeHide code
API Reference
ButtonGroup
The ready-made connected button group: a group-role container that shares size with every
ButtonGroupButton inside via context (an item's own size still wins). There is no Base UI
button-group primitive — the items are independent Base UI Buttons; the group contributes only
the shared chrome and the group role. Name the group for assistive tech via aria-label.
ButtonGroupButton
The ready-made group segment: grafts Base UI's Button behavior onto the styled
ButtonGroupButton (behavior outer, the styled button as the render target), lays out an
optional icon beside the label (iconPosition), and takes its size from the surrounding
ButtonGroup via context.