0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-01-28 20:52:21 +01:00

Merge branch 'bassjobsen-patch-6' into v4-dev

This commit is contained in:
Mark Otto 2015-12-07 23:48:41 -08:00
commit 96dd9c57d2
2 changed files with 60 additions and 28 deletions

View File

@ -93,19 +93,39 @@
// //
.card-primary { .card-primary {
@include card-variant($brand-primary); @include card-variant($brand-primary, $brand-primary);
} }
.card-success { .card-success {
@include card-variant($brand-success); @include card-variant($brand-success, $brand-success);
} }
.card-info { .card-info {
@include card-variant($brand-info); @include card-variant($brand-info, $brand-info);
} }
.card-warning { .card-warning {
@include card-variant($brand-warning); @include card-variant($brand-warning, $brand-warning);
} }
.card-danger { .card-danger {
@include card-variant($brand-danger); @include card-variant($brand-danger, $brand-danger);
}
// Remove all backgrounds
.card-primary-outline {
@include card-outline-variant($btn-primary-bg);
}
.card-secondary-outline {
@include card-outline-variant($btn-secondary-border);
}
.card-info-outline {
@include card-outline-variant($btn-info-bg);
}
.card-success-outline {
@include card-outline-variant($btn-success-bg);
}
.card-warning-outline {
@include card-outline-variant($btn-warning-bg);
}
.card-danger-outline {
@include card-outline-variant($btn-danger-bg);
} }
// //
@ -113,29 +133,9 @@
// //
.card-inverse { .card-inverse {
.card-header, @include card-inverse;
.card-footer {
border-bottom: $card-border-width solid rgba(255,255,255,.2);
}
.card-header,
.card-footer,
.card-title,
.card-blockquote {
color: #fff;
}
.card-link,
.card-text,
.card-blockquote > footer {
color: rgba(255,255,255,.65);
}
.card-link {
@include hover-focus {
color: $card-link-hover-color;
}
}
} }
// //
// Blockquote // Blockquote
// //

View File

@ -1,6 +1,38 @@
// Card variants // Card variants
@mixin card-variant($color) { @mixin card-variant($background, $border) {
background-color: $color; background-color: $background;
border-color: $border;
}
@mixin card-outline-variant($color) {
background-color: transparent;
border-color: $color; border-color: $color;
} }
//
// Inverse text within a card for use with dark backgrounds
//
@mixin card-inverse {
.card-header,
.card-footer {
border-bottom: $card-border-width solid rgba(255,255,255,.2);
}
.card-header,
.card-footer,
.card-title,
.card-blockquote {
color: #fff;
}
.card-link,
.card-text,
.card-blockquote > footer {
color: rgba(255,255,255,.65);
}
.card-link {
@include hover-focus {
color: $card-link-hover-color;
}
}
}