@unocss/preset-mini 0.15.5 → 0.16.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/chunks/default2.cjs +133 -187
- package/dist/chunks/default2.mjs +131 -165
- package/dist/chunks/default3.cjs +8 -6
- package/dist/chunks/default3.mjs +8 -6
- package/dist/chunks/index.cjs +7 -39
- package/dist/chunks/index.mjs +6 -30
- package/dist/rules.cjs +3 -23
- package/dist/rules.d.ts +8 -27
- package/dist/rules.mjs +1 -1
- package/dist/utils.cjs +3 -10
- package/dist/utils.d.ts +4 -12
- package/dist/utils.mjs +2 -1
- package/package.json +2 -2
package/dist/chunks/index.mjs
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { createValueHandler } from '@unocss/core';
|
|
2
|
+
|
|
1
3
|
const directionMap = {
|
|
2
4
|
"l": ["-left"],
|
|
3
5
|
"r": ["-right"],
|
|
@@ -109,7 +111,7 @@ function global(str) {
|
|
|
109
111
|
return str;
|
|
110
112
|
}
|
|
111
113
|
|
|
112
|
-
const
|
|
114
|
+
const valueHandlers = {
|
|
113
115
|
__proto__: null,
|
|
114
116
|
rem: rem,
|
|
115
117
|
px: px,
|
|
@@ -122,37 +124,11 @@ const handlers = {
|
|
|
122
124
|
global: global
|
|
123
125
|
};
|
|
124
126
|
|
|
125
|
-
const
|
|
126
|
-
const
|
|
127
|
-
const s = this.__options?.sequence || [];
|
|
128
|
-
this.__options.sequence = [];
|
|
129
|
-
for (const n of s) {
|
|
130
|
-
const res = handlers[n](str);
|
|
131
|
-
if (res != null)
|
|
132
|
-
return res;
|
|
133
|
-
}
|
|
134
|
-
return void 0;
|
|
135
|
-
};
|
|
136
|
-
function addProcessor(that, name) {
|
|
137
|
-
if (!that.__options) {
|
|
138
|
-
that.__options = {
|
|
139
|
-
sequence: []
|
|
140
|
-
};
|
|
141
|
-
}
|
|
142
|
-
that.__options.sequence.push(name);
|
|
143
|
-
return that;
|
|
144
|
-
}
|
|
145
|
-
handlersNames.forEach((i) => {
|
|
146
|
-
Object.defineProperty(handler, i, {
|
|
147
|
-
enumerable: true,
|
|
148
|
-
get() {
|
|
149
|
-
return addProcessor(this, i);
|
|
150
|
-
}
|
|
151
|
-
});
|
|
152
|
-
});
|
|
127
|
+
const handler = createValueHandler(valueHandlers);
|
|
128
|
+
const h = handler;
|
|
153
129
|
|
|
154
130
|
function capitalize(str) {
|
|
155
131
|
return str.charAt(0).toUpperCase() + str.slice(1);
|
|
156
132
|
}
|
|
157
133
|
|
|
158
|
-
export { capitalize as a,
|
|
134
|
+
export { capitalize as a, h as b, cornerMap as c, directionMap as d, handler as h, valueHandlers as v, xyzMap as x };
|
package/dist/rules.cjs
CHANGED
|
@@ -9,17 +9,12 @@ require('./chunks/pseudo.cjs');
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
exports.
|
|
13
|
-
exports.alignItems = _default.alignItems;
|
|
14
|
-
exports.alignSelfs = _default.alignSelfs;
|
|
12
|
+
exports.alignments = _default.alignments;
|
|
15
13
|
exports.appearance = _default.appearance;
|
|
16
14
|
exports.appearances = _default.appearances;
|
|
17
15
|
exports.aspectRatio = _default.aspectRatio;
|
|
18
16
|
exports.bgColors = _default.bgColors;
|
|
19
17
|
exports.borderColors = _default.borderColors;
|
|
20
|
-
exports.borderRadius = _default.borderRadius;
|
|
21
|
-
exports.borderSizes = _default.borderSizes;
|
|
22
|
-
exports.borderStyles = _default.borderStyles;
|
|
23
18
|
exports.borders = _default.borders;
|
|
24
19
|
exports.boxShadows = _default.boxShadows;
|
|
25
20
|
exports.boxSizing = _default.boxSizing;
|
|
@@ -32,19 +27,13 @@ exports.displays = _default.displays;
|
|
|
32
27
|
exports.fillColors = _default.fillColors;
|
|
33
28
|
exports.flex = _default.flex;
|
|
34
29
|
exports.floats = _default.floats;
|
|
35
|
-
exports.fontSizes = _default.fontSizes;
|
|
36
30
|
exports.fontSmoothings = _default.fontSmoothings;
|
|
37
31
|
exports.fontStyles = _default.fontStyles;
|
|
38
|
-
exports.fontWeights = _default.fontWeights;
|
|
39
32
|
exports.fonts = _default.fonts;
|
|
40
|
-
exports.fontsFamilies = _default.fontsFamilies;
|
|
41
33
|
exports.gaps = _default.gaps;
|
|
42
34
|
exports.grids = _default.grids;
|
|
43
35
|
exports.insets = _default.insets;
|
|
44
36
|
exports.justifies = _default.justifies;
|
|
45
|
-
exports.justifyItems = _default.justifyItems;
|
|
46
|
-
exports.justifySelfs = _default.justifySelfs;
|
|
47
|
-
exports.leadings = _default.leadings;
|
|
48
37
|
exports.margins = _default.margins;
|
|
49
38
|
exports.opacity = _default.opacity;
|
|
50
39
|
exports.orders = _default.orders;
|
|
@@ -52,10 +41,8 @@ exports.outline = _default.outline;
|
|
|
52
41
|
exports.overflows = _default.overflows;
|
|
53
42
|
exports.paddings = _default.paddings;
|
|
54
43
|
exports.parseColorUtil = _default.parseColorUtil;
|
|
55
|
-
exports.placeContents = _default.placeContents;
|
|
56
|
-
exports.placeItems = _default.placeItems;
|
|
57
|
-
exports.placeSelfs = _default.placeSelfs;
|
|
58
44
|
exports.placeholder = _default.placeholder;
|
|
45
|
+
exports.placements = _default.placements;
|
|
59
46
|
exports.pointerEvents = _default.pointerEvents;
|
|
60
47
|
exports.positions = _default.positions;
|
|
61
48
|
exports.questionMark = _default.questionMark;
|
|
@@ -68,23 +55,16 @@ exports.sizes = _default.sizes;
|
|
|
68
55
|
exports.tabSizes = _default.tabSizes;
|
|
69
56
|
exports.textAligns = _default.textAligns;
|
|
70
57
|
exports.textColors = _default.textColors;
|
|
71
|
-
exports.textDecorationColors = _default.textDecorationColors;
|
|
72
|
-
exports.textDecorationLengths = _default.textDecorationLengths;
|
|
73
|
-
exports.textDecorationOffsets = _default.textDecorationOffsets;
|
|
74
|
-
exports.textDecorationStyles = _default.textDecorationStyles;
|
|
75
58
|
exports.textDecorations = _default.textDecorations;
|
|
76
59
|
exports.textIndents = _default.textIndents;
|
|
77
60
|
exports.textOverflows = _default.textOverflows;
|
|
78
61
|
exports.textShadows = _default.textShadows;
|
|
79
|
-
exports.
|
|
80
|
-
exports.textStrokeWidths = _default.textStrokeWidths;
|
|
62
|
+
exports.textStrokes = _default.textStrokes;
|
|
81
63
|
exports.textTransforms = _default.textTransforms;
|
|
82
|
-
exports.trackings = _default.trackings;
|
|
83
64
|
exports.transforms = _default.transforms;
|
|
84
65
|
exports.transitions = _default.transitions;
|
|
85
66
|
exports.userSelects = _default.userSelects;
|
|
86
67
|
exports.varEmpty = _default.varEmpty;
|
|
87
68
|
exports.verticalAligns = _default.verticalAligns;
|
|
88
69
|
exports.whitespaces = _default.whitespaces;
|
|
89
|
-
exports.wordSpacings = _default.wordSpacings;
|
|
90
70
|
exports.zIndexes = _default.zIndexes;
|
package/dist/rules.d.ts
CHANGED
|
@@ -8,10 +8,7 @@ declare const outline: Rule[];
|
|
|
8
8
|
declare const appearance: Rule[];
|
|
9
9
|
declare const placeholder: Rule[];
|
|
10
10
|
|
|
11
|
-
declare const
|
|
12
|
-
declare const borderRadius: Rule[];
|
|
13
|
-
declare const borderStyles: Rule[];
|
|
14
|
-
declare const borders: Rule<{}>[];
|
|
11
|
+
declare const borders: Rule[];
|
|
15
12
|
|
|
16
13
|
declare const parseColorUtil: (body: string, theme: Theme) => {
|
|
17
14
|
opacity: string;
|
|
@@ -31,8 +28,6 @@ declare const opacity: Rule[];
|
|
|
31
28
|
* @example c-red color-red5 text-red-300
|
|
32
29
|
*/
|
|
33
30
|
declare const textColors: Rule[];
|
|
34
|
-
declare const textDecorationColors: Rule[];
|
|
35
|
-
declare const textStrokeColors: Rule[];
|
|
36
31
|
declare const bgColors: Rule[];
|
|
37
32
|
declare const borderColors: Rule[];
|
|
38
33
|
declare const ringColors: Rule[];
|
|
@@ -52,14 +47,8 @@ declare const overflows: Rule[];
|
|
|
52
47
|
declare const positions: Rule[];
|
|
53
48
|
declare const justifies: Rule[];
|
|
54
49
|
declare const orders: Rule[];
|
|
55
|
-
declare const
|
|
56
|
-
declare const
|
|
57
|
-
declare const alignContents: Rule[];
|
|
58
|
-
declare const alignItems: Rule[];
|
|
59
|
-
declare const alignSelfs: Rule[];
|
|
60
|
-
declare const placeContents: Rule[];
|
|
61
|
-
declare const placeItems: Rule[];
|
|
62
|
-
declare const placeSelfs: Rule[];
|
|
50
|
+
declare const alignments: Rule[];
|
|
51
|
+
declare const placements: Rule[];
|
|
63
52
|
declare const insets: Rule[];
|
|
64
53
|
declare const floats: Rule[];
|
|
65
54
|
declare const zIndexes: Rule[];
|
|
@@ -94,8 +83,6 @@ declare const contents: Rule[];
|
|
|
94
83
|
declare const breaks: Rule[];
|
|
95
84
|
declare const textOverflows: Rule[];
|
|
96
85
|
declare const textTransforms: Rule[];
|
|
97
|
-
declare const textDecorations: Rule[];
|
|
98
|
-
declare const textDecorationStyles: Rule[];
|
|
99
86
|
declare const fontStyles: Rule[];
|
|
100
87
|
declare const fontSmoothings: Rule[];
|
|
101
88
|
|
|
@@ -103,20 +90,14 @@ declare const transforms: Rule[];
|
|
|
103
90
|
|
|
104
91
|
declare const transitions: Rule[];
|
|
105
92
|
|
|
106
|
-
declare const
|
|
107
|
-
declare const fontSizes: Rule<Theme>[];
|
|
108
|
-
declare const fontWeights: Rule[];
|
|
109
|
-
declare const leadings: Rule<Theme>[];
|
|
110
|
-
declare const trackings: Rule<Theme>[];
|
|
111
|
-
declare const wordSpacings: Rule<Theme>[];
|
|
93
|
+
declare const fonts: Rule<Theme>[];
|
|
112
94
|
declare const tabSizes: Rule<Theme>[];
|
|
113
|
-
declare const textDecorationLengths: Rule<Theme>[];
|
|
114
|
-
declare const textDecorationOffsets: Rule<Theme>[];
|
|
115
95
|
declare const textIndents: Rule<Theme>[];
|
|
116
|
-
declare const
|
|
96
|
+
declare const textStrokes: Rule<Theme>[];
|
|
117
97
|
declare const textShadows: Rule<Theme>[];
|
|
118
|
-
declare const fonts: Rule<Theme>[];
|
|
119
98
|
|
|
120
99
|
declare const cssVariables: Rule[];
|
|
121
100
|
|
|
122
|
-
|
|
101
|
+
declare const textDecorations: Rule[];
|
|
102
|
+
|
|
103
|
+
export { alignments, appearance, appearances, aspectRatio, bgColors, borderColors, borders, boxShadows, boxSizing, breaks, colorResolver, contents, cssVariables, cursors, displays, fillColors, flex, floats, fontSmoothings, fontStyles, fonts, gaps, grids, insets, justifies, margins, opacity, orders, outline, overflows, paddings, parseColorUtil, placeholder, placements, pointerEvents, positions, questionMark, resizes, ringColors, ringOffsetColors, rings, rules, sizes, tabSizes, textAligns, textColors, textDecorations, textIndents, textOverflows, textShadows, textStrokes, textTransforms, transforms, transitions, userSelects, varEmpty, verticalAligns, whitespaces, zIndexes };
|
package/dist/rules.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { x as alignments, a as appearance, M as appearances, H as aspectRatio, g as bgColors, h as borderColors, b as borders, F as boxShadows, C as boxSizing, T as breaks, d as colorResolver, S as contents, a3 as cssVariables, N as cursors, L as displays, k as fillColors, l as flex, A as floats, X as fontSmoothings, W as fontStyles, _ as fonts, m as gaps, n as grids, z as insets, u as justifies, J as margins, e as opacity, w as orders, o as outline, q as overflows, I as paddings, c as parseColorUtil, p as placeholder, y as placements, O as pointerEvents, s as positions, D as questionMark, P as resizes, i as ringColors, j as ringOffsetColors, E as rings, r as rules, G as sizes, $ as tabSizes, t as textAligns, f as textColors, a4 as textDecorations, a0 as textIndents, U as textOverflows, a2 as textShadows, a1 as textStrokes, V as textTransforms, Y as transforms, Z as transitions, Q as userSelects, K as varEmpty, v as verticalAligns, R as whitespaces, B as zIndexes } from './chunks/default2.mjs';
|
|
2
2
|
import '@unocss/core';
|
|
3
3
|
import './chunks/index.mjs';
|
|
4
4
|
import './chunks/pseudo.mjs';
|
package/dist/utils.cjs
CHANGED
|
@@ -4,22 +4,15 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./chunks/index.cjs');
|
|
6
6
|
const variants = require('./chunks/variants.cjs');
|
|
7
|
+
require('@unocss/core');
|
|
7
8
|
|
|
8
9
|
|
|
9
10
|
|
|
10
|
-
exports.bracket = index.bracket;
|
|
11
11
|
exports.capitalize = index.capitalize;
|
|
12
12
|
exports.cornerMap = index.cornerMap;
|
|
13
|
-
exports.cssvar = index.cssvar;
|
|
14
13
|
exports.directionMap = index.directionMap;
|
|
15
|
-
exports.
|
|
16
|
-
exports.global = index.global;
|
|
14
|
+
exports.h = index.h;
|
|
17
15
|
exports.handler = index.handler;
|
|
18
|
-
exports.
|
|
19
|
-
exports.number = index.number;
|
|
20
|
-
exports.percent = index.percent;
|
|
21
|
-
exports.px = index.px;
|
|
22
|
-
exports.rem = index.rem;
|
|
23
|
-
exports.time = index.time;
|
|
16
|
+
exports.valueHandlers = index.valueHandlers;
|
|
24
17
|
exports.xyzMap = index.xyzMap;
|
|
25
18
|
exports.variantMatcher = variants.variantMatcher;
|
package/dist/utils.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as _unocss_core from '@unocss/core';
|
|
1
2
|
import { VariantHandler } from '@unocss/core';
|
|
2
3
|
|
|
3
4
|
declare const directionMap: Record<string, string[]>;
|
|
@@ -37,20 +38,11 @@ declare namespace handlers {
|
|
|
37
38
|
};
|
|
38
39
|
}
|
|
39
40
|
|
|
40
|
-
declare
|
|
41
|
-
declare const
|
|
42
|
-
declare type Handler = {
|
|
43
|
-
[K in HandlerName]: Handler;
|
|
44
|
-
} & {
|
|
45
|
-
(str: string): string | undefined;
|
|
46
|
-
__options: {
|
|
47
|
-
sequence: HandlerName[];
|
|
48
|
-
};
|
|
49
|
-
};
|
|
50
|
-
declare const handler: Handler;
|
|
41
|
+
declare const handler: _unocss_core.ValueHandler<"number" | "rem" | "px" | "percent" | "fraction" | "bracket" | "cssvar" | "time" | "global">;
|
|
42
|
+
declare const h: _unocss_core.ValueHandler<"number" | "rem" | "px" | "percent" | "fraction" | "bracket" | "cssvar" | "time" | "global">;
|
|
51
43
|
|
|
52
44
|
declare const variantMatcher: (name: string, selector?: ((input: string) => string | undefined) | undefined) => (input: string) => VariantHandler | undefined;
|
|
53
45
|
|
|
54
46
|
declare function capitalize<T extends string>(str: T): Capitalize<T>;
|
|
55
47
|
|
|
56
|
-
export {
|
|
48
|
+
export { capitalize, cornerMap, directionMap, h, handler, handlers as valueHandlers, variantMatcher, xyzMap };
|
package/dist/utils.mjs
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { a as capitalize, c as cornerMap, d as directionMap, b as h, h as handler, v as valueHandlers, x as xyzMap } from './chunks/index.mjs';
|
|
2
2
|
export { v as variantMatcher } from './chunks/variants.mjs';
|
|
3
|
+
import '@unocss/core';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/preset-mini",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.16.2",
|
|
4
4
|
"description": "The minimal preset for UnoCSS",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"unocss",
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"*.css"
|
|
62
62
|
],
|
|
63
63
|
"dependencies": {
|
|
64
|
-
"@unocss/core": "0.
|
|
64
|
+
"@unocss/core": "0.16.2"
|
|
65
65
|
},
|
|
66
66
|
"scripts": {
|
|
67
67
|
"build": "unbuild",
|