aidankmcalister

Confirm Button

Buttons

About

A button that requires a click, double-click, press-and-hold, or slide gesture to confirm a destructive or irreversible action, with built-in undo and async pending states.

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

Code

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

Usage.tsx

"use client";

import { ConfirmButton } from "@/components/ui/confirm-button";

export default function ConfirmButtonDemo() {
  return (
    <ConfirmButton
      variant="destructive"
      gesture="click-again"
      onConfirm={() => console.log("Deleted")}
    >
      Delete project
    </ConfirmButton>
  );
}

More by aidankmcalister

View all
  • Confirm Switch

    Confirm Switch

    1
  • Undoable

    Undoable

  • Consequences List

    Consequences List

  • Confirmation Hook

    Confirmation Hook

  • Type to Confirm

    Type to Confirm

More in Buttons

View all
  • Button

    Button

    14
  • Texture Button

    Texture Button

    92
  • Button

    Button

    64
  • Button

    Button

    34
  • Button Save

    Button Save

    46
  • Button

    Button

  • Notification Button

    Notification Button

    103
  • App Store Button

    App Store Button

    453