@citolab/qti-components 7.28.0 → 8.0.0

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