new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

shadcn/ui · Components · all subjects

dialog/usage

5 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Dialog basic usage example

Basic Dialog example: ```tsx import { Button } from "@/components/ui/button" import { Dialog, DialogDescription, DialogHeader, DialogTitle, DialogTrigger, } from "@/components/ui/dialog" <DialogTrigger> <Button>Open</Button> <Dialog> <DialogHeader> <DialogTitle>Are you absolutely sure?</DialogTitle> <DialogDescription> This action cannot be undone. This will permanently delete your account and remove your data from our servers. </DialogDescription> </DialogHeader> </Dialog> </DialogTrigger> ```

Dialog component imports

The Dialog component exports the following: Dialog, DialogContent, DialogDescription, DialogHeader, DialogTitle, and DialogTrigger. These are imported from @/components/ui/dialog

Dialog basic usage example

Example showing a Dialog with a trigger button and content with header, title, and description: ```tsx <Dialog> <DialogTrigger>Open</DialogTrigger> <DialogContent> <DialogHeader> <DialogTitle>Are you absolutely sure?</DialogTitle> <DialogDescription> This action cannot be undone. This will permanently delete your account and remove your data from our servers. </DialogDescription> </DialogHeader> </DialogContent> </Dialog> ```

Dialog import statement

Import dialog components from @/components/ui/dialog. The components to import are: Dialog, DialogContent, DialogDescription, DialogHeader, DialogTitle, and DialogTrigger.

Dialog basic usage example

Basic dialog structure: wrap DialogTrigger and DialogContent inside a Dialog component. DialogContent contains DialogHeader with DialogTitle and DialogDescription. Example code: <Dialog> <DialogTrigger>Open</DialogTrigger> <DialogContent> <DialogHeader> <DialogTitle>Are you absolutely sure?</DialogTitle> <DialogDescription> This action cannot be undone. This will permanently delete your account and remove your data from our servers. </DialogDescription> </DialogHeader> </DialogContent> </Dialog>

Give your agent this brain