diff --git a/src/styles/libs/bootstrap/CHANGELOG.md b/src/styles/libs/bootstrap/CHANGELOG.md index 8f1cfe47..c667c834 100644 --- a/src/styles/libs/bootstrap/CHANGELOG.md +++ b/src/styles/libs/bootstrap/CHANGELOG.md @@ -1,5 +1,16 @@ # Changelog +## 3.2.0.0 + +- Assets (Sass, JS, fonts) moved from `vendor/assets` to `assets`. `bootstrap.js` now contains concatenated JS. +- Compass generator now copies JS and fonts, and provides a better default `styles.sass`. +- Compass, Sprockets, and Mincer asset path helpers are now provided in pure Sass: `bootstrap-compass`, `bootstrap-sprockets`, and `bootstrap-mincer`. +Asset path helpers must be imported before `bootstrap`, more in Readme. +- Sprockets / Mincer JS manifest has been moved to `bootstrap-mincer.js`. +It can be required without adding Bootstrap JS directory to load path, as it now uses relative paths. +- Sprockets: `depend_on_asset` (`glyphicons.scss`) has been changed to `depend_on` to work around an issue with `depend_on_asset`. +[More information](https://github.com/twbs/bootstrap-sass/issues/592#issuecomment-46570286). + ## 3.1.1.0 - Updated Bower docs diff --git a/src/styles/libs/bootstrap/README.md b/src/styles/libs/bootstrap/README.md index db7cffdc..9d8d673e 100644 --- a/src/styles/libs/bootstrap/README.md +++ b/src/styles/libs/bootstrap/README.md @@ -1,4 +1,7 @@ # Bootstrap sass distribution -Downloaded from [link](https://github.com/twbs/bootstrap-sass/archive/v3.1.1.tar.gz). -Used data from `vendor/assets/stylesheets` folder. +Downloaded from [link](https://github.com/twbs/bootstrap-sass/archive/v3.2.0.tar.gz). +Used data from `vendor/assets/stylesheets` folder except: ++ `_bootstrap-compass.scss` ++ `_bootstrap-mincer.scss` ++ `_bootstrap-sprockets.scss` diff --git a/src/styles/libs/bootstrap/bootstrap.scss b/src/styles/libs/bootstrap/bootstrap.scss index ece2a0ca..65204aad 100644 --- a/src/styles/libs/bootstrap/bootstrap.scss +++ b/src/styles/libs/bootstrap/bootstrap.scss @@ -2,9 +2,10 @@ @import "bootstrap/variables"; @import "bootstrap/mixins"; -// Reset +// Reset and dependencies @import "bootstrap/normalize"; @import "bootstrap/print"; +@import "bootstrap/glyphicons"; // Core CSS @import "bootstrap/scaffolding"; @@ -17,7 +18,6 @@ // Components @import "bootstrap/component-animations"; -@import "bootstrap/glyphicons"; @import "bootstrap/dropdowns"; @import "bootstrap/button-groups"; @import "bootstrap/input-groups"; @@ -35,6 +35,7 @@ @import "bootstrap/media"; @import "bootstrap/list-group"; @import "bootstrap/panels"; +@import "bootstrap/responsive-embed"; @import "bootstrap/wells"; @import "bootstrap/close"; diff --git a/src/styles/libs/bootstrap/bootstrap/_alerts.scss b/src/styles/libs/bootstrap/bootstrap/_alerts.scss index 4685ac3a..e45de830 100644 --- a/src/styles/libs/bootstrap/bootstrap/_alerts.scss +++ b/src/styles/libs/bootstrap/bootstrap/_alerts.scss @@ -33,12 +33,13 @@ } } -// Dismissable alerts +// Dismissible alerts // // Expand the right padding and account for the close button's positioning. -.alert-dismissable { - padding-right: ($alert-padding + 20); +.alert-dismissable, // The misspelled .alert-dismissable was deprecated in 3.2.0. +.alert-dismissible { + padding-right: ($alert-padding + 20); // Adjust close link position .close { diff --git a/src/styles/libs/bootstrap/bootstrap/_badges.scss b/src/styles/libs/bootstrap/bootstrap/_badges.scss index 4014a80b..02394ae7 100644 --- a/src/styles/libs/bootstrap/bootstrap/_badges.scss +++ b/src/styles/libs/bootstrap/bootstrap/_badges.scss @@ -3,7 +3,7 @@ // -------------------------------------------------- -// Base classes +// Base class .badge { display: inline-block; min-width: 10px; @@ -32,6 +32,18 @@ top: 0; padding: 1px 5px; } + + // [converter] extracted a& to a.badge + + // Account for badges in navs + a.list-group-item.active > &, + .nav-pills > .active > a > & { + color: $badge-active-color; + background-color: $badge-active-bg; + } + .nav-pills > li > a > & { + margin-left: 3px; + } } // Hover state, but only for links @@ -43,13 +55,3 @@ a.badge { cursor: pointer; } } - -// Account for counters in navs -a.list-group-item.active > .badge, -.nav-pills > .active > a > .badge { - color: $badge-active-color; - background-color: $badge-active-bg; -} -.nav-pills > li > a > .badge { - margin-left: 3px; -} diff --git a/src/styles/libs/bootstrap/bootstrap/_button-groups.scss b/src/styles/libs/bootstrap/bootstrap/_button-groups.scss index 066b4d77..63ccd927 100644 --- a/src/styles/libs/bootstrap/bootstrap/_button-groups.scss +++ b/src/styles/libs/bootstrap/bootstrap/_button-groups.scss @@ -20,7 +20,7 @@ } &:focus { // Remove focus outline when dropdown JS adds it after closing the menu - outline: none; + outline: 0; } } } @@ -216,11 +216,25 @@ > .btn-group .btn { width: 100%; } + + > .btn-group .dropdown-menu { + left: auto; + } } // Checkbox and radio options +// +// In order to support the browser's form validation feedback, powered by the +// `required` attribute, we have to "hide" the inputs via `opacity`. We cannot +// use `display: none;` or `visibility: hidden;` as that also hides the popover. +// This way, we ensure a DOM element is visible to position the popover from. +// +// See https://github.com/twbs/bootstrap/pull/12794 for more. + [data-toggle="buttons"] > .btn > input[type="radio"], [data-toggle="buttons"] > .btn > input[type="checkbox"] { - display: none; + position: absolute; + z-index: -1; + @include opacity(0); } diff --git a/src/styles/libs/bootstrap/bootstrap/_buttons.scss b/src/styles/libs/bootstrap/bootstrap/_buttons.scss index 28110b65..dae6ee37 100644 --- a/src/styles/libs/bootstrap/bootstrap/_buttons.scss +++ b/src/styles/libs/bootstrap/bootstrap/_buttons.scss @@ -140,8 +140,6 @@ .btn-block { display: block; width: 100%; - padding-left: 0; - padding-right: 0; } // Vertically space out multiple block buttons diff --git a/src/styles/libs/bootstrap/bootstrap/_carousel.scss b/src/styles/libs/bootstrap/bootstrap/_carousel.scss index d8f23648..e9e2f7ce 100644 --- a/src/styles/libs/bootstrap/bootstrap/_carousel.scss +++ b/src/styles/libs/bootstrap/bootstrap/_carousel.scss @@ -28,7 +28,9 @@ > .active, > .next, - > .prev { display: block; } + > .prev { + display: block; + } > .active { left: 0; @@ -91,7 +93,7 @@ // Hover/focus state &:hover, &:focus { - outline: none; + outline: 0; color: $carousel-control-color; text-decoration: none; @include opacity(.9); @@ -110,20 +112,22 @@ .icon-prev, .glyphicon-chevron-left { left: 50%; + margin-left: -10px; } .icon-next, .glyphicon-chevron-right { right: 50%; + margin-right: -10px; } .icon-prev, .icon-next { width: 20px; height: 20px; margin-top: -10px; - margin-left: -10px; font-family: serif; } + .icon-prev { &:before { content: '\2039';// SINGLE LEFT-POINTING ANGLE QUOTATION MARK (U+2039) @@ -213,9 +217,16 @@ width: 30px; height: 30px; margin-top: -15px; - margin-left: -15px; font-size: 30px; } + .glyphicon-chevron-left, + .icon-prev { + margin-left: -15px; + } + .glyphicon-chevron-right, + .icon-next { + margin-right: -15px; + } } // Show and left align the captions diff --git a/src/styles/libs/bootstrap/bootstrap/_code.scss b/src/styles/libs/bootstrap/bootstrap/_code.scss index 89536160..8d83b14d 100644 --- a/src/styles/libs/bootstrap/bootstrap/_code.scss +++ b/src/styles/libs/bootstrap/bootstrap/_code.scss @@ -17,7 +17,6 @@ code { font-size: 90%; color: $code-color; background-color: $code-bg; - white-space: nowrap; border-radius: $border-radius-base; } @@ -29,6 +28,12 @@ kbd { background-color: $kbd-bg; border-radius: $border-radius-small; box-shadow: inset 0 -1px 0 rgba(0,0,0,.25); + + kbd { + padding: 0; + font-size: 100%; + box-shadow: none; + } } // Blocks of code diff --git a/src/styles/libs/bootstrap/bootstrap/_component-animations.scss b/src/styles/libs/bootstrap/bootstrap/_component-animations.scss index 86632fd3..8c3fd07a 100644 --- a/src/styles/libs/bootstrap/bootstrap/_component-animations.scss +++ b/src/styles/libs/bootstrap/bootstrap/_component-animations.scss @@ -5,7 +5,7 @@ // Heads up! // // We don't use the `.opacity()` mixin here since it causes a bug with text -// fields in IE7-8. Source: https://github.com/twitter/bootstrap/pull/3552. +// fields in IE7-8. Source: https://github.com/twbs/bootstrap/pull/3552. .fade { opacity: 0; @@ -17,10 +17,16 @@ .collapse { display: none; - &.in { - display: block; - } + + &.in { display: block; } + // [converter] extracted tr&.in to tr.collapse.in + // [converter] extracted tbody&.in to tbody.collapse.in } + +tr.collapse.in { display: table-row; } + +tbody.collapse.in { display: table-row-group; } + .collapsing { position: relative; height: 0; diff --git a/src/styles/libs/bootstrap/bootstrap/_dropdowns.scss b/src/styles/libs/bootstrap/bootstrap/_dropdowns.scss index 526be5b8..eb74be57 100644 --- a/src/styles/libs/bootstrap/bootstrap/_dropdowns.scss +++ b/src/styles/libs/bootstrap/bootstrap/_dropdowns.scss @@ -38,6 +38,7 @@ margin: 2px 0 0; // override default ul list-style: none; font-size: $font-size-base; + text-align: left; // Ensures proper alignment if parent has it changed (e.g., modal footer) background-color: $dropdown-bg; border: 1px solid $dropdown-fallback-border; // IE8 fallback border: 1px solid $dropdown-border; @@ -154,6 +155,7 @@ font-size: $font-size-small; line-height: $line-height-base; color: $dropdown-header-color; + white-space: nowrap; // as with > li > a } // Backdrop to catch body clicks on mobile, etc. diff --git a/src/styles/libs/bootstrap/bootstrap/_forms.scss b/src/styles/libs/bootstrap/bootstrap/_forms.scss index 26282385..74bb67d8 100644 --- a/src/styles/libs/bootstrap/bootstrap/_forms.scss +++ b/src/styles/libs/bootstrap/bootstrap/_forms.scss @@ -11,7 +11,7 @@ fieldset { padding: 0; margin: 0; border: 0; - // Chrome and Firefox set a `min-width: -webkit-min-content;` on fieldsets, + // Chrome and Firefox set a `min-width: min-content;` on fieldsets, // so we reset that to ensure it behaves more like a standard block element. // See https://github.com/twbs/bootstrap/issues/12359. min-width: 0; @@ -31,6 +31,7 @@ legend { label { display: inline-block; + max-width: 100%; // Force IE8 to wrap long content (see https://github.com/twbs/bootstrap/issues/13141) margin-bottom: 5px; font-weight: bold; } @@ -51,7 +52,7 @@ input[type="search"] { input[type="radio"], input[type="checkbox"] { margin: 4px 0 0; - margin-top: 1px \9; /* IE8-9 */ + margin-top: 1px \9; // IE8-9 line-height: normal; } @@ -166,13 +167,28 @@ input[type="search"] { } -// Special styles for iOS date input +// Special styles for iOS temporal inputs // -// In Mobile Safari, date inputs require a pixel line-height that matches the -// given height of the input. - -input[type="date"] { +// In Mobile Safari, setting `display: block` on temporal inputs causes the +// text within the input to become vertically misaligned. +// As a workaround, we set a pixel line-height that matches the +// given height of the input. Since this fucks up everything else, we have to +// appropriately reset it for Internet Explorer and the size variations. + +input[type="date"], +input[type="time"], +input[type="datetime-local"], +input[type="month"] { line-height: $input-height-base; + // IE8+ misaligns the text within date inputs, so we reset + line-height: $line-height-base #{\0}; + + &.input-sm { + line-height: $input-height-small; + } + &.input-lg { + line-height: $input-height-large; + } } @@ -192,13 +208,15 @@ input[type="date"] { .radio, .checkbox { + position: relative; display: block; min-height: $line-height-computed; // clear the floating input if there is no label text margin-top: 10px; margin-bottom: 10px; - padding-left: 20px; + label { - display: inline; + padding-left: 20px; + margin-bottom: 0; font-weight: normal; cursor: pointer; } @@ -207,9 +225,11 @@ input[type="date"] { .radio-inline input[type="radio"], .checkbox input[type="checkbox"], .checkbox-inline input[type="checkbox"] { - float: left; + position: absolute; margin-left: -20px; + margin-top: 4px \9; } + .radio + .radio, .checkbox + .checkbox { margin-top: -5px; // Move up sibling radios or checkboxes for tighter spacing @@ -232,19 +252,55 @@ input[type="date"] { } // Apply same disabled cursor tweak as for inputs +// Some special care is needed because