From 07752bab7b248d9c064b7b85dcaeccccecde8fc7 Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Wed, 7 Sep 2016 20:40:12 -0700 Subject: [PATCH] v4: Card image fixes (#20667) * Add .img-fluid to card images in columns to ensure proper resizing * change that variable from regular value to variable * use calc to figure out a tighter border for card images --- docs/components/card.md | 6 +++--- scss/_card.scss | 2 +- scss/_variables.scss | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/components/card.md b/docs/components/card.md index 992f4a138e..1cf116d869 100644 --- a/docs/components/card.md +++ b/docs/components/card.md @@ -517,7 +517,7 @@ Only applies to small devices and above. {% example html %}
- Card image cap + Card image cap

Card title that wraps to a new line

This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.

@@ -534,7 +534,7 @@ Only applies to small devices and above.
- Card image cap + Card image cap

Card title

This card has supporting text below as a natural lead-in to additional content.

@@ -557,7 +557,7 @@ Only applies to small devices and above.

Last updated 3 mins ago

- Card image + Card image
diff --git a/scss/_card.scss b/scss/_card.scss index 73b3b0e820..1644ae466c 100644 --- a/scss/_card.scss +++ b/scss/_card.scss @@ -168,7 +168,7 @@ // Card image .card-img { // margin: -1.325rem; - @include border-radius(.25rem); + @include border-radius($card-border-radius-inner); } .card-img-overlay { position: absolute; diff --git a/scss/_variables.scss b/scss/_variables.scss index 05c008820d..c8cdbb104d 100644 --- a/scss/_variables.scss +++ b/scss/_variables.scss @@ -581,7 +581,7 @@ $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-border-radius-inner: calc($card-border-radius - 1px) !default; $card-cap-bg: #f5f5f5 !default; $card-bg: #fff !default;