Dropdown

A menu that 'drops down' when clicked/tapped, showing options to choose from or actions to take.
Class Reference

Basic Dropdowns

Details Tag Dropdown

Native <details> implementation
## Accessibility Considerations We use `div` instead of native `<button>` elements due to a [long-standing Safari bug](https://bugs.webkit.org/show_bug.cgi?id=22261) that prevents proper button focus management. **Why this approach works:** - `tabindex="0"` enables keyboard focus - `role="button"` provides proper ARIA semantics - Works consistently across all modern browsers - Maintains full accessibility compliance This pattern follows WAI-ARIA authoring practices for custom controls while working around browser inconsistencies.

Focus-based Dropdown

CSS focus behavior dropdown

Behaviors

Hover Trigger

Opens on hover

Always Open

Permanently visible dropdown

Positioning

Position: Start

Position: End

Position: Center

Position: Top

Position: Top Center

Position: Top End

Position: Bottom (default)

Position: Bottom (default) End

Position: Left

Position: Left Center

Position: Left End

Position: Right

Position: Right End

Position: Right Center

Advanced Examples

Card Dropdown

Custom dropdown content

Navbar Integration

Dropdown in navigation bar

Helper Card Dropdown

Information tooltip pattern
A normal text and a helper dropdown

Class Reference

Class Type Description
dropdown Component Base dropdown container
dropdown-content Part Dropdown menu container
dropdown-start Placement Aligns dropdown to start of button [Default]
dropdown-center Placement Aligns dropdown to center of button
dropdown-end Placement Aligns dropdown to end of button
dropdown-top Placement Opens above trigger
dropdown-bottom Placement Opens below trigger [Default]
dropdown-left Placement Opens to the left
dropdown-right Placement Opens to the right
dropdown-hover Modifier Opens on hover
dropdown-open Modifier Force open state
Do you have a question? ask the community
Do you see a bug? open an issue on GitHub