less 2.3.1 → 2.4.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 (301) hide show
  1. package/.idea/workspace.xml +277 -237
  2. package/.jscsrc +36 -1
  3. package/.travis.yml +1 -0
  4. package/CHANGELOG.md +14 -0
  5. package/Gruntfile.js +1 -1
  6. package/appveyor.yml +5 -0
  7. package/bin/lessc +8 -5
  8. package/bower.json +1 -1
  9. package/dist/less.js +909 -814
  10. package/dist/less.min.js +6 -6
  11. package/lib/less/contexts.js +2 -2
  12. package/lib/less/environment/abstract-file-manager.js +6 -6
  13. package/lib/less/environment/environment.js +2 -2
  14. package/lib/less/functions/color.js +13 -5
  15. package/lib/less/functions/math.js +1 -1
  16. package/lib/less/functions/number.js +2 -2
  17. package/lib/less/functions/types.js +18 -8
  18. package/lib/less/import-manager.js +5 -5
  19. package/lib/less/index.js +1 -1
  20. package/lib/less/less-error.js +1 -1
  21. package/lib/less/logger.js +2 -2
  22. package/lib/less/parse-tree.js +45 -45
  23. package/lib/less/parse.js +5 -2
  24. package/lib/less/parser/parser-input.js +3 -3
  25. package/lib/less/parser/parser.js +52 -18
  26. package/lib/less/plugin-manager.js +30 -3
  27. package/lib/less/render.js +5 -2
  28. package/lib/less/source-map-builder.js +4 -0
  29. package/lib/less/source-map-output.js +3 -3
  30. package/lib/less/transform-tree.js +4 -4
  31. package/lib/less/tree/anonymous.js +1 -1
  32. package/lib/less/tree/call.js +1 -1
  33. package/lib/less/tree/color.js +2 -2
  34. package/lib/less/tree/condition.js +8 -4
  35. package/lib/less/tree/dimension.js +4 -4
  36. package/lib/less/tree/element.js +1 -1
  37. package/lib/less/tree/expression.js +1 -1
  38. package/lib/less/tree/extend.js +3 -3
  39. package/lib/less/tree/javascript.js +2 -2
  40. package/lib/less/tree/media.js +20 -20
  41. package/lib/less/tree/mixin-call.js +2 -2
  42. package/lib/less/tree/mixin-definition.js +29 -8
  43. package/lib/less/tree/quoted.js +3 -3
  44. package/lib/less/tree/rule.js +1 -1
  45. package/lib/less/tree/ruleset.js +35 -28
  46. package/lib/less/tree/selector.js +1 -1
  47. package/lib/less/tree/unit.js +2 -0
  48. package/lib/less/tree/value.js +1 -1
  49. package/lib/less/visitors/extend-visitor.js +15 -14
  50. package/lib/less/visitors/import-sequencer.js +2 -2
  51. package/lib/less/visitors/import-visitor.js +2 -2
  52. package/lib/less/visitors/to-css-visitor.js +5 -5
  53. package/lib/less-browser/cache.js +2 -2
  54. package/lib/less-browser/file-manager.js +96 -96
  55. package/lib/less-browser/index.js +205 -205
  56. package/lib/less-browser/log-listener.js +2 -2
  57. package/lib/less-browser/utils.js +6 -6
  58. package/lib/less-node/file-manager.js +9 -4
  59. package/lib/less-node/index.js +3 -3
  60. package/lib/less-node/plugin-loader.js +3 -3
  61. package/lib/less-node/url-file-manager.js +5 -2
  62. package/lib/less-rhino/index.js +13 -9
  63. package/lib/source-map/source-map-0.1.31.js +1 -1
  64. package/package.json +1 -1
  65. package/test/browser/css/relative-urls/urls.css +1 -0
  66. package/test/browser/less/relative-urls/urls.less +1 -0
  67. package/test/browser/runner-browser-options.js +23 -23
  68. package/test/browser/runner-errors-spec.js +1 -1
  69. package/test/browser/runner-global-vars-spec.js +1 -1
  70. package/test/browser/runner-main-options.js +5 -5
  71. package/test/browser/runner-main-spec.js +1 -1
  72. package/test/copy-bom.js +35 -35
  73. package/test/css/functions.css +8 -0
  74. package/test/css/import-interpolation.css +1 -0
  75. package/test/css/mixins-important.css +6 -0
  76. package/test/css/selectors.css +5 -0
  77. package/test/css/static-urls/urls.css +1 -0
  78. package/test/css/urls.css +1 -0
  79. package/test/index.js +2 -1
  80. package/test/less/functions.less +13 -0
  81. package/test/less/import/imports/logo.less +1 -0
  82. package/test/less/mixins-important.less +17 -1
  83. package/test/less/selectors.less +10 -0
  84. package/test/less/sourcemaps-empty/empty.less +0 -0
  85. package/test/less/sourcemaps-empty/var-defs.less +1 -0
  86. package/test/less/urls.less +1 -1
  87. package/test/less-test.js +49 -27
  88. package/test/modify-vars.js +13 -13
  89. package/test/browser/less.js +0 -29
  90. package/test/less-bom/charsets.less +0 -3
  91. package/test/less-bom/colors.less +0 -98
  92. package/test/less-bom/comments.less +0 -102
  93. package/test/less-bom/comments2.less +0 -20
  94. package/test/less-bom/compression/compression.less +0 -36
  95. package/test/less-bom/css-3.less +0 -154
  96. package/test/less-bom/css-escapes.less +0 -33
  97. package/test/less-bom/css-guards.less +0 -103
  98. package/test/less-bom/css.less +0 -108
  99. package/test/less-bom/debug/import/test.less +0 -25
  100. package/test/less-bom/debug/linenumbers.less +0 -33
  101. package/test/less-bom/detached-rulesets.less +0 -103
  102. package/test/less-bom/empty.less +0 -1
  103. package/test/less-bom/errors/add-mixed-units.less +0 -3
  104. package/test/less-bom/errors/add-mixed-units.txt +0 -4
  105. package/test/less-bom/errors/add-mixed-units2.less +0 -3
  106. package/test/less-bom/errors/add-mixed-units2.txt +0 -4
  107. package/test/less-bom/errors/at-rules-undefined-var.less +0 -4
  108. package/test/less-bom/errors/at-rules-undefined-var.txt +0 -4
  109. package/test/less-bom/errors/bad-variable-declaration1.less +0 -1
  110. package/test/less-bom/errors/bad-variable-declaration1.txt +0 -2
  111. package/test/less-bom/errors/color-func-invalid-color.less +0 -3
  112. package/test/less-bom/errors/color-func-invalid-color.txt +0 -4
  113. package/test/less-bom/errors/color-invalid-hex-code.less +0 -3
  114. package/test/less-bom/errors/color-invalid-hex-code.txt +0 -4
  115. package/test/less-bom/errors/color-invalid-hex-code2.less +0 -3
  116. package/test/less-bom/errors/color-invalid-hex-code2.txt +0 -4
  117. package/test/less-bom/errors/css-guard-default-func.less +0 -4
  118. package/test/less-bom/errors/css-guard-default-func.txt +0 -4
  119. package/test/less-bom/errors/detached-ruleset-1.less +0 -6
  120. package/test/less-bom/errors/detached-ruleset-1.txt +0 -4
  121. package/test/less-bom/errors/detached-ruleset-2.less +0 -6
  122. package/test/less-bom/errors/detached-ruleset-2.txt +0 -4
  123. package/test/less-bom/errors/detached-ruleset-3.less +0 -4
  124. package/test/less-bom/errors/detached-ruleset-3.txt +0 -4
  125. package/test/less-bom/errors/detached-ruleset-4.less +0 -5
  126. package/test/less-bom/errors/detached-ruleset-4.txt +0 -4
  127. package/test/less-bom/errors/detached-ruleset-5.less +0 -4
  128. package/test/less-bom/errors/detached-ruleset-5.txt +0 -3
  129. package/test/less-bom/errors/detached-ruleset-6.less +0 -5
  130. package/test/less-bom/errors/detached-ruleset-6.txt +0 -4
  131. package/test/less-bom/errors/divide-mixed-units.less +0 -3
  132. package/test/less-bom/errors/divide-mixed-units.txt +0 -4
  133. package/test/less-bom/errors/extend-no-selector.less +0 -3
  134. package/test/less-bom/errors/extend-no-selector.txt +0 -3
  135. package/test/less-bom/errors/extend-not-at-end.less +0 -3
  136. package/test/less-bom/errors/extend-not-at-end.txt +0 -3
  137. package/test/less-bom/errors/import-malformed.less +0 -1
  138. package/test/less-bom/errors/import-malformed.txt +0 -3
  139. package/test/less-bom/errors/import-missing.less +0 -6
  140. package/test/less-bom/errors/import-missing.txt +0 -3
  141. package/test/less-bom/errors/import-no-semi.less +0 -1
  142. package/test/less-bom/errors/import-no-semi.txt +0 -2
  143. package/test/less-bom/errors/import-subfolder1.less +0 -1
  144. package/test/less-bom/errors/import-subfolder1.txt +0 -3
  145. package/test/less-bom/errors/import-subfolder2.less +0 -1
  146. package/test/less-bom/errors/import-subfolder2.txt +0 -4
  147. package/test/less-bom/errors/imports/import-subfolder1.less +0 -1
  148. package/test/less-bom/errors/imports/import-subfolder2.less +0 -1
  149. package/test/less-bom/errors/imports/import-test.less +0 -4
  150. package/test/less-bom/errors/imports/subfolder/mixin-not-defined.less +0 -1
  151. package/test/less-bom/errors/imports/subfolder/parse-error-curly-bracket.less +0 -1
  152. package/test/less-bom/errors/javascript-error.less +0 -3
  153. package/test/less-bom/errors/javascript-error.txt +0 -4
  154. package/test/less-bom/errors/javascript-undefined-var.less +0 -3
  155. package/test/less-bom/errors/javascript-undefined-var.txt +0 -4
  156. package/test/less-bom/errors/mixed-mixin-definition-args-1.less +0 -6
  157. package/test/less-bom/errors/mixed-mixin-definition-args-1.txt +0 -4
  158. package/test/less-bom/errors/mixed-mixin-definition-args-2.less +0 -6
  159. package/test/less-bom/errors/mixed-mixin-definition-args-2.txt +0 -4
  160. package/test/less-bom/errors/mixin-not-defined.less +0 -11
  161. package/test/less-bom/errors/mixin-not-defined.txt +0 -3
  162. package/test/less-bom/errors/mixin-not-matched.less +0 -6
  163. package/test/less-bom/errors/mixin-not-matched.txt +0 -3
  164. package/test/less-bom/errors/mixin-not-matched2.less +0 -6
  165. package/test/less-bom/errors/mixin-not-matched2.txt +0 -3
  166. package/test/less-bom/errors/mixin-not-visible-in-scope-1.less +0 -9
  167. package/test/less-bom/errors/mixin-not-visible-in-scope-1.txt +0 -4
  168. package/test/less-bom/errors/mixins-guards-default-func-1.less +0 -9
  169. package/test/less-bom/errors/mixins-guards-default-func-1.txt +0 -4
  170. package/test/less-bom/errors/mixins-guards-default-func-2.less +0 -9
  171. package/test/less-bom/errors/mixins-guards-default-func-2.txt +0 -4
  172. package/test/less-bom/errors/mixins-guards-default-func-3.less +0 -9
  173. package/test/less-bom/errors/mixins-guards-default-func-3.txt +0 -4
  174. package/test/less-bom/errors/multiple-guards-on-css-selectors.less +0 -4
  175. package/test/less-bom/errors/multiple-guards-on-css-selectors.txt +0 -4
  176. package/test/less-bom/errors/multiple-guards-on-css-selectors2.less +0 -4
  177. package/test/less-bom/errors/multiple-guards-on-css-selectors2.txt +0 -4
  178. package/test/less-bom/errors/multiply-mixed-units.less +0 -7
  179. package/test/less-bom/errors/multiply-mixed-units.txt +0 -4
  180. package/test/less-bom/errors/parens-error-1.less +0 -3
  181. package/test/less-bom/errors/parens-error-1.txt +0 -4
  182. package/test/less-bom/errors/parens-error-2.less +0 -3
  183. package/test/less-bom/errors/parens-error-2.txt +0 -4
  184. package/test/less-bom/errors/parens-error-3.less +0 -3
  185. package/test/less-bom/errors/parens-error-3.txt +0 -4
  186. package/test/less-bom/errors/parse-error-curly-bracket.less +0 -4
  187. package/test/less-bom/errors/parse-error-curly-bracket.txt +0 -4
  188. package/test/less-bom/errors/parse-error-extra-parens.less +0 -5
  189. package/test/less-bom/errors/parse-error-extra-parens.txt +0 -3
  190. package/test/less-bom/errors/parse-error-missing-bracket.less +0 -2
  191. package/test/less-bom/errors/parse-error-missing-bracket.txt +0 -3
  192. package/test/less-bom/errors/parse-error-missing-parens.less +0 -5
  193. package/test/less-bom/errors/parse-error-missing-parens.txt +0 -3
  194. package/test/less-bom/errors/parse-error-with-import.less +0 -13
  195. package/test/less-bom/errors/parse-error-with-import.txt +0 -4
  196. package/test/less-bom/errors/percentage-missing-space.less +0 -3
  197. package/test/less-bom/errors/percentage-missing-space.txt +0 -4
  198. package/test/less-bom/errors/property-asterisk-only-name.less +0 -3
  199. package/test/less-bom/errors/property-asterisk-only-name.txt +0 -4
  200. package/test/less-bom/errors/property-ie5-hack.less +0 -3
  201. package/test/less-bom/errors/property-ie5-hack.txt +0 -3
  202. package/test/less-bom/errors/property-in-root.less +0 -4
  203. package/test/less-bom/errors/property-in-root.txt +0 -4
  204. package/test/less-bom/errors/property-in-root2.less +0 -1
  205. package/test/less-bom/errors/property-in-root2.txt +0 -4
  206. package/test/less-bom/errors/property-in-root3.less +0 -4
  207. package/test/less-bom/errors/property-in-root3.txt +0 -3
  208. package/test/less-bom/errors/property-interp-not-defined.less +0 -1
  209. package/test/less-bom/errors/property-interp-not-defined.txt +0 -2
  210. package/test/less-bom/errors/recursive-variable.less +0 -1
  211. package/test/less-bom/errors/recursive-variable.txt +0 -2
  212. package/test/less-bom/errors/single-character.less +0 -1
  213. package/test/less-bom/errors/single-character.txt +0 -2
  214. package/test/less-bom/errors/svg-gradient1.less +0 -3
  215. package/test/less-bom/errors/svg-gradient1.txt +0 -4
  216. package/test/less-bom/errors/svg-gradient2.less +0 -3
  217. package/test/less-bom/errors/svg-gradient2.txt +0 -4
  218. package/test/less-bom/errors/svg-gradient3.less +0 -3
  219. package/test/less-bom/errors/svg-gradient3.txt +0 -4
  220. package/test/less-bom/errors/unit-function.less +0 -3
  221. package/test/less-bom/errors/unit-function.txt +0 -4
  222. package/test/less-bom/extend-chaining.less +0 -91
  223. package/test/less-bom/extend-clearfix.less +0 -19
  224. package/test/less-bom/extend-exact.less +0 -46
  225. package/test/less-bom/extend-media.less +0 -24
  226. package/test/less-bom/extend-nest.less +0 -65
  227. package/test/less-bom/extend-selector.less +0 -99
  228. package/test/less-bom/extend.less +0 -81
  229. package/test/less-bom/extract-and-length.less +0 -133
  230. package/test/less-bom/functions.less +0 -201
  231. package/test/less-bom/globalVars/extended.json +0 -5
  232. package/test/less-bom/globalVars/extended.less +0 -10
  233. package/test/less-bom/globalVars/simple.json +0 -3
  234. package/test/less-bom/globalVars/simple.less +0 -3
  235. package/test/less-bom/ie-filters.less +0 -15
  236. package/test/less-bom/import/deeper/deeper-2/url-import-2.less +0 -3
  237. package/test/less-bom/import/deeper/deeper-2/url-import.less +0 -1
  238. package/test/less-bom/import/deeper/import-once-test-a.less +0 -1
  239. package/test/less-bom/import/deeper/url-import.less +0 -1
  240. package/test/less-bom/import/import-and-relative-paths-test.less +0 -17
  241. package/test/less-bom/import/import-charset-test.less +0 -1
  242. package/test/less-bom/import/import-interpolation.less +0 -2
  243. package/test/less-bom/import/import-interpolation2.less +0 -5
  244. package/test/less-bom/import/import-once-test-c.less +0 -6
  245. package/test/less-bom/import/import-reference.less +0 -89
  246. package/test/less-bom/import/import-test-a.less +0 -4
  247. package/test/less-bom/import/import-test-b.less +0 -8
  248. package/test/less-bom/import/import-test-c.less +0 -6
  249. package/test/less-bom/import/import-test-d.css +0 -1
  250. package/test/less-bom/import/import-test-e.less +0 -2
  251. package/test/less-bom/import/import-test-f.less +0 -5
  252. package/test/less-bom/import/imports/font.less +0 -8
  253. package/test/less-bom/import/imports/logo.less +0 -5
  254. package/test/less-bom/import/interpolation-vars.less +0 -6
  255. package/test/less-bom/import/invalid-css.less +0 -1
  256. package/test/less-bom/import/urls.less +0 -1
  257. package/test/less-bom/import-inline.less +0 -3
  258. package/test/less-bom/import-interpolation.less +0 -8
  259. package/test/less-bom/import-once.less +0 -6
  260. package/test/less-bom/import-reference.less +0 -23
  261. package/test/less-bom/import.less +0 -30
  262. package/test/less-bom/include-path/include-path.less +0 -6
  263. package/test/less-bom/javascript.less +0 -38
  264. package/test/less-bom/lazy-eval.less +0 -6
  265. package/test/less-bom/legacy/legacy.less +0 -7
  266. package/test/less-bom/media.less +0 -234
  267. package/test/less-bom/merge.less +0 -78
  268. package/test/less-bom/mixins-args.less +0 -215
  269. package/test/less-bom/mixins-closure.less +0 -26
  270. package/test/less-bom/mixins-guards-default-func.less +0 -195
  271. package/test/less-bom/mixins-guards.less +0 -271
  272. package/test/less-bom/mixins-important.less +0 -37
  273. package/test/less-bom/mixins-interpolated.less +0 -75
  274. package/test/less-bom/mixins-named-args.less +0 -36
  275. package/test/less-bom/mixins-nested.less +0 -22
  276. package/test/less-bom/mixins-pattern.less +0 -102
  277. package/test/less-bom/mixins.less +0 -145
  278. package/test/less-bom/modifyVars/extended.json +0 -5
  279. package/test/less-bom/modifyVars/extended.less +0 -11
  280. package/test/less-bom/nested-gradient-with-svg-gradient/mixin-consumer.less +0 -5
  281. package/test/less-bom/nested-gradient-with-svg-gradient/svg-gradient-mixin.less +0 -15
  282. package/test/less-bom/no-js-errors/no-js-errors.less +0 -3
  283. package/test/less-bom/no-js-errors/no-js-errors.txt +0 -4
  284. package/test/less-bom/no-output.less +0 -2
  285. package/test/less-bom/operations.less +0 -62
  286. package/test/less-bom/parens.less +0 -45
  287. package/test/less-bom/property-name-interp.less +0 -56
  288. package/test/less-bom/rulesets.less +0 -30
  289. package/test/less-bom/scope.less +0 -104
  290. package/test/less-bom/selectors.less +0 -174
  291. package/test/less-bom/sourcemaps/basic.json +0 -3
  292. package/test/less-bom/sourcemaps/basic.less +0 -27
  293. package/test/less-bom/sourcemaps/imported.css +0 -7
  294. package/test/less-bom/static-urls/urls.less +0 -33
  295. package/test/less-bom/strict-units/strict-units.less +0 -4
  296. package/test/less-bom/strings.less +0 -73
  297. package/test/less-bom/url-args/urls.less +0 -63
  298. package/test/less-bom/urls.less +0 -94
  299. package/test/less-bom/variables-in-at-rules.less +0 -20
  300. package/test/less-bom/variables.less +0 -119
  301. package/test/less-bom/whitespace.less +0 -44
@@ -1,36 +0,0 @@
1
- #colours {
2
- color1: #fea;
3
- color2: #ffeeaa;
4
- color3: rgba(255, 238, 170, 0.1);
5
- @color1: #fea;
6
- string: "@{color1}";
7
- /* comments are stripped */
8
- // both types!
9
- /*! but not this type
10
- Note preserved whitespace
11
- */
12
- }
13
- dimensions {
14
- val: 0.1px;
15
- val: 0em;
16
- val: 4cm;
17
- val: 0.2;
18
- val: 5;
19
- angles-must-have-unit: 0deg;
20
- durations-must-have-unit: 0s;
21
- length-doesnt-have-unit: 0px;
22
- width: auto\9;
23
- }
24
- @page {
25
- marks: none;
26
- @top-left-corner {
27
- vertical-align: top;
28
- }
29
- @top-left {
30
- vertical-align: top;
31
- }
32
- }
33
- .shadow ^ .dom,
34
- body ^^ .shadow {
35
- display: done;
36
- }
@@ -1,154 +0,0 @@
1
- .comma-delimited {
2
- text-shadow: -1px -1px 1px red, 6px 5px 5px yellow;
3
- -moz-box-shadow: 0pt 0pt 2px rgba(255, 255, 255, 0.4) inset,
4
- 0pt 4px 6px rgba(255, 255, 255, 0.4) inset;
5
- -webkit-transform: rotate(-0.0000000001deg);
6
- }
7
- @font-face {
8
- font-family: Headline;
9
- unicode-range: U+??????, U+0???, U+0-7F, U+A5;
10
- }
11
- .other {
12
- -moz-transform: translate(0, 11em) rotate(-90deg);
13
- transform: rotateX(45deg);
14
- }
15
- .item[data-cra_zy-attr1b-ut3=bold] {
16
- font-weight: bold;
17
- }
18
- p:not([class*="lead"]) {
19
- color: black;
20
- }
21
-
22
- input[type="text"].class#id[attr=32]:not(1) {
23
- color: white;
24
- }
25
-
26
- div#id.class[a=1][b=2].class:not(1) {
27
- color: white;
28
- }
29
-
30
- ul.comma > li:not(:only-child)::after {
31
- color: white;
32
- }
33
-
34
- ol.comma > li:nth-last-child(2)::after {
35
- color: white;
36
- }
37
-
38
- li:nth-child(4n+1),
39
- li:nth-child(-5n),
40
- li:nth-child(-n+2) {
41
- color: white;
42
- }
43
-
44
- a[href^="http://"] {
45
- color: black;
46
- }
47
-
48
- a[href$="http://"] {
49
- color: black;
50
- }
51
-
52
- form[data-disabled] {
53
- color: black;
54
- }
55
-
56
- p::before {
57
- color: black;
58
- }
59
-
60
- #issue322 {
61
- -webkit-animation: anim2 7s infinite ease-in-out;
62
- }
63
-
64
- @-webkit-keyframes frames {
65
- 0% { border: 1px }
66
- 5.5% { border: 2px }
67
- 100% { border: 3px }
68
- }
69
-
70
- @keyframes fontbulger1 {
71
- to {
72
- font-size: 15px;
73
- }
74
- from,to {
75
- font-size: 12px;
76
- }
77
- 0%,100% {
78
- font-size: 12px;
79
- }
80
- }
81
-
82
- .units {
83
- font: 1.2rem/2rem;
84
- font: 8vw/9vw;
85
- font: 10vh/12vh;
86
- font: 12vm/15vm;
87
- font: 12vmin/15vmin;
88
- font: 1.2ch/1.5ch;
89
- }
90
-
91
- @supports ( box-shadow: 2px 2px 2px black ) or
92
- ( -moz-box-shadow: 2px 2px 2px black ) {
93
- .outline {
94
- box-shadow: 2px 2px 2px black;
95
- -moz-box-shadow: 2px 2px 2px black;
96
- }
97
- }
98
-
99
- @-x-document url-prefix(""github.com"") {
100
- h1 {
101
- color: red;
102
- }
103
- }
104
-
105
- @viewport {
106
- font-size: 10px;
107
- }
108
- @namespace foo url(http://www.example.com);
109
-
110
- foo|h1 { color: blue; }
111
- foo|* { color: yellow; }
112
- |h1 { color: red; }
113
- *|h1 { color: green; }
114
- h1 { color: green; }
115
- .upper-test {
116
- UpperCaseProperties: allowed;
117
- }
118
- @host {
119
- div {
120
- display: block;
121
- }
122
- }
123
- ::distributed(input::placeholder) {
124
- color: #b3b3b3;
125
- }
126
- .shadow ^ .dom,
127
- body ^^ .shadow {
128
- display: done;
129
- }
130
-
131
- :host(.sel .a),
132
- :host-context(.sel .b),
133
- .sel /deep/ .b,
134
- ::content .sel {
135
- type: shadow-dom;
136
- }
137
- /deep/ b {
138
- c: 'd';
139
- &[e]{
140
- f: 'g';
141
- }
142
- }
143
-
144
- #issue2066 {
145
- background: url('/images/icon-team.svg') 0 0 / contain;
146
- }
147
- @counter-style triangle {
148
- system: cyclic;
149
- symbols: ‣;
150
- suffix: " ";
151
- }
152
- @-ms-viewport{
153
- //width: auto !important;
154
- }
@@ -1,33 +0,0 @@
1
- @ugly: fuchsia;
2
-
3
- .escape\|random\|char {
4
- color: red;
5
- }
6
-
7
- .mixin\!tUp {
8
- font-weight: bold;
9
- }
10
-
11
- // class="404"
12
- .\34 04 {
13
- background: red;
14
-
15
- strong {
16
- color: @ugly;
17
- .mixin\!tUp;
18
- }
19
- }
20
-
21
- .trailingTest\+ {
22
- color: red;
23
- }
24
-
25
- /* This hideous test of hideousness checks for the selector "blockquote" with various permutations of hex escapes */
26
- \62\6c\6f \63 \6B \0071 \000075o\74 e {
27
- color: silver;
28
- }
29
-
30
- [ng\:cloak],
31
- ng\:form {
32
- display: none;
33
- }
@@ -1,103 +0,0 @@
1
- 
2
- .light when (lightness(@a) > 50%) {
3
- color: green;
4
- }
5
- .dark when (lightness(@a) < 50%) {
6
- color: orange;
7
- }
8
- @a: #ddd;
9
-
10
- .see-the {
11
- @a: #444; // this mirrors what mixins do - they evaluate the guards at the point of definition
12
- .light();
13
- .dark();
14
- }
15
-
16
- .hide-the {
17
- .light();
18
- .dark();
19
- }
20
-
21
- .multiple-conditions-1 when (@b = 1), (@c = 2), (@d = 3) {
22
- color: red;
23
- }
24
-
25
- .multiple-conditions-2 when (@b = 1), (@c = 2), (@d = 2) {
26
- color: blue;
27
- }
28
-
29
- @b: 2;
30
- @c: 3;
31
- @d: 3;
32
-
33
- .inheritance when (@b = 2) {
34
- .test {
35
- color: black;
36
- }
37
- &:hover {
38
- color: pink;
39
- }
40
- .hideme when (@b = 1) {
41
- color: green;
42
- }
43
- & when (@b = 1) {
44
- hideme: green;
45
- }
46
- }
47
-
48
- .hideme when (@b = 1) {
49
- .test {
50
- color: black;
51
- }
52
- &:hover {
53
- color: pink;
54
- }
55
- .hideme when (@b = 1) {
56
- color: green;
57
- }
58
- }
59
-
60
- & when (@b = 1) {
61
- .hideme {
62
- color: red;
63
- }
64
- }
65
-
66
- .mixin-with-guard-inside(@colWidth) {
67
- // selector with guard (applies also to & when() ...)
68
- .clsWithGuard when (@colWidth <= 0) {
69
- dispaly: none;
70
- }
71
- }
72
-
73
- .mixin-with-guard-inside(0px);
74
-
75
- .dont-split-me-up {
76
- width: 1px;
77
- & when (@c = 3) {
78
- color: red;
79
- }
80
- & when (@c = 3) {
81
- height: 1px;
82
- }
83
- + & when (@c = 3) { // creates invalid css but tests that we don't fold it in
84
- sibling: true;
85
- }
86
- }
87
-
88
- .scope-check when (@c = 3) {
89
- @k: 1px;
90
- & when (@c = 3) {
91
- @k: 2px;
92
- sub-prop: @k;
93
- }
94
- prop: @k;
95
- }
96
- .scope-check-2 {
97
- .scope-check();
98
- @k:4px;
99
- }
100
- .errors-if-called when (@c = never) {
101
- .mixin-doesnt-exist();
102
- }
103
- a:hover when (2 = true) {5:-}
@@ -1,108 +0,0 @@
1
- @charset "utf-8";
2
- div { color: black; }
3
- div { width: 99%; }
4
-
5
- * {
6
- min-width: 45em;
7
- }
8
-
9
- h1, h2 > a > p, h3 {
10
- color: none;
11
- }
12
-
13
- div.class {
14
- color: blue;
15
- }
16
-
17
- div#id {
18
- color: green;
19
- }
20
-
21
- .class#id {
22
- color: purple;
23
- }
24
-
25
- .one.two.three {
26
- color: grey;
27
- }
28
-
29
- @media print {
30
- * {
31
- font-size: 3em;
32
- }
33
- }
34
-
35
- @media screen {
36
- * {
37
- font-size: 10px;
38
- }
39
- }
40
-
41
- @font-face {
42
- font-family: 'Garamond Pro';
43
- }
44
-
45
- a:hover, a:link {
46
- color: #999;
47
- }
48
-
49
- p, p:first-child {
50
- text-transform: none;
51
- }
52
-
53
- q:lang(no) {
54
- quotes: none;
55
- }
56
-
57
- p + h1 {
58
- font-size: +2.2em;
59
- }
60
-
61
- #shorthands {
62
- border: 1px solid #000;
63
- font: 12px/16px Arial;
64
- font: 100%/16px Arial;
65
- margin: 1px 0;
66
- padding: 0 auto;
67
- }
68
-
69
- #more-shorthands {
70
- margin: 0;
71
- padding: 1px 0 2px 0;
72
- font: normal small/20px 'Trebuchet MS', Verdana, sans-serif;
73
- font: 0/0 a;
74
- border-radius: 5px / 10px;
75
- }
76
-
77
- .misc {
78
- -moz-border-radius: 2px;
79
- display: -moz-inline-stack;
80
- width: .1em;
81
- background-color: #009998;
82
- background: -webkit-gradient(linear, left top, left bottom, from(red), to(blue));
83
- margin: ;
84
- .nested-multiple {
85
- multiple-semi-colons: yes;;;;;;
86
- };
87
- filter: alpha(opacity=100);
88
- width: auto\9;
89
- }
90
-
91
- #important {
92
- color: red !important;
93
- width: 100%!important;
94
- height: 20px ! important;
95
- }
96
-
97
- .def-font(@name) {
98
- @font-face {
99
- font-family: @name
100
- }
101
- }
102
-
103
- .def-font(font-a);
104
- .def-font(font-b);
105
-
106
- .æøå {
107
- margin: 0;
108
- }
@@ -1,25 +0,0 @@
1
- @charset "ISO-8859-1";
2
-
3
- .mixin_import1() {
4
- @media all {
5
- .tst {
6
- color: black;
7
- @media screen {
8
- color: red;
9
- .tst3 {
10
- color: white;
11
- }
12
- }
13
- }
14
- }
15
- }
16
-
17
- .mixin_import2() {
18
- .tst2 {
19
- color: white;
20
- }
21
- }
22
-
23
- .tst3 {
24
- color: grey;
25
- }
@@ -1,33 +0,0 @@
1
- @charset "UTF-8";
2
-
3
- @import "import/test.less";
4
-
5
- .start() {
6
- .test2 {
7
- color: red;
8
- }
9
- }
10
-
11
- .mix() {
12
- color: black;
13
- }
14
-
15
- .test1 {
16
- .mix();
17
- }
18
-
19
- .start();
20
-
21
- .mixin_import1();
22
-
23
- .mixin_import2();
24
-
25
- @debug: 1;
26
- & when (@debug = 1) {
27
- .test {
28
- color: red;
29
- & when (@debug = 1) {
30
- width: 2;
31
- }
32
- }
33
- }
@@ -1,103 +0,0 @@
1
- @ruleset: {
2
- color: black;
3
- background: white;
4
- };
5
-
6
- @a: 1px;
7
- .wrap-mixin(@ruleset) {
8
- @a: hidden and if you see this in the output its a bug;
9
- @b: visible;
10
- @d: magic-frame; // same behaviour as mixin calls - falls back to this frame
11
- .wrap-selector {
12
- @c: visible;
13
- @ruleset();
14
- visible-one: @b;
15
- visible-two: @c;
16
- }
17
- };
18
-
19
- .wrap-mixin({
20
- color: black;
21
- one: @a;
22
- @b: hidden and if you see this in the output its a bug;
23
- @c: hidden and if you see this in the output its a bug;
24
- four: @d;
25
- });
26
-
27
- .wrap-mixin(@ruleset: {
28
- color: red;
29
- });
30
-
31
- .wrap-mixin(@ruleset);
32
-
33
- .desktop-and-old-ie(@rules) {
34
- @media screen and (min-width: 1200) { @rules(); }
35
- html.lt-ie9 & { @rules(); }
36
- }
37
-
38
- header {
39
- background: blue;
40
-
41
- .desktop-and-old-ie({
42
- background: red;
43
- });
44
- }
45
-
46
- .wrap-mixin-calls-wrap(@ruleset) {
47
- .wrap-mixin(@ruleset);
48
- };
49
-
50
- .wrap-mixin({
51
- test: extra-wrap;
52
- .wrap-mixin-calls-wrap({
53
- test: wrapped-twice;
54
- });
55
- });
56
-
57
- .wrap-mixin({
58
- test-func: unit(90px);
59
- test-arithmetic: unit((9+9), px);
60
- });
61
- // without mixins
62
- @ruleset-2: {
63
- b: 1;
64
- };
65
- .without-mixins {
66
- @ruleset-2();
67
- }
68
- @my-ruleset: {
69
- .my-selector {
70
- @media tv {
71
- background-color: black;
72
- }
73
- }
74
- };
75
- @media (orientation:portrait) {
76
- @my-ruleset();
77
- .wrap-media-mixin({
78
- @media tv {
79
- .triple-wrapped-mq {
80
- triple: true;
81
- }
82
- }
83
- });
84
- }
85
- .wrap-media-mixin(@ruleset) {
86
- @media widescreen {
87
- @media print {
88
- @ruleset();
89
- }
90
- @ruleset();
91
- }
92
- @ruleset();
93
- }
94
- // unlocking mixins
95
- @my-mixins: {
96
- .mixin() {
97
- test: test;
98
- }
99
- };
100
- @my-mixins();
101
- .a {
102
- .mixin();
103
- }
@@ -1 +0,0 @@
1
- 
@@ -1,3 +0,0 @@
1
- .a {
2
- error: (1px + 3em);
3
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: Incompatible units. Change the units or use the unit function. Bad units: 'px' and 'em'. in {path}add-mixed-units.less on line 2, column 3:
2
- 1 .a {
3
- 2 error: (1px + 3em);
4
- 3 }
@@ -1,3 +0,0 @@
1
- .a {
2
- error: ((1px * 2px) + (3em * 3px));
3
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: Incompatible units. Change the units or use the unit function. Bad units: 'px*px' and 'em*px'. in {path}add-mixed-units2.less on line 2, column 3:
2
- 1 .a {
3
- 2 error: ((1px * 2px) + (3em * 3px));
4
- 3 }
@@ -1,4 +0,0 @@
1
- 
2
- @keyframes @name {
3
- 50% {width: 20px;}
4
- }
@@ -1,4 +0,0 @@
1
- NameError: variable @name is undefined in {path}at-rules-undefined-var.less on line 2, column 12:
2
- 1
3
- 2 @keyframes @name {
4
- 3 50% {width: 20px;}
@@ -1 +0,0 @@
1
- @@demo: "hi";
@@ -1,2 +0,0 @@
1
- ParseError: Unrecognised input in {path}bad-variable-declaration1.less on line 1, column 1:
2
- 1 @@demo: "hi";
@@ -1,3 +0,0 @@
1
- .test {
2
- color: color("NOT A COLOR");
3
- }
@@ -1,4 +0,0 @@
1
- ArgumentError: error evaluating function `color`: argument must be a color keyword or 3/6 digit hex e.g. #FFF in {path}color-func-invalid-color.less on line 2, column 10:
2
- 1 .test {
3
- 2 color: color("NOT A COLOR");
4
- 3 }
@@ -1,3 +0,0 @@
1
- .a {
2
- @wrongHEXColorCode: #DCALLB;
3
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: Invalid HEX color code in {path}color-invalid-hex-code.less on line 2, column 29:
2
- 1 .a {
3
- 2 @wrongHEXColorCode: #DCALLB;
4
- 3 }
@@ -1,3 +0,0 @@
1
- .a {
2
- @wrongHEXColorCode: #fffblack;
3
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: Invalid HEX color code in {path}color-invalid-hex-code2.less on line 2, column 29:
2
- 1 .a {
3
- 2 @wrongHEXColorCode: #fffblack;
4
- 3 }
@@ -1,4 +0,0 @@
1
- 
2
- selector when (default()) {
3
- color: red;
4
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: error evaluating function `default`: it is currently only allowed in parametric mixin guards, in {path}css-guard-default-func.less on line 2, column 16:
2
- 1
3
- 2 selector when (default()) {
4
- 3 color: red;
@@ -1,6 +0,0 @@
1
- @a: {
2
- b: 1;
3
- };
4
- .a {
5
- a: @a;
6
- }
@@ -1,4 +0,0 @@
1
- SyntaxError: Rulesets cannot be evaluated on a property. in {path}detached-ruleset-1.less on line 5, column 3:
2
- 4 .a {
3
- 5 a: @a;
4
- 6 }
@@ -1,6 +0,0 @@
1
- @a: {
2
- b: 1;
3
- };
4
- .a {
5
- a: @a();
6
- }