@citolab/qti-components 7.14.2 → 7.15.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 +4070 -4048
- package/custom-elements.json +10320 -25886
- package/dist/base.d.ts +8 -0
- package/dist/base.js +50 -0
- package/dist/{chunks/chunk-7567ZPN6.js → chunk-2DOYPVF5.js} +252 -136
- package/dist/chunk-2DOYPVF5.js.map +1 -0
- package/dist/chunk-2ZEJ3RR5.js +89 -0
- package/dist/chunk-2ZEJ3RR5.js.map +1 -0
- package/dist/{chunks/chunk-Z2FFXTKX.js → chunk-352OTVTY.js} +1483 -445
- package/dist/chunk-352OTVTY.js.map +1 -0
- package/dist/{chunks/chunk-2X2C5WI5.js → chunk-C2HQFI2C.js} +939 -3842
- package/dist/chunk-C2HQFI2C.js.map +1 -0
- package/dist/chunk-DWIRLYDS.js +20 -0
- package/dist/chunk-DWIRLYDS.js.map +1 -0
- package/dist/{chunks/chunk-H2JE6IVU.js → chunk-EUXUH3YW.js} +1 -1
- package/dist/chunk-F44CI35W.js +145 -0
- package/dist/chunk-F44CI35W.js.map +1 -0
- package/dist/{chunks/chunk-XBPO6E25.js → chunk-INKI27D5.js} +6 -5
- package/dist/chunk-INKI27D5.js.map +1 -0
- package/dist/chunk-JEUY3MYB.js +2010 -0
- package/dist/chunk-JEUY3MYB.js.map +1 -0
- package/dist/chunk-O4XIWHTF.js +1139 -0
- package/dist/chunk-O4XIWHTF.js.map +1 -0
- package/dist/chunk-RI47B4ZT.js +1753 -0
- package/dist/chunk-RI47B4ZT.js.map +1 -0
- package/dist/{qti-loader/index.js → chunk-VEV4DGPH.js} +6 -6
- package/dist/chunk-VEV4DGPH.js.map +1 -0
- package/dist/{chunks/chunk-PT5ASWGQ.js → chunk-W4SQRNWO.js} +105 -2
- package/dist/chunk-W4SQRNWO.js.map +1 -0
- package/dist/elements.d.ts +1 -0
- package/dist/elements.js +42 -0
- package/dist/index.d.ts +8 -24
- package/dist/index.js +118 -284
- package/dist/index.js.map +1 -1
- package/dist/interactions.d.ts +1 -0
- package/dist/interactions.js +72 -0
- package/dist/item.css +8 -0
- package/dist/item.d.ts +1 -0
- package/dist/item.js +23 -0
- package/dist/loader.d.ts +1 -0
- package/dist/loader.js +11 -0
- package/dist/processing.d.ts +1 -0
- package/dist/processing.js +103 -0
- package/dist/qti-components-jsx.d.ts +1540 -2452
- package/dist/test.d.ts +1 -0
- package/dist/{qti-test/index.js → test.js} +11 -19
- package/dist/transformers.d.ts +1 -0
- package/dist/{qti-transformers/index.js → transformers.js} +3 -3
- package/dist/vscode.html-custom-data.json +469 -631
- package/package.json +71 -167
- package/LICENSE.md +0 -674
- package/dist/chunks/chunk-2X2C5WI5.js.map +0 -1
- package/dist/chunks/chunk-4OGJBG35.js +0 -8
- package/dist/chunks/chunk-4OGJBG35.js.map +0 -1
- package/dist/chunks/chunk-7567ZPN6.js.map +0 -1
- package/dist/chunks/chunk-BHJSX3Q6.js +0 -8
- package/dist/chunks/chunk-BHJSX3Q6.js.map +0 -1
- package/dist/chunks/chunk-C5RLRG3L.js +0 -10
- package/dist/chunks/chunk-C5RLRG3L.js.map +0 -1
- package/dist/chunks/chunk-CJADUWEC.js +0 -10
- package/dist/chunks/chunk-CJADUWEC.js.map +0 -1
- package/dist/chunks/chunk-DVQQ7I6Y.js +0 -8
- package/dist/chunks/chunk-DVQQ7I6Y.js.map +0 -1
- package/dist/chunks/chunk-ELDMXTUQ.js +0 -31
- package/dist/chunks/chunk-ELDMXTUQ.js.map +0 -1
- package/dist/chunks/chunk-GAAFN7QF.js +0 -146
- package/dist/chunks/chunk-GAAFN7QF.js.map +0 -1
- package/dist/chunks/chunk-H6KHXSIO.js +0 -8
- package/dist/chunks/chunk-H6KHXSIO.js.map +0 -1
- package/dist/chunks/chunk-JQ6HWGRY.js +0 -22
- package/dist/chunks/chunk-JQ6HWGRY.js.map +0 -1
- package/dist/chunks/chunk-NJNQOQUU.js +0 -8
- package/dist/chunks/chunk-NJNQOQUU.js.map +0 -1
- package/dist/chunks/chunk-P4QBOVQ2.js +0 -206
- package/dist/chunks/chunk-P4QBOVQ2.js.map +0 -1
- package/dist/chunks/chunk-PT5ASWGQ.js.map +0 -1
- package/dist/chunks/chunk-SV4K25ZI.js +0 -19
- package/dist/chunks/chunk-SV4K25ZI.js.map +0 -1
- package/dist/chunks/chunk-XBPO6E25.js.map +0 -1
- package/dist/chunks/chunk-YD7FVKDP.js +0 -236
- package/dist/chunks/chunk-YD7FVKDP.js.map +0 -1
- package/dist/chunks/chunk-Z2FFXTKX.js.map +0 -1
- package/dist/exports/computed-item.context.d.ts +0 -23
- package/dist/exports/computed-item.context.js +0 -8
- package/dist/exports/computed.context.d.ts +0 -34
- package/dist/exports/computed.context.js +0 -8
- package/dist/exports/config.context.d.ts +0 -14
- package/dist/exports/config.context.js +0 -8
- package/dist/exports/expression-result.d.ts +0 -19
- package/dist/exports/expression-result.js +0 -1
- package/dist/exports/interaction.d.ts +0 -46
- package/dist/exports/interaction.interface.d.ts +0 -13
- package/dist/exports/interaction.interface.js +0 -1
- package/dist/exports/interaction.js +0 -12
- package/dist/exports/item.context.d.ts +0 -11
- package/dist/exports/item.context.js +0 -8
- package/dist/exports/qti-assessment-item.context.d.ts +0 -9
- package/dist/exports/qti-assessment-item.context.js +0 -8
- package/dist/exports/qti-condition-expression.d.ts +0 -14
- package/dist/exports/qti-condition-expression.js +0 -11
- package/dist/exports/qti-condition-expression.js.map +0 -1
- package/dist/exports/qti-expression.d.ts +0 -23
- package/dist/exports/qti-expression.js +0 -10
- package/dist/exports/qti-expression.js.map +0 -1
- package/dist/exports/qti-test.d.ts +0 -12
- package/dist/exports/qti-test.js +0 -1
- package/dist/exports/qti-test.js.map +0 -1
- package/dist/exports/qti.context.d.ts +0 -14
- package/dist/exports/qti.context.js +0 -8
- package/dist/exports/qti.context.js.map +0 -1
- package/dist/exports/session.context.d.ts +0 -15
- package/dist/exports/session.context.js +0 -10
- package/dist/exports/session.context.js.map +0 -1
- package/dist/exports/test.context.d.ts +0 -16
- package/dist/exports/test.context.js +0 -10
- package/dist/exports/test.context.js.map +0 -1
- package/dist/exports/variables.d.ts +0 -2
- package/dist/exports/variables.js +0 -1
- package/dist/exports/variables.js.map +0 -1
- package/dist/qti-assessment-item-l-mN3teH.d.ts +0 -105
- package/dist/qti-components/index.d.ts +0 -1522
- package/dist/qti-components/index.js +0 -214
- package/dist/qti-components/index.js.map +0 -1
- package/dist/qti-item/index.d.ts +0 -114
- package/dist/qti-item/index.js +0 -19
- package/dist/qti-item/index.js.map +0 -1
- package/dist/qti-loader/index.d.ts +0 -21
- package/dist/qti-loader/index.js.map +0 -1
- package/dist/qti-modal-feedback-PKbhO-3w.d.ts +0 -30
- package/dist/qti-test/index.d.ts +0 -480
- package/dist/qti-test/index.js.map +0 -1
- package/dist/qti-test-Db7oNIWY.d.ts +0 -120
- package/dist/qti-transform-test-Bz9A3hmD.d.ts +0 -63
- package/dist/qti-transformers/index.d.ts +0 -18
- package/dist/qti-transformers/index.js.map +0 -1
- package/dist/variables-BCkyLoXK.d.ts +0 -55
- package/readme.md +0 -59
- /package/dist/{chunks/chunk-H2JE6IVU.js.map → base.js.map} +0 -0
- /package/dist/{exports/computed-item.context.js.map → chunk-EUXUH3YW.js.map} +0 -0
- /package/dist/{exports/computed.context.js.map → elements.js.map} +0 -0
- /package/dist/{exports/config.context.js.map → interactions.js.map} +0 -0
- /package/dist/{exports/expression-result.js.map → item.js.map} +0 -0
- /package/dist/{exports/interaction.interface.js.map → loader.js.map} +0 -0
- /package/dist/{exports/interaction.js.map → processing.js.map} +0 -0
- /package/dist/{exports/item.context.js.map → test.js.map} +0 -0
- /package/dist/{exports/qti-assessment-item.context.js.map → transformers.js.map} +0 -0
package/dist/base.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from '@qti-components/base';
|
|
2
|
+
import '@qti-components/elements';
|
|
3
|
+
import '@qti-components/test';
|
|
4
|
+
import '@qti-components/item';
|
|
5
|
+
import '@qti-components/interactions';
|
|
6
|
+
import '@qti-components/transformers';
|
|
7
|
+
import '@qti-components/loader';
|
|
8
|
+
import '@qti-components/processing';
|
package/dist/base.js
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Correctness,
|
|
3
|
+
INITIAL_SESSION_CONTEXT,
|
|
4
|
+
INITIAL_TEST_CONTEXT,
|
|
5
|
+
Interaction,
|
|
6
|
+
IsNullOrUndefined,
|
|
7
|
+
QtiConditionExpression,
|
|
8
|
+
QtiExpression,
|
|
9
|
+
QtiFeedback,
|
|
10
|
+
QtiRuleElement,
|
|
11
|
+
QtiVariableDeclaration,
|
|
12
|
+
ScoringHelper,
|
|
13
|
+
computedContext,
|
|
14
|
+
computedItemContext,
|
|
15
|
+
configContext,
|
|
16
|
+
convertNumberToUniversalFormat,
|
|
17
|
+
decimalSeparator,
|
|
18
|
+
itemContext,
|
|
19
|
+
itemContextVariables,
|
|
20
|
+
qtiContext,
|
|
21
|
+
removeDoubleSlashes,
|
|
22
|
+
sessionContext,
|
|
23
|
+
testContext
|
|
24
|
+
} from "./chunk-JEUY3MYB.js";
|
|
25
|
+
import "./chunk-EUXUH3YW.js";
|
|
26
|
+
export {
|
|
27
|
+
Correctness,
|
|
28
|
+
INITIAL_SESSION_CONTEXT,
|
|
29
|
+
INITIAL_TEST_CONTEXT,
|
|
30
|
+
Interaction,
|
|
31
|
+
IsNullOrUndefined,
|
|
32
|
+
QtiConditionExpression,
|
|
33
|
+
QtiExpression,
|
|
34
|
+
QtiFeedback,
|
|
35
|
+
QtiRuleElement,
|
|
36
|
+
QtiVariableDeclaration,
|
|
37
|
+
ScoringHelper,
|
|
38
|
+
computedContext,
|
|
39
|
+
computedItemContext,
|
|
40
|
+
configContext,
|
|
41
|
+
convertNumberToUniversalFormat,
|
|
42
|
+
decimalSeparator,
|
|
43
|
+
itemContext,
|
|
44
|
+
itemContextVariables,
|
|
45
|
+
qtiContext,
|
|
46
|
+
removeDoubleSlashes,
|
|
47
|
+
sessionContext,
|
|
48
|
+
testContext
|
|
49
|
+
};
|
|
50
|
+
//# sourceMappingURL=base.js.map
|
|
@@ -1,27 +1,31 @@
|
|
|
1
1
|
import {
|
|
2
|
-
item_default
|
|
3
|
-
|
|
2
|
+
item_default,
|
|
3
|
+
m
|
|
4
|
+
} from "./chunk-W4SQRNWO.js";
|
|
4
5
|
import {
|
|
5
6
|
watch
|
|
6
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-2ZEJ3RR5.js";
|
|
7
8
|
import {
|
|
8
9
|
qtiTransformItem
|
|
9
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-INKI27D5.js";
|
|
10
11
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
c,
|
|
13
|
+
computedItemContext,
|
|
14
|
+
configContext,
|
|
15
|
+
e,
|
|
16
|
+
i,
|
|
17
|
+
i2,
|
|
18
|
+
n,
|
|
19
|
+
r,
|
|
20
|
+
t,
|
|
21
|
+
x
|
|
22
|
+
} from "./chunk-JEUY3MYB.js";
|
|
16
23
|
import {
|
|
17
24
|
__decorateClass
|
|
18
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-EUXUH3YW.js";
|
|
19
26
|
|
|
20
|
-
//
|
|
21
|
-
|
|
22
|
-
import { customElement, property, state } from "lit/decorators.js";
|
|
23
|
-
import { until } from "lit/directives/until.js";
|
|
24
|
-
var ItemContainer = class extends LitElement {
|
|
27
|
+
// ../qti-item/src/components/item-container/item-container.ts
|
|
28
|
+
var ItemContainer = class extends i2 {
|
|
25
29
|
constructor() {
|
|
26
30
|
super(...arguments);
|
|
27
31
|
this.itemURL = null;
|
|
@@ -60,7 +64,7 @@ var ItemContainer = class extends LitElement {
|
|
|
60
64
|
}
|
|
61
65
|
initializeTemplateContent() {
|
|
62
66
|
const template = this.querySelector("template");
|
|
63
|
-
this.templateContent = template ? template.content :
|
|
67
|
+
this.templateContent = template ? template.content : x``;
|
|
64
68
|
}
|
|
65
69
|
applyStyles() {
|
|
66
70
|
const sheet = new CSSStyleSheet();
|
|
@@ -68,21 +72,21 @@ var ItemContainer = class extends LitElement {
|
|
|
68
72
|
this.shadowRoot.adoptedStyleSheets = [sheet];
|
|
69
73
|
}
|
|
70
74
|
render() {
|
|
71
|
-
return
|
|
75
|
+
return x`
|
|
72
76
|
${this.templateContent}
|
|
73
77
|
<slot></slot>
|
|
74
|
-
${
|
|
78
|
+
${m(this.itemDoc, x`<span>Loading...</span>`)}
|
|
75
79
|
`;
|
|
76
80
|
}
|
|
77
81
|
};
|
|
78
82
|
__decorateClass([
|
|
79
|
-
|
|
83
|
+
n({ type: String, attribute: "item-url" })
|
|
80
84
|
], ItemContainer.prototype, "itemURL", 2);
|
|
81
85
|
__decorateClass([
|
|
82
|
-
|
|
86
|
+
r()
|
|
83
87
|
], ItemContainer.prototype, "itemDoc", 2);
|
|
84
88
|
__decorateClass([
|
|
85
|
-
|
|
89
|
+
r()
|
|
86
90
|
], ItemContainer.prototype, "itemXML", 2);
|
|
87
91
|
__decorateClass([
|
|
88
92
|
watch("itemURL", { waitUntilFirstUpdate: true })
|
|
@@ -91,91 +95,62 @@ __decorateClass([
|
|
|
91
95
|
watch("itemXML", { waitUntilFirstUpdate: true })
|
|
92
96
|
], ItemContainer.prototype, "handleItemXMLChange", 1);
|
|
93
97
|
ItemContainer = __decorateClass([
|
|
94
|
-
|
|
98
|
+
t("item-container")
|
|
95
99
|
], ItemContainer);
|
|
96
100
|
|
|
97
|
-
//
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
101
|
+
// ../qti-item/src/components/item-correct-response-mode/item-correct-response-mode.ts
|
|
102
|
+
var ItemCorrectResponseMode = class extends i2 {
|
|
103
|
+
constructor() {
|
|
104
|
+
super(...arguments);
|
|
105
|
+
this.label = "Correct response mode";
|
|
106
|
+
this._options = {
|
|
107
|
+
internal: "Internal",
|
|
108
|
+
full: "Full (copy)"
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
_switchMode(view) {
|
|
112
|
+
this.dispatchEvent(
|
|
113
|
+
new CustomEvent("item-switch-correct-response-mode", {
|
|
114
|
+
detail: view,
|
|
115
|
+
bubbles: true
|
|
116
|
+
})
|
|
117
|
+
);
|
|
118
|
+
}
|
|
102
119
|
render() {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
<tbody>
|
|
120
|
-
${variables.map((v) => {
|
|
121
|
-
const correctResponse = v.correctResponse ? Array.isArray(v.correctResponse) ? v.correctResponse.join(", ") : v.correctResponse : "";
|
|
122
|
-
const mapEntries = v.mapping?.mapEntries?.map((m) => `${m.mapKey}=${m.mappedValue}pt`).join(", ") || "";
|
|
123
|
-
const areaMapEntries = v.areaMapping?.areaMapEntries?.map((m) => `${m.shape}(${m.coords})=${m.mappedValue}pt`).join(", ") || "";
|
|
124
|
-
return html2`
|
|
125
|
-
<tr>
|
|
126
|
-
<td>${v.identifier}</td>
|
|
127
|
-
<td>${Array.isArray(v.value) ? v.value.join(", ") : v.value}</td>
|
|
128
|
-
<td>${v.cardinality}</td>
|
|
129
|
-
<td>${v.baseType}</td>
|
|
130
|
-
<td>${correctResponse || mapEntries || areaMapEntries}</td>
|
|
131
|
-
</tr>
|
|
132
|
-
`;
|
|
133
|
-
})}
|
|
134
|
-
</tbody>
|
|
135
|
-
</table>
|
|
136
|
-
`;
|
|
137
|
-
return html2`
|
|
138
|
-
${renderTable(responseVariables, "Response Variables")} ${renderTable(outcomeVariables, "Outcome Variables")}
|
|
120
|
+
return x`
|
|
121
|
+
<label part="label" for="modeSelect">${this.label}</label>
|
|
122
|
+
<select
|
|
123
|
+
part="select"
|
|
124
|
+
id="modeSelect"
|
|
125
|
+
@change=${(e2) => {
|
|
126
|
+
const el = e2.target;
|
|
127
|
+
this._switchMode(el.value);
|
|
128
|
+
}}
|
|
129
|
+
>
|
|
130
|
+
${Object.keys(this._options).map(
|
|
131
|
+
(value) => x`<option value="${value}" ?selected=${value === this.itemContext?.correctResponseMode}>
|
|
132
|
+
${this._options[value]}
|
|
133
|
+
</option>`
|
|
134
|
+
)}
|
|
135
|
+
</select>
|
|
139
136
|
`;
|
|
140
137
|
}
|
|
141
138
|
};
|
|
142
|
-
PrintItemVariables.styles = css`
|
|
143
|
-
table {
|
|
144
|
-
width: 100%;
|
|
145
|
-
border-collapse: collapse;
|
|
146
|
-
margin: 20px 0;
|
|
147
|
-
font-size: 14px;
|
|
148
|
-
text-align: left;
|
|
149
|
-
}
|
|
150
|
-
th,
|
|
151
|
-
td {
|
|
152
|
-
border: 1px solid #ddd;
|
|
153
|
-
padding: 8px;
|
|
154
|
-
}
|
|
155
|
-
th {
|
|
156
|
-
background-color: #f4f4f4;
|
|
157
|
-
font-weight: bold;
|
|
158
|
-
}
|
|
159
|
-
h3 {
|
|
160
|
-
margin-top: 20px;
|
|
161
|
-
font-size: 16px;
|
|
162
|
-
}
|
|
163
|
-
`;
|
|
164
139
|
__decorateClass([
|
|
165
|
-
|
|
166
|
-
],
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
],
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
140
|
+
c({ context: configContext, subscribe: true })
|
|
141
|
+
], ItemCorrectResponseMode.prototype, "itemContext", 2);
|
|
142
|
+
__decorateClass([
|
|
143
|
+
n({ type: String })
|
|
144
|
+
], ItemCorrectResponseMode.prototype, "label", 2);
|
|
145
|
+
__decorateClass([
|
|
146
|
+
r()
|
|
147
|
+
], ItemCorrectResponseMode.prototype, "_options", 2);
|
|
148
|
+
ItemCorrectResponseMode = __decorateClass([
|
|
149
|
+
t("item-correct-response-mode")
|
|
150
|
+
], ItemCorrectResponseMode);
|
|
175
151
|
|
|
176
|
-
//
|
|
177
|
-
|
|
178
|
-
var form = css2`
|
|
152
|
+
// ../qti-item/src/components/styles.ts
|
|
153
|
+
var form = i`
|
|
179
154
|
display: inline-flex;
|
|
180
155
|
align-items: center;
|
|
181
156
|
cursor: pointer;
|
|
@@ -183,21 +158,92 @@ var form = css2`
|
|
|
183
158
|
border-radius: 0.25rem;
|
|
184
159
|
user-select: none;
|
|
185
160
|
`;
|
|
186
|
-
var btn =
|
|
161
|
+
var btn = i`
|
|
187
162
|
background-color: lightgray;
|
|
188
163
|
${form};
|
|
189
164
|
`;
|
|
190
|
-
var dis =
|
|
165
|
+
var dis = i`
|
|
191
166
|
cursor: not-allowed;
|
|
192
167
|
opacity: 0.8;
|
|
193
168
|
`;
|
|
194
|
-
var ind =
|
|
169
|
+
var ind = i`
|
|
195
170
|
${form};
|
|
196
171
|
border: 1px solid gray;
|
|
197
172
|
`;
|
|
198
173
|
|
|
199
|
-
//
|
|
200
|
-
var
|
|
174
|
+
// ../qti-item/src/components/item-show-candidate-correction/item-show-candidate-correction.ts
|
|
175
|
+
var ItemShowCandidateCorrection = class extends i2 {
|
|
176
|
+
// Store previous active item reference
|
|
177
|
+
constructor() {
|
|
178
|
+
super();
|
|
179
|
+
this.shown = false;
|
|
180
|
+
this.disabled = false;
|
|
181
|
+
this.showCandidateCorrectionText = "Show candidate correction";
|
|
182
|
+
this.hideCandidateCorrectionText = "Hide candidate correction";
|
|
183
|
+
this.noCorrectResponseText = "No correct response specified";
|
|
184
|
+
this._hasCorrectResponse = false;
|
|
185
|
+
// correct response is removed on certain point
|
|
186
|
+
this._previousActiveItem = "";
|
|
187
|
+
}
|
|
188
|
+
updated() {
|
|
189
|
+
if (!this._hasCorrectResponse || this._previousActiveItem !== this.computedContext?.identifier) {
|
|
190
|
+
this._previousActiveItem = this.computedContext?.identifier;
|
|
191
|
+
const containsCorrectResponse = !!this.computedContext?.variables.some((v) => v["correctResponse"]);
|
|
192
|
+
const containsMapping = !!this.computedContext?.variables.some((v) => {
|
|
193
|
+
return v["mapping"]?.mapEntries?.length > 0 || v["areaMapping"]?.areaMapEntries?.length > 0;
|
|
194
|
+
});
|
|
195
|
+
this._hasCorrectResponse = containsCorrectResponse || containsMapping;
|
|
196
|
+
}
|
|
197
|
+
this.disabled = !this._hasCorrectResponse;
|
|
198
|
+
}
|
|
199
|
+
_toggleState() {
|
|
200
|
+
if (this.disabled) return;
|
|
201
|
+
this.dispatchEvent(
|
|
202
|
+
new CustomEvent("item-show-candidate-correction", {
|
|
203
|
+
detail: !this.shown,
|
|
204
|
+
bubbles: true
|
|
205
|
+
})
|
|
206
|
+
);
|
|
207
|
+
}
|
|
208
|
+
_getDisplayedText() {
|
|
209
|
+
return this.disabled ? this.noCorrectResponseText : this.shown ? this.hideCandidateCorrectionText : this.showCandidateCorrectionText;
|
|
210
|
+
}
|
|
211
|
+
render() {
|
|
212
|
+
return x` <div @click="${this._toggleState}">${this._getDisplayedText()}</div> `;
|
|
213
|
+
}
|
|
214
|
+
};
|
|
215
|
+
ItemShowCandidateCorrection.styles = i`
|
|
216
|
+
:host {
|
|
217
|
+
${btn};
|
|
218
|
+
}
|
|
219
|
+
:host([disabled]) {
|
|
220
|
+
${dis};
|
|
221
|
+
}
|
|
222
|
+
`;
|
|
223
|
+
__decorateClass([
|
|
224
|
+
c({ context: computedItemContext, subscribe: true })
|
|
225
|
+
], ItemShowCandidateCorrection.prototype, "computedContext", 2);
|
|
226
|
+
__decorateClass([
|
|
227
|
+
n({ type: Boolean, reflect: true })
|
|
228
|
+
], ItemShowCandidateCorrection.prototype, "shown", 2);
|
|
229
|
+
__decorateClass([
|
|
230
|
+
n({ type: Boolean, reflect: true })
|
|
231
|
+
], ItemShowCandidateCorrection.prototype, "disabled", 2);
|
|
232
|
+
__decorateClass([
|
|
233
|
+
n({ type: String })
|
|
234
|
+
], ItemShowCandidateCorrection.prototype, "showCandidateCorrectionText", 2);
|
|
235
|
+
__decorateClass([
|
|
236
|
+
n({ type: String })
|
|
237
|
+
], ItemShowCandidateCorrection.prototype, "hideCandidateCorrectionText", 2);
|
|
238
|
+
__decorateClass([
|
|
239
|
+
n({ type: String })
|
|
240
|
+
], ItemShowCandidateCorrection.prototype, "noCorrectResponseText", 2);
|
|
241
|
+
ItemShowCandidateCorrection = __decorateClass([
|
|
242
|
+
t("item-show-candidate-correction")
|
|
243
|
+
], ItemShowCandidateCorrection);
|
|
244
|
+
|
|
245
|
+
// ../qti-item/src/components/item-show-correct-response/item-show-correct-response.ts
|
|
246
|
+
var ItemShowCorrectResponse = class extends i2 {
|
|
201
247
|
constructor() {
|
|
202
248
|
super(...arguments);
|
|
203
249
|
this.shown = false;
|
|
@@ -234,10 +280,10 @@ var ItemShowCorrectResponse = class extends LitElement3 {
|
|
|
234
280
|
return this.disabled ? this.noCorrectResponseText : this.shown ? this.hideCorrectText : this.showCorrectText;
|
|
235
281
|
}
|
|
236
282
|
render() {
|
|
237
|
-
return
|
|
283
|
+
return x` <div @click="${this._toggleState}">${this._getDisplayedText()}</div> `;
|
|
238
284
|
}
|
|
239
285
|
};
|
|
240
|
-
ItemShowCorrectResponse.styles =
|
|
286
|
+
ItemShowCorrectResponse.styles = i`
|
|
241
287
|
:host {
|
|
242
288
|
${btn};
|
|
243
289
|
}
|
|
@@ -246,32 +292,100 @@ ItemShowCorrectResponse.styles = css3`
|
|
|
246
292
|
}
|
|
247
293
|
`;
|
|
248
294
|
__decorateClass([
|
|
249
|
-
|
|
295
|
+
c({ context: computedItemContext, subscribe: true })
|
|
250
296
|
], ItemShowCorrectResponse.prototype, "computedContext", 2);
|
|
251
297
|
__decorateClass([
|
|
252
|
-
|
|
298
|
+
n({ type: Boolean, reflect: true })
|
|
253
299
|
], ItemShowCorrectResponse.prototype, "shown", 2);
|
|
254
300
|
__decorateClass([
|
|
255
|
-
|
|
301
|
+
n({ type: Boolean, reflect: true })
|
|
256
302
|
], ItemShowCorrectResponse.prototype, "disabled", 2);
|
|
257
303
|
__decorateClass([
|
|
258
|
-
|
|
304
|
+
n({ type: String })
|
|
259
305
|
], ItemShowCorrectResponse.prototype, "showCorrectText", 2);
|
|
260
306
|
__decorateClass([
|
|
261
|
-
|
|
307
|
+
n({ type: String })
|
|
262
308
|
], ItemShowCorrectResponse.prototype, "hideCorrectText", 2);
|
|
263
309
|
__decorateClass([
|
|
264
|
-
|
|
310
|
+
n({ type: String })
|
|
265
311
|
], ItemShowCorrectResponse.prototype, "noCorrectResponseText", 2);
|
|
266
312
|
ItemShowCorrectResponse = __decorateClass([
|
|
267
|
-
|
|
313
|
+
t("item-show-correct-response")
|
|
268
314
|
], ItemShowCorrectResponse);
|
|
269
315
|
|
|
270
|
-
//
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
316
|
+
// ../qti-item/src/components/item-print-variables/item-print-variables.ts
|
|
317
|
+
var ItemPrintVariables = class extends i2 {
|
|
318
|
+
render() {
|
|
319
|
+
const activeItem = this.computedContext;
|
|
320
|
+
if (!activeItem || !activeItem.variables) return x``;
|
|
321
|
+
const responseVariables = activeItem.variables.filter((v) => v.type === "response");
|
|
322
|
+
const outcomeVariables = activeItem.variables.filter((v) => v.type === "outcome");
|
|
323
|
+
const renderTable = (variables, title) => x`
|
|
324
|
+
<h3>${title}</h3>
|
|
325
|
+
<table>
|
|
326
|
+
<thead>
|
|
327
|
+
<tr>
|
|
328
|
+
<th>Identifier</th>
|
|
329
|
+
<th>Value</th>
|
|
330
|
+
<th>Cardinality</th>
|
|
331
|
+
<th>Base Type</th>
|
|
332
|
+
<th>Correct Response / Mappings</th>
|
|
333
|
+
</tr>
|
|
334
|
+
</thead>
|
|
335
|
+
<tbody>
|
|
336
|
+
${variables.map((v) => {
|
|
337
|
+
const correctResponse = v.correctResponse ? Array.isArray(v.correctResponse) ? v.correctResponse.join(", ") : v.correctResponse : "";
|
|
338
|
+
const mapEntries = v.mapping?.mapEntries?.map((m2) => `${m2.mapKey}=${m2.mappedValue}pt`).join(", ") || "";
|
|
339
|
+
const areaMapEntries = v.areaMapping?.areaMapEntries?.map((m2) => `${m2.shape}(${m2.coords})=${m2.mappedValue}pt`).join(", ") || "";
|
|
340
|
+
return x`
|
|
341
|
+
<tr>
|
|
342
|
+
<td>${v.identifier}</td>
|
|
343
|
+
<td>${Array.isArray(v.value) ? v.value.join(", ") : v.value}</td>
|
|
344
|
+
<td>${v.cardinality}</td>
|
|
345
|
+
<td>${v.baseType}</td>
|
|
346
|
+
<td>${correctResponse || mapEntries || areaMapEntries}</td>
|
|
347
|
+
</tr>
|
|
348
|
+
`;
|
|
349
|
+
})}
|
|
350
|
+
</tbody>
|
|
351
|
+
</table>
|
|
352
|
+
`;
|
|
353
|
+
return x`
|
|
354
|
+
${renderTable(responseVariables, "Response Variables")} ${renderTable(outcomeVariables, "Outcome Variables")}
|
|
355
|
+
`;
|
|
356
|
+
}
|
|
357
|
+
};
|
|
358
|
+
ItemPrintVariables.styles = i`
|
|
359
|
+
table {
|
|
360
|
+
width: 100%;
|
|
361
|
+
border-collapse: collapse;
|
|
362
|
+
margin: 20px 0;
|
|
363
|
+
font-size: 14px;
|
|
364
|
+
text-align: left;
|
|
365
|
+
}
|
|
366
|
+
th,
|
|
367
|
+
td {
|
|
368
|
+
border: 1px solid #ddd;
|
|
369
|
+
padding: 8px;
|
|
370
|
+
}
|
|
371
|
+
th {
|
|
372
|
+
background-color: #f4f4f4;
|
|
373
|
+
font-weight: bold;
|
|
374
|
+
}
|
|
375
|
+
h3 {
|
|
376
|
+
margin-top: 20px;
|
|
377
|
+
font-size: 16px;
|
|
378
|
+
}
|
|
379
|
+
`;
|
|
380
|
+
__decorateClass([
|
|
381
|
+
c({ context: computedItemContext, subscribe: true })
|
|
382
|
+
], ItemPrintVariables.prototype, "computedContext", 2);
|
|
383
|
+
ItemPrintVariables = __decorateClass([
|
|
384
|
+
t("item-print-variables")
|
|
385
|
+
], ItemPrintVariables);
|
|
386
|
+
|
|
387
|
+
// ../qti-item/src/components/qti-item/qti-item.ts
|
|
388
|
+
var QtiItem = class extends i2 {
|
|
275
389
|
constructor() {
|
|
276
390
|
super();
|
|
277
391
|
this.configContext = {};
|
|
@@ -287,12 +401,12 @@ var QtiItem = class extends LitElement4 {
|
|
|
287
401
|
this.addEventListener("item-show-candidate-correction", this._onHandleShowCandidateCorrection);
|
|
288
402
|
this.addEventListener("item-switch-correct-response-mode", this._onHandleSwitchCorrectResponseMode);
|
|
289
403
|
}
|
|
290
|
-
_handleItemContextChanged(
|
|
291
|
-
this._updateItemVariablesInTestContext(
|
|
404
|
+
_handleItemContextChanged(e2) {
|
|
405
|
+
this._updateItemVariablesInTestContext(e2.detail.itemContext.identifier, e2.detail?.itemContext?.variables || []);
|
|
292
406
|
}
|
|
293
|
-
_handleAssessmentItemConnected(
|
|
294
|
-
const fullVariables =
|
|
295
|
-
this._qtiAssessmentItem =
|
|
407
|
+
_handleAssessmentItemConnected(e2) {
|
|
408
|
+
const fullVariables = e2.detail._context.variables;
|
|
409
|
+
this._qtiAssessmentItem = e2.detail;
|
|
296
410
|
this.computedContext = this.computedContext?.identifier === this._qtiAssessmentItem.identifier ? { ...this.computedContext, title: this._qtiAssessmentItem.title } : {
|
|
297
411
|
identifier: this._qtiAssessmentItem.identifier,
|
|
298
412
|
title: this._qtiAssessmentItem.title,
|
|
@@ -302,21 +416,21 @@ var QtiItem = class extends LitElement4 {
|
|
|
302
416
|
};
|
|
303
417
|
this._updateItemVariablesInTestContext(this._qtiAssessmentItem.identifier, fullVariables || []);
|
|
304
418
|
}
|
|
305
|
-
_handleShowCorrectResponse(
|
|
419
|
+
_handleShowCorrectResponse(e2) {
|
|
306
420
|
if (this._qtiAssessmentItem) {
|
|
307
|
-
this._qtiAssessmentItem.showCorrectResponse(
|
|
421
|
+
this._qtiAssessmentItem.showCorrectResponse(e2.detail);
|
|
308
422
|
}
|
|
309
423
|
}
|
|
310
|
-
_handleShowCandidateCorrection(
|
|
424
|
+
_handleShowCandidateCorrection(e2) {
|
|
311
425
|
if (this._qtiAssessmentItem) {
|
|
312
|
-
this._qtiAssessmentItem.showCandidateCorrection(
|
|
426
|
+
this._qtiAssessmentItem.showCandidateCorrection(e2.detail);
|
|
313
427
|
}
|
|
314
428
|
}
|
|
315
|
-
_handleSwitchCorrectResponseMode(
|
|
429
|
+
_handleSwitchCorrectResponseMode(e2) {
|
|
316
430
|
this._handleShowCorrectResponse(new CustomEvent("item-show-correct-response", { detail: false, bubbles: true }));
|
|
317
431
|
this.configContext = {
|
|
318
432
|
...this.configContext,
|
|
319
|
-
correctResponseMode:
|
|
433
|
+
correctResponseMode: e2.detail
|
|
320
434
|
};
|
|
321
435
|
}
|
|
322
436
|
_updateItemVariablesInTestContext(identifier, variables) {
|
|
@@ -336,7 +450,7 @@ var QtiItem = class extends LitElement4 {
|
|
|
336
450
|
};
|
|
337
451
|
}
|
|
338
452
|
render() {
|
|
339
|
-
return
|
|
453
|
+
return x`<slot></slot>`;
|
|
340
454
|
}
|
|
341
455
|
disconnectedCallback() {
|
|
342
456
|
super.disconnectedCallback();
|
|
@@ -345,21 +459,23 @@ var QtiItem = class extends LitElement4 {
|
|
|
345
459
|
}
|
|
346
460
|
};
|
|
347
461
|
__decorateClass([
|
|
348
|
-
|
|
349
|
-
|
|
462
|
+
r(),
|
|
463
|
+
e({ context: computedItemContext })
|
|
350
464
|
], QtiItem.prototype, "computedContext", 2);
|
|
351
465
|
__decorateClass([
|
|
352
|
-
|
|
353
|
-
|
|
466
|
+
r(),
|
|
467
|
+
e({ context: configContext })
|
|
354
468
|
], QtiItem.prototype, "configContext", 2);
|
|
355
469
|
QtiItem = __decorateClass([
|
|
356
|
-
|
|
470
|
+
t("qti-item")
|
|
357
471
|
], QtiItem);
|
|
358
472
|
|
|
359
473
|
export {
|
|
360
474
|
ItemContainer,
|
|
361
|
-
|
|
475
|
+
ItemCorrectResponseMode,
|
|
476
|
+
ItemShowCandidateCorrection,
|
|
362
477
|
ItemShowCorrectResponse,
|
|
478
|
+
ItemPrintVariables,
|
|
363
479
|
QtiItem
|
|
364
480
|
};
|
|
365
|
-
//# sourceMappingURL=chunk-
|
|
481
|
+
//# sourceMappingURL=chunk-2DOYPVF5.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../qti-item/src/components/item-container/item-container.ts","../../qti-item/src/components/item-correct-response-mode/item-correct-response-mode.ts","../../qti-item/src/components/styles.ts","../../qti-item/src/components/item-show-candidate-correction/item-show-candidate-correction.ts","../../qti-item/src/components/item-show-correct-response/item-show-correct-response.ts","../../qti-item/src/components/item-print-variables/item-print-variables.ts","../../qti-item/src/components/qti-item/qti-item.ts"],"sourcesContent":["import { LitElement, html } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport { until } from 'lit/directives/until.js';\n\nimport { watch } from '@qti-components/utilities';\nimport { qtiTransformItem } from '@qti-components/transformers';\nimport itemCss from '@qti-components/theme/src/item.css?inline';\n\n/**\n * `<item-container>` is a custom element designed for hosting the qti-assessment-item.\n * The `qti-assessment-item` will be placed inside the shadow DOM of this element.\n * The element loads the item from the provided URL and renders it inside the shadow DOM.\n *\n * ### Styling\n * Add a class to the element for styling.\n *\n * ```html\n * <qti-item>\n * <item-container class=\"m-4 bg-white\" item-url=\"./path/to/item.xml\"></item-container>\n * </qti-item>\n * ```\n */\n@customElement('item-container')\nexport class ItemContainer extends LitElement {\n /** URL of the item to load */\n @property({ type: String, attribute: 'item-url' })\n itemURL: string = null;\n\n /** A parsed HTML document */\n @state()\n itemDoc: DocumentFragment = null;\n\n /** The raw XML string */\n @state()\n itemXML: string = null;\n\n /** Template content if provided */\n private templateContent: unknown = null;\n\n @watch('itemURL', { waitUntilFirstUpdate: true })\n protected async handleItemURLChange() {\n if (!this.itemURL) return;\n try {\n const api = await qtiTransformItem().load(this.itemURL);\n this.itemDoc = api.htmlDoc();\n } catch (error) {\n console.error('Error loading or parsing XML:', error);\n }\n }\n\n @watch('itemXML', { waitUntilFirstUpdate: true })\n protected handleItemXMLChange() {\n if (!this.itemXML) return;\n try {\n this.itemDoc = qtiTransformItem().parse(this.itemXML).htmlDoc();\n } catch (error) {\n console.error('Error parsing XML:', error);\n }\n }\n\n override async connectedCallback(): Promise<void> {\n super.connectedCallback();\n this.initializeTemplateContent();\n this.applyStyles();\n if (this.itemURL) {\n this.handleItemURLChange();\n }\n if (this.itemXML) {\n this.handleItemXMLChange();\n }\n }\n\n private initializeTemplateContent() {\n const template = this.querySelector('template') as HTMLTemplateElement;\n this.templateContent = template ? template.content : html``;\n }\n\n private applyStyles() {\n const sheet = new CSSStyleSheet();\n sheet.replaceSync(itemCss);\n this.shadowRoot.adoptedStyleSheets = [sheet];\n }\n\n override render() {\n return html`\n ${this.templateContent}\n <slot></slot>\n ${until(this.itemDoc, html`<span>Loading...</span>`)}\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-container': ItemContainer;\n }\n}\n","import { html, LitElement } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport { consume } from '@lit/context';\n\nimport { configContext } from '@qti-components/base';\n\nimport type { ConfigContext, CorrectResponseMode } from '@qti-components/base';\n\n@customElement('item-correct-response-mode')\nexport class ItemCorrectResponseMode extends LitElement {\n @consume({ context: configContext, subscribe: true })\n private itemContext: ConfigContext;\n\n @property({ type: String })\n label = 'Correct response mode';\n\n @state()\n private _options = {\n internal: 'Internal',\n full: 'Full (copy)'\n };\n\n private _switchMode(view: CorrectResponseMode) {\n this.dispatchEvent(\n new CustomEvent('item-switch-correct-response-mode', {\n detail: view,\n bubbles: true\n })\n );\n }\n\n override render() {\n return html`\n <label part=\"label\" for=\"modeSelect\">${this.label}</label>\n <select\n part=\"select\"\n id=\"modeSelect\"\n @change=${(e: Event) => {\n const el = e.target as HTMLSelectElement;\n this._switchMode(el.value as CorrectResponseMode);\n }}\n >\n ${Object.keys(this._options).map(\n value =>\n html`<option value=\"${value}\" ?selected=${value === this.itemContext?.correctResponseMode}>\n ${this._options[value as keyof typeof this._options]}\n </option>`\n )}\n </select>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-correct-response-mode': ItemCorrectResponseMode;\n }\n}\n","import { css } from 'lit';\n\nexport const form = css`\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n padding: 0.5rem 1rem;\n border-radius: 0.25rem;\n user-select: none;\n`;\n\nexport const btn = css`\n background-color: lightgray;\n ${form};\n`;\n\nexport const dis = css`\n cursor: not-allowed;\n opacity: 0.8;\n`;\n\nexport const ind = css`\n ${form};\n border: 1px solid gray;\n`;\n","import { css, html, LitElement } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { consume } from '@lit/context';\n\nimport { computedItemContext } from '@qti-components/base';\n\nimport * as styles from '../styles';\n\nimport type { ComputedItemContext } from '@qti-components/base';\n\n@customElement('item-show-candidate-correction')\nexport class ItemShowCandidateCorrection extends LitElement {\n @consume({ context: computedItemContext, subscribe: true })\n public computedContext?: ComputedItemContext;\n\n static override styles = css`\n :host {\n ${styles.btn};\n }\n :host([disabled]) {\n ${styles.dis};\n }\n `;\n\n @property({ type: Boolean, reflect: true }) shown = false;\n @property({ type: Boolean, reflect: true }) disabled = false; // Reflects to `disabled` attribute\n @property({ type: String }) showCandidateCorrectionText = 'Show candidate correction';\n @property({ type: String }) hideCandidateCorrectionText = 'Hide candidate correction';\n @property({ type: String }) noCorrectResponseText = 'No correct response specified';\n\n private _hasCorrectResponse = false; // correct response is removed on certain point\n private _previousActiveItem = ''; // Store previous active item reference\n\n constructor() {\n super();\n }\n\n override updated() {\n if (!this._hasCorrectResponse || this._previousActiveItem !== this.computedContext?.identifier) {\n this._previousActiveItem = this.computedContext?.identifier;\n const containsCorrectResponse = !!this.computedContext?.variables.some(v => (v as any)['correctResponse']);\n const containsMapping = !!this.computedContext?.variables.some(v => {\n return (v as any)['mapping']?.mapEntries?.length > 0 || (v as any)['areaMapping']?.areaMapEntries?.length > 0;\n });\n this._hasCorrectResponse = containsCorrectResponse || containsMapping;\n }\n this.disabled = !this._hasCorrectResponse;\n }\n\n private _toggleState() {\n if (this.disabled) return; // Prevent toggle if disabled\n\n this.dispatchEvent(\n new CustomEvent('item-show-candidate-correction', {\n detail: !this.shown,\n bubbles: true\n })\n );\n }\n\n private _getDisplayedText(): string {\n return this.disabled\n ? this.noCorrectResponseText\n : this.shown\n ? this.hideCandidateCorrectionText\n : this.showCandidateCorrectionText;\n }\n\n override render() {\n return html` <div @click=\"${this._toggleState}\">${this._getDisplayedText()}</div> `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-show-candidate-correction': ItemShowCandidateCorrection;\n }\n}\n","import { css, html, LitElement } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { consume } from '@lit/context';\n\nimport { computedItemContext } from '@qti-components/base';\n\nimport * as styles from '../styles';\n\nimport type { ComputedItemContext } from '@qti-components/base';\n\n@customElement('item-show-correct-response')\nexport class ItemShowCorrectResponse extends LitElement {\n @consume({ context: computedItemContext, subscribe: true })\n public computedContext?: ComputedItemContext;\n\n static override styles = css`\n :host {\n ${styles.btn};\n }\n :host([disabled]) {\n ${styles.dis};\n }\n `;\n\n @property({ type: Boolean, reflect: true }) shown = false;\n @property({ type: Boolean, reflect: true }) disabled = false; // Reflects to `disabled` attribute\n @property({ type: String }) showCorrectText = 'Show correct response';\n @property({ type: String }) hideCorrectText = 'Hide correct response';\n @property({ type: String }) noCorrectResponseText = 'No correct response specified';\n\n private _hasCorrectResponse = false; // correct response is removed on certain point\n private _previousActiveItem = ''; // Store previous active item reference\n\n override updated() {\n if (!this._hasCorrectResponse || this._previousActiveItem !== this.computedContext?.identifier) {\n this._previousActiveItem = this.computedContext?.identifier;\n const containsCorrectResponse = !!this.computedContext?.variables.some(v => (v as any)['correctResponse']);\n const containsMapping = !!this.computedContext?.variables.some(v => {\n return (v as any)['mapping']?.mapEntries?.length > 0 || (v as any)['areaMapping']?.areaMapEntries?.length > 0;\n });\n this._hasCorrectResponse = containsCorrectResponse || containsMapping;\n }\n this.disabled = !this._hasCorrectResponse;\n }\n\n private _toggleState() {\n if (this.disabled) return; // Prevent toggle if disabled\n\n this.dispatchEvent(\n new CustomEvent('item-show-correct-response', {\n detail: !this.shown,\n bubbles: true\n })\n );\n }\n\n private _getDisplayedText(): string {\n return this.disabled ? this.noCorrectResponseText : this.shown ? this.hideCorrectText : this.showCorrectText;\n }\n\n override render() {\n return html` <div @click=\"${this._toggleState}\">${this._getDisplayedText()}</div> `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-show-correct-response': ItemShowCorrectResponse;\n }\n}\n","import { consume } from '@lit/context';\nimport { css, html, LitElement } from 'lit';\nimport { customElement } from 'lit/decorators.js';\n\nimport { computedItemContext } from '@qti-components/base';\n\nimport type { ResponseVariable } from '@qti-components/base';\nimport type { ComputedItemContext } from '@qti-components/base';\n\n@customElement('item-print-variables')\nexport class ItemPrintVariables extends LitElement {\n @consume({ context: computedItemContext, subscribe: true })\n protected computedContext?: ComputedItemContext;\n\n static override styles = css`\n table {\n width: 100%;\n border-collapse: collapse;\n margin: 20px 0;\n font-size: 14px;\n text-align: left;\n }\n th,\n td {\n border: 1px solid #ddd;\n padding: 8px;\n }\n th {\n background-color: #f4f4f4;\n font-weight: bold;\n }\n h3 {\n margin-top: 20px;\n font-size: 16px;\n }\n `;\n\n override render() {\n const activeItem = this.computedContext;\n\n if (!activeItem || !activeItem.variables) return html``;\n\n const responseVariables: ResponseVariable[] = activeItem.variables.filter(v => v.type === 'response');\n const outcomeVariables = activeItem.variables.filter(v => v.type === 'outcome');\n\n const renderTable = (variables: ResponseVariable[], title: string) => html`\n <h3>${title}</h3>\n <table>\n <thead>\n <tr>\n <th>Identifier</th>\n <th>Value</th>\n <th>Cardinality</th>\n <th>Base Type</th>\n <th>Correct Response / Mappings</th>\n </tr>\n </thead>\n <tbody>\n ${variables.map(v => {\n const correctResponse = v.correctResponse\n ? Array.isArray(v.correctResponse)\n ? v.correctResponse.join(', ')\n : v.correctResponse\n : '';\n\n const mapEntries = v.mapping?.mapEntries?.map(m => `${m.mapKey}=${m.mappedValue}pt`).join(', ') || '';\n\n const areaMapEntries =\n v.areaMapping?.areaMapEntries?.map(m => `${m.shape}(${m.coords})=${m.mappedValue}pt`).join(', ') || '';\n\n return html`\n <tr>\n <td>${v.identifier}</td>\n <td>${Array.isArray(v.value) ? v.value.join(', ') : v.value}</td>\n <td>${v.cardinality}</td>\n <td>${v.baseType}</td>\n <td>${correctResponse || mapEntries || areaMapEntries}</td>\n </tr>\n `;\n })}\n </tbody>\n </table>\n `;\n\n return html`\n ${renderTable(responseVariables, 'Response Variables')} ${renderTable(outcomeVariables, 'Outcome Variables')}\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-print-variables': ItemPrintVariables;\n }\n}\n","import { provide } from '@lit/context';\nimport { html, LitElement } from 'lit';\nimport { customElement, state } from 'lit/decorators.js';\n\nimport { computedItemContext } from '@qti-components/base';\nimport { configContext } from '@qti-components/base';\n\nimport type { QtiAssessmentItem } from '@qti-components/elements';\nimport type { ConfigContext, CorrectResponseMode } from '@qti-components/base';\nimport type { ItemContext } from '@qti-components/base';\nimport type { VariableDeclaration } from '@qti-components/base';\nimport type { ComputedItemContext } from '@qti-components/base';\n\n/**\n * `<qti-item>` is a custom element designed for rendering a single `qti-assessment-item`.\n * It can also host some functionalities to interact with the item like scoring, showing feedback, etc.\n * Placing a mandatory `<item-container>` inside '<qti-item>' will load or parse the item and render it.\n * See `<item-container>` for more details.\n *\n * ```html\n * <qti-item>\n * <item-container class=\"m-4 bg-white\" item-url=\"./path/to/item.xml\"></item-container>\n * </qti-item>\n * ```\n */\n@customElement('qti-item')\nexport class QtiItem extends LitElement {\n @state()\n @provide({ context: computedItemContext })\n public computedContext: ComputedItemContext;\n private _qtiAssessmentItem?: QtiAssessmentItem;\n\n @state()\n @provide({ context: configContext })\n public configContext: ConfigContext = {};\n\n // Store event handlers as instance properties\n private _onItemContextChanged = this._handleItemContextChanged.bind(this);\n private _onAssessmentItemConnected = this._handleAssessmentItemConnected.bind(this);\n\n private _onHandleShowCorrectResponse = this._handleShowCorrectResponse.bind(this);\n private _onHandleShowCandidateCorrection = this._handleShowCandidateCorrection.bind(this);\n private _onHandleSwitchCorrectResponseMode = this._handleSwitchCorrectResponseMode.bind(this);\n\n constructor() {\n super();\n this.addEventListener('qti-item-context-updated', this._onItemContextChanged);\n this.addEventListener('qti-assessment-item-connected', this._onAssessmentItemConnected);\n this.addEventListener('item-show-correct-response', this._onHandleShowCorrectResponse);\n this.addEventListener('item-show-candidate-correction', this._onHandleShowCandidateCorrection);\n this.addEventListener('item-switch-correct-response-mode', this._onHandleSwitchCorrectResponseMode);\n }\n\n private _handleItemContextChanged(e: CustomEvent<{ itemContext: ItemContext }>) {\n this._updateItemVariablesInTestContext(e.detail.itemContext.identifier, e.detail?.itemContext?.variables || []);\n }\n\n private _handleAssessmentItemConnected(e: CustomEvent<QtiAssessmentItem>) {\n const fullVariables = (e.detail as any)._context.variables;\n this._qtiAssessmentItem = e.detail;\n this.computedContext =\n this.computedContext?.identifier === this._qtiAssessmentItem.identifier\n ? { ...this.computedContext, title: this._qtiAssessmentItem.title }\n : ({\n identifier: this._qtiAssessmentItem.identifier,\n title: this._qtiAssessmentItem.title,\n adaptive: this._qtiAssessmentItem.getAttribute('adaptive')?.toLowerCase() === 'true' || false,\n variables: fullVariables,\n correctResponseMode: 'internal'\n } as ComputedItemContext);\n this._updateItemVariablesInTestContext(this._qtiAssessmentItem.identifier, fullVariables || []);\n }\n\n private _handleShowCorrectResponse(e: CustomEvent<boolean>) {\n if (this._qtiAssessmentItem) {\n this._qtiAssessmentItem.showCorrectResponse(e.detail);\n }\n }\n\n private _handleShowCandidateCorrection(e: CustomEvent<boolean>) {\n if (this._qtiAssessmentItem) {\n this._qtiAssessmentItem.showCandidateCorrection(e.detail);\n }\n }\n\n private _handleSwitchCorrectResponseMode(e: CustomEvent<CorrectResponseMode>) {\n // Switch off the correct response first\n this._handleShowCorrectResponse(new CustomEvent('item-show-correct-response', { detail: false, bubbles: true }));\n\n this.configContext = {\n ...this.configContext,\n correctResponseMode: e.detail\n };\n }\n\n private _updateItemVariablesInTestContext(\n identifier: string,\n variables: readonly VariableDeclaration<string | string[] | null>[]\n ): void {\n const rawscore = variables?.find(vr => vr.identifier == 'SCORE')?.value;\n const score = parseFloat(rawscore?.toString());\n const completionStatus = variables?.find(v => v.identifier === 'completionStatus')?.value;\n\n const correct = score !== undefined && !isNaN(score) && score > 0;\n const incorrect = score !== undefined && !isNaN(score) && score <= 0;\n const completed = completionStatus === 'completed';\n this.computedContext = {\n ...this.computedContext,\n identifier,\n correct,\n incorrect,\n completed,\n variables\n };\n }\n\n override render() {\n return html`<slot></slot>`;\n }\n\n override disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('qti-item-context-changed', this._onItemContextChanged);\n this.removeEventListener('qti-assessment-item-connected', this._onAssessmentItemConnected);\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'qti-item': QtiItem;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAuBO,IAAM,gBAAN,cAA4BA,GAAW;AAAA,EAAvC;AAAA;AAGL,mBAAkB;AAIlB,mBAA4B;AAI5B,mBAAkB;AAGlB;AAAA,SAAQ,kBAA2B;AAAA;AAAA,EAGnC,MAAgB,sBAAsB;AACpC,QAAI,CAAC,KAAK,QAAS;AACnB,QAAI;AACF,YAAM,MAAM,MAAM,iBAAiB,EAAE,KAAK,KAAK,OAAO;AACtD,WAAK,UAAU,IAAI,QAAQ;AAAA,IAC7B,SAAS,OAAO;AACd,cAAQ,MAAM,iCAAiC,KAAK;AAAA,IACtD;AAAA,EACF;AAAA,EAGU,sBAAsB;AAC9B,QAAI,CAAC,KAAK,QAAS;AACnB,QAAI;AACF,WAAK,UAAU,iBAAiB,EAAE,MAAM,KAAK,OAAO,E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