flatstrap-sass 2.3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +14 -0
- data/README.md +52 -0
- data/lib/flatstrap-sass.rb +51 -0
- data/lib/flatstrap-sass/compass_functions.rb +19 -0
- data/lib/flatstrap-sass/engine.rb +7 -0
- data/lib/flatstrap-sass/sass_functions.rb +14 -0
- data/templates/project/manifest.rb +13 -0
- data/templates/project/styles.scss +5 -0
- data/vendor/assets/javascripts/application.js +154 -0
- data/vendor/assets/javascripts/bootstrap-affix.js +117 -0
- data/vendor/assets/javascripts/bootstrap-alert.js +99 -0
- data/vendor/assets/javascripts/bootstrap-button.js +105 -0
- data/vendor/assets/javascripts/bootstrap-carousel.js +207 -0
- data/vendor/assets/javascripts/bootstrap-collapse.js +167 -0
- data/vendor/assets/javascripts/bootstrap-dropdown.js +165 -0
- data/vendor/assets/javascripts/bootstrap-modal.js +247 -0
- data/vendor/assets/javascripts/bootstrap-popover.js +114 -0
- data/vendor/assets/javascripts/bootstrap-scrollspy.js +162 -0
- data/vendor/assets/javascripts/bootstrap-tab.js +144 -0
- data/vendor/assets/javascripts/bootstrap-tooltip.js +361 -0
- data/vendor/assets/javascripts/bootstrap-transition.js +60 -0
- data/vendor/assets/javascripts/bootstrap-typeahead.js +335 -0
- data/vendor/assets/javascripts/bootstrap.js +2159 -0
- data/vendor/assets/javascripts/bootstrap.min.js +6 -0
- data/vendor/assets/javascripts/google-code-prettify/prettify.js +28 -0
- data/vendor/assets/javascripts/jquery.js +2 -0
- data/vendor/assets/stylesheets/flatstrap-responsive.scss +1 -0
- data/vendor/assets/stylesheets/flatstrap.scss +1 -0
- data/vendor/assets/stylesheets/flatstrap/_accordion.scss +33 -0
- data/vendor/assets/stylesheets/flatstrap/_alerts.scss +78 -0
- data/vendor/assets/stylesheets/flatstrap/_breadcrumbs.scss +23 -0
- data/vendor/assets/stylesheets/flatstrap/_button-groups.scss +211 -0
- data/vendor/assets/stylesheets/flatstrap/_buttons.scss +215 -0
- data/vendor/assets/stylesheets/flatstrap/_carousel.scss +156 -0
- data/vendor/assets/stylesheets/flatstrap/_close.scss +32 -0
- data/vendor/assets/stylesheets/flatstrap/_code.scss +59 -0
- data/vendor/assets/stylesheets/flatstrap/_component-animations.scss +22 -0
- data/vendor/assets/stylesheets/flatstrap/_dropdowns.scss +231 -0
- data/vendor/assets/stylesheets/flatstrap/_font-awesome.scss +534 -0
- data/vendor/assets/stylesheets/flatstrap/_forms.scss +646 -0
- data/vendor/assets/stylesheets/flatstrap/_grid.scss +21 -0
- data/vendor/assets/stylesheets/flatstrap/_hero-unit.scss +24 -0
- data/vendor/assets/stylesheets/flatstrap/_labels-badges.scss +79 -0
- data/vendor/assets/stylesheets/flatstrap/_layouts.scss +16 -0
- data/vendor/assets/stylesheets/flatstrap/_media.scss +55 -0
- data/vendor/assets/stylesheets/flatstrap/_mixins.scss +654 -0
- data/vendor/assets/stylesheets/flatstrap/_modals.scss +91 -0
- data/vendor/assets/stylesheets/flatstrap/_navbar.scss +481 -0
- data/vendor/assets/stylesheets/flatstrap/_navs.scss +388 -0
- data/vendor/assets/stylesheets/flatstrap/_pager.scss +42 -0
- data/vendor/assets/stylesheets/flatstrap/_pagination.scss +94 -0
- data/vendor/assets/stylesheets/flatstrap/_popovers.scss +130 -0
- data/vendor/assets/stylesheets/flatstrap/_progress-bars.scss +118 -0
- data/vendor/assets/stylesheets/flatstrap/_reset.scss +216 -0
- data/vendor/assets/stylesheets/flatstrap/_responsive-1200px-min.scss +28 -0
- data/vendor/assets/stylesheets/flatstrap/_responsive-767px-max.scss +193 -0
- data/vendor/assets/stylesheets/flatstrap/_responsive-768px-979px.scss +19 -0
- data/vendor/assets/stylesheets/flatstrap/_responsive-navbar.scss +184 -0
- data/vendor/assets/stylesheets/flatstrap/_responsive-utilities.scss +74 -0
- data/vendor/assets/stylesheets/flatstrap/_scaffolding.scss +42 -0
- data/vendor/assets/stylesheets/flatstrap/_tables.scss +183 -0
- data/vendor/assets/stylesheets/flatstrap/_thumbnails.scss +50 -0
- data/vendor/assets/stylesheets/flatstrap/_tooltip.scss +69 -0
- data/vendor/assets/stylesheets/flatstrap/_type.scss +247 -0
- data/vendor/assets/stylesheets/flatstrap/_utilities.scss +45 -0
- data/vendor/assets/stylesheets/flatstrap/_variables.scss +296 -0
- data/vendor/assets/stylesheets/flatstrap/_wells.scss +25 -0
- data/vendor/assets/stylesheets/flatstrap/bootstrap-responsive.scss +48 -0
- data/vendor/assets/stylesheets/flatstrap/bootstrap.scss +63 -0
- metadata +180 -0
@@ -0,0 +1,646 @@
|
|
1
|
+
//
|
2
|
+
// Forms
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// GENERAL STYLES
|
7
|
+
// --------------
|
8
|
+
|
9
|
+
// Make all forms have space below them
|
10
|
+
form {
|
11
|
+
margin: 0 0 $baseLineHeight;
|
12
|
+
}
|
13
|
+
|
14
|
+
// insure no borders on mobile safari
|
15
|
+
input[type="checkbox"] {
|
16
|
+
-webkit-appearance: checkbox;
|
17
|
+
border-radius: 0;
|
18
|
+
}
|
19
|
+
input[type="radio"] {
|
20
|
+
-webkit-appearance: radio;
|
21
|
+
border-radius: 0;
|
22
|
+
}
|
23
|
+
|
24
|
+
fieldset {
|
25
|
+
padding: 0;
|
26
|
+
margin: 0;
|
27
|
+
border: 0;
|
28
|
+
}
|
29
|
+
|
30
|
+
// Groups of fields with labels on top (legends)
|
31
|
+
legend {
|
32
|
+
display: block;
|
33
|
+
width: 100%;
|
34
|
+
padding: 0;
|
35
|
+
margin-bottom: $baseLineHeight;
|
36
|
+
font-size: $baseFontSize * 1.5;
|
37
|
+
line-height: $baseLineHeight * 2;
|
38
|
+
color: $grayDark;
|
39
|
+
border: 0;
|
40
|
+
border-bottom: 1px solid #e5e5e5;
|
41
|
+
|
42
|
+
// Small
|
43
|
+
small {
|
44
|
+
font-size: $baseLineHeight * .75;
|
45
|
+
color: $grayLight;
|
46
|
+
}
|
47
|
+
}
|
48
|
+
|
49
|
+
// Set font for forms
|
50
|
+
label,
|
51
|
+
input,
|
52
|
+
button,
|
53
|
+
select,
|
54
|
+
textarea {
|
55
|
+
@include font-shorthand($baseFontSize, normal, $baseLineHeight); // Set size, weight, line-height here
|
56
|
+
}
|
57
|
+
input,
|
58
|
+
button,
|
59
|
+
select,
|
60
|
+
textarea {
|
61
|
+
font-family: $baseFontFamily; // And only set font-family here for those that need it (note the missing label element)
|
62
|
+
}
|
63
|
+
|
64
|
+
// Identify controls by their labels
|
65
|
+
label {
|
66
|
+
display: block;
|
67
|
+
margin-bottom: 5px;
|
68
|
+
}
|
69
|
+
|
70
|
+
// Form controls
|
71
|
+
// -------------------------
|
72
|
+
|
73
|
+
// Shared size and type resets
|
74
|
+
select,
|
75
|
+
textarea,
|
76
|
+
input[type="text"],
|
77
|
+
input[type="password"],
|
78
|
+
input[type="datetime"],
|
79
|
+
input[type="datetime-local"],
|
80
|
+
input[type="date"],
|
81
|
+
input[type="month"],
|
82
|
+
input[type="time"],
|
83
|
+
input[type="week"],
|
84
|
+
input[type="number"],
|
85
|
+
input[type="email"],
|
86
|
+
input[type="url"],
|
87
|
+
input[type="search"],
|
88
|
+
input[type="tel"],
|
89
|
+
input[type="color"],
|
90
|
+
.uneditable-input {
|
91
|
+
display: inline-block;
|
92
|
+
height: $baseLineHeight;
|
93
|
+
padding: 4px 6px;
|
94
|
+
margin-bottom: $baseLineHeight / 2;;
|
95
|
+
font-size: $baseFontSize;
|
96
|
+
line-height: $baseLineHeight;
|
97
|
+
color: $gray;
|
98
|
+
vertical-align: middle;
|
99
|
+
}
|
100
|
+
|
101
|
+
// Reset appearance properties for textual inputs and textarea
|
102
|
+
// Declare width for legacy (can't be on input[type=*] selectors or it's too specific)
|
103
|
+
input,
|
104
|
+
textarea,
|
105
|
+
.uneditable-input {
|
106
|
+
width: 206px; // plus 12px padding and 2px border
|
107
|
+
}
|
108
|
+
// Reset height since textareas have rows
|
109
|
+
textarea {
|
110
|
+
height: auto;
|
111
|
+
}
|
112
|
+
// Everything else
|
113
|
+
textarea,
|
114
|
+
input[type="text"],
|
115
|
+
input[type="password"],
|
116
|
+
input[type="datetime"],
|
117
|
+
input[type="datetime-local"],
|
118
|
+
input[type="date"],
|
119
|
+
input[type="month"],
|
120
|
+
input[type="time"],
|
121
|
+
input[type="week"],
|
122
|
+
input[type="number"],
|
123
|
+
input[type="email"],
|
124
|
+
input[type="url"],
|
125
|
+
input[type="search"],
|
126
|
+
input[type="tel"],
|
127
|
+
input[type="color"],
|
128
|
+
.uneditable-input {
|
129
|
+
background-color: $inputBackground;
|
130
|
+
border: 1px solid $inputBorder;
|
131
|
+
@include transition(border linear .2s, box-shadow linear .2s);
|
132
|
+
|
133
|
+
// Focus state
|
134
|
+
&:focus {
|
135
|
+
border-color: rgba(82,168,236,.8);
|
136
|
+
outline: 0;
|
137
|
+
outline: thin dotted \9; /* IE6-9 */
|
138
|
+
}
|
139
|
+
}
|
140
|
+
|
141
|
+
// Position radios and checkboxes better
|
142
|
+
input[type="radio"],
|
143
|
+
input[type="checkbox"] {
|
144
|
+
margin: 4px 0 0;
|
145
|
+
*margin-top: 0; /* IE7 */
|
146
|
+
margin-top: 1px \9; /* IE8-9 */
|
147
|
+
line-height: normal;
|
148
|
+
}
|
149
|
+
|
150
|
+
// Reset width of input images, buttons, radios, checkboxes
|
151
|
+
input[type="file"],
|
152
|
+
input[type="image"],
|
153
|
+
input[type="submit"],
|
154
|
+
input[type="reset"],
|
155
|
+
input[type="button"],
|
156
|
+
input[type="radio"],
|
157
|
+
input[type="checkbox"] {
|
158
|
+
width: auto; // Override of generic input selector
|
159
|
+
}
|
160
|
+
|
161
|
+
// Set the height of select and file controls to match text inputs
|
162
|
+
select,
|
163
|
+
input[type="file"] {
|
164
|
+
height: $inputHeight; /* In IE7, the height of the select element cannot be changed by height, only font-size */
|
165
|
+
*margin-top: 4px; /* For IE7, add top margin to align select with labels */
|
166
|
+
line-height: $inputHeight;
|
167
|
+
}
|
168
|
+
|
169
|
+
// Make select elements obey height by applying a border
|
170
|
+
select {
|
171
|
+
width: 220px; // default input width + 10px of padding that doesn't get applied
|
172
|
+
border: 1px solid $inputBorder;
|
173
|
+
background-color: $inputBackground; // Chrome on Linux and Mobile Safari need background-color
|
174
|
+
}
|
175
|
+
|
176
|
+
// Make multiple select elements height not fixed
|
177
|
+
select[multiple],
|
178
|
+
select[size] {
|
179
|
+
height: auto;
|
180
|
+
}
|
181
|
+
|
182
|
+
// Focus for select, file, radio, and checkbox
|
183
|
+
select:focus,
|
184
|
+
input[type="file"]:focus,
|
185
|
+
input[type="radio"]:focus,
|
186
|
+
input[type="checkbox"]:focus {
|
187
|
+
@include tab-focus();
|
188
|
+
}
|
189
|
+
|
190
|
+
|
191
|
+
// Uneditable inputs
|
192
|
+
// -------------------------
|
193
|
+
|
194
|
+
// Make uneditable inputs look inactive
|
195
|
+
.uneditable-input,
|
196
|
+
.uneditable-textarea {
|
197
|
+
color: $grayLight;
|
198
|
+
background-color: darken($inputBackground, 1%);
|
199
|
+
border-color: $inputBorder;
|
200
|
+
cursor: not-allowed;
|
201
|
+
}
|
202
|
+
|
203
|
+
// For text that needs to appear as an input but should not be an input
|
204
|
+
.uneditable-input {
|
205
|
+
overflow: hidden; // prevent text from wrapping, but still cut it off like an input does
|
206
|
+
white-space: nowrap;
|
207
|
+
}
|
208
|
+
|
209
|
+
// Make uneditable textareas behave like a textarea
|
210
|
+
.uneditable-textarea {
|
211
|
+
width: auto;
|
212
|
+
height: auto;
|
213
|
+
}
|
214
|
+
|
215
|
+
|
216
|
+
// Placeholder
|
217
|
+
// -------------------------
|
218
|
+
|
219
|
+
// Placeholder text gets special styles because when browsers invalidate entire lines if it doesn't understand a selector
|
220
|
+
input,
|
221
|
+
textarea {
|
222
|
+
@include placeholder();
|
223
|
+
}
|
224
|
+
|
225
|
+
|
226
|
+
// CHECKBOXES & RADIOS
|
227
|
+
// -------------------
|
228
|
+
|
229
|
+
// Indent the labels to position radios/checkboxes as hanging
|
230
|
+
.radio,
|
231
|
+
.checkbox {
|
232
|
+
min-height: $baseLineHeight; // clear the floating input if there is no label text
|
233
|
+
padding-left: 20px;
|
234
|
+
}
|
235
|
+
.radio input[type="radio"],
|
236
|
+
.checkbox input[type="checkbox"] {
|
237
|
+
float: left;
|
238
|
+
margin-left: -20px;
|
239
|
+
}
|
240
|
+
|
241
|
+
// Move the options list down to align with labels
|
242
|
+
.controls > .radio:first-child,
|
243
|
+
.controls > .checkbox:first-child {
|
244
|
+
padding-top: 5px; // has to be padding because margin collaspes
|
245
|
+
}
|
246
|
+
|
247
|
+
// Radios and checkboxes on same line
|
248
|
+
// TODO v3: Convert .inline to .control-inline
|
249
|
+
.radio.inline,
|
250
|
+
.checkbox.inline {
|
251
|
+
display: inline-block;
|
252
|
+
padding-top: 5px;
|
253
|
+
margin-bottom: 0;
|
254
|
+
vertical-align: middle;
|
255
|
+
}
|
256
|
+
.radio.inline + .radio.inline,
|
257
|
+
.checkbox.inline + .checkbox.inline {
|
258
|
+
margin-left: 10px; // space out consecutive inline controls
|
259
|
+
}
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
// INPUT SIZES
|
264
|
+
// -----------
|
265
|
+
|
266
|
+
// General classes for quick sizes
|
267
|
+
.input-mini { width: 60px; }
|
268
|
+
.input-small { width: 90px; }
|
269
|
+
.input-medium { width: 150px; }
|
270
|
+
.input-large { width: 210px; }
|
271
|
+
.input-xlarge { width: 270px; }
|
272
|
+
.input-xxlarge { width: 530px; }
|
273
|
+
|
274
|
+
// Grid style input sizes
|
275
|
+
input[class*="span"],
|
276
|
+
select[class*="span"],
|
277
|
+
textarea[class*="span"],
|
278
|
+
.uneditable-input[class*="span"],
|
279
|
+
// Redeclare since the fluid row class is more specific
|
280
|
+
.row-fluid input[class*="span"],
|
281
|
+
.row-fluid select[class*="span"],
|
282
|
+
.row-fluid textarea[class*="span"],
|
283
|
+
.row-fluid .uneditable-input[class*="span"] {
|
284
|
+
float: none;
|
285
|
+
margin-left: 0;
|
286
|
+
}
|
287
|
+
// Ensure input-prepend/append never wraps
|
288
|
+
.input-append input[class*="span"],
|
289
|
+
.input-append .uneditable-input[class*="span"],
|
290
|
+
.input-prepend input[class*="span"],
|
291
|
+
.input-prepend .uneditable-input[class*="span"],
|
292
|
+
.row-fluid input[class*="span"],
|
293
|
+
.row-fluid select[class*="span"],
|
294
|
+
.row-fluid textarea[class*="span"],
|
295
|
+
.row-fluid .uneditable-input[class*="span"],
|
296
|
+
.row-fluid .input-prepend [class*="span"],
|
297
|
+
.row-fluid .input-append [class*="span"] {
|
298
|
+
display: inline-block;
|
299
|
+
}
|
300
|
+
|
301
|
+
|
302
|
+
|
303
|
+
// GRID SIZING FOR INPUTS
|
304
|
+
// ----------------------
|
305
|
+
|
306
|
+
// Grid sizes
|
307
|
+
@include grid-input($gridColumnWidth, $gridGutterWidth);
|
308
|
+
|
309
|
+
// Control row for multiple inputs per line
|
310
|
+
.controls-row {
|
311
|
+
@include clearfix(); // Clear the float from controls
|
312
|
+
}
|
313
|
+
|
314
|
+
// Float to collapse white-space for proper grid alignment
|
315
|
+
.controls-row [class*="span"],
|
316
|
+
// Redeclare the fluid grid collapse since we undo the float for inputs
|
317
|
+
.row-fluid .controls-row [class*="span"] {
|
318
|
+
float: left;
|
319
|
+
}
|
320
|
+
// Explicity set top padding on all checkboxes/radios, not just first-child
|
321
|
+
.controls-row .checkbox[class*="span"],
|
322
|
+
.controls-row .radio[class*="span"] {
|
323
|
+
padding-top: 5px;
|
324
|
+
}
|
325
|
+
|
326
|
+
|
327
|
+
|
328
|
+
|
329
|
+
// DISABLED STATE
|
330
|
+
// --------------
|
331
|
+
|
332
|
+
// Disabled and read-only inputs
|
333
|
+
input[disabled],
|
334
|
+
select[disabled],
|
335
|
+
textarea[disabled],
|
336
|
+
input[readonly],
|
337
|
+
select[readonly],
|
338
|
+
textarea[readonly] {
|
339
|
+
cursor: not-allowed;
|
340
|
+
background-color: $inputDisabledBackground;
|
341
|
+
}
|
342
|
+
// Explicitly reset the colors here
|
343
|
+
input[type="radio"][disabled],
|
344
|
+
input[type="checkbox"][disabled],
|
345
|
+
input[type="radio"][readonly],
|
346
|
+
input[type="checkbox"][readonly] {
|
347
|
+
background-color: transparent;
|
348
|
+
}
|
349
|
+
|
350
|
+
|
351
|
+
|
352
|
+
|
353
|
+
// FORM FIELD FEEDBACK STATES
|
354
|
+
// --------------------------
|
355
|
+
|
356
|
+
// Warning
|
357
|
+
.control-group.warning {
|
358
|
+
@include formFieldState($warningText, $warningText, $warningBackground);
|
359
|
+
}
|
360
|
+
// Error
|
361
|
+
.control-group.error {
|
362
|
+
@include formFieldState($errorText, $errorText, $errorBackground);
|
363
|
+
}
|
364
|
+
// Success
|
365
|
+
.control-group.success {
|
366
|
+
@include formFieldState($successText, $successText, $successBackground);
|
367
|
+
}
|
368
|
+
// Info
|
369
|
+
.control-group.info {
|
370
|
+
@include formFieldState($infoText, $infoText, $infoBackground);
|
371
|
+
}
|
372
|
+
|
373
|
+
// HTML5 invalid states
|
374
|
+
// Shares styles with the .control-group.error above
|
375
|
+
input:focus:invalid,
|
376
|
+
textarea:focus:invalid,
|
377
|
+
select:focus:invalid {
|
378
|
+
color: #b94a48;
|
379
|
+
border-color: #ee5f5b;
|
380
|
+
&:focus {
|
381
|
+
border-color: darken(#ee5f5b, 10%);
|
382
|
+
@include box-shadow(0 0 6px lighten(#ee5f5b, 20%));
|
383
|
+
}
|
384
|
+
}
|
385
|
+
|
386
|
+
|
387
|
+
|
388
|
+
// FORM ACTIONS
|
389
|
+
// ------------
|
390
|
+
|
391
|
+
.form-actions {
|
392
|
+
padding: ($baseLineHeight - 1) 20px $baseLineHeight;
|
393
|
+
margin-top: $baseLineHeight;
|
394
|
+
margin-bottom: $baseLineHeight;
|
395
|
+
background-color: $formActionsBackground;
|
396
|
+
border-top: 1px solid #e5e5e5;
|
397
|
+
@include clearfix(); // Adding clearfix to allow for .pull-right button containers
|
398
|
+
}
|
399
|
+
|
400
|
+
|
401
|
+
|
402
|
+
// HELP TEXT
|
403
|
+
// ---------
|
404
|
+
|
405
|
+
.help-block,
|
406
|
+
.help-inline {
|
407
|
+
color: lighten($textColor, 15%); // lighten the text some for contrast
|
408
|
+
}
|
409
|
+
|
410
|
+
.help-block {
|
411
|
+
display: block; // account for any element using help-block
|
412
|
+
margin-bottom: $baseLineHeight / 2;
|
413
|
+
}
|
414
|
+
|
415
|
+
.help-inline {
|
416
|
+
display: inline-block;
|
417
|
+
@include ie7-inline-block();
|
418
|
+
vertical-align: middle;
|
419
|
+
padding-left: 5px;
|
420
|
+
}
|
421
|
+
|
422
|
+
|
423
|
+
|
424
|
+
// INPUT GROUPS
|
425
|
+
// ------------
|
426
|
+
|
427
|
+
// Allow us to put symbols and text within the input field for a cleaner look
|
428
|
+
.input-append,
|
429
|
+
.input-prepend {
|
430
|
+
display: inline-block;
|
431
|
+
margin-bottom: $baseLineHeight / 2;
|
432
|
+
vertical-align: middle;
|
433
|
+
font-size: 0; // white space collapse hack
|
434
|
+
white-space: nowrap; // Prevent span and input from separating
|
435
|
+
|
436
|
+
// Reset the white space collapse hack
|
437
|
+
input,
|
438
|
+
select,
|
439
|
+
.uneditable-input,
|
440
|
+
.dropdown-menu,
|
441
|
+
.popover {
|
442
|
+
font-size: $baseFontSize;
|
443
|
+
}
|
444
|
+
|
445
|
+
input,
|
446
|
+
select,
|
447
|
+
.uneditable-input {
|
448
|
+
position: relative; // placed here by default so that on :focus we can place the input above the .add-on for full border and box-shadow goodness
|
449
|
+
margin-bottom: 0; // prevent bottom margin from screwing up alignment in stacked forms
|
450
|
+
*margin-left: 0;
|
451
|
+
vertical-align: top;
|
452
|
+
// Make input on top when focused so blue border and shadow always show
|
453
|
+
&:focus {
|
454
|
+
z-index: 2;
|
455
|
+
}
|
456
|
+
}
|
457
|
+
.add-on {
|
458
|
+
display: inline-block;
|
459
|
+
width: auto;
|
460
|
+
height: $baseLineHeight;
|
461
|
+
min-width: 16px;
|
462
|
+
padding: 4px 5px;
|
463
|
+
font-size: $baseFontSize;
|
464
|
+
font-weight: normal;
|
465
|
+
line-height: $baseLineHeight;
|
466
|
+
text-align: center;
|
467
|
+
text-shadow: 0 1px 0 $white;
|
468
|
+
background-color: $grayLighter;
|
469
|
+
border: 1px solid #ccc;
|
470
|
+
}
|
471
|
+
.add-on,
|
472
|
+
.btn,
|
473
|
+
.btn-group > .dropdown-toggle {
|
474
|
+
vertical-align: top;
|
475
|
+
}
|
476
|
+
.active {
|
477
|
+
background-color: lighten($green, 30);
|
478
|
+
border-color: $green;
|
479
|
+
}
|
480
|
+
}
|
481
|
+
|
482
|
+
.input-prepend {
|
483
|
+
.add-on,
|
484
|
+
.btn {
|
485
|
+
margin-right: -1px;
|
486
|
+
}
|
487
|
+
}
|
488
|
+
|
489
|
+
.input-append {
|
490
|
+
.add-on,
|
491
|
+
.btn,
|
492
|
+
.btn-group {
|
493
|
+
margin-left: -1px;
|
494
|
+
}
|
495
|
+
}
|
496
|
+
|
497
|
+
// Remove all border-radius for inputs with both prepend and append
|
498
|
+
.input-prepend.input-append {
|
499
|
+
.add-on:first-child,
|
500
|
+
.btn:first-child {
|
501
|
+
margin-right: -1px;
|
502
|
+
}
|
503
|
+
.add-on:last-child,
|
504
|
+
.btn:last-child {
|
505
|
+
margin-left: -1px;
|
506
|
+
}
|
507
|
+
.btn-group:first-child {
|
508
|
+
margin-left: 0;
|
509
|
+
}
|
510
|
+
}
|
511
|
+
|
512
|
+
|
513
|
+
|
514
|
+
|
515
|
+
// SEARCH FORM
|
516
|
+
// -----------
|
517
|
+
|
518
|
+
input.search-query {
|
519
|
+
padding-right: 14px;
|
520
|
+
padding-right: 4px \9;
|
521
|
+
padding-left: 14px;
|
522
|
+
padding-left: 4px \9; /* IE7-8 doesn't have border-radius, so don't indent the padding */
|
523
|
+
margin-bottom: 0; // Remove the default margin on all inputs
|
524
|
+
}
|
525
|
+
|
526
|
+
|
527
|
+
|
528
|
+
|
529
|
+
// HORIZONTAL & VERTICAL FORMS
|
530
|
+
// ---------------------------
|
531
|
+
|
532
|
+
// Common properties
|
533
|
+
// -----------------
|
534
|
+
|
535
|
+
.form-search,
|
536
|
+
.form-inline,
|
537
|
+
.form-horizontal {
|
538
|
+
input,
|
539
|
+
textarea,
|
540
|
+
select,
|
541
|
+
.help-inline,
|
542
|
+
.uneditable-input,
|
543
|
+
.input-prepend,
|
544
|
+
.input-append {
|
545
|
+
display: inline-block;
|
546
|
+
@include ie7-inline-block();
|
547
|
+
margin-bottom: 0;
|
548
|
+
vertical-align: middle;
|
549
|
+
}
|
550
|
+
// Re-hide hidden elements due to specifity
|
551
|
+
.hide {
|
552
|
+
display: none;
|
553
|
+
}
|
554
|
+
}
|
555
|
+
.form-search label,
|
556
|
+
.form-inline label,
|
557
|
+
.form-search .btn-group,
|
558
|
+
.form-inline .btn-group {
|
559
|
+
display: inline-block;
|
560
|
+
}
|
561
|
+
// Remove margin for input-prepend/-append
|
562
|
+
.form-search .input-append,
|
563
|
+
.form-inline .input-append,
|
564
|
+
.form-search .input-prepend,
|
565
|
+
.form-inline .input-prepend {
|
566
|
+
margin-bottom: 0;
|
567
|
+
}
|
568
|
+
// Inline checkbox/radio labels (remove padding on left)
|
569
|
+
.form-search .radio,
|
570
|
+
.form-search .checkbox,
|
571
|
+
.form-inline .radio,
|
572
|
+
.form-inline .checkbox {
|
573
|
+
padding-left: 0;
|
574
|
+
margin-bottom: 0;
|
575
|
+
vertical-align: middle;
|
576
|
+
}
|
577
|
+
// Remove float and margin, set to inline-block
|
578
|
+
.form-search .radio input[type="radio"],
|
579
|
+
.form-search .checkbox input[type="checkbox"],
|
580
|
+
.form-inline .radio input[type="radio"],
|
581
|
+
.form-inline .checkbox input[type="checkbox"] {
|
582
|
+
float: left;
|
583
|
+
margin-right: 3px;
|
584
|
+
margin-left: 0;
|
585
|
+
}
|
586
|
+
|
587
|
+
|
588
|
+
// Margin to space out fieldsets
|
589
|
+
.control-group {
|
590
|
+
margin-bottom: $baseLineHeight / 2;
|
591
|
+
}
|
592
|
+
|
593
|
+
// Legend collapses margin, so next element is responsible for spacing
|
594
|
+
legend + .control-group {
|
595
|
+
margin-top: $baseLineHeight;
|
596
|
+
-webkit-margin-top-collapse: separate;
|
597
|
+
}
|
598
|
+
|
599
|
+
// Horizontal-specific styles
|
600
|
+
// --------------------------
|
601
|
+
|
602
|
+
.form-horizontal {
|
603
|
+
// Increase spacing between groups
|
604
|
+
.control-group {
|
605
|
+
margin-bottom: $baseLineHeight;
|
606
|
+
@include clearfix();
|
607
|
+
}
|
608
|
+
// Float the labels left
|
609
|
+
.control-label {
|
610
|
+
float: left;
|
611
|
+
width: $horizontalComponentOffset - 20;
|
612
|
+
padding-top: 5px;
|
613
|
+
text-align: right;
|
614
|
+
}
|
615
|
+
// Move over all input controls and content
|
616
|
+
.controls {
|
617
|
+
// Super jank IE7 fix to ensure the inputs in .input-append and input-prepend
|
618
|
+
// don't inherit the margin of the parent, in this case .controls
|
619
|
+
*display: inline-block;
|
620
|
+
*padding-left: 20px;
|
621
|
+
margin-left: $horizontalComponentOffset;
|
622
|
+
*margin-left: 0;
|
623
|
+
&:first-child {
|
624
|
+
*padding-left: $horizontalComponentOffset;
|
625
|
+
}
|
626
|
+
}
|
627
|
+
// Remove bottom margin on block level help text since that's accounted for on .control-group
|
628
|
+
.help-block {
|
629
|
+
margin-bottom: 0;
|
630
|
+
}
|
631
|
+
// And apply it only to .help-block instances that follow a form control
|
632
|
+
input,
|
633
|
+
select,
|
634
|
+
textarea,
|
635
|
+
.uneditable-input,
|
636
|
+
.input-prepend,
|
637
|
+
.input-append {
|
638
|
+
+ .help-block {
|
639
|
+
margin-top: $baseLineHeight / 2;
|
640
|
+
}
|
641
|
+
}
|
642
|
+
// Move over buttons in .form-actions to align with .controls
|
643
|
+
.form-actions {
|
644
|
+
padding-left: $horizontalComponentOffset;
|
645
|
+
}
|
646
|
+
}
|