@unocss/preset-mini 65.4.0 → 65.4.3

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/colors.mjs CHANGED
@@ -348,7 +348,7 @@ const colors = {
348
348
  }
349
349
  };
350
350
  Object.values(colors).forEach((color) => {
351
- if (typeof color !== "string" && color !== void 0) {
351
+ if (typeof color !== "string" && color !== undefined) {
352
352
  color.DEFAULT = color.DEFAULT || color[400];
353
353
  Object.keys(color).forEach((key) => {
354
354
  const short = +key / 100;
package/dist/index.mjs CHANGED
@@ -1,13 +1,13 @@
1
1
  import { entriesToCss, toArray, definePreset } from '@unocss/core';
2
2
  import { extractorArbitraryVariants } from '@unocss/extractor-arbitrary-variants';
3
- import { g as globalKeywords } from './shared/preset-mini.DcESQHgx.mjs';
4
- export { k as parseColor } from './shared/preset-mini.DcESQHgx.mjs';
5
- import { t as theme } from './shared/preset-mini.CgxyFerm.mjs';
6
- import { r as rules } from './shared/preset-mini.B6HOWqXO.mjs';
7
- import { j as variants } from './shared/preset-mini.b-jcVywT.mjs';
3
+ import { g as globalKeywords } from './shared/preset-mini.CYO0D_sP.mjs';
4
+ export { k as parseColor } from './shared/preset-mini.CYO0D_sP.mjs';
5
+ import { t as theme } from './shared/preset-mini.CAZVP0vr.mjs';
6
+ import { r as rules } from './shared/preset-mini.ClcVt9ko.mjs';
7
+ import { j as variants } from './shared/preset-mini.D61WkPlu.mjs';
8
8
  export { colors } from './colors.mjs';
9
9
  import '@unocss/rule-utils';
10
- import './shared/preset-mini.C5mgDWy5.mjs';
10
+ import './shared/preset-mini.BQPXk9o5.mjs';
11
11
 
12
12
  function preflights(options) {
13
13
  if (options.preflight) {
@@ -61,7 +61,7 @@ const presetMini = definePreset((options = {}) => {
61
61
  prefix: options.prefix,
62
62
  postprocess: VarPrefixPostprocessor(options.variablePrefix),
63
63
  preflights: preflights(options),
64
- extractorDefault: options.arbitraryVariants === false ? void 0 : extractorArbitraryVariants(),
64
+ extractorDefault: options.arbitraryVariants === false ? undefined : extractorArbitraryVariants(),
65
65
  autocomplete: {
66
66
  shorthands
67
67
  }
package/dist/rules.mjs CHANGED
@@ -1,5 +1,5 @@
1
- export { s as alignments, a as appearance, E as aspectRatio, e as bgColors, b as borderStyles, c as borders, B as boxSizing, f as colorScheme, g as containerParent, P as cssProperty, O as cssVariables, j as flex, x as flexGridJustifiesAlignments, z as floats, J as fonts, k as gaps, l as grids, h as handlerBorderStyle, y as insets, n as justifies, G as margins, d as opacity, q as orders, o as outline, m as overflows, F as paddings, u as placements, p as positions, C as questionMark, r as rules, D as sizes, H as svgUtilities, K as tabSizes, t as textAligns, i as textDecorations, L as textIndents, N as textShadows, M as textStrokes, I as transitions, v as verticalAligns, w as willChange, A as zIndexes } from './shared/preset-mini.B6HOWqXO.mjs';
2
- export { e as appearances, c as boxShadows, b as boxShadowsBase, k as breaks, g as contains, i as contentVisibility, j as contents, f as cursors, d as displays, o as fontSmoothings, n as fontStyles, p as pointerEvents, h as resizes, r as ringBase, a as rings, l as textOverflows, m as textTransforms, t as textWraps, q as transformBase, s as transforms, u as userSelects, v as varEmpty, w as whitespaces } from './shared/preset-mini.C5mgDWy5.mjs';
3
- import './shared/preset-mini.DcESQHgx.mjs';
1
+ export { s as alignments, a as appearance, E as aspectRatio, e as bgColors, b as borderStyles, c as borders, B as boxSizing, f as colorScheme, g as containerParent, P as cssProperty, O as cssVariables, j as flex, x as flexGridJustifiesAlignments, z as floats, J as fonts, k as gaps, l as grids, h as handlerBorderStyle, y as insets, n as justifies, G as margins, d as opacity, q as orders, o as outline, m as overflows, F as paddings, u as placements, p as positions, C as questionMark, r as rules, D as sizes, H as svgUtilities, K as tabSizes, t as textAligns, i as textDecorations, L as textIndents, N as textShadows, M as textStrokes, I as transitions, v as verticalAligns, w as willChange, A as zIndexes } from './shared/preset-mini.ClcVt9ko.mjs';
2
+ export { e as appearances, c as boxShadows, b as boxShadowsBase, k as breaks, g as contains, i as contentVisibility, j as contents, f as cursors, d as displays, o as fontSmoothings, n as fontStyles, p as pointerEvents, h as resizes, r as ringBase, a as rings, l as textOverflows, m as textTransforms, t as textWraps, q as transformBase, s as transforms, u as userSelects, v as varEmpty, w as whitespaces } from './shared/preset-mini.BQPXk9o5.mjs';
3
+ import './shared/preset-mini.CYO0D_sP.mjs';
4
4
  import '@unocss/core';
5
5
  import '@unocss/rule-utils';
@@ -1,4 +1,4 @@
1
- import { a as h, q as makeGlobalStaticRules, g as globalKeywords, l as colorResolver, t as isCSSMathFn, n as hasParseableColor, m as colorableShadows, p as positionMap, w as transformXYZ } from './preset-mini.DcESQHgx.mjs';
1
+ import { a as h, q as makeGlobalStaticRules, g as globalKeywords, l as colorResolver, t as isCSSMathFn, n as hasParseableColor, m as colorableShadows, p as positionMap, w as transformXYZ } from './preset-mini.CYO0D_sP.mjs';
2
2
 
3
3
  const cursorValues = ["auto", "default", "none", "context-menu", "help", "pointer", "progress", "wait", "cell", "crosshair", "text", "vertical-text", "alias", "copy", "move", "no-drop", "not-allowed", "grab", "grabbing", "all-scroll", "col-resize", "row-resize", "n-resize", "e-resize", "s-resize", "w-resize", "ne-resize", "nw-resize", "se-resize", "sw-resize", "ew-resize", "ns-resize", "nesw-resize", "nwse-resize", "zoom-in", "zoom-out"];
4
4
  const containValues = ["none", "strict", "content", "size", "inline-size", "layout", "style", "paint"];
@@ -31,7 +31,7 @@ const contains = [
31
31
  contain: h.bracket(d).split(" ").map((e) => h.cssvar.fraction(e) ?? e).join(" ")
32
32
  };
33
33
  }
34
- return containValues.includes(d) ? { contain: d } : void 0;
34
+ return containValues.includes(d) ? { contain: d } : undefined;
35
35
  }]
36
36
  ];
37
37
  const pointerEvents = [
@@ -56,7 +56,7 @@ const userSelects = [
56
56
  const whitespaces = [
57
57
  [
58
58
  /^(?:whitespace-|ws-)([-\w]+)$/,
59
- ([, v]) => ["normal", "nowrap", "pre", "pre-line", "pre-wrap", "break-spaces", ...globalKeywords].includes(v) ? { "white-space": v } : void 0,
59
+ ([, v]) => ["normal", "nowrap", "pre", "pre-line", "pre-wrap", "break-spaces", ...globalKeywords].includes(v) ? { "white-space": v } : undefined,
60
60
  { autocomplete: "(whitespace|ws)-(normal|nowrap|pre|pre-line|pre-wrap|break-spaces)" }
61
61
  ]
62
62
  ];
@@ -177,7 +177,7 @@ const boxShadows = [
177
177
  const [, d] = match;
178
178
  const { theme } = context;
179
179
  const v = theme.boxShadow?.[d || "DEFAULT"];
180
- const c = d ? h.bracket.cssvar(d) : void 0;
180
+ const c = d ? h.bracket.cssvar(d) : undefined;
181
181
  if ((v != null || c != null) && !hasParseableColor(c, theme, "shadowColor")) {
182
182
  return {
183
183
  "--un-shadow": colorableShadows(v || c, "--un-shadow-color").join(","),
@@ -271,7 +271,7 @@ const transforms = [
271
271
  }],
272
272
  // skip 1 & 2 letters shortcut
273
273
  [/^(?:transform-)?perspect(?:ive)?-origin-(.+)$/, ([, s]) => {
274
- const v = h.bracket.cssvar(s) ?? (s.length >= 3 ? positionMap[s] : void 0);
274
+ const v = h.bracket.cssvar(s) ?? (s.length >= 3 ? positionMap[s] : undefined);
275
275
  if (v != null) {
276
276
  return {
277
277
  "-webkit-perspective-origin": v,
@@ -1,5 +1,5 @@
1
1
  import { colors } from '../colors.mjs';
2
- import { q as transformBase, b as boxShadowsBase, r as ringBase } from './preset-mini.C5mgDWy5.mjs';
2
+ import { q as transformBase, b as boxShadowsBase, r as ringBase } from './preset-mini.BQPXk9o5.mjs';
3
3
 
4
4
  const blur = {
5
5
  "DEFAULT": "8px",
@@ -410,7 +410,7 @@ function getThemeColorForKey(theme, colors, key = "colors") {
410
410
  continue;
411
411
  }
412
412
  }
413
- return void 0;
413
+ return undefined;
414
414
  }
415
415
  return obj;
416
416
  }
@@ -549,7 +549,7 @@ const resolvedBreakpoints = /* @__PURE__ */ new WeakMap();
549
549
  function resolveBreakpoints({ theme, generator }, key = "breakpoints") {
550
550
  const breakpoints = generator?.userConfig?.theme?.[key] || theme[key];
551
551
  if (!breakpoints)
552
- return void 0;
552
+ return undefined;
553
553
  if (resolvedBreakpoints.has(theme))
554
554
  return resolvedBreakpoints.get(theme);
555
555
  const resolved = Object.entries(breakpoints).sort((a, b) => Number.parseInt(a[1].replace(reLetters, "")) - Number.parseInt(b[1].replace(reLetters, ""))).map(([point, size]) => ({ point, size }));
@@ -1,6 +1,6 @@
1
- import { g as globalKeywords, a as h, t as isCSSMathFn, l as colorResolver, d as directionMap, n as hasParseableColor, c as cornerMap, k as parseColor, u as isSize, q as makeGlobalStaticRules, i as insetMap, r as resolveBreakpoints, j as directionSize, m as colorableShadows, s as splitShorthand } from './preset-mini.DcESQHgx.mjs';
1
+ import { g as globalKeywords, a as h, t as isCSSMathFn, l as colorResolver, d as directionMap, n as hasParseableColor, c as cornerMap, k as parseColor, u as isSize, q as makeGlobalStaticRules, i as insetMap, r as resolveBreakpoints, j as directionSize, m as colorableShadows, s as splitShorthand } from './preset-mini.CYO0D_sP.mjs';
2
2
  import { colorToString, colorOpacityToString } from '@unocss/rule-utils';
3
- import { g as contains, p as pointerEvents, e as appearances, d as displays, s as transforms, f as cursors, u as userSelects, h as resizes, l as textOverflows, w as whitespaces, k as breaks, t as textWraps, m as textTransforms, n as fontStyles, o as fontSmoothings, c as boxShadows, a as rings, i as contentVisibility, j as contents } from './preset-mini.C5mgDWy5.mjs';
3
+ import { g as contains, p as pointerEvents, e as appearances, d as displays, s as transforms, f as cursors, u as userSelects, h as resizes, l as textOverflows, w as whitespaces, k as breaks, t as textWraps, m as textTransforms, n as fontStyles, o as fontSmoothings, c as boxShadows, a as rings, i as contentVisibility, j as contents } from './preset-mini.BQPXk9o5.mjs';
4
4
  import { toArray } from '@unocss/core';
5
5
 
6
6
  const verticalAlignAlias = {
@@ -379,8 +379,8 @@ const overflowValues = [
379
379
  ...globalKeywords
380
380
  ];
381
381
  const overflows = [
382
- [/^(?:overflow|of)-(.+)$/, ([, v]) => overflowValues.includes(v) ? { overflow: v } : void 0, { autocomplete: [`(overflow|of)-(${overflowValues.join("|")})`, `(overflow|of)-(x|y)-(${overflowValues.join("|")})`] }],
383
- [/^(?:overflow|of)-([xy])-(.+)$/, ([, d, v]) => overflowValues.includes(v) ? { [`overflow-${d}`]: v } : void 0]
382
+ [/^(?:overflow|of)-(.+)$/, ([, v]) => overflowValues.includes(v) ? { overflow: v } : undefined, { autocomplete: [`(overflow|of)-(${overflowValues.join("|")})`, `(overflow|of)-(x|y)-(${overflowValues.join("|")})`] }],
383
+ [/^(?:overflow|of)-([xy])-(.+)$/, ([, d, v]) => overflowValues.includes(v) ? { [`overflow-${d}`]: v } : undefined]
384
384
  ];
385
385
 
386
386
  const positions = [
@@ -391,7 +391,7 @@ const positions = [
391
391
  "<position>"
392
392
  ]
393
393
  }],
394
- [/^(?:position-|pos-)([-\w]+)$/, ([, v]) => globalKeywords.includes(v) ? { position: v } : void 0],
394
+ [/^(?:position-|pos-)([-\w]+)$/, ([, v]) => globalKeywords.includes(v) ? { position: v } : undefined],
395
395
  [/^(?:position-|pos-)?(static)$/, ([, v]) => ({ position: v })]
396
396
  ];
397
397
  const justifies = [
@@ -759,7 +759,7 @@ const fonts = [
759
759
  // colors
760
760
  [/^(?:color|c)-(.+)$/, colorResolver("color", "text", "textColor"), { autocomplete: "(color|c)-$colors" }],
761
761
  // style
762
- [/^(?:text|color|c)-(.+)$/, ([, v]) => globalKeywords.includes(v) ? { color: v } : void 0, { autocomplete: `(text|color|c)-(${globalKeywords.join("|")})` }],
762
+ [/^(?:text|color|c)-(.+)$/, ([, v]) => globalKeywords.includes(v) ? { color: v } : undefined, { autocomplete: `(text|color|c)-(${globalKeywords.join("|")})` }],
763
763
  // opacity
764
764
  [/^(?:text|color|c)-op(?:acity)?-?(.+)$/, ([, opacity]) => ({ "--un-text-opacity": h.bracket.percent.cssvar(opacity) }), { autocomplete: "(text|color|c)-(op|opacity)-<percent>" }],
765
765
  // weights
@@ -876,7 +876,7 @@ function handleText([, s = "base"], { theme }) {
876
876
  return;
877
877
  const [size, leading] = split;
878
878
  const sizePairs = toArray(theme.fontSize?.[size]);
879
- const lineHeight = leading ? handleThemeByKey(leading, theme, "lineHeight") : void 0;
879
+ const lineHeight = leading ? handleThemeByKey(leading, theme, "lineHeight") : undefined;
880
880
  if (sizePairs?.[0]) {
881
881
  const [fontSize2, height, letterSpacing] = sizePairs;
882
882
  if (typeof height === "object") {
@@ -888,7 +888,7 @@ function handleText([, s = "base"], { theme }) {
888
888
  return {
889
889
  "font-size": fontSize2,
890
890
  "line-height": lineHeight ?? height ?? "1",
891
- "letter-spacing": letterSpacing ? handleThemeByKey(letterSpacing, theme, "letterSpacing") : void 0
891
+ "letter-spacing": letterSpacing ? handleThemeByKey(letterSpacing, theme, "letterSpacing") : undefined
892
892
  };
893
893
  }
894
894
  const fontSize = h.bracketOfLength.rem(size);
@@ -1,5 +1,5 @@
1
1
  import { variantGetParameter, variantMatcher, variantGetBracket, variantParentMatcher, getBracket, hasThemeFn, transformThemeFn, getStringComponent } from '@unocss/rule-utils';
2
- import { a as h, r as resolveBreakpoints, C as CONTROL_MINI_NO_NEGATIVE, e as cssMathFnRE, f as cssVarFnRE } from './preset-mini.DcESQHgx.mjs';
2
+ import { a as h, r as resolveBreakpoints, C as CONTROL_MINI_NO_NEGATIVE, e as cssMathFnRE, f as cssVarFnRE } from './preset-mini.CYO0D_sP.mjs';
3
3
  import { escapeRegExp, escapeSelector } from '@unocss/core';
4
4
 
5
5
  const variantAria = {
@@ -680,7 +680,7 @@ function variantPseudoClassesAndElements() {
680
680
  if (index === -1)
681
681
  index = PseudoClassesColonKeys.indexOf(match[1]);
682
682
  if (index === -1)
683
- index = void 0;
683
+ index = undefined;
684
684
  return {
685
685
  matcher: input.slice(match[0].length),
686
686
  handle: (input2, next) => {
package/dist/theme.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  export { colors } from './colors.mjs';
2
- export { u as baseSize, b as blur, n as borderRadius, o as boxShadow, j as breakpoints, C as containers, d as dropShadow, m as duration, f as fontFamily, a as fontSize, i as fontWeight, A as height, h as letterSpacing, l as lineHeight, k as lineWidth, B as maxHeight, y as maxWidth, p as media, q as preflightBase, r as ringWidth, s as spacing, c as textIndent, g as textShadow, e as textStrokeWidth, t as theme, v as verticalBreakpoints, x as width, w as wordSpacing, z as zIndex } from './shared/preset-mini.CgxyFerm.mjs';
3
- import './shared/preset-mini.C5mgDWy5.mjs';
4
- import './shared/preset-mini.DcESQHgx.mjs';
2
+ export { u as baseSize, b as blur, n as borderRadius, o as boxShadow, j as breakpoints, C as containers, d as dropShadow, m as duration, f as fontFamily, a as fontSize, i as fontWeight, A as height, h as letterSpacing, l as lineHeight, k as lineWidth, B as maxHeight, y as maxWidth, p as media, q as preflightBase, r as ringWidth, s as spacing, c as textIndent, g as textShadow, e as textStrokeWidth, t as theme, v as verticalBreakpoints, x as width, w as wordSpacing, z as zIndex } from './shared/preset-mini.CAZVP0vr.mjs';
3
+ import './shared/preset-mini.BQPXk9o5.mjs';
4
+ import './shared/preset-mini.CYO0D_sP.mjs';
5
5
  import '@unocss/core';
6
6
  import '@unocss/rule-utils';
package/dist/utils.mjs CHANGED
@@ -1,3 +1,3 @@
1
- export { C as CONTROL_MINI_NO_NEGATIVE, l as colorResolver, m as colorableShadows, c as cornerMap, e as cssMathFnRE, f as cssVarFnRE, d as directionMap, j as directionSize, g as globalKeywords, a as h, h as handler, n as hasParseableColor, i as insetMap, t as isCSSMathFn, u as isSize, q as makeGlobalStaticRules, k as parseColor, p as positionMap, r as resolveBreakpoints, o as resolveVerticalBreakpoints, s as splitShorthand, w as transformXYZ, v as valueHandlers, b as xyzArray, x as xyzMap } from './shared/preset-mini.DcESQHgx.mjs';
1
+ export { C as CONTROL_MINI_NO_NEGATIVE, l as colorResolver, m as colorableShadows, c as cornerMap, e as cssMathFnRE, f as cssVarFnRE, d as directionMap, j as directionSize, g as globalKeywords, a as h, h as handler, n as hasParseableColor, i as insetMap, t as isCSSMathFn, u as isSize, q as makeGlobalStaticRules, k as parseColor, p as positionMap, r as resolveBreakpoints, o as resolveVerticalBreakpoints, s as splitShorthand, w as transformXYZ, v as valueHandlers, b as xyzArray, x as xyzMap } from './shared/preset-mini.CYO0D_sP.mjs';
2
2
  export * from '@unocss/rule-utils';
3
3
  import '@unocss/core';
package/dist/variants.mjs CHANGED
@@ -1,4 +1,4 @@
1
- export { c as calcMaxWidthBySize, v as variantAria, b as variantBreakpoints, d as variantChildren, g as variantColorsMediaOrClass, e as variantCombinators, f as variantContainerQuery, p as variantCssLayer, n as variantCustomMedia, h as variantDataAttribute, l as variantImportant, q as variantInternalLayer, k as variantLanguageDirections, u as variantNegative, z as variantPartClasses, m as variantPrint, x as variantPseudoClassFunctions, w as variantPseudoClassesAndElements, r as variantScope, o as variantSelector, A as variantStartingStyle, B as variantSupports, a as variantTaggedAriaAttributes, i as variantTaggedDataAttributes, y as variantTaggedPseudoClasses, t as variantTheme, s as variantVariables, j as variants } from './shared/preset-mini.b-jcVywT.mjs';
1
+ export { c as calcMaxWidthBySize, v as variantAria, b as variantBreakpoints, d as variantChildren, g as variantColorsMediaOrClass, e as variantCombinators, f as variantContainerQuery, p as variantCssLayer, n as variantCustomMedia, h as variantDataAttribute, l as variantImportant, q as variantInternalLayer, k as variantLanguageDirections, u as variantNegative, z as variantPartClasses, m as variantPrint, x as variantPseudoClassFunctions, w as variantPseudoClassesAndElements, r as variantScope, o as variantSelector, A as variantStartingStyle, B as variantSupports, a as variantTaggedAriaAttributes, i as variantTaggedDataAttributes, y as variantTaggedPseudoClasses, t as variantTheme, s as variantVariables, j as variants } from './shared/preset-mini.D61WkPlu.mjs';
2
2
  import '@unocss/rule-utils';
3
- import './shared/preset-mini.DcESQHgx.mjs';
3
+ import './shared/preset-mini.CYO0D_sP.mjs';
4
4
  import '@unocss/core';
package/package.json CHANGED
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "name": "@unocss/preset-mini",
3
3
  "type": "module",
4
- "version": "65.4.0",
4
+ "version": "65.4.3",
5
5
  "description": "The minimal preset for UnoCSS",
6
6
  "author": "Anthony Fu <anthonyfu117@hotmail.com>",
7
7
  "license": "MIT",
8
8
  "funding": "https://github.com/sponsors/antfu",
9
- "homepage": "https://github.com/unocss/unocss/tree/main/packages/preset-mini#readme",
9
+ "homepage": "https://unocss.dev",
10
10
  "repository": {
11
11
  "type": "git",
12
12
  "url": "https://github.com/unocss/unocss",
13
- "directory": "packages/preset-mini"
13
+ "directory": "packages-presets/preset-mini"
14
14
  },
15
15
  "bugs": {
16
16
  "url": "https://github.com/unocss/unocss/issues"
@@ -56,9 +56,9 @@
56
56
  "dist"
57
57
  ],
58
58
  "dependencies": {
59
- "@unocss/extractor-arbitrary-variants": "65.4.0",
60
- "@unocss/rule-utils": "65.4.0",
61
- "@unocss/core": "65.4.0"
59
+ "@unocss/core": "65.4.3",
60
+ "@unocss/extractor-arbitrary-variants": "65.4.3",
61
+ "@unocss/rule-utils": "65.4.3"
62
62
  },
63
63
  "scripts": {
64
64
  "build": "unbuild",