Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add card-specific color variables #19792

Closed
tordans opened this issue Apr 24, 2016 · 2 comments
Closed

Add card-specific color variables #19792

tordans opened this issue Apr 24, 2016 · 2 comments

Comments

@tordans
Copy link
Contributor

tordans commented Apr 24, 2016

There should be an easy way to customize the color of the .card background.

Right now the colors are hard coded inside

bootstrap/scss/_card.scss

Lines 123 to 141 in 1a6d0cc

//
// Background variations
//
.card-primary {
@include card-variant($brand-primary, $brand-primary);
}
.card-success {
@include card-variant($brand-success, $brand-success);
}
.card-info {
@include card-variant($brand-info, $brand-info);
}
.card-warning {
@include card-variant($brand-warning, $brand-warning);
}
.card-danger {
@include card-variant($brand-danger, $brand-danger);
}

Instead there should be a default similar to this:

// Cards
$card-spacer-x:            1.25rem !default;
$card-spacer-y:            .75rem !default;
$card-border-width:        1px !default;
$card-border-radius:       $border-radius !default;
$card-border-color:        rgba(0,0,0,.125) !default;
$card-border-radius-inner: $card-border-radius !default;
$card-cap-bg:              #f5f5f5 !default;
$card-bg:                  #fff !default;
$card-primary-bg:          $brand-primary !default;
$card-success-bg:          $brand-success !default;
$card-info-bg:             $brand-info !default;
$card-warning-bg:          $brand-warning !default;
$card-danger-bg:           $brand-danger !default;

$card-link-hover-color:    #fff !default;
@cvrebert cvrebert changed the title v4: Add variables to change color of semantic Add card-specific color variables Apr 24, 2016
@tordans
Copy link
Contributor Author

tordans commented Apr 24, 2016

@cvrebert I can create a PR if you think this should be done.

@mdo mdo mentioned this issue May 1, 2017
4 tasks
@mdo mdo mentioned this issue Jun 28, 2017
5 tasks
@mdo
Copy link
Member

mdo commented Jun 30, 2017

Not happening with #22836—going to a Sass map based approach to generate these classes.

@mdo mdo closed this as completed Jun 30, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants