Dropdown menu

Split Button

A split button: the plain action on the left in a single click, and a separate arrow zone on the right that opens variants of the same action.

React + Tailwind, shadcn-compatible: press “Copy for AI” and your Cursor or Claude Code agent installs it with the shadcn CLI.

What you can change

  • the main action label through action
  • the variant list through items: label, keys and href on each
  • the button fill through accent — the text colour on it is derived

A link for your AI agent: preview, code and instructions.

Preview

1440pxHost theme
Split Button — A split button: the plain action on the left in a single click, and a separate arrow zone on the right that opens variants of the same action.

Use it with AI

  1. 1. Copy the link.
  2. 2. Write to your agent in your own words and drop the link into the sentence.
  3. 3. The agent opens the link and installs the component from the registry.
AI
1Pick it here

put this on the home page as the hero:

https://vibeui.club/c/dropdown-019?lang=en&theme=dark

2Paste into the chat
3Get it in your project

Not sure where to paste it? Step-by-step guide

Show the full instructions

What the link says, spelled out. Use it when your agent cannot open links — paste this text instead.

Loading…

How to use

<Dropdown019
  action="Save"
  items={[{ label: "Save as…", keys: "Ctrl+Shift+S" }]}
/>

A sample call. The agent installs the component itself from the registry via the “Copy for AI” link.

Settings

Action
action · default: Save
Accent
accent · default: theme colour
Background
background · default: theme colour

FAQ

How do I add Split Button with Cursor or Claude Code?
Press “Copy for AI” on this page and paste it into your agent's chat. The instruction contains the shadcn CLI install command, the dependencies and what to keep, so the agent installs this exact component instead of recreating a lookalike.
What does Split Button depend on?
No npm packages beyond React and Tailwind CSS.
What can I change in Split Button?
Adapt: the main action label through action; the variant list through items: label, keys and href on each; the button fill through accent — the text colour on it is derived. Keep as installed: the local --vibeui-dropdown-019-* palette: the component must look the same in any project; the two separate buttons inside one frame: merging them loses both the focus and the label of the right half; the seam between the halves: without it there is no sign that there are two targets here.
Is Split Button free?
Yes. The preview is open without an account; with a free account you can copy up to 20 components a month.

For developers

npx shadcn@latest add https://vibeui.club/r/pro/dropdown-019.json

This command needs a signed link: sign in and open “Component source” below — it issues a working link valid for 30 minutes. All install options

Technical notes

One file, zero dependencies, the --vibeui-dropdown-019-* palette. A server component: the HTML popover holds the open state and CSS anchor positioning inside @supports places it, so no JS is needed. The two halves sit in one frame but stay two buttons: each has its own focus and its own label, so from the keyboard it is clear where Enter leads. The seam between them is a border-inline-start in currentColor through color-mix. The menu aligns to the right edge (position-area: bottom span-left) because the arrow sits on the right and the list has to fall inside the layout. The halves take their height from content: min-height plus vertical padding, otherwise a long translated label would spill out. The right column carries keyboard shortcuts in tabular-nums.

Tags

  • menu
  • dropdown
  • split-button
  • actions
Component source

The same file your agent installs. Here in case you would rather copy it by hand.

Loading…