entreprise7pro-bootstrap-sass 3.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (171) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +20 -0
  3. data/.travis.yml +19 -0
  4. data/CHANGELOG.md +233 -0
  5. data/CONTRIBUTING.md +86 -0
  6. data/Gemfile +7 -0
  7. data/LICENSE +22 -0
  8. data/README.md +376 -0
  9. data/Rakefile +98 -0
  10. data/assets/fonts/bootstrap/glyphicons-halflings-regular.eot +0 -0
  11. data/assets/fonts/bootstrap/glyphicons-halflings-regular.svg +288 -0
  12. data/assets/fonts/bootstrap/glyphicons-halflings-regular.ttf +0 -0
  13. data/assets/fonts/bootstrap/glyphicons-halflings-regular.woff +0 -0
  14. data/assets/fonts/bootstrap/glyphicons-halflings-regular.woff2 +0 -0
  15. data/assets/images/.keep +0 -0
  16. data/assets/javascripts/bootstrap/affix.js +166 -0
  17. data/assets/javascripts/bootstrap/alert.js +97 -0
  18. data/assets/javascripts/bootstrap/button.js +136 -0
  19. data/assets/javascripts/bootstrap/carousel.js +248 -0
  20. data/assets/javascripts/bootstrap/collapse.js +214 -0
  21. data/assets/javascripts/bootstrap/dropdown.js +167 -0
  22. data/assets/javascripts/bootstrap/modal.js +356 -0
  23. data/assets/javascripts/bootstrap/popover.js +123 -0
  24. data/assets/javascripts/bootstrap/scrollspy.js +174 -0
  25. data/assets/javascripts/bootstrap/tab.js +157 -0
  26. data/assets/javascripts/bootstrap/tooltip.js +679 -0
  27. data/assets/javascripts/bootstrap/transition.js +61 -0
  28. data/assets/javascripts/bootstrap-sprockets.js +12 -0
  29. data/assets/javascripts/bootstrap.js +2611 -0
  30. data/assets/javascripts/bootstrap.min.js +7 -0
  31. data/assets/javascripts/jquery.min.js +2 -0
  32. data/assets/stylesheets/_bootstrap-compass.scss +9 -0
  33. data/assets/stylesheets/_bootstrap-mincer.scss +19 -0
  34. data/assets/stylesheets/_bootstrap-sprockets.scss +9 -0
  35. data/assets/stylesheets/_bootstrap.scss +56 -0
  36. data/assets/stylesheets/bootstrap/_alerts.scss +73 -0
  37. data/assets/stylesheets/bootstrap/_badges.scss +68 -0
  38. data/assets/stylesheets/bootstrap/_breadcrumbs.scss +28 -0
  39. data/assets/stylesheets/bootstrap/_button-groups.scss +244 -0
  40. data/assets/stylesheets/bootstrap/_buttons.scss +168 -0
  41. data/assets/stylesheets/bootstrap/_carousel.scss +263 -0
  42. data/assets/stylesheets/bootstrap/_close.scss +37 -0
  43. data/assets/stylesheets/bootstrap/_code.scss +70 -0
  44. data/assets/stylesheets/bootstrap/_component-animations.scss +38 -0
  45. data/assets/stylesheets/bootstrap/_dropdowns.scss +212 -0
  46. data/assets/stylesheets/bootstrap/_forms.scss +602 -0
  47. data/assets/stylesheets/bootstrap/_glyphicons.scss +307 -0
  48. data/assets/stylesheets/bootstrap/_grid.scss +94 -0
  49. data/assets/stylesheets/bootstrap/_input-groups.scss +166 -0
  50. data/assets/stylesheets/bootstrap/_jumbotron.scss +55 -0
  51. data/assets/stylesheets/bootstrap/_labels.scss +66 -0
  52. data/assets/stylesheets/bootstrap/_list-group.scss +128 -0
  53. data/assets/stylesheets/bootstrap/_media.scss +66 -0
  54. data/assets/stylesheets/bootstrap/_mixins.scss +39 -0
  55. data/assets/stylesheets/bootstrap/_modals.scss +150 -0
  56. data/assets/stylesheets/bootstrap/_navbar.scss +657 -0
  57. data/assets/stylesheets/bootstrap/_navs.scss +242 -0
  58. data/assets/stylesheets/bootstrap/_normalize.scss +422 -0
  59. data/assets/stylesheets/bootstrap/_pager.scss +54 -0
  60. data/assets/stylesheets/bootstrap/_pagination.scss +86 -0
  61. data/assets/stylesheets/bootstrap/_panels.scss +271 -0
  62. data/assets/stylesheets/bootstrap/_popovers.scss +126 -0
  63. data/assets/stylesheets/bootstrap/_print.scss +99 -0
  64. data/assets/stylesheets/bootstrap/_progress-bars.scss +87 -0
  65. data/assets/stylesheets/bootstrap/_responsive-embed.scss +35 -0
  66. data/assets/stylesheets/bootstrap/_responsive-utilities.scss +157 -0
  67. data/assets/stylesheets/bootstrap/_scaffolding.scss +161 -0
  68. data/assets/stylesheets/bootstrap/_tables.scss +233 -0
  69. data/assets/stylesheets/bootstrap/_theme.scss +293 -0
  70. data/assets/stylesheets/bootstrap/_thumbnails.scss +38 -0
  71. data/assets/stylesheets/bootstrap/_tooltip.scss +112 -0
  72. data/assets/stylesheets/bootstrap/_type.scss +299 -0
  73. data/assets/stylesheets/bootstrap/_utilities.scss +55 -0
  74. data/assets/stylesheets/bootstrap/_variables.scss +875 -0
  75. data/assets/stylesheets/bootstrap/_wells.scss +29 -0
  76. data/assets/stylesheets/bootstrap/mixins/_alerts.scss +15 -0
  77. data/assets/stylesheets/bootstrap/mixins/_background-variant.scss +12 -0
  78. data/assets/stylesheets/bootstrap/mixins/_border-radius.scss +18 -0
  79. data/assets/stylesheets/bootstrap/mixins/_buttons.scss +61 -0
  80. data/assets/stylesheets/bootstrap/mixins/_center-block.scss +7 -0
  81. data/assets/stylesheets/bootstrap/mixins/_clearfix.scss +22 -0
  82. data/assets/stylesheets/bootstrap/mixins/_forms.scss +88 -0
  83. data/assets/stylesheets/bootstrap/mixins/_gradients.scss +50 -0
  84. data/assets/stylesheets/bootstrap/mixins/_grid-framework.scss +82 -0
  85. data/assets/stylesheets/bootstrap/mixins/_grid.scss +123 -0
  86. data/assets/stylesheets/bootstrap/mixins/_hide-text.scss +21 -0
  87. data/assets/stylesheets/bootstrap/mixins/_image.scss +28 -0
  88. data/assets/stylesheets/bootstrap/mixins/_labels.scss +12 -0
  89. data/assets/stylesheets/bootstrap/mixins/_list-group.scss +32 -0
  90. data/assets/stylesheets/bootstrap/mixins/_nav-divider.scss +11 -0
  91. data/assets/stylesheets/bootstrap/mixins/_nav-vertical-align.scss +10 -0
  92. data/assets/stylesheets/bootstrap/mixins/_opacity.scss +7 -0
  93. data/assets/stylesheets/bootstrap/mixins/_pagination.scss +24 -0
  94. data/assets/stylesheets/bootstrap/mixins/_panels.scss +24 -0
  95. data/assets/stylesheets/bootstrap/mixins/_progress-bar.scss +10 -0
  96. data/assets/stylesheets/bootstrap/mixins/_reset-text.scss +18 -0
  97. data/assets/stylesheets/bootstrap/mixins/_resize.scss +6 -0
  98. data/assets/stylesheets/bootstrap/mixins/_responsive-visibility.scss +17 -0
  99. data/assets/stylesheets/bootstrap/mixins/_size.scss +10 -0
  100. data/assets/stylesheets/bootstrap/mixins/_tab-focus.scss +9 -0
  101. data/assets/stylesheets/bootstrap/mixins/_table-row.scss +28 -0
  102. data/assets/stylesheets/bootstrap/mixins/_text-emphasis.scss +12 -0
  103. data/assets/stylesheets/bootstrap/mixins/_text-overflow.scss +8 -0
  104. data/assets/stylesheets/bootstrap/mixins/_vendor-prefixes.scss +210 -0
  105. data/bower.json +38 -0
  106. data/composer.json +21 -0
  107. data/entreprise7pro-bootstrap-sass.gemspec +37 -0
  108. data/eyeglass-exports.js +7 -0
  109. data/lib/entreprise7pro-bootstrap-sass/engine.rb +17 -0
  110. data/lib/entreprise7pro-bootstrap-sass/version.rb +4 -0
  111. data/lib/entreprise7pro-bootstrap-sass.rb +91 -0
  112. data/package-lock.json +1011 -0
  113. data/package.json +48 -0
  114. data/sache.json +5 -0
  115. data/tasks/bower.rake +31 -0
  116. data/tasks/converter/char_string_scanner.rb +38 -0
  117. data/tasks/converter/fonts_conversion.rb +16 -0
  118. data/tasks/converter/js_conversion.rb +47 -0
  119. data/tasks/converter/less_conversion.rb +752 -0
  120. data/tasks/converter/logger.rb +57 -0
  121. data/tasks/converter/network.rb +97 -0
  122. data/tasks/converter.rb +80 -0
  123. data/templates/project/_bootstrap-variables.sass +876 -0
  124. data/templates/project/manifest.rb +20 -0
  125. data/templates/project/styles.sass +6 -0
  126. data/test/compilation_test.rb +30 -0
  127. data/test/dummy_node_mincer/apple-touch-icon-144-precomposed.png +0 -0
  128. data/test/dummy_node_mincer/application.css.ejs.scss +6 -0
  129. data/test/dummy_node_mincer/manifest.js +87 -0
  130. data/test/dummy_rails/README.rdoc +3 -0
  131. data/test/dummy_rails/Rakefile +6 -0
  132. data/test/dummy_rails/app/assets/images/.keep +0 -0
  133. data/test/dummy_rails/app/assets/javascripts/application.js +2 -0
  134. data/test/dummy_rails/app/assets/stylesheets/application.sass +2 -0
  135. data/test/dummy_rails/app/controllers/application_controller.rb +5 -0
  136. data/test/dummy_rails/app/controllers/pages_controller.rb +4 -0
  137. data/test/dummy_rails/app/helpers/application_helper.rb +2 -0
  138. data/test/dummy_rails/app/views/layouts/application.html.erb +14 -0
  139. data/test/dummy_rails/app/views/pages/root.html.slim +84 -0
  140. data/test/dummy_rails/config/application.rb +31 -0
  141. data/test/dummy_rails/config/boot.rb +5 -0
  142. data/test/dummy_rails/config/environment.rb +5 -0
  143. data/test/dummy_rails/config/environments/development.rb +23 -0
  144. data/test/dummy_rails/config/environments/production.rb +82 -0
  145. data/test/dummy_rails/config/environments/test.rb +38 -0
  146. data/test/dummy_rails/config/initializers/backtrace_silencers.rb +7 -0
  147. data/test/dummy_rails/config/initializers/filter_parameter_logging.rb +4 -0
  148. data/test/dummy_rails/config/initializers/inflections.rb +16 -0
  149. data/test/dummy_rails/config/initializers/mime_types.rb +5 -0
  150. data/test/dummy_rails/config/initializers/secret_token.rb +18 -0
  151. data/test/dummy_rails/config/initializers/session_store.rb +3 -0
  152. data/test/dummy_rails/config/initializers/wrap_parameters.rb +14 -0
  153. data/test/dummy_rails/config/locales/en.yml +3 -0
  154. data/test/dummy_rails/config/locales/es.yml +3 -0
  155. data/test/dummy_rails/config/routes.rb +3 -0
  156. data/test/dummy_rails/config.ru +4 -0
  157. data/test/dummy_rails/log/.keep +0 -0
  158. data/test/dummy_sass_only/Gemfile +4 -0
  159. data/test/dummy_sass_only/compile.rb +20 -0
  160. data/test/dummy_sass_only/import_all.scss +2 -0
  161. data/test/gemfiles/default.gemfile +3 -0
  162. data/test/node_mincer_test.rb +35 -0
  163. data/test/node_sass_compile_test.sh +9 -0
  164. data/test/pages_test.rb +14 -0
  165. data/test/sass_test.rb +29 -0
  166. data/test/sprockets_rails_test.rb +31 -0
  167. data/test/support/dummy_rails_integration.rb +22 -0
  168. data/test/support/reporting.rb +27 -0
  169. data/test/test_helper.rb +36 -0
  170. data/test/test_helper_rails.rb +6 -0
  171. metadata +467 -0
@@ -0,0 +1,602 @@
1
+ @use "sass:math";
2
+ //
3
+ // Forms
4
+ // --------------------------------------------------
5
+
6
+
7
+ // Normalize non-controls
8
+ //
9
+ // Restyle and baseline non-control form elements.
10
+
11
+ fieldset {
12
+ // Chrome and Firefox set a `min-width: min-content;` on fieldsets,
13
+ // so we reset that to ensure it behaves more like a standard block element.
14
+ // See https://github.com/twbs/bootstrap/issues/12359.
15
+ min-width: 0;
16
+ padding: 0;
17
+ margin: 0;
18
+ border: 0;
19
+ }
20
+
21
+ legend {
22
+ display: block;
23
+ width: 100%;
24
+ padding: 0;
25
+ margin-bottom: $line-height-computed;
26
+ font-size: ($font-size-base * 1.5);
27
+ line-height: inherit;
28
+ color: $legend-color;
29
+ border: 0;
30
+ border-bottom: 1px solid $legend-border-color;
31
+ }
32
+
33
+ label {
34
+ display: inline-block;
35
+ max-width: 100%;
36
+ margin-bottom: 5px;
37
+ font-weight: 700;
38
+ }
39
+
40
+
41
+ // Normalize form controls
42
+ //
43
+ // While most of our form styles require extra classes, some basic normalization
44
+ // is required to ensure optimum display with or without those classes to better
45
+ // address browser inconsistencies.
46
+
47
+ input[type="search"] {
48
+ // Override content-box in Normalize (* isn't specific enough)
49
+ @include box-sizing(border-box);
50
+
51
+ // Search inputs in iOS
52
+ //
53
+ // This overrides the extra rounded corners on search inputs in iOS so that our
54
+ // `.form-control` class can properly style them. Note that this cannot simply
55
+ // be added to `.form-control` as it's not specific enough. For details, see
56
+ // https://github.com/twbs/bootstrap/issues/11586.
57
+ -webkit-appearance: none;
58
+ appearance: none;
59
+ }
60
+
61
+ // Position radios and checkboxes better
62
+ input[type="radio"],
63
+ input[type="checkbox"] {
64
+ margin: 4px 0 0;
65
+ margin-top: 1px \9;
66
+ line-height: normal;
67
+
68
+ // Apply same disabled cursor tweak as for inputs
69
+ // Some special care is needed because <label>s don't inherit their parent's `cursor`.
70
+ //
71
+ // Note: Neither radios nor checkboxes can be readonly.
72
+ &[disabled],
73
+ &.disabled,
74
+ fieldset[disabled] & {
75
+ cursor: $cursor-disabled;
76
+ }
77
+ }
78
+
79
+ input[type="file"] {
80
+ display: block;
81
+ }
82
+
83
+ // Make range inputs behave like textual form controls
84
+ input[type="range"] {
85
+ display: block;
86
+ width: 100%;
87
+ }
88
+
89
+ // Make multiple select elements height not fixed
90
+ select[multiple],
91
+ select[size] {
92
+ height: auto;
93
+ }
94
+
95
+ // Focus for file, radio, and checkbox
96
+ input[type="file"]:focus,
97
+ input[type="radio"]:focus,
98
+ input[type="checkbox"]:focus {
99
+ @include tab-focus;
100
+ }
101
+
102
+ // Adjust output element
103
+ output {
104
+ display: block;
105
+ padding-top: ($padding-base-vertical + 1);
106
+ font-size: $font-size-base;
107
+ line-height: $line-height-base;
108
+ color: $input-color;
109
+ }
110
+
111
+
112
+ // Common form controls
113
+ //
114
+ // Shared size and type resets for form controls. Apply `.form-control` to any
115
+ // of the following form controls:
116
+ //
117
+ // select
118
+ // textarea
119
+ // input[type="text"]
120
+ // input[type="password"]
121
+ // input[type="datetime"]
122
+ // input[type="datetime-local"]
123
+ // input[type="date"]
124
+ // input[type="month"]
125
+ // input[type="time"]
126
+ // input[type="week"]
127
+ // input[type="number"]
128
+ // input[type="email"]
129
+ // input[type="url"]
130
+ // input[type="search"]
131
+ // input[type="tel"]
132
+ // input[type="color"]
133
+
134
+ .form-control {
135
+ display: block;
136
+ width: 100%;
137
+ height: $input-height-base; // Make inputs at least the height of their button counterpart (base line-height + padding + border)
138
+ padding: $padding-base-vertical $padding-base-horizontal;
139
+ font-size: $font-size-base;
140
+ line-height: $line-height-base;
141
+ color: $input-color;
142
+ background-color: $input-bg;
143
+ background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
144
+ border: 1px solid $input-border;
145
+ 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.
146
+ @include box-shadow(inset 0 1px 1px rgba(0, 0, 0, .075));
147
+ @include transition(border-color ease-in-out .15s, box-shadow ease-in-out .15s);
148
+
149
+ // Customize the `:focus` state to imitate native WebKit styles.
150
+ @include form-control-focus;
151
+
152
+ // Placeholder
153
+ @include placeholder;
154
+
155
+ // Disabled and read-only inputs
156
+ //
157
+ // HTML5 says that controls under a fieldset > legend:first-child won't be
158
+ // disabled if the fieldset is disabled. Due to implementation difficulty, we
159
+ // don't honor that edge case; we style them as disabled anyway.
160
+ &[disabled],
161
+ &[readonly],
162
+ fieldset[disabled] & {
163
+ background-color: $input-bg-disabled;
164
+ opacity: 1; // iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655
165
+ }
166
+
167
+ &[disabled],
168
+ fieldset[disabled] & {
169
+ cursor: $cursor-disabled;
170
+ }
171
+
172
+ // [converter] extracted textarea& to textarea.form-control
173
+ }
174
+
175
+ // Reset height for `textarea`s
176
+ textarea.form-control {
177
+ height: auto;
178
+ }
179
+
180
+
181
+ // Special styles for iOS temporal inputs
182
+ //
183
+ // In Mobile Safari, setting `display: block` on temporal inputs causes the
184
+ // text within the input to become vertically misaligned. As a workaround, we
185
+ // set a pixel line-height that matches the given height of the input, but only
186
+ // for Safari. See https://bugs.webkit.org/show_bug.cgi?id=139848
187
+ //
188
+ // Note that as of 9.3, iOS doesn't support `week`.
189
+
190
+ @media screen and (-webkit-min-device-pixel-ratio: 0) {
191
+ input[type="date"],
192
+ input[type="time"],
193
+ input[type="datetime-local"],
194
+ input[type="month"] {
195
+ &.form-control {
196
+ line-height: $input-height-base;
197
+ }
198
+
199
+ &.input-sm,
200
+ .input-group-sm & {
201
+ line-height: $input-height-small;
202
+ }
203
+
204
+ &.input-lg,
205
+ .input-group-lg & {
206
+ line-height: $input-height-large;
207
+ }
208
+ }
209
+ }
210
+
211
+
212
+ // Form groups
213
+ //
214
+ // Designed to help with the organization and spacing of vertical forms. For
215
+ // horizontal forms, use the predefined grid classes.
216
+
217
+ .form-group {
218
+ margin-bottom: $form-group-margin-bottom;
219
+ }
220
+
221
+
222
+ // Checkboxes and radios
223
+ //
224
+ // Indent the labels to position radios/checkboxes as hanging controls.
225
+
226
+ .radio,
227
+ .checkbox {
228
+ position: relative;
229
+ display: block;
230
+ margin-top: 10px;
231
+ margin-bottom: 10px;
232
+
233
+ // These are used on elements with <label> descendants
234
+ &.disabled,
235
+ fieldset[disabled] & {
236
+ label {
237
+ cursor: $cursor-disabled;
238
+ }
239
+ }
240
+
241
+ label {
242
+ min-height: $line-height-computed; // Ensure the input doesn't jump when there is no text
243
+ padding-left: 20px;
244
+ margin-bottom: 0;
245
+ font-weight: 400;
246
+ cursor: pointer;
247
+ }
248
+ }
249
+ .radio input[type="radio"],
250
+ .radio-inline input[type="radio"],
251
+ .checkbox input[type="checkbox"],
252
+ .checkbox-inline input[type="checkbox"] {
253
+ position: absolute;
254
+ margin-top: 4px \9;
255
+ margin-left: -20px;
256
+ }
257
+
258
+ .radio + .radio,
259
+ .checkbox + .checkbox {
260
+ margin-top: -5px; // Move up sibling radios or checkboxes for tighter spacing
261
+ }
262
+
263
+ // Radios and checkboxes on same line
264
+ .radio-inline,
265
+ .checkbox-inline {
266
+ position: relative;
267
+ display: inline-block;
268
+ padding-left: 20px;
269
+ margin-bottom: 0;
270
+ font-weight: 400;
271
+ vertical-align: middle;
272
+ cursor: pointer;
273
+
274
+ // These are used directly on <label>s
275
+ &.disabled,
276
+ fieldset[disabled] & {
277
+ cursor: $cursor-disabled;
278
+ }
279
+ }
280
+ .radio-inline + .radio-inline,
281
+ .checkbox-inline + .checkbox-inline {
282
+ margin-top: 0;
283
+ margin-left: 10px; // space out consecutive inline controls
284
+ }
285
+
286
+
287
+ // Static form control text
288
+ //
289
+ // Apply class to a `p` element to make any string of text align with labels in
290
+ // a horizontal form layout.
291
+
292
+ .form-control-static {
293
+ min-height: ($line-height-computed + $font-size-base);
294
+ // Size it appropriately next to real form controls
295
+ padding-top: ($padding-base-vertical + 1);
296
+ padding-bottom: ($padding-base-vertical + 1);
297
+ // Remove default margin from `p`
298
+ margin-bottom: 0;
299
+
300
+ &.input-lg,
301
+ &.input-sm {
302
+ padding-right: 0;
303
+ padding-left: 0;
304
+ }
305
+ }
306
+
307
+
308
+ // Form control sizing
309
+ //
310
+ // Build on `.form-control` with modifier classes to decrease or increase the
311
+ // height and font-size of form controls.
312
+ //
313
+ // The `.form-group-* form-control` variations are sadly duplicated to avoid the
314
+ // issue documented in https://github.com/twbs/bootstrap/issues/15074.
315
+
316
+ @include input-size('.input-sm', $input-height-small, $padding-small-vertical, $padding-small-horizontal, $font-size-small, $line-height-small, $input-border-radius-small);
317
+ .form-group-sm {
318
+ .form-control {
319
+ height: $input-height-small;
320
+ padding: $padding-small-vertical $padding-small-horizontal;
321
+ font-size: $font-size-small;
322
+ line-height: $line-height-small;
323
+ border-radius: $input-border-radius-small;
324
+ }
325
+ select.form-control {
326
+ height: $input-height-small;
327
+ line-height: $input-height-small;
328
+ }
329
+ textarea.form-control,
330
+ select[multiple].form-control {
331
+ height: auto;
332
+ }
333
+ .form-control-static {
334
+ height: $input-height-small;
335
+ min-height: ($line-height-computed + $font-size-small);
336
+ padding: ($padding-small-vertical + 1) $padding-small-horizontal;
337
+ font-size: $font-size-small;
338
+ line-height: $line-height-small;
339
+ }
340
+ }
341
+
342
+ @include input-size('.input-lg', $input-height-large, $padding-large-vertical, $padding-large-horizontal, $font-size-large, $line-height-large, $input-border-radius-large);
343
+ .form-group-lg {
344
+ .form-control {
345
+ height: $input-height-large;
346
+ padding: $padding-large-vertical $padding-large-horizontal;
347
+ font-size: $font-size-large;
348
+ line-height: $line-height-large;
349
+ border-radius: $input-border-radius-large;
350
+ }
351
+ select.form-control {
352
+ height: $input-height-large;
353
+ line-height: $input-height-large;
354
+ }
355
+ textarea.form-control,
356
+ select[multiple].form-control {
357
+ height: auto;
358
+ }
359
+ .form-control-static {
360
+ height: $input-height-large;
361
+ min-height: ($line-height-computed + $font-size-large);
362
+ padding: ($padding-large-vertical + 1) $padding-large-horizontal;
363
+ font-size: $font-size-large;
364
+ line-height: $line-height-large;
365
+ }
366
+ }
367
+
368
+
369
+ // Form control feedback states
370
+ //
371
+ // Apply contextual and semantic states to individual form controls.
372
+
373
+ .has-feedback {
374
+ // Enable absolute positioning
375
+ position: relative;
376
+
377
+ // Ensure icons don't overlap text
378
+ .form-control {
379
+ padding-right: ($input-height-base * 1.25);
380
+ }
381
+ }
382
+ // Feedback icon (requires .glyphicon classes)
383
+ .form-control-feedback {
384
+ position: absolute;
385
+ top: 0;
386
+ right: 0;
387
+ z-index: 2; // Ensure icon is above input groups
388
+ display: block;
389
+ width: $input-height-base;
390
+ height: $input-height-base;
391
+ line-height: $input-height-base;
392
+ text-align: center;
393
+ pointer-events: none;
394
+ }
395
+ .input-lg + .form-control-feedback,
396
+ .input-group-lg + .form-control-feedback,
397
+ .form-group-lg .form-control + .form-control-feedback {
398
+ width: $input-height-large;
399
+ height: $input-height-large;
400
+ line-height: $input-height-large;
401
+ }
402
+ .input-sm + .form-control-feedback,
403
+ .input-group-sm + .form-control-feedback,
404
+ .form-group-sm .form-control + .form-control-feedback {
405
+ width: $input-height-small;
406
+ height: $input-height-small;
407
+ line-height: $input-height-small;
408
+ }
409
+
410
+ // Feedback states
411
+ .has-success {
412
+ @include form-control-validation($state-success-text, $state-success-text, $state-success-bg);
413
+ }
414
+ .has-warning {
415
+ @include form-control-validation($state-warning-text, $state-warning-text, $state-warning-bg);
416
+ }
417
+ .has-error {
418
+ @include form-control-validation($state-danger-text, $state-danger-text, $state-danger-bg);
419
+ }
420
+
421
+ // Reposition feedback icon if input has visible label above
422
+ .has-feedback label {
423
+
424
+ & ~ .form-control-feedback {
425
+ top: ($line-height-computed + 5); // Height of the `label` and its margin
426
+ }
427
+ &.sr-only ~ .form-control-feedback {
428
+ top: 0;
429
+ }
430
+ }
431
+
432
+
433
+ // Help text
434
+ //
435
+ // Apply to any element you wish to create light text for placement immediately
436
+ // below a form control. Use for general help, formatting, or instructional text.
437
+
438
+ .help-block {
439
+ display: block; // account for any element using help-block
440
+ margin-top: 5px;
441
+ margin-bottom: 10px;
442
+ color: lighten($text-color, 25%); // lighten the text some for contrast
443
+ }
444
+
445
+
446
+ // Inline forms
447
+ //
448
+ // Make forms appear inline(-block) by adding the `.form-inline` class. Inline
449
+ // forms begin stacked on extra small (mobile) devices and then go inline when
450
+ // viewports reach <768px.
451
+ //
452
+ // Requires wrapping inputs and labels with `.form-group` for proper display of
453
+ // default HTML form controls and our custom form controls (e.g., input groups).
454
+ //
455
+ // Heads up! This is mixin-ed into `.navbar-form` in navbars.less.
456
+
457
+ // [converter] extracted from `.form-inline` for libsass compatibility
458
+ @mixin form-inline {
459
+
460
+ // Kick in the inline
461
+ @media (min-width: $screen-sm-min) {
462
+ // Inline-block all the things for "inline"
463
+ .form-group {
464
+ display: inline-block;
465
+ margin-bottom: 0;
466
+ vertical-align: middle;
467
+ }
468
+
469
+ // In navbar-form, allow folks to *not* use `.form-group`
470
+ .form-control {
471
+ display: inline-block;
472
+ width: auto; // Prevent labels from stacking above inputs in `.form-group`
473
+ vertical-align: middle;
474
+ }
475
+
476
+ // Make static controls behave like regular ones
477
+ .form-control-static {
478
+ display: inline-block;
479
+ }
480
+
481
+ .input-group {
482
+ display: inline-table;
483
+ vertical-align: middle;
484
+
485
+ .input-group-addon,
486
+ .input-group-btn,
487
+ .form-control {
488
+ width: auto;
489
+ }
490
+ }
491
+
492
+ // Input groups need that 100% width though
493
+ .input-group > .form-control {
494
+ width: 100%;
495
+ }
496
+
497
+ .control-label {
498
+ margin-bottom: 0;
499
+ vertical-align: middle;
500
+ }
501
+
502
+ // Remove default margin on radios/checkboxes that were used for stacking, and
503
+ // then undo the floating of radios and checkboxes to match.
504
+ .radio,
505
+ .checkbox {
506
+ display: inline-block;
507
+ margin-top: 0;
508
+ margin-bottom: 0;
509
+ vertical-align: middle;
510
+
511
+ label {
512
+ padding-left: 0;
513
+ }
514
+ }
515
+ .radio input[type="radio"],
516
+ .checkbox input[type="checkbox"] {
517
+ position: relative;
518
+ margin-left: 0;
519
+ }
520
+
521
+ // Re-override the feedback icon.
522
+ .has-feedback .form-control-feedback {
523
+ top: 0;
524
+ }
525
+ }
526
+ }
527
+ // [converter] extracted as `@mixin form-inline` for libsass compatibility
528
+ .form-inline {
529
+ @include form-inline;
530
+ }
531
+
532
+
533
+
534
+ // Horizontal forms
535
+ //
536
+ // Horizontal forms are built on grid classes and allow you to create forms with
537
+ // labels on the left and inputs on the right.
538
+
539
+ .form-horizontal {
540
+
541
+ // Consistent vertical alignment of radios and checkboxes
542
+ //
543
+ // Labels also get some reset styles, but that is scoped to a media query below.
544
+ .radio,
545
+ .checkbox,
546
+ .radio-inline,
547
+ .checkbox-inline {
548
+ padding-top: ($padding-base-vertical + 1); // Default padding plus a border
549
+ margin-top: 0;
550
+ margin-bottom: 0;
551
+ }
552
+ // Account for padding we're adding to ensure the alignment and of help text
553
+ // and other content below items
554
+ .radio,
555
+ .checkbox {
556
+ min-height: ($line-height-computed + ($padding-base-vertical + 1));
557
+ }
558
+
559
+ // Make form groups behave like rows
560
+ .form-group {
561
+ @include make-row;
562
+ }
563
+
564
+ // Reset spacing and right align labels, but scope to media queries so that
565
+ // labels on narrow viewports stack the same as a default form example.
566
+ @media (min-width: $screen-sm-min) {
567
+ .control-label {
568
+ padding-top: ($padding-base-vertical + 1); // Default padding plus a border
569
+ margin-bottom: 0;
570
+ text-align: right;
571
+ }
572
+ }
573
+
574
+ // Validation states
575
+ //
576
+ // Reposition the icon because it's now within a grid column and columns have
577
+ // `position: relative;` on them. Also accounts for the grid gutter padding.
578
+ .has-feedback .form-control-feedback {
579
+ right: floor(math.div($grid-gutter-width, 2));
580
+ }
581
+
582
+ // Form group sizes
583
+ //
584
+ // Quick utility class for applying `.input-lg` and `.input-sm` styles to the
585
+ // inputs and labels within a `.form-group`.
586
+ .form-group-lg {
587
+ @media (min-width: $screen-sm-min) {
588
+ .control-label {
589
+ padding-top: ($padding-large-vertical + 1);
590
+ font-size: $font-size-large;
591
+ }
592
+ }
593
+ }
594
+ .form-group-sm {
595
+ @media (min-width: $screen-sm-min) {
596
+ .control-label {
597
+ padding-top: ($padding-small-vertical + 1);
598
+ font-size: $font-size-small;
599
+ }
600
+ }
601
+ }
602
+ }