@animus-ui/extract 0.1.11 → 0.1.12
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/README.md +47 -0
- package/crates/extract-v2/animus-extract-v2.darwin-arm64.node +0 -0
- package/crates/extract-v2/animus-extract-v2.linux-arm64-gnu.node +0 -0
- package/crates/extract-v2/animus-extract-v2.linux-x64-gnu.node +0 -0
- package/crates/extract-v2/index.d.ts +17 -98
- package/dist/index.cjs +11 -6
- package/dist/index.mjs +2 -2
- package/dist/pipeline/analyze-project-args.d.ts +0 -12
- package/dist/pipeline/analyze-project-args.d.ts.map +1 -1
- package/dist/pipeline/assemble-stylesheet.d.ts +0 -35
- package/dist/pipeline/assemble-stylesheet.d.ts.map +1 -1
- package/dist/pipeline/asset-placeholders.d.ts +0 -25
- package/dist/pipeline/asset-placeholders.d.ts.map +1 -1
- package/dist/pipeline/content-hash.d.ts +0 -7
- package/dist/pipeline/content-hash.d.ts.map +1 -1
- package/dist/pipeline/core-options.d.ts +27 -93
- package/dist/pipeline/core-options.d.ts.map +1 -1
- package/dist/pipeline/correlate-external-tokens.d.ts +10 -18
- package/dist/pipeline/correlate-external-tokens.d.ts.map +1 -1
- package/dist/pipeline/discover-files.d.ts +1 -9
- package/dist/pipeline/discover-files.d.ts.map +1 -1
- package/dist/pipeline/discover-packages.d.ts +18 -154
- package/dist/pipeline/discover-packages.d.ts.map +1 -1
- package/dist/pipeline/dynamic-prop-config.d.ts +4 -19
- package/dist/pipeline/dynamic-prop-config.d.ts.map +1 -1
- package/dist/pipeline/engine-adapter.d.ts +16 -52
- package/dist/pipeline/engine-adapter.d.ts.map +1 -1
- package/dist/pipeline/engine-retirement.d.ts +0 -19
- package/dist/pipeline/engine-retirement.d.ts.map +1 -1
- package/dist/pipeline/error-diagnostics.d.ts +0 -24
- package/dist/pipeline/error-diagnostics.d.ts.map +1 -1
- package/dist/pipeline/index.d.ts +9 -8
- package/dist/pipeline/index.d.ts.map +1 -1
- package/dist/pipeline/internal-wire.d.ts +2 -0
- package/dist/pipeline/internal-wire.d.ts.map +1 -0
- package/dist/pipeline/manifest-diagnostics.d.ts +32 -37
- package/dist/pipeline/manifest-diagnostics.d.ts.map +1 -1
- package/dist/pipeline/manifest-schema.d.ts +117 -0
- package/dist/pipeline/manifest-schema.d.ts.map +1 -0
- package/dist/pipeline/mdx-preprocessor.d.ts +9 -33
- package/dist/pipeline/mdx-preprocessor.d.ts.map +1 -1
- package/dist/pipeline/path-aliases.d.ts +0 -19
- package/dist/pipeline/path-aliases.d.ts.map +1 -1
- package/dist/pipeline/post-process-css.d.ts +0 -8
- package/dist/pipeline/post-process-css.d.ts.map +1 -1
- package/dist/pipeline/prefix.d.ts +3 -10
- package/dist/pipeline/prefix.d.ts.map +1 -1
- package/dist/pipeline/replacement-plans.d.ts +10 -34
- package/dist/pipeline/replacement-plans.d.ts.map +1 -1
- package/dist/pipeline/resolve-asset.d.ts +4 -7
- package/dist/pipeline/resolve-asset.d.ts.map +1 -1
- package/dist/pipeline/run-analysis.d.ts +15 -27
- package/dist/pipeline/run-analysis.d.ts.map +1 -1
- package/dist/pipeline/source-corpus.d.ts +25 -0
- package/dist/pipeline/source-corpus.d.ts.map +1 -0
- package/dist/pipeline/source-identity.d.ts +23 -53
- package/dist/pipeline/source-identity.d.ts.map +1 -1
- package/dist/pipeline/source-ingestion.d.ts +48 -53
- package/dist/pipeline/source-ingestion.d.ts.map +1 -1
- package/dist/pipeline/static-css.d.ts +4 -13
- package/dist/pipeline/static-css.d.ts.map +1 -1
- package/dist/pipeline/structural-self-check.d.ts +0 -20
- package/dist/pipeline/structural-self-check.d.ts.map +1 -1
- package/dist/pipeline/svelte-source-adapter.d.ts +5 -12
- package/dist/pipeline/svelte-source-adapter.d.ts.map +1 -1
- package/dist/pipeline/system-config.d.ts +15 -32
- package/dist/pipeline/system-config.d.ts.map +1 -1
- package/dist/pipeline/system-props-module.d.ts +0 -15
- package/dist/pipeline/system-props-module.d.ts.map +1 -1
- package/dist/pipeline/timing-waterfall.d.ts +0 -11
- package/dist/pipeline/timing-waterfall.d.ts.map +1 -1
- package/dist/pipeline/tsconfig-paths.d.ts +2 -3
- package/dist/pipeline/tsconfig-paths.d.ts.map +1 -1
- package/dist/pipeline/unit-fallback.d.ts +0 -5
- package/dist/pipeline/unit-fallback.d.ts.map +1 -1
- package/dist/pipeline/utils.d.ts +1 -1
- package/dist/pipeline/utils.d.ts.map +1 -1
- package/dist/pipeline/watch-keys.d.ts +0 -10
- package/dist/pipeline/watch-keys.d.ts.map +1 -1
- package/dist/{pipeline-lkbOoyAr.mjs → pipeline-DeEENy5C.mjs} +1940 -2263
- package/dist/{pipeline-ojNeABi0.cjs → pipeline-x1yBZ2UP.cjs} +1970 -2269
- package/dist/session/extraction-session.d.ts +110 -316
- package/dist/session/extraction-session.d.ts.map +1 -1
- package/dist/session/index.d.ts +6 -20
- package/dist/session/index.d.ts.map +1 -1
- package/dist/session/published-set.d.ts +45 -25
- package/dist/session/published-set.d.ts.map +1 -1
- package/dist/session/resolve-packages.d.ts +6 -7
- package/dist/session/resolve-packages.d.ts.map +1 -1
- package/dist/session/session-paths.d.ts +38 -72
- package/dist/session/session-paths.d.ts.map +1 -1
- package/dist/session/singleton.d.ts +32 -71
- package/dist/session/singleton.d.ts.map +1 -1
- package/dist/session/timing.d.ts +0 -5
- package/dist/session/timing.d.ts.map +1 -1
- package/dist/session/turbopack-orchestrator.d.ts +17 -33
- package/dist/session/turbopack-orchestrator.d.ts.map +1 -1
- package/dist/session.cjs +530 -677
- package/dist/session.mjs +517 -672
- package/index-v2.js +0 -9
- package/package.json +9 -8
- package/dist/pipeline/external-keyframes.d.ts +0 -23
- package/dist/pipeline/external-keyframes.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../session/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["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9
|
-
*
|
|
10
|
-
* legitimately published set was classified as debris.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
* Recompute every payload hash recorded in the directory's commit record
|
|
14
|
-
* and compare — raw bytes on both sides, matching the writer's hashing
|
|
15
|
-
* domain. Returns failure lines; empty means the set verifies. An absent
|
|
16
|
-
* or unparsable record is itself a failure (the record is written LAST, so
|
|
17
|
-
* a torn or aborted publish cannot verify).
|
|
18
|
-
*/
|
|
1
|
+
export interface CommitRecord {
|
|
2
|
+
schema: 1;
|
|
3
|
+
payloads: Record<string, {
|
|
4
|
+
hash: string;
|
|
5
|
+
}>;
|
|
6
|
+
}
|
|
7
|
+
export declare function decodeCommitRecord(bytes: string): CommitRecord | null;
|
|
8
|
+
/** Recompute every recorded payload hash over raw bytes — the writer's own
|
|
9
|
+
* hashing domain — and return the mismatches; empty means the set verifies. */
|
|
19
10
|
export declare function verifyCommitRecord(dir: string): string[];
|
|
20
|
-
|
|
11
|
+
export interface CliLockRecord {
|
|
12
|
+
pid: number;
|
|
13
|
+
startedAt?: string;
|
|
14
|
+
heartbeatAt?: string;
|
|
15
|
+
}
|
|
16
|
+
export declare const CLI_LOCK_HEARTBEAT_INTERVAL_MS = 60000;
|
|
17
|
+
/** A claim whose heartbeat is older than this has no live holder. Five missed
|
|
18
|
+
* refreshes: synchronous extraction can block the holder's refresh timer. */
|
|
19
|
+
export declare const CLI_LOCK_STALE_AFTER_MS: number;
|
|
20
|
+
export type CliLockLiveness = {
|
|
21
|
+
live: true;
|
|
22
|
+
} | {
|
|
23
|
+
live: false;
|
|
24
|
+
reason: string;
|
|
25
|
+
};
|
|
26
|
+
export type CliLockRead = {
|
|
27
|
+
kind: 'none';
|
|
28
|
+
} | {
|
|
29
|
+
kind: 'held';
|
|
30
|
+
record: CliLockRecord;
|
|
31
|
+
} | {
|
|
32
|
+
kind: 'indeterminate';
|
|
33
|
+
};
|
|
34
|
+
export declare function readCliLockRecord(dir: string): CliLockRead;
|
|
35
|
+
export declare function isLockHolderAlive(pid: number): boolean;
|
|
36
|
+
export declare function checkLockLiveness(record: CliLockRecord): CliLockLiveness;
|
|
37
|
+
export declare function lockRecordBytes(startedAt: string): string;
|
|
38
|
+
export interface DirectoryClaimOptions {
|
|
39
|
+
/** `in-place` (default) keeps a watched directory's mtime still — renaming
|
|
40
|
+
* every interval starts phantom rebuilds; `rename` avoids torn reads. */
|
|
41
|
+
write?: 'in-place' | 'rename';
|
|
42
|
+
startedAt?: string;
|
|
43
|
+
}
|
|
44
|
+
export declare function holdDirectoryClaim(dir: string, options?: DirectoryClaimOptions): () => void;
|
|
21
45
|
export interface SessionAsset {
|
|
22
46
|
name: string;
|
|
23
47
|
bytes: Buffer;
|
|
24
48
|
}
|
|
25
|
-
/**
|
|
26
|
-
*
|
|
27
|
-
* BEFORE the session tree is disposed. The emitted stylesheet references
|
|
28
|
-
* them as `./assets/<name>`, so every driver must publish them beside its
|
|
29
|
-
* stylesheet or the urls dangle.
|
|
30
|
-
*/
|
|
49
|
+
/** Snapshot the session's copied asset() files, sorted, BEFORE the session
|
|
50
|
+
* tree is disposed. Drivers publish them beside the emitted stylesheet. */
|
|
31
51
|
export declare function collectSessionAssets(sessionDir: string | null): SessionAsset[];
|
|
32
52
|
//# sourceMappingURL=published-set.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"published-set.d.ts","sourceRoot":"","sources":["../../session/published-set.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"published-set.d.ts","sourceRoot":"","sources":["../../session/published-set.ts"],"names":[],"mappings":"AA2CA,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,CAAC,CAAC;IACV,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC5C;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,YAAY,GAAG,IAAI,CAiBrE;AAED;gFACgF;AAChF,wBAA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,oBAAoB,CAClC,UAAU,EAAE,MAAM,GAAG,IAAI,GACxB,YAAY,EAAE,CAOhB"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export declare function resolvePackagesByName(rootDir: string, names: string[]): Record<string, string>;
|
|
1
|
+
/** Package specifier → rootDir-relative entry path. An unresolved specifier
|
|
2
|
+
* has no key at all, never a key with an empty target. */
|
|
3
|
+
export interface ResolvedPackageMap {
|
|
4
|
+
[specifier: string]: string;
|
|
5
|
+
}
|
|
6
|
+
export declare function resolvePackagesByName(rootDir: string, names: string[]): ResolvedPackageMap;
|
|
8
7
|
//# sourceMappingURL=resolve-packages.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-packages.d.ts","sourceRoot":"","sources":["../../session/resolve-packages.ts"],"names":[],"mappings":"AAGA
|
|
1
|
+
{"version":3,"file":"resolve-packages.d.ts","sourceRoot":"","sources":["../../session/resolve-packages.ts"],"names":[],"mappings":"AAGA;2DAC2D;AAC3D,MAAM,WAAW,kBAAkB;IACjC,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAAC;CAC7B;AAED,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,MAAM,EACf,KAAK,EAAE,MAAM,EAAE,GACd,kBAAkB,CA8CpB"}
|
|
@@ -1,30 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Session
|
|
3
|
-
*
|
|
4
|
-
* — shared by the session writer (extraction-session), the webpack
|
|
5
|
-
* plugin/loader, and the Turbopack loader.
|
|
6
|
-
*
|
|
7
|
-
* Deliberately free of singleton/session imports: the Turbopack loader
|
|
8
|
-
* executes in isolated worker processes and its module graph must stay
|
|
9
|
-
* worker-local (guardrail G1) — this module is pure path/shape vocabulary.
|
|
2
|
+
* Session artifact names, path derivations, and artifact shapes. Imports no
|
|
3
|
+
* session or singleton module: the Turbopack loader graph stays worker-local.
|
|
10
4
|
*/
|
|
11
|
-
/** Session-dir-relative name of the replacement-epoch disk witness
|
|
12
|
-
* (openspec: next-webpack-served-transform-coherence, design D2;
|
|
13
|
-
* session-scoped by next-turbopack-served-transform-coherence D2). */
|
|
5
|
+
/** Session-dir-relative name of the replacement-epoch disk witness. */
|
|
14
6
|
export declare const REPLACEMENT_EPOCH_ARTIFACT = "replacements-epoch";
|
|
15
|
-
/** Virtual module id of the emitted system-props module
|
|
16
|
-
* vocabulary shared by the orchestrator and the Turbopack config
|
|
17
|
-
* assembly (hoisted here so the session home stays framework-free). */
|
|
7
|
+
/** Virtual module id of the emitted system-props module. */
|
|
18
8
|
export declare const TURBOPACK_SYSTEM_PROPS_ID = "virtual:animus/system-props";
|
|
19
|
-
/** Session-dir-relative name of the analysis-commit transaction artifact
|
|
20
|
-
* (design D1). */
|
|
9
|
+
/** Session-dir-relative name of the analysis-commit transaction artifact. */
|
|
21
10
|
export declare const ANALYSIS_COMMIT_ARTIFACT = "analysis-commit";
|
|
22
|
-
/** Session-dir-relative name of the analysis-status artifact
|
|
11
|
+
/** Session-dir-relative name of the analysis-status artifact. */
|
|
23
12
|
export declare const ANALYSIS_STATUS_ARTIFACT = "analysis-status.json";
|
|
24
13
|
/** Session-dir-relative name of the manifest payload artifact. */
|
|
25
14
|
export declare const MANIFEST_ARTIFACT = "manifest.json";
|
|
26
|
-
/** Session-dir-relative name of the analysis-inputs payload artifact
|
|
27
|
-
*
|
|
15
|
+
/** Session-dir-relative name of the analysis-inputs payload artifact — the
|
|
16
|
+
* Turbopack loader-worker hydration corpus. */
|
|
28
17
|
export declare const ANALYSIS_INPUTS_ARTIFACT = "analysis-inputs.json";
|
|
29
18
|
/** Session-dir-relative name of the emitted stylesheet artifact. */
|
|
30
19
|
export declare const STYLES_ARTIFACT = "styles.css";
|
|
@@ -32,46 +21,31 @@ export declare const STYLES_ARTIFACT = "styles.css";
|
|
|
32
21
|
export declare const SYSTEM_PROPS_ARTIFACT = "system-props.js";
|
|
33
22
|
/** Session-dir-relative directory holding copied asset() files. */
|
|
34
23
|
export declare const SESSION_ASSETS_DIR = "assets";
|
|
35
|
-
/** The standalone CLI's published-set commit record
|
|
36
|
-
*
|
|
37
|
-
* the CLI writer and the session's start hygiene agree on ONE name — the
|
|
38
|
-
* hygiene confinement gate keys on this record, and a renamed literal on
|
|
39
|
-
* either side would silently re-arm deletion of the CLI's published output. */
|
|
24
|
+
/** The standalone CLI's published-set commit record in the flat `.animus/`
|
|
25
|
+
* tree; the session's start hygiene keys on this name before deleting. */
|
|
40
26
|
export declare const CLI_COMMIT_ARTIFACT = "commit.json";
|
|
41
|
-
/**
|
|
42
|
-
*
|
|
27
|
+
/** Advisory claim record (pid plus heartbeat) of whichever directory holds
|
|
28
|
+
* it; sessions write it into their own tree too, despite the `CLI_` name. */
|
|
43
29
|
export declare const CLI_LOCK_ARTIFACT = "lock.json";
|
|
44
|
-
/**
|
|
30
|
+
/** Project-relative artifact directory: the CLI's default output tree and
|
|
31
|
+
* the parent of every session tree. One spelling, or the tree splits. */
|
|
32
|
+
export declare const ANIMUS_ARTIFACT_DIR = ".animus";
|
|
33
|
+
/** Module id the Rust emitter injects, and the alias key both bundlers
|
|
34
|
+
* register. A literal on purpose: a rename breaks built consumer packages.
|
|
35
|
+
* The Next plugin's webpack alias harvest skips this exact key, so a change
|
|
36
|
+
* here is a change in the emitter, both bundler arms and that harvest. */
|
|
37
|
+
export declare const ANIMUS_CSS_MODULE_ID = ".animus/styles.css";
|
|
45
38
|
export declare function sessionsRootDir(rootDir: string): string;
|
|
46
|
-
/** One session's artifact directory (design D2: session-scoped trees,
|
|
47
|
-
* no global pointer). */
|
|
48
39
|
export declare function sessionArtifactDir(rootDir: string, sessionId: string): string;
|
|
49
|
-
/** Absolute path of a session's replacement-epoch artifact — the single
|
|
50
|
-
* derivation shared by the session writer, the webpack plugin's
|
|
51
|
-
* watch-ignore entry, and both loaders' file dependencies. Takes the
|
|
52
|
-
* SESSION directory (not the project root) since the artifact was
|
|
53
|
-
* relocated into the session tree. */
|
|
54
40
|
export declare function replacementEpochPath(sessionDir: string): string;
|
|
55
|
-
/** Absolute path of a session's analysis-commit artifact. */
|
|
56
41
|
export declare function analysisCommitPath(sessionDir: string): string;
|
|
57
|
-
/** Absolute path of a session's analysis-status artifact. */
|
|
58
42
|
export declare function analysisStatusPath(sessionDir: string): string;
|
|
59
|
-
/** Absolute path of a session's manifest artifact. */
|
|
60
43
|
export declare function manifestPath(sessionDir: string): string;
|
|
61
|
-
/** Absolute path of a session's analysis-inputs artifact. */
|
|
62
44
|
export declare function analysisInputsPath(sessionDir: string): string;
|
|
63
|
-
/** Absolute path of a session's stylesheet artifact. */
|
|
64
45
|
export declare function stylesPath(sessionDir: string): string;
|
|
65
|
-
/** Absolute path of a session's system-props module artifact. */
|
|
66
46
|
export declare function systemPropsPath(sessionDir: string): string;
|
|
67
|
-
/**
|
|
68
|
-
*
|
|
69
|
-
* source/commit mismatch can decide — on evidence — whether to wait.
|
|
70
|
-
*
|
|
71
|
-
* Schema 2 (openspec: standalone-extraction-cli, watch readiness) adds the
|
|
72
|
-
* additive `ready` field; every other field is unchanged, so schema-1
|
|
73
|
-
* readers keep working (no reader branches on the schema value — the bump
|
|
74
|
-
* records the shape revision for artifact archaeology). */
|
|
47
|
+
/** Advisory: a loader reads it only after observing a source/commit
|
|
48
|
+
* mismatch, to decide whether to wait. No reader branches on `schema`. */
|
|
75
49
|
export interface AnalysisStatus {
|
|
76
50
|
schema: 1 | 2;
|
|
77
51
|
sessionId: string;
|
|
@@ -82,50 +56,42 @@ export interface AnalysisStatus {
|
|
|
82
56
|
/** Epoch-ms deadline for the active attempt (debounce ceiling + 2s). */
|
|
83
57
|
deadlineAt: number;
|
|
84
58
|
diagnostic?: string;
|
|
85
|
-
/**
|
|
86
|
-
*
|
|
87
|
-
* every status write after it — including 'failed' writes, which is what
|
|
88
|
-
* makes readiness distinct from `state: 'idle'` (idle recurs per attempt;
|
|
89
|
-
* ready never regresses within a session). */
|
|
59
|
+
/** False until the session's first complete publication, true on every
|
|
60
|
+
* later write including failures; never regresses within a session. */
|
|
90
61
|
ready?: boolean;
|
|
91
62
|
}
|
|
92
|
-
/**
|
|
93
|
-
*
|
|
94
|
-
* is present only when the hydration corpus is persisted (Turbopack
|
|
95
|
-
* orchestration); webpack-mode commits omit it (spec:
|
|
96
|
-
* next-turbopack-integration, "Webpack mode skips the hydration corpus"). */
|
|
63
|
+
/** Transaction identity: every hash is of the DISK payload bytes, envelope
|
|
64
|
+
* included. `inputsHash` is absent when no hydration corpus is persisted. */
|
|
97
65
|
export interface AnalysisCommit {
|
|
98
66
|
schema: 1;
|
|
99
67
|
sessionId: string;
|
|
68
|
+
/** Forensic ordinal only: no reader decides anything from it, and it is
|
|
69
|
+
* monotonic per session directory only because publication is exclusive. */
|
|
100
70
|
generation: number;
|
|
101
71
|
replacementEpoch: string;
|
|
102
72
|
manifestHash: string;
|
|
103
73
|
inputsHash?: string;
|
|
104
74
|
stylesHash: string;
|
|
105
75
|
}
|
|
106
|
-
/**
|
|
107
|
-
*
|
|
108
|
-
* guards without byte-reconstructing the payload). */
|
|
76
|
+
/** Embedded in every payload artifact; `payloadHash` lets a same-session
|
|
77
|
+
* restart seed its write guards without rebuilding the payload bytes. */
|
|
109
78
|
export interface SessionEnvelope {
|
|
110
79
|
sessionId: string;
|
|
111
80
|
generation: number;
|
|
112
81
|
replacementEpoch: string;
|
|
113
82
|
payloadHash: string;
|
|
114
83
|
}
|
|
115
|
-
/**
|
|
116
|
-
*
|
|
117
|
-
* (parse/re-stringify could reformat engine-emitted JSON). */
|
|
84
|
+
/** Splices the envelope in as a leading `__animusSession` field without
|
|
85
|
+
* re-serializing: parse/re-stringify would reformat engine-emitted JSON. */
|
|
118
86
|
export declare function envelopeJsonArtifact(payload: string, envelopeJson: string): string;
|
|
119
|
-
/** Trailing-comment side-band
|
|
120
|
-
*
|
|
87
|
+
/** Trailing-comment side-band: a leading comment would displace the `@layer`
|
|
88
|
+
* declaration consumers pin at offset 0. */
|
|
121
89
|
export declare function envelopeCssArtifact(payload: string, envelopeJson: string): string;
|
|
122
|
-
/** Matches the CSS artifact's envelope side-band. */
|
|
123
90
|
export declare const ENVELOPE_CSS_COMMENT_RE: RegExp;
|
|
124
|
-
/** Envelope of a JSON artifact's bytes, or undefined when
|
|
125
|
-
*
|
|
126
|
-
* torn artifact fails closed or degrades. */
|
|
91
|
+
/** Envelope of a JSON artifact's bytes, or undefined when it carries none.
|
|
92
|
+
* Throws on unparseable bytes; callers decide torn-artifact policy. */
|
|
127
93
|
export declare function readJsonEnvelope(bytes: string): SessionEnvelope | undefined;
|
|
128
|
-
/** Envelope of the CSS
|
|
129
|
-
*
|
|
94
|
+
/** Envelope of the CSS side-band comment, or undefined when it is absent.
|
|
95
|
+
* Throws on an unparseable envelope body. */
|
|
130
96
|
export declare function readCssEnvelope(bytes: string): SessionEnvelope | undefined;
|
|
131
97
|
//# sourceMappingURL=session-paths.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-paths.d.ts","sourceRoot":"","sources":["../../session/session-paths.ts"],"names":[],"mappings":"AAEA
|
|
1
|
+
{"version":3,"file":"session-paths.d.ts","sourceRoot":"","sources":["../../session/session-paths.ts"],"names":[],"mappings":"AAEA;;;GAGG;AAEH,uEAAuE;AACvE,eAAO,MAAM,0BAA0B,uBAAuB,CAAC;AAE/D,4DAA4D;AAC5D,eAAO,MAAM,yBAAyB,gCAAgC,CAAC;AAEvE,6EAA6E;AAC7E,eAAO,MAAM,wBAAwB,oBAAoB,CAAC;AAE1D,iEAAiE;AACjE,eAAO,MAAM,wBAAwB,yBAAyB,CAAC;AAE/D,kEAAkE;AAClE,eAAO,MAAM,iBAAiB,kBAAkB,CAAC;AAEjD;gDACgD;AAChD,eAAO,MAAM,wBAAwB,yBAAyB,CAAC;AAE/D,oEAAoE;AACpE,eAAO,MAAM,eAAe,eAAe,CAAC;AAE5C,oEAAoE;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CAAC;IACjC,wEAAwE;IACxE,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;4EACwE;IACxE,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;8EAC8E;AAC9E,MAAM,WAAW,cAAc;IAC7B,MAAM,EAAE,CAAC,CAAC;IACV,SAAS,EAAE,MAAM,CAAC;IAClB;iFAC6E;IAC7E,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;IACzB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;0EAC0E;AAC1E,MAAM,WAAW,eAAe;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;IACzB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED;6EAC6E;AAC7E,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,MAAM,GACnB,MAAM,CAQR;AAED;6CAC6C;AAC7C,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,MAAM,GACnB,MAAM,CAER;AAED,eAAO,MAAM,uBAAuB,QAAuC,CAAC;AAE5E;wEACwE;AACxE,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,GAAG,SAAS,CAK3E;AAED;8CAC8C;AAC9C,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,GAAG,SAAS,CAK1E"}
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
export declare function getManifestJson(): string | null;
|
|
2
2
|
export declare function setManifestJson(json: string): void;
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
/**
|
|
4
|
+
* A latch over the most recently STARTED analysis, never cleared on settle:
|
|
5
|
+
* non-null means one was scheduled. In-flight lives in getWatchTransaction.
|
|
6
|
+
*/
|
|
7
|
+
export declare function getAnalysisStartedPromise(): Promise<void> | null;
|
|
8
|
+
export declare function setAnalysisStartedPromise(promise: Promise<void>): void;
|
|
9
|
+
export declare function resetAnalysisStartedPromise(): void;
|
|
6
10
|
export declare function getSharedCss(): string;
|
|
7
11
|
export declare function setSharedCss(css: string): void;
|
|
8
12
|
export declare function getSharedSystemProps(): string;
|
|
@@ -11,9 +15,8 @@ export declare function getSharedExternalDirs(): string[];
|
|
|
11
15
|
export declare function setSharedExternalDirs(dirs: string[]): void;
|
|
12
16
|
export declare function getSharedExternalEntries(): Map<string, string>;
|
|
13
17
|
export declare function setSharedExternalEntries(entries: Map<string, string>): void;
|
|
14
|
-
/** Structural view of the
|
|
15
|
-
*
|
|
16
|
-
* depends on the session module it serves. */
|
|
18
|
+
/** Structural view of the target session, declared here rather than imported
|
|
19
|
+
* so the singleton never depends on the session module it serves. */
|
|
17
20
|
export interface WatchBatchTarget {
|
|
18
21
|
ingestForwardedBatch(changes: {
|
|
19
22
|
modifiedFiles?: ReadonlySet<string>;
|
|
@@ -21,104 +24,62 @@ export interface WatchBatchTarget {
|
|
|
21
24
|
}): Promise<void>;
|
|
22
25
|
}
|
|
23
26
|
/**
|
|
24
|
-
* The session that
|
|
25
|
-
*
|
|
26
|
-
* its own session AND its own watcher with its own modified set; a
|
|
27
|
-
* non-owning session forwards its batch here instead of dropping it (a file
|
|
28
|
-
* only that compiler watches would otherwise never be analyzed).
|
|
27
|
+
* The only session that can run watch analysis. A non-owning session forwards
|
|
28
|
+
* its batch here; dropping it loses files only that watcher sees.
|
|
29
29
|
*/
|
|
30
30
|
export declare function getOwningWatchSession(): WatchBatchTarget | null;
|
|
31
31
|
export declare function setOwningWatchSession(session: WatchBatchTarget | null): void;
|
|
32
32
|
/**
|
|
33
|
-
* Per-file
|
|
34
|
-
*
|
|
35
|
-
* unconditional catching-up guard (openspec:
|
|
36
|
-
* next-webpack-served-transform-coherence, design D4). Includes files
|
|
37
|
-
* analyzed with ZERO animus entries: analyzed identity is membership in the
|
|
38
|
-
* analysis input set, not manifest entry count.
|
|
33
|
+
* Per-file content hashes of the last published analysis (relPath → hash of
|
|
34
|
+
* the exact bytes analyzed), including files that produced zero entries.
|
|
39
35
|
*/
|
|
40
36
|
export declare function getAnalyzedHashes(): ReadonlyMap<string, string> | null;
|
|
41
37
|
export declare function setAnalyzedHashes(hashes: Map<string, string>): void;
|
|
42
38
|
/**
|
|
43
|
-
* Session identity is per
|
|
44
|
-
*
|
|
45
|
-
* next-turbopack-served-transform-coherence, design D2). The first
|
|
46
|
-
* ExtractionSession constructed in a process claims a fresh randomUUID;
|
|
47
|
-
* every later instance (client/server/RSC compilers each construct one)
|
|
48
|
-
* adopts it, so all compilers alias, watch-ignore, and publish ONE
|
|
49
|
-
* session-scoped artifact tree. Separate invocations (`next dev` +
|
|
50
|
-
* `next build` co-writing) are separate processes and therefore separate
|
|
51
|
-
* sessions by construction.
|
|
39
|
+
* Session identity is per process: the first caller claims a fresh id and
|
|
40
|
+
* every later one adopts it, so all compilers share one artifact tree.
|
|
52
41
|
*/
|
|
53
42
|
export declare function claimProcessSessionId(): string;
|
|
54
43
|
/**
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* shared slots above (manifest, css, artifact dir) plus the one session id
|
|
58
|
-
* mean two CONCURRENT drive loops in one process (a webpack MultiCompiler
|
|
59
|
-
* array config, parallel rollup array builds, two programmatic CLI runs)
|
|
60
|
-
* would share one session directory, overwrite each other's manifests, and
|
|
61
|
-
* delete each other's live trees on dispose. Drivers that run the loop
|
|
62
|
-
* exclusively (the unplugin host) claim for the build's lifetime and
|
|
63
|
-
* release on dispose; SEQUENTIAL claim/release cycles are legal. The Next
|
|
64
|
-
* multi-compiler adoption path stays the non-exclusive default. Throws
|
|
65
|
-
* naming both hosts and the remediation on overlap. The key lives in
|
|
66
|
-
* `SINGLETON_GLOBAL_KEYS`, so per-test global resets clear a leaked claim.
|
|
44
|
+
* Two CONCURRENT drive loops in one process would share one session tree and
|
|
45
|
+
* clobber each other; sequential claim/release cycles are legal.
|
|
67
46
|
*/
|
|
68
47
|
export declare function claimExclusiveSessionOwner(label: string): () => void;
|
|
69
48
|
/**
|
|
70
|
-
* Absolute
|
|
71
|
-
*
|
|
72
|
-
* dependency path (the loader shares the process with the pipeline; the
|
|
73
|
-
* Turbopack loader instead receives the directory via its options).
|
|
49
|
+
* Absolute artifact directory of the OWNING session's last publication. The
|
|
50
|
+
* Turbopack loader runs out of process and receives it via options instead.
|
|
74
51
|
*/
|
|
75
52
|
export declare function getSessionArtifactDir(): string | null;
|
|
76
53
|
export declare function setSessionArtifactDir(dir: string): void;
|
|
77
54
|
/**
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
* — openspec: next-webpack-served-transform-coherence, design D5; the
|
|
81
|
-
* served system-props module rides as the served-dependency witness so
|
|
82
|
-
* offline system-props changes move the epoch). Published by the
|
|
83
|
-
* owning session AFTER the manifest so a reader that observes the epoch
|
|
84
|
-
* always observes at least that generation's manifest. (Session
|
|
85
|
-
* attribution lives on the DISK epoch artifact — no in-process mirror.)
|
|
55
|
+
* Replacement epoch of the last published analysis, written AFTER the
|
|
56
|
+
* manifest so an epoch reader always sees at least that generation's manifest.
|
|
86
57
|
*/
|
|
87
58
|
export declare function getReplacementEpoch(): string | null;
|
|
88
59
|
export declare function setReplacementEpoch(epoch: string): void;
|
|
89
60
|
/**
|
|
90
|
-
* The one in-flight watch-analysis transaction
|
|
91
|
-
*
|
|
92
|
-
* compiler (client/server/RSC — each holds its own session instance) joins
|
|
93
|
-
* this promise instead of proceeding against a pre-transaction generation.
|
|
61
|
+
* The one in-flight watch-analysis transaction: a compiler that did not start
|
|
62
|
+
* it joins this promise rather than read a pre-transaction generation.
|
|
94
63
|
*/
|
|
95
64
|
export declare function getWatchTransaction(): Promise<void> | null;
|
|
96
65
|
export declare function setWatchTransaction(transaction: Promise<void> | null): void;
|
|
97
66
|
export type AnimusEngine = 'v2';
|
|
98
|
-
/** Engine selection travels through the singleton so non-owning
|
|
99
|
-
*
|
|
67
|
+
/** Engine selection travels through the singleton so non-owning compilers
|
|
68
|
+
* and the webpack loader honor the owner's choice. */
|
|
100
69
|
export declare function setSharedEngine(engine: AnimusEngine): void;
|
|
101
70
|
export declare function getSharedEngine(): AnimusEngine;
|
|
102
|
-
/** Single
|
|
103
|
-
*
|
|
104
|
-
* module's own .d.ts is the authoritative surface. */
|
|
71
|
+
/** Single choke-point for every native extraction call; the NAPI module's
|
|
72
|
+
* own `.d.ts` is the authoritative surface for what it returns. */
|
|
105
73
|
export declare function requireEngine(): any;
|
|
106
74
|
/**
|
|
107
|
-
* Test seam
|
|
108
|
-
*
|
|
109
|
-
* keyed so every copy of this module — source-imported, dist-imported,
|
|
110
|
-
* ESM/CJS dual-load — honors the one override. Deliberately NOT in
|
|
111
|
-
* SINGLETON_GLOBAL_KEYS: the override's lifecycle belongs to the test
|
|
112
|
-
* file, and per-test global resets must not strip it mid-suite. Pass null
|
|
113
|
-
* to restore the native-backed API.
|
|
75
|
+
* Test seam, set once at module top level: this key stays OUT of
|
|
76
|
+
* SINGLETON_GLOBAL_KEYS so a per-test reset cannot strip the override.
|
|
114
77
|
*/
|
|
115
78
|
export declare function setEngineApiOverride(api: (() => any) | null): void;
|
|
116
79
|
export declare function engineApi(): any;
|
|
117
80
|
/**
|
|
118
|
-
* Every globalThis key this module owns
|
|
119
|
-
*
|
|
120
|
-
* setEngineApiOverride) — the single authority test harnesses
|
|
121
|
-
* snapshot/clear per test (never re-declare this list).
|
|
81
|
+
* Every globalThis key this module owns except the engine-api override, which
|
|
82
|
+
* a per-test reset must not clear. Test harnesses clear exactly this list.
|
|
122
83
|
*/
|
|
123
|
-
export declare const SINGLETON_GLOBAL_KEYS: readonly ["__animus_manifest_json__", "
|
|
84
|
+
export declare const SINGLETON_GLOBAL_KEYS: readonly ["__animus_manifest_json__", "__animus_analysis_started__", "__animus_shared_css__", "__animus_shared_system_props__", "__animus_external_pkg_dirs__", "__animus_external_source_entries__", "__animus_analyzed_hashes__", "__animus_replacement_epoch__", "__animus_watch_transaction__", "__animus_process_session_id__", "__animus_session_artifact_dir__", "__animus_owning_watch_session__", "__animus_exclusive_session_owner__", "__animus_engine__", "__animus_v2_engine__", "__animus_v2_sent_sources__", "__animus_v2_drift_warned__"];
|
|
124
85
|
//# sourceMappingURL=singleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"singleton.d.ts","sourceRoot":"","sources":["../../session/singleton.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"singleton.d.ts","sourceRoot":"","sources":["../../session/singleton.ts"],"names":[],"mappings":"AAkEA,wBAAgB,eAAe,IAAI,MAAM,GAAG,IAAI,CAE/C;AAED,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAElD;AAED;;;GAGG;AACH,wBAAgB,yBAAyB,IAAI,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAEhE;AAED,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAEtE;AAED,wBAAgB,2BAA2B,IAAI,IAAI,CAElD;AAED,wBAAgB,YAAY,IAAI,MAAM,CAErC;AAED,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAE9C;AAED,wBAAgB,oBAAoB,IAAI,MAAM,CAE7C;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAE1D;AAED,wBAAgB,qBAAqB,IAAI,MAAM,EAAE,CAEhD;AAED,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,IAAI,CAE1D;AAED,wBAAgB,wBAAwB,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAE9D;AAED,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,G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BAAgB,eAAe,CAAC,MAAM,EAAE,YAAY,GAAG,IAAI,CAE1D;AAED,wBAAgB,eAAe,IAAI,YAAY,CAI9C;AAED;oEACoE;AAEpE,wBAAgB,aAAa,IAAI,GAAG,CAGnC;AA6BD;;;GAGG;AAEH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,CAAC,MAAM,GAAG,CAAC,GAAG,IAAI,GAAG,IAAI,CAElE;AAGD,wBAAgB,SAAS,IAAI,GAAG,CAG/B;AAED;;;GAGG;AACH,eAAO,MAAM,qBAAqB,2hBAkBxB,CAAC"}
|
package/dist/session/timing.d.ts
CHANGED
|
@@ -1,7 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Verbose build-timing waterfall: JS phases, analysis sub-phases, and the
|
|
3
|
-
* shared Rust phase table. `ANIMUS_TIMING_JSON=1` additionally dumps a
|
|
4
|
-
* machine-readable merged record.
|
|
5
|
-
*/
|
|
6
1
|
export declare function logBuildTimings(bt: Record<string, number>, rustTiming: Record<string, number> | undefined, log: (msg: string) => void, verbose: boolean): void;
|
|
7
2
|
//# sourceMappingURL=timing.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"timing.d.ts","sourceRoot":"","sources":["../../session/timing.ts"],"names":[],"mappings":"AAEA
|
|
1
|
+
{"version":3,"file":"timing.d.ts","sourceRoot":"","sources":["../../session/timing.ts"],"names":[],"mappings":"AAEA,wBAAgB,eAAe,CAC7B,EAAE,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC1B,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,SAAS,EAC9C,GAAG,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,EAC1B,OAAO,EAAE,OAAO,GACf,IAAI,CAkDN"}
|
|
@@ -1,43 +1,27 @@
|
|
|
1
1
|
import { watch } from 'fs';
|
|
2
2
|
import type { ExtractionSession } from './extraction-session';
|
|
3
|
-
/**
|
|
4
|
-
* Out-of-band pipeline orchestration for Turbopack (spec:
|
|
5
|
-
* next-turbopack-integration). Turbopack exposes no compiler hooks, so the
|
|
6
|
-
* pipeline runs during next.config resolution and, in dev, from a
|
|
7
|
-
* filesystem watcher — the bundler only ever sees the `.animus/` disk
|
|
8
|
-
* artifacts.
|
|
9
|
-
*/
|
|
10
|
-
/** Run the full pipeline with the Turbopack emitter identity: the virtual
|
|
11
|
-
* system-props id (Turbopack rejects the webpack path's absolute-path
|
|
12
|
-
* imports). Turbopack orchestration persists the analysis-inputs
|
|
13
|
-
* hydration corpus — its isolated loader workers replay it (spec:
|
|
14
|
-
* next-turbopack-integration, "Manifest disk artifact"; webpack mode
|
|
15
|
-
* skips the corpus). */
|
|
16
3
|
export declare function runSessionPipeline(session: ExtractionSession): Promise<void>;
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
* caller-initiated teardown; `died` flips only on an ASYNC watcher error
|
|
34
|
-
* (EMFILE/ENOSPC after registration) with `onDied` invoked once so the
|
|
35
|
-
* process owner can surface the degradation; `settle()` resolves when the
|
|
36
|
-
* in-flight update chain has drained. */
|
|
4
|
+
export interface TurbopackWatcherOptions {
|
|
5
|
+
debounceMs?: number;
|
|
6
|
+
watchFn?: typeof watch;
|
|
7
|
+
/** Accumulate observed paths until `deliverHeldEvents()`: a cycle scheduled
|
|
8
|
+
* before the first analysis joins the running pipeline and does nothing. */
|
|
9
|
+
holdEvents?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare function startTurbopackWatcher(session: ExtractionSession, rootDir: string, options?: TurbopackWatcherOptions): TurbopackWatchOutcome;
|
|
12
|
+
export type TurbopackWatchOutcome = {
|
|
13
|
+
kind: 'started';
|
|
14
|
+
handle: TurbopackWatcherHandle;
|
|
15
|
+
} | {
|
|
16
|
+
kind: 'already-watched';
|
|
17
|
+
} | {
|
|
18
|
+
kind: 'unavailable';
|
|
19
|
+
};
|
|
37
20
|
export interface TurbopackWatcherHandle {
|
|
38
21
|
close(): void;
|
|
39
22
|
readonly died: boolean;
|
|
40
23
|
onDied: (() => void) | null;
|
|
41
24
|
settle(): Promise<void>;
|
|
25
|
+
deliverHeldEvents(): Promise<void>;
|
|
42
26
|
}
|
|
43
27
|
//# sourceMappingURL=turbopack-orchestrator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"turbopack-orchestrator.d.ts","sourceRoot":"","sources":["../../session/turbopack-orchestrator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,KAAK,EAAE,MAAM,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"turbopack-orchestrator.d.ts","sourceRoot":"","sources":["../../session/turbopack-orchestrator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,KAAK,EAAE,MAAM,IAAI,CAAC;AAS9D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D,wBAAsB,kBAAkB,CACtC,OAAO,EAAE,iBAAiB,GACzB,OAAO,CAAC,IAAI,CAAC,CAIf;AAkCD,MAAM,WAAW,uBAAuB;IACtC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,KAAK,CAAC;IACvB;iFAC6E;IAC7E,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,iBAAiB,EAC1B,OAAO,EAAE,MAAM,EACf,OAAO,GAAE,uBAA4B,GACpC,qBAAqB,CAqQvB;AAED,MAAM,MAAM,qBAAqB,GAC7B;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,MAAM,EAAE,sBAAsB,CAAA;CAAE,GACnD;IAAE,IAAI,EAAE,iBAAiB,CAAA;CAAE,GAC3B;IAAE,IAAI,EAAE,aAAa,CAAA;CAAE,CAAC;AAE5B,MAAM,WAAW,sBAAsB;IACrC,KAAK,IAAI,IAAI,CAAC;IACd,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,MAAM,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,IAAI,CAAC;IAC5B,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACxB,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACpC"}
|