mirror of
https://github.com/twbs/bootstrap.git
synced 2025-01-30 22:52:24 +01:00
Add support for customising a card title color (#36979)
* Add support for customising a card title color * Group `*card-title-*` variables together * Add support for customising a card subtitle color Co-authored-by: Julien Déramond <julien.deramond@orange.com> Co-authored-by: Mark Otto <markd.otto@gmail.com>
This commit is contained in:
parent
eed6b4a175
commit
cda47731c6
@ -7,6 +7,8 @@
|
||||
--#{$prefix}card-spacer-y: #{$card-spacer-y};
|
||||
--#{$prefix}card-spacer-x: #{$card-spacer-x};
|
||||
--#{$prefix}card-title-spacer-y: #{$card-title-spacer-y};
|
||||
--#{$prefix}card-title-color: #{$card-title-color};
|
||||
--#{$prefix}card-subtitle-color: #{$card-subtitle-color};
|
||||
--#{$prefix}card-border-width: #{$card-border-width};
|
||||
--#{$prefix}card-border-color: #{$card-border-color};
|
||||
--#{$prefix}card-border-radius: #{$card-border-radius};
|
||||
@ -73,11 +75,13 @@
|
||||
|
||||
.card-title {
|
||||
margin-bottom: var(--#{$prefix}card-title-spacer-y);
|
||||
color: var(--#{$prefix}card-title-color);
|
||||
}
|
||||
|
||||
.card-subtitle {
|
||||
margin-top: calc(-.5 * var(--#{$prefix}card-title-spacer-y)); // stylelint-disable-line function-disallowed-list
|
||||
margin-bottom: 0;
|
||||
color: var(--#{$prefix}card-subtitle-color);
|
||||
}
|
||||
|
||||
.card-text:last-child {
|
||||
|
@ -1247,6 +1247,8 @@ $placeholder-opacity-min: .2 !default;
|
||||
$card-spacer-y: $spacer !default;
|
||||
$card-spacer-x: $spacer !default;
|
||||
$card-title-spacer-y: $spacer * .5 !default;
|
||||
$card-title-color: null !default;
|
||||
$card-subtitle-color: null !default;
|
||||
$card-border-width: var(--#{$prefix}border-width) !default;
|
||||
$card-border-color: var(--#{$prefix}border-color-translucent) !default;
|
||||
$card-border-radius: $border-radius !default;
|
||||
|
Loading…
x
Reference in New Issue
Block a user