1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-08-23 05:33:02 +02:00

Simplify list-group borders in cards (#30808)

This commit is contained in:
Mark Otto
2020-05-14 10:48:46 -07:00
committed by GitHub
parent 46d876314b
commit 12a6576f48
2 changed files with 20 additions and 6 deletions

View File

@@ -33,6 +33,13 @@
@include border-bottom-radius($card-inner-border-radius);
}
}
// Due to specificity of the above selector (`.card > .list-group`), we must
// use a child selector here to prevent double borders.
> .card-header + .list-group,
> .list-group + .card-footer {
border-top: 0;
}
}
.card-body {
@@ -80,12 +87,6 @@
&:first-child {
@include border-radius($card-inner-border-radius $card-inner-border-radius 0 0);
}
+ .list-group {
.list-group-item:first-child {
border-top: 0;
}
}
}
.card-footer {