Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap-rubygem.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'assets/stylesheets/bootstrap/_card.scss')
-rw-r--r--assets/stylesheets/bootstrap/_card.scss47
1 files changed, 13 insertions, 34 deletions
diff --git a/assets/stylesheets/bootstrap/_card.scss b/assets/stylesheets/bootstrap/_card.scss
index 377bec0..c6b67ce 100644
--- a/assets/stylesheets/bootstrap/_card.scss
+++ b/assets/stylesheets/bootstrap/_card.scss
@@ -6,7 +6,7 @@
position: relative;
display: flex;
flex-direction: column;
- min-width: 0;
+ min-width: 0; // See https://github.com/twbs/bootstrap/pull/22740#issuecomment-305868106
word-wrap: break-word;
background-color: $card-bg;
background-clip: border-box;
@@ -36,6 +36,7 @@
// as much space as possible, ensuring footers are aligned to the bottom.
flex: 1 1 auto;
padding: $card-spacer-x;
+ color: $card-color;
}
.card-title {
@@ -195,55 +196,35 @@
// Handle rounded corners
@if $enable-rounded {
- &:first-child {
+ &:not(:last-child) {
@include border-right-radius(0);
.card-img-top,
.card-header {
+ // stylelint-disable-next-line property-blacklist
border-top-right-radius: 0;
}
.card-img-bottom,
.card-footer {
+ // stylelint-disable-next-line property-blacklist
border-bottom-right-radius: 0;
}
}
- &:last-child {
+ &:not(:first-child) {
@include border-left-radius(0);
.card-img-top,
.card-header {
+ // stylelint-disable-next-line property-blacklist
border-top-left-radius: 0;
}
.card-img-bottom,
.card-footer {
+ // stylelint-disable-next-line property-blacklist
border-bottom-left-radius: 0;
}
}
-
- &:only-child {
- @include border-radius($card-border-radius);
-
- .card-img-top,
- .card-header {
- @include border-top-radius($card-border-radius);
- }
- .card-img-bottom,
- .card-footer {
- @include border-bottom-radius($card-border-radius);
- }
- }
-
- &:not(:first-child):not(:last-child):not(:only-child) {
- @include border-radius(0);
-
- .card-img-top,
- .card-img-bottom,
- .card-header,
- .card-footer {
- @include border-radius(0);
- }
- }
}
}
}
@@ -278,29 +259,27 @@
//
.accordion {
- .card {
+ > .card {
overflow: hidden;
&:not(:first-of-type) {
.card-header:first-child {
- border-radius: 0;
+ @include border-radius(0);
}
&:not(:last-of-type) {
border-bottom: 0;
- border-radius: 0;
+ @include border-radius(0);
}
}
&:first-of-type {
border-bottom: 0;
- border-bottom-right-radius: 0;
- border-bottom-left-radius: 0;
+ @include border-bottom-radius(0);
}
&:last-of-type {
- border-top-left-radius: 0;
- border-top-right-radius: 0;
+ @include border-top-radius(0);
}
.card-header {