Hero Ui

HeroUI AlertDialog

Buttons 80

About

HeroUI AlertDialog for critical confirmations, with status icons, placements, backdrop variants, sizes, custom icons, dismiss behavior, controlled state and custom trigger examples. Uses the real @heroui/react component with bundled @heroui/styles CSS.

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

Code

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

Usage.tsx

"use client"

import { AlertDialog } from "@/components/ui/heroui-alert-dialog"
import { Button } from "@heroui/react"

export default function Default() {
  return (
    <AlertDialog>
      <Button variant="danger">Delete Project</Button>
      <AlertDialog.Backdrop>
        <AlertDialog.Container>
          <AlertDialog.Dialog className="sm:max-w-[400px]">
            <AlertDialog.CloseTrigger />
            <AlertDialog.Header>
              <AlertDialog.Icon status="danger" />
              <AlertDialog.Heading>Delete project permanently?</AlertDialog.Heading>
            </AlertDialog.Header>
            <AlertDialog.Body>
              <p>
                This will permanently delete <strong>My Awesome Project</strong> and all of its
                data. This action cannot be undone.
              </p>
            </AlertDialog.Body>
            <AlertDialog.Footer>
              <Button slot="close" variant="tertiary">Cancel</Button>
              <Button slot="close" variant="danger">Delete Project</Button>
            </AlertDialog.Footer>
          </AlertDialog.Dialog>
        </AlertDialog.Container>
      </AlertDialog.Backdrop>
    </AlertDialog>
  )
}

Dependencies

More by Hero Ui

View all
  • DatePicker

    DatePicker

    465
  • Chip

    Chip

    441
  •  The Pagination

    The Pagination

    361
  • HeroUI Color Picker

    HeroUI Color Picker

    106
  • Skeleton

    Skeleton

    105
  • HeroUI Table

    HeroUI Table

    102
  • HeroUI Disclosure Group

    HeroUI Disclosure Group

    94
  • ComboBox

    ComboBox

    75

More in Buttons

View all
  • Texture Button

    Texture Button

    93
  • Eclipse Button

    Eclipse Button

    5
  • App Store Button

    App Store Button

    457
  • Button Group

    Button Group

  • Button

    Button

    32
  • Button

    Button

    14
  • Button

    Button

    65
  • HeroUI Button Group

    HeroUI Button Group

    9