Home Components Dropdown Menu
React Dropdown Menu Components
14 free React dropdown menus built with Tailwind CSS and shadcn/ui conventions. Copy the code or install with the shadcn CLI. Great for action menus, account menus, and nested submenus.
Dropdown Menu 1 : Settings menu with a Dashboard header, icon items for account, notifications and privacy, and a red Logout.Dropdown Menu 2 : Account menu opened from an avatar button, with a shaded header and a short description under each item.Dropdown Menu 3 : Text formatting menu opened from a font icon button, each tool shown in a grey icon tile with a hint.Dropdown Menu 4 : Item actions menu with described Edit, Duplicate and Favorite options and a destructive Delete at the bottom.Dropdown Menu 5 : File menu with New File, Open Project, Downloads and Settings items showing keyboard shortcuts on the right.Dropdown Menu 6 : Inbox menu listing developer messages with avatars, timestamps and unread count badges.Dropdown Menu 7 : Team member menu with online status dots, a remove button per person and an Add Member button.Dropdown Menu 8 : Compact account menu with five icon items and a Logout whose icon slides right on hover.Dropdown Menu 9 : Theme menu with Light, Dark and System radio options, where the System option is disabled.Dropdown Menu 10 : Preferences menu of checkbox items like Auto Save and Code Hints, with Debug Mode disabled.Dropdown Menu 11 : Notification level menu with colour-coded volume icons and the selected level highlighted.Dropdown Menu 12 : Profile menu with an online avatar header and a nested Share Workspace submenu for email or link.Dropdown Menu 13 : Daily schedule menu with coloured time chips, attendee avatars and a switch to toggle each session.Dropdown Menu 14 : Workspace switcher with a recent section, plan and member counts, a check on the current one and create options.
About React Dropdown Menu Components A React dropdown menu is a list of actions or options that opens from a button, like an account menu or a row’s more actions menu. Watermelon UI dropdown menus are built on the Radix UI DropdownMenu primitive with Tailwind CSS, with support for groups, separators, checkbox items, radio items, and submenus. Add one with the shadcn CLI, then fill DropdownMenuContent with your items.
When to use it User account menus in a navbar. More actions menus on table rows and cards. View options like sort order or visible columns. When to use something else Use Select when the user is choosing a form value, not running an action. Use Combobox when the list is long and needs a search box. Use Popover when the floating content is a form or rich content rather than a list of items. Frequently asked questions How do I open a dialog from a dropdown menu item? Keep the dialog’s open state outside the menu and set it in the item’s onSelect. Rendering the Dialog outside DropdownMenuContent stops it from unmounting when the menu closes.
Why does the page freeze after closing a dropdown and a dialog? Both are modal by default, and closing one while the other is mid-transition can leave pointer events blocked on the body. Opening the dialog from controlled state, or setting modal={false} on the DropdownMenu, usually fixes it.
How do I keep the menu open after clicking an item? Call event.preventDefault() in the item’s onSelect. This is common for checkbox items that toggle several options in a row.
How do I align the dropdown to the right edge of the trigger? Pass align="end" to DropdownMenuContent. Use side and sideOffset to change which side it opens on and how far away.
How to use React Dropdown Menu Components Start from a React project with Tailwind CSS and shadcn/ui set up. Next.js, Vite, Remix, and Astro all work. Run npx shadcn@latest add https://registry.watermelon.sh/r/dropdown-menu-1.json to add the source files to your project. Import it where you need it, then edit the Tailwind classes and design tokens to match your product. Dependencies installed with it: react-icons.
The code is yours: it lives in your repository, so there is no runtime package to keep updated. Watermelon UI is free and open source under the MIT license.
More: Free React components , UI library alternatives , guides .