About
a beautifully structured Dialog component built using Radix UI primitives with custom styling and slots for full flexibility. It offers smooth animations, a blurred backdrop, responsive sizing, and optional close buttons—making it ideal for modals, alerts, or form popups in any modern React app.
Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Dialog to your project and fits it to your theme.
Code
How Dialog is used: the demo's code. The component's own source comes with a free account.
Usage.tsx
import {
Dialog,
DialogBody,
DialogClose,
DialogContent,
DialogDescription,
DialogFooter,
DialogHeader,
DialogTitle,
DialogTrigger,
} from '@/components/ui/dialog';
import { Button } from '@/components/ui/button';
export default function WithoutCloseButton() {
return (
<Dialog>
<DialogTrigger asChild>
<Button variant="outline">No Close Button Dialog</Button>
</DialogTrigger>
<DialogContent>
<DialogHeader hideCloseButton>
<DialogTitle>No Close Button Dialog</DialogTitle>
<DialogDescription>
This dialog does not show the default close button.
</DialogDescription>
</DialogHeader>
<DialogBody>
<p>This dialog does not show the default close button.</p>
</DialogBody>
<DialogFooter>
<DialogClose asChild>
<Button variant="outline">Close</Button>
</DialogClose>
<Button onClick={() => alert('Do something to close the dialog!')}>
Do Action
</Button>
</DialogFooter>
</DialogContent>
</Dialog>
);
}















