@citolab/qti-components 6.3.5 → 6.3.8

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 (51) hide show
  1. package/dist/{chunk-LNHTXQXY.js → chunk-DHQGPGHW.js} +3 -7
  2. package/dist/chunk-GHNL64KC.js +397 -0
  3. package/dist/{chunk-6G76D2MI.cjs → chunk-HYQC3D4Z.cjs} +1 -1
  4. package/dist/{chunk-LWL4UHCJ.cjs → chunk-OMMRIRZN.cjs} +3 -7
  5. package/dist/chunk-QGPCSWAA.cjs +397 -0
  6. package/dist/{chunk-M4CYU6DC.cjs → chunk-SLKHOXHJ.cjs} +1 -1
  7. package/dist/{chunk-QROD4MVT.js → chunk-V6U2X6CM.js} +1 -1
  8. package/dist/chunk-YWGBLO7P.js +1 -0
  9. package/dist/context/index.cjs +1 -1
  10. package/dist/context/index.js +1 -1
  11. package/dist/custom-elements.json +3788 -3466
  12. package/dist/decorators/index.cjs +1 -1
  13. package/dist/decorators/index.js +1 -1
  14. package/dist/index.cjs +443 -116
  15. package/dist/index.css +1 -5
  16. package/dist/index.d.cts +83 -30
  17. package/dist/index.d.ts +83 -30
  18. package/dist/index.js +443 -116
  19. package/dist/qti-components/index.cjs +40 -39
  20. package/dist/qti-components/index.d.cts +4 -4
  21. package/dist/qti-components/index.d.ts +4 -4
  22. package/dist/qti-components/index.js +29 -28
  23. package/dist/qti-item/index.cjs +1 -1
  24. package/dist/qti-item/index.d.cts +29 -2
  25. package/dist/qti-item/index.d.ts +29 -2
  26. package/dist/qti-item/index.js +1 -1
  27. package/dist/qti-item-react/index.cjs +1 -1
  28. package/dist/qti-item-react/index.d.cts +2 -2
  29. package/dist/qti-item-react/index.d.ts +2 -2
  30. package/dist/qti-item-react/index.js +1 -1
  31. package/dist/{qti-simple-choice-5902cb37.d.ts → qti-simple-choice-1e52645f.d.ts} +1 -1
  32. package/dist/qti-test/index.cjs +1 -1
  33. package/dist/qti-test/index.d.cts +34 -72
  34. package/dist/qti-test/index.d.ts +34 -72
  35. package/dist/qti-test/index.js +1 -1
  36. package/dist/qti-test-react/index.cjs +1 -1
  37. package/dist/qti-test-react/index.d.cts +61 -13
  38. package/dist/qti-test-react/index.d.ts +61 -13
  39. package/dist/qti-test-react/index.js +1 -1
  40. package/dist/qti-transform/index.cjs +1 -1
  41. package/dist/qti-transform/index.js +1 -1
  42. package/dist/test-print-variables-9b4289a6.d.ts +97 -0
  43. package/dist/test-print-variables-9f2390d5.d.ts +97 -0
  44. package/package.json +28 -26
  45. package/dist/chunk-343LZK3D.js +0 -1
  46. package/dist/chunk-5MW7QEIY.cjs +0 -79
  47. package/dist/chunk-CLTJGOOQ.js +0 -79
  48. package/dist/chunk-MTPOYN4D.js +0 -0
  49. package/dist/chunk-TEMU6PXC.cjs +0 -1
  50. package/dist/qti-test-0312b9bb.d.ts +0 -32
  51. package/dist/qti-test-24952460.d.ts +0 -32
package/dist/index.css CHANGED
@@ -5,12 +5,8 @@
5
5
  https://play.tailwindcss.com/CeHVrnwgXR
6
6
  https://play.tailwindcss.com/JOgoCf81JM
7
7
 
8
- We make use of the default prose stylesheet, since it is much better looking then
9
- the default HTML styling.
10
- https://play.tailwindcss.com/uj1vGACRJA?layout=preview
8
+ You should in you project include modern-normalize.css
11
9
 
12
- So first we ( as tailwind does ) reset ALL styling on all default elements
13
- Then we add the prose stylesheet: the Interaction will / or will not have a no-prose declaration, don't know about that yet
14
10
  Then we create tailwind components
15
11
  Then we consume these components in our qti-webcomponents
16
12
 
package/dist/index.d.cts CHANGED
@@ -1,9 +1,11 @@
1
1
  import * as lit from 'lit';
2
- import { LitElement, CSSResultGroup, PropertyValueMap } from 'lit';
2
+ import { LitElement, PropertyValueMap, CSSResultGroup } from 'lit';
3
3
  import * as lit_html from 'lit-html';
4
4
  import { ContextConsumer } from '@lit/context';
5
5
  import * as lit_html_directives_ref from 'lit-html/directives/ref';
6
6
  import * as cheerio from 'cheerio';
7
+ import { Signal } from '@lit-labs/preact-signals';
8
+ import * as haunted_lib_component from 'haunted/lib/component';
7
9
 
8
10
  interface directedPair {
9
11
  destination: string;
@@ -264,7 +266,7 @@ declare global {
264
266
  declare class QtiStylesheet extends LitElement {
265
267
  private styleLink;
266
268
  constructor();
267
- connectedCallback(): void;
269
+ protected firstUpdated(_changedProperties: PropertyValueMap<any> | Map<PropertyKey, unknown>): void;
268
270
  disconnectedCallback(): void;
269
271
  }
270
272
 
@@ -539,7 +541,7 @@ declare class QtiResponseProcessing extends LitElement {
539
541
  }
540
542
  declare global {
541
543
  interface HTMLElementTagNameMap {
542
- 'qti-response-processing': QtiResponseProcessing;
544
+ 'qti-response-processed': QtiResponseProcessing;
543
545
  }
544
546
  }
545
547
 
@@ -878,7 +880,7 @@ declare class QtiPositionObjectStage extends LitElement {
878
880
  static styles: lit.CSSResult[];
879
881
  constructor();
880
882
  dragElementHandler(event: any): void;
881
- connectedCallback(): void;
883
+ firstUpdated(a: any): void;
882
884
  removeMoveListener(event: any): void;
883
885
  disconnectedCallback(): void;
884
886
  }
@@ -1041,15 +1043,42 @@ declare class QtiCustomOperator extends LitElement implements Calculate {
1041
1043
  }
1042
1044
 
1043
1045
  declare class QtiItem extends LitElement {
1046
+ /**
1047
+ * The location of the item.
1048
+ * @attr item-location
1049
+ */
1044
1050
  itemLocation: string;
1051
+ /**
1052
+ * Whether the item is disabled.
1053
+ */
1045
1054
  disabled: boolean;
1055
+ /**
1056
+ * Updates the element.
1057
+ * @param changedProperties - The changed properties.
1058
+ */
1046
1059
  update(changedProperties: Map<string | number | symbol, unknown>): void;
1060
+ /**
1061
+ * The XML content of the item.
1062
+ */
1047
1063
  protected _xml: string;
1064
+ /**
1065
+ * Sets the XML content of the item.
1066
+ * @param val - The XML content.
1067
+ */
1048
1068
  set xml(val: string);
1069
+ /**
1070
+ * Sets the CSS content of the item.
1071
+ * @param val - The CSS content.
1072
+ */
1049
1073
  set css(val: string);
1074
+ /**
1075
+ * Returns the assessment item.
1076
+ */
1050
1077
  get assessmentItem(): QtiAssessmentItem | null;
1078
+ /**
1079
+ * The audience context. describes
1080
+ */
1051
1081
  audienceContext: AudienceContext;
1052
- constructor();
1053
1082
  connectedCallback(): void;
1054
1083
  render: () => lit_html.TemplateResult<1>;
1055
1084
  }
@@ -1076,44 +1105,45 @@ declare class QtiAssessmentItemRef extends QtiItem {
1076
1105
  connectedCallback(): void;
1077
1106
  }
1078
1107
 
1079
- interface ItemInfo {
1080
- href: string;
1081
- }
1082
1108
  declare class TestContext {
1083
1109
  itemIndex: number | null;
1084
- items: (ItemContext & ItemInfo)[];
1110
+ items: ItemContext[];
1085
1111
  }
1112
+ declare const testContext: {
1113
+ __context__: TestContext;
1114
+ };
1086
1115
 
1087
1116
  declare class QtiAssessmentTest extends LitElement {
1088
- context: TestContext;
1117
+ private _initialValue;
1118
+ identifier: string;
1119
+ signalContext: Signal<TestContext>;
1120
+ private _context;
1121
+ set context(value: TestContext);
1122
+ constructor();
1089
1123
  itemRefEls: Map<string, QtiAssessmentItemRef>;
1090
1124
  private copyItemVariables;
1125
+ restoreContext: (contextToRestore: TestContext) => void;
1091
1126
  getAssessmentItem(identifier: string): QtiAssessmentItem;
1127
+ get currentAssessmentItem(): QtiAssessmentItem;
1092
1128
  private onItemRefRegistered;
1093
1129
  private onTestRequestItem;
1094
1130
  firstUpdated(a: any): void;
1095
- constructor();
1131
+ updated(changedProperties: Map<string, any>): void;
1096
1132
  private itemConnected;
1097
1133
  private _requestItem;
1134
+ private _emit;
1098
1135
  render(): lit_html.TemplateResult<1>;
1099
1136
  }
1100
1137
 
1101
1138
  declare class QtiTestPart extends LitElement {
1139
+ loading: boolean;
1102
1140
  private _navigationMode;
1103
1141
  render(): lit_html.TemplateResult<1>;
1104
1142
  }
1105
1143
 
1106
- declare class QtiTest extends LitElement {
1107
- private _navigationMode;
1108
- private assessmentTestURI;
1109
- loadedItems: any[];
1110
- itemRefEls: {
1111
- current: Map<string, QtiAssessmentItemRef>;
1112
- };
1113
- controller: AbortController;
1114
- requestItem(identifier: string): void;
1115
- render(): lit_html.TemplateResult<1>;
1116
- }
1144
+ declare const QtiTest: haunted_lib_component.ComponentConstructor<{
1145
+ "package-uri": any;
1146
+ }>;
1117
1147
 
1118
1148
  declare class TestNext extends LitElement {
1119
1149
  _testContext?: TestContext;
@@ -1127,32 +1157,33 @@ declare class TestPrev extends LitElement {
1127
1157
  render(): lit_html.TemplateResult<1>;
1128
1158
  }
1129
1159
 
1130
- declare class QtiTestProgress extends LitElement {
1160
+ declare class TestProgress extends LitElement {
1131
1161
  _testProvider?: TestContext;
1132
1162
  render(): lit_html.TemplateResult<1>;
1133
1163
  }
1134
1164
 
1135
- declare class QtiTestSlider extends LitElement {
1165
+ declare class TestSlider extends LitElement {
1136
1166
  _testProvider?: TestContext;
1137
1167
  _requestItem(index: any): void;
1138
1168
  render(): lit_html.TemplateResult<1>;
1139
1169
  }
1140
1170
 
1141
- declare class QtiTestPagingRadio extends LitElement {
1171
+ declare class TestPagingRadio extends LitElement {
1142
1172
  _testProvider?: TestContext;
1143
1173
  protected createRenderRoot(): this;
1144
1174
  _requestItem(index: any): void;
1145
1175
  render(): lit_html.TemplateResult<1>;
1146
1176
  }
1147
1177
 
1148
- declare class QtiTestPagingButtons extends LitElement {
1178
+ declare class TestPagingButtons extends LitElement {
1149
1179
  _testProvider?: TestContext;
1180
+ private maxDisplayedItems;
1150
1181
  protected createRenderRoot(): this;
1151
1182
  _requestItem(index: any): void;
1152
1183
  render(): lit_html.TemplateResult<1>;
1153
1184
  }
1154
1185
 
1155
- declare class QtiTestShowCorrect extends LitElement {
1186
+ declare class TestShowCorrect extends LitElement {
1156
1187
  _testProvider?: TestContext;
1157
1188
  render(): lit_html.TemplateResult<1>;
1158
1189
  }
@@ -1171,15 +1202,37 @@ declare class TestShowIndex extends LitElement {
1171
1202
  render(): lit_html.TemplateResult<1>;
1172
1203
  }
1173
1204
 
1174
- declare class QtiPrintVariables extends LitElement {
1205
+ declare class TestPrintVariables extends LitElement {
1175
1206
  _testProvider?: TestContext;
1176
1207
  render(): lit_html.TemplateResult<1>;
1177
1208
  }
1178
1209
 
1179
- declare class QtiTestPrintScore extends LitElement {
1210
+ declare class TestPrintScore extends LitElement {
1180
1211
  _testContext?: TestContext;
1181
1212
  _requestItem(index: any): void;
1182
1213
  render(): lit_html.TemplateResult<1>;
1183
1214
  }
1184
1215
 
1185
- export { BaseType, Calculate, Cardinality, Events, Interaction, InteractionChangedDetails, ItemContext, Multiple, Ordered, OutcomeChangedDetails, OutcomeVariable, QtPrintedVariable, QtiAnd, QtiAssessmentItem, QtiAssessmentItemRef, QtiAssessmentTest, QtiAssociableHotspot, QtiAssociateInteraction, QtiBaseValue, QtiChoice, qtiChoiceElementSelected as QtiChoiceElementSelected, QtiChoiceInteraction, QtiCompanionMaterialsInfo, QtiConditionExpression, QtiContains, QtiCorrect, QtiCustomOperator, QtiEndAttemptInteraction, QtiEqual, QtiEqualRounded, QtiExpression, QtiExtendedTextInteraction, QtiFeedbackBlock, QtiFeedbackInline, QtiGap, QtiGapImg, QtiGapMatchInteraction, QtiGapText, QtiGraphicAssociateInteraction, QtiGraphicGapMatchInteraction, QtiGraphicOrderInteraction, QtiGt, QtiGte, QtiHotspotChoice, QtiHotspotInteraction, QtiHottext, QtiHottextInteraction, QtiInlineChoice, QtiInlineChoiceInteraction, qtiInteractionChanged as QtiInteractionChanged, qtiInteractionResponse as QtiInteractionResponse, QtiIsNull, QtiItem, qtiLooseChoice as QtiLooseChoice, QtiLt, QtiLte, QtiMapResponse, QtiMapping, QtiMatch, QtiMatchInteraction, QtiMediaInteraction, QtiMember, QtiModalFeedback, QtiMultiple, QtiNot, QtiOr, QtiOrderInteraction, QtiOrdered, qtiOutcomeChanged as QtiOutcomeChanged, QtiOutcomeDeclaration, QtiPortableCustomInteraction, QtiPositionObjectStage, QtiPrintVariables, QtiProduct, QtiPrompt, qtiRegisterChoice as QtiRegisterChoice, qtiRegisterHotspot as QtiRegisterHotspot, qtiRegisterInteraction as QtiRegisterInteraction, qtiRegisterVariable as QtiRegisterVariable, QtiResponseCondition, QtiResponseDeclaration, QtiResponseElse, QtiResponseElseIf, QtiResponseIf, QtiResponseProcessing, QtiRule, QtiSPositionObjectInteraction, QtiSelectPointInteraction, QtiSetOutcomeValue, QtiSimpleAssociableChoice, QtiSimpleChoice, QtiSliderInteraction, QtiStringMatch, QtiStylesheet, QtiSum, QtiTest, QtiTestPagingButtons, QtiTestPagingRadio, QtiTestPart, QtiTestPrintScore, QtiTestProgress, QtiTestShowCorrect, QtiTestSlider, QtiTextEntryInteraction, QtiVariable, ResponseInteraction, ResponseVariable, TestNext, TestPrev, TestScript, TestShowIndex, VariableDeclaration, directedPair, float, integer, itemContext, qtiContentBody, qtiRubricBlock, qtiTransform };
1216
+ /**
1217
+ * Requests an XML item from the specified URL.
1218
+ * @param href - The URL of the XML item to request.
1219
+ * @returns A Promise that resolves to the XML item as a string.
1220
+ */
1221
+ declare function requestItem(href: string): Promise<string>;
1222
+ type ManifestData = {
1223
+ itemLocation: string;
1224
+ testIdentifier: string;
1225
+ items: {
1226
+ identifier: string;
1227
+ href: string;
1228
+ category: string;
1229
+ }[];
1230
+ };
1231
+ /**
1232
+ * Fetches manifest data for a given package URI.
1233
+ * @param packageUri The URI of the package to fetch manifest data for.
1234
+ * @returns A Promise that resolves to a ManifestData object.
1235
+ */
1236
+ declare const fetchManifestData: (packageUri: string) => Promise<ManifestData>;
1237
+
1238
+ export { BaseType, Calculate, Cardinality, Events, Interaction, InteractionChangedDetails, ItemContext, ManifestData, Multiple, Ordered, OutcomeChangedDetails, OutcomeVariable, QtPrintedVariable, QtiAnd, QtiAssessmentItem, QtiAssessmentItemRef, QtiAssessmentTest, QtiAssociableHotspot, QtiAssociateInteraction, QtiBaseValue, QtiChoice, qtiChoiceElementSelected as QtiChoiceElementSelected, QtiChoiceInteraction, QtiCompanionMaterialsInfo, QtiConditionExpression, QtiContains, QtiCorrect, QtiCustomOperator, QtiEndAttemptInteraction, QtiEqual, QtiEqualRounded, QtiExpression, QtiExtendedTextInteraction, QtiFeedbackBlock, QtiFeedbackInline, QtiGap, QtiGapImg, QtiGapMatchInteraction, QtiGapText, QtiGraphicAssociateInteraction, QtiGraphicGapMatchInteraction, QtiGraphicOrderInteraction, QtiGt, QtiGte, QtiHotspotChoice, QtiHotspotInteraction, QtiHottext, QtiHottextInteraction, QtiInlineChoice, QtiInlineChoiceInteraction, qtiInteractionChanged as QtiInteractionChanged, qtiInteractionResponse as QtiInteractionResponse, QtiIsNull, QtiItem, qtiLooseChoice as QtiLooseChoice, QtiLt, QtiLte, QtiMapResponse, QtiMapping, QtiMatch, QtiMatchInteraction, QtiMediaInteraction, QtiMember, QtiModalFeedback, QtiMultiple, QtiNot, QtiOr, QtiOrderInteraction, QtiOrdered, qtiOutcomeChanged as QtiOutcomeChanged, QtiOutcomeDeclaration, QtiPortableCustomInteraction, QtiPositionObjectStage, QtiProduct, QtiPrompt, qtiRegisterChoice as QtiRegisterChoice, qtiRegisterHotspot as QtiRegisterHotspot, qtiRegisterInteraction as QtiRegisterInteraction, qtiRegisterVariable as QtiRegisterVariable, QtiResponseCondition, QtiResponseDeclaration, QtiResponseElse, QtiResponseElseIf, QtiResponseIf, QtiResponseProcessing, QtiRule, QtiSPositionObjectInteraction, QtiSelectPointInteraction, QtiSetOutcomeValue, QtiSimpleAssociableChoice, QtiSimpleChoice, QtiSliderInteraction, QtiStringMatch, QtiStylesheet, QtiSum, QtiTest, QtiTestPart, QtiTextEntryInteraction, QtiVariable, ResponseInteraction, ResponseVariable, TestContext, TestNext, TestPagingButtons, TestPagingRadio, TestPrev, TestPrintScore, TestPrintVariables, TestProgress, TestScript, TestShowCorrect, TestShowIndex, TestSlider, VariableDeclaration, directedPair, fetchManifestData, float, integer, itemContext, qtiContentBody, qtiRubricBlock, qtiTransform, requestItem, testContext };
package/dist/index.d.ts CHANGED
@@ -1,9 +1,11 @@
1
1
  import * as lit from 'lit';
2
- import { LitElement, CSSResultGroup, PropertyValueMap } from 'lit';
2
+ import { LitElement, PropertyValueMap, CSSResultGroup } from 'lit';
3
3
  import * as lit_html from 'lit-html';
4
4
  import { ContextConsumer } from '@lit/context';
5
5
  import * as lit_html_directives_ref from 'lit-html/directives/ref';
6
6
  import * as cheerio from 'cheerio';
7
+ import { Signal } from '@lit-labs/preact-signals';
8
+ import * as haunted_lib_component from 'haunted/lib/component';
7
9
 
8
10
  interface directedPair {
9
11
  destination: string;
@@ -264,7 +266,7 @@ declare global {
264
266
  declare class QtiStylesheet extends LitElement {
265
267
  private styleLink;
266
268
  constructor();
267
- connectedCallback(): void;
269
+ protected firstUpdated(_changedProperties: PropertyValueMap<any> | Map<PropertyKey, unknown>): void;
268
270
  disconnectedCallback(): void;
269
271
  }
270
272
 
@@ -539,7 +541,7 @@ declare class QtiResponseProcessing extends LitElement {
539
541
  }
540
542
  declare global {
541
543
  interface HTMLElementTagNameMap {
542
- 'qti-response-processing': QtiResponseProcessing;
544
+ 'qti-response-processed': QtiResponseProcessing;
543
545
  }
544
546
  }
545
547
 
@@ -878,7 +880,7 @@ declare class QtiPositionObjectStage extends LitElement {
878
880
  static styles: lit.CSSResult[];
879
881
  constructor();
880
882
  dragElementHandler(event: any): void;
881
- connectedCallback(): void;
883
+ firstUpdated(a: any): void;
882
884
  removeMoveListener(event: any): void;
883
885
  disconnectedCallback(): void;
884
886
  }
@@ -1041,15 +1043,42 @@ declare class QtiCustomOperator extends LitElement implements Calculate {
1041
1043
  }
1042
1044
 
1043
1045
  declare class QtiItem extends LitElement {
1046
+ /**
1047
+ * The location of the item.
1048
+ * @attr item-location
1049
+ */
1044
1050
  itemLocation: string;
1051
+ /**
1052
+ * Whether the item is disabled.
1053
+ */
1045
1054
  disabled: boolean;
1055
+ /**
1056
+ * Updates the element.
1057
+ * @param changedProperties - The changed properties.
1058
+ */
1046
1059
  update(changedProperties: Map<string | number | symbol, unknown>): void;
1060
+ /**
1061
+ * The XML content of the item.
1062
+ */
1047
1063
  protected _xml: string;
1064
+ /**
1065
+ * Sets the XML content of the item.
1066
+ * @param val - The XML content.
1067
+ */
1048
1068
  set xml(val: string);
1069
+ /**
1070
+ * Sets the CSS content of the item.
1071
+ * @param val - The CSS content.
1072
+ */
1049
1073
  set css(val: string);
1074
+ /**
1075
+ * Returns the assessment item.
1076
+ */
1050
1077
  get assessmentItem(): QtiAssessmentItem | null;
1078
+ /**
1079
+ * The audience context. describes
1080
+ */
1051
1081
  audienceContext: AudienceContext;
1052
- constructor();
1053
1082
  connectedCallback(): void;
1054
1083
  render: () => lit_html.TemplateResult<1>;
1055
1084
  }
@@ -1076,44 +1105,45 @@ declare class QtiAssessmentItemRef extends QtiItem {
1076
1105
  connectedCallback(): void;
1077
1106
  }
1078
1107
 
1079
- interface ItemInfo {
1080
- href: string;
1081
- }
1082
1108
  declare class TestContext {
1083
1109
  itemIndex: number | null;
1084
- items: (ItemContext & ItemInfo)[];
1110
+ items: ItemContext[];
1085
1111
  }
1112
+ declare const testContext: {
1113
+ __context__: TestContext;
1114
+ };
1086
1115
 
1087
1116
  declare class QtiAssessmentTest extends LitElement {
1088
- context: TestContext;
1117
+ private _initialValue;
1118
+ identifier: string;
1119
+ signalContext: Signal<TestContext>;
1120
+ private _context;
1121
+ set context(value: TestContext);
1122
+ constructor();
1089
1123
  itemRefEls: Map<string, QtiAssessmentItemRef>;
1090
1124
  private copyItemVariables;
1125
+ restoreContext: (contextToRestore: TestContext) => void;
1091
1126
  getAssessmentItem(identifier: string): QtiAssessmentItem;
1127
+ get currentAssessmentItem(): QtiAssessmentItem;
1092
1128
  private onItemRefRegistered;
1093
1129
  private onTestRequestItem;
1094
1130
  firstUpdated(a: any): void;
1095
- constructor();
1131
+ updated(changedProperties: Map<string, any>): void;
1096
1132
  private itemConnected;
1097
1133
  private _requestItem;
1134
+ private _emit;
1098
1135
  render(): lit_html.TemplateResult<1>;
1099
1136
  }
1100
1137
 
1101
1138
  declare class QtiTestPart extends LitElement {
1139
+ loading: boolean;
1102
1140
  private _navigationMode;
1103
1141
  render(): lit_html.TemplateResult<1>;
1104
1142
  }
1105
1143
 
1106
- declare class QtiTest extends LitElement {
1107
- private _navigationMode;
1108
- private assessmentTestURI;
1109
- loadedItems: any[];
1110
- itemRefEls: {
1111
- current: Map<string, QtiAssessmentItemRef>;
1112
- };
1113
- controller: AbortController;
1114
- requestItem(identifier: string): void;
1115
- render(): lit_html.TemplateResult<1>;
1116
- }
1144
+ declare const QtiTest: haunted_lib_component.ComponentConstructor<{
1145
+ "package-uri": any;
1146
+ }>;
1117
1147
 
1118
1148
  declare class TestNext extends LitElement {
1119
1149
  _testContext?: TestContext;
@@ -1127,32 +1157,33 @@ declare class TestPrev extends LitElement {
1127
1157
  render(): lit_html.TemplateResult<1>;
1128
1158
  }
1129
1159
 
1130
- declare class QtiTestProgress extends LitElement {
1160
+ declare class TestProgress extends LitElement {
1131
1161
  _testProvider?: TestContext;
1132
1162
  render(): lit_html.TemplateResult<1>;
1133
1163
  }
1134
1164
 
1135
- declare class QtiTestSlider extends LitElement {
1165
+ declare class TestSlider extends LitElement {
1136
1166
  _testProvider?: TestContext;
1137
1167
  _requestItem(index: any): void;
1138
1168
  render(): lit_html.TemplateResult<1>;
1139
1169
  }
1140
1170
 
1141
- declare class QtiTestPagingRadio extends LitElement {
1171
+ declare class TestPagingRadio extends LitElement {
1142
1172
  _testProvider?: TestContext;
1143
1173
  protected createRenderRoot(): this;
1144
1174
  _requestItem(index: any): void;
1145
1175
  render(): lit_html.TemplateResult<1>;
1146
1176
  }
1147
1177
 
1148
- declare class QtiTestPagingButtons extends LitElement {
1178
+ declare class TestPagingButtons extends LitElement {
1149
1179
  _testProvider?: TestContext;
1180
+ private maxDisplayedItems;
1150
1181
  protected createRenderRoot(): this;
1151
1182
  _requestItem(index: any): void;
1152
1183
  render(): lit_html.TemplateResult<1>;
1153
1184
  }
1154
1185
 
1155
- declare class QtiTestShowCorrect extends LitElement {
1186
+ declare class TestShowCorrect extends LitElement {
1156
1187
  _testProvider?: TestContext;
1157
1188
  render(): lit_html.TemplateResult<1>;
1158
1189
  }
@@ -1171,15 +1202,37 @@ declare class TestShowIndex extends LitElement {
1171
1202
  render(): lit_html.TemplateResult<1>;
1172
1203
  }
1173
1204
 
1174
- declare class QtiPrintVariables extends LitElement {
1205
+ declare class TestPrintVariables extends LitElement {
1175
1206
  _testProvider?: TestContext;
1176
1207
  render(): lit_html.TemplateResult<1>;
1177
1208
  }
1178
1209
 
1179
- declare class QtiTestPrintScore extends LitElement {
1210
+ declare class TestPrintScore extends LitElement {
1180
1211
  _testContext?: TestContext;
1181
1212
  _requestItem(index: any): void;
1182
1213
  render(): lit_html.TemplateResult<1>;
1183
1214
  }
1184
1215
 
1185
- export { BaseType, Calculate, Cardinality, Events, Interaction, InteractionChangedDetails, ItemContext, Multiple, Ordered, OutcomeChangedDetails, OutcomeVariable, QtPrintedVariable, QtiAnd, QtiAssessmentItem, QtiAssessmentItemRef, QtiAssessmentTest, QtiAssociableHotspot, QtiAssociateInteraction, QtiBaseValue, QtiChoice, qtiChoiceElementSelected as QtiChoiceElementSelected, QtiChoiceInteraction, QtiCompanionMaterialsInfo, QtiConditionExpression, QtiContains, QtiCorrect, QtiCustomOperator, QtiEndAttemptInteraction, QtiEqual, QtiEqualRounded, QtiExpression, QtiExtendedTextInteraction, QtiFeedbackBlock, QtiFeedbackInline, QtiGap, QtiGapImg, QtiGapMatchInteraction, QtiGapText, QtiGraphicAssociateInteraction, QtiGraphicGapMatchInteraction, QtiGraphicOrderInteraction, QtiGt, QtiGte, QtiHotspotChoice, QtiHotspotInteraction, QtiHottext, QtiHottextInteraction, QtiInlineChoice, QtiInlineChoiceInteraction, qtiInteractionChanged as QtiInteractionChanged, qtiInteractionResponse as QtiInteractionResponse, QtiIsNull, QtiItem, qtiLooseChoice as QtiLooseChoice, QtiLt, QtiLte, QtiMapResponse, QtiMapping, QtiMatch, QtiMatchInteraction, QtiMediaInteraction, QtiMember, QtiModalFeedback, QtiMultiple, QtiNot, QtiOr, QtiOrderInteraction, QtiOrdered, qtiOutcomeChanged as QtiOutcomeChanged, QtiOutcomeDeclaration, QtiPortableCustomInteraction, QtiPositionObjectStage, QtiPrintVariables, QtiProduct, QtiPrompt, qtiRegisterChoice as QtiRegisterChoice, qtiRegisterHotspot as QtiRegisterHotspot, qtiRegisterInteraction as QtiRegisterInteraction, qtiRegisterVariable as QtiRegisterVariable, QtiResponseCondition, QtiResponseDeclaration, QtiResponseElse, QtiResponseElseIf, QtiResponseIf, QtiResponseProcessing, QtiRule, QtiSPositionObjectInteraction, QtiSelectPointInteraction, QtiSetOutcomeValue, QtiSimpleAssociableChoice, QtiSimpleChoice, QtiSliderInteraction, QtiStringMatch, QtiStylesheet, QtiSum, QtiTest, QtiTestPagingButtons, QtiTestPagingRadio, QtiTestPart, QtiTestPrintScore, QtiTestProgress, QtiTestShowCorrect, QtiTestSlider, QtiTextEntryInteraction, QtiVariable, ResponseInteraction, ResponseVariable, TestNext, TestPrev, TestScript, TestShowIndex, VariableDeclaration, directedPair, float, integer, itemContext, qtiContentBody, qtiRubricBlock, qtiTransform };
1216
+ /**
1217
+ * Requests an XML item from the specified URL.
1218
+ * @param href - The URL of the XML item to request.
1219
+ * @returns A Promise that resolves to the XML item as a string.
1220
+ */
1221
+ declare function requestItem(href: string): Promise<string>;
1222
+ type ManifestData = {
1223
+ itemLocation: string;
1224
+ testIdentifier: string;
1225
+ items: {
1226
+ identifier: string;
1227
+ href: string;
1228
+ category: string;
1229
+ }[];
1230
+ };
1231
+ /**
1232
+ * Fetches manifest data for a given package URI.
1233
+ * @param packageUri The URI of the package to fetch manifest data for.
1234
+ * @returns A Promise that resolves to a ManifestData object.
1235
+ */
1236
+ declare const fetchManifestData: (packageUri: string) => Promise<ManifestData>;
1237
+
1238
+ export { BaseType, Calculate, Cardinality, Events, Interaction, InteractionChangedDetails, ItemContext, ManifestData, Multiple, Ordered, OutcomeChangedDetails, OutcomeVariable, QtPrintedVariable, QtiAnd, QtiAssessmentItem, QtiAssessmentItemRef, QtiAssessmentTest, QtiAssociableHotspot, QtiAssociateInteraction, QtiBaseValue, QtiChoice, qtiChoiceElementSelected as QtiChoiceElementSelected, QtiChoiceInteraction, QtiCompanionMaterialsInfo, QtiConditionExpression, QtiContains, QtiCorrect, QtiCustomOperator, QtiEndAttemptInteraction, QtiEqual, QtiEqualRounded, QtiExpression, QtiExtendedTextInteraction, QtiFeedbackBlock, QtiFeedbackInline, QtiGap, QtiGapImg, QtiGapMatchInteraction, QtiGapText, QtiGraphicAssociateInteraction, QtiGraphicGapMatchInteraction, QtiGraphicOrderInteraction, QtiGt, QtiGte, QtiHotspotChoice, QtiHotspotInteraction, QtiHottext, QtiHottextInteraction, QtiInlineChoice, QtiInlineChoiceInteraction, qtiInteractionChanged as QtiInteractionChanged, qtiInteractionResponse as QtiInteractionResponse, QtiIsNull, QtiItem, qtiLooseChoice as QtiLooseChoice, QtiLt, QtiLte, QtiMapResponse, QtiMapping, QtiMatch, QtiMatchInteraction, QtiMediaInteraction, QtiMember, QtiModalFeedback, QtiMultiple, QtiNot, QtiOr, QtiOrderInteraction, QtiOrdered, qtiOutcomeChanged as QtiOutcomeChanged, QtiOutcomeDeclaration, QtiPortableCustomInteraction, QtiPositionObjectStage, QtiProduct, QtiPrompt, qtiRegisterChoice as QtiRegisterChoice, qtiRegisterHotspot as QtiRegisterHotspot, qtiRegisterInteraction as QtiRegisterInteraction, qtiRegisterVariable as QtiRegisterVariable, QtiResponseCondition, QtiResponseDeclaration, QtiResponseElse, QtiResponseElseIf, QtiResponseIf, QtiResponseProcessing, QtiRule, QtiSPositionObjectInteraction, QtiSelectPointInteraction, QtiSetOutcomeValue, QtiSimpleAssociableChoice, QtiSimpleChoice, QtiSliderInteraction, QtiStringMatch, QtiStylesheet, QtiSum, QtiTest, QtiTestPart, QtiTextEntryInteraction, QtiVariable, ResponseInteraction, ResponseVariable, TestContext, TestNext, TestPagingButtons, TestPagingRadio, TestPrev, TestPrintScore, TestPrintVariables, TestProgress, TestScript, TestShowCorrect, TestShowIndex, TestSlider, VariableDeclaration, directedPair, fetchManifestData, float, integer, itemContext, qtiContentBody, qtiRubricBlock, qtiTransform, requestItem, testContext };