tailwindcss-patch 9.0.0 → 9.0.1
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-8l464Juk.js +28 -0
- package/dist/cli.d.mts +1 -2
- package/dist/cli.d.ts +1 -2
- package/dist/cli.js +18 -22
- package/dist/cli.mjs +17 -22
- package/dist/commands/cli-runtime.d.mts +5 -10
- package/dist/commands/cli-runtime.d.ts +5 -10
- package/dist/commands/cli-runtime.js +582 -1217
- package/dist/commands/cli-runtime.mjs +570 -1216
- package/dist/dist-B1VBpHtd.js +21 -0
- package/dist/dist-BjUV1yEM.mjs +19 -0
- package/dist/index.bundle-BGBMTX9A.js +35 -0
- package/dist/index.bundle-ByrTqrr3.mjs +18 -0
- package/dist/index.d.mts +68 -67
- package/dist/index.d.ts +68 -67
- package/dist/index.js +28 -57
- package/dist/index.mjs +3 -57
- package/dist/validate-B8H-8rWO.js +3487 -0
- package/dist/validate-BI8356RT.mjs +3336 -0
- package/dist/validate-Bu_rkfQF.d.ts +686 -0
- package/dist/validate-CIMnzW8O.d.mts +685 -0
- package/package.json +11 -11
- package/src/api/tailwindcss-patcher.ts +33 -6
- package/src/commands/basic-handlers.ts +0 -1
- package/src/config/index.ts +1 -1
- package/src/config/workspace.ts +1 -1
- package/src/options/legacy.ts +2 -2
- package/src/options/normalize.ts +10 -5
- package/src/runtime/collector.ts +7 -7
- package/src/runtime/process-tailwindcss.ts +33 -17
- package/dist/chunk-4RRHMRLJ.js +0 -4378
- package/dist/chunk-AOSPLINO.mjs +0 -4378
- package/dist/chunk-OSH52QWA.mjs +0 -10
- package/dist/chunk-QQXAOMUH.js +0 -25
- package/dist/chunk-YYBY7EM5.mjs +0 -21
- package/dist/chunk-ZPLR2UEW.js +0 -7
- package/dist/dist-22YCNIJW.js +0 -269
- package/dist/dist-7W73GIRD.mjs +0 -269
- package/dist/validate-nbmOI2w8.d.mts +0 -677
- package/dist/validate-nbmOI2w8.d.ts +0 -677
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
const require_chunk = require("./chunk-8l464Juk.js");
|
|
2
|
+
let node_process = require("node:process");
|
|
3
|
+
node_process = require_chunk.__toESM(node_process, 1);
|
|
4
|
+
let defu = require("defu");
|
|
5
|
+
(0, defu.createDefu)((obj, key, value) => {
|
|
6
|
+
if (Array.isArray(obj[key]) && Array.isArray(value)) {
|
|
7
|
+
obj[key] = value;
|
|
8
|
+
return true;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
[
|
|
12
|
+
"ease-out",
|
|
13
|
+
"ease-linear",
|
|
14
|
+
"ease-in",
|
|
15
|
+
"ease-in-out"
|
|
16
|
+
].reduce((acc, cur) => {
|
|
17
|
+
acc[cur] = true;
|
|
18
|
+
return acc;
|
|
19
|
+
}, {});
|
|
20
|
+
//#endregion
|
|
21
|
+
exports.defu = defu.defu;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import "node:process";
|
|
2
|
+
import { createDefu, defu } from "defu";
|
|
3
|
+
createDefu((obj, key, value) => {
|
|
4
|
+
if (Array.isArray(obj[key]) && Array.isArray(value)) {
|
|
5
|
+
obj[key] = value;
|
|
6
|
+
return true;
|
|
7
|
+
}
|
|
8
|
+
});
|
|
9
|
+
[
|
|
10
|
+
"ease-out",
|
|
11
|
+
"ease-linear",
|
|
12
|
+
"ease-in",
|
|
13
|
+
"ease-in-out"
|
|
14
|
+
].reduce((acc, cur) => {
|
|
15
|
+
acc[cur] = true;
|
|
16
|
+
return acc;
|
|
17
|
+
}, {});
|
|
18
|
+
//#endregion
|
|
19
|
+
export { defu };
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
require("./chunk-8l464Juk.js");
|
|
2
|
+
require("./validate-B8H-8rWO.js");
|
|
3
|
+
//#region src/index.bundle.ts
|
|
4
|
+
const require$1 = (0, require("node:module").createRequire)(require("url").pathToFileURL(__filename).href);
|
|
5
|
+
function loadCliModule() {
|
|
6
|
+
return require$1("./commands/cli-runtime.js");
|
|
7
|
+
}
|
|
8
|
+
function mountTailwindcssPatchCommands(cli, options = {}) {
|
|
9
|
+
return loadCliModule().mountTailwindcssPatchCommands(cli, options);
|
|
10
|
+
}
|
|
11
|
+
function createTailwindcssPatchCli(options = {}) {
|
|
12
|
+
return loadCliModule().createTailwindcssPatchCli(options);
|
|
13
|
+
}
|
|
14
|
+
function defineConfig(config) {
|
|
15
|
+
return config;
|
|
16
|
+
}
|
|
17
|
+
//#endregion
|
|
18
|
+
Object.defineProperty(exports, "createTailwindcssPatchCli", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function() {
|
|
21
|
+
return createTailwindcssPatchCli;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
Object.defineProperty(exports, "defineConfig", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function() {
|
|
27
|
+
return defineConfig;
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
Object.defineProperty(exports, "mountTailwindcssPatchCommands", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function() {
|
|
33
|
+
return mountTailwindcssPatchCommands;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import "./validate-BI8356RT.mjs";
|
|
2
|
+
import { createRequire } from "node:module";
|
|
3
|
+
//#region src/index.bundle.ts
|
|
4
|
+
const require = createRequire(import.meta.url);
|
|
5
|
+
function loadCliModule() {
|
|
6
|
+
return require("./commands/cli-runtime.js");
|
|
7
|
+
}
|
|
8
|
+
function mountTailwindcssPatchCommands(cli, options = {}) {
|
|
9
|
+
return loadCliModule().mountTailwindcssPatchCommands(cli, options);
|
|
10
|
+
}
|
|
11
|
+
function createTailwindcssPatchCli(options = {}) {
|
|
12
|
+
return loadCliModule().createTailwindcssPatchCli(options);
|
|
13
|
+
}
|
|
14
|
+
function defineConfig(config) {
|
|
15
|
+
return config;
|
|
16
|
+
}
|
|
17
|
+
//#endregion
|
|
18
|
+
export { defineConfig as n, mountTailwindcssPatchCommands as r, createTailwindcssPatchCli as t };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,84 +1,85 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
import {
|
|
6
|
-
import postcss from 'postcss';
|
|
7
|
-
import '@tailwindcss/oxide';
|
|
8
|
-
import 'tailwindcss';
|
|
9
|
-
import 'consola';
|
|
10
|
-
|
|
11
|
-
declare function normalizeOptions(options?: TailwindCssPatchOptions): NormalizedTailwindCssPatchOptions;
|
|
1
|
+
import { $ as TailwindTokenFileKey, A as groupTokensByFile, B as TailwindCssOptions, C as MIGRATION_REPORT_SCHEMA_VERSION, D as extractRawCandidates, E as extractProjectCandidatesWithPositions, F as ExposeContextOptions, G as ExtractResult, H as TailwindV2Options, I as ExtendLengthUnitsOptions, J as PatchName, K as ILengthUnitsPatchOptions, L as ExtractOptions, M as ApplyOptions, N as CacheOptions, O as extractRawCandidatesWithPositions, P as CacheStrategy, Q as TailwindTokenByFileMap, R as NormalizedCacheOptions, S as MIGRATION_REPORT_KIND, T as TailwindcssPatcher, U as TailwindV3Options, V as TailwindCssPatchOptions, W as TailwindV4Options, X as PatchStatusReport, Y as PatchStatusEntry, Z as TailwindPatchRuntime, _ as ConfigFileMigrationEntry, a as ValidateFailureSummary, at as CacheClearResult, b as RestoreConfigFilesOptions, c as TailwindcssPatchCliMountOptions, ct as CacheContextMetadata, d as TailwindcssPatchCommandContext, dt as CacheReadResult, et as TailwindTokenLocation, f as TailwindcssPatchCommandHandler, g as tailwindcssPatchCommands, h as TailwindcssPatchCommandOptions, i as ValidateFailureReason, it as CacheClearOptions, j as normalizeOptions, k as extractValidCandidates, l as TailwindcssPatchCliOptions, lt as CacheIndexFileV2, m as TailwindcssPatchCommandOptionDefinition, n as VALIDATE_FAILURE_REASONS, nt as TailwindcssClassCache, o as ValidateJsonFailurePayload, ot as CacheClearScope, p as TailwindcssPatchCommandHandlerMap, q as PatchCheckStatus, r as ValidateCommandError, rt as TailwindcssRuntimeContext, s as ValidateJsonSuccessPayload, st as CacheContextDescriptor, t as VALIDATE_EXIT_CODES, tt as TailwindTokenReport, u as TailwindcssPatchCommand, ut as CacheReadMeta, v as ConfigFileMigrationReport, w as logger, x as RestoreConfigFilesResult, y as MigrateConfigFilesOptions, z as NormalizedTailwindCssPatchOptions } from "./validate-CIMnzW8O.mjs";
|
|
2
|
+
import { PackageInfo } from "local-pkg";
|
|
3
|
+
import postcss from "postcss";
|
|
4
|
+
import { CAC } from "cac";
|
|
5
|
+
import { TailwindcssMangleConfig } from "@tailwindcss-mangle/config";
|
|
12
6
|
|
|
7
|
+
//#region src/cache/store.d.ts
|
|
13
8
|
declare class CacheStore {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
9
|
+
private readonly options;
|
|
10
|
+
private readonly context?;
|
|
11
|
+
private readonly driver;
|
|
12
|
+
private readonly lockPath;
|
|
13
|
+
private memoryCache;
|
|
14
|
+
private memoryIndex;
|
|
15
|
+
private lastReadMeta;
|
|
16
|
+
constructor(options: NormalizedCacheOptions, context?: CacheContextDescriptor | undefined);
|
|
17
|
+
private isContextAware;
|
|
18
|
+
private createEmptyIndex;
|
|
19
|
+
private ensureDir;
|
|
20
|
+
private ensureDirSync;
|
|
21
|
+
private createTempPath;
|
|
22
|
+
private replaceCacheFile;
|
|
23
|
+
private replaceCacheFileSync;
|
|
24
|
+
private cleanupTempFile;
|
|
25
|
+
private cleanupTempFileSync;
|
|
26
|
+
private delay;
|
|
27
|
+
private acquireLock;
|
|
28
|
+
private releaseLockSyncOrAsync;
|
|
29
|
+
private acquireLockSync;
|
|
30
|
+
private withFileLock;
|
|
31
|
+
private withFileLockSync;
|
|
32
|
+
private normalizeContextEntry;
|
|
33
|
+
private normalizeIndexFile;
|
|
34
|
+
private readParsedCacheFile;
|
|
35
|
+
private readParsedCacheFileSync;
|
|
36
|
+
private findProjectMatch;
|
|
37
|
+
private writeIndexFile;
|
|
38
|
+
private writeIndexFileSync;
|
|
39
|
+
write(data: Set<string>): Promise<string | undefined>;
|
|
40
|
+
writeSync(data: Set<string>): string | undefined;
|
|
41
|
+
readWithMeta(): Promise<CacheReadResult>;
|
|
42
|
+
readWithMetaSync(): CacheReadResult;
|
|
43
|
+
read(): Promise<Set<string>>;
|
|
44
|
+
readSync(): Set<string>;
|
|
45
|
+
getLastReadMeta(): CacheReadMeta;
|
|
46
|
+
private countEntriesFromParsed;
|
|
47
|
+
clear(options?: CacheClearOptions): Promise<CacheClearResult>;
|
|
48
|
+
clearSync(options?: CacheClearOptions): CacheClearResult;
|
|
49
|
+
readIndexSnapshot(): CacheIndexFileV2 | undefined;
|
|
55
50
|
}
|
|
56
|
-
|
|
51
|
+
//#endregion
|
|
52
|
+
//#region src/commands/migrate-config.d.ts
|
|
57
53
|
declare function migrateConfigFiles(options: MigrateConfigFilesOptions): Promise<ConfigFileMigrationReport>;
|
|
58
54
|
declare function restoreConfigFiles(options: RestoreConfigFilesOptions): Promise<RestoreConfigFilesResult>;
|
|
59
|
-
|
|
55
|
+
//#endregion
|
|
56
|
+
//#region src/runtime/class-collector.d.ts
|
|
60
57
|
declare function collectClassesFromContexts(contexts: TailwindcssRuntimeContext[], filter: (className: string) => boolean): Set<string>;
|
|
61
58
|
declare function collectClassesFromTailwindV4(options: NormalizedTailwindCssPatchOptions): Promise<Set<string>>;
|
|
62
|
-
|
|
59
|
+
//#endregion
|
|
60
|
+
//#region src/runtime/context-registry.d.ts
|
|
63
61
|
declare function loadRuntimeContexts(packageInfo: PackageInfo, majorVersion: 2 | 3 | 4, refProperty: string): TailwindcssRuntimeContext[];
|
|
64
|
-
|
|
62
|
+
//#endregion
|
|
63
|
+
//#region src/runtime/process-tailwindcss.d.ts
|
|
65
64
|
interface TailwindBuildOptions {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
65
|
+
cwd: string;
|
|
66
|
+
config?: string;
|
|
67
|
+
majorVersion: 2 | 3 | 4;
|
|
68
|
+
postcssPlugin?: string;
|
|
70
69
|
}
|
|
71
70
|
declare function runTailwindBuild(options: TailwindBuildOptions): Promise<postcss.Result<postcss.Root>>;
|
|
72
|
-
|
|
71
|
+
//#endregion
|
|
72
|
+
//#region src/patching/status.d.ts
|
|
73
73
|
interface PatchStatusContext {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
74
|
+
packageInfo: PackageInfo;
|
|
75
|
+
options: NormalizedTailwindCssPatchOptions;
|
|
76
|
+
majorVersion: 2 | 3 | 4;
|
|
77
77
|
}
|
|
78
78
|
declare function getPatchStatusReport(context: PatchStatusContext): PatchStatusReport;
|
|
79
|
-
|
|
79
|
+
//#endregion
|
|
80
|
+
//#region src/index.bundle.d.ts
|
|
80
81
|
declare function mountTailwindcssPatchCommands(cli: CAC, options?: TailwindcssPatchCliMountOptions): CAC;
|
|
81
82
|
declare function createTailwindcssPatchCli(options?: TailwindcssPatchCliOptions): CAC;
|
|
82
83
|
declare function defineConfig<T extends TailwindcssMangleConfig>(config: T): T;
|
|
83
|
-
|
|
84
|
-
export { CacheClearOptions, CacheClearResult, CacheReadMeta, CacheStore, ConfigFileMigrationReport, MigrateConfigFilesOptions, NormalizedTailwindCssPatchOptions, PatchStatusReport, RestoreConfigFilesOptions, RestoreConfigFilesResult, TailwindCssPatchOptions, TailwindcssPatchCliMountOptions, TailwindcssPatchCliOptions, TailwindcssRuntimeContext, collectClassesFromContexts, collectClassesFromTailwindV4, createTailwindcssPatchCli, defineConfig, getPatchStatusReport, loadRuntimeContexts, migrateConfigFiles, mountTailwindcssPatchCommands, normalizeOptions, restoreConfigFiles, runTailwindBuild };
|
|
84
|
+
//#endregion
|
|
85
|
+
export { ApplyOptions, CacheClearOptions, CacheClearResult, CacheClearScope, CacheContextMetadata, CacheOptions, CacheReadMeta, CacheStore, CacheStrategy, type ConfigFileMigrationEntry, type ConfigFileMigrationReport, ExposeContextOptions, ExtendLengthUnitsOptions, ExtractOptions, ExtractResult, ILengthUnitsPatchOptions, MIGRATION_REPORT_KIND, MIGRATION_REPORT_SCHEMA_VERSION, type MigrateConfigFilesOptions, NormalizedTailwindCssPatchOptions, PatchCheckStatus, PatchName, PatchStatusEntry, PatchStatusReport, type RestoreConfigFilesOptions, type RestoreConfigFilesResult, TailwindCssOptions, type TailwindCssPatchOptions, TailwindPatchRuntime, TailwindTokenByFileMap, TailwindTokenFileKey, TailwindTokenLocation, TailwindTokenReport, TailwindV2Options, TailwindV3Options, TailwindV4Options, TailwindcssClassCache, type TailwindcssPatchCliMountOptions, type TailwindcssPatchCliOptions, type TailwindcssPatchCommand, type TailwindcssPatchCommandContext, type TailwindcssPatchCommandHandler, type TailwindcssPatchCommandHandlerMap, type TailwindcssPatchCommandOptionDefinition, type TailwindcssPatchCommandOptions, TailwindcssPatcher, TailwindcssRuntimeContext, VALIDATE_EXIT_CODES, VALIDATE_FAILURE_REASONS, ValidateCommandError, type ValidateFailureReason, type ValidateFailureSummary, type ValidateJsonFailurePayload, type ValidateJsonSuccessPayload, collectClassesFromContexts, collectClassesFromTailwindV4, createTailwindcssPatchCli, defineConfig, extractProjectCandidatesWithPositions, extractRawCandidates, extractRawCandidatesWithPositions, extractValidCandidates, getPatchStatusReport, groupTokensByFile, loadRuntimeContexts, logger, migrateConfigFiles, mountTailwindcssPatchCommands, normalizeOptions, restoreConfigFiles, runTailwindBuild, tailwindcssPatchCommands };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,84 +1,85 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { CAC } from
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
import {
|
|
6
|
-
import postcss from 'postcss';
|
|
7
|
-
import '@tailwindcss/oxide';
|
|
8
|
-
import 'tailwindcss';
|
|
9
|
-
import 'consola';
|
|
10
|
-
|
|
11
|
-
declare function normalizeOptions(options?: TailwindCssPatchOptions): NormalizedTailwindCssPatchOptions;
|
|
1
|
+
import { $ as TailwindTokenFileKey, A as groupTokensByFile, B as TailwindCssOptions, C as MIGRATION_REPORT_SCHEMA_VERSION, D as extractRawCandidates, E as extractProjectCandidatesWithPositions, F as ExposeContextOptions, G as ExtractResult, H as TailwindV2Options, I as ExtendLengthUnitsOptions, J as PatchName, K as ILengthUnitsPatchOptions, L as ExtractOptions, M as ApplyOptions, N as CacheOptions, O as extractRawCandidatesWithPositions, P as CacheStrategy, Q as TailwindTokenByFileMap, R as NormalizedCacheOptions, S as MIGRATION_REPORT_KIND, T as TailwindcssPatcher, U as TailwindV3Options, V as TailwindCssPatchOptions, W as TailwindV4Options, X as PatchStatusReport, Y as PatchStatusEntry, Z as TailwindPatchRuntime, _ as ConfigFileMigrationEntry, a as ValidateFailureSummary, at as CacheClearResult, b as RestoreConfigFilesOptions, c as TailwindcssPatchCliMountOptions, ct as CacheContextMetadata, d as TailwindcssPatchCommandContext, dt as CacheReadResult, et as TailwindTokenLocation, f as TailwindcssPatchCommandHandler, g as tailwindcssPatchCommands, h as TailwindcssPatchCommandOptions, i as ValidateFailureReason, it as CacheClearOptions, j as normalizeOptions, k as extractValidCandidates, l as TailwindcssPatchCliOptions, lt as CacheIndexFileV2, m as TailwindcssPatchCommandOptionDefinition, n as VALIDATE_FAILURE_REASONS, nt as TailwindcssClassCache, o as ValidateJsonFailurePayload, ot as CacheClearScope, p as TailwindcssPatchCommandHandlerMap, q as PatchCheckStatus, r as ValidateCommandError, rt as TailwindcssRuntimeContext, s as ValidateJsonSuccessPayload, st as CacheContextDescriptor, t as VALIDATE_EXIT_CODES, tt as TailwindTokenReport, u as TailwindcssPatchCommand, ut as CacheReadMeta, v as ConfigFileMigrationReport, w as logger, x as RestoreConfigFilesResult, y as MigrateConfigFilesOptions, z as NormalizedTailwindCssPatchOptions } from "./validate-Bu_rkfQF.js";
|
|
2
|
+
import { CAC } from "cac";
|
|
3
|
+
import { PackageInfo } from "local-pkg";
|
|
4
|
+
import postcss from "postcss";
|
|
5
|
+
import { TailwindcssMangleConfig } from "@tailwindcss-mangle/config";
|
|
12
6
|
|
|
7
|
+
//#region src/cache/store.d.ts
|
|
13
8
|
declare class CacheStore {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
9
|
+
private readonly options;
|
|
10
|
+
private readonly context?;
|
|
11
|
+
private readonly driver;
|
|
12
|
+
private readonly lockPath;
|
|
13
|
+
private memoryCache;
|
|
14
|
+
private memoryIndex;
|
|
15
|
+
private lastReadMeta;
|
|
16
|
+
constructor(options: NormalizedCacheOptions, context?: CacheContextDescriptor | undefined);
|
|
17
|
+
private isContextAware;
|
|
18
|
+
private createEmptyIndex;
|
|
19
|
+
private ensureDir;
|
|
20
|
+
private ensureDirSync;
|
|
21
|
+
private createTempPath;
|
|
22
|
+
private replaceCacheFile;
|
|
23
|
+
private replaceCacheFileSync;
|
|
24
|
+
private cleanupTempFile;
|
|
25
|
+
private cleanupTempFileSync;
|
|
26
|
+
private delay;
|
|
27
|
+
private acquireLock;
|
|
28
|
+
private releaseLockSyncOrAsync;
|
|
29
|
+
private acquireLockSync;
|
|
30
|
+
private withFileLock;
|
|
31
|
+
private withFileLockSync;
|
|
32
|
+
private normalizeContextEntry;
|
|
33
|
+
private normalizeIndexFile;
|
|
34
|
+
private readParsedCacheFile;
|
|
35
|
+
private readParsedCacheFileSync;
|
|
36
|
+
private findProjectMatch;
|
|
37
|
+
private writeIndexFile;
|
|
38
|
+
private writeIndexFileSync;
|
|
39
|
+
write(data: Set<string>): Promise<string | undefined>;
|
|
40
|
+
writeSync(data: Set<string>): string | undefined;
|
|
41
|
+
readWithMeta(): Promise<CacheReadResult>;
|
|
42
|
+
readWithMetaSync(): CacheReadResult;
|
|
43
|
+
read(): Promise<Set<string>>;
|
|
44
|
+
readSync(): Set<string>;
|
|
45
|
+
getLastReadMeta(): CacheReadMeta;
|
|
46
|
+
private countEntriesFromParsed;
|
|
47
|
+
clear(options?: CacheClearOptions): Promise<CacheClearResult>;
|
|
48
|
+
clearSync(options?: CacheClearOptions): CacheClearResult;
|
|
49
|
+
readIndexSnapshot(): CacheIndexFileV2 | undefined;
|
|
55
50
|
}
|
|
56
|
-
|
|
51
|
+
//#endregion
|
|
52
|
+
//#region src/commands/migrate-config.d.ts
|
|
57
53
|
declare function migrateConfigFiles(options: MigrateConfigFilesOptions): Promise<ConfigFileMigrationReport>;
|
|
58
54
|
declare function restoreConfigFiles(options: RestoreConfigFilesOptions): Promise<RestoreConfigFilesResult>;
|
|
59
|
-
|
|
55
|
+
//#endregion
|
|
56
|
+
//#region src/runtime/class-collector.d.ts
|
|
60
57
|
declare function collectClassesFromContexts(contexts: TailwindcssRuntimeContext[], filter: (className: string) => boolean): Set<string>;
|
|
61
58
|
declare function collectClassesFromTailwindV4(options: NormalizedTailwindCssPatchOptions): Promise<Set<string>>;
|
|
62
|
-
|
|
59
|
+
//#endregion
|
|
60
|
+
//#region src/runtime/context-registry.d.ts
|
|
63
61
|
declare function loadRuntimeContexts(packageInfo: PackageInfo, majorVersion: 2 | 3 | 4, refProperty: string): TailwindcssRuntimeContext[];
|
|
64
|
-
|
|
62
|
+
//#endregion
|
|
63
|
+
//#region src/runtime/process-tailwindcss.d.ts
|
|
65
64
|
interface TailwindBuildOptions {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
65
|
+
cwd: string;
|
|
66
|
+
config?: string;
|
|
67
|
+
majorVersion: 2 | 3 | 4;
|
|
68
|
+
postcssPlugin?: string;
|
|
70
69
|
}
|
|
71
70
|
declare function runTailwindBuild(options: TailwindBuildOptions): Promise<postcss.Result<postcss.Root>>;
|
|
72
|
-
|
|
71
|
+
//#endregion
|
|
72
|
+
//#region src/patching/status.d.ts
|
|
73
73
|
interface PatchStatusContext {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
74
|
+
packageInfo: PackageInfo;
|
|
75
|
+
options: NormalizedTailwindCssPatchOptions;
|
|
76
|
+
majorVersion: 2 | 3 | 4;
|
|
77
77
|
}
|
|
78
78
|
declare function getPatchStatusReport(context: PatchStatusContext): PatchStatusReport;
|
|
79
|
-
|
|
79
|
+
//#endregion
|
|
80
|
+
//#region src/index.bundle.d.ts
|
|
80
81
|
declare function mountTailwindcssPatchCommands(cli: CAC, options?: TailwindcssPatchCliMountOptions): CAC;
|
|
81
82
|
declare function createTailwindcssPatchCli(options?: TailwindcssPatchCliOptions): CAC;
|
|
82
83
|
declare function defineConfig<T extends TailwindcssMangleConfig>(config: T): T;
|
|
83
|
-
|
|
84
|
-
export { CacheClearOptions, CacheClearResult, CacheReadMeta, CacheStore, ConfigFileMigrationReport, MigrateConfigFilesOptions, NormalizedTailwindCssPatchOptions, PatchStatusReport, RestoreConfigFilesOptions, RestoreConfigFilesResult, TailwindCssPatchOptions, TailwindcssPatchCliMountOptions, TailwindcssPatchCliOptions, TailwindcssRuntimeContext, collectClassesFromContexts, collectClassesFromTailwindV4, createTailwindcssPatchCli, defineConfig, getPatchStatusReport, loadRuntimeContexts, migrateConfigFiles, mountTailwindcssPatchCommands, normalizeOptions, restoreConfigFiles, runTailwindBuild };
|
|
84
|
+
//#endregion
|
|
85
|
+
export { ApplyOptions, CacheClearOptions, CacheClearResult, CacheClearScope, CacheContextMetadata, CacheOptions, CacheReadMeta, CacheStore, CacheStrategy, type ConfigFileMigrationEntry, type ConfigFileMigrationReport, ExposeContextOptions, ExtendLengthUnitsOptions, ExtractOptions, ExtractResult, ILengthUnitsPatchOptions, MIGRATION_REPORT_KIND, MIGRATION_REPORT_SCHEMA_VERSION, type MigrateConfigFilesOptions, NormalizedTailwindCssPatchOptions, PatchCheckStatus, PatchName, PatchStatusEntry, PatchStatusReport, type RestoreConfigFilesOptions, type RestoreConfigFilesResult, TailwindCssOptions, type TailwindCssPatchOptions, TailwindPatchRuntime, TailwindTokenByFileMap, TailwindTokenFileKey, TailwindTokenLocation, TailwindTokenReport, TailwindV2Options, TailwindV3Options, TailwindV4Options, TailwindcssClassCache, type TailwindcssPatchCliMountOptions, type TailwindcssPatchCliOptions, type TailwindcssPatchCommand, type TailwindcssPatchCommandContext, type TailwindcssPatchCommandHandler, type TailwindcssPatchCommandHandlerMap, type TailwindcssPatchCommandOptionDefinition, type TailwindcssPatchCommandOptions, TailwindcssPatcher, TailwindcssRuntimeContext, VALIDATE_EXIT_CODES, VALIDATE_FAILURE_REASONS, ValidateCommandError, type ValidateFailureReason, type ValidateFailureSummary, type ValidateJsonFailurePayload, type ValidateJsonSuccessPayload, collectClassesFromContexts, collectClassesFromTailwindV4, createTailwindcssPatchCli, defineConfig, extractProjectCandidatesWithPositions, extractRawCandidates, extractRawCandidatesWithPositions, extractValidCandidates, getPatchStatusReport, groupTokensByFile, loadRuntimeContexts, logger, migrateConfigFiles, mountTailwindcssPatchCommands, normalizeOptions, restoreConfigFiles, runTailwindBuild, tailwindcssPatchCommands };
|
package/dist/index.js
CHANGED
|
@@ -1,57 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
var _chunk4RRHMRLJjs = require('./chunk-4RRHMRLJ.js');
|
|
30
|
-
require('./chunk-ZPLR2UEW.js');
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
exports.CacheStore = _chunk4RRHMRLJjs.CacheStore; exports.MIGRATION_REPORT_KIND = _chunk4RRHMRLJjs.MIGRATION_REPORT_KIND; exports.MIGRATION_REPORT_SCHEMA_VERSION = _chunk4RRHMRLJjs.MIGRATION_REPORT_SCHEMA_VERSION; exports.TailwindcssPatcher = _chunk4RRHMRLJjs.TailwindcssPatcher; exports.VALIDATE_EXIT_CODES = _chunk4RRHMRLJjs.VALIDATE_EXIT_CODES; exports.VALIDATE_FAILURE_REASONS = _chunk4RRHMRLJjs.VALIDATE_FAILURE_REASONS; exports.ValidateCommandError = _chunk4RRHMRLJjs.ValidateCommandError; exports.collectClassesFromContexts = _chunk4RRHMRLJjs.collectClassesFromContexts; exports.collectClassesFromTailwindV4 = _chunk4RRHMRLJjs.collectClassesFromTailwindV4; exports.createTailwindcssPatchCli = _chunkQQXAOMUHjs.createTailwindcssPatchCli; exports.defineConfig = _chunkQQXAOMUHjs.defineConfig; exports.extractProjectCandidatesWithPositions = _chunk4RRHMRLJjs.extractProjectCandidatesWithPositions; exports.extractRawCandidates = _chunk4RRHMRLJjs.extractRawCandidates; exports.extractRawCandidatesWithPositions = _chunk4RRHMRLJjs.extractRawCandidatesWithPositions; exports.extractValidCandidates = _chunk4RRHMRLJjs.extractValidCandidates; exports.getPatchStatusReport = _chunk4RRHMRLJjs.getPatchStatusReport; exports.groupTokensByFile = _chunk4RRHMRLJjs.groupTokensByFile; exports.loadRuntimeContexts = _chunk4RRHMRLJjs.loadRuntimeContexts; exports.logger = _chunk4RRHMRLJjs.logger_default; exports.migrateConfigFiles = _chunk4RRHMRLJjs.migrateConfigFiles; exports.mountTailwindcssPatchCommands = _chunkQQXAOMUHjs.mountTailwindcssPatchCommands; exports.normalizeOptions = _chunk4RRHMRLJjs.normalizeOptions; exports.restoreConfigFiles = _chunk4RRHMRLJjs.restoreConfigFiles; exports.runTailwindBuild = _chunk4RRHMRLJjs.runTailwindBuild; exports.tailwindcssPatchCommands = _chunk4RRHMRLJjs.tailwindcssPatchCommands;
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_validate = require("./validate-B8H-8rWO.js");
|
|
3
|
+
const require_index_bundle = require("./index.bundle-BGBMTX9A.js");
|
|
4
|
+
exports.CacheStore = require_validate.CacheStore;
|
|
5
|
+
exports.MIGRATION_REPORT_KIND = require_validate.MIGRATION_REPORT_KIND;
|
|
6
|
+
exports.MIGRATION_REPORT_SCHEMA_VERSION = require_validate.MIGRATION_REPORT_SCHEMA_VERSION;
|
|
7
|
+
exports.TailwindcssPatcher = require_validate.TailwindcssPatcher;
|
|
8
|
+
exports.VALIDATE_EXIT_CODES = require_validate.VALIDATE_EXIT_CODES;
|
|
9
|
+
exports.VALIDATE_FAILURE_REASONS = require_validate.VALIDATE_FAILURE_REASONS;
|
|
10
|
+
exports.ValidateCommandError = require_validate.ValidateCommandError;
|
|
11
|
+
exports.collectClassesFromContexts = require_validate.collectClassesFromContexts;
|
|
12
|
+
exports.collectClassesFromTailwindV4 = require_validate.collectClassesFromTailwindV4;
|
|
13
|
+
exports.createTailwindcssPatchCli = require_index_bundle.createTailwindcssPatchCli;
|
|
14
|
+
exports.defineConfig = require_index_bundle.defineConfig;
|
|
15
|
+
exports.extractProjectCandidatesWithPositions = require_validate.extractProjectCandidatesWithPositions;
|
|
16
|
+
exports.extractRawCandidates = require_validate.extractRawCandidates;
|
|
17
|
+
exports.extractRawCandidatesWithPositions = require_validate.extractRawCandidatesWithPositions;
|
|
18
|
+
exports.extractValidCandidates = require_validate.extractValidCandidates;
|
|
19
|
+
exports.getPatchStatusReport = require_validate.getPatchStatusReport;
|
|
20
|
+
exports.groupTokensByFile = require_validate.groupTokensByFile;
|
|
21
|
+
exports.loadRuntimeContexts = require_validate.loadRuntimeContexts;
|
|
22
|
+
exports.logger = require_validate.logger;
|
|
23
|
+
exports.migrateConfigFiles = require_validate.migrateConfigFiles;
|
|
24
|
+
exports.mountTailwindcssPatchCommands = require_index_bundle.mountTailwindcssPatchCommands;
|
|
25
|
+
exports.normalizeOptions = require_validate.normalizeOptions;
|
|
26
|
+
exports.restoreConfigFiles = require_validate.restoreConfigFiles;
|
|
27
|
+
exports.runTailwindBuild = require_validate.runTailwindBuild;
|
|
28
|
+
exports.tailwindcssPatchCommands = require_validate.tailwindcssPatchCommands;
|
package/dist/index.mjs
CHANGED
|
@@ -1,57 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
mountTailwindcssPatchCommands
|
|
5
|
-
} from "./chunk-YYBY7EM5.mjs";
|
|
6
|
-
import {
|
|
7
|
-
CacheStore,
|
|
8
|
-
MIGRATION_REPORT_KIND,
|
|
9
|
-
MIGRATION_REPORT_SCHEMA_VERSION,
|
|
10
|
-
TailwindcssPatcher,
|
|
11
|
-
VALIDATE_EXIT_CODES,
|
|
12
|
-
VALIDATE_FAILURE_REASONS,
|
|
13
|
-
ValidateCommandError,
|
|
14
|
-
collectClassesFromContexts,
|
|
15
|
-
collectClassesFromTailwindV4,
|
|
16
|
-
extractProjectCandidatesWithPositions,
|
|
17
|
-
extractRawCandidates,
|
|
18
|
-
extractRawCandidatesWithPositions,
|
|
19
|
-
extractValidCandidates,
|
|
20
|
-
getPatchStatusReport,
|
|
21
|
-
groupTokensByFile,
|
|
22
|
-
loadRuntimeContexts,
|
|
23
|
-
logger_default,
|
|
24
|
-
migrateConfigFiles,
|
|
25
|
-
normalizeOptions,
|
|
26
|
-
restoreConfigFiles,
|
|
27
|
-
runTailwindBuild,
|
|
28
|
-
tailwindcssPatchCommands
|
|
29
|
-
} from "./chunk-AOSPLINO.mjs";
|
|
30
|
-
import "./chunk-OSH52QWA.mjs";
|
|
31
|
-
export {
|
|
32
|
-
CacheStore,
|
|
33
|
-
MIGRATION_REPORT_KIND,
|
|
34
|
-
MIGRATION_REPORT_SCHEMA_VERSION,
|
|
35
|
-
TailwindcssPatcher,
|
|
36
|
-
VALIDATE_EXIT_CODES,
|
|
37
|
-
VALIDATE_FAILURE_REASONS,
|
|
38
|
-
ValidateCommandError,
|
|
39
|
-
collectClassesFromContexts,
|
|
40
|
-
collectClassesFromTailwindV4,
|
|
41
|
-
createTailwindcssPatchCli,
|
|
42
|
-
defineConfig,
|
|
43
|
-
extractProjectCandidatesWithPositions,
|
|
44
|
-
extractRawCandidates,
|
|
45
|
-
extractRawCandidatesWithPositions,
|
|
46
|
-
extractValidCandidates,
|
|
47
|
-
getPatchStatusReport,
|
|
48
|
-
groupTokensByFile,
|
|
49
|
-
loadRuntimeContexts,
|
|
50
|
-
logger_default as logger,
|
|
51
|
-
migrateConfigFiles,
|
|
52
|
-
mountTailwindcssPatchCommands,
|
|
53
|
-
normalizeOptions,
|
|
54
|
-
restoreConfigFiles,
|
|
55
|
-
runTailwindBuild,
|
|
56
|
-
tailwindcssPatchCommands
|
|
57
|
-
};
|
|
1
|
+
import { C as normalizeOptions, T as logger, _ as extractRawCandidates, a as tailwindcssPatchCommands, b as groupTokensByFile, c as MIGRATION_REPORT_KIND, d as getPatchStatusReport, f as runTailwindBuild, g as extractProjectCandidatesWithPositions, h as collectClassesFromTailwindV4, l as MIGRATION_REPORT_SCHEMA_VERSION, m as collectClassesFromContexts, n as VALIDATE_FAILURE_REASONS, o as migrateConfigFiles, p as loadRuntimeContexts, r as ValidateCommandError, s as restoreConfigFiles, t as VALIDATE_EXIT_CODES, u as TailwindcssPatcher, v as extractRawCandidatesWithPositions, w as CacheStore, y as extractValidCandidates } from "./validate-BI8356RT.mjs";
|
|
2
|
+
import { n as defineConfig, r as mountTailwindcssPatchCommands, t as createTailwindcssPatchCli } from "./index.bundle-ByrTqrr3.mjs";
|
|
3
|
+
export { CacheStore, MIGRATION_REPORT_KIND, MIGRATION_REPORT_SCHEMA_VERSION, TailwindcssPatcher, VALIDATE_EXIT_CODES, VALIDATE_FAILURE_REASONS, ValidateCommandError, collectClassesFromContexts, collectClassesFromTailwindV4, createTailwindcssPatchCli, defineConfig, extractProjectCandidatesWithPositions, extractRawCandidates, extractRawCandidatesWithPositions, extractValidCandidates, getPatchStatusReport, groupTokensByFile, loadRuntimeContexts, logger, migrateConfigFiles, mountTailwindcssPatchCommands, normalizeOptions, restoreConfigFiles, runTailwindBuild, tailwindcssPatchCommands };
|