DrawerDialogDemo() — ui Function Reference
Architecture documentation for the DrawerDialogDemo() function in drawer-dialog.tsx from the ui codebase.
Entity Profile
Dependency Diagram
graph TD 56675cec_f17b_69c7_0eaf_36dd0d9f709b["DrawerDialogDemo()"] 3ff1eefd_a481_9e9d_e87b_0e3710e11ec5["drawer-dialog.tsx"] 56675cec_f17b_69c7_0eaf_36dd0d9f709b -->|defined in| 3ff1eefd_a481_9e9d_e87b_0e3710e11ec5 style 56675cec_f17b_69c7_0eaf_36dd0d9f709b fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
apps/v4/registry/new-york-v4/examples/drawer-dialog.tsx lines 29–74
export default function DrawerDialogDemo() {
const [open, setOpen] = React.useState(false)
const isDesktop = useMediaQuery("(min-width: 768px)")
if (isDesktop) {
return (
<Dialog open={open} onOpenChange={setOpen}>
<DialogTrigger asChild>
<Button variant="outline">Edit Profile</Button>
</DialogTrigger>
<DialogContent className="sm:max-w-[425px]">
<DialogHeader>
<DialogTitle>Edit profile</DialogTitle>
<DialogDescription>
Make changes to your profile here. Click save when you're
done.
</DialogDescription>
</DialogHeader>
<ProfileForm />
</DialogContent>
</Dialog>
)
}
return (
<Drawer open={open} onOpenChange={setOpen}>
<DrawerTrigger asChild>
<Button variant="outline">Edit Profile</Button>
</DrawerTrigger>
<DrawerContent>
<DrawerHeader className="text-left">
<DrawerTitle>Edit profile</DrawerTitle>
<DrawerDescription>
Make changes to your profile here. Click save when you're done.
</DrawerDescription>
</DrawerHeader>
<ProfileForm className="px-4" />
<DrawerFooter className="pt-2">
<DrawerClose asChild>
<Button variant="outline">Cancel</Button>
</DrawerClose>
</DrawerFooter>
</DrawerContent>
</Drawer>
)
}
Domain
Subdomains
Source
Frequently Asked Questions
What does DrawerDialogDemo() do?
DrawerDialogDemo() is a function in the ui codebase, defined in apps/v4/registry/new-york-v4/examples/drawer-dialog.tsx.
Where is DrawerDialogDemo() defined?
DrawerDialogDemo() is defined in apps/v4/registry/new-york-v4/examples/drawer-dialog.tsx at line 29.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free