weapp-tailwindcss 4.7.0 → 4.7.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/{chunk-Q5TPAJI4.js → chunk-2SI3KT2H.js} +7 -6
- package/dist/{chunk-IY2OKZE6.mjs → chunk-3ARXMTWC.mjs} +21 -8
- package/dist/{chunk-D7SF52F6.mjs → chunk-5BW6X6AJ.mjs} +42 -36
- package/dist/chunk-667CYXAH.mjs +133 -0
- package/dist/chunk-BUMQQPAO.js +133 -0
- package/dist/{chunk-W3JU6K3T.js → chunk-FPDJ3BCM.js} +260 -108
- package/dist/{chunk-BAXZHBSU.js → chunk-GNWJEIZZ.js} +92 -77
- package/dist/{chunk-7TKAJ3P6.mjs → chunk-JYCQWWYU.mjs} +257 -105
- package/dist/{chunk-NRG7N2Q7.mjs → chunk-KZJLIZIK.mjs} +0 -1
- package/dist/{chunk-34T2BFTJ.mjs → chunk-KZUIVLPP.mjs} +42 -1
- package/dist/{chunk-C3CG4UUY.js → chunk-OPTIAB5G.js} +21 -8
- package/dist/{chunk-BTOCLUJ4.mjs → chunk-Q6PLZCM6.mjs} +6 -5
- package/dist/{chunk-CCMDCC3N.js → chunk-QZRXYCOQ.js} +49 -43
- package/dist/{chunk-WVKK6TBL.js → chunk-W7BVY5S5.js} +42 -1
- package/dist/{chunk-LZ6L3UQO.js → chunk-WXBFAARR.js} +0 -1
- package/dist/{chunk-KSXOBEXQ.mjs → chunk-Z2H7M33Z.mjs} +83 -68
- package/dist/cli.js +6 -6
- package/dist/cli.mjs +3 -3
- package/dist/core.js +10 -9
- package/dist/core.mjs +10 -9
- package/dist/defaults.js +2 -2
- package/dist/defaults.mjs +1 -1
- package/dist/gulp.js +6 -6
- package/dist/gulp.mjs +5 -5
- package/dist/index.js +9 -9
- package/dist/index.mjs +8 -8
- package/dist/presets.js +2 -2
- package/dist/presets.mjs +1 -1
- package/dist/types.d.mts +2 -21
- package/dist/types.d.ts +2 -21
- package/dist/vite.js +7 -7
- package/dist/vite.mjs +6 -6
- package/dist/webpack.js +7 -7
- package/dist/webpack.mjs +6 -6
- package/dist/webpack4.js +51 -45
- package/dist/webpack4.mjs +44 -38
- package/package.json +4 -4
- package/dist/chunk-FB5P4TRH.js +0 -70
- package/dist/chunk-YPBRGP6K.mjs +0 -70
package/dist/chunk-FB5P4TRH.js
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }// src/debug/index.ts
|
|
2
|
-
var _debug2 = require('debug'); var _debug3 = _interopRequireDefault(_debug2);
|
|
3
|
-
var _debug = _debug3.default.call(void 0, "weapp-tw");
|
|
4
|
-
function createDebug(prefix) {
|
|
5
|
-
function debug2(formatter, ...args) {
|
|
6
|
-
return _debug((_nullishCoalesce(prefix, () => ( ""))) + formatter, ...args);
|
|
7
|
-
}
|
|
8
|
-
return debug2;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
// src/tailwindcss/runtime.ts
|
|
12
|
-
var debug = createDebug("[tailwindcss:runtime] ");
|
|
13
|
-
function shouldPreferSync(majorVersion) {
|
|
14
|
-
if (majorVersion == null) {
|
|
15
|
-
return true;
|
|
16
|
-
}
|
|
17
|
-
if (majorVersion === 3) {
|
|
18
|
-
return true;
|
|
19
|
-
}
|
|
20
|
-
if (majorVersion === 4) {
|
|
21
|
-
return true;
|
|
22
|
-
}
|
|
23
|
-
return false;
|
|
24
|
-
}
|
|
25
|
-
function tryGetRuntimeClassSetSync(twPatcher) {
|
|
26
|
-
if (typeof twPatcher.getClassSetSync !== "function") {
|
|
27
|
-
return void 0;
|
|
28
|
-
}
|
|
29
|
-
if (!shouldPreferSync(twPatcher.majorVersion)) {
|
|
30
|
-
return void 0;
|
|
31
|
-
}
|
|
32
|
-
try {
|
|
33
|
-
return twPatcher.getClassSetSync();
|
|
34
|
-
} catch (error) {
|
|
35
|
-
if (twPatcher.majorVersion === 4) {
|
|
36
|
-
debug("getClassSetSync() unavailable for tailwindcss v4, fallback to async getClassSet(): %O", error);
|
|
37
|
-
} else {
|
|
38
|
-
debug("getClassSetSync() failed, fallback to async getClassSet(): %O", error);
|
|
39
|
-
}
|
|
40
|
-
return void 0;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
async function collectRuntimeClassSet(twPatcher) {
|
|
44
|
-
const syncSet = tryGetRuntimeClassSetSync(twPatcher);
|
|
45
|
-
if (syncSet) {
|
|
46
|
-
return syncSet;
|
|
47
|
-
}
|
|
48
|
-
try {
|
|
49
|
-
const result = await twPatcher.extract({ write: false });
|
|
50
|
-
if (_optionalChain([result, 'optionalAccess', _ => _.classSet])) {
|
|
51
|
-
return result.classSet;
|
|
52
|
-
}
|
|
53
|
-
} catch (error) {
|
|
54
|
-
debug("extract() failed, fallback to getClassSet(): %O", error);
|
|
55
|
-
}
|
|
56
|
-
try {
|
|
57
|
-
const fallbackSet = await Promise.resolve(twPatcher.getClassSet());
|
|
58
|
-
if (fallbackSet) {
|
|
59
|
-
return fallbackSet;
|
|
60
|
-
}
|
|
61
|
-
} catch (error) {
|
|
62
|
-
debug("getClassSet() failed, returning empty set: %O", error);
|
|
63
|
-
}
|
|
64
|
-
return /* @__PURE__ */ new Set();
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
exports.createDebug = createDebug; exports.collectRuntimeClassSet = collectRuntimeClassSet;
|
package/dist/chunk-YPBRGP6K.mjs
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
// src/debug/index.ts
|
|
2
|
-
import _createDebug from "debug";
|
|
3
|
-
var _debug = _createDebug("weapp-tw");
|
|
4
|
-
function createDebug(prefix) {
|
|
5
|
-
function debug2(formatter, ...args) {
|
|
6
|
-
return _debug((prefix ?? "") + formatter, ...args);
|
|
7
|
-
}
|
|
8
|
-
return debug2;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
// src/tailwindcss/runtime.ts
|
|
12
|
-
var debug = createDebug("[tailwindcss:runtime] ");
|
|
13
|
-
function shouldPreferSync(majorVersion) {
|
|
14
|
-
if (majorVersion == null) {
|
|
15
|
-
return true;
|
|
16
|
-
}
|
|
17
|
-
if (majorVersion === 3) {
|
|
18
|
-
return true;
|
|
19
|
-
}
|
|
20
|
-
if (majorVersion === 4) {
|
|
21
|
-
return true;
|
|
22
|
-
}
|
|
23
|
-
return false;
|
|
24
|
-
}
|
|
25
|
-
function tryGetRuntimeClassSetSync(twPatcher) {
|
|
26
|
-
if (typeof twPatcher.getClassSetSync !== "function") {
|
|
27
|
-
return void 0;
|
|
28
|
-
}
|
|
29
|
-
if (!shouldPreferSync(twPatcher.majorVersion)) {
|
|
30
|
-
return void 0;
|
|
31
|
-
}
|
|
32
|
-
try {
|
|
33
|
-
return twPatcher.getClassSetSync();
|
|
34
|
-
} catch (error) {
|
|
35
|
-
if (twPatcher.majorVersion === 4) {
|
|
36
|
-
debug("getClassSetSync() unavailable for tailwindcss v4, fallback to async getClassSet(): %O", error);
|
|
37
|
-
} else {
|
|
38
|
-
debug("getClassSetSync() failed, fallback to async getClassSet(): %O", error);
|
|
39
|
-
}
|
|
40
|
-
return void 0;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
async function collectRuntimeClassSet(twPatcher) {
|
|
44
|
-
const syncSet = tryGetRuntimeClassSetSync(twPatcher);
|
|
45
|
-
if (syncSet) {
|
|
46
|
-
return syncSet;
|
|
47
|
-
}
|
|
48
|
-
try {
|
|
49
|
-
const result = await twPatcher.extract({ write: false });
|
|
50
|
-
if (result?.classSet) {
|
|
51
|
-
return result.classSet;
|
|
52
|
-
}
|
|
53
|
-
} catch (error) {
|
|
54
|
-
debug("extract() failed, fallback to getClassSet(): %O", error);
|
|
55
|
-
}
|
|
56
|
-
try {
|
|
57
|
-
const fallbackSet = await Promise.resolve(twPatcher.getClassSet());
|
|
58
|
-
if (fallbackSet) {
|
|
59
|
-
return fallbackSet;
|
|
60
|
-
}
|
|
61
|
-
} catch (error) {
|
|
62
|
-
debug("getClassSet() failed, returning empty set: %O", error);
|
|
63
|
-
}
|
|
64
|
-
return /* @__PURE__ */ new Set();
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export {
|
|
68
|
-
createDebug,
|
|
69
|
-
collectRuntimeClassSet
|
|
70
|
-
};
|