From cb02466ccae0c3e45e2b665117102b387e997b24 Mon Sep 17 00:00:00 2001 From: Kara Erickson Date: Thu, 11 May 2017 12:42:03 -0700 Subject: [PATCH] fix(list): fix padding for list items --- src/lib/list/list.scss | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/lib/list/list.scss b/src/lib/list/list.scss index 6c33ef3b1f16..e4d14fc077c6 100644 --- a/src/lib/list/list.scss +++ b/src/lib/list/list.scss @@ -80,7 +80,11 @@ $mat-dense-list-icon-size: 20px; @include mat-line-wrapper-base(); padding: 0 $mat-list-side-padding; - &:first-child { + // We only want to override the padding if there isn't + // an avatar or icon before the element. Since the ripple + // will always be the first child in the container, we + // check whether this element is the second child. + &:nth-child(2) { padding: 0; } }