kuratlielia

Split Button

Buttons 5

About

A primary action button paired with a dropdown trigger that reveals a menu of related alternative actions.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Split Button to your project and fits it to your theme.

Code

How Split Button is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import SplitButton from "@/components/ui/split-button";
import { Download, Copy, Trash2 } from "lucide-react";

export default function SplitButtonDemo() {
  return (
    <div className="flex min-h-[200px] w-full items-center justify-center bg-background p-10">
      <SplitButton
        label="Download"
        icon={<Download size={16} strokeWidth={1.8} />}
        actions={[
          { label: "Copy link", icon: <Copy size={15} strokeWidth={1.8} /> },
          { label: "Duplicate" },
          {
            label: "Delete",
            destructive: true,
            icon: <Trash2 size={15} strokeWidth={1.8} />,
          },
        ]}
      />
    </div>
  );
}

Dependencies

More by kuratlielia

View all
  • Activity Heatmap

    Activity Heatmap

    342
  • Image Compare

    Image Compare

    105
  • User Menu

    User Menu

    93
  • Date Range Picker

    Date Range Picker

    62
  • Stats Band

    Stats Band

    52
  • Usage Meter

    Usage Meter

    45
  • Signature Pad

    Signature Pad

    37
  • Timeline

    Timeline

    34

More in Buttons

View all
  • Button

    Button

    14
  • Texture Button

    Texture Button

    92
  • Button

    Button

    34
  • Button Save

    Button Save

    46
  • Button

    Button

    64
  • Button

    Button

  • Notification Button

    Notification Button

    103
  • App Store Button

    App Store Button

    453