导航栏

移动端抽屉菜单

Mobile drawer menu

汉堡按钮滑出全高面板

实时预览

提示词正文

Build a mobile drawer menu with Tailwind CSS: a hamburger button that slides a full-height panel in from the right over a dimmed backdrop, holding the nav links as large tap targets, collapsible sub-sections, and the account actions at the bottom. Trap focus inside the drawer while open, close on backdrop click or Escape, and animate with a transform transition. Lock body scroll while the drawer is open.

提示词保持英文原文——直接粘贴进 Claude、Cursor、v0 或任何 AI 编程工具即可使用。

怎么用

抽屉三件套:焦点锁定、body 滚动锁定、Esc/点遮罩关闭;菜单项点击区域≥44px。

同类提示词 · 导航栏

© 2026 Genisource Vibe · 提示词详情