compass 0.12.7 → 0.13.alpha.4

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 (254) hide show
  1. data/README.markdown +1 -1
  2. data/Rakefile +14 -9
  3. data/VERSION.yml +6 -0
  4. data/features/command_line.feature +8 -50
  5. data/features/step_definitions/command_line_steps.rb +3 -2
  6. data/frameworks/compass/stylesheets/compass/_css3.scss +2 -0
  7. data/frameworks/compass/stylesheets/compass/_support.scss +4 -4
  8. data/frameworks/compass/stylesheets/compass/css3/_animation.scss +121 -0
  9. data/frameworks/compass/stylesheets/compass/css3/_appearance.scss +10 -6
  10. data/frameworks/compass/stylesheets/compass/css3/_background-clip.scss +32 -36
  11. data/frameworks/compass/stylesheets/compass/css3/_background-origin.scss +32 -35
  12. data/frameworks/compass/stylesheets/compass/css3/_background-size.scss +12 -15
  13. data/frameworks/compass/stylesheets/compass/css3/_border-radius.scss +27 -48
  14. data/frameworks/compass/stylesheets/compass/css3/_box-shadow.scss +22 -35
  15. data/frameworks/compass/stylesheets/compass/css3/_box-sizing.scss +12 -8
  16. data/frameworks/compass/stylesheets/compass/css3/_box.scss +57 -82
  17. data/frameworks/compass/stylesheets/compass/css3/_columns.scss +104 -71
  18. data/frameworks/compass/stylesheets/compass/css3/_filter.scss +38 -18
  19. data/frameworks/compass/stylesheets/compass/css3/_flexbox.scss +294 -0
  20. data/frameworks/compass/stylesheets/compass/css3/_font-face.scss +4 -4
  21. data/frameworks/compass/stylesheets/compass/css3/_hyphenation.scss +13 -22
  22. data/frameworks/compass/stylesheets/compass/css3/_images.scss +45 -48
  23. data/frameworks/compass/stylesheets/compass/css3/_inline-block.scss +1 -1
  24. data/frameworks/compass/stylesheets/compass/css3/_regions.scss +12 -8
  25. data/frameworks/compass/stylesheets/compass/css3/_selection.scss +31 -0
  26. data/frameworks/compass/stylesheets/compass/css3/_shared.scss +226 -2
  27. data/frameworks/compass/stylesheets/compass/css3/_text-shadow.scss +21 -26
  28. data/frameworks/compass/stylesheets/compass/css3/_transform-legacy.scss +3 -3
  29. data/frameworks/compass/stylesheets/compass/css3/_transform.scss +8 -8
  30. data/frameworks/compass/stylesheets/compass/css3/_transition.scss +3 -3
  31. data/frameworks/compass/stylesheets/compass/css3/_user-interface.scss +43 -4
  32. data/frameworks/compass/stylesheets/compass/typography/_units.scss +152 -0
  33. data/frameworks/compass/stylesheets/compass/typography/_vertical_rhythm.scss +180 -102
  34. data/frameworks/compass/stylesheets/compass/typography/lists/_horizontal-list.scss +5 -3
  35. data/frameworks/compass/stylesheets/compass/typography/lists/_inline-list.scss +6 -3
  36. data/frameworks/compass/stylesheets/compass/typography/text/_ellipsis.scss +1 -1
  37. data/frameworks/compass/stylesheets/compass/utilities/general/_float.scss +7 -3
  38. data/frameworks/compass/stylesheets/compass/utilities/general/_hacks.scss +2 -2
  39. data/frameworks/compass/stylesheets/compass/utilities/sprites/_base.scss +32 -13
  40. data/frameworks/compass/stylesheets/compass/utilities/tables/_borders.scss +14 -9
  41. data/lib/compass/actions.rb +3 -1
  42. data/lib/compass/commands/update_project.rb +1 -2
  43. data/lib/compass/commands/watch_project.rb +11 -113
  44. data/lib/compass/commands.rb +1 -1
  45. data/lib/compass/compiler.rb +8 -1
  46. data/lib/compass/configuration/data.rb +1 -1
  47. data/lib/compass/configuration/helpers.rb +2 -0
  48. data/lib/compass/exec/project_options_parser.rb +8 -0
  49. data/lib/compass/logger.rb +2 -0
  50. data/lib/compass/sass_extensions/functions/cross_browser_support.rb +1 -1
  51. data/lib/compass/sass_extensions/functions/env.rb +18 -0
  52. data/lib/compass/sass_extensions/functions/gradient_support.rb +101 -29
  53. data/lib/compass/sass_extensions/functions/image_size.rb +2 -1
  54. data/lib/compass/sass_extensions/functions/math.rb +13 -1
  55. data/lib/compass/sass_extensions/functions/sprites.rb +82 -22
  56. data/lib/compass/sass_extensions/functions/urls.rb +37 -6
  57. data/lib/compass/sass_extensions/functions/utility.rb +10 -0
  58. data/lib/compass/sass_extensions/sprites/engines/chunky_png_engine.rb +11 -9
  59. data/lib/compass/sass_extensions/sprites/image.rb +7 -2
  60. data/lib/compass/sass_extensions/sprites/image_methods.rb +5 -1
  61. data/lib/compass/sass_extensions/sprites/images.rb +29 -0
  62. data/lib/compass/sass_extensions/sprites/layout/diagonal.rb +42 -0
  63. data/lib/compass/sass_extensions/sprites/layout/horizontal.rb +66 -0
  64. data/lib/compass/sass_extensions/sprites/layout/smart.rb +33 -0
  65. data/lib/compass/sass_extensions/sprites/layout/vertical.rb +68 -0
  66. data/lib/compass/sass_extensions/sprites/layout.rb +39 -0
  67. data/lib/compass/sass_extensions/sprites/layout_methods.rb +9 -115
  68. data/lib/compass/sass_extensions/sprites/sprite_map.rb +5 -1
  69. data/lib/compass/sass_extensions/sprites/sprite_methods.rb +8 -14
  70. data/lib/compass/sass_extensions/sprites.rb +2 -0
  71. data/lib/compass/sprite_importer/content.erb +29 -24
  72. data/lib/compass/sprite_importer.rb +7 -11
  73. data/lib/compass/version.rb +10 -13
  74. data/lib/compass/watcher/compiler.rb +59 -0
  75. data/lib/compass/watcher/project_watcher.rb +111 -0
  76. data/lib/compass/watcher/watch.rb +33 -0
  77. data/lib/compass/watcher.rb +11 -0
  78. data/lib/compass.rb +2 -2
  79. data/test/fixtures/sprites/public/images/numeric/200.png +0 -0
  80. data/test/fixtures/stylesheets/busted_font_urls/config.rb +32 -0
  81. data/test/fixtures/stylesheets/busted_font_urls/css/screen.css +7 -0
  82. data/test/fixtures/stylesheets/busted_font_urls/fonts/feed.ttf +0 -0
  83. data/test/fixtures/stylesheets/busted_font_urls/fonts/grid.ttf +0 -0
  84. data/test/fixtures/stylesheets/busted_font_urls/fonts/sub/dk.ttf +0 -0
  85. data/test/fixtures/stylesheets/busted_font_urls/sass/screen.sass +11 -0
  86. data/test/fixtures/stylesheets/busted_font_urls/tmp/screen.css +7 -0
  87. data/test/fixtures/stylesheets/busted_image_urls/tmp/screen.css +9 -0
  88. data/test/fixtures/stylesheets/compass/css/animation-with-legacy-ie.css +33 -0
  89. data/test/fixtures/stylesheets/compass/css/animation.css +33 -0
  90. data/test/fixtures/stylesheets/compass/css/background-clip.css +5 -0
  91. data/test/fixtures/stylesheets/compass/css/background-origin.css +15 -0
  92. data/test/fixtures/stylesheets/compass/css/background-size.css +24 -0
  93. data/test/fixtures/stylesheets/compass/css/columns.css +27 -63
  94. data/test/fixtures/stylesheets/compass/css/flexbox.css +121 -0
  95. data/test/fixtures/stylesheets/compass/css/fonts.css +1 -1
  96. data/test/fixtures/stylesheets/compass/css/gradients.css +64 -36
  97. data/test/fixtures/stylesheets/compass/css/grid_background.css +7 -14
  98. data/test/fixtures/stylesheets/compass/css/hyphenation.css +4 -2
  99. data/test/fixtures/stylesheets/compass/css/lists.css +5 -5
  100. data/test/fixtures/stylesheets/compass/css/pie.css +0 -3
  101. data/test/fixtures/stylesheets/compass/css/regions.css +4 -2
  102. data/test/fixtures/stylesheets/compass/css/selection.css +13 -0
  103. data/test/fixtures/stylesheets/compass/css/sprites.css +251 -250
  104. data/test/fixtures/stylesheets/compass/css/text_shadow.css +6 -6
  105. data/test/fixtures/stylesheets/compass/css/transition.css +6 -0
  106. data/test/fixtures/stylesheets/compass/css/units.css +30 -0
  107. data/test/fixtures/stylesheets/compass/css/user-interface.css +22 -1
  108. data/test/fixtures/stylesheets/compass/css/utilities.css +15 -0
  109. data/test/fixtures/stylesheets/compass/css/vertical_rhythm.css +177 -8
  110. data/test/fixtures/stylesheets/compass/images/flag-s5b4f509715.png +0 -0
  111. data/test/fixtures/stylesheets/compass/sass/animation-with-legacy-ie.scss +19 -0
  112. data/test/fixtures/stylesheets/compass/sass/animation.scss +13 -0
  113. data/test/fixtures/stylesheets/compass/sass/background-clip.scss +4 -2
  114. data/test/fixtures/stylesheets/compass/sass/background-origin.scss +10 -0
  115. data/test/fixtures/stylesheets/compass/sass/background-size.scss +12 -0
  116. data/test/fixtures/stylesheets/compass/sass/columns.scss +9 -9
  117. data/test/fixtures/stylesheets/compass/sass/flexbox.scss +44 -0
  118. data/test/fixtures/stylesheets/compass/sass/gradients.sass +31 -0
  119. data/test/fixtures/stylesheets/compass/sass/selection.scss +13 -0
  120. data/test/fixtures/stylesheets/compass/sass/transition.scss +1 -1
  121. data/test/fixtures/stylesheets/compass/sass/units.scss +45 -0
  122. data/test/fixtures/stylesheets/compass/sass/user-interface.scss +13 -1
  123. data/test/fixtures/stylesheets/compass/sass/utilities.scss +10 -0
  124. data/test/fixtures/stylesheets/compass/sass/vertical_rhythm.scss +208 -7
  125. data/test/fixtures/stylesheets/envtest/css/env.css +8 -0
  126. data/test/fixtures/stylesheets/envtest/sass/env.scss +16 -0
  127. data/test/fixtures/stylesheets/envtest/tmp/env.css +14 -0
  128. data/test/fixtures/stylesheets/valid/css/simple.css +4 -0
  129. data/test/helpers/diff.rb +1 -1
  130. data/test/integrations/compass_test.rb +23 -14
  131. data/test/integrations/sprites_test.rb +305 -63
  132. data/test/test_helper.rb +5 -15
  133. data/test/units/command_line_test.rb +0 -2
  134. data/test/units/compass_module_test.rb +1 -1
  135. data/test/units/configuration_test.rb +12 -0
  136. data/test/units/regressions_test.rb +8 -8
  137. data/test/units/sass_extensions_test.rb +2 -0
  138. data/test/units/sass_extenstions/gradients_test.rb +33 -0
  139. data/test/units/sprites/image_test.rb +5 -0
  140. data/test/units/sprites/images_test.rb +46 -0
  141. data/test/units/sprites/layout_test.rb +29 -4
  142. data/test/units/watcher/compiler_test.rb +39 -0
  143. data/test/units/watcher/project_watcher_test.rb +73 -0
  144. data/test/units/watcher/watch_test.rb +42 -0
  145. metadata +171 -236
  146. checksums.yaml +0 -7
  147. data/frameworks/blueprint/stylesheets/_blueprint.scss +0 -37
  148. data/frameworks/blueprint/stylesheets/blueprint/_buttons.scss +0 -101
  149. data/frameworks/blueprint/stylesheets/blueprint/_colors.scss +0 -36
  150. data/frameworks/blueprint/stylesheets/blueprint/_debug.scss +0 -28
  151. data/frameworks/blueprint/stylesheets/blueprint/_fancy-type.scss +0 -88
  152. data/frameworks/blueprint/stylesheets/blueprint/_form.scss +0 -66
  153. data/frameworks/blueprint/stylesheets/blueprint/_grid.scss +0 -258
  154. data/frameworks/blueprint/stylesheets/blueprint/_ie.scss +0 -111
  155. data/frameworks/blueprint/stylesheets/blueprint/_interaction.scss +0 -66
  156. data/frameworks/blueprint/stylesheets/blueprint/_link-icons.scss +0 -37
  157. data/frameworks/blueprint/stylesheets/blueprint/_liquid.scss +0 -152
  158. data/frameworks/blueprint/stylesheets/blueprint/_print.scss +0 -86
  159. data/frameworks/blueprint/stylesheets/blueprint/_reset.scss +0 -3
  160. data/frameworks/blueprint/stylesheets/blueprint/_rtl.scss +0 -121
  161. data/frameworks/blueprint/stylesheets/blueprint/_scaffolding.scss +0 -52
  162. data/frameworks/blueprint/stylesheets/blueprint/_typography.scss +0 -90
  163. data/frameworks/blueprint/stylesheets/blueprint/_utilities.scss +0 -37
  164. data/frameworks/blueprint/stylesheets/blueprint/reset/_utilities.scss +0 -83
  165. data/frameworks/blueprint/templates/basic/grid.png +0 -0
  166. data/frameworks/blueprint/templates/basic/ie.sass +0 -4
  167. data/frameworks/blueprint/templates/basic/manifest.rb +0 -30
  168. data/frameworks/blueprint/templates/basic/partials/_base.sass +0 -10
  169. data/frameworks/blueprint/templates/basic/print.sass +0 -4
  170. data/frameworks/blueprint/templates/basic/screen.sass +0 -12
  171. data/frameworks/blueprint/templates/buttons/buttons/cross.png +0 -0
  172. data/frameworks/blueprint/templates/buttons/buttons/key.png +0 -0
  173. data/frameworks/blueprint/templates/buttons/buttons/tick.png +0 -0
  174. data/frameworks/blueprint/templates/buttons/buttons.sass +0 -49
  175. data/frameworks/blueprint/templates/buttons/manifest.rb +0 -17
  176. data/frameworks/blueprint/templates/link_icons/link_icons/doc.png +0 -0
  177. data/frameworks/blueprint/templates/link_icons/link_icons/email.png +0 -0
  178. data/frameworks/blueprint/templates/link_icons/link_icons/external.png +0 -0
  179. data/frameworks/blueprint/templates/link_icons/link_icons/feed.png +0 -0
  180. data/frameworks/blueprint/templates/link_icons/link_icons/im.png +0 -0
  181. data/frameworks/blueprint/templates/link_icons/link_icons/pdf.png +0 -0
  182. data/frameworks/blueprint/templates/link_icons/link_icons/visited.png +0 -0
  183. data/frameworks/blueprint/templates/link_icons/link_icons/xls.png +0 -0
  184. data/frameworks/blueprint/templates/link_icons/link_icons.sass +0 -13
  185. data/frameworks/blueprint/templates/link_icons/manifest.rb +0 -23
  186. data/frameworks/blueprint/templates/project/grid.png +0 -0
  187. data/frameworks/blueprint/templates/project/ie.sass +0 -16
  188. data/frameworks/blueprint/templates/project/manifest.rb +0 -30
  189. data/frameworks/blueprint/templates/project/partials/_base.sass +0 -11
  190. data/frameworks/blueprint/templates/project/print.sass +0 -8
  191. data/frameworks/blueprint/templates/project/screen.sass +0 -46
  192. data/frameworks/blueprint/templates/semantic/grid.png +0 -0
  193. data/frameworks/blueprint/templates/semantic/ie.sass +0 -16
  194. data/frameworks/blueprint/templates/semantic/manifest.rb +0 -33
  195. data/frameworks/blueprint/templates/semantic/partials/_base.sass +0 -10
  196. data/frameworks/blueprint/templates/semantic/partials/_form.sass +0 -6
  197. data/frameworks/blueprint/templates/semantic/partials/_page.sass +0 -17
  198. data/frameworks/blueprint/templates/semantic/partials/_two_col.sass +0 -38
  199. data/frameworks/blueprint/templates/semantic/print.sass +0 -5
  200. data/frameworks/blueprint/templates/semantic/screen.sass +0 -14
  201. data/lib/compass/commands/generate_grid_background.rb +0 -96
  202. data/lib/compass/grid_builder.rb +0 -102
  203. data/test/fixtures/stylesheets/blueprint/config.rb +0 -14
  204. data/test/fixtures/stylesheets/blueprint/css/ie.css +0 -76
  205. data/test/fixtures/stylesheets/blueprint/css/print.css +0 -56
  206. data/test/fixtures/stylesheets/blueprint/css/screen.css +0 -815
  207. data/test/fixtures/stylesheets/blueprint/css/single-imports/buttons.css +0 -56
  208. data/test/fixtures/stylesheets/blueprint/css/single-imports/colors.css +0 -80
  209. data/test/fixtures/stylesheets/blueprint/css/single-imports/debug.css +0 -11
  210. data/test/fixtures/stylesheets/blueprint/css/single-imports/fancy-type.css +0 -30
  211. data/test/fixtures/stylesheets/blueprint/css/single-imports/form.css +0 -42
  212. data/test/fixtures/stylesheets/blueprint/css/single-imports/grid.css +0 -435
  213. data/test/fixtures/stylesheets/blueprint/css/single-imports/ie.css +0 -76
  214. data/test/fixtures/stylesheets/blueprint/css/single-imports/interaction.css +0 -46
  215. data/test/fixtures/stylesheets/blueprint/css/single-imports/link-icons.css +0 -40
  216. data/test/fixtures/stylesheets/blueprint/css/single-imports/liquid.css +0 -651
  217. data/test/fixtures/stylesheets/blueprint/css/single-imports/print.css +0 -60
  218. data/test/fixtures/stylesheets/blueprint/css/single-imports/reset-utilities.css +0 -75
  219. data/test/fixtures/stylesheets/blueprint/css/single-imports/reset.css +0 -42
  220. data/test/fixtures/stylesheets/blueprint/css/single-imports/rtl.css +0 -437
  221. data/test/fixtures/stylesheets/blueprint/css/single-imports/scaffolding.css +0 -45
  222. data/test/fixtures/stylesheets/blueprint/css/single-imports/typography.css +0 -146
  223. data/test/fixtures/stylesheets/blueprint/css/single-imports/utilities.css +0 -35
  224. data/test/fixtures/stylesheets/blueprint/images/grid.png +0 -0
  225. data/test/fixtures/stylesheets/blueprint/images/link_icons/doc.png +0 -0
  226. data/test/fixtures/stylesheets/blueprint/images/link_icons/email.png +0 -0
  227. data/test/fixtures/stylesheets/blueprint/images/link_icons/external.png +0 -0
  228. data/test/fixtures/stylesheets/blueprint/images/link_icons/feed.png +0 -0
  229. data/test/fixtures/stylesheets/blueprint/images/link_icons/im.png +0 -0
  230. data/test/fixtures/stylesheets/blueprint/images/link_icons/pdf.png +0 -0
  231. data/test/fixtures/stylesheets/blueprint/images/link_icons/visited.png +0 -0
  232. data/test/fixtures/stylesheets/blueprint/images/link_icons/xls.png +0 -0
  233. data/test/fixtures/stylesheets/blueprint/sass/ie.sass +0 -3
  234. data/test/fixtures/stylesheets/blueprint/sass/print.sass +0 -3
  235. data/test/fixtures/stylesheets/blueprint/sass/screen.sass +0 -18
  236. data/test/fixtures/stylesheets/blueprint/sass/single-imports/buttons.scss +0 -4
  237. data/test/fixtures/stylesheets/blueprint/sass/single-imports/colors.scss +0 -34
  238. data/test/fixtures/stylesheets/blueprint/sass/single-imports/debug.scss +0 -3
  239. data/test/fixtures/stylesheets/blueprint/sass/single-imports/fancy-type.scss +0 -3
  240. data/test/fixtures/stylesheets/blueprint/sass/single-imports/form.scss +0 -5
  241. data/test/fixtures/stylesheets/blueprint/sass/single-imports/grid.scss +0 -3
  242. data/test/fixtures/stylesheets/blueprint/sass/single-imports/ie.scss +0 -3
  243. data/test/fixtures/stylesheets/blueprint/sass/single-imports/interaction.scss +0 -3
  244. data/test/fixtures/stylesheets/blueprint/sass/single-imports/link-icons.scss +0 -13
  245. data/test/fixtures/stylesheets/blueprint/sass/single-imports/liquid.scss +0 -3
  246. data/test/fixtures/stylesheets/blueprint/sass/single-imports/print.scss +0 -5
  247. data/test/fixtures/stylesheets/blueprint/sass/single-imports/reset-utilities.scss +0 -5
  248. data/test/fixtures/stylesheets/blueprint/sass/single-imports/reset.scss +0 -1
  249. data/test/fixtures/stylesheets/blueprint/sass/single-imports/rtl.scss +0 -3
  250. data/test/fixtures/stylesheets/blueprint/sass/single-imports/scaffolding.scss +0 -5
  251. data/test/fixtures/stylesheets/blueprint/sass/single-imports/typography.scss +0 -3
  252. data/test/fixtures/stylesheets/blueprint/sass/single-imports/utilities.scss +0 -3
  253. data/test/fixtures/stylesheets/compass/images/flag-s4798b5a210.png +0 -0
  254. data/test/units/compass_png_test.rb +0 -46
@@ -1,7 +1,16 @@
1
+ // Border Radius
2
+
1
3
  @import "shared";
2
4
 
5
+ // @private css3-feature-support variables must always include a list of five boolean values
6
+ // representing in order: -moz, -webkit, -ms, -o, -khtml
7
+ $border-radius-support: not -moz, not -webkit, not -ms, not -o, -khtml;
8
+
9
+
10
+ // The length of a border-radius to be used by default.
3
11
  $default-border-radius: 5px !default;
4
12
 
13
+
5
14
  // Round all corners by a specific amount, defaults to value of `$default-border-radius`.
6
15
  //
7
16
  // When two values are passed, the first is the horizontal radius
@@ -23,89 +32,59 @@ $default-border-radius: 5px !default;
23
32
  // -moz-border-radius: 4px / 4px;
24
33
  // -khtml-border-radius: 4px / 4px;
25
34
  // border-radius: 4px / 4px; }
26
- //
35
+ //
27
36
  // .compound {
28
37
  // -webkit-border-radius: 2px 3px;
29
38
  // -moz-border-radius: 2px 5px / 3px 6px;
30
39
  // -khtml-border-radius: 2px 5px / 3px 6px;
31
40
  // border-radius: 2px 5px / 3px 6px; }
32
- //
41
+ //
33
42
  // .crazy {
34
43
  // -webkit-border-radius: 1px 2px;
35
44
  // -moz-border-radius: 1px 3px 5px 7px / 2px 4px 6px 8px;
36
45
  // -khtml-border-radius: 1px 3px 5px 7px / 2px 4px 6px 8px;
37
46
  // border-radius: 1px 3px 5px 7px / 2px 4px 6px 8px; }
38
-
39
47
  @mixin border-radius($radius: $default-border-radius, $vertical-radius: false) {
40
48
 
41
- @if $vertical-radius {
42
- // Webkit doesn't understand the official shorthand syntax for specifying
43
- // a vertical radius unless so in case there's several we only take the first.
44
- @include experimental(border-radius, first-value-of($radius) first-value-of($vertical-radius),
45
- not -moz,
46
- -webkit,
47
- not -o,
48
- not -ms,
49
- not -khtml,
50
- not official
51
- );
52
- @include experimental("border-radius", $radius unquote("/") $vertical-radius,
53
- -moz,
54
- not -webkit,
55
- not -o,
56
- not -ms,
57
- -khtml,
58
- official
59
- );
60
- }
61
- @else {
62
- @include experimental(border-radius, $radius);
63
- }
49
+ // Legacy Webkit didn't understand the official shorthand syntax for specifying a vertical radius.
50
+ $legacy-webkit-radius: first-value-of($radius);
51
+ @if $vertical-radius { $legacy-webkit-radius: append($legacy-webkit-radius, first-value-of($vertical-radius)); }
52
+ @include experimental-only-for(border-radius, $legacy-webkit-radius, $webkit: $legacy-support-for-webkit);
53
+
54
+ // Official syntax for everyone else
55
+ $radius: if($vertical-radius, #{$radius} / #{$vertical-radius}, $radius);
56
+ @include experimental-only-for(border-radius, $radius, $moz: $legacy-support-for-mozilla);
57
+ @include experimental(border-radius, $radius, $border-radius-support...);
64
58
  }
65
59
 
66
60
  // Round radius at position by amount.
67
61
  //
68
62
  // * legal values for `$vert`: `top`, `bottom`
69
63
  // * legal values for `$horz`: `left`, `right`
70
-
71
64
  @mixin border-corner-radius($vert, $horz, $radius: $default-border-radius) {
65
+
72
66
  // Support for mozilla's syntax for specifying a corner
73
- @include experimental("border-radius-#{$vert}#{$horz}", $radius,
74
- -moz,
75
- not -webkit,
76
- not -o,
77
- not -ms,
78
- not -khtml,
79
- not official
80
- );
81
- @include experimental("border-#{$vert}-#{$horz}-radius", $radius,
82
- not -moz,
83
- -webkit,
84
- not -o,
85
- not -ms,
86
- -khtml,
87
- official
88
- );
89
-
67
+ @include experimental-only-for("border-radius-#{$vert}#{$horz}", $radius, $moz: $legacy-support-for-mozilla);
68
+
69
+ // Official syntax for everyone else
70
+ $corners: "border-#{$vert}-#{$horz}-radius";
71
+ @include experimental-only-for($corners, $radius, $webkit: $legacy-support-for-webkit);
72
+ @include experimental($corners, $radius, $border-radius-support...);
90
73
  }
91
74
 
92
75
  // Round top-left corner only
93
-
94
76
  @mixin border-top-left-radius($radius: $default-border-radius) {
95
77
  @include border-corner-radius(top, left, $radius); }
96
78
 
97
79
  // Round top-right corner only
98
-
99
80
  @mixin border-top-right-radius($radius: $default-border-radius) {
100
81
  @include border-corner-radius(top, right, $radius); }
101
82
 
102
83
  // Round bottom-left corner only
103
-
104
84
  @mixin border-bottom-left-radius($radius: $default-border-radius) {
105
85
  @include border-corner-radius(bottom, left, $radius); }
106
86
 
107
87
  // Round bottom-right corner only
108
-
109
88
  @mixin border-bottom-right-radius($radius: $default-border-radius) {
110
89
  @include border-corner-radius(bottom, right, $radius); }
111
90
 
@@ -1,69 +1,56 @@
1
- // @doc off
2
- // These defaults make the arguments optional for this mixin
3
- // If you like, set different defaults before importing.
4
- // @doc on
1
+ // Box Shadow
5
2
 
6
3
  @import "shared";
7
4
 
5
+ // @private css3-feature-support variables must always include a list of five boolean values
6
+ // representing in order: -moz, -webkit, -ms, -o, -khtml
7
+ $box-shadow-support: -moz, -webkit, not -ms, not -o, not -khtml;
8
+
8
9
 
9
10
  // The default color for box shadows
10
- $default-box-shadow-color: #333333 !default;
11
+ $default-box-shadow-color : #333333 !default;
11
12
 
12
13
  // The default horizontal offset. Positive is to the right.
13
- $default-box-shadow-h-offset: 0px !default;
14
+ $default-box-shadow-h-offset : 0px !default;
14
15
 
15
16
  // The default vertical offset. Positive is down.
16
- $default-box-shadow-v-offset: 0px !default;
17
+ $default-box-shadow-v-offset : 0px !default;
17
18
 
18
19
  // The default blur length.
19
- $default-box-shadow-blur: 5px !default;
20
+ $default-box-shadow-blur : 5px !default;
20
21
 
21
22
  // The default spread length.
22
- $default-box-shadow-spread : false !default;
23
+ $default-box-shadow-spread : false !default;
23
24
 
24
25
  // The default shadow inset: inset or false (for standard shadow).
25
- $default-box-shadow-inset : false !default;
26
+ $default-box-shadow-inset : false !default;
26
27
 
27
- // Provides cross-browser for Webkit, Gecko, and CSS3 box shadows when one or more box
28
- // shadows are needed.
29
- // Each shadow argument should adhere to the standard css3 syntax for the
30
- // box-shadow property.
31
- @mixin box-shadow(
32
- $shadow-1 : default,
33
- $shadow-2 : false,
34
- $shadow-3 : false,
35
- $shadow-4 : false,
36
- $shadow-5 : false,
37
- $shadow-6 : false,
38
- $shadow-7 : false,
39
- $shadow-8 : false,
40
- $shadow-9 : false,
41
- $shadow-10: false
42
- ) {
43
- @if $shadow-1 == default {
44
- $shadow-1 : -compass-space-list(compact(if($default-box-shadow-inset, inset, false), $default-box-shadow-h-offset, $default-box-shadow-v-offset, $default-box-shadow-blur, $default-box-shadow-spread, $default-box-shadow-color));
45
- }
46
- $shadow : compact($shadow-1, $shadow-2, $shadow-3, $shadow-4, $shadow-5, $shadow-6, $shadow-7, $shadow-8, $shadow-9, $shadow-10);
47
- @include experimental(box-shadow, $shadow,
48
- -moz, -webkit, not -o, not -ms, not -khtml, official
49
- );
28
+
29
+ // Provides cross-browser for Webkit, Gecko, and CSS3 box shadows
30
+ // when one or more box shadows are needed.
31
+ // Each shadow argument should adhere to the standard css3 syntax
32
+ // for the box-shadow property.
33
+ @mixin box-shadow($shadow...) {
34
+ $default: -compass-space-list(compact(if($default-box-shadow-inset, inset, false), $default-box-shadow-h-offset, $default-box-shadow-v-offset, $default-box-shadow-blur, $default-box-shadow-spread, $default-box-shadow-color));
35
+ $shadow: set-arglist-default($shadow, $default);
36
+ @include experimental(box-shadow, $shadow, $box-shadow-support...);
50
37
  }
51
38
 
52
39
  // Provides a single cross-browser CSS box shadow for Webkit, Gecko, and CSS3.
53
40
  // Includes default arguments for color, horizontal offset, vertical offset, blur length, spread length, and inset.
54
41
  @mixin single-box-shadow(
55
- $color : $default-box-shadow-color,
56
42
  $hoff : $default-box-shadow-h-offset,
57
43
  $voff : $default-box-shadow-v-offset,
58
44
  $blur : $default-box-shadow-blur,
59
45
  $spread : $default-box-shadow-spread,
46
+ $color : $default-box-shadow-color,
60
47
  $inset : $default-box-shadow-inset
61
48
  ) {
62
49
  @if not ($inset == true or $inset == false or $inset == inset) {
63
50
  @warn "$inset expected to be true or the inset keyword. Got #{$inset} instead. Using: inset";
64
51
  }
65
52
 
66
- @if $color == none {
53
+ @if $hoff == none {
67
54
  @include box-shadow(none);
68
55
  } @else {
69
56
  $full : $hoff $voff;
@@ -1,13 +1,17 @@
1
+ // Box Sizing
2
+
1
3
  @import "shared";
2
4
 
5
+ // @private css3-feature-support variables must always include a list of five boolean values
6
+ // representing in order: -moz, -webkit, -ms, -o, -khtml
7
+ $box-sizing-support: -moz, -webkit, not -ms, not -o, not -khtml;
8
+
9
+
3
10
  // Change the box model for Mozilla, Webkit, IE8 and the future
4
11
  //
5
- // @param $bs
6
- // [ content-box | border-box ]
7
-
8
- @mixin box-sizing($bs) {
9
- $bs: unquote($bs);
10
- @include experimental(box-sizing, $bs,
11
- -moz, -webkit, not -o, not -ms, not -khtml, official
12
- );
12
+ // @param $box-model
13
+ // [ content-box | border-box | padding-box ]
14
+ @mixin box-sizing($box-model) {
15
+ $box-model: unquote($box-model);
16
+ @include experimental(box-sizing, $box-model, $box-sizing-support...);
13
17
  }
@@ -1,111 +1,86 @@
1
+ // Flexible Box
2
+
1
3
  @import "shared";
2
4
 
3
- // display:box; must be used for any of the other flexbox mixins to work properly
4
- @mixin display-box {
5
- @include experimental-value(display, box,
6
- -moz, -webkit, not -o, -ms, not -khtml, official
7
- );
8
- }
5
+ // @private css3-feature-support variables must always include a list of five boolean values
6
+ // representing in order: -moz, -webkit, -ms, -o, -khtml
7
+ $flexbox-support: -moz, -webkit, -ms, not -o, not -khtml;
8
+
9
9
 
10
10
  // Default box orientation, assuming that the user wants something less block-like
11
- $default-box-orient: horizontal !default;
11
+ $default-box-orient : horizontal !default;
12
+
13
+ // Default box-align
14
+ $default-box-align : stretch !default;
15
+
16
+ // Default box flex
17
+ $default-box-flex : 0 !default;
18
+
19
+ // Default flex group
20
+ $default-box-flex-group : 1 !default;
21
+
22
+ // Box direction default value
23
+ $default-box-direction : normal !default;
24
+
25
+ // Default ordinal group
26
+ $default-box-ordinal-group : 1 !default;
27
+
28
+ // Default box lines
29
+ $default-box-lines : single !default;
30
+
31
+ // Default box pack
32
+ $default-box-pack : start !default;
33
+
34
+
35
+ // Apply 'display:box;' to an element.
36
+ // - must be used for any of the other flexbox mixins to work properly
37
+ @mixin display-box {
38
+ @include experimental-value(display, box, $flexbox-support...);
39
+ }
12
40
 
13
41
  // Box orientation [ horizontal | vertical | inline-axis | block-axis | inherit ]
14
- @mixin box-orient(
15
- $orientation: $default-box-orient
16
- ) {
42
+ @mixin box-orient($orientation: $default-box-orient) {
17
43
  $orientation : unquote($orientation);
18
- @include experimental(box-orient, $orientation,
19
- -moz, -webkit, not -o, -ms, not -khtml, official
20
- );
44
+ @include experimental(box-orient, $orientation, $flexbox-support...);
21
45
  }
22
46
 
23
- // Default box-align
24
- $default-box-align: stretch !default;
25
-
26
47
  // Box align [ start | end | center | baseline | stretch ]
27
- @mixin box-align(
28
- $alignment: $default-box-align
29
- ) {
48
+ @mixin box-align($alignment: $default-box-align) {
30
49
  $alignment : unquote($alignment);
31
- @include experimental(box-align, $alignment,
32
- -moz, -webkit, not -o, -ms, not -khtml, official
33
- );
50
+ @include experimental(box-align, $alignment, $flexbox-support...);
34
51
  }
35
52
 
36
- // Default box flex
37
- $default-box-flex: 0 !default;
38
-
39
- // mixin which takes an int argument for box flex. Apply this to the children inside the box.
53
+ // Takes an int argument for box flex. Apply this to the children inside the box.
40
54
  //
41
55
  // For example: "div.display-box > div.child-box" would get the box flex mixin.
42
- @mixin box-flex(
43
- $flex: $default-box-flex
44
- ) {
45
- @include experimental(box-flex, $flex,
46
- -moz, -webkit, not -o, -ms, not -khtml, official
47
- );
56
+ @mixin box-flex($flex: $default-box-flex) {
57
+ @include experimental(box-flex, $flex, $flexbox-support...);
48
58
  }
49
59
 
50
- // Default flex group
51
- $default-box-flex-group: 1 !default;
52
-
53
- // mixin which takes an int argument for flexible grouping
54
- @mixin box-flex-group(
55
- $group: $default-box-flex-group
56
- ) {
57
- @include experimental(box-flex-group, $group,
58
- -moz, -webkit, not -o, -ms, not -khtml, official
59
- );
60
+ // Takes an int argument for flexible grouping
61
+ @mixin box-flex-group($group: $default-box-flex-group) {
62
+ @include experimental(box-flex-group, $group, $flexbox-support...);
60
63
  }
61
64
 
62
- // default for ordinal group
63
- $default-box-ordinal-group: 1 !default;
64
-
65
- // mixin which takes an int argument for ordinal grouping and rearranging the order
66
- @mixin box-ordinal-group(
67
- $group: $default-box-ordinal-group
68
- ) {
69
- @include experimental(box-ordinal-group, $group,
70
- -moz, -webkit, not -o, -ms, not -khtml, official
71
- );
65
+ // Takes an int argument for ordinal grouping and rearranging the order
66
+ @mixin box-ordinal-group($group: $default-box-ordinal-group) {
67
+ @include experimental(box-ordinal-group, $group, $flexbox-support...);
72
68
  }
73
69
 
74
- // Box direction default value
75
- $default-box-direction: normal !default;
76
-
77
- // mixin for box-direction [ normal | reverse | inherit ]
78
- @mixin box-direction(
79
- $direction: $default-box-direction
80
- ) {
70
+ // Box direction [ normal | reverse | inherit ]
71
+ @mixin box-direction($direction: $default-box-direction) {
81
72
  $direction: unquote($direction);
82
- @include experimental(box-direction, $direction,
83
- -moz, -webkit, not -o, -ms, not -khtml, official
84
- );
73
+ @include experimental(box-direction, $direction, $flexbox-support...);
85
74
  }
86
75
 
87
- // default for box lines
88
- $default-box-lines: single !default;
89
-
90
- // mixin for box lines [ single | multiple ]
91
- @mixin box-lines(
92
- $lines: $default-box-lines
93
- ) {
76
+ // Box lines [ single | multiple ]
77
+ @mixin box-lines($lines: $default-box-lines) {
94
78
  $lines: unquote($lines);
95
- @include experimental(box-lines, $lines,
96
- -moz, -webkit, not -o, -ms, not -khtml, official
97
- );
79
+ @include experimental(box-lines, $lines, $flexbox-support...);
98
80
  }
99
81
 
100
- // default for box pack
101
- $default-box-pack: start !default;
102
-
103
- // mixin for box pack [ start | end | center | justify ]
104
- @mixin box-pack(
105
- $pack: $default-box-pack
106
- ) {
82
+ // Box pack [ start | end | center | justify ]
83
+ @mixin box-pack($pack: $default-box-pack) {
107
84
  $pack: unquote($pack);
108
- @include experimental(box-pack, $pack,
109
- -moz, -webkit, not -o, -ms, not -khtml, official
110
- );
85
+ @include experimental(box-pack, $pack, $flexbox-support...);
111
86
  }
@@ -1,35 +1,34 @@
1
+ // Columns
2
+
1
3
  @import "shared";
2
4
 
5
+ // @private css3-feature-support variables must always include a list of five boolean values
6
+ // representing in order: -moz, -webkit, -ms, -o, -khtml
7
+ $multicolumn-support: -moz, -webkit, not -ms, not -o, not -khtml;
8
+
9
+
3
10
  // Specify the shorthand `columns` property.
4
11
  //
5
12
  // Example:
6
13
  //
7
- // @include columns(20em 2)
14
+ // @include columns(20em 2);
8
15
  @mixin columns($width-and-count) {
9
- @include experimental(columns, $width-and-count,
10
- -moz, -webkit, -o, -ms, not -khtml, official
11
- );
16
+ @include experimental(columns, $width-and-count, $multicolumn-support...);
12
17
  }
13
18
 
14
19
  // Specify the number of columns
15
20
  @mixin column-count($count) {
16
- @include experimental(column-count, $count,
17
- -moz, -webkit, -o, -ms, not -khtml, official
18
- );
21
+ @include experimental(column-count, $count, $multicolumn-support...);
19
22
  }
20
23
 
21
24
  // Specify the gap between columns e.g. `20px`
22
25
  @mixin column-gap($width) {
23
- @include experimental(column-gap, $width,
24
- -moz, -webkit, -o, -ms, not -khtml, official
25
- );
26
+ @include experimental(column-gap, $width, $multicolumn-support...);
26
27
  }
27
28
 
28
29
  // Specify the width of columns e.g. `100px`
29
30
  @mixin column-width($width) {
30
- @include experimental(column-width, $width,
31
- -moz, -webkit, -o, -ms, not -khtml, official
32
- );
31
+ @include experimental(column-width, $width, $multicolumn-support...);
33
32
  }
34
33
 
35
34
  // Specify how many columns an element should span across.
@@ -43,25 +42,19 @@
43
42
 
44
43
  // Specify the width of the rule between columns e.g. `1px`
45
44
  @mixin column-rule-width($width) {
46
- @include experimental(column-rule-width, $width,
47
- -moz, -webkit, -o, -ms, not -khtml, official
48
- );
45
+ @include experimental(rule-width, $width, $multicolumn-support...);
49
46
  }
50
47
 
51
48
  // Specify the style of the rule between columns e.g. `dotted`.
52
49
  // This works like border-style.
53
50
  @mixin column-rule-style($style) {
54
- @include experimental(column-rule-style, unquote($style),
55
- -moz, -webkit, -o, -ms, not -khtml, official
56
- );
51
+ @include experimental(rule-style, unquote($style), $multicolumn-support...);
57
52
  }
58
53
 
59
54
  // Specify the color of the rule between columns e.g. `blue`.
60
55
  // This works like border-color.
61
56
  @mixin column-rule-color($color) {
62
- @include experimental(column-rule-color, $color,
63
- -moz, -webkit, -o, -ms, not -khtml, official
64
- );
57
+ @include experimental(rule-color, $color, $multicolumn-support...);
65
58
  }
66
59
 
67
60
  // Mixin encompassing all column rule properties
@@ -74,84 +67,124 @@
74
67
  // @include column-rule(1px solid #c00)
75
68
  @mixin column-rule($width, $style: false, $color: false) {
76
69
  $full : -compass-space-list(compact($width, $style, $color));
77
- @include experimental(column-rule, $full,
78
- -moz, -webkit, -o, -ms, not -khtml, official
79
- );
70
+ @include experimental(column-rule, $full, $multicolumn-support...);
71
+ }
72
+
73
+ // All-purpose mixin for setting column breaks.
74
+ //
75
+ // * legal values for $type : before, after, inside
76
+ // * legal values for '$value' are dependent on $type
77
+ // * when $type = before, legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
78
+ // * when $type = after, legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
79
+ // * when $type = inside, legal values are auto, avoid, avoid-page, avoid-column
80
+ //
81
+ // Examples:
82
+ // h2.before {@include column-break(before, always);}
83
+ // h2.after {@include column-break(after, always); }
84
+ // h2.inside {@include column-break(inside); }
85
+ //
86
+ // Which generates:
87
+ // h2.before {
88
+ // -webkit-column-break-before: always;
89
+ // break-before: always;}
90
+ //
91
+ // h2.after {
92
+ // -webkit-column-break-after: always;
93
+ // break-after: always; }
94
+ //
95
+ // h2.inside {
96
+ // -webkit-column-break-inside: auto;
97
+ // break-inside: auto;}
98
+
99
+ @mixin column-break($type: before, $value: auto){
100
+ // Webkit uses non-standard syntax
101
+ @if $experimental-support-for-webkit {
102
+ -webkit-column-break-#{$type}: $value;
103
+ }
104
+
105
+ // Official syntax
106
+ break-#{$type}: $value;
80
107
  }
81
108
 
82
- // Mixin for setting column-break-before
109
+ // Mixin for setting break-before
83
110
  //
84
111
  // * legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
85
112
  //
86
- // Example:
87
- // h2.before {@include column-break-before(always);}
113
+ // Example:
114
+ // h2.before {@include break-before(always);}
88
115
  //
89
- // Which generates:
116
+ // Which generates:
90
117
  //
91
- // h2.before {
118
+ // h2.before {
92
119
  // -webkit-column-break-before: always;
93
- // column-break-before: always;}
120
+ // break-before: always;}
121
+ @mixin break-before($value: auto){
122
+ @include column-break(before, $value);
123
+ }
124
+
94
125
  @mixin column-break-before($value: auto){
95
- @include experimental(column-break-before, $value, not -moz, -webkit, not -o, not -ms, not -khtml, official );
126
+ @include column-break(before, $value);
127
+ @warn '"column-break-before" has been deprecated in favor of the official syntax: "break-before".';
96
128
  }
97
129
 
98
- // Mixin for setting column-break-after
130
+ // Mixin for setting break-after
99
131
  //
100
132
  // * legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
101
133
  //
102
- // Example:
103
- // h2.after {@include column-break-after(always); }
134
+ // Example:
135
+ // h2.after {@include break-after(always); }
104
136
  //
105
- // Which generates:
137
+ // Which generates:
106
138
  //
107
139
  // h2.after {
108
140
  // -webkit-column-break-after: always;
109
- // column-break-after: always; }
141
+ // break-after: always; }
142
+ @mixin break-after($value: auto){
143
+ @include column-break(after, $value);
144
+ }
145
+
110
146
  @mixin column-break-after($value: auto){
111
- @include experimental(column-break-after, $value, not -moz, -webkit, not -o, not -ms, not -khtml, official );
147
+ @include column-break(after, $value);
148
+ @warn '"column-break-after" has been deprecated in favor of the official syntax: "break-after".';
112
149
  }
113
150
 
114
- // Mixin for setting column-break-inside
151
+ // Mixin for setting break-inside
115
152
  //
116
153
  // * legal values are auto, avoid, avoid-page, avoid-column
117
154
  //
118
- // Example:
119
- // h2.inside {@include column-break-inside();}
120
- // Which generates:
121
- //
155
+ // Example:
156
+ // h2.inside {@include break-inside();}
157
+ //
158
+ // Which generates:
159
+ //
122
160
  // h2.inside {
123
161
  // -webkit-column-break-inside: auto;
124
- // column-break-inside: auto;}
162
+ // break-inside: auto;}
163
+ @mixin break-inside($value: auto){
164
+ @include column-break(inside, $value);
165
+ }
166
+
125
167
  @mixin column-break-inside($value: auto){
126
- @include experimental(column-break-inside, $value, not -moz, -webkit, not -o, not -ms, not -khtml, official );
168
+ @include column-break(inside, $value);
169
+ @warn '"column-break-inside" has been deprecated in favor of the official syntax: "break-inside".';
127
170
  }
128
171
 
129
- // All-purpose mixin for setting column breaks.
172
+ // Mixin for setting column-span
130
173
  //
131
- // * legal values for $type : before, after, inside
132
- // * legal values for '$value' are dependent on $type
133
- // * when $type = before, legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
134
- // * when $type = after, legal values are auto, always, avoid, left, right, page, column, avoid-page, avoid-column
135
- // * when $type = inside, legal values are auto, avoid, avoid-page, avoid-column
136
- //
137
- // Examples:
138
- // h2.before {@include column-break(before, always);}
139
- // h2.after {@include column-break(after, always); }
140
- // h2.inside {@include column-break(inside); }
174
+ // * legal values: none, all
141
175
  //
142
- // Which generates:
143
- // h2.before {
144
- // -webkit-column-break-before: always;
145
- // column-break-before: always;}
146
- //
147
- // h2.after {
148
- // -webkit-column-break-after: always;
149
- // column-break-after: always; }
176
+ // Example:
177
+ // h2.span {@include column-span();}
178
+ @mixin column-span($span: all){
179
+ @include experimental(column-span, unquote($span), $multicolumn-support...);
180
+ }
181
+
182
+ // Mixin for setting column-fill
150
183
  //
151
- // h2.inside {
152
- // -webkit-column-break-inside: auto;
153
- // column-break-inside: auto;}
154
-
155
- @mixin column-break($type: before, $value: auto){
156
- @include experimental("column-break-#{$type}", $value, not -moz, -webkit, not -o, not -ms, not -khtml, official );
157
- }
184
+ // * legal values: auto, balance
185
+ //
186
+ // Example:
187
+ // h2.fill {@include column-fill();}
188
+ @mixin column-fill($fill: balance){
189
+ @include experimental(column-fill, unquote($fill), $multicolumn-support...);
190
+ }