Dropdowns

Examples

Toggle contextual overlays for displaying lists of links and more with the Bootstrap dropdown plugin.

Single button dropdowns

Any single .btncan be turned into a dropdown toggle with some markup changes. Here’s how you can put them to work with either <button>elements:

Variant

The best part is you can do this with any button variant,too:

Dropright variation

Trigger dropdown menus at the right of the elements by adding .droprightto the parent element.

Dropup variation

Trigger dropdown menus above elements by adding .dropupto the parent element.

Active Item

Add .activeto item in the dropdown to style them as active.

Headers

Add a header to label sections of actions in any dropdown menu.

Forms

Put a form within a dropdown menu,or make it into a dropdown menu,and use margin or padding utilities to give it the negative space you require.

Split button dropdowns

Similarly,create split button dropdowns with virtually the same markup as single button dropdowns,but with the addition of .dropdown-toggle-splitfor proper spacing around the dropdown caret.

Sizing

Button dropdowns work with buttons of all sizes,including default and split dropdown buttons.

Dropleft variation

Trigger dropdown menus at the right of the elements by adding .dropleftto the parent element.

Menu alignment

Add .dropdown-menu-rightto a .dropdown-menuto right align the dropdown menu.

Disabled Item

Add .disabledto items in the dropdown to style them as disabled.

Text

Place any freeform text within a dropdown menu with text and use spacing utilities. Note that you’ll likely need additional sizing styles to constrain the menu width.