Drawer

A drawer slides in from the edge of the screen to display content.

<Dialog>
  <Button>Open drawer</Button>
  <Drawer>
    <DialogContent>Drawer content</DialogContent>
  </Drawer>
</Dialog>

Installation

pnpm dlx shadcn@latest add @dotui/drawer

Usage

Use drawers to display content that slides in from the edge of the screen.

import { Button } from "@/components/ui/button";
import { Dialog, DialogContent } from "@/components/ui/dialog";
import { Drawer } from "@/components/ui/drawer";
<Dialog>
  <Button>Open Drawer</Button>
  <Drawer placement="bottom">
    <DialogContent>Drawer content</DialogContent>
  </Drawer>
</Dialog>

Playground

Use the controls below to experiment with different drawer props and see the live preview and code update.

placement

API Reference

Missing description.

PropType
union
boolean
boolean
Element
boolean
boolean
((element: Element) => boolean)
ReactNode | function

Last updated on 12/21/2025

dotUI

Bringing singularity to the web.

Built with passion by @mehdibha.