@citolab/qti-components 10.0.0-next.13 → 10.0.0-next.15

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 (72) hide show
  1. package/cdn/index.global.js +1 -1
  2. package/cdn/index.js +522 -435
  3. package/dist/base.d.ts +4 -4
  4. package/dist/base.js +1 -1
  5. package/dist/{chunk-PHRHLDQB.js → chunk-32PI7KWX.js} +2 -2
  6. package/dist/{chunk-MDBNEEPH.js → chunk-5AJZGRWI.js} +8 -3
  7. package/dist/chunk-5AJZGRWI.js.map +1 -0
  8. package/dist/{chunk-LFVPS7KB.js → chunk-DAOLVUTR.js} +2 -2
  9. package/dist/{chunk-K4WLYVDT.js → chunk-F553IZPL.js} +2 -2
  10. package/dist/{chunk-HOGJ5ZNW.js → chunk-G2EIC7H2.js} +221 -107
  11. package/dist/chunk-G2EIC7H2.js.map +1 -0
  12. package/dist/{chunk-EIBGCCXH.js → chunk-HT3LSWXL.js} +2 -2
  13. package/dist/{chunk-WUIA4OOX.js → chunk-IM5AKPIJ.js} +34 -6
  14. package/dist/chunk-IM5AKPIJ.js.map +1 -0
  15. package/dist/{chunk-FLAD6SC6.js → chunk-IWNRQVNW.js} +2 -2
  16. package/dist/{chunk-TLAVOBEM.js → chunk-LORYM4U2.js} +120 -1
  17. package/dist/chunk-LORYM4U2.js.map +1 -0
  18. package/dist/{chunk-Y5DZTCDP.js → chunk-MIQZBDTB.js} +225 -258
  19. package/dist/chunk-MIQZBDTB.js.map +1 -0
  20. package/dist/{chunk-AKX4YMWU.js → chunk-QT7WQXCS.js} +237 -95
  21. package/dist/chunk-QT7WQXCS.js.map +1 -0
  22. package/dist/chunk-RNLSNH4N.js +7 -0
  23. package/dist/chunk-RNLSNH4N.js.map +1 -0
  24. package/dist/{chunk-H3GITIPE.js → chunk-URYYGVTA.js} +23 -7
  25. package/dist/chunk-URYYGVTA.js.map +1 -0
  26. package/dist/{chunk-G6LTYTJR.js → chunk-WIUPAUJV.js} +2 -2
  27. package/dist/{chunk-PYHKCIYN.js → chunk-XY5DHYIH.js} +4 -4
  28. package/dist/{config.context.d-BniMHSBB.d.ts → config.context.d-CCqlJXpE.d.ts} +2 -1
  29. package/dist/corrections.d.ts +8 -8
  30. package/dist/corrections.js +9 -9
  31. package/dist/elements.d.ts +84 -14
  32. package/dist/elements.js +4 -4
  33. package/dist/index.d.ts +9 -9
  34. package/dist/index.js +15 -15
  35. package/dist/interactions.d.ts +17 -5
  36. package/dist/interactions.js +3 -3
  37. package/dist/item.css +132 -18
  38. package/dist/item.d.ts +4 -4
  39. package/dist/item.js +5 -5
  40. package/dist/loader.d.ts +2 -2
  41. package/dist/loader.js +2 -2
  42. package/dist/processing.d.ts +8 -4
  43. package/dist/processing.js +3 -3
  44. package/dist/qti-components-jsx.d.ts +291 -115
  45. package/dist/{qti-feedback.d-DbzPSJuK.d.ts → qti-feedback.d-GAqMqAt6.d.ts} +7 -0
  46. package/dist/{qti-item.d-BqWYBdV2.d.ts → qti-item.d-pFcNk0th.d.ts} +1 -1
  47. package/dist/{qti-rule-base.d-Bdzg8eGH.d.ts → qti-rule-base.d-CeKP0Ooi.d.ts} +2 -2
  48. package/dist/{qti-test.d-B6AGSQlk.d.ts → qti-test.d-BjhVQnQy.d.ts} +31 -5
  49. package/dist/{qti-text-entry-interaction.d-B44Z3qUG.d.ts → qti-text-entry-interaction.d-DECzpIzi.d.ts} +50 -14
  50. package/dist/{qti-transform-test.d-BL7GGFJj.d.ts → qti-transform-test.d-Bb9vnLzP.d.ts} +1 -0
  51. package/dist/{record.d-C6m0Y4xr.d.ts → record.d-CljDLwRz.d.ts} +1 -1
  52. package/dist/test.d.ts +6 -6
  53. package/dist/test.js +6 -6
  54. package/dist/transformers.d.ts +1 -1
  55. package/dist/transformers.js +1 -1
  56. package/package.json +11 -11
  57. package/dist/chunk-AKX4YMWU.js.map +0 -1
  58. package/dist/chunk-DVLSXMXD.js +0 -7
  59. package/dist/chunk-DVLSXMXD.js.map +0 -1
  60. package/dist/chunk-H3GITIPE.js.map +0 -1
  61. package/dist/chunk-HOGJ5ZNW.js.map +0 -1
  62. package/dist/chunk-MDBNEEPH.js.map +0 -1
  63. package/dist/chunk-TLAVOBEM.js.map +0 -1
  64. package/dist/chunk-WUIA4OOX.js.map +0 -1
  65. package/dist/chunk-Y5DZTCDP.js.map +0 -1
  66. /package/dist/{chunk-PHRHLDQB.js.map → chunk-32PI7KWX.js.map} +0 -0
  67. /package/dist/{chunk-LFVPS7KB.js.map → chunk-DAOLVUTR.js.map} +0 -0
  68. /package/dist/{chunk-K4WLYVDT.js.map → chunk-F553IZPL.js.map} +0 -0
  69. /package/dist/{chunk-EIBGCCXH.js.map → chunk-HT3LSWXL.js.map} +0 -0
  70. /package/dist/{chunk-FLAD6SC6.js.map → chunk-IWNRQVNW.js.map} +0 -0
  71. /package/dist/{chunk-G6LTYTJR.js.map → chunk-WIUPAUJV.js.map} +0 -0
  72. /package/dist/{chunk-PYHKCIYN.js.map → chunk-XY5DHYIH.js.map} +0 -0
@@ -14,7 +14,6 @@ import type {
14
14
  import type {
15
15
  QtiTemplateConstraint,
16
16
  QtiTemplateProcessing,
17
- QtiResponseProcessing,
18
17
  QtiAssessmentItem,
19
18
  QtiAssessmentStimulus,
20
19
  QtiAssessmentStimulusRef,
@@ -29,6 +28,7 @@ import type {
29
28
  QtiModalFeedback,
30
29
  QtiOutcomeDeclaration,
31
30
  QtiResponseDeclaration,
31
+ QtiResponseProcessing,
32
32
  QtiRubricBlock,
33
33
  QtiStylesheet,
34
34
  QtiTemplateDeclaration,
@@ -324,15 +324,6 @@ export type QtiTemplateProcessingSolidJsProps = {
324
324
  textContent?: string | number | undefined;
325
325
  };
326
326
 
327
- export type QtiResponseProcessingProps = {};
328
-
329
- export type QtiResponseProcessingSolidJsProps = {
330
- /** Set the innerHTML of the element */
331
- innerHTML?: string | undefined;
332
- /** Set the textContent of the element */
333
- textContent?: string | number | undefined;
334
- };
335
-
336
327
  export type QtiAssessmentItemProps = {
337
328
  /** */
338
329
  identifier?: QtiAssessmentItem["identifier"] | undefined;
@@ -361,7 +352,7 @@ follow, so the item keeps no list of them to set it on. */
361
352
 
362
353
  /** */
363
354
  "onqti-assessment-item-connected"?: ((e: CustomEvent) => void) | undefined;
364
- /** Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing. */
355
+ /** */
365
356
  "onqti-item-context-updated"?: ((e: CustomEvent) => void) | undefined;
366
357
  };
367
358
 
@@ -394,7 +385,7 @@ follow, so the item keeps no list of them to set it on. */
394
385
  "prop:responses"?: QtiAssessmentItem["responses"] | undefined;
395
386
  /** */
396
387
  "on:qti-assessment-item-connected"?: ((e: CustomEvent) => void) | undefined;
397
- /** Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing. */
388
+ /** */
398
389
  "on:qti-item-context-updated"?: ((e: CustomEvent) => void) | undefined;
399
390
 
400
391
  /** Set the innerHTML of the element */
@@ -471,15 +462,11 @@ export type QtiContextDeclarationSolidJsProps = {
471
462
  export type QtiCustomOperatorProps = {
472
463
  /** */
473
464
  "onqti-set-outcome-value"?: ((e: CustomEvent) => void) | undefined;
474
- /** */
475
- "onqti-interaction-response"?: ((e: CustomEvent) => void) | undefined;
476
465
  };
477
466
 
478
467
  export type QtiCustomOperatorSolidJsProps = {
479
468
  /** */
480
469
  "on:qti-set-outcome-value"?: ((e: CustomEvent) => void) | undefined;
481
- /** */
482
- "on:qti-interaction-response"?: ((e: CustomEvent) => void) | undefined;
483
470
 
484
471
  /** Set the innerHTML of the element */
485
472
  innerHTML?: string | undefined;
@@ -683,6 +670,15 @@ export type QtiResponseDeclarationSolidJsProps = {
683
670
  textContent?: string | number | undefined;
684
671
  };
685
672
 
673
+ export type QtiResponseProcessingProps = {};
674
+
675
+ export type QtiResponseProcessingSolidJsProps = {
676
+ /** Set the innerHTML of the element */
677
+ innerHTML?: string | undefined;
678
+ /** Set the textContent of the element */
679
+ textContent?: string | number | undefined;
680
+ };
681
+
686
682
  export type QtiRubricBlockProps = {
687
683
  /** */
688
684
  id?: QtiRubricBlock["id"] | undefined;
@@ -1626,9 +1622,17 @@ export type QtiEndAttemptInteractionProps = {
1626
1622
  | undefined;
1627
1623
  /** */
1628
1624
  disabled?: QtiEndAttemptInteraction["disabled"] | undefined;
1629
- /** Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt) */
1625
+ /** Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
1626
+ uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
1627
+ should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
1628
+ as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
1629
+ [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction) */
1630
1630
  "count-attempt"?: QtiEndAttemptInteraction["countAttempt"] | undefined;
1631
- /** Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt) */
1631
+ /** Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
1632
+ uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
1633
+ should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
1634
+ as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
1635
+ [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction) */
1632
1636
  countAttempt?: QtiEndAttemptInteraction["countAttempt"] | undefined;
1633
1637
  /** */
1634
1638
  title?: QtiEndAttemptInteraction["title"] | undefined;
@@ -1648,9 +1652,17 @@ export type QtiEndAttemptInteractionSolidJsProps = {
1648
1652
  | undefined;
1649
1653
  /** */
1650
1654
  "prop:disabled"?: QtiEndAttemptInteraction["disabled"] | undefined;
1651
- /** Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt) */
1655
+ /** Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
1656
+ uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
1657
+ should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
1658
+ as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
1659
+ [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction) */
1652
1660
  "attr:count-attempt"?: QtiEndAttemptInteraction["countAttempt"] | undefined;
1653
- /** Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt) */
1661
+ /** Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
1662
+ uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
1663
+ should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
1664
+ as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
1665
+ [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction) */
1654
1666
  "prop:countAttempt"?: QtiEndAttemptInteraction["countAttempt"] | undefined;
1655
1667
  /** */
1656
1668
  "prop:title"?: QtiEndAttemptInteraction["title"] | undefined;
@@ -2176,6 +2188,10 @@ casts, rather than pretending at an encapsulation the type system was the only t
2176
2188
  };
2177
2189
 
2178
2190
  export type QtiGraphicGapMatchInteractionProps = {
2191
+ /** QTI's default (information model §5.60). */
2192
+ maxAssociations?:
2193
+ | QtiGraphicGapMatchInteraction["maxAssociations"]
2194
+ | undefined;
2179
2195
  /** A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
2180
2196
  `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
2181
2197
  beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
@@ -2197,6 +2213,10 @@ their hotspots through `--qti-graphic-scale` instead. */
2197
2213
  };
2198
2214
 
2199
2215
  export type QtiGraphicGapMatchInteractionSolidJsProps = {
2216
+ /** QTI's default (information model §5.60). */
2217
+ "prop:maxAssociations"?:
2218
+ | QtiGraphicGapMatchInteraction["maxAssociations"]
2219
+ | undefined;
2200
2220
  /** A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
2201
2221
  `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
2202
2222
  beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
@@ -2599,7 +2619,8 @@ Declared rather than read straight off `dataset` so it reaches the custom elemen
2599
2619
  manifest, the generated types and the Storybook controls — and so that changing it
2600
2620
  re-renders, which reading `dataset` at render time never did.
2601
2621
 
2602
- Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. */
2622
+ Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
2623
+ string is a value, not a missing one: `data-prompt=""` shows an empty placeholder. */
2603
2624
  "data-prompt"?: QtiInlineChoiceInteraction["dataPrompt"] | undefined;
2604
2625
  /** Placeholder shown in the closed combobox before a choice is picked.
2605
2626
 
@@ -2607,8 +2628,15 @@ Declared rather than read straight off `dataset` so it reaches the custom elemen
2607
2628
  manifest, the generated types and the Storybook controls — and so that changing it
2608
2629
  re-renders, which reading `dataset` at render time never did.
2609
2630
 
2610
- Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. */
2631
+ Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
2632
+ string is a value, not a missing one: `data-prompt=""` shows an empty placeholder. */
2611
2633
  dataPrompt?: QtiInlineChoiceInteraction["dataPrompt"] | undefined;
2634
+ /** Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
2635
+ been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`. */
2636
+ "data-clear-label"?: QtiInlineChoiceInteraction["dataClearLabel"] | undefined;
2637
+ /** Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
2638
+ been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`. */
2639
+ dataClearLabel?: QtiInlineChoiceInteraction["dataClearLabel"] | undefined;
2612
2640
  /** Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2613
2641
  shuffle?: unknown | undefined;
2614
2642
  /** Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element. */
@@ -2693,7 +2721,8 @@ Declared rather than read straight off `dataset` so it reaches the custom elemen
2693
2721
  manifest, the generated types and the Storybook controls — and so that changing it
2694
2722
  re-renders, which reading `dataset` at render time never did.
2695
2723
 
2696
- Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. */
2724
+ Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
2725
+ string is a value, not a missing one: `data-prompt=""` shows an empty placeholder. */
2697
2726
  "attr:data-prompt"?: QtiInlineChoiceInteraction["dataPrompt"] | undefined;
2698
2727
  /** Placeholder shown in the closed combobox before a choice is picked.
2699
2728
 
@@ -2701,8 +2730,19 @@ Declared rather than read straight off `dataset` so it reaches the custom elemen
2701
2730
  manifest, the generated types and the Storybook controls — and so that changing it
2702
2731
  re-renders, which reading `dataset` at render time never did.
2703
2732
 
2704
- Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. */
2733
+ Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
2734
+ string is a value, not a missing one: `data-prompt=""` shows an empty placeholder. */
2705
2735
  "prop:dataPrompt"?: QtiInlineChoiceInteraction["dataPrompt"] | undefined;
2736
+ /** Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
2737
+ been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`. */
2738
+ "attr:data-clear-label"?:
2739
+ | QtiInlineChoiceInteraction["dataClearLabel"]
2740
+ | undefined;
2741
+ /** Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
2742
+ been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`. */
2743
+ "prop:dataClearLabel"?:
2744
+ | QtiInlineChoiceInteraction["dataClearLabel"]
2745
+ | undefined;
2706
2746
  /** Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2707
2747
  "bool:shuffle"?: unknown | undefined;
2708
2748
  /** Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element. */
@@ -2783,19 +2823,27 @@ export type QtiMatchInteractionProps = {
2783
2823
  "response-identifier"?: QtiMatchInteraction["responseIdentifier"] | undefined;
2784
2824
  /** Required. Identifier of the bound response variable. */
2785
2825
  responseIdentifier?: QtiMatchInteraction["responseIdentifier"] | undefined;
2786
- /** Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md. */
2826
+ /** Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89). */
2787
2827
  "max-associations"?: QtiMatchInteraction["maxAssociations"] | undefined;
2788
- /** Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md. */
2828
+ /** Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89). */
2789
2829
  maxAssociations?: QtiMatchInteraction["maxAssociations"] | undefined;
2790
- /** Minimum pairings for a valid response. */
2830
+ /** Minimum pairings for a valid response (QTI's default). */
2791
2831
  "min-associations"?: QtiMatchInteraction["minAssociations"] | undefined;
2792
- /** Minimum pairings for a valid response. */
2832
+ /** Minimum pairings for a valid response (QTI's default). */
2793
2833
  minAssociations?: QtiMatchInteraction["minAssociations"] | undefined;
2834
+ /** QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell. */
2835
+ "data-first-column-header"?:
2836
+ | QtiMatchInteraction["dataFirstColumnHeader"]
2837
+ | undefined;
2838
+ /** QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell. */
2839
+ dataFirstColumnHeader?:
2840
+ | QtiMatchInteraction["dataFirstColumnHeader"]
2841
+ | undefined;
2794
2842
  /** Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2795
2843
  shuffle?: unknown | undefined;
2796
2844
  /** Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2797
2845
  undefined?: unknown | undefined;
2798
- /** QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop; the `qti-choices-*` values position the source set. */
2846
+ /** QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop, and with it `qti-header-hidden` leaves out the column-header row; the `qti-choices-*` values position the source set. */
2799
2847
  class?: QtiMatchInteraction["class"] | undefined;
2800
2848
  /** Extension, not QTI. Sizes every drop target to the widest chip so placement does not reflow the layout. The mixin default is `true`; this interaction is the one that overrides it to `false`, because a match target is a category card rather than a socket (see the field below and DROP-SIZING.md §1). */
2801
2849
  "auto-size-dropzones"?: unknown | undefined;
@@ -2880,19 +2928,27 @@ export type QtiMatchInteractionSolidJsProps = {
2880
2928
  "prop:responseIdentifier"?:
2881
2929
  | QtiMatchInteraction["responseIdentifier"]
2882
2930
  | undefined;
2883
- /** Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md. */
2931
+ /** Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89). */
2884
2932
  "attr:max-associations"?: QtiMatchInteraction["maxAssociations"] | undefined;
2885
- /** Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md. */
2933
+ /** Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89). */
2886
2934
  "prop:maxAssociations"?: QtiMatchInteraction["maxAssociations"] | undefined;
2887
- /** Minimum pairings for a valid response. */
2935
+ /** Minimum pairings for a valid response (QTI's default). */
2888
2936
  "attr:min-associations"?: QtiMatchInteraction["minAssociations"] | undefined;
2889
- /** Minimum pairings for a valid response. */
2937
+ /** Minimum pairings for a valid response (QTI's default). */
2890
2938
  "prop:minAssociations"?: QtiMatchInteraction["minAssociations"] | undefined;
2939
+ /** QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell. */
2940
+ "attr:data-first-column-header"?:
2941
+ | QtiMatchInteraction["dataFirstColumnHeader"]
2942
+ | undefined;
2943
+ /** QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell. */
2944
+ "prop:dataFirstColumnHeader"?:
2945
+ | QtiMatchInteraction["dataFirstColumnHeader"]
2946
+ | undefined;
2891
2947
  /** Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2892
2948
  "bool:shuffle"?: unknown | undefined;
2893
2949
  /** Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element. */
2894
2950
  "prop:undefined"?: unknown | undefined;
2895
- /** QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop; the `qti-choices-*` values position the source set. */
2951
+ /** QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop, and with it `qti-header-hidden` leaves out the column-header row; the `qti-choices-*` values position the source set. */
2896
2952
  "prop:class"?: QtiMatchInteraction["class"] | undefined;
2897
2953
  /** Extension, not QTI. Sizes every drop target to the widest chip so placement does not reflow the layout. The mixin default is `true`; this interaction is the one that overrides it to `false`, because a match target is a category card rather than a socket (see the field below and DROP-SIZING.md §1). */
2898
2954
  "bool:auto-size-dropzones"?: unknown | undefined;
@@ -4627,16 +4683,28 @@ object, do not mutate it: an in-place change does not notify the components insi
4627
4683
  };
4628
4684
 
4629
4685
  export type TestEndAttemptProps = {
4630
- /** */
4686
+ /** Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says. */
4687
+ "require-answer"?: TestEndAttempt["requireAnswer"] | undefined;
4688
+ /** Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says. */
4689
+ requireAnswer?: TestEndAttempt["requireAnswer"] | undefined;
4690
+ /** The item-ref identifier whose attempt this button ends; without it, the item it is stamped into, or else the one on screen. */
4691
+ item?: TestEndAttempt["item"] | undefined;
4692
+ /** Reflected: the item's attempt cannot be ended. */
4631
4693
  disabled?: TestEndAttempt["_internalDisabled"] | undefined;
4632
- /** */
4694
+ /** Reflected: the item's attempt cannot be ended. */
4633
4695
  _internalDisabled?: TestEndAttempt["_internalDisabled"] | undefined;
4634
4696
  };
4635
4697
 
4636
4698
  export type TestEndAttemptSolidJsProps = {
4637
- /** */
4699
+ /** Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says. */
4700
+ "bool:require-answer"?: TestEndAttempt["requireAnswer"] | undefined;
4701
+ /** Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says. */
4702
+ "prop:requireAnswer"?: TestEndAttempt["requireAnswer"] | undefined;
4703
+ /** The item-ref identifier whose attempt this button ends; without it, the item it is stamped into, or else the one on screen. */
4704
+ "prop:item"?: TestEndAttempt["item"] | undefined;
4705
+ /** Reflected: the item's attempt cannot be ended. */
4638
4706
  "bool:disabled"?: TestEndAttempt["_internalDisabled"] | undefined;
4639
- /** */
4707
+ /** Reflected: the item's attempt cannot be ended. */
4640
4708
  "prop:_internalDisabled"?: TestEndAttempt["_internalDisabled"] | undefined;
4641
4709
 
4642
4710
  /** Set the innerHTML of the element */
@@ -6321,7 +6389,7 @@ follow, so the item keeps no list of them to set it on. */
6321
6389
 
6322
6390
  /** */
6323
6391
  "onqti-assessment-item-connected"?: ((e: CustomEvent) => void) | undefined;
6324
- /** Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing. */
6392
+ /** */
6325
6393
  "onqti-item-context-updated"?: ((e: CustomEvent) => void) | undefined;
6326
6394
  };
6327
6395
 
@@ -6358,7 +6426,7 @@ follow, so the item keeps no list of them to set it on. */
6358
6426
  "prop:responses"?: QtiAssessmentItemCorrection["responses"] | undefined;
6359
6427
  /** */
6360
6428
  "on:qti-assessment-item-connected"?: ((e: CustomEvent) => void) | undefined;
6361
- /** Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing. */
6429
+ /** */
6362
6430
  "on:qti-item-context-updated"?: ((e: CustomEvent) => void) | undefined;
6363
6431
 
6364
6432
  /** Set the innerHTML of the element */
@@ -6727,19 +6795,6 @@ export type CustomElements = {
6727
6795
  QtiTemplateProcessingProps & BaseProps<QtiTemplateProcessing> & BaseEvents
6728
6796
  >;
6729
6797
 
6730
- /**
6731
- *
6732
- *
6733
- * ## Methods
6734
- *
6735
- * Methods that can be called to access component functionality.
6736
- *
6737
- * - `process() => void`: undefined
6738
- */
6739
- "qti-response-processing": Partial<
6740
- QtiResponseProcessingProps & BaseProps<QtiResponseProcessing> & BaseEvents
6741
- >;
6742
-
6743
6798
  /**
6744
6799
  *
6745
6800
  *
@@ -6767,13 +6822,18 @@ export type CustomElements = {
6767
6822
  * Events that will be emitted by the component.
6768
6823
  *
6769
6824
  * - `qti-assessment-item-connected`: undefined
6770
- * - `qti-item-context-updated`: Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing.
6825
+ * - `qti-item-context-updated`: undefined
6771
6826
  *
6772
6827
  * ## Methods
6773
6828
  *
6774
6829
  * Methods that can be called to access component functionality.
6775
6830
  *
6776
- * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => boolean`: undefined
6831
+ * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => void`: Scores the attempt. The item does not score itself: its response processing does, like a
6832
+ * backend, and sends the outcomes back in `cito-item-set-outcomes`, which the item applies in one
6833
+ * update. The item keeps the attempt count (QTI info model §2.2.2: the delivery engine maintains
6834
+ * numAttempts) and hands the new count to the run, whose rules may read it. Without response
6835
+ * processing the item only counts the attempt. A run that throws still counts the attempt and applies
6836
+ * no outcomes.
6777
6837
  * - `resetResponses() => void`: undefined
6778
6838
  * - `getOutcome(identifier: string) => Readonly<OutcomeVariable>`: undefined
6779
6839
  * - `updateTemplateVariable(identifier: string, value: string | string[] | undefined) => void`: Updates the template variable with the specified identifier to the given value.
@@ -6886,7 +6946,6 @@ export type CustomElements = {
6886
6946
  * Events that will be emitted by the component.
6887
6947
  *
6888
6948
  * - `qti-set-outcome-value`: undefined
6889
- * - `qti-interaction-response`: undefined
6890
6949
  *
6891
6950
  * ## Methods
6892
6951
  *
@@ -7040,6 +7099,25 @@ export type CustomElements = {
7040
7099
  QtiResponseDeclarationProps & BaseProps<QtiResponseDeclaration> & BaseEvents
7041
7100
  >;
7042
7101
 
7102
+ /**
7103
+ * Response processing as the item's own backend: it reads the item context, runs its rules once and
7104
+ * sends the outcomes and the attempt count back in one `cito-item-set-outcomes`. The item applies
7105
+ * them; a host that scores elsewhere sends the same event instead.
7106
+ *
7107
+ * ## Methods
7108
+ *
7109
+ * Methods that can be called to access component functionality.
7110
+ *
7111
+ * - `processResponse({ numAttempts }: { numAttempts: number }) => void`: Scores the attempt on the copy: sets `numAttempts` to the count the item hands over, resets a
7112
+ * non-adaptive item's outcomes to their defaults (QTI info model §2.5), runs the rules and sends
7113
+ * every outcome and `numAttempts` in one `cito-item-set-outcomes`. The item applies them and publishes, which gives this element a
7114
+ * fresh copy. A rule that throws ends the run and the error propagates; nothing is sent, and the
7115
+ * run's writes stay in the copy until the item's next update.
7116
+ */
7117
+ "qti-response-processing": Partial<
7118
+ QtiResponseProcessingProps & BaseProps<QtiResponseProcessing> & BaseEvents
7119
+ >;
7120
+
7043
7121
  /**
7044
7122
  *
7045
7123
  *
@@ -7682,13 +7760,21 @@ export type CustomElements = {
7682
7760
  /**
7683
7761
  * A button that ends the current attempt.
7684
7762
  *
7763
+ * It follows its item: it cannot be pressed while the item is `disabled` or `readonly`, or once an
7764
+ * adaptive item is done. An adaptive item that sets `completionStatus` to `completed` closes its
7765
+ * session, so no further attempt can start (QTI info model §2.5).
7766
+ *
7685
7767
  * ## Attributes & Properties
7686
7768
  *
7687
7769
  * Component attributes and properties that can be applied to the element or by using JavaScript.
7688
7770
  *
7689
7771
  * - `response-identifier`/`responseIdentifier`: undefined
7690
7772
  * - `disabled`: undefined
7691
- * - `count-attempt`/`countAttempt`: Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt)
7773
+ * - `count-attempt`/`countAttempt`: Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
7774
+ * uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
7775
+ * should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
7776
+ * as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
7777
+ * [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction)
7692
7778
  * - `title`: undefined
7693
7779
  *
7694
7780
  * ## Events
@@ -8014,6 +8100,7 @@ export type CustomElements = {
8014
8100
  *
8015
8101
  * Component attributes and properties that can be applied to the element or by using JavaScript.
8016
8102
  *
8103
+ * - `maxAssociations`: QTI's default (information model §5.60). (property only)
8017
8104
  * - `autoSizeDropzones`: A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
8018
8105
  * `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
8019
8106
  * beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
@@ -8292,7 +8379,10 @@ export type CustomElements = {
8292
8379
  * manifest, the generated types and the Storybook controls — and so that changing it
8293
8380
  * re-renders, which reading `dataset` at render time never did.
8294
8381
  *
8295
- * Falls back to the item configuration's `inlineChoicePrompt`, then to `select`.
8382
+ * Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
8383
+ * string is a value, not a missing one: `data-prompt=""` shows an empty placeholder.
8384
+ * - `data-clear-label`/`dataClearLabel`: Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
8385
+ * been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`.
8296
8386
  * - `shuffle`/`undefined`: Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element.
8297
8387
  * - `required`: Whether a choice must be selected for the response to be valid. QTI defaults this to
8298
8388
  * false, so an untouched dropdown is a valid empty response unless an author opts in.
@@ -8356,6 +8446,10 @@ export type CustomElements = {
8356
8446
  *
8357
8447
  * Methods that can be called to access component functionality.
8358
8448
  *
8449
+ * - `menuAutoSizeRows() => HTMLElement[]`: Leaves the prompt row out of the width measurement when the prompt is empty. That row is hidden
8450
+ * while nothing is chosen (measures 0) and a clear glyph once something is (measures a glyph), so
8451
+ * counting it would let the closed field change width on the first choice. Its text is empty
8452
+ * either way, so it has nothing to contribute.
8359
8453
  * - `shouldAutoSizeMenu() => boolean`: Autosizing is on unless a host turns it off (`configContext.inlineChoiceAutosize: false`), and an
8360
8454
  * explicit `qti-input-width-*` class always wins. On by default because without it the field sizes
8361
8455
  * to the option shown, so choosing a longer one widened the field and reflowed the sentence around
@@ -8364,7 +8458,8 @@ export type CustomElements = {
8364
8458
  * That second check has to live here rather than in CSS: the measurement is written as an inline
8365
8459
  * style on the trigger, and the width classes set the same property on `:host`, so the cascade
8366
8460
  * would hand it to the measurement every time. Not writing at all is what makes the class win.
8367
- * - `menuAutoSizeExtraWidth() => number`: The chevron sits in the trigger and not in the menu, so the menu never measures it.
8461
+ * - `menuAutoSizeExtraWidth() => number`: The chevron (and the gap before it) sits in the trigger and not in the menu, so the menu never
8462
+ * measures it.
8368
8463
  *
8369
8464
  * `offsetWidth`, NOT `getBoundingClientRect().width`: the icon rotates when the menu opens, and a
8370
8465
  * client rect reports the TRANSFORMED box — so a chevron caught mid-rotation measures wider than
@@ -8375,11 +8470,6 @@ export type CustomElements = {
8375
8470
  * - `reportValidity() => boolean`: undefined
8376
8471
  * - `reset() => void`: undefined
8377
8472
  * - `menuAutoSizePropertyTarget() => HTMLElement | null`: Where the measured width is written. Inside the shadow root — see the header.
8378
- * - `menuAutoSizeRows() => HTMLElement[]`: The menu's rows, which is what actually gets measured — one at a time.
8379
- *
8380
- * Flat tree, so a `<slot>` is replaced by the elements assigned to it: in the shipped control the
8381
- * prompt is rendered in the shadow root and the author's options are slotted light DOM, and both
8382
- * are rows of the same list.
8383
8473
  * - `withMenuMeasurable(measure: () => T) => T`: Make the rows measurable, run `measure`, and put everything back.
8384
8474
  *
8385
8475
  * A hook, because hosts hide their menu differently and a measurement needs layout. The default
@@ -8401,8 +8491,9 @@ export type CustomElements = {
8401
8491
  * - `value`: The currently displayed value inside the trigger.
8402
8492
  * - `dropdown-icon`: The chevron icon inside the trigger; also carries `dropdown-icon-open` when open.
8403
8493
  * - `menu`: The popover element containing the option list.
8404
- * - `option`: Each option button; also carries `option-prompt` and `option-selected` variants.
8494
+ * - `option`: Each option button; also carries `option-prompt`, `option-selected` and `option-clear` (the prompt row as a clear button, see `data-clear-label`) variants.
8405
8495
  * - `option-content`: The content wrapper inside each option.
8496
+ * - `clear-icon`: The x glyph inside the clear row.
8406
8497
  */
8407
8498
  "qti-inline-choice-interaction": Partial<
8408
8499
  QtiInlineChoiceInteractionProps &
@@ -8418,10 +8509,11 @@ export type CustomElements = {
8418
8509
  * Component attributes and properties that can be applied to the element or by using JavaScript.
8419
8510
  *
8420
8511
  * - `response-identifier`/`responseIdentifier`: Required. Identifier of the bound response variable.
8421
- * - `max-associations`/`maxAssociations`: Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md.
8422
- * - `min-associations`/`minAssociations`: Minimum pairings for a valid response.
8512
+ * - `max-associations`/`maxAssociations`: Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89).
8513
+ * - `min-associations`/`minAssociations`: Minimum pairings for a valid response (QTI's default).
8514
+ * - `data-first-column-header`/`dataFirstColumnHeader`: QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell.
8423
8515
  * - `shuffle`/`undefined`: Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element.
8424
- * - `class`: QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop; the `qti-choices-*` values position the source set.
8516
+ * - `class`: QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop, and with it `qti-header-hidden` leaves out the column-header row; the `qti-choices-*` values position the source set.
8425
8517
  * - `auto-size-dropzones`/`undefined`: Extension, not QTI. Sizes every drop target to the widest chip so placement does not reflow the layout. The mixin default is `true`; this interaction is the one that overrides it to `false`, because a match target is a category card rather than a socket (see the field below and DROP-SIZING.md §1).
8426
8518
  * - `disable-animations`/`disableAnimations`: Extension, not QTI. Disables the FLIP move animation.
8427
8519
  * - `response`: undefined
@@ -8538,7 +8630,7 @@ export type CustomElements = {
8538
8630
  * Custom selectors for styling elements within the component.
8539
8631
  *
8540
8632
  * - `grid`: The tabular grid container.
8541
- * - `corner`: The top-left corner cell of the grid.
8633
+ * - `corner`: The top-left corner cell of the grid; shows `data-first-column-header`.
8542
8634
  * - `cols-wrap`: Wrapper row for the column headers.
8543
8635
  * - `c-header`: The column header slot wrapper.
8544
8636
  * - `rows-wrap`: Wrapper column for the row headers.
@@ -9610,13 +9702,34 @@ export type CustomElements = {
9610
9702
  "qti-test": Partial<QtiTestProps & BaseProps<QtiTest> & BaseEvents>;
9611
9703
 
9612
9704
  /**
9705
+ * A button that ends the attempt of an item: its response is processed, `numAttempts` goes up and
9706
+ * feedback is shown as the item's session control allows. It dispatches `cito-test-end-attempt`,
9707
+ * which `<test-navigation>` handles.
9708
+ *
9709
+ * Put it inside `<test-navigation>`, either in the toolbar, where it ends the attempt of the item on
9710
+ * screen, or in the `<template item-ref>`, where each item gets its own and it ends the attempt of
9711
+ * that item: with `<qti-test navigate="section">` every item of the section is on screen, each with
9712
+ * its own button. Give it an `item` (an item-ref identifier) to end the attempt of that item instead,
9713
+ * wherever the button sits.
9613
9714
  *
9715
+ * It is `disabled` by the state of its item: when the attempts allowed by `max-attempts` are used
9716
+ * (non-adaptive items), when the last attempt was already optimal (non-adaptive items), when an
9717
+ * adaptive item is completed, or, when skipping is not allowed, while the response is invalid or
9718
+ * still the default.
9614
9719
  *
9615
9720
  * ## Attributes & Properties
9616
9721
  *
9617
9722
  * Component attributes and properties that can be applied to the element or by using JavaScript.
9618
9723
  *
9619
- * - `disabled`/`_internalDisabled`: undefined
9724
+ * - `require-answer`/`requireAnswer`: Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says.
9725
+ * - `item`: The item-ref identifier whose attempt this button ends; without it, the item it is stamped into, or else the one on screen.
9726
+ * - `disabled`/`_internalDisabled`: Reflected: the item's attempt cannot be ended.
9727
+ *
9728
+ * ## Slots
9729
+ *
9730
+ * Areas where markup can be added to the component.
9731
+ *
9732
+ * - `(default)`: The label.
9620
9733
  *
9621
9734
  * ## Methods
9622
9735
  *
@@ -11435,7 +11548,8 @@ export type CustomElements = {
11435
11548
  *
11436
11549
  * Methods that can be called to access component functionality.
11437
11550
  *
11438
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
11551
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
11552
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
11439
11553
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
11440
11554
  * - `process() => void`: undefined
11441
11555
  */
@@ -11450,7 +11564,8 @@ export type CustomElements = {
11450
11564
  *
11451
11565
  * Methods that can be called to access component functionality.
11452
11566
  *
11453
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
11567
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
11568
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
11454
11569
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
11455
11570
  * - `process() => void`: undefined
11456
11571
  */
@@ -11716,7 +11831,8 @@ export type CustomElements = {
11716
11831
  *
11717
11832
  * Methods that can be called to access component functionality.
11718
11833
  *
11719
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
11834
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
11835
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
11720
11836
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
11721
11837
  * - `process() => void`: undefined
11722
11838
  */
@@ -11731,7 +11847,8 @@ export type CustomElements = {
11731
11847
  *
11732
11848
  * Methods that can be called to access component functionality.
11733
11849
  *
11734
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
11850
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
11851
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
11735
11852
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
11736
11853
  * - `process() => void`: undefined
11737
11854
  */
@@ -12130,7 +12247,7 @@ export type CustomElements = {
12130
12247
  * Events that will be emitted by the component.
12131
12248
  *
12132
12249
  * - `qti-assessment-item-connected`: undefined
12133
- * - `qti-item-context-updated`: Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing.
12250
+ * - `qti-item-context-updated`: undefined
12134
12251
  *
12135
12252
  * ## Methods
12136
12253
  *
@@ -12138,7 +12255,12 @@ export type CustomElements = {
12138
12255
  *
12139
12256
  * - `showCorrectResponse(show: boolean) => void`: undefined
12140
12257
  * - `showCandidateCorrection(show: boolean) => void`: undefined
12141
- * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => boolean`: undefined
12258
+ * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => void`: Scores the attempt. The item does not score itself: its response processing does, like a
12259
+ * backend, and sends the outcomes back in `cito-item-set-outcomes`, which the item applies in one
12260
+ * update. The item keeps the attempt count (QTI info model §2.2.2: the delivery engine maintains
12261
+ * numAttempts) and hands the new count to the run, whose rules may read it. Without response
12262
+ * processing the item only counts the attempt. A run that throws still counts the attempt and applies
12263
+ * no outcomes.
12142
12264
  * - `resetResponses() => void`: undefined
12143
12265
  * - `getOutcome(identifier: string) => Readonly<OutcomeVariable>`: undefined
12144
12266
  * - `updateTemplateVariable(identifier: string, value: string | string[] | undefined) => void`: Updates the template variable with the specified identifier to the given value.
@@ -12414,22 +12536,6 @@ export type CustomElementsSolidJs = {
12414
12536
  BaseEvents
12415
12537
  >;
12416
12538
 
12417
- /**
12418
- *
12419
- *
12420
- * ## Methods
12421
- *
12422
- * Methods that can be called to access component functionality.
12423
- *
12424
- * - `process() => void`: undefined
12425
- */
12426
- "qti-response-processing": Partial<
12427
- QtiResponseProcessingProps &
12428
- QtiResponseProcessingSolidJsProps &
12429
- BaseProps<QtiResponseProcessing> &
12430
- BaseEvents
12431
- >;
12432
-
12433
12539
  /**
12434
12540
  *
12435
12541
  *
@@ -12457,13 +12563,18 @@ export type CustomElementsSolidJs = {
12457
12563
  * Events that will be emitted by the component.
12458
12564
  *
12459
12565
  * - `qti-assessment-item-connected`: undefined
12460
- * - `qti-item-context-updated`: Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing.
12566
+ * - `qti-item-context-updated`: undefined
12461
12567
  *
12462
12568
  * ## Methods
12463
12569
  *
12464
12570
  * Methods that can be called to access component functionality.
12465
12571
  *
12466
- * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => boolean`: undefined
12572
+ * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => void`: Scores the attempt. The item does not score itself: its response processing does, like a
12573
+ * backend, and sends the outcomes back in `cito-item-set-outcomes`, which the item applies in one
12574
+ * update. The item keeps the attempt count (QTI info model §2.2.2: the delivery engine maintains
12575
+ * numAttempts) and hands the new count to the run, whose rules may read it. Without response
12576
+ * processing the item only counts the attempt. A run that throws still counts the attempt and applies
12577
+ * no outcomes.
12467
12578
  * - `resetResponses() => void`: undefined
12468
12579
  * - `getOutcome(identifier: string) => Readonly<OutcomeVariable>`: undefined
12469
12580
  * - `updateTemplateVariable(identifier: string, value: string | string[] | undefined) => void`: Updates the template variable with the specified identifier to the given value.
@@ -12590,7 +12701,6 @@ export type CustomElementsSolidJs = {
12590
12701
  * Events that will be emitted by the component.
12591
12702
  *
12592
12703
  * - `qti-set-outcome-value`: undefined
12593
- * - `qti-interaction-response`: undefined
12594
12704
  *
12595
12705
  * ## Methods
12596
12706
  *
@@ -12765,6 +12875,28 @@ export type CustomElementsSolidJs = {
12765
12875
  BaseEvents
12766
12876
  >;
12767
12877
 
12878
+ /**
12879
+ * Response processing as the item's own backend: it reads the item context, runs its rules once and
12880
+ * sends the outcomes and the attempt count back in one `cito-item-set-outcomes`. The item applies
12881
+ * them; a host that scores elsewhere sends the same event instead.
12882
+ *
12883
+ * ## Methods
12884
+ *
12885
+ * Methods that can be called to access component functionality.
12886
+ *
12887
+ * - `processResponse({ numAttempts }: { numAttempts: number }) => void`: Scores the attempt on the copy: sets `numAttempts` to the count the item hands over, resets a
12888
+ * non-adaptive item's outcomes to their defaults (QTI info model §2.5), runs the rules and sends
12889
+ * every outcome and `numAttempts` in one `cito-item-set-outcomes`. The item applies them and publishes, which gives this element a
12890
+ * fresh copy. A rule that throws ends the run and the error propagates; nothing is sent, and the
12891
+ * run's writes stay in the copy until the item's next update.
12892
+ */
12893
+ "qti-response-processing": Partial<
12894
+ QtiResponseProcessingProps &
12895
+ QtiResponseProcessingSolidJsProps &
12896
+ BaseProps<QtiResponseProcessing> &
12897
+ BaseEvents
12898
+ >;
12899
+
12768
12900
  /**
12769
12901
  *
12770
12902
  *
@@ -13460,13 +13592,21 @@ export type CustomElementsSolidJs = {
13460
13592
  /**
13461
13593
  * A button that ends the current attempt.
13462
13594
  *
13595
+ * It follows its item: it cannot be pressed while the item is `disabled` or `readonly`, or once an
13596
+ * adaptive item is done. An adaptive item that sets `completionStatus` to `completed` closes its
13597
+ * session, so no further attempt can start (QTI info model §2.5).
13598
+ *
13463
13599
  * ## Attributes & Properties
13464
13600
  *
13465
13601
  * Component attributes and properties that can be applied to the element or by using JavaScript.
13466
13602
  *
13467
13603
  * - `response-identifier`/`responseIdentifier`: undefined
13468
13604
  * - `disabled`: undefined
13469
- * - `count-attempt`/`countAttempt`: Defines the number of attempts that a user can make using the 'endAttemptInteraction' mechanism (this can be used to limit the number of hints, etc.). [More information](https://www.imsglobal.org/sites/default/files/spec/qti/v3/info/index.html#DataCharacteristic_EndAttemptInteraction.Attr_count-attempt)
13605
+ * - `count-attempt`/`countAttempt`: Whether ending the attempt with this button counts as an attempt (`numAttempts` goes up), so it
13606
+ * uses up one of the item's `max-attempts`. Only `"false"` does not count: a hint button that
13607
+ * should not use up an attempt says so. QTI 3 gives the attribute no default; an absent value counts,
13608
+ * as QTI 2.x's default `true` did and as amp-up and QTI.JS do.
13609
+ * [More information](https://www.imsglobal.org/spec/qti/v3p0/info#Data_EndAttemptInteraction)
13470
13610
  * - `title`: undefined
13471
13611
  *
13472
13612
  * ## Events
@@ -13798,6 +13938,7 @@ export type CustomElementsSolidJs = {
13798
13938
  *
13799
13939
  * Component attributes and properties that can be applied to the element or by using JavaScript.
13800
13940
  *
13941
+ * - `maxAssociations`: QTI's default (information model §5.60). (property only)
13801
13942
  * - `autoSizeDropzones`: A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
13802
13943
  * `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
13803
13944
  * beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
@@ -14084,7 +14225,10 @@ export type CustomElementsSolidJs = {
14084
14225
  * manifest, the generated types and the Storybook controls — and so that changing it
14085
14226
  * re-renders, which reading `dataset` at render time never did.
14086
14227
  *
14087
- * Falls back to the item configuration's `inlineChoicePrompt`, then to `select`.
14228
+ * Falls back to the item configuration's `inlineChoicePrompt`, then to `select`. An empty
14229
+ * string is a value, not a missing one: `data-prompt=""` shows an empty placeholder.
14230
+ * - `data-clear-label`/`dataClearLabel`: Accessible name of the clear row: the prompt row when `data-prompt` is empty and a choice has
14231
+ * been made. It has no text to read, only an x glyph, so it needs a name. Defaults to `Clear`.
14088
14232
  * - `shuffle`/`undefined`: Requests option shuffling. Applied by the transform pipeline (`qti-transformers`), not by this element.
14089
14233
  * - `required`: Whether a choice must be selected for the response to be valid. QTI defaults this to
14090
14234
  * false, so an untouched dropdown is a valid empty response unless an author opts in.
@@ -14148,6 +14292,10 @@ export type CustomElementsSolidJs = {
14148
14292
  *
14149
14293
  * Methods that can be called to access component functionality.
14150
14294
  *
14295
+ * - `menuAutoSizeRows() => HTMLElement[]`: Leaves the prompt row out of the width measurement when the prompt is empty. That row is hidden
14296
+ * while nothing is chosen (measures 0) and a clear glyph once something is (measures a glyph), so
14297
+ * counting it would let the closed field change width on the first choice. Its text is empty
14298
+ * either way, so it has nothing to contribute.
14151
14299
  * - `shouldAutoSizeMenu() => boolean`: Autosizing is on unless a host turns it off (`configContext.inlineChoiceAutosize: false`), and an
14152
14300
  * explicit `qti-input-width-*` class always wins. On by default because without it the field sizes
14153
14301
  * to the option shown, so choosing a longer one widened the field and reflowed the sentence around
@@ -14156,7 +14304,8 @@ export type CustomElementsSolidJs = {
14156
14304
  * That second check has to live here rather than in CSS: the measurement is written as an inline
14157
14305
  * style on the trigger, and the width classes set the same property on `:host`, so the cascade
14158
14306
  * would hand it to the measurement every time. Not writing at all is what makes the class win.
14159
- * - `menuAutoSizeExtraWidth() => number`: The chevron sits in the trigger and not in the menu, so the menu never measures it.
14307
+ * - `menuAutoSizeExtraWidth() => number`: The chevron (and the gap before it) sits in the trigger and not in the menu, so the menu never
14308
+ * measures it.
14160
14309
  *
14161
14310
  * `offsetWidth`, NOT `getBoundingClientRect().width`: the icon rotates when the menu opens, and a
14162
14311
  * client rect reports the TRANSFORMED box — so a chevron caught mid-rotation measures wider than
@@ -14167,11 +14316,6 @@ export type CustomElementsSolidJs = {
14167
14316
  * - `reportValidity() => boolean`: undefined
14168
14317
  * - `reset() => void`: undefined
14169
14318
  * - `menuAutoSizePropertyTarget() => HTMLElement | null`: Where the measured width is written. Inside the shadow root — see the header.
14170
- * - `menuAutoSizeRows() => HTMLElement[]`: The menu's rows, which is what actually gets measured — one at a time.
14171
- *
14172
- * Flat tree, so a `<slot>` is replaced by the elements assigned to it: in the shipped control the
14173
- * prompt is rendered in the shadow root and the author's options are slotted light DOM, and both
14174
- * are rows of the same list.
14175
14319
  * - `withMenuMeasurable(measure: () => T) => T`: Make the rows measurable, run `measure`, and put everything back.
14176
14320
  *
14177
14321
  * A hook, because hosts hide their menu differently and a measurement needs layout. The default
@@ -14193,8 +14337,9 @@ export type CustomElementsSolidJs = {
14193
14337
  * - `value`: The currently displayed value inside the trigger.
14194
14338
  * - `dropdown-icon`: The chevron icon inside the trigger; also carries `dropdown-icon-open` when open.
14195
14339
  * - `menu`: The popover element containing the option list.
14196
- * - `option`: Each option button; also carries `option-prompt` and `option-selected` variants.
14340
+ * - `option`: Each option button; also carries `option-prompt`, `option-selected` and `option-clear` (the prompt row as a clear button, see `data-clear-label`) variants.
14197
14341
  * - `option-content`: The content wrapper inside each option.
14342
+ * - `clear-icon`: The x glyph inside the clear row.
14198
14343
  */
14199
14344
  "qti-inline-choice-interaction": Partial<
14200
14345
  QtiInlineChoiceInteractionProps &
@@ -14211,10 +14356,11 @@ export type CustomElementsSolidJs = {
14211
14356
  * Component attributes and properties that can be applied to the element or by using JavaScript.
14212
14357
  *
14213
14358
  * - `response-identifier`/`responseIdentifier`: Required. Identifier of the bound response variable.
14214
- * - `max-associations`/`maxAssociations`: Maximum pairings across the whole interaction; `0` means unlimited. QTI's own default is `1`; this element defaults to unlimited because a literal `1` breaks any multi-pair match item. See plans/interaction-attribute-spec-conformance.md.
14215
- * - `min-associations`/`minAssociations`: Minimum pairings for a valid response.
14359
+ * - `max-associations`/`maxAssociations`: Maximum pairings across the whole interaction; `0` means unlimited. Without the attribute it is QTI's default of 1 (information model §5.89).
14360
+ * - `min-associations`/`minAssociations`: Minimum pairings for a valid response (QTI's default).
14361
+ * - `data-first-column-header`/`dataFirstColumnHeader`: QTI shared vocabulary, with `qti-match-tabular`: the text of the table's top-left cell.
14216
14362
  * - `shuffle`/`undefined`: Requests shuffling of both match sets. Applied by the transform pipeline (`qti-transformers`), not by this element.
14217
- * - `class`: QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop; the `qti-choices-*` values position the source set.
14363
+ * - `class`: QTI shared presentation vocabulary. `qti-match-tabular` renders a checkbox/radio grid instead of drag-and-drop, and with it `qti-header-hidden` leaves out the column-header row; the `qti-choices-*` values position the source set.
14218
14364
  * - `auto-size-dropzones`/`undefined`: Extension, not QTI. Sizes every drop target to the widest chip so placement does not reflow the layout. The mixin default is `true`; this interaction is the one that overrides it to `false`, because a match target is a category card rather than a socket (see the field below and DROP-SIZING.md §1).
14219
14365
  * - `disable-animations`/`disableAnimations`: Extension, not QTI. Disables the FLIP move animation.
14220
14366
  * - `response`: undefined
@@ -14331,7 +14477,7 @@ export type CustomElementsSolidJs = {
14331
14477
  * Custom selectors for styling elements within the component.
14332
14478
  *
14333
14479
  * - `grid`: The tabular grid container.
14334
- * - `corner`: The top-left corner cell of the grid.
14480
+ * - `corner`: The top-left corner cell of the grid; shows `data-first-column-header`.
14335
14481
  * - `cols-wrap`: Wrapper row for the column headers.
14336
14482
  * - `c-header`: The column header slot wrapper.
14337
14483
  * - `rows-wrap`: Wrapper column for the row headers.
@@ -15467,13 +15613,34 @@ export type CustomElementsSolidJs = {
15467
15613
  >;
15468
15614
 
15469
15615
  /**
15616
+ * A button that ends the attempt of an item: its response is processed, `numAttempts` goes up and
15617
+ * feedback is shown as the item's session control allows. It dispatches `cito-test-end-attempt`,
15618
+ * which `<test-navigation>` handles.
15619
+ *
15620
+ * Put it inside `<test-navigation>`, either in the toolbar, where it ends the attempt of the item on
15621
+ * screen, or in the `<template item-ref>`, where each item gets its own and it ends the attempt of
15622
+ * that item: with `<qti-test navigate="section">` every item of the section is on screen, each with
15623
+ * its own button. Give it an `item` (an item-ref identifier) to end the attempt of that item instead,
15624
+ * wherever the button sits.
15470
15625
  *
15626
+ * It is `disabled` by the state of its item: when the attempts allowed by `max-attempts` are used
15627
+ * (non-adaptive items), when the last attempt was already optimal (non-adaptive items), when an
15628
+ * adaptive item is completed, or, when skipping is not allowed, while the response is invalid or
15629
+ * still the default.
15471
15630
  *
15472
15631
  * ## Attributes & Properties
15473
15632
  *
15474
15633
  * Component attributes and properties that can be applied to the element or by using JavaScript.
15475
15634
  *
15476
- * - `disabled`/`_internalDisabled`: undefined
15635
+ * - `require-answer`/`requireAnswer`: Ends no attempt until the response is valid and not the default, whatever the item's `allow-skipping` says.
15636
+ * - `item`: The item-ref identifier whose attempt this button ends; without it, the item it is stamped into, or else the one on screen.
15637
+ * - `disabled`/`_internalDisabled`: Reflected: the item's attempt cannot be ended.
15638
+ *
15639
+ * ## Slots
15640
+ *
15641
+ * Areas where markup can be added to the component.
15642
+ *
15643
+ * - `(default)`: The label.
15477
15644
  *
15478
15645
  * ## Methods
15479
15646
  *
@@ -17481,7 +17648,8 @@ export type CustomElementsSolidJs = {
17481
17648
  *
17482
17649
  * Methods that can be called to access component functionality.
17483
17650
  *
17484
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
17651
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
17652
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
17485
17653
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
17486
17654
  * - `process() => void`: undefined
17487
17655
  */
@@ -17499,7 +17667,8 @@ export type CustomElementsSolidJs = {
17499
17667
  *
17500
17668
  * Methods that can be called to access component functionality.
17501
17669
  *
17502
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
17670
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
17671
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
17503
17672
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
17504
17673
  * - `process() => void`: undefined
17505
17674
  */
@@ -17794,7 +17963,8 @@ export type CustomElementsSolidJs = {
17794
17963
  *
17795
17964
  * Methods that can be called to access component functionality.
17796
17965
  *
17797
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
17966
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
17967
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
17798
17968
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
17799
17969
  * - `process() => void`: undefined
17800
17970
  */
@@ -17812,7 +17982,8 @@ export type CustomElementsSolidJs = {
17812
17982
  *
17813
17983
  * Methods that can be called to access component functionality.
17814
17984
  *
17815
- * - `shouldProcess() => boolean`: Whether this branch's sub-rules should be processed.
17985
+ * - `shouldProcess() => boolean`: Variables and base values hold a boolean as the string `'true'` or `'false'`, and `'false'` is
17986
+ * truthy, so the condition applies only to `true` itself; `false` and NULL do not.
17816
17987
  * - `getSubRules() => QtiRule[]`: The sub-rules to process when this branch applies.
17817
17988
  * - `process() => void`: undefined
17818
17989
  */
@@ -18254,7 +18425,7 @@ export type CustomElementsSolidJs = {
18254
18425
  * Events that will be emitted by the component.
18255
18426
  *
18256
18427
  * - `qti-assessment-item-connected`: undefined
18257
- * - `qti-item-context-updated`: Emitted when through a user action the itemContext is updated, typically on interaction with the interactions, or calling response processing.
18428
+ * - `qti-item-context-updated`: undefined
18258
18429
  *
18259
18430
  * ## Methods
18260
18431
  *
@@ -18262,7 +18433,12 @@ export type CustomElementsSolidJs = {
18262
18433
  *
18263
18434
  * - `showCorrectResponse(show: boolean) => void`: undefined
18264
18435
  * - `showCandidateCorrection(show: boolean) => void`: undefined
18265
- * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => boolean`: undefined
18436
+ * - `processResponse(countNumAttempts = true, reportValidityAfterScoring = true) => void`: Scores the attempt. The item does not score itself: its response processing does, like a
18437
+ * backend, and sends the outcomes back in `cito-item-set-outcomes`, which the item applies in one
18438
+ * update. The item keeps the attempt count (QTI info model §2.2.2: the delivery engine maintains
18439
+ * numAttempts) and hands the new count to the run, whose rules may read it. Without response
18440
+ * processing the item only counts the attempt. A run that throws still counts the attempt and applies
18441
+ * no outcomes.
18266
18442
  * - `resetResponses() => void`: undefined
18267
18443
  * - `getOutcome(identifier: string) => Readonly<OutcomeVariable>`: undefined
18268
18444
  * - `updateTemplateVariable(identifier: string, value: string | string[] | undefined) => void`: Updates the template variable with the specified identifier to the given value.