@pie-qti/item-player 0.1.22 → 0.1.23
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/README.md +22 -0
- package/dist/core/Player.d.ts +22 -3
- package/dist/core/Player.js +32 -8
- package/dist/core/Player.js.map +1 -1
- package/dist/{element-class-DWoLXp_r.js → element-class-DBV-1lkb.js} +82 -56
- package/dist/element-class-DBV-1lkb.js.map +1 -0
- package/dist/element-class.js +1 -1
- package/dist/element.js +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/pci/PciHost.d.ts +61 -2
- package/dist/pci/PciHost.js +100 -3
- package/dist/pci/PciHost.js.map +1 -1
- package/dist/pci/allowlistResolver.d.ts +45 -0
- package/dist/pci/allowlistResolver.js +72 -0
- package/dist/pci/allowlistResolver.js.map +1 -0
- package/dist/pci/index.d.ts +2 -0
- package/dist/pci/index.js +1 -0
- package/dist/pci/index.js.map +1 -1
- package/dist/pci/types.d.ts +22 -1
- package/dist/pci/types.js.map +1 -1
- package/package.json +6 -6
- package/dist/element-class-DWoLXp_r.js.map +0 -1
|
@@ -2,7 +2,7 @@ import { Qti2xAttributeNameMapper as e, Qti2xElementNameMapper as t, Qti3Attribu
|
|
|
2
2
|
import { parse as s } from "node-html-parser";
|
|
3
3
|
import { decodeXmlAttribute as c, isBlockedStylesheetCss as l, normalizeCssForPolicy as u, normalizeHeuristicsConfig as d, parseSrcsetCandidates as f } from "@pie-qti/ims-cp-core";
|
|
4
4
|
import { DeclarationContext as p, OperatorRegistry as m, buildOutcomeProcessingAst as h, buildResponseProcessingAst as g, buildTemplateProcessingAst as _, childElements as v, coerceBaseValue as y, evalExpr as b, execProgram as ee, findAssessmentItem as x, findDescendants as S, findFirstDescendant as te, getAttr as C, parseXml as ne, qtiNull as re, qtiValue as w, serializeXml as ie, toBoolean as ae, toNumber as oe, toStringValue as se } from "@pie-qti/qti-processing";
|
|
5
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
5
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/shared/utils.js
|
|
6
6
|
var ce = Array.isArray, le = Array.prototype.indexOf, ue = Array.prototype.includes, de = Array.from, fe = Object.defineProperty, pe = Object.getOwnPropertyDescriptor, me = Object.getOwnPropertyDescriptors, he = Object.prototype, ge = Array.prototype, _e = Object.getPrototypeOf, ve = Object.isExtensible, ye = () => {};
|
|
7
7
|
function be(e) {
|
|
8
8
|
for (var t = 0; t < e.length; t++) e[t]();
|
|
@@ -56,14 +56,14 @@ function Te(e, t, n) {
|
|
|
56
56
|
}) : e[t] = n, e;
|
|
57
57
|
}
|
|
58
58
|
//#endregion
|
|
59
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
59
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/constants.js
|
|
60
60
|
var Ee = 1 << 24, De = 1024, Oe = 2048, ke = 4096, Ae = 8192, je = 16384, Me = 32768, Ne = 1 << 25, Pe = 65536, Fe = 1 << 19, Ie = 1 << 20, Le = 1 << 25, Re = 65536, ze = 1 << 21, Be = 1 << 22, Ve = 1 << 23, He = Symbol("$state"), Ue = Symbol("legacy props"), We = Symbol(""), Ge = Symbol("attributes"), Ke = Symbol("class"), qe = Symbol("style"), Je = Symbol("text"), Ye = Symbol("form reset"), Xe = new class extends Error {
|
|
61
61
|
constructor(...e) {
|
|
62
62
|
super(...e), Te(this, "name", "StaleReactionError"), Te(this, "message", "The reaction that called `getAbortSignal()` was re-run or destroyed");
|
|
63
63
|
}
|
|
64
64
|
}(), Ze = !!globalThis.document?.contentType && /* @__PURE__ */ globalThis.document.contentType.includes("xml");
|
|
65
65
|
//#endregion
|
|
66
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
66
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/errors.js
|
|
67
67
|
function Qe() {
|
|
68
68
|
throw Error("https://svelte.dev/e/async_derived_orphan");
|
|
69
69
|
}
|
|
@@ -98,7 +98,7 @@ function ct() {
|
|
|
98
98
|
throw Error("https://svelte.dev/e/svelte_boundary_reset_onerror");
|
|
99
99
|
}
|
|
100
100
|
//#endregion
|
|
101
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
101
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/constants.js
|
|
102
102
|
var lt = {}, T = Symbol("uninitialized"), ut = "http://www.w3.org/2000/svg", dt = "http://www.w3.org/1998/Math/MathML";
|
|
103
103
|
function ft() {
|
|
104
104
|
console.warn("https://svelte.dev/e/derived_inert");
|
|
@@ -113,7 +113,7 @@ function ht() {
|
|
|
113
113
|
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
114
114
|
}
|
|
115
115
|
//#endregion
|
|
116
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
116
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/hydration.js
|
|
117
117
|
var E = !1;
|
|
118
118
|
function gt(e) {
|
|
119
119
|
E = e;
|
|
@@ -156,7 +156,7 @@ function bt(e) {
|
|
|
156
156
|
return e.data;
|
|
157
157
|
}
|
|
158
158
|
//#endregion
|
|
159
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
159
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/equality.js
|
|
160
160
|
function xt(e) {
|
|
161
161
|
return e === this.v;
|
|
162
162
|
}
|
|
@@ -167,7 +167,7 @@ function Ct(e) {
|
|
|
167
167
|
return !St(e, this.v);
|
|
168
168
|
}
|
|
169
169
|
//#endregion
|
|
170
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
170
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/context.js
|
|
171
171
|
var wt = null;
|
|
172
172
|
function Tt(e) {
|
|
173
173
|
wt = e;
|
|
@@ -196,7 +196,7 @@ function Ot() {
|
|
|
196
196
|
return !0;
|
|
197
197
|
}
|
|
198
198
|
//#endregion
|
|
199
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
199
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/task.js
|
|
200
200
|
var kt = [];
|
|
201
201
|
function At() {
|
|
202
202
|
var e = kt;
|
|
@@ -235,7 +235,7 @@ function Nt(e, t) {
|
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
237
|
//#endregion
|
|
238
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
238
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/status.js
|
|
239
239
|
var Pt = ~(Oe | ke | De);
|
|
240
240
|
function A(e, t) {
|
|
241
241
|
e.f = e.f & Pt | t;
|
|
@@ -244,7 +244,7 @@ function Ft(e) {
|
|
|
244
244
|
e.f & 512 || e.deps === null ? A(e, De) : A(e, ke);
|
|
245
245
|
}
|
|
246
246
|
//#endregion
|
|
247
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
247
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/utils.js
|
|
248
248
|
function It(e) {
|
|
249
249
|
if (e !== null) for (let t of e) !(t.f & 2) || !(t.f & 65536) || (t.f ^= Re, It(t.deps));
|
|
250
250
|
}
|
|
@@ -252,7 +252,7 @@ function Lt(e, t, n) {
|
|
|
252
252
|
e.f & 2048 ? t.add(e) : e.f & 4096 && n.add(e), It(e.deps), A(e, De);
|
|
253
253
|
}
|
|
254
254
|
//#endregion
|
|
255
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
255
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/store.js
|
|
256
256
|
var Rt = !1;
|
|
257
257
|
function zt(e) {
|
|
258
258
|
var t = Rt;
|
|
@@ -263,7 +263,7 @@ function zt(e) {
|
|
|
263
263
|
}
|
|
264
264
|
}
|
|
265
265
|
//#endregion
|
|
266
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
266
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/misc.js
|
|
267
267
|
function Bt(e, t) {
|
|
268
268
|
if (t) {
|
|
269
269
|
let t = document.body;
|
|
@@ -281,7 +281,7 @@ function Ht() {
|
|
|
281
281
|
}, { capture: !0 }));
|
|
282
282
|
}
|
|
283
283
|
//#endregion
|
|
284
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
284
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/bindings/shared.js
|
|
285
285
|
function Ut(e) {
|
|
286
286
|
var t = W, n = G;
|
|
287
287
|
Si(null), Ci(null);
|
|
@@ -292,7 +292,7 @@ function Ut(e) {
|
|
|
292
292
|
}
|
|
293
293
|
}
|
|
294
294
|
//#endregion
|
|
295
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
295
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/reactivity/create-subscriber.js
|
|
296
296
|
function Wt(e) {
|
|
297
297
|
let t = 0, n = wr(0), r;
|
|
298
298
|
return () => {
|
|
@@ -335,7 +335,7 @@ function P(e, t) {
|
|
|
335
335
|
return e.get(M(e, t));
|
|
336
336
|
}
|
|
337
337
|
//#endregion
|
|
338
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
338
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/blocks/boundary.js
|
|
339
339
|
var qt = Pe | Fe;
|
|
340
340
|
function Jt(e, t, n, r) {
|
|
341
341
|
new fn(e, t, n, r);
|
|
@@ -496,7 +496,7 @@ function xn(e) {
|
|
|
496
496
|
});
|
|
497
497
|
}
|
|
498
498
|
//#endregion
|
|
499
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
499
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/async.js
|
|
500
500
|
function Sn(e, t, n, r) {
|
|
501
501
|
let i = Ot() ? En : kn;
|
|
502
502
|
var a = e.filter((e) => !e.settled), o = t.map(i);
|
|
@@ -645,7 +645,7 @@ function Pn(e) {
|
|
|
645
645
|
if (e.effects !== null) for (let t of e.effects) t.teardown && t.fn !== null && Bi(t);
|
|
646
646
|
}
|
|
647
647
|
//#endregion
|
|
648
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
648
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/batch.js
|
|
649
649
|
var Fn, In = null, L = null, Ln = null, Rn = null, zn = null, Bn = !1, Vn = !1, Hn = null, Un = null, Wn = 0, Gn = 1, Kn = /* @__PURE__ */ new WeakMap(), qn = /* @__PURE__ */ new WeakMap(), Jn = /* @__PURE__ */ new WeakMap(), Yn = /* @__PURE__ */ new WeakMap(), Xn = /* @__PURE__ */ new WeakMap(), Zn = /* @__PURE__ */ new WeakMap(), Qn = /* @__PURE__ */ new WeakMap(), $n = /* @__PURE__ */ new WeakMap(), er = /* @__PURE__ */ new WeakMap(), tr = /* @__PURE__ */ new WeakMap(), nr = /* @__PURE__ */ new WeakMap(), rr = /* @__PURE__ */ new WeakMap(), ir = /* @__PURE__ */ new WeakMap(), ar = /* @__PURE__ */ new WeakMap(), or = /* @__PURE__ */ new WeakMap(), R = /* @__PURE__ */ new WeakSet(), sr = class e {
|
|
650
650
|
constructor() {
|
|
651
651
|
Kt(this, R), Te(this, "id", Gn++), j(this, Kn, !1), Te(this, "linked", !0), j(this, qn, null), j(this, Jn, null), Te(this, "async_deriveds", /* @__PURE__ */ new Map()), Te(this, "current", /* @__PURE__ */ new Map()), Te(this, "previous", /* @__PURE__ */ new Map()), j(this, Yn, /* @__PURE__ */ new Set()), j(this, Xn, /* @__PURE__ */ new Set()), j(this, Zn, 0), j(this, Qn, /* @__PURE__ */ new Map()), j(this, $n, null), j(this, er, []), j(this, tr, []), j(this, nr, /* @__PURE__ */ new Set()), j(this, rr, /* @__PURE__ */ new Set()), j(this, ir, /* @__PURE__ */ new Map()), j(this, ar, /* @__PURE__ */ new Set()), Te(this, "is_fork", !1), j(this, or, !1), In === null ? In = this : (N(Jn, In, this), N(qn, this, In)), In = this;
|
|
@@ -907,7 +907,7 @@ function br(e) {
|
|
|
907
907
|
for (var t = e.first; t !== null;) br(t), t = t.next;
|
|
908
908
|
}
|
|
909
909
|
//#endregion
|
|
910
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
910
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/sources.js
|
|
911
911
|
var xr = /* @__PURE__ */ new Set(), Sr = /* @__PURE__ */ new Map(), Cr = !1;
|
|
912
912
|
function wr(e, t) {
|
|
913
913
|
return {
|
|
@@ -1154,7 +1154,7 @@ function Kr(e) {
|
|
|
1154
1154
|
for (; t !== null && t.nodeType === 3;) t.remove(), e.nodeValue += t.nodeValue, t = e.nextSibling;
|
|
1155
1155
|
}
|
|
1156
1156
|
//#endregion
|
|
1157
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1157
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/effects.js
|
|
1158
1158
|
function qr(e) {
|
|
1159
1159
|
G === null && (W === null && nt(e), tt()), yi && et(e);
|
|
1160
1160
|
}
|
|
@@ -1345,7 +1345,7 @@ function gi(e, t) {
|
|
|
1345
1345
|
}
|
|
1346
1346
|
}
|
|
1347
1347
|
//#endregion
|
|
1348
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1348
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/legacy.js
|
|
1349
1349
|
var _i = null, vi = !1, yi = !1;
|
|
1350
1350
|
function bi(e) {
|
|
1351
1351
|
yi = e;
|
|
@@ -1592,7 +1592,7 @@ function ta(e) {
|
|
|
1592
1592
|
return ea.includes(e);
|
|
1593
1593
|
}
|
|
1594
1594
|
//#endregion
|
|
1595
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1595
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dev/css.js
|
|
1596
1596
|
var na = Symbol("events"), ra = /* @__PURE__ */ new Set(), ia = /* @__PURE__ */ new Set();
|
|
1597
1597
|
function aa(e, t, n, r = {}) {
|
|
1598
1598
|
function i(e) {
|
|
@@ -1665,7 +1665,7 @@ function ua(e) {
|
|
|
1665
1665
|
}
|
|
1666
1666
|
}
|
|
1667
1667
|
//#endregion
|
|
1668
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1668
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/reconciler.js
|
|
1669
1669
|
var da = globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", { createHTML: (e) => e });
|
|
1670
1670
|
function fa(e) {
|
|
1671
1671
|
return da?.createHTML(e) ?? e;
|
|
@@ -1675,7 +1675,7 @@ function pa(e) {
|
|
|
1675
1675
|
return t.innerHTML = fa(e.replaceAll("<!>", "<!---->")), t.content;
|
|
1676
1676
|
}
|
|
1677
1677
|
//#endregion
|
|
1678
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1678
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/template.js
|
|
1679
1679
|
function ma(e, t) {
|
|
1680
1680
|
var n = G;
|
|
1681
1681
|
n.nodes === null && (n.nodes = {
|
|
@@ -1769,7 +1769,7 @@ function Sa(e, t) {
|
|
|
1769
1769
|
return n ? (xa.delete(e), n(t)) : Promise.resolve();
|
|
1770
1770
|
}
|
|
1771
1771
|
//#endregion
|
|
1772
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1772
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/blocks/branches.js
|
|
1773
1773
|
var Ca = /* @__PURE__ */ new WeakMap(), wa = /* @__PURE__ */ new WeakMap(), Ta = /* @__PURE__ */ new WeakMap(), Ea = /* @__PURE__ */ new WeakMap(), Da = /* @__PURE__ */ new WeakMap(), Oa = /* @__PURE__ */ new WeakMap(), ka = /* @__PURE__ */ new WeakMap(), Aa = class {
|
|
1774
1774
|
constructor(e, t = !0) {
|
|
1775
1775
|
Te(this, "anchor", void 0), j(this, Ca, /* @__PURE__ */ new Map()), j(this, wa, /* @__PURE__ */ new Map()), j(this, Ta, /* @__PURE__ */ new Map()), j(this, Ea, /* @__PURE__ */ new Set()), j(this, Da, !0), j(this, Oa, (e) => {
|
|
@@ -1825,7 +1825,7 @@ var Ca = /* @__PURE__ */ new WeakMap(), wa = /* @__PURE__ */ new WeakMap(), Ta =
|
|
|
1825
1825
|
}
|
|
1826
1826
|
};
|
|
1827
1827
|
//#endregion
|
|
1828
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1828
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/blocks/if.js
|
|
1829
1829
|
function ja(e, t, n = !1) {
|
|
1830
1830
|
var r;
|
|
1831
1831
|
E && (r = D, _t());
|
|
@@ -1849,7 +1849,7 @@ function ja(e, t, n = !1) {
|
|
|
1849
1849
|
}, a);
|
|
1850
1850
|
}
|
|
1851
1851
|
//#endregion
|
|
1852
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
1852
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/blocks/each.js
|
|
1853
1853
|
function Ma(e, t) {
|
|
1854
1854
|
return t;
|
|
1855
1855
|
}
|
|
@@ -1866,7 +1866,7 @@ function Na(e, t, n) {
|
|
|
1866
1866
|
}, !1);
|
|
1867
1867
|
}
|
|
1868
1868
|
if (o === 0) {
|
|
1869
|
-
var c = r.length === 0 && n !== null;
|
|
1869
|
+
var c = r.length === 0 && n !== null && e.pending.size === 0;
|
|
1870
1870
|
if (c) {
|
|
1871
1871
|
var l = n, u = l.parentNode;
|
|
1872
1872
|
Ur(u), u.append(l), e.items.clear();
|
|
@@ -2043,7 +2043,7 @@ function Ha(e, t, n = !1, r = !1, i = !1, a = !1) {
|
|
|
2043
2043
|
});
|
|
2044
2044
|
}
|
|
2045
2045
|
//#endregion
|
|
2046
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2046
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/blocks/svelte-element.js
|
|
2047
2047
|
function Ua(e, t, n, r, i, a) {
|
|
2048
2048
|
let o = E;
|
|
2049
2049
|
E && _t();
|
|
@@ -2072,7 +2072,7 @@ function Ua(e, t, n, r, i, a) {
|
|
|
2072
2072
|
}, Pe), Zr(() => {}), o && (gt(!0), O(c));
|
|
2073
2073
|
}
|
|
2074
2074
|
//#endregion
|
|
2075
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2075
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/css.js
|
|
2076
2076
|
function Wa(e, t) {
|
|
2077
2077
|
ti(() => {
|
|
2078
2078
|
var n = e.getRootNode(), r = n.host ? n : n.head ?? n.ownerDocument.head;
|
|
@@ -2083,7 +2083,7 @@ function Wa(e, t) {
|
|
|
2083
2083
|
});
|
|
2084
2084
|
}
|
|
2085
2085
|
//#endregion
|
|
2086
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2086
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/actions.js
|
|
2087
2087
|
function Ga(e, t, n) {
|
|
2088
2088
|
ti(() => {
|
|
2089
2089
|
var r = Ui(() => t(e, n?.()) || {});
|
|
@@ -2098,7 +2098,7 @@ function Ga(e, t, n) {
|
|
|
2098
2098
|
});
|
|
2099
2099
|
}
|
|
2100
2100
|
//#endregion
|
|
2101
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2101
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/attachments.js
|
|
2102
2102
|
function Ka(e, t) {
|
|
2103
2103
|
var n = void 0, r;
|
|
2104
2104
|
ai(() => {
|
|
@@ -2125,7 +2125,7 @@ function Ja() {
|
|
|
2125
2125
|
return r;
|
|
2126
2126
|
}
|
|
2127
2127
|
//#endregion
|
|
2128
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2128
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/shared/attributes.js
|
|
2129
2129
|
function Ya(e) {
|
|
2130
2130
|
return typeof e == "object" ? Ja(e) : e ?? "";
|
|
2131
2131
|
}
|
|
@@ -2184,7 +2184,7 @@ function eo(e, t) {
|
|
|
2184
2184
|
return e == null ? null : String(e);
|
|
2185
2185
|
}
|
|
2186
2186
|
//#endregion
|
|
2187
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2187
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/class.js
|
|
2188
2188
|
function to(e, t, n, r, i, a) {
|
|
2189
2189
|
var o = e[Ke];
|
|
2190
2190
|
if (E || o !== n || o === void 0) {
|
|
@@ -2197,7 +2197,7 @@ function to(e, t, n, r, i, a) {
|
|
|
2197
2197
|
return a;
|
|
2198
2198
|
}
|
|
2199
2199
|
//#endregion
|
|
2200
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2200
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/style.js
|
|
2201
2201
|
function no(e, t = {}, n, r) {
|
|
2202
2202
|
for (var i in n) {
|
|
2203
2203
|
var a = n[i];
|
|
@@ -2213,7 +2213,7 @@ function ro(e, t, n, r) {
|
|
|
2213
2213
|
return r;
|
|
2214
2214
|
}
|
|
2215
2215
|
//#endregion
|
|
2216
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2216
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/bindings/select.js
|
|
2217
2217
|
function io(e, t, n = !1) {
|
|
2218
2218
|
if (e.multiple) {
|
|
2219
2219
|
if (t == null) return;
|
|
@@ -2244,7 +2244,7 @@ function oo(e) {
|
|
|
2244
2244
|
return "__value" in e ? e.__value : e.value;
|
|
2245
2245
|
}
|
|
2246
2246
|
//#endregion
|
|
2247
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2247
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/attributes.js
|
|
2248
2248
|
var so = Symbol("class"), co = Symbol("style"), lo = Symbol("is custom element"), uo = Symbol("is html"), fo = Ze ? "link" : "LINK", po = Ze ? "input" : "INPUT", mo = Ze ? "option" : "OPTION", ho = Ze ? "select" : "SELECT", go = Ze ? "progress" : "PROGRESS";
|
|
2249
2249
|
function _o(e) {
|
|
2250
2250
|
if (E) {
|
|
@@ -2388,7 +2388,7 @@ function wo(e) {
|
|
|
2388
2388
|
return n;
|
|
2389
2389
|
}
|
|
2390
2390
|
//#endregion
|
|
2391
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2391
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/bindings/size.js
|
|
2392
2392
|
var To, Eo = /* @__PURE__ */ new WeakMap(), Do = /* @__PURE__ */ new WeakMap(), Oo = /* @__PURE__ */ new WeakMap(), ko = /* @__PURE__ */ new WeakSet(), Ao = class {
|
|
2393
2393
|
constructor(e) {
|
|
2394
2394
|
Kt(this, ko), j(this, Eo, /* @__PURE__ */ new WeakMap()), j(this, Do, void 0), j(this, Oo, void 0), N(Oo, this, e);
|
|
@@ -2412,7 +2412,7 @@ function jo() {
|
|
|
2412
2412
|
}
|
|
2413
2413
|
Te(Ao, "entries", /* @__PURE__ */ new WeakMap());
|
|
2414
2414
|
//#endregion
|
|
2415
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2415
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/dom/elements/bindings/this.js
|
|
2416
2416
|
function Mo(e, t) {
|
|
2417
2417
|
return e === t || e?.[He] === t;
|
|
2418
2418
|
}
|
|
@@ -2437,7 +2437,7 @@ function No(e = {}, t, n, r) {
|
|
|
2437
2437
|
}), e;
|
|
2438
2438
|
}
|
|
2439
2439
|
//#endregion
|
|
2440
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2440
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/client/reactivity/props.js
|
|
2441
2441
|
function Po(e, t, n, r) {
|
|
2442
2442
|
var i = !0, a = !!(n & 8), o = !!(n & 16), s = r, c = !0, l = void 0, u = () => o && i ? (l ?? (l = /* @__PURE__ */ En(r)), K(l)) : (c && (c = !1, s = o ? Ui(r) : r), s);
|
|
2443
2443
|
let d;
|
|
@@ -2473,7 +2473,7 @@ function Po(e, t, n, r) {
|
|
|
2473
2473
|
});
|
|
2474
2474
|
}
|
|
2475
2475
|
//#endregion
|
|
2476
|
-
//#region ../../node_modules/.bun/svelte@5.56.
|
|
2476
|
+
//#region ../../node_modules/.bun/svelte@5.56.9/node_modules/svelte/src/internal/disclose-version.js
|
|
2477
2477
|
if (typeof window < "u") {
|
|
2478
2478
|
var Fo, Io;
|
|
2479
2479
|
((Fo = (Io = window).__svelte ?? (Io.__svelte = {})).v ?? (Fo.v = /* @__PURE__ */ new Set())).add("5");
|
|
@@ -5030,11 +5030,14 @@ var bl = class extends Error {
|
|
|
5030
5030
|
}
|
|
5031
5031
|
}, Sl = class {
|
|
5032
5032
|
constructor(e, t = {}) {
|
|
5033
|
-
this.module = null, this.destroyed = !1, this.loadGeneration = 0, this._response = null, this._hasResponse = !1, this._responseChangeListeners = /* @__PURE__ */ new Set(), this.data = e, this.baseUrl = typeof t == "string" ? t : t.baseUrl ?? "", this.moduleResolver = typeof t == "string" ? void 0 : t.moduleResolver;
|
|
5033
|
+
this.module = null, this.destroyed = !1, this.loadGeneration = 0, this._response = null, this._hasResponse = !1, this._moduleOwnsResponse = !1, this._restorePending = !1, this._responseChangeListeners = /* @__PURE__ */ new Set(), this._remountRequestListeners = /* @__PURE__ */ new Set(), this.data = e, this.baseUrl = typeof t == "string" ? t : t.baseUrl ?? "", this.moduleResolver = typeof t == "string" ? void 0 : t.moduleResolver;
|
|
5034
5034
|
}
|
|
5035
5035
|
onResponseChange(e) {
|
|
5036
5036
|
return this._responseChangeListeners.add(e), () => this._responseChangeListeners.delete(e);
|
|
5037
5037
|
}
|
|
5038
|
+
onRemountRequest(e) {
|
|
5039
|
+
return this._remountRequestListeners.add(e), () => this._remountRequestListeners.delete(e);
|
|
5040
|
+
}
|
|
5038
5041
|
async load() {
|
|
5039
5042
|
if (this.destroyed) throw Error("Cannot load a destroyed PciHost");
|
|
5040
5043
|
if (!this.moduleResolver) throw new bl(this.data.responseIdentifier, this.data.primaryPath);
|
|
@@ -5060,22 +5063,36 @@ var bl = class extends Error {
|
|
|
5060
5063
|
let t = {
|
|
5061
5064
|
onReady: () => {},
|
|
5062
5065
|
onResponseChange: (e) => {
|
|
5063
|
-
this._response = e, this._hasResponse = !0;
|
|
5066
|
+
this._response = e, this._hasResponse = !0, this._moduleOwnsResponse = !0, this._restorePending = !1;
|
|
5064
5067
|
for (let t of this._responseChangeListeners) t(this.data.responseIdentifier, e);
|
|
5065
5068
|
}
|
|
5066
5069
|
};
|
|
5067
5070
|
try {
|
|
5068
|
-
this.module.initialize(e, this.data.config, t), this._hasResponse && this.module.setResponse(this._response);
|
|
5071
|
+
this.module.initialize(e, this.data.config, t), this._hasResponse && this.module.setResponse(this._response), this._restorePending = !1;
|
|
5069
5072
|
} catch (e) {
|
|
5070
5073
|
let t = this.module;
|
|
5071
5074
|
throw this.module = null, t.destroy(), e;
|
|
5072
5075
|
}
|
|
5073
5076
|
}
|
|
5074
5077
|
getResponse() {
|
|
5075
|
-
return this.module ? this.module.getResponse() : this._response;
|
|
5078
|
+
return this._restorePending ? this._response : this.module ? this.module.getResponse() : this._response;
|
|
5079
|
+
}
|
|
5080
|
+
offerResponse(e) {
|
|
5081
|
+
return !this._moduleOwnsResponse && (this._response = e, this._hasResponse = !0, this.module && (this.module.setResponse(e), this._restorePending = !1), !0);
|
|
5082
|
+
}
|
|
5083
|
+
restore(e) {
|
|
5084
|
+
if (this._response = e, this._hasResponse = !0, this._moduleOwnsResponse = !1, this.module) {
|
|
5085
|
+
if (this._remountRequestListeners.size === 0) {
|
|
5086
|
+
this.module.setResponse(e);
|
|
5087
|
+
return;
|
|
5088
|
+
}
|
|
5089
|
+
this._restorePending = !0;
|
|
5090
|
+
for (let e of this._remountRequestListeners) e();
|
|
5091
|
+
}
|
|
5076
5092
|
}
|
|
5077
|
-
|
|
5078
|
-
this.
|
|
5093
|
+
async remount(e) {
|
|
5094
|
+
if (this.destroyed) throw Error("Cannot remount a destroyed PciHost");
|
|
5095
|
+
this.module?.destroy(), this.module = null, await this.load(), this.initialize(e);
|
|
5079
5096
|
}
|
|
5080
5097
|
disable() {
|
|
5081
5098
|
this.module?.disable();
|
|
@@ -5084,7 +5101,7 @@ var bl = class extends Error {
|
|
|
5084
5101
|
this.module?.enable();
|
|
5085
5102
|
}
|
|
5086
5103
|
destroy() {
|
|
5087
|
-
this.destroyed = !0, this.loadGeneration++, this.module?.destroy(), this.module = null, this._responseChangeListeners.clear();
|
|
5104
|
+
this.destroyed = !0, this.loadGeneration++, this.module?.destroy(), this.module = null, this._responseChangeListeners.clear(), this._remountRequestListeners.clear();
|
|
5088
5105
|
}
|
|
5089
5106
|
resolveModule(e, t, n) {
|
|
5090
5107
|
return Promise.resolve(this.moduleResolver(e, {
|
|
@@ -5109,7 +5126,7 @@ var bl = class extends Error {
|
|
|
5109
5126
|
adoptResolvedModule(e, t, n) {
|
|
5110
5127
|
let r = this.extractPciInterface(e, t);
|
|
5111
5128
|
if (!this.isCurrentLoad(n)) throw r.destroy(), Error("PciHost was destroyed before its module finished loading");
|
|
5112
|
-
this.module?.destroy(), this.module = r;
|
|
5129
|
+
this.module?.destroy(), this.module = r, this._moduleOwnsResponse = !1;
|
|
5113
5130
|
}
|
|
5114
5131
|
extractPciInterface(e, t) {
|
|
5115
5132
|
let n = e?.default ?? e?.getInstance?.() ?? e, r = [
|
|
@@ -5322,8 +5339,11 @@ var Al = class {
|
|
|
5322
5339
|
n && (n.value = this.coerceToDeclarationValue(n.baseType, n.cardinality, t, n.identifier));
|
|
5323
5340
|
}), this._pciHosts.set(e.responseIdentifier, t), t;
|
|
5324
5341
|
}
|
|
5325
|
-
|
|
5326
|
-
this._pciHosts.get(e)?.
|
|
5342
|
+
offerPciResponse(e, t) {
|
|
5343
|
+
this._pciHosts.get(e)?.offerResponse(t);
|
|
5344
|
+
}
|
|
5345
|
+
restorePciResponse(e, t) {
|
|
5346
|
+
this._pciHosts.get(e)?.restore(t);
|
|
5327
5347
|
}
|
|
5328
5348
|
syncPciDisabledState() {
|
|
5329
5349
|
let e = this.role !== "candidate";
|
|
@@ -5337,9 +5357,15 @@ var Al = class {
|
|
|
5337
5357
|
return this.decls;
|
|
5338
5358
|
}
|
|
5339
5359
|
setResponses(e) {
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5360
|
+
this.applyResponses(e, (e, t) => this.offerPciResponse(e, t));
|
|
5361
|
+
}
|
|
5362
|
+
restoreResponses(e) {
|
|
5363
|
+
this.applyResponses(e, (e, t) => this.restorePciResponse(e, t));
|
|
5364
|
+
}
|
|
5365
|
+
applyResponses(e, t) {
|
|
5366
|
+
for (let [n, r] of Object.entries(e)) {
|
|
5367
|
+
let e = this.decls[n];
|
|
5368
|
+
e && (e.value = this.coerceToDeclarationValue(e.baseType, e.cardinality, r, e.identifier), t(n, this.qtiValueToPublic(e.value)));
|
|
5343
5369
|
}
|
|
5344
5370
|
}
|
|
5345
5371
|
destroy() {
|
|
@@ -5479,7 +5505,7 @@ var Al = class {
|
|
|
5479
5505
|
for (let e of Object.values(this.decls)) e.__kind === "outcome" && e.identifier !== "numAttempts" && e.identifier !== "completionStatus" && e.identifier !== "duration" && this.ctx.resetToDefault(e.identifier);
|
|
5480
5506
|
}
|
|
5481
5507
|
resetResponsesToDefault() {
|
|
5482
|
-
for (let e of Object.values(this.decls)) e.__kind === "response" && (this.ctx.resetToDefault(e.identifier), this.
|
|
5508
|
+
for (let e of Object.values(this.decls)) e.__kind === "response" && (this.ctx.resetToDefault(e.identifier), this.restorePciResponse(e.identifier, e.value.kind === "value" ? e.value.value : null));
|
|
5483
5509
|
}
|
|
5484
5510
|
resetTemplatesToDefault() {
|
|
5485
5511
|
for (let e of Object.values(this.decls)) e.isTemplate && this.ctx.resetToDefault(e.identifier);
|
|
@@ -5923,7 +5949,7 @@ var Al = class {
|
|
|
5923
5949
|
applySerializedVariables(e) {
|
|
5924
5950
|
for (let t of Object.values(e)) {
|
|
5925
5951
|
let e = this.decls[t.identifier];
|
|
5926
|
-
e && (e.value = this.coerceToDeclarationValue(e.baseType, e.cardinality, t.value, e.identifier), e.__kind === "response" && this.
|
|
5952
|
+
e && (e.value = this.coerceToDeclarationValue(e.baseType, e.cardinality, t.value, e.identifier), e.__kind === "response" && this.restorePciResponse(e.identifier, this.qtiValueToPublic(e.value)));
|
|
5927
5953
|
}
|
|
5928
5954
|
}
|
|
5929
5955
|
serializeItemSession() {
|
|
@@ -7819,4 +7845,4 @@ function $() {
|
|
|
7819
7845
|
//#endregion
|
|
7820
7846
|
export { cf as t };
|
|
7821
7847
|
|
|
7822
|
-
//# sourceMappingURL=element-class-
|
|
7848
|
+
//# sourceMappingURL=element-class-DBV-1lkb.js.map
|