bootstrap-sass 3.3.1.0 → 3.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +1 -0
- data/.travis.yml +8 -14
- data/CHANGELOG.md +55 -0
- data/CONTRIBUTING.md +8 -1
- data/Gemfile +1 -4
- data/LICENSE +2 -1
- data/README.md +118 -96
- data/Rakefile +58 -12
- data/assets/fonts/bootstrap/glyphicons-halflings-regular.eot +0 -0
- data/assets/fonts/bootstrap/glyphicons-halflings-regular.svg +273 -214
- data/assets/fonts/bootstrap/glyphicons-halflings-regular.ttf +0 -0
- data/assets/fonts/bootstrap/glyphicons-halflings-regular.woff +0 -0
- data/assets/fonts/bootstrap/glyphicons-halflings-regular.woff2 +0 -0
- data/assets/javascripts/bootstrap/affix.js +11 -9
- data/assets/javascripts/bootstrap/alert.js +6 -5
- data/assets/javascripts/bootstrap/button.js +24 -15
- data/assets/javascripts/bootstrap/carousel.js +24 -18
- data/assets/javascripts/bootstrap/collapse.js +13 -12
- data/assets/javascripts/bootstrap/dropdown.js +50 -46
- data/assets/javascripts/bootstrap/modal.js +77 -43
- data/assets/javascripts/bootstrap/popover.js +31 -27
- data/assets/javascripts/bootstrap/scrollspy.js +19 -22
- data/assets/javascripts/bootstrap/tab.js +14 -12
- data/assets/javascripts/bootstrap/tooltip.js +255 -56
- data/assets/javascripts/bootstrap/transition.js +5 -5
- data/assets/javascripts/bootstrap-sprockets.js +2 -2
- data/assets/javascripts/bootstrap.js +1280 -1004
- data/assets/javascripts/bootstrap.min.js +6 -0
- data/assets/stylesheets/_bootstrap-compass.scss +2 -0
- data/assets/stylesheets/_bootstrap-mincer.scss +4 -2
- data/assets/stylesheets/_bootstrap-sprockets.scss +2 -0
- data/assets/stylesheets/_bootstrap.scss +6 -0
- data/assets/stylesheets/bootstrap/_alerts.scss +8 -3
- data/assets/stylesheets/bootstrap/_badges.scss +9 -4
- data/assets/stylesheets/bootstrap/_breadcrumbs.scss +3 -1
- data/assets/stylesheets/bootstrap/_button-groups.scss +11 -10
- data/assets/stylesheets/bootstrap/_buttons.scss +18 -10
- data/assets/stylesheets/bootstrap/_carousel.scss +40 -36
- data/assets/stylesheets/bootstrap/_close.scss +2 -0
- data/assets/stylesheets/bootstrap/_code.scss +3 -3
- data/assets/stylesheets/bootstrap/_component-animations.scss +2 -2
- data/assets/stylesheets/bootstrap/_dropdowns.scss +24 -24
- data/assets/stylesheets/bootstrap/_forms.scss +143 -84
- data/assets/stylesheets/bootstrap/_glyphicons.scss +85 -12
- data/assets/stylesheets/bootstrap/_grid.scss +10 -0
- data/assets/stylesheets/bootstrap/_input-groups.scss +10 -5
- data/assets/stylesheets/bootstrap/_jumbotron.scss +9 -4
- data/assets/stylesheets/bootstrap/_labels.scss +1 -1
- data/assets/stylesheets/bootstrap/_list-group.scss +30 -26
- data/assets/stylesheets/bootstrap/_media.scss +19 -0
- data/assets/stylesheets/bootstrap/_mixins.scss +1 -0
- data/assets/stylesheets/bootstrap/_modals.scss +11 -9
- data/assets/stylesheets/bootstrap/_navbar.scss +76 -82
- data/assets/stylesheets/bootstrap/_navs.scss +4 -6
- data/assets/stylesheets/bootstrap/_normalize.scss +13 -13
- data/assets/stylesheets/bootstrap/_pager.scss +2 -2
- data/assets/stylesheets/bootstrap/_pagination.scss +15 -17
- data/assets/stylesheets/bootstrap/_panels.scss +16 -6
- data/assets/stylesheets/bootstrap/_popovers.scss +50 -59
- data/assets/stylesheets/bootstrap/_print.scss +90 -98
- data/assets/stylesheets/bootstrap/_progress-bars.scss +3 -3
- data/assets/stylesheets/bootstrap/_responsive-embed.scss +10 -10
- data/assets/stylesheets/bootstrap/_responsive-utilities.scss +11 -6
- data/assets/stylesheets/bootstrap/_scaffolding.scss +18 -7
- data/assets/stylesheets/bootstrap/_tables.scss +24 -24
- data/assets/stylesheets/bootstrap/_theme.scss +45 -22
- data/assets/stylesheets/bootstrap/_thumbnails.scss +1 -1
- data/assets/stylesheets/bootstrap/_tooltip.scss +42 -33
- data/assets/stylesheets/bootstrap/_type.scss +12 -12
- data/assets/stylesheets/bootstrap/_utilities.scss +0 -1
- data/assets/stylesheets/bootstrap/_variables.scss +27 -17
- data/assets/stylesheets/bootstrap/_wells.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_alerts.scss +2 -1
- data/assets/stylesheets/bootstrap/mixins/_background-variant.scss +2 -1
- data/assets/stylesheets/bootstrap/mixins/_border-radius.scss +4 -4
- data/assets/stylesheets/bootstrap/mixins/_buttons.scss +20 -11
- data/assets/stylesheets/bootstrap/mixins/_center-block.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_clearfix.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_forms.scss +4 -4
- data/assets/stylesheets/bootstrap/mixins/_gradients.scss +6 -8
- data/assets/stylesheets/bootstrap/mixins/_grid-framework.scss +2 -2
- data/assets/stylesheets/bootstrap/mixins/_grid.scss +8 -8
- data/assets/stylesheets/bootstrap/mixins/_hide-text.scss +3 -3
- data/assets/stylesheets/bootstrap/mixins/_image.scss +5 -10
- data/assets/stylesheets/bootstrap/mixins/_list-group.scss +3 -2
- data/assets/stylesheets/bootstrap/mixins/_opacity.scss +2 -3
- data/assets/stylesheets/bootstrap/mixins/_pagination.scss +2 -1
- data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +18 -0
- data/assets/stylesheets/bootstrap/mixins/_resize.scss +1 -1
- data/assets/stylesheets/bootstrap/mixins/_responsive-visibility.scss +1 -5
- data/assets/stylesheets/bootstrap/mixins/_tab-focus.scss +3 -3
- data/assets/stylesheets/bootstrap/mixins/_text-emphasis.scss +2 -1
- data/assets/stylesheets/bootstrap/mixins/_vendor-prefixes.scss +4 -4
- data/bootstrap-sass.gemspec +10 -9
- data/bower.json +6 -20
- data/composer.json +2 -2
- data/eyeglass-exports.js +7 -0
- data/lib/bootstrap-sass/engine.rb +6 -1
- data/lib/bootstrap-sass/version.rb +2 -2
- data/lib/bootstrap-sass.rb +32 -13
- data/package-lock.json +1611 -0
- data/package.json +21 -7
- data/sache.json +1 -1
- data/tasks/bower.rake +2 -5
- data/tasks/converter/fonts_conversion.rb +1 -1
- data/tasks/converter/js_conversion.rb +7 -5
- data/tasks/converter/less_conversion.rb +47 -36
- data/tasks/converter/network.rb +12 -7
- data/tasks/converter.rb +1 -1
- data/templates/project/_bootstrap-variables.sass +27 -18
- data/templates/project/styles.sass +3 -0
- data/test/compilation_test.rb +24 -12
- data/test/dummy_rails/app/assets/stylesheets/{application.css.sass → application.sass} +0 -0
- data/test/dummy_rails/app/views/pages/root.html.slim +43 -0
- data/test/dummy_rails/config/application.rb +2 -1
- data/test/dummy_rails/config/boot.rb +1 -1
- data/test/dummy_rails/config/environments/development.rb +0 -3
- data/test/dummy_rails/config/environments/production.rb +7 -1
- data/test/dummy_rails/config/environments/test.rb +9 -1
- data/test/dummy_sass_only/Gemfile +1 -1
- data/test/dummy_sass_only/compile.rb +14 -7
- data/test/dummy_sass_only/import_all.scss +2 -0
- data/test/gemfiles/default.gemfile +3 -0
- data/test/node_mincer_test.rb +2 -3
- data/test/node_sass_compile_test.sh +4 -3
- data/test/sass_test.rb +10 -7
- data/test/sprockets_rails_test.rb +12 -8
- data/test/support/dummy_rails_integration.rb +1 -1
- data/test/support/reporting.rb +10 -0
- data/test/test_helper.rb +3 -2
- metadata +56 -46
- data/test/compass_test.rb +0 -9
- data/test/dummy_rails/log/development.log +0 -0
- data/test/dummy_sass_only/import_all.sass +0 -2
- data/test/gemfiles/sass_3_2.gemfile +0 -6
- data/test/gemfiles/sass_3_3.gemfile +0 -6
- data/test/gemfiles/sass_3_4.gemfile +0 -7
- data/test/gemfiles/sass_head.gemfile +0 -6
@@ -27,12 +27,12 @@ kbd {
|
|
27
27
|
color: $kbd-color;
|
28
28
|
background-color: $kbd-bg;
|
29
29
|
border-radius: $border-radius-small;
|
30
|
-
box-shadow: inset 0 -1px 0 rgba(0,0,0
|
30
|
+
box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25);
|
31
31
|
|
32
32
|
kbd {
|
33
33
|
padding: 0;
|
34
34
|
font-size: 100%;
|
35
|
-
font-weight:
|
35
|
+
font-weight: 700;
|
36
36
|
box-shadow: none;
|
37
37
|
}
|
38
38
|
}
|
@@ -44,9 +44,9 @@ pre {
|
|
44
44
|
margin: 0 0 ($line-height-computed / 2);
|
45
45
|
font-size: ($font-size-base - 1); // 14px to 13px
|
46
46
|
line-height: $line-height-base;
|
47
|
+
color: $pre-color;
|
47
48
|
word-break: break-all;
|
48
49
|
word-wrap: break-word;
|
49
|
-
color: $pre-color;
|
50
50
|
background-color: $pre-bg;
|
51
51
|
border: 1px solid $pre-border-color;
|
52
52
|
border-radius: $border-radius-base;
|
@@ -10,6 +10,7 @@
|
|
10
10
|
.fade {
|
11
11
|
opacity: 0;
|
12
12
|
@include transition(opacity .15s linear);
|
13
|
+
|
13
14
|
&.in {
|
14
15
|
opacity: 1;
|
15
16
|
}
|
@@ -17,9 +18,8 @@
|
|
17
18
|
|
18
19
|
.collapse {
|
19
20
|
display: none;
|
20
|
-
visibility: hidden;
|
21
21
|
|
22
|
-
&.in { display: block;
|
22
|
+
&.in { display: block; }
|
23
23
|
// [converter] extracted tr&.in to tr.collapse.in
|
24
24
|
// [converter] extracted tbody&.in to tbody.collapse.in
|
25
25
|
}
|
@@ -10,12 +10,14 @@
|
|
10
10
|
height: 0;
|
11
11
|
margin-left: 2px;
|
12
12
|
vertical-align: middle;
|
13
|
-
border-top:
|
13
|
+
border-top: $caret-width-base dashed;
|
14
|
+
border-top: $caret-width-base solid \9; // IE8
|
14
15
|
border-right: $caret-width-base solid transparent;
|
15
|
-
border-left:
|
16
|
+
border-left: $caret-width-base solid transparent;
|
16
17
|
}
|
17
18
|
|
18
19
|
// The dropdown wrapper (div)
|
20
|
+
.dropup,
|
19
21
|
.dropdown {
|
20
22
|
position: relative;
|
21
23
|
}
|
@@ -36,15 +38,15 @@
|
|
36
38
|
min-width: 160px;
|
37
39
|
padding: 5px 0;
|
38
40
|
margin: 2px 0 0; // override default ul
|
39
|
-
list-style: none;
|
40
41
|
font-size: $font-size-base;
|
41
42
|
text-align: left; // Ensures proper alignment if parent has it changed (e.g., modal footer)
|
43
|
+
list-style: none;
|
42
44
|
background-color: $dropdown-bg;
|
45
|
+
background-clip: padding-box;
|
43
46
|
border: 1px solid $dropdown-fallback-border; // IE8 fallback
|
44
47
|
border: 1px solid $dropdown-border;
|
45
48
|
border-radius: $border-radius-base;
|
46
|
-
@include box-shadow(0 6px 12px rgba(0,0,0
|
47
|
-
background-clip: padding-box;
|
49
|
+
@include box-shadow(0 6px 12px rgba(0, 0, 0, .175));
|
48
50
|
|
49
51
|
// Aligns the dropdown menu to right
|
50
52
|
//
|
@@ -64,20 +66,17 @@
|
|
64
66
|
display: block;
|
65
67
|
padding: 3px 20px;
|
66
68
|
clear: both;
|
67
|
-
font-weight:
|
69
|
+
font-weight: 400;
|
68
70
|
line-height: $line-height-base;
|
69
71
|
color: $dropdown-link-color;
|
70
72
|
white-space: nowrap; // prevent links from randomly breaking onto new lines
|
71
|
-
}
|
72
|
-
}
|
73
73
|
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
background-color: $dropdown-link-hover-bg;
|
74
|
+
&:hover,
|
75
|
+
&:focus {
|
76
|
+
color: $dropdown-link-hover-color;
|
77
|
+
text-decoration: none;
|
78
|
+
background-color: $dropdown-link-hover-bg;
|
79
|
+
}
|
81
80
|
}
|
82
81
|
}
|
83
82
|
|
@@ -88,8 +87,8 @@
|
|
88
87
|
&:focus {
|
89
88
|
color: $dropdown-link-active-color;
|
90
89
|
text-decoration: none;
|
91
|
-
outline: 0;
|
92
90
|
background-color: $dropdown-link-active-bg;
|
91
|
+
outline: 0;
|
93
92
|
}
|
94
93
|
}
|
95
94
|
|
@@ -108,10 +107,10 @@
|
|
108
107
|
&:hover,
|
109
108
|
&:focus {
|
110
109
|
text-decoration: none;
|
110
|
+
cursor: $cursor-disabled;
|
111
111
|
background-color: transparent;
|
112
112
|
background-image: none; // Remove CSS gradient
|
113
113
|
@include reset-filter;
|
114
|
-
cursor: $cursor-disabled;
|
115
114
|
}
|
116
115
|
}
|
117
116
|
|
@@ -133,8 +132,8 @@
|
|
133
132
|
// Add extra class to `.dropdown-menu` to flip the alignment of the dropdown
|
134
133
|
// menu with the parent.
|
135
134
|
.dropdown-menu-right {
|
136
|
-
left: auto; // Reset the default from `.dropdown-menu`
|
137
135
|
right: 0;
|
136
|
+
left: auto; // Reset the default from `.dropdown-menu`
|
138
137
|
}
|
139
138
|
// With v3, we enabled auto-flipping if you have a dropdown within a right
|
140
139
|
// aligned nav component. To enable the undoing of that, we provide an override
|
@@ -143,8 +142,8 @@
|
|
143
142
|
// This is only for left-aligning a dropdown menu within a `.navbar-right` or
|
144
143
|
// `.pull-right` nav component.
|
145
144
|
.dropdown-menu-left {
|
146
|
-
left: 0;
|
147
145
|
right: auto;
|
146
|
+
left: 0;
|
148
147
|
}
|
149
148
|
|
150
149
|
// Dropdown section headers
|
@@ -160,10 +159,10 @@
|
|
160
159
|
// Backdrop to catch body clicks on mobile, etc.
|
161
160
|
.dropdown-backdrop {
|
162
161
|
position: fixed;
|
163
|
-
|
162
|
+
top: 0;
|
164
163
|
right: 0;
|
165
164
|
bottom: 0;
|
166
|
-
|
165
|
+
left: 0;
|
167
166
|
z-index: ($zindex-dropdown - 10);
|
168
167
|
}
|
169
168
|
|
@@ -182,15 +181,16 @@
|
|
182
181
|
.navbar-fixed-bottom .dropdown {
|
183
182
|
// Reverse the caret
|
184
183
|
.caret {
|
185
|
-
border-top: 0;
|
186
|
-
border-bottom: $caret-width-base solid;
|
187
184
|
content: "";
|
185
|
+
border-top: 0;
|
186
|
+
border-bottom: $caret-width-base dashed;
|
187
|
+
border-bottom: $caret-width-base solid \9; // IE8
|
188
188
|
}
|
189
189
|
// Different positioning for bottom up menu
|
190
190
|
.dropdown-menu {
|
191
191
|
top: auto;
|
192
192
|
bottom: 100%;
|
193
|
-
margin-bottom:
|
193
|
+
margin-bottom: 2px;
|
194
194
|
}
|
195
195
|
}
|
196
196
|
|
@@ -8,13 +8,13 @@
|
|
8
8
|
// Restyle and baseline non-control form elements.
|
9
9
|
|
10
10
|
fieldset {
|
11
|
-
padding: 0;
|
12
|
-
margin: 0;
|
13
|
-
border: 0;
|
14
11
|
// Chrome and Firefox set a `min-width: min-content;` on fieldsets,
|
15
12
|
// so we reset that to ensure it behaves more like a standard block element.
|
16
13
|
// See https://github.com/twbs/bootstrap/issues/12359.
|
17
14
|
min-width: 0;
|
15
|
+
padding: 0;
|
16
|
+
margin: 0;
|
17
|
+
border: 0;
|
18
18
|
}
|
19
19
|
|
20
20
|
legend {
|
@@ -33,7 +33,7 @@ label {
|
|
33
33
|
display: inline-block;
|
34
34
|
max-width: 100%; // Force IE8 to wrap long content (see https://github.com/twbs/bootstrap/issues/13141)
|
35
35
|
margin-bottom: 5px;
|
36
|
-
font-weight:
|
36
|
+
font-weight: 700;
|
37
37
|
}
|
38
38
|
|
39
39
|
|
@@ -43,9 +43,18 @@ label {
|
|
43
43
|
// is required to ensure optimum display with or without those classes to better
|
44
44
|
// address browser inconsistencies.
|
45
45
|
|
46
|
-
// Override content-box in Normalize (* isn't specific enough)
|
47
46
|
input[type="search"] {
|
47
|
+
// Override content-box in Normalize (* isn't specific enough)
|
48
48
|
@include box-sizing(border-box);
|
49
|
+
|
50
|
+
// Search inputs in iOS
|
51
|
+
//
|
52
|
+
// This overrides the extra rounded corners on search inputs in iOS so that our
|
53
|
+
// `.form-control` class can properly style them. Note that this cannot simply
|
54
|
+
// be added to `.form-control` as it's not specific enough. For details, see
|
55
|
+
// https://github.com/twbs/bootstrap/issues/11586.
|
56
|
+
-webkit-appearance: none;
|
57
|
+
appearance: none;
|
49
58
|
}
|
50
59
|
|
51
60
|
// Position radios and checkboxes better
|
@@ -54,9 +63,18 @@ input[type="checkbox"] {
|
|
54
63
|
margin: 4px 0 0;
|
55
64
|
margin-top: 1px \9; // IE8-9
|
56
65
|
line-height: normal;
|
66
|
+
|
67
|
+
// Apply same disabled cursor tweak as for inputs
|
68
|
+
// Some special care is needed because <label>s don't inherit their parent's `cursor`.
|
69
|
+
//
|
70
|
+
// Note: Neither radios nor checkboxes can be readonly.
|
71
|
+
&[disabled],
|
72
|
+
&.disabled,
|
73
|
+
fieldset[disabled] & {
|
74
|
+
cursor: $cursor-disabled;
|
75
|
+
}
|
57
76
|
}
|
58
77
|
|
59
|
-
// Set the height of file controls to match text inputs
|
60
78
|
input[type="file"] {
|
61
79
|
display: block;
|
62
80
|
}
|
@@ -123,8 +141,8 @@ output {
|
|
123
141
|
background-color: $input-bg;
|
124
142
|
background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
|
125
143
|
border: 1px solid $input-border;
|
126
|
-
border-radius: $input-border-radius;
|
127
|
-
@include box-shadow(inset 0 1px 1px rgba(0,0,0
|
144
|
+
border-radius: $input-border-radius; // Note: This has no effect on <select>s in some browsers, due to the limited stylability of <select>s in CSS.
|
145
|
+
@include box-shadow(inset 0 1px 1px rgba(0, 0, 0, .075));
|
128
146
|
@include transition(border-color ease-in-out .15s, box-shadow ease-in-out .15s);
|
129
147
|
|
130
148
|
// Customize the `:focus` state to imitate native WebKit styles.
|
@@ -133,6 +151,12 @@ output {
|
|
133
151
|
// Placeholder
|
134
152
|
@include placeholder;
|
135
153
|
|
154
|
+
// Unstyle the caret on `<select>`s in IE10+.
|
155
|
+
&::-ms-expand {
|
156
|
+
background-color: transparent;
|
157
|
+
border: 0;
|
158
|
+
}
|
159
|
+
|
136
160
|
// Disabled and read-only inputs
|
137
161
|
//
|
138
162
|
// HTML5 says that controls under a fieldset > legend:first-child won't be
|
@@ -141,9 +165,13 @@ output {
|
|
141
165
|
&[disabled],
|
142
166
|
&[readonly],
|
143
167
|
fieldset[disabled] & {
|
144
|
-
cursor: $cursor-disabled;
|
145
168
|
background-color: $input-bg-disabled;
|
146
|
-
opacity: 1; // iOS fix for unreadable disabled content
|
169
|
+
opacity: 1; // iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655
|
170
|
+
}
|
171
|
+
|
172
|
+
&[disabled],
|
173
|
+
fieldset[disabled] & {
|
174
|
+
cursor: $cursor-disabled;
|
147
175
|
}
|
148
176
|
|
149
177
|
// [converter] extracted textarea& to textarea.form-control
|
@@ -155,43 +183,33 @@ textarea.form-control {
|
|
155
183
|
}
|
156
184
|
|
157
185
|
|
158
|
-
// Search inputs in iOS
|
159
|
-
//
|
160
|
-
// This overrides the extra rounded corners on search inputs in iOS so that our
|
161
|
-
// `.form-control` class can properly style them. Note that this cannot simply
|
162
|
-
// be added to `.form-control` as it's not specific enough. For details, see
|
163
|
-
// https://github.com/twbs/bootstrap/issues/11586.
|
164
|
-
|
165
|
-
input[type="search"] {
|
166
|
-
-webkit-appearance: none;
|
167
|
-
}
|
168
|
-
|
169
|
-
|
170
186
|
// Special styles for iOS temporal inputs
|
171
187
|
//
|
172
188
|
// In Mobile Safari, setting `display: block` on temporal inputs causes the
|
173
189
|
// text within the input to become vertically misaligned. As a workaround, we
|
174
190
|
// set a pixel line-height that matches the given height of the input, but only
|
175
|
-
// for Safari.
|
191
|
+
// for Safari. See https://bugs.webkit.org/show_bug.cgi?id=139848
|
192
|
+
//
|
193
|
+
// Note that as of 9.3, iOS doesn't support `week`.
|
176
194
|
|
177
195
|
@media screen and (-webkit-min-device-pixel-ratio: 0) {
|
178
196
|
input[type="date"],
|
179
197
|
input[type="time"],
|
180
198
|
input[type="datetime-local"],
|
181
199
|
input[type="month"] {
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
200
|
+
&.form-control {
|
201
|
+
line-height: $input-height-base;
|
202
|
+
}
|
203
|
+
|
204
|
+
&.input-sm,
|
205
|
+
.input-group-sm & {
|
206
|
+
line-height: $input-height-small;
|
207
|
+
}
|
208
|
+
|
209
|
+
&.input-lg,
|
210
|
+
.input-group-lg & {
|
211
|
+
line-height: $input-height-large;
|
212
|
+
}
|
195
213
|
}
|
196
214
|
}
|
197
215
|
|
@@ -202,7 +220,7 @@ input[type="search"] {
|
|
202
220
|
// horizontal forms, use the predefined grid classes.
|
203
221
|
|
204
222
|
.form-group {
|
205
|
-
margin-bottom:
|
223
|
+
margin-bottom: $form-group-margin-bottom;
|
206
224
|
}
|
207
225
|
|
208
226
|
|
@@ -217,11 +235,19 @@ input[type="search"] {
|
|
217
235
|
margin-top: 10px;
|
218
236
|
margin-bottom: 10px;
|
219
237
|
|
238
|
+
// These are used on elements with <label> descendants
|
239
|
+
&.disabled,
|
240
|
+
fieldset[disabled] & {
|
241
|
+
label {
|
242
|
+
cursor: $cursor-disabled;
|
243
|
+
}
|
244
|
+
}
|
245
|
+
|
220
246
|
label {
|
221
247
|
min-height: $line-height-computed; // Ensure the input doesn't jump when there is no text
|
222
248
|
padding-left: 20px;
|
223
249
|
margin-bottom: 0;
|
224
|
-
font-weight:
|
250
|
+
font-weight: 400;
|
225
251
|
cursor: pointer;
|
226
252
|
}
|
227
253
|
}
|
@@ -230,8 +256,8 @@ input[type="search"] {
|
|
230
256
|
.checkbox input[type="checkbox"],
|
231
257
|
.checkbox-inline input[type="checkbox"] {
|
232
258
|
position: absolute;
|
233
|
-
margin-left: -20px;
|
234
259
|
margin-top: 4px \9;
|
260
|
+
margin-left: -20px;
|
235
261
|
}
|
236
262
|
|
237
263
|
.radio + .radio,
|
@@ -242,48 +268,24 @@ input[type="search"] {
|
|
242
268
|
// Radios and checkboxes on same line
|
243
269
|
.radio-inline,
|
244
270
|
.checkbox-inline {
|
271
|
+
position: relative;
|
245
272
|
display: inline-block;
|
246
273
|
padding-left: 20px;
|
247
274
|
margin-bottom: 0;
|
275
|
+
font-weight: 400;
|
248
276
|
vertical-align: middle;
|
249
|
-
font-weight: normal;
|
250
277
|
cursor: pointer;
|
251
|
-
}
|
252
|
-
.radio-inline + .radio-inline,
|
253
|
-
.checkbox-inline + .checkbox-inline {
|
254
|
-
margin-top: 0;
|
255
|
-
margin-left: 10px; // space out consecutive inline controls
|
256
|
-
}
|
257
278
|
|
258
|
-
//
|
259
|
-
// Some special care is needed because <label>s don't inherit their parent's `cursor`.
|
260
|
-
//
|
261
|
-
// Note: Neither radios nor checkboxes can be readonly.
|
262
|
-
input[type="radio"],
|
263
|
-
input[type="checkbox"] {
|
264
|
-
&[disabled],
|
265
|
-
&.disabled,
|
266
|
-
fieldset[disabled] & {
|
267
|
-
cursor: $cursor-disabled;
|
268
|
-
}
|
269
|
-
}
|
270
|
-
// These classes are used directly on <label>s
|
271
|
-
.radio-inline,
|
272
|
-
.checkbox-inline {
|
279
|
+
// These are used directly on <label>s
|
273
280
|
&.disabled,
|
274
281
|
fieldset[disabled] & {
|
275
282
|
cursor: $cursor-disabled;
|
276
283
|
}
|
277
284
|
}
|
278
|
-
|
279
|
-
.
|
280
|
-
|
281
|
-
|
282
|
-
fieldset[disabled] & {
|
283
|
-
label {
|
284
|
-
cursor: $cursor-disabled;
|
285
|
-
}
|
286
|
-
}
|
285
|
+
.radio-inline + .radio-inline,
|
286
|
+
.checkbox-inline + .checkbox-inline {
|
287
|
+
margin-top: 0;
|
288
|
+
margin-left: 10px; // space out consecutive inline controls
|
287
289
|
}
|
288
290
|
|
289
291
|
|
@@ -293,6 +295,7 @@ input[type="checkbox"] {
|
|
293
295
|
// a horizontal form layout.
|
294
296
|
|
295
297
|
.form-control-static {
|
298
|
+
min-height: ($line-height-computed + $font-size-base);
|
296
299
|
// Size it appropriately next to real form controls
|
297
300
|
padding-top: ($padding-base-vertical + 1);
|
298
301
|
padding-bottom: ($padding-base-vertical + 1);
|
@@ -301,8 +304,8 @@ input[type="checkbox"] {
|
|
301
304
|
|
302
305
|
&.input-lg,
|
303
306
|
&.input-sm {
|
304
|
-
padding-left: 0;
|
305
307
|
padding-right: 0;
|
308
|
+
padding-left: 0;
|
306
309
|
}
|
307
310
|
}
|
308
311
|
|
@@ -311,10 +314,61 @@ input[type="checkbox"] {
|
|
311
314
|
//
|
312
315
|
// Build on `.form-control` with modifier classes to decrease or increase the
|
313
316
|
// height and font-size of form controls.
|
317
|
+
//
|
318
|
+
// The `.form-group-* form-control` variations are sadly duplicated to avoid the
|
319
|
+
// issue documented in https://github.com/twbs/bootstrap/issues/15074.
|
314
320
|
|
315
|
-
@include input-size('.input-sm
|
321
|
+
@include input-size('.input-sm', $input-height-small, $padding-small-vertical, $padding-small-horizontal, $font-size-small, $line-height-small, $input-border-radius-small);
|
322
|
+
.form-group-sm {
|
323
|
+
.form-control {
|
324
|
+
height: $input-height-small;
|
325
|
+
padding: $padding-small-vertical $padding-small-horizontal;
|
326
|
+
font-size: $font-size-small;
|
327
|
+
line-height: $line-height-small;
|
328
|
+
border-radius: $input-border-radius-small;
|
329
|
+
}
|
330
|
+
select.form-control {
|
331
|
+
height: $input-height-small;
|
332
|
+
line-height: $input-height-small;
|
333
|
+
}
|
334
|
+
textarea.form-control,
|
335
|
+
select[multiple].form-control {
|
336
|
+
height: auto;
|
337
|
+
}
|
338
|
+
.form-control-static {
|
339
|
+
height: $input-height-small;
|
340
|
+
min-height: ($line-height-computed + $font-size-small);
|
341
|
+
padding: ($padding-small-vertical + 1) $padding-small-horizontal;
|
342
|
+
font-size: $font-size-small;
|
343
|
+
line-height: $line-height-small;
|
344
|
+
}
|
345
|
+
}
|
316
346
|
|
317
|
-
@include input-size('.input-lg
|
347
|
+
@include input-size('.input-lg', $input-height-large, $padding-large-vertical, $padding-large-horizontal, $font-size-large, $line-height-large, $input-border-radius-large);
|
348
|
+
.form-group-lg {
|
349
|
+
.form-control {
|
350
|
+
height: $input-height-large;
|
351
|
+
padding: $padding-large-vertical $padding-large-horizontal;
|
352
|
+
font-size: $font-size-large;
|
353
|
+
line-height: $line-height-large;
|
354
|
+
border-radius: $input-border-radius-large;
|
355
|
+
}
|
356
|
+
select.form-control {
|
357
|
+
height: $input-height-large;
|
358
|
+
line-height: $input-height-large;
|
359
|
+
}
|
360
|
+
textarea.form-control,
|
361
|
+
select[multiple].form-control {
|
362
|
+
height: auto;
|
363
|
+
}
|
364
|
+
.form-control-static {
|
365
|
+
height: $input-height-large;
|
366
|
+
min-height: ($line-height-computed + $font-size-large);
|
367
|
+
padding: ($padding-large-vertical + 1) $padding-large-horizontal;
|
368
|
+
font-size: $font-size-large;
|
369
|
+
line-height: $line-height-large;
|
370
|
+
}
|
371
|
+
}
|
318
372
|
|
319
373
|
|
320
374
|
// Form control feedback states
|
@@ -343,12 +397,16 @@ input[type="checkbox"] {
|
|
343
397
|
text-align: center;
|
344
398
|
pointer-events: none;
|
345
399
|
}
|
346
|
-
.input-lg + .form-control-feedback
|
400
|
+
.input-lg + .form-control-feedback,
|
401
|
+
.input-group-lg + .form-control-feedback,
|
402
|
+
.form-group-lg .form-control + .form-control-feedback {
|
347
403
|
width: $input-height-large;
|
348
404
|
height: $input-height-large;
|
349
405
|
line-height: $input-height-large;
|
350
406
|
}
|
351
|
-
.input-sm + .form-control-feedback
|
407
|
+
.input-sm + .form-control-feedback,
|
408
|
+
.input-group-sm + .form-control-feedback,
|
409
|
+
.form-group-sm .form-control + .form-control-feedback {
|
352
410
|
width: $input-height-small;
|
353
411
|
height: $input-height-small;
|
354
412
|
line-height: $input-height-small;
|
@@ -369,10 +427,10 @@ input[type="checkbox"] {
|
|
369
427
|
.has-feedback label {
|
370
428
|
|
371
429
|
& ~ .form-control-feedback {
|
372
|
-
|
430
|
+
top: ($line-height-computed + 5); // Height of the `label` and its margin
|
373
431
|
}
|
374
432
|
&.sr-only ~ .form-control-feedback {
|
375
|
-
|
433
|
+
top: 0;
|
376
434
|
}
|
377
435
|
}
|
378
436
|
|
@@ -447,8 +505,7 @@ input[type="checkbox"] {
|
|
447
505
|
}
|
448
506
|
|
449
507
|
// Remove default margin on radios/checkboxes that were used for stacking, and
|
450
|
-
// then undo the floating of radios and checkboxes to match
|
451
|
-
// a bug in WebKit: https://github.com/twbs/bootstrap/issues/1969).
|
508
|
+
// then undo the floating of radios and checkboxes to match.
|
452
509
|
.radio,
|
453
510
|
.checkbox {
|
454
511
|
display: inline-block;
|
@@ -493,9 +550,9 @@ input[type="checkbox"] {
|
|
493
550
|
.checkbox,
|
494
551
|
.radio-inline,
|
495
552
|
.checkbox-inline {
|
553
|
+
padding-top: ($padding-base-vertical + 1); // Default padding plus a border
|
496
554
|
margin-top: 0;
|
497
555
|
margin-bottom: 0;
|
498
|
-
padding-top: ($padding-base-vertical + 1); // Default padding plus a border
|
499
556
|
}
|
500
557
|
// Account for padding we're adding to ensure the alignment and of help text
|
501
558
|
// and other content below items
|
@@ -513,9 +570,9 @@ input[type="checkbox"] {
|
|
513
570
|
// labels on narrow viewports stack the same as a default form example.
|
514
571
|
@media (min-width: $screen-sm-min) {
|
515
572
|
.control-label {
|
516
|
-
text-align: right;
|
517
|
-
margin-bottom: 0;
|
518
573
|
padding-top: ($padding-base-vertical + 1); // Default padding plus a border
|
574
|
+
margin-bottom: 0;
|
575
|
+
text-align: right;
|
519
576
|
}
|
520
577
|
}
|
521
578
|
|
@@ -524,7 +581,7 @@ input[type="checkbox"] {
|
|
524
581
|
// Reposition the icon because it's now within a grid column and columns have
|
525
582
|
// `position: relative;` on them. Also accounts for the grid gutter padding.
|
526
583
|
.has-feedback .form-control-feedback {
|
527
|
-
right: ($grid-gutter-width / 2);
|
584
|
+
right: floor(($grid-gutter-width / 2));
|
528
585
|
}
|
529
586
|
|
530
587
|
// Form group sizes
|
@@ -534,7 +591,8 @@ input[type="checkbox"] {
|
|
534
591
|
.form-group-lg {
|
535
592
|
@media (min-width: $screen-sm-min) {
|
536
593
|
.control-label {
|
537
|
-
padding-top: (
|
594
|
+
padding-top: ($padding-large-vertical + 1);
|
595
|
+
font-size: $font-size-large;
|
538
596
|
}
|
539
597
|
}
|
540
598
|
}
|
@@ -542,6 +600,7 @@ input[type="checkbox"] {
|
|
542
600
|
@media (min-width: $screen-sm-min) {
|
543
601
|
.control-label {
|
544
602
|
padding-top: ($padding-small-vertical + 1);
|
603
|
+
font-size: $font-size-small;
|
545
604
|
}
|
546
605
|
}
|
547
606
|
}
|