@pie-players/pie-section-player 0.3.30 → 0.3.31
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 +87 -24
- package/dist/chunks/tool-annotation-toolbar-db5bfbec.js +1018 -934
- package/dist/components/shared/player-preload.d.ts +88 -71
- package/dist/components/shared/player-preload.d.ts.map +1 -1
- package/dist/components/shared/section-player-host-runtime.d.ts +72 -0
- package/dist/components/shared/section-player-host-runtime.d.ts.map +1 -0
- package/dist/components/shared/section-player-runtime-callbacks.d.ts +33 -0
- package/dist/components/shared/section-player-runtime-callbacks.d.ts.map +1 -0
- package/dist/components/shared/section-player-view-state.d.ts.map +1 -1
- package/dist/contracts/host-hooks.d.ts +20 -0
- package/dist/contracts/host-hooks.d.ts.map +1 -1
- package/dist/contracts/layout-contract.d.ts +2 -2
- package/dist/contracts/layout-contract.d.ts.map +1 -1
- package/dist/contracts/layout-parity-metadata.d.ts.map +1 -1
- package/dist/contracts/public-events.d.ts +86 -10
- package/dist/contracts/public-events.d.ts.map +1 -1
- package/dist/contracts/stages.d.ts +11 -0
- package/dist/contracts/stages.d.ts.map +1 -0
- package/dist/pie-section-player.d.ts +2 -2
- package/dist/pie-section-player.d.ts.map +1 -1
- package/dist/pie-section-player.js +18342 -6450
- package/dist/policies/index.d.ts +21 -4
- package/dist/policies/index.d.ts.map +1 -1
- package/dist/policies/types.d.ts +0 -5
- package/dist/policies/types.d.ts.map +1 -1
- package/package.json +12 -15
- package/dist/chunks/player-preload-79b07366.js +0 -10093
- package/dist/components/shared/section-player-readiness.d.ts +0 -14
- package/dist/components/shared/section-player-readiness.d.ts.map +0 -1
- package/dist/components/shared/section-player-runtime.d.ts +0 -154
- package/dist/components/shared/section-player-runtime.d.ts.map +0 -1
- package/dist/utils/player-preload.d.ts +0 -2
- package/dist/utils/player-preload.d.ts.map +0 -1
- package/dist/utils/player-preload.js +0 -8
|
@@ -1,10 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { EsmBackendConfig, IifeBackendConfig, IifeBundleRetryStatus, ItemEntity, createPieLogger } from '@pie-players/pie-players-shared';
|
|
2
|
+
export type IifeBundleRetryStatusHandler = (status: IifeBundleRetryStatus) => void;
|
|
3
|
+
/**
|
|
4
|
+
* Narrow string union of section-preload pipeline stages reported on
|
|
5
|
+
* `element-preload-retry` and `element-preload-error` events. Hosts use
|
|
6
|
+
* this to disambiguate "the renderable's PIE config is invalid" from
|
|
7
|
+
* "the IIFE bundle won't load" from "the ESM module won't import" from
|
|
8
|
+
* "the host claimed strategy='preloaded' but didn't pre-register".
|
|
9
|
+
*/
|
|
10
|
+
export type PreloadStage = "validate-config" | "iife-load" | "esm-load" | "preloaded-assert";
|
|
5
11
|
export type ElementPreloadRetryDetail = {
|
|
6
12
|
componentTag: string;
|
|
7
|
-
stage:
|
|
13
|
+
stage: PreloadStage;
|
|
8
14
|
attempt: number;
|
|
9
15
|
maxRetries: number;
|
|
10
16
|
error: string;
|
|
@@ -15,84 +21,95 @@ export type ElementPreloadRetryDetail = {
|
|
|
15
21
|
};
|
|
16
22
|
export type ElementPreloadErrorDetail = {
|
|
17
23
|
componentTag: string;
|
|
18
|
-
stage:
|
|
24
|
+
stage: PreloadStage;
|
|
19
25
|
error: string;
|
|
20
26
|
strategy: string;
|
|
21
27
|
bundleType: string | null;
|
|
22
28
|
bundleHost: string;
|
|
23
29
|
renderablesCount: number;
|
|
24
30
|
};
|
|
25
|
-
|
|
31
|
+
/**
|
|
32
|
+
* Carries which stage of `warmupSectionElements` rejected, so the
|
|
33
|
+
* `SectionItemsPane.svelte` `usePromise` rejection effect can surface
|
|
34
|
+
* the right `stage` on the host's `element-preload-error` event.
|
|
35
|
+
*
|
|
36
|
+
* Catastrophic adapter rejections (network freeze, bundle timeout) bubble
|
|
37
|
+
* up through `ensureRegistered` as `ElementLoaderError` and get wrapped
|
|
38
|
+
* in `PreloadStageError` with stage `"iife-load"` or `"esm-load"`
|
|
39
|
+
* depending on the requested strategy. Config-contract failures wrap
|
|
40
|
+
* with stage `"validate-config"`.
|
|
41
|
+
*/
|
|
42
|
+
export declare class PreloadStageError extends Error {
|
|
43
|
+
readonly name = "PreloadStageError";
|
|
44
|
+
readonly stage: PreloadStage;
|
|
45
|
+
readonly cause: unknown;
|
|
46
|
+
constructor(stage: PreloadStage, cause: unknown);
|
|
47
|
+
}
|
|
48
|
+
export declare function getPreloadLogger(componentTag: string): import('@pie-players/pie-players-shared').PieLogger;
|
|
26
49
|
export declare function getLoaderView(env: Record<string, unknown>): "author" | "delivery";
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
50
|
+
/**
|
|
51
|
+
* Stable string signature of a list of renderables, used as a react-key
|
|
52
|
+
* hint for the composition snapshot plumbed through the layout tree.
|
|
53
|
+
*
|
|
54
|
+
* The signature is *not* used for preload dedup anymore — the deep
|
|
55
|
+
* `ElementLoader` primitive handles that internally. It is retained only
|
|
56
|
+
* because downstream template props still pass a string identifier
|
|
57
|
+
* through the customElement boundary.
|
|
58
|
+
*/
|
|
59
|
+
export declare function getRenderablesSignature(renderables: unknown[]): string;
|
|
36
60
|
export declare function formatElementLoadError(stage: string, error: unknown): string;
|
|
37
|
-
export declare function
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
export declare function preloadPlayerElementsWithRetry(args: {
|
|
49
|
-
componentTag: string;
|
|
61
|
+
export declare function toErrorMessage(error: unknown): string;
|
|
62
|
+
/**
|
|
63
|
+
* Translate a section-player's resolved props into an `ElementLoader`
|
|
64
|
+
* backend config. Throws when required host-supplied values (bundle host
|
|
65
|
+
* for IIFE) are missing — callers should surface this as a preload error.
|
|
66
|
+
*
|
|
67
|
+
* `onBundleRetryStatus` is wired through to `IifeBackendConfig` for IIFE
|
|
68
|
+
* strategy so hosts can render "bundle still building" UI while the
|
|
69
|
+
* adapter polls the bundle service. ESM ignores it.
|
|
70
|
+
*/
|
|
71
|
+
export declare function buildBackendConfigFromProps(args: {
|
|
50
72
|
strategy: string;
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
export declare function orchestratePlayerElementPreload(args: {
|
|
86
|
-
componentTag: string;
|
|
73
|
+
resolvedPlayerProps: Record<string, unknown>;
|
|
74
|
+
resolvedPlayerEnv: Record<string, unknown>;
|
|
75
|
+
iifeBundleHost?: string | null;
|
|
76
|
+
onBundleRetryStatus?: IifeBundleRetryStatusHandler;
|
|
77
|
+
}): IifeBackendConfig | EsmBackendConfig;
|
|
78
|
+
/**
|
|
79
|
+
* Returns the bundle type (IIFE) or `null` (ESM, preloaded, empty) that
|
|
80
|
+
* should be reported on `element-preload-error` events. Host telemetry
|
|
81
|
+
* needs this as a string to distinguish editor bundles from player bundles.
|
|
82
|
+
*/
|
|
83
|
+
export declare function describeBundleType(backend: IifeBackendConfig | EsmBackendConfig | null): string | null;
|
|
84
|
+
/**
|
|
85
|
+
* Return the bundle host (IIFE only) for telemetry. Empty string for any
|
|
86
|
+
* other backend so the host event shape stays stable.
|
|
87
|
+
*/
|
|
88
|
+
export declare function describeBundleHost(backend: IifeBackendConfig | EsmBackendConfig | null): string;
|
|
89
|
+
/**
|
|
90
|
+
* Pre-warm the aggregate element set for a section before items mount.
|
|
91
|
+
*
|
|
92
|
+
* Contract:
|
|
93
|
+
* - `renderables.length === 0` — no-op. Nothing to load.
|
|
94
|
+
* - `strategy === "preloaded"` — assert every aggregate tag is already
|
|
95
|
+
* registered with `customElements`. Throws `ElementAssertionError`
|
|
96
|
+
* (wrapped in `PreloadStageError` with stage `"preloaded-assert"`) on
|
|
97
|
+
* any missing tag, surfacing one section-level diagnostic instead of
|
|
98
|
+
* N small per-item rejections.
|
|
99
|
+
* - Otherwise: aggregate tags, build backend, await `ensureRegistered`.
|
|
100
|
+
*
|
|
101
|
+
* On any validation or load failure, rejects with a descriptive Error.
|
|
102
|
+
* The caller (section-player widget) is expected to surface the failure
|
|
103
|
+
* through an `element-preload-error` event; item-players then attempt
|
|
104
|
+
* their own registration and typically get a clean per-tag error.
|
|
105
|
+
*/
|
|
106
|
+
export declare function warmupSectionElements(args: {
|
|
87
107
|
strategy: string;
|
|
88
108
|
renderables: ItemEntity[];
|
|
89
|
-
renderablesSignature: string;
|
|
90
109
|
resolvedPlayerProps: Record<string, unknown>;
|
|
91
110
|
resolvedPlayerEnv: Record<string, unknown>;
|
|
92
111
|
iifeBundleHost?: string | null;
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
onPreloadError?: (detail: ElementPreloadErrorDetail) => void;
|
|
97
|
-
}): void;
|
|
112
|
+
logger?: ReturnType<typeof createPieLogger>;
|
|
113
|
+
onBundleRetryStatus?: IifeBundleRetryStatusHandler;
|
|
114
|
+
}): Promise<void>;
|
|
98
115
|
//# sourceMappingURL=player-preload.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"player-preload.d.ts","sourceRoot":"","sources":["../../../src/components/shared/player-preload.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"player-preload.d.ts","sourceRoot":"","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;IAC3C,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,MAAM,CAAC,EAAE,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC;IAC5C,mBAAmB,CAAC,EAAE,4BAA4B,CAAC;CACnD,GAAG,OAAO,CAAC,IAAI,CAAC,CAwChB"}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { RuntimeInputs } from '@pie-players/pie-assessment-toolkit/runtime/internal';
|
|
2
|
+
import { ItemEntity } from '@pie-players/pie-players-shared';
|
|
3
|
+
/**
|
|
4
|
+
* Resolve the player-runtime view (player tag, attributes, props,
|
|
5
|
+
* env, strategy) for the section-player host. Stays in section-player
|
|
6
|
+
* because of the `DEFAULT_PLAYER_DEFINITIONS` dependency, which
|
|
7
|
+
* side-effect-imports `@pie-players/pie-item-player`.
|
|
8
|
+
*
|
|
9
|
+
* Verbatim absorption of the pre-PR-7 `resolvePlayerRuntime` from
|
|
10
|
+
* `section-player-runtime.ts`; behavior is byte-for-byte identical
|
|
11
|
+
* (the existing `tests/section-player-runtime.test.ts` test suite
|
|
12
|
+
* pins this module's export at PR 7).
|
|
13
|
+
*/
|
|
14
|
+
export declare function resolvePlayerRuntime(args: {
|
|
15
|
+
effectiveRuntime: Record<string, unknown>;
|
|
16
|
+
playerType: string;
|
|
17
|
+
env: Record<string, unknown> | null;
|
|
18
|
+
}): {
|
|
19
|
+
effectivePlayerType: string;
|
|
20
|
+
resolvedPlayerDefinition: import('../../component-definitions.js').ComponentDefinition;
|
|
21
|
+
resolvedPlayerTag: string;
|
|
22
|
+
resolvedPlayerAttributes: Record<string, string>;
|
|
23
|
+
resolvedPlayerProps: {
|
|
24
|
+
loaderOptions: {
|
|
25
|
+
[x: string]: unknown;
|
|
26
|
+
};
|
|
27
|
+
loaderConfig?: import('@pie-players/pie-players-shared').LoaderConfig;
|
|
28
|
+
};
|
|
29
|
+
resolvedPlayerEnv: Record<string, unknown>;
|
|
30
|
+
strategy: import('@pie-players/pie-players-shared').ItemPlayerStrategy;
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* Map the layout's `renderables` array (composition-model entries) to
|
|
34
|
+
* a flat `ItemEntity[]`. Used by `section-player-view-state.ts` to
|
|
35
|
+
* project the kernel's composition snapshot into the per-item card
|
|
36
|
+
* view. Stays in section-player because the consumer is a
|
|
37
|
+
* section-player module.
|
|
38
|
+
*/
|
|
39
|
+
export declare function mapRenderablesToItems(renderables: unknown[]): ItemEntity[];
|
|
40
|
+
/**
|
|
41
|
+
* Section-player host orchestrator. Thin wrapper over the toolkit's
|
|
42
|
+
* `resolveSectionEngineRuntimeState`, supplying section-player's
|
|
43
|
+
* local `resolvePlayerRuntime` so the toolkit core never imports
|
|
44
|
+
* `DEFAULT_PLAYER_DEFINITIONS`.
|
|
45
|
+
*
|
|
46
|
+
* Pre-PR-7 callers used the legacy
|
|
47
|
+
* `resolveSectionPlayerRuntimeState` from `section-player-runtime.ts`;
|
|
48
|
+
* post-PR-7 the legacy file is deleted and this wrapper is the only
|
|
49
|
+
* orchestrator entry point.
|
|
50
|
+
*
|
|
51
|
+
* Behavior is byte-for-byte identical to the pre-PR-7 implementation
|
|
52
|
+
* (pinned by `tests/section-player-runtime.test.ts`).
|
|
53
|
+
*/
|
|
54
|
+
export declare function resolveSectionPlayerRuntimeState(args: RuntimeInputs): {
|
|
55
|
+
effectiveToolsConfig: unknown;
|
|
56
|
+
effectiveRuntime: import('@pie-players/pie-assessment-toolkit/runtime/internal').EffectiveRuntime;
|
|
57
|
+
playerRuntime: {
|
|
58
|
+
effectivePlayerType: string;
|
|
59
|
+
resolvedPlayerDefinition: import('../../component-definitions.js').ComponentDefinition;
|
|
60
|
+
resolvedPlayerTag: string;
|
|
61
|
+
resolvedPlayerAttributes: Record<string, string>;
|
|
62
|
+
resolvedPlayerProps: {
|
|
63
|
+
loaderOptions: {
|
|
64
|
+
[x: string]: unknown;
|
|
65
|
+
};
|
|
66
|
+
loaderConfig?: import('@pie-players/pie-players-shared').LoaderConfig;
|
|
67
|
+
};
|
|
68
|
+
resolvedPlayerEnv: Record<string, unknown>;
|
|
69
|
+
strategy: import('@pie-players/pie-players-shared').ItemPlayerStrategy;
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=section-player-host-runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"section-player-host-runtime.d.ts","sourceRoot":"","sources":["../../../src/components/shared/section-player-host-runtime.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH,OAAO,EAIN,KAAK,aAAa,EAClB,MAAM,sDAAsD,CAAC;AAC9D,OAAO,EAEN,KAAK,UAAU,EACf,MAAM,iCAAiC,CAAC;AAGzC;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE;IAC1C,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC1C,UAAU,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC;CACpC;;;;;;;;;;;;;EAiDA;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,OAAO,EAAE,GAAG,UAAU,EAAE,CAK1E;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gCAAgC,CAAC,IAAI,EAAE,aAAa;;;;;;;;;;;;;;;;;EAInE"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { LoadingCompleteHandler, StageChangeHandler } from '@pie-players/pie-assessment-toolkit/runtime/internal';
|
|
2
|
+
export type RuntimeCallbackBridgeChannel = "onStageChange" | "onLoadingComplete";
|
|
3
|
+
export interface RuntimeCallbackBridgeOptions {
|
|
4
|
+
/** Layout CE host element the engine dispatches DOM events on. */
|
|
5
|
+
host: HTMLElement;
|
|
6
|
+
/**
|
|
7
|
+
* Late-bound accessor for the resolved `runtime.onStageChange`. The
|
|
8
|
+
* bridge calls this on each `pie-stage-change` event so prop
|
|
9
|
+
* reassigns mid-cohort still reach the latest handler.
|
|
10
|
+
*/
|
|
11
|
+
getOnStageChange: () => StageChangeHandler | undefined;
|
|
12
|
+
/**
|
|
13
|
+
* Late-bound accessor for the resolved
|
|
14
|
+
* `runtime.onLoadingComplete`. Called on each
|
|
15
|
+
* `pie-loading-complete` event for the same reason as
|
|
16
|
+
* `getOnStageChange`.
|
|
17
|
+
*/
|
|
18
|
+
getOnLoadingComplete: () => LoadingCompleteHandler | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Optional error sink invoked when a host callback throws. The
|
|
21
|
+
* kernel pipes this into its logger so `runtime.on*` exceptions
|
|
22
|
+
* surface in `pie-debug` without breaking the engine's own
|
|
23
|
+
* dispatch path.
|
|
24
|
+
*/
|
|
25
|
+
onError?: (channel: RuntimeCallbackBridgeChannel, error: unknown) => void;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Attach the lockstep callback bridge. Returns a teardown that removes
|
|
29
|
+
* both DOM listeners; the kernel runs it from its `$effect` cleanup so
|
|
30
|
+
* subsequent host swaps or unmounts release the listeners cleanly.
|
|
31
|
+
*/
|
|
32
|
+
export declare function attachRuntimeCallbackBridge(options: RuntimeCallbackBridgeOptions): () => void;
|
|
33
|
+
//# sourceMappingURL=section-player-runtime-callbacks.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"section-player-runtime-callbacks.d.ts","sourceRoot":"","sources":["../../../src/components/shared/section-player-runtime-callbacks.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAMH,OAAO,KAAK,EACX,sBAAsB,EACtB,kBAAkB,EAClB,MAAM,sDAAsD,CAAC;AAE9D,MAAM,MAAM,4BAA4B,GACrC,eAAe,GACf,mBAAmB,CAAC;AAEvB,MAAM,WAAW,4BAA4B;IAC5C,kEAAkE;IAClE,IAAI,EAAE,WAAW,CAAC;IAClB;;;;OAIG;IACH,gBAAgB,EAAE,MAAM,kBAAkB,GAAG,SAAS,CAAC;IACvD;;;;;OAKG;IACH,oBAAoB,EAAE,MAAM,sBAAsB,GAAG,SAAS,CAAC;IAC/D;;;;;OAKG;IACH,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,4BAA4B,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;CAC1E;AAED;;;;GAIG;AACH,wBAAgB,2BAA2B,CAC1C,OAAO,EAAE,4BAA4B,GACnC,MAAM,IAAI,CA8BZ"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section-player-view-state.d.ts","sourceRoot":"","sources":["../../../src/components/shared/section-player-view-state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uCAAuC,CAAC;AACxE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAM1E,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAI9D,MAAM,MAAM,yBAAyB,GAAG;IACvC,gBAAgB,EAAE,uBAAuB,CAAC;IAC1C,QAAQ,EAAE,uBAAuB,CAAC,UAAU,CAAC,CAAC;IAC9C,KAAK,EAAE,uBAAuB,CAAC,OAAO,CAAC,CAAC;IACxC,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,oBAAoB,EAAE,MAAM,CAAC;CAC7B,CAAC;
|
|
1
|
+
{"version":3,"file":"section-player-view-state.d.ts","sourceRoot":"","sources":["../../../src/components/shared/section-player-view-state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uCAAuC,CAAC;AACxE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAM1E,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAI9D,MAAM,MAAM,yBAAyB,GAAG;I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}
|
|
@@ -1,4 +1,24 @@
|
|
|
1
1
|
import { SectionPlayerCardTitleFormatter } from './card-title-formatters.js';
|
|
2
|
+
/**
|
|
3
|
+
* Host-extension hook contract for the section-player layout custom elements.
|
|
4
|
+
*
|
|
5
|
+
* Hosts pass a `SectionPlayerHostHooks` value via the `host-hooks` attribute
|
|
6
|
+
* (or the `hostHooks` prop, mirroring per the two-tier policy in
|
|
7
|
+
* {@link ../../ARCHITECTURE.md}) on `<pie-section-player-*>` to override
|
|
8
|
+
* formatter / decoration behavior that the engine intentionally leaves to the
|
|
9
|
+
* host. Each hook is optional; omitted hooks fall back to documented defaults.
|
|
10
|
+
*
|
|
11
|
+
* Today the contract has a single member (`cardTitleFormatter`). The shape is
|
|
12
|
+
* intentionally a struct, not a single callback prop, so future host-supplied
|
|
13
|
+
* formatters / decorators can be added without renaming the surface.
|
|
14
|
+
*
|
|
15
|
+
* The naming/expansion of this contract is part of the
|
|
16
|
+
* "Coherent Options Surface" review; the broader expansion (additional hook
|
|
17
|
+
* fields produced as the section host runtime engine consolidates) is owned
|
|
18
|
+
* by the M7 follow-up plan in `coherent_options_surface_review_0133a7cd.plan.md`.
|
|
19
|
+
* Keeping the current name (`SectionPlayerHostHooks`) is deliberate so that
|
|
20
|
+
* additions there do not require a breaking rename across the layout CEs.
|
|
21
|
+
*/
|
|
2
22
|
export type SectionPlayerHostHooks = {
|
|
3
23
|
cardTitleFormatter?: SectionPlayerCardTitleFormatter;
|
|
4
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"host-hooks.d.ts","sourceRoot":"","sources":["../../src/contracts/host-hooks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,4BAA4B,CAAC;AAElF,MAAM,MAAM,sBAAsB,GAAG;IACpC,kBAAkB,CAAC,EAAE,+BAA+B,CAAC;CACrD,CAAC"}
|
|
1
|
+
{"version":3,"file":"host-hooks.d.ts","sourceRoot":"","sources":["../../src/contracts/host-hooks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,4BAA4B,CAAC;AAElF;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACpC,kBAAkB,CAAC,EAAE,+BAA+B,CAAC;CACrD,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { SectionPlayerPublicEventName } from './public-events.js';
|
|
2
2
|
export type SectionPlayerLayoutName = "splitpane" | "vertical" | "tabbed";
|
|
3
3
|
export type SectionPlayerLayoutCapability = "items-pane" | "passages-pane" | "section-toolbar" | "item-toolbar" | "passage-toolbar" | "readiness-events" | "navigation-events";
|
|
4
|
-
export type SectionPlayerBasicPropName = "assessmentId" | "section" | "sectionId" | "attemptId" | "debug" | "showToolbar" | "toolbarPosition" | "narrowLayoutBreakpoint" | "contentMaxWidthNoPassage" | "contentMaxWidthWithPassage" | "splitPaneMinRegionWidth" | "splitPaneCollapseStrategy" | "enabledTools"
|
|
5
|
-
export type SectionPlayerAdvancedPropName = "runtime" | "playerType" | "player" | "lazyInit" | "tools" | "accessibility" | "coordinator" | "
|
|
4
|
+
export type SectionPlayerBasicPropName = "assessmentId" | "section" | "sectionId" | "attemptId" | "debug" | "showToolbar" | "toolbarPosition" | "narrowLayoutBreakpoint" | "contentMaxWidthNoPassage" | "contentMaxWidthWithPassage" | "splitPaneMinRegionWidth" | "splitPaneCollapseStrategy" | "enabledTools";
|
|
5
|
+
export type SectionPlayerAdvancedPropName = "runtime" | "playerType" | "player" | "lazyInit" | "tools" | "accessibility" | "coordinator" | "env" | "iifeBundleHost" | "toolRegistry" | "sectionHostButtons" | "itemHostButtons" | "passageHostButtons" | "policies" | "toolConfigStrictness" | "hooks" | "onFrameworkError" | "onStageChange" | "onLoadingComplete";
|
|
6
6
|
export type SectionPlayerLayoutPropName = SectionPlayerBasicPropName | SectionPlayerAdvancedPropName;
|
|
7
7
|
export type SectionPlayerLayoutCommandName = "getSnapshot" | "selectComposition" | "selectNavigation" | "selectReadiness" | "navigateTo" | "navigateNext" | "navigatePrevious" | "getSectionController" | "waitForSectionController";
|
|
8
8
|
export type SectionPlayerLayoutContract = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout-contract.d.ts","sourceRoot":"","sources":["../../src/contracts/layout-contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,oBAAoB,CAAC;AAEvE,MAAM,MAAM,uBAAuB,GAAG,WAAW,GAAG,UAAU,GAAG,QAAQ,CAAC;AAE1E,MAAM,MAAM,6BAA6B,GACtC,YAAY,GACZ,eAAe,GACf,iBAAiB,GACjB,cAAc,GACd,iBAAiB,GACjB,kBAAkB,GAClB,mBAAmB,CAAC;AAEvB,MAAM,MAAM,0BAA0B,GACnC,cAAc,GACd,SAAS,GACT,WAAW,GACX,WAAW,GACX,OAAO,GACP,aAAa,GACb,iBAAiB,GACjB,wBAAwB,GACxB,0BAA0B,GAC1B,4BAA4B,GAC5B,yBAAyB,GACzB,2BAA2B,GAC3B,cAAc,
|
|
1
|
+
{"version":3,"file":"layout-contract.d.ts","sourceRoot":"","sources":["../../src/contracts/layout-contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,oBAAoB,CAAC;AAEvE,MAAM,MAAM,uBAAuB,GAAG,WAAW,GAAG,UAAU,GAAG,QAAQ,CAAC;AAE1E,MAAM,MAAM,6BAA6B,GACtC,YAAY,GACZ,eAAe,GACf,iBAAiB,GACjB,cAAc,GACd,iBAAiB,GACjB,kBAAkB,GAClB,mBAAmB,CAAC;AAEvB,MAAM,MAAM,0BAA0B,GACnC,cAAc,GACd,SAAS,GACT,WAAW,GACX,WAAW,GACX,OAAO,GACP,aAAa,GACb,iBAAiB,GACjB,wBAAwB,GACxB,0BAA0B,GAC1B,4BAA4B,GAC5B,yBAAyB,GACzB,2BAA2B,GAC3B,cAAc,CAAC;AAElB,MAAM,MAAM,6BAA6B,GACtC,SAAS,GACT,YAAY,GACZ,QAAQ,GACR,UAAU,GACV,OAAO,GACP,eAAe,GACf,aAAa,GACb,KAAK,GACL,gBAAgB,GAChB,cAAc,GACd,oBAAoB,GACpB,iBAAiB,GACjB,oBAAoB,GACpB,UAAU,GACV,sBAAsB,GACtB,OAAO,GACP,kBAAkB,GAClB,eAAe,GACf,mBAAmB,CAAC;AAEvB,MAAM,MAAM,2BAA2B,GACpC,0BAA0B,GAC1B,6BAA6B,CAAC;AAEjC,MAAM,MAAM,8BAA8B,GACvC,aAAa,GACb,mBAAmB,GACnB,kBAAkB,GAClB,iBAAiB,GACjB,YAAY,GACZ,cAAc,GACd,kBAAkB,GAClB,sBAAsB,GACtB,0BAA0B,CAAC;AAE9B,MAAM,MAAM,2BAA2B,GAAG;IACzC,OAAO,EAAE,CAAC,CAAC;IACX,MAAM,EAAE,uBAAuB,CAAC;IAChC,KAAK,EAAE,SAAS,2BAA2B,EAAE,CAAC;IAC9C,qBAAqB,EAAE,SAAS,0BAA0B,EAAE,CAAC;IAC7D,wBAAwB,EAAE,SAAS,6BAA6B,EAAE,CAAC;IACnE,MAAM,EAAE,SAAS,4BAA4B,EAAE,CAAC;IAChD,QAAQ,EAAE,SAAS,8BAA8B,EAAE,CAAC;IACpD,YAAY,EAAE,SAAS,6BAA6B,EAAE,CAAC;CACvD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout-parity-metadata.d.ts","sourceRoot":"","sources":["../../src/contracts/layout-parity-metadata.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"layout-parity-metadata.d.ts","sourceRoot":"","sources":["../../src/contracts/layout-parity-metadata.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAC;AA8ExE,eAAO,MAAM,yBAAyB,EAAE,2BASvC,CAAC;AAEF,eAAO,MAAM,wBAAwB,EAAE,2BAStC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,2BASpC,CAAC"}
|
|
@@ -1,15 +1,96 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Section-player layout-CE public DOM event vocabulary.
|
|
3
|
+
*
|
|
4
|
+
* **Engine routing (M7).** The *stage / loading-complete /
|
|
5
|
+
* framework-error* family is dispatched on the layout CE host by the
|
|
6
|
+
* section runtime engine
|
|
7
|
+
* (`@pie-players/pie-assessment-toolkit/runtime/engine`) — not by an
|
|
8
|
+
* in-CE `$effect` cluster. The kernel attaches the engine to the host
|
|
9
|
+
* (`engine.attachHost({ host, sourceCe, frameworkErrorBus })`), and
|
|
10
|
+
* the engine's DOM-event bridge dispatches `pie-stage-change`,
|
|
11
|
+
* `pie-loading-complete`, and `framework-error`.
|
|
12
|
+
*
|
|
13
|
+
* **Kernel-side Svelte forwards (not engine-routed).** The
|
|
14
|
+
* composition / session / runtime-tier family
|
|
15
|
+
* (`composition-changed`, `session-changed`, `runtime-owned`,
|
|
16
|
+
* `runtime-inherited`) is forwarded by the kernel's Svelte
|
|
17
|
+
* `createEventDispatcher` from `<pie-section-player-base>` events; it
|
|
18
|
+
* does not flow through the engine. This split is intentional: the
|
|
19
|
+
* engine owns lifecycle and error reporting, while composition /
|
|
20
|
+
* session forwarding stays in section-player because the shape is
|
|
21
|
+
* section-player-specific and the engine has no opinion on it.
|
|
22
|
+
*
|
|
23
|
+
* **`framework-error` single-emit on the layout host (compat sweep).**
|
|
24
|
+
* `<pie-assessment-toolkit>` nested inside a layout CE still
|
|
25
|
+
* dispatches its own `framework-error` (with `bubbles: true,
|
|
26
|
+
* composed: true`) so direct toolkit consumers keep working. The
|
|
27
|
+
* kernel's `handleFrameworkError` listener intercepts that bubbled
|
|
28
|
+
* emit at `<pie-section-player-base>` and calls
|
|
29
|
+
* `event.stopPropagation()`, leaving the engine-bridge emit on the
|
|
30
|
+
* layout host as the single canonical DOM surface for
|
|
31
|
+
* section-player consumers. The single-emit contract is pinned by
|
|
32
|
+
* `tests/section-player-framework-error-dual-emit.test.ts`. The
|
|
33
|
+
* previous dual-emit was removed in the broad architecture review
|
|
34
|
+
* compat sweep.
|
|
35
|
+
*
|
|
36
|
+
* **Removed in the broad architecture review compat sweep.** The
|
|
37
|
+
* deprecated readiness aliases (`readiness-change`,
|
|
38
|
+
* `interaction-ready`, `ready`) and their `legacy-event-bridge.ts`
|
|
39
|
+
* are gone. Hosts that previously listened for them migrate to:
|
|
40
|
+
* - `readiness-change` → `pie-stage-change` (the readiness phase
|
|
41
|
+
* is also reachable via `selectReadiness()` /
|
|
42
|
+
* `getSnapshot().readiness`).
|
|
43
|
+
* - `interaction-ready` → `pie-stage-change` filtered on
|
|
44
|
+
* `detail.stage === "interactive"`.
|
|
45
|
+
* - `ready` → `pie-loading-complete`.
|
|
46
|
+
*
|
|
47
|
+
* The deprecated `section-controller-ready` Svelte/DOM event was
|
|
48
|
+
* also removed. Hosts that previously listened for it migrate to
|
|
49
|
+
* `waitForSectionController(timeoutMs)` / `getSectionController()`
|
|
50
|
+
* on the layout CE, or filter `pie-stage-change` for
|
|
51
|
+
* `detail.stage === "engine-ready"`.
|
|
52
|
+
*
|
|
53
|
+
* Source of truth for the names: `players-shared/src/pie/stages.ts`
|
|
54
|
+
* and the `SectionEngineOutput` discriminator in
|
|
55
|
+
* `assessment-toolkit/src/runtime/core/engine-output.ts`.
|
|
56
|
+
*/
|
|
1
57
|
export declare const SECTION_PLAYER_PUBLIC_EVENTS: {
|
|
2
58
|
readonly runtimeOwned: "runtime-owned";
|
|
3
59
|
readonly runtimeInherited: "runtime-inherited";
|
|
4
|
-
|
|
60
|
+
/**
|
|
61
|
+
* Engine-routed (M7). Dispatched by
|
|
62
|
+
* `framework-error-bridge.ts` on the layout CE host whenever the
|
|
63
|
+
* engine receives a `framework-error` input. See class doc on
|
|
64
|
+
* `FrameworkErrorBus` for the back-pressure / fan-out semantics.
|
|
65
|
+
*/
|
|
66
|
+
readonly frameworkError: "framework-error";
|
|
5
67
|
readonly compositionChanged: "composition-changed";
|
|
6
68
|
readonly sessionChanged: "session-changed";
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
69
|
+
/**
|
|
70
|
+
* Engine-routed (M7). One DOM event family carries every stage
|
|
71
|
+
* transition (`composed` → `engine-ready` → `interactive` →
|
|
72
|
+
* `disposed`) with the discriminator in `event.detail.stage`.
|
|
73
|
+
* Dispatched by the engine's `dom-event-bridge.ts` on each
|
|
74
|
+
* `SectionEngineOutput` of kind `stage-change`. See
|
|
75
|
+
* `packages/players-shared/src/pie/stages.ts`.
|
|
76
|
+
*/
|
|
77
|
+
readonly stageChange: "pie-stage-change";
|
|
78
|
+
/**
|
|
79
|
+
* Engine-routed (M7). Companion to `stageChange`. Fires once per
|
|
80
|
+
* cohort when every item in the section has finished loading
|
|
81
|
+
* (`loadedCount === itemCount`), gated by the engine's
|
|
82
|
+
* `interactive` state.
|
|
83
|
+
*/
|
|
84
|
+
readonly loadingComplete: "pie-loading-complete";
|
|
11
85
|
};
|
|
12
86
|
export type SectionPlayerPublicEventName = (typeof SECTION_PLAYER_PUBLIC_EVENTS)[keyof typeof SECTION_PLAYER_PUBLIC_EVENTS];
|
|
87
|
+
/**
|
|
88
|
+
* Readiness phase reported by the engine's readiness derivation. The
|
|
89
|
+
* type is named after the deprecated `readiness-change` event for
|
|
90
|
+
* backward compatibility with consumers that imported it via the
|
|
91
|
+
* kernel's `selectReadiness()` selector — the *event name* is gone,
|
|
92
|
+
* but the readiness payload itself is still the canonical shape.
|
|
93
|
+
*/
|
|
13
94
|
export type SectionPlayerReadinessPhase = "bootstrapping" | "interaction-ready" | "loading" | "ready" | "error";
|
|
14
95
|
export type SectionPlayerReadinessChangeDetail = {
|
|
15
96
|
phase: SectionPlayerReadinessPhase;
|
|
@@ -17,9 +98,4 @@ export type SectionPlayerReadinessChangeDetail = {
|
|
|
17
98
|
allLoadingComplete: boolean;
|
|
18
99
|
reason?: string;
|
|
19
100
|
};
|
|
20
|
-
export type SectionPlayerControllerReadyDetail = {
|
|
21
|
-
sectionId: string;
|
|
22
|
-
attemptId?: string;
|
|
23
|
-
controller: unknown;
|
|
24
|
-
};
|
|
25
101
|
//# sourceMappingURL=public-events.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-events.d.ts","sourceRoot":"","sources":["../../src/contracts/public-events.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,4BAA4B
|
|
1
|
+
{"version":3,"file":"public-events.d.ts","sourceRoot":"","sources":["../../src/contracts/public-events.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuDG;AACH,eAAO,MAAM,4BAA4B;;;IAGxC;;;;;OAKG;;;;IAIH;;;;;;;OAOG;;IAEH;;;;;OAKG;;CAEM,CAAC;AAEX,MAAM,MAAM,4BAA4B,GACvC,CAAC,OAAO,4BAA4B,CAAC,CAAC,MAAM,OAAO,4BAA4B,CAAC,CAAC;AAElF;;;;;;GAMG;AACH,MAAM,MAAM,2BAA2B,GACpC,eAAe,GACf,mBAAmB,GACnB,SAAS,GACT,OAAO,GACP,OAAO,CAAC;AAEX,MAAM,MAAM,kCAAkC,GAAG;IAChD,KAAK,EAAE,2BAA2B,CAAC;IACnC,gBAAgB,EAAE,OAAO,CAAC;IAC1B,kBAAkB,EAAE,OAAO,CAAC;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-export shim for the canonical stage vocabulary.
|
|
3
|
+
*
|
|
4
|
+
* The contract types and tracker primitive live in
|
|
5
|
+
* `@pie-players/pie-players-shared/pie` so both
|
|
6
|
+
* `<pie-section-player-*>` and `<pie-assessment-toolkit>` import the
|
|
7
|
+
* same source of truth (M6 Phase C).
|
|
8
|
+
*/
|
|
9
|
+
export { STAGES, applicableStages, stageOrdinal, } from '@pie-players/pie-players-shared/pie';
|
|
10
|
+
export type { LoadingCompleteDetail, Stage, StageChangeDetail, StageSourceCe, StageStatus, } from '@pie-players/pie-players-shared/pie';
|
|
11
|
+
//# sourceMappingURL=stages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stages.d.ts","sourceRoot":"","sources":["../../src/contracts/stages.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EACN,MAAM,EACN,gBAAgB,EAChB,YAAY,GACZ,MAAM,qCAAqC,CAAC;AAC7C,YAAY,EACX,qBAAqB,EACrB,KAAK,EACL,iBAAiB,EACjB,aAAa,EACb,WAAW,GACX,MAAM,qCAAqC,CAAC"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export type { SectionPlayerLayoutContract, SectionPlayerLayoutName, SectionPlayerLayoutCapability, SectionPlayerBasicPropName, SectionPlayerAdvancedPropName, SectionPlayerLayoutPropName, SectionPlayerLayoutCommandName, } from './contracts/layout-contract.js';
|
|
2
|
-
export type { SectionPlayerPublicEventName, SectionPlayerReadinessPhase, SectionPlayerReadinessChangeDetail,
|
|
2
|
+
export type { SectionPlayerPublicEventName, SectionPlayerReadinessPhase, SectionPlayerReadinessChangeDetail, } from './contracts/public-events.js';
|
|
3
3
|
export { SECTION_PLAYER_PUBLIC_EVENTS } from './contracts/public-events.js';
|
|
4
4
|
export type { SectionPlayerRuntimeHostContract, SectionPlayerNavigationSnapshot, SectionPlayerSnapshot, } from './contracts/runtime-host-contract.js';
|
|
5
5
|
export { SPLITPANE_LAYOUT_CONTRACT, TABBED_LAYOUT_CONTRACT, VERTICAL_LAYOUT_CONTRACT, } from './contracts/layout-parity-metadata.js';
|
|
6
6
|
export type { ReadinessPolicyAdapter, SectionPlayerPolicies, SectionPlayerReadinessPolicy, SectionPlayerPreloadPolicy, SectionPlayerFocusPolicy, SectionPlayerAutoFocusStrategy, SectionPlayerTelemetryPolicy, } from './policies/types.js';
|
|
7
|
-
export { DEFAULT_FOCUS_POLICY, DEFAULT_SECTION_PLAYER_POLICIES, resolveAutoFocusStrategy, } from './policies/index.js';
|
|
7
|
+
export { DEFAULT_FOCUS_POLICY, DEFAULT_SECTION_PLAYER_POLICIES, isPreloadEnabled, isTelemetryEnabled, resolveAutoFocusStrategy, } from './policies/index.js';
|
|
8
8
|
export type { SectionPlayerCardTitleContext, SectionPlayerCardTitleFormatter, SectionPlayerItemTitleContext, SectionPlayerPassageTitleContext, } from './contracts/card-title-formatters.js';
|
|
9
9
|
export type { SectionPlayerHostHooks } from './contracts/host-hooks.js';
|
|
10
10
|
//# sourceMappingURL=pie-section-player.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pie-section-player.d.ts","sourceRoot":"","sources":["../src/pie-section-player.ts"],"names":[],"mappings":"AAAA,OAAO,+CAA+C,CAAC;AACvD,OAAO,8CAA8C,CAAC;AACtD,OAAO,4CAA4C,CAAC;AACpD,OAAO,+CAA+C,CAAC;AACvD,OAAO,kDAAkD,CAAC;AAC1D,OAAO,gDAAgD,CAAC;AACxD,OAAO,mDAAmD,CAAC;AAC3D,OAAO,2CAA2C,CAAC;AACnD,OAAO,iDAAiD,CAAC;AAEzD,YAAY,EACX,2BAA2B,EAC3B,uBAAuB,EACvB,6BAA6B,EAC7B,0BAA0B,EAC1B,6BAA6B,EAC7B,2BAA2B,EAC3B,8BAA8B,GAC9B,MAAM,gCAAgC,CAAC;AACxC,YAAY,EACX,4BAA4B,EAC5B,2BAA2B,EAC3B,kCAAkC,
|
|
1
|
+
{"version":3,"file":"pie-section-player.d.ts","sourceRoot":"","sources":["../src/pie-section-player.ts"],"names":[],"mappings":"AAAA,OAAO,+CAA+C,CAAC;AACvD,OAAO,8CAA8C,CAAC;AACtD,OAAO,4CAA4C,CAAC;AACpD,OAAO,+CAA+C,CAAC;AACvD,OAAO,kDAA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