bourbon 4.0.2 → 4.1.0

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 (110) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +6 -6
  3. data/.npmignore +12 -9
  4. data/CONTRIBUTING.md +34 -0
  5. data/Gemfile +0 -1
  6. data/{LICENSE → LICENSE.md} +3 -3
  7. data/README.md +130 -0
  8. data/app/assets/stylesheets/_bourbon-deprecated-upcoming.scss +399 -5
  9. data/app/assets/stylesheets/_bourbon.scss +14 -7
  10. data/app/assets/stylesheets/addons/_clearfix.scss +11 -16
  11. data/app/assets/stylesheets/addons/_ellipsis.scss +1 -0
  12. data/app/assets/stylesheets/addons/_hide-text.scss +4 -2
  13. data/app/assets/stylesheets/addons/_html5-input-types.scss +4 -0
  14. data/app/assets/stylesheets/addons/_position.scss +13 -19
  15. data/app/assets/stylesheets/addons/_size.scss +17 -7
  16. data/app/assets/stylesheets/addons/_word-wrap.scss +3 -1
  17. data/app/assets/stylesheets/css3/_background.scss +1 -1
  18. data/app/assets/stylesheets/css3/_border-radius.scss +14 -14
  19. data/app/assets/stylesheets/css3/_flex-box.scss +151 -152
  20. data/app/assets/stylesheets/css3/_font-face.scss +17 -16
  21. data/app/assets/stylesheets/css3/_hidpi-media-query.scss +2 -2
  22. data/app/assets/stylesheets/css3/_selection.scss +14 -0
  23. data/app/assets/stylesheets/css3/_text-decoration.scss +19 -0
  24. data/app/assets/stylesheets/functions/_contains.scss +12 -0
  25. data/app/assets/stylesheets/functions/_is-length.scss +7 -0
  26. data/app/assets/stylesheets/functions/_is-size.scss +6 -0
  27. data/app/assets/stylesheets/functions/_modular-scale.scss +4 -1
  28. data/app/assets/stylesheets/helpers/_font-source-declaration.scss +36 -0
  29. data/app/assets/stylesheets/helpers/_is-num.scss +4 -7
  30. data/bourbon.gemspec +13 -16
  31. data/bower.json +25 -8
  32. data/lib/bourbon/version.rb +1 -1
  33. data/package.json +18 -14
  34. data/sache.json +5 -0
  35. metadata +40 -108
  36. data/Gemfile.lock +0 -49
  37. data/app/assets/stylesheets/addons/_button.scss +0 -374
  38. data/app/assets/stylesheets/functions/_flex-grid.scss +0 -39
  39. data/app/assets/stylesheets/functions/_golden-ratio.scss +0 -3
  40. data/app/assets/stylesheets/functions/_grid-width.scss +0 -13
  41. data/dist/_bourbon-deprecated-upcoming.scss +0 -8
  42. data/dist/_bourbon.scss +0 -79
  43. data/dist/addons/_button.scss +0 -374
  44. data/dist/addons/_clearfix.scss +0 -23
  45. data/dist/addons/_directional-values.scss +0 -111
  46. data/dist/addons/_ellipsis.scss +0 -7
  47. data/dist/addons/_font-family.scss +0 -5
  48. data/dist/addons/_hide-text.scss +0 -10
  49. data/dist/addons/_html5-input-types.scss +0 -86
  50. data/dist/addons/_position.scss +0 -32
  51. data/dist/addons/_prefixer.scss +0 -45
  52. data/dist/addons/_retina-image.scss +0 -31
  53. data/dist/addons/_size.scss +0 -16
  54. data/dist/addons/_timing-functions.scss +0 -32
  55. data/dist/addons/_triangle.scss +0 -83
  56. data/dist/addons/_word-wrap.scss +0 -8
  57. data/dist/css3/_animation.scss +0 -52
  58. data/dist/css3/_appearance.scss +0 -3
  59. data/dist/css3/_backface-visibility.scss +0 -6
  60. data/dist/css3/_background-image.scss +0 -42
  61. data/dist/css3/_background.scss +0 -55
  62. data/dist/css3/_border-image.scss +0 -59
  63. data/dist/css3/_border-radius.scss +0 -22
  64. data/dist/css3/_box-sizing.scss +0 -4
  65. data/dist/css3/_calc.scss +0 -4
  66. data/dist/css3/_columns.scss +0 -47
  67. data/dist/css3/_filter.scss +0 -5
  68. data/dist/css3/_flex-box.scss +0 -321
  69. data/dist/css3/_font-face.scss +0 -23
  70. data/dist/css3/_font-feature-settings.scss +0 -10
  71. data/dist/css3/_hidpi-media-query.scss +0 -10
  72. data/dist/css3/_hyphens.scss +0 -4
  73. data/dist/css3/_image-rendering.scss +0 -14
  74. data/dist/css3/_keyframes.scss +0 -35
  75. data/dist/css3/_linear-gradient.scss +0 -38
  76. data/dist/css3/_perspective.scss +0 -8
  77. data/dist/css3/_placeholder.scss +0 -8
  78. data/dist/css3/_radial-gradient.scss +0 -39
  79. data/dist/css3/_transform.scss +0 -15
  80. data/dist/css3/_transition.scss +0 -77
  81. data/dist/css3/_user-select.scss +0 -3
  82. data/dist/functions/_assign.scss +0 -11
  83. data/dist/functions/_color-lightness.scss +0 -13
  84. data/dist/functions/_flex-grid.scss +0 -39
  85. data/dist/functions/_golden-ratio.scss +0 -3
  86. data/dist/functions/_grid-width.scss +0 -13
  87. data/dist/functions/_modular-scale.scss +0 -66
  88. data/dist/functions/_px-to-em.scss +0 -13
  89. data/dist/functions/_px-to-rem.scss +0 -15
  90. data/dist/functions/_strip-units.scss +0 -5
  91. data/dist/functions/_tint-shade.scss +0 -9
  92. data/dist/functions/_transition-property-name.scss +0 -22
  93. data/dist/functions/_unpack.scss +0 -17
  94. data/dist/helpers/_convert-units.scss +0 -15
  95. data/dist/helpers/_gradient-positions-parser.scss +0 -13
  96. data/dist/helpers/_is-num.scss +0 -8
  97. data/dist/helpers/_linear-angle-parser.scss +0 -25
  98. data/dist/helpers/_linear-gradient-parser.scss +0 -41
  99. data/dist/helpers/_linear-positions-parser.scss +0 -61
  100. data/dist/helpers/_linear-side-corner-parser.scss +0 -31
  101. data/dist/helpers/_radial-arg-parser.scss +0 -69
  102. data/dist/helpers/_radial-gradient-parser.scss +0 -50
  103. data/dist/helpers/_radial-positions-parser.scss +0 -18
  104. data/dist/helpers/_render-gradients.scss +0 -26
  105. data/dist/helpers/_shape-size-stripper.scss +0 -10
  106. data/dist/helpers/_str-to-num.scss +0 -50
  107. data/dist/settings/_asset-pipeline.scss +0 -1
  108. data/dist/settings/_prefixer.scss +0 -6
  109. data/dist/settings/_px-to-em.scss +0 -1
  110. data/readme.md +0 -105
@@ -64,34 +64,34 @@
64
64
  // 2011 - display (flexbox | inline-flexbox)
65
65
  // 2012 - display (flex | inline-flex)
66
66
  @mixin display($value) {
67
- // flex | inline-flex
68
- @if $value == "flex" {
69
- // 2009
70
- display: -webkit-box;
71
- display: -moz-box;
72
- display: box;
73
-
74
- // 2012
75
- display: -webkit-flex;
76
- display: -moz-flex;
77
- display: -ms-flexbox; // 2011 (IE 10)
78
- display: flex;
79
- }
80
-
81
- @elseif $value == "inline-flex" {
82
- display: -webkit-inline-box;
83
- display: -moz-inline-box;
84
- display: inline-box;
85
-
86
- display: -webkit-inline-flex;
87
- display: -moz-inline-flex;
88
- display: -ms-inline-flexbox;
89
- display: inline-flex;
90
- }
91
-
92
- @else {
93
- display: $value;
94
- }
67
+ // flex | inline-flex
68
+ @if $value == "flex" {
69
+ // 2009
70
+ display: -webkit-box;
71
+ display: -moz-box;
72
+ display: box;
73
+
74
+ // 2012
75
+ display: -webkit-flex;
76
+ display: -moz-flex;
77
+ display: -ms-flexbox; // 2011 (IE 10)
78
+ display: flex;
79
+ }
80
+
81
+ @else if $value == "inline-flex" {
82
+ display: -webkit-inline-box;
83
+ display: -moz-inline-box;
84
+ display: inline-box;
85
+
86
+ display: -webkit-inline-flex;
87
+ display: -moz-inline-flex;
88
+ display: -ms-inline-flexbox;
89
+ display: inline-flex;
90
+ }
91
+
92
+ @else {
93
+ display: $value;
94
+ }
95
95
  }
96
96
 
97
97
  // 2009 - box-flex (integer)
@@ -99,56 +99,56 @@
99
99
  // 2012 - flex (integer integer width)
100
100
  @mixin flex($value) {
101
101
 
102
- // Grab flex-grow for older browsers.
103
- $flex-grow: nth($value, 1);
102
+ // Grab flex-grow for older browsers.
103
+ $flex-grow: nth($value, 1);
104
104
 
105
- // 2009
106
- @include prefixer(box-flex, $flex-grow, webkit moz spec);
105
+ // 2009
106
+ @include prefixer(box-flex, $flex-grow, webkit moz spec);
107
107
 
108
- // 2011 (IE 10), 2012
109
- @include prefixer(flex, $value, webkit moz ms spec);
108
+ // 2011 (IE 10), 2012
109
+ @include prefixer(flex, $value, webkit moz ms spec);
110
110
  }
111
111
 
112
112
  // 2009 - box-orient ( horizontal | vertical | inline-axis | block-axis)
113
- // - box-direction (normal | reverse)
113
+ // - box-direction (normal | reverse)
114
114
  // 2011 - flex-direction (row | row-reverse | column | column-reverse)
115
115
  // 2012 - flex-direction (row | row-reverse | column | column-reverse)
116
116
  @mixin flex-direction($value: row) {
117
117
 
118
- // Alt values.
119
- $value-2009: $value;
120
- $value-2011: $value;
121
- $direction: "normal";
118
+ // Alt values.
119
+ $value-2009: $value;
120
+ $value-2011: $value;
121
+ $direction: "normal";
122
122
 
123
- @if $value == row {
124
- $value-2009: horizontal;
125
- }
123
+ @if $value == row {
124
+ $value-2009: horizontal;
125
+ }
126
126
 
127
- @elseif $value == "row-reverse" {
128
- $value-2009: horizontal;
129
- $direction: reverse;
130
- }
127
+ @else if $value == "row-reverse" {
128
+ $value-2009: horizontal;
129
+ $direction: reverse;
130
+ }
131
131
 
132
- @elseif $value == column {
133
- $value-2009: vertical;
134
- }
132
+ @else if $value == column {
133
+ $value-2009: vertical;
134
+ }
135
135
 
136
- @elseif $value == "column-reverse" {
137
- $value-2009: vertical;
138
- $direction: reverse;
139
- }
136
+ @else if $value == "column-reverse" {
137
+ $value-2009: vertical;
138
+ $direction: reverse;
139
+ }
140
140
 
141
- // 2009
142
- @include prefixer(box-orient, $value-2009, webkit moz spec);
143
- @if $direction == "reverse" {
144
- @include prefixer(box-direction, $direction, webkit moz spec);
145
- }
141
+ // 2009
142
+ @include prefixer(box-orient, $value-2009, webkit moz spec);
143
+ @if $direction == "reverse" {
144
+ @include prefixer(box-direction, $direction, webkit moz spec);
145
+ }
146
146
 
147
- // 2012
148
- @include prefixer(flex-direction, $value, webkit moz spec);
147
+ // 2012
148
+ @include prefixer(flex-direction, $value, webkit moz spec);
149
149
 
150
- // 2011 (IE 10)
151
- -ms-flex-direction: $value;
150
+ // 2011 (IE 10)
151
+ -ms-flex-direction: $value;
152
152
  }
153
153
 
154
154
  // 2009 - box-lines (single | multiple)
@@ -156,94 +156,94 @@
156
156
  // 2012 - flex-wrap (nowrap | wrap | wrap-reverse)
157
157
  @mixin flex-wrap($value: nowrap) {
158
158
 
159
- // Alt values.
160
- $alt-value: $value;
161
- @if $value == nowrap {
162
- $alt-value: single;
163
- }
159
+ // Alt values
160
+ $alt-value: $value;
161
+ @if $value == nowrap {
162
+ $alt-value: single;
163
+ }
164
164
 
165
- @elseif $value == wrap {
166
- $alt-value: multiple;
167
- }
165
+ @else if $value == wrap {
166
+ $alt-value: multiple;
167
+ }
168
168
 
169
- @elseif $value == "wrap-reverse" {
170
- $alt-value: multiple;
171
- }
169
+ @else if $value == "wrap-reverse" {
170
+ $alt-value: multiple;
171
+ }
172
172
 
173
- @include prefixer(box-lines, $alt-value, webkit moz spec);
174
- @include prefixer(flex-wrap, $value, webkit moz ms spec);
173
+ @include prefixer(box-lines, $alt-value, webkit moz spec);
174
+ @include prefixer(flex-wrap, $value, webkit moz ms spec);
175
175
  }
176
176
 
177
177
  // 2009 - TODO: parse values into flex-direction/flex-wrap
178
178
  // 2011 - TODO: parse values into flex-direction/flex-wrap
179
179
  // 2012 - flex-flow (flex-direction || flex-wrap)
180
180
  @mixin flex-flow($value) {
181
- @include prefixer(flex-flow, $value, webkit moz spec);
181
+ @include prefixer(flex-flow, $value, webkit moz spec);
182
182
  }
183
183
 
184
184
  // 2009 - box-ordinal-group (integer)
185
185
  // 2011 - flex-order (integer)
186
186
  // 2012 - order (integer)
187
187
  @mixin order($int: 0) {
188
- // 2009
189
- @include prefixer(box-ordinal-group, $int, webkit moz spec);
188
+ // 2009
189
+ @include prefixer(box-ordinal-group, $int, webkit moz spec);
190
190
 
191
- // 2012
192
- @include prefixer(order, $int, webkit moz spec);
191
+ // 2012
192
+ @include prefixer(order, $int, webkit moz spec);
193
193
 
194
- // 2011 (IE 10)
195
- -ms-flex-order: $int;
194
+ // 2011 (IE 10)
195
+ -ms-flex-order: $int;
196
196
  }
197
197
 
198
198
  // 2012 - flex-grow (number)
199
199
  @mixin flex-grow($number: 0) {
200
- @include prefixer(flex-grow, $number, webkit moz spec);
201
- -ms-flex-positive: $number;
200
+ @include prefixer(flex-grow, $number, webkit moz spec);
201
+ -ms-flex-positive: $number;
202
202
  }
203
203
 
204
204
  // 2012 - flex-shrink (number)
205
205
  @mixin flex-shrink($number: 1) {
206
- @include prefixer(flex-shrink, $number, webkit moz spec);
207
- -ms-flex-negative: $number;
206
+ @include prefixer(flex-shrink, $number, webkit moz spec);
207
+ -ms-flex-negative: $number;
208
208
  }
209
209
 
210
210
  // 2012 - flex-basis (number)
211
211
  @mixin flex-basis($width: auto) {
212
- @include prefixer(flex-basis, $width, webkit moz spec);
213
- -ms-flex-preferred-size: $width;
212
+ @include prefixer(flex-basis, $width, webkit moz spec);
213
+ -ms-flex-preferred-size: $width;
214
214
  }
215
215
 
216
216
  // 2009 - box-pack (start | end | center | justify)
217
217
  // 2011 - flex-pack (start | end | center | justify)
218
218
  // 2012 - justify-content (flex-start | flex-end | center | space-between | space-around)
219
- @mixin justify-content ($value: flex-start) {
219
+ @mixin justify-content($value: flex-start) {
220
220
 
221
- // Alt values.
222
- $alt-value: $value;
223
- @if $value == "flex-start" {
224
- $alt-value: start;
225
- }
221
+ // Alt values.
222
+ $alt-value: $value;
223
+ @if $value == "flex-start" {
224
+ $alt-value: start;
225
+ }
226
226
 
227
- @elseif $value == "flex-end" {
228
- $alt-value: end;
229
- }
227
+ @else if $value == "flex-end" {
228
+ $alt-value: end;
229
+ }
230
230
 
231
- @elseif $value == "space-between" {
232
- $alt-value: justify;
233
- }
231
+ @else if $value == "space-between" {
232
+ $alt-value: justify;
233
+ }
234
234
 
235
- @elseif $value == "space-around" {
236
- $alt-value: center;
237
- }
235
+ @else if $value == "space-around" {
236
+ $alt-value: distribute;
237
+ }
238
238
 
239
- // 2009
240
- @include prefixer(box-pack, $alt-value, webkit moz spec);
239
+ // 2009
240
+ @include prefixer(box-pack, $alt-value, webkit moz spec);
241
241
 
242
- // 2012
243
- @include prefixer(justify-content, $value, webkit moz ms o spec);
242
+ // 2012
243
+ @include prefixer(justify-content, $value, webkit moz ms o spec);
244
244
 
245
- // 2011 (IE 10)
246
- -ms-flex-pack: $alt-value;
245
+ // 2011 (IE 10)
246
+ -ms-flex-pack: $alt-value;
247
247
  }
248
248
 
249
249
  // 2009 - box-align (start | end | center | baseline | stretch)
@@ -251,71 +251,70 @@
251
251
  // 2012 - align-items (flex-start | flex-end | center | baseline | stretch)
252
252
  @mixin align-items($value: stretch) {
253
253
 
254
- $alt-value: $value;
254
+ $alt-value: $value;
255
255
 
256
- @if $value == "flex-start" {
257
- $alt-value: start;
258
- }
256
+ @if $value == "flex-start" {
257
+ $alt-value: start;
258
+ }
259
259
 
260
- @elseif $value == "flex-end" {
261
- $alt-value: end;
262
- }
260
+ @else if $value == "flex-end" {
261
+ $alt-value: end;
262
+ }
263
263
 
264
- // 2009
265
- @include prefixer(box-align, $alt-value, webkit moz spec);
264
+ // 2009
265
+ @include prefixer(box-align, $alt-value, webkit moz spec);
266
266
 
267
- // 2012
268
- @include prefixer(align-items, $value, webkit moz ms o spec);
269
-
270
- // 2011 (IE 10)
271
- -ms-flex-align: $alt-value;
267
+ // 2012
268
+ @include prefixer(align-items, $value, webkit moz ms o spec);
269
+
270
+ // 2011 (IE 10)
271
+ -ms-flex-align: $alt-value;
272
272
  }
273
273
 
274
274
  // 2011 - flex-item-align (auto | start | end | center | baseline | stretch)
275
275
  // 2012 - align-self (auto | flex-start | flex-end | center | baseline | stretch)
276
276
  @mixin align-self($value: auto) {
277
277
 
278
- $value-2011: $value;
279
- @if $value == "flex-start" {
280
- $value-2011: start;
281
- }
278
+ $value-2011: $value;
279
+ @if $value == "flex-start" {
280
+ $value-2011: start;
281
+ }
282
282
 
283
- @elseif $value == "flex-end" {
284
- $value-2011: end;
285
- }
283
+ @else if $value == "flex-end" {
284
+ $value-2011: end;
285
+ }
286
286
 
287
- // 2012
288
- @include prefixer(align-self, $value, webkit moz spec);
287
+ // 2012
288
+ @include prefixer(align-self, $value, webkit moz spec);
289
289
 
290
- // 2011 (IE 10)
291
- -ms-flex-item-align: $value-2011;
290
+ // 2011 (IE 10)
291
+ -ms-flex-item-align: $value-2011;
292
292
  }
293
293
 
294
294
  // 2011 - flex-line-pack (start | end | center | justify | distribute | stretch)
295
295
  // 2012 - align-content (flex-start | flex-end | center | space-between | space-around | stretch)
296
296
  @mixin align-content($value: stretch) {
297
297
 
298
- $value-2011: $value;
299
- @if $value == "flex-start" {
300
- $value-2011: start;
301
- }
298
+ $value-2011: $value;
299
+ @if $value == "flex-start" {
300
+ $value-2011: start;
301
+ }
302
302
 
303
- @elseif $value == "flex-end" {
304
- $value-2011: end;
305
- }
303
+ @else if $value == "flex-end" {
304
+ $value-2011: end;
305
+ }
306
306
 
307
- @elseif $value == "space-between" {
308
- $value-2011: justify;
309
- }
307
+ @else if $value == "space-between" {
308
+ $value-2011: justify;
309
+ }
310
310
 
311
- @elseif $value == "space-around" {
312
- $value-2011: distribute;
313
- }
311
+ @else if $value == "space-around" {
312
+ $value-2011: distribute;
313
+ }
314
314
 
315
- // 2012
316
- @include prefixer(align-content, $value, webkit moz spec);
315
+ // 2012
316
+ @include prefixer(align-content, $value, webkit moz spec);
317
317
 
318
- // 2011 (IE 10)
319
- -ms-flex-line-pack: $value-2011;
318
+ // 2011 (IE 10)
319
+ -ms-flex-line-pack: $value-2011;
320
320
  }
321
-
@@ -1,23 +1,24 @@
1
- // Order of the includes matters, and it is: normal, bold, italic, bold+italic.
1
+ @mixin font-face(
2
+ $font-family,
3
+ $file-path,
4
+ $weight: normal,
5
+ $style: normal,
6
+ $asset-pipeline: $asset-pipeline,
7
+ $file-formats: eot woff2 woff ttf svg) {
8
+
9
+ $font-url-prefix: font-url-prefixer($asset-pipeline);
2
10
 
3
- @mixin font-face($font-family, $file-path, $weight: normal, $style: normal, $asset-pipeline: $asset-pipeline) {
4
11
  @font-face {
5
12
  font-family: $font-family;
6
- font-weight: $weight;
7
13
  font-style: $style;
14
+ font-weight: $weight;
8
15
 
9
- @if $asset-pipeline == true {
10
- src: font-url('#{$file-path}.eot');
11
- src: font-url('#{$file-path}.eot?#iefix') format('embedded-opentype'),
12
- font-url('#{$file-path}.woff') format('woff'),
13
- font-url('#{$file-path}.ttf') format('truetype'),
14
- font-url('#{$file-path}.svg##{$font-family}') format('svg');
15
- } @else {
16
- src: url('#{$file-path}.eot');
17
- src: url('#{$file-path}.eot?#iefix') format('embedded-opentype'),
18
- url('#{$file-path}.woff') format('woff'),
19
- url('#{$file-path}.ttf') format('truetype'),
20
- url('#{$file-path}.svg##{$font-family}') format('svg');
21
- }
16
+ src: font-source-declaration(
17
+ $font-family,
18
+ $file-path,
19
+ $asset-pipeline,
20
+ $file-formats,
21
+ $font-url-prefix
22
+ );
22
23
  }
23
24
  }
@@ -3,8 +3,8 @@
3
3
  @media only screen and (-webkit-min-device-pixel-ratio: $ratio),
4
4
  only screen and (min--moz-device-pixel-ratio: $ratio),
5
5
  only screen and (-o-min-device-pixel-ratio: #{$ratio}/1),
6
- only screen and (min-resolution: #{round($ratio*96)}dpi),
7
- only screen and (min-resolution: #{$ratio}dppx) {
6
+ only screen and (min-resolution: round($ratio * 96dpi)),
7
+ only screen and (min-resolution: $ratio * 1dppx) {
8
8
  @content;
9
9
  }
10
10
  }
@@ -0,0 +1,14 @@
1
+ @mixin selection {
2
+ $before-colons: "";
3
+
4
+ @if & {
5
+ $before-colons: "&"
6
+ }
7
+
8
+ #{$before-colons}::selection {
9
+ @content;
10
+ }
11
+ #{$before-colons}::-moz-selection {
12
+ @content;
13
+ }
14
+ }
@@ -0,0 +1,19 @@
1
+ @mixin text-decoration($value) {
2
+ // <text-decoration-line> || <text-decoration-style> || <text-decoration-color>
3
+ @include prefixer(text-decoration, $value, moz);
4
+ }
5
+
6
+ @mixin text-decoration-line($line: none) {
7
+ // none || underline || overline || line-through
8
+ @include prefixer(text-decoration-line, $line, moz);
9
+ }
10
+
11
+ @mixin text-decoration-style($style: solid) {
12
+ // solid || double || dotted || dashed || wavy
13
+ @include prefixer(text-decoration-style, $style, moz webkit);
14
+ }
15
+
16
+ @mixin text-decoration-color($color: currentColor) {
17
+ // currentColor || <color>
18
+ @include prefixer(text-decoration-color, $color, moz);
19
+ }
@@ -0,0 +1,12 @@
1
+ // Test a Sass list to see if it contains a defined value
2
+ // Allows for checking if a list contains several values at once
3
+
4
+ @function contains($list, $values...) {
5
+ @each $value in $values {
6
+ @if type-of(index($list, $value)) != "number" {
7
+ @return false;
8
+ }
9
+ }
10
+
11
+ @return true;
12
+ }
@@ -0,0 +1,7 @@
1
+ // Check for a valid length
2
+
3
+ @function is-length($value) {
4
+ @return type-of($value) != "null" and (str-slice($value + "", 1, 4) == 'calc'
5
+ or index(auto inherit initial 0, $value)
6
+ or (type-of($value) == "number" and not(unitless($value))));
7
+ }
@@ -0,0 +1,6 @@
1
+ // Check for a valid size
2
+
3
+ @function is-size($value) {
4
+ @return is-length($value)
5
+ or contains("fill" "fit-content" "min-content" "max-content", $value);
6
+ }
@@ -17,7 +17,10 @@ $major-eleventh: 2.667;
17
17
  $major-twelfth: 3;
18
18
  $double-octave: 4;
19
19
 
20
- @function modular-scale($value, $increment, $ratio) {
20
+ $modular-scale-ratio: $perfect-fourth !default;
21
+ $modular-scale-base: em($em-base) !default;
22
+
23
+ @function modular-scale($increment, $value: $modular-scale-base, $ratio: $modular-scale-ratio) {
21
24
  $v1: nth($value, 1);
22
25
  $v2: nth($value, length($value));
23
26
  $value: $v1;
@@ -0,0 +1,36 @@
1
+ // Used for creating the source string for fonts using @font-face
2
+ // Reference: http://goo.gl/Ru1bKP
3
+
4
+ @function font-url-prefixer($asset-pipeline) {
5
+ @if $asset-pipeline == true {
6
+ @return font-url;
7
+ } @else {
8
+ @return url;
9
+ }
10
+ }
11
+
12
+ @function font-source-declaration(
13
+ $font-family,
14
+ $file-path,
15
+ $asset-pipeline,
16
+ $file-formats,
17
+ $font-url) {
18
+
19
+ $src: null;
20
+
21
+ $formats-map: (
22
+ eot: $font-url + "(\"#{$file-path}.eot?#iefix\")" format("embedded-opentype"),
23
+ woff2: $font-url + "(\"#{$file-path}.woff2\")" format("woff2"),
24
+ woff: $font-url + "(\"#{$file-path}.woff\")" format("woff"),
25
+ ttf: $font-url + "(\"#{$file-path}.ttf\")" format("truetype"),
26
+ svg: $font-url + "(\"#{$file-path}.svg##{$font-family}\")" format("svg")
27
+ );
28
+
29
+ @each $format, $file-path in $formats-map {
30
+ @if contains($file-formats, $format) {
31
+ $src: append($src, $file-path, comma);
32
+ }
33
+ }
34
+
35
+ @return $src;
36
+ }
@@ -1,8 +1,5 @@
1
- //************************************************************************//
2
- // Helper for linear-gradient-parser
3
- //************************************************************************//
4
- @function _is-num($char) {
5
- $values: '0' '1' '2' '3' '4' '5' '6' '7' '8' '9' 0 1 2 3 4 5 6 7 8 9;
6
- $index: index($values, $char);
7
- @return if($index, true, false);
1
+ // Check for a valid number
2
+
3
+ @function _is-num($value) {
4
+ @return contains('0' '1' '2' '3' '4' '5' '6' '7' '8' '9' 0 1 2 3 4 5 6 7 8 9, $value);
8
5
  }
data/bourbon.gemspec CHANGED
@@ -1,31 +1,28 @@
1
- # -*- encoding: utf-8 -*-
2
- $:.push File.expand_path("../lib", __FILE__)
3
- require "bourbon/version"
1
+ # coding: utf-8
2
+ $:.push File.expand_path('../lib', __FILE__)
3
+ require 'bourbon/version'
4
4
 
5
5
  Gem::Specification.new do |s|
6
- s.name = "bourbon"
6
+ s.name = 'bourbon'
7
7
  s.version = Bourbon::VERSION
8
8
  s.platform = Gem::Platform::RUBY
9
- s.authors = ["Phil LaPier", "Chad Mazzola", "Matt Jankowski", "Nick Quaranto", "Jeremy Raines", "Mike Burns", "Andres Mejia", "Travis Haynes", "Chris Lloyd", "Gabe Berke-Williams", "J. Edward Dewyea", "Reda Lemeden", "Kyle Fiedler"]
10
- s.email = ["support@thoughtbot.com"]
9
+ s.authors = ['Andres Mejia', 'Chad Mazzola', 'Chris Lloyd', 'Gabe Berke-Williams', 'J. Edward Dewyea', 'Jeremy Raines', 'Kyle Fiedler', 'Matt Jankowski', 'Mike Burns', 'Nick Quaranto', 'Phil LaPier', 'Reda Lemeden', 'Travis Haynes', 'Tyson Gach', 'Will McMahan']
10
+ s.email = 'design+bourbon@thoughtbot.com'
11
11
  s.license = 'MIT'
12
- s.homepage = "https://github.com/thoughtbot/bourbon"
13
- s.summary = "Bourbon Sass Mixins using SCSS syntax."
12
+ s.homepage = 'http://bourbon.io'
13
+ s.summary = 'A simple and lightweight mixin library for Sass'
14
14
  s.description = <<-DESC
15
- Bourbon provides a comprehensive framework of
16
- sass mixins that are designed to be as vanilla as possible. Meaning they
17
- should not deter from the original CSS syntax. The mixins contain vendor
18
- specific prefixes for all CSS3 properties for support amongst modern
19
- browsers. The prefixes also ensure graceful degradation for older browsers
20
- that support only CSS3 prefixed properties.
15
+ Bourbon is a library of pure Sass mixins that are designed to be simple and easy
16
+ to use. No configuration required. The mixins aim to be as vanilla as possible,
17
+ meaning they should be as close to the original CSS syntax as possible.
21
18
  DESC
22
19
 
23
- s.rubyforge_project = "bourbon"
20
+ s.rubyforge_project = 'bourbon'
24
21
 
25
22
  s.files = `git ls-files`.split("\n")
26
23
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
27
24
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
28
- s.require_paths = ["lib"]
25
+ s.require_paths = ['lib']
29
26
 
30
27
  s.add_dependency('sass', '~> 3.3')
31
28
  s.add_dependency('thor')