mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-22 15:39:59 +00:00
clip to border-box, update overlay
This commit is contained in:
parent
77639905cb
commit
88b9e558fb
@ -352,7 +352,7 @@ Similar to headers and footers, cards can include top and bottom "image caps"—
|
|||||||
Turn an image into a card background and overlay your card's text. Depending on the image, you may or may not need additional styles or utilities.
|
Turn an image into a card background and overlay your card's text. Depending on the image, you may or may not need additional styles or utilities.
|
||||||
|
|
||||||
{% example html %}
|
{% example html %}
|
||||||
<div class="card text-white">
|
<div class="card bg-dark text-white">
|
||||||
<img class="card-img" data-src="holder.js/100px270/#55595c:#373a3c/text:Card image" alt="Card image">
|
<img class="card-img" data-src="holder.js/100px270/#55595c:#373a3c/text:Card image" alt="Card image">
|
||||||
<div class="card-img-overlay">
|
<div class="card-img-overlay">
|
||||||
<h4 class="card-title">Card title</h4>
|
<h4 class="card-title">Card title</h4>
|
||||||
|
@ -9,6 +9,7 @@
|
|||||||
min-width: 0;
|
min-width: 0;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
background-color: $card-bg;
|
background-color: $card-bg;
|
||||||
|
background-clip: border-box;
|
||||||
border: $card-border-width solid $card-border-color;
|
border: $card-border-width solid $card-border-color;
|
||||||
@include border-radius($card-border-radius);
|
@include border-radius($card-border-radius);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user