Skip to content

Commit a3da8d2

Browse files
authored
Revert "fix(menu): allow text wrapping in menu items" (#14493)
* Revert "build: update nodejs bazel rules (#14466)" This reverts commit a3fef46. * Revert "docs(form-field): native select reset values not working in examples (#14236)" This reverts commit 97f52c0. * Revert "fix(menu): allow text wrapping in menu items (#11430)" This reverts commit 3661abe.
1 parent a3fef46 commit a3da8d2

File tree

4 files changed

+3
-15
lines changed

4 files changed

+3
-15
lines changed

src/dev-app/menu/menu-demo.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,13 @@ export class MenuDemo {
1919
selected = '';
2020
items = [
2121
{text: 'Refresh'},
22-
{text: 'Settings with a longer name so we can test text wrapping'},
22+
{text: 'Settings'},
2323
{text: 'Help', disabled: true},
2424
{text: 'Sign Out'}
2525
];
2626

2727
iconItems = [
28-
{text: 'Redial with a longer name so we can test text wrapping', icon: 'dialpad'},
28+
{text: 'Redial', icon: 'dialpad'},
2929
{text: 'Check voicemail', icon: 'voicemail', disabled: true},
3030
{text: 'Disable alerts', icon: 'notifications_off'}
3131
];

src/lib/core/option/option.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
display: flex;
1212
flex-direction: row;
1313
max-width: 100%;
14+
box-sizing: border-box;
1415
align-items: center;
1516
-webkit-tap-highlight-color: transparent;
1617

src/lib/core/style/_menu-common.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ $mat-menu-icon-margin: 16px !default;
2828
line-height: $mat-menu-item-height;
2929
height: $mat-menu-item-height;
3030
padding: 0 $mat-menu-side-padding;
31-
box-sizing: border-box;
3231

3332
text-align: left;
3433
text-decoration: none; // necessary to reset anchor tags

src/lib/menu/menu.scss

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
@import '../../cdk/a11y/a11y';
66

77
$mat-menu-vertical-padding: 8px !default;
8-
$mat-menu-item-vertical-padding: 8px !default;
98
$mat-menu-border-radius: 4px !default;
109
$mat-menu-submenu-indicator-size: 10px !default;
1110

@@ -31,17 +30,6 @@ $mat-menu-submenu-indicator-size: 10px !default;
3130
@include mat-menu-item-base();
3231
position: relative;
3332

34-
// TODO(crisbeto): most of these can be moved into the `mat-menu-item-base`
35-
// once we start allowing text wrapping in mat-select and mat-autocomplete.
36-
display: flex;
37-
align-items: center;
38-
white-space: normal;
39-
line-height: normal;
40-
height: auto;
41-
min-height: $mat-menu-item-height;
42-
padding-top: $mat-menu-item-vertical-padding;
43-
padding-bottom: $mat-menu-item-vertical-padding;
44-
4533
@include cdk-high-contrast {
4634
&.cdk-program-focused,
4735
&.cdk-keyboard-focused,

0 commit comments

Comments
 (0)