@pie-players/pie-section-player 0.3.73 → 0.3.74

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.
Files changed (123) hide show
  1. package/README.md +173 -42
  2. package/dist/browser/assets/evaluation-worker-DkU_wGh3.js +155241 -0
  3. package/dist/browser/chunks/ItemToolBar-wr2myaah-2ce4b643.js +1 -0
  4. package/dist/browser/chunks/PUA-tLuTiQ7--f2b27953.js +1 -0
  5. package/dist/browser/chunks/ToolCoordinator-cc2dc319.js +1 -0
  6. package/dist/browser/chunks/accents-BTUYmhn9-cafeb96e.js +1 -0
  7. package/dist/browser/chunks/accents-b-i-CngHZsLL-e0eb98fd.js +1 -0
  8. package/dist/browser/chunks/arabic-BzEHMVZD-30ac1ade.js +1 -0
  9. package/dist/browser/chunks/arrows-VjxlU-jv-2e17c192.js +1 -0
  10. package/dist/browser/chunks/base-dfd67c41.js +1 -0
  11. package/dist/browser/chunks/braille-BeWC_Ruq-a3bb8ef9.js +1 -0
  12. package/dist/browser/chunks/braille-d-Dk6J96GO-d832bfbf.js +1 -0
  13. package/dist/browser/chunks/browser-a3c32178.js +36 -0
  14. package/dist/browser/chunks/calculator-element-271c142f.js +9 -0
  15. package/dist/browser/chunks/calligraphic-Cew9cU3x-04cf0735.js +1 -0
  16. package/dist/browser/chunks/cherokee-Cny3FYho-4da7d2f3.js +1 -0
  17. package/dist/browser/chunks/classPrivateFieldGet2-338e0179.js +1 -0
  18. package/dist/browser/chunks/custom-element-define-2a92deb0.js +1 -0
  19. package/dist/browser/chunks/cyrillic-CfCDulXU-5550df0b.js +1 -0
  20. package/dist/browser/chunks/cyrillic-ss-lU7bNGG9-12eb0188.js +1 -0
  21. package/dist/browser/chunks/defineProperty-a20a667d.js +1 -0
  22. package/dist/browser/chunks/devanagari-CDIz2h-r-18c38725.js +1 -0
  23. package/dist/browser/chunks/dist-41b39e7f.js +1 -0
  24. package/dist/browser/chunks/dist-59132a53.js +1 -0
  25. package/dist/browser/chunks/dist-60d7afef.js +1 -0
  26. package/dist/browser/chunks/dist-ca9b9622.js +1 -0
  27. package/dist/browser/chunks/double-struck-BpJEQk8y-500ce8dd.js +1 -0
  28. package/dist/browser/chunks/en-5ff22e17.js +1 -0
  29. package/dist/browser/chunks/es-a0ba6cb6.js +1 -0
  30. package/dist/browser/chunks/focus-trap-44913bf3.js +1 -0
  31. package/dist/browser/chunks/fraktur-rLEq9DEH-44cc14d8.js +1 -0
  32. package/dist/browser/chunks/greek-BlraJTyL-90ce8924.js +1 -0
  33. package/dist/browser/chunks/greek-ss-D-EN2PK0-91610739.js +1 -0
  34. package/dist/browser/chunks/hebrew-GiQZeybp-b583f555.js +1 -0
  35. package/dist/browser/chunks/latin-b-BhEnC7R2-d13e06ff.js +1 -0
  36. package/dist/browser/chunks/latin-bi-DqiIKv3U-1dec8705.js +1 -0
  37. package/dist/browser/chunks/latin-i-B1xtwaE1-21637466.js +1 -0
  38. package/dist/browser/chunks/latin-xfWFlLkD-5bcea5cf.js +1 -0
  39. package/dist/browser/chunks/logger-8b07fb72.js +1 -0
  40. package/dist/browser/chunks/marrows-DD1NgMQi-15b63755.js +1 -0
  41. package/dist/browser/chunks/math-DpWn1mbG-38eeb914.js +1 -0
  42. package/dist/browser/chunks/math-rendering-ready-9a0fd90a.js +1 -0
  43. package/dist/browser/chunks/mathjax-D2JHb_R_-64780dc5.js +232 -0
  44. package/dist/browser/chunks/module-0191e321.js +74 -0
  45. package/dist/browser/chunks/module-shim-58659a86.js +0 -0
  46. package/dist/browser/chunks/module-shim-b4470740.js +12 -0
  47. package/dist/browser/chunks/monospace-D116QD2a-98d484fd.js +1 -0
  48. package/dist/browser/chunks/monospace-ex-DcXpouKS-456b403c.js +1 -0
  49. package/dist/browser/chunks/monospace-l-Ct5wkMDs-f34a4a9e.js +1 -0
  50. package/dist/browser/chunks/mshapes-DCp86WSX-c0055952.js +1 -0
  51. package/dist/browser/chunks/nds-icon-button-d602f784.js +194 -0
  52. package/dist/browser/chunks/nl-NL-364d61b9.js +1 -0
  53. package/dist/browser/chunks/nl-NL-8b7e6d4b.js +1 -0
  54. package/dist/browser/chunks/overlay-containment-edaaff13.js +1 -0
  55. package/dist/browser/chunks/overlay-placement-e8058232.js +1 -0
  56. package/dist/browser/chunks/phonetics-BwOCw2Y9-d2e3af59.js +1 -0
  57. package/dist/browser/chunks/phonetics-ss-CRtMn02f-579b6135.js +1 -0
  58. package/dist/browser/chunks/pie-api-client-687c319a.js +1 -0
  59. package/dist/browser/chunks/pie-tool-calculator-cortex-0626bc24.js +9 -0
  60. package/dist/browser/chunks/pie-tool-calculator-geogebra-561236cb.js +9 -0
  61. package/dist/browser/chunks/pointer-gesture-ce75f0a7.js +1 -0
  62. package/dist/browser/chunks/preload-helper-6ad28da3.js +1 -0
  63. package/dist/browser/chunks/provider-4c704118.js +1 -0
  64. package/dist/browser/chunks/rolldown-runtime-1287ba31.js +1 -0
  65. package/dist/browser/chunks/runtime-C7H1jS4E-64772f5e.js +8413 -0
  66. package/dist/browser/chunks/sanitize-svg-icon-b9082bba.js +3 -0
  67. package/dist/browser/chunks/sans-serif-BYPZKlE9-2efdbcd9.js +1 -0
  68. package/dist/browser/chunks/sans-serif-b-B0kRKiC--b5530dce.js +1 -0
  69. package/dist/browser/chunks/sans-serif-bi-DXWul6mu-5370dba4.js +1 -0
  70. package/dist/browser/chunks/sans-serif-ex-Boux1kMP-aa178f31.js +1 -0
  71. package/dist/browser/chunks/sans-serif-i-676RFaSO-2db54474.js +1 -0
  72. package/dist/browser/chunks/sans-serif-r-DrN9xdZt-0fc72eea.js +1 -0
  73. package/dist/browser/chunks/script-0ohehnXc-526904f4.js +1 -0
  74. package/dist/browser/chunks/shapes-BG47NodJ-d59b0eca.js +1 -0
  75. package/dist/browser/chunks/src-BcptuNS5-ed25d7fd.js +191 -0
  76. package/dist/browser/chunks/sre-engine-wf9s43gg-f09289c5.js +53 -0
  77. package/dist/browser/chunks/symbols-BqnUxf_t-83087e87.js +1 -0
  78. package/dist/browser/chunks/symbols-b-i-eg9k5hmF-9c461ac2.js +1 -0
  79. package/dist/browser/chunks/tool-annotation-toolbar-997438b4.js +248 -0
  80. package/dist/browser/chunks/tool-answer-eliminator-35483abd.js +13 -0
  81. package/dist/browser/chunks/tool-color-scheme-b7de5cdf.js +26 -0
  82. package/dist/browser/chunks/tool-dictionary-cecff3b4.js +7 -0
  83. package/dist/browser/chunks/tool-graph-cb0338e8.js +11 -0
  84. package/dist/browser/chunks/tool-host-contract-b93b482c.js +1 -0
  85. package/dist/browser/chunks/tool-line-reader-f8ef3c6a.js +62 -0
  86. package/dist/browser/chunks/tool-periodic-table-43b133b8.js +153 -0
  87. package/dist/browser/chunks/tool-picture-dictionary-33721e91.js +4 -0
  88. package/dist/browser/chunks/tool-protractor-23f77028.js +17 -0
  89. package/dist/browser/chunks/tool-ruler-1d9a03a6.js +15 -0
  90. package/dist/browser/chunks/tool-tts-inline-98c2ce7a.js +179 -0
  91. package/dist/browser/chunks/variants-2LRNhOUP-966fc49d.js +1 -0
  92. package/dist/browser/chunks/versioned-tag-54a76be9.js +1 -0
  93. package/dist/browser/pie-section-player.js +1613 -0
  94. package/dist/browser.d.ts +10 -0
  95. package/dist/chunks/ItemToolBar-wr2myaah-1287ba31.js +28 -0
  96. package/dist/chunks/module-shim-58659a86.js +2129 -0
  97. package/dist/chunks/{nl-NL-9312c316.js → nl-NL-364d61b9.js} +8 -2
  98. package/dist/chunks/sre-engine-wf9s43gg-f09289c5.js +8 -0
  99. package/dist/components/shared/composition.d.ts +0 -1
  100. package/dist/components/shared/layout-host-methods.d.ts +400 -0
  101. package/dist/components/shared/missing-tool-providers.d.ts +16 -0
  102. package/dist/components/shared/player-preload.d.ts +14 -10
  103. package/dist/contracts/host-hooks.d.ts +4 -5
  104. package/dist/contracts/host-hooks.js +0 -0
  105. package/dist/contracts/layout-contract.js +0 -0
  106. package/dist/contracts/layout-parity-metadata.js +87 -0
  107. package/dist/contracts/public-events.d.ts +14 -15
  108. package/dist/contracts/public-events.js +12 -0
  109. package/dist/contracts/runtime-host-contract.js +0 -0
  110. package/dist/controllers/SectionController.d.ts +13 -0
  111. package/dist/controllers/toolkit-section-contracts.d.ts +1 -17
  112. package/dist/controllers/types.d.ts +17 -10
  113. package/dist/pie-section-player.js +19298 -37928
  114. package/dist/policies/index.d.ts +9 -2
  115. package/dist/policies/index.js +25 -0
  116. package/package.json +34 -29
  117. package/dist/chunks/module-a516757f.js +0 -73997
  118. package/dist/chunks/nl-NL-ef6dd604.js +0 -505
  119. package/dist/chunks/pie-api-client-22de9d9c.js +0 -168
  120. package/dist/chunks/rolldown-runtime-1287ba31.js +0 -20
  121. package/dist/chunks/sre-0162a7a9.js +0 -17637
  122. package/dist/contracts/stages.d.ts +0 -10
  123. package/dist/utils/z-index.d.ts +0 -5
@@ -43,6 +43,7 @@ var e = {
43
43
  items: "Vragen",
44
44
  section: "Onderdeel",
45
45
  loadingSection: "Onderdeel wordt geladen…",
46
+ sectionLoadError: "Het onderdeel kon niet worden geladen.",
46
47
  loadingPassage: "Tekst wordt geladen…",
47
48
  configurationError: "Configuratiefout",
48
49
  playerError: "Fout in de speler",
@@ -108,6 +109,11 @@ var e = {
108
109
  centerA11y: "Venster centreren",
109
110
  closeA11y: "Hulpmiddel sluiten"
110
111
  },
112
+ placement: {
113
+ controlsA11y: "Verplaatsen en draaien",
114
+ rotateClockwiseA11y: "{degrees}° rechtsom draaien",
115
+ rotateCounterclockwiseA11y: "{degrees}° linksom draaien"
116
+ },
111
117
  announce: {
112
118
  movedUp: "Omhoog verplaatst naar {position}",
113
119
  movedDown: "Omlaag verplaatst naar {position}",
@@ -135,8 +141,8 @@ var e = {
135
141
  },
136
142
  graph: {
137
143
  name: "Grafiek",
138
- description: "Grafische rekenmachine en assenstelsel",
139
- buttonA11y: "Grafiek, grafische rekenmachine",
144
+ description: "Assenstelsel",
145
+ buttonA11y: "Grafiek, assenstelsel",
140
146
  tooltip: "Grafiek",
141
147
  toolA11y: "Grafiekhulpmiddel — punten en lijnen tekenen in een assenstelsel",
142
148
  canvasA11y: "Tekenvlak — gebruik de hulpmiddelen om punten toe te voegen en lijnen te tekenen",
@@ -0,0 +1,8 @@
1
+ import { n as t } from "./ItemToolBar-wr2myaah-1287ba31.js";
2
+ import * as a from "speech-rule-engine";
3
+ var r = a.default ?? a;
4
+ r.setupEngine(t());
5
+ var o = r;
6
+ export {
7
+ o as default
8
+ };
@@ -2,7 +2,6 @@ import { ItemEntity } from '@pie-players/pie-players-shared/types';
2
2
  import { SectionCompositionModel } from '../../controllers/types.js';
3
3
  export declare const EMPTY_ITEM_SESSION: Record<string, unknown>;
4
4
  export declare const EMPTY_COMPOSITION: SectionCompositionModel;
5
- export declare function getEntityTitle(entity: unknown): string;
6
5
  export declare function getCanonicalItemIdForItem(compositionModel: SectionCompositionModel, item: ItemEntity): string;
7
6
  export declare function getSessionForItem(compositionModel: SectionCompositionModel, item: ItemEntity): unknown;
8
7
  export declare function getSessionForItemOrEmpty(compositionModel: SectionCompositionModel, item: ItemEntity): Record<string, unknown>;
@@ -0,0 +1,400 @@
1
+ import { SectionControllerHandle } from '@pie-players/pie-assessment-toolkit';
2
+ import { SectionPlayerNavigationSnapshot, SectionPlayerSnapshot } from '../../contracts/runtime-host-contract.js';
3
+ export declare const BOOTSTRAP_READINESS: {
4
+ readonly phase: "bootstrapping";
5
+ readonly interactionReady: false;
6
+ readonly allLoadingComplete: false;
7
+ };
8
+ export declare const BOOTSTRAP_SNAPSHOT: {
9
+ readonly readiness: {
10
+ readonly phase: "bootstrapping";
11
+ readonly interactionReady: false;
12
+ readonly allLoadingComplete: false;
13
+ };
14
+ readonly composition: {
15
+ readonly itemsCount: 0;
16
+ readonly passagesCount: 0;
17
+ };
18
+ readonly navigation: {
19
+ readonly currentIndex: 0;
20
+ readonly totalItems: 0;
21
+ readonly canNext: false;
22
+ readonly canPrevious: false;
23
+ };
24
+ };
25
+ /** What each read returns before the component mounts. */
26
+ export type UnmountedReads = {
27
+ snapshot: SectionPlayerSnapshot | null;
28
+ composition: SectionPlayerSnapshot["composition"] | null;
29
+ navigation: SectionPlayerNavigationSnapshot | null;
30
+ readiness: SectionPlayerSnapshot["readiness"] | null;
31
+ };
32
+ export declare const NULL_READS: UnmountedReads;
33
+ export declare const BOOTSTRAP_READS: UnmountedReads;
34
+ /**
35
+ * For a layout element's `customElement.extend`. `unmounted` is what that
36
+ * element's reads return while its kernel is not bound.
37
+ */
38
+ export declare function withHostMethods(unmounted: UnmountedReads): <Base extends CustomElementConstructor>(ElementClass: Base) => {
39
+ new (...params: any[]): {
40
+ getSnapshot(): SectionPlayerSnapshot | null;
41
+ selectComposition(): SectionPlayerSnapshot["composition"] | null;
42
+ selectNavigation(): SectionPlayerNavigationSnapshot | null;
43
+ selectReadiness(): SectionPlayerSnapshot["readiness"] | null;
44
+ navigateTo(index: number): boolean;
45
+ navigateNext(): boolean;
46
+ navigatePrevious(): boolean;
47
+ getSectionController(): SectionControllerHandle | null;
48
+ waitForSectionController(timeoutMs?: number): Promise<SectionControllerHandle | null>;
49
+ accessKey: string;
50
+ readonly accessKeyLabel: string;
51
+ autocapitalize: string;
52
+ autocorrect: boolean;
53
+ dir: string;
54
+ draggable: boolean;
55
+ hidden: boolean;
56
+ inert: boolean;
57
+ innerText: string;
58
+ lang: string;
59
+ readonly offsetHeight: number;
60
+ readonly offsetLeft: number;
61
+ readonly offsetParent: Element | null;
62
+ readonly offsetTop: number;
63
+ readonly offsetWidth: number;
64
+ outerText: string;
65
+ popover: string | null;
66
+ spellcheck: boolean;
67
+ title: string;
68
+ translate: boolean;
69
+ writingSuggestions: string;
70
+ attachInternals(): ElementInternals;
71
+ click(): void;
72
+ hidePopover(): void;
73
+ showPopover(): void;
74
+ togglePopover(options?: boolean): boolean;
75
+ addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
76
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
77
+ removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
78
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
79
+ readonly attributes: NamedNodeMap;
80
+ get classList(): DOMTokenList;
81
+ set classList(value: string);
82
+ className: string;
83
+ readonly clientHeight: number;
84
+ readonly clientLeft: number;
85
+ readonly clientTop: number;
86
+ readonly clientWidth: number;
87
+ readonly currentCSSZoom: number;
88
+ id: string;
89
+ innerHTML: string;
90
+ readonly localName: string;
91
+ readonly namespaceURI: string | null;
92
+ onfullscreenchange: ((this: Element, ev: Event) => any) | null;
93
+ onfullscreenerror: ((this: Element, ev: Event) => any) | null;
94
+ outerHTML: string;
95
+ readonly ownerDocument: Document;
96
+ get part(): DOMTokenList;
97
+ set part(value: string);
98
+ readonly prefix: string | null;
99
+ readonly scrollHeight: number;
100
+ scrollLeft: number;
101
+ scrollTop: number;
102
+ readonly scrollWidth: number;
103
+ readonly shadowRoot: ShadowRoot | null;
104
+ slot: string;
105
+ readonly tagName: string;
106
+ attachShadow(init: ShadowRootInit): ShadowRoot;
107
+ checkVisibility(options?: CheckVisibilityOptions): boolean;
108
+ closest<K extends keyof HTMLElementTagNameMap>(selector: K): HTMLElementTagNameMap[K] | null;
109
+ closest<K extends keyof SVGElementTagNameMap>(selector: K): SVGElementTagNameMap[K] | null;
110
+ closest<K extends keyof MathMLElementTagNameMap>(selector: K): MathMLElementTagNameMap[K] | null;
111
+ closest<E extends Element = Element>(selectors: string): E | null;
112
+ computedStyleMap(): StylePropertyMapReadOnly;
113
+ getAttribute(qualifiedName: string): string | null;
114
+ getAttributeNS(namespace: string | null, localName: string): string | null;
115
+ getAttributeNames(): string[];
116
+ getAttributeNode(qualifiedName: string): Attr | null;
117
+ getAttributeNodeNS(namespace: string | null, localName: string): Attr | null;
118
+ getBoundingClientRect(): DOMRect;
119
+ getClientRects(): DOMRectList;
120
+ getElementsByClassName(classNames: string): HTMLCollectionOf<Element>;
121
+ getElementsByTagName<K extends keyof HTMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementTagNameMap[K]>;
122
+ getElementsByTagName<K extends keyof SVGElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<SVGElementTagNameMap[K]>;
123
+ getElementsByTagName<K extends keyof MathMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<MathMLElementTagNameMap[K]>;
124
+ getElementsByTagName<K extends keyof HTMLElementDeprecatedTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>;
125
+ getElementsByTagName(qualifiedName: string): HTMLCollectionOf<Element>;
126
+ getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1999/xhtml", localName: string): HTMLCollectionOf<HTMLElement>;
127
+ getElementsByTagNameNS(namespaceURI: "http://www.w3.org/2000/svg", localName: string): HTMLCollectionOf<SVGElement>;
128
+ getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1998/Math/MathML", localName: string): HTMLCollectionOf<MathMLElement>;
129
+ getElementsByTagNameNS(namespace: string | null, localName: string): HTMLCollectionOf<Element>;
130
+ getHTML(options?: GetHTMLOptions): string;
131
+ hasAttribute(qualifiedName: string): boolean;
132
+ hasAttributeNS(namespace: string | null, localName: string): boolean;
133
+ hasAttributes(): boolean;
134
+ hasPointerCapture(pointerId: number): boolean;
135
+ insertAdjacentElement(where: InsertPosition, element: Element): Element | null;
136
+ insertAdjacentHTML(position: InsertPosition, string: string): void;
137
+ insertAdjacentText(where: InsertPosition, data: string): void;
138
+ matches(selectors: string): boolean;
139
+ releasePointerCapture(pointerId: number): void;
140
+ removeAttribute(qualifiedName: string): void;
141
+ removeAttributeNS(namespace: string | null, localName: string): void;
142
+ removeAttributeNode(attr: Attr): Attr;
143
+ requestFullscreen(options?: FullscreenOptions): Promise<void>;
144
+ requestPointerLock(options?: PointerLockOptions): Promise<void>;
145
+ scroll(options?: ScrollToOptions): void;
146
+ scroll(x: number, y: number): void;
147
+ scrollBy(options?: ScrollToOptions): void;
148
+ scrollBy(x: number, y: number): void;
149
+ scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;
150
+ scrollTo(options?: ScrollToOptions): void;
151
+ scrollTo(x: number, y: number): void;
152
+ setAttribute(qualifiedName: string, value: string): void;
153
+ setAttributeNS(namespace: string | null, qualifiedName: string, value: string): void;
154
+ setAttributeNode(attr: Attr): Attr | null;
155
+ setAttributeNodeNS(attr: Attr): Attr | null;
156
+ setHTMLUnsafe(html: string): void;
157
+ setPointerCapture(pointerId: number): void;
158
+ toggleAttribute(qualifiedName: string, force?: boolean): boolean;
159
+ webkitMatchesSelector(selectors: string): boolean;
160
+ get textContent(): string;
161
+ set textContent(value: string | null);
162
+ readonly baseURI: string;
163
+ readonly childNodes: NodeListOf<ChildNode>;
164
+ readonly firstChild: ChildNode | null;
165
+ readonly isConnected: boolean;
166
+ readonly lastChild: ChildNode | null;
167
+ readonly nextSibling: ChildNode | null;
168
+ readonly nodeName: string;
169
+ readonly nodeType: number;
170
+ nodeValue: string | null;
171
+ readonly parentElement: HTMLElement | null;
172
+ readonly parentNode: ParentNode | null;
173
+ readonly previousSibling: ChildNode | null;
174
+ appendChild<T extends Node>(node: T): T;
175
+ cloneNode(subtree?: boolean): Node;
176
+ compareDocumentPosition(other: Node): number;
177
+ contains(other: Node | null): boolean;
178
+ getRootNode(options?: GetRootNodeOptions): Node;
179
+ hasChildNodes(): boolean;
180
+ insertBefore<T extends Node>(node: T, child: Node | null): T;
181
+ isDefaultNamespace(namespace: string | null): boolean;
182
+ isEqualNode(otherNode: Node | null): boolean;
183
+ isSameNode(otherNode: Node | null): boolean;
184
+ lookupNamespaceURI(prefix: string | null): string | null;
185
+ lookupPrefix(namespace: string | null): string | null;
186
+ normalize(): void;
187
+ removeChild<T extends Node>(child: T): T;
188
+ replaceChild<T extends Node>(node: Node, child: T): T;
189
+ readonly ELEMENT_NODE: 1;
190
+ readonly ATTRIBUTE_NODE: 2;
191
+ readonly TEXT_NODE: 3;
192
+ readonly CDATA_SECTION_NODE: 4;
193
+ readonly ENTITY_REFERENCE_NODE: 5;
194
+ readonly ENTITY_NODE: 6;
195
+ readonly PROCESSING_INSTRUCTION_NODE: 7;
196
+ readonly COMMENT_NODE: 8;
197
+ readonly DOCUMENT_NODE: 9;
198
+ readonly DOCUMENT_TYPE_NODE: 10;
199
+ readonly DOCUMENT_FRAGMENT_NODE: 11;
200
+ readonly NOTATION_NODE: 12;
201
+ readonly DOCUMENT_POSITION_DISCONNECTED: 1;
202
+ readonly DOCUMENT_POSITION_PRECEDING: 2;
203
+ readonly DOCUMENT_POSITION_FOLLOWING: 4;
204
+ readonly DOCUMENT_POSITION_CONTAINS: 8;
205
+ readonly DOCUMENT_POSITION_CONTAINED_BY: 16;
206
+ readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: 32;
207
+ dispatchEvent(event: Event): boolean;
208
+ ariaActiveDescendantElement: Element | null;
209
+ ariaAtomic: string | null;
210
+ ariaAutoComplete: string | null;
211
+ ariaBrailleLabel: string | null;
212
+ ariaBrailleRoleDescription: string | null;
213
+ ariaBusy: string | null;
214
+ ariaChecked: string | null;
215
+ ariaColCount: string | null;
216
+ ariaColIndex: string | null;
217
+ ariaColIndexText: string | null;
218
+ ariaColSpan: string | null;
219
+ ariaControlsElements: ReadonlyArray<Element> | null;
220
+ ariaCurrent: string | null;
221
+ ariaDescribedByElements: ReadonlyArray<Element> | null;
222
+ ariaDescription: string | null;
223
+ ariaDetailsElements: ReadonlyArray<Element> | null;
224
+ ariaDisabled: string | null;
225
+ ariaErrorMessageElements: ReadonlyArray<Element> | null;
226
+ ariaExpanded: string | null;
227
+ ariaFlowToElements: ReadonlyArray<Element> | null;
228
+ ariaHasPopup: string | null;
229
+ ariaHidden: string | null;
230
+ ariaInvalid: string | null;
231
+ ariaKeyShortcuts: string | null;
232
+ ariaLabel: string | null;
233
+ ariaLabelledByElements: ReadonlyArray<Element> | null;
234
+ ariaLevel: string | null;
235
+ ariaLive: string | null;
236
+ ariaModal: string | null;
237
+ ariaMultiLine: string | null;
238
+ ariaMultiSelectable: string | null;
239
+ ariaOrientation: string | null;
240
+ ariaOwnsElements: ReadonlyArray<Element> | null;
241
+ ariaPlaceholder: string | null;
242
+ ariaPosInSet: string | null;
243
+ ariaPressed: string | null;
244
+ ariaReadOnly: string | null;
245
+ ariaRelevant: string | null;
246
+ ariaRequired: string | null;
247
+ ariaRoleDescription: string | null;
248
+ ariaRowCount: string | null;
249
+ ariaRowIndex: string | null;
250
+ ariaRowIndexText: string | null;
251
+ ariaRowSpan: string | null;
252
+ ariaSelected: string | null;
253
+ ariaSetSize: string | null;
254
+ ariaSort: string | null;
255
+ ariaValueMax: string | null;
256
+ ariaValueMin: string | null;
257
+ ariaValueNow: string | null;
258
+ ariaValueText: string | null;
259
+ role: string | null;
260
+ animate(keyframes: Keyframe[] | PropertyIndexedKeyframes | null, options?: number | KeyframeAnimationOptions): Animation;
261
+ getAnimations(options?: GetAnimationsOptions): Animation[];
262
+ after(...nodes: (Node | string)[]): void;
263
+ before(...nodes: (Node | string)[]): void;
264
+ remove(): void;
265
+ replaceWith(...nodes: (Node | string)[]): void;
266
+ readonly nextElementSibling: Element | null;
267
+ readonly previousElementSibling: Element | null;
268
+ readonly childElementCount: number;
269
+ readonly children: HTMLCollection;
270
+ readonly firstElementChild: Element | null;
271
+ readonly lastElementChild: Element | null;
272
+ append(...nodes: (Node | string)[]): void;
273
+ prepend(...nodes: (Node | string)[]): void;
274
+ querySelector<K extends keyof HTMLElementTagNameMap>(selectors: K): HTMLElementTagNameMap[K] | null;
275
+ querySelector<K extends keyof SVGElementTagNameMap>(selectors: K): SVGElementTagNameMap[K] | null;
276
+ querySelector<K extends keyof MathMLElementTagNameMap>(selectors: K): MathMLElementTagNameMap[K] | null;
277
+ querySelector<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): HTMLElementDeprecatedTagNameMap[K] | null;
278
+ querySelector<E extends Element = Element>(selectors: string): E | null;
279
+ querySelectorAll<K extends keyof HTMLElementTagNameMap>(selectors: K): NodeListOf<HTMLElementTagNameMap[K]>;
280
+ querySelectorAll<K extends keyof SVGElementTagNameMap>(selectors: K): NodeListOf<SVGElementTagNameMap[K]>;
281
+ querySelectorAll<K extends keyof MathMLElementTagNameMap>(selectors: K): NodeListOf<MathMLElementTagNameMap[K]>;
282
+ querySelectorAll<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): NodeListOf<HTMLElementDeprecatedTagNameMap[K]>;
283
+ querySelectorAll<E extends Element = Element>(selectors: string): NodeListOf<E>;
284
+ replaceChildren(...nodes: (Node | string)[]): void;
285
+ readonly assignedSlot: HTMLSlotElement | null;
286
+ readonly attributeStyleMap: StylePropertyMap;
287
+ get style(): CSSStyleDeclaration;
288
+ set style(cssText: string);
289
+ contentEditable: string;
290
+ enterKeyHint: string;
291
+ inputMode: string;
292
+ readonly isContentEditable: boolean;
293
+ onabort: ((this: GlobalEventHandlers, ev: UIEvent) => any) | null;
294
+ onanimationcancel: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
295
+ onanimationend: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
296
+ onanimationiteration: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
297
+ onanimationstart: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
298
+ onauxclick: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
299
+ onbeforeinput: ((this: GlobalEventHandlers, ev: InputEvent) => any) | null;
300
+ onbeforematch: ((this: GlobalEventHandlers, ev: Event) => any) | null;
301
+ onbeforetoggle: ((this: GlobalEventHandlers, ev: ToggleEvent) => any) | null;
302
+ onblur: ((this: GlobalEventHandlers, ev: FocusEvent) => any) | null;
303
+ oncancel: ((this: GlobalEventHandlers, ev: Event) => any) | null;
304
+ oncanplay: ((this: GlobalEventHandlers, ev: Event) => any) | null;
305
+ oncanplaythrough: ((this: GlobalEventHandlers, ev: Event) => any) | null;
306
+ onchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
307
+ onclick: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
308
+ onclose: ((this: GlobalEventHandlers, ev: Event) => any) | null;
309
+ oncontextlost: ((this: GlobalEventHandlers, ev: Event) => any) | null;
310
+ oncontextmenu: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
311
+ oncontextrestored: ((this: GlobalEventHandlers, ev: Event) => any) | null;
312
+ oncopy: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
313
+ oncuechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
314
+ oncut: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
315
+ ondblclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
316
+ ondrag: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
317
+ ondragend: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
318
+ ondragenter: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
319
+ ondragleave: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
320
+ ondragover: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
321
+ ondragstart: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
322
+ ondrop: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
323
+ ondurationchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
324
+ onemptied: ((this: GlobalEventHandlers, ev: Event) => any) | null;
325
+ onended: ((this: GlobalEventHandlers, ev: Event) => any) | null;
326
+ onerror: OnErrorEventHandler;
327
+ onfocus: ((this: GlobalEventHandlers, ev: FocusEvent) => any) | null;
328
+ onformdata: ((this: GlobalEventHandlers, ev: FormDataEvent) => any) | null;
329
+ ongotpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
330
+ oninput: ((this: GlobalEventHandlers, ev: Event) => any) | null;
331
+ oninvalid: ((this: GlobalEventHandlers, ev: Event) => any) | null;
332
+ onkeydown: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
333
+ onkeypress: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
334
+ onkeyup: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
335
+ onload: ((this: GlobalEventHandlers, ev: Event) => any) | null;
336
+ onloadeddata: ((this: GlobalEventHandlers, ev: Event) => any) | null;
337
+ onloadedmetadata: ((this: GlobalEventHandlers, ev: Event) => any) | null;
338
+ onloadstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
339
+ onlostpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
340
+ onmousedown: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
341
+ onmouseenter: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
342
+ onmouseleave: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
343
+ onmousemove: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
344
+ onmouseout: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
345
+ onmouseover: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
346
+ onmouseup: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
347
+ onpaste: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
348
+ onpause: ((this: GlobalEventHandlers, ev: Event) => any) | null;
349
+ onplay: ((this: GlobalEventHandlers, ev: Event) => any) | null;
350
+ onplaying: ((this: GlobalEventHandlers, ev: Event) => any) | null;
351
+ onpointercancel: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
352
+ onpointerdown: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
353
+ onpointerenter: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
354
+ onpointerleave: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
355
+ onpointermove: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
356
+ onpointerout: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
357
+ onpointerover: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
358
+ onpointerrawupdate: ((this: GlobalEventHandlers, ev: Event) => any) | null;
359
+ onpointerup: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
360
+ onprogress: ((this: GlobalEventHandlers, ev: ProgressEvent) => any) | null;
361
+ onratechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
362
+ onreset: ((this: GlobalEventHandlers, ev: Event) => any) | null;
363
+ onresize: ((this: GlobalEventHandlers, ev: UIEvent) => any) | null;
364
+ onscroll: ((this: GlobalEventHandlers, ev: Event) => any) | null;
365
+ onscrollend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
366
+ onsecuritypolicyviolation: ((this: GlobalEventHandlers, ev: SecurityPolicyViolationEvent) => any) | null;
367
+ onseeked: ((this: GlobalEventHandlers, ev: Event) => any) | null;
368
+ onseeking: ((this: GlobalEventHandlers, ev: Event) => any) | null;
369
+ onselect: ((this: GlobalEventHandlers, ev: Event) => any) | null;
370
+ onselectionchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
371
+ onselectstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
372
+ onslotchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
373
+ onstalled: ((this: GlobalEventHandlers, ev: Event) => any) | null;
374
+ onsubmit: ((this: GlobalEventHandlers, ev: SubmitEvent) => any) | null;
375
+ onsuspend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
376
+ ontimeupdate: ((this: GlobalEventHandlers, ev: Event) => any) | null;
377
+ ontoggle: ((this: GlobalEventHandlers, ev: ToggleEvent) => any) | null;
378
+ ontouchcancel?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
379
+ ontouchend?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
380
+ ontouchmove?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
381
+ ontouchstart?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
382
+ ontransitioncancel: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
383
+ ontransitionend: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
384
+ ontransitionrun: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
385
+ ontransitionstart: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
386
+ onvolumechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
387
+ onwaiting: ((this: GlobalEventHandlers, ev: Event) => any) | null;
388
+ onwebkitanimationend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
389
+ onwebkitanimationiteration: ((this: GlobalEventHandlers, ev: Event) => any) | null;
390
+ onwebkitanimationstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
391
+ onwebkittransitionend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
392
+ onwheel: ((this: GlobalEventHandlers, ev: WheelEvent) => any) | null;
393
+ autofocus: boolean;
394
+ readonly dataset: DOMStringMap;
395
+ nonce?: string;
396
+ tabIndex: number;
397
+ blur(): void;
398
+ focus(options?: FocusOptions): void;
399
+ };
400
+ } & Base;
@@ -0,0 +1,16 @@
1
+ import { ToolkitCoordinatorApi, ToolRegistry } from '@pie-players/pie-assessment-toolkit';
2
+ /**
3
+ * Warn once per placed tool whose registration carries a provider the coordinator
4
+ * has not registered. Reads the coordinator's current placement and providers, so
5
+ * call it only once the coordinator reports ready.
6
+ */
7
+ export declare function reportMissingToolProviders(coordinator: ToolkitCoordinatorApi, toolRegistry: ToolRegistry): void;
8
+ /**
9
+ * Check `coordinator` now and whenever its policy inputs change, since placement
10
+ * can. A check runs once the coordinator reports ready: its providers have
11
+ * registered by then, and a text-to-speech reconfiguration, which unregisters and
12
+ * re-registers that provider, holds readiness until it is back. Readiness is
13
+ * polled because `waitUntilReady()` would start initialization a lazy
14
+ * coordinator defers, and retry one that failed. Returns the teardown.
15
+ */
16
+ export declare function watchMissingToolProviders(coordinator: ToolkitCoordinatorApi, toolRegistry: ToolRegistry): () => void;
@@ -46,7 +46,8 @@ export declare class PreloadStageError extends Error {
46
46
  constructor(stage: PreloadStage, cause: unknown);
47
47
  }
48
48
  export declare function getPreloadLogger(componentTag: string): import('@pie-players/pie-players-shared').PieLogger;
49
- export declare function getLoaderView(env: Record<string, unknown>): "author" | "delivery";
49
+ /** The element view the item players render, which pre-warm has to match. */
50
+ export declare function getLoaderView(props: Record<string, unknown>, env: Record<string, unknown>): string;
50
51
  /**
51
52
  * Stable string signature of a list of renderables, used as a react-key
52
53
  * hint for the composition snapshot plumbed through the layout tree.
@@ -91,17 +92,20 @@ export declare function describeBundleHost(backend: IifeBackendConfig | EsmBacke
91
92
  *
92
93
  * Contract:
93
94
  * - `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`.
95
+ * - `strategy === "preloaded"` — align each renderable's authored versions
96
+ * to the page's registrations (`alignPreloadedElementVersions`, as the
97
+ * item player does), define each authored tag of a package registered
98
+ * under another base tag (`defineAuthoredPreloadedTags`), then assert
99
+ * every aggregate tag is registered with `customElements`. Throws
100
+ * `ElementAssertionError` (wrapped in `PreloadStageError` with stage
101
+ * `"preloaded-assert"`) on any missing tag, surfacing one section-level
102
+ * diagnostic instead of N small per-item rejections.
103
+ * - Otherwise: aggregate tags, build backend, install the math renderer
104
+ * unless the strategy is ESM, await `ensureRegistered`.
100
105
  *
101
106
  * 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.
107
+ * The caller (`SectionItemsPane`) keeps the items unmounted, reports an
108
+ * `element-preload` framework error and dispatches `element-preload-error`.
105
109
  */
106
110
  export declare function warmupSectionElements(args: {
107
111
  strategy: string;
@@ -2,11 +2,10 @@ import { SectionPlayerCardTitleFormatter } from './card-title-formatters.js';
2
2
  /**
3
3
  * Host-extension hook contract for the section-player layout custom elements.
4
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.
5
+ * Hosts pass a `SectionPlayerHostHooks` value as the `hooks` JS property on
6
+ * `<pie-section-player-*>` to override formatter / decoration behavior that
7
+ * the engine intentionally leaves to the host. Each hook is optional; omitted
8
+ * hooks fall back to documented defaults.
10
9
  *
11
10
  * Today the contract has a single member (`cardTitleFormatter`). The shape is
12
11
  * intentionally a struct, not a single callback prop, so future host-supplied
File without changes
File without changes
@@ -0,0 +1,87 @@
1
+ import { SECTION_PLAYER_PUBLIC_EVENTS as e } from "./public-events.js";
2
+ var a = [
3
+ "assessmentId",
4
+ "section",
5
+ "sectionId",
6
+ "attemptId",
7
+ "debug",
8
+ "showToolbar",
9
+ "toolbarPosition",
10
+ "narrowLayoutBreakpoint",
11
+ "contentMaxWidthNoPassage",
12
+ "contentMaxWidthWithPassage",
13
+ "splitPaneMinRegionWidth",
14
+ "splitPaneInitialPassageWidth",
15
+ "splitPaneCollapseStrategy"
16
+ ], o = [
17
+ "runtime",
18
+ "iifeBundleHost",
19
+ "toolRegistry",
20
+ "sectionHostButtons",
21
+ "itemHostButtons",
22
+ "passageHostButtons",
23
+ "policies",
24
+ "toolConfigStrictness",
25
+ "hooks",
26
+ "onFrameworkError",
27
+ "onStageChange",
28
+ "onLoadingComplete"
29
+ ], t = [...a, ...o], s = [
30
+ e.runtimeOwned,
31
+ e.runtimeInherited,
32
+ e.frameworkError,
33
+ e.compositionChanged,
34
+ e.sessionChanged,
35
+ e.stageChange,
36
+ e.loadingComplete
37
+ ], n = [
38
+ "getSnapshot",
39
+ "selectComposition",
40
+ "selectNavigation",
41
+ "selectReadiness",
42
+ "navigateTo",
43
+ "navigateNext",
44
+ "navigatePrevious",
45
+ "getSectionController",
46
+ "waitForSectionController"
47
+ ], i = [
48
+ "items-pane",
49
+ "passages-pane",
50
+ "section-toolbar",
51
+ "item-toolbar",
52
+ "passage-toolbar",
53
+ "readiness-events",
54
+ "navigation-events"
55
+ ], p = {
56
+ version: 1,
57
+ layout: "splitpane",
58
+ props: t,
59
+ recommendedBasicProps: a,
60
+ advancedEscapeHatchProps: o,
61
+ events: s,
62
+ commands: n,
63
+ capabilities: i
64
+ }, c = {
65
+ version: 1,
66
+ layout: "vertical",
67
+ props: t,
68
+ recommendedBasicProps: a,
69
+ advancedEscapeHatchProps: o,
70
+ events: s,
71
+ commands: n,
72
+ capabilities: i
73
+ }, d = {
74
+ version: 1,
75
+ layout: "tabbed",
76
+ props: t,
77
+ recommendedBasicProps: a,
78
+ advancedEscapeHatchProps: o,
79
+ events: s,
80
+ commands: n,
81
+ capabilities: i
82
+ };
83
+ export {
84
+ p as SPLITPANE_LAYOUT_CONTRACT,
85
+ d as TABBED_LAYOUT_CONTRACT,
86
+ c as VERTICAL_LAYOUT_CONTRACT
87
+ };