DrawerDialogDemo() — ui Function Reference
Architecture documentation for the DrawerDialogDemo() function in drawer-dialog.tsx from the ui codebase.
Entity Profile
Dependency Diagram
graph TD 46768b6c_6702_fbde_163b_79c9a92a0a33["DrawerDialogDemo()"] d985c2ec_fc62_9820_0684_efd00d7df8c3["drawer-dialog.tsx"] 46768b6c_6702_fbde_163b_79c9a92a0a33 -->|defined in| d985c2ec_fc62_9820_0684_efd00d7df8c3 style 46768b6c_6702_fbde_163b_79c9a92a0a33 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
deprecated/www/registry/new-york/examples/drawer-dialog.tsx lines 27–71
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 deprecated/www/registry/new-york/examples/drawer-dialog.tsx.
Where is DrawerDialogDemo() defined?
DrawerDialogDemo() is defined in deprecated/www/registry/new-york/examples/drawer-dialog.tsx at line 27.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free