Installation
CLI
Install the component using the StarUI CLI:
star add alert-dialogExamples
Basic Alert Dialog
Simple alert dialog with dismiss and confirm actions
Destructive Action
Delete confirmation with detailed information
Danger Zone
Irreversible actions
Delete Repository
Once deleted, it will be gone forever
Unsaved Changes
Prompt user about unsaved changes before exiting
Document Editor
Edit your document details
Make changes to the document fields above and try to save.
Session Timeout
Auto-triggered alert with countdown timer
Session Management
Auto-logout demonstration with warning
Batch Operations
Confirm actions on multiple selected items
Batch Operations
Confirm actions on multiple items
items selected
Payment Confirmation
Secure payment confirmation with order details
Complete Purchase
Review your order
Product:
Premium Plan
Price:
$99.00
Tax:
$9.90
Total:
$108.90
API Reference
| Component | Description |
|---|---|
AlertDialog |
Container for alert dialog functionality |
AlertDialogTrigger |
Button or element that opens the dialog |
AlertDialogContent |
Main dialog content container |
AlertDialogHeader |
Header section with title and description |
AlertDialogTitle |
Dialog title text |
AlertDialogDescription |
Dialog description or message |
AlertDialogFooter |
Footer with action buttons |
AlertDialogAction |
Primary action button (e.g., Confirm, Delete) |
AlertDialogCancel |
Cancel/dismiss button |