mirror of
https://github.com/lc-soft/LCUI.git
synced 2026-11-30 16:48:21 +01:00
44 lines
1.2 KiB
TypeScript
44 lines
1.2 KiB
TypeScript
import {
|
|
AlertDialog,
|
|
AlertDialogTrigger,
|
|
AlertDialogOverlay,
|
|
AlertDialogContent,
|
|
AlertDialogHeader,
|
|
AlertDialogMedia,
|
|
AlertDialogTitle,
|
|
AlertDialogDescription,
|
|
AlertDialogFooter,
|
|
AlertDialogCancel,
|
|
AlertDialogAction,
|
|
Icon,
|
|
Portal,
|
|
} from "@lcui/react";
|
|
|
|
export default function Example() {
|
|
return (
|
|
<AlertDialog>
|
|
<AlertDialogTrigger>Delete Chat</AlertDialogTrigger>
|
|
<Portal>
|
|
<AlertDialogOverlay>
|
|
<AlertDialogContent size="sm">
|
|
<AlertDialogHeader>
|
|
<AlertDialogMedia>
|
|
<Icon name="delete" />
|
|
</AlertDialogMedia>
|
|
<AlertDialogTitle>Delete chat?</AlertDialogTitle>
|
|
<AlertDialogDescription>
|
|
This will permanently delete this chat conversation and any
|
|
memories saved during this chat.
|
|
</AlertDialogDescription>
|
|
</AlertDialogHeader>
|
|
<AlertDialogFooter>
|
|
<AlertDialogCancel variant="outline">Cancel</AlertDialogCancel>
|
|
<AlertDialogAction variant="destructive">Delete</AlertDialogAction>
|
|
</AlertDialogFooter>
|
|
</AlertDialogContent>
|
|
</AlertDialogOverlay>
|
|
</Portal>
|
|
</AlertDialog>
|
|
);
|
|
}
|