Skip to content

Commit 154c89b

Browse files
committed
fix(list): not working correctly when list item is used as a button
Based on our selector for `mat-list-item`, we allow it to be a `button`, however we don't do the necessary resets for it to be usable.
1 parent 5a65a63 commit 154c89b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/material/list/list.scss

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,11 @@ $mat-list-item-inset-divider-offset: 72px;
4444
height: $base-height;
4545
-webkit-tap-highlight-color: transparent;
4646

47-
// Override the user agent styling if the list item is a button.
48-
width: 100%;
47+
// Button resets.
48+
border: none;
49+
background: none;
4950
padding: 0;
51+
width: 100%;
5052

5153
.mat-list-item-content {
5254
display: flex;

0 commit comments

Comments
 (0)