reopt design
DocsExploreTemplatesCanvasToolsPricing
Login
opt-uiopt-chartsopt-datagridopt-editoropt-calendaropt-filemanageropt-chatopt-shellbrandapp-ui
Overview205Core74Shells99Blocks32
Drawer
reopt designreopt design

A design system for the AI era

  • Docs
  • Pricing
  • Releases
  • About
  • Contact
  • Terms of Service
  • Privacy Policy

reopt Inc.Business registration no. 217-88-02453contact@reopt.ai

© 2026 reopt Inc. All rights reserved.

Drawer

Component

Open accessible side or bottom sliding panels with a Dialog-based compound API.

overlay
Related docs
bun add @reopt-ai/opt-ui
Install and import
bash
bun add @reopt-ai/opt-ui
tsx
import { DrawerRoot, DrawerPanel, DrawerClose } from "@reopt-ai/opt-ui";

Live preview

Change the width and theme, then interact with the components.

100%

기본 사용

DrawerRoot

PropTypeDefaultDescription
openboolean—제어 모드 열림 상태
onClose() => void—닫힘 콜백

DrawerPanel

PropTypeDefaultDescription
side"left" | "right" | "bottom""right"슬라이드 방향
size"sm" | "md" | "lg" | "full""md"패널 크기
swipeToDismissbooleantrue가장자리 방향으로 드래그해 닫기 활성화
swipeDismissThresholdnumber80닫힘 커밋에 필요한 드래그 거리(px)
View test results

테스트 커버리지

2026년 7월 9일5/5 통과
5성공
0실패
5전체
  • open=true일 때 드로어 패널이 렌더링된다
  • side prop에 따라 방향이 결정된다
  • 임계값을 넘겨 스와이프하면 드로어가 닫힌다
  • 임계값 미만 스와이프는 닫지 않는다
  • swipeToDismiss=false면 스와이프해도 닫히지 않는다

키보드 동작

키동작
Esc드로어 닫기
Tab드로어 내부 포커스 이동

Related components

opt-ui

Disclosure

Core

Expand and collapse content with Root, Trigger, and Content components.

opt-ui

Dialog

Core

Compose accessible modal dialogs with triggers, headings, descriptions, dismissal controls, and header, body, and footer regions.

opt-ui

Popover

Core

Show floating content anchored to a trigger using the Popover primitive.

opt-ui

Menu

Core

Compose menu bars and individual menus with checkbox items, radio items, separators, and popovers.

opt-ui

DropdownMenu

Core

Create a single-trigger dropdown with a convenient wrapper around Menu Core.

opt-ui

FieldToken

Core

Display field types with consistent glyphs and optional labels for strings, numbers, dates, IP addresses, and geographic data.

PreviousLogoNextPagination