2016-01-26 21:12:48 +03:00
---
layout: docs
title: Menus
group: material-design
---
Bootstrap users know these as [dropdowns ]({{ site.baseurl }}/components/dropdowns/ ), but these are also known as menus in the [Material Design specification ](https://www.google.com/design/spec/components/menus.html#menus-specs ).
## Contents
* Will be replaced with the ToC, excluding the "Contents" header
{:toc}
## Styles
2016-03-28 21:30:21 +03:00
### Icon with buttons
2016-01-26 21:12:48 +03:00
{% example html %}
< div class = "dropdown" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "ex1" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2016-03-28 22:46:33 +03:00
< div class = "dropdown-menu dropdown-menu-left" aria-labelledby = "ex1" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > Action< / button >
< button class = "dropdown-item disabled" type = "button" > Another action< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< / div >
< / div >
2016-03-28 21:30:21 +03:00
{% endexample %}
2016-01-26 21:12:48 +03:00
2016-03-28 21:30:21 +03:00
### Icon with links
{% example html %}
2016-03-28 22:46:33 +03:00
< div class = "btn-group" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "ex2" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
2016-03-28 21:30:21 +03:00
< / button >
2016-03-28 22:46:33 +03:00
< div class = "dropdown-menu dropdown-menu-left" aria-labelledby = "ex2" >
2016-08-02 20:44:50 +03:00
< a class = "dropdown-item" href = "#" > Regular link< / a >
< a class = "dropdown-item disabled" href = "#" > Disabled link< / a >
< a class = "dropdown-item" href = "#" > Another link< / a >
2016-01-26 21:12:48 +03:00
< / div >
< / div >
2016-03-28 21:30:21 +03:00
{% endexample %}
2016-01-26 21:12:48 +03:00
2016-03-28 21:30:21 +03:00
### Small fab
{% example html %}
2016-03-28 22:46:33 +03:00
< div class = "btn-group" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-fab bmd-btn-fab-sm dropdown-toggle" type = "button" id = "ex3" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2016-03-28 22:46:33 +03:00
< div class = "dropdown-menu dropdown-menu-left" aria-labelledby = "ex3" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > Action< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< / div >
< / div >
2016-03-28 21:30:21 +03:00
{% endexample %}
2016-01-26 21:12:48 +03:00
2016-03-28 21:30:21 +03:00
### Default fab
{% example html %}
2016-03-28 22:46:33 +03:00
< div class = "btn-group" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-fab dropdown-toggle" type = "button" id = "ex4" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2016-03-28 22:46:33 +03:00
< div class = "dropdown-menu dropdown-menu-left" aria-labelledby = "ex4" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > Action< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< / div >
< / div >
2016-03-28 21:30:21 +03:00
{% endexample %}
### Default button
{% example html %}
2017-12-11 14:28:54 +03:00
< div class = "btn-group" >
2016-01-26 21:12:48 +03:00
< button class = "btn dropdown-toggle" type = "button" id = "buttonMenu1" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
Dropdown
< / button >
< div class = "dropdown-menu" aria-labelledby = "buttonMenu1" >
2016-08-02 20:44:50 +03:00
< a class = "dropdown-item" href = "#" > Action< / a >
< a class = "dropdown-item" href = "#" > Another action< / a >
< a class = "dropdown-item" href = "#" > Something else here< / a >
2016-01-26 21:12:48 +03:00
< / div >
< / div >
{% endexample %}
## Alignment
### Lower left side
{% example html %}
2017-12-11 14:28:54 +03:00
< div class = "btn-group" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "ll1" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2016-03-28 22:46:33 +03:00
< div class = "dropdown-menu dropdown-menu-left" aria-labelledby = "ll1" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > Action< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< button class = "dropdown-item disabled" type = "button" > Disabled action< / button >
< div class = "dropdown-divider" > < / div >
2016-08-02 20:44:50 +03:00
< a class = "dropdown-item" href = "#" > Separated link< / a >
2016-01-26 21:12:48 +03:00
< / div >
< / div >
{% endexample %}
### Lower right side
2016-03-28 22:46:33 +03:00
2016-01-26 21:12:48 +03:00
{% example html %}
2017-12-11 14:28:54 +03:00
< div class = "dropdown pull-xs-right" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "lr1" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
< div class = "dropdown-menu dropdown-menu-right" aria-labelledby = "lr1" >
< button class = "dropdown-item" type = "button" > Action< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< button class = "dropdown-item disabled" type = "button" > Disabled action< / button >
< div class = "dropdown-divider" > < / div >
2016-08-02 20:44:50 +03:00
< a class = "dropdown-item" href = "#" > Separated link< / a >
2016-01-26 21:12:48 +03:00
< / div >
< / div >
{% endexample %}
## Widths
### Minimum width
{% example html %}
2017-12-11 14:28:54 +03:00
< div class = "btn-group pull-xs-right" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "mw1" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2017-12-11 14:28:54 +03:00
< div class = "dropdown-menu" aria-labelledby = "mw1" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > A< / button >
< button class = "dropdown-item" type = "button" > B< / button >
< / div >
< / div >
{% endexample %}
### Maximum width
{% example html %}
2017-12-11 14:28:54 +03:00
< div class = "btn-group pull-xs-right" >
2016-03-21 17:56:51 +03:00
< button class = "btn bmd-btn-icon dropdown-toggle" type = "button" id = "mw2" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2016-01-26 21:12:48 +03:00
< i class = "material-icons" > more_vert< / i >
< / button >
2017-12-11 14:28:54 +03:00
< div class = "dropdown-menu" aria-labelledby = "mw2" >
2016-01-26 21:12:48 +03:00
< button class = "dropdown-item" type = "button" > Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ut malesuada elit. Proin tristique, lorem eu vehicula congue, lectus ipsum porta quam, eget rutrum sapien turpis et libero.Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ut malesuada elit. Proin tristique, lorem eu vehicula congue, lectus ipsum porta quam, eget rutrum sapien turpis et libero.Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ut malesuada elit. Proin tristique, lorem eu vehicula congue, lectus ipsum porta quam, eget rutrum sapien turpis et libero.< / button >
< button class = "dropdown-item" type = "button" > Another action< / button >
< / div >
< / div >
{% endexample %}