weapp-tailwindcss 5.1.4 → 5.1.5
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/bundlers/shared/generator-css/generation-helpers.d.ts +8 -2
- package/dist/bundlers/shared/generator-css/source-resolver/metadata.d.ts +5 -1
- package/dist/bundlers/vite/generate-bundle/tailwind-v4-css-source.d.ts +6 -3
- package/dist/bundlers/vite/hot-css-modules.d.ts +1 -0
- package/dist/bundlers/vite/source-scan/css-entries.d.ts +1 -0
- package/dist/bundlers/webpack/BaseUnifiedPlugin/v5-assets/pipeline-helpers.d.ts +2 -1
- package/dist/cli.js +18 -3
- package/dist/cli.mjs +16 -1
- package/dist/{context-DCVMkTRj.js → context-BziwyWy1.js} +21 -6
- package/dist/{context-Bkpmt3ja.mjs → context-rrYZuUBU.mjs} +18 -3
- package/dist/core.js +1 -1
- package/dist/core.mjs +1 -1
- package/dist/css-macro/index.d.ts +2 -1
- package/dist/{defaults-BhE26nSw.mjs → defaults-9B6aMyZb.mjs} +2 -2
- package/dist/{defaults-DQhgnnn-.js → defaults-nsf4VNMX.js} +2 -2
- package/dist/defaults.d.ts +1 -1
- package/dist/defaults.js +1 -1
- package/dist/defaults.mjs +1 -1
- package/dist/{gulp-Bogfnoki.js → gulp-CuVsZdO9.js} +3 -3
- package/dist/{gulp-0RsqkF_d.mjs → gulp-ygWfmOqh.mjs} +3 -3
- package/dist/gulp.js +1 -1
- package/dist/gulp.mjs +1 -1
- package/dist/{hmr-timing-BV6nFPoT.js → hmr-timing-BKdCeIrn.js} +207 -67
- package/dist/{hmr-timing-BRNaz8Od.mjs → hmr-timing-Dh_nn3w5.mjs} +207 -67
- package/dist/index.js +3 -3
- package/dist/index.mjs +3 -3
- package/dist/js/js-string-escape.d.ts +1 -0
- package/dist/presets.js +1 -1
- package/dist/presets.mjs +1 -1
- package/dist/rspack.js +1 -1
- package/dist/rspack.mjs +1 -1
- package/dist/{source-candidate-scan-signature-BB1hvW68.mjs → source-candidate-scan-signature-DATRnS1X.mjs} +157 -6
- package/dist/{source-candidate-scan-signature-CaDT0gkj.js → source-candidate-scan-signature-DIj9m4wB.js} +168 -5
- package/dist/style-injector/internal.d.ts +7 -0
- package/dist/style-injector/options.d.ts +25 -0
- package/dist/tailwindcss/v4/preflight.d.ts +4 -0
- package/dist/{tailwindcss-D2xs4OEu.js → tailwindcss-BwoNQ3t8.js} +52 -12
- package/dist/{tailwindcss-D0JF0fuZ.mjs → tailwindcss-C-uM4rB8.mjs} +47 -13
- package/dist/{transform-BP86eSZp.mjs → transform-DHLemtaX.mjs} +1 -1
- package/dist/{transform-CXCQ28Tc.js → transform-KLD1tJdb.js} +1 -1
- package/dist/typedoc.export.d.ts +1 -0
- package/dist/types/index.d.ts +2 -1
- package/dist/types/user-defined-options/general.d.ts +2 -0
- package/dist/{vite-BYgT1ir9.js → vite-Yp14HNyS.js} +101 -37
- package/dist/{vite-B1SlBmqO.mjs → vite-cH0tTMHc.mjs} +101 -37
- package/dist/vite.js +1 -1
- package/dist/vite.mjs +1 -1
- package/dist/weapp-tw-css-import-rewrite-loader.js +276 -83
- package/dist/{webpack-Bg6pefpb.mjs → webpack-DBhmJ-_P.mjs} +62 -18
- package/dist/{webpack-khSwkXP5.js → webpack-DN3tgLbF.js} +61 -17
- package/dist/webpack.js +1 -1
- package/dist/webpack.mjs +1 -1
- package/package.json +16 -5
|
@@ -6,13 +6,19 @@ import type { InternalUserDefinedOptions } from '../../../types';
|
|
|
6
6
|
export declare function hasMiniProgramTailwindV4PreflightReset(css: string): boolean;
|
|
7
7
|
export declare function finalizeMiniProgramGeneratorCss(css: string, target: string, _majorVersion: number | undefined, cssPreflight: InternalUserDefinedOptions['cssPreflight'], options?: {
|
|
8
8
|
injectPreflight?: boolean;
|
|
9
|
+
preservePreflight?: boolean;
|
|
9
10
|
styleOptions?: Partial<IStyleHandlerOptions> | undefined;
|
|
10
11
|
}): string;
|
|
11
|
-
export declare function
|
|
12
|
+
export declare function resolveMiniProgramPreflightModeForGeneratorCss(opts: InternalUserDefinedOptions, options: {
|
|
12
13
|
cssHandlerOptions: IStyleHandlerOptions;
|
|
13
14
|
isolateCurrentCssCandidates: boolean;
|
|
14
15
|
localImports?: string | undefined;
|
|
15
|
-
|
|
16
|
+
primaryCssSource?: boolean | undefined;
|
|
17
|
+
explicitCssSource?: boolean | undefined;
|
|
18
|
+
}): {
|
|
19
|
+
inject: boolean;
|
|
20
|
+
preserve: boolean;
|
|
21
|
+
};
|
|
16
22
|
export declare function mergeScopedRuntimeWithCurrentRuntime(scopedRuntime: Set<string>, runtime: Set<string>, options: {
|
|
17
23
|
currentCssCandidates?: string[] | undefined;
|
|
18
24
|
cssHandlerOptions: IStyleHandlerOptions;
|
|
@@ -2,8 +2,12 @@ import type { SourceSideCssEntrySource } from '../source-files';
|
|
|
2
2
|
import type { TailwindResolvedSource } from '../../../../generator';
|
|
3
3
|
import type { TailwindSourceEntry } from '../../../../tailwindcss/source-scan';
|
|
4
4
|
export interface GeneratorSourceMetadata {
|
|
5
|
+
cssEntryIndex?: number | undefined;
|
|
6
|
+
cssSourceIndex?: number | undefined;
|
|
7
|
+
includesPreflight?: boolean | undefined;
|
|
5
8
|
isolateCssSource?: boolean | undefined;
|
|
6
9
|
matchedCssSourceFile?: string | undefined;
|
|
10
|
+
primaryCssSource?: boolean | undefined;
|
|
7
11
|
sourceEntries?: TailwindSourceEntry[] | undefined;
|
|
8
12
|
sourceBase?: string | undefined;
|
|
9
13
|
sourceCss?: string | undefined;
|
|
@@ -12,4 +16,4 @@ export type GeneratorResolvedSource = TailwindResolvedSource & {
|
|
|
12
16
|
__weappTailwindcssMeta?: GeneratorSourceMetadata | undefined;
|
|
13
17
|
};
|
|
14
18
|
export declare function withGeneratorSourceMetadata(source: TailwindResolvedSource, metadata: GeneratorSourceMetadata): GeneratorResolvedSource;
|
|
15
|
-
export declare function withMatchedSourceSideMetadata(source: TailwindResolvedSource, resolvedEntrySource: SourceSideCssEntrySource): import("@/generator").TailwindV4ResolvedSource;
|
|
19
|
+
export declare function withMatchedSourceSideMetadata(source: TailwindResolvedSource, resolvedEntrySource: SourceSideCssEntrySource, metadata?: GeneratorSourceMetadata): import("@/generator").TailwindV4ResolvedSource;
|
|
@@ -2,8 +2,11 @@ export interface TailwindV4GenerationCssSourceEntry {
|
|
|
2
2
|
file: string;
|
|
3
3
|
source: string;
|
|
4
4
|
}
|
|
5
|
+
export interface TailwindV4GenerationCssSourceSelectionOptions {
|
|
6
|
+
cwd?: string | undefined;
|
|
7
|
+
outputRoot?: string | undefined;
|
|
8
|
+
projectRoot?: string | undefined;
|
|
9
|
+
}
|
|
5
10
|
export declare function collectTailwindV4SourceFingerprint(source: string): Set<string>;
|
|
6
11
|
export declare function scoreConfiguredTailwindV4SourceForRawSource(rawSource: string | undefined, entrySource: string): number;
|
|
7
|
-
export declare function
|
|
8
|
-
export declare function isSameSubpackageScope(outputFile: string, sourceFile: string | undefined, subpackageRoots: Set<string> | undefined): boolean;
|
|
9
|
-
export declare function selectTailwindV4GenerationCssSourceForOutput<T extends TailwindV4GenerationCssSourceEntry>(outputFile: string, entries: T[], rawSource?: string, subpackageRoots?: Set<string> | undefined): T | undefined;
|
|
12
|
+
export declare function selectTailwindV4GenerationCssSourceForOutput<T extends TailwindV4GenerationCssSourceEntry>(outputFile: string, entries: T[], rawSource?: string, options?: TailwindV4GenerationCssSourceSelectionOptions): T | undefined;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { HmrContext, ModuleNode } from 'vite';
|
|
2
2
|
export declare function resolveHotTailwindCssModules(ctx: HmrContext, tailwindRootCssModuleIds: Set<string>): ModuleNode[];
|
|
3
|
+
export declare function resolveHotSourceModules(ctx: HmrContext): ModuleNode[];
|
|
3
4
|
export declare function hasSelfAcceptingNonStyleHotModule(modules: ModuleNode[]): boolean;
|
|
4
5
|
export declare function sendSupplementalCssHotUpdates(ctx: HmrContext, cssModules: ModuleNode[]): void;
|
|
5
6
|
export declare function sendFullReloadForUnresolvedHotUpdate(ctx: HmrContext): void;
|
|
@@ -4,6 +4,7 @@ import type { UserDefinedOptions } from '../../../types';
|
|
|
4
4
|
export interface ResolvedTailwindV4CssEntries {
|
|
5
5
|
entries: TailwindSourceEntry[];
|
|
6
6
|
explicit: boolean;
|
|
7
|
+
includesPreflight: boolean;
|
|
7
8
|
inlineCandidates: TailwindInlineSourceCandidates;
|
|
8
9
|
dependencies: string[];
|
|
9
10
|
}
|
|
@@ -140,7 +140,7 @@ export declare function resolveWebpackMemoryDebugStats(context: {
|
|
|
140
140
|
};
|
|
141
141
|
};
|
|
142
142
|
} | undefined;
|
|
143
|
-
export declare function shouldInjectWebpackCssTracePreflight(
|
|
143
|
+
export declare function shouldInjectWebpackCssTracePreflight(_appType: SetupWebpackV5ProcessAssetsHookOptions['appType'], cssHandlerOptions: Pick<WebpackCssHandlerOptions, 'isMainChunk' | 'sourceOptions'>): boolean;
|
|
144
144
|
export declare function finalizeMiniProgramUserCssAssetSource(source: string, compilerOptions: SetupWebpackV5ProcessAssetsHookOptions['options'], isWebGeneratorTarget: boolean, options?: {
|
|
145
145
|
cssPreflight?: boolean | undefined;
|
|
146
146
|
}): string;
|
|
@@ -183,6 +183,7 @@ export declare function finalizeTracedWebpackCssAsset(css: string, cssHandlerOpt
|
|
|
183
183
|
isWebGeneratorTarget: boolean;
|
|
184
184
|
}): string;
|
|
185
185
|
export declare function finalizeWebpackCssAssetSource(source: string, compilerOptions: SetupWebpackV5ProcessAssetsHookOptions['options'], isWebGeneratorTarget: boolean, options?: {
|
|
186
|
+
cssPreflight?: boolean | undefined;
|
|
186
187
|
generatedCss?: boolean;
|
|
187
188
|
}): string;
|
|
188
189
|
export declare function collectWebpackJsRuntimeCandidatesFromAssets(options: {
|
package/dist/cli.js
CHANGED
|
@@ -47,7 +47,6 @@ _babel_traverse = __toESM(_babel_traverse);
|
|
|
47
47
|
let _babel_parser = require("@babel/parser");
|
|
48
48
|
let magic_string = require("magic-string");
|
|
49
49
|
magic_string = __toESM(magic_string);
|
|
50
|
-
let _ast_core_escape = require("@ast-core/escape");
|
|
51
50
|
require("@babel/types");
|
|
52
51
|
//#region src/js/babel/cache-options.ts
|
|
53
52
|
const DEFAULT_PARSE_CACHE_MAX_SOURCE_LENGTH = 5e4;
|
|
@@ -485,6 +484,22 @@ function isClassContextLiteralPath(path) {
|
|
|
485
484
|
return false;
|
|
486
485
|
}
|
|
487
486
|
//#endregion
|
|
487
|
+
//#region src/js/js-string-escape.ts
|
|
488
|
+
function jsStringEscape(value) {
|
|
489
|
+
return String(value).replaceAll(/[\n\r"'\\\u2028\u2029]/g, (character) => {
|
|
490
|
+
switch (character) {
|
|
491
|
+
case "\"":
|
|
492
|
+
case "'":
|
|
493
|
+
case "\\": return `\\${character}`;
|
|
494
|
+
case "\n": return "\\n";
|
|
495
|
+
case "\r": return "\\r";
|
|
496
|
+
case "\u2028": return "\\u2028";
|
|
497
|
+
case "\u2029": return "\\u2029";
|
|
498
|
+
default: return character;
|
|
499
|
+
}
|
|
500
|
+
});
|
|
501
|
+
}
|
|
502
|
+
//#endregion
|
|
488
503
|
//#region src/js/replacement-cache.ts
|
|
489
504
|
const replacementCacheByEscapeMap = /* @__PURE__ */ new WeakMap();
|
|
490
505
|
const defaultReplacementCache = /* @__PURE__ */ new Map();
|
|
@@ -644,7 +659,7 @@ function replaceHandleValue(path, options) {
|
|
|
644
659
|
return {
|
|
645
660
|
start,
|
|
646
661
|
end,
|
|
647
|
-
value: needEscaped ?
|
|
662
|
+
value: needEscaped ? jsStringEscape(transformed) : transformed,
|
|
648
663
|
path
|
|
649
664
|
};
|
|
650
665
|
}
|
|
@@ -756,7 +771,7 @@ function createEvalReplacementToken(path, updated) {
|
|
|
756
771
|
return {
|
|
757
772
|
start,
|
|
758
773
|
end,
|
|
759
|
-
value: path.isStringLiteral() ?
|
|
774
|
+
value: path.isStringLiteral() ? jsStringEscape(updated) : updated,
|
|
760
775
|
path
|
|
761
776
|
};
|
|
762
777
|
}
|
package/dist/cli.mjs
CHANGED
|
@@ -18,7 +18,6 @@ import "tailwindcss-config";
|
|
|
18
18
|
import _babelTraverse from "@babel/traverse";
|
|
19
19
|
import { parse } from "@babel/parser";
|
|
20
20
|
import MagicString from "magic-string";
|
|
21
|
-
import { jsStringEscape } from "@ast-core/escape";
|
|
22
21
|
import "@babel/types";
|
|
23
22
|
//#region src/js/babel/cache-options.ts
|
|
24
23
|
const DEFAULT_PARSE_CACHE_MAX_SOURCE_LENGTH = 5e4;
|
|
@@ -456,6 +455,22 @@ function isClassContextLiteralPath(path) {
|
|
|
456
455
|
return false;
|
|
457
456
|
}
|
|
458
457
|
//#endregion
|
|
458
|
+
//#region src/js/js-string-escape.ts
|
|
459
|
+
function jsStringEscape(value) {
|
|
460
|
+
return String(value).replaceAll(/[\n\r"'\\\u2028\u2029]/g, (character) => {
|
|
461
|
+
switch (character) {
|
|
462
|
+
case "\"":
|
|
463
|
+
case "'":
|
|
464
|
+
case "\\": return `\\${character}`;
|
|
465
|
+
case "\n": return "\\n";
|
|
466
|
+
case "\r": return "\\r";
|
|
467
|
+
case "\u2028": return "\\u2028";
|
|
468
|
+
case "\u2029": return "\\u2029";
|
|
469
|
+
default: return character;
|
|
470
|
+
}
|
|
471
|
+
});
|
|
472
|
+
}
|
|
473
|
+
//#endregion
|
|
459
474
|
//#region src/js/replacement-cache.ts
|
|
460
475
|
const replacementCacheByEscapeMap = /* @__PURE__ */ new WeakMap();
|
|
461
476
|
const defaultReplacementCache = /* @__PURE__ */ new Map();
|
|
@@ -3,8 +3,8 @@ const require_framework = require("./framework.js");
|
|
|
3
3
|
const require_v4_engine = require("./v4-engine-CKtsdKxK.js");
|
|
4
4
|
const require_generator = require("./generator-CilgHtxb.js");
|
|
5
5
|
require("./utils-D3h8j7Mk.js");
|
|
6
|
-
const require_defaults = require("./defaults-
|
|
7
|
-
const require_tailwindcss = require("./tailwindcss-
|
|
6
|
+
const require_defaults = require("./defaults-nsf4VNMX.js");
|
|
7
|
+
const require_tailwindcss = require("./tailwindcss-BwoNQ3t8.js");
|
|
8
8
|
let node_path = require("node:path");
|
|
9
9
|
node_path = require_rolldown_runtime.__toESM(node_path);
|
|
10
10
|
let node_process = require("node:process");
|
|
@@ -25,7 +25,6 @@ _babel_traverse = require_rolldown_runtime.__toESM(_babel_traverse);
|
|
|
25
25
|
let _babel_parser = require("@babel/parser");
|
|
26
26
|
let magic_string = require("magic-string");
|
|
27
27
|
magic_string = require_rolldown_runtime.__toESM(magic_string);
|
|
28
|
-
let _ast_core_escape = require("@ast-core/escape");
|
|
29
28
|
let _babel_types = require("@babel/types");
|
|
30
29
|
_babel_types = require_rolldown_runtime.__toESM(_babel_types);
|
|
31
30
|
let _weapp_tailwindcss_shared = require("@weapp-tailwindcss/shared");
|
|
@@ -959,6 +958,22 @@ function isClassContextLiteralPath(path) {
|
|
|
959
958
|
return false;
|
|
960
959
|
}
|
|
961
960
|
//#endregion
|
|
961
|
+
//#region src/js/js-string-escape.ts
|
|
962
|
+
function jsStringEscape(value) {
|
|
963
|
+
return String(value).replaceAll(/[\n\r"'\\\u2028\u2029]/g, (character) => {
|
|
964
|
+
switch (character) {
|
|
965
|
+
case "\"":
|
|
966
|
+
case "'":
|
|
967
|
+
case "\\": return `\\${character}`;
|
|
968
|
+
case "\n": return "\\n";
|
|
969
|
+
case "\r": return "\\r";
|
|
970
|
+
case "\u2028": return "\\u2028";
|
|
971
|
+
case "\u2029": return "\\u2029";
|
|
972
|
+
default: return character;
|
|
973
|
+
}
|
|
974
|
+
});
|
|
975
|
+
}
|
|
976
|
+
//#endregion
|
|
962
977
|
//#region src/js/replacement-cache.ts
|
|
963
978
|
const replacementCacheByEscapeMap = /* @__PURE__ */ new WeakMap();
|
|
964
979
|
const defaultReplacementCache = /* @__PURE__ */ new Map();
|
|
@@ -1118,7 +1133,7 @@ function replaceHandleValue(path, options) {
|
|
|
1118
1133
|
return {
|
|
1119
1134
|
start,
|
|
1120
1135
|
end,
|
|
1121
|
-
value: needEscaped ?
|
|
1136
|
+
value: needEscaped ? jsStringEscape(transformed) : transformed,
|
|
1122
1137
|
path
|
|
1123
1138
|
};
|
|
1124
1139
|
}
|
|
@@ -1230,7 +1245,7 @@ function createEvalReplacementToken(path, updated) {
|
|
|
1230
1245
|
return {
|
|
1231
1246
|
start,
|
|
1232
1247
|
end,
|
|
1233
|
-
value: path.isStringLiteral() ?
|
|
1248
|
+
value: path.isStringLiteral() ? jsStringEscape(updated) : updated,
|
|
1234
1249
|
path
|
|
1235
1250
|
};
|
|
1236
1251
|
}
|
|
@@ -2188,7 +2203,7 @@ function addStringLiteralReplacement(rawSource, node, transformOptions, context)
|
|
|
2188
2203
|
const start = node.start + 1;
|
|
2189
2204
|
const end = node.end - 1;
|
|
2190
2205
|
if (start >= end || transformed === rawSource.slice(start, end)) return false;
|
|
2191
|
-
getMagicString(rawSource, context).update(start, end,
|
|
2206
|
+
getMagicString(rawSource, context).update(start, end, jsStringEscape(transformed));
|
|
2192
2207
|
return true;
|
|
2193
2208
|
}
|
|
2194
2209
|
function addTemplateElementReplacement(rawSource, node, transformOptions, context) {
|
|
@@ -2,8 +2,8 @@ import { resolveMpxPlatform } from "./framework.mjs";
|
|
|
2
2
|
import { W as createTailwindV4Engine$1, ct as omitUndefined, dt as resolveValidTailwindV4Candidates$1, n as resolveTailwindV4SourceFromRuntime, ot as resolveCssMacroTailwindV4Source, ut as loadTailwindV4DesignSystem, y as resolveBooleanObjectOption } from "./v4-engine-BuuYDXt1.mjs";
|
|
3
3
|
import { a as resolveGeneratorRuntimeBranch, i as normalizeWeappTailwindcssGeneratorOptions } from "./generator-24-HgU9F.mjs";
|
|
4
4
|
import { i as isMap, n as defuOverrideArray } from "./utils-DodxWHGz.mjs";
|
|
5
|
-
import { a as DEFAULT_PARSE_CACHE_MAX_SOURCE_LENGTH, i as resolveDefaultCssPreflight, o as HARD_PARSE_CACHE_MAX_ENTRIES, r as getDefaultOptions } from "./defaults-
|
|
6
|
-
import { c as getRuntimeClassSetCacheEntry, d as invalidateRuntimeClassSet, i as resolveUniAppXOptions, o as applyV4CssCalcDefaults, s as warnMissingCssEntries, t as createTailwindcssRuntimeFromContext, u as getRuntimeClassSetSignatureWithSources } from "./tailwindcss-
|
|
5
|
+
import { a as DEFAULT_PARSE_CACHE_MAX_SOURCE_LENGTH, i as resolveDefaultCssPreflight, o as HARD_PARSE_CACHE_MAX_ENTRIES, r as getDefaultOptions } from "./defaults-9B6aMyZb.mjs";
|
|
6
|
+
import { c as getRuntimeClassSetCacheEntry, d as invalidateRuntimeClassSet, i as resolveUniAppXOptions, o as applyV4CssCalcDefaults, s as warnMissingCssEntries, t as createTailwindcssRuntimeFromContext, u as getRuntimeClassSetSignatureWithSources } from "./tailwindcss-C-uM4rB8.mjs";
|
|
7
7
|
import { createRequire } from "node:module";
|
|
8
8
|
import path from "node:path";
|
|
9
9
|
import process from "node:process";
|
|
@@ -19,7 +19,6 @@ import _createDebug from "debug";
|
|
|
19
19
|
import _babelTraverse from "@babel/traverse";
|
|
20
20
|
import { parse, parseExpression } from "@babel/parser";
|
|
21
21
|
import MagicString from "magic-string";
|
|
22
|
-
import { jsStringEscape } from "@ast-core/escape";
|
|
23
22
|
import * as t from "@babel/types";
|
|
24
23
|
//#region src/cache/index.ts
|
|
25
24
|
function isProcessResult(value) {
|
|
@@ -951,6 +950,22 @@ function isClassContextLiteralPath(path) {
|
|
|
951
950
|
return false;
|
|
952
951
|
}
|
|
953
952
|
//#endregion
|
|
953
|
+
//#region src/js/js-string-escape.ts
|
|
954
|
+
function jsStringEscape(value) {
|
|
955
|
+
return String(value).replaceAll(/[\n\r"'\\\u2028\u2029]/g, (character) => {
|
|
956
|
+
switch (character) {
|
|
957
|
+
case "\"":
|
|
958
|
+
case "'":
|
|
959
|
+
case "\\": return `\\${character}`;
|
|
960
|
+
case "\n": return "\\n";
|
|
961
|
+
case "\r": return "\\r";
|
|
962
|
+
case "\u2028": return "\\u2028";
|
|
963
|
+
case "\u2029": return "\\u2029";
|
|
964
|
+
default: return character;
|
|
965
|
+
}
|
|
966
|
+
});
|
|
967
|
+
}
|
|
968
|
+
//#endregion
|
|
954
969
|
//#region src/js/replacement-cache.ts
|
|
955
970
|
const replacementCacheByEscapeMap = /* @__PURE__ */ new WeakMap();
|
|
956
971
|
const defaultReplacementCache = /* @__PURE__ */ new Map();
|
package/dist/core.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_context = require("./context-
|
|
2
|
+
const require_context = require("./context-BziwyWy1.js");
|
|
3
3
|
let _weapp_tailwindcss_shared = require("@weapp-tailwindcss/shared");
|
|
4
4
|
//#region src/core.ts
|
|
5
5
|
const DEFAULT_MAIN_CHUNK_STYLE_OPTIONS = Object.freeze({ isMainChunk: true });
|
package/dist/core.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { b as ensureRuntimeClassSet, l as shouldSkipJsTransform, t as getCompilerContext, y as createTailwindRuntimeReadyPromise } from "./context-
|
|
1
|
+
import { b as ensureRuntimeClassSet, l as shouldSkipJsTransform, t as getCompilerContext, y as createTailwindRuntimeReadyPromise } from "./context-rrYZuUBU.mjs";
|
|
2
2
|
import { defuOverrideArray } from "@weapp-tailwindcss/shared";
|
|
3
3
|
//#region src/core.ts
|
|
4
4
|
const DEFAULT_MAIN_CHUNK_STYLE_OPTIONS = Object.freeze({ isMainChunk: true });
|
|
@@ -10,10 +10,10 @@ const HTML_FILE_PATTERN = /.+\.(?:(?:wx|ax|jx|ks|tt|q|ty|xhs)ml|swan)$/;
|
|
|
10
10
|
const JS_FILE_PATTERN = /.+\.[cm]?js?$/;
|
|
11
11
|
const alwaysFalse = () => false;
|
|
12
12
|
const TAILWIND_V4_CSS_PREFLIGHT = {
|
|
13
|
+
"border": "0 solid",
|
|
13
14
|
"box-sizing": "border-box",
|
|
14
15
|
"margin": "0",
|
|
15
|
-
"padding": "0"
|
|
16
|
-
"border": "0 solid"
|
|
16
|
+
"padding": "0"
|
|
17
17
|
};
|
|
18
18
|
function getDefaultCssPreflight() {
|
|
19
19
|
return { ...TAILWIND_V4_CSS_PREFLIGHT };
|
|
@@ -11,10 +11,10 @@ const HTML_FILE_PATTERN = /.+\.(?:(?:wx|ax|jx|ks|tt|q|ty|xhs)ml|swan)$/;
|
|
|
11
11
|
const JS_FILE_PATTERN = /.+\.[cm]?js?$/;
|
|
12
12
|
const alwaysFalse = () => false;
|
|
13
13
|
const TAILWIND_V4_CSS_PREFLIGHT = {
|
|
14
|
+
"border": "0 solid",
|
|
14
15
|
"box-sizing": "border-box",
|
|
15
16
|
"margin": "0",
|
|
16
|
-
"padding": "0"
|
|
17
|
-
"border": "0 solid"
|
|
17
|
+
"padding": "0"
|
|
18
18
|
};
|
|
19
19
|
function getDefaultCssPreflight() {
|
|
20
20
|
return { ...TAILWIND_V4_CSS_PREFLIGHT };
|
package/dist/defaults.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { CssPreflightOptions, UserDefinedOptions } from './types';
|
|
2
2
|
export declare const TAILWIND_V4_CSS_PREFLIGHT: {
|
|
3
|
+
border: string;
|
|
3
4
|
'box-sizing': string;
|
|
4
5
|
margin: string;
|
|
5
6
|
padding: string;
|
|
6
|
-
border: string;
|
|
7
7
|
};
|
|
8
8
|
export declare function getDefaultCssPreflight(): Exclude<CssPreflightOptions, false>;
|
|
9
9
|
export declare function resolveDefaultCssPreflight(cssPreflight: CssPreflightOptions | undefined, _tailwindcssMajorVersion?: number): CssPreflightOptions;
|
package/dist/defaults.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_defaults = require("./defaults-
|
|
2
|
+
const require_defaults = require("./defaults-nsf4VNMX.js");
|
|
3
3
|
exports.TAILWIND_V4_CSS_PREFLIGHT = require_defaults.TAILWIND_V4_CSS_PREFLIGHT;
|
|
4
4
|
exports.getDefaultCssPreflight = require_defaults.getDefaultCssPreflight;
|
|
5
5
|
exports.getDefaultOptions = require_defaults.getDefaultOptions;
|
package/dist/defaults.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as resolveDefaultCssPreflight, n as getDefaultCssPreflight, r as getDefaultOptions, t as TAILWIND_V4_CSS_PREFLIGHT } from "./defaults-
|
|
1
|
+
import { i as resolveDefaultCssPreflight, n as getDefaultCssPreflight, r as getDefaultOptions, t as TAILWIND_V4_CSS_PREFLIGHT } from "./defaults-9B6aMyZb.mjs";
|
|
2
2
|
export { TAILWIND_V4_CSS_PREFLIGHT, getDefaultCssPreflight, getDefaultOptions, resolveDefaultCssPreflight };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
const require_rolldown_runtime = require("./rolldown-runtime-emK7D4bc.js");
|
|
2
2
|
const require_v4_engine = require("./v4-engine-CKtsdKxK.js");
|
|
3
|
-
const require_context = require("./context-
|
|
4
|
-
const require_tailwindcss = require("./tailwindcss-
|
|
5
|
-
const require_hmr_timing = require("./hmr-timing-
|
|
3
|
+
const require_context = require("./context-BziwyWy1.js");
|
|
4
|
+
const require_tailwindcss = require("./tailwindcss-BwoNQ3t8.js");
|
|
5
|
+
const require_hmr_timing = require("./hmr-timing-BKdCeIrn.js");
|
|
6
6
|
let node_fs = require("node:fs");
|
|
7
7
|
node_fs = require_rolldown_runtime.__toESM(node_fs);
|
|
8
8
|
let node_path = require("node:path");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { C as hasTailwindRootDirectives, D as normalizeTailwindSourceForGenerator, G as getTailwindV4IncrementalGenerateCacheStats, T as normalizeTailwindConfigDirectives, U as prependConfigDirective, o as hasConfiguredTailwindV4CssRoots, s as upsertTailwindV4CssSource } from "./v4-engine-BuuYDXt1.mjs";
|
|
2
|
-
import { S as createDebug, b as ensureRuntimeClassSet, l as shouldSkipJsTransform, n as normalizeStyleHandlerMajorVersion, t as getCompilerContext, y as createTailwindRuntimeReadyPromise } from "./context-
|
|
3
|
-
import { l as getRuntimeClassSetSignature, p as resolveViteSourceScanEntries } from "./tailwindcss-
|
|
4
|
-
import { F as createCssTokenSourceMap, L as processCachedTask, N as annotateCssSourceTrace, P as createCssSourceTraceCacheSignature, n as emitHmrTiming, r as createSourceCandidateCollector, s as createBundleRuntimeClassSetManager, u as generateCssByGenerator, v as rewriteLocalCssImportRequestsForOutput, y as splitLocalCssImports } from "./hmr-timing-
|
|
2
|
+
import { S as createDebug, b as ensureRuntimeClassSet, l as shouldSkipJsTransform, n as normalizeStyleHandlerMajorVersion, t as getCompilerContext, y as createTailwindRuntimeReadyPromise } from "./context-rrYZuUBU.mjs";
|
|
3
|
+
import { l as getRuntimeClassSetSignature, p as resolveViteSourceScanEntries } from "./tailwindcss-C-uM4rB8.mjs";
|
|
4
|
+
import { F as createCssTokenSourceMap, L as processCachedTask, N as annotateCssSourceTrace, P as createCssSourceTraceCacheSignature, n as emitHmrTiming, r as createSourceCandidateCollector, s as createBundleRuntimeClassSetManager, u as generateCssByGenerator, v as rewriteLocalCssImportRequestsForOutput, y as splitLocalCssImports } from "./hmr-timing-Dh_nn3w5.mjs";
|
|
5
5
|
import fs from "node:fs";
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import process from "node:process";
|
package/dist/gulp.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_gulp = require("./gulp-
|
|
2
|
+
const require_gulp = require("./gulp-CuVsZdO9.js");
|
|
3
3
|
exports.WeappTailwindcss = require_gulp.createPlugins;
|
|
4
4
|
exports.createPlugins = require_gulp.createPlugins;
|
|
5
5
|
exports.weappTailwindcss = require_gulp.createPlugins;
|
package/dist/gulp.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as createPlugins } from "./gulp-
|
|
1
|
+
import { t as createPlugins } from "./gulp-ygWfmOqh.mjs";
|
|
2
2
|
export { createPlugins as WeappTailwindcss, createPlugins, createPlugins as weappTailwindcss };
|