Split Button
A primary action fused with a chevron trigger that reveals related actions in a spring-timed dropdown, sharing a single pill silhouette.
Installation
Add the component directly to your repository using shadcn CLI:
npx shadcn@latest add Surajmaurya1/easyui/split-button
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| label | string | — | Label for the primary (left) action |
| onClick | () => void | — | Called when the primary action is pressed |
| options | SplitButtonOption[] | — | Dropdown options revealed by the chevron trigger |
| size | 'sm' | 'md' | 'lg' | 'md' | Padding and text size |
| variant | 'primary' | 'secondary' | 'primary' | Visual style of both halves of the control |
| disabled | boolean | false | Disables the entire control |