@unocss/preset-wind 0.40.0 → 0.41.2

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.
package/dist/index.cjs CHANGED
@@ -3,7 +3,6 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const presetMini = require('@unocss/preset-mini');
6
- const core = require('@unocss/core');
7
6
  const utils = require('@unocss/preset-mini/utils');
8
7
  const rules$1 = require('@unocss/preset-mini/rules');
9
8
  const theme$1 = require('@unocss/preset-mini/theme');
@@ -163,6 +162,7 @@ const backgroundStyles = [
163
162
  ["bg-none", { "background-image": "none" }],
164
163
  ["box-decoration-slice", { "box-decoration-break": "slice" }],
165
164
  ["box-decoration-clone", { "box-decoration-break": "clone" }],
165
+ ...utils.makeGlobalStaticRules("box-decoration", "box-decoration-break"),
166
166
  ["bg-auto", { "background-size": "auto" }],
167
167
  ["bg-cover", { "background-size": "cover" }],
168
168
  ["bg-contain", { "background-size": "contain" }],
@@ -173,6 +173,10 @@ const backgroundStyles = [
173
173
  ["bg-clip-content", { "-webkit-background-clip": "content-box", "background-clip": "content-box" }],
174
174
  ["bg-clip-padding", { "-webkit-background-clip": "padding-box", "background-clip": "padding-box" }],
175
175
  ["bg-clip-text", { "-webkit-background-clip": "text", "background-clip": "text" }],
176
+ ...utils.globalKeywords.map((keyword) => [`bg-clip-${keyword}`, {
177
+ "-webkit-background-clip": keyword,
178
+ "background-clip": keyword
179
+ }]),
176
180
  [/^bg-([-\w]{3,})$/, ([, s]) => ({ "background-position": utils.positionMap[s] })],
177
181
  ["bg-repeat", { "background-repeat": "repeat" }],
178
182
  ["bg-no-repeat", { "background-repeat": "no-repeat" }],
@@ -180,9 +184,11 @@ const backgroundStyles = [
180
184
  ["bg-repeat-y", { "background-repeat": "repeat-y" }],
181
185
  ["bg-repeat-round", { "background-repeat": "round" }],
182
186
  ["bg-repeat-space", { "background-repeat": "space" }],
187
+ ...utils.makeGlobalStaticRules("bg-repeat", "background-repeat"),
183
188
  ["bg-origin-border", { "background-origin": "border-box" }],
184
189
  ["bg-origin-padding", { "background-origin": "padding-box" }],
185
- ["bg-origin-content", { "background-origin": "content-box" }]
190
+ ["bg-origin-content", { "background-origin": "content-box" }],
191
+ ...utils.makeGlobalStaticRules("bg-origin", "background-origin")
186
192
  ];
187
193
 
188
194
  const listStyles = {
@@ -211,7 +217,8 @@ const listStyle = [
211
217
  }, { autocomplete: [`list-(${Object.keys(listStyles).join("|")})`, `list-(${Object.keys(listStyles).join("|")})-(outside|inside)`] }],
212
218
  ["list-outside", { "list-style-position": "outside" }],
213
219
  ["list-inside", { "list-style-position": "inside" }],
214
- ["list-none", { "list-style-type": "none" }]
220
+ ["list-none", { "list-style-type": "none" }],
221
+ ...utils.makeGlobalStaticRules("list", "list-style")
215
222
  ];
216
223
  const accents = [
217
224
  [/^accent-(.+)$/, utils.colorResolver("accent-color", "accent"), { autocomplete: "accent-$colors" }],
@@ -236,16 +243,20 @@ const overscrolls = [
236
243
  ["overscroll-auto", { "overscroll-behavior": "auto" }],
237
244
  ["overscroll-contain", { "overscroll-behavior": "contain" }],
238
245
  ["overscroll-none", { "overscroll-behavior": "none" }],
246
+ ...utils.makeGlobalStaticRules("overscroll", "overscroll-behavior"),
239
247
  ["overscroll-x-auto", { "overscroll-behavior-x": "auto" }],
240
248
  ["overscroll-x-contain", { "overscroll-behavior-x": "contain" }],
241
249
  ["overscroll-x-none", { "overscroll-behavior-x": "none" }],
250
+ ...utils.makeGlobalStaticRules("overscroll-x", "overscroll-behavior-x"),
242
251
  ["overscroll-y-auto", { "overscroll-behavior-y": "auto" }],
243
252
  ["overscroll-y-contain", { "overscroll-behavior-y": "contain" }],
244
- ["overscroll-y-none", { "overscroll-behavior-y": "none" }]
253
+ ["overscroll-y-none", { "overscroll-behavior-y": "none" }],
254
+ ...utils.makeGlobalStaticRules("overscroll-y", "overscroll-behavior-y")
245
255
  ];
246
256
  const scrollBehaviors = [
247
257
  ["scroll-auto", { "scroll-behavior": "auto" }],
248
- ["scroll-smooth", { "scroll-behavior": "smooth" }]
258
+ ["scroll-smooth", { "scroll-behavior": "smooth" }],
259
+ ...utils.makeGlobalStaticRules("scroll", "scroll-behavior")
249
260
  ];
250
261
 
251
262
  const columns = [
@@ -258,10 +269,12 @@ const columns = [
258
269
  ["break-before-left", { "break-before": "left" }],
259
270
  ["break-before-right", { "break-before": "right" }],
260
271
  ["break-before-column", { "break-before": "column" }],
272
+ ...utils.makeGlobalStaticRules("break-before"),
261
273
  ["break-inside-auto", { "break-inside": "auto" }],
262
274
  ["break-inside-avoid", { "break-inside": "avoid" }],
263
275
  ["break-inside-avoid-page", { "break-inside": "avoid-page" }],
264
276
  ["break-inside-avoid-column", { "break-inside": "avoid-column" }],
277
+ ...utils.makeGlobalStaticRules("break-inside"),
265
278
  ["break-after-auto", { "break-after": "auto" }],
266
279
  ["break-after-avoid", { "break-after": "avoid" }],
267
280
  ["break-after-all", { "break-after": "all" }],
@@ -269,23 +282,31 @@ const columns = [
269
282
  ["break-after-page", { "break-after": "page" }],
270
283
  ["break-after-left", { "break-after": "left" }],
271
284
  ["break-after-right", { "break-after": "right" }],
272
- ["break-after-column", { "break-after": "column" }]
285
+ ["break-after-column", { "break-after": "column" }],
286
+ ...utils.makeGlobalStaticRules("break-after")
273
287
  ];
274
288
 
275
289
  const queryMatcher = /@media \(min-width: (.+)\)/;
276
290
  const container = [
277
291
  [
278
292
  /^__container$/,
279
- (m, { variantHandlers }) => {
293
+ (m, { theme, variantHandlers }) => {
280
294
  let width = "100%";
281
295
  for (const v of variantHandlers) {
282
- const query = core.toArray(v.parent || [])[0];
296
+ const query = v.handle?.({}, (x) => x)?.parent;
283
297
  if (typeof query === "string") {
284
298
  const match = query.match(queryMatcher)?.[1];
285
299
  if (match)
286
300
  width = match;
287
301
  }
288
302
  }
303
+ if (theme.container?.center) {
304
+ return {
305
+ "max-width": width,
306
+ "margin-left": "auto",
307
+ "margin-right": "auto"
308
+ };
309
+ }
289
310
  return { "max-width": width };
290
311
  },
291
312
  { internal: true }
@@ -410,7 +431,12 @@ const filters = [
410
431
  ["backdrop-filter-none", {
411
432
  "-webkit-backdrop-filter": "none",
412
433
  "backdrop-filter": "none"
413
- }]
434
+ }],
435
+ ...utils.globalKeywords.map((keyword) => [`filter-${keyword}`, { filter: keyword }]),
436
+ ...utils.globalKeywords.map((keyword) => [`backdrop-filter-${keyword}`, {
437
+ "-webkit-backdrop-filter": keyword,
438
+ "backdrop-filter": keyword
439
+ }])
414
440
  ];
415
441
 
416
442
  const spaces = [
@@ -443,31 +469,23 @@ const textTransforms = [
443
469
  ["normal-case", { "text-transform": "none" }]
444
470
  ];
445
471
  const hyphens = [
446
- ["hyphens-manual", {
447
- "-webkit-hyphens": "manual",
448
- "-ms-hyphens": "manual",
449
- "hyphens": "manual"
450
- }],
451
- ["hyphens-auto", {
452
- "-webkit-hyphens": "auto",
453
- "-ms-hyphens": "auto",
454
- "hyphens": "auto"
455
- }],
456
- ["hyphens-none", {
457
- "-webkit-hyphens": "none",
458
- "-ms-hyphens": "none",
459
- "hyphens": "none"
460
- }]
472
+ ...["manual", "auto", "none", ...utils.globalKeywords].map((keyword) => [`hyphens-${keyword}`, {
473
+ "-webkit-hyphens": keyword,
474
+ "-ms-hyphens": keyword,
475
+ "hyphens": keyword
476
+ }])
461
477
  ];
462
478
  const writingModes = [
463
479
  ["write-vertical-right", { "writing-mode": "vertical-rl" }],
464
480
  ["write-vertical-left", { "writing-mode": "vertical-lr" }],
465
- ["write-normal", { "writing-mode": "horizontal-tb" }]
481
+ ["write-normal", { "writing-mode": "horizontal-tb" }],
482
+ ...utils.makeGlobalStaticRules("write", "writing-mode")
466
483
  ];
467
484
  const writingOrientations = [
468
485
  ["write-orient-mixed", { "text-orientation": "mixed" }],
469
486
  ["write-orient-sideways", { "text-orientation": "sideways" }],
470
- ["write-orient-upright", { "text-orientation": "upright" }]
487
+ ["write-orient-upright", { "text-orientation": "upright" }],
488
+ ...utils.makeGlobalStaticRules("write-orient", "text-orientation")
471
489
  ];
472
490
  const screenReadersAccess = [
473
491
  [
@@ -532,7 +550,8 @@ const backgroundBlendModes = [
532
550
  ["bg-blend-saturation", { "background-blend-mode": "saturation" }],
533
551
  ["bg-blend-color", { "background-blend-mode": "color" }],
534
552
  ["bg-blend-luminosity", { "background-blend-mode": "luminosity" }],
535
- ["bg-blend-normal", { "background-blend-mode": "normal" }]
553
+ ["bg-blend-normal", { "background-blend-mode": "normal" }],
554
+ ...utils.makeGlobalStaticRules("bg-blend", "background-blend")
536
555
  ];
537
556
  const mixBlendModes = [
538
557
  ["mix-blend-multiply", { "mix-blend-mode": "multiply" }],
@@ -551,7 +570,8 @@ const mixBlendModes = [
551
570
  ["mix-blend-color", { "mix-blend-mode": "color" }],
552
571
  ["mix-blend-luminosity", { "mix-blend-mode": "luminosity" }],
553
572
  ["mix-blend-plus-lighter", { "mix-blend-mode": "plus-lighter" }],
554
- ["mix-blend-normal", { "mix-blend-mode": "normal" }]
573
+ ["mix-blend-normal", { "mix-blend-mode": "normal" }],
574
+ ...utils.makeGlobalStaticRules("mix-blend")
555
575
  ];
556
576
 
557
577
  const borderSpacingBase = {
@@ -712,7 +732,8 @@ const touchActions = [
712
732
  }],
713
733
  ["touch-auto", { "touch-action": "auto" }],
714
734
  ["touch-manipulation", { "touch-action": "manipulation" }],
715
- ["touch-none", { "touch-action": "none" }]
735
+ ["touch-none", { "touch-action": "none" }],
736
+ ...utils.makeGlobalStaticRules("touch", "touch-action")
716
737
  ];
717
738
 
718
739
  const scrollSnapTypeBase = {
@@ -1044,8 +1065,8 @@ const variantCombinators = [
1044
1065
  ];
1045
1066
 
1046
1067
  const variantColorsScheme = [
1047
- utils.variantMatcher(".dark", (input) => ({ prefix: `${input.prefix}.dark $$ ` })),
1048
- utils.variantMatcher(".light", (input) => ({ prefix: `${input.prefix}.light $$ ` })),
1068
+ utils.variantMatcher(".dark", (input) => ({ prefix: `.dark $$ ${input.prefix}` })),
1069
+ utils.variantMatcher(".light", (input) => ({ prefix: `.light $$ ${input.prefix}` })),
1049
1070
  utils.variantParentMatcher("@dark", "@media (prefers-color-scheme: dark)"),
1050
1071
  utils.variantParentMatcher("@light", "@media (prefers-color-scheme: light)")
1051
1072
  ];
package/dist/index.mjs CHANGED
@@ -1,7 +1,6 @@
1
1
  import { preflights } from '@unocss/preset-mini';
2
2
  export { colors, preflights } from '@unocss/preset-mini';
3
- import { toArray } from '@unocss/core';
4
- import { handler, positionMap, parseColor, colorToString, colorOpacityToString, colorResolver, resolveBreakpoints, colorableShadows, directionMap, directionSize, variantMatcher, variantParentMatcher, hasParseableColor } from '@unocss/preset-mini/utils';
3
+ import { handler, positionMap, makeGlobalStaticRules, globalKeywords, parseColor, colorToString, colorOpacityToString, colorResolver, resolveBreakpoints, colorableShadows, directionMap, directionSize, variantMatcher, variantParentMatcher, hasParseableColor } from '@unocss/preset-mini/utils';
5
4
  import { varEmpty, cssVariables as cssVariables$1, cssProperty, pointerEvents, appearances, positions, insets, zIndexes, orders, grids, floats, margins, boxSizing, displays, aspectRatio, sizes, flex, transforms, cursors, userSelects, resizes, appearance, placements, alignments, justifies, gaps, overflows, textOverflows, whitespaces, breaks, borders, bgColors, svgUtilities, paddings, textAligns, textIndents, verticalAligns, fonts, textTransforms as textTransforms$1, fontStyles, textColors, textDecorations, fontSmoothings, tabSizes, textStrokes, textShadows, opacity, boxShadows, outline, rings, transitions, willChange, contents, questionMark, transformBase, boxShadowsBase, ringBase } from '@unocss/preset-mini/rules';
6
5
  import { theme as theme$1 } from '@unocss/preset-mini/theme';
7
6
  import { variants as variants$1 } from '@unocss/preset-mini/variants';
@@ -160,6 +159,7 @@ const backgroundStyles = [
160
159
  ["bg-none", { "background-image": "none" }],
161
160
  ["box-decoration-slice", { "box-decoration-break": "slice" }],
162
161
  ["box-decoration-clone", { "box-decoration-break": "clone" }],
162
+ ...makeGlobalStaticRules("box-decoration", "box-decoration-break"),
163
163
  ["bg-auto", { "background-size": "auto" }],
164
164
  ["bg-cover", { "background-size": "cover" }],
165
165
  ["bg-contain", { "background-size": "contain" }],
@@ -170,6 +170,10 @@ const backgroundStyles = [
170
170
  ["bg-clip-content", { "-webkit-background-clip": "content-box", "background-clip": "content-box" }],
171
171
  ["bg-clip-padding", { "-webkit-background-clip": "padding-box", "background-clip": "padding-box" }],
172
172
  ["bg-clip-text", { "-webkit-background-clip": "text", "background-clip": "text" }],
173
+ ...globalKeywords.map((keyword) => [`bg-clip-${keyword}`, {
174
+ "-webkit-background-clip": keyword,
175
+ "background-clip": keyword
176
+ }]),
173
177
  [/^bg-([-\w]{3,})$/, ([, s]) => ({ "background-position": positionMap[s] })],
174
178
  ["bg-repeat", { "background-repeat": "repeat" }],
175
179
  ["bg-no-repeat", { "background-repeat": "no-repeat" }],
@@ -177,9 +181,11 @@ const backgroundStyles = [
177
181
  ["bg-repeat-y", { "background-repeat": "repeat-y" }],
178
182
  ["bg-repeat-round", { "background-repeat": "round" }],
179
183
  ["bg-repeat-space", { "background-repeat": "space" }],
184
+ ...makeGlobalStaticRules("bg-repeat", "background-repeat"),
180
185
  ["bg-origin-border", { "background-origin": "border-box" }],
181
186
  ["bg-origin-padding", { "background-origin": "padding-box" }],
182
- ["bg-origin-content", { "background-origin": "content-box" }]
187
+ ["bg-origin-content", { "background-origin": "content-box" }],
188
+ ...makeGlobalStaticRules("bg-origin", "background-origin")
183
189
  ];
184
190
 
185
191
  const listStyles = {
@@ -208,7 +214,8 @@ const listStyle = [
208
214
  }, { autocomplete: [`list-(${Object.keys(listStyles).join("|")})`, `list-(${Object.keys(listStyles).join("|")})-(outside|inside)`] }],
209
215
  ["list-outside", { "list-style-position": "outside" }],
210
216
  ["list-inside", { "list-style-position": "inside" }],
211
- ["list-none", { "list-style-type": "none" }]
217
+ ["list-none", { "list-style-type": "none" }],
218
+ ...makeGlobalStaticRules("list", "list-style")
212
219
  ];
213
220
  const accents = [
214
221
  [/^accent-(.+)$/, colorResolver("accent-color", "accent"), { autocomplete: "accent-$colors" }],
@@ -233,16 +240,20 @@ const overscrolls = [
233
240
  ["overscroll-auto", { "overscroll-behavior": "auto" }],
234
241
  ["overscroll-contain", { "overscroll-behavior": "contain" }],
235
242
  ["overscroll-none", { "overscroll-behavior": "none" }],
243
+ ...makeGlobalStaticRules("overscroll", "overscroll-behavior"),
236
244
  ["overscroll-x-auto", { "overscroll-behavior-x": "auto" }],
237
245
  ["overscroll-x-contain", { "overscroll-behavior-x": "contain" }],
238
246
  ["overscroll-x-none", { "overscroll-behavior-x": "none" }],
247
+ ...makeGlobalStaticRules("overscroll-x", "overscroll-behavior-x"),
239
248
  ["overscroll-y-auto", { "overscroll-behavior-y": "auto" }],
240
249
  ["overscroll-y-contain", { "overscroll-behavior-y": "contain" }],
241
- ["overscroll-y-none", { "overscroll-behavior-y": "none" }]
250
+ ["overscroll-y-none", { "overscroll-behavior-y": "none" }],
251
+ ...makeGlobalStaticRules("overscroll-y", "overscroll-behavior-y")
242
252
  ];
243
253
  const scrollBehaviors = [
244
254
  ["scroll-auto", { "scroll-behavior": "auto" }],
245
- ["scroll-smooth", { "scroll-behavior": "smooth" }]
255
+ ["scroll-smooth", { "scroll-behavior": "smooth" }],
256
+ ...makeGlobalStaticRules("scroll", "scroll-behavior")
246
257
  ];
247
258
 
248
259
  const columns = [
@@ -255,10 +266,12 @@ const columns = [
255
266
  ["break-before-left", { "break-before": "left" }],
256
267
  ["break-before-right", { "break-before": "right" }],
257
268
  ["break-before-column", { "break-before": "column" }],
269
+ ...makeGlobalStaticRules("break-before"),
258
270
  ["break-inside-auto", { "break-inside": "auto" }],
259
271
  ["break-inside-avoid", { "break-inside": "avoid" }],
260
272
  ["break-inside-avoid-page", { "break-inside": "avoid-page" }],
261
273
  ["break-inside-avoid-column", { "break-inside": "avoid-column" }],
274
+ ...makeGlobalStaticRules("break-inside"),
262
275
  ["break-after-auto", { "break-after": "auto" }],
263
276
  ["break-after-avoid", { "break-after": "avoid" }],
264
277
  ["break-after-all", { "break-after": "all" }],
@@ -266,23 +279,31 @@ const columns = [
266
279
  ["break-after-page", { "break-after": "page" }],
267
280
  ["break-after-left", { "break-after": "left" }],
268
281
  ["break-after-right", { "break-after": "right" }],
269
- ["break-after-column", { "break-after": "column" }]
282
+ ["break-after-column", { "break-after": "column" }],
283
+ ...makeGlobalStaticRules("break-after")
270
284
  ];
271
285
 
272
286
  const queryMatcher = /@media \(min-width: (.+)\)/;
273
287
  const container = [
274
288
  [
275
289
  /^__container$/,
276
- (m, { variantHandlers }) => {
290
+ (m, { theme, variantHandlers }) => {
277
291
  let width = "100%";
278
292
  for (const v of variantHandlers) {
279
- const query = toArray(v.parent || [])[0];
293
+ const query = v.handle?.({}, (x) => x)?.parent;
280
294
  if (typeof query === "string") {
281
295
  const match = query.match(queryMatcher)?.[1];
282
296
  if (match)
283
297
  width = match;
284
298
  }
285
299
  }
300
+ if (theme.container?.center) {
301
+ return {
302
+ "max-width": width,
303
+ "margin-left": "auto",
304
+ "margin-right": "auto"
305
+ };
306
+ }
286
307
  return { "max-width": width };
287
308
  },
288
309
  { internal: true }
@@ -407,7 +428,12 @@ const filters = [
407
428
  ["backdrop-filter-none", {
408
429
  "-webkit-backdrop-filter": "none",
409
430
  "backdrop-filter": "none"
410
- }]
431
+ }],
432
+ ...globalKeywords.map((keyword) => [`filter-${keyword}`, { filter: keyword }]),
433
+ ...globalKeywords.map((keyword) => [`backdrop-filter-${keyword}`, {
434
+ "-webkit-backdrop-filter": keyword,
435
+ "backdrop-filter": keyword
436
+ }])
411
437
  ];
412
438
 
413
439
  const spaces = [
@@ -440,31 +466,23 @@ const textTransforms = [
440
466
  ["normal-case", { "text-transform": "none" }]
441
467
  ];
442
468
  const hyphens = [
443
- ["hyphens-manual", {
444
- "-webkit-hyphens": "manual",
445
- "-ms-hyphens": "manual",
446
- "hyphens": "manual"
447
- }],
448
- ["hyphens-auto", {
449
- "-webkit-hyphens": "auto",
450
- "-ms-hyphens": "auto",
451
- "hyphens": "auto"
452
- }],
453
- ["hyphens-none", {
454
- "-webkit-hyphens": "none",
455
- "-ms-hyphens": "none",
456
- "hyphens": "none"
457
- }]
469
+ ...["manual", "auto", "none", ...globalKeywords].map((keyword) => [`hyphens-${keyword}`, {
470
+ "-webkit-hyphens": keyword,
471
+ "-ms-hyphens": keyword,
472
+ "hyphens": keyword
473
+ }])
458
474
  ];
459
475
  const writingModes = [
460
476
  ["write-vertical-right", { "writing-mode": "vertical-rl" }],
461
477
  ["write-vertical-left", { "writing-mode": "vertical-lr" }],
462
- ["write-normal", { "writing-mode": "horizontal-tb" }]
478
+ ["write-normal", { "writing-mode": "horizontal-tb" }],
479
+ ...makeGlobalStaticRules("write", "writing-mode")
463
480
  ];
464
481
  const writingOrientations = [
465
482
  ["write-orient-mixed", { "text-orientation": "mixed" }],
466
483
  ["write-orient-sideways", { "text-orientation": "sideways" }],
467
- ["write-orient-upright", { "text-orientation": "upright" }]
484
+ ["write-orient-upright", { "text-orientation": "upright" }],
485
+ ...makeGlobalStaticRules("write-orient", "text-orientation")
468
486
  ];
469
487
  const screenReadersAccess = [
470
488
  [
@@ -529,7 +547,8 @@ const backgroundBlendModes = [
529
547
  ["bg-blend-saturation", { "background-blend-mode": "saturation" }],
530
548
  ["bg-blend-color", { "background-blend-mode": "color" }],
531
549
  ["bg-blend-luminosity", { "background-blend-mode": "luminosity" }],
532
- ["bg-blend-normal", { "background-blend-mode": "normal" }]
550
+ ["bg-blend-normal", { "background-blend-mode": "normal" }],
551
+ ...makeGlobalStaticRules("bg-blend", "background-blend")
533
552
  ];
534
553
  const mixBlendModes = [
535
554
  ["mix-blend-multiply", { "mix-blend-mode": "multiply" }],
@@ -548,7 +567,8 @@ const mixBlendModes = [
548
567
  ["mix-blend-color", { "mix-blend-mode": "color" }],
549
568
  ["mix-blend-luminosity", { "mix-blend-mode": "luminosity" }],
550
569
  ["mix-blend-plus-lighter", { "mix-blend-mode": "plus-lighter" }],
551
- ["mix-blend-normal", { "mix-blend-mode": "normal" }]
570
+ ["mix-blend-normal", { "mix-blend-mode": "normal" }],
571
+ ...makeGlobalStaticRules("mix-blend")
552
572
  ];
553
573
 
554
574
  const borderSpacingBase = {
@@ -709,7 +729,8 @@ const touchActions = [
709
729
  }],
710
730
  ["touch-auto", { "touch-action": "auto" }],
711
731
  ["touch-manipulation", { "touch-action": "manipulation" }],
712
- ["touch-none", { "touch-action": "none" }]
732
+ ["touch-none", { "touch-action": "none" }],
733
+ ...makeGlobalStaticRules("touch", "touch-action")
713
734
  ];
714
735
 
715
736
  const scrollSnapTypeBase = {
@@ -1041,8 +1062,8 @@ const variantCombinators = [
1041
1062
  ];
1042
1063
 
1043
1064
  const variantColorsScheme = [
1044
- variantMatcher(".dark", (input) => ({ prefix: `${input.prefix}.dark $$ ` })),
1045
- variantMatcher(".light", (input) => ({ prefix: `${input.prefix}.light $$ ` })),
1065
+ variantMatcher(".dark", (input) => ({ prefix: `.dark $$ ${input.prefix}` })),
1066
+ variantMatcher(".light", (input) => ({ prefix: `.light $$ ${input.prefix}` })),
1046
1067
  variantParentMatcher("@dark", "@media (prefers-color-scheme: dark)"),
1047
1068
  variantParentMatcher("@light", "@media (prefers-color-scheme: light)")
1048
1069
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unocss/preset-wind",
3
- "version": "0.40.0",
3
+ "version": "0.41.2",
4
4
  "description": "Tailwind / Windi CSS compact preset for UnoCSS",
5
5
  "author": "Anthony Fu <anthonyfu117@hotmail.com>",
6
6
  "license": "MIT",
@@ -35,8 +35,8 @@
35
35
  "*.css"
36
36
  ],
37
37
  "dependencies": {
38
- "@unocss/core": "0.40.0",
39
- "@unocss/preset-mini": "0.40.0"
38
+ "@unocss/core": "0.41.2",
39
+ "@unocss/preset-mini": "0.41.2"
40
40
  },
41
41
  "scripts": {
42
42
  "build": "unbuild",