codekingpro/portable-devtools
114k
1// Responsive images (ensure images don't scale beyond their parents)2//3// This is purposefully opt-in via an explicit class rather than being the default for all `<img>`s.4// We previously tried the "images are responsive by default" approach in Bootstrap v2,5// and abandoned it in Bootstrap v3 because it breaks lots of third-party widgets (including Google Maps)6// which weren't expecting the images within themselves to be involuntarily resized.7// See also https://github.com/twbs/bootstrap/issues/181788.img-fluid {9 @include img-fluid();10}11 12 13// Image thumbnails14.img-thumbnail {15 padding: $thumbnail-padding;16 background-color: $thumbnail-bg;17 border: $thumbnail-border-width solid $thumbnail-border-color;18 @include border-radius($thumbnail-border-radius);19 @include box-shadow($thumbnail-box-shadow);20 21 // Keep them at most 100% wide22 @include img-fluid();23}24 25//26// Figures27//28 29.figure {30 // Ensures the caption's text aligns with the image.31 display: inline-block;32}33 34.figure-img {35 margin-bottom: $spacer * .5;36 line-height: 1;37}38 39.figure-caption {40 @include font-size($figure-caption-font-size);41 color: $figure-caption-color;42}43 