From: Martijn Cuppens Date: Sat, 14 Dec 2019 11:45:26 +0000 (+0100) Subject: bootstrap-grid.css: Only apply `box-sizing: border-box` to the columns instead of... X-Git-Tag: v5.0.0-alpha1~374 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5ac9fe8967c0e1797223b18954addbd179bea90e;p=thirdparty%2Fbootstrap.git bootstrap-grid.css: Only apply `box-sizing: border-box` to the columns instead of using the universal selector --- diff --git a/scss/bootstrap-grid.scss b/scss/bootstrap-grid.scss index 8a76c9956e..4abb6822ab 100644 --- a/scss/bootstrap-grid.scss +++ b/scss/bootstrap-grid.scss @@ -5,15 +5,7 @@ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) */ -html { - box-sizing: border-box; -} - -*, -*::before, -*::after { - box-sizing: inherit; -} +$include-column-box-sizing: true !default; @import "functions"; @import "variables"; diff --git a/scss/mixins/_grid.scss b/scss/mixins/_grid.scss index ef97a61bfa..aa71a39a26 100644 --- a/scss/mixins/_grid.scss +++ b/scss/mixins/_grid.scss @@ -10,6 +10,8 @@ } @mixin make-col-ready($gutter: $grid-gutter-width) { + // Add box sizing if only the grid is loaded + box-sizing: if(variable-exists(include-column-box-sizing) and $include-column-box-sizing, border-box, null); // Prevent columns from becoming too narrow when at smaller grid tiers by // always setting `width: 100%;`. This works because we set the width // later on to override this initial width.