@unocss/preset-wind 0.36.0 → 0.37.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.
package/dist/index.cjs CHANGED
@@ -627,16 +627,12 @@ const fontVariantNumericBase = {
627
627
  "--un-numeric-figure": rules$1.varEmpty,
628
628
  "--un-numeric-spacing": rules$1.varEmpty,
629
629
  "--un-numeric-fraction": rules$1.varEmpty,
630
- "--un-font-variant-numeric": "var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)",
631
- [core.CONTROL_SHORTCUT_NO_MERGE]: ""
630
+ "--un-font-variant-numeric": "var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)"
632
631
  };
633
- const toEntries = (entry) => [
634
- fontVariantNumericBase,
635
- {
636
- ...entry,
637
- "font-variant-numeric": "var(--un-font-variant-numeric)"
638
- }
639
- ];
632
+ const toEntries = (entry) => ({
633
+ ...entry,
634
+ "font-variant-numeric": "var(--un-font-variant-numeric)"
635
+ });
640
636
  const fontVariantNumeric = [
641
637
  [/^ordinal$/, () => toEntries({ "--un-ordinal": "ordinal" }), { autocomplete: "ordinal" }],
642
638
  [/^slashed-zero$/, () => toEntries({ "--un-slashed-zero": "slashed-zero" }), { autocomplete: "slashed-zero" }],
@@ -653,46 +649,36 @@ const touchActionBase = {
653
649
  "--un-pan-x": rules$1.varEmpty,
654
650
  "--un-pan-y": rules$1.varEmpty,
655
651
  "--un-pinch-zoom": rules$1.varEmpty,
656
- "--un-touch-action": "var(--un-pan-x) var(--un-pan-y) var(--un-pinch-zoom)",
657
- [core.CONTROL_SHORTCUT_NO_MERGE]: ""
652
+ "--un-touch-action": "var(--un-pan-x) var(--un-pan-y) var(--un-pinch-zoom)"
658
653
  };
659
654
  const touchActions = [
660
- [/^touch-pan-(x|left|right)$/, ([, d]) => [
661
- touchActionBase,
662
- {
663
- "--un-pan-x": `pan-${d}`,
664
- "touch-action": "var(--un-touch-action)"
665
- }
666
- ], { autocomplete: ["touch-pan", "touch-pan-(x|left|right|y|up|down)"] }],
667
- [/^touch-pan-(y|up|down)$/, ([, d]) => [
668
- touchActionBase,
669
- {
670
- "--un-pan-y": `pan-${d}`,
671
- "touch-action": "var(--un-touch-action)"
672
- }
673
- ]],
674
- [/^touch-pinch-zoom$/, () => [
675
- touchActionBase,
676
- {
677
- "--un-pinch-zoom": "pinch-zoom",
678
- "touch-action": "var(--un-touch-action)"
679
- }
680
- ], { autocomplete: ["touch-pinch", "touch-pinch-zoom"] }],
655
+ [/^touch-pan-(x|left|right)$/, ([, d]) => ({
656
+ "--un-pan-x": `pan-${d}`,
657
+ "touch-action": "var(--un-touch-action)"
658
+ }), { autocomplete: ["touch-pan", "touch-pan-(x|left|right|y|up|down)"] }],
659
+ [/^touch-pan-(y|up|down)$/, ([, d]) => ({
660
+ "--un-pan-y": `pan-${d}`,
661
+ "touch-action": "var(--un-touch-action)"
662
+ })],
663
+ ["touch-pinch-zoom", {
664
+ "--un-pinch-zoom": "pinch-zoom",
665
+ "touch-action": "var(--un-touch-action)"
666
+ }],
681
667
  ["touch-auto", { "touch-action": "auto" }],
682
668
  ["touch-manipulation", { "touch-action": "manipulation" }],
683
669
  ["touch-none", { "touch-action": "none" }]
684
670
  ];
685
671
 
672
+ const scrollSnapTypeBase = {
673
+ "--un-scroll-snap-strictness": "proximity"
674
+ };
686
675
  const scrolls = [
687
- [/^snap-(x|y|both)$/, ([, d]) => [
688
- {
689
- "--un-scroll-snap-strictness": "proximity",
690
- [core.CONTROL_SHORTCUT_NO_MERGE]: ""
691
- },
692
- {
693
- "scroll-snap-type": `${d} var(--un-scroll-snap-strictness)`
694
- }
695
- ], { autocomplete: "snap-(x|y|both)" }],
676
+ [/^snap-(x|y)$/, ([, d]) => ({
677
+ "scroll-snap-type": `${d} var(--un-scroll-snap-strictness)`
678
+ }), { autocomplete: "snap-(x|y|both)" }],
679
+ [/^snap-both$/, () => ({
680
+ "scroll-snap-type": "both var(--un-scroll-snap-strictness)"
681
+ })],
696
682
  ["snap-mandatory", { "--un-scroll-snap-strictness": "mandatory" }],
697
683
  ["snap-proximity", { "--un-scroll-snap-strictness": "proximity" }],
698
684
  ["snap-none", { "scroll-snap-type": "none" }],
@@ -988,6 +974,11 @@ const theme = {
988
974
  },
989
975
  preflightBase: {
990
976
  ...rules$1.transformBase,
977
+ ...touchActionBase,
978
+ ...scrollSnapTypeBase,
979
+ ...fontVariantNumericBase,
980
+ ...rules$1.boxShadowsBase,
981
+ ...rules$1.ringBase,
991
982
  ...filterBase,
992
983
  ...backdropFilterBase
993
984
  }
package/dist/index.mjs CHANGED
@@ -1,8 +1,8 @@
1
1
  import { preflights } from '@unocss/preset-mini';
2
2
  export { colors, preflights } from '@unocss/preset-mini';
3
- import { toArray, CONTROL_SHORTCUT_NO_MERGE } from '@unocss/core';
3
+ import { toArray } from '@unocss/core';
4
4
  import { handler, positionMap, parseColor, colorToString, colorResolver, resolveBreakpoints, colorableShadows, directionMap, directionSize, variantMatcher, variantParentMatcher, hasParseableColor } from '@unocss/preset-mini/utils';
5
- 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 } from '@unocss/preset-mini/rules';
5
+ 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
6
  import { theme as theme$1 } from '@unocss/preset-mini/theme';
7
7
  import { variants as variants$1 } from '@unocss/preset-mini/variants';
8
8
 
@@ -624,16 +624,12 @@ const fontVariantNumericBase = {
624
624
  "--un-numeric-figure": varEmpty,
625
625
  "--un-numeric-spacing": varEmpty,
626
626
  "--un-numeric-fraction": varEmpty,
627
- "--un-font-variant-numeric": "var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)",
628
- [CONTROL_SHORTCUT_NO_MERGE]: ""
627
+ "--un-font-variant-numeric": "var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)"
629
628
  };
630
- const toEntries = (entry) => [
631
- fontVariantNumericBase,
632
- {
633
- ...entry,
634
- "font-variant-numeric": "var(--un-font-variant-numeric)"
635
- }
636
- ];
629
+ const toEntries = (entry) => ({
630
+ ...entry,
631
+ "font-variant-numeric": "var(--un-font-variant-numeric)"
632
+ });
637
633
  const fontVariantNumeric = [
638
634
  [/^ordinal$/, () => toEntries({ "--un-ordinal": "ordinal" }), { autocomplete: "ordinal" }],
639
635
  [/^slashed-zero$/, () => toEntries({ "--un-slashed-zero": "slashed-zero" }), { autocomplete: "slashed-zero" }],
@@ -650,46 +646,36 @@ const touchActionBase = {
650
646
  "--un-pan-x": varEmpty,
651
647
  "--un-pan-y": varEmpty,
652
648
  "--un-pinch-zoom": varEmpty,
653
- "--un-touch-action": "var(--un-pan-x) var(--un-pan-y) var(--un-pinch-zoom)",
654
- [CONTROL_SHORTCUT_NO_MERGE]: ""
649
+ "--un-touch-action": "var(--un-pan-x) var(--un-pan-y) var(--un-pinch-zoom)"
655
650
  };
656
651
  const touchActions = [
657
- [/^touch-pan-(x|left|right)$/, ([, d]) => [
658
- touchActionBase,
659
- {
660
- "--un-pan-x": `pan-${d}`,
661
- "touch-action": "var(--un-touch-action)"
662
- }
663
- ], { autocomplete: ["touch-pan", "touch-pan-(x|left|right|y|up|down)"] }],
664
- [/^touch-pan-(y|up|down)$/, ([, d]) => [
665
- touchActionBase,
666
- {
667
- "--un-pan-y": `pan-${d}`,
668
- "touch-action": "var(--un-touch-action)"
669
- }
670
- ]],
671
- [/^touch-pinch-zoom$/, () => [
672
- touchActionBase,
673
- {
674
- "--un-pinch-zoom": "pinch-zoom",
675
- "touch-action": "var(--un-touch-action)"
676
- }
677
- ], { autocomplete: ["touch-pinch", "touch-pinch-zoom"] }],
652
+ [/^touch-pan-(x|left|right)$/, ([, d]) => ({
653
+ "--un-pan-x": `pan-${d}`,
654
+ "touch-action": "var(--un-touch-action)"
655
+ }), { autocomplete: ["touch-pan", "touch-pan-(x|left|right|y|up|down)"] }],
656
+ [/^touch-pan-(y|up|down)$/, ([, d]) => ({
657
+ "--un-pan-y": `pan-${d}`,
658
+ "touch-action": "var(--un-touch-action)"
659
+ })],
660
+ ["touch-pinch-zoom", {
661
+ "--un-pinch-zoom": "pinch-zoom",
662
+ "touch-action": "var(--un-touch-action)"
663
+ }],
678
664
  ["touch-auto", { "touch-action": "auto" }],
679
665
  ["touch-manipulation", { "touch-action": "manipulation" }],
680
666
  ["touch-none", { "touch-action": "none" }]
681
667
  ];
682
668
 
669
+ const scrollSnapTypeBase = {
670
+ "--un-scroll-snap-strictness": "proximity"
671
+ };
683
672
  const scrolls = [
684
- [/^snap-(x|y|both)$/, ([, d]) => [
685
- {
686
- "--un-scroll-snap-strictness": "proximity",
687
- [CONTROL_SHORTCUT_NO_MERGE]: ""
688
- },
689
- {
690
- "scroll-snap-type": `${d} var(--un-scroll-snap-strictness)`
691
- }
692
- ], { autocomplete: "snap-(x|y|both)" }],
673
+ [/^snap-(x|y)$/, ([, d]) => ({
674
+ "scroll-snap-type": `${d} var(--un-scroll-snap-strictness)`
675
+ }), { autocomplete: "snap-(x|y|both)" }],
676
+ [/^snap-both$/, () => ({
677
+ "scroll-snap-type": "both var(--un-scroll-snap-strictness)"
678
+ })],
693
679
  ["snap-mandatory", { "--un-scroll-snap-strictness": "mandatory" }],
694
680
  ["snap-proximity", { "--un-scroll-snap-strictness": "proximity" }],
695
681
  ["snap-none", { "scroll-snap-type": "none" }],
@@ -985,6 +971,11 @@ const theme = {
985
971
  },
986
972
  preflightBase: {
987
973
  ...transformBase,
974
+ ...touchActionBase,
975
+ ...scrollSnapTypeBase,
976
+ ...fontVariantNumericBase,
977
+ ...boxShadowsBase,
978
+ ...ringBase,
988
979
  ...filterBase,
989
980
  ...backdropFilterBase
990
981
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unocss/preset-wind",
3
- "version": "0.36.0",
3
+ "version": "0.37.0",
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.36.0",
39
- "@unocss/preset-mini": "0.36.0"
38
+ "@unocss/core": "0.37.0",
39
+ "@unocss/preset-mini": "0.37.0"
40
40
  },
41
41
  "scripts": {
42
42
  "build": "unbuild",