Skip to content

Commit

Permalink
fix(list): prevent list item wrapper elements from collapsing (angula…
Browse files Browse the repository at this point in the history
…r#2075)

Adds a `display: block` to the list items, in order to prevent them from collapsing. This allows users to set a custom background directly on the list item.

Fixes angular#2012.
  • Loading branch information
crisbeto authored and mmalerba committed Dec 7, 2016
1 parent 539e44e commit 27f9c99
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lib/list/list.scss
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ $md-dense-three-line-height: 76px;
@mixin md-list-item-base($font-size, $base-height, $avatar-height,
$two-line-height, $three-line-height) {

// Prevents the wrapper `md-list-item` from collapsing due to it being `inline` by default.
display: block;

.md-list-item {
display: flex;
flex-direction: row;
Expand Down

0 comments on commit 27f9c99

Please sign in to comment.