diff options
| author | Mark Otto <[email protected]> | 2016-12-22 23:19:21 -0800 |
|---|---|---|
| committer | Mark Otto <[email protected]> | 2016-12-24 14:21:04 -0800 |
| commit | 66c87cb7caa896adf23be7849b2c9559829b3a7b (patch) | |
| tree | 6d5431a342da934f3cba16755c975bcfd5ac9ecc | |
| parent | 4377e2956b202b7b684241bc86b549743fff33d2 (diff) | |
| download | bootstrap-66c87cb7caa896adf23be7849b2c9559829b3a7b.tar.xz bootstrap-66c87cb7caa896adf23be7849b2c9559829b3a7b.zip | |
Undo #21171 (which closed #20977)
Turns out we did have the correct height calculation with our custom selects. The problem was we lacked a shared line-height with our buttons and inputs.
This restores the previous `calc` math and adds a line-height that reuses the input line-height.
| -rw-r--r-- | scss/_custom-forms.scss | 3 | ||||
| -rw-r--r-- | scss/_variables.scss | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/scss/_custom-forms.scss b/scss/_custom-forms.scss index 1d74bc5f4..0e9c76460 100644 --- a/scss/_custom-forms.scss +++ b/scss/_custom-forms.scss @@ -136,8 +136,9 @@ display: inline-block; max-width: 100%; $select-border-width: ($border-width * 2); - height: calc(#{$input-height} - #{$select-border-width}); + height: calc(#{$input-height} + #{$select-border-width}); padding: $custom-select-padding-y ($custom-select-padding-x + $custom-select-indicator-padding) $custom-select-padding-y $custom-select-padding-x; + line-height: $custom-select-line-height; color: $custom-select-color; vertical-align: middle; background: $custom-select-bg $custom-select-indicator no-repeat right $custom-select-padding-x center; diff --git a/scss/_variables.scss b/scss/_variables.scss index a68e45d6e..412f944f5 100644 --- a/scss/_variables.scss +++ b/scss/_variables.scss @@ -487,6 +487,7 @@ $custom-radio-checked-icon: str-replace(url("data:image/svg+xml;charset=utf8,%3C $custom-select-padding-x: .75rem !default; $custom-select-padding-y: .375rem !default; $custom-select-indicator-padding: 1rem !default; // Extra padding to account for the presence of the background-image based indicator +$custom-select-line-height: $input-line-height !default; $custom-select-color: $input-color !default; $custom-select-disabled-color: $gray-light !default; $custom-select-bg: $white !default; |
