Skip to content

Commit 1bf5c41

Browse files
crisbetotinayuangao
authored andcommitted
fix(expansion-panel): inconsistent margin for nested panels (#11305)
Fixes some inconsistent margin when expansion panels are nested inside other expansion panels. Fixes #11254.
1 parent dd44e06 commit 1bf5c41

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/lib/expansion/expansion-panel.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,12 @@
2626
margin: 16px 0;
2727

2828
.mat-accordion > &:first-child,
29-
.mat-accordion > *:first-child & {
29+
.mat-accordion > *:first-child:not(.mat-expansion-panel) & {
3030
margin-top: 0;
3131
}
3232

3333
.mat-accordion > &:last-child,
34-
.mat-accordion > *:last-child & {
34+
.mat-accordion > *:last-child:not(.mat-expansion-panel) & {
3535
margin-bottom: 0;
3636
}
3737
}

0 commit comments

Comments
 (0)