sass_twitter_bootstrap 0.1.alpha.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.markdown +59 -0
- data/lib/sass_twitter_bootstrap.rb +3 -0
- data/stylesheets/_bootstrap.sass +67 -0
- data/stylesheets/sass_twitter_bootstrap/_accordion.sass +24 -0
- data/stylesheets/sass_twitter_bootstrap/_alerts.sass +65 -0
- data/stylesheets/sass_twitter_bootstrap/_bootstrap.sass +1 -0
- data/stylesheets/sass_twitter_bootstrap/_breadcrumbs.sass +18 -0
- data/stylesheets/sass_twitter_bootstrap/_button-groups.sass +129 -0
- data/stylesheets/sass_twitter_bootstrap/_buttons.sass +166 -0
- data/stylesheets/sass_twitter_bootstrap/_carousel.sass +95 -0
- data/stylesheets/sass_twitter_bootstrap/_close.sass +16 -0
- data/stylesheets/sass_twitter_bootstrap/_code.sass +51 -0
- data/stylesheets/sass_twitter_bootstrap/_component-animations.sass +16 -0
- data/stylesheets/sass_twitter_bootstrap/_dropdowns.sass +120 -0
- data/stylesheets/sass_twitter_bootstrap/_forms.sass +482 -0
- data/stylesheets/sass_twitter_bootstrap/_grid.sass +8 -0
- data/stylesheets/sass_twitter_bootstrap/_hero-unit.sass +17 -0
- data/stylesheets/sass_twitter_bootstrap/_labels.sass +42 -0
- data/stylesheets/sass_twitter_bootstrap/_layouts.sass +14 -0
- data/stylesheets/sass_twitter_bootstrap/_mixins.sass +487 -0
- data/stylesheets/sass_twitter_bootstrap/_modals.sass +84 -0
- data/stylesheets/sass_twitter_bootstrap/_navbar.sass +268 -0
- data/stylesheets/sass_twitter_bootstrap/_navs.sass +326 -0
- data/stylesheets/sass_twitter_bootstrap/_pager.sass +29 -0
- data/stylesheets/sass_twitter_bootstrap/_pagination.sass +53 -0
- data/stylesheets/sass_twitter_bootstrap/_popovers.sass +55 -0
- data/stylesheets/sass_twitter_bootstrap/_print.sass +15 -0
- data/stylesheets/sass_twitter_bootstrap/_progress-bars.sass +89 -0
- data/stylesheets/sass_twitter_bootstrap/_reset.sass +130 -0
- data/stylesheets/sass_twitter_bootstrap/_scaffolding.sass +25 -0
- data/stylesheets/sass_twitter_bootstrap/_sprites.sass +394 -0
- data/stylesheets/sass_twitter_bootstrap/_tables.sass +134 -0
- data/stylesheets/sass_twitter_bootstrap/_thumbnails.sass +34 -0
- data/stylesheets/sass_twitter_bootstrap/_tooltip.sass +43 -0
- data/stylesheets/sass_twitter_bootstrap/_type.sass +193 -0
- data/stylesheets/sass_twitter_bootstrap/_utilities.sass +20 -0
- data/stylesheets/sass_twitter_bootstrap/_variables.sass +101 -0
- data/stylesheets/sass_twitter_bootstrap/_wells.sass +15 -0
- data/templates/project/bootstrap.sass +67 -0
- data/templates/project/manifest.rb +20 -0
- data/templates/project/responsive.sass +255 -0
- metadata +110 -0
@@ -0,0 +1,487 @@
|
|
1
|
+
// MIXINS
|
2
|
+
// Snippets of reusable CSS to develop faster and keep code readable
|
3
|
+
// -----------------------------------------------------------------
|
4
|
+
|
5
|
+
// UTILITY MIXINS
|
6
|
+
// -------------------------------------------------
|
7
|
+
|
8
|
+
// Clearfix
|
9
|
+
// --------
|
10
|
+
// For clearing floats like a boss h5bp.com/q
|
11
|
+
=clearfix
|
12
|
+
*zoom: 1
|
13
|
+
&:before,
|
14
|
+
&:after
|
15
|
+
display: table
|
16
|
+
content: ""
|
17
|
+
&:after
|
18
|
+
clear: both
|
19
|
+
|
20
|
+
// Webkit-style focus
|
21
|
+
// ------------------
|
22
|
+
=tab-focus
|
23
|
+
// Default
|
24
|
+
outline: thin dotted #333
|
25
|
+
// Webkit
|
26
|
+
outline: 5px auto -webkit-focus-ring-color
|
27
|
+
outline-offset: -2px
|
28
|
+
|
29
|
+
// Center-align a block level element
|
30
|
+
// ----------------------------------
|
31
|
+
=center-block
|
32
|
+
display: block
|
33
|
+
margin-left: auto
|
34
|
+
margin-right: auto
|
35
|
+
|
36
|
+
// IE7 inline-block
|
37
|
+
// ----------------
|
38
|
+
=ie7-inline-block
|
39
|
+
*display: inline
|
40
|
+
/* IE7 inline-block hack
|
41
|
+
*zoom: 1
|
42
|
+
|
43
|
+
// IE7 likes to collapse whitespace on either side of the inline-block elements.
|
44
|
+
// Ems because we're attempting to match the width of a space character. Left
|
45
|
+
// version is for form buttons, which typically come after other elements, and
|
46
|
+
// right version is for icons, which come before. Applying both is ok, but it will
|
47
|
+
// mean that space between those elements will be .6em (~2 space characters) in IE7,
|
48
|
+
// instead of the 1 space in other browsers.
|
49
|
+
=ie7-restore-left-whitespace
|
50
|
+
*margin-left: .3em
|
51
|
+
&:first-child
|
52
|
+
*margin-left: 0
|
53
|
+
|
54
|
+
=ie7-restore-right-whitespace
|
55
|
+
*margin-right: .3em
|
56
|
+
&:last-child
|
57
|
+
*margin-left: 0
|
58
|
+
|
59
|
+
// Sizing shortcuts
|
60
|
+
// -------------------------
|
61
|
+
=size($height: 5px, $width: 5px)
|
62
|
+
width: $width
|
63
|
+
height: $height
|
64
|
+
|
65
|
+
=square($size: 5px)
|
66
|
+
+size($size, $size)
|
67
|
+
|
68
|
+
// Placeholder text
|
69
|
+
// -------------------------
|
70
|
+
=placeholder($color: $placeholderText)
|
71
|
+
\:-moz-placeholder
|
72
|
+
color: $color
|
73
|
+
\::-webkit-input-placeholder
|
74
|
+
color: $color
|
75
|
+
|
76
|
+
// Text overflow
|
77
|
+
// -------------------------
|
78
|
+
// Requires inline-block or block for proper styling
|
79
|
+
=text-overflow
|
80
|
+
overflow: hidden
|
81
|
+
text-overflow: ellipsis
|
82
|
+
white-space: nowrap
|
83
|
+
|
84
|
+
// FONTS
|
85
|
+
// --------------------------------------------------
|
86
|
+
|
87
|
+
// Font Stacks
|
88
|
+
=font-shorthand($size: $baseFontSize, $weight: normal, $lineHeight: $baseLineHeight)
|
89
|
+
font-size: $size
|
90
|
+
font-weight: $weight
|
91
|
+
line-height: $lineHeight
|
92
|
+
|
93
|
+
=font-serif($size: $baseFontSize, $weight: normal, $lineHeight: $baseLineHeight)
|
94
|
+
font-family: Georgia, "Times New Roman", Times, serif
|
95
|
+
+font-shorthand($size, $weight, $lineHeight)
|
96
|
+
|
97
|
+
=font-sans-serif($size: $baseFontSize, $weight: normal, $lineHeight: $baseLineHeight)
|
98
|
+
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif
|
99
|
+
+font-shorthand($size, $weight, $lineHeight)
|
100
|
+
|
101
|
+
=font-family-monospace
|
102
|
+
font-family: Menlo, Monaco, "Courier New", monospace
|
103
|
+
|
104
|
+
=font-monospace($size: $baseFontSize, $weight: normal, $lineHeight: $baseLineHeight)
|
105
|
+
+font-family-monospace
|
106
|
+
+font-shorthand($size, $weight, $lineHeight)
|
107
|
+
|
108
|
+
// GRID SYSTEM
|
109
|
+
// --------------------------------------------------
|
110
|
+
|
111
|
+
// Site container
|
112
|
+
// -------------------------
|
113
|
+
=container-fixed
|
114
|
+
width: $gridRowWidth
|
115
|
+
margin-left: auto
|
116
|
+
margin-right: auto
|
117
|
+
+clearfix
|
118
|
+
|
119
|
+
// Le grid system
|
120
|
+
// -------------------------
|
121
|
+
=gridSystem-columns($gridGutterWidth, $gridColumnWidth, $gridRowWidth, $columns)
|
122
|
+
width: $gridColumnWidth * $columns + $gridGutterWidth * ($columns - 1)
|
123
|
+
|
124
|
+
=gridSystem-offset($gridColumnWidth, $gridGutterWidth, $columns)
|
125
|
+
margin-left: $gridColumnWidth * $columns + $gridGutterWidth * ($columns - 1) + $gridGutterWidth * 2
|
126
|
+
|
127
|
+
=gridSystem-gridColumn($gridGutterWidth)
|
128
|
+
float: left
|
129
|
+
margin-left: $gridGutterWidth
|
130
|
+
|
131
|
+
// Take these values and mixins, and make 'em do their thang
|
132
|
+
=gridSystem-generate($gridColumns, $gridColumnWidth, $gridGutterWidth)
|
133
|
+
// Row surrounds the columns
|
134
|
+
.row
|
135
|
+
margin-left: $gridGutterWidth * -1
|
136
|
+
+clearfix
|
137
|
+
// Find all .span# classes within .row and give them the necessary properties for grid columns (supported by all browsers back to IE7, thanks $dhg)
|
138
|
+
[class*="span"]
|
139
|
+
+gridSystem-gridColumn($gridGutterWidth)
|
140
|
+
// Default columns
|
141
|
+
@for $i from 1 through $gridColumns
|
142
|
+
.span#{$i}
|
143
|
+
+gridSystem-columns($gridGutterWidth, $gridColumnWidth, $gridRowWidth, $i)
|
144
|
+
.container
|
145
|
+
+gridSystem-columns($gridGutterWidth, $gridColumnWidth, $gridRowWidth, 12)
|
146
|
+
// Offset column options
|
147
|
+
@for $i from 1 through $gridColumns - 1
|
148
|
+
.offset#{$i}
|
149
|
+
+gridSystem-offset($gridColumnWidth, $gridGutterWidth, $i)
|
150
|
+
|
151
|
+
// Fluid grid system
|
152
|
+
// -------------------------
|
153
|
+
=fluidGridSystem-columns($fluidGridGutterWidth, $fluidGridColumnWidth, $columns)
|
154
|
+
width: $fluidGridColumnWidth * $columns + $fluidGridGutterWidth * ($columns - 1)
|
155
|
+
|
156
|
+
=fluidGridSystem-gridColumn($fluidGridGutterWidth)
|
157
|
+
float: left
|
158
|
+
margin-left: $fluidGridGutterWidth
|
159
|
+
|
160
|
+
// Take these values and mixins, and make 'em do their thang
|
161
|
+
=fluidGridSystem-generate($gridColumns, $fluidGridColumnWidth, $fluidGridGutterWidth)
|
162
|
+
// Row surrounds the columns
|
163
|
+
.row-fluid
|
164
|
+
width: 100%
|
165
|
+
+clearfix
|
166
|
+
// Find all .span# classes within .row and give them the necessary properties for grid columns (supported by all browsers back to IE7, thanks $dhg)
|
167
|
+
> [class*="span"]
|
168
|
+
+fluidGridSystem-gridColumn($fluidGridGutterWidth)
|
169
|
+
> [class*="span"]:first-child
|
170
|
+
margin-left: 0
|
171
|
+
// Default columns
|
172
|
+
@for $i from 1 through $gridColumns
|
173
|
+
> .span#{$i}
|
174
|
+
+fluidGridSystem-columns($fluidGridGutterWidth, $fluidGridColumnWidth, $i)
|
175
|
+
|
176
|
+
// Input grid system
|
177
|
+
// -------------------------
|
178
|
+
=inputGridSystem-inputColumns($gridGutterWidth, $gridColumnWidth, $gridRowWidth, $columns)
|
179
|
+
width: $gridColumnWidth * $columns + $gridGutterWidth * ($columns - 1) - 10
|
180
|
+
|
181
|
+
=inputGridSystem-generate($gridColumns, $gridColumnWidth, $gridGutterWidth)
|
182
|
+
input,
|
183
|
+
textarea,
|
184
|
+
.uneditable-input
|
185
|
+
@for $i from 1 through $gridColumns
|
186
|
+
&.span#{$i}
|
187
|
+
+inputGridSystem-inputColumns($gridGutterWidth, $gridColumnWidth, $gridRowWidth, $i)
|
188
|
+
|
189
|
+
// Make a Grid
|
190
|
+
// -------------------------
|
191
|
+
// Use .makeRow and .makeColumn to assign semantic layouts grid system behavior
|
192
|
+
=makeRow
|
193
|
+
margin-left: $gridGutterWidth * -1
|
194
|
+
+clearfix
|
195
|
+
|
196
|
+
=makeColumn($columns: 1)
|
197
|
+
float: left
|
198
|
+
margin-left: $gridGutterWidth
|
199
|
+
width: $gridColumnWidth * $columns + $gridGutterWidth * ($columns - 1)
|
200
|
+
|
201
|
+
// Form field states (used in forms.less)
|
202
|
+
// --------------------------------------------------
|
203
|
+
|
204
|
+
// Mixin for form field states
|
205
|
+
=formFieldState($textColor: #555555, $borderColor: #cccccc, $backgroundColor: whitesmoke)
|
206
|
+
// Set the text color
|
207
|
+
> label,
|
208
|
+
.help-block,
|
209
|
+
.help-inline
|
210
|
+
color: $textColor
|
211
|
+
// Style inputs accordingly
|
212
|
+
input,
|
213
|
+
select,
|
214
|
+
textarea
|
215
|
+
color: $textColor
|
216
|
+
border-color: $borderColor
|
217
|
+
&:focus
|
218
|
+
border-color: darken($borderColor, 10%)
|
219
|
+
+box-shadow(0 0 6px lighten($borderColor, 20%))
|
220
|
+
// Give a small background color for input-prepend/-append
|
221
|
+
.input-prepend .add-on,
|
222
|
+
.input-append .add-on
|
223
|
+
color: $textColor
|
224
|
+
background-color: $backgroundColor
|
225
|
+
border-color: $textColor
|
226
|
+
|
227
|
+
// CSS3 PROPERTIES
|
228
|
+
// --------------------------------------------------
|
229
|
+
|
230
|
+
// Border Radius
|
231
|
+
=border-radius($radius: 5px)
|
232
|
+
-webkit-border-radius: $radius
|
233
|
+
-moz-border-radius: $radius
|
234
|
+
border-radius: $radius
|
235
|
+
|
236
|
+
// Drop shadows
|
237
|
+
=box-shadow($shadow: 0 1px 3px rgba(0, 0, 0, 0.25))
|
238
|
+
-webkit-box-shadow: $shadow
|
239
|
+
-moz-box-shadow: $shadow
|
240
|
+
box-shadow: $shadow
|
241
|
+
|
242
|
+
// Transitions
|
243
|
+
=transition($transition)
|
244
|
+
-webkit-transition: $transition
|
245
|
+
-moz-transition: $transition
|
246
|
+
-ms-transition: $transition
|
247
|
+
-o-transition: $transition
|
248
|
+
transition: $transition
|
249
|
+
|
250
|
+
// Transformations
|
251
|
+
=rotate($degrees: 5deg)
|
252
|
+
-webkit-transform: rotate($degrees)
|
253
|
+
-moz-transform: rotate($degrees)
|
254
|
+
-ms-transform: rotate($degrees)
|
255
|
+
-o-transform: rotate($degrees)
|
256
|
+
transform: rotate($degrees)
|
257
|
+
|
258
|
+
=scale($ratio)
|
259
|
+
-webkit-transform: scale($ratio)
|
260
|
+
-moz-transform: scale($ratio)
|
261
|
+
-ms-transform: scale($ratio)
|
262
|
+
-o-transform: scale($ratio)
|
263
|
+
transform: scale($ratio)
|
264
|
+
|
265
|
+
=translate($x: 0, $y: 0)
|
266
|
+
-webkit-transform: translate($x, $y)
|
267
|
+
-moz-transform: translate($x, $y)
|
268
|
+
-ms-transform: translate($x, $y)
|
269
|
+
-o-transform: translate($x, $y)
|
270
|
+
transform: translate($x, $y)
|
271
|
+
|
272
|
+
=skew($x: 0, $y: 0)
|
273
|
+
-webkit-transform: translate($x, $y)
|
274
|
+
-moz-transform: translate($x, $y)
|
275
|
+
-ms-transform: translate($x, $y)
|
276
|
+
-o-transform: translate($x, $y)
|
277
|
+
transform: translate($x, $y)
|
278
|
+
|
279
|
+
=translate3d($x: 0, $y: 0, $z: 0)
|
280
|
+
-webkit-transform: translate($x, $y, $z)
|
281
|
+
-moz-transform: translate($x, $y, $z)
|
282
|
+
-ms-transform: translate($x, $y, $z)
|
283
|
+
-o-transform: translate($x, $y, $z)
|
284
|
+
transform: translate($x, $y, $z)
|
285
|
+
|
286
|
+
// Background clipping
|
287
|
+
// Heads up: FF 3.6 and under need padding instead of padding-box
|
288
|
+
=background-clip($clip)
|
289
|
+
-webkit-background-clip: $clip
|
290
|
+
-moz-background-clip: $clip
|
291
|
+
background-clip: $clip
|
292
|
+
|
293
|
+
// Background sizing
|
294
|
+
=background-size($size)
|
295
|
+
-webkit-background-size: $size
|
296
|
+
-moz-background-size: $size
|
297
|
+
-o-background-size: $size
|
298
|
+
background-size: $size
|
299
|
+
|
300
|
+
// Box sizing
|
301
|
+
=box-sizing($boxmodel)
|
302
|
+
-webkit-box-sizing: $boxmodel
|
303
|
+
-moz-box-sizing: $boxmodel
|
304
|
+
box-sizing: $boxmodel
|
305
|
+
|
306
|
+
// User select
|
307
|
+
// For selecting text on the page
|
308
|
+
=user-select($select)
|
309
|
+
-webkit-user-select: $select
|
310
|
+
-moz-user-select: $select
|
311
|
+
-o-user-select: $select
|
312
|
+
user-select: $select
|
313
|
+
|
314
|
+
// Resize anything
|
315
|
+
=resizable($direction: both)
|
316
|
+
resize: $direction
|
317
|
+
// Options: horizontal, vertical, both
|
318
|
+
overflow: auto
|
319
|
+
// Safari fix
|
320
|
+
|
321
|
+
// CSS3 Content Columns
|
322
|
+
=content-columns($columnCount, $columnGap: $gridColumnGutter)
|
323
|
+
-webkit-column-count: $columnCount
|
324
|
+
-moz-column-count: $columnCount
|
325
|
+
column-count: $columnCount
|
326
|
+
-webkit-column-gap: $columnGap
|
327
|
+
-moz-column-gap: $columnGap
|
328
|
+
column-gap: $columnGap
|
329
|
+
|
330
|
+
// Opacity
|
331
|
+
=opacity($opacity: 100)
|
332
|
+
opacity: $opacity / 100
|
333
|
+
filter: alpha(opacity = $opacity)
|
334
|
+
|
335
|
+
// BACKGROUNDS
|
336
|
+
// --------------------------------------------------
|
337
|
+
|
338
|
+
// Add an alphatransparency value to any background or border color (via Elyse Holladay)
|
339
|
+
=translucent-background($color: $white, $alpha: 1)
|
340
|
+
background-color: hsla(hue($color), saturation($color), lightness($color), $alpha)
|
341
|
+
|
342
|
+
=translucent-border($color: $white, $alpha: 1)
|
343
|
+
border-color: hsla(hue($color), saturation($color), lightness($color), $alpha)
|
344
|
+
+background-clip(padding-box)
|
345
|
+
|
346
|
+
// Gradients
|
347
|
+
=gradient-horizontal($startColor: #555555, $endColor: #333333)
|
348
|
+
background-color: $endColor
|
349
|
+
background-image: -moz-linear-gradient(left, $startColor, $endColor)
|
350
|
+
// FF 3.6+
|
351
|
+
background-image: -ms-linear-gradient(left, $startColor, $endColor)
|
352
|
+
// IE10
|
353
|
+
background-image: -webkit-gradient(linear, 0 0, 100% 0, from($startColor), to($endColor))
|
354
|
+
// Safari 4+, Chrome 2+
|
355
|
+
background-image: -webkit-linear-gradient(left, $startColor, $endColor)
|
356
|
+
// Safari 5.1+, Chrome 10+
|
357
|
+
background-image: -o-linear-gradient(left, $startColor, $endColor)
|
358
|
+
// Opera 11.10
|
359
|
+
background-image: linear-gradient(left, $startColor, $endColor)
|
360
|
+
// Le standard
|
361
|
+
background-repeat: repeat-x
|
362
|
+
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$startColor}', endColorstr='#{$endColor}', GradientType=1), $startColor, $endColor
|
363
|
+
// IE9 and down
|
364
|
+
|
365
|
+
=gradient-vertical($startColor: #555555, $endColor: #333333)
|
366
|
+
background-color: mix($startColor, $endColor, 60%)
|
367
|
+
background-image: -moz-linear-gradient(top, $startColor, $endColor)
|
368
|
+
// FF 3.6+
|
369
|
+
background-image: -ms-linear-gradient(top, $startColor, $endColor)
|
370
|
+
// IE10
|
371
|
+
background-image: -webkit-gradient(linear, 0 0, 0 100%, from($startColor), to($endColor))
|
372
|
+
// Safari 4+, Chrome 2+
|
373
|
+
background-image: -webkit-linear-gradient(top, $startColor, $endColor)
|
374
|
+
// Safari 5.1+, Chrome 10+
|
375
|
+
background-image: -o-linear-gradient(top, $startColor, $endColor)
|
376
|
+
// Opera 11.10
|
377
|
+
background-image: linear-gradient(top, $startColor, $endColor)
|
378
|
+
// The standard
|
379
|
+
background-repeat: repeat-x
|
380
|
+
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$startColor}', endColorstr='#{$endColor}', GradientType=0), $startColor, $endColor
|
381
|
+
// IE9 and down
|
382
|
+
|
383
|
+
=gradient-directional($startColor: #555555, $endColor: #333333, $deg: 45deg)
|
384
|
+
background-color: $endColor
|
385
|
+
background-repeat: repeat-x
|
386
|
+
background-image: -moz-linear-gradient($deg, $startColor, $endColor)
|
387
|
+
// FF 3.6+
|
388
|
+
background-image: -ms-linear-gradient($deg, $startColor, $endColor)
|
389
|
+
// IE10
|
390
|
+
background-image: -webkit-linear-gradient($deg, $startColor, $endColor)
|
391
|
+
// Safari 5.1+, Chrome 10+
|
392
|
+
background-image: -o-linear-gradient($deg, $startColor, $endColor)
|
393
|
+
// Opera 11.10
|
394
|
+
background-image: linear-gradient($deg, $startColor, $endColor)
|
395
|
+
// The standard
|
396
|
+
|
397
|
+
=gradient-vertical-three-colors($startColor: #00b3ee, $midColor: #7a43b6, $colorStop: 50%, $endColor: #c3325f)
|
398
|
+
background-color: mix($midColor, $endColor, 80%)
|
399
|
+
background-image: -webkit-gradient(linear, 0 0, 0 100%, from($startColor), color-stop($colorStop, $midColor), to($endColor))
|
400
|
+
background-image: -webkit-linear-gradient($startColor, $midColor $colorStop, $endColor)
|
401
|
+
background-image: -moz-linear-gradient(top, $startColor, $midColor $colorStop, $endColor)
|
402
|
+
background-image: -ms-linear-gradient($startColor, $midColor $colorStop, $endColor)
|
403
|
+
background-image: -o-linear-gradient($startColor, $midColor $colorStop, $endColor)
|
404
|
+
background-image: linear-gradient($startColor, $midColor $colorStop, $endColor)
|
405
|
+
background-repeat: no-repeat
|
406
|
+
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$startColor}', endColorstr='#{$endColor}', GradientType=0), $startColor, $endColor
|
407
|
+
// IE9 and down, gets no color-stop at all the proper fallback
|
408
|
+
|
409
|
+
=gradient-radial($centerColor: #555555, $outsideColor: #333333)
|
410
|
+
background-color: $outerColor
|
411
|
+
background-image: -webkit-gradient(radial, center center, 0, center center, 460, from($centerColor), to($outsideColor))
|
412
|
+
background-image: -webkit-radial-gradient(circle, $centerColor, $outsideColor)
|
413
|
+
background-image: -moz-radial-gradient(circle, $centerColor, $outsideColor)
|
414
|
+
background-image: -ms-radial-gradient(circle, $centerColor, $outsideColor)
|
415
|
+
background-repeat: no-repeat
|
416
|
+
// Opera cannot do radial gradients yet
|
417
|
+
|
418
|
+
=gradient-striped($color, $angle: -45deg)
|
419
|
+
background-color: $color
|
420
|
+
background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent))
|
421
|
+
background-image: -webkit-linear-gradient($angle, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)
|
422
|
+
background-image: -moz-linear-gradient($angle, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)
|
423
|
+
background-image: -ms-linear-gradient($angle, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)
|
424
|
+
background-image: -o-linear-gradient($angle, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)
|
425
|
+
//background-image: linear-gradient($angle, rgba(255,255,255,.15) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.15) 50%, rgba(255,255,255,.15) 75%, transparent 75%, transparent);
|
426
|
+
|
427
|
+
// Gradient Bar Colors for buttons and alerts
|
428
|
+
=gradientBar($primaryColor, $secondaryColor)
|
429
|
+
+gradient-vertical($primaryColor, $secondaryColor)
|
430
|
+
border-color: $secondaryColor $secondaryColor darken($secondaryColor, 15%)
|
431
|
+
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) fade-in(rgba(0, 0, 0, 0.1), 0.15)
|
432
|
+
|
433
|
+
// Reset filters for IE
|
434
|
+
=reset-filter
|
435
|
+
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false)
|
436
|
+
|
437
|
+
// Mixin for generating button backgrounds
|
438
|
+
// ---------------------------------------
|
439
|
+
=buttonBackground($startColor, $endColor)
|
440
|
+
// gradientBar will set the background to a pleasing blend of these, to support IE<=9
|
441
|
+
+gradientBar($startColor, $endColor)
|
442
|
+
+reset-filter
|
443
|
+
// in these cases the gradient won't cover the background, so we override
|
444
|
+
&:hover, &:active, &.active, &.disabled, &[disabled]
|
445
|
+
background-color: $endColor
|
446
|
+
// IE 7 + 8 can't handle box-shadow to show active, so we darken a bit ourselves
|
447
|
+
&:active,
|
448
|
+
&.active
|
449
|
+
background-color: darken($endColor, 10%) #{"\9"}
|
450
|
+
|
451
|
+
// COMPONENT MIXINS
|
452
|
+
// --------------------------------------------------
|
453
|
+
|
454
|
+
// POPOVER ARROWS
|
455
|
+
// -------------------------
|
456
|
+
// For tipsies and popovers
|
457
|
+
=popoverArrow-top($arrowWidth: 5px)
|
458
|
+
bottom: 0
|
459
|
+
left: 50%
|
460
|
+
margin-left: -$arrowWidth
|
461
|
+
border-left: $arrowWidth solid transparent
|
462
|
+
border-right: $arrowWidth solid transparent
|
463
|
+
border-top: $arrowWidth solid $black
|
464
|
+
|
465
|
+
=popoverArrow-left($arrowWidth: 5px)
|
466
|
+
top: 50%
|
467
|
+
right: 0
|
468
|
+
margin-top: -$arrowWidth
|
469
|
+
border-top: $arrowWidth solid transparent
|
470
|
+
border-bottom: $arrowWidth solid transparent
|
471
|
+
border-left: $arrowWidth solid $black
|
472
|
+
|
473
|
+
=popoverArrow-bottom($arrowWidth: 5px)
|
474
|
+
top: 0
|
475
|
+
left: 50%
|
476
|
+
margin-left: -$arrowWidth
|
477
|
+
border-left: $arrowWidth solid transparent
|
478
|
+
border-right: $arrowWidth solid transparent
|
479
|
+
border-bottom: $arrowWidth solid $black
|
480
|
+
|
481
|
+
=popoverArrow-right($arrowWidth: 5px)
|
482
|
+
top: 50%
|
483
|
+
left: 0
|
484
|
+
margin-top: -$arrowWidth
|
485
|
+
border-top: $arrowWidth solid transparent
|
486
|
+
border-bottom: $arrowWidth solid transparent
|
487
|
+
border-right: $arrowWidth solid $black
|
@@ -0,0 +1,84 @@
|
|
1
|
+
// MODALS
|
2
|
+
// ------
|
3
|
+
|
4
|
+
// Recalculate z-index where appropriate
|
5
|
+
.modal-open
|
6
|
+
.dropdown-menu
|
7
|
+
z-index: $zindexDropdown + $zindexModal
|
8
|
+
.dropdown.open
|
9
|
+
*z-index: $zindexDropdown + $zindexModal
|
10
|
+
.popover
|
11
|
+
z-index: $zindexPopover + $zindexModal
|
12
|
+
.tooltip
|
13
|
+
z-index: $zindexTooltip + $zindexModal
|
14
|
+
|
15
|
+
// Background
|
16
|
+
.modal-backdrop
|
17
|
+
position: fixed
|
18
|
+
top: 0
|
19
|
+
right: 0
|
20
|
+
bottom: 0
|
21
|
+
left: 0
|
22
|
+
z-index: $zindexModalBackdrop
|
23
|
+
background-color: $black
|
24
|
+
// Fade for backdrop
|
25
|
+
&.fade
|
26
|
+
opacity: 0
|
27
|
+
|
28
|
+
.modal-backdrop,
|
29
|
+
.modal-backdrop.fade.in
|
30
|
+
+opacity(80)
|
31
|
+
|
32
|
+
// Base modal
|
33
|
+
.modal
|
34
|
+
position: fixed
|
35
|
+
top: 50%
|
36
|
+
left: 50%
|
37
|
+
z-index: $zindexModal
|
38
|
+
max-height: 500px
|
39
|
+
overflow: auto
|
40
|
+
width: 560px
|
41
|
+
margin: -250px 0 0 -280px
|
42
|
+
background-color: $white
|
43
|
+
border: 1px solid #999
|
44
|
+
border: 1px solid rgba(0, 0, 0, 0.3)
|
45
|
+
*border: 1px solid #999
|
46
|
+
/* IE6-7
|
47
|
+
+border-radius(6px)
|
48
|
+
+box-shadow(0 3px 7px rgba(0, 0, 0, 0.3))
|
49
|
+
+background-clip(padding-box)
|
50
|
+
&.fade
|
51
|
+
+transition(opacity 0.3s linear)
|
52
|
+
top: -25%
|
53
|
+
&.fade.in
|
54
|
+
top: 50%
|
55
|
+
|
56
|
+
.modal-header
|
57
|
+
padding: 9px 15px
|
58
|
+
border-bottom: 1px solid #eee
|
59
|
+
// Close icon
|
60
|
+
.close
|
61
|
+
margin-top: 2px
|
62
|
+
|
63
|
+
// Body (where all modal content resises)
|
64
|
+
.modal-body
|
65
|
+
padding: 15px
|
66
|
+
|
67
|
+
// Remove bottom margin if need be
|
68
|
+
.modal-body .modal-form
|
69
|
+
margin-bottom: 0
|
70
|
+
|
71
|
+
// Footer (for actions)
|
72
|
+
.modal-footer
|
73
|
+
padding: 14px 15px 15px
|
74
|
+
margin-bottom: 0
|
75
|
+
background-color: #f5f5f5
|
76
|
+
border-top: 1px solid #ddd
|
77
|
+
+border-radius(0 0 6px 6px)
|
78
|
+
+box-shadow(inset 0 1px 0 $white)
|
79
|
+
+clearfix
|
80
|
+
.btn
|
81
|
+
float: right
|
82
|
+
margin-left: 5px
|
83
|
+
margin-bottom: 0
|
84
|
+
// account for input[type="submit"] which gets the bottom margin like all other inputs
|