@unocss/preset-mini 66.5.10 → 66.5.12

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 (44) hide show
  1. package/dist/chunk-gol_9zmq.mjs +36 -0
  2. package/dist/colors-C9l2trjD.d.mts +431 -0
  3. package/dist/colors-Cxq9P2g9.mjs +362 -0
  4. package/dist/colors.d.mts +2 -354
  5. package/dist/colors.mjs +2 -360
  6. package/dist/index-CnsmLem5.d.mts +71 -0
  7. package/dist/index.d.mts +5 -76
  8. package/dist/index.mjs +67 -70
  9. package/dist/rules-CuP-xMI2.mjs +1683 -0
  10. package/dist/rules.d.mts +72 -48
  11. package/dist/rules.mjs +4 -5
  12. package/dist/theme-5nLH7UVx.d.mts +1085 -0
  13. package/dist/theme-DeYMqZAV.mjs +347 -0
  14. package/dist/theme.d.mts +3 -338
  15. package/dist/theme.mjs +5 -6
  16. package/dist/utils-CNv_IKMQ.d.mts +122 -0
  17. package/dist/utils-DLpYZ57Q.mjs +638 -0
  18. package/dist/utils.d.mts +5 -77
  19. package/dist/utils.mjs +5 -3
  20. package/dist/variants.d.mts +38 -24
  21. package/dist/variants.mjs +661 -4
  22. package/package.json +7 -8
  23. package/colors.d.ts +0 -1
  24. package/dist/colors.d.ts +0 -354
  25. package/dist/index.d.ts +0 -76
  26. package/dist/rules.d.ts +0 -130
  27. package/dist/shared/preset-mini.BSnAbT9I.d.mts +0 -748
  28. package/dist/shared/preset-mini.B_2UJsV2.mjs +0 -693
  29. package/dist/shared/preset-mini.BjJC-NnU.d.mts +0 -79
  30. package/dist/shared/preset-mini.BjJC-NnU.d.ts +0 -79
  31. package/dist/shared/preset-mini.CRliz1QB.d.ts +0 -76
  32. package/dist/shared/preset-mini.CVEK1uAa.mjs +0 -355
  33. package/dist/shared/preset-mini.CoOfBKs_.d.ts +0 -748
  34. package/dist/shared/preset-mini.DBTjVFxS.mjs +0 -580
  35. package/dist/shared/preset-mini.QLusboLD.mjs +0 -1064
  36. package/dist/shared/preset-mini.kmtdc_h1.mjs +0 -324
  37. package/dist/shared/preset-mini.oF7XTPi1.d.mts +0 -76
  38. package/dist/theme.d.ts +0 -338
  39. package/dist/utils.d.ts +0 -77
  40. package/dist/variants.d.ts +0 -52
  41. package/rules.d.ts +0 -1
  42. package/theme.d.ts +0 -1
  43. package/utils.d.ts +0 -1
  44. package/variants.d.ts +0 -1
@@ -1,324 +0,0 @@
1
- import { colors } from '../colors.mjs';
2
- import { r as ringBase, b as boxShadowsBase, s as transformBase } from './preset-mini.CVEK1uAa.mjs';
3
-
4
- const blur = {
5
- "DEFAULT": "8px",
6
- "0": "0",
7
- "sm": "4px",
8
- "md": "12px",
9
- "lg": "16px",
10
- "xl": "24px",
11
- "2xl": "40px",
12
- "3xl": "64px"
13
- };
14
- const dropShadow = {
15
- "DEFAULT": ["0 1px 2px rgb(0 0 0 / 0.1)", "0 1px 1px rgb(0 0 0 / 0.06)"],
16
- "sm": "0 1px 1px rgb(0 0 0 / 0.05)",
17
- "md": ["0 4px 3px rgb(0 0 0 / 0.07)", "0 2px 2px rgb(0 0 0 / 0.06)"],
18
- "lg": ["0 10px 8px rgb(0 0 0 / 0.04)", "0 4px 3px rgb(0 0 0 / 0.1)"],
19
- "xl": ["0 20px 13px rgb(0 0 0 / 0.03)", "0 8px 5px rgb(0 0 0 / 0.08)"],
20
- "2xl": "0 25px 25px rgb(0 0 0 / 0.15)",
21
- "none": "0 0 rgb(0 0 0 / 0)"
22
- };
23
-
24
- const fontFamily = {
25
- sans: [
26
- "ui-sans-serif",
27
- "system-ui",
28
- "-apple-system",
29
- "BlinkMacSystemFont",
30
- '"Segoe UI"',
31
- "Roboto",
32
- '"Helvetica Neue"',
33
- "Arial",
34
- '"Noto Sans"',
35
- "sans-serif",
36
- '"Apple Color Emoji"',
37
- '"Segoe UI Emoji"',
38
- '"Segoe UI Symbol"',
39
- '"Noto Color Emoji"'
40
- ].join(","),
41
- serif: [
42
- "ui-serif",
43
- "Georgia",
44
- "Cambria",
45
- '"Times New Roman"',
46
- "Times",
47
- "serif"
48
- ].join(","),
49
- mono: [
50
- "ui-monospace",
51
- "SFMono-Regular",
52
- "Menlo",
53
- "Monaco",
54
- "Consolas",
55
- '"Liberation Mono"',
56
- '"Courier New"',
57
- "monospace"
58
- ].join(",")
59
- };
60
- const fontSize = {
61
- "xs": ["0.75rem", "1rem"],
62
- "sm": ["0.875rem", "1.25rem"],
63
- "base": ["1rem", "1.5rem"],
64
- "lg": ["1.125rem", "1.75rem"],
65
- "xl": ["1.25rem", "1.75rem"],
66
- "2xl": ["1.5rem", "2rem"],
67
- "3xl": ["1.875rem", "2.25rem"],
68
- "4xl": ["2.25rem", "2.5rem"],
69
- "5xl": ["3rem", "1"],
70
- "6xl": ["3.75rem", "1"],
71
- "7xl": ["4.5rem", "1"],
72
- "8xl": ["6rem", "1"],
73
- "9xl": ["8rem", "1"]
74
- };
75
- const textIndent = {
76
- "DEFAULT": "1.5rem",
77
- "xs": "0.5rem",
78
- "sm": "1rem",
79
- "md": "1.5rem",
80
- "lg": "2rem",
81
- "xl": "2.5rem",
82
- "2xl": "3rem",
83
- "3xl": "4rem"
84
- };
85
- const textStrokeWidth = {
86
- DEFAULT: "1.5rem",
87
- none: "0",
88
- sm: "thin",
89
- md: "medium",
90
- lg: "thick"
91
- };
92
- const textShadow = {
93
- DEFAULT: ["0 0 1px rgb(0 0 0 / 0.2)", "0 0 1px rgb(1 0 5 / 0.1)"],
94
- none: "0 0 rgb(0 0 0 / 0)",
95
- sm: "1px 1px 3px rgb(36 37 47 / 0.25)",
96
- md: ["0 1px 2px rgb(30 29 39 / 0.19)", "1px 2px 4px rgb(54 64 147 / 0.18)"],
97
- lg: ["3px 3px 6px rgb(0 0 0 / 0.26)", "0 0 5px rgb(15 3 86 / 0.22)"],
98
- xl: ["1px 1px 3px rgb(0 0 0 / 0.29)", "2px 4px 7px rgb(73 64 125 / 0.35)"]
99
- };
100
- const lineHeight = {
101
- none: "1",
102
- tight: "1.25",
103
- snug: "1.375",
104
- normal: "1.5",
105
- relaxed: "1.625",
106
- loose: "2"
107
- };
108
- const letterSpacing = {
109
- tighter: "-0.05em",
110
- tight: "-0.025em",
111
- normal: "0em",
112
- wide: "0.025em",
113
- wider: "0.05em",
114
- widest: "0.1em"
115
- };
116
- const fontWeight = {
117
- thin: "100",
118
- extralight: "200",
119
- light: "300",
120
- normal: "400",
121
- medium: "500",
122
- semibold: "600",
123
- bold: "700",
124
- extrabold: "800",
125
- black: "900"
126
- // int[0, 900] -> int
127
- };
128
- const wordSpacing = letterSpacing;
129
-
130
- const breakpoints = {
131
- "sm": "640px",
132
- "md": "768px",
133
- "lg": "1024px",
134
- "xl": "1280px",
135
- "2xl": "1536px"
136
- };
137
- const verticalBreakpoints = { ...breakpoints };
138
- const lineWidth = {
139
- DEFAULT: "1px",
140
- none: "0"
141
- };
142
- const spacing = {
143
- "DEFAULT": "1rem",
144
- "none": "0",
145
- "xs": "0.75rem",
146
- "sm": "0.875rem",
147
- "lg": "1.125rem",
148
- "xl": "1.25rem",
149
- "2xl": "1.5rem",
150
- "3xl": "1.875rem",
151
- "4xl": "2.25rem",
152
- "5xl": "3rem",
153
- "6xl": "3.75rem",
154
- "7xl": "4.5rem",
155
- "8xl": "6rem",
156
- "9xl": "8rem"
157
- };
158
- const duration = {
159
- DEFAULT: "150ms",
160
- none: "0s",
161
- 75: "75ms",
162
- 100: "100ms",
163
- 150: "150ms",
164
- 200: "200ms",
165
- 300: "300ms",
166
- 500: "500ms",
167
- 700: "700ms",
168
- 1e3: "1000ms"
169
- };
170
- const borderRadius = {
171
- "DEFAULT": "0.25rem",
172
- "none": "0",
173
- "sm": "0.125rem",
174
- "md": "0.375rem",
175
- "lg": "0.5rem",
176
- "xl": "0.75rem",
177
- "2xl": "1rem",
178
- "3xl": "1.5rem",
179
- "full": "9999px"
180
- };
181
- const boxShadow = {
182
- "DEFAULT": ["var(--un-shadow-inset) 0 1px 3px 0 rgb(0 0 0 / 0.1)", "var(--un-shadow-inset) 0 1px 2px -1px rgb(0 0 0 / 0.1)"],
183
- "none": "0 0 rgb(0 0 0 / 0)",
184
- "sm": "var(--un-shadow-inset) 0 1px 2px 0 rgb(0 0 0 / 0.05)",
185
- "md": ["var(--un-shadow-inset) 0 4px 6px -1px rgb(0 0 0 / 0.1)", "var(--un-shadow-inset) 0 2px 4px -2px rgb(0 0 0 / 0.1)"],
186
- "lg": ["var(--un-shadow-inset) 0 10px 15px -3px rgb(0 0 0 / 0.1)", "var(--un-shadow-inset) 0 4px 6px -4px rgb(0 0 0 / 0.1)"],
187
- "xl": ["var(--un-shadow-inset) 0 20px 25px -5px rgb(0 0 0 / 0.1)", "var(--un-shadow-inset) 0 8px 10px -6px rgb(0 0 0 / 0.1)"],
188
- "2xl": "var(--un-shadow-inset) 0 25px 50px -12px rgb(0 0 0 / 0.25)",
189
- "inner": "inset 0 2px 4px 0 rgb(0 0 0 / 0.05)"
190
- };
191
- const ringWidth = {
192
- DEFAULT: "3px",
193
- none: "0"
194
- };
195
- const zIndex = {
196
- auto: "auto"
197
- };
198
- const media = {
199
- mouse: "(hover) and (pointer: fine)"
200
- };
201
-
202
- const preflightBase = {
203
- ...transformBase,
204
- ...boxShadowsBase,
205
- ...ringBase
206
- };
207
-
208
- const baseSize = {
209
- "xs": "20rem",
210
- "sm": "24rem",
211
- "md": "28rem",
212
- "lg": "32rem",
213
- "xl": "36rem",
214
- "2xl": "42rem",
215
- "3xl": "48rem",
216
- "4xl": "56rem",
217
- "5xl": "64rem",
218
- "6xl": "72rem",
219
- "7xl": "80rem",
220
- "prose": "65ch"
221
- };
222
- const width = {
223
- auto: "auto",
224
- ...baseSize,
225
- screen: "100vw"
226
- };
227
- const maxWidth = {
228
- none: "none",
229
- ...baseSize,
230
- screen: "100vw"
231
- };
232
- const blockSize = {
233
- auto: "auto",
234
- ...baseSize,
235
- screen: "100vb"
236
- };
237
- const inlineSize = {
238
- auto: "auto",
239
- ...baseSize,
240
- screen: "100vi"
241
- };
242
- const height = {
243
- auto: "auto",
244
- ...baseSize,
245
- screen: "100vh"
246
- };
247
- const maxHeight = {
248
- none: "none",
249
- ...baseSize,
250
- screen: "100vh"
251
- };
252
- const maxBlockSize = {
253
- none: "none",
254
- ...baseSize,
255
- screen: "100vb"
256
- };
257
- const maxInlineSize = {
258
- none: "none",
259
- ...baseSize,
260
- screen: "100vi"
261
- };
262
- const containers = { ...baseSize };
263
-
264
- const easing = {
265
- "DEFAULT": "cubic-bezier(0.4, 0, 0.2, 1)",
266
- "linear": "linear",
267
- "in": "cubic-bezier(0.4, 0, 1, 1)",
268
- "out": "cubic-bezier(0, 0, 0.2, 1)",
269
- "in-out": "cubic-bezier(0.4, 0, 0.2, 1)"
270
- };
271
- const transitionProperty = {
272
- none: "none",
273
- all: "all",
274
- colors: ["color", "background-color", "border-color", "text-decoration-color", "fill", "stroke"].join(","),
275
- opacity: "opacity",
276
- shadow: "box-shadow",
277
- transform: "transform",
278
- get DEFAULT() {
279
- return [this.colors, "opacity", "box-shadow", "transform", "filter", "backdrop-filter"].join(",");
280
- }
281
- };
282
-
283
- const theme = {
284
- width,
285
- height,
286
- maxWidth,
287
- maxHeight,
288
- minWidth: maxWidth,
289
- minHeight: maxHeight,
290
- inlineSize,
291
- blockSize,
292
- maxInlineSize,
293
- maxBlockSize,
294
- minInlineSize: maxInlineSize,
295
- minBlockSize: maxBlockSize,
296
- colors,
297
- fontFamily,
298
- fontSize,
299
- fontWeight,
300
- breakpoints,
301
- verticalBreakpoints,
302
- borderRadius,
303
- lineHeight,
304
- letterSpacing,
305
- wordSpacing,
306
- boxShadow,
307
- textIndent,
308
- textShadow,
309
- textStrokeWidth,
310
- blur,
311
- dropShadow,
312
- easing,
313
- transitionProperty,
314
- lineWidth,
315
- spacing,
316
- duration,
317
- ringWidth,
318
- preflightBase,
319
- containers,
320
- zIndex,
321
- media
322
- };
323
-
324
- export { blockSize as A, inlineSize as B, height as C, maxHeight as D, maxBlockSize as E, maxInlineSize as F, containers as G, fontSize as a, blur as b, textIndent as c, dropShadow as d, textStrokeWidth as e, fontFamily as f, textShadow as g, letterSpacing as h, fontWeight as i, breakpoints as j, lineWidth as k, lineHeight as l, duration as m, borderRadius as n, boxShadow as o, media as p, preflightBase as q, ringWidth as r, spacing as s, theme as t, baseSize as u, verticalBreakpoints as v, wordSpacing as w, width as x, maxWidth as y, zIndex as z };
@@ -1,76 +0,0 @@
1
- import { DynamicMatcher, CSSObject, VariantContext, StaticRule } from '@unocss/core';
2
- import { ParsedColorValue } from '@unocss/rule-utils';
3
- import { T as Theme } from './preset-mini.BjJC-NnU.mjs';
4
-
5
- declare const CONTROL_MINI_NO_NEGATIVE = "$$mini-no-negative";
6
- /**
7
- * Provide {@link DynamicMatcher} function returning spacing definition. See spacing rules.
8
- *
9
- * @param propertyPrefix - Property for the css value to be created. Postfix will be appended according to direction matched.
10
- * @see {@link directionMap}
11
- */
12
- declare function directionSize(propertyPrefix: string): DynamicMatcher;
13
- type ThemeColorKeys = 'colors' | 'borderColor' | 'backgroundColor' | 'textColor' | 'shadowColor' | 'accentColor';
14
- /**
15
- * Split utility shorthand delimited by / or :
16
- */
17
- declare function splitShorthand(body: string, type: string): string[] | undefined;
18
- /**
19
- * Parse color string into {@link ParsedColorValue} (if possible). Color value will first be matched to theme object before parsing.
20
- * See also color.tests.ts for more examples.
21
- *
22
- * @example Parseable strings:
23
- * 'red' // From theme, if 'red' is available
24
- * 'red-100' // From theme, plus scale
25
- * 'red-100/20' // From theme, plus scale/opacity
26
- * '[rgb(100 2 3)]/[var(--op)]' // Bracket with rgb color and bracket with opacity
27
- *
28
- * @param body - Color string to be parsed.
29
- * @param theme - {@link Theme} object.
30
- * @return object if string is parseable.
31
- */
32
- declare function parseColor(body: string, theme: Theme, key?: ThemeColorKeys): ParsedColorValue | undefined;
33
- /**
34
- * Provide {@link DynamicMatcher} function to produce color value matched from rule.
35
- *
36
- * @see {@link parseColor}
37
- *
38
- * @example Resolving 'red' from theme:
39
- * colorResolver('background-color', 'background')('', 'red')
40
- * return { 'background-color': '#f12' }
41
- *
42
- * @example Resolving 'red-100' from theme:
43
- * colorResolver('background-color', 'background')('', 'red-100')
44
- * return { '--un-background-opacity': '1', 'background-color': 'rgb(254 226 226 / var(--un-background-opacity))' }
45
- *
46
- * @example Resolving 'red-100/20' from theme:
47
- * colorResolver('background-color', 'background')('', 'red-100/20')
48
- * return { 'background-color': 'rgb(204 251 241 / 0.22)' }
49
- *
50
- * @example Resolving 'hex-124':
51
- * colorResolver('color', 'text')('', 'hex-124')
52
- * return { '--un-text-opacity': '1', 'color': 'rgb(17 34 68 / var(--un-text-opacity))' }
53
- *
54
- * @param property - Property for the css value to be created.
55
- * @param varName - Base name for the opacity variable.
56
- * @param [key] - Theme key to select the color from.
57
- * @param [shouldPass] - Function to decide whether to pass the css.
58
- * @return object.
59
- */
60
- declare function colorResolver(property: string, varName: string, key?: ThemeColorKeys, shouldPass?: (css: CSSObject) => boolean): DynamicMatcher;
61
- declare function colorableShadows(shadows: string | string[], colorVar: string): string[];
62
- declare function hasParseableColor(color: string | undefined, theme: Theme, key: ThemeColorKeys): boolean;
63
- declare function resolveBreakpoints({ theme, generator }: Readonly<VariantContext<Theme>>, key?: 'breakpoints' | 'verticalBreakpoints'): {
64
- point: string;
65
- size: string;
66
- }[] | undefined;
67
- declare function resolveVerticalBreakpoints(context: Readonly<VariantContext<Theme>>): {
68
- point: string;
69
- size: string;
70
- }[] | undefined;
71
- declare function makeGlobalStaticRules(prefix: string, property?: string): StaticRule[];
72
- declare function isCSSMathFn(value: string | undefined): boolean;
73
- declare function isSize(str: string): boolean;
74
- declare function transformXYZ(d: string, v: string, name: string): [string, string][];
75
-
76
- export { CONTROL_MINI_NO_NEGATIVE as C, colorableShadows as a, resolveVerticalBreakpoints as b, colorResolver as c, directionSize as d, isSize as e, hasParseableColor as h, isCSSMathFn as i, makeGlobalStaticRules as m, parseColor as p, resolveBreakpoints as r, splitShorthand as s, transformXYZ as t };