]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
Redo line-height globally
authorMark Otto <markdotto@gmail.com>
Thu, 4 Feb 2016 03:45:13 +0000 (19:45 -0800)
committerMark Otto <markdotto@gmail.com>
Thu, 4 Feb 2016 03:45:13 +0000 (19:45 -0800)
- Rename -height to -height-base to match other vars
- Drop use of -height across the board and rely on it to be inherited
- Adjust padding of .dropdown-header to account for different line-height of h6 heading element (this needs refactoring for variables and rems also)

14 files changed:
docs/assets/scss/_content.scss
scss/_buttons.scss
scss/_code.scss
scss/_dropdown.scss
scss/_forms.scss
scss/_images.scss
scss/_pagination.scss
scss/_reboot.scss
scss/_tables.scss
scss/_type.scss
scss/_variables.scss
scss/mixins/_buttons.scss
scss/mixins/_pagination.scss
scss/mixins/_reset-text.scss

index 70ca83375c461363268cbd6b0f78340d38dda608..4e753dd04ffae6fdfbc3724aa98bed0f61067495 100644 (file)
@@ -20,7 +20,6 @@
         > th,
         > td {
           padding: $table-cell-padding;
-          line-height: $line-height;
           vertical-align: top;
           border: 1px solid $table-border-color;
 
index 640fe1dfeb2dbed1280e8ae61fb9480de955c562..1373218eb0c145015793f1f5a791e52d4de72c3a 100644 (file)
@@ -11,7 +11,7 @@
   cursor: pointer;
   user-select: none;
   border: $input-btn-border-width solid transparent;
-  @include button-size($btn-padding-y, $btn-padding-x, $font-size-base, $line-height, $btn-border-radius);
+  @include button-size($btn-padding-y, $btn-padding-x, $font-size-base, $line-height-base, $btn-border-radius);
   @include transition(all .2s ease-in-out);
 
   &,
index a9ddb4c0f517dcb8028e82d3f6e21db553951e51..e3235169828f7d0dac002043f447e43468a1fbea 100644 (file)
@@ -38,7 +38,6 @@ pre {
   margin-top: 0;
   margin-bottom: 1rem;
   font-size: 90%;
-  line-height: $line-height;
   color: $pre-color;
 
   // Account for some code outputs that place code tags in pre tags
index cf4472acd03c151bc0194674e9b2266694e0e5d2..48bdee28695420f01240932674fff94597deaac7 100644 (file)
@@ -70,7 +70,6 @@
   padding: 3px 20px;
   clear: both;
   font-weight: normal;
-  line-height: $line-height;
   color: $dropdown-link-color;
   text-align: inherit; // For `<button>`s
   white-space: nowrap; // prevent links from randomly breaking onto new lines
 // Dropdown section headers
 .dropdown-header {
   display: block;
-  padding: 3px 20px;
+  padding: 5px 20px;
   font-size: $font-size-sm;
-  line-height: $line-height;
   color: $dropdown-header-color;
   white-space: nowrap; // as with > li > a
 }
index aa87bd51a3d6b36ae7d19b0ed6ae1dba4c7c6080..28e0f26bdc1ca9a8656ab4b871fecf3cb260e006 100644 (file)
@@ -9,7 +9,6 @@
   // height: $input-height;
   padding: $input-padding-y $input-padding-x;
   font-size: $font-size-base;
-  line-height: $line-height;
   color: $input-color;
   background-color: $input-bg;
   // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214.
index 60e8fc9b573d873ab889b9c0d15a21db2f2eafaf..410a09e36479fcc6002e6655d54480d2cfd979d0 100644 (file)
@@ -17,7 +17,6 @@
 // Image thumbnails
 .img-thumbnail {
   padding: $thumbnail-padding;
-  line-height: $line-height;
   background-color: $thumbnail-bg;
   border: $thumbnail-border-width solid $thumbnail-border-color;
   border-radius: $thumbnail-border-radius;
index c0b82399fbb9be75c7b81ac297c3f2174cf552ee..5f40a7fd4cbece14cc2ed066d62b53b3947cadb8 100644 (file)
@@ -47,7 +47,6 @@
   float: left; // Collapse white-space
   padding: $pagination-padding-y $pagination-padding-x;
   margin-left: -1px;
-  line-height: $line-height;
   color: $pagination-color;
   text-decoration: none;
   background-color: $pagination-bg;
index 1920474a96721b51ec4bb3b50e48bd3c164ae179..ac3e83baa4120a45cd7a144d853c4ba54eab282e 100644 (file)
@@ -77,7 +77,7 @@ body {
   // Make the `body` use the `font-size-root`
   font-family: $font-family-base;
   font-size: $font-size-base;
-  line-height: $line-height;
+  line-height: $line-height-base;
   // Go easy on the eyes and use something other than `#000` for text
   color: $body-color;
   // By default, `<body>` has no `background-color` so we set one as a best practice.
index 8ec35b9d4071e0df8d59004e13d376afc505bb78..bf688a2c7ec5ab1122c14dd69370c5f7e1bde294 100644 (file)
@@ -10,7 +10,6 @@
   th,
   td {
     padding: $table-cell-padding;
-    line-height: $line-height;
     vertical-align: top;
     border-top: $table-border-width solid $table-border-color;
   }
index fc45d352dbd4e28c24d36a69d135c4f2dd6c8a6a..57214e81875ab343b3be3e7d92d16ffb40cfad65 100644 (file)
@@ -123,7 +123,6 @@ mark,
 .blockquote-footer {
   display: block;
   font-size: 80%; // back to default font-size
-  line-height: $line-height;
   color: $blockquote-small-color;
 
   &::before {
index 81eabb278d4d69e50cb3d4d842878f2093cec81d..a9159e543005da1cbb6000bb73660ae6e97b9ced 100644 (file)
@@ -140,7 +140,7 @@ $grid-gutter-width: 1.875rem !default; // 30px
 $font-family-sans-serif: "Helvetica Neue", Helvetica, Arial, sans-serif !default;
 $font-family-serif:      Georgia, "Times New Roman", Times, serif !default;
 $font-family-monospace:  Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace !default;
-$font-family-base:       $font-family-sans-serif !default;
+$font-family-base: $font-family-sans-serif !default;
 
 // Pixel value used to responsively scale all typography. Applied to the `<html>` element.
 $font-size-root: 16px !default;
@@ -150,6 +150,8 @@ $font-size-lg:   1.25rem !default;
 $font-size-sm:   .875rem !default;
 $font-size-xs:   .75rem !default;
 
+$line-height-base: 1.5 !default;
+
 $font-size-h1: 2.5rem !default;
 $font-size-h2: 2rem !default;
 $font-size-h3: 1.75rem !default;
@@ -167,8 +169,6 @@ $display2-weight: 300 !default;
 $display3-weight: 300 !default;
 $display4-weight: 300 !default;
 
-$line-height: 1.5 !default;
-
 $headings-margin-bottom: ($spacer / 2) !default;
 $headings-font-family:   inherit !default;
 $headings-font-weight:   500 !default;
@@ -314,7 +314,7 @@ $input-padding-y-sm:             .275rem !default;
 $input-padding-x-lg:             1.25rem !default;
 $input-padding-y-lg:             .75rem !default;
 
-$input-height:                   (($font-size-base * $line-height) + ($input-padding-y * 2)) !default;
+$input-height:                   (($font-size-base * $line-height-base) + ($input-padding-y * 2)) !default;
 $input-height-lg:                (($font-size-lg * $line-height-lg) + ($input-padding-y-lg * 2)) !default;
 $input-height-sm:                (($font-size-sm * $line-height-sm) + ($input-padding-y-sm * 2)) !default;
 
@@ -604,7 +604,7 @@ $label-font-weight:           bold !default;
 $modal-inner-padding:         15px !default;
 
 $modal-title-padding:         15px !default;
-$modal-title-line-height:     $line-height !default;
+$modal-title-line-height:     $line-height-base !default;
 
 $modal-content-bg:               #fff !default;
 $modal-content-border-color:     rgba(0,0,0,.2) !default;
index 21240dd9329598947c548071adfcdb89527fc42d..968634880ed8b6a4a5366c4b5b33a91d567b839f 100644 (file)
@@ -95,6 +95,5 @@
 @mixin button-size($padding-y, $padding-x, $font-size, $line-height, $border-radius) {
   padding: $padding-y $padding-x;
   font-size: $font-size;
-  line-height: $line-height;
   @include border-radius($border-radius);
 }
index ff36eb6b40a8ad577ae61f304cc5f23402d74cef..8cd9317cf5226e2f35d19cefa637feb73cfe4a8b 100644 (file)
@@ -4,7 +4,6 @@
   .page-link {
     padding: $padding-y $padding-x;
     font-size: $font-size;
-    line-height: $line-height;
   }
 
   .page-item {
index e1d1725fad0ad0d12aa14211395da164238119d1..bb882f2ac0f8494d6b82d67418a71bc89ed8fbf0 100644 (file)
@@ -5,7 +5,7 @@
   font-weight: normal;
   letter-spacing: normal;
   line-break: auto;
-  line-height: $line-height;
+  line-height: $line-height-base;
   text-align: left; // Fallback for where `start` is not supported
   text-align: start;
   text-decoration: none;