@citolab/qti-components 9.5.0 → 9.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cdn/index.global.js +1 -1
- package/cdn/index.js +1761 -204
- package/dist/base.d.ts +10 -10
- package/dist/base.js +7 -1
- package/dist/{chunk-SIE3E4FG.js → chunk-EAQOUBXA.js} +4 -4
- package/dist/{chunk-GBZNFSFY.js → chunk-H72OXVRF.js} +2 -2
- package/dist/{chunk-RU6332MD.js → chunk-I7ACMH74.js} +3 -3
- package/dist/{chunk-DAFB2E5H.js → chunk-LOKULHVY.js} +386 -241
- package/dist/chunk-LOKULHVY.js.map +1 -0
- package/dist/{chunk-MI7774NV.js → chunk-QOFGUIYE.js} +2 -2
- package/dist/{chunk-TDWJ6WZA.js → chunk-QUTM5TT6.js} +37 -1
- package/dist/chunk-QUTM5TT6.js.map +1 -0
- package/dist/chunk-QVZLJY75.js +7 -0
- package/dist/chunk-QVZLJY75.js.map +1 -0
- package/dist/{chunk-FD4AB6TM.js → chunk-RV7ADJ33.js} +2 -2
- package/dist/{chunk-OQDBARD5.js → chunk-TBJT7AGB.js} +2 -2
- package/dist/{chunk-SU63QGGD.js → chunk-TC4257SG.js} +6 -6
- package/dist/{chunk-6U3YPHXU.js → chunk-TFQAUWCM.js} +40 -5
- package/dist/{chunk-6U3YPHXU.js.map → chunk-TFQAUWCM.js.map} +1 -1
- package/dist/{chunk-6K3QWJHH.js → chunk-V3NKEAQY.js} +40 -4
- package/dist/chunk-V3NKEAQY.js.map +1 -0
- package/dist/{chunk-YZRODVYZ.js → chunk-YS6CBO45.js} +2 -2
- package/dist/{computed.types.d-gJrBeUMG.d.ts → computed.types.d-SsTm3ieP.d.ts} +1 -1
- package/dist/corrections.d.ts +9 -9
- package/dist/corrections.js +8 -8
- package/dist/elements.d.ts +2 -2
- package/dist/elements.js +3 -3
- package/dist/index.d.ts +10 -10
- package/dist/index.js +23 -13
- package/dist/interactions.d.ts +4 -4
- package/dist/interactions.js +7 -3
- package/dist/item.css +2 -1
- package/dist/item.d.ts +4 -4
- package/dist/item.js +4 -4
- package/dist/{item.types.d-B55QkJ92.d.ts → item.types.d-DuVR0ZVK.d.ts} +7 -1
- package/dist/loader.d.ts +2 -2
- package/dist/processing.d.ts +10 -3
- package/dist/processing.js +3 -3
- package/dist/qti-components-jsx.d.ts +46 -26
- package/dist/{qti-condition-expression.d-VJH6cWxf.d.ts → qti-condition-expression.d-B-T1NNl0.d.ts} +1 -1
- package/dist/{qti-expression.d-BPxEp8HU.d.ts → qti-expression.d-B-Cfbqlb.d.ts} +1 -1
- package/dist/{qti-feedback.d-wMYNVkkj.d.ts → qti-feedback.d-DbzPSJuK.d.ts} +1 -1
- package/dist/{qti-item.d-DgC1AQbY.d.ts → qti-item.d-DjWvKbfL.d.ts} +1 -1
- package/dist/{qti-test.d-86TlaMlI.d.ts → qti-test.d-DOWT6YNa.d.ts} +4 -4
- package/dist/{qti-text-entry-interaction.d-C4eixT-D.d.ts → qti-text-entry-interaction.d-h5UZ8Qvp.d.ts} +28 -18
- package/dist/{interaction.d-g6XG0T0Z.d.ts → record.d-wB9uYs-j.d.ts} +34 -2
- package/dist/{session.context.d-D5080LVx.d.ts → session.context.d-Cw8GcziG.d.ts} +1 -1
- package/dist/test.d.ts +7 -7
- package/dist/test.js +5 -5
- package/package.json +5 -5
- package/dist/chunk-6K3QWJHH.js.map +0 -1
- package/dist/chunk-DAFB2E5H.js.map +0 -1
- package/dist/chunk-TDWJ6WZA.js.map +0 -1
- package/dist/chunk-ZP6QQYSU.js +0 -7
- package/dist/chunk-ZP6QQYSU.js.map +0 -1
- /package/dist/{chunk-SIE3E4FG.js.map → chunk-EAQOUBXA.js.map} +0 -0
- /package/dist/{chunk-GBZNFSFY.js.map → chunk-H72OXVRF.js.map} +0 -0
- /package/dist/{chunk-RU6332MD.js.map → chunk-I7ACMH74.js.map} +0 -0
- /package/dist/{chunk-MI7774NV.js.map → chunk-QOFGUIYE.js.map} +0 -0
- /package/dist/{chunk-FD4AB6TM.js.map → chunk-RV7ADJ33.js.map} +0 -0
- /package/dist/{chunk-OQDBARD5.js.map → chunk-TBJT7AGB.js.map} +0 -0
- /package/dist/{chunk-SU63QGGD.js.map → chunk-TC4257SG.js.map} +0 -0
- /package/dist/{chunk-YZRODVYZ.js.map → chunk-YS6CBO45.js.map} +0 -0
|
@@ -61,6 +61,8 @@ import type {
|
|
|
61
61
|
QtiMediaInteraction,
|
|
62
62
|
QtiOrderInteraction,
|
|
63
63
|
QtiPortableCustomInteraction,
|
|
64
|
+
inlineScriptText,
|
|
65
|
+
inlineStyleText,
|
|
64
66
|
QtiPortableCustomInteractionTest,
|
|
65
67
|
QtiPositionObjectInteraction,
|
|
66
68
|
QtiPositionObjectStage,
|
|
@@ -2165,6 +2167,14 @@ casts, rather than pretending at an encapsulation the type system was the only t
|
|
|
2165
2167
|
};
|
|
2166
2168
|
|
|
2167
2169
|
export type QtiGraphicGapMatchInteractionProps = {
|
|
2170
|
+
/** A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
|
|
2171
|
+
`--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
|
|
2172
|
+
beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
|
|
2173
|
+
declared width: a 275px chip kept a 17% hotspot at 275px over a 482px map. Chips are sized to
|
|
2174
|
+
their hotspots through `--qti-graphic-scale` instead. */
|
|
2175
|
+
autoSizeDropzones?:
|
|
2176
|
+
| QtiGraphicGapMatchInteraction["autoSizeDropzones"]
|
|
2177
|
+
| undefined;
|
|
2168
2178
|
/** */
|
|
2169
2179
|
allowReorder?: QtiGraphicGapMatchInteraction["allowReorder"] | undefined;
|
|
2170
2180
|
/** */
|
|
@@ -2178,6 +2188,14 @@ export type QtiGraphicGapMatchInteractionProps = {
|
|
|
2178
2188
|
};
|
|
2179
2189
|
|
|
2180
2190
|
export type QtiGraphicGapMatchInteractionSolidJsProps = {
|
|
2191
|
+
/** A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
|
|
2192
|
+
`--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
|
|
2193
|
+
beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
|
|
2194
|
+
declared width: a 275px chip kept a 17% hotspot at 275px over a 482px map. Chips are sized to
|
|
2195
|
+
their hotspots through `--qti-graphic-scale` instead. */
|
|
2196
|
+
"prop:autoSizeDropzones"?:
|
|
2197
|
+
| QtiGraphicGapMatchInteraction["autoSizeDropzones"]
|
|
2198
|
+
| undefined;
|
|
2181
2199
|
/** */
|
|
2182
2200
|
"prop:allowReorder"?:
|
|
2183
2201
|
| QtiGraphicGapMatchInteraction["allowReorder"]
|
|
@@ -3147,11 +3165,11 @@ export type QtiPortableCustomInteractionProps = {
|
|
|
3147
3165
|
| undefined;
|
|
3148
3166
|
/** */
|
|
3149
3167
|
requireShimJson?: QtiPortableCustomInteraction["requireShimJson"] | undefined;
|
|
3150
|
-
/**
|
|
3168
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3151
3169
|
"data-require-js-url"?:
|
|
3152
3170
|
| QtiPortableCustomInteraction["requireJsUrl"]
|
|
3153
3171
|
| undefined;
|
|
3154
|
-
/**
|
|
3172
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3155
3173
|
requireJsUrl?: QtiPortableCustomInteraction["requireJsUrl"] | undefined;
|
|
3156
3174
|
/** */
|
|
3157
3175
|
"data-base-url"?: QtiPortableCustomInteraction["baseUrl"] | undefined;
|
|
@@ -3256,11 +3274,11 @@ export type QtiPortableCustomInteractionSolidJsProps = {
|
|
|
3256
3274
|
"prop:requireShimJson"?:
|
|
3257
3275
|
| QtiPortableCustomInteraction["requireShimJson"]
|
|
3258
3276
|
| undefined;
|
|
3259
|
-
/**
|
|
3277
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3260
3278
|
"attr:data-require-js-url"?:
|
|
3261
3279
|
| QtiPortableCustomInteraction["requireJsUrl"]
|
|
3262
3280
|
| undefined;
|
|
3263
|
-
/**
|
|
3281
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3264
3282
|
"prop:requireJsUrl"?:
|
|
3265
3283
|
| QtiPortableCustomInteraction["requireJsUrl"]
|
|
3266
3284
|
| undefined;
|
|
@@ -3375,11 +3393,11 @@ export type QtiPortableCustomInteractionTestProps = {
|
|
|
3375
3393
|
requireShimJson?:
|
|
3376
3394
|
| QtiPortableCustomInteractionTest["requireShimJson"]
|
|
3377
3395
|
| undefined;
|
|
3378
|
-
/**
|
|
3396
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3379
3397
|
"data-require-js-url"?:
|
|
3380
3398
|
| QtiPortableCustomInteractionTest["requireJsUrl"]
|
|
3381
3399
|
| undefined;
|
|
3382
|
-
/**
|
|
3400
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3383
3401
|
requireJsUrl?: QtiPortableCustomInteractionTest["requireJsUrl"] | undefined;
|
|
3384
3402
|
/** */
|
|
3385
3403
|
"data-base-url"?: QtiPortableCustomInteractionTest["baseUrl"] | undefined;
|
|
@@ -3486,11 +3504,11 @@ export type QtiPortableCustomInteractionTestSolidJsProps = {
|
|
|
3486
3504
|
"prop:requireShimJson"?:
|
|
3487
3505
|
| QtiPortableCustomInteractionTest["requireShimJson"]
|
|
3488
3506
|
| undefined;
|
|
3489
|
-
/**
|
|
3507
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3490
3508
|
"attr:data-require-js-url"?:
|
|
3491
3509
|
| QtiPortableCustomInteractionTest["requireJsUrl"]
|
|
3492
3510
|
| undefined;
|
|
3493
|
-
/**
|
|
3511
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
3494
3512
|
"prop:requireJsUrl"?:
|
|
3495
3513
|
| QtiPortableCustomInteractionTest["requireJsUrl"]
|
|
3496
3514
|
| undefined;
|
|
@@ -7968,6 +7986,11 @@ export type CustomElements = {
|
|
|
7968
7986
|
*
|
|
7969
7987
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
7970
7988
|
*
|
|
7989
|
+
* - `autoSizeDropzones`: A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
|
|
7990
|
+
* `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
|
|
7991
|
+
* beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
|
|
7992
|
+
* declared width: a 275px chip kept a 17% hotspot at 275px over a 482px map. Chips are sized to
|
|
7993
|
+
* their hotspots through `--qti-graphic-scale` instead. (property only)
|
|
7971
7994
|
* - `allowReorder`: undefined (property only)
|
|
7972
7995
|
* - `sortablePlaceholderConfig`: undefined (property only)
|
|
7973
7996
|
* - `sortableAnimationConfig`: undefined (property only)
|
|
@@ -8632,7 +8655,7 @@ export type CustomElements = {
|
|
|
8632
8655
|
* - `custom-interaction-type-identifier`/`customInteractionTypeIdentifier`: undefined
|
|
8633
8656
|
* - `data-require-paths`/`requirePathsJson`: undefined
|
|
8634
8657
|
* - `data-require-shim`/`requireShimJson`: undefined
|
|
8635
|
-
* - `data-require-js-url`/`requireJsUrl`:
|
|
8658
|
+
* - `data-require-js-url`/`requireJsUrl`: A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts).
|
|
8636
8659
|
* - `data-base-url`/`baseUrl`: undefined
|
|
8637
8660
|
* - `data-use-default-paths`/`useDefaultPaths`: undefined
|
|
8638
8661
|
* - `data-status`/`status`: Item lifecycle status handed to the PCI in its `getInstance` configuration.
|
|
@@ -8715,7 +8738,7 @@ export type CustomElements = {
|
|
|
8715
8738
|
* - `custom-interaction-type-identifier`/`customInteractionTypeIdentifier`: undefined
|
|
8716
8739
|
* - `data-require-paths`/`requirePathsJson`: undefined
|
|
8717
8740
|
* - `data-require-shim`/`requireShimJson`: undefined
|
|
8718
|
-
* - `data-require-js-url`/`requireJsUrl`:
|
|
8741
|
+
* - `data-require-js-url`/`requireJsUrl`: A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts).
|
|
8719
8742
|
* - `data-base-url`/`baseUrl`: undefined
|
|
8720
8743
|
* - `data-use-default-paths`/`useDefaultPaths`: undefined
|
|
8721
8744
|
* - `data-status`/`status`: Item lifecycle status handed to the PCI in its `getInstance` configuration.
|
|
@@ -10484,6 +10507,9 @@ export type CustomElements = {
|
|
|
10484
10507
|
*
|
|
10485
10508
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
10486
10509
|
*
|
|
10510
|
+
* - `resultBaseType`: The base type of the field last read: as declared on the record's correct response when it
|
|
10511
|
+
* is, otherwise read off the value. The value alone is a string like `"4.1"` or `"455 250"`, and
|
|
10512
|
+
* an operator reading it as text would refuse to compare it as a number or test it as a point. (property only) (readonly)
|
|
10487
10513
|
* - `lastResult`: What the last `calculate()` produced, or undefined if it has not run.
|
|
10488
10514
|
*
|
|
10489
10515
|
* This is the supported way to inspect a scoring run: process the responses,
|
|
@@ -10491,13 +10517,6 @@ export type CustomElements = {
|
|
|
10491
10517
|
* to visualise how a score came about gets the whole tree annotated with its
|
|
10492
10518
|
* values, without the components having to re-render to show them. (property only) (readonly)
|
|
10493
10519
|
* - `lastVariables`: undefined (property only) (readonly)
|
|
10494
|
-
* - `resultBaseType`: The base type this operator always produces, when the QTI vocabulary fixes
|
|
10495
|
-
* one regardless of its operands — `qti-divide` is a float even dividing two
|
|
10496
|
-
* integers exactly, and `qti-round` is an integer whatever it rounds.
|
|
10497
|
-
*
|
|
10498
|
-
* Left undefined by operators whose result type follows their operands (a
|
|
10499
|
-
* `qti-sum` of integers is an integer) and by those that return no number at
|
|
10500
|
-
* all; the type is then read off the value. (property only) (readonly)
|
|
10501
10520
|
* - `getVariables`: undefined (property only)
|
|
10502
10521
|
*
|
|
10503
10522
|
* ## Methods
|
|
@@ -13705,6 +13724,11 @@ export type CustomElementsSolidJs = {
|
|
|
13705
13724
|
*
|
|
13706
13725
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
13707
13726
|
*
|
|
13727
|
+
* - `autoSizeDropzones`: A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
|
|
13728
|
+
* `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
|
|
13729
|
+
* beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
|
|
13730
|
+
* declared width: a 275px chip kept a 17% hotspot at 275px over a 482px map. Chips are sized to
|
|
13731
|
+
* their hotspots through `--qti-graphic-scale` instead. (property only)
|
|
13708
13732
|
* - `allowReorder`: undefined (property only)
|
|
13709
13733
|
* - `sortablePlaceholderConfig`: undefined (property only)
|
|
13710
13734
|
* - `sortableAnimationConfig`: undefined (property only)
|
|
@@ -14387,7 +14411,7 @@ export type CustomElementsSolidJs = {
|
|
|
14387
14411
|
* - `custom-interaction-type-identifier`/`customInteractionTypeIdentifier`: undefined
|
|
14388
14412
|
* - `data-require-paths`/`requirePathsJson`: undefined
|
|
14389
14413
|
* - `data-require-shim`/`requireShimJson`: undefined
|
|
14390
|
-
* - `data-require-js-url`/`requireJsUrl`:
|
|
14414
|
+
* - `data-require-js-url`/`requireJsUrl`: A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts).
|
|
14391
14415
|
* - `data-base-url`/`baseUrl`: undefined
|
|
14392
14416
|
* - `data-use-default-paths`/`useDefaultPaths`: undefined
|
|
14393
14417
|
* - `data-status`/`status`: Item lifecycle status handed to the PCI in its `getInstance` configuration.
|
|
@@ -14471,7 +14495,7 @@ export type CustomElementsSolidJs = {
|
|
|
14471
14495
|
* - `custom-interaction-type-identifier`/`customInteractionTypeIdentifier`: undefined
|
|
14472
14496
|
* - `data-require-paths`/`requirePathsJson`: undefined
|
|
14473
14497
|
* - `data-require-shim`/`requireShimJson`: undefined
|
|
14474
|
-
* - `data-require-js-url`/`requireJsUrl`:
|
|
14498
|
+
* - `data-require-js-url`/`requireJsUrl`: A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts).
|
|
14475
14499
|
* - `data-base-url`/`baseUrl`: undefined
|
|
14476
14500
|
* - `data-use-default-paths`/`useDefaultPaths`: undefined
|
|
14477
14501
|
* - `data-status`/`status`: Item lifecycle status handed to the PCI in its `getInstance` configuration.
|
|
@@ -16406,6 +16430,9 @@ export type CustomElementsSolidJs = {
|
|
|
16406
16430
|
*
|
|
16407
16431
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
16408
16432
|
*
|
|
16433
|
+
* - `resultBaseType`: The base type of the field last read: as declared on the record's correct response when it
|
|
16434
|
+
* is, otherwise read off the value. The value alone is a string like `"4.1"` or `"455 250"`, and
|
|
16435
|
+
* an operator reading it as text would refuse to compare it as a number or test it as a point. (property only) (readonly)
|
|
16409
16436
|
* - `lastResult`: What the last `calculate()` produced, or undefined if it has not run.
|
|
16410
16437
|
*
|
|
16411
16438
|
* This is the supported way to inspect a scoring run: process the responses,
|
|
@@ -16413,13 +16440,6 @@ export type CustomElementsSolidJs = {
|
|
|
16413
16440
|
* to visualise how a score came about gets the whole tree annotated with its
|
|
16414
16441
|
* values, without the components having to re-render to show them. (property only) (readonly)
|
|
16415
16442
|
* - `lastVariables`: undefined (property only) (readonly)
|
|
16416
|
-
* - `resultBaseType`: The base type this operator always produces, when the QTI vocabulary fixes
|
|
16417
|
-
* one regardless of its operands — `qti-divide` is a float even dividing two
|
|
16418
|
-
* integers exactly, and `qti-round` is an integer whatever it rounds.
|
|
16419
|
-
*
|
|
16420
|
-
* Left undefined by operators whose result type follows their operands (a
|
|
16421
|
-
* `qti-sum` of integers is an integer) and by those that return no number at
|
|
16422
|
-
* all; the type is then read off the value. (property only) (readonly)
|
|
16423
16443
|
* - `getVariables`: undefined (property only)
|
|
16424
16444
|
*
|
|
16425
16445
|
* ## Methods
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as lit from 'lit';
|
|
2
2
|
import { LitElement } from 'lit';
|
|
3
|
-
import { b as ItemContext, V as VariableDeclaration, g as ResponseVariable, B as BaseType } from './item.types.d-
|
|
3
|
+
import { b as ItemContext, V as VariableDeclaration, g as ResponseVariable, B as BaseType } from './item.types.d-DuVR0ZVK.js';
|
|
4
4
|
import { a as QtiContextType, Q as QtiContext } from './qti.context.d-CejJMlfZ.js';
|
|
5
5
|
|
|
6
6
|
interface TestContext {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as lit from 'lit';
|
|
2
2
|
import { LitElement } from 'lit';
|
|
3
|
-
import { a as Cardinality } from './item.types.d-
|
|
3
|
+
import { a as Cardinality } from './item.types.d-DuVR0ZVK.js';
|
|
4
4
|
|
|
5
5
|
declare abstract class QtiVariableDeclaration extends LitElement {
|
|
6
6
|
render(): lit.TemplateResult<1>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as lit from 'lit';
|
|
2
2
|
import { LitElement } from 'lit';
|
|
3
3
|
import { Q as QtiContext } from './qti.context.d-CejJMlfZ.js';
|
|
4
|
-
import { C as ComputedItemContext, V as View } from './session.context.d-
|
|
4
|
+
import { C as ComputedItemContext, V as View } from './session.context.d-Cw8GcziG.js';
|
|
5
5
|
import { C as ConfigContext } from './config.context.d-BvU9r-Mg.js';
|
|
6
6
|
import { QtiAssessmentItem } from './elements.js';
|
|
7
7
|
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import * as lit from 'lit';
|
|
2
2
|
import { LitElement, PropertyValues, nothing } from 'lit';
|
|
3
3
|
import { b as transformTestApi, t as transformItemApi } from './qti-transform-test.d-BL7GGFJj.js';
|
|
4
|
-
import { C as ComputedContext, a as ComputedItem } from './computed.types.d-
|
|
4
|
+
import { C as ComputedContext, a as ComputedItem } from './computed.types.d-SsTm3ieP.js';
|
|
5
5
|
import { QtiAssessmentItem, QtiModalFeedback } from './elements.js';
|
|
6
6
|
import { Q as QtiContext } from './qti.context.d-CejJMlfZ.js';
|
|
7
|
-
import { T as TestContext, Q as QtiExpression, a as QtiExpressionBase } from './qti-expression.d-
|
|
7
|
+
import { T as TestContext, Q as QtiExpression, a as QtiExpressionBase } from './qti-expression.d-B-Cfbqlb.js';
|
|
8
8
|
import { TemplateFunction } from '@heximal/templates';
|
|
9
|
-
import { h as VariableValue, b as ItemContext, c as OutcomeVariable, V as VariableDeclaration } from './item.types.d-
|
|
10
|
-
import { S as SessionContext, V as View } from './session.context.d-
|
|
9
|
+
import { h as VariableValue, b as ItemContext, c as OutcomeVariable, V as VariableDeclaration } from './item.types.d-DuVR0ZVK.js';
|
|
10
|
+
import { S as SessionContext, V as View } from './session.context.d-Cw8GcziG.js';
|
|
11
11
|
import { C as ConfigContext } from './config.context.d-BvU9r-Mg.js';
|
|
12
12
|
import { b as QtiRuleBase } from './qti-rule-base.d-Bdzg8eGH.js';
|
|
13
13
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as lit from 'lit';
|
|
2
2
|
import { LitElement, CSSResultGroup, PropertyValues } from 'lit';
|
|
3
|
-
import { I as Interaction } from './
|
|
3
|
+
import { I as Interaction, b as RecordValue } from './record.d-wB9uYs-j.js';
|
|
4
4
|
import { V as ValidatableInteraction } from './interaction.interface.d-CvjHM2bi.js';
|
|
5
5
|
import { C as ConfigContext } from './config.context.d-BvU9r-Mg.js';
|
|
6
|
-
import { B as BaseType, a as Cardinality, b as ItemContext, Q as QtiAreaMapEntry } from './item.types.d-
|
|
6
|
+
import { B as BaseType, a as Cardinality, b as ItemContext, Q as QtiAreaMapEntry } from './item.types.d-DuVR0ZVK.js';
|
|
7
7
|
import { Q as QtiContext } from './qti.context.d-CejJMlfZ.js';
|
|
8
8
|
import * as lit_directives_ref_js from 'lit/directives/ref.js';
|
|
9
9
|
|
|
@@ -750,6 +750,20 @@ declare const QtiGraphicGapMatchInteraction_base: (abstract new (...args: any[])
|
|
|
750
750
|
declare class QtiGraphicGapMatchInteraction extends QtiGraphicGapMatchInteraction_base {
|
|
751
751
|
#private;
|
|
752
752
|
static styles: CSSResultGroup;
|
|
753
|
+
/**
|
|
754
|
+
* A hotspot's box is its authored `coords`, always (CONFIGURABILITY.md §4). The measured
|
|
755
|
+
* `--qti-dropzone-min-*` reservation is a floor on the hotspot's `min-width`/`min-height`, and it
|
|
756
|
+
* beat the percentage box from `positionShapes` as soon as the graphic rendered narrower than its
|
|
757
|
+
* declared width: a 275px chip kept a 17% hotspot at 275px over a 482px map. Chips are sized to
|
|
758
|
+
* their hotspots through `--qti-graphic-scale` instead.
|
|
759
|
+
*/
|
|
760
|
+
autoSizeDropzones: boolean;
|
|
761
|
+
/**
|
|
762
|
+
* Rendered width of the graphic over its declared width: the factor the drop areas are scaled by.
|
|
763
|
+
* Published as `--qti-graphic-scale` on both slots, so it reaches a chip in the bank and one placed
|
|
764
|
+
* in a hotspot (qti-gap-img.styles.ts), without writing to the light-DOM host.
|
|
765
|
+
*/
|
|
766
|
+
private _graphicScale;
|
|
753
767
|
render(): lit.TemplateResult<1>;
|
|
754
768
|
shouldReturnToInventoryOnInventoryDrop(): boolean;
|
|
755
769
|
connectedCallback(): void;
|
|
@@ -1107,10 +1121,11 @@ type PciInteractionStatus = 'interacting' | 'suspended' | 'closed' | 'solution'
|
|
|
1107
1121
|
* Correct response of a response declaration, mirroring `qti-correct-response`.
|
|
1108
1122
|
*
|
|
1109
1123
|
* `value` holds the authored `qti-value` content: a single value for `single`
|
|
1110
|
-
* cardinality,
|
|
1124
|
+
* cardinality, a field map (`{ time: '4.0', point: '460 245' }`) for `record`
|
|
1125
|
+
* cardinality, and an array of values for every other cardinality.
|
|
1111
1126
|
*/
|
|
1112
1127
|
interface PciCorrectResponse {
|
|
1113
|
-
value: string | string[]
|
|
1128
|
+
value: string | string[] | Record<string, string | string[] | null>;
|
|
1114
1129
|
}
|
|
1115
1130
|
/**
|
|
1116
1131
|
* Response declaration passed into the `getInstance` configuration so a PCI can
|
|
@@ -1203,6 +1218,12 @@ declare type QtiVariableJSON = {
|
|
|
1203
1218
|
record?: QtiRecordItem[] | null;
|
|
1204
1219
|
};
|
|
1205
1220
|
|
|
1221
|
+
/** Text for an inline `<script>`: a `</script` inside it would end the element early. */
|
|
1222
|
+
declare const inlineScriptText: (text: string) => string;
|
|
1223
|
+
/** Text for an inline `<style>`: a `</style` inside it would end the element early. */
|
|
1224
|
+
declare const inlineStyleText: (text: string) => string;
|
|
1225
|
+
/** A response value as this interaction holds it: a record response is its field map. */
|
|
1226
|
+
type PciResponseValue = string | string[] | RecordValue;
|
|
1206
1227
|
declare class QtiPortableCustomInteraction extends Interaction {
|
|
1207
1228
|
#private;
|
|
1208
1229
|
protected _iframeLoaded: boolean;
|
|
@@ -1218,6 +1239,7 @@ declare class QtiPortableCustomInteraction extends Interaction {
|
|
|
1218
1239
|
customInteractionTypeIdentifier: string;
|
|
1219
1240
|
requirePathsJson: string;
|
|
1220
1241
|
requireShimJson: string;
|
|
1242
|
+
/** A RequireJS to load in the iframe instead of the inlined copy (src/vendor/require-js.ts). */
|
|
1221
1243
|
requireJsUrl: string;
|
|
1222
1244
|
baseUrl: string;
|
|
1223
1245
|
useDefaultPaths: boolean;
|
|
@@ -1245,10 +1267,6 @@ declare class QtiPortableCustomInteraction extends Interaction {
|
|
|
1245
1267
|
* Get direct child elements by tag name
|
|
1246
1268
|
*/
|
|
1247
1269
|
private getDirectChildrenByTag;
|
|
1248
|
-
/**
|
|
1249
|
-
* Coerce a scalar value to the expected base-type when possible
|
|
1250
|
-
*/
|
|
1251
|
-
private coerceBaseValue;
|
|
1252
1270
|
/**
|
|
1253
1271
|
* Normalize an input into a list form
|
|
1254
1272
|
*/
|
|
@@ -1257,14 +1275,6 @@ declare class QtiPortableCustomInteraction extends Interaction {
|
|
|
1257
1275
|
* Convert a variable value to QtiVariableJSON
|
|
1258
1276
|
*/
|
|
1259
1277
|
private variableToQtiVariableJSON;
|
|
1260
|
-
/**
|
|
1261
|
-
* Convert a record object into QtiVariableJSON
|
|
1262
|
-
*/
|
|
1263
|
-
private recordToQtiVariableJSON;
|
|
1264
|
-
/**
|
|
1265
|
-
* Build a record entry from an arbitrary value
|
|
1266
|
-
*/
|
|
1267
|
-
private recordEntryFromValue;
|
|
1268
1278
|
/**
|
|
1269
1279
|
* Extract default QTI_CONTEXT values from qti-context-declaration elements
|
|
1270
1280
|
*/
|
|
@@ -1284,7 +1294,7 @@ declare class QtiPortableCustomInteraction extends Interaction {
|
|
|
1284
1294
|
/**
|
|
1285
1295
|
* Converts response variables to QtiVariableJSON
|
|
1286
1296
|
*/
|
|
1287
|
-
protected responseVariablesToQtiVariableJSON(input:
|
|
1297
|
+
protected responseVariablesToQtiVariableJSON(input: PciResponseValue, cardinality: Cardinality, baseType: BaseType, fieldBaseTypes?: Record<string, BaseType>): QtiVariableJSON;
|
|
1288
1298
|
validate(): boolean;
|
|
1289
1299
|
set value(v: string | null);
|
|
1290
1300
|
get value(): string | null;
|
|
@@ -1570,4 +1580,4 @@ declare global {
|
|
|
1570
1580
|
}
|
|
1571
1581
|
}
|
|
1572
1582
|
|
|
1573
|
-
export { type Choice as C, type Orientation as O, QtiAssociableHotspot as Q, QtiAssociateInteraction as a, QtiChoiceInteraction as b, QtiExtendedTextInteraction as c, QtiGap as d, QtiGapImg as e, QtiGapMatchInteraction as f, QtiGapText as g, QtiGraphicAssociateInteraction as h, QtiGraphicGapMatchInteraction as i, QtiGraphicOrderInteraction as j, QtiHotspotChoice as k, QtiHotspotInteraction as l, QtiHottext as m, QtiHottextInteraction as n, QtiInlineChoice as o, QtiInlineChoiceInteraction as p, QtiMatchInteraction as q, QtiOrderInteraction as r, QtiPortableCustomInteraction as s, QtiPrompt as t, QtiSelectPointInteraction as u, QtiSimpleAssociableChoice as v, QtiSimpleChoice as w, QtiSliderInteraction as x, QtiTextEntryInteraction as y,
|
|
1583
|
+
export { inlineStyleText as A, QtiPortableCustomInteractionTest as B, type Choice as C, type Orientation as O, QtiAssociableHotspot as Q, QtiAssociateInteraction as a, QtiChoiceInteraction as b, QtiExtendedTextInteraction as c, QtiGap as d, QtiGapImg as e, QtiGapMatchInteraction as f, QtiGapText as g, QtiGraphicAssociateInteraction as h, QtiGraphicGapMatchInteraction as i, QtiGraphicOrderInteraction as j, QtiHotspotChoice as k, QtiHotspotInteraction as l, QtiHottext as m, QtiHottextInteraction as n, QtiInlineChoice as o, QtiInlineChoiceInteraction as p, QtiMatchInteraction as q, QtiOrderInteraction as r, QtiPortableCustomInteraction as s, QtiPrompt as t, QtiSelectPointInteraction as u, QtiSimpleAssociableChoice as v, QtiSimpleChoice as w, QtiSliderInteraction as x, QtiTextEntryInteraction as y, inlineScriptText as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { LitElement, PropertyValues } from 'lit';
|
|
2
2
|
import { C as ConfigContext, V as ValidationDisplayMode } from './config.context.d-BvU9r-Mg.js';
|
|
3
3
|
import { V as ValidatableInteraction } from './interaction.interface.d-CvjHM2bi.js';
|
|
4
|
-
import { g as ResponseVariable } from './item.types.d-
|
|
4
|
+
import { g as ResponseVariable, B as BaseType } from './item.types.d-DuVR0ZVK.js';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* What a choice element should render and behave as. The same element — `qti-simple-choice`,
|
|
@@ -123,4 +123,36 @@ declare abstract class Interaction extends LitElement implements ValidatableInte
|
|
|
123
123
|
protected firstUpdated(_changedProperties?: PropertyValues): void;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
|
-
|
|
126
|
+
/**
|
|
127
|
+
* The value of a variable with `record` cardinality: its fields by field identifier.
|
|
128
|
+
*
|
|
129
|
+
* Field values are kept the way every other response value is kept, as QTI string literals — a
|
|
130
|
+
* float is `"4.12"`, a point is `"455 250"` — with a list-valued field as an array of them.
|
|
131
|
+
*/
|
|
132
|
+
type RecordValue = Record<string, string | string[] | null>;
|
|
133
|
+
/** A record's field values with the base type each `qti-value` declared for its field. */
|
|
134
|
+
interface RecordFieldValues {
|
|
135
|
+
value: RecordValue;
|
|
136
|
+
baseTypes: Record<string, BaseType>;
|
|
137
|
+
}
|
|
138
|
+
/** Whether a variable value is a record: a plain object, not a list and not NULL. */
|
|
139
|
+
declare const isRecordValue: (value: unknown) => value is RecordValue;
|
|
140
|
+
/**
|
|
141
|
+
* Reads the field values of a record out of `qti-value field-identifier="…" base-type="…"`
|
|
142
|
+
* elements, as found in a `qti-correct-response` or `qti-default-value` of a record declaration.
|
|
143
|
+
*
|
|
144
|
+
* A value without a `field-identifier` is not a record field and is skipped. A field without a
|
|
145
|
+
* `base-type` gets no entry in `baseTypes`, so a reader can tell "declared string" from "unknown".
|
|
146
|
+
*/
|
|
147
|
+
declare const readRecordFieldValues: (valueElements: Iterable<Element>) => RecordFieldValues;
|
|
148
|
+
/**
|
|
149
|
+
* A best guess at a record field's base type, for when the declaration does not say.
|
|
150
|
+
*
|
|
151
|
+
* A record field value carries no type of its own once it is stored, and a record response
|
|
152
|
+
* declaration has no `base-type`, so this is the fallback. A number is a float (or an integer
|
|
153
|
+
* when given as a whole JS number), two numbers separated by whitespace are a point, and
|
|
154
|
+
* anything else is a string.
|
|
155
|
+
*/
|
|
156
|
+
declare const inferRecordFieldBaseType: (value: unknown) => BaseType;
|
|
157
|
+
|
|
158
|
+
export { type ChoiceRole as C, Interaction as I, type RecordFieldValues as R, type InteractionContext as a, type RecordValue as b, interactionContext as c, isRecordValue as d, inferRecordFieldBaseType as i, readRecordFieldValues as r };
|
package/dist/test.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { U as ItemVariableValue, I as ITestNavigationMixin, a as ITestStateMixin } from './qti-test.d-
|
|
2
|
-
export { b as ItemRefTemplateModel, Q as QtiAssessmentItemRef, c as QtiAssessmentSection, d as QtiAssessmentTest, e as QtiBranchRule, f as QtiItemSessionControl, g as QtiNumberPresented, h as QtiNumberSelected, i as QtiOutcomeProcessing, j as QtiOutcomeProcessingProcessor, k as QtiPreCondition, l as QtiTest, m as QtiTestFeedback, n as QtiTestPart, o as QtiTestVariables, p as QtiTestVariablesExpression, S as SpeechState, T as TestCheckItem, q as TestContainer, r as TestEndAttempt, s as TestItemLink, t as TestItemToSpeech, u as TestNavigation, v as TestNext, w as TestPagingButtonsStamp, x as TestPrev, y as TestPrintContext, z as TestPrintVariables, A as TestScoringButtons, B as TestScoringFeedback, C as TestSectionButtonsStamp, D as TestSectionLink, E as TestStamp, F as TestTtsNext, G as TestTtsPause, H as TestTtsPick, J as TestTtsPlay, K as TestTtsPrev, L as TestTtsResume, M as TestTtsStop, N as TestView, O as TestViewToggle, P as TtsContext, R as ttsContext } from './qti-test.d-
|
|
1
|
+
import { U as ItemVariableValue, I as ITestNavigationMixin, a as ITestStateMixin } from './qti-test.d-DOWT6YNa.js';
|
|
2
|
+
export { b as ItemRefTemplateModel, Q as QtiAssessmentItemRef, c as QtiAssessmentSection, d as QtiAssessmentTest, e as QtiBranchRule, f as QtiItemSessionControl, g as QtiNumberPresented, h as QtiNumberSelected, i as QtiOutcomeProcessing, j as QtiOutcomeProcessingProcessor, k as QtiPreCondition, l as QtiTest, m as QtiTestFeedback, n as QtiTestPart, o as QtiTestVariables, p as QtiTestVariablesExpression, S as SpeechState, T as TestCheckItem, q as TestContainer, r as TestEndAttempt, s as TestItemLink, t as TestItemToSpeech, u as TestNavigation, v as TestNext, w as TestPagingButtonsStamp, x as TestPrev, y as TestPrintContext, z as TestPrintVariables, A as TestScoringButtons, B as TestScoringFeedback, C as TestSectionButtonsStamp, D as TestSectionLink, E as TestStamp, F as TestTtsNext, G as TestTtsPause, H as TestTtsPick, J as TestTtsPlay, K as TestTtsPrev, L as TestTtsResume, M as TestTtsStop, N as TestView, O as TestViewToggle, P as TtsContext, R as ttsContext } from './qti-test.d-DOWT6YNa.js';
|
|
3
3
|
import { LitElement } from 'lit';
|
|
4
|
-
import { b as ItemContext, c as OutcomeVariable, V as VariableDeclaration } from './item.types.d-
|
|
5
|
-
import { S as SessionContext } from './session.context.d-
|
|
4
|
+
import { b as ItemContext, c as OutcomeVariable, V as VariableDeclaration } from './item.types.d-DuVR0ZVK.js';
|
|
5
|
+
import { S as SessionContext } from './session.context.d-Cw8GcziG.js';
|
|
6
6
|
import { C as ConfigContext } from './config.context.d-BvU9r-Mg.js';
|
|
7
|
-
import { T as TestContext } from './qti-expression.d-
|
|
7
|
+
import { T as TestContext } from './qti-expression.d-B-Cfbqlb.js';
|
|
8
8
|
import './qti-transform-test.d-BL7GGFJj.js';
|
|
9
|
-
import './computed.types.d-
|
|
9
|
+
import './computed.types.d-SsTm3ieP.js';
|
|
10
10
|
import './elements.js';
|
|
11
11
|
import './interaction.interface.d-CvjHM2bi.js';
|
|
12
|
-
import './qti-feedback.d-
|
|
12
|
+
import './qti-feedback.d-DbzPSJuK.js';
|
|
13
13
|
import './qti-rule-base.d-Bdzg8eGH.js';
|
|
14
14
|
import './qti.context.d-CejJMlfZ.js';
|
|
15
15
|
import '@heximal/templates';
|
package/dist/test.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./chunk-
|
|
1
|
+
import "./chunk-TBJT7AGB.js";
|
|
2
2
|
import {
|
|
3
3
|
QTI_TEST_STATE_VERSION,
|
|
4
4
|
QtiAssessmentItemRef,
|
|
@@ -42,12 +42,12 @@ import {
|
|
|
42
42
|
TestView,
|
|
43
43
|
TestViewToggle,
|
|
44
44
|
ttsContext
|
|
45
|
-
} from "./chunk-
|
|
46
|
-
import "./chunk-
|
|
47
|
-
import "./chunk-
|
|
45
|
+
} from "./chunk-EAQOUBXA.js";
|
|
46
|
+
import "./chunk-TFQAUWCM.js";
|
|
47
|
+
import "./chunk-QVZLJY75.js";
|
|
48
48
|
import "./chunk-4DB4SC5K.js";
|
|
49
49
|
import "./chunk-TLAVOBEM.js";
|
|
50
|
-
import "./chunk-
|
|
50
|
+
import "./chunk-QUTM5TT6.js";
|
|
51
51
|
export {
|
|
52
52
|
QTI_TEST_STATE_VERSION,
|
|
53
53
|
QtiAssessmentItemRef,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@citolab/qti-components",
|
|
3
3
|
"description": "QTI component utilities",
|
|
4
|
-
"version": "9.
|
|
4
|
+
"version": "9.6.0",
|
|
5
5
|
"author": "",
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"@heximal/templates": "^0.1.5",
|
|
@@ -10,15 +10,15 @@
|
|
|
10
10
|
"lit-html": "^3.3.1"
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"@qti-components/base": "^2.
|
|
13
|
+
"@qti-components/base": "^2.5.0",
|
|
14
14
|
"@qti-components/corrections": "^0.4.0",
|
|
15
|
-
"@qti-components/elements": "^1.10.
|
|
15
|
+
"@qti-components/elements": "^1.10.1",
|
|
16
16
|
"@qti-components/interactions": "^1.10.4",
|
|
17
17
|
"@qti-components/item": "^1.5.0",
|
|
18
18
|
"@qti-components/loader": "^1.3.3",
|
|
19
|
-
"@qti-components/processing": "^1.6.
|
|
19
|
+
"@qti-components/processing": "^1.6.1",
|
|
20
20
|
"@qti-components/test": "^1.10.0",
|
|
21
|
-
"@qti-components/theme": "^2.
|
|
21
|
+
"@qti-components/theme": "^2.3.0",
|
|
22
22
|
"@qti-components/transformers": "^1.7.3"
|
|
23
23
|
},
|
|
24
24
|
"exports": {
|