@less/test-data 3.12.2 → 4.2.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 (108) hide show
  1. package/css/_main/colors.css +6 -6
  2. package/css/_main/colors2.css +6 -0
  3. package/css/_main/container.css +148 -0
  4. package/css/_main/css-3.css +5 -10
  5. package/css/_main/css-guards.css +1 -1
  6. package/css/_main/detached-rulesets.css +4 -4
  7. package/css/_main/extend-chaining.css +2 -2
  8. package/css/_main/extend-media.css +2 -2
  9. package/css/_main/functions.css +14 -0
  10. package/css/_main/impor.css +1 -0
  11. package/css/_main/import-remote.css +1 -1
  12. package/css/_main/javascript.css +3 -3
  13. package/css/_main/media.css +53 -5
  14. package/css/_main/mixin-noparens.css +7 -0
  15. package/css/_main/mixins-guards-default-func.css +4 -4
  16. package/css/_main/permissive-parse.css +9 -0
  17. package/css/_main/plugi.css +1 -0
  18. package/css/_main/selectors.css +19 -4
  19. package/css/math/parens-division/mixins-args.css +0 -5
  20. package/css/math/parens-division/parens.css +5 -0
  21. package/css/math/strict/mixins-args.css +0 -5
  22. package/css/math/strict/parens.css +5 -0
  23. package/css/namespacing/namespacing-8.css +10 -0
  24. package/errors/eval/color-func-invalid-color-2.txt +1 -1
  25. package/errors/eval/color-func-invalid-color.txt +1 -1
  26. package/errors/eval/css-guard-default-func.txt +1 -1
  27. package/errors/eval/functions-1.txt +1 -1
  28. package/errors/eval/functions-4-call.txt +1 -1
  29. package/errors/eval/mixin-not-visible-in-scope-1.less +1 -1
  30. package/errors/eval/mixin-not-visible-in-scope-1.txt +1 -1
  31. package/errors/eval/percentage-non-number-argument.txt +1 -1
  32. package/errors/eval/recursive-variable.txt +1 -1
  33. package/errors/eval/root-func-undefined-1.txt +1 -1
  34. package/errors/eval/root-func-undefined-2.txt +1 -1
  35. package/errors/eval/svg-gradient1.txt +1 -1
  36. package/errors/eval/svg-gradient2.txt +1 -1
  37. package/errors/eval/svg-gradient3.txt +1 -1
  38. package/errors/eval/svg-gradient4.txt +1 -1
  39. package/errors/eval/svg-gradient5.txt +1 -1
  40. package/errors/eval/svg-gradient6.txt +1 -1
  41. package/errors/eval/unit-function.txt +1 -1
  42. package/less/_main/colors.less +6 -6
  43. package/less/_main/colors2.less +6 -0
  44. package/less/_main/container.less +180 -0
  45. package/less/_main/css-3.less +5 -6
  46. package/less/_main/css-escapes.less +1 -1
  47. package/less/_main/css-guards.less +1 -1
  48. package/less/_main/detached-rulesets.less +4 -4
  49. package/less/_main/directives-bubling.less +1 -1
  50. package/less/_main/extend-chaining.less +2 -2
  51. package/less/_main/extend-media.less +2 -2
  52. package/less/_main/extract-and-length.less +2 -2
  53. package/less/_main/functions.less +23 -4
  54. package/less/_main/impor.less +5 -0
  55. package/less/_main/import/import-and-relative-paths-test.less +2 -2
  56. package/less/_main/import-reference-issues/comments-2991.less +25 -0
  57. package/less/_main/import-reference-issues.less +3 -0
  58. package/less/_main/import-remote.less +2 -2
  59. package/less/_main/import.less +1 -1
  60. package/less/_main/javascript.less +3 -3
  61. package/less/_main/media.less +64 -6
  62. package/less/_main/mixin-noparens.less +9 -0
  63. package/less/_main/mixins-closure.less +3 -3
  64. package/less/_main/mixins-guards-default-func.less +5 -5
  65. package/less/_main/mixins-guards.less +2 -2
  66. package/less/_main/mixins-important.less +1 -1
  67. package/less/_main/mixins-interpolated.less +7 -7
  68. package/less/_main/mixins.less +17 -17
  69. package/less/_main/permissive-parse.less +6 -1
  70. package/less/_main/plugi.less +5 -0
  71. package/less/_main/scope.less +2 -2
  72. package/less/_main/selectors.less +23 -5
  73. package/less/_main/urls.less +2 -2
  74. package/less/import-redirect/import-redirect.less +3 -0
  75. package/less/js-type-errors/js-type-error-2.txt +4 -0
  76. package/less/js-type-errors/js-type-error.less +3 -0
  77. package/less/js-type-errors/js-type-error.txt +4 -0
  78. package/less/math/parens-division/media-math.less +1 -1
  79. package/less/math/parens-division/mixins-args.less +3 -7
  80. package/less/math/parens-division/parens.less +6 -0
  81. package/less/math/strict/mixins-args.less +3 -7
  82. package/less/math/strict/parens.less +6 -0
  83. package/less/namespacing/namespacing-3.less +1 -1
  84. package/less/namespacing/namespacing-4.less +1 -1
  85. package/less/namespacing/namespacing-8.less +31 -0
  86. package/less/sourcemaps-variable-selector/basic.less +5 -0
  87. package/less/sourcemaps-variable-selector/vars.less +3 -0
  88. package/package.json +2 -2
  89. package/css/3rd-party/uikit.css +0 -8955
  90. package/css/math/strict-legacy/css.css +0 -95
  91. package/css/math/strict-legacy/media-math.css +0 -10
  92. package/css/math/strict-legacy/mixins-args.css +0 -163
  93. package/css/math/strict-legacy/parens.css +0 -40
  94. package/errors/eval/javascript-error.less +0 -3
  95. package/errors/eval/javascript-error.txt +0 -4
  96. package/less/3rd-party/uikit.less +0 -1
  97. package/less/math/strict-legacy/css.less +0 -108
  98. package/less/math/strict-legacy/media-math.less +0 -9
  99. package/less/math/strict-legacy/mixins-args.less +0 -263
  100. package/less/math/strict-legacy/parens.less +0 -50
  101. /package/css/{no-strict-math → math/always}/mixins-guards.css +0 -0
  102. /package/css/{no-strict-math → math/always}/no-sm-operations.css +0 -0
  103. /package/css/{legacy/legacy.css → units/no-strict/no-strict.css} +0 -0
  104. /package/css/{strict-units → units/strict}/strict-units.css +0 -0
  105. /package/less/{no-strict-math → math/always}/mixins-guards.less +0 -0
  106. /package/less/{no-strict-math → math/always}/no-sm-operations.less +0 -0
  107. /package/less/{legacy/legacy.less → units/no-strict/no-strict.less} +0 -0
  108. /package/less/{strict-units → units/strict}/strict-units.less +0 -0
@@ -1,4 +1,4 @@
1
- ArgumentError: error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient3.less on line 2, column 6:
1
+ ArgumentError: Error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient3.less on line 2, column 6:
2
2
  1 .a {
3
3
  2 a: svg-gradient(black, orange);
4
4
  3 }
@@ -1,4 +1,4 @@
1
- ArgumentError: error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient4.less on line 2, column 6:
1
+ ArgumentError: Error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient4.less on line 2, column 6:
2
2
  1 .a {
3
3
  2 a: svg-gradient(horizontal, @colors);
4
4
  3 }
@@ -1,4 +1,4 @@
1
- ArgumentError: error evaluating function `svg-gradient`: svg-gradient expects direction, start_color [start_position], [color position,]..., end_color [end_position] or direction, color list in {path}svg-gradient5.less on line 2, column 6:
1
+ ArgumentError: Error evaluating function `svg-gradient`: svg-gradient expects direction, start_color [start_position], [color position,]..., end_color [end_position] or direction, color list in {path}svg-gradient5.less on line 2, column 6:
2
2
  1 .a {
3
3
  2 a: svg-gradient(to bottom, @colors);
4
4
  3 }
@@ -1,4 +1,4 @@
1
- ArgumentError: error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient6.less on line 2, column 6:
1
+ ArgumentError: Error evaluating function `svg-gradient`: svg-gradient direction must be 'to bottom', 'to right', 'to bottom right', 'to top right' or 'ellipse at center' in {path}svg-gradient6.less on line 2, column 6:
2
2
  1 .a {
3
3
  2 a: svg-gradient(black, @colors);
4
4
  3 }
@@ -1,4 +1,4 @@
1
- ArgumentError: error evaluating function `unit`: the first argument to unit must be a number. Have you forgotten parenthesis? in {path}unit-function.less on line 2, column 14:
1
+ ArgumentError: Error evaluating function `unit`: the first argument to unit must be a number. Have you forgotten parenthesis? in {path}unit-function.less on line 2, column 14:
2
2
  1 .a {
3
3
  2 font-size: unit(80/16,rem);
4
4
  3 }
@@ -44,16 +44,16 @@
44
44
  color: rgb(200, 200, 200);
45
45
  }
46
46
 
47
- #333333 {
48
- color: rgb(20%, 20%, 20%);
47
+ #aa3333 {
48
+ color: rgb(66.66%, 20%, 20%);
49
49
  }
50
50
 
51
- #808080 {
52
- color: hsl(50, 0%, 50%);
51
+ #bb8080 {
52
+ color: hsl(0deg, 30%, 62%);
53
53
  }
54
54
 
55
- #00ff00 {
56
- color: hsl(120, 100%, 50%);
55
+ #ccff00 {
56
+ color: hsl(72deg, 100%, 50%);
57
57
  }
58
58
 
59
59
  .lightenblue {
@@ -0,0 +1,6 @@
1
+ foo {
2
+ color: rgb(0 128 255);
3
+ color: rgb(0 128 255 / 50%);
4
+ color: hsl(198deg 28% 50%);
5
+ color: hsl(198deg 28% 50% / 50%);
6
+ }
@@ -0,0 +1,180 @@
1
+ .widget.discoverresults, .widget.repositoriesresults {
2
+ container-type: inline-size;
3
+
4
+ @container (max-width: 350px) {
5
+ .cite {
6
+ .wdr-authors {
7
+ display: none;
8
+ }
9
+ }
10
+ }
11
+ }
12
+
13
+ @container (min-width: 700px) {
14
+ .card h2 {
15
+ font-size: 2em;
16
+ }
17
+ }
18
+
19
+ @container sidebar (min-width: 700px) {
20
+ .card {
21
+ font-size: 2em;
22
+ }
23
+ }
24
+
25
+ @container (min-width: 60ch) {
26
+ .container:nth-child(odd) > article {
27
+ border: 1px solid grey;
28
+ }
29
+ }
30
+
31
+ @container size(min-width: 60ch) {
32
+ .article--post header {
33
+ grid-template-areas:
34
+ "avatar name"
35
+ "avatar headline";
36
+ align-items: start;
37
+ }
38
+
39
+ .article--post {
40
+ grid-template-areas: "header header" ". stats" ". content";
41
+ grid-auto-columns: 5rem 1fr;
42
+ column-gap: 1rem;
43
+ }
44
+
45
+ .article--post__title {
46
+ font-size: 1.75rem;
47
+ }
48
+ }
49
+
50
+ .card h2 {
51
+ container-type: inline-size;
52
+ margin: 0;
53
+ padding: 10px;
54
+
55
+ @container (min-width: 500px) {
56
+ .card-content {
57
+ grid-template-columns: 1fr 2fr;
58
+ grid-template-rows: auto 1fr;
59
+ align-items: start;
60
+ column-gap: 20px;
61
+ }
62
+
63
+ .card-content h2 {
64
+ padding: 0;
65
+ margin: 0.5em 0 0 0;
66
+ }
67
+ }
68
+ }
69
+
70
+ @container (width >= 500px) and (height >= 500px) {
71
+ .card-content h2 {
72
+ padding: 0;
73
+ margin: 0.5em 0 0 0;
74
+ }
75
+ }
76
+
77
+ @container (width > 760px) not (height > 670px) {
78
+ .card-content h2 {
79
+ padding: 0;
80
+ margin: 0.5em 0 0 0;
81
+ }
82
+ }
83
+
84
+ @container not (height <= 1080px) {
85
+ .card-content h2 {
86
+ padding: 0;
87
+ margin: 0.5em 0 0 0;
88
+ }
89
+ }
90
+
91
+ @container (width < 500px) or (height < 500px) {
92
+ .card-content h2 {
93
+ padding: 0;
94
+ margin: 0.5em 0 0 0;
95
+ }
96
+ }
97
+
98
+ @container (width < 500px) or (height < 500px) and (inline-size >= 0px) {
99
+ .card-content p {
100
+ padding: 0;
101
+
102
+ h2 {
103
+ margin: 0.5em 0 0 0;
104
+ }
105
+ }
106
+ }
107
+
108
+ @container my-page-layout (width < 500px) or (height < 500px) and (block-size > 12em) {
109
+ .card-content p {
110
+ padding: 0;
111
+
112
+ h2 {
113
+ margin: 0.5em 0 0 0;
114
+ }
115
+ }
116
+ }
117
+
118
+ @container (width < 500px) or (height < 500px) and (aspect-ratio: 3/2) {
119
+ .card-content p {
120
+ padding: 0;
121
+
122
+ h2 {
123
+ margin: 0.5em 0 0 0;
124
+ }
125
+ }
126
+ }
127
+
128
+ @container (width < 500px) or (height < 500px) and (orientation: portrait) {
129
+ .card-content p {
130
+ padding: 0;
131
+
132
+ h2 {
133
+ margin: 0.5em 0 0 0;
134
+ }
135
+ }
136
+ }
137
+
138
+ @container card (inline-size > 30em) {
139
+ .card-content p {
140
+ padding: 0;
141
+
142
+ h2 {
143
+ margin: 0.5em 0 0 0;
144
+ }
145
+ }
146
+
147
+ @container style(--responsive: true) {
148
+ .card-content {
149
+ grid-template-columns: 1fr 2fr;
150
+ grid-template-rows: auto 1fr;
151
+ align-items: start;
152
+ column-gap: 20px;
153
+ }
154
+
155
+ .card-content h2 {
156
+ padding: 0;
157
+ margin: 0.5em 0 0 0;
158
+ }
159
+ }
160
+ }
161
+
162
+ @container ( width < 500px ) or (height<500px) and (orientation: portrait) {
163
+ .card-content p {
164
+ padding: 0;
165
+
166
+ h2 {
167
+ margin: 0.5em 0 0 0;
168
+ }
169
+ }
170
+ }
171
+
172
+ @container my-page-layout ( width< 500px) or ( height<500px) and ( block-size>12em ) {
173
+ .card-content p {
174
+ padding: 0;
175
+
176
+ h2 {
177
+ margin: 0.5em 0 0 0;
178
+ }
179
+ }
180
+ }
@@ -100,7 +100,6 @@ p::before {
100
100
 
101
101
  foo|h1 { color: blue; }
102
102
  foo|* { color: yellow; }
103
- |h1 { color: red; }
104
103
  *|h1 { color: green; }
105
104
  h1 { color: green; }
106
105
  .upper-test {
@@ -114,18 +113,18 @@ h1 { color: green; }
114
113
  ::distributed(input::placeholder) {
115
114
  color: #b3b3b3;
116
115
  }
117
- .shadow ^ .dom,
118
- body ^^ .shadow {
116
+ .shadow > .dom,
117
+ body > .shadow {
119
118
  display: done;
120
119
  }
121
120
 
122
121
  :host(.sel .a),
123
122
  :host-context(.sel .b),
124
- .sel /deep/ .b,
123
+ .sel > .b,
125
124
  ::content .sel {
126
125
  type: shadow-dom;
127
126
  }
128
- /deep/ b {
127
+ * b {
129
128
  c: 'd';
130
129
  &[e]{
131
130
  f: 'g';
@@ -147,7 +146,7 @@ body ^^ .shadow {
147
146
  }
148
147
 
149
148
  @unknown foo 42 (bar) {
150
- x {y: z}
149
+ x {y: z}
151
150
  }
152
151
 
153
152
  @unknown foo 43;
@@ -14,7 +14,7 @@
14
14
 
15
15
  strong {
16
16
  color: @ugly;
17
- .mixin\!tUp;
17
+ .mixin\!tUp();
18
18
  }
19
19
  }
20
20
 
@@ -80,7 +80,7 @@
80
80
  & when (@c = 3) {
81
81
  height: 1px;
82
82
  }
83
- + & when (@c = 3) { // creates invalid css but tests that we don't fold it in
83
+ * & when (@c = 3) {
84
84
  sibling: true;
85
85
  }
86
86
  }
@@ -67,7 +67,7 @@ header {
67
67
  }
68
68
  @my-ruleset: {
69
69
  .my-selector {
70
- @media tv {
70
+ @media (tv) {
71
71
  background-color: black;
72
72
  }
73
73
  }
@@ -75,7 +75,7 @@ header {
75
75
  @media (orientation:portrait) {
76
76
  @my-ruleset();
77
77
  .wrap-media-mixin({
78
- @media tv {
78
+ @media (tv) {
79
79
  .triple-wrapped-mq {
80
80
  triple: true;
81
81
  }
@@ -83,8 +83,8 @@ header {
83
83
  });
84
84
  }
85
85
  .wrap-media-mixin(@ruleset) {
86
- @media widescreen {
87
- @media print {
86
+ @media (widescreen) {
87
+ @media (print) {
88
88
  @ruleset();
89
89
  }
90
90
  @ruleset();
@@ -122,7 +122,7 @@
122
122
  }
123
123
 
124
124
  html {
125
- .nestedSupportsMixin;
125
+ .nestedSupportsMixin();
126
126
  }
127
127
 
128
128
  // selectors should not propagate into all directive types
@@ -73,14 +73,14 @@
73
73
 
74
74
  // media queries - don't extend outside, do extend inside
75
75
 
76
- @media tv {
76
+ @media (tv) {
77
77
  .ma:extend(.a,.b,.c,.d,.e,.f,.g,.h,.i,.j,.k,.l,.m,.n,.o,.p,.q,.r,.s,.t,.u,.v,.w,.x,.y,.z,.md) {
78
78
  color: black;
79
79
  }
80
80
  .md {
81
81
  color: inherit;
82
82
  }
83
- @media plasma {
83
+ @media (plasma) {
84
84
  .me, .mf {
85
85
  &:extend(.mb,.md);
86
86
  background: red;
@@ -2,14 +2,14 @@
2
2
  background: black;
3
3
  }
4
4
 
5
- @media tv {
5
+ @media (tv) {
6
6
  .ext1 .ext3 {
7
7
  color: inherit;
8
8
  }
9
9
  .tv-lowres :extend(.ext1 all) {
10
10
  background: blue;
11
11
  }
12
- @media hires {
12
+ @media (hires) {
13
13
  .ext1 .ext4 {
14
14
  color: green;
15
15
  }
@@ -5,12 +5,12 @@
5
5
  .a(@i: length(@cols)) when (@i > 0) {
6
6
  @divider: e(extract(@cols, @i));
7
7
  }
8
- .a;
8
+ .a();
9
9
 
10
10
  .b(@j: 1) when (@j < length(@cols)) {
11
11
  @divider: e(extract(@cols, @j));
12
12
  }
13
- .b;
13
+ .b();
14
14
 
15
15
  // simple array/list:
16
16
 
@@ -116,8 +116,11 @@
116
116
  min: min(6, 5);
117
117
  min: min(1pt, 3pt);
118
118
  min: min(1cm, 3mm);
119
+ min: min(6em, 5, 4ex, 3, 2pt, 1);
119
120
  max: max(1, 3);
120
121
  max: max(3em, 1em, 2em, 5em);
122
+ max: max(1px, 2, 3em, 4, 5m, 6);
123
+ max-native: max(10vw, 100px);
121
124
  percentage: percentage((10px / 50));
122
125
  color-quoted-digit: color("#dda0dd");
123
126
  color-quoted-keyword: color("plum");
@@ -134,11 +137,11 @@
134
137
 
135
138
  fade-out: fadeout(red, 5%); // support fadeOut and fadeout
136
139
  fade-in: fadein(fadeout(red, 10%), 5%);
137
- fade-out-relative: fadeout(red, 5%,relative);
140
+ fade-out-relative: fadeout(red, 5%,relative);
138
141
  fade-in-relative: fadein(fadeout(red, 10%, relative), 5%, relative);
139
- fade-out2: fadeout(fadeout(red, 50%), 50%);
142
+ fade-out2: fadeout(fadeout(red, 50%), 50%);
140
143
  fade-out2-relative: fadeout(fadeout(red, 50%, relative), 50%, relative);
141
-
144
+
142
145
  hsv: hsv(5, 50%, 30%);
143
146
  hsva: hsva(3, 50%, 30%, 0.2);
144
147
 
@@ -152,6 +155,8 @@
152
155
  @rules: {
153
156
  color: red;
154
157
  };
158
+ rules-defined: isdefined(@rules);
159
+ foo-defined: isdefined(@foo);
155
160
  ruleset: isruleset(@rules);
156
161
  color: iscolor(#ddd);
157
162
  color1: iscolor(red);
@@ -266,7 +271,7 @@ html {
266
271
  // see: https://github.com/less/less.js/issues/3371
267
272
  @some: foo;
268
273
  l: if((iscolor(@some)), darken(@some, 10%), black);
269
-
274
+
270
275
 
271
276
  if((false), {g: 7}); /* results in void */
272
277
 
@@ -282,3 +287,17 @@ html {
282
287
  });
283
288
  @falsey();
284
289
  }
290
+
291
+ .paren-escapes {
292
+ list-1: ~(1, 2, 3);
293
+ length-1: length($list-1);
294
+ each(~(1 2 3); {
295
+ item-@{value}: @value + 3;
296
+ })
297
+
298
+ .mixin(@list-1; @list-2) {
299
+ list-2: @list-1;
300
+ list-3: @list-2;
301
+ }
302
+ .mixin($list-1, ~(7; 8; 9));
303
+ }
@@ -0,0 +1,5 @@
1
+ // https://github.com/less/less.js/issues/3660
2
+ // const dir = parserInput.$re(/^@import?\s+/);
3
+ // correct regexp is /^@import\s+/
4
+ // so follow code will change nothing, parse result is same with raw less code
5
+ @impor "impor-typo-dont-parse-as-@import.less";
@@ -12,6 +12,6 @@
12
12
  }
13
13
 
14
14
  #imported-relative-path {
15
- .unquoted-relative-path-bg;
16
- .quoted-relative-path-border-image;
15
+ .unquoted-relative-path-bg();
16
+ .quoted-relative-path-border-image();
17
17
  }
@@ -0,0 +1,25 @@
1
+ .referenced {
2
+ // This file should not output anything if referenced.
3
+ @media (hover) {
4
+ // This file should not output anything if referenced.
5
+ }
6
+ // This file should not output anything if referenced.
7
+ @media (hover) {
8
+ // This file should not output anything if referenced.
9
+ }
10
+ // This file should not output anything if referenced.
11
+ @media (hover) {
12
+ /* This file should not output anything if referenced. */
13
+ }
14
+ // This file should not output anything if referenced.
15
+ @media (hover) {
16
+ color: #000000;
17
+ }
18
+ }
19
+ // This file should not output anything if referenced.
20
+ @media (hover) {
21
+ // This file should not output anything if referenced.
22
+ }
23
+ @media (hover) {
24
+ /* This file should not output anything if referenced. */
25
+ }
@@ -5,6 +5,7 @@
5
5
  // * #2716 - A file imported by reference and then normally - multiple imports should be independent
6
6
  // * #1968 - When using an @import (reference), mixins that contain an & selector get added to the compiled output improperly
7
7
  // * #2162 - Cannot put import by reference inside of a mixin (also doubles #1896)
8
+ // * #2991 - Empty @media queries generated through line comments when compiling less file with (reference)
8
9
 
9
10
  // #1878: extend inside referenced file should not extend outside selectors
10
11
  @import (reference) "import-reference-issues/global-scope-import.less";
@@ -48,3 +49,5 @@ show-all-content {
48
49
  call-mixin-with-import-by-reference-inside {
49
50
  .mixin-with-import-by-reference-inside();
50
51
  }
52
+
53
+ @import (reference) "import-reference-issues/comments-2991.less";
@@ -1,8 +1,8 @@
1
1
  // https://github.com/less/less.js/issues/3541
2
2
  @import (reference) url(https://cdn.jsdelivr.net/npm/@less/test-data/less/_main/selectors.less);
3
- @import (reference) url("https://cdn.jsdelivr.net/npm/@less/test-data/less/_main/scope.less");
3
+ @import (reference) url("https://cdn.jsdelivr.net/npm/@less/test-data/less/_main/media.less");
4
4
  @import (reference) url("https://cdn.jsdelivr.net/npm/@less/test-data/less/_main/empty.less?arg");
5
5
 
6
6
  .test {
7
- color: @x;
7
+ color: @var;
8
8
  }
@@ -9,7 +9,7 @@
9
9
  @import url("//ha.com/file.css") (min-width:@var);
10
10
 
11
11
  #import-test {
12
- .mixin;
12
+ .mixin();
13
13
  width: 10px;
14
14
  height: (@a + 10%);
15
15
  value: pi-anon();
@@ -30,9 +30,9 @@
30
30
  }
31
31
  .transitions(...) {
32
32
  @arg: ~`"@{arguments}".replace(/[\[\]]*/g, '')`;
33
- 1: @arg; // rounded to integers
34
- 2: ~`"@{arguments}"`; // rounded to integers
35
- 3: @arguments; // OK
33
+ one: @arg; // rounded to integers
34
+ two: ~`"@{arguments}"`; // rounded to integers
35
+ three: @arguments; // OK
36
36
  }
37
37
  .test-rule-tran {
38
38
  .transitions(opacity 0.3s ease-in 0.3s, max-height 0.6s linear, margin-bottom 0.4s linear;);
@@ -62,11 +62,11 @@
62
62
 
63
63
  @media a {
64
64
  .first {
65
- @media b {
65
+ @media (b) {
66
66
  .second {
67
67
  .third {
68
68
  width: 300px;
69
- @media c {
69
+ @media (c) {
70
70
  width: 500px;
71
71
  }
72
72
  }
@@ -79,10 +79,10 @@
79
79
  }
80
80
 
81
81
  .body {
82
- @media a, b and c {
82
+ @media a, (b) and (c) {
83
83
  width: 95%;
84
84
 
85
- @media x, y {
85
+ @media (x), (y) {
86
86
  width: 100%;
87
87
  }
88
88
  }
@@ -226,7 +226,7 @@
226
226
  }
227
227
  }
228
228
  @all: ~"all";
229
- @tv: ~"tv";
229
+ @tv: ~"(tv)";
230
230
  @media @all and @tv {
231
231
  .all-and-tv-variables {
232
232
  var: all-and-tv;
@@ -238,4 +238,62 @@
238
238
  .selector {
239
239
  foo: bar;
240
240
  }
241
- }
241
+ }
242
+
243
+ @media screen and (color), projection and (color) {
244
+ .selector {
245
+ color: #eee;
246
+ }
247
+ }
248
+
249
+ @media not (width <= -100px) {
250
+ body {
251
+ background: green;
252
+ }
253
+ }
254
+
255
+ @media (height > -100px) {
256
+ body {
257
+ background: green;
258
+ }
259
+ }
260
+
261
+ @media not (resolution: -300dpi) {
262
+ body {
263
+ background: green;
264
+ }
265
+ }
266
+
267
+ @media (example, all,), speech {
268
+ body {
269
+ background: green;
270
+ }
271
+ }
272
+
273
+ @media (min-orientation:portrait) {
274
+ body {
275
+ background: green;
276
+ }
277
+ }
278
+
279
+ @media print and (min-resolution: 118dpcm) {
280
+ body {
281
+ background: green;
282
+ }
283
+ }
284
+
285
+ @media (200px <= width <= 500px) {
286
+ .test-range-syntax {
287
+ padding: 0;
288
+ }
289
+ }
290
+
291
+ .selector {
292
+ color: #eee;
293
+
294
+ @media (200px <= width <= 500px) {
295
+ .test-range-syntax {
296
+ padding: 0;
297
+ }
298
+ }
299
+ }
@@ -0,0 +1,9 @@
1
+ #theme {
2
+ > .mixin {
3
+ background-color: grey;
4
+ }
5
+ }
6
+ #container {
7
+ color: black;
8
+ #theme > .mixin;
9
+ }
@@ -6,12 +6,12 @@
6
6
  }
7
7
 
8
8
  .class {
9
- .scope > .mixin;
9
+ .scope > .mixin();
10
10
  }
11
11
 
12
12
  .overwrite {
13
13
  @var: 0px;
14
- .scope > .mixin;
14
+ .scope > .mixin();
15
15
  }
16
16
 
17
17
  .nested {
@@ -21,6 +21,6 @@
21
21
  }
22
22
  .class {
23
23
  @var: 10px;
24
- .mixin;
24
+ .mixin();
25
25
  }
26
26
  }