11// TODO(kara): update vars for desktop when MD team responds
22// TODO(kara): animation for menu opening
3- @import ' ../core/style/variables' ;
4- @import ' ../core/style/elevation' ;
3+
54@import ' ../core/style/button-common' ;
65@import ' ../core/style/sidenav-common' ;
7- @import ' ../core/style/list-common' ;
8-
9-
10- // menu width must be a multiple of 56px
11- $md-menu-overlay-min-width : 112px !default ; // 56 * 2
12- $md-menu-overlay-max-width : 280px !default ; // 56 * 5
13-
14- $md-menu-item-height : 48px !default ;
15- $md-menu-font-size : 16px !default ;
16- $md-menu-side-padding : 16px !default ;
17- $md-menu-vertical-padding : 8px !default ;
6+ @import ' ../core/style/menu-common' ;
187
198.md-menu-panel {
20- @include md-elevation (2 );
21- min-width : $md-menu-overlay-min-width ;
22- max-width : $md-menu-overlay-max-width ;
9+ @include md-menu-base ();
2310
2411 // max height must be 100% of the viewport height + one row height
2512 max-height : calc (100vh + 48px );
26- overflow : auto ;
27- -webkit-overflow-scrolling : touch ; // for momentum scroll on mobile
28-
29- padding-top : $md-menu-vertical-padding ;
30- padding-bottom : $md-menu-vertical-padding ;
3113}
3214
3315[md-menu-item ] {
3416 @include md-button-reset ();
35- @include md-truncate-line ();
36-
37- display : flex ;
38- flex-direction : row ;
39- align-items : center ;
40- height : $md-menu-item-height ;
41- padding : 0 $md-menu-side-padding ;
42-
43- font-size : $md-menu-font-size ;
44- font-family : $md-font-family ;
45- text-align : start ;
46- text-decoration : none ; // necessary to reset anchor tags
47-
48- & [disabled ] {
49- cursor : default ;
50- }
17+ @include md-menu-item-base ();
5118}
5219
5320button [md-menu-item ] {
5421 width : 100% ;
55- }
22+ }
0 commit comments