weapp-tailwindcss 5.0.0-next.23 → 5.0.0-next.25
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/auto-AduSz49t.mjs +80 -0
- package/dist/auto-B11j1XiD.js +117 -0
- package/dist/{bundle-state-BxWD-X7F.js → bundle-state-BY7PWHAc.js} +1 -1
- package/dist/{bundle-state-CCjtHdeS.mjs → bundle-state-CBouNDzi.mjs} +1 -1
- package/dist/cli.js +167 -5
- package/dist/cli.mjs +166 -4
- package/dist/context/runtime-package-replacements.d.ts +2 -0
- package/dist/context/style-options.d.ts +3 -0
- package/dist/core.js +1 -1
- package/dist/core.mjs +1 -1
- package/dist/css-macro/auto.d.ts +10 -0
- package/dist/css-macro/constants.d.ts +5 -2
- package/dist/css-macro/postcss.d.ts +1 -0
- package/dist/css-macro/postcss.js +7 -47
- package/dist/css-macro/postcss.mjs +2 -47
- package/dist/css-macro.js +15 -6
- package/dist/css-macro.mjs +15 -6
- package/dist/{defaults-C6sIKXgC.mjs → defaults-B-1EEhdL.mjs} +2 -1
- package/dist/{defaults-D3cFX6Cq.js → defaults-C10hYUch.js} +2 -1
- package/dist/defaults.js +1 -1
- package/dist/defaults.mjs +1 -1
- package/dist/{generator-BP_VdS_x.mjs → generator-CtqzN9L-.mjs} +1 -1
- package/dist/{generator-D6gEmxIp.js → generator-DTPePQZ9.js} +1 -1
- package/dist/generator.js +2 -2
- package/dist/generator.mjs +2 -2
- package/dist/gulp.js +5 -5
- package/dist/gulp.mjs +5 -5
- package/dist/{incremental-runtime-class-set-DEf-VOwB.mjs → incremental-runtime-class-set-BlJ86j-A.mjs} +4 -16
- package/dist/{incremental-runtime-class-set-CdcqejGM.js → incremental-runtime-class-set-CERcE0fP.js} +4 -16
- package/dist/index.d.ts +1 -0
- package/dist/index.js +18 -4
- package/dist/index.mjs +6 -5
- package/dist/{postcss-D8kdiqHg.js → postcss-BAO9tGi5.js} +2 -2
- package/dist/{postcss-KBUSjpTr.mjs → postcss-CYPHxj7a.mjs} +2 -2
- package/dist/postcss-DXkxsPNg.js +192 -0
- package/dist/postcss-DYktK8_T.mjs +169 -0
- package/dist/postcss.js +1 -1
- package/dist/postcss.mjs +1 -1
- package/dist/{precheck-DT3ydSET.mjs → precheck-B4CpMt_w.mjs} +69 -32
- package/dist/{precheck-DrBpp5HA.js → precheck-ezN3ovAq.js} +75 -32
- package/dist/presets/uni-app-x.d.ts +1 -0
- package/dist/presets.js +5 -4
- package/dist/presets.mjs +5 -4
- package/dist/{source-candidates-CHJBRaDA.js → source-candidates-0jPRIPmC.js} +1 -1
- package/dist/{source-candidates-CvmmNj4x.mjs → source-candidates-DoyOltpZ.mjs} +1 -1
- package/dist/{tailwindcss-CxAd28dW.js → tailwindcss-nQetCaPp.js} +17 -26
- package/dist/{tailwindcss-eov9DmH3.mjs → tailwindcss-ujlr9Iad.mjs} +17 -26
- package/dist/types/index.d.ts +1 -1
- package/dist/types/shared.d.ts +3 -0
- package/dist/types/user-defined-options/general.d.ts +2 -1
- package/dist/types/user-defined-options/important.d.ts +3 -1
- package/dist/unocss/index.d.ts +2 -0
- package/dist/utils/options.d.ts +2 -0
- package/dist/utils/regex.d.ts +1 -0
- package/dist/{v3-engine-CxCp7Ydh.js → v3-engine-Bbsrez2w.js} +72 -21
- package/dist/{v3-engine-CzD7OvXg.mjs → v3-engine-COw08vWd.mjs} +61 -22
- package/dist/{vite-xq8oINaq.js → vite-DE8Vfzal.js} +40 -10
- package/dist/{vite-DyQrAtpx.mjs → vite-hZsQAY1a.mjs} +40 -10
- package/dist/vite.js +1 -1
- package/dist/vite.mjs +1 -1
- package/dist/weapp-tw-css-import-rewrite-loader.js +334 -74
- package/dist/weapp-tw-runtime-classset-loader.js +1 -4
- package/dist/{webpack-bTvAcuj4.js → webpack-CTJcw_sX.js} +6 -6
- package/dist/{webpack-CZIJ7caJ.mjs → webpack-c2WJnCJI.mjs} +6 -6
- package/dist/webpack.js +1 -1
- package/dist/webpack.mjs +1 -1
- package/package.json +9 -11
- package/dist/constants-BG12WAKw.mjs +0 -44
- package/dist/constants-BeeyfJ9k.js +0 -73
- /package/dist/{logger-EVNB9z7i.js → logger-Cdzl3p8j.js} +0 -0
- /package/dist/{logger-CZUxvJJD.mjs → logger-Dr7IvyH2.mjs} +0 -0
- /package/dist/{utils-CGBVVNm6.mjs → utils-B2SJgA1L.mjs} +0 -0
- /package/dist/{utils-4ODFyoqD.js → utils-CSA174-I.js} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "weapp-tailwindcss",
|
|
3
|
-
"version": "5.0.0-next.
|
|
3
|
+
"version": "5.0.0-next.25",
|
|
4
4
|
"description": "把 tailwindcss 原子化样式思想,带给小程序开发者们! bring tailwindcss to miniprogram developers!",
|
|
5
5
|
"author": "ice breaker <1324318532@qq.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -172,17 +172,15 @@
|
|
|
172
172
|
"@babel/parser": "~7.29.7",
|
|
173
173
|
"@babel/traverse": "~7.29.7",
|
|
174
174
|
"@babel/types": "~7.29.7",
|
|
175
|
-
"@vue/compiler-dom": "^3.5.
|
|
176
|
-
"@vue/compiler-sfc": "^3.5.
|
|
177
|
-
"@weapp-core/escape": "~
|
|
178
|
-
"
|
|
179
|
-
"comment-json": "^4.6.2",
|
|
175
|
+
"@vue/compiler-dom": "^3.5.35",
|
|
176
|
+
"@vue/compiler-sfc": "^3.5.35",
|
|
177
|
+
"@weapp-core/escape": "~8.0.0",
|
|
178
|
+
"comment-json": "^5.0.0",
|
|
180
179
|
"debug": "~4.4.3",
|
|
181
180
|
"fast-glob": "^3.3.3",
|
|
182
|
-
"htmlparser2": "
|
|
183
|
-
"loader-utils": "2.0.4",
|
|
181
|
+
"htmlparser2": "12.0.0",
|
|
184
182
|
"local-pkg": "^1.2.1",
|
|
185
|
-
"lru-cache": "
|
|
183
|
+
"lru-cache": "11.5.0",
|
|
186
184
|
"magic-string": "0.30.21",
|
|
187
185
|
"micromatch": "^4.0.8",
|
|
188
186
|
"postcss-load-config": "^6.0.1",
|
|
@@ -190,8 +188,8 @@
|
|
|
190
188
|
"tailwindcss-patch": "9.3.7",
|
|
191
189
|
"yaml": "^2.9.0",
|
|
192
190
|
"@weapp-tailwindcss/logger": "1.1.0",
|
|
193
|
-
"@weapp-tailwindcss/postcss": "3.0.0-next.
|
|
194
|
-
"@weapp-tailwindcss/reset": "0.1.1-next.
|
|
191
|
+
"@weapp-tailwindcss/postcss": "3.0.0-next.7",
|
|
192
|
+
"@weapp-tailwindcss/reset": "0.1.1-next.1",
|
|
195
193
|
"@weapp-tailwindcss/shared": "1.1.3",
|
|
196
194
|
"tailwindcss-config": "1.1.6-next.1"
|
|
197
195
|
},
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
//#region src/css-macro/constants.ts
|
|
2
|
-
const queryKey = "weapp-tw-platform";
|
|
3
|
-
function createMediaQuery(value) {
|
|
4
|
-
return `@media (${queryKey}:"${value}"){&}`;
|
|
5
|
-
}
|
|
6
|
-
function createNegativeMediaQuery(value) {
|
|
7
|
-
return `@media not screen and (${queryKey}:"${value}"){&}`;
|
|
8
|
-
}
|
|
9
|
-
const UNESCAPED_UNDERSCORE_RE = /(?<!\\)_/g;
|
|
10
|
-
const WHITESPACE_RE = /\s+/g;
|
|
11
|
-
const LOGICAL_OPERATOR_RE = /\s*(\|\||&&)\s*/g;
|
|
12
|
-
function normalComment(text) {
|
|
13
|
-
if (typeof text === "string") {
|
|
14
|
-
const normalized = text.replaceAll(UNESCAPED_UNDERSCORE_RE, " ").replaceAll(WHITESPACE_RE, " ").trim();
|
|
15
|
-
if (normalized.includes("\\")) return normalized;
|
|
16
|
-
return normalized.replaceAll(LOGICAL_OPERATOR_RE, " $1 ").replaceAll(WHITESPACE_RE, " ").trim();
|
|
17
|
-
}
|
|
18
|
-
return text;
|
|
19
|
-
}
|
|
20
|
-
function ifdef(text) {
|
|
21
|
-
return {
|
|
22
|
-
start: `#ifdef ${normalComment(text)}`,
|
|
23
|
-
end: `#endif`
|
|
24
|
-
};
|
|
25
|
-
}
|
|
26
|
-
function ifndef(text) {
|
|
27
|
-
return {
|
|
28
|
-
start: `#ifndef ${normalComment(text)}`,
|
|
29
|
-
end: `#endif`
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
const QUERY_KEY_REGEX = new RegExp(`\\(\\s*${queryKey}\\s*:\\s*"([^)]*)"\\)`, "g");
|
|
33
|
-
function matchCustomPropertyFromValue(str, cb) {
|
|
34
|
-
let index = 0;
|
|
35
|
-
QUERY_KEY_REGEX.lastIndex = 0;
|
|
36
|
-
let arr = QUERY_KEY_REGEX.exec(str);
|
|
37
|
-
while (arr !== null) {
|
|
38
|
-
cb(arr, index);
|
|
39
|
-
index++;
|
|
40
|
-
arr = QUERY_KEY_REGEX.exec(str);
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
//#endregion
|
|
44
|
-
export { matchCustomPropertyFromValue as a, ifndef as i, createNegativeMediaQuery as n, ifdef as r, createMediaQuery as t };
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
//#region src/css-macro/constants.ts
|
|
2
|
-
const queryKey = "weapp-tw-platform";
|
|
3
|
-
function createMediaQuery(value) {
|
|
4
|
-
return `@media (${queryKey}:"${value}"){&}`;
|
|
5
|
-
}
|
|
6
|
-
function createNegativeMediaQuery(value) {
|
|
7
|
-
return `@media not screen and (${queryKey}:"${value}"){&}`;
|
|
8
|
-
}
|
|
9
|
-
const UNESCAPED_UNDERSCORE_RE = /(?<!\\)_/g;
|
|
10
|
-
const WHITESPACE_RE = /\s+/g;
|
|
11
|
-
const LOGICAL_OPERATOR_RE = /\s*(\|\||&&)\s*/g;
|
|
12
|
-
function normalComment(text) {
|
|
13
|
-
if (typeof text === "string") {
|
|
14
|
-
const normalized = text.replaceAll(UNESCAPED_UNDERSCORE_RE, " ").replaceAll(WHITESPACE_RE, " ").trim();
|
|
15
|
-
if (normalized.includes("\\")) return normalized;
|
|
16
|
-
return normalized.replaceAll(LOGICAL_OPERATOR_RE, " $1 ").replaceAll(WHITESPACE_RE, " ").trim();
|
|
17
|
-
}
|
|
18
|
-
return text;
|
|
19
|
-
}
|
|
20
|
-
function ifdef(text) {
|
|
21
|
-
return {
|
|
22
|
-
start: `#ifdef ${normalComment(text)}`,
|
|
23
|
-
end: `#endif`
|
|
24
|
-
};
|
|
25
|
-
}
|
|
26
|
-
function ifndef(text) {
|
|
27
|
-
return {
|
|
28
|
-
start: `#ifndef ${normalComment(text)}`,
|
|
29
|
-
end: `#endif`
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
const QUERY_KEY_REGEX = new RegExp(`\\(\\s*${queryKey}\\s*:\\s*"([^)]*)"\\)`, "g");
|
|
33
|
-
function matchCustomPropertyFromValue(str, cb) {
|
|
34
|
-
let index = 0;
|
|
35
|
-
QUERY_KEY_REGEX.lastIndex = 0;
|
|
36
|
-
let arr = QUERY_KEY_REGEX.exec(str);
|
|
37
|
-
while (arr !== null) {
|
|
38
|
-
cb(arr, index);
|
|
39
|
-
index++;
|
|
40
|
-
arr = QUERY_KEY_REGEX.exec(str);
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
//#endregion
|
|
44
|
-
Object.defineProperty(exports, "createMediaQuery", {
|
|
45
|
-
enumerable: true,
|
|
46
|
-
get: function() {
|
|
47
|
-
return createMediaQuery;
|
|
48
|
-
}
|
|
49
|
-
});
|
|
50
|
-
Object.defineProperty(exports, "createNegativeMediaQuery", {
|
|
51
|
-
enumerable: true,
|
|
52
|
-
get: function() {
|
|
53
|
-
return createNegativeMediaQuery;
|
|
54
|
-
}
|
|
55
|
-
});
|
|
56
|
-
Object.defineProperty(exports, "ifdef", {
|
|
57
|
-
enumerable: true,
|
|
58
|
-
get: function() {
|
|
59
|
-
return ifdef;
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
Object.defineProperty(exports, "ifndef", {
|
|
63
|
-
enumerable: true,
|
|
64
|
-
get: function() {
|
|
65
|
-
return ifndef;
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
Object.defineProperty(exports, "matchCustomPropertyFromValue", {
|
|
69
|
-
enumerable: true,
|
|
70
|
-
get: function() {
|
|
71
|
-
return matchCustomPropertyFromValue;
|
|
72
|
-
}
|
|
73
|
-
});
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|