@pie-element/simple-cloze 0.1.4-next.0 → 0.1.4-next.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/author.js +2 -0
- package/dist/author/index.d.ts +2 -10
- package/dist/author/index.js +7196 -4017
- package/dist/author/index.js.map +1 -1
- package/dist/browser/author/index.js +17049 -0
- package/dist/browser/author/index.js.map +1 -0
- package/dist/browser/client-C4zbv8nl.js +2355 -0
- package/dist/browser/client-C4zbv8nl.js.map +1 -0
- package/dist/browser/controller/index.js +2 -0
- package/dist/browser/controller-1IBOQFFL.js +69 -0
- package/dist/browser/controller-1IBOQFFL.js.map +1 -0
- package/dist/browser/delivery/index.js +243 -0
- package/dist/browser/delivery/index.js.map +1 -0
- package/dist/browser/i18n-BaF24Jzw.js +1610 -0
- package/dist/browser/i18n-BaF24Jzw.js.map +1 -0
- package/dist/browser/plain-text-iaQZhkGe.js +53 -0
- package/dist/browser/plain-text-iaQZhkGe.js.map +1 -0
- package/dist/browser/print/index.js +71 -0
- package/dist/browser/print/index.js.map +1 -0
- package/dist/controller/defaults.d.ts +6 -0
- package/dist/controller/index.d.ts +51 -8
- package/dist/controller/index.js +132 -33
- package/dist/controller/index.js.map +1 -1
- package/dist/controller/plain-text.d.ts +11 -0
- package/dist/delivery/index.d.ts +2 -14
- package/dist/delivery/index.js +5921 -3314
- package/dist/delivery/index.js.map +1 -1
- package/dist/i18n.d.ts +7 -0
- package/dist/index.iife.js +9 -3
- package/dist/index.js +2 -4809
- package/dist/print/index.d.ts +6 -7
- package/dist/print/index.js +6287 -3493
- package/dist/print/index.js.map +1 -1
- package/dist/runtime-support.js +5 -5
- package/dist/runtime-support.js.map +1 -1
- package/module/print.js +3787 -0
- package/module/print.js.map +1 -0
- package/package.json +27 -17
- package/print.js +2 -0
- package/dist/index.js.map +0 -1
package/module/print.js
ADDED
|
@@ -0,0 +1,3787 @@
|
|
|
1
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/disclose-version.js
|
|
2
|
+
typeof window < "u" && ((window.__svelte ??= {}).v ??= /* @__PURE__ */ new Set()).add("5");
|
|
3
|
+
//#endregion
|
|
4
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/constants.js
|
|
5
|
+
var e = {}, t = Symbol("uninitialized"), n = "http://www.w3.org/1999/xhtml", r = "http://www.w3.org/2000/svg", i = "http://www.w3.org/1998/Math/MathML", a = Array.isArray, o = Array.prototype.indexOf, s = Array.prototype.includes, c = Array.from, l = Object.keys, u = Object.defineProperty, d = Object.getOwnPropertyDescriptor, f = Object.getOwnPropertyDescriptors, p = Object.prototype, m = Array.prototype, h = Object.getPrototypeOf, g = Object.isExtensible, ee = () => {};
|
|
6
|
+
function _(e) {
|
|
7
|
+
for (var t = 0; t < e.length; t++) e[t]();
|
|
8
|
+
}
|
|
9
|
+
function v() {
|
|
10
|
+
var e, t;
|
|
11
|
+
return {
|
|
12
|
+
promise: new Promise((n, r) => {
|
|
13
|
+
e = n, t = r;
|
|
14
|
+
}),
|
|
15
|
+
resolve: e,
|
|
16
|
+
reject: t
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
var y = 1024, b = 2048, te = 4096, ne = 8192, re = 16384, x = 32768, S = 1 << 25, ie = 65536, ae = 1 << 19, oe = 1 << 20, se = 65536, ce = 1 << 21, le = 1 << 22, ue = 1 << 23, de = Symbol("$state"), fe = Symbol("component"), pe = Symbol("legacy props"), me = Symbol(""), he = Symbol("attributes"), ge = Symbol("class"), _e = Symbol("style"), ve = Symbol("text"), ye = new class extends Error {
|
|
20
|
+
name = "StaleReactionError";
|
|
21
|
+
message = "The reaction that called `getAbortSignal()` was re-run or destroyed";
|
|
22
|
+
}(), be = !!globalThis.document?.contentType && /* @__PURE__ */ globalThis.document.contentType.includes("xml");
|
|
23
|
+
function xe() {
|
|
24
|
+
console.warn("https://svelte.dev/e/derived_inert");
|
|
25
|
+
}
|
|
26
|
+
function Se(e) {
|
|
27
|
+
console.warn("https://svelte.dev/e/hydration_mismatch");
|
|
28
|
+
}
|
|
29
|
+
function Ce() {
|
|
30
|
+
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
31
|
+
}
|
|
32
|
+
//#endregion
|
|
33
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/hydration.js
|
|
34
|
+
var C = !1;
|
|
35
|
+
function we(e) {
|
|
36
|
+
C = e;
|
|
37
|
+
}
|
|
38
|
+
var w;
|
|
39
|
+
function T(t) {
|
|
40
|
+
if (t === null) throw Se(), e;
|
|
41
|
+
return w = t;
|
|
42
|
+
}
|
|
43
|
+
function Te() {
|
|
44
|
+
return T(/* @__PURE__ */ F(w));
|
|
45
|
+
}
|
|
46
|
+
function Ee(t) {
|
|
47
|
+
if (C) {
|
|
48
|
+
if (/* @__PURE__ */ F(w) !== null) throw Se(), e;
|
|
49
|
+
w = t;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
function De(e = 1) {
|
|
53
|
+
if (C) {
|
|
54
|
+
for (var t = e, n = w; t--;) n = /* @__PURE__ */ F(n);
|
|
55
|
+
w = n;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
function Oe(e = !0) {
|
|
59
|
+
for (var t = 0, n = w;;) {
|
|
60
|
+
if (n.nodeType === 8) {
|
|
61
|
+
var r = n.data;
|
|
62
|
+
if (r === "]") {
|
|
63
|
+
if (t === 0) return n;
|
|
64
|
+
--t;
|
|
65
|
+
} else (r === "[" || r === "[!" || r[0] === "[" && !isNaN(Number(r.slice(1)))) && (t += 1);
|
|
66
|
+
}
|
|
67
|
+
var i = /* @__PURE__ */ F(n);
|
|
68
|
+
e && n.remove(), n = i;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
function ke(t) {
|
|
72
|
+
if (!t || t.nodeType !== 8) throw Se(), e;
|
|
73
|
+
return t.data;
|
|
74
|
+
}
|
|
75
|
+
//#endregion
|
|
76
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/equality.js
|
|
77
|
+
function Ae(e) {
|
|
78
|
+
return e === this.v;
|
|
79
|
+
}
|
|
80
|
+
function je(e, t) {
|
|
81
|
+
return e == e ? e !== t || typeof e == "object" && !!e || typeof e == "function" : t == t;
|
|
82
|
+
}
|
|
83
|
+
function Me(e) {
|
|
84
|
+
return !je(e, this.v);
|
|
85
|
+
}
|
|
86
|
+
//#endregion
|
|
87
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/errors.js
|
|
88
|
+
function Ne() {
|
|
89
|
+
throw Error("https://svelte.dev/e/async_derived_orphan");
|
|
90
|
+
}
|
|
91
|
+
function Pe(e) {
|
|
92
|
+
throw Error("https://svelte.dev/e/effect_in_teardown");
|
|
93
|
+
}
|
|
94
|
+
function Fe() {
|
|
95
|
+
throw Error("https://svelte.dev/e/effect_in_unowned_derived");
|
|
96
|
+
}
|
|
97
|
+
function Ie(e) {
|
|
98
|
+
throw Error("https://svelte.dev/e/effect_orphan");
|
|
99
|
+
}
|
|
100
|
+
function Le() {
|
|
101
|
+
throw Error("https://svelte.dev/e/effect_update_depth_exceeded");
|
|
102
|
+
}
|
|
103
|
+
function Re() {
|
|
104
|
+
throw Error("https://svelte.dev/e/hydration_failed");
|
|
105
|
+
}
|
|
106
|
+
function ze(e) {
|
|
107
|
+
throw Error("https://svelte.dev/e/props_invalid_value");
|
|
108
|
+
}
|
|
109
|
+
function Be() {
|
|
110
|
+
throw Error("https://svelte.dev/e/state_descriptors_fixed");
|
|
111
|
+
}
|
|
112
|
+
function Ve() {
|
|
113
|
+
throw Error("https://svelte.dev/e/state_prototype_fixed");
|
|
114
|
+
}
|
|
115
|
+
function He() {
|
|
116
|
+
throw Error("https://svelte.dev/e/state_unsafe_mutation");
|
|
117
|
+
}
|
|
118
|
+
function Ue() {
|
|
119
|
+
throw Error("https://svelte.dev/e/svelte_boundary_reset_onerror");
|
|
120
|
+
}
|
|
121
|
+
//#endregion
|
|
122
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/context.js
|
|
123
|
+
var E = null;
|
|
124
|
+
function We(e) {
|
|
125
|
+
E = e;
|
|
126
|
+
}
|
|
127
|
+
function Ge(e, t = !1, n) {
|
|
128
|
+
E = {
|
|
129
|
+
p: E,
|
|
130
|
+
i: !1,
|
|
131
|
+
c: null,
|
|
132
|
+
e: null,
|
|
133
|
+
s: e,
|
|
134
|
+
x: null,
|
|
135
|
+
r: W,
|
|
136
|
+
l: null
|
|
137
|
+
};
|
|
138
|
+
}
|
|
139
|
+
function Ke(e) {
|
|
140
|
+
var t = E, n = t.e;
|
|
141
|
+
if (n !== null) {
|
|
142
|
+
t.e = null;
|
|
143
|
+
for (var r of n) mn(r);
|
|
144
|
+
}
|
|
145
|
+
return e !== void 0 && (t.x = e), t.i = !0, E = t.p, qe(e);
|
|
146
|
+
}
|
|
147
|
+
function qe(e = {}) {
|
|
148
|
+
return u(e, fe, { value: !0 }), e;
|
|
149
|
+
}
|
|
150
|
+
function Je() {
|
|
151
|
+
return !0;
|
|
152
|
+
}
|
|
153
|
+
//#endregion
|
|
154
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/task.js
|
|
155
|
+
var Ye = [];
|
|
156
|
+
function Xe() {
|
|
157
|
+
var e = Ye;
|
|
158
|
+
Ye = [], _(e);
|
|
159
|
+
}
|
|
160
|
+
function Ze(e) {
|
|
161
|
+
if (Ye.length === 0 && !Ct) {
|
|
162
|
+
var t = Ye;
|
|
163
|
+
queueMicrotask(() => {
|
|
164
|
+
t === Ye && Xe();
|
|
165
|
+
});
|
|
166
|
+
}
|
|
167
|
+
Ye.push(e);
|
|
168
|
+
}
|
|
169
|
+
function Qe() {
|
|
170
|
+
for (; Ye.length > 0;) Xe();
|
|
171
|
+
}
|
|
172
|
+
//#endregion
|
|
173
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/status.js
|
|
174
|
+
var $e = ~(b | te | y);
|
|
175
|
+
function D(e, t) {
|
|
176
|
+
e.f = e.f & $e | t;
|
|
177
|
+
}
|
|
178
|
+
function et(e) {
|
|
179
|
+
e.f & 512 || e.deps === null ? D(e, y) : D(e, te);
|
|
180
|
+
}
|
|
181
|
+
//#endregion
|
|
182
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/utils.js
|
|
183
|
+
function tt(e) {
|
|
184
|
+
if (e !== null) for (let t of e) !(t.f & 2) || !(t.f & 65536) || (t.f ^= se, tt(t.deps));
|
|
185
|
+
}
|
|
186
|
+
function nt(e, t, n) {
|
|
187
|
+
e.f & 2048 ? t.add(e) : e.f & 4096 && n.add(e), tt(e.deps), D(e, y);
|
|
188
|
+
}
|
|
189
|
+
//#endregion
|
|
190
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/store.js
|
|
191
|
+
var rt = !1;
|
|
192
|
+
function it(e) {
|
|
193
|
+
var t = rt;
|
|
194
|
+
try {
|
|
195
|
+
return rt = !1, [e(), rt];
|
|
196
|
+
} finally {
|
|
197
|
+
rt = t;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
//#endregion
|
|
201
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/bindings/shared.js
|
|
202
|
+
function at(e) {
|
|
203
|
+
var t = V, n = W;
|
|
204
|
+
U(null), G(null);
|
|
205
|
+
try {
|
|
206
|
+
return e();
|
|
207
|
+
} finally {
|
|
208
|
+
U(t), G(n);
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/async.js
|
|
213
|
+
function ot(e, t, n, r) {
|
|
214
|
+
let i = Je() ? ut : mt;
|
|
215
|
+
var a = e.filter((e) => !e.settled), o = t.map(i);
|
|
216
|
+
if (n.length === 0 && a.length === 0) {
|
|
217
|
+
r(o);
|
|
218
|
+
return;
|
|
219
|
+
}
|
|
220
|
+
var s = W, c = st(), l = a.length === 1 ? a[0].promise : a.length > 1 ? Promise.all(a.map((e) => e.promise)) : null;
|
|
221
|
+
function u(e) {
|
|
222
|
+
if (!(s.f & 16384)) {
|
|
223
|
+
c();
|
|
224
|
+
try {
|
|
225
|
+
r([...o, ...e]);
|
|
226
|
+
} catch (e) {
|
|
227
|
+
I(e, s);
|
|
228
|
+
}
|
|
229
|
+
ct();
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
var d = lt();
|
|
233
|
+
if (n.length === 0) {
|
|
234
|
+
l.then(() => u([])).finally(d);
|
|
235
|
+
return;
|
|
236
|
+
}
|
|
237
|
+
function f() {
|
|
238
|
+
Promise.all(n.map((e) => /* @__PURE__ */ ft(e))).then(u).catch((e) => I(e, s)).finally(d);
|
|
239
|
+
}
|
|
240
|
+
l ? l.then(() => {
|
|
241
|
+
c(), f(), ct();
|
|
242
|
+
}) : f();
|
|
243
|
+
}
|
|
244
|
+
function st() {
|
|
245
|
+
var e = W, t = V, n = E, r = O;
|
|
246
|
+
return function(i = !0) {
|
|
247
|
+
G(e), U(t), We(n), i && !(e.f & 16384) && (r?.activate(), r?.apply());
|
|
248
|
+
};
|
|
249
|
+
}
|
|
250
|
+
function ct(e = !0) {
|
|
251
|
+
G(null), U(null), We(null), e && O?.deactivate();
|
|
252
|
+
}
|
|
253
|
+
function lt() {
|
|
254
|
+
var e = W, t = e.b, n = O, r = !!t?.is_rendered();
|
|
255
|
+
return t?.update_pending_count(1, n), n.increment(r, e), () => {
|
|
256
|
+
t?.update_pending_count(-1, n), n.decrement(r, e);
|
|
257
|
+
};
|
|
258
|
+
}
|
|
259
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
260
|
+
function ut(e) {
|
|
261
|
+
var n = 2 | b;
|
|
262
|
+
return W !== null && (W.f |= ae), {
|
|
263
|
+
ctx: E,
|
|
264
|
+
deps: null,
|
|
265
|
+
effects: null,
|
|
266
|
+
equals: Ae,
|
|
267
|
+
f: n,
|
|
268
|
+
fn: e,
|
|
269
|
+
reactions: null,
|
|
270
|
+
rv: 0,
|
|
271
|
+
v: t,
|
|
272
|
+
wv: 0,
|
|
273
|
+
parent: W,
|
|
274
|
+
ac: null
|
|
275
|
+
};
|
|
276
|
+
}
|
|
277
|
+
var dt = Symbol("obsolete");
|
|
278
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
279
|
+
function ft(e, n, r) {
|
|
280
|
+
let i = W;
|
|
281
|
+
i === null && Ne();
|
|
282
|
+
var a = void 0, o = Bt(t), s = !V, c = /* @__PURE__ */ new Set();
|
|
283
|
+
return vn(() => {
|
|
284
|
+
var t = W, n = v();
|
|
285
|
+
a = n.promise;
|
|
286
|
+
try {
|
|
287
|
+
Promise.resolve(e()).then(n.resolve, (e) => {
|
|
288
|
+
e !== ye && n.reject(e);
|
|
289
|
+
}).finally(ct);
|
|
290
|
+
} catch (e) {
|
|
291
|
+
n.reject(e), ct();
|
|
292
|
+
}
|
|
293
|
+
var r = O;
|
|
294
|
+
if (s) {
|
|
295
|
+
if (t.f & 32768) var l = lt();
|
|
296
|
+
if (i.b?.is_rendered()) r.async_deriveds.get(t)?.reject(dt);
|
|
297
|
+
else for (let e of c.values()) e.reject(dt);
|
|
298
|
+
c.add(n), r.async_deriveds.set(t, n);
|
|
299
|
+
}
|
|
300
|
+
let u = (e, t = void 0) => {
|
|
301
|
+
l?.(), c.delete(n), t !== dt && (r.activate(), t ? (o.f |= ue, Ht(o, t)) : (o.f & 8388608 && (o.f ^= ue), Ht(o, e)), r.deactivate());
|
|
302
|
+
};
|
|
303
|
+
n.promise.then(u, (e) => u(null, e || "unknown"));
|
|
304
|
+
}), fn(() => {
|
|
305
|
+
for (let e of c) e.reject(dt);
|
|
306
|
+
}), new Promise((e) => {
|
|
307
|
+
function t(n) {
|
|
308
|
+
function r() {
|
|
309
|
+
n === a ? e(o) : t(a);
|
|
310
|
+
}
|
|
311
|
+
n.then(r, r);
|
|
312
|
+
}
|
|
313
|
+
t(a);
|
|
314
|
+
});
|
|
315
|
+
}
|
|
316
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
317
|
+
function pt(e) {
|
|
318
|
+
let t = /* @__PURE__ */ ut(e);
|
|
319
|
+
return Fn(t), t;
|
|
320
|
+
}
|
|
321
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
322
|
+
function mt(e) {
|
|
323
|
+
let t = /* @__PURE__ */ ut(e);
|
|
324
|
+
return t.equals = Me, t;
|
|
325
|
+
}
|
|
326
|
+
function ht(e) {
|
|
327
|
+
var t = e.effects;
|
|
328
|
+
if (t !== null) {
|
|
329
|
+
e.effects = null;
|
|
330
|
+
for (var n = 0; n < t.length; n += 1) z(t[n]);
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
function gt(e) {
|
|
334
|
+
var n, r = W, i = e.parent;
|
|
335
|
+
if (!B && i !== null && e.v !== t && i.f & 24576) return xe(), e.v;
|
|
336
|
+
G(i);
|
|
337
|
+
try {
|
|
338
|
+
e.f &= ~se, ht(e), n = Wn(e);
|
|
339
|
+
} finally {
|
|
340
|
+
G(r);
|
|
341
|
+
}
|
|
342
|
+
return n;
|
|
343
|
+
}
|
|
344
|
+
function _t(e) {
|
|
345
|
+
var t = gt(e);
|
|
346
|
+
if (!e.equals(t) && (e.wv = Vn(), (!O?.is_fork || e.deps === null) && (O === null ? e.v = t : (O.capture(e, t, !0), xt?.capture(e, t, !0)), e.deps === null))) {
|
|
347
|
+
D(e, y);
|
|
348
|
+
return;
|
|
349
|
+
}
|
|
350
|
+
B || (k === null ? et(e) : (dn() || O?.is_fork) && k.set(e, t));
|
|
351
|
+
}
|
|
352
|
+
function vt(e) {
|
|
353
|
+
if (e.effects !== null) for (let t of e.effects) (t.teardown || t.ac) && (t.teardown?.(), t.ac !== null && at(() => {
|
|
354
|
+
t.ac.abort(ye), t.ac = null;
|
|
355
|
+
}), t.fn !== null && (t.teardown = ee), qn(t, 0), Cn(t));
|
|
356
|
+
}
|
|
357
|
+
function yt(e) {
|
|
358
|
+
if (e.effects !== null) for (let t of e.effects) t.teardown && t.fn !== null && Jn(t);
|
|
359
|
+
}
|
|
360
|
+
//#endregion
|
|
361
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/batch.js
|
|
362
|
+
var bt = null, O = null, xt = null, k = null, St = null, Ct = !1, wt = !1, Tt = null, Et = null, Dt = 0, Ot = 1, kt = class e {
|
|
363
|
+
id = Ot++;
|
|
364
|
+
#e = !1;
|
|
365
|
+
linked = !0;
|
|
366
|
+
#t = null;
|
|
367
|
+
#n = null;
|
|
368
|
+
async_deriveds = /* @__PURE__ */ new Map();
|
|
369
|
+
current = /* @__PURE__ */ new Map();
|
|
370
|
+
previous = /* @__PURE__ */ new Map();
|
|
371
|
+
#r = /* @__PURE__ */ new Set();
|
|
372
|
+
#i = /* @__PURE__ */ new Set();
|
|
373
|
+
#a = 0;
|
|
374
|
+
#o = /* @__PURE__ */ new Map();
|
|
375
|
+
#s = null;
|
|
376
|
+
#c = [];
|
|
377
|
+
#l = [];
|
|
378
|
+
#u = /* @__PURE__ */ new Set();
|
|
379
|
+
#d = /* @__PURE__ */ new Set();
|
|
380
|
+
#f = /* @__PURE__ */ new Map();
|
|
381
|
+
#p = /* @__PURE__ */ new Set();
|
|
382
|
+
is_fork = !1;
|
|
383
|
+
#m = !1;
|
|
384
|
+
constructor() {
|
|
385
|
+
bt === null ? bt = this : (bt.#n = this, this.#t = bt), bt = this;
|
|
386
|
+
}
|
|
387
|
+
#h() {
|
|
388
|
+
if (this.is_fork) return !0;
|
|
389
|
+
for (let n of this.#o.keys()) {
|
|
390
|
+
for (var e = n, t = !1; e.parent !== null;) {
|
|
391
|
+
if (this.#f.has(e)) {
|
|
392
|
+
t = !0;
|
|
393
|
+
break;
|
|
394
|
+
}
|
|
395
|
+
e = e.parent;
|
|
396
|
+
}
|
|
397
|
+
if (!t) return !0;
|
|
398
|
+
}
|
|
399
|
+
return !1;
|
|
400
|
+
}
|
|
401
|
+
skip_effect(e) {
|
|
402
|
+
this.#f.has(e) || this.#f.set(e, {
|
|
403
|
+
d: [],
|
|
404
|
+
m: []
|
|
405
|
+
}), this.#p.delete(e);
|
|
406
|
+
}
|
|
407
|
+
unskip_effect(e, t = (e) => this.schedule(e)) {
|
|
408
|
+
var n = this.#f.get(e);
|
|
409
|
+
if (n) {
|
|
410
|
+
this.#f.delete(e);
|
|
411
|
+
for (var r of n.d) D(r, b), t(r);
|
|
412
|
+
for (r of n.m) D(r, te), t(r);
|
|
413
|
+
}
|
|
414
|
+
this.#p.add(e);
|
|
415
|
+
}
|
|
416
|
+
#g() {
|
|
417
|
+
this.#e = !0, Dt++ > 1e3 && (this.#x(), jt());
|
|
418
|
+
for (let e of this.#u) this.#d.delete(e), D(e, b), this.schedule(e);
|
|
419
|
+
for (let e of this.#d) D(e, te), this.schedule(e);
|
|
420
|
+
let t = this.#c;
|
|
421
|
+
this.#c = [], this.apply();
|
|
422
|
+
var n = Tt = [], r = [], i = Et = [];
|
|
423
|
+
for (let e of t) try {
|
|
424
|
+
this.#_(e, n, r);
|
|
425
|
+
} catch (t) {
|
|
426
|
+
throw Lt(e), this.#h() || this.discard(), t;
|
|
427
|
+
}
|
|
428
|
+
if (O = null, i.length > 0) {
|
|
429
|
+
var a = e.ensure();
|
|
430
|
+
for (let e of i) a.schedule(e);
|
|
431
|
+
}
|
|
432
|
+
if (Tt = null, Et = null, this.#h()) {
|
|
433
|
+
this.#b(r), this.#b(n);
|
|
434
|
+
for (let [e, t] of this.#f) It(e, t);
|
|
435
|
+
i.length > 0 && O.#g();
|
|
436
|
+
return;
|
|
437
|
+
}
|
|
438
|
+
let o = this.#v();
|
|
439
|
+
if (o) {
|
|
440
|
+
this.#b(r), this.#b(n), o.#y(this);
|
|
441
|
+
return;
|
|
442
|
+
}
|
|
443
|
+
this.#u.clear(), this.#d.clear();
|
|
444
|
+
for (let e of this.#r) e(this);
|
|
445
|
+
this.#r.clear(), xt = this, Mt(r), Mt(n), xt = null, this.#s?.resolve();
|
|
446
|
+
var s = O;
|
|
447
|
+
if (this.#a === 0 && (this.#c.length === 0 || s !== null) && this.#x(), this.#c.length > 0) if (s !== null) {
|
|
448
|
+
let e = s;
|
|
449
|
+
e.#c.push(...this.#c.filter((t) => !e.#c.includes(t)));
|
|
450
|
+
} else s = this;
|
|
451
|
+
s !== null && (j.clear(), s.#g());
|
|
452
|
+
}
|
|
453
|
+
#_(e, t, n) {
|
|
454
|
+
e.f ^= y;
|
|
455
|
+
for (var r = e.first; r !== null;) {
|
|
456
|
+
var i = r.f, a = (i & 96) != 0;
|
|
457
|
+
if (!(a && i & 1024 || i & 8192 || this.#f.has(r)) && r.fn !== null) {
|
|
458
|
+
a ? r.f ^= y : i & 4 ? t.push(r) : Hn(r) && (i & 16 && this.#d.add(r), Jn(r));
|
|
459
|
+
var o = r.first;
|
|
460
|
+
if (o !== null) {
|
|
461
|
+
r = o;
|
|
462
|
+
continue;
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
for (; r !== null;) {
|
|
466
|
+
var s = r.next;
|
|
467
|
+
if (s !== null) {
|
|
468
|
+
r = s;
|
|
469
|
+
break;
|
|
470
|
+
}
|
|
471
|
+
r = r.parent;
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
}
|
|
475
|
+
#v() {
|
|
476
|
+
for (var e = this.#t; e !== null;) {
|
|
477
|
+
if (!e.is_fork) {
|
|
478
|
+
for (let [t, [, n]] of this.current) if (e.current.has(t) && !n) return e;
|
|
479
|
+
}
|
|
480
|
+
e = e.#t;
|
|
481
|
+
}
|
|
482
|
+
return null;
|
|
483
|
+
}
|
|
484
|
+
#y(e) {
|
|
485
|
+
for (let [t, n] of e.current) !this.previous.has(t) && e.previous.has(t) && this.previous.set(t, e.previous.get(t)), this.current.set(t, n);
|
|
486
|
+
for (let [t, n] of e.async_deriveds) {
|
|
487
|
+
let e = this.async_deriveds.get(t);
|
|
488
|
+
e && n.promise.then(e.resolve).catch(e.reject);
|
|
489
|
+
}
|
|
490
|
+
e.async_deriveds.clear(), this.transfer_effects(e.#u, e.#d);
|
|
491
|
+
let t = (e) => {
|
|
492
|
+
var n = e.reactions;
|
|
493
|
+
if (n !== null && !(e.f & 2 && !(e.f & 6144))) for (let e of n) {
|
|
494
|
+
var r = e.f;
|
|
495
|
+
if (r & 2) t(e);
|
|
496
|
+
else {
|
|
497
|
+
var i = e;
|
|
498
|
+
r & 4194320 && !this.async_deriveds.has(i) && (this.#d.delete(i), D(i, b), this.schedule(i));
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
};
|
|
502
|
+
for (let e of this.current.keys()) t(e);
|
|
503
|
+
this.oncommit(() => e.discard()), e.#x(), O = this, this.#g();
|
|
504
|
+
}
|
|
505
|
+
#b(e) {
|
|
506
|
+
for (var t = 0; t < e.length; t += 1) nt(e[t], this.#u, this.#d);
|
|
507
|
+
}
|
|
508
|
+
capture(e, n, r = !1) {
|
|
509
|
+
e.v !== t && !this.previous.has(e) && this.previous.set(e, e.v), e.f & 8388608 || (this.current.set(e, [n, r]), k?.set(e, n)), this.is_fork || (e.v = n);
|
|
510
|
+
}
|
|
511
|
+
activate() {
|
|
512
|
+
O = this;
|
|
513
|
+
}
|
|
514
|
+
deactivate() {
|
|
515
|
+
O = null, k = null;
|
|
516
|
+
}
|
|
517
|
+
flush() {
|
|
518
|
+
try {
|
|
519
|
+
wt = !0, O = this, this.#g();
|
|
520
|
+
} finally {
|
|
521
|
+
Dt = 0, St = null, Tt = null, Et = null, wt = !1, O = null, k = null, j.clear();
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
discard() {
|
|
525
|
+
for (let e of this.#i) e(this);
|
|
526
|
+
this.#i.clear();
|
|
527
|
+
for (let e of this.async_deriveds.values()) e.reject(dt);
|
|
528
|
+
this.#x(), this.#s?.resolve();
|
|
529
|
+
}
|
|
530
|
+
register_created_effect(e) {
|
|
531
|
+
this.#l.push(e);
|
|
532
|
+
}
|
|
533
|
+
increment(e, t) {
|
|
534
|
+
if (this.#a += 1, e) {
|
|
535
|
+
let e = this.#o.get(t) ?? 0;
|
|
536
|
+
this.#o.set(t, e + 1);
|
|
537
|
+
}
|
|
538
|
+
}
|
|
539
|
+
decrement(e, t) {
|
|
540
|
+
if (--this.#a, e) {
|
|
541
|
+
let e = this.#o.get(t) ?? 0;
|
|
542
|
+
e === 1 ? this.#o.delete(t) : this.#o.set(t, e - 1);
|
|
543
|
+
}
|
|
544
|
+
this.#m || (this.#m = !0, Ze(() => {
|
|
545
|
+
this.#m = !1, this.linked && this.flush();
|
|
546
|
+
}));
|
|
547
|
+
}
|
|
548
|
+
transfer_effects(e, t) {
|
|
549
|
+
for (let t of e) this.#u.add(t);
|
|
550
|
+
for (let e of t) this.#d.add(e);
|
|
551
|
+
e.clear(), t.clear();
|
|
552
|
+
}
|
|
553
|
+
oncommit(e) {
|
|
554
|
+
this.#r.add(e);
|
|
555
|
+
}
|
|
556
|
+
ondiscard(e) {
|
|
557
|
+
this.#i.add(e);
|
|
558
|
+
}
|
|
559
|
+
settled() {
|
|
560
|
+
return (this.#s ??= v()).promise;
|
|
561
|
+
}
|
|
562
|
+
static ensure() {
|
|
563
|
+
if (O === null) {
|
|
564
|
+
let t = O = new e();
|
|
565
|
+
!wt && !Ct && Ze(() => {
|
|
566
|
+
t.#e || t.flush();
|
|
567
|
+
});
|
|
568
|
+
}
|
|
569
|
+
return O;
|
|
570
|
+
}
|
|
571
|
+
apply() {
|
|
572
|
+
k = null;
|
|
573
|
+
}
|
|
574
|
+
schedule(e) {
|
|
575
|
+
if (St = e, e.b?.is_pending && e.f & 16777228 && !(e.f & 32768)) {
|
|
576
|
+
e.b.defer_effect(e);
|
|
577
|
+
return;
|
|
578
|
+
}
|
|
579
|
+
for (var t = e; t.parent !== null;) {
|
|
580
|
+
t = t.parent;
|
|
581
|
+
var n = t.f;
|
|
582
|
+
if (Tt !== null && t === W && (V === null || !(V.f & 2))) return;
|
|
583
|
+
if (n & 96) {
|
|
584
|
+
if (!(n & 1024)) return;
|
|
585
|
+
t.f ^= y;
|
|
586
|
+
}
|
|
587
|
+
}
|
|
588
|
+
this.#c.push(t);
|
|
589
|
+
}
|
|
590
|
+
#x() {
|
|
591
|
+
if (this.linked) {
|
|
592
|
+
var e = this.#t, t = this.#n;
|
|
593
|
+
e === null || (e.#n = t), t === null ? bt = e : t.#t = e, this.linked = !1;
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
};
|
|
597
|
+
function At(e) {
|
|
598
|
+
var t = Ct;
|
|
599
|
+
Ct = !0;
|
|
600
|
+
try {
|
|
601
|
+
var n;
|
|
602
|
+
for (e && (O !== null && !O.is_fork && O.flush(), n = e());;) {
|
|
603
|
+
if (Qe(), O === null) return n;
|
|
604
|
+
O.flush();
|
|
605
|
+
}
|
|
606
|
+
} finally {
|
|
607
|
+
Ct = t;
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
function jt() {
|
|
611
|
+
try {
|
|
612
|
+
Le();
|
|
613
|
+
} catch (e) {
|
|
614
|
+
I(e, St);
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
var A = null;
|
|
618
|
+
function Mt(e) {
|
|
619
|
+
var t = e.length;
|
|
620
|
+
if (t !== 0) {
|
|
621
|
+
for (var n = 0; n < t;) {
|
|
622
|
+
var r = e[n++];
|
|
623
|
+
if (!(r.f & 24576) && Hn(r) && (A = /* @__PURE__ */ new Set(), Jn(r), r.deps === null && r.first === null && r.nodes === null && r.teardown === null && r.ac === null && En(r), A?.size > 0)) {
|
|
624
|
+
j.clear();
|
|
625
|
+
for (let e of A) {
|
|
626
|
+
if (e.f & 24576) continue;
|
|
627
|
+
let t = [e], n = e.parent;
|
|
628
|
+
for (; n !== null;) A.has(n) && (A.delete(n), t.push(n)), n = n.parent;
|
|
629
|
+
for (let e = t.length - 1; e >= 0; e--) {
|
|
630
|
+
let n = t[e];
|
|
631
|
+
n.f & 24576 || Jn(n);
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
A.clear();
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
A = null;
|
|
638
|
+
}
|
|
639
|
+
}
|
|
640
|
+
function Nt(e, t, n, r) {
|
|
641
|
+
if (!n.has(e) && (n.add(e), e.reactions !== null)) for (let i of e.reactions) {
|
|
642
|
+
let e = i.f;
|
|
643
|
+
e & 2 ? Nt(i, t, n, r) : e & 4194320 && !(e & 2048) && Pt(i, t, r) && (D(i, b), Ft(i));
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
function Pt(e, t, n) {
|
|
647
|
+
let r = n.get(e);
|
|
648
|
+
if (r !== void 0) return r;
|
|
649
|
+
if (e.deps !== null) for (let r of e.deps) {
|
|
650
|
+
if (s.call(t, r)) return !0;
|
|
651
|
+
if (r.f & 2 && Pt(r, t, n)) return n.set(r, !0), !0;
|
|
652
|
+
}
|
|
653
|
+
return n.set(e, !1), !1;
|
|
654
|
+
}
|
|
655
|
+
function Ft(e) {
|
|
656
|
+
O.schedule(e);
|
|
657
|
+
}
|
|
658
|
+
function It(e, t) {
|
|
659
|
+
if (!(e.f & 32 && e.f & 1024)) {
|
|
660
|
+
e.f & 2048 ? t.d.push(e) : e.f & 4096 && t.m.push(e), D(e, y);
|
|
661
|
+
for (var n = e.first; n !== null;) It(n, t), n = n.next;
|
|
662
|
+
}
|
|
663
|
+
}
|
|
664
|
+
function Lt(e) {
|
|
665
|
+
D(e, y);
|
|
666
|
+
for (var t = e.first; t !== null;) Lt(t), t = t.next;
|
|
667
|
+
}
|
|
668
|
+
//#endregion
|
|
669
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/sources.js
|
|
670
|
+
var Rt = /* @__PURE__ */ new Set(), j = /* @__PURE__ */ new Map(), zt = !1;
|
|
671
|
+
function Bt(e, t) {
|
|
672
|
+
return {
|
|
673
|
+
f: 0,
|
|
674
|
+
v: e,
|
|
675
|
+
reactions: null,
|
|
676
|
+
equals: Ae,
|
|
677
|
+
rv: 0,
|
|
678
|
+
wv: 0
|
|
679
|
+
};
|
|
680
|
+
}
|
|
681
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
682
|
+
function M(e, t) {
|
|
683
|
+
let n = Bt(e, t);
|
|
684
|
+
return Fn(n), n;
|
|
685
|
+
}
|
|
686
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
687
|
+
function Vt(e, t = !1, n = !0) {
|
|
688
|
+
let r = Bt(e);
|
|
689
|
+
return t || (r.equals = Me), r;
|
|
690
|
+
}
|
|
691
|
+
function N(e, t, n = !1) {
|
|
692
|
+
return V !== null && (!H || V.f & 131072) && Je() && V.f & 4325394 && (K === null || !K.has(e)) && He(), Ht(e, n ? Kt(t) : t, Et);
|
|
693
|
+
}
|
|
694
|
+
function Ht(e, t, n = null) {
|
|
695
|
+
if (!e.equals(t)) {
|
|
696
|
+
B ? j.set(e, t) : j.has(e) || j.set(e, e.v);
|
|
697
|
+
var r = kt.ensure();
|
|
698
|
+
if (r.capture(e, t), e.f & 2) {
|
|
699
|
+
let t = e;
|
|
700
|
+
e.f & 2048 && gt(t), k === null && et(t);
|
|
701
|
+
}
|
|
702
|
+
e.wv = Vn(), Gt(e, b, n), Je() && W !== null && W.f & 1024 && !(W.f & 96) && (Y === null ? In([e]) : Y.push(e)), !r.is_fork && Rt.size > 0 && !zt && Ut();
|
|
703
|
+
}
|
|
704
|
+
return t;
|
|
705
|
+
}
|
|
706
|
+
function Ut() {
|
|
707
|
+
zt = !1;
|
|
708
|
+
for (let e of Rt) {
|
|
709
|
+
e.f & 1024 && D(e, te);
|
|
710
|
+
let t;
|
|
711
|
+
try {
|
|
712
|
+
t = Hn(e);
|
|
713
|
+
} catch {
|
|
714
|
+
t = !0;
|
|
715
|
+
}
|
|
716
|
+
t && Jn(e);
|
|
717
|
+
}
|
|
718
|
+
Rt.clear();
|
|
719
|
+
}
|
|
720
|
+
function Wt(e) {
|
|
721
|
+
N(e, e.v + 1);
|
|
722
|
+
}
|
|
723
|
+
function Gt(e, t, n) {
|
|
724
|
+
var r = e.reactions;
|
|
725
|
+
if (r !== null) for (var i = Je(), a = r.length, o = 0; o < a; o++) {
|
|
726
|
+
var s = r[o], c = s.f;
|
|
727
|
+
if (!(!i && s === W)) {
|
|
728
|
+
var l = (c & b) === 0;
|
|
729
|
+
if (l && D(s, t), c & 131072) Rt.add(s);
|
|
730
|
+
else if (c & 2) {
|
|
731
|
+
var u = s;
|
|
732
|
+
k?.delete(u), c & 65536 || (c & 512 && (W === null || !(W.f & 2097152)) && (s.f |= se), Gt(u, te, n));
|
|
733
|
+
} else if (l) {
|
|
734
|
+
var d = s;
|
|
735
|
+
c & 16 && A !== null && A.add(d), n === null ? Ft(d) : n.push(d);
|
|
736
|
+
}
|
|
737
|
+
}
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
function Kt(e) {
|
|
741
|
+
if (typeof e != "object" || !e || de in e || fe in e) return e;
|
|
742
|
+
let n = h(e);
|
|
743
|
+
if (n !== p && n !== m) return e;
|
|
744
|
+
var r = /* @__PURE__ */ new Map(), i = a(e), o = /* @__PURE__ */ M(0), s = null, c = zn, l = (e) => {
|
|
745
|
+
if (zn === c) return e();
|
|
746
|
+
var t = V, n = zn;
|
|
747
|
+
U(null), Bn(c);
|
|
748
|
+
var r = e();
|
|
749
|
+
return U(t), Bn(n), r;
|
|
750
|
+
};
|
|
751
|
+
return i && r.set("length", /* @__PURE__ */ M(e.length, s)), new Proxy(e, {
|
|
752
|
+
defineProperty(e, t, n) {
|
|
753
|
+
(!("value" in n) || n.configurable === !1 || n.enumerable === !1 || n.writable === !1) && Be();
|
|
754
|
+
var i = r.get(t);
|
|
755
|
+
return i === void 0 ? l(() => {
|
|
756
|
+
var e = /* @__PURE__ */ M(n.value, s);
|
|
757
|
+
return r.set(t, e), e;
|
|
758
|
+
}) : N(i, n.value, !0), !0;
|
|
759
|
+
},
|
|
760
|
+
deleteProperty(e, n) {
|
|
761
|
+
var i = r.get(n);
|
|
762
|
+
if (i === void 0) {
|
|
763
|
+
if (n in e) {
|
|
764
|
+
let e = l(() => /* @__PURE__ */ M(t, s));
|
|
765
|
+
r.set(n, e), Wt(o);
|
|
766
|
+
}
|
|
767
|
+
} else N(i, t), Wt(o);
|
|
768
|
+
return !0;
|
|
769
|
+
},
|
|
770
|
+
get(n, i, a) {
|
|
771
|
+
if (i === de) return e;
|
|
772
|
+
var o = r.get(i), c = i in n;
|
|
773
|
+
if (o === void 0 && (!c || d(n, i)?.writable) && (o = l(() => /* @__PURE__ */ M(Kt(c ? n[i] : t), s)), r.set(i, o)), o !== void 0) {
|
|
774
|
+
var u = X(o);
|
|
775
|
+
return u === t ? void 0 : u;
|
|
776
|
+
}
|
|
777
|
+
return Reflect.get(n, i, a);
|
|
778
|
+
},
|
|
779
|
+
getOwnPropertyDescriptor(e, n) {
|
|
780
|
+
var i = Reflect.getOwnPropertyDescriptor(e, n);
|
|
781
|
+
if (i && "value" in i) {
|
|
782
|
+
var a = r.get(n);
|
|
783
|
+
a && (i.value = X(a));
|
|
784
|
+
} else if (i === void 0) {
|
|
785
|
+
var o = r.get(n), s = o?.v;
|
|
786
|
+
if (o !== void 0 && s !== t) return {
|
|
787
|
+
enumerable: !0,
|
|
788
|
+
configurable: !0,
|
|
789
|
+
value: s,
|
|
790
|
+
writable: !0
|
|
791
|
+
};
|
|
792
|
+
}
|
|
793
|
+
return i;
|
|
794
|
+
},
|
|
795
|
+
has(e, n) {
|
|
796
|
+
if (n === de) return !0;
|
|
797
|
+
var i = r.get(n), a = i !== void 0 && i.v !== t || Reflect.has(e, n);
|
|
798
|
+
return (i !== void 0 || W !== null && (!a || d(e, n)?.writable)) && (i === void 0 && (i = l(() => /* @__PURE__ */ M(a ? Kt(e[n]) : t, s)), r.set(n, i)), X(i) === t) ? !1 : a;
|
|
799
|
+
},
|
|
800
|
+
set(e, n, a, c) {
|
|
801
|
+
var u = r.get(n), f = n in e;
|
|
802
|
+
if (i && n === "length") for (var p = a; p < u.v; p += 1) {
|
|
803
|
+
var m = r.get(p + "");
|
|
804
|
+
m === void 0 ? p in e && (m = l(() => /* @__PURE__ */ M(t, s)), r.set(p + "", m)) : N(m, t);
|
|
805
|
+
}
|
|
806
|
+
if (u === void 0) (!f || d(e, n)?.writable) && (u = l(() => /* @__PURE__ */ M(void 0, s)), N(u, Kt(a)), r.set(n, u));
|
|
807
|
+
else {
|
|
808
|
+
f = u.v !== t;
|
|
809
|
+
var h = l(() => Kt(a));
|
|
810
|
+
N(u, h);
|
|
811
|
+
}
|
|
812
|
+
var g = Reflect.getOwnPropertyDescriptor(e, n);
|
|
813
|
+
if (g?.set && g.set.call(c, a), !f) {
|
|
814
|
+
if (i && typeof n == "string") {
|
|
815
|
+
var ee = r.get("length"), _ = Number(n);
|
|
816
|
+
Number.isInteger(_) && _ >= ee.v && N(ee, _ + 1);
|
|
817
|
+
}
|
|
818
|
+
Wt(o);
|
|
819
|
+
}
|
|
820
|
+
return !0;
|
|
821
|
+
},
|
|
822
|
+
ownKeys(e) {
|
|
823
|
+
X(o);
|
|
824
|
+
var n = Reflect.ownKeys(e).filter((e) => {
|
|
825
|
+
var n = r.get(e);
|
|
826
|
+
return n === void 0 || n.v !== t;
|
|
827
|
+
});
|
|
828
|
+
for (var [i, a] of r) a.v !== t && !(i in e) && n.push(i);
|
|
829
|
+
return n;
|
|
830
|
+
},
|
|
831
|
+
setPrototypeOf() {
|
|
832
|
+
Ve();
|
|
833
|
+
}
|
|
834
|
+
});
|
|
835
|
+
}
|
|
836
|
+
var qt, Jt, Yt, Xt;
|
|
837
|
+
function Zt() {
|
|
838
|
+
if (qt === void 0) {
|
|
839
|
+
qt = window, Jt = /Firefox/.test(navigator.userAgent);
|
|
840
|
+
var e = Element.prototype, t = Node.prototype, n = Text.prototype;
|
|
841
|
+
Yt = d(t, "firstChild").get, Xt = d(t, "nextSibling").get, g(e) && (e[ge] = void 0, e[he] = null, e[_e] = void 0, e.__e = void 0), g(n) && (n[ve] = void 0);
|
|
842
|
+
}
|
|
843
|
+
}
|
|
844
|
+
function Qt(e = "") {
|
|
845
|
+
return document.createTextNode(e);
|
|
846
|
+
}
|
|
847
|
+
/*@__NO_SIDE_EFFECTS__*/
|
|
848
|
+
function P(e) {
|
|
849
|
+
return Yt.call(e);
|
|
850
|
+
}
|
|
851
|
+
/*@__NO_SIDE_EFFECTS__*/
|
|
852
|
+
function F(e) {
|
|
853
|
+
return Xt.call(e);
|
|
854
|
+
}
|
|
855
|
+
function $t(e, t) {
|
|
856
|
+
if (!C) return /* @__PURE__ */ P(e);
|
|
857
|
+
var n = /* @__PURE__ */ P(w);
|
|
858
|
+
if (n === null) n = w.appendChild(Qt());
|
|
859
|
+
else if (t && n.nodeType !== 3) {
|
|
860
|
+
var r = Qt();
|
|
861
|
+
return n?.before(r), T(r), r;
|
|
862
|
+
}
|
|
863
|
+
return t && sn(n), T(n), n;
|
|
864
|
+
}
|
|
865
|
+
function en(e, t = !1) {
|
|
866
|
+
if (!C) {
|
|
867
|
+
var n = /* @__PURE__ */ P(e);
|
|
868
|
+
return n instanceof Comment && n.data === "" ? /* @__PURE__ */ F(n) : n;
|
|
869
|
+
}
|
|
870
|
+
if (t) {
|
|
871
|
+
if (w?.nodeType !== 3) {
|
|
872
|
+
var r = Qt();
|
|
873
|
+
return w?.before(r), T(r), r;
|
|
874
|
+
}
|
|
875
|
+
sn(w);
|
|
876
|
+
}
|
|
877
|
+
return w;
|
|
878
|
+
}
|
|
879
|
+
function tn(e, t = !1) {
|
|
880
|
+
if (!C) return /* @__PURE__ */ P(e);
|
|
881
|
+
var n = $t(e, t);
|
|
882
|
+
return Ee(e), n;
|
|
883
|
+
}
|
|
884
|
+
function nn(e, t = 1, n = !1) {
|
|
885
|
+
let r = C ? w : e;
|
|
886
|
+
for (var i; t--;) i = r, r = /* @__PURE__ */ F(r);
|
|
887
|
+
if (!C) return r;
|
|
888
|
+
if (n) {
|
|
889
|
+
if (r?.nodeType !== 3) {
|
|
890
|
+
var a = Qt();
|
|
891
|
+
return r === null ? i?.after(a) : r.before(a), T(a), a;
|
|
892
|
+
}
|
|
893
|
+
sn(r);
|
|
894
|
+
}
|
|
895
|
+
return T(r), r;
|
|
896
|
+
}
|
|
897
|
+
function rn(e) {
|
|
898
|
+
e.textContent = "";
|
|
899
|
+
}
|
|
900
|
+
function an() {
|
|
901
|
+
return !1;
|
|
902
|
+
}
|
|
903
|
+
function on(e, t, n) {
|
|
904
|
+
return t == null || t === "http://www.w3.org/1999/xhtml" ? n ? document.createElement(e, { is: n }) : document.createElement(e) : n ? document.createElementNS(t, e, { is: n }) : document.createElementNS(t, e);
|
|
905
|
+
}
|
|
906
|
+
function sn(e) {
|
|
907
|
+
if (e.nodeValue.length < 65536) return;
|
|
908
|
+
let t = e.nextSibling;
|
|
909
|
+
for (; t !== null && t.nodeType === 3;) t.remove(), e.nodeValue += t.nodeValue, t = e.nextSibling;
|
|
910
|
+
}
|
|
911
|
+
function cn(e) {
|
|
912
|
+
var t = W;
|
|
913
|
+
if (t === null) return V.f |= ue, e;
|
|
914
|
+
if (!(t.f & 32768) && !(t.f & 4)) throw e;
|
|
915
|
+
I(e, t);
|
|
916
|
+
}
|
|
917
|
+
function I(e, t) {
|
|
918
|
+
if (!(t !== null && t.f & 16384)) {
|
|
919
|
+
for (; t !== null;) {
|
|
920
|
+
if (t.f & 128 && !(t.f & 33570816)) {
|
|
921
|
+
if (!(t.f & 32768)) throw e;
|
|
922
|
+
try {
|
|
923
|
+
t.b.error(e);
|
|
924
|
+
return;
|
|
925
|
+
} catch (t) {
|
|
926
|
+
e = t;
|
|
927
|
+
}
|
|
928
|
+
}
|
|
929
|
+
t = t.parent;
|
|
930
|
+
}
|
|
931
|
+
throw e;
|
|
932
|
+
}
|
|
933
|
+
}
|
|
934
|
+
//#endregion
|
|
935
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/effects.js
|
|
936
|
+
function ln(e) {
|
|
937
|
+
W === null && (V === null && Ie(e), Fe()), B && Pe(e);
|
|
938
|
+
}
|
|
939
|
+
function un(e, t) {
|
|
940
|
+
var n = t.last;
|
|
941
|
+
n === null ? t.last = t.first = e : (n.next = e, e.prev = n, t.last = e);
|
|
942
|
+
}
|
|
943
|
+
function L(e, t) {
|
|
944
|
+
var n = W;
|
|
945
|
+
n !== null && n.f & 8192 && (e |= ne);
|
|
946
|
+
var r = {
|
|
947
|
+
ctx: E,
|
|
948
|
+
deps: null,
|
|
949
|
+
nodes: null,
|
|
950
|
+
f: e | b | 512,
|
|
951
|
+
first: null,
|
|
952
|
+
fn: t,
|
|
953
|
+
last: null,
|
|
954
|
+
next: null,
|
|
955
|
+
parent: n,
|
|
956
|
+
b: n && n.b,
|
|
957
|
+
prev: null,
|
|
958
|
+
teardown: null,
|
|
959
|
+
wv: 0,
|
|
960
|
+
ac: null
|
|
961
|
+
};
|
|
962
|
+
O?.register_created_effect(r);
|
|
963
|
+
var i = r;
|
|
964
|
+
if (e & 4) Tt === null ? kt.ensure().schedule(r) : Tt.push(r);
|
|
965
|
+
else if (t !== null) {
|
|
966
|
+
try {
|
|
967
|
+
Jn(r);
|
|
968
|
+
} catch (e) {
|
|
969
|
+
throw z(r), e;
|
|
970
|
+
}
|
|
971
|
+
i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && !(i.f & 524288) && (i = i.first, e & 16 && e & 65536 && i !== null && (i.f |= ie));
|
|
972
|
+
}
|
|
973
|
+
if (i !== null && (i.parent = n, n !== null && un(i, n), V !== null && V.f & 2 && !(e & 64))) {
|
|
974
|
+
var a = V;
|
|
975
|
+
(a.effects ??= []).push(i);
|
|
976
|
+
}
|
|
977
|
+
return r;
|
|
978
|
+
}
|
|
979
|
+
function dn() {
|
|
980
|
+
return V !== null && !H;
|
|
981
|
+
}
|
|
982
|
+
function fn(e) {
|
|
983
|
+
let t = L(8, null);
|
|
984
|
+
return D(t, y), t.teardown = e, t;
|
|
985
|
+
}
|
|
986
|
+
function pn(e) {
|
|
987
|
+
ln("$effect");
|
|
988
|
+
var t = W.f;
|
|
989
|
+
if (!V && t & 32 && E !== null && !E.i) {
|
|
990
|
+
var n = E;
|
|
991
|
+
(n.e ??= []).push(e);
|
|
992
|
+
} else return mn(e);
|
|
993
|
+
}
|
|
994
|
+
function mn(e) {
|
|
995
|
+
return L(4 | oe, e);
|
|
996
|
+
}
|
|
997
|
+
function hn(e) {
|
|
998
|
+
kt.ensure();
|
|
999
|
+
let t = L(64 | ae, e);
|
|
1000
|
+
return () => {
|
|
1001
|
+
z(t);
|
|
1002
|
+
};
|
|
1003
|
+
}
|
|
1004
|
+
function gn(e) {
|
|
1005
|
+
kt.ensure();
|
|
1006
|
+
let t = L(64 | ae, e);
|
|
1007
|
+
return (e = {}) => new Promise((n) => {
|
|
1008
|
+
e.outro ? Dn(t, () => {
|
|
1009
|
+
z(t), n(void 0);
|
|
1010
|
+
}) : (z(t), n(void 0));
|
|
1011
|
+
});
|
|
1012
|
+
}
|
|
1013
|
+
function _n(e) {
|
|
1014
|
+
return L(4, e);
|
|
1015
|
+
}
|
|
1016
|
+
function vn(e) {
|
|
1017
|
+
return L(le | ae, e);
|
|
1018
|
+
}
|
|
1019
|
+
function yn(e, t = 0) {
|
|
1020
|
+
return L(8 | t, e);
|
|
1021
|
+
}
|
|
1022
|
+
function bn(e, t = [], n = [], r = []) {
|
|
1023
|
+
ot(r, t, n, (t) => {
|
|
1024
|
+
L(8, () => {
|
|
1025
|
+
e(...t.map(X));
|
|
1026
|
+
});
|
|
1027
|
+
});
|
|
1028
|
+
}
|
|
1029
|
+
function xn(e, t = 0) {
|
|
1030
|
+
return L(16 | t, e);
|
|
1031
|
+
}
|
|
1032
|
+
function R(e) {
|
|
1033
|
+
return L(32 | ae, e);
|
|
1034
|
+
}
|
|
1035
|
+
function Sn(e) {
|
|
1036
|
+
var t = e.teardown;
|
|
1037
|
+
if (t !== null) {
|
|
1038
|
+
let n = B, r = V;
|
|
1039
|
+
Pn(!0), U(null);
|
|
1040
|
+
try {
|
|
1041
|
+
t.call(null);
|
|
1042
|
+
} catch (t) {
|
|
1043
|
+
I(t, e.parent);
|
|
1044
|
+
} finally {
|
|
1045
|
+
Pn(n), U(r);
|
|
1046
|
+
}
|
|
1047
|
+
}
|
|
1048
|
+
}
|
|
1049
|
+
function Cn(e, t = !1) {
|
|
1050
|
+
var n = e.first;
|
|
1051
|
+
for (e.first = e.last = null; n !== null;) {
|
|
1052
|
+
let e = n.ac;
|
|
1053
|
+
e !== null && at(() => {
|
|
1054
|
+
e.abort(ye);
|
|
1055
|
+
});
|
|
1056
|
+
var r = n.next;
|
|
1057
|
+
n.f & 64 ? n.parent = null : z(n, t), n = r;
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
function wn(e) {
|
|
1061
|
+
for (var t = e.first; t !== null;) {
|
|
1062
|
+
var n = t.next;
|
|
1063
|
+
t.f & 32 || z(t), t = n;
|
|
1064
|
+
}
|
|
1065
|
+
}
|
|
1066
|
+
function z(e, t = !0) {
|
|
1067
|
+
var n = !1;
|
|
1068
|
+
(t || e.f & 262144) && e.nodes !== null && e.nodes.end !== null && (Tn(e.nodes.start, e.nodes.end), n = !0), e.f |= S, Cn(e, t && !n), qn(e, 0);
|
|
1069
|
+
var r = e.nodes && e.nodes.t;
|
|
1070
|
+
if (r !== null) for (let e of r) e.stop();
|
|
1071
|
+
Sn(e), e.f ^= S, e.f |= re;
|
|
1072
|
+
var i = e.parent;
|
|
1073
|
+
i !== null && i.first !== null && En(e), e.next = e.prev = e.teardown = e.ctx = e.deps = e.fn = e.nodes = e.ac = e.b = null;
|
|
1074
|
+
}
|
|
1075
|
+
function Tn(e, t) {
|
|
1076
|
+
for (; e !== null;) {
|
|
1077
|
+
var n = e === t ? null : /* @__PURE__ */ F(e);
|
|
1078
|
+
e.remove(), e = n;
|
|
1079
|
+
}
|
|
1080
|
+
}
|
|
1081
|
+
function En(e) {
|
|
1082
|
+
var t = e.parent, n = e.prev, r = e.next;
|
|
1083
|
+
n !== null && (n.next = r), r !== null && (r.prev = n), t !== null && (t.first === e && (t.first = r), t.last === e && (t.last = n));
|
|
1084
|
+
}
|
|
1085
|
+
function Dn(e, t, n = !0) {
|
|
1086
|
+
var r = [];
|
|
1087
|
+
e.f |= 256, On(e, r, !0);
|
|
1088
|
+
var i = () => {
|
|
1089
|
+
n && z(e), t && t();
|
|
1090
|
+
}, a = r.length;
|
|
1091
|
+
if (a > 0) {
|
|
1092
|
+
var o = () => --a || i();
|
|
1093
|
+
for (var s of r) s.out(o);
|
|
1094
|
+
} else i();
|
|
1095
|
+
}
|
|
1096
|
+
function On(e, t, n) {
|
|
1097
|
+
if (!(e.f & 8192)) {
|
|
1098
|
+
e.f ^= ne;
|
|
1099
|
+
var r = e.nodes && e.nodes.t;
|
|
1100
|
+
if (r !== null) for (let e of r) (e.is_global || n) && t.push(e);
|
|
1101
|
+
for (var i = e.first; i !== null;) {
|
|
1102
|
+
var a = i.next;
|
|
1103
|
+
if (!(i.f & 64)) {
|
|
1104
|
+
var o = (i.f & 65536) != 0 || (i.f & 32) != 0 && (e.f & 16) != 0;
|
|
1105
|
+
On(i, t, o ? n : !1);
|
|
1106
|
+
}
|
|
1107
|
+
i = a;
|
|
1108
|
+
}
|
|
1109
|
+
}
|
|
1110
|
+
}
|
|
1111
|
+
function kn(e) {
|
|
1112
|
+
e.f &= -257, An(e, !0);
|
|
1113
|
+
}
|
|
1114
|
+
function An(e, t) {
|
|
1115
|
+
if (!(e.f & 256) && e.f & 8192) {
|
|
1116
|
+
e.f ^= ne, e.f & 1024 || (D(e, b), kt.ensure().schedule(e));
|
|
1117
|
+
for (var n = e.first; n !== null;) {
|
|
1118
|
+
var r = n.next, i = (n.f & 65536) != 0 || (n.f & 32) != 0;
|
|
1119
|
+
An(n, i ? t : !1), n = r;
|
|
1120
|
+
}
|
|
1121
|
+
var a = e.nodes && e.nodes.t;
|
|
1122
|
+
if (a !== null) for (let e of a) (e.is_global || t) && e.in();
|
|
1123
|
+
}
|
|
1124
|
+
}
|
|
1125
|
+
function jn(e, t) {
|
|
1126
|
+
if (e.nodes) for (var n = e.nodes.start, r = e.nodes.end; n !== null;) {
|
|
1127
|
+
var i = n === r ? null : /* @__PURE__ */ F(n);
|
|
1128
|
+
t.append(n), n = i;
|
|
1129
|
+
}
|
|
1130
|
+
}
|
|
1131
|
+
//#endregion
|
|
1132
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/legacy.js
|
|
1133
|
+
var Mn = null, Nn = !1, B = !1;
|
|
1134
|
+
function Pn(e) {
|
|
1135
|
+
B = e;
|
|
1136
|
+
}
|
|
1137
|
+
var V = null, H = !1;
|
|
1138
|
+
function U(e) {
|
|
1139
|
+
V = e;
|
|
1140
|
+
}
|
|
1141
|
+
var W = null;
|
|
1142
|
+
function G(e) {
|
|
1143
|
+
W = e;
|
|
1144
|
+
}
|
|
1145
|
+
var K = null;
|
|
1146
|
+
function Fn(e) {
|
|
1147
|
+
V !== null && (K ??= /* @__PURE__ */ new Set()).add(e);
|
|
1148
|
+
}
|
|
1149
|
+
var q = null, J = 0, Y = null;
|
|
1150
|
+
function In(e) {
|
|
1151
|
+
Y = e;
|
|
1152
|
+
}
|
|
1153
|
+
var Ln = 1, Rn = 0, zn = Rn;
|
|
1154
|
+
function Bn(e) {
|
|
1155
|
+
zn = e;
|
|
1156
|
+
}
|
|
1157
|
+
function Vn() {
|
|
1158
|
+
return ++Ln;
|
|
1159
|
+
}
|
|
1160
|
+
function Hn(e) {
|
|
1161
|
+
var t = e.f;
|
|
1162
|
+
if (t & 2048) return !0;
|
|
1163
|
+
if (t & 2 && (e.f &= ~se), t & 4096) {
|
|
1164
|
+
for (var n = e.deps, r = n.length, i = 0; i < r; i++) {
|
|
1165
|
+
var a = n[i];
|
|
1166
|
+
if (Hn(a) && _t(a), a.wv > e.wv) return !0;
|
|
1167
|
+
}
|
|
1168
|
+
t & 512 && k === null && D(e, y);
|
|
1169
|
+
}
|
|
1170
|
+
return !1;
|
|
1171
|
+
}
|
|
1172
|
+
function Un(e, t, n = !0) {
|
|
1173
|
+
var r = e.reactions;
|
|
1174
|
+
if (r !== null && !(K !== null && K.has(e))) for (var i = 0; i < r.length; i++) {
|
|
1175
|
+
var a = r[i];
|
|
1176
|
+
a.f & 2 ? Un(a, t, !1) : t === a && (n ? D(a, b) : a.f & 1024 && D(a, te), Ft(a));
|
|
1177
|
+
}
|
|
1178
|
+
}
|
|
1179
|
+
function Wn(e) {
|
|
1180
|
+
var t = q, n = J, r = Y, i = V, a = K, o = E, s = H, c = zn, l = e.f;
|
|
1181
|
+
q = null, J = 0, Y = null, V = l & 96 ? null : e, K = null, We(e.ctx), H = !1, zn = ++Rn, e.ac !== null && (at(() => {
|
|
1182
|
+
e.ac.abort(ye);
|
|
1183
|
+
}), e.ac = null);
|
|
1184
|
+
try {
|
|
1185
|
+
e.f |= ce;
|
|
1186
|
+
var u = e.fn, d = u();
|
|
1187
|
+
e.f |= x;
|
|
1188
|
+
var f = Gn(e);
|
|
1189
|
+
if (Je() && Y !== null && !H && f !== null && !(e.f & 6146)) for (var p = 0; p < Y.length; p++) Un(Y[p], e);
|
|
1190
|
+
if (i !== null && i !== e) {
|
|
1191
|
+
if (Rn++, i.deps !== null) for (let e = 0; e < n; e += 1) i.deps[e].rv = Rn;
|
|
1192
|
+
if (t !== null) for (let e of t) e.rv = Rn;
|
|
1193
|
+
Y !== null && (r === null ? r = Y : r.push(...Y));
|
|
1194
|
+
}
|
|
1195
|
+
return e.f & 8388608 && (e.f ^= ue), d;
|
|
1196
|
+
} catch (t) {
|
|
1197
|
+
return Gn(e), cn(t);
|
|
1198
|
+
} finally {
|
|
1199
|
+
e.f ^= ce, q = t, J = n, Y = r, V = i, K = a, We(o), H = s, zn = c;
|
|
1200
|
+
}
|
|
1201
|
+
}
|
|
1202
|
+
function Gn(e) {
|
|
1203
|
+
var t = e.deps, n = O?.is_fork;
|
|
1204
|
+
if (q !== null) {
|
|
1205
|
+
var r;
|
|
1206
|
+
if (n || qn(e, J), t !== null && J > 0) for (t.length = J + q.length, r = 0; r < q.length; r++) t[J + r] = q[r];
|
|
1207
|
+
else e.deps = t = q;
|
|
1208
|
+
if (dn() && e.f & 512) for (r = J; r < t.length; r++) (t[r].reactions ??= []).push(e);
|
|
1209
|
+
} else !n && t !== null && J < t.length && (qn(e, J), t.length = J);
|
|
1210
|
+
return t;
|
|
1211
|
+
}
|
|
1212
|
+
function Kn(e, n) {
|
|
1213
|
+
let r = n.reactions;
|
|
1214
|
+
if (r !== null) {
|
|
1215
|
+
var i = o.call(r, e);
|
|
1216
|
+
if (i !== -1) {
|
|
1217
|
+
var a = r.length - 1;
|
|
1218
|
+
a === 0 ? r = n.reactions = null : (r[i] = r[a], r.pop());
|
|
1219
|
+
}
|
|
1220
|
+
}
|
|
1221
|
+
if (r === null && n.f & 2 && (q === null || !s.call(q, n))) {
|
|
1222
|
+
var c = n;
|
|
1223
|
+
c.f & 512 && (c.f ^= 512, c.f &= ~se), c.v !== t && et(c), c.ac !== null && at(() => {
|
|
1224
|
+
c.ac.abort(ye), c.ac = null, D(c, b);
|
|
1225
|
+
}), vt(c), qn(c, 0);
|
|
1226
|
+
}
|
|
1227
|
+
}
|
|
1228
|
+
function qn(e, t) {
|
|
1229
|
+
var n = e.deps;
|
|
1230
|
+
if (n !== null) for (var r = t; r < n.length; r++) Kn(e, n[r]);
|
|
1231
|
+
}
|
|
1232
|
+
function Jn(e) {
|
|
1233
|
+
var t = e.f;
|
|
1234
|
+
if (!(t & 16384)) {
|
|
1235
|
+
D(e, y);
|
|
1236
|
+
var n = W, r = Nn;
|
|
1237
|
+
W = e, Nn = (t & 96) == 0;
|
|
1238
|
+
try {
|
|
1239
|
+
t & 16777232 ? wn(e) : Cn(e), Sn(e);
|
|
1240
|
+
var i = Wn(e);
|
|
1241
|
+
e.teardown = typeof i == "function" ? i : null, e.wv = Ln;
|
|
1242
|
+
} finally {
|
|
1243
|
+
Nn = r, W = n;
|
|
1244
|
+
}
|
|
1245
|
+
}
|
|
1246
|
+
}
|
|
1247
|
+
function X(e) {
|
|
1248
|
+
var t = (e.f & 2) != 0;
|
|
1249
|
+
if (Mn?.add(e), V !== null && !H && !(W !== null && W.f & 16384) && (K === null || !K.has(e))) {
|
|
1250
|
+
var n = V.deps;
|
|
1251
|
+
if (V.f & 2097152) e.rv < Rn && (e.rv = Rn, q === null && n !== null && n[J] === e ? J++ : q === null ? q = [e] : q.push(e));
|
|
1252
|
+
else {
|
|
1253
|
+
V.deps ??= [], s.call(V.deps, e) || V.deps.push(e);
|
|
1254
|
+
var r = e.reactions;
|
|
1255
|
+
r === null ? e.reactions = [V] : s.call(r, V) || r.push(V);
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
if (B && j.has(e)) return j.get(e);
|
|
1259
|
+
if (t) {
|
|
1260
|
+
var i = e;
|
|
1261
|
+
if (B) {
|
|
1262
|
+
var a = i.v;
|
|
1263
|
+
return (!(i.f & 1024) && i.reactions !== null || Xn(i)) && (a = gt(i)), j.set(i, a), a;
|
|
1264
|
+
}
|
|
1265
|
+
var o = (i.f & 512) == 0 && !H && V !== null && (Nn || (V.f & 512) != 0), c = (i.f & x) === 0;
|
|
1266
|
+
Hn(i) && (o && (i.f |= 512), _t(i)), o && !c && (yt(i), Yn(i));
|
|
1267
|
+
}
|
|
1268
|
+
if (k?.has(e)) return k.get(e);
|
|
1269
|
+
if (e.f & 8388608) throw e.v;
|
|
1270
|
+
return e.v;
|
|
1271
|
+
}
|
|
1272
|
+
function Yn(e) {
|
|
1273
|
+
if (e.f |= 512, e.deps !== null) for (let t of e.deps) (t.reactions ??= []).push(e), t.f & 2 && !(t.f & 512) && (yt(t), Yn(t));
|
|
1274
|
+
}
|
|
1275
|
+
function Xn(e) {
|
|
1276
|
+
if (e.v === t) return !0;
|
|
1277
|
+
if (e.deps === null) return !1;
|
|
1278
|
+
for (let t of e.deps) if (j.has(t) || t.f & 2 && Xn(t)) return !0;
|
|
1279
|
+
return !1;
|
|
1280
|
+
}
|
|
1281
|
+
function Zn(e) {
|
|
1282
|
+
var t = H;
|
|
1283
|
+
try {
|
|
1284
|
+
return H = !0, e();
|
|
1285
|
+
} finally {
|
|
1286
|
+
H = t;
|
|
1287
|
+
}
|
|
1288
|
+
}
|
|
1289
|
+
//#endregion
|
|
1290
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/events.js
|
|
1291
|
+
var Qn = Symbol("events"), $n = /* @__PURE__ */ new Set(), er = /* @__PURE__ */ new Set(), tr = null, nr = !1;
|
|
1292
|
+
function rr(e) {
|
|
1293
|
+
var t = this, n = t.ownerDocument, r = e.type, i = e.composedPath?.() || [], a = i[0] || e.target;
|
|
1294
|
+
tr = e, nr || (nr = !0, setTimeout(() => {
|
|
1295
|
+
nr = !1, tr = null;
|
|
1296
|
+
}));
|
|
1297
|
+
var o = 0, s = tr === e && e[Qn];
|
|
1298
|
+
if (s) {
|
|
1299
|
+
var c = i.indexOf(s);
|
|
1300
|
+
if (c !== -1 && (t === document || t === window)) {
|
|
1301
|
+
e[Qn] = t;
|
|
1302
|
+
return;
|
|
1303
|
+
}
|
|
1304
|
+
var l = i.indexOf(t);
|
|
1305
|
+
if (l === -1) return;
|
|
1306
|
+
c <= l && (o = c);
|
|
1307
|
+
}
|
|
1308
|
+
if (a = i[o] || e.target, a !== t) {
|
|
1309
|
+
u(e, "currentTarget", {
|
|
1310
|
+
configurable: !0,
|
|
1311
|
+
get() {
|
|
1312
|
+
return a || n;
|
|
1313
|
+
}
|
|
1314
|
+
});
|
|
1315
|
+
var d = V, f = W;
|
|
1316
|
+
U(null), G(null);
|
|
1317
|
+
try {
|
|
1318
|
+
for (var p, m = []; a !== null && a !== t;) {
|
|
1319
|
+
try {
|
|
1320
|
+
var h = a[Qn]?.[r];
|
|
1321
|
+
h != null && (!a.disabled || e.target === a) && h.call(a, e);
|
|
1322
|
+
} catch (e) {
|
|
1323
|
+
p ? m.push(e) : p = e;
|
|
1324
|
+
}
|
|
1325
|
+
if (e.cancelBubble) break;
|
|
1326
|
+
o++, a = o < i.length ? i[o] : null;
|
|
1327
|
+
}
|
|
1328
|
+
if (p) {
|
|
1329
|
+
for (let e of m) queueMicrotask(() => {
|
|
1330
|
+
throw e;
|
|
1331
|
+
});
|
|
1332
|
+
throw p;
|
|
1333
|
+
}
|
|
1334
|
+
} finally {
|
|
1335
|
+
e[Qn] = t, delete e.currentTarget, U(d), G(f);
|
|
1336
|
+
}
|
|
1337
|
+
}
|
|
1338
|
+
}
|
|
1339
|
+
//#endregion
|
|
1340
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/reconciler.js
|
|
1341
|
+
var ir = globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", { createHTML: (e) => e });
|
|
1342
|
+
function ar(e) {
|
|
1343
|
+
return ir?.createHTML(e) ?? e;
|
|
1344
|
+
}
|
|
1345
|
+
function or(e) {
|
|
1346
|
+
var t = on("template");
|
|
1347
|
+
return t.innerHTML = ar(e.replaceAll("<!>", "<!---->")), t.content;
|
|
1348
|
+
}
|
|
1349
|
+
//#endregion
|
|
1350
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/template.js
|
|
1351
|
+
function sr(e, t) {
|
|
1352
|
+
var n = W;
|
|
1353
|
+
n.nodes === null && (n.nodes = {
|
|
1354
|
+
start: e,
|
|
1355
|
+
end: t,
|
|
1356
|
+
a: null,
|
|
1357
|
+
t: null
|
|
1358
|
+
});
|
|
1359
|
+
}
|
|
1360
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
1361
|
+
function cr(e, t) {
|
|
1362
|
+
var n = (t & 1) != 0, r = (t & 2) != 0, i, a = !e.startsWith("<!>");
|
|
1363
|
+
return () => {
|
|
1364
|
+
if (C) return sr(w, null), w;
|
|
1365
|
+
i === void 0 && (i = or(a ? e : "<!>" + e), n || (i = /* @__PURE__ */ P(i)));
|
|
1366
|
+
var t = r || Jt ? document.importNode(i, !0) : i.cloneNode(!0);
|
|
1367
|
+
if (n) {
|
|
1368
|
+
var o = /* @__PURE__ */ P(t), s = t.lastChild;
|
|
1369
|
+
sr(o, s);
|
|
1370
|
+
} else sr(t, t);
|
|
1371
|
+
return t;
|
|
1372
|
+
};
|
|
1373
|
+
}
|
|
1374
|
+
function lr(e, t) {
|
|
1375
|
+
if (C) {
|
|
1376
|
+
var n = W;
|
|
1377
|
+
(!(n.f & 32768) || n.nodes.end === null) && (n.nodes.end = w), Te();
|
|
1378
|
+
return;
|
|
1379
|
+
}
|
|
1380
|
+
e !== null && e.before(t);
|
|
1381
|
+
}
|
|
1382
|
+
[.../* @__PURE__ */ "allowfullscreen.async.autofocus.autoplay.checked.controls.default.disabled.formnovalidate.indeterminate.inert.ismap.loop.multiple.muted.nomodule.novalidate.open.playsinline.readonly.required.reversed.seamless.selected.webkitdirectory.defer.disablepictureinpicture.disableremoteplayback".split(".")];
|
|
1383
|
+
var ur = ["touchstart", "touchmove"];
|
|
1384
|
+
function dr(e) {
|
|
1385
|
+
return ur.includes(e);
|
|
1386
|
+
}
|
|
1387
|
+
//#endregion
|
|
1388
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/reactivity/create-subscriber.js
|
|
1389
|
+
function fr(e) {
|
|
1390
|
+
let t = 0, n = Bt(0), r;
|
|
1391
|
+
return () => {
|
|
1392
|
+
dn() && (X(n), yn(() => (t === 0 && (r = Zn(() => e(() => Wt(n)))), t += 1, () => {
|
|
1393
|
+
Ze(() => {
|
|
1394
|
+
--t, t === 0 && (r?.(), r = void 0, Wt(n));
|
|
1395
|
+
});
|
|
1396
|
+
})));
|
|
1397
|
+
};
|
|
1398
|
+
}
|
|
1399
|
+
//#endregion
|
|
1400
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/boundary.js
|
|
1401
|
+
var pr = ie | ae;
|
|
1402
|
+
function mr(e, t, n, r) {
|
|
1403
|
+
new hr(e, t, n, r);
|
|
1404
|
+
}
|
|
1405
|
+
var hr = class {
|
|
1406
|
+
parent;
|
|
1407
|
+
is_pending = !1;
|
|
1408
|
+
transform_error;
|
|
1409
|
+
#e;
|
|
1410
|
+
#t = C ? w : null;
|
|
1411
|
+
#n;
|
|
1412
|
+
#r;
|
|
1413
|
+
#i;
|
|
1414
|
+
#a = null;
|
|
1415
|
+
#o = null;
|
|
1416
|
+
#s = null;
|
|
1417
|
+
#c = null;
|
|
1418
|
+
#l = 0;
|
|
1419
|
+
#u = 0;
|
|
1420
|
+
#d = !1;
|
|
1421
|
+
#f = /* @__PURE__ */ new Set();
|
|
1422
|
+
#p = /* @__PURE__ */ new Set();
|
|
1423
|
+
#m = null;
|
|
1424
|
+
#h = fr(() => (this.#m = Bt(this.#l), () => {
|
|
1425
|
+
this.#m = null;
|
|
1426
|
+
}));
|
|
1427
|
+
constructor(e, t, n, r) {
|
|
1428
|
+
this.#e = e, this.#n = t, this.#r = (e) => {
|
|
1429
|
+
var t = W;
|
|
1430
|
+
t.b = this, t.f |= 128, n(e);
|
|
1431
|
+
}, this.parent = W.b, this.transform_error = r ?? this.parent?.transform_error ?? ((e) => e), this.#i = xn(() => {
|
|
1432
|
+
if (C) {
|
|
1433
|
+
let e = this.#t;
|
|
1434
|
+
Te();
|
|
1435
|
+
let t = e.data === "[!";
|
|
1436
|
+
if (e.data.startsWith("[?")) {
|
|
1437
|
+
let t = JSON.parse(e.data.slice(2));
|
|
1438
|
+
this.#_(t);
|
|
1439
|
+
} else t ? this.#y() : this.#g();
|
|
1440
|
+
} else this.#b();
|
|
1441
|
+
}, pr), C && (this.#e = w);
|
|
1442
|
+
}
|
|
1443
|
+
#g() {
|
|
1444
|
+
try {
|
|
1445
|
+
this.#a = R(() => this.#r(this.#e));
|
|
1446
|
+
} catch (e) {
|
|
1447
|
+
this.error(e);
|
|
1448
|
+
}
|
|
1449
|
+
}
|
|
1450
|
+
#_(e) {
|
|
1451
|
+
let t = this.#n.failed, { reset: n, invoke_onerror: r } = this.#v(e);
|
|
1452
|
+
Ze(r), t && (this.#s = R(() => {
|
|
1453
|
+
t(this.#e, () => e, () => n);
|
|
1454
|
+
}));
|
|
1455
|
+
}
|
|
1456
|
+
#v(e) {
|
|
1457
|
+
var t = !1, n = !1;
|
|
1458
|
+
let r = () => {
|
|
1459
|
+
if (t) {
|
|
1460
|
+
Ce();
|
|
1461
|
+
return;
|
|
1462
|
+
}
|
|
1463
|
+
t = !0, n && Ue(), this.#s !== null && Dn(this.#s, () => {
|
|
1464
|
+
this.#s = null;
|
|
1465
|
+
}), this.#S(() => {
|
|
1466
|
+
this.#b();
|
|
1467
|
+
});
|
|
1468
|
+
};
|
|
1469
|
+
return {
|
|
1470
|
+
reset: r,
|
|
1471
|
+
invoke_onerror: () => {
|
|
1472
|
+
try {
|
|
1473
|
+
n = !0, this.#n.onerror?.(e, r), n = !1;
|
|
1474
|
+
} catch (e) {
|
|
1475
|
+
I(e, this.#i && this.#i.parent);
|
|
1476
|
+
}
|
|
1477
|
+
}
|
|
1478
|
+
};
|
|
1479
|
+
}
|
|
1480
|
+
#y() {
|
|
1481
|
+
let e = this.#n.pending;
|
|
1482
|
+
e && (this.is_pending = !0, this.#o = R(() => e(this.#e)), Ze(() => {
|
|
1483
|
+
var e = this.#c = document.createDocumentFragment(), t = Qt(), n = !1;
|
|
1484
|
+
if (e.append(t), this.#a = this.#S(() => {
|
|
1485
|
+
try {
|
|
1486
|
+
return R(() => this.#r(t));
|
|
1487
|
+
} catch (e) {
|
|
1488
|
+
try {
|
|
1489
|
+
this.error(e), n = !0;
|
|
1490
|
+
} catch (e) {
|
|
1491
|
+
I(e, this.#i.parent);
|
|
1492
|
+
}
|
|
1493
|
+
return null;
|
|
1494
|
+
}
|
|
1495
|
+
}), this.#a === null) {
|
|
1496
|
+
this.#c = null, n && this.#x(O);
|
|
1497
|
+
return;
|
|
1498
|
+
}
|
|
1499
|
+
this.#u === 0 && (this.#e.before(e), this.#c = null, Dn(this.#o, () => {
|
|
1500
|
+
this.#o = null;
|
|
1501
|
+
}), this.#x(O));
|
|
1502
|
+
}));
|
|
1503
|
+
}
|
|
1504
|
+
#b() {
|
|
1505
|
+
try {
|
|
1506
|
+
if (this.is_pending = this.has_pending_snippet(), this.#u = 0, this.#l = 0, this.#a = R(() => {
|
|
1507
|
+
this.#r(this.#e);
|
|
1508
|
+
}), this.#u > 0) {
|
|
1509
|
+
var e = this.#c = document.createDocumentFragment();
|
|
1510
|
+
jn(this.#a, e);
|
|
1511
|
+
let t = this.#n.pending;
|
|
1512
|
+
this.#o = R(() => t(this.#e));
|
|
1513
|
+
} else this.#x(O);
|
|
1514
|
+
} catch (e) {
|
|
1515
|
+
this.error(e);
|
|
1516
|
+
}
|
|
1517
|
+
}
|
|
1518
|
+
#x(e) {
|
|
1519
|
+
this.is_pending = !1, e.transfer_effects(this.#f, this.#p);
|
|
1520
|
+
}
|
|
1521
|
+
defer_effect(e) {
|
|
1522
|
+
nt(e, this.#f, this.#p);
|
|
1523
|
+
}
|
|
1524
|
+
is_rendered() {
|
|
1525
|
+
return !this.is_pending && (!this.parent || this.parent.is_rendered());
|
|
1526
|
+
}
|
|
1527
|
+
has_pending_snippet() {
|
|
1528
|
+
return !!this.#n.pending;
|
|
1529
|
+
}
|
|
1530
|
+
#S(e) {
|
|
1531
|
+
var t = W, n = V, r = E;
|
|
1532
|
+
G(this.#i), U(this.#i), We(this.#i.ctx);
|
|
1533
|
+
try {
|
|
1534
|
+
return kt.ensure(), e();
|
|
1535
|
+
} finally {
|
|
1536
|
+
G(t), U(n), We(r);
|
|
1537
|
+
}
|
|
1538
|
+
}
|
|
1539
|
+
#C(e, t) {
|
|
1540
|
+
if (!this.has_pending_snippet()) {
|
|
1541
|
+
this.parent && this.parent.#C(e, t);
|
|
1542
|
+
return;
|
|
1543
|
+
}
|
|
1544
|
+
this.#u += e, this.#u === 0 && (this.#x(t), this.#o && Dn(this.#o, () => {
|
|
1545
|
+
this.#o = null;
|
|
1546
|
+
}), this.#c &&= (this.#e.before(this.#c), null));
|
|
1547
|
+
}
|
|
1548
|
+
update_pending_count(e, t) {
|
|
1549
|
+
this.#C(e, t), this.#l += e, !(!this.#m || this.#d) && (this.#d = !0, Ze(() => {
|
|
1550
|
+
this.#d = !1, this.#m && Ht(this.#m, this.#l);
|
|
1551
|
+
}));
|
|
1552
|
+
}
|
|
1553
|
+
get_effect_pending() {
|
|
1554
|
+
return this.#h(), X(this.#m);
|
|
1555
|
+
}
|
|
1556
|
+
error(e) {
|
|
1557
|
+
if (!this.#n.onerror && !this.#n.failed) throw e;
|
|
1558
|
+
O?.is_fork ? (this.#a && O.skip_effect(this.#a), this.#o && O.skip_effect(this.#o), this.#s && O.skip_effect(this.#s), O.oncommit(() => {
|
|
1559
|
+
this.#w(e);
|
|
1560
|
+
})) : this.#w(e);
|
|
1561
|
+
}
|
|
1562
|
+
#w(e) {
|
|
1563
|
+
this.#a &&= (z(this.#a), null), this.#o &&= (z(this.#o), null), this.#s &&= (z(this.#s), null), C && (T(this.#t), De(), T(Oe()));
|
|
1564
|
+
let t = this.#n.failed, n = (e) => {
|
|
1565
|
+
let { reset: n, invoke_onerror: r } = this.#v(e);
|
|
1566
|
+
r(), t && (this.#s = this.#S(() => {
|
|
1567
|
+
try {
|
|
1568
|
+
return R(() => {
|
|
1569
|
+
var r = W;
|
|
1570
|
+
r.b = this, r.f |= 128, t(this.#e, () => e, () => n);
|
|
1571
|
+
});
|
|
1572
|
+
} catch (e) {
|
|
1573
|
+
return I(e, this.#i.parent), null;
|
|
1574
|
+
}
|
|
1575
|
+
}));
|
|
1576
|
+
};
|
|
1577
|
+
Ze(() => {
|
|
1578
|
+
var t;
|
|
1579
|
+
try {
|
|
1580
|
+
t = this.transform_error(e);
|
|
1581
|
+
} catch (e) {
|
|
1582
|
+
I(e, this.#i && this.#i.parent);
|
|
1583
|
+
return;
|
|
1584
|
+
}
|
|
1585
|
+
typeof t == "object" && t && typeof t.then == "function" ? t.then(n, (e) => I(e, this.#i && this.#i.parent)) : n(t);
|
|
1586
|
+
});
|
|
1587
|
+
}
|
|
1588
|
+
};
|
|
1589
|
+
function gr(e, t) {
|
|
1590
|
+
var n = t == null ? "" : typeof t == "object" ? `${t}` : t;
|
|
1591
|
+
n !== (e[ve] ??= e.nodeValue) && (e[ve] = n, e.nodeValue = `${n}`);
|
|
1592
|
+
}
|
|
1593
|
+
function _r(e, t) {
|
|
1594
|
+
return br(e, t);
|
|
1595
|
+
}
|
|
1596
|
+
function vr(t, n) {
|
|
1597
|
+
Zt(), n.intro = n.intro ?? !1;
|
|
1598
|
+
let r = n.target, i = C, a = w;
|
|
1599
|
+
try {
|
|
1600
|
+
for (var o = /* @__PURE__ */ P(r); o && (o.nodeType !== 8 || o.data !== "[");) o = /* @__PURE__ */ F(o);
|
|
1601
|
+
if (!o) throw e;
|
|
1602
|
+
we(!0), T(o);
|
|
1603
|
+
let i = br(t, {
|
|
1604
|
+
...n,
|
|
1605
|
+
anchor: o
|
|
1606
|
+
});
|
|
1607
|
+
return we(!1), i;
|
|
1608
|
+
} catch (i) {
|
|
1609
|
+
if (i instanceof Error && i.message.split("\n").some((e) => e.startsWith("https://svelte.dev/e/"))) throw i;
|
|
1610
|
+
return i !== e && console.warn("Failed to hydrate: ", i), n.recover === !1 && Re(), Zt(), rn(r), we(!1), _r(t, n);
|
|
1611
|
+
} finally {
|
|
1612
|
+
we(i), T(a);
|
|
1613
|
+
}
|
|
1614
|
+
}
|
|
1615
|
+
var yr = /* @__PURE__ */ new Map();
|
|
1616
|
+
function br(t, { target: n, anchor: r, props: i = {}, events: a, context: o, intro: s = !0, transformError: l }) {
|
|
1617
|
+
Zt();
|
|
1618
|
+
var u = void 0, d = gn(() => {
|
|
1619
|
+
var s = r ?? n.appendChild(Qt());
|
|
1620
|
+
mr(s, { pending: () => {} }, (n) => {
|
|
1621
|
+
Ge({});
|
|
1622
|
+
var r = E;
|
|
1623
|
+
if (o && (r.c = o), a && (i.$$events = a), C && sr(n, null), u = t(n, i) || qe(), C && (W.nodes.end = w, w === null || w.nodeType !== 8 || w.data !== "]")) throw Se(), e;
|
|
1624
|
+
Ke();
|
|
1625
|
+
}, l);
|
|
1626
|
+
var d = /* @__PURE__ */ new Set(), f = (e) => {
|
|
1627
|
+
for (var t = 0; t < e.length; t++) {
|
|
1628
|
+
var r = e[t];
|
|
1629
|
+
if (!d.has(r)) {
|
|
1630
|
+
d.add(r);
|
|
1631
|
+
var i = dr(r);
|
|
1632
|
+
for (let e of [n, document]) {
|
|
1633
|
+
var a = yr.get(e);
|
|
1634
|
+
a === void 0 && (a = /* @__PURE__ */ new Map(), yr.set(e, a));
|
|
1635
|
+
var o = a.get(r);
|
|
1636
|
+
o === void 0 ? (e.addEventListener(r, rr, { passive: i }), a.set(r, 1)) : a.set(r, o + 1);
|
|
1637
|
+
}
|
|
1638
|
+
}
|
|
1639
|
+
}
|
|
1640
|
+
};
|
|
1641
|
+
return f(c($n)), er.add(f), () => {
|
|
1642
|
+
for (var e of d) for (let r of [n, document]) {
|
|
1643
|
+
var t = yr.get(r), i = t.get(e);
|
|
1644
|
+
--i == 0 ? (r.removeEventListener(e, rr), t.delete(e), t.size === 0 && yr.delete(r)) : t.set(e, i);
|
|
1645
|
+
}
|
|
1646
|
+
er.delete(f), s !== r && s.parentNode?.removeChild(s);
|
|
1647
|
+
};
|
|
1648
|
+
});
|
|
1649
|
+
return xr.set(u, d), u;
|
|
1650
|
+
}
|
|
1651
|
+
var xr = /* @__PURE__ */ new WeakMap();
|
|
1652
|
+
function Sr(e, t) {
|
|
1653
|
+
let n = xr.get(e);
|
|
1654
|
+
return n ? (xr.delete(e), n(t)) : Promise.resolve();
|
|
1655
|
+
}
|
|
1656
|
+
//#endregion
|
|
1657
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/branches.js
|
|
1658
|
+
var Cr = class {
|
|
1659
|
+
anchor;
|
|
1660
|
+
#e = /* @__PURE__ */ new Map();
|
|
1661
|
+
#t = /* @__PURE__ */ new Map();
|
|
1662
|
+
#n = /* @__PURE__ */ new Map();
|
|
1663
|
+
#r = /* @__PURE__ */ new Set();
|
|
1664
|
+
#i = !0;
|
|
1665
|
+
constructor(e, t = !0) {
|
|
1666
|
+
this.anchor = e, this.#i = t;
|
|
1667
|
+
}
|
|
1668
|
+
#a = (e) => {
|
|
1669
|
+
if (this.#e.has(e)) {
|
|
1670
|
+
var t = this.#e.get(e), n = this.#t.get(t);
|
|
1671
|
+
if (n) kn(n), this.#r.delete(t);
|
|
1672
|
+
else {
|
|
1673
|
+
var r = this.#n.get(t);
|
|
1674
|
+
r && (kn(r.effect), this.#t.set(t, r.effect), this.#n.delete(t), r.fragment.lastChild.remove(), this.anchor.before(r.fragment), n = r.effect);
|
|
1675
|
+
}
|
|
1676
|
+
for (let [t, n] of this.#e) {
|
|
1677
|
+
if (this.#e.delete(t), t === e) break;
|
|
1678
|
+
let r = this.#n.get(n);
|
|
1679
|
+
r && (z(r.effect), this.#n.delete(n));
|
|
1680
|
+
}
|
|
1681
|
+
for (let [e, r] of this.#t) {
|
|
1682
|
+
if (e === t || this.#r.has(e)) continue;
|
|
1683
|
+
let i = () => {
|
|
1684
|
+
if (Array.from(this.#e.values()).includes(e)) {
|
|
1685
|
+
var t = document.createDocumentFragment();
|
|
1686
|
+
jn(r, t), t.append(Qt()), this.#n.set(e, {
|
|
1687
|
+
effect: r,
|
|
1688
|
+
fragment: t
|
|
1689
|
+
});
|
|
1690
|
+
} else z(r);
|
|
1691
|
+
this.#r.delete(e), this.#t.delete(e);
|
|
1692
|
+
};
|
|
1693
|
+
this.#i || !n ? (this.#r.add(e), Dn(r, i, !1)) : i();
|
|
1694
|
+
}
|
|
1695
|
+
}
|
|
1696
|
+
};
|
|
1697
|
+
#o = (e) => {
|
|
1698
|
+
this.#e.delete(e);
|
|
1699
|
+
let t = Array.from(this.#e.values());
|
|
1700
|
+
for (let [e, n] of this.#n) t.includes(e) || (z(n.effect), this.#n.delete(e));
|
|
1701
|
+
};
|
|
1702
|
+
ensure(e, t) {
|
|
1703
|
+
var n = O, r = an();
|
|
1704
|
+
if (t && !this.#t.has(e) && !this.#n.has(e)) if (r) {
|
|
1705
|
+
var i = document.createDocumentFragment(), a = Qt();
|
|
1706
|
+
i.append(a), this.#n.set(e, {
|
|
1707
|
+
effect: R(() => t(a)),
|
|
1708
|
+
fragment: i
|
|
1709
|
+
});
|
|
1710
|
+
} else this.#t.set(e, R(() => t(this.anchor)));
|
|
1711
|
+
if (this.#e.set(n, e), r) {
|
|
1712
|
+
for (let [t, r] of this.#t) t === e ? n.unskip_effect(r) : n.skip_effect(r);
|
|
1713
|
+
for (let [t, r] of this.#n) t === e ? n.unskip_effect(r.effect) : n.skip_effect(r.effect);
|
|
1714
|
+
n.oncommit(this.#a), n.ondiscard(this.#o);
|
|
1715
|
+
} else C && (this.anchor = w), this.#a(n);
|
|
1716
|
+
}
|
|
1717
|
+
};
|
|
1718
|
+
//#endregion
|
|
1719
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/blocks/if.js
|
|
1720
|
+
function wr(e, t, n = !1) {
|
|
1721
|
+
var r;
|
|
1722
|
+
C && (r = w, Te());
|
|
1723
|
+
var i = new Cr(e), a = n ? ie : 0;
|
|
1724
|
+
function o(e, t) {
|
|
1725
|
+
if (C) {
|
|
1726
|
+
var n = ke(r);
|
|
1727
|
+
if (e !== parseInt(n.substring(1))) {
|
|
1728
|
+
var a = Oe();
|
|
1729
|
+
T(a), i.anchor = a, we(!1), i.ensure(e, t), we(!0);
|
|
1730
|
+
return;
|
|
1731
|
+
}
|
|
1732
|
+
}
|
|
1733
|
+
i.ensure(e, t);
|
|
1734
|
+
}
|
|
1735
|
+
xn(() => {
|
|
1736
|
+
var e = !1;
|
|
1737
|
+
t((t, n = 0) => {
|
|
1738
|
+
e = !0, o(n, t);
|
|
1739
|
+
}), e || o(-1, null);
|
|
1740
|
+
}, a);
|
|
1741
|
+
}
|
|
1742
|
+
function Tr(t, n, a = !1, o = !1, s = !1, c = !1) {
|
|
1743
|
+
var l = t, u = "";
|
|
1744
|
+
if (a) {
|
|
1745
|
+
var d = t;
|
|
1746
|
+
C && (l = T(/* @__PURE__ */ P(d)));
|
|
1747
|
+
}
|
|
1748
|
+
bn(() => {
|
|
1749
|
+
var t = W;
|
|
1750
|
+
if (u === (u = n() ?? "")) {
|
|
1751
|
+
C && Te();
|
|
1752
|
+
return;
|
|
1753
|
+
}
|
|
1754
|
+
if (a && !C) {
|
|
1755
|
+
t.nodes = null, d.innerHTML = u, u !== "" && sr(/* @__PURE__ */ P(d), d.lastChild);
|
|
1756
|
+
return;
|
|
1757
|
+
}
|
|
1758
|
+
if (t.nodes !== null && (Tn(t.nodes.start, t.nodes.end), t.nodes = null), u !== "") {
|
|
1759
|
+
if (C) {
|
|
1760
|
+
for (var c = w.data, f = Te(), p = f; f !== null && (f.nodeType !== 8 || f.data !== "");) p = f, f = /* @__PURE__ */ F(f);
|
|
1761
|
+
if (f === null) throw Se(), e;
|
|
1762
|
+
sr(w, p), l = T(f);
|
|
1763
|
+
return;
|
|
1764
|
+
}
|
|
1765
|
+
var m = on(o ? "svg" : s ? "math" : "template", o ? r : s ? i : void 0);
|
|
1766
|
+
m.innerHTML = u;
|
|
1767
|
+
var h = o || s ? m : m.content;
|
|
1768
|
+
if (sr(/* @__PURE__ */ P(h), h.lastChild), o || s) for (; /* @__PURE__ */ P(h);) l.before(/* @__PURE__ */ P(h));
|
|
1769
|
+
else l.before(h);
|
|
1770
|
+
}
|
|
1771
|
+
});
|
|
1772
|
+
}
|
|
1773
|
+
//#endregion
|
|
1774
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/css.js
|
|
1775
|
+
function Er(e, t) {
|
|
1776
|
+
_n(() => {
|
|
1777
|
+
e = W?.parent?.nodes?.start ?? e;
|
|
1778
|
+
var n = e.getRootNode(), r = n.host ? n : n.head ?? n.ownerDocument.head;
|
|
1779
|
+
if (!r.querySelector("#" + t.hash)) {
|
|
1780
|
+
let e = on("style");
|
|
1781
|
+
e.id = t.hash, e.textContent = t.code, r.appendChild(e);
|
|
1782
|
+
}
|
|
1783
|
+
});
|
|
1784
|
+
}
|
|
1785
|
+
//#endregion
|
|
1786
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/attributes.js
|
|
1787
|
+
var Dr = Symbol("is custom element"), Or = Symbol("is html"), kr = be ? "link" : "LINK";
|
|
1788
|
+
function Ar(e, t, n, r) {
|
|
1789
|
+
var i = jr(e);
|
|
1790
|
+
C && (i[t] = e.getAttribute(t), t === "src" || t === "srcset" || t === "href" && e.nodeName === kr) || i[t] !== (i[t] = n) && (t === "loading" && (e[me] = n), n == null ? e.removeAttribute(t) : typeof n != "string" && Nr(e).has(t) ? e[t] = n : e.setAttribute(t, n));
|
|
1791
|
+
}
|
|
1792
|
+
function jr(e) {
|
|
1793
|
+
return e[he] ??= {
|
|
1794
|
+
[Dr]: e.nodeName.includes("-"),
|
|
1795
|
+
[Or]: e.namespaceURI === n
|
|
1796
|
+
};
|
|
1797
|
+
}
|
|
1798
|
+
var Mr = /* @__PURE__ */ new Map();
|
|
1799
|
+
function Nr(e) {
|
|
1800
|
+
var t = e.getAttribute("is") || e.nodeName, n = Mr.get(t);
|
|
1801
|
+
if (n) return n;
|
|
1802
|
+
Mr.set(t, n = /* @__PURE__ */ new Set());
|
|
1803
|
+
for (var r, i = e, a = Element.prototype; a !== i;) {
|
|
1804
|
+
for (var o in r = f(i), r) r[o].set && o !== "innerHTML" && o !== "textContent" && o !== "innerText" && n.add(o);
|
|
1805
|
+
i = h(i);
|
|
1806
|
+
}
|
|
1807
|
+
return n;
|
|
1808
|
+
}
|
|
1809
|
+
//#endregion
|
|
1810
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/dom/elements/bindings/this.js
|
|
1811
|
+
function Pr(e, t) {
|
|
1812
|
+
return e === t || e?.[de] === t;
|
|
1813
|
+
}
|
|
1814
|
+
function Fr(e = qe(), t, n, r) {
|
|
1815
|
+
var i = E.r, a = W;
|
|
1816
|
+
return _n(() => {
|
|
1817
|
+
var o, s;
|
|
1818
|
+
return yn(() => {
|
|
1819
|
+
o = s, s = r?.() || [], Zn(() => {
|
|
1820
|
+
Pr(n(...s), e) || (t(e, ...s), o && Pr(n(...o), e) && t(null, ...o));
|
|
1821
|
+
});
|
|
1822
|
+
}), () => {
|
|
1823
|
+
let r = a;
|
|
1824
|
+
for (; r !== i && r.parent !== null && r.parent.f & 33554432;) r = r.parent;
|
|
1825
|
+
let o = () => {
|
|
1826
|
+
s && Pr(n(...s), e) && t(null, ...s);
|
|
1827
|
+
}, c = r.teardown;
|
|
1828
|
+
r.teardown = () => {
|
|
1829
|
+
o(), c?.();
|
|
1830
|
+
};
|
|
1831
|
+
};
|
|
1832
|
+
}), e;
|
|
1833
|
+
}
|
|
1834
|
+
//#endregion
|
|
1835
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/internal/client/reactivity/props.js
|
|
1836
|
+
function Ir(e, t, n, r) {
|
|
1837
|
+
var i = !0, a = (n & 8) != 0, o = (n & 16) != 0, s = r, c = !0, l = void 0, u = () => o && i ? (l ??= /* @__PURE__ */ ut(r), X(l)) : (c && (c = !1, s = o ? Zn(r) : r), s);
|
|
1838
|
+
let f;
|
|
1839
|
+
if (a) {
|
|
1840
|
+
var p = de in e || pe in e;
|
|
1841
|
+
f = d(e, t)?.set ?? (p && t in e ? (n) => e[t] = n : void 0);
|
|
1842
|
+
}
|
|
1843
|
+
var m, h = !1;
|
|
1844
|
+
a ? [m, h] = it(() => e[t]) : m = e[t], m === void 0 && r !== void 0 && (m = u(), f && (i && ze(t), f(m)));
|
|
1845
|
+
var g = i ? () => {
|
|
1846
|
+
var n = e[t];
|
|
1847
|
+
return n === void 0 ? u() : (c = !0, n);
|
|
1848
|
+
} : () => {
|
|
1849
|
+
var n = e[t];
|
|
1850
|
+
return n !== void 0 && (s = void 0), n === void 0 ? s : n;
|
|
1851
|
+
};
|
|
1852
|
+
if (i && !(n & 4)) return g;
|
|
1853
|
+
if (f) {
|
|
1854
|
+
var ee = e.$$legacy;
|
|
1855
|
+
return (function(e, t) {
|
|
1856
|
+
return arguments.length > 0 ? ((!i || !t || ee || h) && f(t ? g() : e), e) : g();
|
|
1857
|
+
});
|
|
1858
|
+
}
|
|
1859
|
+
var _ = !1, v = (n & 1 ? ut : mt)(() => (_ = !1, g()));
|
|
1860
|
+
a && X(v);
|
|
1861
|
+
var y = W;
|
|
1862
|
+
return (function(e, t) {
|
|
1863
|
+
if (arguments.length > 0) {
|
|
1864
|
+
let n = t ? X(v) : i && a ? Kt(e) : e;
|
|
1865
|
+
return N(v, n), _ = !0, s !== void 0 && (s = n), e;
|
|
1866
|
+
}
|
|
1867
|
+
return B && _ || y.f & 16384 ? v.v : X(v);
|
|
1868
|
+
});
|
|
1869
|
+
}
|
|
1870
|
+
//#endregion
|
|
1871
|
+
//#region ../../../node_modules/.bun/svelte@5.57.0/node_modules/svelte/src/legacy/legacy-client.js
|
|
1872
|
+
function Lr(e) {
|
|
1873
|
+
return new Rr(e);
|
|
1874
|
+
}
|
|
1875
|
+
var Rr = class {
|
|
1876
|
+
#e;
|
|
1877
|
+
#t;
|
|
1878
|
+
constructor(e) {
|
|
1879
|
+
var t = /* @__PURE__ */ new Map(), n = (e, n) => {
|
|
1880
|
+
var r = /* @__PURE__ */ Vt(n, !1, !1);
|
|
1881
|
+
return t.set(e, r), r;
|
|
1882
|
+
};
|
|
1883
|
+
let r = new Proxy({
|
|
1884
|
+
...e.props || {},
|
|
1885
|
+
$$events: {}
|
|
1886
|
+
}, {
|
|
1887
|
+
get(e, r) {
|
|
1888
|
+
return X(t.get(r) ?? n(r, Reflect.get(e, r)));
|
|
1889
|
+
},
|
|
1890
|
+
has(e, r) {
|
|
1891
|
+
return r === pe ? !0 : (X(t.get(r) ?? n(r, Reflect.get(e, r))), Reflect.has(e, r));
|
|
1892
|
+
},
|
|
1893
|
+
set(e, r, i) {
|
|
1894
|
+
return N(t.get(r) ?? n(r, i), i), Reflect.set(e, r, i);
|
|
1895
|
+
}
|
|
1896
|
+
});
|
|
1897
|
+
this.#t = (e.hydrate ? vr : _r)(e.component, {
|
|
1898
|
+
target: e.target,
|
|
1899
|
+
anchor: e.anchor,
|
|
1900
|
+
props: r,
|
|
1901
|
+
context: e.context,
|
|
1902
|
+
intro: e.intro ?? !1,
|
|
1903
|
+
recover: e.recover,
|
|
1904
|
+
transformError: e.transformError
|
|
1905
|
+
}), (!e?.props?.$$host || e.sync === !1) && At(), this.#e = r.$$events;
|
|
1906
|
+
for (let e of Object.keys(this.#t)) e === "$set" || e === "$destroy" || e === "$on" || u(this, e, {
|
|
1907
|
+
get() {
|
|
1908
|
+
return this.#t[e];
|
|
1909
|
+
},
|
|
1910
|
+
set(t) {
|
|
1911
|
+
this.#t[e] = t;
|
|
1912
|
+
},
|
|
1913
|
+
enumerable: !0
|
|
1914
|
+
});
|
|
1915
|
+
this.#t.$set = (e) => {
|
|
1916
|
+
Object.assign(r, e);
|
|
1917
|
+
}, this.#t.$destroy = () => {
|
|
1918
|
+
Sr(this.#t);
|
|
1919
|
+
};
|
|
1920
|
+
}
|
|
1921
|
+
$set(e) {
|
|
1922
|
+
this.#t.$set(e);
|
|
1923
|
+
}
|
|
1924
|
+
$on(e, t) {
|
|
1925
|
+
this.#e[e] = this.#e[e] || [];
|
|
1926
|
+
let n = (...e) => t.call(this, ...e);
|
|
1927
|
+
return this.#e[e].push(n), () => {
|
|
1928
|
+
this.#e[e] = this.#e[e].filter((e) => e !== n);
|
|
1929
|
+
};
|
|
1930
|
+
}
|
|
1931
|
+
$destroy() {
|
|
1932
|
+
this.#t.$destroy();
|
|
1933
|
+
}
|
|
1934
|
+
}, zr;
|
|
1935
|
+
typeof HTMLElement == "function" && (zr = class extends HTMLElement {
|
|
1936
|
+
$$ctor;
|
|
1937
|
+
$$s;
|
|
1938
|
+
$$c;
|
|
1939
|
+
$$cn = !1;
|
|
1940
|
+
$$d = {};
|
|
1941
|
+
$$r = !1;
|
|
1942
|
+
$$p_d = {};
|
|
1943
|
+
$$l = {};
|
|
1944
|
+
$$l_u = /* @__PURE__ */ new Map();
|
|
1945
|
+
$$me;
|
|
1946
|
+
$$shadowRoot = null;
|
|
1947
|
+
constructor(e, t, n) {
|
|
1948
|
+
super(), this.$$ctor = e, this.$$s = t, n && (this.$$shadowRoot = this.attachShadow(n));
|
|
1949
|
+
}
|
|
1950
|
+
addEventListener(e, t, n) {
|
|
1951
|
+
if (this.$$l[e] = this.$$l[e] || [], this.$$l[e].push(t), this.$$c) {
|
|
1952
|
+
let n = this.$$c.$on(e, t);
|
|
1953
|
+
this.$$l_u.set(t, n);
|
|
1954
|
+
}
|
|
1955
|
+
super.addEventListener(e, t, n);
|
|
1956
|
+
}
|
|
1957
|
+
removeEventListener(e, t, n) {
|
|
1958
|
+
if (super.removeEventListener(e, t, n), this.$$c) {
|
|
1959
|
+
let e = this.$$l_u.get(t);
|
|
1960
|
+
e && (e(), this.$$l_u.delete(t));
|
|
1961
|
+
}
|
|
1962
|
+
}
|
|
1963
|
+
async connectedCallback() {
|
|
1964
|
+
if (this.$$cn = !0, !this.$$c) {
|
|
1965
|
+
if (await Promise.resolve(), !this.$$cn || this.$$c) return;
|
|
1966
|
+
function e(e) {
|
|
1967
|
+
return (t) => {
|
|
1968
|
+
let n = on("slot");
|
|
1969
|
+
e !== "default" && (n.name = e), lr(t, n);
|
|
1970
|
+
};
|
|
1971
|
+
}
|
|
1972
|
+
let t = {}, n = Vr(this);
|
|
1973
|
+
for (let r of this.$$s) r in n && (r === "default" && !this.$$d.children ? (this.$$d.children = e(r), t.default = !0) : t[r] = e(r));
|
|
1974
|
+
for (let e of this.attributes) {
|
|
1975
|
+
let t = this.$$g_p(e.name);
|
|
1976
|
+
t in this.$$d || (this.$$d[t] = Br(t, e.value, this.$$p_d, "toProp"));
|
|
1977
|
+
}
|
|
1978
|
+
for (let e in this.$$p_d) !(e in this.$$d) && this[e] !== void 0 && (this.$$d[e] = this[e], delete this[e]);
|
|
1979
|
+
this.$$c = Lr({
|
|
1980
|
+
component: this.$$ctor,
|
|
1981
|
+
target: this.$$shadowRoot || this,
|
|
1982
|
+
props: {
|
|
1983
|
+
...this.$$d,
|
|
1984
|
+
$$slots: t,
|
|
1985
|
+
$$host: this
|
|
1986
|
+
}
|
|
1987
|
+
}), this.$$me = hn(() => {
|
|
1988
|
+
yn(() => {
|
|
1989
|
+
this.$$r = !0;
|
|
1990
|
+
for (let e of l(this.$$c)) {
|
|
1991
|
+
if (!this.$$p_d[e]?.reflect) continue;
|
|
1992
|
+
this.$$d[e] = this.$$c[e];
|
|
1993
|
+
let t = Br(e, this.$$d[e], this.$$p_d, "toAttribute");
|
|
1994
|
+
t == null ? this.removeAttribute(this.$$p_d[e].attribute || e) : this.setAttribute(this.$$p_d[e].attribute || e, t);
|
|
1995
|
+
}
|
|
1996
|
+
this.$$r = !1;
|
|
1997
|
+
});
|
|
1998
|
+
});
|
|
1999
|
+
for (let e in this.$$l) for (let t of this.$$l[e]) {
|
|
2000
|
+
let n = this.$$c.$on(e, t);
|
|
2001
|
+
this.$$l_u.set(t, n);
|
|
2002
|
+
}
|
|
2003
|
+
this.$$l = {};
|
|
2004
|
+
}
|
|
2005
|
+
}
|
|
2006
|
+
attributeChangedCallback(e, t, n) {
|
|
2007
|
+
this.$$r || (e = this.$$g_p(e), this.$$d[e] = Br(e, n, this.$$p_d, "toProp"), this.$$c?.$set({ [e]: this.$$d[e] }));
|
|
2008
|
+
}
|
|
2009
|
+
disconnectedCallback() {
|
|
2010
|
+
this.$$cn = !1, Promise.resolve().then(() => {
|
|
2011
|
+
!this.$$cn && this.$$c && (this.$$c.$destroy(), this.$$me(), this.$$c = void 0);
|
|
2012
|
+
});
|
|
2013
|
+
}
|
|
2014
|
+
$$g_p(e) {
|
|
2015
|
+
return l(this.$$p_d).find((t) => this.$$p_d[t].attribute === e || !this.$$p_d[t].attribute && t.toLowerCase() === e) || e;
|
|
2016
|
+
}
|
|
2017
|
+
});
|
|
2018
|
+
function Br(e, t, n, r) {
|
|
2019
|
+
let i = n[e]?.type;
|
|
2020
|
+
if (t = i === "Boolean" && typeof t != "boolean" ? t != null : t, !r || !n[e]) return t;
|
|
2021
|
+
if (r === "toAttribute") switch (i) {
|
|
2022
|
+
case "Object":
|
|
2023
|
+
case "Array": return t == null ? null : JSON.stringify(t);
|
|
2024
|
+
case "Boolean": return t ? "" : null;
|
|
2025
|
+
case "Number": return t ?? null;
|
|
2026
|
+
default: return t;
|
|
2027
|
+
}
|
|
2028
|
+
else switch (i) {
|
|
2029
|
+
case "Object":
|
|
2030
|
+
case "Array": return t && JSON.parse(t);
|
|
2031
|
+
case "Boolean": return t;
|
|
2032
|
+
case "Number": return t == null ? t : +t;
|
|
2033
|
+
default: return t;
|
|
2034
|
+
}
|
|
2035
|
+
}
|
|
2036
|
+
function Vr(e) {
|
|
2037
|
+
let t = {};
|
|
2038
|
+
return e.childNodes.forEach((e) => {
|
|
2039
|
+
t[e.slot || "default"] = !0;
|
|
2040
|
+
}), t;
|
|
2041
|
+
}
|
|
2042
|
+
function Hr(e, t, n, r, i, a) {
|
|
2043
|
+
let o = class extends zr {
|
|
2044
|
+
constructor() {
|
|
2045
|
+
super(e, n, i), this.$$p_d = t;
|
|
2046
|
+
}
|
|
2047
|
+
static get observedAttributes() {
|
|
2048
|
+
return l(t).map((e) => (t[e].attribute || e).toLowerCase());
|
|
2049
|
+
}
|
|
2050
|
+
};
|
|
2051
|
+
return l(t).forEach((e) => {
|
|
2052
|
+
u(o.prototype, e, {
|
|
2053
|
+
get() {
|
|
2054
|
+
return this.$$c && e in this.$$c ? this.$$c[e] : this.$$d[e];
|
|
2055
|
+
},
|
|
2056
|
+
set(n) {
|
|
2057
|
+
n = Br(e, n, t), this.$$d[e] = n;
|
|
2058
|
+
var r = this.$$c;
|
|
2059
|
+
r && (d(r, e)?.get ? r[e] = n : r.$set({ [e]: n }));
|
|
2060
|
+
}
|
|
2061
|
+
});
|
|
2062
|
+
}), r.forEach((e) => {
|
|
2063
|
+
u(o.prototype, e, { get() {
|
|
2064
|
+
return this.$$c?.[e];
|
|
2065
|
+
} });
|
|
2066
|
+
}), a && (o = a(o)), e.element = o, o;
|
|
2067
|
+
}
|
|
2068
|
+
//#endregion
|
|
2069
|
+
//#region ../../shared/math-rendering-mathjax/dist/index.js
|
|
2070
|
+
var Ur = null;
|
|
2071
|
+
function Wr(e) {
|
|
2072
|
+
return typeof window > "u" || window.MathJax?.typesetPromise ? Promise.resolve() : Ur || (Ur = new Promise((t, n) => {
|
|
2073
|
+
let { useSingleDollar: r = !1, accessibility: i = !0, loadFonts: a = !0, srcUrl: o } = e, s = {
|
|
2074
|
+
loader: { load: i ? ["a11y/assistive-mml"] : [] },
|
|
2075
|
+
tex: {
|
|
2076
|
+
packages: [
|
|
2077
|
+
"base",
|
|
2078
|
+
"ams",
|
|
2079
|
+
"autoload"
|
|
2080
|
+
],
|
|
2081
|
+
macros: {
|
|
2082
|
+
parallelogram: "\\lower.2em{\\Huge\\unicode{x25B1}}",
|
|
2083
|
+
overarc: "\\overparen",
|
|
2084
|
+
napprox: "\\not\\approx",
|
|
2085
|
+
longdiv: "\\enclose{longdiv}"
|
|
2086
|
+
}
|
|
2087
|
+
},
|
|
2088
|
+
options: {
|
|
2089
|
+
enableMenu: i,
|
|
2090
|
+
enableExplorer: i,
|
|
2091
|
+
enableAssistiveMml: i
|
|
2092
|
+
},
|
|
2093
|
+
startup: {
|
|
2094
|
+
ready: () => {
|
|
2095
|
+
window.MathJax?.startup.defaultReady && (window.MathJax.startup.defaultReady(), t());
|
|
2096
|
+
},
|
|
2097
|
+
defaultReady: () => {}
|
|
2098
|
+
}
|
|
2099
|
+
};
|
|
2100
|
+
r && s.tex && (s.tex.inlineMath = [["$", "$"], ["\\(", "\\)"]], s.tex.processEscapes = !0), a || (s.chtml = { fontURL: "" }), window.MathJax = s;
|
|
2101
|
+
let c = document.createElement("script");
|
|
2102
|
+
c.src = o || "https://cdn.jsdelivr.net/npm/mathjax@4/tex-chtml.js", c.async = !0, c.onload = () => {
|
|
2103
|
+
setTimeout(t, 100);
|
|
2104
|
+
}, c.onerror = () => {
|
|
2105
|
+
n(/* @__PURE__ */ Error("Failed to load MathJax"));
|
|
2106
|
+
}, document.head.appendChild(c);
|
|
2107
|
+
}), Ur);
|
|
2108
|
+
}
|
|
2109
|
+
function Gr() {
|
|
2110
|
+
let e = window.MathJax?.startup?.document;
|
|
2111
|
+
if (typeof e?.assistiveMml == "function") try {
|
|
2112
|
+
e.assistiveMml().updateDocument?.();
|
|
2113
|
+
} catch (e) {
|
|
2114
|
+
console.warn("[mathjax-renderer] Failed to attach assistive MathML:", e);
|
|
2115
|
+
}
|
|
2116
|
+
}
|
|
2117
|
+
function Kr(e = {}) {
|
|
2118
|
+
return async (t) => {
|
|
2119
|
+
if (await Wr(e), !window.MathJax?.typesetPromise) {
|
|
2120
|
+
console.warn("[mathjax-renderer] MathJax not loaded or missing typesetPromise.");
|
|
2121
|
+
return;
|
|
2122
|
+
}
|
|
2123
|
+
await window.MathJax.typesetPromise([t]), Gr();
|
|
2124
|
+
};
|
|
2125
|
+
}
|
|
2126
|
+
var qr = null;
|
|
2127
|
+
function Jr() {
|
|
2128
|
+
return qr ||= Kr({
|
|
2129
|
+
accessibility: !0,
|
|
2130
|
+
useSingleDollar: !0
|
|
2131
|
+
}), qr;
|
|
2132
|
+
}
|
|
2133
|
+
function Yr() {
|
|
2134
|
+
if (typeof window > "u") return null;
|
|
2135
|
+
let e = window["@pie-lib/math-rendering"];
|
|
2136
|
+
return typeof e?.renderMath == "function" ? e : null;
|
|
2137
|
+
}
|
|
2138
|
+
var Xr = async (e) => {
|
|
2139
|
+
if (typeof window > "u") return;
|
|
2140
|
+
let t = typeof e == "string", n;
|
|
2141
|
+
t ? (n = document.createElement("div"), n.innerHTML = e) : n = e || document.body;
|
|
2142
|
+
let r = Yr();
|
|
2143
|
+
return r ? await r.renderMath?.(n) : await Jr()(n), t ? n.innerHTML : void 0;
|
|
2144
|
+
}, Zr = [
|
|
2145
|
+
"nbsp iexcl cent pound curren yen brvbar sect uml copy ordf laquo not shy reg macr",
|
|
2146
|
+
"deg plusmn sup2 sup3 acute micro para middot cedil sup1 ordm raquo frac14 frac12 frac34 iquest",
|
|
2147
|
+
"Agrave Aacute Acirc Atilde Auml Aring AElig Ccedil Egrave Eacute Ecirc Euml Igrave Iacute Icirc Iuml",
|
|
2148
|
+
"ETH Ntilde Ograve Oacute Ocirc Otilde Ouml times Oslash Ugrave Uacute Ucirc Uuml Yacute THORN szlig",
|
|
2149
|
+
"agrave aacute acirc atilde auml aring aelig ccedil egrave eacute ecirc euml igrave iacute icirc iuml",
|
|
2150
|
+
"eth ntilde ograve oacute ocirc otilde ouml divide oslash ugrave uacute ucirc uuml yacute thorn yuml"
|
|
2151
|
+
].join(" "), Qr = "alpha beta gamma delta epsilon zeta eta theta iota kappa lambda mu nu xi omicron pi rho sigmaf sigma tau upsilon phi chi psi omega", $r = new Map(Object.entries({
|
|
2152
|
+
quot: 34,
|
|
2153
|
+
amp: 38,
|
|
2154
|
+
apos: 39,
|
|
2155
|
+
lt: 60,
|
|
2156
|
+
gt: 62,
|
|
2157
|
+
ensp: 8194,
|
|
2158
|
+
emsp: 8195,
|
|
2159
|
+
thinsp: 8201,
|
|
2160
|
+
ndash: 8211,
|
|
2161
|
+
mdash: 8212,
|
|
2162
|
+
lsquo: 8216,
|
|
2163
|
+
rsquo: 8217,
|
|
2164
|
+
sbquo: 8218,
|
|
2165
|
+
ldquo: 8220,
|
|
2166
|
+
rdquo: 8221,
|
|
2167
|
+
bdquo: 8222,
|
|
2168
|
+
bull: 8226,
|
|
2169
|
+
hellip: 8230,
|
|
2170
|
+
prime: 8242,
|
|
2171
|
+
Prime: 8243,
|
|
2172
|
+
euro: 8364,
|
|
2173
|
+
trade: 8482,
|
|
2174
|
+
minus: 8722,
|
|
2175
|
+
radic: 8730,
|
|
2176
|
+
infin: 8734,
|
|
2177
|
+
asymp: 8776,
|
|
2178
|
+
ne: 8800,
|
|
2179
|
+
le: 8804,
|
|
2180
|
+
ge: 8805
|
|
2181
|
+
}));
|
|
2182
|
+
for (let [e, t] of Zr.split(" ").entries()) $r.set(t, 160 + e);
|
|
2183
|
+
for (let [e, t] of Qr.split(" ").entries()) $r.set(t, 945 + e), t !== "sigmaf" && $r.set(t[0].toUpperCase() + t.slice(1), 913 + e);
|
|
2184
|
+
var ei = /<\/?(?:br|p|div|li|h[1-6]|blockquote|pre|tr|td|th)\b[^>]*>/gi, ti = /<\/?[a-z][^>]*>|<!--[\s\S]*?-->/gi, ni = /&(#[0-9]+|#x[0-9a-f]+|[a-z][a-z0-9]*);/gi, ri = (e, t) => {
|
|
2185
|
+
if (t[0] === "#") {
|
|
2186
|
+
let e = t[1] === "x" || t[1] === "X", n = Number.parseInt(t.slice(e ? 2 : 1), e ? 16 : 10), r = n > 0 && n <= 1114111 && (n < 55296 || n > 57343);
|
|
2187
|
+
return String.fromCodePoint(r ? n : 65533);
|
|
2188
|
+
}
|
|
2189
|
+
let n = $r.get(t);
|
|
2190
|
+
return n === void 0 ? e : String.fromCodePoint(n);
|
|
2191
|
+
}, ii = (e) => typeof e == "string" ? e.replace(ei, " ").replace(ti, "").replace(ni, ri).replace(/\s+/g, " ").trim() : "", ai = {
|
|
2192
|
+
translation: {
|
|
2193
|
+
categorize: {
|
|
2194
|
+
limitMaxChoicesPerCategory: "You've reached the limit of {{maxChoicesPerCategory}} responses per area. To add another response, one must first be removed.",
|
|
2195
|
+
maxChoicesPerCategoryRestriction: "To change this value to {{maxChoicesPerCategory}}, each category must have {{maxChoicesPerCategory}} or fewer answer choice[s]."
|
|
2196
|
+
},
|
|
2197
|
+
ebsr: { part: "Part {{index}}" },
|
|
2198
|
+
numberLine: {
|
|
2199
|
+
addElementLimit_one: "You can only add {{count}} element",
|
|
2200
|
+
addElementLimit_other: "You can only add {{count}} elements",
|
|
2201
|
+
clearAll: "Clear all"
|
|
2202
|
+
},
|
|
2203
|
+
imageClozeAssociation: {
|
|
2204
|
+
reachedLimit_one: "You’ve reached the limit of {{count}} response per area. To add another response, one must first be removed.",
|
|
2205
|
+
reachedLimit_other: "Full"
|
|
2206
|
+
},
|
|
2207
|
+
drawingResponse: {
|
|
2208
|
+
fillColor: "Fill color",
|
|
2209
|
+
outlineColor: "Outline color",
|
|
2210
|
+
noFill: "No fill",
|
|
2211
|
+
lightblue: "Light blue",
|
|
2212
|
+
lightyellow: "Light yellow",
|
|
2213
|
+
red: "Red",
|
|
2214
|
+
orange: "Orange",
|
|
2215
|
+
yellow: "Yellow",
|
|
2216
|
+
violet: "Violet",
|
|
2217
|
+
blue: "Blue",
|
|
2218
|
+
green: "Green",
|
|
2219
|
+
white: "White",
|
|
2220
|
+
black: "Black",
|
|
2221
|
+
onDoubleClick: "Double click to edit this text. Press Enter to submit."
|
|
2222
|
+
},
|
|
2223
|
+
charting: {
|
|
2224
|
+
addCategory: "Add category",
|
|
2225
|
+
actions: "Actions",
|
|
2226
|
+
add: "Add",
|
|
2227
|
+
delete: "Delete",
|
|
2228
|
+
newLabel: "New label",
|
|
2229
|
+
reachedLimit_other: "There can't be more than {{count}} categories.",
|
|
2230
|
+
keyLegend: {
|
|
2231
|
+
incorrectAnswer: "Student incorrect answer",
|
|
2232
|
+
correctAnswer: "Student correct answer",
|
|
2233
|
+
correctKeyAnswer: "Answer key correct"
|
|
2234
|
+
}
|
|
2235
|
+
},
|
|
2236
|
+
graphing: {
|
|
2237
|
+
point: "Point",
|
|
2238
|
+
circle: "Circle",
|
|
2239
|
+
line: "Line",
|
|
2240
|
+
parabola: "Parabola",
|
|
2241
|
+
absolute: "Absolute Value",
|
|
2242
|
+
exponential: "Exponential",
|
|
2243
|
+
polygon: "Polygon",
|
|
2244
|
+
ray: "Ray",
|
|
2245
|
+
segment: "Segment",
|
|
2246
|
+
sine: "Sine",
|
|
2247
|
+
vector: "Vector",
|
|
2248
|
+
label: "Label",
|
|
2249
|
+
redo: "Redo",
|
|
2250
|
+
reset: "Reset"
|
|
2251
|
+
},
|
|
2252
|
+
mathInline: { primaryCorrectWithAlternates: "Note: The answer shown above is the primary correct answer specified by the author for this item, but other answers may also be recognized as correct." },
|
|
2253
|
+
mcPopulatedBlank: {
|
|
2254
|
+
answerChoices: "Answer choices",
|
|
2255
|
+
blankLabel: "blank",
|
|
2256
|
+
emptyBlank: "(blank)",
|
|
2257
|
+
blankPreSelectionHint: "The answer you choose will appear on the blank line above.",
|
|
2258
|
+
correctAnswerSelected: "Correct answer selected",
|
|
2259
|
+
incorrectAnswerSelected: "Incorrect answer selected",
|
|
2260
|
+
selectedAnswerImage: "Selected answer image",
|
|
2261
|
+
choiceImage: "Choice {{id}}",
|
|
2262
|
+
clickToEnableAutoplay: "Click to enable audio autoplay",
|
|
2263
|
+
audioResourceUnavailable: "Audio is enabled but no playable audio URL is configured.",
|
|
2264
|
+
listen: "Listen",
|
|
2265
|
+
listenSilentAlt: "Repeat instructions",
|
|
2266
|
+
listenPlayingAlt: "Instructions are playing",
|
|
2267
|
+
printAudio: "Audio:",
|
|
2268
|
+
printTranscript: "Transcript:"
|
|
2269
|
+
},
|
|
2270
|
+
multipleChoice: {
|
|
2271
|
+
minSelections: "Select at least {{minSelections}}.",
|
|
2272
|
+
maxSelections_one: "Only {{maxSelections}} answer is allowed.",
|
|
2273
|
+
maxSelections_other: "Only {{maxSelections}} answers are allowed.",
|
|
2274
|
+
minmaxSelections_equal: "Select {{minSelections}}.",
|
|
2275
|
+
minmaxSelections_range: "Select between {{minSelections}} and {{maxSelections}}."
|
|
2276
|
+
},
|
|
2277
|
+
selectText: {
|
|
2278
|
+
correctAnswerSelected: "Correct",
|
|
2279
|
+
correctAnswerNotSelected: "Correct Answer Not Selected",
|
|
2280
|
+
incorrectSelection: "Incorrect Selection",
|
|
2281
|
+
key: "Key"
|
|
2282
|
+
},
|
|
2283
|
+
simpleCloze: {
|
|
2284
|
+
correctAnswerShown: "Correct answer",
|
|
2285
|
+
correct: "Correct",
|
|
2286
|
+
incorrect: "Incorrect",
|
|
2287
|
+
unanswered: "No answer",
|
|
2288
|
+
placeholder: "Enter your answer...",
|
|
2289
|
+
answerInput: "Your answer",
|
|
2290
|
+
printCorrectAnswer: "Correct answer:",
|
|
2291
|
+
printAnswerBlank: "Answer blank"
|
|
2292
|
+
},
|
|
2293
|
+
vennClassification: {
|
|
2294
|
+
tray: "Tiles to classify",
|
|
2295
|
+
unknownTarget: "unknown",
|
|
2296
|
+
cancelled: "Cancelled",
|
|
2297
|
+
returnedToTray: "{{name}} returned to tray",
|
|
2298
|
+
placedIn: "{{name}} placed in {{target}}",
|
|
2299
|
+
pickedUp: "Picked up {{name}}",
|
|
2300
|
+
pickedUpWithKeyboard: "Picked up {{name}}, drop target: {{target}}. Use arrow keys to choose a drop target, Enter to drop, Escape to cancel.",
|
|
2301
|
+
dropTarget: "Drop target: {{target}}",
|
|
2302
|
+
unsupportedCircles_one: "This diagram cannot be shown: it has {{count}} circle, and only {{supported}} are supported.",
|
|
2303
|
+
unsupportedCircles_other: "This diagram cannot be shown: it has {{count}} circles, and only {{supported}} are supported.",
|
|
2304
|
+
setNumber: "Set {{number}}",
|
|
2305
|
+
regionOnly: "{{set}} only",
|
|
2306
|
+
regionNeither: "Neither {{first}} nor {{second}}",
|
|
2307
|
+
regionNoneOf: "None of {{sets}}",
|
|
2308
|
+
regionAndSeparator: " and ",
|
|
2309
|
+
tileFallbackName: "Tile",
|
|
2310
|
+
tileNotPlaced: "not placed",
|
|
2311
|
+
tileInRegion: "in {{region}}",
|
|
2312
|
+
tileCorrect: "correct",
|
|
2313
|
+
tileIncorrect: "incorrect"
|
|
2314
|
+
}
|
|
2315
|
+
},
|
|
2316
|
+
common: {
|
|
2317
|
+
undo: "Undo",
|
|
2318
|
+
clearAll: "Clear all",
|
|
2319
|
+
correct: "Correct",
|
|
2320
|
+
incorrect: "Incorrect",
|
|
2321
|
+
showCorrectAnswer: "Show correct answer",
|
|
2322
|
+
hideCorrectAnswer: "Hide correct answer",
|
|
2323
|
+
showTeacherInstructions: "Show Teacher Instructions",
|
|
2324
|
+
hideTeacherInstructions: "Hide Teacher Instructions",
|
|
2325
|
+
commonCorrectAnswerWithAlternates: "Note: The answer shown above is the most common correct answer for this item. One or more additional correct answers are also defined, and will also be recognized as correct.",
|
|
2326
|
+
warning: "Warning",
|
|
2327
|
+
showNote: "Show Note",
|
|
2328
|
+
hideNote: "Hide Note",
|
|
2329
|
+
cancel: "Cancel"
|
|
2330
|
+
}
|
|
2331
|
+
}, oi = {
|
|
2332
|
+
translation: {
|
|
2333
|
+
categorize: {
|
|
2334
|
+
limitMaxChoicesPerCategory: "Has alcanzado el límite de {{maxChoicesPerCategory}} respuestas por área. Para agregar otra respuesta, primero se debe eliminar una respuesta.",
|
|
2335
|
+
maxChoicesPerCategoryRestriction: "Para cambiar este valor a {{maxChoicesPerCategory}}, cada categoría debe tener {{maxChoicesPerCategory}} o menos opciones de respuesta"
|
|
2336
|
+
},
|
|
2337
|
+
ebsr: { part: "Parte {{index}}" },
|
|
2338
|
+
numberLine: {
|
|
2339
|
+
addElementLimit_one: "Solo puedes agregar {{count}} elemento",
|
|
2340
|
+
addElementLimit_other: "Solo puedes agregar {{count}} elementos",
|
|
2341
|
+
clearAll: "Borrar todo"
|
|
2342
|
+
},
|
|
2343
|
+
imageClozeAssociation: {
|
|
2344
|
+
reachedLimit_one: "Has alcanzado el límite de {{count}} respuesta por área. Para agregar otra respuesta, primero se debe eliminar una respuesta.",
|
|
2345
|
+
reachedLimit_other: "Lleno"
|
|
2346
|
+
},
|
|
2347
|
+
drawingResponse: {
|
|
2348
|
+
fillColor: "Color de relleno",
|
|
2349
|
+
outlineColor: "Color del contorno",
|
|
2350
|
+
noFill: "Sin relleno",
|
|
2351
|
+
lightblue: "Azul claro",
|
|
2352
|
+
lightyellow: "Amarillo claro",
|
|
2353
|
+
red: "Rojo",
|
|
2354
|
+
orange: "Naranja",
|
|
2355
|
+
yellow: "Amarillo",
|
|
2356
|
+
violet: "Violeta",
|
|
2357
|
+
blue: "Azul",
|
|
2358
|
+
green: "Verde",
|
|
2359
|
+
white: "Blanco",
|
|
2360
|
+
black: "Negro",
|
|
2361
|
+
onDoubleClick: "Haz doble clic para revisar este texto. Presiona el botón de ingreso para enviar"
|
|
2362
|
+
},
|
|
2363
|
+
charting: {
|
|
2364
|
+
addCategory: "Añadir categoría",
|
|
2365
|
+
actions: "Acciones",
|
|
2366
|
+
add: "Añadir",
|
|
2367
|
+
delete: "Eliminar",
|
|
2368
|
+
newLabel: "Nueva etiqueta",
|
|
2369
|
+
reachedLimit_other: "No puede haber más de {{count}} categorías.",
|
|
2370
|
+
keyLegend: {
|
|
2371
|
+
incorrectAnswer: "Respuesta incorrecta del estudiante",
|
|
2372
|
+
correctAnswer: "Respuesta correcta del estudiante",
|
|
2373
|
+
correctKeyAnswer: "Clave de respuesta correcta"
|
|
2374
|
+
}
|
|
2375
|
+
},
|
|
2376
|
+
graphing: {
|
|
2377
|
+
point: "Punto",
|
|
2378
|
+
circle: "Circulo",
|
|
2379
|
+
line: "Línea",
|
|
2380
|
+
parabola: "Parábola",
|
|
2381
|
+
absolute: "Valor absoluto",
|
|
2382
|
+
exponential: "Exponencial",
|
|
2383
|
+
polygon: "Polígono",
|
|
2384
|
+
ray: "Semirrecta",
|
|
2385
|
+
segment: "Segmento ",
|
|
2386
|
+
sine: "Seno",
|
|
2387
|
+
vector: "Vector",
|
|
2388
|
+
label: "Etiqueta",
|
|
2389
|
+
redo: "Rehacer",
|
|
2390
|
+
reset: "Reiniciar"
|
|
2391
|
+
},
|
|
2392
|
+
mathInline: { primaryCorrectWithAlternates: "Nota: La respuesta que se muestra arriba es la respuesta correcta principal especificada por el autor para esta pregunta, pero también se pueden reconocer otras respuestas como correctas." },
|
|
2393
|
+
mcPopulatedBlank: {
|
|
2394
|
+
answerChoices: "Opciones de respuesta",
|
|
2395
|
+
blankLabel: "espacio en blanco",
|
|
2396
|
+
emptyBlank: "(en blanco)",
|
|
2397
|
+
blankPreSelectionHint: "La respuesta que elijas aparecerá en la línea en blanco de arriba.",
|
|
2398
|
+
correctAnswerSelected: "Respuesta correcta seleccionada",
|
|
2399
|
+
incorrectAnswerSelected: "Respuesta incorrecta seleccionada",
|
|
2400
|
+
selectedAnswerImage: "Imagen de la respuesta seleccionada",
|
|
2401
|
+
choiceImage: "Opción {{id}}",
|
|
2402
|
+
clickToEnableAutoplay: "Haz clic para activar la reproducción automática del audio",
|
|
2403
|
+
audioResourceUnavailable: "El audio está activado, pero no hay una URL de audio reproducible configurada.",
|
|
2404
|
+
listen: "Escuchar",
|
|
2405
|
+
listenSilentAlt: "Escuchar. Repetir las instrucciones.",
|
|
2406
|
+
listenPlayingAlt: "Escuchar. Estas son las instrucciones.",
|
|
2407
|
+
printAudio: "Audio:",
|
|
2408
|
+
printTranscript: "Transcripción:"
|
|
2409
|
+
},
|
|
2410
|
+
multipleChoice: {
|
|
2411
|
+
minSelections: "Seleccione al menos {{minSelections}}.",
|
|
2412
|
+
maxSelections_one: "Sólo se permite {{maxSelections}} respuesta.",
|
|
2413
|
+
maxSelections_other: "Sólo se permiten {{maxSelections}} respuestas.",
|
|
2414
|
+
minmaxSelections_equal: "Seleccione {{minSelections}}.",
|
|
2415
|
+
minmaxSelections_range: "Seleccione entre {{minSelections}} y {{maxSelections}}."
|
|
2416
|
+
},
|
|
2417
|
+
selectText: {
|
|
2418
|
+
correctAnswerSelected: "Respuesta Correcta",
|
|
2419
|
+
correctAnswerNotSelected: "Respuesta Correcta No Seleccionada",
|
|
2420
|
+
incorrectSelection: "Selección Incorrecta",
|
|
2421
|
+
key: "Clave"
|
|
2422
|
+
},
|
|
2423
|
+
simpleCloze: {
|
|
2424
|
+
correctAnswerShown: "Respuesta correcta",
|
|
2425
|
+
correct: "Correcto",
|
|
2426
|
+
incorrect: "Incorrecto",
|
|
2427
|
+
unanswered: "Sin respuesta",
|
|
2428
|
+
placeholder: "Escribe tu respuesta...",
|
|
2429
|
+
answerInput: "Tu respuesta",
|
|
2430
|
+
printCorrectAnswer: "Respuesta correcta:",
|
|
2431
|
+
printAnswerBlank: "Espacio para la respuesta"
|
|
2432
|
+
},
|
|
2433
|
+
vennClassification: {
|
|
2434
|
+
tray: "Fichas para clasificar",
|
|
2435
|
+
unknownTarget: "desconocido",
|
|
2436
|
+
cancelled: "Cancelado",
|
|
2437
|
+
returnedToTray: "Se devolvió {{name}} a la bandeja",
|
|
2438
|
+
placedIn: "Se colocó {{name}} en {{target}}",
|
|
2439
|
+
pickedUp: "Se tomó {{name}}",
|
|
2440
|
+
pickedUpWithKeyboard: "Se tomó {{name}}, destino: {{target}}. Usa las flechas para elegir un destino, Enter para soltar y Escape para cancelar.",
|
|
2441
|
+
dropTarget: "Destino: {{target}}",
|
|
2442
|
+
unsupportedCircles_one: "No se puede mostrar este diagrama: tiene {{count}} círculo, y solo se admiten {{supported}}.",
|
|
2443
|
+
unsupportedCircles_other: "No se puede mostrar este diagrama: tiene {{count}} círculos, y solo se admiten {{supported}}.",
|
|
2444
|
+
setNumber: "Conjunto {{number}}",
|
|
2445
|
+
regionOnly: "Solo {{set}}",
|
|
2446
|
+
regionNeither: "Ni {{first}} ni {{second}}",
|
|
2447
|
+
regionNoneOf: "Ninguno de {{sets}}",
|
|
2448
|
+
regionAndSeparator: " y ",
|
|
2449
|
+
tileFallbackName: "Ficha",
|
|
2450
|
+
tileNotPlaced: "sin colocar",
|
|
2451
|
+
tileInRegion: "en {{region}}",
|
|
2452
|
+
tileCorrect: "correcta",
|
|
2453
|
+
tileIncorrect: "incorrecta"
|
|
2454
|
+
}
|
|
2455
|
+
},
|
|
2456
|
+
common: {
|
|
2457
|
+
undo: "Deshacer",
|
|
2458
|
+
clearAll: "Borrar todo",
|
|
2459
|
+
correct: "Correcto",
|
|
2460
|
+
incorrect: "Incorrecto",
|
|
2461
|
+
showCorrectAnswer: "Mostrar respuesta correcta",
|
|
2462
|
+
hideCorrectAnswer: "Ocultar respuesta correcta",
|
|
2463
|
+
showTeacherInstructions: "Mostrar instrucciones para el maestro",
|
|
2464
|
+
hideTeacherInstructions: "Ocultar instrucciones para el maestro",
|
|
2465
|
+
commonCorrectAnswerWithAlternates: "Nota: La respuesta que se muestra arriba es la respuesta correcta más común para esta pregunta. También se definen una o más respuestas correctas adicionales, y también se reconocerán como correctas.",
|
|
2466
|
+
warning: "Advertencia",
|
|
2467
|
+
showNote: "Mostrar Nota",
|
|
2468
|
+
hideNote: "Ocultar Nota",
|
|
2469
|
+
cancel: "Cancelar"
|
|
2470
|
+
}
|
|
2471
|
+
}, Z = (e) => typeof e == "string", si = () => {
|
|
2472
|
+
let e, t, n = new Promise((n, r) => {
|
|
2473
|
+
e = n, t = r;
|
|
2474
|
+
});
|
|
2475
|
+
return n.resolve = e, n.reject = t, n;
|
|
2476
|
+
}, ci = (e) => e == null ? "" : "" + e, li = (e, t, n) => {
|
|
2477
|
+
e.forEach((e) => {
|
|
2478
|
+
t[e] && (n[e] = t[e]);
|
|
2479
|
+
});
|
|
2480
|
+
}, ui = /###/g, di = (e) => e && e.indexOf("###") > -1 ? e.replace(ui, ".") : e, fi = (e) => !e || Z(e), pi = (e, t, n) => {
|
|
2481
|
+
let r = Z(t) ? t.split(".") : t, i = 0;
|
|
2482
|
+
for (; i < r.length - 1;) {
|
|
2483
|
+
if (fi(e)) return {};
|
|
2484
|
+
let t = di(r[i]);
|
|
2485
|
+
!e[t] && n && (e[t] = new n()), e = Object.prototype.hasOwnProperty.call(e, t) ? e[t] : {}, ++i;
|
|
2486
|
+
}
|
|
2487
|
+
return fi(e) ? {} : {
|
|
2488
|
+
obj: e,
|
|
2489
|
+
k: di(r[i])
|
|
2490
|
+
};
|
|
2491
|
+
}, mi = (e, t, n) => {
|
|
2492
|
+
let { obj: r, k: i } = pi(e, t, Object);
|
|
2493
|
+
if (r !== void 0 || t.length === 1) {
|
|
2494
|
+
r[i] = n;
|
|
2495
|
+
return;
|
|
2496
|
+
}
|
|
2497
|
+
let a = t[t.length - 1], o = t.slice(0, t.length - 1), s = pi(e, o, Object);
|
|
2498
|
+
for (; s.obj === void 0 && o.length;) a = `${o[o.length - 1]}.${a}`, o = o.slice(0, o.length - 1), s = pi(e, o, Object), s?.obj && s.obj[`${s.k}.${a}`] !== void 0 && (s.obj = void 0);
|
|
2499
|
+
s.obj[`${s.k}.${a}`] = n;
|
|
2500
|
+
}, hi = (e, t, n, r) => {
|
|
2501
|
+
let { obj: i, k: a } = pi(e, t, Object);
|
|
2502
|
+
i[a] = i[a] || [], i[a].push(n);
|
|
2503
|
+
}, gi = (e, t) => {
|
|
2504
|
+
let { obj: n, k: r } = pi(e, t);
|
|
2505
|
+
if (n && Object.prototype.hasOwnProperty.call(n, r)) return n[r];
|
|
2506
|
+
}, _i = (e, t, n) => {
|
|
2507
|
+
let r = gi(e, n);
|
|
2508
|
+
return r === void 0 ? gi(t, n) : r;
|
|
2509
|
+
}, vi = (e, t, n) => {
|
|
2510
|
+
for (let r in t) r !== "__proto__" && r !== "constructor" && (r in e ? Z(e[r]) || e[r] instanceof String || Z(t[r]) || t[r] instanceof String ? n && (e[r] = t[r]) : vi(e[r], t[r], n) : e[r] = t[r]);
|
|
2511
|
+
return e;
|
|
2512
|
+
}, yi = (e) => e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&"), bi = {
|
|
2513
|
+
"&": "&",
|
|
2514
|
+
"<": "<",
|
|
2515
|
+
">": ">",
|
|
2516
|
+
"\"": """,
|
|
2517
|
+
"'": "'",
|
|
2518
|
+
"/": "/"
|
|
2519
|
+
}, xi = (e) => Z(e) ? e.replace(/[&<>"'\/]/g, (e) => bi[e]) : e, Si = class {
|
|
2520
|
+
constructor(e) {
|
|
2521
|
+
this.capacity = e, this.regExpMap = /* @__PURE__ */ new Map(), this.regExpQueue = [];
|
|
2522
|
+
}
|
|
2523
|
+
getRegExp(e) {
|
|
2524
|
+
let t = this.regExpMap.get(e);
|
|
2525
|
+
if (t !== void 0) return t;
|
|
2526
|
+
let n = new RegExp(e);
|
|
2527
|
+
return this.regExpQueue.length === this.capacity && this.regExpMap.delete(this.regExpQueue.shift()), this.regExpMap.set(e, n), this.regExpQueue.push(e), n;
|
|
2528
|
+
}
|
|
2529
|
+
}, Ci = [
|
|
2530
|
+
" ",
|
|
2531
|
+
",",
|
|
2532
|
+
"?",
|
|
2533
|
+
"!",
|
|
2534
|
+
";"
|
|
2535
|
+
], wi = new Si(20), Ti = (e, t, n) => {
|
|
2536
|
+
t ||= "", n ||= "";
|
|
2537
|
+
let r = Ci.filter((e) => t.indexOf(e) < 0 && n.indexOf(e) < 0);
|
|
2538
|
+
if (r.length === 0) return !0;
|
|
2539
|
+
let i = wi.getRegExp(`(${r.map((e) => e === "?" ? "\\?" : e).join("|")})`), a = !i.test(e);
|
|
2540
|
+
if (!a) {
|
|
2541
|
+
let t = e.indexOf(n);
|
|
2542
|
+
t > 0 && !i.test(e.substring(0, t)) && (a = !0);
|
|
2543
|
+
}
|
|
2544
|
+
return a;
|
|
2545
|
+
}, Ei = (e, t, n = ".") => {
|
|
2546
|
+
if (!e) return;
|
|
2547
|
+
if (e[t]) return Object.prototype.hasOwnProperty.call(e, t) ? e[t] : void 0;
|
|
2548
|
+
let r = t.split(n), i = e;
|
|
2549
|
+
for (let e = 0; e < r.length;) {
|
|
2550
|
+
if (!i || typeof i != "object") return;
|
|
2551
|
+
let t, a = "";
|
|
2552
|
+
for (let o = e; o < r.length; ++o) if (o !== e && (a += n), a += r[o], t = i[a], t !== void 0) {
|
|
2553
|
+
if ([
|
|
2554
|
+
"string",
|
|
2555
|
+
"number",
|
|
2556
|
+
"boolean"
|
|
2557
|
+
].indexOf(typeof t) > -1 && o < r.length - 1) continue;
|
|
2558
|
+
e += o - e + 1;
|
|
2559
|
+
break;
|
|
2560
|
+
}
|
|
2561
|
+
i = t;
|
|
2562
|
+
}
|
|
2563
|
+
return i;
|
|
2564
|
+
}, Di = (e) => e?.replace(/_/g, "-"), Oi = {
|
|
2565
|
+
type: "logger",
|
|
2566
|
+
log(e) {
|
|
2567
|
+
this.output("log", e);
|
|
2568
|
+
},
|
|
2569
|
+
warn(e) {
|
|
2570
|
+
this.output("warn", e);
|
|
2571
|
+
},
|
|
2572
|
+
error(e) {
|
|
2573
|
+
this.output("error", e);
|
|
2574
|
+
},
|
|
2575
|
+
output(e, t) {
|
|
2576
|
+
console?.[e]?.apply?.(console, t);
|
|
2577
|
+
}
|
|
2578
|
+
}, Q = new class e {
|
|
2579
|
+
constructor(e, t = {}) {
|
|
2580
|
+
this.init(e, t);
|
|
2581
|
+
}
|
|
2582
|
+
init(e, t = {}) {
|
|
2583
|
+
this.prefix = t.prefix || "i18next:", this.logger = e || Oi, this.options = t, this.debug = t.debug;
|
|
2584
|
+
}
|
|
2585
|
+
log(...e) {
|
|
2586
|
+
return this.forward(e, "log", "", !0);
|
|
2587
|
+
}
|
|
2588
|
+
warn(...e) {
|
|
2589
|
+
return this.forward(e, "warn", "", !0);
|
|
2590
|
+
}
|
|
2591
|
+
error(...e) {
|
|
2592
|
+
return this.forward(e, "error", "");
|
|
2593
|
+
}
|
|
2594
|
+
deprecate(...e) {
|
|
2595
|
+
return this.forward(e, "warn", "WARNING DEPRECATED: ", !0);
|
|
2596
|
+
}
|
|
2597
|
+
forward(e, t, n, r) {
|
|
2598
|
+
return r && !this.debug ? null : (Z(e[0]) && (e[0] = `${n}${this.prefix} ${e[0]}`), this.logger[t](e));
|
|
2599
|
+
}
|
|
2600
|
+
create(t) {
|
|
2601
|
+
return new e(this.logger, {
|
|
2602
|
+
prefix: `${this.prefix}:${t}:`,
|
|
2603
|
+
...this.options
|
|
2604
|
+
});
|
|
2605
|
+
}
|
|
2606
|
+
clone(t) {
|
|
2607
|
+
return t ||= this.options, t.prefix = t.prefix || this.prefix, new e(this.logger, t);
|
|
2608
|
+
}
|
|
2609
|
+
}(), ki = class {
|
|
2610
|
+
constructor() {
|
|
2611
|
+
this.observers = {};
|
|
2612
|
+
}
|
|
2613
|
+
on(e, t) {
|
|
2614
|
+
return e.split(" ").forEach((e) => {
|
|
2615
|
+
this.observers[e] || (this.observers[e] = /* @__PURE__ */ new Map());
|
|
2616
|
+
let n = this.observers[e].get(t) || 0;
|
|
2617
|
+
this.observers[e].set(t, n + 1);
|
|
2618
|
+
}), this;
|
|
2619
|
+
}
|
|
2620
|
+
off(e, t) {
|
|
2621
|
+
if (this.observers[e]) {
|
|
2622
|
+
if (!t) {
|
|
2623
|
+
delete this.observers[e];
|
|
2624
|
+
return;
|
|
2625
|
+
}
|
|
2626
|
+
this.observers[e].delete(t);
|
|
2627
|
+
}
|
|
2628
|
+
}
|
|
2629
|
+
emit(e, ...t) {
|
|
2630
|
+
this.observers[e] && Array.from(this.observers[e].entries()).forEach(([e, n]) => {
|
|
2631
|
+
for (let r = 0; r < n; r++) e(...t);
|
|
2632
|
+
}), this.observers["*"] && Array.from(this.observers["*"].entries()).forEach(([n, r]) => {
|
|
2633
|
+
for (let i = 0; i < r; i++) n.apply(n, [e, ...t]);
|
|
2634
|
+
});
|
|
2635
|
+
}
|
|
2636
|
+
}, Ai = class extends ki {
|
|
2637
|
+
constructor(e, t = {
|
|
2638
|
+
ns: ["translation"],
|
|
2639
|
+
defaultNS: "translation"
|
|
2640
|
+
}) {
|
|
2641
|
+
super(), this.data = e || {}, this.options = t, this.options.keySeparator === void 0 && (this.options.keySeparator = "."), this.options.ignoreJSONStructure === void 0 && (this.options.ignoreJSONStructure = !0);
|
|
2642
|
+
}
|
|
2643
|
+
addNamespaces(e) {
|
|
2644
|
+
this.options.ns.indexOf(e) < 0 && this.options.ns.push(e);
|
|
2645
|
+
}
|
|
2646
|
+
removeNamespaces(e) {
|
|
2647
|
+
let t = this.options.ns.indexOf(e);
|
|
2648
|
+
t > -1 && this.options.ns.splice(t, 1);
|
|
2649
|
+
}
|
|
2650
|
+
getResource(e, t, n, r = {}) {
|
|
2651
|
+
let i = r.keySeparator === void 0 ? this.options.keySeparator : r.keySeparator, a = r.ignoreJSONStructure === void 0 ? this.options.ignoreJSONStructure : r.ignoreJSONStructure, o;
|
|
2652
|
+
e.indexOf(".") > -1 ? o = e.split(".") : (o = [e, t], n && (Array.isArray(n) ? o.push(...n) : Z(n) && i ? o.push(...n.split(i)) : o.push(n)));
|
|
2653
|
+
let s = gi(this.data, o);
|
|
2654
|
+
return !s && !t && !n && e.indexOf(".") > -1 && (e = o[0], t = o[1], n = o.slice(2).join(".")), s || !a || !Z(n) ? s : Ei(this.data?.[e]?.[t], n, i);
|
|
2655
|
+
}
|
|
2656
|
+
addResource(e, t, n, r, i = { silent: !1 }) {
|
|
2657
|
+
let a = i.keySeparator === void 0 ? this.options.keySeparator : i.keySeparator, o = [e, t];
|
|
2658
|
+
n && (o = o.concat(a ? n.split(a) : n)), e.indexOf(".") > -1 && (o = e.split("."), r = t, t = o[1]), this.addNamespaces(t), mi(this.data, o, r), i.silent || this.emit("added", e, t, n, r);
|
|
2659
|
+
}
|
|
2660
|
+
addResources(e, t, n, r = { silent: !1 }) {
|
|
2661
|
+
for (let r in n) (Z(n[r]) || Array.isArray(n[r])) && this.addResource(e, t, r, n[r], { silent: !0 });
|
|
2662
|
+
r.silent || this.emit("added", e, t, n);
|
|
2663
|
+
}
|
|
2664
|
+
addResourceBundle(e, t, n, r, i, a = {
|
|
2665
|
+
silent: !1,
|
|
2666
|
+
skipCopy: !1
|
|
2667
|
+
}) {
|
|
2668
|
+
let o = [e, t];
|
|
2669
|
+
e.indexOf(".") > -1 && (o = e.split("."), r = n, n = t, t = o[1]), this.addNamespaces(t);
|
|
2670
|
+
let s = gi(this.data, o) || {};
|
|
2671
|
+
a.skipCopy || (n = JSON.parse(JSON.stringify(n))), r ? vi(s, n, i) : s = {
|
|
2672
|
+
...s,
|
|
2673
|
+
...n
|
|
2674
|
+
}, mi(this.data, o, s), a.silent || this.emit("added", e, t, n);
|
|
2675
|
+
}
|
|
2676
|
+
removeResourceBundle(e, t) {
|
|
2677
|
+
this.hasResourceBundle(e, t) && delete this.data[e][t], this.removeNamespaces(t), this.emit("removed", e, t);
|
|
2678
|
+
}
|
|
2679
|
+
hasResourceBundle(e, t) {
|
|
2680
|
+
return this.getResource(e, t) !== void 0;
|
|
2681
|
+
}
|
|
2682
|
+
getResourceBundle(e, t) {
|
|
2683
|
+
return t ||= this.options.defaultNS, this.getResource(e, t);
|
|
2684
|
+
}
|
|
2685
|
+
getDataByLanguage(e) {
|
|
2686
|
+
return this.data[e];
|
|
2687
|
+
}
|
|
2688
|
+
hasLanguageSomeTranslations(e) {
|
|
2689
|
+
let t = this.getDataByLanguage(e);
|
|
2690
|
+
return !!(t && Object.keys(t) || []).find((e) => t[e] && Object.keys(t[e]).length > 0);
|
|
2691
|
+
}
|
|
2692
|
+
toJSON() {
|
|
2693
|
+
return this.data;
|
|
2694
|
+
}
|
|
2695
|
+
}, ji = {
|
|
2696
|
+
processors: {},
|
|
2697
|
+
addPostProcessor(e) {
|
|
2698
|
+
this.processors[e.name] = e;
|
|
2699
|
+
},
|
|
2700
|
+
handle(e, t, n, r, i) {
|
|
2701
|
+
return e.forEach((e) => {
|
|
2702
|
+
t = this.processors[e]?.process(t, n, r, i) ?? t;
|
|
2703
|
+
}), t;
|
|
2704
|
+
}
|
|
2705
|
+
}, Mi = Symbol("i18next/PATH_KEY");
|
|
2706
|
+
function Ni() {
|
|
2707
|
+
let e = [], t = Object.create(null), n;
|
|
2708
|
+
return t.get = (r, i) => (n?.revoke?.(), i === Mi ? e : (e.push(i), n = Proxy.revocable(r, t), n.proxy)), Proxy.revocable(Object.create(null), t).proxy;
|
|
2709
|
+
}
|
|
2710
|
+
function Pi(e, t) {
|
|
2711
|
+
let { [Mi]: n } = e(Ni()), r = t?.keySeparator ?? ".", i = t?.nsSeparator ?? ":";
|
|
2712
|
+
if (n.length > 1 && i) {
|
|
2713
|
+
let e = t?.ns, a = Array.isArray(e) ? e : null;
|
|
2714
|
+
if (a && a.length > 1 && a.slice(1).includes(n[0])) return `${n[0]}${i}${n.slice(1).join(r)}`;
|
|
2715
|
+
}
|
|
2716
|
+
return n.join(r);
|
|
2717
|
+
}
|
|
2718
|
+
var Fi = {}, Ii = (e) => !Z(e) && typeof e != "boolean" && typeof e != "number", Li = class e extends ki {
|
|
2719
|
+
constructor(e, t = {}) {
|
|
2720
|
+
super(), li([
|
|
2721
|
+
"resourceStore",
|
|
2722
|
+
"languageUtils",
|
|
2723
|
+
"pluralResolver",
|
|
2724
|
+
"interpolator",
|
|
2725
|
+
"backendConnector",
|
|
2726
|
+
"i18nFormat",
|
|
2727
|
+
"utils"
|
|
2728
|
+
], e, this), this.options = t, this.options.keySeparator === void 0 && (this.options.keySeparator = "."), this.logger = Q.create("translator");
|
|
2729
|
+
}
|
|
2730
|
+
changeLanguage(e) {
|
|
2731
|
+
e && (this.language = e);
|
|
2732
|
+
}
|
|
2733
|
+
exists(e, t = { interpolation: {} }) {
|
|
2734
|
+
let n = { ...t };
|
|
2735
|
+
if (e == null) return !1;
|
|
2736
|
+
let r = this.resolve(e, n);
|
|
2737
|
+
if (r?.res === void 0) return !1;
|
|
2738
|
+
let i = Ii(r.res);
|
|
2739
|
+
return !(n.returnObjects === !1 && i);
|
|
2740
|
+
}
|
|
2741
|
+
extractFromKey(e, t) {
|
|
2742
|
+
let n = t.nsSeparator === void 0 ? this.options.nsSeparator : t.nsSeparator;
|
|
2743
|
+
n === void 0 && (n = ":");
|
|
2744
|
+
let r = t.keySeparator === void 0 ? this.options.keySeparator : t.keySeparator, i = t.ns || this.options.defaultNS || [], a = n && e.indexOf(n) > -1, o = !this.options.userDefinedKeySeparator && !t.keySeparator && !this.options.userDefinedNsSeparator && !t.nsSeparator && !Ti(e, n, r);
|
|
2745
|
+
if (a && !o) {
|
|
2746
|
+
let t = e.match(this.interpolator.nestingRegexp);
|
|
2747
|
+
if (t && t.length > 0) return {
|
|
2748
|
+
key: e,
|
|
2749
|
+
namespaces: Z(i) ? [i] : i
|
|
2750
|
+
};
|
|
2751
|
+
let a = e.split(n);
|
|
2752
|
+
(n !== r || n === r && this.options.ns.indexOf(a[0]) > -1) && (i = a.shift()), e = a.join(r);
|
|
2753
|
+
}
|
|
2754
|
+
return {
|
|
2755
|
+
key: e,
|
|
2756
|
+
namespaces: Z(i) ? [i] : i
|
|
2757
|
+
};
|
|
2758
|
+
}
|
|
2759
|
+
translate(t, n, r) {
|
|
2760
|
+
let i = typeof n == "object" ? { ...n } : n;
|
|
2761
|
+
if (typeof i != "object" && this.options.overloadTranslationOptionHandler && (i = this.options.overloadTranslationOptionHandler(arguments)), typeof i == "object" && (i = { ...i }), i ||= {}, t == null) return "";
|
|
2762
|
+
typeof t == "function" && (t = Pi(t, {
|
|
2763
|
+
...this.options,
|
|
2764
|
+
...i
|
|
2765
|
+
})), Array.isArray(t) || (t = [String(t)]), t = t.map((e) => typeof e == "function" ? Pi(e, {
|
|
2766
|
+
...this.options,
|
|
2767
|
+
...i
|
|
2768
|
+
}) : String(e));
|
|
2769
|
+
let a = i.returnDetails === void 0 ? this.options.returnDetails : i.returnDetails, o = i.keySeparator === void 0 ? this.options.keySeparator : i.keySeparator, { key: s, namespaces: c } = this.extractFromKey(t[t.length - 1], i), l = c[c.length - 1], u = i.nsSeparator === void 0 ? this.options.nsSeparator : i.nsSeparator;
|
|
2770
|
+
u === void 0 && (u = ":");
|
|
2771
|
+
let d = i.lng || this.language, f = i.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
|
|
2772
|
+
if (d?.toLowerCase() === "cimode") return f ? a ? {
|
|
2773
|
+
res: `${l}${u}${s}`,
|
|
2774
|
+
usedKey: s,
|
|
2775
|
+
exactUsedKey: s,
|
|
2776
|
+
usedLng: d,
|
|
2777
|
+
usedNS: l,
|
|
2778
|
+
usedParams: this.getUsedParamsDetails(i)
|
|
2779
|
+
} : `${l}${u}${s}` : a ? {
|
|
2780
|
+
res: s,
|
|
2781
|
+
usedKey: s,
|
|
2782
|
+
exactUsedKey: s,
|
|
2783
|
+
usedLng: d,
|
|
2784
|
+
usedNS: l,
|
|
2785
|
+
usedParams: this.getUsedParamsDetails(i)
|
|
2786
|
+
} : s;
|
|
2787
|
+
let p = this.resolve(t, i), m = p?.res, h = p?.usedKey || s, g = p?.exactUsedKey || s, ee = [
|
|
2788
|
+
"[object Number]",
|
|
2789
|
+
"[object Function]",
|
|
2790
|
+
"[object RegExp]"
|
|
2791
|
+
], _ = i.joinArrays === void 0 ? this.options.joinArrays : i.joinArrays, v = !this.i18nFormat || this.i18nFormat.handleAsObject, y = i.count !== void 0 && !Z(i.count), b = e.hasDefaultValue(i), te = y ? this.pluralResolver.getSuffix(d, i.count, i) : "", ne = i.ordinal && y ? this.pluralResolver.getSuffix(d, i.count, { ordinal: !1 }) : "", re = y && !i.ordinal && i.count === 0, x = re && i[`defaultValue${this.options.pluralSeparator}zero`] || i[`defaultValue${te}`] || i[`defaultValue${ne}`] || i.defaultValue, S = m;
|
|
2792
|
+
v && !m && b && (S = x);
|
|
2793
|
+
let ie = Ii(S), ae = Object.prototype.toString.apply(S);
|
|
2794
|
+
if (v && S && ie && ee.indexOf(ae) < 0 && !(Z(_) && Array.isArray(S))) {
|
|
2795
|
+
if (!i.returnObjects && !this.options.returnObjects) {
|
|
2796
|
+
this.options.returnedObjectHandler || this.logger.warn("accessing an object - but returnObjects options is not enabled!");
|
|
2797
|
+
let e = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(h, S, {
|
|
2798
|
+
...i,
|
|
2799
|
+
ns: c
|
|
2800
|
+
}) : `key '${s} (${this.language})' returned an object instead of string.`;
|
|
2801
|
+
return a ? (p.res = e, p.usedParams = this.getUsedParamsDetails(i), p) : e;
|
|
2802
|
+
}
|
|
2803
|
+
if (o) {
|
|
2804
|
+
let e = Array.isArray(S), t = e ? [] : {}, n = e ? g : h;
|
|
2805
|
+
for (let e in S) if (Object.prototype.hasOwnProperty.call(S, e)) {
|
|
2806
|
+
let r = `${n}${o}${e}`;
|
|
2807
|
+
b && !m ? t[e] = this.translate(r, {
|
|
2808
|
+
...i,
|
|
2809
|
+
defaultValue: Ii(x) ? x[e] : void 0,
|
|
2810
|
+
joinArrays: !1,
|
|
2811
|
+
ns: c
|
|
2812
|
+
}) : t[e] = this.translate(r, {
|
|
2813
|
+
...i,
|
|
2814
|
+
joinArrays: !1,
|
|
2815
|
+
ns: c
|
|
2816
|
+
}), t[e] === r && (t[e] = S[e]);
|
|
2817
|
+
}
|
|
2818
|
+
m = t;
|
|
2819
|
+
}
|
|
2820
|
+
} else if (v && Z(_) && Array.isArray(m)) m = m.join(_), m &&= this.extendTranslation(m, t, i, r);
|
|
2821
|
+
else {
|
|
2822
|
+
let e = !1, n = !1;
|
|
2823
|
+
!this.isValidLookup(m) && b && (e = !0, m = x), this.isValidLookup(m) || (n = !0, m = s);
|
|
2824
|
+
let a = (i.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && n ? void 0 : m, c = b && x !== m && this.options.updateMissing;
|
|
2825
|
+
if (n || e || c) {
|
|
2826
|
+
if (this.logger.log(c ? "updateKey" : "missingKey", d, l, s, c ? x : m), o) {
|
|
2827
|
+
let e = this.resolve(s, {
|
|
2828
|
+
...i,
|
|
2829
|
+
keySeparator: !1
|
|
2830
|
+
});
|
|
2831
|
+
e && e.res && this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.");
|
|
2832
|
+
}
|
|
2833
|
+
let e = [], t = this.languageUtils.getFallbackCodes(this.options.fallbackLng, i.lng || this.language);
|
|
2834
|
+
if (this.options.saveMissingTo === "fallback" && t && t[0]) for (let n = 0; n < t.length; n++) e.push(t[n]);
|
|
2835
|
+
else this.options.saveMissingTo === "all" ? e = this.languageUtils.toResolveHierarchy(i.lng || this.language) : e.push(i.lng || this.language);
|
|
2836
|
+
let n = (e, t, n) => {
|
|
2837
|
+
let r = b && n !== m ? n : a;
|
|
2838
|
+
this.options.missingKeyHandler ? this.options.missingKeyHandler(e, l, t, r, c, i) : this.backendConnector?.saveMissing && this.backendConnector.saveMissing(e, l, t, r, c, i), this.emit("missingKey", e, l, t, m);
|
|
2839
|
+
};
|
|
2840
|
+
this.options.saveMissing && (this.options.saveMissingPlurals && y ? e.forEach((e) => {
|
|
2841
|
+
let t = this.pluralResolver.getSuffixes(e, i);
|
|
2842
|
+
re && i[`defaultValue${this.options.pluralSeparator}zero`] && t.indexOf(`${this.options.pluralSeparator}zero`) < 0 && t.push(`${this.options.pluralSeparator}zero`), t.forEach((t) => {
|
|
2843
|
+
n([e], s + t, i[`defaultValue${t}`] || x);
|
|
2844
|
+
});
|
|
2845
|
+
}) : n(e, s, x));
|
|
2846
|
+
}
|
|
2847
|
+
m = this.extendTranslation(m, t, i, p, r), n && m === s && this.options.appendNamespaceToMissingKey && (m = `${l}${u}${s}`), (n || e) && this.options.parseMissingKeyHandler && (m = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${l}${u}${s}` : s, e ? m : void 0, i));
|
|
2848
|
+
}
|
|
2849
|
+
return a ? (p.res = m, p.usedParams = this.getUsedParamsDetails(i), p) : m;
|
|
2850
|
+
}
|
|
2851
|
+
extendTranslation(e, t, n, r, i) {
|
|
2852
|
+
if (this.i18nFormat?.parse) e = this.i18nFormat.parse(e, {
|
|
2853
|
+
...this.options.interpolation.defaultVariables,
|
|
2854
|
+
...n
|
|
2855
|
+
}, n.lng || this.language || r.usedLng, r.usedNS, r.usedKey, { resolved: r });
|
|
2856
|
+
else if (!n.skipInterpolation) {
|
|
2857
|
+
n.interpolation && this.interpolator.init({
|
|
2858
|
+
...n,
|
|
2859
|
+
interpolation: {
|
|
2860
|
+
...this.options.interpolation,
|
|
2861
|
+
...n.interpolation
|
|
2862
|
+
}
|
|
2863
|
+
});
|
|
2864
|
+
let a = Z(e) && (n?.interpolation?.skipOnVariables === void 0 ? this.options.interpolation.skipOnVariables : n.interpolation.skipOnVariables), o;
|
|
2865
|
+
if (a) {
|
|
2866
|
+
let t = e.match(this.interpolator.nestingRegexp);
|
|
2867
|
+
o = t && t.length;
|
|
2868
|
+
}
|
|
2869
|
+
let s = n.replace && !Z(n.replace) ? n.replace : n;
|
|
2870
|
+
if (this.options.interpolation.defaultVariables && (s = {
|
|
2871
|
+
...this.options.interpolation.defaultVariables,
|
|
2872
|
+
...s
|
|
2873
|
+
}), e = this.interpolator.interpolate(e, s, n.lng || this.language || r.usedLng, n), a) {
|
|
2874
|
+
let t = e.match(this.interpolator.nestingRegexp), r = t && t.length;
|
|
2875
|
+
o < r && (n.nest = !1);
|
|
2876
|
+
}
|
|
2877
|
+
!n.lng && r && r.res && (n.lng = this.language || r.usedLng), n.nest !== !1 && (e = this.interpolator.nest(e, (...e) => i?.[0] === e[0] && !n.context ? (this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`), null) : this.translate(...e, t), n)), n.interpolation && this.interpolator.reset();
|
|
2878
|
+
}
|
|
2879
|
+
let a = n.postProcess || this.options.postProcess, o = Z(a) ? [a] : a;
|
|
2880
|
+
return e != null && o?.length && n.applyPostProcessor !== !1 && (e = ji.handle(o, e, t, this.options && this.options.postProcessPassResolved ? {
|
|
2881
|
+
i18nResolved: {
|
|
2882
|
+
...r,
|
|
2883
|
+
usedParams: this.getUsedParamsDetails(n)
|
|
2884
|
+
},
|
|
2885
|
+
...n
|
|
2886
|
+
} : n, this)), e;
|
|
2887
|
+
}
|
|
2888
|
+
resolve(e, t = {}) {
|
|
2889
|
+
let n, r, i, a, o;
|
|
2890
|
+
return Z(e) && (e = [e]), Array.isArray(e) && (e = e.map((e) => typeof e == "function" ? Pi(e, {
|
|
2891
|
+
...this.options,
|
|
2892
|
+
...t
|
|
2893
|
+
}) : e)), e.forEach((e) => {
|
|
2894
|
+
if (this.isValidLookup(n)) return;
|
|
2895
|
+
let s = this.extractFromKey(e, t), c = s.key;
|
|
2896
|
+
r = c;
|
|
2897
|
+
let l = s.namespaces;
|
|
2898
|
+
this.options.fallbackNS && (l = l.concat(this.options.fallbackNS));
|
|
2899
|
+
let u = t.count !== void 0 && !Z(t.count), d = u && !t.ordinal && t.count === 0, f = t.context !== void 0 && (Z(t.context) || typeof t.context == "number") && t.context !== "", p = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
|
|
2900
|
+
l.forEach((e) => {
|
|
2901
|
+
this.isValidLookup(n) || (o = e, !Fi[`${p[0]}-${e}`] && this.utils?.hasLoadedNamespace && !this.utils?.hasLoadedNamespace(o) && (Fi[`${p[0]}-${e}`] = !0, this.logger.warn(`key "${r}" for languages "${p.join(", ")}" won't get resolved as namespace "${o}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), p.forEach((r) => {
|
|
2902
|
+
if (this.isValidLookup(n)) return;
|
|
2903
|
+
a = r;
|
|
2904
|
+
let o = [c];
|
|
2905
|
+
if (this.i18nFormat?.addLookupKeys) this.i18nFormat.addLookupKeys(o, c, r, e, t);
|
|
2906
|
+
else {
|
|
2907
|
+
let e;
|
|
2908
|
+
u && (e = this.pluralResolver.getSuffix(r, t.count, t));
|
|
2909
|
+
let n = `${this.options.pluralSeparator}zero`, i = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
|
|
2910
|
+
if (u && (t.ordinal && e.indexOf(i) === 0 && o.push(c + e.replace(i, this.options.pluralSeparator)), o.push(c + e), d && o.push(c + n)), f) {
|
|
2911
|
+
let r = `${c}${this.options.contextSeparator || "_"}${t.context}`;
|
|
2912
|
+
o.push(r), u && (t.ordinal && e.indexOf(i) === 0 && o.push(r + e.replace(i, this.options.pluralSeparator)), o.push(r + e), d && o.push(r + n));
|
|
2913
|
+
}
|
|
2914
|
+
}
|
|
2915
|
+
let s;
|
|
2916
|
+
for (; s = o.pop();) this.isValidLookup(n) || (i = s, n = this.getResource(r, e, s, t));
|
|
2917
|
+
}));
|
|
2918
|
+
});
|
|
2919
|
+
}), {
|
|
2920
|
+
res: n,
|
|
2921
|
+
usedKey: r,
|
|
2922
|
+
exactUsedKey: i,
|
|
2923
|
+
usedLng: a,
|
|
2924
|
+
usedNS: o
|
|
2925
|
+
};
|
|
2926
|
+
}
|
|
2927
|
+
isValidLookup(e) {
|
|
2928
|
+
return e !== void 0 && !(!this.options.returnNull && e === null) && !(!this.options.returnEmptyString && e === "");
|
|
2929
|
+
}
|
|
2930
|
+
getResource(e, t, n, r = {}) {
|
|
2931
|
+
return this.i18nFormat?.getResource ? this.i18nFormat.getResource(e, t, n, r) : this.resourceStore.getResource(e, t, n, r);
|
|
2932
|
+
}
|
|
2933
|
+
getUsedParamsDetails(e = {}) {
|
|
2934
|
+
let t = [
|
|
2935
|
+
"defaultValue",
|
|
2936
|
+
"ordinal",
|
|
2937
|
+
"context",
|
|
2938
|
+
"replace",
|
|
2939
|
+
"lng",
|
|
2940
|
+
"lngs",
|
|
2941
|
+
"fallbackLng",
|
|
2942
|
+
"ns",
|
|
2943
|
+
"keySeparator",
|
|
2944
|
+
"nsSeparator",
|
|
2945
|
+
"returnObjects",
|
|
2946
|
+
"returnDetails",
|
|
2947
|
+
"joinArrays",
|
|
2948
|
+
"postProcess",
|
|
2949
|
+
"interpolation"
|
|
2950
|
+
], n = e.replace && !Z(e.replace), r = n ? e.replace : e;
|
|
2951
|
+
if (n && e.count !== void 0 && (r.count = e.count), this.options.interpolation.defaultVariables && (r = {
|
|
2952
|
+
...this.options.interpolation.defaultVariables,
|
|
2953
|
+
...r
|
|
2954
|
+
}), !n) {
|
|
2955
|
+
r = { ...r };
|
|
2956
|
+
for (let e of t) delete r[e];
|
|
2957
|
+
}
|
|
2958
|
+
return r;
|
|
2959
|
+
}
|
|
2960
|
+
static hasDefaultValue(e) {
|
|
2961
|
+
for (let t in e) if (Object.prototype.hasOwnProperty.call(e, t) && t.substring(0, 12) === "defaultValue" && e[t] !== void 0) return !0;
|
|
2962
|
+
return !1;
|
|
2963
|
+
}
|
|
2964
|
+
}, Ri = class {
|
|
2965
|
+
constructor(e) {
|
|
2966
|
+
this.options = e, this.supportedLngs = this.options.supportedLngs || !1, this.logger = Q.create("languageUtils");
|
|
2967
|
+
}
|
|
2968
|
+
getScriptPartFromCode(e) {
|
|
2969
|
+
if (e = Di(e), !e || e.indexOf("-") < 0) return null;
|
|
2970
|
+
let t = e.split("-");
|
|
2971
|
+
return t.length === 2 || (t.pop(), t[t.length - 1].toLowerCase() === "x") ? null : this.formatLanguageCode(t.join("-"));
|
|
2972
|
+
}
|
|
2973
|
+
getLanguagePartFromCode(e) {
|
|
2974
|
+
if (e = Di(e), !e || e.indexOf("-") < 0) return e;
|
|
2975
|
+
let t = e.split("-");
|
|
2976
|
+
return this.formatLanguageCode(t[0]);
|
|
2977
|
+
}
|
|
2978
|
+
formatLanguageCode(e) {
|
|
2979
|
+
if (Z(e) && e.indexOf("-") > -1) {
|
|
2980
|
+
let t;
|
|
2981
|
+
try {
|
|
2982
|
+
t = Intl.getCanonicalLocales(e)[0];
|
|
2983
|
+
} catch {}
|
|
2984
|
+
return t && this.options.lowerCaseLng && (t = t.toLowerCase()), t || (this.options.lowerCaseLng ? e.toLowerCase() : e);
|
|
2985
|
+
}
|
|
2986
|
+
return this.options.cleanCode || this.options.lowerCaseLng ? e.toLowerCase() : e;
|
|
2987
|
+
}
|
|
2988
|
+
isSupportedCode(e) {
|
|
2989
|
+
return (this.options.load === "languageOnly" || this.options.nonExplicitSupportedLngs) && (e = this.getLanguagePartFromCode(e)), !this.supportedLngs || !this.supportedLngs.length || this.supportedLngs.indexOf(e) > -1;
|
|
2990
|
+
}
|
|
2991
|
+
getBestMatchFromCodes(e) {
|
|
2992
|
+
if (!e) return null;
|
|
2993
|
+
let t;
|
|
2994
|
+
return e.forEach((e) => {
|
|
2995
|
+
if (t) return;
|
|
2996
|
+
let n = this.formatLanguageCode(e);
|
|
2997
|
+
(!this.options.supportedLngs || this.isSupportedCode(n)) && (t = n);
|
|
2998
|
+
}), !t && this.options.supportedLngs && e.forEach((e) => {
|
|
2999
|
+
if (t) return;
|
|
3000
|
+
let n = this.getScriptPartFromCode(e);
|
|
3001
|
+
if (this.isSupportedCode(n)) return t = n;
|
|
3002
|
+
let r = this.getLanguagePartFromCode(e);
|
|
3003
|
+
if (this.isSupportedCode(r)) return t = r;
|
|
3004
|
+
t = this.options.supportedLngs.find((e) => {
|
|
3005
|
+
if (e === r || !(e.indexOf("-") < 0 && r.indexOf("-") < 0) && (e.indexOf("-") > 0 && r.indexOf("-") < 0 && e.substring(0, e.indexOf("-")) === r || e.indexOf(r) === 0 && r.length > 1)) return e;
|
|
3006
|
+
});
|
|
3007
|
+
}), t ||= this.getFallbackCodes(this.options.fallbackLng)[0], t;
|
|
3008
|
+
}
|
|
3009
|
+
getFallbackCodes(e, t) {
|
|
3010
|
+
if (!e) return [];
|
|
3011
|
+
if (typeof e == "function" && (e = e(t)), Z(e) && (e = [e]), Array.isArray(e)) return e;
|
|
3012
|
+
if (!t) return e.default || [];
|
|
3013
|
+
let n = e[t];
|
|
3014
|
+
return n ||= e[this.getScriptPartFromCode(t)], n ||= e[this.formatLanguageCode(t)], n ||= e[this.getLanguagePartFromCode(t)], n ||= e.default, n || [];
|
|
3015
|
+
}
|
|
3016
|
+
toResolveHierarchy(e, t) {
|
|
3017
|
+
let n = this.getFallbackCodes((t === !1 ? [] : t) || this.options.fallbackLng || [], e), r = [], i = (e) => {
|
|
3018
|
+
e && (this.isSupportedCode(e) ? r.push(e) : this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`));
|
|
3019
|
+
};
|
|
3020
|
+
return Z(e) && (e.indexOf("-") > -1 || e.indexOf("_") > -1) ? (this.options.load !== "languageOnly" && i(this.formatLanguageCode(e)), this.options.load !== "languageOnly" && this.options.load !== "currentOnly" && i(this.getScriptPartFromCode(e)), this.options.load !== "currentOnly" && i(this.getLanguagePartFromCode(e))) : Z(e) && i(this.formatLanguageCode(e)), n.forEach((e) => {
|
|
3021
|
+
r.indexOf(e) < 0 && i(this.formatLanguageCode(e));
|
|
3022
|
+
}), r;
|
|
3023
|
+
}
|
|
3024
|
+
}, zi = {
|
|
3025
|
+
zero: 0,
|
|
3026
|
+
one: 1,
|
|
3027
|
+
two: 2,
|
|
3028
|
+
few: 3,
|
|
3029
|
+
many: 4,
|
|
3030
|
+
other: 5
|
|
3031
|
+
}, Bi = {
|
|
3032
|
+
select: (e) => e === 1 ? "one" : "other",
|
|
3033
|
+
resolvedOptions: () => ({ pluralCategories: ["one", "other"] })
|
|
3034
|
+
}, Vi = class {
|
|
3035
|
+
constructor(e, t = {}) {
|
|
3036
|
+
this.languageUtils = e, this.options = t, this.logger = Q.create("pluralResolver"), this.pluralRulesCache = {};
|
|
3037
|
+
}
|
|
3038
|
+
clearCache() {
|
|
3039
|
+
this.pluralRulesCache = {};
|
|
3040
|
+
}
|
|
3041
|
+
getRule(e, t = {}) {
|
|
3042
|
+
let n = Di(e === "dev" ? "en" : e), r = t.ordinal ? "ordinal" : "cardinal", i = JSON.stringify({
|
|
3043
|
+
cleanedCode: n,
|
|
3044
|
+
type: r
|
|
3045
|
+
});
|
|
3046
|
+
if (i in this.pluralRulesCache) return this.pluralRulesCache[i];
|
|
3047
|
+
let a;
|
|
3048
|
+
try {
|
|
3049
|
+
a = new Intl.PluralRules(n, { type: r });
|
|
3050
|
+
} catch {
|
|
3051
|
+
if (typeof Intl > "u") return this.logger.error("No Intl support, please use an Intl polyfill!"), Bi;
|
|
3052
|
+
if (!e.match(/-|_/)) return Bi;
|
|
3053
|
+
let n = this.languageUtils.getLanguagePartFromCode(e);
|
|
3054
|
+
a = this.getRule(n, t);
|
|
3055
|
+
}
|
|
3056
|
+
return this.pluralRulesCache[i] = a, a;
|
|
3057
|
+
}
|
|
3058
|
+
needsPlural(e, t = {}) {
|
|
3059
|
+
let n = this.getRule(e, t);
|
|
3060
|
+
return n ||= this.getRule("dev", t), n?.resolvedOptions().pluralCategories.length > 1;
|
|
3061
|
+
}
|
|
3062
|
+
getPluralFormsOfKey(e, t, n = {}) {
|
|
3063
|
+
return this.getSuffixes(e, n).map((e) => `${t}${e}`);
|
|
3064
|
+
}
|
|
3065
|
+
getSuffixes(e, t = {}) {
|
|
3066
|
+
let n = this.getRule(e, t);
|
|
3067
|
+
return n ||= this.getRule("dev", t), n ? n.resolvedOptions().pluralCategories.sort((e, t) => zi[e] - zi[t]).map((e) => `${this.options.prepend}${t.ordinal ? `ordinal${this.options.prepend}` : ""}${e}`) : [];
|
|
3068
|
+
}
|
|
3069
|
+
getSuffix(e, t, n = {}) {
|
|
3070
|
+
let r = this.getRule(e, n);
|
|
3071
|
+
return r ? `${this.options.prepend}${n.ordinal ? `ordinal${this.options.prepend}` : ""}${r.select(t)}` : (this.logger.warn(`no plural rule found for: ${e}`), this.getSuffix("dev", t, n));
|
|
3072
|
+
}
|
|
3073
|
+
}, Hi = (e, t, n, r = ".", i = !0) => {
|
|
3074
|
+
let a = _i(e, t, n);
|
|
3075
|
+
return !a && i && Z(n) && (a = Ei(e, n, r), a === void 0 && (a = Ei(t, n, r))), a;
|
|
3076
|
+
}, Ui = (e) => e.replace(/\$/g, "$$$$"), Wi = class {
|
|
3077
|
+
constructor(e = {}) {
|
|
3078
|
+
this.logger = Q.create("interpolator"), this.options = e, this.format = e?.interpolation?.format || ((e) => e), this.init(e);
|
|
3079
|
+
}
|
|
3080
|
+
init(e = {}) {
|
|
3081
|
+
e.interpolation ||= { escapeValue: !0 };
|
|
3082
|
+
let { escape: t, escapeValue: n, useRawValueToEscape: r, prefix: i, prefixEscaped: a, suffix: o, suffixEscaped: s, formatSeparator: c, unescapeSuffix: l, unescapePrefix: u, nestingPrefix: d, nestingPrefixEscaped: f, nestingSuffix: p, nestingSuffixEscaped: m, nestingOptionsSeparator: h, maxReplaces: g, alwaysFormat: ee } = e.interpolation;
|
|
3083
|
+
this.escape = t === void 0 ? xi : t, this.escapeValue = n === void 0 || n, this.useRawValueToEscape = r !== void 0 && r, this.prefix = i ? yi(i) : a || "{{", this.suffix = o ? yi(o) : s || "}}", this.formatSeparator = c || ",", this.unescapePrefix = l ? "" : u || "-", this.unescapeSuffix = this.unescapePrefix ? "" : l || "", this.nestingPrefix = d ? yi(d) : f || yi("$t("), this.nestingSuffix = p ? yi(p) : m || yi(")"), this.nestingOptionsSeparator = h || ",", this.maxReplaces = g || 1e3, this.alwaysFormat = ee !== void 0 && ee, this.resetRegExp();
|
|
3084
|
+
}
|
|
3085
|
+
reset() {
|
|
3086
|
+
this.options && this.init(this.options);
|
|
3087
|
+
}
|
|
3088
|
+
resetRegExp() {
|
|
3089
|
+
let e = (e, t) => e?.source === t ? (e.lastIndex = 0, e) : new RegExp(t, "g");
|
|
3090
|
+
this.regexp = e(this.regexp, `${this.prefix}(.+?)${this.suffix}`), this.regexpUnescape = e(this.regexpUnescape, `${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`), this.nestingRegexp = e(this.nestingRegexp, `${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`);
|
|
3091
|
+
}
|
|
3092
|
+
interpolate(e, t, n, r) {
|
|
3093
|
+
let i, a, o, s = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, c = (e) => {
|
|
3094
|
+
if (e.indexOf(this.formatSeparator) < 0) {
|
|
3095
|
+
let i = Hi(t, s, e, this.options.keySeparator, this.options.ignoreJSONStructure);
|
|
3096
|
+
return this.alwaysFormat ? this.format(i, void 0, n, {
|
|
3097
|
+
...r,
|
|
3098
|
+
...t,
|
|
3099
|
+
interpolationkey: e
|
|
3100
|
+
}) : i;
|
|
3101
|
+
}
|
|
3102
|
+
let i = e.split(this.formatSeparator), a = i.shift().trim(), o = i.join(this.formatSeparator).trim();
|
|
3103
|
+
return this.format(Hi(t, s, a, this.options.keySeparator, this.options.ignoreJSONStructure), o, n, {
|
|
3104
|
+
...r,
|
|
3105
|
+
...t,
|
|
3106
|
+
interpolationkey: a
|
|
3107
|
+
});
|
|
3108
|
+
};
|
|
3109
|
+
this.resetRegExp();
|
|
3110
|
+
let l = r?.missingInterpolationHandler || this.options.missingInterpolationHandler, u = r?.interpolation?.skipOnVariables === void 0 ? this.options.interpolation.skipOnVariables : r.interpolation.skipOnVariables;
|
|
3111
|
+
return [{
|
|
3112
|
+
regex: this.regexpUnescape,
|
|
3113
|
+
safeValue: (e) => Ui(e)
|
|
3114
|
+
}, {
|
|
3115
|
+
regex: this.regexp,
|
|
3116
|
+
safeValue: (e) => this.escapeValue ? Ui(this.escape(e)) : Ui(e)
|
|
3117
|
+
}].forEach((t) => {
|
|
3118
|
+
for (o = 0; i = t.regex.exec(e);) {
|
|
3119
|
+
let n = i[1].trim();
|
|
3120
|
+
if (a = c(n), a === void 0) if (typeof l == "function") {
|
|
3121
|
+
let t = l(e, i, r);
|
|
3122
|
+
a = Z(t) ? t : "";
|
|
3123
|
+
} else if (r && Object.prototype.hasOwnProperty.call(r, n)) a = "";
|
|
3124
|
+
else if (u) {
|
|
3125
|
+
a = i[0];
|
|
3126
|
+
continue;
|
|
3127
|
+
} else this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`), a = "";
|
|
3128
|
+
else !Z(a) && !this.useRawValueToEscape && (a = ci(a));
|
|
3129
|
+
let s = t.safeValue(a);
|
|
3130
|
+
if (e = e.replace(i[0], s), u ? (t.regex.lastIndex += a.length, t.regex.lastIndex -= i[0].length) : t.regex.lastIndex = 0, o++, o >= this.maxReplaces) break;
|
|
3131
|
+
}
|
|
3132
|
+
}), e;
|
|
3133
|
+
}
|
|
3134
|
+
nest(e, t, n = {}) {
|
|
3135
|
+
let r, i, a, o = (e, t) => {
|
|
3136
|
+
let n = this.nestingOptionsSeparator;
|
|
3137
|
+
if (e.indexOf(n) < 0) return e;
|
|
3138
|
+
let r = e.split(RegExp(`${yi(n)}[ ]*{`)), i = `{${r[1]}`;
|
|
3139
|
+
e = r[0], i = this.interpolate(i, a);
|
|
3140
|
+
let o = i.match(/'/g), s = i.match(/"/g);
|
|
3141
|
+
((o?.length ?? 0) % 2 == 0 && !s || (s?.length ?? 0) % 2 != 0) && (i = i.replace(/'/g, "\""));
|
|
3142
|
+
try {
|
|
3143
|
+
a = JSON.parse(i), t && (a = {
|
|
3144
|
+
...t,
|
|
3145
|
+
...a
|
|
3146
|
+
});
|
|
3147
|
+
} catch (t) {
|
|
3148
|
+
return this.logger.warn(`failed parsing options string in nesting for key ${e}`, t), `${e}${n}${i}`;
|
|
3149
|
+
}
|
|
3150
|
+
return a.defaultValue && a.defaultValue.indexOf(this.prefix) > -1 && delete a.defaultValue, e;
|
|
3151
|
+
};
|
|
3152
|
+
for (; r = this.nestingRegexp.exec(e);) {
|
|
3153
|
+
let s = [];
|
|
3154
|
+
a = { ...n }, a = a.replace && !Z(a.replace) ? a.replace : a, a.applyPostProcessor = !1, delete a.defaultValue;
|
|
3155
|
+
let c = /{.*}/.test(r[1]) ? r[1].lastIndexOf("}") + 1 : r[1].indexOf(this.formatSeparator);
|
|
3156
|
+
if (c !== -1 && (s = r[1].slice(c).split(this.formatSeparator).map((e) => e.trim()).filter(Boolean), r[1] = r[1].slice(0, c)), i = t(o.call(this, r[1].trim(), a), a), i && r[0] === e && !Z(i)) return i;
|
|
3157
|
+
Z(i) || (i = ci(i)), i ||= (this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`), ""), s.length && (i = s.reduce((e, t) => this.format(e, t, n.lng, {
|
|
3158
|
+
...n,
|
|
3159
|
+
interpolationkey: r[1].trim()
|
|
3160
|
+
}), i.trim())), e = e.replace(r[0], i), this.regexp.lastIndex = 0;
|
|
3161
|
+
}
|
|
3162
|
+
return e;
|
|
3163
|
+
}
|
|
3164
|
+
}, Gi = (e) => {
|
|
3165
|
+
let t = e.toLowerCase().trim(), n = {};
|
|
3166
|
+
if (e.indexOf("(") > -1) {
|
|
3167
|
+
let r = e.split("(");
|
|
3168
|
+
t = r[0].toLowerCase().trim();
|
|
3169
|
+
let i = r[1].substring(0, r[1].length - 1);
|
|
3170
|
+
t === "currency" && i.indexOf(":") < 0 ? n.currency ||= i.trim() : t === "relativetime" && i.indexOf(":") < 0 ? n.range ||= i.trim() : i.split(";").forEach((e) => {
|
|
3171
|
+
if (e) {
|
|
3172
|
+
let [t, ...r] = e.split(":"), i = r.join(":").trim().replace(/^'+|'+$/g, ""), a = t.trim();
|
|
3173
|
+
n[a] || (n[a] = i), i === "false" && (n[a] = !1), i === "true" && (n[a] = !0), isNaN(i) || (n[a] = parseInt(i, 10));
|
|
3174
|
+
}
|
|
3175
|
+
});
|
|
3176
|
+
}
|
|
3177
|
+
return {
|
|
3178
|
+
formatName: t,
|
|
3179
|
+
formatOptions: n
|
|
3180
|
+
};
|
|
3181
|
+
}, Ki = (e) => {
|
|
3182
|
+
let t = {};
|
|
3183
|
+
return (n, r, i) => {
|
|
3184
|
+
let a = i;
|
|
3185
|
+
i && i.interpolationkey && i.formatParams && i.formatParams[i.interpolationkey] && i[i.interpolationkey] && (a = {
|
|
3186
|
+
...a,
|
|
3187
|
+
[i.interpolationkey]: void 0
|
|
3188
|
+
});
|
|
3189
|
+
let o = r + JSON.stringify(a), s = t[o];
|
|
3190
|
+
return s || (s = e(Di(r), i), t[o] = s), s(n);
|
|
3191
|
+
};
|
|
3192
|
+
}, qi = (e) => (t, n, r) => e(Di(n), r)(t), Ji = class {
|
|
3193
|
+
constructor(e = {}) {
|
|
3194
|
+
this.logger = Q.create("formatter"), this.options = e, this.init(e);
|
|
3195
|
+
}
|
|
3196
|
+
init(e, t = { interpolation: {} }) {
|
|
3197
|
+
this.formatSeparator = t.interpolation.formatSeparator || ",";
|
|
3198
|
+
let n = t.cacheInBuiltFormats ? Ki : qi;
|
|
3199
|
+
this.formats = {
|
|
3200
|
+
number: n((e, t) => {
|
|
3201
|
+
let n = new Intl.NumberFormat(e, { ...t });
|
|
3202
|
+
return (e) => n.format(e);
|
|
3203
|
+
}),
|
|
3204
|
+
currency: n((e, t) => {
|
|
3205
|
+
let n = new Intl.NumberFormat(e, {
|
|
3206
|
+
...t,
|
|
3207
|
+
style: "currency"
|
|
3208
|
+
});
|
|
3209
|
+
return (e) => n.format(e);
|
|
3210
|
+
}),
|
|
3211
|
+
datetime: n((e, t) => {
|
|
3212
|
+
let n = new Intl.DateTimeFormat(e, { ...t });
|
|
3213
|
+
return (e) => n.format(e);
|
|
3214
|
+
}),
|
|
3215
|
+
relativetime: n((e, t) => {
|
|
3216
|
+
let n = new Intl.RelativeTimeFormat(e, { ...t });
|
|
3217
|
+
return (e) => n.format(e, t.range || "day");
|
|
3218
|
+
}),
|
|
3219
|
+
list: n((e, t) => {
|
|
3220
|
+
let n = new Intl.ListFormat(e, { ...t });
|
|
3221
|
+
return (e) => n.format(e);
|
|
3222
|
+
})
|
|
3223
|
+
};
|
|
3224
|
+
}
|
|
3225
|
+
add(e, t) {
|
|
3226
|
+
this.formats[e.toLowerCase().trim()] = t;
|
|
3227
|
+
}
|
|
3228
|
+
addCached(e, t) {
|
|
3229
|
+
this.formats[e.toLowerCase().trim()] = Ki(t);
|
|
3230
|
+
}
|
|
3231
|
+
format(e, t, n, r = {}) {
|
|
3232
|
+
let i = t.split(this.formatSeparator);
|
|
3233
|
+
if (i.length > 1 && i[0].indexOf("(") > 1 && i[0].indexOf(")") < 0 && i.find((e) => e.indexOf(")") > -1)) {
|
|
3234
|
+
let e = i.findIndex((e) => e.indexOf(")") > -1);
|
|
3235
|
+
i[0] = [i[0], ...i.splice(1, e)].join(this.formatSeparator);
|
|
3236
|
+
}
|
|
3237
|
+
return i.reduce((e, t) => {
|
|
3238
|
+
let { formatName: i, formatOptions: a } = Gi(t);
|
|
3239
|
+
if (this.formats[i]) {
|
|
3240
|
+
let t = e;
|
|
3241
|
+
try {
|
|
3242
|
+
let o = r?.formatParams?.[r.interpolationkey] || {}, s = o.locale || o.lng || r.locale || r.lng || n;
|
|
3243
|
+
t = this.formats[i](e, s, {
|
|
3244
|
+
...a,
|
|
3245
|
+
...r,
|
|
3246
|
+
...o
|
|
3247
|
+
});
|
|
3248
|
+
} catch (e) {
|
|
3249
|
+
this.logger.warn(e);
|
|
3250
|
+
}
|
|
3251
|
+
return t;
|
|
3252
|
+
} else this.logger.warn(`there was no format function for ${i}`);
|
|
3253
|
+
return e;
|
|
3254
|
+
}, e);
|
|
3255
|
+
}
|
|
3256
|
+
}, Yi = (e, t) => {
|
|
3257
|
+
e.pending[t] !== void 0 && (delete e.pending[t], e.pendingCount--);
|
|
3258
|
+
}, Xi = class extends ki {
|
|
3259
|
+
constructor(e, t, n, r = {}) {
|
|
3260
|
+
super(), this.backend = e, this.store = t, this.services = n, this.languageUtils = n.languageUtils, this.options = r, this.logger = Q.create("backendConnector"), this.waitingReads = [], this.maxParallelReads = r.maxParallelReads || 10, this.readingCalls = 0, this.maxRetries = r.maxRetries >= 0 ? r.maxRetries : 5, this.retryTimeout = r.retryTimeout >= 1 ? r.retryTimeout : 350, this.state = {}, this.queue = [], this.backend?.init?.(n, r.backend, r);
|
|
3261
|
+
}
|
|
3262
|
+
queueLoad(e, t, n, r) {
|
|
3263
|
+
let i = {}, a = {}, o = {}, s = {};
|
|
3264
|
+
return e.forEach((e) => {
|
|
3265
|
+
let r = !0;
|
|
3266
|
+
t.forEach((t) => {
|
|
3267
|
+
let o = `${e}|${t}`;
|
|
3268
|
+
!n.reload && this.store.hasResourceBundle(e, t) ? this.state[o] = 2 : this.state[o] < 0 || (this.state[o] === 1 ? a[o] === void 0 && (a[o] = !0) : (this.state[o] = 1, r = !1, a[o] === void 0 && (a[o] = !0), i[o] === void 0 && (i[o] = !0), s[t] === void 0 && (s[t] = !0)));
|
|
3269
|
+
}), r || (o[e] = !0);
|
|
3270
|
+
}), (Object.keys(i).length || Object.keys(a).length) && this.queue.push({
|
|
3271
|
+
pending: a,
|
|
3272
|
+
pendingCount: Object.keys(a).length,
|
|
3273
|
+
loaded: {},
|
|
3274
|
+
errors: [],
|
|
3275
|
+
callback: r
|
|
3276
|
+
}), {
|
|
3277
|
+
toLoad: Object.keys(i),
|
|
3278
|
+
pending: Object.keys(a),
|
|
3279
|
+
toLoadLanguages: Object.keys(o),
|
|
3280
|
+
toLoadNamespaces: Object.keys(s)
|
|
3281
|
+
};
|
|
3282
|
+
}
|
|
3283
|
+
loaded(e, t, n) {
|
|
3284
|
+
let r = e.split("|"), i = r[0], a = r[1];
|
|
3285
|
+
t && this.emit("failedLoading", i, a, t), !t && n && this.store.addResourceBundle(i, a, n, void 0, void 0, { skipCopy: !0 }), this.state[e] = t ? -1 : 2, t && n && (this.state[e] = 0);
|
|
3286
|
+
let o = {};
|
|
3287
|
+
this.queue.forEach((n) => {
|
|
3288
|
+
hi(n.loaded, [i], a), Yi(n, e), t && n.errors.push(t), n.pendingCount === 0 && !n.done && (Object.keys(n.loaded).forEach((e) => {
|
|
3289
|
+
o[e] || (o[e] = {});
|
|
3290
|
+
let t = n.loaded[e];
|
|
3291
|
+
t.length && t.forEach((t) => {
|
|
3292
|
+
o[e][t] === void 0 && (o[e][t] = !0);
|
|
3293
|
+
});
|
|
3294
|
+
}), n.done = !0, n.errors.length ? n.callback(n.errors) : n.callback());
|
|
3295
|
+
}), this.emit("loaded", o), this.queue = this.queue.filter((e) => !e.done);
|
|
3296
|
+
}
|
|
3297
|
+
read(e, t, n, r = 0, i = this.retryTimeout, a) {
|
|
3298
|
+
if (!e.length) return a(null, {});
|
|
3299
|
+
if (this.readingCalls >= this.maxParallelReads) {
|
|
3300
|
+
this.waitingReads.push({
|
|
3301
|
+
lng: e,
|
|
3302
|
+
ns: t,
|
|
3303
|
+
fcName: n,
|
|
3304
|
+
tried: r,
|
|
3305
|
+
wait: i,
|
|
3306
|
+
callback: a
|
|
3307
|
+
});
|
|
3308
|
+
return;
|
|
3309
|
+
}
|
|
3310
|
+
this.readingCalls++;
|
|
3311
|
+
let o = (o, s) => {
|
|
3312
|
+
if (this.readingCalls--, this.waitingReads.length > 0) {
|
|
3313
|
+
let e = this.waitingReads.shift();
|
|
3314
|
+
this.read(e.lng, e.ns, e.fcName, e.tried, e.wait, e.callback);
|
|
3315
|
+
}
|
|
3316
|
+
if (o && s && r < this.maxRetries) {
|
|
3317
|
+
setTimeout(() => {
|
|
3318
|
+
this.read.call(this, e, t, n, r + 1, i * 2, a);
|
|
3319
|
+
}, i);
|
|
3320
|
+
return;
|
|
3321
|
+
}
|
|
3322
|
+
a(o, s);
|
|
3323
|
+
}, s = this.backend[n].bind(this.backend);
|
|
3324
|
+
if (s.length === 2) {
|
|
3325
|
+
try {
|
|
3326
|
+
let n = s(e, t);
|
|
3327
|
+
n && typeof n.then == "function" ? n.then((e) => o(null, e)).catch(o) : o(null, n);
|
|
3328
|
+
} catch (e) {
|
|
3329
|
+
o(e);
|
|
3330
|
+
}
|
|
3331
|
+
return;
|
|
3332
|
+
}
|
|
3333
|
+
return s(e, t, o);
|
|
3334
|
+
}
|
|
3335
|
+
prepareLoading(e, t, n = {}, r) {
|
|
3336
|
+
if (!this.backend) return this.logger.warn("No backend was added via i18next.use. Will not load resources."), r && r();
|
|
3337
|
+
Z(e) && (e = this.languageUtils.toResolveHierarchy(e)), Z(t) && (t = [t]);
|
|
3338
|
+
let i = this.queueLoad(e, t, n, r);
|
|
3339
|
+
if (!i.toLoad.length) return i.pending.length || r(), null;
|
|
3340
|
+
i.toLoad.forEach((e) => {
|
|
3341
|
+
this.loadOne(e);
|
|
3342
|
+
});
|
|
3343
|
+
}
|
|
3344
|
+
load(e, t, n) {
|
|
3345
|
+
this.prepareLoading(e, t, {}, n);
|
|
3346
|
+
}
|
|
3347
|
+
reload(e, t, n) {
|
|
3348
|
+
this.prepareLoading(e, t, { reload: !0 }, n);
|
|
3349
|
+
}
|
|
3350
|
+
loadOne(e, t = "") {
|
|
3351
|
+
let n = e.split("|"), r = n[0], i = n[1];
|
|
3352
|
+
this.read(r, i, "read", void 0, void 0, (n, a) => {
|
|
3353
|
+
n && this.logger.warn(`${t}loading namespace ${i} for language ${r} failed`, n), !n && a && this.logger.log(`${t}loaded namespace ${i} for language ${r}`, a), this.loaded(e, n, a);
|
|
3354
|
+
});
|
|
3355
|
+
}
|
|
3356
|
+
saveMissing(e, t, n, r, i, a = {}, o = () => {}) {
|
|
3357
|
+
if (this.services?.utils?.hasLoadedNamespace && !this.services?.utils?.hasLoadedNamespace(t)) {
|
|
3358
|
+
this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");
|
|
3359
|
+
return;
|
|
3360
|
+
}
|
|
3361
|
+
if (!(n == null || n === "")) {
|
|
3362
|
+
if (this.backend?.create) {
|
|
3363
|
+
let s = {
|
|
3364
|
+
...a,
|
|
3365
|
+
isUpdate: i
|
|
3366
|
+
}, c = this.backend.create.bind(this.backend);
|
|
3367
|
+
if (c.length < 6) try {
|
|
3368
|
+
let i;
|
|
3369
|
+
i = c.length === 5 ? c(e, t, n, r, s) : c(e, t, n, r), i && typeof i.then == "function" ? i.then((e) => o(null, e)).catch(o) : o(null, i);
|
|
3370
|
+
} catch (e) {
|
|
3371
|
+
o(e);
|
|
3372
|
+
}
|
|
3373
|
+
else c(e, t, n, r, o, s);
|
|
3374
|
+
}
|
|
3375
|
+
!e || !e[0] || this.store.addResource(e[0], t, n, r);
|
|
3376
|
+
}
|
|
3377
|
+
}
|
|
3378
|
+
}, Zi = () => ({
|
|
3379
|
+
debug: !1,
|
|
3380
|
+
initAsync: !0,
|
|
3381
|
+
ns: ["translation"],
|
|
3382
|
+
defaultNS: ["translation"],
|
|
3383
|
+
fallbackLng: ["dev"],
|
|
3384
|
+
fallbackNS: !1,
|
|
3385
|
+
supportedLngs: !1,
|
|
3386
|
+
nonExplicitSupportedLngs: !1,
|
|
3387
|
+
load: "all",
|
|
3388
|
+
preload: !1,
|
|
3389
|
+
simplifyPluralSuffix: !0,
|
|
3390
|
+
keySeparator: ".",
|
|
3391
|
+
nsSeparator: ":",
|
|
3392
|
+
pluralSeparator: "_",
|
|
3393
|
+
contextSeparator: "_",
|
|
3394
|
+
partialBundledLanguages: !1,
|
|
3395
|
+
saveMissing: !1,
|
|
3396
|
+
updateMissing: !1,
|
|
3397
|
+
saveMissingTo: "fallback",
|
|
3398
|
+
saveMissingPlurals: !0,
|
|
3399
|
+
missingKeyHandler: !1,
|
|
3400
|
+
missingInterpolationHandler: !1,
|
|
3401
|
+
postProcess: !1,
|
|
3402
|
+
postProcessPassResolved: !1,
|
|
3403
|
+
returnNull: !1,
|
|
3404
|
+
returnEmptyString: !0,
|
|
3405
|
+
returnObjects: !1,
|
|
3406
|
+
joinArrays: !1,
|
|
3407
|
+
returnedObjectHandler: !1,
|
|
3408
|
+
parseMissingKeyHandler: !1,
|
|
3409
|
+
appendNamespaceToMissingKey: !1,
|
|
3410
|
+
appendNamespaceToCIMode: !1,
|
|
3411
|
+
overloadTranslationOptionHandler: (e) => {
|
|
3412
|
+
let t = {};
|
|
3413
|
+
if (typeof e[1] == "object" && (t = e[1]), Z(e[1]) && (t.defaultValue = e[1]), Z(e[2]) && (t.tDescription = e[2]), typeof e[2] == "object" || typeof e[3] == "object") {
|
|
3414
|
+
let n = e[3] || e[2];
|
|
3415
|
+
Object.keys(n).forEach((e) => {
|
|
3416
|
+
t[e] = n[e];
|
|
3417
|
+
});
|
|
3418
|
+
}
|
|
3419
|
+
return t;
|
|
3420
|
+
},
|
|
3421
|
+
interpolation: {
|
|
3422
|
+
escapeValue: !0,
|
|
3423
|
+
format: (e) => e,
|
|
3424
|
+
prefix: "{{",
|
|
3425
|
+
suffix: "}}",
|
|
3426
|
+
formatSeparator: ",",
|
|
3427
|
+
unescapePrefix: "-",
|
|
3428
|
+
nestingPrefix: "$t(",
|
|
3429
|
+
nestingSuffix: ")",
|
|
3430
|
+
nestingOptionsSeparator: ",",
|
|
3431
|
+
maxReplaces: 1e3,
|
|
3432
|
+
skipOnVariables: !0
|
|
3433
|
+
},
|
|
3434
|
+
cacheInBuiltFormats: !0
|
|
3435
|
+
}), Qi = (e) => (Z(e.ns) && (e.ns = [e.ns]), Z(e.fallbackLng) && (e.fallbackLng = [e.fallbackLng]), Z(e.fallbackNS) && (e.fallbackNS = [e.fallbackNS]), e.supportedLngs?.indexOf?.("cimode") < 0 && (e.supportedLngs = e.supportedLngs.concat(["cimode"])), typeof e.initImmediate == "boolean" && (e.initAsync = e.initImmediate), e), $i = () => {}, ea = (e) => {
|
|
3436
|
+
Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach((t) => {
|
|
3437
|
+
typeof e[t] == "function" && (e[t] = e[t].bind(e));
|
|
3438
|
+
});
|
|
3439
|
+
}, ta = "__i18next_supportNoticeShown", na = () => !!(typeof globalThis < "u" && globalThis[ta] || typeof process < "u" && process.env && process.env.I18NEXT_NO_SUPPORT_NOTICE || typeof process < "u" && process.env), ra = () => {
|
|
3440
|
+
typeof globalThis < "u" && (globalThis[ta] = !0);
|
|
3441
|
+
}, ia = (e) => !!(e?.modules?.backend?.name?.indexOf("Locize") > 0 || e?.modules?.backend?.constructor?.name?.indexOf("Locize") > 0 || e?.options?.backend?.backends && e.options.backend.backends.some((e) => e?.name?.indexOf("Locize") > 0 || e?.constructor?.name?.indexOf("Locize") > 0) || e?.options?.backend?.projectId || e?.options?.backend?.backendOptions && e.options.backend.backendOptions.some((e) => e?.projectId)), $ = class e extends ki {
|
|
3442
|
+
constructor(e = {}, t) {
|
|
3443
|
+
if (super(), this.options = Qi(e), this.services = {}, this.logger = Q, this.modules = { external: [] }, ea(this), t && !this.isInitialized && !e.isClone) {
|
|
3444
|
+
if (!this.options.initAsync) return this.init(e, t), this;
|
|
3445
|
+
setTimeout(() => {
|
|
3446
|
+
this.init(e, t);
|
|
3447
|
+
}, 0);
|
|
3448
|
+
}
|
|
3449
|
+
}
|
|
3450
|
+
init(e = {}, t) {
|
|
3451
|
+
this.isInitializing = !0, typeof e == "function" && (t = e, e = {}), e.defaultNS == null && e.ns && (Z(e.ns) ? e.defaultNS = e.ns : e.ns.indexOf("translation") < 0 && (e.defaultNS = e.ns[0]));
|
|
3452
|
+
let n = Zi();
|
|
3453
|
+
this.options = {
|
|
3454
|
+
...n,
|
|
3455
|
+
...this.options,
|
|
3456
|
+
...Qi(e)
|
|
3457
|
+
}, this.options.interpolation = {
|
|
3458
|
+
...n.interpolation,
|
|
3459
|
+
...this.options.interpolation
|
|
3460
|
+
}, e.keySeparator !== void 0 && (this.options.userDefinedKeySeparator = e.keySeparator), e.nsSeparator !== void 0 && (this.options.userDefinedNsSeparator = e.nsSeparator), typeof this.options.overloadTranslationOptionHandler != "function" && (this.options.overloadTranslationOptionHandler = n.overloadTranslationOptionHandler), this.options.showSupportNotice !== !1 && !ia(this) && !na() && (typeof console < "u" && console.info !== void 0 && console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"), ra());
|
|
3461
|
+
let r = (e) => e ? typeof e == "function" ? new e() : e : null;
|
|
3462
|
+
if (!this.options.isClone) {
|
|
3463
|
+
this.modules.logger ? Q.init(r(this.modules.logger), this.options) : Q.init(null, this.options);
|
|
3464
|
+
let e;
|
|
3465
|
+
e = this.modules.formatter ? this.modules.formatter : Ji;
|
|
3466
|
+
let t = new Ri(this.options);
|
|
3467
|
+
this.store = new Ai(this.options.resources, this.options);
|
|
3468
|
+
let i = this.services;
|
|
3469
|
+
i.logger = Q, i.resourceStore = this.store, i.languageUtils = t, i.pluralResolver = new Vi(t, {
|
|
3470
|
+
prepend: this.options.pluralSeparator,
|
|
3471
|
+
simplifyPluralSuffix: this.options.simplifyPluralSuffix
|
|
3472
|
+
}), this.options.interpolation.format && this.options.interpolation.format !== n.interpolation.format && this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"), e && (!this.options.interpolation.format || this.options.interpolation.format === n.interpolation.format) && (i.formatter = r(e), i.formatter.init && i.formatter.init(i, this.options), this.options.interpolation.format = i.formatter.format.bind(i.formatter)), i.interpolator = new Wi(this.options), i.utils = { hasLoadedNamespace: this.hasLoadedNamespace.bind(this) }, i.backendConnector = new Xi(r(this.modules.backend), i.resourceStore, i, this.options), i.backendConnector.on("*", (e, ...t) => {
|
|
3473
|
+
this.emit(e, ...t);
|
|
3474
|
+
}), this.modules.languageDetector && (i.languageDetector = r(this.modules.languageDetector), i.languageDetector.init && i.languageDetector.init(i, this.options.detection, this.options)), this.modules.i18nFormat && (i.i18nFormat = r(this.modules.i18nFormat), i.i18nFormat.init && i.i18nFormat.init(this)), this.translator = new Li(this.services, this.options), this.translator.on("*", (e, ...t) => {
|
|
3475
|
+
this.emit(e, ...t);
|
|
3476
|
+
}), this.modules.external.forEach((e) => {
|
|
3477
|
+
e.init && e.init(this);
|
|
3478
|
+
});
|
|
3479
|
+
}
|
|
3480
|
+
if (this.format = this.options.interpolation.format, t ||= $i, this.options.fallbackLng && !this.services.languageDetector && !this.options.lng) {
|
|
3481
|
+
let e = this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);
|
|
3482
|
+
e.length > 0 && e[0] !== "dev" && (this.options.lng = e[0]);
|
|
3483
|
+
}
|
|
3484
|
+
!this.services.languageDetector && !this.options.lng && this.logger.warn("init: no languageDetector is used and no lng is defined"), [
|
|
3485
|
+
"getResource",
|
|
3486
|
+
"hasResourceBundle",
|
|
3487
|
+
"getResourceBundle",
|
|
3488
|
+
"getDataByLanguage"
|
|
3489
|
+
].forEach((e) => {
|
|
3490
|
+
this[e] = (...t) => this.store[e](...t);
|
|
3491
|
+
}), [
|
|
3492
|
+
"addResource",
|
|
3493
|
+
"addResources",
|
|
3494
|
+
"addResourceBundle",
|
|
3495
|
+
"removeResourceBundle"
|
|
3496
|
+
].forEach((e) => {
|
|
3497
|
+
this[e] = (...t) => (this.store[e](...t), this);
|
|
3498
|
+
});
|
|
3499
|
+
let i = si(), a = () => {
|
|
3500
|
+
let e = (e, n) => {
|
|
3501
|
+
this.isInitializing = !1, this.isInitialized && !this.initializedStoreOnce && this.logger.warn("init: i18next is already initialized. You should call init just once!"), this.isInitialized = !0, this.options.isClone || this.logger.log("initialized", this.options), this.emit("initialized", this.options), i.resolve(n), t(e, n);
|
|
3502
|
+
};
|
|
3503
|
+
if (this.languages && !this.isInitialized) return e(null, this.t.bind(this));
|
|
3504
|
+
this.changeLanguage(this.options.lng, e);
|
|
3505
|
+
};
|
|
3506
|
+
return this.options.resources || !this.options.initAsync ? a() : setTimeout(a, 0), i;
|
|
3507
|
+
}
|
|
3508
|
+
loadResources(e, t = $i) {
|
|
3509
|
+
let n = t, r = Z(e) ? e : this.language;
|
|
3510
|
+
if (typeof e == "function" && (n = e), !this.options.resources || this.options.partialBundledLanguages) {
|
|
3511
|
+
if (r?.toLowerCase() === "cimode" && (!this.options.preload || this.options.preload.length === 0)) return n();
|
|
3512
|
+
let e = [], t = (t) => {
|
|
3513
|
+
t && t !== "cimode" && this.services.languageUtils.toResolveHierarchy(t).forEach((t) => {
|
|
3514
|
+
t !== "cimode" && e.indexOf(t) < 0 && e.push(t);
|
|
3515
|
+
});
|
|
3516
|
+
};
|
|
3517
|
+
r ? t(r) : this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach((e) => t(e)), this.options.preload?.forEach?.((e) => t(e)), this.services.backendConnector.load(e, this.options.ns, (e) => {
|
|
3518
|
+
!e && !this.resolvedLanguage && this.language && this.setResolvedLanguage(this.language), n(e);
|
|
3519
|
+
});
|
|
3520
|
+
} else n(null);
|
|
3521
|
+
}
|
|
3522
|
+
reloadResources(e, t, n) {
|
|
3523
|
+
let r = si();
|
|
3524
|
+
return typeof e == "function" && (n = e, e = void 0), typeof t == "function" && (n = t, t = void 0), e ||= this.languages, t ||= this.options.ns, n ||= $i, this.services.backendConnector.reload(e, t, (e) => {
|
|
3525
|
+
r.resolve(), n(e);
|
|
3526
|
+
}), r;
|
|
3527
|
+
}
|
|
3528
|
+
use(e) {
|
|
3529
|
+
if (!e) throw Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");
|
|
3530
|
+
if (!e.type) throw Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");
|
|
3531
|
+
return e.type === "backend" && (this.modules.backend = e), (e.type === "logger" || e.log && e.warn && e.error) && (this.modules.logger = e), e.type === "languageDetector" && (this.modules.languageDetector = e), e.type === "i18nFormat" && (this.modules.i18nFormat = e), e.type === "postProcessor" && ji.addPostProcessor(e), e.type === "formatter" && (this.modules.formatter = e), e.type === "3rdParty" && this.modules.external.push(e), this;
|
|
3532
|
+
}
|
|
3533
|
+
setResolvedLanguage(e) {
|
|
3534
|
+
if (!(!e || !this.languages) && !(["cimode", "dev"].indexOf(e) > -1)) {
|
|
3535
|
+
for (let e = 0; e < this.languages.length; e++) {
|
|
3536
|
+
let t = this.languages[e];
|
|
3537
|
+
if (!(["cimode", "dev"].indexOf(t) > -1) && this.store.hasLanguageSomeTranslations(t)) {
|
|
3538
|
+
this.resolvedLanguage = t;
|
|
3539
|
+
break;
|
|
3540
|
+
}
|
|
3541
|
+
}
|
|
3542
|
+
!this.resolvedLanguage && this.languages.indexOf(e) < 0 && this.store.hasLanguageSomeTranslations(e) && (this.resolvedLanguage = e, this.languages.unshift(e));
|
|
3543
|
+
}
|
|
3544
|
+
}
|
|
3545
|
+
changeLanguage(e, t) {
|
|
3546
|
+
this.isLanguageChangingTo = e;
|
|
3547
|
+
let n = si();
|
|
3548
|
+
this.emit("languageChanging", e);
|
|
3549
|
+
let r = (e) => {
|
|
3550
|
+
this.language = e, this.languages = this.services.languageUtils.toResolveHierarchy(e), this.resolvedLanguage = void 0, this.setResolvedLanguage(e);
|
|
3551
|
+
}, i = (i, a) => {
|
|
3552
|
+
a ? this.isLanguageChangingTo === e && (r(a), this.translator.changeLanguage(a), this.isLanguageChangingTo = void 0, this.emit("languageChanged", a), this.logger.log("languageChanged", a)) : this.isLanguageChangingTo = void 0, n.resolve((...e) => this.t(...e)), t && t(i, (...e) => this.t(...e));
|
|
3553
|
+
}, a = (t) => {
|
|
3554
|
+
!e && !t && this.services.languageDetector && (t = []);
|
|
3555
|
+
let n = Z(t) ? t : t && t[0], a = this.store.hasLanguageSomeTranslations(n) ? n : this.services.languageUtils.getBestMatchFromCodes(Z(t) ? [t] : t);
|
|
3556
|
+
a && (this.language || r(a), this.translator.language || this.translator.changeLanguage(a), this.services.languageDetector?.cacheUserLanguage?.(a)), this.loadResources(a, (e) => {
|
|
3557
|
+
i(e, a);
|
|
3558
|
+
});
|
|
3559
|
+
};
|
|
3560
|
+
return !e && this.services.languageDetector && !this.services.languageDetector.async ? a(this.services.languageDetector.detect()) : !e && this.services.languageDetector && this.services.languageDetector.async ? this.services.languageDetector.detect.length === 0 ? this.services.languageDetector.detect().then(a) : this.services.languageDetector.detect(a) : a(e), n;
|
|
3561
|
+
}
|
|
3562
|
+
getFixedT(e, t, n) {
|
|
3563
|
+
let r = (e, t, ...i) => {
|
|
3564
|
+
let a;
|
|
3565
|
+
a = typeof t == "object" ? { ...t } : this.options.overloadTranslationOptionHandler([e, t].concat(i)), a.lng = a.lng || r.lng, a.lngs = a.lngs || r.lngs, a.ns = a.ns || r.ns, a.keyPrefix !== "" && (a.keyPrefix = a.keyPrefix || n || r.keyPrefix);
|
|
3566
|
+
let o = {
|
|
3567
|
+
...this.options,
|
|
3568
|
+
...a
|
|
3569
|
+
};
|
|
3570
|
+
typeof a.keyPrefix == "function" && (a.keyPrefix = Pi(a.keyPrefix, o));
|
|
3571
|
+
let s = this.options.keySeparator || ".", c;
|
|
3572
|
+
return a.keyPrefix && Array.isArray(e) ? c = e.map((e) => (typeof e == "function" && (e = Pi(e, o)), `${a.keyPrefix}${s}${e}`)) : (typeof e == "function" && (e = Pi(e, o)), c = a.keyPrefix ? `${a.keyPrefix}${s}${e}` : e), this.t(c, a);
|
|
3573
|
+
};
|
|
3574
|
+
return Z(e) ? r.lng = e : r.lngs = e, r.ns = t, r.keyPrefix = n, r;
|
|
3575
|
+
}
|
|
3576
|
+
t(...e) {
|
|
3577
|
+
return this.translator?.translate(...e);
|
|
3578
|
+
}
|
|
3579
|
+
exists(...e) {
|
|
3580
|
+
return this.translator?.exists(...e);
|
|
3581
|
+
}
|
|
3582
|
+
setDefaultNamespace(e) {
|
|
3583
|
+
this.options.defaultNS = e;
|
|
3584
|
+
}
|
|
3585
|
+
hasLoadedNamespace(e, t = {}) {
|
|
3586
|
+
if (!this.isInitialized) return this.logger.warn("hasLoadedNamespace: i18next was not initialized", this.languages), !1;
|
|
3587
|
+
if (!this.languages || !this.languages.length) return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty", this.languages), !1;
|
|
3588
|
+
let n = t.lng || this.resolvedLanguage || this.languages[0], r = this.options ? this.options.fallbackLng : !1, i = this.languages[this.languages.length - 1];
|
|
3589
|
+
if (n.toLowerCase() === "cimode") return !0;
|
|
3590
|
+
let a = (e, t) => {
|
|
3591
|
+
let n = this.services.backendConnector.state[`${e}|${t}`];
|
|
3592
|
+
return n === -1 || n === 0 || n === 2;
|
|
3593
|
+
};
|
|
3594
|
+
if (t.precheck) {
|
|
3595
|
+
let e = t.precheck(this, a);
|
|
3596
|
+
if (e !== void 0) return e;
|
|
3597
|
+
}
|
|
3598
|
+
return !!(this.hasResourceBundle(n, e) || !this.services.backendConnector.backend || this.options.resources && !this.options.partialBundledLanguages || a(n, e) && (!r || a(i, e)));
|
|
3599
|
+
}
|
|
3600
|
+
loadNamespaces(e, t) {
|
|
3601
|
+
let n = si();
|
|
3602
|
+
return this.options.ns ? (Z(e) && (e = [e]), e.forEach((e) => {
|
|
3603
|
+
this.options.ns.indexOf(e) < 0 && this.options.ns.push(e);
|
|
3604
|
+
}), this.loadResources((e) => {
|
|
3605
|
+
n.resolve(), t && t(e);
|
|
3606
|
+
}), n) : (t && t(), Promise.resolve());
|
|
3607
|
+
}
|
|
3608
|
+
loadLanguages(e, t) {
|
|
3609
|
+
let n = si();
|
|
3610
|
+
Z(e) && (e = [e]);
|
|
3611
|
+
let r = this.options.preload || [], i = e.filter((e) => r.indexOf(e) < 0 && this.services.languageUtils.isSupportedCode(e));
|
|
3612
|
+
return i.length ? (this.options.preload = r.concat(i), this.loadResources((e) => {
|
|
3613
|
+
n.resolve(), t && t(e);
|
|
3614
|
+
}), n) : (t && t(), Promise.resolve());
|
|
3615
|
+
}
|
|
3616
|
+
dir(e) {
|
|
3617
|
+
if (e ||= this.resolvedLanguage || (this.languages?.length > 0 ? this.languages[0] : this.language), !e) return "rtl";
|
|
3618
|
+
try {
|
|
3619
|
+
let t = new Intl.Locale(e);
|
|
3620
|
+
if (t && t.getTextInfo) {
|
|
3621
|
+
let e = t.getTextInfo();
|
|
3622
|
+
if (e && e.direction) return e.direction;
|
|
3623
|
+
}
|
|
3624
|
+
} catch {}
|
|
3625
|
+
let t = /* @__PURE__ */ "ar.shu.sqr.ssh.xaa.yhd.yud.aao.abh.abv.acm.acq.acw.acx.acy.adf.ads.aeb.aec.afb.ajp.apc.apd.arb.arq.ars.ary.arz.auz.avl.ayh.ayl.ayn.ayp.bbz.pga.he.iw.ps.pbt.pbu.pst.prp.prd.ug.ur.ydd.yds.yih.ji.yi.hbo.men.xmn.fa.jpr.peo.pes.prs.dv.sam.ckb".split("."), n = this.services?.languageUtils || new Ri(Zi());
|
|
3626
|
+
return e.toLowerCase().indexOf("-latn") > 1 ? "ltr" : t.indexOf(n.getLanguagePartFromCode(e)) > -1 || e.toLowerCase().indexOf("-arab") > 1 ? "rtl" : "ltr";
|
|
3627
|
+
}
|
|
3628
|
+
static createInstance(t = {}, n) {
|
|
3629
|
+
let r = new e(t, n);
|
|
3630
|
+
return r.createInstance = e.createInstance, r;
|
|
3631
|
+
}
|
|
3632
|
+
cloneInstance(t = {}, n = $i) {
|
|
3633
|
+
let r = t.forkResourceStore;
|
|
3634
|
+
r && delete t.forkResourceStore;
|
|
3635
|
+
let i = {
|
|
3636
|
+
...this.options,
|
|
3637
|
+
...t,
|
|
3638
|
+
isClone: !0
|
|
3639
|
+
}, a = new e(i);
|
|
3640
|
+
if ((t.debug !== void 0 || t.prefix !== void 0) && (a.logger = a.logger.clone(t)), [
|
|
3641
|
+
"store",
|
|
3642
|
+
"services",
|
|
3643
|
+
"language"
|
|
3644
|
+
].forEach((e) => {
|
|
3645
|
+
a[e] = this[e];
|
|
3646
|
+
}), a.services = { ...this.services }, a.services.utils = { hasLoadedNamespace: a.hasLoadedNamespace.bind(a) }, r && (a.store = new Ai(Object.keys(this.store.data).reduce((e, t) => (e[t] = { ...this.store.data[t] }, e[t] = Object.keys(e[t]).reduce((n, r) => (n[r] = { ...e[t][r] }, n), e[t]), e), {}), i), a.services.resourceStore = a.store), t.interpolation) {
|
|
3647
|
+
let e = {
|
|
3648
|
+
...Zi().interpolation,
|
|
3649
|
+
...this.options.interpolation,
|
|
3650
|
+
...t.interpolation
|
|
3651
|
+
}, n = {
|
|
3652
|
+
...i,
|
|
3653
|
+
interpolation: e
|
|
3654
|
+
};
|
|
3655
|
+
a.services.interpolator = new Wi(n);
|
|
3656
|
+
}
|
|
3657
|
+
return a.translator = new Li(a.services, i), a.translator.on("*", (e, ...t) => {
|
|
3658
|
+
a.emit(e, ...t);
|
|
3659
|
+
}), a.init(i, n), a.translator.options = i, a.translator.backendConnector.services.utils = { hasLoadedNamespace: a.hasLoadedNamespace.bind(a) }, a;
|
|
3660
|
+
}
|
|
3661
|
+
toJSON() {
|
|
3662
|
+
return {
|
|
3663
|
+
options: this.options,
|
|
3664
|
+
store: this.store,
|
|
3665
|
+
language: this.language,
|
|
3666
|
+
languages: this.languages,
|
|
3667
|
+
resolvedLanguage: this.resolvedLanguage
|
|
3668
|
+
};
|
|
3669
|
+
}
|
|
3670
|
+
}.createInstance();
|
|
3671
|
+
//#endregion
|
|
3672
|
+
//#region ../../shared/translator/dist/index.js
|
|
3673
|
+
$.createInstance, $.dir, $.init, $.loadResources, $.reloadResources, $.use, $.changeLanguage, $.getFixedT, $.t, $.exists, $.setDefaultNamespace, $.hasLoadedNamespace, $.loadNamespaces, $.loadLanguages, $.init({
|
|
3674
|
+
fallbackLng: "en",
|
|
3675
|
+
lng: "en",
|
|
3676
|
+
showSupportNotice: !1,
|
|
3677
|
+
resources: {
|
|
3678
|
+
en: ai,
|
|
3679
|
+
es: oi
|
|
3680
|
+
}
|
|
3681
|
+
});
|
|
3682
|
+
//#endregion
|
|
3683
|
+
//#region src/i18n.ts
|
|
3684
|
+
var { translator: aa } = {
|
|
3685
|
+
translator: {
|
|
3686
|
+
...$,
|
|
3687
|
+
t: (e, t) => {
|
|
3688
|
+
let { lng: n } = t;
|
|
3689
|
+
switch (n) {
|
|
3690
|
+
case "en_US":
|
|
3691
|
+
case "en-US":
|
|
3692
|
+
t.lng = "en";
|
|
3693
|
+
break;
|
|
3694
|
+
case "es_ES":
|
|
3695
|
+
case "es-ES":
|
|
3696
|
+
case "es_MX":
|
|
3697
|
+
case "es-MX":
|
|
3698
|
+
t.lng = "es";
|
|
3699
|
+
break;
|
|
3700
|
+
default: break;
|
|
3701
|
+
}
|
|
3702
|
+
return $.t(e, {
|
|
3703
|
+
lng: n,
|
|
3704
|
+
...t
|
|
3705
|
+
});
|
|
3706
|
+
}
|
|
3707
|
+
},
|
|
3708
|
+
languageOptions: [{
|
|
3709
|
+
value: "en_US",
|
|
3710
|
+
label: "English (US)"
|
|
3711
|
+
}, {
|
|
3712
|
+
value: "es_ES",
|
|
3713
|
+
label: "Spanish"
|
|
3714
|
+
}]
|
|
3715
|
+
};
|
|
3716
|
+
function oa(e, t) {
|
|
3717
|
+
return aa.t(`translation:simpleCloze:${e}`, { lng: t });
|
|
3718
|
+
}
|
|
3719
|
+
//#endregion
|
|
3720
|
+
//#region src/print/Print.svelte
|
|
3721
|
+
var sa = /* @__PURE__ */ cr("<div class=\"simple-cloze-print-teacher-instructions svelte-1fx5wwa\"></div>"), ca = /* @__PURE__ */ cr("<div class=\"simple-cloze-print-prompt svelte-1fx5wwa\"></div>"), la = /* @__PURE__ */ cr("<span class=\"simple-cloze-print-key-label svelte-1fx5wwa\"> </span> <span class=\"simple-cloze-print-blank simple-cloze-print-blank--key svelte-1fx5wwa\"> </span>", 1), ua = /* @__PURE__ */ cr("<span class=\"simple-cloze-print-blank svelte-1fx5wwa\" role=\"img\"></span>"), da = /* @__PURE__ */ cr("<div class=\"simple-cloze-print svelte-1fx5wwa\"><!> <!> <div class=\"simple-cloze-print-response svelte-1fx5wwa\"><!></div></div>"), fa = {
|
|
3722
|
+
hash: "svelte-1fx5wwa",
|
|
3723
|
+
code: "\n /* Self-contained: print players ship no Tailwind or CSS reset. */.simple-cloze-print.svelte-1fx5wwa {padding:1rem;color:var(--pie-text, black);}.simple-cloze-print-teacher-instructions.svelte-1fx5wwa,\n .simple-cloze-print-prompt.svelte-1fx5wwa {margin-bottom:1rem;}.simple-cloze-print-teacher-instructions.svelte-1fx5wwa p,\n .simple-cloze-print-prompt.svelte-1fx5wwa p {margin:0.5em 0;}.simple-cloze-print-prompt.svelte-1fx5wwa strong {font-weight:600;}.simple-cloze-print-response.svelte-1fx5wwa {display:inline-flex;align-items:baseline;gap:0.5rem;}.simple-cloze-print-key-label.svelte-1fx5wwa {font-size:0.875rem;line-height:1.25rem;font-weight:600;}.simple-cloze-print-blank.svelte-1fx5wwa {display:inline-block;min-width:12rem;min-height:1.5rem;padding:0.5rem 0.75rem;border-bottom:2px solid var(--pie-text, black);}.simple-cloze-print-blank--key.svelte-1fx5wwa {min-width:6rem;font-weight:600;}\n\n @media print {.simple-cloze-print.svelte-1fx5wwa {padding:0;}\n }"
|
|
3724
|
+
};
|
|
3725
|
+
function pa(e, t) {
|
|
3726
|
+
Ge(t, !0), Er(e, fa);
|
|
3727
|
+
let n = Ir(t, "model", 7, null), r = Ir(t, "options", 7, null), i = /* @__PURE__ */ pt(() => r()?.role === "instructor"), a = /* @__PURE__ */ pt(() => n()?.promptEnabled !== !1 && typeof n()?.prompt == "string" ? n().prompt : ""), o = /* @__PURE__ */ pt(() => ii(n()?.correctAnswer)), s = /* @__PURE__ */ pt(() => X(i) && !!X(o)), c = /* @__PURE__ */ pt(() => X(i) && n()?.teacherInstructionsEnabled !== !1 && n()?.teacherInstructions || ""), l = /* @__PURE__ */ M(null);
|
|
3728
|
+
pn(() => {
|
|
3729
|
+
if (!X(l) || !X(a)) return;
|
|
3730
|
+
let e = (e) => console.warn("simple-cloze: MathJax render failed", e);
|
|
3731
|
+
try {
|
|
3732
|
+
Promise.resolve(Xr(X(l))).catch(e);
|
|
3733
|
+
} catch (t) {
|
|
3734
|
+
e(t);
|
|
3735
|
+
}
|
|
3736
|
+
});
|
|
3737
|
+
var u = {
|
|
3738
|
+
get model() {
|
|
3739
|
+
return n();
|
|
3740
|
+
},
|
|
3741
|
+
set model(e = null) {
|
|
3742
|
+
n(e), At();
|
|
3743
|
+
},
|
|
3744
|
+
get options() {
|
|
3745
|
+
return r();
|
|
3746
|
+
},
|
|
3747
|
+
set options(e = null) {
|
|
3748
|
+
r(e), At();
|
|
3749
|
+
}
|
|
3750
|
+
}, d = da(), f = $t(d), p = (e) => {
|
|
3751
|
+
var t = sa();
|
|
3752
|
+
Tr(t, () => X(c), !0), Ee(t), lr(e, t);
|
|
3753
|
+
};
|
|
3754
|
+
wr(f, (e) => {
|
|
3755
|
+
X(c) && e(p);
|
|
3756
|
+
});
|
|
3757
|
+
var m = nn(f, 2), h = (e) => {
|
|
3758
|
+
var t = ca();
|
|
3759
|
+
Tr(t, () => X(a), !0), Ee(t), Fr(t, (e) => N(l, e), () => X(l)), lr(e, t);
|
|
3760
|
+
};
|
|
3761
|
+
wr(m, (e) => {
|
|
3762
|
+
X(a) && e(h);
|
|
3763
|
+
});
|
|
3764
|
+
var g = nn(m, 2), ee = $t(g), _ = (e) => {
|
|
3765
|
+
var t = la(), r = en(t), i = tn(r, !0), a = tn(nn(r, 2), !0);
|
|
3766
|
+
bn((e) => {
|
|
3767
|
+
gr(i, e), gr(a, X(o));
|
|
3768
|
+
}, [() => oa("printCorrectAnswer", n()?.language)]), lr(e, t);
|
|
3769
|
+
}, v = (e) => {
|
|
3770
|
+
var t = ua();
|
|
3771
|
+
bn((e) => Ar(t, "aria-label", e), [() => oa("printAnswerBlank", n()?.language)]), lr(e, t);
|
|
3772
|
+
};
|
|
3773
|
+
return wr(ee, (e) => {
|
|
3774
|
+
X(s) ? e(_) : e(v, -1);
|
|
3775
|
+
}), Ee(g), Ee(d), lr(e, d), Ke(u);
|
|
3776
|
+
}
|
|
3777
|
+
Hr(pa, {
|
|
3778
|
+
model: { type: "Object" },
|
|
3779
|
+
options: { type: "Object" }
|
|
3780
|
+
}, [], []);
|
|
3781
|
+
//#endregion
|
|
3782
|
+
//#region src/print/index.ts
|
|
3783
|
+
var ma = pa.element;
|
|
3784
|
+
//#endregion
|
|
3785
|
+
export { ma as default };
|
|
3786
|
+
|
|
3787
|
+
//# sourceMappingURL=print.js.map
|