@citolab/qti-components 7.28.1 → 8.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. package/cdn/index.global.js +1 -1
  2. package/cdn/index.js +6316 -2710
  3. package/dist/base.d.ts +100 -15
  4. package/dist/base.js +27 -6
  5. package/dist/chunk-3AJOQCDU.js +11 -0
  6. package/dist/chunk-3AJOQCDU.js.map +1 -0
  7. package/dist/chunk-64XSIBGO.js +241 -0
  8. package/dist/chunk-64XSIBGO.js.map +1 -0
  9. package/dist/chunk-7HC5SMCU.js +102 -0
  10. package/dist/chunk-7HC5SMCU.js.map +1 -0
  11. package/dist/{chunk-SP6S2WMG.js → chunk-7V4HJFHW.js} +3 -3
  12. package/dist/{chunk-SP6S2WMG.js.map → chunk-7V4HJFHW.js.map} +1 -1
  13. package/dist/chunk-CAO4JRLY.js +11 -0
  14. package/dist/chunk-CAO4JRLY.js.map +1 -0
  15. package/dist/{chunk-MPC7LIPC.js → chunk-F4BNJWYN.js} +4264 -3647
  16. package/dist/chunk-F4BNJWYN.js.map +1 -0
  17. package/dist/{chunk-3XV26R5M.js → chunk-H3J7LFRO.js} +829 -1005
  18. package/dist/chunk-H3J7LFRO.js.map +1 -0
  19. package/dist/{chunk-3WBG257S.js → chunk-IJD53WY6.js} +96 -74
  20. package/dist/chunk-IJD53WY6.js.map +1 -0
  21. package/dist/chunk-LVBIQDPM.js +1374 -0
  22. package/dist/chunk-LVBIQDPM.js.map +1 -0
  23. package/dist/{chunk-REI3AMCZ.js → chunk-NA2N2WSG.js} +1303 -1193
  24. package/dist/chunk-NA2N2WSG.js.map +1 -0
  25. package/dist/chunk-QECOPVPO.js +294 -0
  26. package/dist/chunk-QECOPVPO.js.map +1 -0
  27. package/dist/{chunk-HFCZFWSH.js → chunk-RXGDQDOV.js} +1993 -1764
  28. package/dist/chunk-RXGDQDOV.js.map +1 -0
  29. package/dist/chunk-V5G7X53Y.js +11 -0
  30. package/dist/chunk-V5G7X53Y.js.map +1 -0
  31. package/dist/{chunk-WDO2TRFM.js → chunk-WVVMNF74.js} +851 -925
  32. package/dist/chunk-WVVMNF74.js.map +1 -0
  33. package/dist/{chunk-FLJAKWXL.js → chunk-X3E5HXG2.js} +2 -2
  34. package/dist/chunk-XU7HNT4F.js +1608 -0
  35. package/dist/chunk-XU7HNT4F.js.map +1 -0
  36. package/dist/{computed-item.context-DfsW_96S.d.ts → computed-item.types.d-BKZdSLLJ.d.ts} +2 -5
  37. package/dist/{computed.context-DHbxad0N.d.ts → computed.types.d-rKLSPvVG.d.ts} +2 -5
  38. package/dist/config.context.d-BvU9r-Mg.d.ts +91 -0
  39. package/dist/corrections.d.ts +432 -0
  40. package/dist/corrections.js +84 -0
  41. package/dist/elements.d.ts +8 -14
  42. package/dist/elements.js +6 -5
  43. package/dist/index.d.ts +51 -16
  44. package/dist/index.js +193 -76
  45. package/dist/interaction.d-D4MstYRz.d.ts +115 -0
  46. package/dist/interaction.interface.d-CvjHM2bi.d.ts +46 -0
  47. package/dist/interactions.d.ts +1206 -552
  48. package/dist/interactions.js +19 -15
  49. package/dist/item.css +4228 -1656
  50. package/dist/item.d.ts +13 -55
  51. package/dist/item.js +6 -11
  52. package/dist/{variables-CMYcDbyW.d.ts → item.types.d-QU7LljEK.d.ts} +13 -1
  53. package/dist/loader.d.ts +4 -4
  54. package/dist/loader.js +2 -3
  55. package/dist/processing.d.ts +6 -7
  56. package/dist/processing.js +2 -3
  57. package/dist/qti-components-jsx.d.ts +5348 -2709
  58. package/dist/qti-components-jsx.js +1 -0
  59. package/dist/qti-condition-expression.d-aMvBvpc6.d.ts +8 -0
  60. package/dist/{qti-condition-expression-Dam-RER6.d.ts → qti-expression.d-BietT_8b.d.ts} +14 -9
  61. package/dist/{qti-feedback-ChmXhZuf.d.ts → qti-feedback.d-DZbad0RN.d.ts} +1 -1
  62. package/dist/{qti-transform-test-DoZaWItm.d.ts → qti-transform-test.d-BL7GGFJj.d.ts} +2 -2
  63. package/dist/response.d-_8y4kjGP.d.ts +106 -0
  64. package/dist/test.d.ts +199 -39
  65. package/dist/test.js +34 -11
  66. package/dist/transformers.d.ts +1 -1
  67. package/dist/transformers.js +1 -2
  68. package/package.json +24 -17
  69. package/custom-elements.json +0 -43251
  70. package/dist/chunk-3WBG257S.js.map +0 -1
  71. package/dist/chunk-3XV26R5M.js.map +0 -1
  72. package/dist/chunk-AQ5RJFM6.js +0 -3673
  73. package/dist/chunk-AQ5RJFM6.js.map +0 -1
  74. package/dist/chunk-HFCZFWSH.js.map +0 -1
  75. package/dist/chunk-MPC7LIPC.js.map +0 -1
  76. package/dist/chunk-QXBXORM3.js +0 -27
  77. package/dist/chunk-REI3AMCZ.js.map +0 -1
  78. package/dist/chunk-RLTYVS2I.js +0 -530
  79. package/dist/chunk-RLTYVS2I.js.map +0 -1
  80. package/dist/chunk-WDO2TRFM.js.map +0 -1
  81. package/dist/config.context-BjZ2bZSY.d.ts +0 -42
  82. package/dist/interaction-Bgzlw7Iu.d.ts +0 -110
  83. package/dist/item.context-CkUeDcaO.d.ts +0 -15
  84. package/dist/test.context-CByZZjkR.d.ts +0 -15
  85. /package/dist/{chunk-FLJAKWXL.js.map → chunk-X3E5HXG2.js.map} +0 -0
  86. /package/dist/{chunk-QXBXORM3.js.map → corrections.js.map} +0 -0
  87. /package/dist/{qti-rule-base-ajOnfGXY.d.ts → qti-rule-base.d-ajOnfGXY.d.ts} +0 -0
  88. /package/dist/{qti.context-CejJMlfZ.d.ts → qti.context.d-CejJMlfZ.d.ts} +0 -0
@@ -1,28 +1,24 @@
1
- import {
2
- __decorateClass
3
- } from "./chunk-QXBXORM3.js";
4
-
5
1
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/context-request-event.js
6
2
  var s = class extends Event {
7
- constructor(s9, t7, e8, o8) {
8
- super("context-request", { bubbles: true, composed: true }), this.context = s9, this.contextTarget = t7, this.callback = e8, this.subscribe = o8 ?? false;
3
+ constructor(s7, t4, e7, o7) {
4
+ super("context-request", { bubbles: true, composed: true }), this.context = s7, this.contextTarget = t4, this.callback = e7, this.subscribe = o7 ?? false;
9
5
  }
10
6
  };
11
7
 
12
8
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/create-context.js
13
- function n(n8) {
14
- return n8;
9
+ function n(n6) {
10
+ return n6;
15
11
  }
16
12
 
17
13
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/controllers/context-consumer.js
18
14
  var s2 = class {
19
- constructor(t7, s9, i7, h5) {
20
- if (this.subscribe = false, this.provided = false, this.value = void 0, this.t = (t8, s10) => {
21
- this.unsubscribe && (this.unsubscribe !== s10 && (this.provided = false, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = t8, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = true, this.callback && this.callback(t8, s10)), this.unsubscribe = s10;
22
- }, this.host = t7, void 0 !== s9.context) {
23
- const t8 = s9;
24
- this.context = t8.context, this.callback = t8.callback, this.subscribe = t8.subscribe ?? false;
25
- } else this.context = s9, this.callback = i7, this.subscribe = h5 ?? false;
15
+ constructor(t4, s7, i5, h3) {
16
+ if (this.subscribe = false, this.provided = false, this.value = void 0, this.t = (t5, s8) => {
17
+ this.unsubscribe && (this.unsubscribe !== s8 && (this.provided = false, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = t5, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = true, this.callback && this.callback(t5, s8)), this.unsubscribe = s8;
18
+ }, this.host = t4, void 0 !== s7.context) {
19
+ const t5 = s7;
20
+ this.context = t5.context, this.callback = t5.callback, this.subscribe = t5.subscribe ?? false;
21
+ } else this.context = s7, this.callback = i5, this.subscribe = h3 ?? false;
26
22
  this.host.addController(this);
27
23
  }
28
24
  hostConnected() {
@@ -41,25 +37,25 @@ var s3 = class {
41
37
  get value() {
42
38
  return this.o;
43
39
  }
44
- set value(s9) {
45
- this.setValue(s9);
40
+ set value(s7) {
41
+ this.setValue(s7);
46
42
  }
47
- setValue(s9, t7 = false) {
48
- const i7 = t7 || !Object.is(s9, this.o);
49
- this.o = s9, i7 && this.updateObservers();
43
+ setValue(s7, t4 = false) {
44
+ const i5 = t4 || !Object.is(s7, this.o);
45
+ this.o = s7, i5 && this.updateObservers();
50
46
  }
51
- constructor(s9) {
47
+ constructor(s7) {
52
48
  this.subscriptions = /* @__PURE__ */ new Map(), this.updateObservers = () => {
53
- for (const [s10, { disposer: t7 }] of this.subscriptions) s10(this.o, t7);
54
- }, void 0 !== s9 && (this.value = s9);
49
+ for (const [s8, { disposer: t4 }] of this.subscriptions) s8(this.o, t4);
50
+ }, void 0 !== s7 && (this.value = s7);
55
51
  }
56
- addCallback(s9, t7, i7) {
57
- if (!i7) return void s9(this.value);
58
- this.subscriptions.has(s9) || this.subscriptions.set(s9, { disposer: () => {
59
- this.subscriptions.delete(s9);
60
- }, consumerHost: t7 });
61
- const { disposer: h5 } = this.subscriptions.get(s9);
62
- s9(this.value, h5);
52
+ addCallback(s7, t4, i5) {
53
+ if (!i5) return void s7(this.value);
54
+ this.subscriptions.has(s7) || this.subscriptions.set(s7, { disposer: () => {
55
+ this.subscriptions.delete(s7);
56
+ }, consumerHost: t4 });
57
+ const { disposer: h3 } = this.subscriptions.get(s7);
58
+ s7(this.value, h3);
63
59
  }
64
60
  clearCallbacks() {
65
61
  this.subscriptions.clear();
@@ -68,23 +64,23 @@ var s3 = class {
68
64
 
69
65
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/controllers/context-provider.js
70
66
  var e = class extends Event {
71
- constructor(t7, s9) {
72
- super("context-provider", { bubbles: true, composed: true }), this.context = t7, this.contextTarget = s9;
67
+ constructor(t4, s7) {
68
+ super("context-provider", { bubbles: true, composed: true }), this.context = t4, this.contextTarget = s7;
73
69
  }
74
70
  };
75
71
  var i = class extends s3 {
76
- constructor(s9, e8, i7) {
77
- super(void 0 !== e8.context ? e8.initialValue : i7), this.onContextRequest = (t7) => {
78
- if (t7.context !== this.context) return;
79
- const s10 = t7.contextTarget ?? t7.composedPath()[0];
80
- s10 !== this.host && (t7.stopPropagation(), this.addCallback(t7.callback, s10, t7.subscribe));
81
- }, this.onProviderRequest = (s10) => {
82
- if (s10.context !== this.context) return;
83
- if ((s10.contextTarget ?? s10.composedPath()[0]) === this.host) return;
84
- const e9 = /* @__PURE__ */ new Set();
85
- for (const [s11, { consumerHost: i8 }] of this.subscriptions) e9.has(s11) || (e9.add(s11), i8.dispatchEvent(new s(this.context, i8, s11, true)));
86
- s10.stopPropagation();
87
- }, this.host = s9, void 0 !== e8.context ? this.context = e8.context : this.context = e8, this.attachListeners(), this.host.addController?.(this);
72
+ constructor(s7, e7, i5) {
73
+ super(void 0 !== e7.context ? e7.initialValue : i5), this.onContextRequest = (t4) => {
74
+ if (t4.context !== this.context) return;
75
+ const s8 = t4.contextTarget ?? t4.composedPath()[0];
76
+ s8 !== this.host && (t4.stopPropagation(), this.addCallback(t4.callback, s8, t4.subscribe));
77
+ }, this.onProviderRequest = (s8) => {
78
+ if (s8.context !== this.context) return;
79
+ if ((s8.contextTarget ?? s8.composedPath()[0]) === this.host) return;
80
+ const e8 = /* @__PURE__ */ new Set();
81
+ for (const [s9, { consumerHost: i6 }] of this.subscriptions) e8.has(s9) || (e8.add(s9), i6.dispatchEvent(new s(this.context, i6, s9, true)));
82
+ s8.stopPropagation();
83
+ }, this.host = s7, void 0 !== e7.context ? this.context = e7.context : this.context = e7, this.attachListeners(), this.host.addController?.(this);
88
84
  }
89
85
  attachListeners() {
90
86
  this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
@@ -95,65 +91,71 @@ var i = class extends s3 {
95
91
  };
96
92
 
97
93
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/decorators/provide.js
98
- function e2({ context: e8 }) {
99
- return (n8, i7) => {
100
- const r8 = /* @__PURE__ */ new WeakMap();
101
- if ("object" == typeof i7) return { get() {
102
- return n8.get.call(this);
103
- }, set(t7) {
104
- return r8.get(this).setValue(t7), n8.set.call(this, t7);
105
- }, init(n9) {
106
- return r8.set(this, new i(this, { context: e8, initialValue: n9 })), n9;
94
+ function e2({ context: e7 }) {
95
+ return (n6, i5) => {
96
+ const r6 = /* @__PURE__ */ new WeakMap();
97
+ if ("object" == typeof i5) return { get() {
98
+ return n6.get.call(this);
99
+ }, set(t4) {
100
+ return r6.get(this).setValue(t4), n6.set.call(this, t4);
101
+ }, init(n7) {
102
+ return r6.set(this, new i(this, { context: e7, initialValue: n7 })), n7;
107
103
  } };
108
104
  {
109
- n8.constructor.addInitializer(((n9) => {
110
- r8.set(n9, new i(n9, { context: e8 }));
105
+ n6.constructor.addInitializer(((n7) => {
106
+ r6.set(n7, new i(n7, { context: e7 }));
111
107
  }));
112
- const o8 = Object.getOwnPropertyDescriptor(n8, i7);
113
- let s9;
114
- if (void 0 === o8) {
115
- const t7 = /* @__PURE__ */ new WeakMap();
116
- s9 = { get() {
117
- return t7.get(this);
118
- }, set(e9) {
119
- r8.get(this).setValue(e9), t7.set(this, e9);
108
+ const o7 = Object.getOwnPropertyDescriptor(n6, i5);
109
+ let s7;
110
+ if (void 0 === o7) {
111
+ const t4 = /* @__PURE__ */ new WeakMap();
112
+ s7 = { get() {
113
+ return t4.get(this);
114
+ }, set(e8) {
115
+ r6.get(this).setValue(e8), t4.set(this, e8);
120
116
  }, configurable: true, enumerable: true };
121
117
  } else {
122
- const t7 = o8.set;
123
- s9 = { ...o8, set(e9) {
124
- r8.get(this).setValue(e9), t7?.call(this, e9);
118
+ const t4 = o7.set;
119
+ s7 = { ...o7, set(e8) {
120
+ r6.get(this).setValue(e8), t4?.call(this, e8);
125
121
  } };
126
122
  }
127
- return void Object.defineProperty(n8, i7, s9);
123
+ return void Object.defineProperty(n6, i5, s7);
128
124
  }
129
125
  };
130
126
  }
131
127
 
132
128
  // ../../node_modules/.pnpm/@lit+context@1.1.6/node_modules/@lit/context/lib/decorators/consume.js
133
- function c({ context: c6, subscribe: e8 }) {
134
- return (o8, n8) => {
135
- "object" == typeof n8 ? n8.addInitializer((function() {
136
- new s2(this, { context: c6, callback: (t7) => {
137
- o8.set.call(this, t7);
138
- }, subscribe: e8 });
139
- })) : o8.constructor.addInitializer(((o9) => {
140
- new s2(o9, { context: c6, callback: (t7) => {
141
- o9[n8] = t7;
142
- }, subscribe: e8 });
129
+ function c({ context: c5, subscribe: e7 }) {
130
+ return (o7, n6) => {
131
+ "object" == typeof n6 ? n6.addInitializer((function() {
132
+ new s2(this, { context: c5, callback: (t4) => {
133
+ o7.set.call(this, t4);
134
+ }, subscribe: e7 });
135
+ })) : o7.constructor.addInitializer(((o8) => {
136
+ new s2(o8, { context: c5, callback: (t4) => {
137
+ o8[n6] = t4;
138
+ }, subscribe: e7 });
143
139
  }));
144
140
  };
145
141
  }
146
142
 
147
- // ../qti-base/src/context/computed-item.context.ts
143
+ // ../qti-base/dist/context/computed-item.context.js
148
144
  var computedItemContext = n(/* @__PURE__ */ Symbol("computedItemContext"));
149
145
 
150
- // ../qti-base/src/context/computed.context.ts
146
+ // ../qti-base/dist/context/computed.context.js
151
147
  var computedContext = n(/* @__PURE__ */ Symbol("computedContext"));
152
148
 
153
- // ../qti-base/src/context/config.context.ts
149
+ // ../qti-base/dist/context/config.context.js
154
150
  var configContext = n(/* @__PURE__ */ Symbol("configContext"));
155
151
 
156
- // ../qti-base/src/context/item.context.ts
152
+ // ../qti-base/dist/context/interaction.context.js
153
+ var interactionContext = n(/* @__PURE__ */ Symbol("interactionContext"));
154
+
155
+ // ../qti-base/dist/context/item.context.js
156
+ var itemContext = n(/* @__PURE__ */ Symbol("item"));
157
+
158
+ // ../qti-base/dist/context/types/item.types.js
157
159
  var itemContextVariables = [
158
160
  {
159
161
  identifier: "completionStatus",
@@ -171,30 +173,20 @@ var itemContextVariables = [
171
173
  }
172
174
  ];
173
175
 
174
- // ../qti-base/src/context/qti-assessment-item.context.ts
175
- var itemContext = n(/* @__PURE__ */ Symbol("item"));
176
-
177
- // ../qti-base/src/context/qti.context.ts
176
+ // ../qti-base/dist/context/qti.context.js
178
177
  var SEED_PATTERN = /^[A-Za-z0-9-]+$/;
179
178
  var isSeed = (value) => typeof value === "string" && SEED_PATTERN.test(value);
180
179
  var asSeed = (value) => isSeed(value) ? value : void 0;
181
180
  var qtiContext = n(/* @__PURE__ */ Symbol("qtiContext"));
182
181
 
183
- // ../qti-base/src/context/session.context.ts
182
+ // ../qti-base/dist/context/session.context.js
184
183
  var INITIAL_SESSION_CONTEXT = { view: "candidate" };
185
184
  var sessionContext = n(/* @__PURE__ */ Symbol("testContext"));
186
185
 
187
- // ../qti-base/src/context/test.context.ts
186
+ // ../qti-base/dist/context/test.context.js
188
187
  var INITIAL_TEST_CONTEXT = { items: [], testOutcomeVariables: [] };
189
188
  var testContext = n(/* @__PURE__ */ Symbol("testContext"));
190
189
 
191
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/custom-element.js
192
- var t2 = (t7) => (e8, o8) => {
193
- void 0 !== o8 ? o8.addInitializer(() => {
194
- customElements.define(t7, e8);
195
- }) : customElements.define(t7, e8);
196
- };
197
-
198
190
  // ../../node_modules/.pnpm/@lit-labs+ssr-dom-shim@1.5.1/node_modules/@lit-labs/ssr-dom-shim/lib/element-internals.js
199
191
  var ElementInternalsShim = class ElementInternals {
200
192
  get shadowRoot() {
@@ -275,16 +267,16 @@ var ElementInternalsShim = class ElementInternals {
275
267
  };
276
268
 
277
269
  // ../../node_modules/.pnpm/@lit-labs+ssr-dom-shim@1.5.1/node_modules/@lit-labs/ssr-dom-shim/lib/events.js
278
- var __classPrivateFieldSet = function(receiver, state, value, kind, f4) {
270
+ var __classPrivateFieldSet = function(receiver, state, value, kind, f3) {
279
271
  if (kind === "m") throw new TypeError("Private method is not writable");
280
- if (kind === "a" && !f4) throw new TypeError("Private accessor was defined without a setter");
281
- if (typeof state === "function" ? receiver !== state || !f4 : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
282
- return kind === "a" ? f4.call(receiver, value) : f4 ? f4.value = value : state.set(receiver, value), value;
272
+ if (kind === "a" && !f3) throw new TypeError("Private accessor was defined without a setter");
273
+ if (typeof state === "function" ? receiver !== state || !f3 : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
274
+ return kind === "a" ? f3.call(receiver, value) : f3 ? f3.value = value : state.set(receiver, value), value;
283
275
  };
284
- var __classPrivateFieldGet = function(receiver, state, kind, f4) {
285
- if (kind === "a" && !f4) throw new TypeError("Private accessor was defined without a getter");
286
- if (typeof state === "function" ? receiver !== state || !f4 : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
287
- return kind === "m" ? f4 : kind === "a" ? f4.call(receiver) : f4 ? f4.value : state.get(receiver);
276
+ var __classPrivateFieldGet = function(receiver, state, kind, f3) {
277
+ if (kind === "a" && !f3) throw new TypeError("Private accessor was defined without a getter");
278
+ if (typeof state === "function" ? receiver !== state || !f3 : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
279
+ return kind === "m" ? f3 : kind === "a" ? f3.call(receiver) : f3 ? f3.value : state.get(receiver);
288
280
  };
289
281
  var _Event_cancelable;
290
282
  var _Event_bubbles;
@@ -793,49 +785,49 @@ var CustomElementRegistryShimWithRealType = CustomElementRegistry;
793
785
  var customElements2 = new CustomElementRegistryShimWithRealType();
794
786
 
795
787
  // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/css-tag.js
796
- var t3 = globalThis;
797
- var e3 = t3.ShadowRoot && (void 0 === t3.ShadyCSS || t3.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype;
788
+ var t2 = globalThis;
789
+ var e3 = t2.ShadowRoot && (void 0 === t2.ShadyCSS || t2.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype;
798
790
  var s4 = /* @__PURE__ */ Symbol();
799
791
  var o = /* @__PURE__ */ new WeakMap();
800
792
  var n2 = class {
801
- constructor(t7, e8, o8) {
802
- if (this._$cssResult$ = true, o8 !== s4) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
803
- this.cssText = t7, this.t = e8;
793
+ constructor(t4, e7, o7) {
794
+ if (this._$cssResult$ = true, o7 !== s4) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
795
+ this.cssText = t4, this.t = e7;
804
796
  }
805
797
  get styleSheet() {
806
- let t7 = this.o;
807
- const s9 = this.t;
808
- if (e3 && void 0 === t7) {
809
- const e8 = void 0 !== s9 && 1 === s9.length;
810
- e8 && (t7 = o.get(s9)), void 0 === t7 && ((this.o = t7 = new CSSStyleSheet()).replaceSync(this.cssText), e8 && o.set(s9, t7));
798
+ let t4 = this.o;
799
+ const s7 = this.t;
800
+ if (e3 && void 0 === t4) {
801
+ const e7 = void 0 !== s7 && 1 === s7.length;
802
+ e7 && (t4 = o.get(s7)), void 0 === t4 && ((this.o = t4 = new CSSStyleSheet()).replaceSync(this.cssText), e7 && o.set(s7, t4));
811
803
  }
812
- return t7;
804
+ return t4;
813
805
  }
814
806
  toString() {
815
807
  return this.cssText;
816
808
  }
817
809
  };
818
- var r = (t7) => new n2("string" == typeof t7 ? t7 : t7 + "", void 0, s4);
819
- var i2 = (t7, ...e8) => {
820
- const o8 = 1 === t7.length ? t7[0] : e8.reduce((e9, s9, o9) => e9 + ((t8) => {
821
- if (true === t8._$cssResult$) return t8.cssText;
822
- if ("number" == typeof t8) return t8;
823
- throw Error("Value passed to 'css' function must be a 'css' function result: " + t8 + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
824
- })(s9) + t7[o9 + 1], t7[0]);
825
- return new n2(o8, t7, s4);
810
+ var r = (t4) => new n2("string" == typeof t4 ? t4 : t4 + "", void 0, s4);
811
+ var i2 = (t4, ...e7) => {
812
+ const o7 = 1 === t4.length ? t4[0] : e7.reduce((e8, s7, o8) => e8 + ((t5) => {
813
+ if (true === t5._$cssResult$) return t5.cssText;
814
+ if ("number" == typeof t5) return t5;
815
+ throw Error("Value passed to 'css' function must be a 'css' function result: " + t5 + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
816
+ })(s7) + t4[o8 + 1], t4[0]);
817
+ return new n2(o7, t4, s4);
826
818
  };
827
- var S = (s9, o8) => {
828
- if (e3) s9.adoptedStyleSheets = o8.map((t7) => t7 instanceof CSSStyleSheet ? t7 : t7.styleSheet);
829
- else for (const e8 of o8) {
830
- const o9 = document.createElement("style"), n8 = t3.litNonce;
831
- void 0 !== n8 && o9.setAttribute("nonce", n8), o9.textContent = e8.cssText, s9.appendChild(o9);
819
+ var S = (s7, o7) => {
820
+ if (e3) s7.adoptedStyleSheets = o7.map((t4) => t4 instanceof CSSStyleSheet ? t4 : t4.styleSheet);
821
+ else for (const e7 of o7) {
822
+ const o8 = document.createElement("style"), n6 = t2.litNonce;
823
+ void 0 !== n6 && o8.setAttribute("nonce", n6), o8.textContent = e7.cssText, s7.appendChild(o8);
832
824
  }
833
825
  };
834
- var c2 = e3 || void 0 === t3.CSSStyleSheet ? (t7) => t7 : (t7) => t7 instanceof CSSStyleSheet ? ((t8) => {
835
- let e8 = "";
836
- for (const s9 of t8.cssRules) e8 += s9.cssText;
837
- return r(e8);
838
- })(t7) : t7;
826
+ var c2 = e3 || void 0 === t2.CSSStyleSheet ? (t4) => t4 : (t4) => t4 instanceof CSSStyleSheet ? ((t5) => {
827
+ let e7 = "";
828
+ for (const s7 of t5.cssRules) e7 += s7.cssText;
829
+ return r(e7);
830
+ })(t4) : t4;
839
831
 
840
832
  // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/reactive-element.js
841
833
  var { is: h, defineProperty: r2, getOwnPropertyDescriptor: o2, getOwnPropertyNames: n3, getOwnPropertySymbols: a, getPrototypeOf: c3 } = Object;
@@ -844,169 +836,169 @@ l.customElements ??= customElements2;
844
836
  var p = l.trustedTypes;
845
837
  var d = p ? p.emptyScript : "";
846
838
  var u = l.reactiveElementPolyfillSupport;
847
- var f = (t7, s9) => t7;
848
- var b = { toAttribute(t7, s9) {
849
- switch (s9) {
839
+ var f = (t4, s7) => t4;
840
+ var b = { toAttribute(t4, s7) {
841
+ switch (s7) {
850
842
  case Boolean:
851
- t7 = t7 ? d : null;
843
+ t4 = t4 ? d : null;
852
844
  break;
853
845
  case Object:
854
846
  case Array:
855
- t7 = null == t7 ? t7 : JSON.stringify(t7);
847
+ t4 = null == t4 ? t4 : JSON.stringify(t4);
856
848
  }
857
- return t7;
858
- }, fromAttribute(t7, s9) {
859
- let i7 = t7;
860
- switch (s9) {
849
+ return t4;
850
+ }, fromAttribute(t4, s7) {
851
+ let i5 = t4;
852
+ switch (s7) {
861
853
  case Boolean:
862
- i7 = null !== t7;
854
+ i5 = null !== t4;
863
855
  break;
864
856
  case Number:
865
- i7 = null === t7 ? null : Number(t7);
857
+ i5 = null === t4 ? null : Number(t4);
866
858
  break;
867
859
  case Object:
868
860
  case Array:
869
861
  try {
870
- i7 = JSON.parse(t7);
871
- } catch (t8) {
872
- i7 = null;
862
+ i5 = JSON.parse(t4);
863
+ } catch (t5) {
864
+ i5 = null;
873
865
  }
874
866
  }
875
- return i7;
867
+ return i5;
876
868
  } };
877
- var m = (t7, s9) => !h(t7, s9);
869
+ var m = (t4, s7) => !h(t4, s7);
878
870
  var y = { attribute: true, type: String, converter: b, reflect: false, useDefault: false, hasChanged: m };
879
871
  Symbol.metadata ??= /* @__PURE__ */ Symbol("metadata"), l.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
880
872
  var g = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType) {
881
- static addInitializer(t7) {
882
- this._$Ei(), (this.l ??= []).push(t7);
873
+ static addInitializer(t4) {
874
+ this._$Ei(), (this.l ??= []).push(t4);
883
875
  }
884
876
  static get observedAttributes() {
885
877
  return this.finalize(), this._$Eh && [...this._$Eh.keys()];
886
878
  }
887
- static createProperty(t7, s9 = y) {
888
- if (s9.state && (s9.attribute = false), this._$Ei(), this.prototype.hasOwnProperty(t7) && ((s9 = Object.create(s9)).wrapped = true), this.elementProperties.set(t7, s9), !s9.noAccessor) {
889
- const i7 = /* @__PURE__ */ Symbol(), e8 = this.getPropertyDescriptor(t7, i7, s9);
890
- void 0 !== e8 && r2(this.prototype, t7, e8);
879
+ static createProperty(t4, s7 = y) {
880
+ if (s7.state && (s7.attribute = false), this._$Ei(), this.prototype.hasOwnProperty(t4) && ((s7 = Object.create(s7)).wrapped = true), this.elementProperties.set(t4, s7), !s7.noAccessor) {
881
+ const i5 = /* @__PURE__ */ Symbol(), e7 = this.getPropertyDescriptor(t4, i5, s7);
882
+ void 0 !== e7 && r2(this.prototype, t4, e7);
891
883
  }
892
884
  }
893
- static getPropertyDescriptor(t7, s9, i7) {
894
- const { get: e8, set: h5 } = o2(this.prototype, t7) ?? { get() {
895
- return this[s9];
896
- }, set(t8) {
897
- this[s9] = t8;
885
+ static getPropertyDescriptor(t4, s7, i5) {
886
+ const { get: e7, set: h3 } = o2(this.prototype, t4) ?? { get() {
887
+ return this[s7];
888
+ }, set(t5) {
889
+ this[s7] = t5;
898
890
  } };
899
- return { get: e8, set(s10) {
900
- const r8 = e8?.call(this);
901
- h5?.call(this, s10), this.requestUpdate(t7, r8, i7);
891
+ return { get: e7, set(s8) {
892
+ const r6 = e7?.call(this);
893
+ h3?.call(this, s8), this.requestUpdate(t4, r6, i5);
902
894
  }, configurable: true, enumerable: true };
903
895
  }
904
- static getPropertyOptions(t7) {
905
- return this.elementProperties.get(t7) ?? y;
896
+ static getPropertyOptions(t4) {
897
+ return this.elementProperties.get(t4) ?? y;
906
898
  }
907
899
  static _$Ei() {
908
900
  if (this.hasOwnProperty(f("elementProperties"))) return;
909
- const t7 = c3(this);
910
- t7.finalize(), void 0 !== t7.l && (this.l = [...t7.l]), this.elementProperties = new Map(t7.elementProperties);
901
+ const t4 = c3(this);
902
+ t4.finalize(), void 0 !== t4.l && (this.l = [...t4.l]), this.elementProperties = new Map(t4.elementProperties);
911
903
  }
912
904
  static finalize() {
913
905
  if (this.hasOwnProperty(f("finalized"))) return;
914
906
  if (this.finalized = true, this._$Ei(), this.hasOwnProperty(f("properties"))) {
915
- const t8 = this.properties, s9 = [...n3(t8), ...a(t8)];
916
- for (const i7 of s9) this.createProperty(i7, t8[i7]);
907
+ const t5 = this.properties, s7 = [...n3(t5), ...a(t5)];
908
+ for (const i5 of s7) this.createProperty(i5, t5[i5]);
917
909
  }
918
- const t7 = this[Symbol.metadata];
919
- if (null !== t7) {
920
- const s9 = litPropertyMetadata.get(t7);
921
- if (void 0 !== s9) for (const [t8, i7] of s9) this.elementProperties.set(t8, i7);
910
+ const t4 = this[Symbol.metadata];
911
+ if (null !== t4) {
912
+ const s7 = litPropertyMetadata.get(t4);
913
+ if (void 0 !== s7) for (const [t5, i5] of s7) this.elementProperties.set(t5, i5);
922
914
  }
923
915
  this._$Eh = /* @__PURE__ */ new Map();
924
- for (const [t8, s9] of this.elementProperties) {
925
- const i7 = this._$Eu(t8, s9);
926
- void 0 !== i7 && this._$Eh.set(i7, t8);
916
+ for (const [t5, s7] of this.elementProperties) {
917
+ const i5 = this._$Eu(t5, s7);
918
+ void 0 !== i5 && this._$Eh.set(i5, t5);
927
919
  }
928
920
  this.elementStyles = this.finalizeStyles(this.styles);
929
921
  }
930
- static finalizeStyles(t7) {
931
- const s9 = [];
932
- if (Array.isArray(t7)) {
933
- const e8 = new Set(t7.flat(1 / 0).reverse());
934
- for (const t8 of e8) s9.unshift(c2(t8));
935
- } else void 0 !== t7 && s9.push(c2(t7));
936
- return s9;
922
+ static finalizeStyles(t4) {
923
+ const s7 = [];
924
+ if (Array.isArray(t4)) {
925
+ const e7 = new Set(t4.flat(1 / 0).reverse());
926
+ for (const t5 of e7) s7.unshift(c2(t5));
927
+ } else void 0 !== t4 && s7.push(c2(t4));
928
+ return s7;
937
929
  }
938
- static _$Eu(t7, s9) {
939
- const i7 = s9.attribute;
940
- return false === i7 ? void 0 : "string" == typeof i7 ? i7 : "string" == typeof t7 ? t7.toLowerCase() : void 0;
930
+ static _$Eu(t4, s7) {
931
+ const i5 = s7.attribute;
932
+ return false === i5 ? void 0 : "string" == typeof i5 ? i5 : "string" == typeof t4 ? t4.toLowerCase() : void 0;
941
933
  }
942
934
  constructor() {
943
935
  super(), this._$Ep = void 0, this.isUpdatePending = false, this.hasUpdated = false, this._$Em = null, this._$Ev();
944
936
  }
945
937
  _$Ev() {
946
- this._$ES = new Promise((t7) => this.enableUpdating = t7), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t7) => t7(this));
938
+ this._$ES = new Promise((t4) => this.enableUpdating = t4), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t4) => t4(this));
947
939
  }
948
- addController(t7) {
949
- (this._$EO ??= /* @__PURE__ */ new Set()).add(t7), void 0 !== this.renderRoot && this.isConnected && t7.hostConnected?.();
940
+ addController(t4) {
941
+ (this._$EO ??= /* @__PURE__ */ new Set()).add(t4), void 0 !== this.renderRoot && this.isConnected && t4.hostConnected?.();
950
942
  }
951
- removeController(t7) {
952
- this._$EO?.delete(t7);
943
+ removeController(t4) {
944
+ this._$EO?.delete(t4);
953
945
  }
954
946
  _$E_() {
955
- const t7 = /* @__PURE__ */ new Map(), s9 = this.constructor.elementProperties;
956
- for (const i7 of s9.keys()) this.hasOwnProperty(i7) && (t7.set(i7, this[i7]), delete this[i7]);
957
- t7.size > 0 && (this._$Ep = t7);
947
+ const t4 = /* @__PURE__ */ new Map(), s7 = this.constructor.elementProperties;
948
+ for (const i5 of s7.keys()) this.hasOwnProperty(i5) && (t4.set(i5, this[i5]), delete this[i5]);
949
+ t4.size > 0 && (this._$Ep = t4);
958
950
  }
959
951
  createRenderRoot() {
960
- const t7 = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
961
- return S(t7, this.constructor.elementStyles), t7;
952
+ const t4 = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
953
+ return S(t4, this.constructor.elementStyles), t4;
962
954
  }
963
955
  connectedCallback() {
964
- this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(true), this._$EO?.forEach((t7) => t7.hostConnected?.());
956
+ this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(true), this._$EO?.forEach((t4) => t4.hostConnected?.());
965
957
  }
966
- enableUpdating(t7) {
958
+ enableUpdating(t4) {
967
959
  }
968
960
  disconnectedCallback() {
969
- this._$EO?.forEach((t7) => t7.hostDisconnected?.());
961
+ this._$EO?.forEach((t4) => t4.hostDisconnected?.());
970
962
  }
971
- attributeChangedCallback(t7, s9, i7) {
972
- this._$AK(t7, i7);
963
+ attributeChangedCallback(t4, s7, i5) {
964
+ this._$AK(t4, i5);
973
965
  }
974
- _$ET(t7, s9) {
975
- const i7 = this.constructor.elementProperties.get(t7), e8 = this.constructor._$Eu(t7, i7);
976
- if (void 0 !== e8 && true === i7.reflect) {
977
- const h5 = (void 0 !== i7.converter?.toAttribute ? i7.converter : b).toAttribute(s9, i7.type);
978
- this._$Em = t7, null == h5 ? this.removeAttribute(e8) : this.setAttribute(e8, h5), this._$Em = null;
966
+ _$ET(t4, s7) {
967
+ const i5 = this.constructor.elementProperties.get(t4), e7 = this.constructor._$Eu(t4, i5);
968
+ if (void 0 !== e7 && true === i5.reflect) {
969
+ const h3 = (void 0 !== i5.converter?.toAttribute ? i5.converter : b).toAttribute(s7, i5.type);
970
+ this._$Em = t4, null == h3 ? this.removeAttribute(e7) : this.setAttribute(e7, h3), this._$Em = null;
979
971
  }
980
972
  }
981
- _$AK(t7, s9) {
982
- const i7 = this.constructor, e8 = i7._$Eh.get(t7);
983
- if (void 0 !== e8 && this._$Em !== e8) {
984
- const t8 = i7.getPropertyOptions(e8), h5 = "function" == typeof t8.converter ? { fromAttribute: t8.converter } : void 0 !== t8.converter?.fromAttribute ? t8.converter : b;
985
- this._$Em = e8;
986
- const r8 = h5.fromAttribute(s9, t8.type);
987
- this[e8] = r8 ?? this._$Ej?.get(e8) ?? r8, this._$Em = null;
973
+ _$AK(t4, s7) {
974
+ const i5 = this.constructor, e7 = i5._$Eh.get(t4);
975
+ if (void 0 !== e7 && this._$Em !== e7) {
976
+ const t5 = i5.getPropertyOptions(e7), h3 = "function" == typeof t5.converter ? { fromAttribute: t5.converter } : void 0 !== t5.converter?.fromAttribute ? t5.converter : b;
977
+ this._$Em = e7;
978
+ const r6 = h3.fromAttribute(s7, t5.type);
979
+ this[e7] = r6 ?? this._$Ej?.get(e7) ?? r6, this._$Em = null;
988
980
  }
989
981
  }
990
- requestUpdate(t7, s9, i7, e8 = false, h5) {
991
- if (void 0 !== t7) {
992
- const r8 = this.constructor;
993
- if (false === e8 && (h5 = this[t7]), i7 ??= r8.getPropertyOptions(t7), !((i7.hasChanged ?? m)(h5, s9) || i7.useDefault && i7.reflect && h5 === this._$Ej?.get(t7) && !this.hasAttribute(r8._$Eu(t7, i7)))) return;
994
- this.C(t7, s9, i7);
982
+ requestUpdate(t4, s7, i5, e7 = false, h3) {
983
+ if (void 0 !== t4) {
984
+ const r6 = this.constructor;
985
+ if (false === e7 && (h3 = this[t4]), i5 ??= r6.getPropertyOptions(t4), !((i5.hasChanged ?? m)(h3, s7) || i5.useDefault && i5.reflect && h3 === this._$Ej?.get(t4) && !this.hasAttribute(r6._$Eu(t4, i5)))) return;
986
+ this.C(t4, s7, i5);
995
987
  }
996
988
  false === this.isUpdatePending && (this._$ES = this._$EP());
997
989
  }
998
- C(t7, s9, { useDefault: i7, reflect: e8, wrapped: h5 }, r8) {
999
- i7 && !(this._$Ej ??= /* @__PURE__ */ new Map()).has(t7) && (this._$Ej.set(t7, r8 ?? s9 ?? this[t7]), true !== h5 || void 0 !== r8) || (this._$AL.has(t7) || (this.hasUpdated || i7 || (s9 = void 0), this._$AL.set(t7, s9)), true === e8 && this._$Em !== t7 && (this._$Eq ??= /* @__PURE__ */ new Set()).add(t7));
990
+ C(t4, s7, { useDefault: i5, reflect: e7, wrapped: h3 }, r6) {
991
+ i5 && !(this._$Ej ??= /* @__PURE__ */ new Map()).has(t4) && (this._$Ej.set(t4, r6 ?? s7 ?? this[t4]), true !== h3 || void 0 !== r6) || (this._$AL.has(t4) || (this.hasUpdated || i5 || (s7 = void 0), this._$AL.set(t4, s7)), true === e7 && this._$Em !== t4 && (this._$Eq ??= /* @__PURE__ */ new Set()).add(t4));
1000
992
  }
1001
993
  async _$EP() {
1002
994
  this.isUpdatePending = true;
1003
995
  try {
1004
996
  await this._$ES;
1005
- } catch (t8) {
1006
- Promise.reject(t8);
997
+ } catch (t5) {
998
+ Promise.reject(t5);
1007
999
  }
1008
- const t7 = this.scheduleUpdate();
1009
- return null != t7 && await t7, !this.isUpdatePending;
1000
+ const t4 = this.scheduleUpdate();
1001
+ return null != t4 && await t4, !this.isUpdatePending;
1010
1002
  }
1011
1003
  scheduleUpdate() {
1012
1004
  return this.performUpdate();
@@ -1015,28 +1007,28 @@ var g = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType) {
1015
1007
  if (!this.isUpdatePending) return;
1016
1008
  if (!this.hasUpdated) {
1017
1009
  if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
1018
- for (const [t9, s10] of this._$Ep) this[t9] = s10;
1010
+ for (const [t6, s8] of this._$Ep) this[t6] = s8;
1019
1011
  this._$Ep = void 0;
1020
1012
  }
1021
- const t8 = this.constructor.elementProperties;
1022
- if (t8.size > 0) for (const [s10, i7] of t8) {
1023
- const { wrapped: t9 } = i7, e8 = this[s10];
1024
- true !== t9 || this._$AL.has(s10) || void 0 === e8 || this.C(s10, void 0, i7, e8);
1013
+ const t5 = this.constructor.elementProperties;
1014
+ if (t5.size > 0) for (const [s8, i5] of t5) {
1015
+ const { wrapped: t6 } = i5, e7 = this[s8];
1016
+ true !== t6 || this._$AL.has(s8) || void 0 === e7 || this.C(s8, void 0, i5, e7);
1025
1017
  }
1026
1018
  }
1027
- let t7 = false;
1028
- const s9 = this._$AL;
1019
+ let t4 = false;
1020
+ const s7 = this._$AL;
1029
1021
  try {
1030
- t7 = this.shouldUpdate(s9), t7 ? (this.willUpdate(s9), this._$EO?.forEach((t8) => t8.hostUpdate?.()), this.update(s9)) : this._$EM();
1031
- } catch (s10) {
1032
- throw t7 = false, this._$EM(), s10;
1022
+ t4 = this.shouldUpdate(s7), t4 ? (this.willUpdate(s7), this._$EO?.forEach((t5) => t5.hostUpdate?.()), this.update(s7)) : this._$EM();
1023
+ } catch (s8) {
1024
+ throw t4 = false, this._$EM(), s8;
1033
1025
  }
1034
- t7 && this._$AE(s9);
1026
+ t4 && this._$AE(s7);
1035
1027
  }
1036
- willUpdate(t7) {
1028
+ willUpdate(t4) {
1037
1029
  }
1038
- _$AE(t7) {
1039
- this._$EO?.forEach((t8) => t8.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = true, this.firstUpdated(t7)), this.updated(t7);
1030
+ _$AE(t4) {
1031
+ this._$EO?.forEach((t5) => t5.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = true, this.firstUpdated(t4)), this.updated(t4);
1040
1032
  }
1041
1033
  _$EM() {
1042
1034
  this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = false;
@@ -1047,106 +1039,33 @@ var g = class extends (globalThis.HTMLElement ?? HTMLElementShimWithRealType) {
1047
1039
  getUpdateComplete() {
1048
1040
  return this._$ES;
1049
1041
  }
1050
- shouldUpdate(t7) {
1042
+ shouldUpdate(t4) {
1051
1043
  return true;
1052
1044
  }
1053
- update(t7) {
1054
- this._$Eq &&= this._$Eq.forEach((t8) => this._$ET(t8, this[t8])), this._$EM();
1045
+ update(t4) {
1046
+ this._$Eq &&= this._$Eq.forEach((t5) => this._$ET(t5, this[t5])), this._$EM();
1055
1047
  }
1056
- updated(t7) {
1048
+ updated(t4) {
1057
1049
  }
1058
- firstUpdated(t7) {
1050
+ firstUpdated(t4) {
1059
1051
  }
1060
1052
  };
1061
1053
  g.elementStyles = [], g.shadowRootOptions = { mode: "open" }, g[f("elementProperties")] = /* @__PURE__ */ new Map(), g[f("finalized")] = /* @__PURE__ */ new Map(), u?.({ ReactiveElement: g }), (l.reactiveElementVersions ??= []).push("2.1.2");
1062
1054
 
1063
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/property.js
1064
- var o3 = { attribute: true, type: String, converter: b, reflect: false, hasChanged: m };
1065
- var r3 = (t7 = o3, e8, r8) => {
1066
- const { kind: n8, metadata: i7 } = r8;
1067
- let s9 = globalThis.litPropertyMetadata.get(i7);
1068
- if (void 0 === s9 && globalThis.litPropertyMetadata.set(i7, s9 = /* @__PURE__ */ new Map()), "setter" === n8 && ((t7 = Object.create(t7)).wrapped = true), s9.set(r8.name, t7), "accessor" === n8) {
1069
- const { name: o8 } = r8;
1070
- return { set(r9) {
1071
- const n9 = e8.get.call(this);
1072
- e8.set.call(this, r9), this.requestUpdate(o8, n9, t7, true, r9);
1073
- }, init(e9) {
1074
- return void 0 !== e9 && this.C(o8, void 0, t7, e9), e9;
1075
- } };
1076
- }
1077
- if ("setter" === n8) {
1078
- const { name: o8 } = r8;
1079
- return function(r9) {
1080
- const n9 = this[o8];
1081
- e8.call(this, r9), this.requestUpdate(o8, n9, t7, true, r9);
1082
- };
1083
- }
1084
- throw Error("Unsupported decorator location: " + n8);
1085
- };
1086
- function n4(t7) {
1087
- return (e8, o8) => "object" == typeof o8 ? r3(t7, e8, o8) : ((t8, e9, o9) => {
1088
- const r8 = e9.hasOwnProperty(o9);
1089
- return e9.constructor.createProperty(o9, t8), r8 ? Object.getOwnPropertyDescriptor(e9, o9) : void 0;
1090
- })(t7, e8, o8);
1091
- }
1092
-
1093
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/state.js
1094
- function r4(r8) {
1095
- return n4({ ...r8, state: true, attribute: false });
1096
- }
1097
-
1098
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/base.js
1099
- var e4 = (e8, t7, c6) => (c6.configurable = true, c6.enumerable = true, Reflect.decorate && "object" != typeof t7 && Object.defineProperty(e8, t7, c6), c6);
1100
-
1101
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query.js
1102
- function e5(e8, r8) {
1103
- return (n8, s9, i7) => {
1104
- const o8 = (t7) => t7.renderRoot?.querySelector(e8) ?? null;
1105
- if (r8) {
1106
- const { get: e9, set: r9 } = "object" == typeof s9 ? n8 : i7 ?? /* @__PURE__ */ (() => {
1107
- const t7 = /* @__PURE__ */ Symbol();
1108
- return { get() {
1109
- return this[t7];
1110
- }, set(e10) {
1111
- this[t7] = e10;
1112
- } };
1113
- })();
1114
- return e4(n8, s9, { get() {
1115
- let t7 = e9.call(this);
1116
- return void 0 === t7 && (t7 = o8(this), (null !== t7 || this.hasUpdated) && r9.call(this, t7)), t7;
1117
- } });
1118
- }
1119
- return e4(n8, s9, { get() {
1120
- return o8(this);
1121
- } });
1122
- };
1123
- }
1124
-
1125
- // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query-assigned-elements.js
1126
- function o4(o8) {
1127
- return (e8, n8) => {
1128
- const { slot: r8, selector: s9 } = o8 ?? {}, c6 = "slot" + (r8 ? `[name=${r8}]` : ":not([name])");
1129
- return e4(e8, n8, { get() {
1130
- const t7 = this.renderRoot?.querySelector(c6), e9 = t7?.assignedElements(o8) ?? [];
1131
- return void 0 === s9 ? e9 : e9.filter((t8) => t8.matches(s9));
1132
- } });
1133
- };
1134
- }
1135
-
1136
1055
  // ../../node_modules/.pnpm/lit-html@3.3.2/node_modules/lit-html/node/lit-html.js
1137
- var t4 = globalThis;
1138
- var i3 = (t7) => t7;
1139
- var s5 = t4.trustedTypes;
1140
- var e6 = s5 ? s5.createPolicy("lit-html", { createHTML: (t7) => t7 }) : void 0;
1056
+ var t3 = globalThis;
1057
+ var i3 = (t4) => t4;
1058
+ var s5 = t3.trustedTypes;
1059
+ var e4 = s5 ? s5.createPolicy("lit-html", { createHTML: (t4) => t4 }) : void 0;
1141
1060
  var h2 = "$lit$";
1142
- var o5 = `lit$${Math.random().toFixed(9).slice(2)}$`;
1143
- var n5 = "?" + o5;
1144
- var r5 = `<${n5}>`;
1145
- var l2 = void 0 === t4.document ? { createTreeWalker: () => ({}) } : document;
1061
+ var o3 = `lit$${Math.random().toFixed(9).slice(2)}$`;
1062
+ var n4 = "?" + o3;
1063
+ var r3 = `<${n4}>`;
1064
+ var l2 = void 0 === t3.document ? { createTreeWalker: () => ({}) } : document;
1146
1065
  var c4 = () => l2.createComment("");
1147
- var a2 = (t7) => null === t7 || "object" != typeof t7 && "function" != typeof t7;
1066
+ var a2 = (t4) => null === t4 || "object" != typeof t4 && "function" != typeof t4;
1148
1067
  var u2 = Array.isArray;
1149
- var d2 = (t7) => u2(t7) || "function" == typeof t7?.[Symbol.iterator];
1068
+ var d2 = (t4) => u2(t4) || "function" == typeof t4?.[Symbol.iterator];
1150
1069
  var f2 = "[ \n\f\r]";
1151
1070
  var v = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g;
1152
1071
  var _ = /-->/g;
@@ -1156,7 +1075,7 @@ var p2 = RegExp(`>|${f2}(?:([^\\s"'>=/]+)(${f2}*=${f2}*(?:[^
1156
1075
  var g2 = /'/g;
1157
1076
  var $ = /"/g;
1158
1077
  var y2 = /^(?:script|style|textarea|title)$/i;
1159
- var x = (t7) => (i7, ...s9) => ({ _$litType$: t7, strings: i7, values: s9 });
1078
+ var x = (t4) => (i5, ...s7) => ({ _$litType$: t4, strings: i5, values: s7 });
1160
1079
  var T = x(1);
1161
1080
  var b2 = x(2);
1162
1081
  var w = x(3);
@@ -1164,68 +1083,68 @@ var E = /* @__PURE__ */ Symbol.for("lit-noChange");
1164
1083
  var A = /* @__PURE__ */ Symbol.for("lit-nothing");
1165
1084
  var C = /* @__PURE__ */ new WeakMap();
1166
1085
  var P = l2.createTreeWalker(l2, 129);
1167
- function V(t7, i7) {
1168
- if (!u2(t7) || !t7.hasOwnProperty("raw")) throw Error("invalid template strings array");
1169
- return void 0 !== e6 ? e6.createHTML(i7) : i7;
1086
+ function V(t4, i5) {
1087
+ if (!u2(t4) || !t4.hasOwnProperty("raw")) throw Error("invalid template strings array");
1088
+ return void 0 !== e4 ? e4.createHTML(i5) : i5;
1170
1089
  }
1171
- var N = (t7, i7) => {
1172
- const s9 = t7.length - 1, e8 = [];
1173
- let n8, l3 = 2 === i7 ? "<svg>" : 3 === i7 ? "<math>" : "", c6 = v;
1174
- for (let i8 = 0; i8 < s9; i8++) {
1175
- const s10 = t7[i8];
1176
- let a3, u4, d3 = -1, f4 = 0;
1177
- for (; f4 < s10.length && (c6.lastIndex = f4, u4 = c6.exec(s10), null !== u4); ) f4 = c6.lastIndex, c6 === v ? "!--" === u4[1] ? c6 = _ : void 0 !== u4[1] ? c6 = m2 : void 0 !== u4[2] ? (y2.test(u4[2]) && (n8 = RegExp("</" + u4[2], "g")), c6 = p2) : void 0 !== u4[3] && (c6 = p2) : c6 === p2 ? ">" === u4[0] ? (c6 = n8 ?? v, d3 = -1) : void 0 === u4[1] ? d3 = -2 : (d3 = c6.lastIndex - u4[2].length, a3 = u4[1], c6 = void 0 === u4[3] ? p2 : '"' === u4[3] ? $ : g2) : c6 === $ || c6 === g2 ? c6 = p2 : c6 === _ || c6 === m2 ? c6 = v : (c6 = p2, n8 = void 0);
1178
- const x2 = c6 === p2 && t7[i8 + 1].startsWith("/>") ? " " : "";
1179
- l3 += c6 === v ? s10 + r5 : d3 >= 0 ? (e8.push(a3), s10.slice(0, d3) + h2 + s10.slice(d3) + o5 + x2) : s10 + o5 + (-2 === d3 ? i8 : x2);
1180
- }
1181
- return [V(t7, l3 + (t7[s9] || "<?>") + (2 === i7 ? "</svg>" : 3 === i7 ? "</math>" : "")), e8];
1090
+ var N = (t4, i5) => {
1091
+ const s7 = t4.length - 1, e7 = [];
1092
+ let n6, l3 = 2 === i5 ? "<svg>" : 3 === i5 ? "<math>" : "", c5 = v;
1093
+ for (let i6 = 0; i6 < s7; i6++) {
1094
+ const s8 = t4[i6];
1095
+ let a3, u3, d3 = -1, f3 = 0;
1096
+ for (; f3 < s8.length && (c5.lastIndex = f3, u3 = c5.exec(s8), null !== u3); ) f3 = c5.lastIndex, c5 === v ? "!--" === u3[1] ? c5 = _ : void 0 !== u3[1] ? c5 = m2 : void 0 !== u3[2] ? (y2.test(u3[2]) && (n6 = RegExp("</" + u3[2], "g")), c5 = p2) : void 0 !== u3[3] && (c5 = p2) : c5 === p2 ? ">" === u3[0] ? (c5 = n6 ?? v, d3 = -1) : void 0 === u3[1] ? d3 = -2 : (d3 = c5.lastIndex - u3[2].length, a3 = u3[1], c5 = void 0 === u3[3] ? p2 : '"' === u3[3] ? $ : g2) : c5 === $ || c5 === g2 ? c5 = p2 : c5 === _ || c5 === m2 ? c5 = v : (c5 = p2, n6 = void 0);
1097
+ const x2 = c5 === p2 && t4[i6 + 1].startsWith("/>") ? " " : "";
1098
+ l3 += c5 === v ? s8 + r3 : d3 >= 0 ? (e7.push(a3), s8.slice(0, d3) + h2 + s8.slice(d3) + o3 + x2) : s8 + o3 + (-2 === d3 ? i6 : x2);
1099
+ }
1100
+ return [V(t4, l3 + (t4[s7] || "<?>") + (2 === i5 ? "</svg>" : 3 === i5 ? "</math>" : "")), e7];
1182
1101
  };
1183
1102
  var S2 = class _S {
1184
- constructor({ strings: t7, _$litType$: i7 }, e8) {
1185
- let r8;
1103
+ constructor({ strings: t4, _$litType$: i5 }, e7) {
1104
+ let r6;
1186
1105
  this.parts = [];
1187
1106
  let l3 = 0, a3 = 0;
1188
- const u4 = t7.length - 1, d3 = this.parts, [f4, v3] = N(t7, i7);
1189
- if (this.el = _S.createElement(f4, e8), P.currentNode = this.el.content, 2 === i7 || 3 === i7) {
1190
- const t8 = this.el.content.firstChild;
1191
- t8.replaceWith(...t8.childNodes);
1192
- }
1193
- for (; null !== (r8 = P.nextNode()) && d3.length < u4; ) {
1194
- if (1 === r8.nodeType) {
1195
- if (r8.hasAttributes()) for (const t8 of r8.getAttributeNames()) if (t8.endsWith(h2)) {
1196
- const i8 = v3[a3++], s9 = r8.getAttribute(t8).split(o5), e9 = /([.?@])?(.*)/.exec(i8);
1197
- d3.push({ type: 1, index: l3, name: e9[2], strings: s9, ctor: "." === e9[1] ? I : "?" === e9[1] ? L : "@" === e9[1] ? z : H }), r8.removeAttribute(t8);
1198
- } else t8.startsWith(o5) && (d3.push({ type: 6, index: l3 }), r8.removeAttribute(t8));
1199
- if (y2.test(r8.tagName)) {
1200
- const t8 = r8.textContent.split(o5), i8 = t8.length - 1;
1201
- if (i8 > 0) {
1202
- r8.textContent = s5 ? s5.emptyScript : "";
1203
- for (let s9 = 0; s9 < i8; s9++) r8.append(t8[s9], c4()), P.nextNode(), d3.push({ type: 2, index: ++l3 });
1204
- r8.append(t8[i8], c4());
1107
+ const u3 = t4.length - 1, d3 = this.parts, [f3, v2] = N(t4, i5);
1108
+ if (this.el = _S.createElement(f3, e7), P.currentNode = this.el.content, 2 === i5 || 3 === i5) {
1109
+ const t5 = this.el.content.firstChild;
1110
+ t5.replaceWith(...t5.childNodes);
1111
+ }
1112
+ for (; null !== (r6 = P.nextNode()) && d3.length < u3; ) {
1113
+ if (1 === r6.nodeType) {
1114
+ if (r6.hasAttributes()) for (const t5 of r6.getAttributeNames()) if (t5.endsWith(h2)) {
1115
+ const i6 = v2[a3++], s7 = r6.getAttribute(t5).split(o3), e8 = /([.?@])?(.*)/.exec(i6);
1116
+ d3.push({ type: 1, index: l3, name: e8[2], strings: s7, ctor: "." === e8[1] ? I : "?" === e8[1] ? L : "@" === e8[1] ? z : H }), r6.removeAttribute(t5);
1117
+ } else t5.startsWith(o3) && (d3.push({ type: 6, index: l3 }), r6.removeAttribute(t5));
1118
+ if (y2.test(r6.tagName)) {
1119
+ const t5 = r6.textContent.split(o3), i6 = t5.length - 1;
1120
+ if (i6 > 0) {
1121
+ r6.textContent = s5 ? s5.emptyScript : "";
1122
+ for (let s7 = 0; s7 < i6; s7++) r6.append(t5[s7], c4()), P.nextNode(), d3.push({ type: 2, index: ++l3 });
1123
+ r6.append(t5[i6], c4());
1205
1124
  }
1206
1125
  }
1207
- } else if (8 === r8.nodeType) if (r8.data === n5) d3.push({ type: 2, index: l3 });
1126
+ } else if (8 === r6.nodeType) if (r6.data === n4) d3.push({ type: 2, index: l3 });
1208
1127
  else {
1209
- let t8 = -1;
1210
- for (; -1 !== (t8 = r8.data.indexOf(o5, t8 + 1)); ) d3.push({ type: 7, index: l3 }), t8 += o5.length - 1;
1128
+ let t5 = -1;
1129
+ for (; -1 !== (t5 = r6.data.indexOf(o3, t5 + 1)); ) d3.push({ type: 7, index: l3 }), t5 += o3.length - 1;
1211
1130
  }
1212
1131
  l3++;
1213
1132
  }
1214
1133
  }
1215
- static createElement(t7, i7) {
1216
- const s9 = l2.createElement("template");
1217
- return s9.innerHTML = t7, s9;
1134
+ static createElement(t4, i5) {
1135
+ const s7 = l2.createElement("template");
1136
+ return s7.innerHTML = t4, s7;
1218
1137
  }
1219
1138
  };
1220
- function M(t7, i7, s9 = t7, e8) {
1221
- if (i7 === E) return i7;
1222
- let h5 = void 0 !== e8 ? s9._$Co?.[e8] : s9._$Cl;
1223
- const o8 = a2(i7) ? void 0 : i7._$litDirective$;
1224
- return h5?.constructor !== o8 && (h5?._$AO?.(false), void 0 === o8 ? h5 = void 0 : (h5 = new o8(t7), h5._$AT(t7, s9, e8)), void 0 !== e8 ? (s9._$Co ??= [])[e8] = h5 : s9._$Cl = h5), void 0 !== h5 && (i7 = M(t7, h5._$AS(t7, i7.values), h5, e8)), i7;
1139
+ function M(t4, i5, s7 = t4, e7) {
1140
+ if (i5 === E) return i5;
1141
+ let h3 = void 0 !== e7 ? s7._$Co?.[e7] : s7._$Cl;
1142
+ const o7 = a2(i5) ? void 0 : i5._$litDirective$;
1143
+ return h3?.constructor !== o7 && (h3?._$AO?.(false), void 0 === o7 ? h3 = void 0 : (h3 = new o7(t4), h3._$AT(t4, s7, e7)), void 0 !== e7 ? (s7._$Co ??= [])[e7] = h3 : s7._$Cl = h3), void 0 !== h3 && (i5 = M(t4, h3._$AS(t4, i5.values), h3, e7)), i5;
1225
1144
  }
1226
1145
  var k = class {
1227
- constructor(t7, i7) {
1228
- this._$AV = [], this._$AN = void 0, this._$AD = t7, this._$AM = i7;
1146
+ constructor(t4, i5) {
1147
+ this._$AV = [], this._$AN = void 0, this._$AD = t4, this._$AM = i5;
1229
1148
  }
1230
1149
  get parentNode() {
1231
1150
  return this._$AM.parentNode;
@@ -1233,35 +1152,35 @@ var k = class {
1233
1152
  get _$AU() {
1234
1153
  return this._$AM._$AU;
1235
1154
  }
1236
- u(t7) {
1237
- const { el: { content: i7 }, parts: s9 } = this._$AD, e8 = (t7?.creationScope ?? l2).importNode(i7, true);
1238
- P.currentNode = e8;
1239
- let h5 = P.nextNode(), o8 = 0, n8 = 0, r8 = s9[0];
1240
- for (; void 0 !== r8; ) {
1241
- if (o8 === r8.index) {
1242
- let i8;
1243
- 2 === r8.type ? i8 = new R(h5, h5.nextSibling, this, t7) : 1 === r8.type ? i8 = new r8.ctor(h5, r8.name, r8.strings, this, t7) : 6 === r8.type && (i8 = new W(h5, this, t7)), this._$AV.push(i8), r8 = s9[++n8];
1155
+ u(t4) {
1156
+ const { el: { content: i5 }, parts: s7 } = this._$AD, e7 = (t4?.creationScope ?? l2).importNode(i5, true);
1157
+ P.currentNode = e7;
1158
+ let h3 = P.nextNode(), o7 = 0, n6 = 0, r6 = s7[0];
1159
+ for (; void 0 !== r6; ) {
1160
+ if (o7 === r6.index) {
1161
+ let i6;
1162
+ 2 === r6.type ? i6 = new R(h3, h3.nextSibling, this, t4) : 1 === r6.type ? i6 = new r6.ctor(h3, r6.name, r6.strings, this, t4) : 6 === r6.type && (i6 = new W(h3, this, t4)), this._$AV.push(i6), r6 = s7[++n6];
1244
1163
  }
1245
- o8 !== r8?.index && (h5 = P.nextNode(), o8++);
1164
+ o7 !== r6?.index && (h3 = P.nextNode(), o7++);
1246
1165
  }
1247
- return P.currentNode = l2, e8;
1166
+ return P.currentNode = l2, e7;
1248
1167
  }
1249
- p(t7) {
1250
- let i7 = 0;
1251
- for (const s9 of this._$AV) void 0 !== s9 && (void 0 !== s9.strings ? (s9._$AI(t7, s9, i7), i7 += s9.strings.length - 2) : s9._$AI(t7[i7])), i7++;
1168
+ p(t4) {
1169
+ let i5 = 0;
1170
+ for (const s7 of this._$AV) void 0 !== s7 && (void 0 !== s7.strings ? (s7._$AI(t4, s7, i5), i5 += s7.strings.length - 2) : s7._$AI(t4[i5])), i5++;
1252
1171
  }
1253
1172
  };
1254
1173
  var R = class _R {
1255
1174
  get _$AU() {
1256
1175
  return this._$AM?._$AU ?? this._$Cv;
1257
1176
  }
1258
- constructor(t7, i7, s9, e8) {
1259
- this.type = 2, this._$AH = A, this._$AN = void 0, this._$AA = t7, this._$AB = i7, this._$AM = s9, this.options = e8, this._$Cv = e8?.isConnected ?? true;
1177
+ constructor(t4, i5, s7, e7) {
1178
+ this.type = 2, this._$AH = A, this._$AN = void 0, this._$AA = t4, this._$AB = i5, this._$AM = s7, this.options = e7, this._$Cv = e7?.isConnected ?? true;
1260
1179
  }
1261
1180
  get parentNode() {
1262
- let t7 = this._$AA.parentNode;
1263
- const i7 = this._$AM;
1264
- return void 0 !== i7 && 11 === t7?.nodeType && (t7 = i7.parentNode), t7;
1181
+ let t4 = this._$AA.parentNode;
1182
+ const i5 = this._$AM;
1183
+ return void 0 !== i5 && 11 === t4?.nodeType && (t4 = i5.parentNode), t4;
1265
1184
  }
1266
1185
  get startNode() {
1267
1186
  return this._$AA;
@@ -1269,45 +1188,45 @@ var R = class _R {
1269
1188
  get endNode() {
1270
1189
  return this._$AB;
1271
1190
  }
1272
- _$AI(t7, i7 = this) {
1273
- t7 = M(this, t7, i7), a2(t7) ? t7 === A || null == t7 || "" === t7 ? (this._$AH !== A && this._$AR(), this._$AH = A) : t7 !== this._$AH && t7 !== E && this._(t7) : void 0 !== t7._$litType$ ? this.$(t7) : void 0 !== t7.nodeType ? this.T(t7) : d2(t7) ? this.k(t7) : this._(t7);
1191
+ _$AI(t4, i5 = this) {
1192
+ t4 = M(this, t4, i5), a2(t4) ? t4 === A || null == t4 || "" === t4 ? (this._$AH !== A && this._$AR(), this._$AH = A) : t4 !== this._$AH && t4 !== E && this._(t4) : void 0 !== t4._$litType$ ? this.$(t4) : void 0 !== t4.nodeType ? this.T(t4) : d2(t4) ? this.k(t4) : this._(t4);
1274
1193
  }
1275
- O(t7) {
1276
- return this._$AA.parentNode.insertBefore(t7, this._$AB);
1194
+ O(t4) {
1195
+ return this._$AA.parentNode.insertBefore(t4, this._$AB);
1277
1196
  }
1278
- T(t7) {
1279
- this._$AH !== t7 && (this._$AR(), this._$AH = this.O(t7));
1197
+ T(t4) {
1198
+ this._$AH !== t4 && (this._$AR(), this._$AH = this.O(t4));
1280
1199
  }
1281
- _(t7) {
1282
- this._$AH !== A && a2(this._$AH) ? this._$AA.nextSibling.data = t7 : this.T(l2.createTextNode(t7)), this._$AH = t7;
1200
+ _(t4) {
1201
+ this._$AH !== A && a2(this._$AH) ? this._$AA.nextSibling.data = t4 : this.T(l2.createTextNode(t4)), this._$AH = t4;
1283
1202
  }
1284
- $(t7) {
1285
- const { values: i7, _$litType$: s9 } = t7, e8 = "number" == typeof s9 ? this._$AC(t7) : (void 0 === s9.el && (s9.el = S2.createElement(V(s9.h, s9.h[0]), this.options)), s9);
1286
- if (this._$AH?._$AD === e8) this._$AH.p(i7);
1203
+ $(t4) {
1204
+ const { values: i5, _$litType$: s7 } = t4, e7 = "number" == typeof s7 ? this._$AC(t4) : (void 0 === s7.el && (s7.el = S2.createElement(V(s7.h, s7.h[0]), this.options)), s7);
1205
+ if (this._$AH?._$AD === e7) this._$AH.p(i5);
1287
1206
  else {
1288
- const t8 = new k(e8, this), s10 = t8.u(this.options);
1289
- t8.p(i7), this.T(s10), this._$AH = t8;
1207
+ const t5 = new k(e7, this), s8 = t5.u(this.options);
1208
+ t5.p(i5), this.T(s8), this._$AH = t5;
1290
1209
  }
1291
1210
  }
1292
- _$AC(t7) {
1293
- let i7 = C.get(t7.strings);
1294
- return void 0 === i7 && C.set(t7.strings, i7 = new S2(t7)), i7;
1211
+ _$AC(t4) {
1212
+ let i5 = C.get(t4.strings);
1213
+ return void 0 === i5 && C.set(t4.strings, i5 = new S2(t4)), i5;
1295
1214
  }
1296
- k(t7) {
1215
+ k(t4) {
1297
1216
  u2(this._$AH) || (this._$AH = [], this._$AR());
1298
- const i7 = this._$AH;
1299
- let s9, e8 = 0;
1300
- for (const h5 of t7) e8 === i7.length ? i7.push(s9 = new _R(this.O(c4()), this.O(c4()), this, this.options)) : s9 = i7[e8], s9._$AI(h5), e8++;
1301
- e8 < i7.length && (this._$AR(s9 && s9._$AB.nextSibling, e8), i7.length = e8);
1302
- }
1303
- _$AR(t7 = this._$AA.nextSibling, s9) {
1304
- for (this._$AP?.(false, true, s9); t7 !== this._$AB; ) {
1305
- const s10 = i3(t7).nextSibling;
1306
- i3(t7).remove(), t7 = s10;
1217
+ const i5 = this._$AH;
1218
+ let s7, e7 = 0;
1219
+ for (const h3 of t4) e7 === i5.length ? i5.push(s7 = new _R(this.O(c4()), this.O(c4()), this, this.options)) : s7 = i5[e7], s7._$AI(h3), e7++;
1220
+ e7 < i5.length && (this._$AR(s7 && s7._$AB.nextSibling, e7), i5.length = e7);
1221
+ }
1222
+ _$AR(t4 = this._$AA.nextSibling, s7) {
1223
+ for (this._$AP?.(false, true, s7); t4 !== this._$AB; ) {
1224
+ const s8 = i3(t4).nextSibling;
1225
+ i3(t4).remove(), t4 = s8;
1307
1226
  }
1308
1227
  }
1309
- setConnected(t7) {
1310
- void 0 === this._$AM && (this._$Cv = t7, this._$AP?.(t7));
1228
+ setConnected(t4) {
1229
+ void 0 === this._$AM && (this._$Cv = t4, this._$AP?.(t4));
1311
1230
  }
1312
1231
  };
1313
1232
  var H = class {
@@ -1317,75 +1236,75 @@ var H = class {
1317
1236
  get _$AU() {
1318
1237
  return this._$AM._$AU;
1319
1238
  }
1320
- constructor(t7, i7, s9, e8, h5) {
1321
- this.type = 1, this._$AH = A, this._$AN = void 0, this.element = t7, this.name = i7, this._$AM = e8, this.options = h5, s9.length > 2 || "" !== s9[0] || "" !== s9[1] ? (this._$AH = Array(s9.length - 1).fill(new String()), this.strings = s9) : this._$AH = A;
1239
+ constructor(t4, i5, s7, e7, h3) {
1240
+ this.type = 1, this._$AH = A, this._$AN = void 0, this.element = t4, this.name = i5, this._$AM = e7, this.options = h3, s7.length > 2 || "" !== s7[0] || "" !== s7[1] ? (this._$AH = Array(s7.length - 1).fill(new String()), this.strings = s7) : this._$AH = A;
1322
1241
  }
1323
- _$AI(t7, i7 = this, s9, e8) {
1324
- const h5 = this.strings;
1325
- let o8 = false;
1326
- if (void 0 === h5) t7 = M(this, t7, i7, 0), o8 = !a2(t7) || t7 !== this._$AH && t7 !== E, o8 && (this._$AH = t7);
1242
+ _$AI(t4, i5 = this, s7, e7) {
1243
+ const h3 = this.strings;
1244
+ let o7 = false;
1245
+ if (void 0 === h3) t4 = M(this, t4, i5, 0), o7 = !a2(t4) || t4 !== this._$AH && t4 !== E, o7 && (this._$AH = t4);
1327
1246
  else {
1328
- const e9 = t7;
1329
- let n8, r8;
1330
- for (t7 = h5[0], n8 = 0; n8 < h5.length - 1; n8++) r8 = M(this, e9[s9 + n8], i7, n8), r8 === E && (r8 = this._$AH[n8]), o8 ||= !a2(r8) || r8 !== this._$AH[n8], r8 === A ? t7 = A : t7 !== A && (t7 += (r8 ?? "") + h5[n8 + 1]), this._$AH[n8] = r8;
1247
+ const e8 = t4;
1248
+ let n6, r6;
1249
+ for (t4 = h3[0], n6 = 0; n6 < h3.length - 1; n6++) r6 = M(this, e8[s7 + n6], i5, n6), r6 === E && (r6 = this._$AH[n6]), o7 ||= !a2(r6) || r6 !== this._$AH[n6], r6 === A ? t4 = A : t4 !== A && (t4 += (r6 ?? "") + h3[n6 + 1]), this._$AH[n6] = r6;
1331
1250
  }
1332
- o8 && !e8 && this.j(t7);
1251
+ o7 && !e7 && this.j(t4);
1333
1252
  }
1334
- j(t7) {
1335
- t7 === A ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t7 ?? "");
1253
+ j(t4) {
1254
+ t4 === A ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t4 ?? "");
1336
1255
  }
1337
1256
  };
1338
1257
  var I = class extends H {
1339
1258
  constructor() {
1340
1259
  super(...arguments), this.type = 3;
1341
1260
  }
1342
- j(t7) {
1343
- this.element[this.name] = t7 === A ? void 0 : t7;
1261
+ j(t4) {
1262
+ this.element[this.name] = t4 === A ? void 0 : t4;
1344
1263
  }
1345
1264
  };
1346
1265
  var L = class extends H {
1347
1266
  constructor() {
1348
1267
  super(...arguments), this.type = 4;
1349
1268
  }
1350
- j(t7) {
1351
- this.element.toggleAttribute(this.name, !!t7 && t7 !== A);
1269
+ j(t4) {
1270
+ this.element.toggleAttribute(this.name, !!t4 && t4 !== A);
1352
1271
  }
1353
1272
  };
1354
1273
  var z = class extends H {
1355
- constructor(t7, i7, s9, e8, h5) {
1356
- super(t7, i7, s9, e8, h5), this.type = 5;
1274
+ constructor(t4, i5, s7, e7, h3) {
1275
+ super(t4, i5, s7, e7, h3), this.type = 5;
1357
1276
  }
1358
- _$AI(t7, i7 = this) {
1359
- if ((t7 = M(this, t7, i7, 0) ?? A) === E) return;
1360
- const s9 = this._$AH, e8 = t7 === A && s9 !== A || t7.capture !== s9.capture || t7.once !== s9.once || t7.passive !== s9.passive, h5 = t7 !== A && (s9 === A || e8);
1361
- e8 && this.element.removeEventListener(this.name, this, s9), h5 && this.element.addEventListener(this.name, this, t7), this._$AH = t7;
1277
+ _$AI(t4, i5 = this) {
1278
+ if ((t4 = M(this, t4, i5, 0) ?? A) === E) return;
1279
+ const s7 = this._$AH, e7 = t4 === A && s7 !== A || t4.capture !== s7.capture || t4.once !== s7.once || t4.passive !== s7.passive, h3 = t4 !== A && (s7 === A || e7);
1280
+ e7 && this.element.removeEventListener(this.name, this, s7), h3 && this.element.addEventListener(this.name, this, t4), this._$AH = t4;
1362
1281
  }
1363
- handleEvent(t7) {
1364
- "function" == typeof this._$AH ? this._$AH.call(this.options?.host ?? this.element, t7) : this._$AH.handleEvent(t7);
1282
+ handleEvent(t4) {
1283
+ "function" == typeof this._$AH ? this._$AH.call(this.options?.host ?? this.element, t4) : this._$AH.handleEvent(t4);
1365
1284
  }
1366
1285
  };
1367
1286
  var W = class {
1368
- constructor(t7, i7, s9) {
1369
- this.element = t7, this.type = 6, this._$AN = void 0, this._$AM = i7, this.options = s9;
1287
+ constructor(t4, i5, s7) {
1288
+ this.element = t4, this.type = 6, this._$AN = void 0, this._$AM = i5, this.options = s7;
1370
1289
  }
1371
1290
  get _$AU() {
1372
1291
  return this._$AM._$AU;
1373
1292
  }
1374
- _$AI(t7) {
1375
- M(this, t7);
1293
+ _$AI(t4) {
1294
+ M(this, t4);
1376
1295
  }
1377
1296
  };
1378
- var Z = { M: h2, P: o5, A: n5, C: 1, L: N, R: k, D: d2, V: M, I: R, H, N: L, U: z, B: I, F: W };
1379
- var j = t4.litHtmlPolyfillSupport;
1380
- j?.(S2, R), (t4.litHtmlVersions ??= []).push("3.3.2");
1381
- var B = (t7, i7, s9) => {
1382
- const e8 = s9?.renderBefore ?? i7;
1383
- let h5 = e8._$litPart$;
1384
- if (void 0 === h5) {
1385
- const t8 = s9?.renderBefore ?? null;
1386
- e8._$litPart$ = h5 = new R(i7.insertBefore(c4(), t8), t8, void 0, s9 ?? {});
1387
- }
1388
- return h5._$AI(t7), h5;
1297
+ var Z = { M: h2, P: o3, A: n4, C: 1, L: N, R: k, D: d2, V: M, I: R, H, N: L, U: z, B: I, F: W };
1298
+ var j = t3.litHtmlPolyfillSupport;
1299
+ j?.(S2, R), (t3.litHtmlVersions ??= []).push("3.3.2");
1300
+ var B = (t4, i5, s7) => {
1301
+ const e7 = s7?.renderBefore ?? i5;
1302
+ let h3 = e7._$litPart$;
1303
+ if (void 0 === h3) {
1304
+ const t5 = s7?.renderBefore ?? null;
1305
+ e7._$litPart$ = h3 = new R(i5.insertBefore(c4(), t5), t5, void 0, s7 ?? {});
1306
+ }
1307
+ return h3._$AI(t4), h3;
1389
1308
  };
1390
1309
 
1391
1310
  // ../../node_modules/.pnpm/lit-element@4.2.2/node_modules/lit-element/lit-element.js
@@ -1395,12 +1314,12 @@ var i4 = class extends g {
1395
1314
  super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
1396
1315
  }
1397
1316
  createRenderRoot() {
1398
- const t7 = super.createRenderRoot();
1399
- return this.renderOptions.renderBefore ??= t7.firstChild, t7;
1317
+ const t4 = super.createRenderRoot();
1318
+ return this.renderOptions.renderBefore ??= t4.firstChild, t4;
1400
1319
  }
1401
- update(t7) {
1402
- const r8 = this.render();
1403
- this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t7), this._$Do = B(r8, this.renderRoot, this.renderOptions);
1320
+ update(t4) {
1321
+ const r6 = this.render();
1322
+ this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t4), this._$Do = B(r6, this.renderRoot, this.renderOptions);
1404
1323
  }
1405
1324
  connectedCallback() {
1406
1325
  super.connectedCallback(), this._$Do?.setConnected(true);
@@ -1413,321 +1332,164 @@ var i4 = class extends g {
1413
1332
  }
1414
1333
  };
1415
1334
  i4._$litElement$ = true, i4["finalized"] = true, s6.litElementHydrateSupport?.({ LitElement: i4 });
1416
- var o6 = s6.litElementPolyfillSupport;
1417
- o6?.({ LitElement: i4 });
1335
+ var o4 = s6.litElementPolyfillSupport;
1336
+ o4?.({ LitElement: i4 });
1418
1337
  (s6.litElementVersions ??= []).push("4.2.2");
1419
1338
 
1420
- // ../qti-utilities/src/decorators/watch.ts
1421
- function watch(propertyName, options) {
1422
- const resolvedOptions = {
1423
- waitUntilFirstUpdate: false,
1424
- ...options
1425
- };
1426
- return (proto, decoratedFnName) => {
1427
- const { update } = proto;
1428
- const watchedProperties = Array.isArray(propertyName) ? propertyName : [propertyName];
1429
- proto.update = function(changedProps) {
1430
- watchedProperties.forEach((property) => {
1431
- const key = property;
1432
- if (changedProps.has(key)) {
1433
- const oldValue = changedProps.get(key);
1434
- const newValue = this[key];
1435
- if (oldValue !== newValue) {
1436
- if (!resolvedOptions.waitUntilFirstUpdate || this.hasUpdated) {
1437
- this[decoratedFnName](oldValue, newValue);
1438
- }
1439
- }
1440
- }
1441
- });
1442
- update.call(this, changedProps);
1443
- };
1444
- };
1445
- }
1446
-
1447
- // ../../node_modules/.pnpm/lit-html@3.3.2/node_modules/lit-html/node/directive.js
1448
- var t5 = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 };
1449
- var e7 = (t7) => (...e8) => ({ _$litDirective$: t7, values: e8 });
1450
- var i5 = class {
1451
- constructor(t7) {
1452
- }
1453
- get _$AU() {
1454
- return this._$AM._$AU;
1339
+ // ../qti-base/dist/styles/box-sizing.styles.js
1340
+ var boxSizing = i2`
1341
+ :host {
1342
+ box-sizing: border-box;
1455
1343
  }
1456
- _$AT(t7, e8, i7) {
1457
- this._$Ct = t7, this._$AM = e8, this._$Ci = i7;
1344
+
1345
+ *,
1346
+ *::before,
1347
+ *::after {
1348
+ box-sizing: inherit;
1458
1349
  }
1459
- _$AS(t7, e8) {
1460
- return this.update(t7, e8);
1350
+ `;
1351
+
1352
+ // ../qti-base/dist/styles/drop-region.styles.js
1353
+ var dropRegion = i2`
1354
+ [part~='drop'] {
1355
+ /*
1356
+ * The one deliberate opt-out from the border-box reset.
1357
+ *
1358
+ * --qti-dropzone-min-* is the border-box of the largest chip, and what has to hold that chip is
1359
+ * this region's *content* area. Under border-box a theme's dashed drop border is subtracted
1360
+ * from the chip's own size, the content comes up short, and the drop grows the moment a chip
1361
+ * lands in it. Order's drop did exactly that: 64px empty, 66px full, for a 1px border.
1362
+ */
1363
+ box-sizing: content-box;
1364
+
1365
+ /*
1366
+ * No padding, and no token for one.
1367
+ *
1368
+ * A drop reserves --qti-dropzone-min-*, which is the chip's BORDER-box, as this region's CONTENT
1369
+ * area — so the chip already fits exactly, with nothing to spare and nothing squeezed. An inset
1370
+ * on top would only make the drop bigger than the thing it holds.
1371
+ *
1372
+ * There was a 1px one, to make the drop read as a frame a hair outside the chip. It never painted:
1373
+ * an EMPTY slot has nothing inside the inset to separate from, and a FILLED one hides its edge
1374
+ * (DROP-SIZING.md §4), so both states spent 2px on an invisible ring. The one drop that genuinely
1375
+ * wants breathing room — match's category card — declares padding on its own rule, which a
1376
+ * theme reaches with ::part(drop). A token in between bought nothing.
1377
+ */
1378
+ display: flex;
1379
+ flex-wrap: wrap;
1380
+ align-items: flex-start;
1381
+ justify-content: flex-start;
1382
+ /* No gap either: 0 is the flex initial value, so the declaration only existed to host a token.
1383
+ A drop that wants space between chips sets gap on its own rule. */
1384
+ /* Containing block for anything a theme draws over the drop. Was 'position: relative' in the
1385
+ theme's 'drop' mixin, which put a document stylesheet in charge of a shadow node's position. */
1386
+ position: relative;
1461
1387
  }
1462
- update(t7, e8) {
1463
- return this.render(...e8);
1388
+
1389
+ [part~='drop'] > * {
1390
+ flex: 0 1 auto;
1391
+ align-self: flex-start;
1464
1392
  }
1465
- };
1393
+ `;
1466
1394
 
1467
- // ../../node_modules/.pnpm/lit-html@3.3.2/node_modules/lit-html/node/directive-helpers.js
1468
- var { I: t6 } = Z;
1469
- var i6 = (o8) => o8;
1470
- var n6 = (o8) => null === o8 || "object" != typeof o8 && "function" != typeof o8;
1471
- var r6 = (o8) => void 0 === o8.strings;
1472
- var s7 = () => document.createComment("");
1473
- var v2 = (o8, n8, e8) => {
1474
- const l3 = o8._$AA.parentNode, d3 = void 0 === n8 ? o8._$AB : n8._$AA;
1475
- if (void 0 === e8) {
1476
- const i7 = l3.insertBefore(s7(), d3), n9 = l3.insertBefore(s7(), d3);
1477
- e8 = new t6(i7, n9, o8, o8.options);
1478
- } else {
1479
- const t7 = e8._$AB.nextSibling, n9 = e8._$AM, c6 = n9 !== o8;
1480
- if (c6) {
1481
- let t8;
1482
- e8._$AQ?.(o8), e8._$AM = o8, void 0 !== e8._$AP && (t8 = o8._$AU) !== n9._$AU && e8._$AP(t8);
1483
- }
1484
- if (t7 !== d3 || c6) {
1485
- let o9 = e8._$AA;
1486
- for (; o9 !== t7; ) {
1487
- const t8 = i6(o9).nextSibling;
1488
- i6(l3).insertBefore(o9, d3), o9 = t8;
1489
- }
1490
- }
1395
+ // ../qti-base/dist/styles/validation-message.styles.js
1396
+ var validationMessage = i2`
1397
+ [part~='message'] {
1398
+ display: none;
1491
1399
  }
1492
- return e8;
1493
- };
1494
- var u3 = (o8, t7, i7 = o8) => (o8._$AI(t7, i7), o8);
1495
- var m3 = {};
1496
- var p3 = (o8, t7 = m3) => o8._$AH = t7;
1497
- var M2 = (o8) => o8._$AH;
1498
- var h3 = (o8) => {
1499
- o8._$AR(), o8._$AA.remove();
1500
- };
1400
+ `;
1501
1401
 
1502
- // ../../node_modules/.pnpm/lit-html@3.3.2/node_modules/lit-html/node/async-directive.js
1503
- var s8 = (i7, t7) => {
1504
- const e8 = i7._$AN;
1505
- if (void 0 === e8) return false;
1506
- for (const i8 of e8) i8._$AO?.(t7, false), s8(i8, t7);
1507
- return true;
1508
- };
1509
- var o7 = (i7) => {
1510
- let t7, e8;
1511
- do {
1512
- if (void 0 === (t7 = i7._$AM)) break;
1513
- e8 = t7._$AN, e8.delete(i7), i7 = t7;
1514
- } while (0 === e8?.size);
1515
- };
1516
- var r7 = (i7) => {
1517
- for (let t7; t7 = i7._$AM; i7 = t7) {
1518
- let e8 = t7._$AN;
1519
- if (void 0 === e8) t7._$AN = e8 = /* @__PURE__ */ new Set();
1520
- else if (e8.has(i7)) break;
1521
- e8.add(i7), c5(t7);
1402
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/property.js
1403
+ var o5 = { attribute: true, type: String, converter: b, reflect: false, hasChanged: m };
1404
+ var r4 = (t4 = o5, e7, r6) => {
1405
+ const { kind: n6, metadata: i5 } = r6;
1406
+ let s7 = globalThis.litPropertyMetadata.get(i5);
1407
+ if (void 0 === s7 && globalThis.litPropertyMetadata.set(i5, s7 = /* @__PURE__ */ new Map()), "setter" === n6 && ((t4 = Object.create(t4)).wrapped = true), s7.set(r6.name, t4), "accessor" === n6) {
1408
+ const { name: o7 } = r6;
1409
+ return { set(r7) {
1410
+ const n7 = e7.get.call(this);
1411
+ e7.set.call(this, r7), this.requestUpdate(o7, n7, t4, true, r7);
1412
+ }, init(e8) {
1413
+ return void 0 !== e8 && this.C(o7, void 0, t4, e8), e8;
1414
+ } };
1415
+ }
1416
+ if ("setter" === n6) {
1417
+ const { name: o7 } = r6;
1418
+ return function(r7) {
1419
+ const n7 = this[o7];
1420
+ e7.call(this, r7), this.requestUpdate(o7, n7, t4, true, r7);
1421
+ };
1522
1422
  }
1423
+ throw Error("Unsupported decorator location: " + n6);
1523
1424
  };
1524
- function h4(i7) {
1525
- void 0 !== this._$AN ? (o7(this), this._$AM = i7, r7(this)) : this._$AM = i7;
1425
+ function n5(t4) {
1426
+ return (e7, o7) => "object" == typeof o7 ? r4(t4, e7, o7) : ((t5, e8, o8) => {
1427
+ const r6 = e8.hasOwnProperty(o8);
1428
+ return e8.constructor.createProperty(o8, t5), r6 ? Object.getOwnPropertyDescriptor(e8, o8) : void 0;
1429
+ })(t4, e7, o7);
1526
1430
  }
1527
- function n7(i7, t7 = false, e8 = 0) {
1528
- const r8 = this._$AH, h5 = this._$AN;
1529
- if (void 0 !== h5 && 0 !== h5.size) if (t7) if (Array.isArray(r8)) for (let i8 = e8; i8 < r8.length; i8++) s8(r8[i8], false), o7(r8[i8]);
1530
- else null != r8 && (s8(r8, false), o7(r8));
1531
- else s8(this, i7);
1431
+
1432
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/state.js
1433
+ function r5(r6) {
1434
+ return n5({ ...r6, state: true, attribute: false });
1532
1435
  }
1533
- var c5 = (i7) => {
1534
- i7.type == t5.CHILD && (i7._$AP ??= n7, i7._$AQ ??= h4);
1535
- };
1536
- var f3 = class extends i5 {
1537
- constructor() {
1538
- super(...arguments), this._$AN = void 0;
1539
- }
1540
- _$AT(i7, t7, e8) {
1541
- super._$AT(i7, t7, e8), r7(this), this.isConnected = i7._$AU;
1542
- }
1543
- _$AO(i7, t7 = true) {
1544
- i7 !== this.isConnected && (this.isConnected = i7, i7 ? this.reconnected?.() : this.disconnected?.()), t7 && (s8(this, i7), o7(this));
1545
- }
1546
- setValue(t7) {
1547
- if (r6(this._$Ct)) this._$Ct._$AI(t7, this);
1548
- else {
1549
- const i7 = [...this._$Ct._$AH];
1550
- i7[this._$Ci] = t7, this._$Ct._$AI(i7, this, 0);
1551
- }
1552
- }
1553
- disconnected() {
1554
- }
1555
- reconnected() {
1556
- }
1557
- };
1558
1436
 
1559
- // ../qti-utilities/src/directives/spread-args.ts
1560
- var SpreadArgsDirective = class extends f3 {
1561
- constructor() {
1562
- super(...arguments);
1563
- this.prevData = {};
1564
- }
1565
- render(_spreadData) {
1566
- return A;
1567
- }
1568
- update(part, [spreadData]) {
1569
- if (this.element !== part.element) {
1570
- this.element = part.element;
1571
- }
1572
- this.host = part.options?.host || this.element;
1573
- this.apply(spreadData);
1574
- this.groom(spreadData);
1575
- this.prevData = { ...spreadData };
1576
- return A;
1577
- }
1578
- apply(data) {
1579
- const filteredData = this.#filterArgs(data);
1580
- const { prevData, element } = this;
1581
- for (const key in filteredData) {
1582
- const value = filteredData[key];
1583
- if (value === prevData[key]) {
1584
- continue;
1585
- }
1586
- if (value === true) {
1587
- element.setAttribute(key, "");
1588
- } else if (value === false) {
1589
- element.removeAttribute(key);
1590
- } else if (value != null) {
1591
- element.setAttribute(key, String(value));
1592
- } else {
1593
- element.removeAttribute(key);
1594
- }
1595
- }
1596
- }
1597
- groom(data) {
1598
- const { prevData, element } = this;
1599
- if (!prevData) return;
1600
- const filteredData = data ? this.#filterArgs(data) : {};
1601
- for (const key in prevData) {
1602
- if (!filteredData || !(key in filteredData)) {
1603
- element.removeAttribute(key);
1604
- }
1437
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/base.js
1438
+ var e5 = (e7, t4, c5) => (c5.configurable = true, c5.enumerable = true, Reflect.decorate && "object" != typeof t4 && Object.defineProperty(e7, t4, c5), c5);
1439
+
1440
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query.js
1441
+ function e6(e7, r6) {
1442
+ return (n6, s7, i5) => {
1443
+ const o7 = (t4) => t4.renderRoot?.querySelector(e7) ?? null;
1444
+ if (r6) {
1445
+ const { get: e8, set: r7 } = "object" == typeof s7 ? n6 : i5 ?? /* @__PURE__ */ (() => {
1446
+ const t4 = /* @__PURE__ */ Symbol();
1447
+ return { get() {
1448
+ return this[t4];
1449
+ }, set(e9) {
1450
+ this[t4] = e9;
1451
+ } };
1452
+ })();
1453
+ return e5(n6, s7, { get() {
1454
+ let t4 = e8.call(this);
1455
+ return void 0 === t4 && (t4 = o7(this), (null !== t4 || this.hasUpdated) && r7.call(this, t4)), t4;
1456
+ } });
1605
1457
  }
1606
- }
1607
- #filterArgs(args) {
1608
- return Object.fromEntries(
1609
- Object.entries(args).filter(([key, value]) => {
1610
- if (typeof value === "function") {
1611
- return false;
1612
- }
1613
- if (key === "max-choices" && value === 0) {
1614
- return true;
1615
- }
1616
- if (value === "" || value === null || value === void 0) {
1617
- return false;
1618
- }
1619
- return true;
1620
- })
1621
- );
1622
- }
1623
- };
1624
- var spreadArgs = e7(SpreadArgsDirective);
1458
+ return e5(n6, s7, { get() {
1459
+ return o7(this);
1460
+ } });
1461
+ };
1462
+ }
1625
1463
 
1626
- // ../qti-base/src/abstract/interaction.ts
1627
- var Correctness = /* @__PURE__ */ ((Correctness2) => {
1628
- Correctness2["Correct"] = "correct";
1629
- Correctness2["PartiallyCorrect"] = "partially-correct";
1630
- Correctness2["Incorrect"] = "incorrect";
1631
- return Correctness2;
1632
- })(Correctness || {});
1464
+ // ../../node_modules/.pnpm/@lit+reactive-element@2.1.2/node_modules/@lit/reactive-element/node/decorators/query-assigned-elements.js
1465
+ function o6(o7) {
1466
+ return (e7, n6) => {
1467
+ const { slot: r6, selector: s7 } = o7 ?? {}, c5 = "slot" + (r6 ? `[name=${r6}]` : ":not([name])");
1468
+ return e5(e7, n6, { get() {
1469
+ const t4 = this.renderRoot?.querySelector(c5), e8 = t4?.assignedElements(o7) ?? [];
1470
+ return void 0 === s7 ? e8 : e8.filter((t5) => t5.matches(s7));
1471
+ } });
1472
+ };
1473
+ }
1474
+
1475
+ // ../qti-base/dist/abstract/interaction.js
1476
+ var __decorate = function(decorators, target, key, desc) {
1477
+ var c5 = arguments.length, r6 = c5 < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d3;
1478
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r6 = Reflect.decorate(decorators, target, key, desc);
1479
+ else for (var i5 = decorators.length - 1; i5 >= 0; i5--) if (d3 = decorators[i5]) r6 = (c5 < 3 ? d3(r6) : c5 > 3 ? d3(target, key, r6) : d3(target, key)) || r6;
1480
+ return c5 > 3 && r6 && Object.defineProperty(target, key, r6), r6;
1481
+ };
1633
1482
  var Interaction = class extends i4 {
1634
- constructor() {
1635
- super();
1636
- this.disabled = false;
1637
- this.readonly = false;
1638
- this.showCorrectResponse = false;
1639
- this._handleShowCorrectResponseChange = (_2, show) => {
1640
- this.toggleInternalCorrectResponse(show);
1641
- };
1642
- this.showFullCorrectResponse = false;
1643
- this._handleShowFullCorrectResponseChange = (_2, show) => {
1644
- this.toggleFullCorrectResponse(show);
1645
- };
1646
- this.showCandidateCorrection = false;
1647
- this._handleShowCandidateCorrectionChange = (_2, show) => {
1648
- this.toggleCandidateCorrection(show);
1649
- };
1650
- this._correctResponse = null;
1651
- this._internals = this.attachInternals();
1652
- }
1483
+ #didLogDisableAfterIfMaxChoicesReachedDeprecation;
1653
1484
  static {
1654
1485
  this.formAssociated = true;
1655
1486
  }
1656
1487
  get internals() {
1657
1488
  return this._internals;
1658
1489
  }
1659
- set correctResponseAttr(val) {
1660
- if (val === null) {
1661
- this._correctResponse = null;
1662
- } else if (val.includes(",")) {
1663
- this._correctResponse = val.split(",").map((v3) => v3.trim());
1664
- } else {
1665
- this._correctResponse = val;
1666
- }
1667
- }
1668
- get correctResponseAttr() {
1669
- if (this._correctResponse === null || this._correctResponse === void 0) {
1670
- return null;
1671
- }
1672
- return Array.isArray(this._correctResponse) ? this._correctResponse.join(",") : this._correctResponse;
1673
- }
1674
- get isFullCorrectResponse() {
1675
- return this._isFullCorrectResponse;
1676
- }
1677
- set isFullCorrectResponse(val) {
1678
- this._isFullCorrectResponse = val;
1679
- if (val) {
1680
- this.disabled = true;
1681
- this.setAttribute("inert", "");
1682
- this.setAttribute("response-identifier", this.responseIdentifier + "_cr");
1683
- }
1684
- }
1685
- /**
1686
- * Get/set correct response programmatically.
1687
- * This property syncs with the `correct-response` attribute.
1688
- */
1689
- get correctResponse() {
1690
- const responseVariable = this.responseVariable;
1691
- if (responseVariable?.correctResponse) {
1692
- return responseVariable.correctResponse;
1693
- }
1694
- return this._correctResponse;
1695
- }
1696
- set correctResponse(val) {
1697
- const oldVal = this._correctResponse;
1698
- this._correctResponse = val;
1699
- if (val === null || val === void 0) {
1700
- this.removeAttribute("correct-response");
1701
- } else {
1702
- this.setAttribute("correct-response", Array.isArray(val) ? val.join(",") : val);
1703
- }
1704
- this.requestUpdate("_correctResponse", oldVal);
1705
- }
1706
- /**
1707
- * Returns the correctness of the current response compared to correct response.
1708
- * Works in both standalone mode (using `correct-response` attribute) and
1709
- * item context mode (using responseVariable).
1710
- */
1711
- get correctness() {
1712
- const correctResponse = this.correctResponse;
1713
- if (!correctResponse) return null;
1714
- const currentResponse = this.response;
1715
- if (currentResponse === null || currentResponse === void 0 || currentResponse === "" || Array.isArray(currentResponse) && currentResponse.length === 0) {
1716
- return null;
1717
- }
1718
- const correctArr = Array.isArray(correctResponse) ? correctResponse : [correctResponse];
1719
- const responseArr = Array.isArray(currentResponse) ? currentResponse : [currentResponse];
1720
- const filteredResponseArr = responseArr.filter((r8) => r8 !== "");
1721
- if (filteredResponseArr.length === 0) return null;
1722
- const correctCount = filteredResponseArr.filter((r8) => correctArr.includes(r8)).length;
1723
- const incorrectCount = filteredResponseArr.filter((r8) => !correctArr.includes(r8)).length;
1724
- if (correctCount === correctArr.length && incorrectCount === 0 && filteredResponseArr.length === correctArr.length) {
1725
- return "correct" /* Correct */;
1726
- }
1727
- if (correctCount > 0 && (correctCount < correctArr.length || incorrectCount > 0)) {
1728
- return "partially-correct" /* PartiallyCorrect */;
1729
- }
1730
- return "incorrect" /* Incorrect */;
1490
+ /** Extension point used by wrappers that should not register as candidate inputs. */
1491
+ get registersWithItem() {
1492
+ return true;
1731
1493
  }
1732
1494
  get isInline() {
1733
1495
  return false;
@@ -1736,200 +1498,163 @@ var Interaction = class extends i4 {
1736
1498
  if (!this._context?.variables) {
1737
1499
  return void 0;
1738
1500
  }
1739
- const responseVariables = this._context.variables.filter((v3) => v3.type === "response");
1501
+ const responseVariables = this._context.variables.filter((v2) => v2.type === "response");
1740
1502
  const responseIdentifier = this.getAttribute("response-identifier");
1741
- return responseVariables.find((v3) => v3.identifier === responseIdentifier);
1503
+ return responseVariables.find((v2) => v2.identifier === responseIdentifier);
1742
1504
  }
1743
- toggleCorrectResponse(show) {
1744
- const correctResponseMode = this?.configContext?.correctResponseMode || "internal";
1745
- if (correctResponseMode === "full") {
1746
- this.toggleFullCorrectResponse(show);
1747
- } else {
1748
- this.toggleInternalCorrectResponse(show);
1749
- }
1505
+ get value() {
1506
+ return JSON.stringify(this.response);
1750
1507
  }
1751
- async toggleFullCorrectResponse(show) {
1752
- const nextSibling = this.nextSibling;
1753
- const nextSiblingIsFullCorrectResponse = nextSibling instanceof HTMLDivElement && nextSibling?.classList.contains("full-correct-response");
1754
- const correctResponse = this.correctResponse;
1755
- if (!correctResponse) {
1756
- return;
1508
+ set value(val) {
1509
+ this.response = val ? JSON.parse(val) : null;
1510
+ }
1511
+ reportValidity() {
1512
+ const isValid = this._internals.validity.valid;
1513
+ const mode = this.validationDisplayMode;
1514
+ if (mode === "native" || mode === "both") {
1515
+ this._internals.reportValidity();
1757
1516
  }
1758
- const showFullCorrectResponse = show && (this?.configContext?.fullCorrectResponseOnlyWhenIncorrect === false || this.correctness !== "correct" /* Correct */);
1759
- if (!showFullCorrectResponse) {
1760
- if (!nextSiblingIsFullCorrectResponse) {
1761
- return;
1762
- }
1763
- this.parentElement?.removeChild(nextSibling);
1764
- return;
1517
+ if (mode === "inline" || mode === "both") {
1518
+ this.updateInlineValidationMessage();
1519
+ } else {
1520
+ this.clearInlineValidationMessage();
1765
1521
  }
1766
- if (nextSiblingIsFullCorrectResponse) {
1767
- return;
1522
+ if (mode === "none") {
1523
+ this.clearInlineValidationMessage();
1768
1524
  }
1769
- const clone = this.cloneNode(true);
1770
- clone.removeAttribute("show-full-correct-response");
1771
- clone.removeAttribute("show-correct-response");
1772
- clone.removeAttribute("show-candidate-correction");
1773
- const containerDiv = document.createElement("div");
1774
- containerDiv.classList.add("full-correct-response");
1775
- if (this.isInline) {
1776
- containerDiv.classList.add("full-correct-response-inline");
1777
- } else {
1778
- containerDiv.classList.add("full-correct-response-block");
1525
+ return isValid;
1526
+ }
1527
+ get validationDisplayMode() {
1528
+ return this.configContext?.validationDisplayMode ?? "inline";
1529
+ }
1530
+ resolveAllowReorder(options) {
1531
+ const defaultWhenUnset = options?.defaultWhenUnset ?? true;
1532
+ const config = this.configContext;
1533
+ if (!config) {
1534
+ return defaultWhenUnset;
1779
1535
  }
1780
- containerDiv.role = "full-correct-response";
1781
- containerDiv.appendChild(clone);
1782
- clone.isFullCorrectResponse = true;
1783
- this.parentElement?.insertBefore(containerDiv, this.nextSibling);
1784
- await clone.updateComplete;
1785
- clone.response = Array.isArray(correctResponse) ? [...correctResponse] : correctResponse;
1786
- }
1787
- toggleInternalCorrectResponse(show) {
1788
- this._internals.states.delete("show-correct-response");
1789
- if (show && this.correctResponse) {
1790
- this._internals.states.add("show-correct-response");
1536
+ if (config.allowReorder !== void 0) {
1537
+ return config.allowReorder;
1791
1538
  }
1539
+ return defaultWhenUnset;
1792
1540
  }
1793
- toggleCandidateCorrection(show) {
1794
- this._internals.states.delete("candidate-correct");
1795
- this._internals.states.delete("candidate-partially-correct");
1796
- this._internals.states.delete("candidate-incorrect");
1797
- if (!show) {
1798
- return;
1541
+ resolveDisableAfterMaxReached(options) {
1542
+ const defaultWhenUnset = options?.defaultWhenUnset ?? false;
1543
+ const config = this.configContext;
1544
+ if (!config) {
1545
+ return defaultWhenUnset;
1799
1546
  }
1800
- if (this.correctness === "correct" /* Correct */) {
1801
- this._internals.states.add("candidate-correct");
1547
+ if (config.disableAfterMaxReached !== void 0) {
1548
+ return config.disableAfterMaxReached;
1802
1549
  }
1803
- if (this.correctness === "partially-correct" /* PartiallyCorrect */) {
1804
- this._internals.states.add("candidate-partially-correct");
1550
+ if (config.disableAfterIfMaxChoicesReached !== void 0) {
1551
+ if (!this.#didLogDisableAfterIfMaxChoicesReachedDeprecation) {
1552
+ this.#didLogDisableAfterIfMaxChoicesReachedDeprecation = true;
1553
+ console.log("[QTI Config] `disableAfterIfMaxChoicesReached` is deprecated. Use `disableAfterMaxReached` instead.");
1554
+ }
1555
+ return config.disableAfterIfMaxChoicesReached;
1805
1556
  }
1806
- if (this.correctness === "incorrect" /* Incorrect */) {
1807
- this._internals.states.add("candidate-incorrect");
1557
+ return defaultWhenUnset;
1558
+ }
1559
+ setInteractionValidity(isValid, validityMessage = "", anchor, options) {
1560
+ const validityAnchor = anchor ?? this;
1561
+ this._internals.setValidity(isValid ? {} : { customError: true }, validityMessage, validityAnchor);
1562
+ if (options?.suppressInline !== true && (this.validationDisplayMode === "inline" || this.validationDisplayMode === "both")) {
1563
+ this.updateInlineValidationMessage();
1808
1564
  }
1809
1565
  }
1810
- get value() {
1811
- return JSON.stringify(this.response);
1566
+ updateInlineValidationMessage() {
1567
+ const validationMessageElement = this.getValidationMessageElement();
1568
+ if (!validationMessageElement) {
1569
+ return;
1570
+ }
1571
+ if (!this._internals.validity.valid) {
1572
+ validationMessageElement.textContent = this._internals.validationMessage;
1573
+ validationMessageElement.style.setProperty("display", "block", "important");
1574
+ return;
1575
+ }
1576
+ validationMessageElement.textContent = "";
1577
+ validationMessageElement.style.display = "none";
1812
1578
  }
1813
- set value(val) {
1814
- this.response = val ? JSON.parse(val) : null;
1579
+ clearInlineValidationMessage() {
1580
+ const validationMessageElement = this.getValidationMessageElement();
1581
+ if (!validationMessageElement) {
1582
+ return;
1583
+ }
1584
+ validationMessageElement.textContent = "";
1585
+ validationMessageElement.style.display = "none";
1815
1586
  }
1816
- reportValidity() {
1817
- return this._internals.reportValidity();
1587
+ getValidationMessageElement() {
1588
+ return this.shadowRoot?.querySelector("#validation-message");
1818
1589
  }
1819
1590
  reset() {
1820
1591
  this.response = null;
1821
1592
  }
1822
- /**
1823
- * Called by the browser when the associated form is reset.
1824
- * Part of the Form-Associated Custom Elements API.
1825
- */
1826
1593
  formResetCallback() {
1827
1594
  this.reset();
1828
1595
  }
1829
- // attributeChangedCallback(name: string, _old: string | null, value: string | null): void {
1830
- // super.attributeChangedCallback(name, _old, value);
1831
- // // changing attributes in lit is not a thing, they are defined in the QTI XML and will never change
1832
- // // except in storybook where we can change the value of the attribute
1833
- // // this can make the internal state out of sync with the attribute
1834
- // // so we reset the value to null to force the internal state to be reset
1835
- // const attributeNamesToExclude = ['style', 'class'];
1836
- // if (!attributeNamesToExclude.includes(name)) {
1837
- // this.reset();
1838
- // }
1839
- // }
1840
1596
  connectedCallback() {
1841
1597
  super.connectedCallback();
1842
- if (this.isFullCorrectResponse) {
1843
- return;
1844
- }
1845
- this.dispatchEvent(
1846
- new CustomEvent("qti-register-interaction", {
1847
- bubbles: true,
1848
- composed: true,
1849
- cancelable: false,
1850
- detail: {
1851
- interactionElement: this,
1852
- responseIdentifier: this.responseIdentifier
1853
- }
1854
- })
1855
- );
1856
- }
1857
- firstUpdated() {
1858
- if (this.isFullCorrectResponse) {
1598
+ if (!this.registersWithItem) {
1859
1599
  return;
1860
1600
  }
1861
- if (this.showCorrectResponse) {
1862
- this.toggleInternalCorrectResponse(true);
1863
- }
1864
- if (this.showFullCorrectResponse) {
1865
- this.toggleFullCorrectResponse(true);
1866
- }
1867
- if (this.showCandidateCorrection) {
1868
- this.toggleCandidateCorrection(true);
1869
- }
1601
+ this.dispatchEvent(new CustomEvent("qti-register-interaction", {
1602
+ bubbles: true,
1603
+ composed: true,
1604
+ cancelable: false,
1605
+ detail: {
1606
+ interactionElement: this,
1607
+ responseIdentifier: this.responseIdentifier
1608
+ }
1609
+ }));
1870
1610
  }
1871
1611
  saveResponse(value, state) {
1872
- this.dispatchEvent(
1873
- new CustomEvent("qti-interaction-response", {
1874
- bubbles: true,
1875
- composed: true,
1876
- cancelable: false,
1877
- detail: {
1878
- responseIdentifier: this.responseIdentifier,
1879
- response: Array.isArray(value) ? [...value] : value,
1880
- ...state !== void 0 ? { state } : {}
1881
- }
1882
- })
1883
- );
1612
+ this.dispatchEvent(new CustomEvent("qti-interaction-response", {
1613
+ bubbles: true,
1614
+ composed: true,
1615
+ cancelable: false,
1616
+ detail: {
1617
+ responseIdentifier: this.responseIdentifier,
1618
+ response: Array.isArray(value) ? [...value] : value,
1619
+ ...state !== void 0 ? { state } : {}
1620
+ }
1621
+ }));
1622
+ }
1623
+ constructor() {
1624
+ super();
1625
+ this.#didLogDisableAfterIfMaxChoicesReachedDeprecation = false;
1626
+ this._interactionContext = { choiceRole: null, draggablesSelector: null };
1627
+ this.disabled = false;
1628
+ this.readonly = false;
1629
+ this._internals = this.attachInternals();
1630
+ }
1631
+ /** Optional lifecycle bridge for interaction subclasses that do not need changed-property data. */
1632
+ firstUpdated(_changedProperties) {
1884
1633
  }
1885
1634
  };
1886
- __decorateClass([
1635
+ __decorate([
1887
1636
  c({ context: itemContext, subscribe: true })
1888
- ], Interaction.prototype, "_context", 2);
1889
- __decorateClass([
1637
+ ], Interaction.prototype, "_context", void 0);
1638
+ __decorate([
1890
1639
  c({ context: configContext, subscribe: true })
1891
- ], Interaction.prototype, "configContext", 2);
1892
- __decorateClass([
1893
- n4({ type: String, attribute: "response-identifier" })
1894
- ], Interaction.prototype, "responseIdentifier", 2);
1895
- __decorateClass([
1896
- n4({ reflect: true, type: Boolean })
1897
- ], Interaction.prototype, "disabled", 2);
1898
- __decorateClass([
1899
- n4({ reflect: true, type: Boolean })
1900
- ], Interaction.prototype, "readonly", 2);
1901
- __decorateClass([
1902
- n4({ type: String })
1903
- ], Interaction.prototype, "name", 2);
1904
- __decorateClass([
1905
- n4({ type: String, attribute: "correct-response", reflect: true })
1906
- ], Interaction.prototype, "correctResponseAttr", 1);
1907
- __decorateClass([
1908
- n4({ type: Boolean, attribute: "show-correct-response", reflect: true })
1909
- ], Interaction.prototype, "showCorrectResponse", 2);
1910
- __decorateClass([
1911
- watch("showCorrectResponse", { waitUntilFirstUpdate: true })
1912
- ], Interaction.prototype, "_handleShowCorrectResponseChange", 2);
1913
- __decorateClass([
1914
- n4({ type: Boolean, attribute: "show-full-correct-response", reflect: true })
1915
- ], Interaction.prototype, "showFullCorrectResponse", 2);
1916
- __decorateClass([
1917
- watch("showFullCorrectResponse", { waitUntilFirstUpdate: true })
1918
- ], Interaction.prototype, "_handleShowFullCorrectResponseChange", 2);
1919
- __decorateClass([
1920
- n4({ type: Boolean, attribute: "show-candidate-correction", reflect: true })
1921
- ], Interaction.prototype, "showCandidateCorrection", 2);
1922
- __decorateClass([
1923
- watch("showCandidateCorrection", { waitUntilFirstUpdate: true })
1924
- ], Interaction.prototype, "_handleShowCandidateCorrectionChange", 2);
1925
- __decorateClass([
1926
- r4()
1927
- ], Interaction.prototype, "_isFullCorrectResponse", 2);
1928
- __decorateClass([
1929
- r4()
1930
- ], Interaction.prototype, "_correctResponse", 2);
1640
+ ], Interaction.prototype, "configContext", void 0);
1641
+ __decorate([
1642
+ e2({ context: interactionContext })
1643
+ ], Interaction.prototype, "_interactionContext", void 0);
1644
+ __decorate([
1645
+ n5({ type: String, attribute: "response-identifier" })
1646
+ ], Interaction.prototype, "responseIdentifier", void 0);
1647
+ __decorate([
1648
+ n5({ reflect: true, type: Boolean })
1649
+ ], Interaction.prototype, "disabled", void 0);
1650
+ __decorate([
1651
+ n5({ reflect: true, type: Boolean })
1652
+ ], Interaction.prototype, "readonly", void 0);
1653
+ __decorate([
1654
+ n5({ type: String })
1655
+ ], Interaction.prototype, "name", void 0);
1931
1656
 
1932
- // ../qti-base/src/abstract/qti-variable-declaration.ts
1657
+ // ../qti-base/dist/abstract/qti-variable-declaration.js
1933
1658
  var QtiVariableDeclaration = class extends i4 {
1934
1659
  render() {
1935
1660
  return T`<slot></slot>`;
@@ -1939,7 +1664,7 @@ var QtiVariableDeclaration = class extends i4 {
1939
1664
  if (htmlValues.length === 0) {
1940
1665
  return null;
1941
1666
  }
1942
- const defaultValues = htmlValues.map((n8) => n8.innerHTML.trim());
1667
+ const defaultValues = htmlValues.map((n6) => n6.innerHTML.trim());
1943
1668
  if (defaultValues.length > 1 || cardinality === "multiple" || cardinality === "ordered") {
1944
1669
  return defaultValues;
1945
1670
  }
@@ -1947,25 +1672,31 @@ var QtiVariableDeclaration = class extends i4 {
1947
1672
  }
1948
1673
  };
1949
1674
 
1950
- // ../qti-base/src/abstract/qti-expression.ts
1675
+ // ../qti-base/dist/abstract/qti-expression.js
1676
+ var __decorate2 = function(decorators, target, key, desc) {
1677
+ var c5 = arguments.length, r6 = c5 < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d3;
1678
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r6 = Reflect.decorate(decorators, target, key, desc);
1679
+ else for (var i5 = decorators.length - 1; i5 >= 0; i5--) if (d3 = decorators[i5]) r6 = (c5 < 3 ? d3(r6) : c5 > 3 ? d3(target, key, r6) : d3(target, key)) || r6;
1680
+ return c5 > 3 && r6 && Object.defineProperty(target, key, r6), r6;
1681
+ };
1951
1682
  var QtiExpression = class extends i4 {
1952
1683
  constructor() {
1953
1684
  super(...arguments);
1954
1685
  this.getVariables = () => (
1955
1686
  // FIXME: if this itself is multiple, this will never enter the qti-multiple switch
1956
1687
  // See this example here: https://github.com/1EdTech/qti-examples/blob/master/qtiv3-examples/packaging/items/Example05-feedbackBlock-adaptive.xml
1957
- Array.from(this.children).map((e8) => {
1958
- console.debug("getVariables", e8.tagName.toLowerCase());
1959
- switch (e8.tagName.toLowerCase()) {
1688
+ Array.from(this.children).map((e7) => {
1689
+ console.debug("getVariables", e7.tagName.toLowerCase());
1690
+ switch (e7.tagName.toLowerCase()) {
1960
1691
  case "qti-base-value": {
1961
1692
  return {
1962
- baseType: e8.getAttribute("base-type"),
1963
- value: e8.textContent.trim(),
1693
+ baseType: e7.getAttribute("base-type"),
1694
+ value: e7.textContent.trim(),
1964
1695
  cardinality: "single"
1965
1696
  };
1966
1697
  }
1967
1698
  case "qti-variable": {
1968
- const identifier = e8.getAttribute("identifier") || "";
1699
+ const identifier = e7.getAttribute("identifier") || "";
1969
1700
  if (identifier === "QTI_CONTEXT") {
1970
1701
  if (!this.qtiContext?.QTI_CONTEXT) {
1971
1702
  console.warn("QTI_CONTEXT not available");
@@ -1985,18 +1716,18 @@ var QtiExpression = class extends i4 {
1985
1716
  type: "context"
1986
1717
  };
1987
1718
  }
1988
- const variable = this.context.variables.find((v3) => v3.identifier === identifier) || null;
1719
+ const variable = this.context.variables.find((v2) => v2.identifier === identifier) || null;
1989
1720
  return variable;
1990
1721
  }
1991
1722
  case "qti-multiple": {
1992
- const multiple = e8;
1723
+ const multiple = e7;
1993
1724
  const values = multiple.getResult();
1994
1725
  console.debug("values", values);
1995
1726
  if (values?.length > 0) {
1996
1727
  return {
1997
1728
  identifier: "",
1998
1729
  baseType: values[0].baseType,
1999
- value: values.map((v3) => v3.value),
1730
+ value: values.map((v2) => v2.value),
2000
1731
  cardinality: "multiple",
2001
1732
  type: "response"
2002
1733
  };
@@ -2004,13 +1735,13 @@ var QtiExpression = class extends i4 {
2004
1735
  return null;
2005
1736
  }
2006
1737
  case "qti-ordered": {
2007
- const multiple = e8;
1738
+ const multiple = e7;
2008
1739
  const values = multiple.getResult();
2009
1740
  if (values?.length > 0) {
2010
1741
  return {
2011
1742
  identifier: "",
2012
1743
  baseType: values[0].baseType,
2013
- value: values.map((v3) => v3.value),
1744
+ value: values.map((v2) => v2.value),
2014
1745
  cardinality: "ordered",
2015
1746
  type: "response"
2016
1747
  };
@@ -2018,7 +1749,7 @@ var QtiExpression = class extends i4 {
2018
1749
  return null;
2019
1750
  }
2020
1751
  case "qti-repeat": {
2021
- const repeat = e8;
1752
+ const repeat = e7;
2022
1753
  const values = repeat.getResult();
2023
1754
  if (values?.length > 0) {
2024
1755
  return values;
@@ -2026,8 +1757,8 @@ var QtiExpression = class extends i4 {
2026
1757
  return null;
2027
1758
  }
2028
1759
  case "qti-correct": {
2029
- const identifier = e8.getAttribute("identifier") || "";
2030
- const responseVariable = this.context?.variables?.find((v3) => v3.identifier === identifier) || null;
1760
+ const identifier = e7.getAttribute("identifier") || "";
1761
+ const responseVariable = this.context?.variables?.find((v2) => v2.identifier === identifier) || null;
2031
1762
  return {
2032
1763
  baseType: responseVariable.baseType,
2033
1764
  value: responseVariable.correctResponse,
@@ -2036,7 +1767,7 @@ var QtiExpression = class extends i4 {
2036
1767
  }
2037
1768
  default: {
2038
1769
  try {
2039
- const expression = e8;
1770
+ const expression = e7;
2040
1771
  const value = expression.getResult();
2041
1772
  return {
2042
1773
  baseType: "integer",
@@ -2049,11 +1780,10 @@ var QtiExpression = class extends i4 {
2049
1780
  return null;
2050
1781
  }
2051
1782
  }
2052
- }).flatMap((v3) => Array.isArray(v3) ? v3 : [v3]).filter((v3) => v3 !== null)
1783
+ }).flatMap((v2) => Array.isArray(v2) ? v2 : [v2]).filter((v2) => v2 !== null)
2053
1784
  );
2054
1785
  }
2055
1786
  static {
2056
- // hide the slot with css
2057
1787
  this.styles = i2`
2058
1788
  slot {
2059
1789
  display: none;
@@ -2072,19 +1802,19 @@ var QtiExpression = class extends i4 {
2072
1802
  throw new Error("Not implemented");
2073
1803
  }
2074
1804
  };
2075
- __decorateClass([
2076
- r4()
2077
- ], QtiExpression.prototype, "result", 2);
2078
- __decorateClass([
1805
+ __decorate2([
1806
+ r5()
1807
+ ], QtiExpression.prototype, "result", void 0);
1808
+ __decorate2([
2079
1809
  c({ context: itemContext, subscribe: true }),
2080
- r4()
2081
- ], QtiExpression.prototype, "context", 2);
2082
- __decorateClass([
1810
+ r5()
1811
+ ], QtiExpression.prototype, "context", void 0);
1812
+ __decorate2([
2083
1813
  c({ context: qtiContext, subscribe: true }),
2084
- r4()
2085
- ], QtiExpression.prototype, "qtiContext", 2);
1814
+ r5()
1815
+ ], QtiExpression.prototype, "qtiContext", void 0);
2086
1816
 
2087
- // ../qti-base/src/abstract/qti-condition-expression.ts
1817
+ // ../qti-base/dist/abstract/qti-condition-expression.js
2088
1818
  var QtiConditionExpression = class extends QtiExpression {
2089
1819
  calculate() {
2090
1820
  this.result = this.getResult();
@@ -2095,7 +1825,7 @@ var QtiConditionExpression = class extends QtiExpression {
2095
1825
  }
2096
1826
  };
2097
1827
 
2098
- // ../qti-base/src/utils/utils.ts
1828
+ // ../qti-base/dist/utils/utils.js
2099
1829
  var decimalSeparator = () => {
2100
1830
  return new Intl.NumberFormat().format(0.1).replace(/\d/g, "");
2101
1831
  };
@@ -2118,7 +1848,13 @@ function removeDoubleSlashes(str) {
2118
1848
  return singleForwardSlashes;
2119
1849
  }
2120
1850
 
2121
- // ../qti-base/src/abstract/qti-feedback.ts
1851
+ // ../qti-base/dist/abstract/qti-feedback.js
1852
+ var __decorate3 = function(decorators, target, key, desc) {
1853
+ var c5 = arguments.length, r6 = c5 < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d3;
1854
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r6 = Reflect.decorate(decorators, target, key, desc);
1855
+ else for (var i5 = decorators.length - 1; i5 >= 0; i5--) if (d3 = decorators[i5]) r6 = (c5 < 3 ? d3(r6) : c5 > 3 ? d3(target, key, r6) : d3(target, key)) || r6;
1856
+ return c5 > 3 && r6 && Object.defineProperty(target, key, r6), r6;
1857
+ };
2122
1858
  var QtiFeedback = class extends i4 {
2123
1859
  constructor() {
2124
1860
  super(...arguments);
@@ -2126,17 +1862,16 @@ var QtiFeedback = class extends i4 {
2126
1862
  }
2127
1863
  connectedCallback() {
2128
1864
  super.connectedCallback();
2129
- this.dispatchEvent(
2130
- new CustomEvent("qti-register-feedback", {
2131
- bubbles: true,
2132
- composed: true,
2133
- detail: this
2134
- })
2135
- );
1865
+ this.dispatchEvent(new CustomEvent("qti-register-feedback", {
1866
+ bubbles: true,
1867
+ composed: true,
1868
+ detail: this
1869
+ }));
2136
1870
  }
2137
1871
  checkShowFeedback(outcomeIdentifier) {
2138
- const outcomeVariable = this._context.variables.find((v3) => v3.identifier === outcomeIdentifier) || null;
2139
- if (this.outcomeIdentifier !== outcomeIdentifier || !outcomeVariable) return;
1872
+ const outcomeVariable = this._context.variables.find((v2) => v2.identifier === outcomeIdentifier) || null;
1873
+ if (this.outcomeIdentifier !== outcomeIdentifier || !outcomeVariable)
1874
+ return;
2140
1875
  let isFound = false;
2141
1876
  if (Array.isArray(outcomeVariable.value)) {
2142
1877
  isFound = outcomeVariable.value.includes(this.identifier);
@@ -2149,28 +1884,114 @@ var QtiFeedback = class extends i4 {
2149
1884
  this.showStatus = value && this.showHide === "show" || !value && this.showHide === "hide" ? "on" : "off";
2150
1885
  }
2151
1886
  };
2152
- __decorateClass([
2153
- n4({ type: String, attribute: "show-hide" })
2154
- ], QtiFeedback.prototype, "showHide", 2);
2155
- __decorateClass([
2156
- n4({ type: String, attribute: "outcome-identifier" })
2157
- ], QtiFeedback.prototype, "outcomeIdentifier", 2);
2158
- __decorateClass([
2159
- n4({ type: String })
2160
- ], QtiFeedback.prototype, "identifier", 2);
2161
- __decorateClass([
2162
- n4({ type: String, attribute: false })
2163
- ], QtiFeedback.prototype, "showStatus", 2);
2164
- __decorateClass([
1887
+ __decorate3([
1888
+ n5({ type: String, attribute: "show-hide" })
1889
+ ], QtiFeedback.prototype, "showHide", void 0);
1890
+ __decorate3([
1891
+ n5({ type: String, attribute: "outcome-identifier" })
1892
+ ], QtiFeedback.prototype, "outcomeIdentifier", void 0);
1893
+ __decorate3([
1894
+ n5({ type: String })
1895
+ ], QtiFeedback.prototype, "identifier", void 0);
1896
+ __decorate3([
1897
+ n5({ type: String, attribute: false })
1898
+ ], QtiFeedback.prototype, "showStatus", void 0);
1899
+ __decorate3([
2165
1900
  c({ context: itemContext, subscribe: true }),
2166
- r4()
2167
- ], QtiFeedback.prototype, "_context", 2);
1901
+ r5()
1902
+ ], QtiFeedback.prototype, "_context", void 0);
1903
+
1904
+ // ../qti-base/dist/lib/response.js
1905
+ function parseResponseAttribute(raw) {
1906
+ if (raw == null)
1907
+ return null;
1908
+ if (!raw.includes(",")) {
1909
+ const trimmed = raw.trim();
1910
+ return trimmed.length > 0 ? trimmed : null;
1911
+ }
1912
+ const tokens = raw.split(",").map((token) => token.trim()).filter((token) => token.length > 0);
1913
+ if (tokens.length === 0)
1914
+ return null;
1915
+ if (tokens.length === 1)
1916
+ return tokens[0];
1917
+ return tokens;
1918
+ }
1919
+ function serializeResponseAttribute(value) {
1920
+ if (value == null)
1921
+ return null;
1922
+ if (Array.isArray(value)) {
1923
+ const tokens = value.map((token) => token.trim()).filter((token) => token.length > 0);
1924
+ return tokens.length > 0 ? tokens.join(",") : null;
1925
+ }
1926
+ const trimmed = value.trim();
1927
+ return trimmed.length > 0 ? trimmed : null;
1928
+ }
1929
+ function* iterResponseValues(raw) {
1930
+ if (raw == null)
1931
+ return;
1932
+ if (Array.isArray(raw)) {
1933
+ for (const v2 of raw) {
1934
+ const t4 = v2.trim();
1935
+ if (t4)
1936
+ yield t4;
1937
+ }
1938
+ return;
1939
+ }
1940
+ if (!raw.includes(",")) {
1941
+ const t4 = raw.trim();
1942
+ if (t4)
1943
+ yield t4;
1944
+ return;
1945
+ }
1946
+ for (const v2 of raw.split(",")) {
1947
+ const t4 = v2.trim();
1948
+ if (t4)
1949
+ yield t4;
1950
+ }
1951
+ }
1952
+ function parsePair(value) {
1953
+ const [source, target, ...rest] = value.trim().split(/\s+/);
1954
+ if (!source || !target || rest.length > 0) {
1955
+ throw new Error(`malformed directed-pair value: "${value}" (expected "source target")`);
1956
+ }
1957
+ return { source, target };
1958
+ }
1959
+ function serializePair(source, target) {
1960
+ return `${source} ${target}`;
1961
+ }
1962
+ function parsePoint(value) {
1963
+ const [xStr, yStr, ...rest] = value.trim().split(/\s+/);
1964
+ const x2 = Number(xStr);
1965
+ const y3 = Number(yStr);
1966
+ if (!Number.isFinite(x2) || !Number.isFinite(y3) || rest.length > 0) {
1967
+ throw new Error(`malformed point value: "${value}" (expected "x y" numeric coords)`);
1968
+ }
1969
+ return { x: x2, y: y3 };
1970
+ }
1971
+ function serializePoint(x2, y3) {
1972
+ return `${x2} ${y3}`;
1973
+ }
1974
+ function responseAttributeConverter(opts) {
1975
+ const { emptyAs } = opts;
1976
+ const isEmptySentinel = (value) => value === emptyAs || value == null || value === "" || Array.isArray(value) && value.length === 0;
1977
+ return {
1978
+ fromAttribute: (value) => {
1979
+ const parsed = parseResponseAttribute(value);
1980
+ return parsed === null ? emptyAs : parsed;
1981
+ },
1982
+ toAttribute: (value) => {
1983
+ if (isEmptySentinel(value))
1984
+ return null;
1985
+ return serializeResponseAttribute(value);
1986
+ }
1987
+ };
1988
+ }
2168
1989
 
2169
- // ../qti-base/src/lib/qti-rule-base.ts
1990
+ // ../qti-base/dist/lib/qti-rule-base.js
2170
1991
  var QtiRuleElement = class extends i4 {
2171
1992
  };
2172
1993
 
2173
- // ../qti-base/src/utils/scoring-helper.ts
1994
+ // ../qti-base/dist/utils/scoring-helper.js
2174
1995
  var ScoringHelper = class {
2175
1996
  /**
2176
1997
  * Checks if a given point is within a specified area.
@@ -2222,8 +2043,8 @@ var ScoringHelper = class {
2222
2043
  return false;
2223
2044
  }
2224
2045
  const vertices = [];
2225
- for (let i7 = 0; i7 < coordinates.length; i7 += 2) {
2226
- vertices.push({ x: coordinates[i7], y: coordinates[i7 + 1] });
2046
+ for (let i5 = 0; i5 < coordinates.length; i5 += 2) {
2047
+ vertices.push({ x: coordinates[i5], y: coordinates[i5 + 1] });
2227
2048
  }
2228
2049
  return this.isPointInPolygon({ x: px, y: py }, vertices);
2229
2050
  }
@@ -2240,11 +2061,12 @@ var ScoringHelper = class {
2240
2061
  */
2241
2062
  static isPointInPolygon(point, vertices) {
2242
2063
  let inside = false;
2243
- for (let i7 = 0, j2 = vertices.length - 1; i7 < vertices.length; j2 = i7++) {
2244
- const xi = vertices[i7].x, yi = vertices[i7].y;
2064
+ for (let i5 = 0, j2 = vertices.length - 1; i5 < vertices.length; j2 = i5++) {
2065
+ const xi = vertices[i5].x, yi = vertices[i5].y;
2245
2066
  const xj = vertices[j2].x, yj = vertices[j2].y;
2246
2067
  const intersect = yi > point.y !== yj > point.y && point.x < (xj - xi) * (point.y - yi) / (yj - yi) + xi;
2247
- if (intersect) inside = !inside;
2068
+ if (intersect)
2069
+ inside = !inside;
2248
2070
  }
2249
2071
  return inside;
2250
2072
  }
@@ -2293,14 +2115,26 @@ var ScoringHelper = class {
2293
2115
  }
2294
2116
  };
2295
2117
 
2118
+ // ../qti-base/dist/elements.js
2119
+ var qtiBaseElements = [];
2120
+
2121
+ // ../qti-base/dist/register.js
2122
+ for (const { tag, ctor } of qtiBaseElements) {
2123
+ if (!customElements.get(tag)) {
2124
+ customElements.define(tag, ctor);
2125
+ }
2126
+ }
2127
+
2296
2128
  export {
2129
+ n,
2297
2130
  e2 as e,
2298
2131
  c,
2299
2132
  computedItemContext,
2300
2133
  computedContext,
2301
2134
  configContext,
2302
- itemContextVariables,
2135
+ interactionContext,
2303
2136
  itemContext,
2137
+ itemContextVariables,
2304
2138
  isSeed,
2305
2139
  asSeed,
2306
2140
  qtiContext,
@@ -2308,29 +2142,20 @@ export {
2308
2142
  sessionContext,
2309
2143
  INITIAL_TEST_CONTEXT,
2310
2144
  testContext,
2311
- t2 as t,
2312
2145
  i2 as i,
2313
- n4 as n,
2314
- r4 as r,
2315
- e5 as e2,
2316
- o4 as o,
2317
2146
  T,
2318
2147
  b2 as b,
2319
2148
  E,
2320
2149
  A,
2150
+ Z,
2321
2151
  i4 as i2,
2322
- watch,
2323
- t5 as t2,
2324
- e7 as e3,
2325
- i5 as i3,
2326
- n6 as n2,
2327
- v2 as v,
2328
- u3 as u,
2329
- p3 as p,
2330
- M2 as M,
2331
- h3 as h,
2332
- f3 as f,
2333
- Correctness,
2152
+ boxSizing,
2153
+ dropRegion,
2154
+ validationMessage,
2155
+ n5 as n2,
2156
+ r5 as r,
2157
+ e6 as e2,
2158
+ o6 as o,
2334
2159
  Interaction,
2335
2160
  QtiVariableDeclaration,
2336
2161
  QtiExpression,
@@ -2340,6 +2165,14 @@ export {
2340
2165
  IsNullOrUndefined,
2341
2166
  removeDoubleSlashes,
2342
2167
  QtiFeedback,
2168
+ parseResponseAttribute,
2169
+ serializeResponseAttribute,
2170
+ iterResponseValues,
2171
+ parsePair,
2172
+ serializePair,
2173
+ parsePoint,
2174
+ serializePoint,
2175
+ responseAttributeConverter,
2343
2176
  QtiRuleElement,
2344
2177
  ScoringHelper
2345
2178
  };
@@ -2359,6 +2192,8 @@ export {
2359
2192
  *)
2360
2193
 
2361
2194
  @lit/context/lib/decorators/provide.js:
2195
+ lit-html/node/lit-html.js:
2196
+ lit-element/lit-element.js:
2362
2197
  @lit/reactive-element/node/decorators/custom-element.js:
2363
2198
  @lit/reactive-element/node/decorators/property.js:
2364
2199
  @lit/reactive-element/node/decorators/state.js:
@@ -2368,10 +2203,6 @@ export {
2368
2203
  @lit/reactive-element/node/decorators/query-all.js:
2369
2204
  @lit/reactive-element/node/decorators/query-async.js:
2370
2205
  @lit/reactive-element/node/decorators/query-assigned-nodes.js:
2371
- lit-html/node/lit-html.js:
2372
- lit-element/lit-element.js:
2373
- lit-html/node/directive.js:
2374
- lit-html/node/async-directive.js:
2375
2206
  (**
2376
2207
  * @license
2377
2208
  * Copyright 2017 Google LLC
@@ -2408,12 +2239,5 @@ lit-html/node/is-server.js:
2408
2239
  * Copyright 2019 Google LLC
2409
2240
  * SPDX-License-Identifier: BSD-3-Clause
2410
2241
  *)
2411
-
2412
- lit-html/node/directive-helpers.js:
2413
- (**
2414
- * @license
2415
- * Copyright 2020 Google LLC
2416
- * SPDX-License-Identifier: BSD-3-Clause
2417
- *)
2418
2242
  */
2419
- //# sourceMappingURL=chunk-3XV26R5M.js.map
2243
+ //# sourceMappingURL=chunk-H3J7LFRO.js.map