@everymatrix/loyalty-points-card 0.1.23 → 0.1.25
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/components/LoyaltyPointsCard-B_DMeKlZ.cjs +21 -0
- package/components/{LoyaltyPointsCard-DCvci6IK.js → LoyaltyPointsCard-CR1jlktX.js} +1109 -1083
- package/components/{LoyaltyPointsCard-DxiD0FSD.js → LoyaltyPointsCard-DdZkDi4L.js} +1571 -1545
- package/components/LoyaltyPointsCard-Dxmx5_Co.cjs +21 -0
- package/es2015/loyalty-points-card.cjs +1 -1
- package/es2015/loyalty-points-card.js +2 -2
- package/esnext/loyalty-points-card.cjs +1 -1
- package/esnext/loyalty-points-card.js +2 -2
- package/package.json +1 -1
- package/components/LoyaltyPointsCard-CaJ_laaI.cjs +0 -21
- package/components/LoyaltyPointsCard-Cn6YDuST.cjs +0 -21
|
@@ -5,21 +5,21 @@ typeof globalThis.HTMLElement > "u" && (globalThis.HTMLElement = class {
|
|
|
5
5
|
} });
|
|
6
6
|
const ss = "5";
|
|
7
7
|
typeof window < "u" && ((window.__svelte ??= {}).v ??= /* @__PURE__ */ new Set()).add(ss);
|
|
8
|
-
const as = 2, Rn = "[",
|
|
9
|
-
var os = Array.isArray, us = Array.prototype.indexOf, Yt = Array.prototype.includes, ls = Array.from, zt = Object.keys,
|
|
8
|
+
const as = 2, Rn = "[", Dn = "[!", ln = "[?", kn = "]", it = {}, j = Symbol("uninitialized"), Fn = !1;
|
|
9
|
+
var os = Array.isArray, us = Array.prototype.indexOf, Yt = Array.prototype.includes, ls = Array.from, zt = Object.keys, st = Object.defineProperty, rt = Object.getOwnPropertyDescriptor, fs = Object.prototype, hs = Array.prototype, cs = Object.getPrototypeOf, fn = Object.isExtensible;
|
|
10
10
|
const Be = () => {
|
|
11
11
|
};
|
|
12
|
-
function
|
|
12
|
+
function Un(e) {
|
|
13
13
|
for (var t = 0; t < e.length; t++)
|
|
14
14
|
e[t]();
|
|
15
15
|
}
|
|
16
|
-
function
|
|
16
|
+
function Gn() {
|
|
17
17
|
var e, t, r = new Promise((n, i) => {
|
|
18
18
|
e = n, t = i;
|
|
19
19
|
});
|
|
20
20
|
return { promise: r, resolve: e, reject: t };
|
|
21
21
|
}
|
|
22
|
-
const
|
|
22
|
+
const q = 2, at = 4, ir = 8, jn = 1 << 24, de = 16, me = 32, Te = 64, Ar = 128, Wr = 256, _e = 512, V = 1024, k = 2048, fe = 4096, he = 8192, ne = 16384, Ye = 32768, $r = 1 << 25, ot = 65536, qt = 1 << 17, ds = 1 << 18, ze = 1 << 19, ps = 1 << 20, Zt = 1 << 21, nt = 1 << 22, Re = 1 << 23, pr = Symbol("$state"), Vn = Symbol("component"), vs = Symbol("legacy props"), _s = Symbol("attributes"), ms = Symbol("class"), gs = Symbol("style"), Or = Symbol("text"), Mt = new class extends Error {
|
|
23
23
|
name = "StaleReactionError";
|
|
24
24
|
message = "The reaction that called `getAbortSignal()` was re-run or destroyed";
|
|
25
25
|
}(), sr = 3, ar = 8;
|
|
@@ -32,45 +32,45 @@ function or(e) {
|
|
|
32
32
|
function ys() {
|
|
33
33
|
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
34
34
|
}
|
|
35
|
-
let
|
|
35
|
+
let F = !1;
|
|
36
36
|
function tt(e) {
|
|
37
|
-
|
|
37
|
+
F = e;
|
|
38
38
|
}
|
|
39
39
|
let L;
|
|
40
40
|
function ge(e) {
|
|
41
41
|
if (e === null)
|
|
42
|
-
throw or(),
|
|
42
|
+
throw or(), it;
|
|
43
43
|
return L = e;
|
|
44
44
|
}
|
|
45
|
-
function
|
|
45
|
+
function Xr() {
|
|
46
46
|
return ge(/* @__PURE__ */ Ne(L));
|
|
47
47
|
}
|
|
48
48
|
function Ft(e) {
|
|
49
|
-
if (
|
|
49
|
+
if (F) {
|
|
50
50
|
if (/* @__PURE__ */ Ne(L) !== null)
|
|
51
|
-
throw or(),
|
|
51
|
+
throw or(), it;
|
|
52
52
|
L = e;
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
function Es(e = 1) {
|
|
56
|
-
if (
|
|
56
|
+
if (F) {
|
|
57
57
|
for (var t = e, r = L; t--; )
|
|
58
58
|
r = /** @type {TemplateNode} */
|
|
59
59
|
/* @__PURE__ */ Ne(r);
|
|
60
60
|
L = r;
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
function
|
|
63
|
+
function Wn(e = !0) {
|
|
64
64
|
for (var t = 0, r = L; ; ) {
|
|
65
65
|
if (r.nodeType === ar) {
|
|
66
66
|
var n = (
|
|
67
67
|
/** @type {Comment} */
|
|
68
68
|
r.data
|
|
69
69
|
);
|
|
70
|
-
if (n ===
|
|
70
|
+
if (n === kn) {
|
|
71
71
|
if (t === 0) return r;
|
|
72
72
|
t -= 1;
|
|
73
|
-
} else (n === Rn || n ===
|
|
73
|
+
} else (n === Rn || n === Dn || // "[1", "[2", etc. for if blocks
|
|
74
74
|
n[0] === "[" && !isNaN(Number(n.slice(1)))) && (t += 1);
|
|
75
75
|
}
|
|
76
76
|
var i = (
|
|
@@ -82,20 +82,20 @@ function Vn(e = !0) {
|
|
|
82
82
|
}
|
|
83
83
|
function xs(e) {
|
|
84
84
|
if (!e || e.nodeType !== ar)
|
|
85
|
-
throw or(),
|
|
85
|
+
throw or(), it;
|
|
86
86
|
return (
|
|
87
87
|
/** @type {Comment} */
|
|
88
88
|
e.data
|
|
89
89
|
);
|
|
90
90
|
}
|
|
91
|
-
function
|
|
91
|
+
function Xn(e) {
|
|
92
92
|
return e === this.v;
|
|
93
93
|
}
|
|
94
|
-
function
|
|
94
|
+
function Yn(e, t) {
|
|
95
95
|
return e != e ? t == t : e !== t || e !== null && typeof e == "object" || typeof e == "function";
|
|
96
96
|
}
|
|
97
97
|
function ws(e) {
|
|
98
|
-
return !
|
|
98
|
+
return !Yn(e, this.v);
|
|
99
99
|
}
|
|
100
100
|
function Ts() {
|
|
101
101
|
throw new Error("https://svelte.dev/e/async_derived_orphan");
|
|
@@ -127,13 +127,13 @@ function Ps() {
|
|
|
127
127
|
function Ms() {
|
|
128
128
|
throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror");
|
|
129
129
|
}
|
|
130
|
-
let Ns = !1,
|
|
131
|
-
function
|
|
132
|
-
|
|
130
|
+
let Ns = !1, ie = null;
|
|
131
|
+
function ut(e) {
|
|
132
|
+
ie = e;
|
|
133
133
|
}
|
|
134
|
-
function
|
|
135
|
-
|
|
136
|
-
p:
|
|
134
|
+
function Yr(e, t = !1, r) {
|
|
135
|
+
ie = {
|
|
136
|
+
p: ie,
|
|
137
137
|
i: !1,
|
|
138
138
|
c: null,
|
|
139
139
|
e: null,
|
|
@@ -141,184 +141,59 @@ function Xr(e, t = !1, r) {
|
|
|
141
141
|
x: null,
|
|
142
142
|
r: (
|
|
143
143
|
/** @type {Effect} */
|
|
144
|
-
|
|
144
|
+
S
|
|
145
145
|
),
|
|
146
146
|
l: null
|
|
147
147
|
};
|
|
148
148
|
}
|
|
149
|
-
function
|
|
149
|
+
function zr(e) {
|
|
150
150
|
var t = (
|
|
151
151
|
/** @type {ComponentContext} */
|
|
152
|
-
|
|
152
|
+
ie
|
|
153
153
|
), r = t.e;
|
|
154
154
|
if (r !== null) {
|
|
155
155
|
t.e = null;
|
|
156
156
|
for (var n of r)
|
|
157
157
|
hi(n);
|
|
158
158
|
}
|
|
159
|
-
return e !== void 0 && (t.x = e), t.i = !0,
|
|
159
|
+
return e !== void 0 && (t.x = e), t.i = !0, ie = t.p, zn(e);
|
|
160
160
|
}
|
|
161
|
-
function
|
|
162
|
-
return
|
|
161
|
+
function zn(e = {}) {
|
|
162
|
+
return st(e, Vn, { value: !0 }), e;
|
|
163
163
|
}
|
|
164
|
-
function
|
|
164
|
+
function qn() {
|
|
165
165
|
return !0;
|
|
166
166
|
}
|
|
167
|
-
let
|
|
168
|
-
function
|
|
169
|
-
var e =
|
|
170
|
-
|
|
167
|
+
let Ge = [];
|
|
168
|
+
function Zn() {
|
|
169
|
+
var e = Ge;
|
|
170
|
+
Ge = [], Un(e);
|
|
171
171
|
}
|
|
172
|
-
function
|
|
173
|
-
if (
|
|
174
|
-
var t =
|
|
172
|
+
function je(e) {
|
|
173
|
+
if (Ge.length === 0 && !St) {
|
|
174
|
+
var t = Ge;
|
|
175
175
|
queueMicrotask(() => {
|
|
176
|
-
t ===
|
|
176
|
+
t === Ge && Zn();
|
|
177
177
|
});
|
|
178
178
|
}
|
|
179
|
-
|
|
179
|
+
Ge.push(e);
|
|
180
180
|
}
|
|
181
181
|
function Is() {
|
|
182
|
-
for (;
|
|
183
|
-
|
|
182
|
+
for (; Ge.length > 0; )
|
|
183
|
+
Zn();
|
|
184
184
|
}
|
|
185
|
-
const
|
|
186
|
-
function
|
|
187
|
-
e.f = e.f &
|
|
185
|
+
const Cs = -7169;
|
|
186
|
+
function C(e, t) {
|
|
187
|
+
e.f = e.f & Cs | t;
|
|
188
188
|
}
|
|
189
|
-
function
|
|
190
|
-
e.f &
|
|
191
|
-
}
|
|
192
|
-
function Zn(e) {
|
|
193
|
-
if (e !== null)
|
|
194
|
-
for (const t of e)
|
|
195
|
-
!(t.f & z) || !(t.f & We) || (t.f ^= We, Zn(
|
|
196
|
-
/** @type {Derived} */
|
|
197
|
-
t.deps
|
|
198
|
-
));
|
|
189
|
+
function qr(e) {
|
|
190
|
+
e.f & _e || e.deps === null ? C(e, V) : C(e, fe);
|
|
199
191
|
}
|
|
200
192
|
function Jn(e, t, r) {
|
|
201
|
-
e.f &
|
|
202
|
-
}
|
|
203
|
-
function qr(e, t, r) {
|
|
204
|
-
if (e == null)
|
|
205
|
-
return t(void 0), r && r(void 0), Be;
|
|
206
|
-
const n = Hi(
|
|
207
|
-
() => e.subscribe(
|
|
208
|
-
t,
|
|
209
|
-
// @ts-expect-error
|
|
210
|
-
r
|
|
211
|
-
)
|
|
212
|
-
);
|
|
213
|
-
return n.unsubscribe ? () => n.unsubscribe() : n;
|
|
214
|
-
}
|
|
215
|
-
const Qe = [];
|
|
216
|
-
function Cs(e, t) {
|
|
217
|
-
return {
|
|
218
|
-
subscribe: ur(e, t).subscribe
|
|
219
|
-
};
|
|
220
|
-
}
|
|
221
|
-
function ur(e, t = Be) {
|
|
222
|
-
let r = null;
|
|
223
|
-
const n = /* @__PURE__ */ new Set();
|
|
224
|
-
function i(o) {
|
|
225
|
-
if (Xn(e, o) && (e = o, r)) {
|
|
226
|
-
const u = !Qe.length;
|
|
227
|
-
for (const l of n)
|
|
228
|
-
l[1](), Qe.push(l, e);
|
|
229
|
-
if (u) {
|
|
230
|
-
for (let l = 0; l < Qe.length; l += 2)
|
|
231
|
-
Qe[l][0](Qe[l + 1]);
|
|
232
|
-
Qe.length = 0;
|
|
233
|
-
}
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
function s(o) {
|
|
237
|
-
i(o(
|
|
238
|
-
/** @type {T} */
|
|
239
|
-
e
|
|
240
|
-
));
|
|
241
|
-
}
|
|
242
|
-
function a(o, u = Be) {
|
|
243
|
-
const l = [o, u];
|
|
244
|
-
return n.add(l), n.size === 1 && (r = t(i, s) || Be), o(
|
|
245
|
-
/** @type {T} */
|
|
246
|
-
e
|
|
247
|
-
), () => {
|
|
248
|
-
n.delete(l), n.size === 0 && r && (r(), r = null);
|
|
249
|
-
};
|
|
250
|
-
}
|
|
251
|
-
return { set: i, update: s, subscribe: a };
|
|
252
|
-
}
|
|
253
|
-
function _t(e, t, r) {
|
|
254
|
-
const n = !Array.isArray(e), i = n ? [e] : e;
|
|
255
|
-
if (!i.every(Boolean))
|
|
256
|
-
throw new Error("derived() expects stores as input, got a falsy value");
|
|
257
|
-
const s = t.length < 2;
|
|
258
|
-
return Cs(r, (a, o) => {
|
|
259
|
-
let u = !1;
|
|
260
|
-
const l = [];
|
|
261
|
-
let f = 0, h = Be;
|
|
262
|
-
const c = () => {
|
|
263
|
-
if (f)
|
|
264
|
-
return;
|
|
265
|
-
h();
|
|
266
|
-
const p = t(n ? l[0] : l, a, o);
|
|
267
|
-
s ? a(p) : h = typeof p == "function" ? p : Be;
|
|
268
|
-
}, d = i.map(
|
|
269
|
-
(p, b) => qr(
|
|
270
|
-
p,
|
|
271
|
-
(N) => {
|
|
272
|
-
l[b] = N, f &= ~(1 << b), u && c();
|
|
273
|
-
},
|
|
274
|
-
() => {
|
|
275
|
-
f |= 1 << b;
|
|
276
|
-
}
|
|
277
|
-
)
|
|
278
|
-
);
|
|
279
|
-
return u = !0, c(), function() {
|
|
280
|
-
Fn(d), h(), u = !1;
|
|
281
|
-
};
|
|
282
|
-
});
|
|
283
|
-
}
|
|
284
|
-
function Ds(e) {
|
|
285
|
-
let t;
|
|
286
|
-
return qr(e, (r) => t = r)(), t;
|
|
287
|
-
}
|
|
288
|
-
let Br = Symbol("unmounted");
|
|
289
|
-
function ks(e, t, r) {
|
|
290
|
-
const n = r[t] ??= {
|
|
291
|
-
store: null,
|
|
292
|
-
source: /* @__PURE__ */ si(void 0),
|
|
293
|
-
unsubscribe: Be
|
|
294
|
-
};
|
|
295
|
-
if (n.store !== e && !(Br in r))
|
|
296
|
-
if (n.unsubscribe(), n.store = e ?? null, e == null)
|
|
297
|
-
n.source.v = void 0, n.unsubscribe = Be;
|
|
298
|
-
else {
|
|
299
|
-
var i = !0;
|
|
300
|
-
n.unsubscribe = qr(e, (s) => {
|
|
301
|
-
i ? n.source.v = s : Y(n.source, s);
|
|
302
|
-
}), i = !1;
|
|
303
|
-
}
|
|
304
|
-
return e && Br in r ? Ds(e) : $(n.source);
|
|
193
|
+
e.f & k ? t.add(e) : e.f & fe && r.add(e), C(e, V);
|
|
305
194
|
}
|
|
306
|
-
function
|
|
307
|
-
|
|
308
|
-
function t() {
|
|
309
|
-
fi(() => {
|
|
310
|
-
for (var r in e)
|
|
311
|
-
e[r].unsubscribe();
|
|
312
|
-
at(e, Br, {
|
|
313
|
-
enumerable: !1,
|
|
314
|
-
value: !0
|
|
315
|
-
});
|
|
316
|
-
});
|
|
317
|
-
}
|
|
318
|
-
return [e, t];
|
|
319
|
-
}
|
|
320
|
-
function lr(e) {
|
|
321
|
-
var t = S, r = w;
|
|
195
|
+
function ur(e) {
|
|
196
|
+
var t = T, r = S;
|
|
322
197
|
ce(null), Se(null);
|
|
323
198
|
try {
|
|
324
199
|
return e();
|
|
@@ -326,24 +201,24 @@ function lr(e) {
|
|
|
326
201
|
ce(t), Se(r);
|
|
327
202
|
}
|
|
328
203
|
}
|
|
329
|
-
function
|
|
204
|
+
function Rs(e, t, r, n) {
|
|
330
205
|
const i = Zr;
|
|
331
|
-
var s = e.filter((d) => !d.settled),
|
|
206
|
+
var s = e.filter((d) => !d.settled), o = t.map(i);
|
|
332
207
|
if (r.length === 0 && s.length === 0) {
|
|
333
|
-
n(
|
|
208
|
+
n(o);
|
|
334
209
|
return;
|
|
335
210
|
}
|
|
336
|
-
var
|
|
211
|
+
var a = (
|
|
337
212
|
/** @type {Effect} */
|
|
338
|
-
|
|
339
|
-
), u =
|
|
213
|
+
S
|
|
214
|
+
), u = Ds(), l = s.length === 1 ? s[0].promise : s.length > 1 ? Promise.all(s.map((d) => d.promise)) : null;
|
|
340
215
|
function f(d) {
|
|
341
|
-
if (!(
|
|
216
|
+
if (!(a.f & ne)) {
|
|
342
217
|
u();
|
|
343
218
|
try {
|
|
344
|
-
n([...
|
|
219
|
+
n([...o, ...d]);
|
|
345
220
|
} catch (p) {
|
|
346
|
-
be(p,
|
|
221
|
+
be(p, a);
|
|
347
222
|
}
|
|
348
223
|
Jt();
|
|
349
224
|
}
|
|
@@ -354,31 +229,31 @@ function Us(e, t, r, n) {
|
|
|
354
229
|
return;
|
|
355
230
|
}
|
|
356
231
|
function c() {
|
|
357
|
-
Promise.all(r.map((d) => /* @__PURE__ */
|
|
232
|
+
Promise.all(r.map((d) => /* @__PURE__ */ ks(d))).then(f).catch((d) => be(d, a)).finally(h);
|
|
358
233
|
}
|
|
359
234
|
l ? l.then(() => {
|
|
360
235
|
u(), c(), Jt();
|
|
361
236
|
}) : c();
|
|
362
237
|
}
|
|
363
|
-
function
|
|
238
|
+
function Ds() {
|
|
364
239
|
var e = (
|
|
365
240
|
/** @type {Effect} */
|
|
366
|
-
|
|
367
|
-
), t =
|
|
241
|
+
S
|
|
242
|
+
), t = T, r = ie, n = (
|
|
368
243
|
/** @type {Batch} */
|
|
369
244
|
A
|
|
370
245
|
);
|
|
371
246
|
return function(s = !0) {
|
|
372
|
-
Se(e), ce(t),
|
|
247
|
+
Se(e), ce(t), ut(r), s && !(e.f & ne) && (n?.activate(), n?.apply());
|
|
373
248
|
};
|
|
374
249
|
}
|
|
375
250
|
function Jt(e = !0) {
|
|
376
|
-
Se(null), ce(null),
|
|
251
|
+
Se(null), ce(null), ut(null), e && A?.deactivate();
|
|
377
252
|
}
|
|
378
253
|
function Qn() {
|
|
379
254
|
var e = (
|
|
380
255
|
/** @type {Effect} */
|
|
381
|
-
|
|
256
|
+
S
|
|
382
257
|
), t = e.b, r = (
|
|
383
258
|
/** @type {Batch} */
|
|
384
259
|
A
|
|
@@ -389,12 +264,12 @@ function Qn() {
|
|
|
389
264
|
}
|
|
390
265
|
// @__NO_SIDE_EFFECTS__
|
|
391
266
|
function Zr(e) {
|
|
392
|
-
var t =
|
|
393
|
-
return
|
|
394
|
-
ctx:
|
|
267
|
+
var t = q | k;
|
|
268
|
+
return S !== null && (S.f |= ze), {
|
|
269
|
+
ctx: ie,
|
|
395
270
|
deps: null,
|
|
396
271
|
effects: null,
|
|
397
|
-
equals:
|
|
272
|
+
equals: Xn,
|
|
398
273
|
f: t,
|
|
399
274
|
fn: e,
|
|
400
275
|
reactions: null,
|
|
@@ -404,16 +279,16 @@ function Zr(e) {
|
|
|
404
279
|
j
|
|
405
280
|
),
|
|
406
281
|
wv: 0,
|
|
407
|
-
parent:
|
|
282
|
+
parent: S,
|
|
408
283
|
ac: null
|
|
409
284
|
};
|
|
410
285
|
}
|
|
411
|
-
const
|
|
286
|
+
const xt = Symbol("obsolete");
|
|
412
287
|
// @__NO_SIDE_EFFECTS__
|
|
413
|
-
function
|
|
288
|
+
function ks(e, t, r) {
|
|
414
289
|
let n = (
|
|
415
290
|
/** @type {Effect | null} */
|
|
416
|
-
|
|
291
|
+
S
|
|
417
292
|
);
|
|
418
293
|
n === null && Ts();
|
|
419
294
|
var i = (
|
|
@@ -423,12 +298,12 @@ function js(e, t, r) {
|
|
|
423
298
|
), s = Nt(
|
|
424
299
|
/** @type {V} */
|
|
425
300
|
j
|
|
426
|
-
),
|
|
427
|
-
return
|
|
301
|
+
), o = !T, a = /* @__PURE__ */ new Set();
|
|
302
|
+
return ea(() => {
|
|
428
303
|
var u = (
|
|
429
304
|
/** @type {Effect} */
|
|
430
|
-
|
|
431
|
-
), l =
|
|
305
|
+
S
|
|
306
|
+
), l = Gn();
|
|
432
307
|
i = l.promise;
|
|
433
308
|
try {
|
|
434
309
|
Promise.resolve(e()).then(l.resolve, (d) => {
|
|
@@ -441,26 +316,26 @@ function js(e, t, r) {
|
|
|
441
316
|
/** @type {Batch} */
|
|
442
317
|
A
|
|
443
318
|
);
|
|
444
|
-
if (
|
|
319
|
+
if (o) {
|
|
445
320
|
if (u.f & Ye)
|
|
446
321
|
var h = Qn();
|
|
447
322
|
if (
|
|
448
323
|
// boundary can be null if the async derived is inside an $effect.root not connected to the component render tree
|
|
449
324
|
n.b?.is_rendered()
|
|
450
325
|
)
|
|
451
|
-
f.async_deriveds.get(u)?.reject(
|
|
326
|
+
f.async_deriveds.get(u)?.reject(xt);
|
|
452
327
|
else
|
|
453
|
-
for (const d of
|
|
454
|
-
d.reject(
|
|
455
|
-
|
|
328
|
+
for (const d of a.values())
|
|
329
|
+
d.reject(xt);
|
|
330
|
+
a.add(l), f.async_deriveds.set(u, l);
|
|
456
331
|
}
|
|
457
332
|
const c = (d, p = void 0) => {
|
|
458
|
-
h?.(),
|
|
333
|
+
h?.(), a.delete(l), p !== xt && (f.activate(), p ? (s.f |= Re, Kt(s, p)) : (s.f & Re && (s.f ^= Re), Kt(s, d)), f.deactivate());
|
|
459
334
|
};
|
|
460
335
|
l.promise.then(c, (d) => c(null, d || "unknown"));
|
|
461
336
|
}), fi(() => {
|
|
462
|
-
for (const u of
|
|
463
|
-
u.reject(
|
|
337
|
+
for (const u of a)
|
|
338
|
+
u.reject(xt);
|
|
464
339
|
}), new Promise((u) => {
|
|
465
340
|
function l(f) {
|
|
466
341
|
function h() {
|
|
@@ -472,29 +347,29 @@ function js(e, t, r) {
|
|
|
472
347
|
});
|
|
473
348
|
}
|
|
474
349
|
// @__NO_SIDE_EFFECTS__
|
|
475
|
-
function
|
|
350
|
+
function Qe(e) {
|
|
476
351
|
const t = /* @__PURE__ */ Zr(e);
|
|
477
352
|
return bi(t), t;
|
|
478
353
|
}
|
|
479
|
-
function
|
|
354
|
+
function Fs(e) {
|
|
480
355
|
var t = e.effects;
|
|
481
356
|
if (t !== null) {
|
|
482
357
|
e.effects = null;
|
|
483
358
|
for (var r = 0; r < t.length; r += 1)
|
|
484
|
-
|
|
359
|
+
se(
|
|
485
360
|
/** @type {Effect} */
|
|
486
361
|
t[r]
|
|
487
362
|
);
|
|
488
363
|
}
|
|
489
364
|
}
|
|
490
365
|
function Jr(e) {
|
|
491
|
-
var t, r =
|
|
366
|
+
var t, r = S, n = e.parent;
|
|
492
367
|
if (!Me && n !== null && e.v !== j && // if it was never evaluated before, it's guaranteed to fail downstream, so we try to execute instead
|
|
493
|
-
n.f & (
|
|
368
|
+
n.f & (ne | he))
|
|
494
369
|
return bs(), e.v;
|
|
495
370
|
Se(n);
|
|
496
371
|
try {
|
|
497
|
-
|
|
372
|
+
Fs(e), t = wi(e);
|
|
498
373
|
} finally {
|
|
499
374
|
Se(r);
|
|
500
375
|
}
|
|
@@ -502,29 +377,29 @@ function Jr(e) {
|
|
|
502
377
|
}
|
|
503
378
|
function Kn(e) {
|
|
504
379
|
var t = Jr(e);
|
|
505
|
-
if (!e.equals(t) && (e.wv = Ei(), (!A?.is_fork || e.deps === null) && (A !== null ? (A.capture(e, t, !0),
|
|
506
|
-
|
|
380
|
+
if (!e.equals(t) && (e.wv = Ei(), (!A?.is_fork || e.deps === null) && (A !== null ? (A.capture(e, t, !0), Br?.capture(e, t, !0)) : e.v = t, e.deps === null))) {
|
|
381
|
+
C(e, V);
|
|
507
382
|
return;
|
|
508
383
|
}
|
|
509
|
-
Me || (pe !== null ? (rn() || A?.is_fork) && pe.set(e, t) :
|
|
384
|
+
Me || (pe !== null ? (rn() || A?.is_fork) && pe.set(e, t) : qr(e));
|
|
510
385
|
}
|
|
511
|
-
function
|
|
386
|
+
function Us(e) {
|
|
512
387
|
if (e.effects !== null)
|
|
513
388
|
for (const t of e.effects)
|
|
514
|
-
(t.teardown || t.ac) && (t.teardown?.(), t.ac !== null &&
|
|
389
|
+
(t.teardown || t.ac) && (t.teardown?.(), t.ac !== null && ur(() => {
|
|
515
390
|
t.ac.abort(Mt), t.ac = null;
|
|
516
391
|
}), t.fn !== null && (t.teardown = Be), Ot(t, 0), nn(t));
|
|
517
392
|
}
|
|
518
393
|
function ei(e) {
|
|
519
394
|
if (e.effects !== null)
|
|
520
395
|
for (const t of e.effects)
|
|
521
|
-
t.teardown && t.fn !== null &&
|
|
396
|
+
t.teardown && t.fn !== null && ft(t);
|
|
522
397
|
}
|
|
523
|
-
let vr = null,
|
|
524
|
-
var
|
|
525
|
-
let
|
|
398
|
+
let vr = null, Ke = null, A = null, Br = null, pe = null, Lr = null, St = !1, _r = !1, Ht = null, Ut = null;
|
|
399
|
+
var hn = 0;
|
|
400
|
+
let Gs = 1;
|
|
526
401
|
class Le {
|
|
527
|
-
id =
|
|
402
|
+
id = Gs++;
|
|
528
403
|
/** True as soon as `#process` was called */
|
|
529
404
|
#e = !1;
|
|
530
405
|
linked = !0;
|
|
@@ -574,7 +449,14 @@ class Le {
|
|
|
574
449
|
*/
|
|
575
450
|
#o = null;
|
|
576
451
|
/**
|
|
577
|
-
*
|
|
452
|
+
* Effects that were scheduled in this batch but not yet 'resolved' into the
|
|
453
|
+
* root effects that need to be flushed. Resolving — the upwards traversal that
|
|
454
|
+
* marks the path to each effect on the shared effect tree (see #resolve) — is
|
|
455
|
+
* deferred until the batch is processed, so that the markers are created and
|
|
456
|
+
* consumed within a single traversal. Scheduling into other batches (which can
|
|
457
|
+
* happen concurrently, e.g. while a batch is committed) can therefore never
|
|
458
|
+
* observe (and be confused by) this batch's markers.
|
|
459
|
+
* May contain duplicates — deduplication happens during resolving
|
|
578
460
|
* @type {Effect[]}
|
|
579
461
|
*/
|
|
580
462
|
#s = [];
|
|
@@ -582,7 +464,7 @@ class Le {
|
|
|
582
464
|
* Effects created while this batch was active.
|
|
583
465
|
* @type {Effect[]}
|
|
584
466
|
*/
|
|
585
|
-
#
|
|
467
|
+
#p = [];
|
|
586
468
|
/**
|
|
587
469
|
* Deferred effects (which run after async work has completed) that are DIRTY
|
|
588
470
|
* @type {Set<Effect>}
|
|
@@ -609,7 +491,7 @@ class Le {
|
|
|
609
491
|
is_fork = !1;
|
|
610
492
|
#h = !1;
|
|
611
493
|
constructor() {
|
|
612
|
-
|
|
494
|
+
Ke === null ? vr = Ke = this : (Ke.#r = this, this.#t = Ke), Ke = this;
|
|
613
495
|
}
|
|
614
496
|
#b() {
|
|
615
497
|
if (this.is_fork) return !0;
|
|
@@ -644,57 +526,87 @@ class Le {
|
|
|
644
526
|
if (n) {
|
|
645
527
|
this.#c.delete(t);
|
|
646
528
|
for (var i of n.d)
|
|
647
|
-
|
|
529
|
+
C(i, k), r(i);
|
|
648
530
|
for (i of n.m)
|
|
649
|
-
|
|
531
|
+
C(i, fe), r(i);
|
|
650
532
|
}
|
|
651
533
|
this.#_.add(t);
|
|
652
534
|
}
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
535
|
+
/**
|
|
536
|
+
* Convert the effects that were scheduled in this batch into the root effects
|
|
537
|
+
* that need to be traversed, marking the path to each effect (by clearing the
|
|
538
|
+
* `CLEAN` flag on ancestor branches) so that the traversal can find them.
|
|
539
|
+
* This happens right before traversal rather than at scheduling time, so that
|
|
540
|
+
* the markers left on the (shared) effect tree are created and consumed within
|
|
541
|
+
* a single traversal — scheduling into other batches can never observe them
|
|
542
|
+
* @returns {Effect[]}
|
|
543
|
+
*/
|
|
544
|
+
#y() {
|
|
545
|
+
var t = [];
|
|
546
|
+
for (const s of this.#s)
|
|
547
|
+
if (!(s.f & ne || !(s.f & (k | fe)))) {
|
|
548
|
+
for (var r = s, n = !1; r.parent !== null; ) {
|
|
549
|
+
r = r.parent;
|
|
550
|
+
var i = r.f;
|
|
551
|
+
if (i & (Te | me)) {
|
|
552
|
+
if (!(i & V)) {
|
|
553
|
+
n = !0;
|
|
554
|
+
break;
|
|
555
|
+
}
|
|
556
|
+
r.f ^= V;
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
n || t.push(r);
|
|
667
560
|
}
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
561
|
+
return this.#s = [], t;
|
|
562
|
+
}
|
|
563
|
+
#m() {
|
|
564
|
+
this.#e = !0;
|
|
565
|
+
for (const a of this.#l)
|
|
566
|
+
this.#f.delete(a), C(a, k), this.schedule(a);
|
|
567
|
+
for (const a of this.#f)
|
|
568
|
+
C(a, fe), this.schedule(a);
|
|
569
|
+
this.apply();
|
|
570
|
+
for (var t = Ht = [], r = [], n = Ut = []; this.#s.length > 0; ) {
|
|
571
|
+
hn++ > 1e3 && (this.#v(), js());
|
|
572
|
+
for (const a of this.#y())
|
|
573
|
+
try {
|
|
574
|
+
this.#g(a, t, r);
|
|
575
|
+
} catch (u) {
|
|
576
|
+
throw ni(a), this.#b() || this.discard(), u;
|
|
577
|
+
}
|
|
672
578
|
}
|
|
673
|
-
if (
|
|
674
|
-
|
|
675
|
-
for (const
|
|
676
|
-
|
|
677
|
-
|
|
579
|
+
if (A = null, n.length > 0) {
|
|
580
|
+
var i = Le.ensure();
|
|
581
|
+
for (const a of n)
|
|
582
|
+
i.schedule(a);
|
|
583
|
+
}
|
|
584
|
+
if (Ht = null, Ut = null, this.#b()) {
|
|
585
|
+
this.#d(r), this.#d(t);
|
|
586
|
+
for (const [a, u] of this.#c)
|
|
587
|
+
ri(a, u);
|
|
588
|
+
n.length > 0 && /** @type {unknown} */
|
|
678
589
|
A.#m();
|
|
679
590
|
return;
|
|
680
591
|
}
|
|
681
|
-
const
|
|
682
|
-
if (
|
|
683
|
-
this.#d(
|
|
592
|
+
const s = this.#w();
|
|
593
|
+
if (s) {
|
|
594
|
+
this.#d(r), this.#d(t), s.#E(this);
|
|
684
595
|
return;
|
|
685
596
|
}
|
|
686
597
|
this.#l.clear(), this.#f.clear();
|
|
687
|
-
for (const
|
|
688
|
-
this.#u.clear(),
|
|
598
|
+
for (const a of this.#u) a(this);
|
|
599
|
+
this.#u.clear(), Br = this, cn(r), cn(t), Br = null, this.#o?.resolve();
|
|
689
600
|
var o = (
|
|
690
601
|
/** @type {Batch | null} */
|
|
691
602
|
/** @type {unknown} */
|
|
692
603
|
A
|
|
693
604
|
);
|
|
694
|
-
if (this.#a === 0 && (this.#s.length === 0 || o !== null) && this.#
|
|
605
|
+
if (this.#a === 0 && (this.#s.length === 0 || o !== null) && this.#v(), this.#s.length > 0)
|
|
695
606
|
if (o !== null) {
|
|
696
|
-
const
|
|
697
|
-
|
|
607
|
+
for (const a of this.#s)
|
|
608
|
+
o.#s.push(a);
|
|
609
|
+
this.#s = [];
|
|
698
610
|
} else
|
|
699
611
|
o = this;
|
|
700
612
|
o !== null && (xe.clear(), o.#m());
|
|
@@ -706,12 +618,12 @@ class Le {
|
|
|
706
618
|
* @param {Effect[]} effects
|
|
707
619
|
* @param {Effect[]} render_effects
|
|
708
620
|
*/
|
|
709
|
-
#
|
|
621
|
+
#g(t, r, n) {
|
|
710
622
|
t.f ^= V;
|
|
711
623
|
for (var i = t.first; i !== null; ) {
|
|
712
|
-
var s = i.f,
|
|
624
|
+
var s = i.f, o = (s & (me | Te)) !== 0, a = o && (s & V) !== 0, u = a || (s & he) !== 0 || this.#c.has(i);
|
|
713
625
|
if (!u && i.fn !== null) {
|
|
714
|
-
|
|
626
|
+
o ? i.f ^= V : s & at ? r.push(i) : It(i) && (s & de && this.#f.add(i), ft(i));
|
|
715
627
|
var l = i.first;
|
|
716
628
|
if (l !== null) {
|
|
717
629
|
i = l;
|
|
@@ -728,7 +640,7 @@ class Le {
|
|
|
728
640
|
}
|
|
729
641
|
}
|
|
730
642
|
}
|
|
731
|
-
#
|
|
643
|
+
#w() {
|
|
732
644
|
for (var t = this.#t; t !== null; ) {
|
|
733
645
|
if (!t.is_fork) {
|
|
734
646
|
for (const [r, [, n]] of this.current)
|
|
@@ -742,7 +654,7 @@ class Le {
|
|
|
742
654
|
/**
|
|
743
655
|
* @param {Batch} batch
|
|
744
656
|
*/
|
|
745
|
-
#
|
|
657
|
+
#E(t) {
|
|
746
658
|
for (const [n, i] of t.current)
|
|
747
659
|
!this.previous.has(n) && t.previous.has(n) && this.previous.set(n, t.previous.get(n)), this.current.set(n, i);
|
|
748
660
|
for (const [n, i] of t.async_deriveds) {
|
|
@@ -752,26 +664,26 @@ class Le {
|
|
|
752
664
|
t.async_deriveds.clear(), this.transfer_effects(t.#l, t.#f);
|
|
753
665
|
const r = (n) => {
|
|
754
666
|
var i = n.reactions;
|
|
755
|
-
if (i !== null && !(n.f &
|
|
756
|
-
for (const
|
|
757
|
-
var s =
|
|
758
|
-
if (s &
|
|
667
|
+
if (i !== null && !(n.f & q && !(n.f & (k | fe))))
|
|
668
|
+
for (const a of i) {
|
|
669
|
+
var s = a.f;
|
|
670
|
+
if (s & q)
|
|
759
671
|
r(
|
|
760
672
|
/** @type {Derived} */
|
|
761
|
-
|
|
673
|
+
a
|
|
762
674
|
);
|
|
763
675
|
else {
|
|
764
|
-
var
|
|
676
|
+
var o = (
|
|
765
677
|
/** @type {Effect} */
|
|
766
|
-
|
|
678
|
+
a
|
|
767
679
|
);
|
|
768
|
-
s & (
|
|
680
|
+
s & (nt | de) && !this.async_deriveds.has(o) && (this.#f.delete(o), C(o, k), this.schedule(o));
|
|
769
681
|
}
|
|
770
682
|
}
|
|
771
683
|
};
|
|
772
684
|
for (const n of this.current.keys())
|
|
773
685
|
r(n);
|
|
774
|
-
this.oncommit(() => t.discard()), t.#
|
|
686
|
+
this.oncommit(() => t.discard()), t.#v(), A = this, this.#m();
|
|
775
687
|
}
|
|
776
688
|
/**
|
|
777
689
|
* @param {Effect[]} effects
|
|
@@ -788,7 +700,7 @@ class Le {
|
|
|
788
700
|
* @param {boolean} [is_derived]
|
|
789
701
|
*/
|
|
790
702
|
capture(t, r, n = !1) {
|
|
791
|
-
t.v !== j && !this.previous.has(t) && this.previous.set(t, t.v), t.f &
|
|
703
|
+
t.v !== j && !this.previous.has(t) && this.previous.set(t, t.v), t.f & Re || (this.current.set(t, [r, n]), pe?.set(t, r)), this.is_fork || (t.v = r);
|
|
792
704
|
}
|
|
793
705
|
activate() {
|
|
794
706
|
A = this;
|
|
@@ -800,23 +712,23 @@ class Le {
|
|
|
800
712
|
try {
|
|
801
713
|
_r = !0, A = this, this.#m();
|
|
802
714
|
} finally {
|
|
803
|
-
|
|
715
|
+
hn = 0, Lr = null, Ht = null, Ut = null, _r = !1, A = null, pe = null, xe.clear();
|
|
804
716
|
}
|
|
805
717
|
}
|
|
806
718
|
discard() {
|
|
807
719
|
for (const t of this.#i) t(this);
|
|
808
720
|
this.#i.clear();
|
|
809
721
|
for (const t of this.async_deriveds.values())
|
|
810
|
-
t.reject(
|
|
811
|
-
this.#
|
|
722
|
+
t.reject(xt);
|
|
723
|
+
this.#v(), this.#o?.resolve();
|
|
812
724
|
}
|
|
813
725
|
/**
|
|
814
726
|
* @param {Effect} effect
|
|
815
727
|
*/
|
|
816
728
|
register_created_effect(t) {
|
|
817
|
-
this.#
|
|
729
|
+
this.#p.push(t);
|
|
818
730
|
}
|
|
819
|
-
#
|
|
731
|
+
#x() {
|
|
820
732
|
for (let h = vr; h !== null; h = h.#r) {
|
|
821
733
|
var t = h.id < this.id, r = [];
|
|
822
734
|
for (const [c, [d, p]] of this.current) {
|
|
@@ -849,25 +761,24 @@ class Le {
|
|
|
849
761
|
if (t)
|
|
850
762
|
for (const c of this.#_)
|
|
851
763
|
h.unskip_effect(c, (d) => {
|
|
852
|
-
d.f & (de |
|
|
764
|
+
d.f & (de | nt) ? h.schedule(d) : h.#d([d]);
|
|
853
765
|
});
|
|
854
766
|
h.activate();
|
|
855
|
-
var
|
|
767
|
+
var o = /* @__PURE__ */ new Set(), a = /* @__PURE__ */ new Map();
|
|
856
768
|
for (var u of r)
|
|
857
|
-
ti(u, s,
|
|
858
|
-
|
|
769
|
+
ti(u, s, o, a);
|
|
770
|
+
a = /* @__PURE__ */ new Map();
|
|
859
771
|
var l = [...h.current].filter(([c, d]) => {
|
|
860
772
|
const p = this.current.get(c);
|
|
861
773
|
return p ? p[0] !== d[0] || p[1] !== d[1] : !0;
|
|
862
774
|
}).map(([c]) => c);
|
|
863
775
|
if (l.length > 0)
|
|
864
|
-
for (const c of this.#
|
|
865
|
-
!(c.f & (
|
|
776
|
+
for (const c of this.#p)
|
|
777
|
+
!(c.f & (ne | he | qt)) && Qr(c, l, a) && (c.f & (nt | de) ? (C(c, k), h.schedule(c)) : h.#l.add(c));
|
|
866
778
|
if (h.#s.length > 0 && !h.#h) {
|
|
867
779
|
h.apply();
|
|
868
|
-
for (var f of h.#
|
|
869
|
-
h.#
|
|
870
|
-
h.#s = [];
|
|
780
|
+
for (var f of h.#y())
|
|
781
|
+
h.#g(f, [], []);
|
|
871
782
|
}
|
|
872
783
|
h.deactivate();
|
|
873
784
|
}
|
|
@@ -893,7 +804,7 @@ class Le {
|
|
|
893
804
|
let n = this.#n.get(r) ?? 0;
|
|
894
805
|
n === 1 ? this.#n.delete(r) : this.#n.set(r, n - 1);
|
|
895
806
|
}
|
|
896
|
-
this.#h || (this.#h = !0,
|
|
807
|
+
this.#h || (this.#h = !0, je(() => {
|
|
897
808
|
this.#h = !1, this.linked && this.flush();
|
|
898
809
|
}));
|
|
899
810
|
}
|
|
@@ -917,12 +828,12 @@ class Le {
|
|
|
917
828
|
this.#i.add(t);
|
|
918
829
|
}
|
|
919
830
|
settled() {
|
|
920
|
-
return (this.#o ??=
|
|
831
|
+
return (this.#o ??= Gn()).promise;
|
|
921
832
|
}
|
|
922
833
|
static ensure() {
|
|
923
834
|
if (A === null) {
|
|
924
835
|
const t = A = new Le();
|
|
925
|
-
!_r && !
|
|
836
|
+
!_r && !St && je(() => {
|
|
926
837
|
t.#e || t.flush();
|
|
927
838
|
});
|
|
928
839
|
}
|
|
@@ -939,33 +850,22 @@ class Le {
|
|
|
939
850
|
* @param {Effect} effect
|
|
940
851
|
*/
|
|
941
852
|
schedule(t) {
|
|
942
|
-
if (
|
|
853
|
+
if (Lr = t, t.b?.is_pending && t.f & (at | ir | jn) && !(t.f & Ye)) {
|
|
943
854
|
t.b.defer_effect(t);
|
|
944
855
|
return;
|
|
945
856
|
}
|
|
946
|
-
|
|
947
|
-
r = r.parent;
|
|
948
|
-
var n = r.f;
|
|
949
|
-
if (rt !== null && r === w && (S === null || !(S.f & z)))
|
|
950
|
-
return;
|
|
951
|
-
if (n & (Te | me)) {
|
|
952
|
-
if (!(n & V))
|
|
953
|
-
return;
|
|
954
|
-
r.f ^= V;
|
|
955
|
-
}
|
|
956
|
-
}
|
|
957
|
-
this.#s.push(r);
|
|
857
|
+
this.#s.push(t);
|
|
958
858
|
}
|
|
959
|
-
#
|
|
859
|
+
#v() {
|
|
960
860
|
if (this.linked) {
|
|
961
861
|
var t = this.#t, r = this.#r;
|
|
962
|
-
t === null ? vr = r : t.#r = r, r === null ?
|
|
862
|
+
t === null ? vr = r : t.#r = r, r === null ? Ke = t : r.#t = t, this.linked = !1;
|
|
963
863
|
}
|
|
964
864
|
}
|
|
965
865
|
}
|
|
966
866
|
function le(e) {
|
|
967
|
-
var t =
|
|
968
|
-
|
|
867
|
+
var t = St;
|
|
868
|
+
St = !0;
|
|
969
869
|
try {
|
|
970
870
|
for (var r; ; ) {
|
|
971
871
|
if (Is(), A === null)
|
|
@@ -976,33 +876,33 @@ function le(e) {
|
|
|
976
876
|
A.flush();
|
|
977
877
|
}
|
|
978
878
|
} finally {
|
|
979
|
-
|
|
879
|
+
St = t;
|
|
980
880
|
}
|
|
981
881
|
}
|
|
982
|
-
function
|
|
882
|
+
function js() {
|
|
983
883
|
try {
|
|
984
884
|
$s();
|
|
985
885
|
} catch (e) {
|
|
986
|
-
be(e,
|
|
886
|
+
be(e, Lr);
|
|
987
887
|
}
|
|
988
888
|
}
|
|
989
889
|
let $e = null;
|
|
990
|
-
function
|
|
890
|
+
function cn(e) {
|
|
991
891
|
var t = e.length;
|
|
992
892
|
if (t !== 0) {
|
|
993
893
|
for (var r = 0; r < t; ) {
|
|
994
894
|
var n = e[r++];
|
|
995
|
-
if (!(n.f & (
|
|
895
|
+
if (!(n.f & (ne | he)) && It(n) && ($e = /* @__PURE__ */ new Set(), ft(n), n.deps === null && n.first === null && n.nodes === null && n.teardown === null && n.ac === null && vi(n), $e?.size > 0)) {
|
|
996
896
|
xe.clear();
|
|
997
897
|
for (const i of $e) {
|
|
998
|
-
if (i.f & (
|
|
898
|
+
if (i.f & (ne | he)) continue;
|
|
999
899
|
const s = [i];
|
|
1000
|
-
let
|
|
1001
|
-
for (;
|
|
1002
|
-
$e.has(
|
|
1003
|
-
for (let
|
|
1004
|
-
const u = s[
|
|
1005
|
-
u.f & (
|
|
900
|
+
let o = i.parent;
|
|
901
|
+
for (; o !== null; )
|
|
902
|
+
$e.has(o) && ($e.delete(o), s.push(o)), o = o.parent;
|
|
903
|
+
for (let a = s.length - 1; a >= 0; a--) {
|
|
904
|
+
const u = s[a];
|
|
905
|
+
u.f & (ne | he) || ft(u);
|
|
1006
906
|
}
|
|
1007
907
|
}
|
|
1008
908
|
$e.clear();
|
|
@@ -1015,13 +915,13 @@ function ti(e, t, r, n) {
|
|
|
1015
915
|
if (!r.has(e) && (r.add(e), e.reactions !== null))
|
|
1016
916
|
for (const i of e.reactions) {
|
|
1017
917
|
const s = i.f;
|
|
1018
|
-
s &
|
|
918
|
+
s & q ? ti(
|
|
1019
919
|
/** @type {Derived} */
|
|
1020
920
|
i,
|
|
1021
921
|
t,
|
|
1022
922
|
r,
|
|
1023
923
|
n
|
|
1024
|
-
) : s & (
|
|
924
|
+
) : s & (nt | de) && !(s & k) && Qr(i, t, n) && (C(i, k), Kr(
|
|
1025
925
|
/** @type {Effect} */
|
|
1026
926
|
i
|
|
1027
927
|
));
|
|
@@ -1034,7 +934,7 @@ function Qr(e, t, r) {
|
|
|
1034
934
|
for (const i of e.deps) {
|
|
1035
935
|
if (Yt.call(t, i))
|
|
1036
936
|
return !0;
|
|
1037
|
-
if (i.f &
|
|
937
|
+
if (i.f & q && Qr(
|
|
1038
938
|
/** @type {Derived} */
|
|
1039
939
|
i,
|
|
1040
940
|
t,
|
|
@@ -1053,13 +953,13 @@ function Kr(e) {
|
|
|
1053
953
|
}
|
|
1054
954
|
function ri(e, t) {
|
|
1055
955
|
if (!(e.f & me && e.f & V)) {
|
|
1056
|
-
e.f &
|
|
956
|
+
e.f & k ? t.d.push(e) : e.f & fe && t.m.push(e), C(e, V);
|
|
1057
957
|
for (var r = e.first; r !== null; )
|
|
1058
958
|
ri(r, t), r = r.next;
|
|
1059
959
|
}
|
|
1060
960
|
}
|
|
1061
961
|
function ni(e) {
|
|
1062
|
-
|
|
962
|
+
C(e, V);
|
|
1063
963
|
for (var t = e.first; t !== null; )
|
|
1064
964
|
ni(t), t = t.next;
|
|
1065
965
|
}
|
|
@@ -1072,7 +972,7 @@ function Nt(e, t) {
|
|
|
1072
972
|
// TODO ideally we could skip this altogether, but it causes type errors
|
|
1073
973
|
v: e,
|
|
1074
974
|
reactions: null,
|
|
1075
|
-
equals:
|
|
975
|
+
equals: Xn,
|
|
1076
976
|
rv: 0,
|
|
1077
977
|
wv: 0
|
|
1078
978
|
};
|
|
@@ -1089,38 +989,39 @@ function si(e, t = !1, r = !0) {
|
|
|
1089
989
|
return t || (n.equals = ws), n;
|
|
1090
990
|
}
|
|
1091
991
|
function Y(e, t, r = !1) {
|
|
1092
|
-
|
|
992
|
+
T !== null && // since we are untracking the function inside `$inspect.with` we need to add this check
|
|
1093
993
|
// to ensure we error if state is set inside an inspect effect
|
|
1094
|
-
(!ve ||
|
|
1095
|
-
let n = r ?
|
|
994
|
+
(!ve || T.f & qt) && qn() && T.f & (q | de | nt | qt) && (we === null || !we.has(e)) && Ps();
|
|
995
|
+
let n = r ? wt(t) : t;
|
|
1096
996
|
return Kt(e, n, Ut);
|
|
1097
997
|
}
|
|
998
|
+
var Ue = null, Pr = 0;
|
|
1098
999
|
function Kt(e, t, r = null) {
|
|
1099
1000
|
if (!e.equals(t)) {
|
|
1100
1001
|
Me ? xe.set(e, t) : xe.has(e) || xe.set(e, e.v);
|
|
1101
1002
|
var n = Le.ensure();
|
|
1102
|
-
if (n.capture(e, t), e.f &
|
|
1003
|
+
if (n.capture(e, t), e.f & q) {
|
|
1103
1004
|
const i = (
|
|
1104
1005
|
/** @type {Derived} */
|
|
1105
1006
|
e
|
|
1106
1007
|
);
|
|
1107
|
-
e.f &
|
|
1008
|
+
e.f & k && Jr(i), pe === null && qr(i);
|
|
1108
1009
|
}
|
|
1109
|
-
e.wv = Ei(), ai(e,
|
|
1010
|
+
e.wv = Ei(), Ue = null, Pr = 0, ai(e, k, r), Ue = null, S !== null && S.f & V && !(S.f & (me | Te)) && (ue === null ? na([e]) : ue.push(e)), !n.is_fork && Qt.size > 0 && !ii && Vs();
|
|
1110
1011
|
}
|
|
1111
1012
|
return t;
|
|
1112
1013
|
}
|
|
1113
|
-
function
|
|
1014
|
+
function Vs() {
|
|
1114
1015
|
ii = !1;
|
|
1115
1016
|
for (const e of Qt) {
|
|
1116
|
-
e.f & V &&
|
|
1017
|
+
e.f & V && C(e, fe);
|
|
1117
1018
|
let t;
|
|
1118
1019
|
try {
|
|
1119
1020
|
t = It(e);
|
|
1120
1021
|
} catch {
|
|
1121
1022
|
t = !0;
|
|
1122
1023
|
}
|
|
1123
|
-
t &&
|
|
1024
|
+
t && ft(e);
|
|
1124
1025
|
}
|
|
1125
1026
|
Qt.clear();
|
|
1126
1027
|
}
|
|
@@ -1129,42 +1030,48 @@ function At(e) {
|
|
|
1129
1030
|
}
|
|
1130
1031
|
function ai(e, t, r) {
|
|
1131
1032
|
var n = e.reactions;
|
|
1132
|
-
if (n !== null)
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
if (
|
|
1033
|
+
if (n !== null) {
|
|
1034
|
+
var i = n.length;
|
|
1035
|
+
if (Pr += i, Pr > 1e5 && Ue === null && (Ue = /* @__PURE__ */ new Set()), Ue !== null) {
|
|
1036
|
+
if (Ue.has(e)) return;
|
|
1037
|
+
Ue.add(e);
|
|
1038
|
+
}
|
|
1039
|
+
for (var s = 0; s < i; s++) {
|
|
1040
|
+
var o = n[s], a = o.f, u = (a & k) === 0;
|
|
1041
|
+
if (u && C(o, t), a & qt)
|
|
1136
1042
|
Qt.add(
|
|
1137
1043
|
/** @type {Effect} */
|
|
1138
|
-
|
|
1044
|
+
o
|
|
1139
1045
|
);
|
|
1140
|
-
else if (
|
|
1046
|
+
else if (a & q) {
|
|
1141
1047
|
var l = (
|
|
1142
1048
|
/** @type {Derived} */
|
|
1143
|
-
|
|
1049
|
+
o
|
|
1144
1050
|
);
|
|
1145
|
-
pe?.delete(l),
|
|
1051
|
+
pe?.delete(l), ai(l, fe, r);
|
|
1146
1052
|
} else if (u) {
|
|
1147
1053
|
var f = (
|
|
1148
1054
|
/** @type {Effect} */
|
|
1149
|
-
|
|
1055
|
+
o
|
|
1150
1056
|
);
|
|
1151
|
-
|
|
1057
|
+
a & de && $e !== null && $e.add(f), r !== null ? r.push(f) : Kr(f);
|
|
1152
1058
|
}
|
|
1153
1059
|
}
|
|
1060
|
+
}
|
|
1154
1061
|
}
|
|
1155
|
-
function
|
|
1156
|
-
if (typeof e != "object" || e === null || pr in e ||
|
|
1062
|
+
function wt(e) {
|
|
1063
|
+
if (typeof e != "object" || e === null || pr in e || Vn in e)
|
|
1157
1064
|
return e;
|
|
1158
1065
|
const t = cs(e);
|
|
1159
1066
|
if (t !== fs && t !== hs)
|
|
1160
1067
|
return e;
|
|
1161
|
-
var r = /* @__PURE__ */ new Map(), n = os(e), i = /* @__PURE__ */ te(0), s =
|
|
1162
|
-
if (
|
|
1163
|
-
return
|
|
1164
|
-
var u =
|
|
1165
|
-
ce(null),
|
|
1166
|
-
var f =
|
|
1167
|
-
return ce(u),
|
|
1068
|
+
var r = /* @__PURE__ */ new Map(), n = os(e), i = /* @__PURE__ */ te(0), s = We, o = (a) => {
|
|
1069
|
+
if (We === s)
|
|
1070
|
+
return a();
|
|
1071
|
+
var u = T, l = We;
|
|
1072
|
+
ce(null), bn(s);
|
|
1073
|
+
var f = a();
|
|
1074
|
+
return ce(u), bn(l), f;
|
|
1168
1075
|
};
|
|
1169
1076
|
return n && r.set("length", /* @__PURE__ */ te(
|
|
1170
1077
|
/** @type {any[]} */
|
|
@@ -1173,62 +1080,64 @@ function Tt(e) {
|
|
|
1173
1080
|
/** @type {any} */
|
|
1174
1081
|
e,
|
|
1175
1082
|
{
|
|
1176
|
-
defineProperty(
|
|
1083
|
+
defineProperty(a, u, l) {
|
|
1177
1084
|
(!("value" in l) || l.configurable === !1 || l.enumerable === !1 || l.writable === !1) && Bs();
|
|
1178
1085
|
var f = r.get(u);
|
|
1179
|
-
return f === void 0 ?
|
|
1086
|
+
return f === void 0 ? o(() => {
|
|
1180
1087
|
var h = /* @__PURE__ */ te(l.value);
|
|
1181
1088
|
return r.set(u, h), h;
|
|
1182
1089
|
}) : Y(f, l.value, !0), !0;
|
|
1183
1090
|
},
|
|
1184
|
-
deleteProperty(
|
|
1091
|
+
deleteProperty(a, u) {
|
|
1185
1092
|
var l = r.get(u);
|
|
1186
1093
|
if (l === void 0) {
|
|
1187
|
-
if (u in
|
|
1188
|
-
const f =
|
|
1094
|
+
if (u in a) {
|
|
1095
|
+
const f = o(() => /* @__PURE__ */ te(j));
|
|
1189
1096
|
r.set(u, f), At(i);
|
|
1190
1097
|
}
|
|
1191
1098
|
} else
|
|
1192
1099
|
Y(l, j), At(i);
|
|
1193
1100
|
return !0;
|
|
1194
1101
|
},
|
|
1195
|
-
get(
|
|
1102
|
+
get(a, u, l) {
|
|
1196
1103
|
if (u === pr)
|
|
1197
1104
|
return e;
|
|
1198
|
-
var f = r.get(u), h = u in
|
|
1199
|
-
if (f === void 0 && (!h ||
|
|
1200
|
-
var d =
|
|
1105
|
+
var f = r.get(u), h = u in a;
|
|
1106
|
+
if (f === void 0 && (!h || rt(a, u)?.writable) && (f = o(() => {
|
|
1107
|
+
var d = wt(h ? a[u] : j), p = /* @__PURE__ */ te(d);
|
|
1201
1108
|
return p;
|
|
1202
1109
|
}), r.set(u, f)), f !== void 0) {
|
|
1203
1110
|
var c = $(f);
|
|
1204
1111
|
return c === j ? void 0 : c;
|
|
1205
1112
|
}
|
|
1206
|
-
return Reflect.get(
|
|
1113
|
+
return Reflect.get(a, u, l);
|
|
1207
1114
|
},
|
|
1208
|
-
getOwnPropertyDescriptor(
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
if (
|
|
1115
|
+
getOwnPropertyDescriptor(a, u) {
|
|
1116
|
+
this.has?.(a, u);
|
|
1117
|
+
var l = Reflect.getOwnPropertyDescriptor(a, u), f = r.get(u);
|
|
1118
|
+
if (f !== void 0) {
|
|
1119
|
+
var h = $(f);
|
|
1120
|
+
if (h === j)
|
|
1121
|
+
return;
|
|
1122
|
+
if (l && "value" in l)
|
|
1123
|
+
l.value = h;
|
|
1124
|
+
else
|
|
1216
1125
|
return {
|
|
1217
1126
|
enumerable: !0,
|
|
1218
1127
|
configurable: !0,
|
|
1219
|
-
value:
|
|
1128
|
+
value: h,
|
|
1220
1129
|
writable: !0
|
|
1221
1130
|
};
|
|
1222
1131
|
}
|
|
1223
1132
|
return l;
|
|
1224
1133
|
},
|
|
1225
|
-
has(
|
|
1134
|
+
has(a, u) {
|
|
1226
1135
|
if (u === pr)
|
|
1227
1136
|
return !0;
|
|
1228
|
-
var l = r.get(u), f = l !== void 0 && l.v !== j || Reflect.has(
|
|
1229
|
-
if (l !== void 0 ||
|
|
1230
|
-
l === void 0 && (l =
|
|
1231
|
-
var c = f ?
|
|
1137
|
+
var l = r.get(u), f = l !== void 0 && l.v !== j || Reflect.has(a, u);
|
|
1138
|
+
if (l !== void 0 || S !== null && (!f || rt(a, u)?.writable)) {
|
|
1139
|
+
l === void 0 && (l = o(() => {
|
|
1140
|
+
var c = f ? wt(a[u]) : j, d = /* @__PURE__ */ te(c);
|
|
1232
1141
|
return d;
|
|
1233
1142
|
}), r.set(u, l));
|
|
1234
1143
|
var h = $(l);
|
|
@@ -1237,22 +1146,22 @@ function Tt(e) {
|
|
|
1237
1146
|
}
|
|
1238
1147
|
return f;
|
|
1239
1148
|
},
|
|
1240
|
-
set(
|
|
1241
|
-
var h = r.get(u), c = u in
|
|
1149
|
+
set(a, u, l, f) {
|
|
1150
|
+
var h = r.get(u), c = u in a;
|
|
1242
1151
|
if (n && u === "length")
|
|
1243
1152
|
for (var d = l; d < /** @type {Source<number>} */
|
|
1244
1153
|
h.v; d += 1) {
|
|
1245
1154
|
var p = r.get(d + "");
|
|
1246
|
-
p !== void 0 ? Y(p, j) : d in
|
|
1155
|
+
p !== void 0 ? Y(p, j) : d in a && (p = o(() => /* @__PURE__ */ te(j)), r.set(d + "", p));
|
|
1247
1156
|
}
|
|
1248
1157
|
if (h === void 0)
|
|
1249
|
-
(!c ||
|
|
1158
|
+
(!c || rt(a, u)?.writable) && (h = o(() => /* @__PURE__ */ te(void 0)), Y(h, wt(l)), r.set(u, h));
|
|
1250
1159
|
else {
|
|
1251
1160
|
c = h.v !== j;
|
|
1252
|
-
var b =
|
|
1161
|
+
var b = o(() => wt(l));
|
|
1253
1162
|
Y(h, b);
|
|
1254
1163
|
}
|
|
1255
|
-
var N = Reflect.getOwnPropertyDescriptor(
|
|
1164
|
+
var N = Reflect.getOwnPropertyDescriptor(a, u);
|
|
1256
1165
|
if (N?.set && N.set.call(f, l), !c) {
|
|
1257
1166
|
if (n && typeof u == "string") {
|
|
1258
1167
|
var G = (
|
|
@@ -1265,14 +1174,14 @@ function Tt(e) {
|
|
|
1265
1174
|
}
|
|
1266
1175
|
return !0;
|
|
1267
1176
|
},
|
|
1268
|
-
ownKeys(
|
|
1177
|
+
ownKeys(a) {
|
|
1269
1178
|
$(i);
|
|
1270
|
-
var u = Reflect.ownKeys(
|
|
1179
|
+
var u = Reflect.ownKeys(a).filter((h) => {
|
|
1271
1180
|
var c = r.get(h);
|
|
1272
1181
|
return c === void 0 || c.v !== j;
|
|
1273
1182
|
});
|
|
1274
1183
|
for (var [l, f] of r)
|
|
1275
|
-
f.v !== j && !(l in
|
|
1184
|
+
f.v !== j && !(l in a) && u.push(l);
|
|
1276
1185
|
return u;
|
|
1277
1186
|
},
|
|
1278
1187
|
setPrototypeOf() {
|
|
@@ -1281,19 +1190,19 @@ function Tt(e) {
|
|
|
1281
1190
|
}
|
|
1282
1191
|
);
|
|
1283
1192
|
}
|
|
1284
|
-
var
|
|
1193
|
+
var dn, oi, ui, li;
|
|
1285
1194
|
function Mr() {
|
|
1286
|
-
if (
|
|
1287
|
-
|
|
1195
|
+
if (dn === void 0) {
|
|
1196
|
+
dn = window, oi = /Firefox/.test(navigator.userAgent);
|
|
1288
1197
|
var e = Element.prototype, t = Node.prototype, r = Text.prototype;
|
|
1289
|
-
ui =
|
|
1198
|
+
ui = rt(t, "firstChild").get, li = rt(t, "nextSibling").get, fn(e) && (e[ms] = void 0, e[_s] = null, e[gs] = void 0, e.__e = void 0), fn(r) && (r[Or] = void 0);
|
|
1290
1199
|
}
|
|
1291
1200
|
}
|
|
1292
1201
|
function Pe(e = "") {
|
|
1293
1202
|
return document.createTextNode(e);
|
|
1294
1203
|
}
|
|
1295
1204
|
// @__NO_SIDE_EFFECTS__
|
|
1296
|
-
function
|
|
1205
|
+
function lt(e) {
|
|
1297
1206
|
return (
|
|
1298
1207
|
/** @type {TemplateNode | null} */
|
|
1299
1208
|
ui.call(e)
|
|
@@ -1307,9 +1216,9 @@ function Ne(e) {
|
|
|
1307
1216
|
);
|
|
1308
1217
|
}
|
|
1309
1218
|
function Gt(e, t) {
|
|
1310
|
-
if (!
|
|
1311
|
-
return /* @__PURE__ */
|
|
1312
|
-
var r = /* @__PURE__ */
|
|
1219
|
+
if (!F)
|
|
1220
|
+
return /* @__PURE__ */ lt(e);
|
|
1221
|
+
var r = /* @__PURE__ */ lt(L);
|
|
1313
1222
|
if (r === null)
|
|
1314
1223
|
r = L.appendChild(Pe());
|
|
1315
1224
|
else if (t && r.nodeType !== sr) {
|
|
@@ -1321,9 +1230,9 @@ function Gt(e, t) {
|
|
|
1321
1230
|
r
|
|
1322
1231
|
), ge(r), r;
|
|
1323
1232
|
}
|
|
1324
|
-
function
|
|
1325
|
-
if (!
|
|
1326
|
-
var r = /* @__PURE__ */
|
|
1233
|
+
function Ws(e, t = !1) {
|
|
1234
|
+
if (!F) {
|
|
1235
|
+
var r = /* @__PURE__ */ lt(e);
|
|
1327
1236
|
return r instanceof Comment && r.data === "" ? /* @__PURE__ */ Ne(r) : r;
|
|
1328
1237
|
}
|
|
1329
1238
|
if (t) {
|
|
@@ -1339,17 +1248,17 @@ function qs(e, t = !1) {
|
|
|
1339
1248
|
return L;
|
|
1340
1249
|
}
|
|
1341
1250
|
function mr(e, t = !1) {
|
|
1342
|
-
if (!
|
|
1343
|
-
return /* @__PURE__ */
|
|
1251
|
+
if (!F)
|
|
1252
|
+
return /* @__PURE__ */ lt(e);
|
|
1344
1253
|
var r = Gt(e, t);
|
|
1345
1254
|
return Ft(e), r;
|
|
1346
1255
|
}
|
|
1347
|
-
function
|
|
1348
|
-
let n =
|
|
1256
|
+
function pn(e, t = 1, r = !1) {
|
|
1257
|
+
let n = F ? L : e;
|
|
1349
1258
|
for (var i; t--; )
|
|
1350
1259
|
i = n, n = /** @type {TemplateNode} */
|
|
1351
1260
|
/* @__PURE__ */ Ne(n);
|
|
1352
|
-
if (!
|
|
1261
|
+
if (!F)
|
|
1353
1262
|
return n;
|
|
1354
1263
|
if (r) {
|
|
1355
1264
|
if (n?.nodeType !== sr) {
|
|
@@ -1363,10 +1272,10 @@ function dn(e, t = 1, r = !1) {
|
|
|
1363
1272
|
}
|
|
1364
1273
|
return ge(n), n;
|
|
1365
1274
|
}
|
|
1366
|
-
function
|
|
1275
|
+
function Xs(e) {
|
|
1367
1276
|
e.textContent = "";
|
|
1368
1277
|
}
|
|
1369
|
-
function
|
|
1278
|
+
function Ys() {
|
|
1370
1279
|
return !1;
|
|
1371
1280
|
}
|
|
1372
1281
|
function en(e, t, r) {
|
|
@@ -1386,18 +1295,18 @@ function tn(e) {
|
|
|
1386
1295
|
t.remove(), e.nodeValue += /** @type {string} */
|
|
1387
1296
|
t.nodeValue, t = e.nextSibling;
|
|
1388
1297
|
}
|
|
1389
|
-
function
|
|
1390
|
-
var t =
|
|
1298
|
+
function zs(e) {
|
|
1299
|
+
var t = S;
|
|
1391
1300
|
if (t === null)
|
|
1392
|
-
return
|
|
1393
|
-
if (!(t.f & Ye) && !(t.f &
|
|
1301
|
+
return T.f |= Re, e;
|
|
1302
|
+
if (!(t.f & Ye) && !(t.f & at))
|
|
1394
1303
|
throw e;
|
|
1395
1304
|
be(e, t);
|
|
1396
1305
|
}
|
|
1397
1306
|
function be(e, t) {
|
|
1398
|
-
if (!(t !== null && t.f &
|
|
1307
|
+
if (!(t !== null && t.f & ne)) {
|
|
1399
1308
|
for (; t !== null; ) {
|
|
1400
|
-
if (t.f & Ar && !(t.f & (
|
|
1309
|
+
if (t.f & Ar && !(t.f & (ne | $r))) {
|
|
1401
1310
|
if (!(t.f & Ye))
|
|
1402
1311
|
throw e;
|
|
1403
1312
|
try {
|
|
@@ -1412,21 +1321,21 @@ function be(e, t) {
|
|
|
1412
1321
|
throw e;
|
|
1413
1322
|
}
|
|
1414
1323
|
}
|
|
1415
|
-
function
|
|
1416
|
-
|
|
1324
|
+
function qs(e) {
|
|
1325
|
+
S === null && (T === null && As(), Hs()), Me && Ss();
|
|
1417
1326
|
}
|
|
1418
|
-
function
|
|
1327
|
+
function Zs(e, t) {
|
|
1419
1328
|
var r = t.last;
|
|
1420
1329
|
r === null ? t.last = t.first = e : (r.next = e, e.prev = r, t.last = e);
|
|
1421
1330
|
}
|
|
1422
1331
|
function He(e, t) {
|
|
1423
|
-
var r =
|
|
1332
|
+
var r = S;
|
|
1424
1333
|
r !== null && r.f & he && (e |= he);
|
|
1425
1334
|
var n = {
|
|
1426
|
-
ctx:
|
|
1335
|
+
ctx: ie,
|
|
1427
1336
|
deps: null,
|
|
1428
1337
|
nodes: null,
|
|
1429
|
-
f: e |
|
|
1338
|
+
f: e | k | _e,
|
|
1430
1339
|
first: null,
|
|
1431
1340
|
fn: t,
|
|
1432
1341
|
last: null,
|
|
@@ -1440,78 +1349,78 @@ function He(e, t) {
|
|
|
1440
1349
|
};
|
|
1441
1350
|
A?.register_created_effect(n);
|
|
1442
1351
|
var i = n;
|
|
1443
|
-
if (e &
|
|
1444
|
-
|
|
1352
|
+
if (e & at)
|
|
1353
|
+
Ht !== null ? Ht.push(n) : Le.ensure().schedule(n);
|
|
1445
1354
|
else if (t !== null) {
|
|
1446
1355
|
try {
|
|
1447
|
-
|
|
1448
|
-
} catch (
|
|
1449
|
-
throw
|
|
1356
|
+
ft(n);
|
|
1357
|
+
} catch (o) {
|
|
1358
|
+
throw se(n), o;
|
|
1450
1359
|
}
|
|
1451
1360
|
i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && // either `null`, or a singular child
|
|
1452
|
-
!(i.f & ze) && (i = i.first, e & de && e &
|
|
1361
|
+
!(i.f & ze) && (i = i.first, e & de && e & ot && i !== null && (i.f |= ot));
|
|
1453
1362
|
}
|
|
1454
|
-
if (i !== null && (i.parent = r, r !== null &&
|
|
1363
|
+
if (i !== null && (i.parent = r, r !== null && Zs(i, r), T !== null && T.f & q && !(e & Te))) {
|
|
1455
1364
|
var s = (
|
|
1456
1365
|
/** @type {Derived} */
|
|
1457
|
-
|
|
1366
|
+
T
|
|
1458
1367
|
);
|
|
1459
1368
|
(s.effects ??= []).push(i);
|
|
1460
1369
|
}
|
|
1461
1370
|
return n;
|
|
1462
1371
|
}
|
|
1463
1372
|
function rn() {
|
|
1464
|
-
return
|
|
1373
|
+
return T !== null && !ve;
|
|
1465
1374
|
}
|
|
1466
1375
|
function fi(e) {
|
|
1467
1376
|
const t = He(ir, null);
|
|
1468
|
-
return
|
|
1377
|
+
return C(t, V), t.teardown = e, t;
|
|
1469
1378
|
}
|
|
1470
|
-
function
|
|
1471
|
-
|
|
1379
|
+
function vn(e) {
|
|
1380
|
+
qs();
|
|
1472
1381
|
var t = (
|
|
1473
1382
|
/** @type {Effect} */
|
|
1474
|
-
|
|
1475
|
-
), r = !
|
|
1383
|
+
S.f
|
|
1384
|
+
), r = !T && (t & me) !== 0 && ie !== null && !ie.i;
|
|
1476
1385
|
if (r) {
|
|
1477
1386
|
var n = (
|
|
1478
1387
|
/** @type {ComponentContext} */
|
|
1479
|
-
|
|
1388
|
+
ie
|
|
1480
1389
|
);
|
|
1481
1390
|
(n.e ??= []).push(e);
|
|
1482
1391
|
} else
|
|
1483
1392
|
return hi(e);
|
|
1484
1393
|
}
|
|
1485
1394
|
function hi(e) {
|
|
1486
|
-
return He(
|
|
1395
|
+
return He(at | ps, e);
|
|
1487
1396
|
}
|
|
1488
|
-
function
|
|
1397
|
+
function Js(e) {
|
|
1489
1398
|
Le.ensure();
|
|
1490
1399
|
const t = He(Te | ze, e);
|
|
1491
1400
|
return () => {
|
|
1492
|
-
|
|
1401
|
+
se(t);
|
|
1493
1402
|
};
|
|
1494
1403
|
}
|
|
1495
|
-
function
|
|
1404
|
+
function Qs(e) {
|
|
1496
1405
|
Le.ensure();
|
|
1497
1406
|
const t = He(Te | ze, e);
|
|
1498
1407
|
return (r = {}) => new Promise((n) => {
|
|
1499
1408
|
r.outro ? $t(t, () => {
|
|
1500
|
-
|
|
1501
|
-
}) : (
|
|
1409
|
+
se(t), n(void 0);
|
|
1410
|
+
}) : (se(t), n(void 0));
|
|
1502
1411
|
});
|
|
1503
1412
|
}
|
|
1504
|
-
function
|
|
1505
|
-
return He(
|
|
1413
|
+
function Ks(e) {
|
|
1414
|
+
return He(at, e);
|
|
1506
1415
|
}
|
|
1507
|
-
function
|
|
1508
|
-
return He(
|
|
1416
|
+
function ea(e) {
|
|
1417
|
+
return He(nt | ze, e);
|
|
1509
1418
|
}
|
|
1510
1419
|
function ci(e, t = 0) {
|
|
1511
1420
|
return He(ir | t, e);
|
|
1512
1421
|
}
|
|
1513
|
-
function
|
|
1514
|
-
|
|
1422
|
+
function _n(e, t = [], r = [], n = []) {
|
|
1423
|
+
Rs(n, t, r, (i) => {
|
|
1515
1424
|
He(ir, () => {
|
|
1516
1425
|
e(...i.map($));
|
|
1517
1426
|
});
|
|
@@ -1527,14 +1436,14 @@ function Oe(e) {
|
|
|
1527
1436
|
function pi(e) {
|
|
1528
1437
|
var t = e.teardown;
|
|
1529
1438
|
if (t !== null) {
|
|
1530
|
-
const r = Me, n =
|
|
1531
|
-
|
|
1439
|
+
const r = Me, n = T;
|
|
1440
|
+
gn(!0), ce(null);
|
|
1532
1441
|
try {
|
|
1533
1442
|
t.call(null);
|
|
1534
1443
|
} catch (i) {
|
|
1535
1444
|
be(i, e.parent);
|
|
1536
1445
|
} finally {
|
|
1537
|
-
|
|
1446
|
+
gn(r), ce(n);
|
|
1538
1447
|
}
|
|
1539
1448
|
}
|
|
1540
1449
|
}
|
|
@@ -1542,22 +1451,22 @@ function nn(e, t = !1) {
|
|
|
1542
1451
|
var r = e.first;
|
|
1543
1452
|
for (e.first = e.last = null; r !== null; ) {
|
|
1544
1453
|
const i = r.ac;
|
|
1545
|
-
i !== null &&
|
|
1454
|
+
i !== null && ur(() => {
|
|
1546
1455
|
i.abort(Mt);
|
|
1547
1456
|
});
|
|
1548
1457
|
var n = r.next;
|
|
1549
|
-
r.f & Te ? r.parent = null :
|
|
1458
|
+
r.f & Te ? r.parent = null : se(r, t), r = n;
|
|
1550
1459
|
}
|
|
1551
1460
|
}
|
|
1552
|
-
function
|
|
1461
|
+
function ta(e) {
|
|
1553
1462
|
for (var t = e.first; t !== null; ) {
|
|
1554
1463
|
var r = t.next;
|
|
1555
|
-
t.f & me ||
|
|
1464
|
+
t.f & me || se(t), t = r;
|
|
1556
1465
|
}
|
|
1557
1466
|
}
|
|
1558
|
-
function
|
|
1467
|
+
function se(e, t = !0) {
|
|
1559
1468
|
var r = !1;
|
|
1560
|
-
(t || e.f & ds) && e.nodes !== null && e.nodes.end !== null && (
|
|
1469
|
+
(t || e.f & ds) && e.nodes !== null && e.nodes.end !== null && (ra(
|
|
1561
1470
|
e.nodes.start,
|
|
1562
1471
|
/** @type {TemplateNode} */
|
|
1563
1472
|
e.nodes.end
|
|
@@ -1566,11 +1475,11 @@ function ie(e, t = !0) {
|
|
|
1566
1475
|
if (n !== null)
|
|
1567
1476
|
for (const s of n)
|
|
1568
1477
|
s.stop();
|
|
1569
|
-
pi(e), e.f ^= $r, e.f |=
|
|
1478
|
+
pi(e), e.f ^= $r, e.f |= ne;
|
|
1570
1479
|
var i = e.parent;
|
|
1571
1480
|
i !== null && i.first !== null && vi(e), e.next = e.prev = e.teardown = e.ctx = e.deps = e.fn = e.nodes = e.ac = e.b = null;
|
|
1572
1481
|
}
|
|
1573
|
-
function
|
|
1482
|
+
function ra(e, t) {
|
|
1574
1483
|
for (; e !== null; ) {
|
|
1575
1484
|
var r = e === t ? null : /* @__PURE__ */ Ne(e);
|
|
1576
1485
|
e.remove(), e = r;
|
|
@@ -1582,14 +1491,14 @@ function vi(e) {
|
|
|
1582
1491
|
}
|
|
1583
1492
|
function $t(e, t, r = !0) {
|
|
1584
1493
|
var n = [];
|
|
1585
|
-
e.f |=
|
|
1494
|
+
e.f |= Wr, _i(e, n, !0);
|
|
1586
1495
|
var i = () => {
|
|
1587
|
-
r &&
|
|
1496
|
+
r && se(e), t && t();
|
|
1588
1497
|
}, s = n.length;
|
|
1589
1498
|
if (s > 0) {
|
|
1590
|
-
var
|
|
1591
|
-
for (var
|
|
1592
|
-
|
|
1499
|
+
var o = () => --s || i();
|
|
1500
|
+
for (var a of n)
|
|
1501
|
+
a.out(o);
|
|
1593
1502
|
} else
|
|
1594
1503
|
i();
|
|
1595
1504
|
}
|
|
@@ -1598,35 +1507,35 @@ function _i(e, t, r) {
|
|
|
1598
1507
|
e.f ^= he;
|
|
1599
1508
|
var n = e.nodes && e.nodes.t;
|
|
1600
1509
|
if (n !== null)
|
|
1601
|
-
for (const
|
|
1602
|
-
(
|
|
1510
|
+
for (const a of n)
|
|
1511
|
+
(a.is_global || r) && t.push(a);
|
|
1603
1512
|
for (var i = e.first; i !== null; ) {
|
|
1604
1513
|
var s = i.next;
|
|
1605
1514
|
if (!(i.f & Te)) {
|
|
1606
|
-
var
|
|
1515
|
+
var o = (i.f & ot) !== 0 || // If this is a branch effect without a block effect parent,
|
|
1607
1516
|
// it means the parent block effect was pruned. In that case,
|
|
1608
1517
|
// transparency information was transferred to the branch effect.
|
|
1609
1518
|
(i.f & me) !== 0 && (e.f & de) !== 0;
|
|
1610
|
-
_i(i, t,
|
|
1519
|
+
_i(i, t, o ? r : !1);
|
|
1611
1520
|
}
|
|
1612
1521
|
i = s;
|
|
1613
1522
|
}
|
|
1614
1523
|
}
|
|
1615
1524
|
}
|
|
1616
|
-
function
|
|
1617
|
-
e.f &= ~
|
|
1525
|
+
function mn(e) {
|
|
1526
|
+
e.f &= ~Wr, mi(e, !0);
|
|
1618
1527
|
}
|
|
1619
1528
|
function mi(e, t) {
|
|
1620
|
-
if (!(e.f &
|
|
1621
|
-
e.f ^= he, e.f & V || (
|
|
1529
|
+
if (!(e.f & Wr) && e.f & he) {
|
|
1530
|
+
e.f ^= he, e.f & V || (C(e, k), Le.ensure().schedule(e));
|
|
1622
1531
|
for (var r = e.first; r !== null; ) {
|
|
1623
|
-
var n = r.next, i = (r.f &
|
|
1532
|
+
var n = r.next, i = (r.f & ot) !== 0 || (r.f & me) !== 0;
|
|
1624
1533
|
mi(r, i ? t : !1), r = n;
|
|
1625
1534
|
}
|
|
1626
1535
|
var s = e.nodes && e.nodes.t;
|
|
1627
1536
|
if (s !== null)
|
|
1628
|
-
for (const
|
|
1629
|
-
(
|
|
1537
|
+
for (const o of s)
|
|
1538
|
+
(o.is_global || t) && o.in();
|
|
1630
1539
|
}
|
|
1631
1540
|
}
|
|
1632
1541
|
function gi(e, t) {
|
|
@@ -1637,37 +1546,37 @@ function gi(e, t) {
|
|
|
1637
1546
|
}
|
|
1638
1547
|
}
|
|
1639
1548
|
let jt = !1, Me = !1;
|
|
1640
|
-
function
|
|
1549
|
+
function gn(e) {
|
|
1641
1550
|
Me = e;
|
|
1642
1551
|
}
|
|
1643
|
-
let
|
|
1552
|
+
let T = null, ve = !1;
|
|
1644
1553
|
function ce(e) {
|
|
1645
|
-
|
|
1554
|
+
T = e;
|
|
1646
1555
|
}
|
|
1647
|
-
let
|
|
1556
|
+
let S = null;
|
|
1648
1557
|
function Se(e) {
|
|
1649
|
-
|
|
1558
|
+
S = e;
|
|
1650
1559
|
}
|
|
1651
1560
|
let we = null;
|
|
1652
1561
|
function bi(e) {
|
|
1653
|
-
|
|
1562
|
+
T !== null && (T.f & Zt || T.f & q) && (we ??= /* @__PURE__ */ new Set()).add(e);
|
|
1654
1563
|
}
|
|
1655
|
-
let re = null,
|
|
1656
|
-
function
|
|
1564
|
+
let re = null, ae = 0, ue = null;
|
|
1565
|
+
function na(e) {
|
|
1657
1566
|
ue = e;
|
|
1658
1567
|
}
|
|
1659
|
-
let yi = 1,
|
|
1660
|
-
function
|
|
1661
|
-
|
|
1568
|
+
let yi = 1, Ve = 0, We = Ve;
|
|
1569
|
+
function bn(e) {
|
|
1570
|
+
We = e;
|
|
1662
1571
|
}
|
|
1663
1572
|
function Ei() {
|
|
1664
1573
|
return ++yi;
|
|
1665
1574
|
}
|
|
1666
1575
|
function It(e) {
|
|
1667
1576
|
var t = e.f;
|
|
1668
|
-
if (t &
|
|
1577
|
+
if (t & k)
|
|
1669
1578
|
return !0;
|
|
1670
|
-
if (t &
|
|
1579
|
+
if (t & fe) {
|
|
1671
1580
|
for (var r = (
|
|
1672
1581
|
/** @type {Value[]} */
|
|
1673
1582
|
e.deps
|
|
@@ -1682,9 +1591,9 @@ function It(e) {
|
|
|
1682
1591
|
), s.wv > e.wv)
|
|
1683
1592
|
return !0;
|
|
1684
1593
|
}
|
|
1685
|
-
t &
|
|
1594
|
+
t & _e && // During time traveling we don't want to reset the status so that
|
|
1686
1595
|
// traversal of the graph in the other batches still happens
|
|
1687
|
-
pe === null &&
|
|
1596
|
+
pe === null && C(e, V);
|
|
1688
1597
|
}
|
|
1689
1598
|
return !1;
|
|
1690
1599
|
}
|
|
@@ -1693,21 +1602,21 @@ function xi(e, t, r = !0) {
|
|
|
1693
1602
|
if (n !== null && !(we !== null && we.has(e)))
|
|
1694
1603
|
for (var i = 0; i < n.length; i++) {
|
|
1695
1604
|
var s = n[i];
|
|
1696
|
-
s.f &
|
|
1605
|
+
s.f & q ? xi(
|
|
1697
1606
|
/** @type {Derived} */
|
|
1698
1607
|
s,
|
|
1699
1608
|
t,
|
|
1700
1609
|
!1
|
|
1701
|
-
) : t === s && (r ?
|
|
1610
|
+
) : t === s && (r ? C(s, k) : s.f & V && C(s, fe), Kr(
|
|
1702
1611
|
/** @type {Effect} */
|
|
1703
1612
|
s
|
|
1704
1613
|
));
|
|
1705
1614
|
}
|
|
1706
1615
|
}
|
|
1707
1616
|
function wi(e) {
|
|
1708
|
-
var t = re, r =
|
|
1617
|
+
var t = re, r = ae, n = ue, i = T, s = we, o = ie, a = ve, u = We, l = e.f;
|
|
1709
1618
|
re = /** @type {null | Value[]} */
|
|
1710
|
-
null,
|
|
1619
|
+
null, ae = 0, ue = null, T = l & (me | Te) ? null : e, we = null, ut(e.ctx), ve = !1, We = ++Ve, e.ac !== null && (ur(() => {
|
|
1711
1620
|
e.ac.abort(Mt);
|
|
1712
1621
|
}), e.ac = null);
|
|
1713
1622
|
try {
|
|
@@ -1717,8 +1626,8 @@ function wi(e) {
|
|
|
1717
1626
|
e.fn
|
|
1718
1627
|
), h = f();
|
|
1719
1628
|
e.f |= Ye;
|
|
1720
|
-
var c =
|
|
1721
|
-
if (
|
|
1629
|
+
var c = yn(e);
|
|
1630
|
+
if (qn() && ue !== null && !ve && c !== null && !(e.f & (q | fe | k)))
|
|
1722
1631
|
for (var d = 0; d < /** @type {Source[]} */
|
|
1723
1632
|
ue.length; d++)
|
|
1724
1633
|
xi(
|
|
@@ -1727,38 +1636,38 @@ function wi(e) {
|
|
|
1727
1636
|
e
|
|
1728
1637
|
);
|
|
1729
1638
|
if (i !== null && i !== e) {
|
|
1730
|
-
if (
|
|
1639
|
+
if (Ve++, i.deps !== null)
|
|
1731
1640
|
for (let p = 0; p < r; p += 1)
|
|
1732
|
-
i.deps[p].rv =
|
|
1641
|
+
i.deps[p].rv = Ve;
|
|
1733
1642
|
if (t !== null)
|
|
1734
1643
|
for (const p of t)
|
|
1735
|
-
p.rv =
|
|
1644
|
+
p.rv = Ve;
|
|
1736
1645
|
ue !== null && (n === null ? n = ue : n.push(.../** @type {Source[]} */
|
|
1737
1646
|
ue));
|
|
1738
1647
|
}
|
|
1739
|
-
return e.f &
|
|
1648
|
+
return e.f & Re && (e.f ^= Re), h;
|
|
1740
1649
|
} catch (p) {
|
|
1741
|
-
return
|
|
1650
|
+
return yn(e), zs(p);
|
|
1742
1651
|
} finally {
|
|
1743
|
-
e.f ^= Zt, re = t,
|
|
1652
|
+
e.f ^= Zt, re = t, ae = r, ue = n, T = i, we = s, ut(o), ve = a, We = u;
|
|
1744
1653
|
}
|
|
1745
1654
|
}
|
|
1746
|
-
function
|
|
1655
|
+
function yn(e) {
|
|
1747
1656
|
var t = e.deps, r = A?.is_fork;
|
|
1748
1657
|
if (re !== null) {
|
|
1749
1658
|
var n;
|
|
1750
|
-
if (r || Ot(e,
|
|
1751
|
-
for (t.length =
|
|
1752
|
-
t[
|
|
1659
|
+
if (r || Ot(e, ae), t !== null && ae > 0)
|
|
1660
|
+
for (t.length = ae + re.length, n = 0; n < re.length; n++)
|
|
1661
|
+
t[ae + n] = re[n];
|
|
1753
1662
|
else
|
|
1754
1663
|
e.deps = t = re;
|
|
1755
|
-
if (rn() && e.f &
|
|
1756
|
-
for (n =
|
|
1664
|
+
if (rn() && e.f & _e)
|
|
1665
|
+
for (n = ae; n < t.length; n++)
|
|
1757
1666
|
(t[n].reactions ??= []).push(e);
|
|
1758
|
-
} else !r && t !== null &&
|
|
1667
|
+
} else !r && t !== null && ae < t.length && (Ot(e, ae), t.length = ae);
|
|
1759
1668
|
return t;
|
|
1760
1669
|
}
|
|
1761
|
-
function
|
|
1670
|
+
function ia(e, t) {
|
|
1762
1671
|
let r = t.reactions;
|
|
1763
1672
|
if (r !== null) {
|
|
1764
1673
|
var n = us.call(r, e);
|
|
@@ -1767,7 +1676,7 @@ function ua(e, t) {
|
|
|
1767
1676
|
i === 0 ? r = t.reactions = null : (r[n] = r[i], r.pop());
|
|
1768
1677
|
}
|
|
1769
1678
|
}
|
|
1770
|
-
if (r === null && t.f &
|
|
1679
|
+
if (r === null && t.f & q && // Destroying a child effect while updating a parent effect can cause a dependency to appear
|
|
1771
1680
|
// to be unused, when in fact it is used by the currently-updating parent. Checking `new_deps`
|
|
1772
1681
|
// allows us to skip the expensive work of disconnecting and immediately reconnecting it
|
|
1773
1682
|
(re === null || !Yt.call(re, t))) {
|
|
@@ -1775,76 +1684,76 @@ function ua(e, t) {
|
|
|
1775
1684
|
/** @type {Derived} */
|
|
1776
1685
|
t
|
|
1777
1686
|
);
|
|
1778
|
-
s.f &
|
|
1779
|
-
s.ac.abort(Mt), s.ac = null,
|
|
1780
|
-
}),
|
|
1687
|
+
s.f & _e && (s.f ^= _e), s.v !== j && qr(s), s.ac !== null && ur(() => {
|
|
1688
|
+
s.ac.abort(Mt), s.ac = null, C(s, k);
|
|
1689
|
+
}), Us(s), Ot(s, 0);
|
|
1781
1690
|
}
|
|
1782
1691
|
}
|
|
1783
1692
|
function Ot(e, t) {
|
|
1784
1693
|
var r = e.deps;
|
|
1785
1694
|
if (r !== null)
|
|
1786
1695
|
for (var n = t; n < r.length; n++)
|
|
1787
|
-
|
|
1696
|
+
ia(e, r[n]);
|
|
1788
1697
|
}
|
|
1789
|
-
function
|
|
1698
|
+
function ft(e) {
|
|
1790
1699
|
var t = e.f;
|
|
1791
|
-
if (!(t &
|
|
1792
|
-
|
|
1793
|
-
var r =
|
|
1794
|
-
|
|
1700
|
+
if (!(t & ne)) {
|
|
1701
|
+
C(e, V);
|
|
1702
|
+
var r = S, n = jt;
|
|
1703
|
+
S = e, jt = (t & (me | Te)) === 0;
|
|
1795
1704
|
try {
|
|
1796
|
-
t & (de |
|
|
1705
|
+
t & (de | jn) ? ta(e) : nn(e), pi(e);
|
|
1797
1706
|
var i = wi(e);
|
|
1798
1707
|
e.teardown = typeof i == "function" ? i : null, e.wv = yi;
|
|
1799
1708
|
var s;
|
|
1800
|
-
|
|
1709
|
+
Fn && Ns && e.f & k && e.deps;
|
|
1801
1710
|
} finally {
|
|
1802
|
-
jt = n,
|
|
1711
|
+
jt = n, S = r;
|
|
1803
1712
|
}
|
|
1804
1713
|
}
|
|
1805
1714
|
}
|
|
1806
|
-
async function
|
|
1715
|
+
async function sa() {
|
|
1807
1716
|
await Promise.resolve(), le();
|
|
1808
1717
|
}
|
|
1809
1718
|
function $(e) {
|
|
1810
|
-
var t = e.f, r = (t &
|
|
1811
|
-
if (
|
|
1812
|
-
var n =
|
|
1719
|
+
var t = e.f, r = (t & q) !== 0;
|
|
1720
|
+
if (T !== null && !ve) {
|
|
1721
|
+
var n = S !== null && (S.f & ne) !== 0;
|
|
1813
1722
|
if (!n && (we === null || !we.has(e))) {
|
|
1814
|
-
var i =
|
|
1815
|
-
if (
|
|
1816
|
-
e.rv <
|
|
1723
|
+
var i = T.deps;
|
|
1724
|
+
if (T.f & Zt)
|
|
1725
|
+
e.rv < Ve && (e.rv = Ve, re === null && i !== null && i[ae] === e ? ae++ : re === null ? re = [e] : re.push(e));
|
|
1817
1726
|
else {
|
|
1818
|
-
|
|
1727
|
+
T.deps ??= [], Yt.call(T.deps, e) || T.deps.push(e);
|
|
1819
1728
|
var s = e.reactions;
|
|
1820
|
-
s === null ? e.reactions = [
|
|
1729
|
+
s === null ? e.reactions = [T] : Yt.call(s, T) || s.push(T);
|
|
1821
1730
|
}
|
|
1822
1731
|
}
|
|
1823
1732
|
}
|
|
1824
1733
|
if (Me && xe.has(e))
|
|
1825
1734
|
return xe.get(e);
|
|
1826
1735
|
if (r) {
|
|
1827
|
-
var
|
|
1736
|
+
var o = (
|
|
1828
1737
|
/** @type {Derived} */
|
|
1829
1738
|
e
|
|
1830
1739
|
);
|
|
1831
1740
|
if (Me) {
|
|
1832
|
-
var
|
|
1833
|
-
return (!(
|
|
1741
|
+
var a = o.v;
|
|
1742
|
+
return (!(o.f & V) && o.reactions !== null || Si(o)) && (a = Jr(o)), xe.set(o, a), a;
|
|
1834
1743
|
}
|
|
1835
|
-
var u = (
|
|
1836
|
-
It(
|
|
1744
|
+
var u = (o.f & _e) === 0 && !ve && T !== null && (jt || (T.f & _e) !== 0), l = (o.f & Ye) === 0;
|
|
1745
|
+
It(o) && (u && (o.f |= _e), Kn(o)), u && !l && (ei(o), Ti(o));
|
|
1837
1746
|
}
|
|
1838
1747
|
if (pe?.has(e))
|
|
1839
1748
|
return pe.get(e);
|
|
1840
|
-
if (e.f &
|
|
1749
|
+
if (e.f & Re)
|
|
1841
1750
|
throw e.v;
|
|
1842
1751
|
return e.v;
|
|
1843
1752
|
}
|
|
1844
1753
|
function Ti(e) {
|
|
1845
|
-
if (e.f |=
|
|
1754
|
+
if (e.f |= _e, e.deps !== null)
|
|
1846
1755
|
for (const t of e.deps)
|
|
1847
|
-
(t.reactions ??= []).push(e), t.f &
|
|
1756
|
+
(t.reactions ??= []).push(e), t.f & q && !(t.f & _e) && (ei(
|
|
1848
1757
|
/** @type {Derived} */
|
|
1849
1758
|
t
|
|
1850
1759
|
), Ti(
|
|
@@ -1856,7 +1765,7 @@ function Si(e) {
|
|
|
1856
1765
|
if (e.v === j) return !0;
|
|
1857
1766
|
if (e.deps === null) return !1;
|
|
1858
1767
|
for (const t of e.deps)
|
|
1859
|
-
if (xe.has(t) || t.f &
|
|
1768
|
+
if (xe.has(t) || t.f & q && Si(
|
|
1860
1769
|
/** @type {Derived} */
|
|
1861
1770
|
t
|
|
1862
1771
|
))
|
|
@@ -1871,9 +1780,9 @@ function Hi(e) {
|
|
|
1871
1780
|
ve = t;
|
|
1872
1781
|
}
|
|
1873
1782
|
}
|
|
1874
|
-
const
|
|
1783
|
+
const Rt = Symbol("events"), aa = /* @__PURE__ */ new Set(), En = /* @__PURE__ */ new Set();
|
|
1875
1784
|
let gr = null, br = !1;
|
|
1876
|
-
function
|
|
1785
|
+
function xn(e) {
|
|
1877
1786
|
var t = this, r = (
|
|
1878
1787
|
/** @type {Node} */
|
|
1879
1788
|
t.ownerDocument
|
|
@@ -1884,33 +1793,33 @@ function En(e) {
|
|
|
1884
1793
|
gr = e, br || (br = !0, setTimeout(() => {
|
|
1885
1794
|
br = !1, gr = null;
|
|
1886
1795
|
}));
|
|
1887
|
-
var
|
|
1888
|
-
if (
|
|
1889
|
-
var u = i.indexOf(
|
|
1796
|
+
var o = 0, a = gr === e && e[Rt];
|
|
1797
|
+
if (a) {
|
|
1798
|
+
var u = i.indexOf(a);
|
|
1890
1799
|
if (u !== -1 && (t === document || t === /** @type {any} */
|
|
1891
1800
|
window)) {
|
|
1892
|
-
e[
|
|
1801
|
+
e[Rt] = t;
|
|
1893
1802
|
return;
|
|
1894
1803
|
}
|
|
1895
1804
|
var l = i.indexOf(t);
|
|
1896
1805
|
if (l === -1)
|
|
1897
1806
|
return;
|
|
1898
|
-
u <= l && (
|
|
1807
|
+
u <= l && (o = u);
|
|
1899
1808
|
}
|
|
1900
1809
|
if (s = /** @type {Element} */
|
|
1901
|
-
i[
|
|
1902
|
-
|
|
1810
|
+
i[o] || e.target, s !== t) {
|
|
1811
|
+
st(e, "currentTarget", {
|
|
1903
1812
|
configurable: !0,
|
|
1904
1813
|
get() {
|
|
1905
1814
|
return s || r;
|
|
1906
1815
|
}
|
|
1907
1816
|
});
|
|
1908
|
-
var f =
|
|
1817
|
+
var f = T, h = S;
|
|
1909
1818
|
ce(null), Se(null);
|
|
1910
1819
|
try {
|
|
1911
1820
|
for (var c, d = []; s !== null && s !== t; ) {
|
|
1912
1821
|
try {
|
|
1913
|
-
var p = s[
|
|
1822
|
+
var p = s[Rt]?.[n];
|
|
1914
1823
|
p != null && (!/** @type {any} */
|
|
1915
1824
|
s.disabled || // DOM could've been updated already by the time this is reached, so we check this as well
|
|
1916
1825
|
// -> the target could not have been disabled because it emits the event in the first place
|
|
@@ -1919,9 +1828,9 @@ function En(e) {
|
|
|
1919
1828
|
c ? d.push(b) : c = b;
|
|
1920
1829
|
}
|
|
1921
1830
|
if (e.cancelBubble) break;
|
|
1922
|
-
|
|
1831
|
+
o++, s = o < i.length ? (
|
|
1923
1832
|
/** @type {Element} */
|
|
1924
|
-
i[
|
|
1833
|
+
i[o]
|
|
1925
1834
|
) : null;
|
|
1926
1835
|
}
|
|
1927
1836
|
if (c) {
|
|
@@ -1932,31 +1841,31 @@ function En(e) {
|
|
|
1932
1841
|
throw c;
|
|
1933
1842
|
}
|
|
1934
1843
|
} finally {
|
|
1935
|
-
e[
|
|
1844
|
+
e[Rt] = t, delete e.currentTarget, ce(f), Se(h);
|
|
1936
1845
|
}
|
|
1937
1846
|
}
|
|
1938
1847
|
}
|
|
1939
|
-
const
|
|
1848
|
+
const oa = (
|
|
1940
1849
|
// We gotta write it like this because after downleveling the pure comment may end up in the wrong location
|
|
1941
1850
|
globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", {
|
|
1942
1851
|
/** @param {string} html */
|
|
1943
1852
|
createHTML: (e) => e
|
|
1944
1853
|
})
|
|
1945
1854
|
);
|
|
1946
|
-
function
|
|
1855
|
+
function ua(e) {
|
|
1947
1856
|
return (
|
|
1948
1857
|
/** @type {string} */
|
|
1949
|
-
|
|
1858
|
+
oa?.createHTML(e) ?? e
|
|
1950
1859
|
);
|
|
1951
1860
|
}
|
|
1952
|
-
function
|
|
1861
|
+
function la(e) {
|
|
1953
1862
|
var t = en("template");
|
|
1954
|
-
return t.innerHTML =
|
|
1863
|
+
return t.innerHTML = ua(e.replaceAll("<!>", "<!---->")), t.content;
|
|
1955
1864
|
}
|
|
1956
1865
|
function Bt(e, t) {
|
|
1957
1866
|
var r = (
|
|
1958
1867
|
/** @type {Effect} */
|
|
1959
|
-
|
|
1868
|
+
S
|
|
1960
1869
|
);
|
|
1961
1870
|
r.nodes === null && (r.nodes = { start: e, end: t, a: null, t: null });
|
|
1962
1871
|
}
|
|
@@ -1964,10 +1873,10 @@ function Bt(e, t) {
|
|
|
1964
1873
|
function sn(e, t) {
|
|
1965
1874
|
var r = (t & as) !== 0, n, i = !e.startsWith("<!>");
|
|
1966
1875
|
return () => {
|
|
1967
|
-
if (
|
|
1876
|
+
if (F)
|
|
1968
1877
|
return Bt(L, null), L;
|
|
1969
|
-
n === void 0 && (n =
|
|
1970
|
-
/* @__PURE__ */
|
|
1878
|
+
n === void 0 && (n = la(i ? e : "<!>" + e), n = /** @type {TemplateNode} */
|
|
1879
|
+
/* @__PURE__ */ lt(n));
|
|
1971
1880
|
var s = (
|
|
1972
1881
|
/** @type {TemplateNode} */
|
|
1973
1882
|
r || oi ? document.importNode(n, !0) : n.cloneNode(!0)
|
|
@@ -1975,19 +1884,19 @@ function sn(e, t) {
|
|
|
1975
1884
|
return Bt(s, s), s;
|
|
1976
1885
|
};
|
|
1977
1886
|
}
|
|
1978
|
-
function
|
|
1979
|
-
if (
|
|
1887
|
+
function fa() {
|
|
1888
|
+
if (F)
|
|
1980
1889
|
return Bt(L, null), L;
|
|
1981
1890
|
var e = document.createDocumentFragment(), t = document.createComment(""), r = Pe();
|
|
1982
1891
|
return e.append(t, r), Bt(t, r), e;
|
|
1983
1892
|
}
|
|
1984
|
-
function
|
|
1985
|
-
if (
|
|
1893
|
+
function Tt(e, t) {
|
|
1894
|
+
if (F) {
|
|
1986
1895
|
var r = (
|
|
1987
1896
|
/** @type {Effect & { nodes: EffectNodes }} */
|
|
1988
|
-
|
|
1897
|
+
S
|
|
1989
1898
|
);
|
|
1990
|
-
(!(r.f & Ye) || r.nodes.end === null) && (r.nodes.end = L),
|
|
1899
|
+
(!(r.f & Ye) || r.nodes.end === null) && (r.nodes.end = L), Xr();
|
|
1991
1900
|
return;
|
|
1992
1901
|
}
|
|
1993
1902
|
e !== null && e.before(
|
|
@@ -1995,25 +1904,25 @@ function St(e, t) {
|
|
|
1995
1904
|
t
|
|
1996
1905
|
);
|
|
1997
1906
|
}
|
|
1998
|
-
const
|
|
1999
|
-
function
|
|
2000
|
-
return
|
|
1907
|
+
const ha = ["touchstart", "touchmove"];
|
|
1908
|
+
function ca(e) {
|
|
1909
|
+
return ha.includes(e);
|
|
2001
1910
|
}
|
|
2002
|
-
function
|
|
1911
|
+
function da(e) {
|
|
2003
1912
|
let t = 0, r = Nt(0), n;
|
|
2004
1913
|
return () => {
|
|
2005
1914
|
rn() && ($(r), ci(() => (t === 0 && (n = Hi(() => e(() => At(r)))), t += 1, () => {
|
|
2006
|
-
|
|
1915
|
+
je(() => {
|
|
2007
1916
|
t -= 1, t === 0 && (n?.(), n = void 0, At(r));
|
|
2008
1917
|
});
|
|
2009
1918
|
})));
|
|
2010
1919
|
};
|
|
2011
1920
|
}
|
|
2012
|
-
var
|
|
2013
|
-
function
|
|
2014
|
-
new
|
|
1921
|
+
var pa = ot | ze;
|
|
1922
|
+
function va(e, t, r, n) {
|
|
1923
|
+
new _a(e, t, r, n);
|
|
2015
1924
|
}
|
|
2016
|
-
class
|
|
1925
|
+
class _a {
|
|
2017
1926
|
/** @type {Boundary | null} */
|
|
2018
1927
|
parent;
|
|
2019
1928
|
is_pending = !1;
|
|
@@ -2026,7 +1935,7 @@ class ya {
|
|
|
2026
1935
|
/** @type {TemplateNode} */
|
|
2027
1936
|
#e;
|
|
2028
1937
|
/** @type {TemplateNode | null} */
|
|
2029
|
-
#t =
|
|
1938
|
+
#t = F ? L : null;
|
|
2030
1939
|
/** @type {BoundaryProps} */
|
|
2031
1940
|
#r;
|
|
2032
1941
|
/** @type {((anchor: Node) => void)} */
|
|
@@ -2041,7 +1950,7 @@ class ya {
|
|
|
2041
1950
|
#o = null;
|
|
2042
1951
|
/** @type {DocumentFragment | null} */
|
|
2043
1952
|
#s = null;
|
|
2044
|
-
#
|
|
1953
|
+
#p = 0;
|
|
2045
1954
|
#l = 0;
|
|
2046
1955
|
#f = !1;
|
|
2047
1956
|
/** @type {Set<Effect>} */
|
|
@@ -2056,7 +1965,7 @@ class ya {
|
|
|
2056
1965
|
* @type {Source<number> | null}
|
|
2057
1966
|
*/
|
|
2058
1967
|
#h = null;
|
|
2059
|
-
#b =
|
|
1968
|
+
#b = da(() => (this.#h = Nt(this.#p), () => {
|
|
2060
1969
|
this.#h = null;
|
|
2061
1970
|
}));
|
|
2062
1971
|
/**
|
|
@@ -2067,29 +1976,29 @@ class ya {
|
|
|
2067
1976
|
*/
|
|
2068
1977
|
constructor(t, r, n, i) {
|
|
2069
1978
|
this.#e = t, this.#r = r, this.#u = (s) => {
|
|
2070
|
-
var
|
|
1979
|
+
var o = (
|
|
2071
1980
|
/** @type {Effect} */
|
|
2072
|
-
|
|
1981
|
+
S
|
|
2073
1982
|
);
|
|
2074
|
-
|
|
1983
|
+
o.b = this, o.f |= Ar, n(s);
|
|
2075
1984
|
}, this.parent = /** @type {Effect} */
|
|
2076
|
-
|
|
2077
|
-
if (
|
|
1985
|
+
S.b, this.transform_error = i ?? this.parent?.transform_error ?? ((s) => s), this.#i = di(() => {
|
|
1986
|
+
if (F) {
|
|
2078
1987
|
const s = (
|
|
2079
1988
|
/** @type {Comment} */
|
|
2080
1989
|
this.#t
|
|
2081
1990
|
);
|
|
2082
|
-
|
|
2083
|
-
const
|
|
2084
|
-
if (s.data.startsWith(
|
|
2085
|
-
const u = JSON.parse(s.data.slice(
|
|
2086
|
-
this.#
|
|
2087
|
-
} else
|
|
1991
|
+
Xr();
|
|
1992
|
+
const o = s.data === Dn;
|
|
1993
|
+
if (s.data.startsWith(ln)) {
|
|
1994
|
+
const u = JSON.parse(s.data.slice(ln.length));
|
|
1995
|
+
this.#m(u);
|
|
1996
|
+
} else o ? this.#w() : this.#y();
|
|
2088
1997
|
} else
|
|
2089
|
-
this.#
|
|
2090
|
-
},
|
|
1998
|
+
this.#E();
|
|
1999
|
+
}, pa), F && (this.#e = L);
|
|
2091
2000
|
}
|
|
2092
|
-
#
|
|
2001
|
+
#y() {
|
|
2093
2002
|
try {
|
|
2094
2003
|
this.#a = Oe(() => this.#u(this.#e));
|
|
2095
2004
|
} catch (t) {
|
|
@@ -2099,9 +2008,9 @@ class ya {
|
|
|
2099
2008
|
/**
|
|
2100
2009
|
* @param {unknown} error The deserialized error from the server's hydration comment
|
|
2101
2010
|
*/
|
|
2102
|
-
#
|
|
2103
|
-
const r = this.#r.failed, { reset: n, invoke_onerror: i } = this.#
|
|
2104
|
-
|
|
2011
|
+
#m(t) {
|
|
2012
|
+
const r = this.#r.failed, { reset: n, invoke_onerror: i } = this.#g(t);
|
|
2013
|
+
je(i), r && (this.#o = Oe(() => {
|
|
2105
2014
|
r(
|
|
2106
2015
|
this.#e,
|
|
2107
2016
|
() => t,
|
|
@@ -2115,7 +2024,7 @@ class ya {
|
|
|
2115
2024
|
* @param {unknown} error
|
|
2116
2025
|
* @returns {{ reset: () => void, invoke_onerror: () => void }}
|
|
2117
2026
|
*/
|
|
2118
|
-
#
|
|
2027
|
+
#g(t) {
|
|
2119
2028
|
var r = !1, n = !1;
|
|
2120
2029
|
const i = () => {
|
|
2121
2030
|
if (r) {
|
|
@@ -2124,35 +2033,35 @@ class ya {
|
|
|
2124
2033
|
}
|
|
2125
2034
|
r = !0, n && Ms(), this.#o !== null && $t(this.#o, () => {
|
|
2126
2035
|
this.#o = null;
|
|
2127
|
-
}), this.#
|
|
2128
|
-
this.#
|
|
2036
|
+
}), this.#x(() => {
|
|
2037
|
+
this.#E();
|
|
2129
2038
|
});
|
|
2130
2039
|
};
|
|
2131
2040
|
return { reset: i, invoke_onerror: () => {
|
|
2132
2041
|
try {
|
|
2133
2042
|
n = !0, this.#r.onerror?.(t, i), n = !1;
|
|
2134
|
-
} catch (
|
|
2135
|
-
be(
|
|
2043
|
+
} catch (o) {
|
|
2044
|
+
be(o, this.#i && this.#i.parent);
|
|
2136
2045
|
}
|
|
2137
2046
|
} };
|
|
2138
2047
|
}
|
|
2139
|
-
#
|
|
2048
|
+
#w() {
|
|
2140
2049
|
const t = this.#r.pending;
|
|
2141
|
-
t && (this.is_pending = !0, this.#n = Oe(() => t(this.#e)),
|
|
2050
|
+
t && (this.is_pending = !0, this.#n = Oe(() => t(this.#e)), je(() => {
|
|
2142
2051
|
var r = this.#s = document.createDocumentFragment(), n = Pe(), i = !1;
|
|
2143
|
-
if (r.append(n), this.#a = this.#
|
|
2052
|
+
if (r.append(n), this.#a = this.#x(() => {
|
|
2144
2053
|
try {
|
|
2145
2054
|
return Oe(() => this.#u(n));
|
|
2146
2055
|
} catch (s) {
|
|
2147
2056
|
try {
|
|
2148
2057
|
this.error(s), i = !0;
|
|
2149
|
-
} catch (
|
|
2150
|
-
be(
|
|
2058
|
+
} catch (o) {
|
|
2059
|
+
be(o, this.#i.parent);
|
|
2151
2060
|
}
|
|
2152
2061
|
return null;
|
|
2153
2062
|
}
|
|
2154
2063
|
}), this.#a === null) {
|
|
2155
|
-
this.#s = null, i && this.#
|
|
2064
|
+
this.#s = null, i && this.#d(
|
|
2156
2065
|
/** @type {Batch} */
|
|
2157
2066
|
A
|
|
2158
2067
|
);
|
|
@@ -2164,15 +2073,15 @@ class ya {
|
|
|
2164
2073
|
() => {
|
|
2165
2074
|
this.#n = null;
|
|
2166
2075
|
}
|
|
2167
|
-
), this.#
|
|
2076
|
+
), this.#d(
|
|
2168
2077
|
/** @type {Batch} */
|
|
2169
2078
|
A
|
|
2170
2079
|
));
|
|
2171
2080
|
}));
|
|
2172
2081
|
}
|
|
2173
|
-
#
|
|
2082
|
+
#E() {
|
|
2174
2083
|
try {
|
|
2175
|
-
if (this.is_pending = this.has_pending_snippet(), this.#l = 0, this.#
|
|
2084
|
+
if (this.is_pending = this.has_pending_snippet(), this.#l = 0, this.#p = 0, this.#a = Oe(() => {
|
|
2176
2085
|
this.#u(this.#e);
|
|
2177
2086
|
}), this.#l > 0) {
|
|
2178
2087
|
var t = this.#s = document.createDocumentFragment();
|
|
@@ -2183,7 +2092,7 @@ class ya {
|
|
|
2183
2092
|
);
|
|
2184
2093
|
this.#n = Oe(() => r(this.#e));
|
|
2185
2094
|
} else
|
|
2186
|
-
this.#
|
|
2095
|
+
this.#d(
|
|
2187
2096
|
/** @type {Batch} */
|
|
2188
2097
|
A
|
|
2189
2098
|
);
|
|
@@ -2194,7 +2103,7 @@ class ya {
|
|
|
2194
2103
|
/**
|
|
2195
2104
|
* @param {Batch} batch
|
|
2196
2105
|
*/
|
|
2197
|
-
#
|
|
2106
|
+
#d(t) {
|
|
2198
2107
|
this.is_pending = !1, t.transfer_effects(this.#c, this.#_);
|
|
2199
2108
|
}
|
|
2200
2109
|
/**
|
|
@@ -2218,13 +2127,13 @@ class ya {
|
|
|
2218
2127
|
* @template T
|
|
2219
2128
|
* @param {() => T} fn
|
|
2220
2129
|
*/
|
|
2221
|
-
#
|
|
2222
|
-
var r =
|
|
2223
|
-
Se(this.#i), ce(this.#i),
|
|
2130
|
+
#x(t) {
|
|
2131
|
+
var r = S, n = T, i = ie;
|
|
2132
|
+
Se(this.#i), ce(this.#i), ut(this.#i.ctx);
|
|
2224
2133
|
try {
|
|
2225
2134
|
return Le.ensure(), t();
|
|
2226
2135
|
} finally {
|
|
2227
|
-
Se(r), ce(n),
|
|
2136
|
+
Se(r), ce(n), ut(i);
|
|
2228
2137
|
}
|
|
2229
2138
|
}
|
|
2230
2139
|
/**
|
|
@@ -2233,12 +2142,12 @@ class ya {
|
|
|
2233
2142
|
* @param {1 | -1} d
|
|
2234
2143
|
* @param {Batch} batch
|
|
2235
2144
|
*/
|
|
2236
|
-
#
|
|
2145
|
+
#v(t, r) {
|
|
2237
2146
|
if (!this.has_pending_snippet()) {
|
|
2238
|
-
this.parent && this.parent.#
|
|
2147
|
+
this.parent && this.parent.#v(t, r);
|
|
2239
2148
|
return;
|
|
2240
2149
|
}
|
|
2241
|
-
this.#l += t, this.#l === 0 && (this.#
|
|
2150
|
+
this.#l += t, this.#l === 0 && (this.#d(r), this.#n && $t(this.#n, () => {
|
|
2242
2151
|
this.#n = null;
|
|
2243
2152
|
}), this.#s && (this.#e.before(this.#s), this.#s = null));
|
|
2244
2153
|
}
|
|
@@ -2250,8 +2159,8 @@ class ya {
|
|
|
2250
2159
|
* @param {Batch} batch
|
|
2251
2160
|
*/
|
|
2252
2161
|
update_pending_count(t, r) {
|
|
2253
|
-
this.#
|
|
2254
|
-
this.#f = !1, this.#h && Kt(this.#h, this.#
|
|
2162
|
+
this.#v(t, r), this.#p += t, !(!this.#h || this.#f) && (this.#f = !0, je(() => {
|
|
2163
|
+
this.#f = !1, this.#h && Kt(this.#h, this.#p);
|
|
2255
2164
|
}));
|
|
2256
2165
|
}
|
|
2257
2166
|
get_effect_pending() {
|
|
@@ -2272,36 +2181,36 @@ class ya {
|
|
|
2272
2181
|
* @param {unknown} error
|
|
2273
2182
|
*/
|
|
2274
2183
|
#T(t) {
|
|
2275
|
-
this.#a && (
|
|
2184
|
+
this.#a && (se(this.#a), this.#a = null), this.#n && (se(this.#n), this.#n = null), this.#o && (se(this.#o), this.#o = null), F && (ge(
|
|
2276
2185
|
/** @type {TemplateNode} */
|
|
2277
2186
|
this.#t
|
|
2278
|
-
), Es(), ge(
|
|
2187
|
+
), Es(), ge(Wn()));
|
|
2279
2188
|
let r = this.#r.failed;
|
|
2280
2189
|
const n = (i) => {
|
|
2281
|
-
const { reset: s, invoke_onerror:
|
|
2282
|
-
|
|
2190
|
+
const { reset: s, invoke_onerror: o } = this.#g(i);
|
|
2191
|
+
o(), r && (this.#o = this.#x(() => {
|
|
2283
2192
|
try {
|
|
2284
2193
|
return Oe(() => {
|
|
2285
|
-
var
|
|
2194
|
+
var a = (
|
|
2286
2195
|
/** @type {Effect} */
|
|
2287
|
-
|
|
2196
|
+
S
|
|
2288
2197
|
);
|
|
2289
|
-
|
|
2198
|
+
a.b = this, a.f |= Ar, r(
|
|
2290
2199
|
this.#e,
|
|
2291
2200
|
() => i,
|
|
2292
2201
|
() => s
|
|
2293
2202
|
);
|
|
2294
2203
|
});
|
|
2295
|
-
} catch (
|
|
2204
|
+
} catch (a) {
|
|
2296
2205
|
return be(
|
|
2297
|
-
|
|
2206
|
+
a,
|
|
2298
2207
|
/** @type {Effect} */
|
|
2299
2208
|
this.#i.parent
|
|
2300
2209
|
), null;
|
|
2301
2210
|
}
|
|
2302
2211
|
}));
|
|
2303
2212
|
};
|
|
2304
|
-
|
|
2213
|
+
je(() => {
|
|
2305
2214
|
var i;
|
|
2306
2215
|
try {
|
|
2307
2216
|
i = this.transform_error(t);
|
|
@@ -2326,37 +2235,37 @@ function yr(e, t) {
|
|
|
2326
2235
|
function Ai(e, t) {
|
|
2327
2236
|
return $i(e, t);
|
|
2328
2237
|
}
|
|
2329
|
-
function
|
|
2238
|
+
function ma(e, t) {
|
|
2330
2239
|
Mr(), t.intro = t.intro ?? !1;
|
|
2331
|
-
const r = t.target, n =
|
|
2240
|
+
const r = t.target, n = F, i = L;
|
|
2332
2241
|
try {
|
|
2333
|
-
for (var s = /* @__PURE__ */
|
|
2242
|
+
for (var s = /* @__PURE__ */ lt(r); s && (s.nodeType !== ar || /** @type {Comment} */
|
|
2334
2243
|
s.data !== Rn); )
|
|
2335
2244
|
s = /* @__PURE__ */ Ne(s);
|
|
2336
2245
|
if (!s)
|
|
2337
|
-
throw
|
|
2246
|
+
throw it;
|
|
2338
2247
|
tt(!0), ge(
|
|
2339
2248
|
/** @type {Comment} */
|
|
2340
2249
|
s
|
|
2341
2250
|
);
|
|
2342
|
-
const
|
|
2251
|
+
const o = $i(e, { ...t, anchor: s });
|
|
2343
2252
|
return tt(!1), /** @type {Exports} */
|
|
2344
|
-
|
|
2345
|
-
} catch (
|
|
2346
|
-
if (
|
|
2347
|
-
`).some((
|
|
2348
|
-
throw
|
|
2349
|
-
return
|
|
2253
|
+
o;
|
|
2254
|
+
} catch (o) {
|
|
2255
|
+
if (o instanceof Error && o.message.split(`
|
|
2256
|
+
`).some((a) => a.startsWith("https://svelte.dev/e/")))
|
|
2257
|
+
throw o;
|
|
2258
|
+
return o !== it && console.warn("Failed to hydrate: ", o), t.recover === !1 && Os(), Mr(), Xs(r), tt(!1), Ai(e, t);
|
|
2350
2259
|
} finally {
|
|
2351
2260
|
tt(n), ge(i);
|
|
2352
2261
|
}
|
|
2353
2262
|
}
|
|
2354
2263
|
const Dt = /* @__PURE__ */ new Map();
|
|
2355
|
-
function $i(e, { target: t, anchor: r, props: n = {}, events: i, context: s, intro:
|
|
2264
|
+
function $i(e, { target: t, anchor: r, props: n = {}, events: i, context: s, intro: o = !0, transformError: a }) {
|
|
2356
2265
|
Mr();
|
|
2357
|
-
var u = void 0, l =
|
|
2266
|
+
var u = void 0, l = Qs(() => {
|
|
2358
2267
|
var f = r ?? t.appendChild(Pe());
|
|
2359
|
-
|
|
2268
|
+
va(
|
|
2360
2269
|
/** @type {TemplateNode} */
|
|
2361
2270
|
f,
|
|
2362
2271
|
{
|
|
@@ -2364,38 +2273,38 @@ function $i(e, { target: t, anchor: r, props: n = {}, events: i, context: s, int
|
|
|
2364
2273
|
}
|
|
2365
2274
|
},
|
|
2366
2275
|
(d) => {
|
|
2367
|
-
|
|
2276
|
+
Yr({});
|
|
2368
2277
|
var p = (
|
|
2369
2278
|
/** @type {ComponentContext} */
|
|
2370
|
-
|
|
2279
|
+
ie
|
|
2371
2280
|
);
|
|
2372
|
-
if (s && (p.c = s), i && (n.$$events = i),
|
|
2281
|
+
if (s && (p.c = s), i && (n.$$events = i), F && Bt(
|
|
2373
2282
|
/** @type {TemplateNode} */
|
|
2374
2283
|
d,
|
|
2375
2284
|
null
|
|
2376
|
-
), u = e(d, n) ||
|
|
2377
|
-
L.data !==
|
|
2378
|
-
throw or(),
|
|
2379
|
-
|
|
2285
|
+
), u = e(d, n) || zn(), F && (S.nodes.end = L, L === null || L.nodeType !== ar || /** @type {Comment} */
|
|
2286
|
+
L.data !== kn))
|
|
2287
|
+
throw or(), it;
|
|
2288
|
+
zr();
|
|
2380
2289
|
},
|
|
2381
|
-
|
|
2290
|
+
a
|
|
2382
2291
|
);
|
|
2383
2292
|
var h = /* @__PURE__ */ new Set(), c = (d) => {
|
|
2384
2293
|
for (var p = 0; p < d.length; p++) {
|
|
2385
2294
|
var b = d[p];
|
|
2386
2295
|
if (!h.has(b)) {
|
|
2387
2296
|
h.add(b);
|
|
2388
|
-
var N =
|
|
2389
|
-
for (const
|
|
2390
|
-
var G = Dt.get(
|
|
2391
|
-
G === void 0 && (G = /* @__PURE__ */ new Map(), Dt.set(
|
|
2297
|
+
var N = ca(b);
|
|
2298
|
+
for (const U of [t, document]) {
|
|
2299
|
+
var G = Dt.get(U);
|
|
2300
|
+
G === void 0 && (G = /* @__PURE__ */ new Map(), Dt.set(U, G));
|
|
2392
2301
|
var W = G.get(b);
|
|
2393
|
-
W === void 0 ? (
|
|
2302
|
+
W === void 0 ? (U.addEventListener(b, xn, { passive: N }), G.set(b, 1)) : G.set(b, W + 1);
|
|
2394
2303
|
}
|
|
2395
2304
|
}
|
|
2396
2305
|
}
|
|
2397
2306
|
};
|
|
2398
|
-
return c(ls(
|
|
2307
|
+
return c(ls(aa)), En.add(c), () => {
|
|
2399
2308
|
for (var d of h)
|
|
2400
2309
|
for (const N of [t, document]) {
|
|
2401
2310
|
var p = (
|
|
@@ -2405,19 +2314,19 @@ function $i(e, { target: t, anchor: r, props: n = {}, events: i, context: s, int
|
|
|
2405
2314
|
/** @type {number} */
|
|
2406
2315
|
p.get(d)
|
|
2407
2316
|
);
|
|
2408
|
-
--b == 0 ? (N.removeEventListener(d,
|
|
2317
|
+
--b == 0 ? (N.removeEventListener(d, xn), p.delete(d), p.size === 0 && Dt.delete(N)) : p.set(d, b);
|
|
2409
2318
|
}
|
|
2410
|
-
|
|
2319
|
+
En.delete(c), f !== r && f.parentNode?.removeChild(f);
|
|
2411
2320
|
};
|
|
2412
2321
|
});
|
|
2413
2322
|
return Nr.set(u, l), u;
|
|
2414
2323
|
}
|
|
2415
2324
|
let Nr = /* @__PURE__ */ new WeakMap();
|
|
2416
|
-
function
|
|
2325
|
+
function ga(e, t) {
|
|
2417
2326
|
const r = Nr.get(e);
|
|
2418
2327
|
return r ? (Nr.delete(e), r(t)) : Promise.resolve();
|
|
2419
2328
|
}
|
|
2420
|
-
class
|
|
2329
|
+
class ba {
|
|
2421
2330
|
/** @type {TemplateNode} */
|
|
2422
2331
|
anchor;
|
|
2423
2332
|
/** @type {Map<Batch, Key>} */
|
|
@@ -2470,28 +2379,28 @@ class wa {
|
|
|
2470
2379
|
this.#e.get(t)
|
|
2471
2380
|
), n = this.#t.get(r);
|
|
2472
2381
|
if (n)
|
|
2473
|
-
|
|
2382
|
+
mn(n), this.#u.delete(r);
|
|
2474
2383
|
else {
|
|
2475
2384
|
var i = this.#r.get(r);
|
|
2476
|
-
i && (
|
|
2385
|
+
i && (mn(i.effect), this.#t.set(r, i.effect), this.#r.delete(r), i.fragment.lastChild.remove(), this.anchor.before(i.fragment), n = i.effect);
|
|
2477
2386
|
}
|
|
2478
|
-
for (const [s,
|
|
2387
|
+
for (const [s, o] of this.#e) {
|
|
2479
2388
|
if (this.#e.delete(s), s === t)
|
|
2480
2389
|
break;
|
|
2481
|
-
const
|
|
2482
|
-
|
|
2390
|
+
const a = this.#r.get(o);
|
|
2391
|
+
a && (se(a.effect), this.#r.delete(o));
|
|
2483
2392
|
}
|
|
2484
|
-
for (const [s,
|
|
2393
|
+
for (const [s, o] of this.#t) {
|
|
2485
2394
|
if (s === r || this.#u.has(s)) continue;
|
|
2486
|
-
const
|
|
2395
|
+
const a = () => {
|
|
2487
2396
|
if (Array.from(this.#e.values()).includes(s)) {
|
|
2488
2397
|
var l = document.createDocumentFragment();
|
|
2489
|
-
gi(
|
|
2398
|
+
gi(o, l), l.append(Pe()), this.#r.set(s, { effect: o, fragment: l });
|
|
2490
2399
|
} else
|
|
2491
|
-
|
|
2400
|
+
se(o);
|
|
2492
2401
|
this.#u.delete(s), this.#t.delete(s);
|
|
2493
2402
|
};
|
|
2494
|
-
this.#i || !n ? (this.#u.add(s), $t(
|
|
2403
|
+
this.#i || !n ? (this.#u.add(s), $t(o, a, !1)) : a();
|
|
2495
2404
|
}
|
|
2496
2405
|
}
|
|
2497
2406
|
};
|
|
@@ -2502,7 +2411,7 @@ class wa {
|
|
|
2502
2411
|
this.#e.delete(t);
|
|
2503
2412
|
const r = Array.from(this.#e.values());
|
|
2504
2413
|
for (const [n, i] of this.#r)
|
|
2505
|
-
r.includes(n) || (
|
|
2414
|
+
r.includes(n) || (se(i.effect), this.#r.delete(n));
|
|
2506
2415
|
};
|
|
2507
2416
|
/**
|
|
2508
2417
|
*
|
|
@@ -2513,12 +2422,12 @@ class wa {
|
|
|
2513
2422
|
var n = (
|
|
2514
2423
|
/** @type {Batch} */
|
|
2515
2424
|
A
|
|
2516
|
-
), i =
|
|
2425
|
+
), i = Ys();
|
|
2517
2426
|
if (r && !this.#t.has(t) && !this.#r.has(t))
|
|
2518
2427
|
if (i) {
|
|
2519
|
-
var s = document.createDocumentFragment(),
|
|
2520
|
-
s.append(
|
|
2521
|
-
effect: Oe(() => r(
|
|
2428
|
+
var s = document.createDocumentFragment(), o = Pe();
|
|
2429
|
+
s.append(o), this.#r.set(t, {
|
|
2430
|
+
effect: Oe(() => r(o)),
|
|
2522
2431
|
fragment: s
|
|
2523
2432
|
});
|
|
2524
2433
|
} else
|
|
@@ -2527,43 +2436,43 @@ class wa {
|
|
|
2527
2436
|
Oe(() => r(this.anchor))
|
|
2528
2437
|
);
|
|
2529
2438
|
if (this.#e.set(n, t), i) {
|
|
2530
|
-
for (const [
|
|
2531
|
-
|
|
2532
|
-
for (const [
|
|
2533
|
-
|
|
2439
|
+
for (const [a, u] of this.#t)
|
|
2440
|
+
a === t ? n.unskip_effect(u) : n.skip_effect(u);
|
|
2441
|
+
for (const [a, u] of this.#r)
|
|
2442
|
+
a === t ? n.unskip_effect(u.effect) : n.skip_effect(u.effect);
|
|
2534
2443
|
n.oncommit(this.#a), n.ondiscard(this.#n);
|
|
2535
2444
|
} else
|
|
2536
|
-
|
|
2445
|
+
F && (this.anchor = L), this.#a(n);
|
|
2537
2446
|
}
|
|
2538
2447
|
}
|
|
2539
|
-
function
|
|
2448
|
+
function wn(e, t, r = !1) {
|
|
2540
2449
|
var n;
|
|
2541
|
-
|
|
2542
|
-
var i = new
|
|
2543
|
-
function a
|
|
2544
|
-
if (
|
|
2450
|
+
F && (n = L, Xr());
|
|
2451
|
+
var i = new ba(e), s = r ? ot : 0;
|
|
2452
|
+
function o(a, u) {
|
|
2453
|
+
if (F) {
|
|
2545
2454
|
var l = xs(
|
|
2546
2455
|
/** @type {TemplateNode} */
|
|
2547
2456
|
n
|
|
2548
2457
|
);
|
|
2549
|
-
if (
|
|
2550
|
-
var f =
|
|
2551
|
-
ge(f), i.anchor = f, tt(!1), i.ensure(
|
|
2458
|
+
if (a !== parseInt(l.substring(1))) {
|
|
2459
|
+
var f = Wn();
|
|
2460
|
+
ge(f), i.anchor = f, tt(!1), i.ensure(a, u), tt(!0);
|
|
2552
2461
|
return;
|
|
2553
2462
|
}
|
|
2554
2463
|
}
|
|
2555
|
-
i.ensure(
|
|
2464
|
+
i.ensure(a, u);
|
|
2556
2465
|
}
|
|
2557
2466
|
di(() => {
|
|
2558
|
-
var
|
|
2467
|
+
var a = !1;
|
|
2559
2468
|
t((u, l = 0) => {
|
|
2560
|
-
|
|
2561
|
-
}),
|
|
2469
|
+
a = !0, o(l, u);
|
|
2470
|
+
}), a || o(-1, null);
|
|
2562
2471
|
}, s);
|
|
2563
2472
|
}
|
|
2564
|
-
function
|
|
2565
|
-
|
|
2566
|
-
e =
|
|
2473
|
+
function ya(e, t) {
|
|
2474
|
+
Ks(() => {
|
|
2475
|
+
e = S?.parent?.nodes?.start ?? e;
|
|
2567
2476
|
var r = e.getRootNode(), n = (
|
|
2568
2477
|
/** @type {ShadowRoot} */
|
|
2569
2478
|
r.host ? (
|
|
@@ -2581,25 +2490,142 @@ function Ta(e, t) {
|
|
|
2581
2490
|
}
|
|
2582
2491
|
});
|
|
2583
2492
|
}
|
|
2493
|
+
function an(e, t, r) {
|
|
2494
|
+
if (e == null)
|
|
2495
|
+
return t(void 0), r && r(void 0), Be;
|
|
2496
|
+
const n = Hi(
|
|
2497
|
+
() => e.subscribe(
|
|
2498
|
+
t,
|
|
2499
|
+
// @ts-expect-error
|
|
2500
|
+
r
|
|
2501
|
+
)
|
|
2502
|
+
);
|
|
2503
|
+
return n.unsubscribe ? () => n.unsubscribe() : n;
|
|
2504
|
+
}
|
|
2505
|
+
const et = [];
|
|
2506
|
+
function Ea(e, t) {
|
|
2507
|
+
return {
|
|
2508
|
+
subscribe: lr(e, t).subscribe
|
|
2509
|
+
};
|
|
2510
|
+
}
|
|
2511
|
+
function lr(e, t = Be) {
|
|
2512
|
+
let r = null;
|
|
2513
|
+
const n = /* @__PURE__ */ new Set();
|
|
2514
|
+
function i(a) {
|
|
2515
|
+
if (Yn(e, a) && (e = a, r)) {
|
|
2516
|
+
const u = !et.length;
|
|
2517
|
+
for (const l of n)
|
|
2518
|
+
l[1](), et.push(l, e);
|
|
2519
|
+
if (u) {
|
|
2520
|
+
for (let l = 0; l < et.length; l += 2)
|
|
2521
|
+
et[l][0](et[l + 1]);
|
|
2522
|
+
et.length = 0;
|
|
2523
|
+
}
|
|
2524
|
+
}
|
|
2525
|
+
}
|
|
2526
|
+
function s(a) {
|
|
2527
|
+
i(a(
|
|
2528
|
+
/** @type {T} */
|
|
2529
|
+
e
|
|
2530
|
+
));
|
|
2531
|
+
}
|
|
2532
|
+
function o(a, u = Be) {
|
|
2533
|
+
const l = [a, u];
|
|
2534
|
+
return n.add(l), n.size === 1 && (r = t(i, s) || Be), a(
|
|
2535
|
+
/** @type {T} */
|
|
2536
|
+
e
|
|
2537
|
+
), () => {
|
|
2538
|
+
n.delete(l), n.size === 0 && r && (r(), r = null);
|
|
2539
|
+
};
|
|
2540
|
+
}
|
|
2541
|
+
return { set: i, update: s, subscribe: o };
|
|
2542
|
+
}
|
|
2543
|
+
function vt(e, t, r) {
|
|
2544
|
+
const n = !Array.isArray(e), i = n ? [e] : e;
|
|
2545
|
+
if (!i.every(Boolean))
|
|
2546
|
+
throw new Error("derived() expects stores as input, got a falsy value");
|
|
2547
|
+
const s = t.length < 2;
|
|
2548
|
+
return Ea(r, (o, a) => {
|
|
2549
|
+
let u = !1;
|
|
2550
|
+
const l = [];
|
|
2551
|
+
let f = 0, h = Be;
|
|
2552
|
+
const c = () => {
|
|
2553
|
+
if (f)
|
|
2554
|
+
return;
|
|
2555
|
+
h();
|
|
2556
|
+
const p = t(n ? l[0] : l, o, a);
|
|
2557
|
+
s ? o(p) : h = typeof p == "function" ? p : Be;
|
|
2558
|
+
}, d = i.map(
|
|
2559
|
+
(p, b) => an(
|
|
2560
|
+
p,
|
|
2561
|
+
(N) => {
|
|
2562
|
+
l[b] = N, f &= ~(1 << b), u && c();
|
|
2563
|
+
},
|
|
2564
|
+
() => {
|
|
2565
|
+
f |= 1 << b;
|
|
2566
|
+
}
|
|
2567
|
+
)
|
|
2568
|
+
);
|
|
2569
|
+
return u = !0, c(), function() {
|
|
2570
|
+
Un(d), h(), u = !1;
|
|
2571
|
+
};
|
|
2572
|
+
});
|
|
2573
|
+
}
|
|
2574
|
+
function xa(e) {
|
|
2575
|
+
let t;
|
|
2576
|
+
return an(e, (r) => t = r)(), t;
|
|
2577
|
+
}
|
|
2578
|
+
let Ir = Symbol("unmounted");
|
|
2579
|
+
function wa(e, t, r) {
|
|
2580
|
+
const n = r[t] ??= {
|
|
2581
|
+
store: null,
|
|
2582
|
+
source: /* @__PURE__ */ si(void 0),
|
|
2583
|
+
unsubscribe: Be
|
|
2584
|
+
};
|
|
2585
|
+
if (n.store !== e && !(Ir in r))
|
|
2586
|
+
if (n.unsubscribe(), n.store = e ?? null, e == null)
|
|
2587
|
+
n.source.v = void 0, n.unsubscribe = Be;
|
|
2588
|
+
else {
|
|
2589
|
+
var i = !0;
|
|
2590
|
+
n.unsubscribe = an(e, (s) => {
|
|
2591
|
+
i ? n.source.v = s : Y(n.source, s);
|
|
2592
|
+
}), i = !1;
|
|
2593
|
+
}
|
|
2594
|
+
return e && Ir in r ? xa(e) : $(n.source);
|
|
2595
|
+
}
|
|
2596
|
+
function Ta() {
|
|
2597
|
+
const e = {};
|
|
2598
|
+
function t() {
|
|
2599
|
+
fi(() => {
|
|
2600
|
+
for (var r in e)
|
|
2601
|
+
e[r].unsubscribe();
|
|
2602
|
+
st(e, Ir, {
|
|
2603
|
+
enumerable: !1,
|
|
2604
|
+
value: !0
|
|
2605
|
+
});
|
|
2606
|
+
});
|
|
2607
|
+
}
|
|
2608
|
+
return [e, t];
|
|
2609
|
+
}
|
|
2584
2610
|
function ye(e, t, r, n) {
|
|
2585
2611
|
var i = (
|
|
2586
2612
|
/** @type {V} */
|
|
2587
2613
|
n
|
|
2588
|
-
), s = !0,
|
|
2589
|
-
n), i),
|
|
2590
|
-
|
|
2591
|
-
e[t],
|
|
2614
|
+
), s = !0, o = () => (s && (s = !1, i = /** @type {V} */
|
|
2615
|
+
n), i), a;
|
|
2616
|
+
a = /** @type {V} */
|
|
2617
|
+
e[t], a === void 0 && n !== void 0 && (a = o());
|
|
2592
2618
|
var u;
|
|
2593
2619
|
u = () => {
|
|
2594
2620
|
var c = (
|
|
2595
2621
|
/** @type {V} */
|
|
2596
2622
|
e[t]
|
|
2597
2623
|
);
|
|
2598
|
-
return c === void 0 ?
|
|
2624
|
+
return c === void 0 ? o() : (s = !0, c);
|
|
2599
2625
|
};
|
|
2600
2626
|
var l = !1, f = /* @__PURE__ */ Zr(() => (l = !1, u())), h = (
|
|
2601
2627
|
/** @type {Effect} */
|
|
2602
|
-
|
|
2628
|
+
S
|
|
2603
2629
|
);
|
|
2604
2630
|
return (
|
|
2605
2631
|
/** @type {() => V} */
|
|
@@ -2608,7 +2634,7 @@ function ye(e, t, r, n) {
|
|
|
2608
2634
|
const p = d ? $(f) : c;
|
|
2609
2635
|
return Y(f, p), l = !0, i !== void 0 && (i = p), c;
|
|
2610
2636
|
}
|
|
2611
|
-
return Me && l || h.f &
|
|
2637
|
+
return Me && l || h.f & ne ? f.v : $(f);
|
|
2612
2638
|
}
|
|
2613
2639
|
);
|
|
2614
2640
|
}
|
|
@@ -2626,25 +2652,25 @@ class Ha {
|
|
|
2626
2652
|
* }} options
|
|
2627
2653
|
*/
|
|
2628
2654
|
constructor(t) {
|
|
2629
|
-
var r = /* @__PURE__ */ new Map(), n = (s,
|
|
2630
|
-
var
|
|
2631
|
-
return r.set(s,
|
|
2655
|
+
var r = /* @__PURE__ */ new Map(), n = (s, o) => {
|
|
2656
|
+
var a = /* @__PURE__ */ si(o, !1, !1);
|
|
2657
|
+
return r.set(s, a), a;
|
|
2632
2658
|
};
|
|
2633
2659
|
const i = new Proxy(
|
|
2634
2660
|
{ ...t.props || {}, $$events: {} },
|
|
2635
2661
|
{
|
|
2636
|
-
get(s,
|
|
2637
|
-
return $(r.get(
|
|
2662
|
+
get(s, o) {
|
|
2663
|
+
return $(r.get(o) ?? n(o, Reflect.get(s, o)));
|
|
2638
2664
|
},
|
|
2639
|
-
has(s,
|
|
2640
|
-
return
|
|
2665
|
+
has(s, o) {
|
|
2666
|
+
return o === vs ? !0 : ($(r.get(o) ?? n(o, Reflect.get(s, o))), Reflect.has(s, o));
|
|
2641
2667
|
},
|
|
2642
|
-
set(s,
|
|
2643
|
-
return Y(r.get(
|
|
2668
|
+
set(s, o, a) {
|
|
2669
|
+
return Y(r.get(o) ?? n(o, a), a), Reflect.set(s, o, a);
|
|
2644
2670
|
}
|
|
2645
2671
|
}
|
|
2646
2672
|
);
|
|
2647
|
-
this.#t = (t.hydrate ?
|
|
2673
|
+
this.#t = (t.hydrate ? ma : Ai)(t.component, {
|
|
2648
2674
|
target: t.target,
|
|
2649
2675
|
anchor: t.anchor,
|
|
2650
2676
|
props: i,
|
|
@@ -2654,13 +2680,13 @@ class Ha {
|
|
|
2654
2680
|
transformError: t.transformError
|
|
2655
2681
|
}), (!t?.props?.$$host || t.sync === !1) && le(), this.#e = i.$$events;
|
|
2656
2682
|
for (const s of Object.keys(this.#t))
|
|
2657
|
-
s === "$set" || s === "$destroy" || s === "$on" ||
|
|
2683
|
+
s === "$set" || s === "$destroy" || s === "$on" || st(this, s, {
|
|
2658
2684
|
get() {
|
|
2659
2685
|
return this.#t[s];
|
|
2660
2686
|
},
|
|
2661
2687
|
/** @param {any} value */
|
|
2662
|
-
set(
|
|
2663
|
-
this.#t[s] =
|
|
2688
|
+
set(o) {
|
|
2689
|
+
this.#t[s] = o;
|
|
2664
2690
|
},
|
|
2665
2691
|
enumerable: !0
|
|
2666
2692
|
});
|
|
@@ -2668,7 +2694,7 @@ class Ha {
|
|
|
2668
2694
|
(s) => {
|
|
2669
2695
|
Object.assign(i, s);
|
|
2670
2696
|
}, this.#t.$destroy = () => {
|
|
2671
|
-
|
|
2697
|
+
ga(this.#t);
|
|
2672
2698
|
};
|
|
2673
2699
|
}
|
|
2674
2700
|
/** @param {Record<string, any>} props */
|
|
@@ -2754,7 +2780,7 @@ typeof HTMLElement == "function" && (Oi = class extends HTMLElement {
|
|
|
2754
2780
|
let e = function(n) {
|
|
2755
2781
|
return (i) => {
|
|
2756
2782
|
const s = en("slot");
|
|
2757
|
-
n !== "default" && (s.name = n),
|
|
2783
|
+
n !== "default" && (s.name = n), Tt(i, s);
|
|
2758
2784
|
};
|
|
2759
2785
|
};
|
|
2760
2786
|
if (await Promise.resolve(), !this.$$cn || this.$$c)
|
|
@@ -2776,7 +2802,7 @@ typeof HTMLElement == "function" && (Oi = class extends HTMLElement {
|
|
|
2776
2802
|
$$slots: t,
|
|
2777
2803
|
$$host: this
|
|
2778
2804
|
}
|
|
2779
|
-
}), this.$$me =
|
|
2805
|
+
}), this.$$me = Js(() => {
|
|
2780
2806
|
ci(() => {
|
|
2781
2807
|
this.$$r = !0;
|
|
2782
2808
|
for (const n of zt(this.$$c)) {
|
|
@@ -2864,38 +2890,38 @@ function Aa(e) {
|
|
|
2864
2890
|
}), t;
|
|
2865
2891
|
}
|
|
2866
2892
|
function Bi(e, t, r, n, i, s) {
|
|
2867
|
-
let
|
|
2893
|
+
let o = class extends Oi {
|
|
2868
2894
|
constructor() {
|
|
2869
2895
|
super(e, r, i), this.$$p_d = t;
|
|
2870
2896
|
}
|
|
2871
2897
|
static get observedAttributes() {
|
|
2872
2898
|
return zt(t).map(
|
|
2873
|
-
(
|
|
2899
|
+
(a) => (t[a].attribute || a).toLowerCase()
|
|
2874
2900
|
);
|
|
2875
2901
|
}
|
|
2876
2902
|
};
|
|
2877
|
-
return zt(t).forEach((
|
|
2878
|
-
|
|
2903
|
+
return zt(t).forEach((a) => {
|
|
2904
|
+
st(o.prototype, a, {
|
|
2879
2905
|
get() {
|
|
2880
|
-
return this.$$c &&
|
|
2906
|
+
return this.$$c && a in this.$$c ? this.$$c[a] : this.$$d[a];
|
|
2881
2907
|
},
|
|
2882
2908
|
set(u) {
|
|
2883
|
-
u = Vt(
|
|
2909
|
+
u = Vt(a, u, t), this.$$d[a] = u;
|
|
2884
2910
|
var l = this.$$c;
|
|
2885
2911
|
if (l) {
|
|
2886
|
-
var f =
|
|
2887
|
-
f ? l[
|
|
2912
|
+
var f = rt(l, a)?.get;
|
|
2913
|
+
f ? l[a] = u : l.$set({ [a]: u });
|
|
2888
2914
|
}
|
|
2889
2915
|
}
|
|
2890
2916
|
});
|
|
2891
|
-
}), n.forEach((
|
|
2892
|
-
|
|
2917
|
+
}), n.forEach((a) => {
|
|
2918
|
+
st(o.prototype, a, {
|
|
2893
2919
|
get() {
|
|
2894
|
-
return this.$$c?.[
|
|
2920
|
+
return this.$$c?.[a];
|
|
2895
2921
|
}
|
|
2896
2922
|
});
|
|
2897
2923
|
}), e.element = /** @type {any} */
|
|
2898
|
-
|
|
2924
|
+
o, o;
|
|
2899
2925
|
}
|
|
2900
2926
|
class $a extends Error {
|
|
2901
2927
|
constructor(t, r) {
|
|
@@ -2928,15 +2954,15 @@ var Pi = { exports: {} };
|
|
|
2928
2954
|
(function(r, n) {
|
|
2929
2955
|
e.exports = n();
|
|
2930
2956
|
})(Pa, function() {
|
|
2931
|
-
var r = 1e3, n = 6e4, i = 36e5, s = "millisecond",
|
|
2957
|
+
var r = 1e3, n = 6e4, i = 36e5, s = "millisecond", o = "second", a = "minute", u = "hour", l = "day", f = "week", h = "month", c = "quarter", d = "year", p = "date", b = "Invalid Date", N = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, G = /\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, W = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(y) {
|
|
2932
2958
|
var m = ["th", "st", "nd", "rd"], v = y % 100;
|
|
2933
2959
|
return "[" + y + (m[(v - 20) % 10] || m[v] || m[0]) + "]";
|
|
2934
|
-
} },
|
|
2960
|
+
} }, U = function(y, m, v) {
|
|
2935
2961
|
var g = String(y);
|
|
2936
2962
|
return !g || g.length >= m ? y : "" + Array(m + 1 - g.length).join(v) + y;
|
|
2937
|
-
}, Ae = { s:
|
|
2963
|
+
}, Ae = { s: U, z: function(y) {
|
|
2938
2964
|
var m = -y.utcOffset(), v = Math.abs(m), g = Math.floor(v / 60), _ = v % 60;
|
|
2939
|
-
return (m <= 0 ? "+" : "-") +
|
|
2965
|
+
return (m <= 0 ? "+" : "-") + U(g, 2, "0") + ":" + U(_, 2, "0");
|
|
2940
2966
|
}, m: function y(m, v) {
|
|
2941
2967
|
if (m.date() < v.date()) return -y(v, m);
|
|
2942
2968
|
var g = 12 * (v.year() - m.year()) + (v.month() - m.month()), _ = m.clone().add(g, h), E = v - _ < 0, x = m.clone().add(g + (E ? -1 : 1), h);
|
|
@@ -2944,7 +2970,7 @@ var Pi = { exports: {} };
|
|
|
2944
2970
|
}, a: function(y) {
|
|
2945
2971
|
return y < 0 ? Math.ceil(y) || 0 : Math.floor(y);
|
|
2946
2972
|
}, p: function(y) {
|
|
2947
|
-
return { M: h, y: d, w: f, d: l, D: p, h: u, m:
|
|
2973
|
+
return { M: h, y: d, w: f, d: l, D: p, h: u, m: a, s: o, ms: s, Q: c }[y] || String(y || "").toLowerCase().replace(/s$/, "");
|
|
2948
2974
|
}, u: function(y) {
|
|
2949
2975
|
return y === void 0;
|
|
2950
2976
|
} }, Z = "en", Q = {};
|
|
@@ -2964,13 +2990,13 @@ var Pi = { exports: {} };
|
|
|
2964
2990
|
Q[P] = m, _ = P;
|
|
2965
2991
|
}
|
|
2966
2992
|
return !g && _ && (Z = _), _ || !g && Z;
|
|
2967
|
-
},
|
|
2993
|
+
}, R = function(y, m) {
|
|
2968
2994
|
if (K(y)) return y.clone();
|
|
2969
2995
|
var v = typeof m == "object" ? m : {};
|
|
2970
2996
|
return v.date = y, v.args = arguments, new Ze(v);
|
|
2971
2997
|
}, O = Ae;
|
|
2972
2998
|
O.l = De, O.i = K, O.w = function(y, m) {
|
|
2973
|
-
return
|
|
2999
|
+
return R(y, { locale: m.$L, utc: m.$u, x: m.$x, $offset: m.$offset });
|
|
2974
3000
|
};
|
|
2975
3001
|
var Ze = function() {
|
|
2976
3002
|
function y(v) {
|
|
@@ -3000,12 +3026,12 @@ var Pi = { exports: {} };
|
|
|
3000
3026
|
}, m.isValid = function() {
|
|
3001
3027
|
return this.$d.toString() !== b;
|
|
3002
3028
|
}, m.isSame = function(v, g) {
|
|
3003
|
-
var _ =
|
|
3029
|
+
var _ = R(v);
|
|
3004
3030
|
return this.startOf(g) <= _ && _ <= this.endOf(g);
|
|
3005
3031
|
}, m.isAfter = function(v, g) {
|
|
3006
|
-
return
|
|
3032
|
+
return R(v) < this.startOf(g);
|
|
3007
3033
|
}, m.isBefore = function(v, g) {
|
|
3008
|
-
return this.endOf(g) <
|
|
3034
|
+
return this.endOf(g) < R(v);
|
|
3009
3035
|
}, m.$g = function(v, g, _) {
|
|
3010
3036
|
return O.u(v) ? this[g] : this.set(_, v);
|
|
3011
3037
|
}, m.unix = function() {
|
|
@@ -3018,23 +3044,23 @@ var Pi = { exports: {} };
|
|
|
3018
3044
|
return E ? Ie : Ie.endOf(l);
|
|
3019
3045
|
}, D = function(Fe, ee) {
|
|
3020
3046
|
return O.w(_.toDate()[Fe].apply(_.toDate("s"), (E ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(ee)), _);
|
|
3021
|
-
}, X = this.$W,
|
|
3047
|
+
}, X = this.$W, z = this.$M, oe = this.$D, Je = "set" + (this.$u ? "UTC" : "");
|
|
3022
3048
|
switch (x) {
|
|
3023
3049
|
case d:
|
|
3024
3050
|
return E ? P(1, 0) : P(31, 11);
|
|
3025
3051
|
case h:
|
|
3026
|
-
return E ? P(1,
|
|
3052
|
+
return E ? P(1, z) : P(0, z + 1);
|
|
3027
3053
|
case f:
|
|
3028
|
-
var ke = this.$locale().weekStart || 0,
|
|
3029
|
-
return P(E ? oe -
|
|
3054
|
+
var ke = this.$locale().weekStart || 0, bt = (X < ke ? X + 7 : X) - ke;
|
|
3055
|
+
return P(E ? oe - bt : oe + (6 - bt), z);
|
|
3030
3056
|
case l:
|
|
3031
3057
|
case p:
|
|
3032
3058
|
return D(Je + "Hours", 0);
|
|
3033
3059
|
case u:
|
|
3034
3060
|
return D(Je + "Minutes", 1);
|
|
3035
|
-
case o:
|
|
3036
|
-
return D(Je + "Seconds", 2);
|
|
3037
3061
|
case a:
|
|
3062
|
+
return D(Je + "Seconds", 2);
|
|
3063
|
+
case o:
|
|
3038
3064
|
return D(Je + "Milliseconds", 3);
|
|
3039
3065
|
default:
|
|
3040
3066
|
return this.clone();
|
|
@@ -3042,7 +3068,7 @@ var Pi = { exports: {} };
|
|
|
3042
3068
|
}, m.endOf = function(v) {
|
|
3043
3069
|
return this.startOf(v, !1);
|
|
3044
3070
|
}, m.$set = function(v, g) {
|
|
3045
|
-
var _, E = O.p(v), x = "set" + (this.$u ? "UTC" : ""), P = (_ = {}, _[l] = x + "Date", _[p] = x + "Date", _[h] = x + "Month", _[d] = x + "FullYear", _[u] = x + "Hours", _[
|
|
3071
|
+
var _, E = O.p(v), x = "set" + (this.$u ? "UTC" : ""), P = (_ = {}, _[l] = x + "Date", _[p] = x + "Date", _[h] = x + "Month", _[d] = x + "FullYear", _[u] = x + "Hours", _[a] = x + "Minutes", _[o] = x + "Seconds", _[s] = x + "Milliseconds", _)[E], D = E === l ? this.$D + (g - this.$W) : g;
|
|
3046
3072
|
if (E === h || E === d) {
|
|
3047
3073
|
var X = this.clone().set(p, 1);
|
|
3048
3074
|
X.$d[P](D), X.init(), this.$d = X.set(p, Math.min(this.$D, X.daysInMonth())).$d;
|
|
@@ -3055,32 +3081,32 @@ var Pi = { exports: {} };
|
|
|
3055
3081
|
}, m.add = function(v, g) {
|
|
3056
3082
|
var _, E = this;
|
|
3057
3083
|
v = Number(v);
|
|
3058
|
-
var x = O.p(g), P = function(
|
|
3059
|
-
var oe =
|
|
3060
|
-
return O.w(oe.date(oe.date() + Math.round(
|
|
3084
|
+
var x = O.p(g), P = function(z) {
|
|
3085
|
+
var oe = R(E);
|
|
3086
|
+
return O.w(oe.date(oe.date() + Math.round(z * v)), E);
|
|
3061
3087
|
};
|
|
3062
3088
|
if (x === h) return this.set(h, this.$M + v);
|
|
3063
3089
|
if (x === d) return this.set(d, this.$y + v);
|
|
3064
3090
|
if (x === l) return P(1);
|
|
3065
3091
|
if (x === f) return P(7);
|
|
3066
|
-
var D = (_ = {}, _[
|
|
3092
|
+
var D = (_ = {}, _[a] = n, _[u] = i, _[o] = r, _)[x] || 1, X = this.$d.getTime() + v * D;
|
|
3067
3093
|
return O.w(X, this);
|
|
3068
3094
|
}, m.subtract = function(v, g) {
|
|
3069
3095
|
return this.add(-1 * v, g);
|
|
3070
3096
|
}, m.format = function(v) {
|
|
3071
3097
|
var g = this, _ = this.$locale();
|
|
3072
3098
|
if (!this.isValid()) return _.invalidDate || b;
|
|
3073
|
-
var E = v || "YYYY-MM-DDTHH:mm:ssZ", x = O.z(this), P = this.$H, D = this.$m, X = this.$M,
|
|
3074
|
-
return ee && (ee[Ie] || ee(g, E)) ||
|
|
3075
|
-
},
|
|
3099
|
+
var E = v || "YYYY-MM-DDTHH:mm:ssZ", x = O.z(this), P = this.$H, D = this.$m, X = this.$M, z = _.weekdays, oe = _.months, Je = _.meridiem, ke = function(ee, Ie, yt, Ct) {
|
|
3100
|
+
return ee && (ee[Ie] || ee(g, E)) || yt[Ie].slice(0, Ct);
|
|
3101
|
+
}, bt = function(ee) {
|
|
3076
3102
|
return O.s(P % 12 || 12, ee, "0");
|
|
3077
|
-
}, Fe = Je || function(ee, Ie,
|
|
3078
|
-
var
|
|
3079
|
-
return
|
|
3103
|
+
}, Fe = Je || function(ee, Ie, yt) {
|
|
3104
|
+
var Ct = ee < 12 ? "AM" : "PM";
|
|
3105
|
+
return yt ? Ct.toLowerCase() : Ct;
|
|
3080
3106
|
};
|
|
3081
3107
|
return E.replace(G, function(ee, Ie) {
|
|
3082
|
-
return Ie || function(
|
|
3083
|
-
switch (
|
|
3108
|
+
return Ie || function(yt) {
|
|
3109
|
+
switch (yt) {
|
|
3084
3110
|
case "YY":
|
|
3085
3111
|
return String(g.$y).slice(-2);
|
|
3086
3112
|
case "YYYY":
|
|
@@ -3100,19 +3126,19 @@ var Pi = { exports: {} };
|
|
|
3100
3126
|
case "d":
|
|
3101
3127
|
return String(g.$W);
|
|
3102
3128
|
case "dd":
|
|
3103
|
-
return ke(_.weekdaysMin, g.$W,
|
|
3129
|
+
return ke(_.weekdaysMin, g.$W, z, 2);
|
|
3104
3130
|
case "ddd":
|
|
3105
|
-
return ke(_.weekdaysShort, g.$W,
|
|
3131
|
+
return ke(_.weekdaysShort, g.$W, z, 3);
|
|
3106
3132
|
case "dddd":
|
|
3107
|
-
return
|
|
3133
|
+
return z[g.$W];
|
|
3108
3134
|
case "H":
|
|
3109
3135
|
return String(P);
|
|
3110
3136
|
case "HH":
|
|
3111
3137
|
return O.s(P, 2, "0");
|
|
3112
3138
|
case "h":
|
|
3113
|
-
return
|
|
3139
|
+
return bt(1);
|
|
3114
3140
|
case "hh":
|
|
3115
|
-
return
|
|
3141
|
+
return bt(2);
|
|
3116
3142
|
case "a":
|
|
3117
3143
|
return Fe(P, D, !0);
|
|
3118
3144
|
case "A":
|
|
@@ -3136,7 +3162,7 @@ var Pi = { exports: {} };
|
|
|
3136
3162
|
}, m.utcOffset = function() {
|
|
3137
3163
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
3138
3164
|
}, m.diff = function(v, g, _) {
|
|
3139
|
-
var E, x = this, P = O.p(g), D =
|
|
3165
|
+
var E, x = this, P = O.p(g), D = R(v), X = (D.utcOffset() - this.utcOffset()) * n, z = this - D, oe = function() {
|
|
3140
3166
|
return O.m(x, D);
|
|
3141
3167
|
};
|
|
3142
3168
|
switch (P) {
|
|
@@ -3150,22 +3176,22 @@ var Pi = { exports: {} };
|
|
|
3150
3176
|
E = oe() / 3;
|
|
3151
3177
|
break;
|
|
3152
3178
|
case f:
|
|
3153
|
-
E = (
|
|
3179
|
+
E = (z - X) / 6048e5;
|
|
3154
3180
|
break;
|
|
3155
3181
|
case l:
|
|
3156
|
-
E = (
|
|
3182
|
+
E = (z - X) / 864e5;
|
|
3157
3183
|
break;
|
|
3158
3184
|
case u:
|
|
3159
|
-
E =
|
|
3160
|
-
break;
|
|
3161
|
-
case o:
|
|
3162
|
-
E = q / n;
|
|
3185
|
+
E = z / i;
|
|
3163
3186
|
break;
|
|
3164
3187
|
case a:
|
|
3165
|
-
E =
|
|
3188
|
+
E = z / n;
|
|
3189
|
+
break;
|
|
3190
|
+
case o:
|
|
3191
|
+
E = z / r;
|
|
3166
3192
|
break;
|
|
3167
3193
|
default:
|
|
3168
|
-
E =
|
|
3194
|
+
E = z;
|
|
3169
3195
|
}
|
|
3170
3196
|
return _ ? E : O.a(E);
|
|
3171
3197
|
}, m.daysInMonth = function() {
|
|
@@ -3187,16 +3213,16 @@ var Pi = { exports: {} };
|
|
|
3187
3213
|
}, m.toString = function() {
|
|
3188
3214
|
return this.$d.toUTCString();
|
|
3189
3215
|
}, y;
|
|
3190
|
-
}(),
|
|
3191
|
-
return
|
|
3192
|
-
|
|
3216
|
+
}(), gt = Ze.prototype;
|
|
3217
|
+
return R.prototype = gt, [["$ms", s], ["$s", o], ["$m", a], ["$H", u], ["$W", l], ["$M", h], ["$y", d], ["$D", p]].forEach(function(y) {
|
|
3218
|
+
gt[y[1]] = function(m) {
|
|
3193
3219
|
return this.$g(m, y[0], y[1]);
|
|
3194
3220
|
};
|
|
3195
|
-
}),
|
|
3196
|
-
return y.$i || (y(m, Ze,
|
|
3197
|
-
},
|
|
3198
|
-
return
|
|
3199
|
-
},
|
|
3221
|
+
}), R.extend = function(y, m) {
|
|
3222
|
+
return y.$i || (y(m, Ze, R), y.$i = !0), R;
|
|
3223
|
+
}, R.locale = De, R.isDayjs = K, R.unix = function(y) {
|
|
3224
|
+
return R(1e3 * y);
|
|
3225
|
+
}, R.en = Q[Z], R.Ls = Q, R.p = {}, R;
|
|
3200
3226
|
});
|
|
3201
3227
|
})(Pi);
|
|
3202
3228
|
var Ma = Pi.exports;
|
|
@@ -3204,10 +3230,10 @@ const Na = /* @__PURE__ */ Li(Ma), Ia = (e, t = "DD/MM/YYYY") => {
|
|
|
3204
3230
|
const r = Na(e);
|
|
3205
3231
|
return r.isValid() ? r.format(t) : "";
|
|
3206
3232
|
};
|
|
3207
|
-
var
|
|
3208
|
-
return
|
|
3233
|
+
var Ca = function(t) {
|
|
3234
|
+
return Ra(t) && !Da(t);
|
|
3209
3235
|
};
|
|
3210
|
-
function
|
|
3236
|
+
function Ra(e) {
|
|
3211
3237
|
return !!e && typeof e == "object";
|
|
3212
3238
|
}
|
|
3213
3239
|
function Da(e) {
|
|
@@ -3222,7 +3248,7 @@ function Ga(e) {
|
|
|
3222
3248
|
return Array.isArray(e) ? [] : {};
|
|
3223
3249
|
}
|
|
3224
3250
|
function Lt(e, t) {
|
|
3225
|
-
return t.clone !== !1 && t.isMergeableObject(e) ?
|
|
3251
|
+
return t.clone !== !1 && t.isMergeableObject(e) ? ht(Ga(e), e, t) : e;
|
|
3226
3252
|
}
|
|
3227
3253
|
function ja(e, t, r) {
|
|
3228
3254
|
return e.concat(t).map(function(n) {
|
|
@@ -3231,16 +3257,16 @@ function ja(e, t, r) {
|
|
|
3231
3257
|
}
|
|
3232
3258
|
function Va(e, t) {
|
|
3233
3259
|
if (!t.customMerge)
|
|
3234
|
-
return
|
|
3260
|
+
return ht;
|
|
3235
3261
|
var r = t.customMerge(e);
|
|
3236
|
-
return typeof r == "function" ? r :
|
|
3262
|
+
return typeof r == "function" ? r : ht;
|
|
3237
3263
|
}
|
|
3238
3264
|
function Wa(e) {
|
|
3239
3265
|
return Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(e).filter(function(t) {
|
|
3240
3266
|
return Object.propertyIsEnumerable.call(e, t);
|
|
3241
3267
|
}) : [];
|
|
3242
3268
|
}
|
|
3243
|
-
function
|
|
3269
|
+
function Tn(e) {
|
|
3244
3270
|
return Object.keys(e).concat(Wa(e));
|
|
3245
3271
|
}
|
|
3246
3272
|
function Mi(e, t) {
|
|
@@ -3255,37 +3281,37 @@ function Xa(e, t) {
|
|
|
3255
3281
|
}
|
|
3256
3282
|
function Ya(e, t, r) {
|
|
3257
3283
|
var n = {};
|
|
3258
|
-
return r.isMergeableObject(e) &&
|
|
3284
|
+
return r.isMergeableObject(e) && Tn(e).forEach(function(i) {
|
|
3259
3285
|
n[i] = Lt(e[i], r);
|
|
3260
|
-
}),
|
|
3286
|
+
}), Tn(t).forEach(function(i) {
|
|
3261
3287
|
Xa(e, i) || (Mi(e, i) && r.isMergeableObject(t[i]) ? n[i] = Va(i, r)(e[i], t[i], r) : n[i] = Lt(t[i], r));
|
|
3262
3288
|
}), n;
|
|
3263
3289
|
}
|
|
3264
|
-
function
|
|
3265
|
-
r = r || {}, r.arrayMerge = r.arrayMerge || ja, r.isMergeableObject = r.isMergeableObject ||
|
|
3290
|
+
function ht(e, t, r) {
|
|
3291
|
+
r = r || {}, r.arrayMerge = r.arrayMerge || ja, r.isMergeableObject = r.isMergeableObject || Ca, r.cloneUnlessOtherwiseSpecified = Lt;
|
|
3266
3292
|
var n = Array.isArray(t), i = Array.isArray(e), s = n === i;
|
|
3267
3293
|
return s ? n ? r.arrayMerge(e, t, r) : Ya(e, t, r) : Lt(t, r);
|
|
3268
3294
|
}
|
|
3269
|
-
|
|
3295
|
+
ht.all = function(t, r) {
|
|
3270
3296
|
if (!Array.isArray(t))
|
|
3271
3297
|
throw new Error("first argument should be an array");
|
|
3272
3298
|
return t.reduce(function(n, i) {
|
|
3273
|
-
return
|
|
3299
|
+
return ht(n, i, r);
|
|
3274
3300
|
}, {});
|
|
3275
3301
|
};
|
|
3276
|
-
var za =
|
|
3302
|
+
var za = ht, qa = za;
|
|
3277
3303
|
const Za = /* @__PURE__ */ Li(qa);
|
|
3278
|
-
var
|
|
3279
|
-
return
|
|
3304
|
+
var Cr = function(e, t) {
|
|
3305
|
+
return Cr = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, n) {
|
|
3280
3306
|
r.__proto__ = n;
|
|
3281
3307
|
} || function(r, n) {
|
|
3282
3308
|
for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (r[i] = n[i]);
|
|
3283
|
-
},
|
|
3309
|
+
}, Cr(e, t);
|
|
3284
3310
|
};
|
|
3285
3311
|
function fr(e, t) {
|
|
3286
3312
|
if (typeof t != "function" && t !== null)
|
|
3287
3313
|
throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
|
|
3288
|
-
|
|
3314
|
+
Cr(e, t);
|
|
3289
3315
|
function r() {
|
|
3290
3316
|
this.constructor = e;
|
|
3291
3317
|
}
|
|
@@ -3370,28 +3396,28 @@ var ro = function() {
|
|
|
3370
3396
|
return t;
|
|
3371
3397
|
}, tr.apply(this, arguments);
|
|
3372
3398
|
};
|
|
3373
|
-
var
|
|
3399
|
+
var w;
|
|
3374
3400
|
(function(e) {
|
|
3375
3401
|
e[e.EXPECT_ARGUMENT_CLOSING_BRACE = 1] = "EXPECT_ARGUMENT_CLOSING_BRACE", e[e.EMPTY_ARGUMENT = 2] = "EMPTY_ARGUMENT", e[e.MALFORMED_ARGUMENT = 3] = "MALFORMED_ARGUMENT", e[e.EXPECT_ARGUMENT_TYPE = 4] = "EXPECT_ARGUMENT_TYPE", e[e.INVALID_ARGUMENT_TYPE = 5] = "INVALID_ARGUMENT_TYPE", e[e.EXPECT_ARGUMENT_STYLE = 6] = "EXPECT_ARGUMENT_STYLE", e[e.INVALID_NUMBER_SKELETON = 7] = "INVALID_NUMBER_SKELETON", e[e.INVALID_DATE_TIME_SKELETON = 8] = "INVALID_DATE_TIME_SKELETON", e[e.EXPECT_NUMBER_SKELETON = 9] = "EXPECT_NUMBER_SKELETON", e[e.EXPECT_DATE_TIME_SKELETON = 10] = "EXPECT_DATE_TIME_SKELETON", e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE = 11] = "UNCLOSED_QUOTE_IN_ARGUMENT_STYLE", e[e.EXPECT_SELECT_ARGUMENT_OPTIONS = 12] = "EXPECT_SELECT_ARGUMENT_OPTIONS", e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE = 13] = "EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE", e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE = 14] = "INVALID_PLURAL_ARGUMENT_OFFSET_VALUE", e[e.EXPECT_SELECT_ARGUMENT_SELECTOR = 15] = "EXPECT_SELECT_ARGUMENT_SELECTOR", e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR = 16] = "EXPECT_PLURAL_ARGUMENT_SELECTOR", e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT = 17] = "EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT", e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT = 18] = "EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT", e[e.INVALID_PLURAL_ARGUMENT_SELECTOR = 19] = "INVALID_PLURAL_ARGUMENT_SELECTOR", e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR = 20] = "DUPLICATE_PLURAL_ARGUMENT_SELECTOR", e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR = 21] = "DUPLICATE_SELECT_ARGUMENT_SELECTOR", e[e.MISSING_OTHER_CLAUSE = 22] = "MISSING_OTHER_CLAUSE", e[e.INVALID_TAG = 23] = "INVALID_TAG", e[e.INVALID_TAG_NAME = 25] = "INVALID_TAG_NAME", e[e.UNMATCHED_CLOSING_TAG = 26] = "UNMATCHED_CLOSING_TAG", e[e.UNCLOSED_TAG = 27] = "UNCLOSED_TAG";
|
|
3376
|
-
})(
|
|
3402
|
+
})(w || (w = {}));
|
|
3377
3403
|
var M;
|
|
3378
3404
|
(function(e) {
|
|
3379
3405
|
e[e.literal = 0] = "literal", e[e.argument = 1] = "argument", e[e.number = 2] = "number", e[e.date = 3] = "date", e[e.time = 4] = "time", e[e.select = 5] = "select", e[e.plural = 6] = "plural", e[e.pound = 7] = "pound", e[e.tag = 8] = "tag";
|
|
3380
3406
|
})(M || (M = {}));
|
|
3381
|
-
var
|
|
3407
|
+
var ct;
|
|
3382
3408
|
(function(e) {
|
|
3383
3409
|
e[e.number = 0] = "number", e[e.dateTime = 1] = "dateTime";
|
|
3384
|
-
})(
|
|
3385
|
-
function
|
|
3410
|
+
})(ct || (ct = {}));
|
|
3411
|
+
function Sn(e) {
|
|
3386
3412
|
return e.type === M.literal;
|
|
3387
3413
|
}
|
|
3388
3414
|
function so(e) {
|
|
3389
3415
|
return e.type === M.argument;
|
|
3390
3416
|
}
|
|
3391
|
-
function
|
|
3417
|
+
function Ci(e) {
|
|
3392
3418
|
return e.type === M.number;
|
|
3393
3419
|
}
|
|
3394
|
-
function
|
|
3420
|
+
function Ri(e) {
|
|
3395
3421
|
return e.type === M.date;
|
|
3396
3422
|
}
|
|
3397
3423
|
function Di(e) {
|
|
@@ -3410,10 +3436,10 @@ function Ui(e) {
|
|
|
3410
3436
|
return e.type === M.tag;
|
|
3411
3437
|
}
|
|
3412
3438
|
function Gi(e) {
|
|
3413
|
-
return !!(e && typeof e == "object" && e.type ===
|
|
3439
|
+
return !!(e && typeof e == "object" && e.type === ct.number);
|
|
3414
3440
|
}
|
|
3415
3441
|
function Rr(e) {
|
|
3416
|
-
return !!(e && typeof e == "object" && e.type ===
|
|
3442
|
+
return !!(e && typeof e == "object" && e.type === ct.dateTime);
|
|
3417
3443
|
}
|
|
3418
3444
|
var ji = /[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/, oo = /(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;
|
|
3419
3445
|
function uo(e) {
|
|
@@ -3523,23 +3549,23 @@ function fo(e) {
|
|
|
3523
3549
|
for (var t = e.split(lo).filter(function(c) {
|
|
3524
3550
|
return c.length > 0;
|
|
3525
3551
|
}), r = [], n = 0, i = t; n < i.length; n++) {
|
|
3526
|
-
var s = i[n],
|
|
3527
|
-
if (
|
|
3552
|
+
var s = i[n], o = s.split("/");
|
|
3553
|
+
if (o.length === 0)
|
|
3528
3554
|
throw new Error("Invalid number skeleton");
|
|
3529
|
-
for (var
|
|
3555
|
+
for (var a = o[0], u = o.slice(1), l = 0, f = u; l < f.length; l++) {
|
|
3530
3556
|
var h = f[l];
|
|
3531
3557
|
if (h.length === 0)
|
|
3532
3558
|
throw new Error("Invalid number skeleton");
|
|
3533
3559
|
}
|
|
3534
|
-
r.push({ stem:
|
|
3560
|
+
r.push({ stem: a, options: u });
|
|
3535
3561
|
}
|
|
3536
3562
|
return r;
|
|
3537
3563
|
}
|
|
3538
3564
|
function ho(e) {
|
|
3539
3565
|
return e.replace(/^(.*?)-/, "");
|
|
3540
3566
|
}
|
|
3541
|
-
var
|
|
3542
|
-
function
|
|
3567
|
+
var Hn = /^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g, Vi = /^(@+)?(\+|#+)?[rs]?$/g, co = /(\*)(0+)|(#+)(0+)|(0+)/g, Wi = /^(0+)$/;
|
|
3568
|
+
function An(e) {
|
|
3543
3569
|
var t = {};
|
|
3544
3570
|
return e[e.length - 1] === "r" ? t.roundingPriority = "morePrecision" : e[e.length - 1] === "s" && (t.roundingPriority = "lessPrecision"), e.replace(Vi, function(r, n, i) {
|
|
3545
3571
|
return typeof i != "string" ? (t.minimumSignificantDigits = n.length, t.maximumSignificantDigits = n.length) : i === "+" ? t.minimumSignificantDigits = n.length : n[0] === "#" ? t.maximumSignificantDigits = n.length : (t.minimumSignificantDigits = n.length, t.maximumSignificantDigits = n.length + (typeof i == "string" ? i.length : 0)), "";
|
|
@@ -3599,7 +3625,7 @@ function po(e) {
|
|
|
3599
3625
|
}
|
|
3600
3626
|
return t;
|
|
3601
3627
|
}
|
|
3602
|
-
function
|
|
3628
|
+
function $n(e) {
|
|
3603
3629
|
var t = {}, r = Xi(e);
|
|
3604
3630
|
return r || t;
|
|
3605
3631
|
}
|
|
@@ -3639,12 +3665,12 @@ function vo(e) {
|
|
|
3639
3665
|
continue;
|
|
3640
3666
|
case "scientific":
|
|
3641
3667
|
t = I(I(I({}, t), { notation: "scientific" }), i.options.reduce(function(u, l) {
|
|
3642
|
-
return I(I({}, u),
|
|
3668
|
+
return I(I({}, u), $n(l));
|
|
3643
3669
|
}, {}));
|
|
3644
3670
|
continue;
|
|
3645
3671
|
case "engineering":
|
|
3646
3672
|
t = I(I(I({}, t), { notation: "engineering" }), i.options.reduce(function(u, l) {
|
|
3647
|
-
return I(I({}, u),
|
|
3673
|
+
return I(I({}, u), $n(l));
|
|
3648
3674
|
}, {}));
|
|
3649
3675
|
continue;
|
|
3650
3676
|
case "notation-simple":
|
|
@@ -3706,24 +3732,24 @@ function vo(e) {
|
|
|
3706
3732
|
t.minimumIntegerDigits = i.stem.length;
|
|
3707
3733
|
continue;
|
|
3708
3734
|
}
|
|
3709
|
-
if (
|
|
3735
|
+
if (Hn.test(i.stem)) {
|
|
3710
3736
|
if (i.options.length > 1)
|
|
3711
3737
|
throw new RangeError("Fraction-precision stems only accept a single optional option");
|
|
3712
|
-
i.stem.replace(
|
|
3738
|
+
i.stem.replace(Hn, function(u, l, f, h, c, d) {
|
|
3713
3739
|
return f === "*" ? t.minimumFractionDigits = l.length : h && h[0] === "#" ? t.maximumFractionDigits = h.length : c && d ? (t.minimumFractionDigits = c.length, t.maximumFractionDigits = c.length + d.length) : (t.minimumFractionDigits = l.length, t.maximumFractionDigits = l.length), "";
|
|
3714
3740
|
});
|
|
3715
3741
|
var s = i.options[0];
|
|
3716
|
-
s === "w" ? t = I(I({}, t), { trailingZeroDisplay: "stripIfInteger" }) : s && (t = I(I({}, t),
|
|
3742
|
+
s === "w" ? t = I(I({}, t), { trailingZeroDisplay: "stripIfInteger" }) : s && (t = I(I({}, t), An(s)));
|
|
3717
3743
|
continue;
|
|
3718
3744
|
}
|
|
3719
3745
|
if (Vi.test(i.stem)) {
|
|
3720
|
-
t = I(I({}, t),
|
|
3746
|
+
t = I(I({}, t), An(i.stem));
|
|
3721
3747
|
continue;
|
|
3722
3748
|
}
|
|
3723
|
-
var
|
|
3724
|
-
a && (t = I(I({}, t), a));
|
|
3725
|
-
var o = po(i.stem);
|
|
3749
|
+
var o = Xi(i.stem);
|
|
3726
3750
|
o && (t = I(I({}, t), o));
|
|
3751
|
+
var a = po(i.stem);
|
|
3752
|
+
a && (t = I(I({}, t), a));
|
|
3727
3753
|
}
|
|
3728
3754
|
return t;
|
|
3729
3755
|
}
|
|
@@ -5148,10 +5174,10 @@ function _o(e, t) {
|
|
|
5148
5174
|
if (i === "j") {
|
|
5149
5175
|
for (var s = 0; n + 1 < e.length && e.charAt(n + 1) === i; )
|
|
5150
5176
|
s++, n++;
|
|
5151
|
-
var
|
|
5152
|
-
for ((l == "H" || l == "k") && (
|
|
5177
|
+
var o = 1 + (s & 1), a = s < 2 ? 1 : 3 + (s >> 1), u = "a", l = mo(t);
|
|
5178
|
+
for ((l == "H" || l == "k") && (a = 0); a-- > 0; )
|
|
5153
5179
|
r += u;
|
|
5154
|
-
for (;
|
|
5180
|
+
for (; o-- > 0; )
|
|
5155
5181
|
r = l + r;
|
|
5156
5182
|
} else i === "J" ? r += "H" : r += i;
|
|
5157
5183
|
}
|
|
@@ -5185,14 +5211,14 @@ function H(e, t) {
|
|
|
5185
5211
|
}
|
|
5186
5212
|
var yo = !!String.prototype.startsWith && "_a".startsWith("a", 1), Eo = !!String.fromCodePoint, xo = !!Object.fromEntries, wo = !!String.prototype.codePointAt, To = !!String.prototype.trimStart, So = !!String.prototype.trimEnd, Ho = !!Number.isSafeInteger, Ao = Ho ? Number.isSafeInteger : function(e) {
|
|
5187
5213
|
return typeof e == "number" && isFinite(e) && Math.floor(e) === e && Math.abs(e) <= 9007199254740991;
|
|
5188
|
-
},
|
|
5214
|
+
}, Dr = !0;
|
|
5189
5215
|
try {
|
|
5190
5216
|
var $o = zi("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
|
|
5191
|
-
|
|
5217
|
+
Dr = ((Tr = $o.exec("a")) === null || Tr === void 0 ? void 0 : Tr[0]) === "a";
|
|
5192
5218
|
} catch {
|
|
5193
|
-
|
|
5219
|
+
Dr = !1;
|
|
5194
5220
|
}
|
|
5195
|
-
var
|
|
5221
|
+
var On = yo ? (
|
|
5196
5222
|
// Native
|
|
5197
5223
|
function(t, r, n) {
|
|
5198
5224
|
return t.startsWith(r, n);
|
|
@@ -5202,26 +5228,26 @@ var $n = yo ? (
|
|
|
5202
5228
|
function(t, r, n) {
|
|
5203
5229
|
return t.slice(n, n + r.length) === r;
|
|
5204
5230
|
}
|
|
5205
|
-
),
|
|
5231
|
+
), kr = Eo ? String.fromCodePoint : (
|
|
5206
5232
|
// IE11
|
|
5207
5233
|
function() {
|
|
5208
5234
|
for (var t = [], r = 0; r < arguments.length; r++)
|
|
5209
5235
|
t[r] = arguments[r];
|
|
5210
|
-
for (var n = "", i = t.length, s = 0,
|
|
5211
|
-
if (
|
|
5212
|
-
throw RangeError(
|
|
5213
|
-
n +=
|
|
5236
|
+
for (var n = "", i = t.length, s = 0, o; i > s; ) {
|
|
5237
|
+
if (o = t[s++], o > 1114111)
|
|
5238
|
+
throw RangeError(o + " is not a valid code point");
|
|
5239
|
+
n += o < 65536 ? String.fromCharCode(o) : String.fromCharCode(((o -= 65536) >> 10) + 55296, o % 1024 + 56320);
|
|
5214
5240
|
}
|
|
5215
5241
|
return n;
|
|
5216
5242
|
}
|
|
5217
|
-
),
|
|
5243
|
+
), Bn = (
|
|
5218
5244
|
// native
|
|
5219
5245
|
xo ? Object.fromEntries : (
|
|
5220
5246
|
// Ponyfill
|
|
5221
5247
|
function(t) {
|
|
5222
5248
|
for (var r = {}, n = 0, i = t; n < i.length; n++) {
|
|
5223
|
-
var s = i[n],
|
|
5224
|
-
r[
|
|
5249
|
+
var s = i[n], o = s[0], a = s[1];
|
|
5250
|
+
r[o] = a;
|
|
5225
5251
|
}
|
|
5226
5252
|
return r;
|
|
5227
5253
|
}
|
|
@@ -5264,24 +5290,24 @@ var $n = yo ? (
|
|
|
5264
5290
|
function zi(e, t) {
|
|
5265
5291
|
return new RegExp(e, t);
|
|
5266
5292
|
}
|
|
5267
|
-
var
|
|
5268
|
-
if (
|
|
5269
|
-
var
|
|
5270
|
-
|
|
5293
|
+
var Fr;
|
|
5294
|
+
if (Dr) {
|
|
5295
|
+
var Ln = zi("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
|
|
5296
|
+
Fr = function(t, r) {
|
|
5271
5297
|
var n;
|
|
5272
|
-
|
|
5273
|
-
var i =
|
|
5298
|
+
Ln.lastIndex = r;
|
|
5299
|
+
var i = Ln.exec(t);
|
|
5274
5300
|
return (n = i[1]) !== null && n !== void 0 ? n : "";
|
|
5275
5301
|
};
|
|
5276
5302
|
} else
|
|
5277
|
-
|
|
5303
|
+
Fr = function(t, r) {
|
|
5278
5304
|
for (var n = []; ; ) {
|
|
5279
5305
|
var i = Yi(t, r);
|
|
5280
5306
|
if (i === void 0 || qi(i) || No(i))
|
|
5281
5307
|
break;
|
|
5282
5308
|
n.push(i), r += i >= 65536 ? 2 : 1;
|
|
5283
5309
|
}
|
|
5284
|
-
return
|
|
5310
|
+
return kr.apply(void 0, n);
|
|
5285
5311
|
};
|
|
5286
5312
|
var Lo = (
|
|
5287
5313
|
/** @class */
|
|
@@ -5297,33 +5323,33 @@ var Lo = (
|
|
|
5297
5323
|
for (var i = []; !this.isEOF(); ) {
|
|
5298
5324
|
var s = this.char();
|
|
5299
5325
|
if (s === 123) {
|
|
5300
|
-
var
|
|
5301
|
-
if (
|
|
5302
|
-
return
|
|
5303
|
-
i.push(
|
|
5326
|
+
var o = this.parseArgument(t, n);
|
|
5327
|
+
if (o.err)
|
|
5328
|
+
return o;
|
|
5329
|
+
i.push(o.val);
|
|
5304
5330
|
} else {
|
|
5305
5331
|
if (s === 125 && t > 0)
|
|
5306
5332
|
break;
|
|
5307
5333
|
if (s === 35 && (r === "plural" || r === "selectordinal")) {
|
|
5308
|
-
var
|
|
5334
|
+
var a = this.clonePosition();
|
|
5309
5335
|
this.bump(), i.push({
|
|
5310
5336
|
type: M.pound,
|
|
5311
|
-
location: H(
|
|
5337
|
+
location: H(a, this.clonePosition())
|
|
5312
5338
|
});
|
|
5313
5339
|
} else if (s === 60 && !this.ignoreTag && this.peek() === 47) {
|
|
5314
5340
|
if (n)
|
|
5315
5341
|
break;
|
|
5316
|
-
return this.error(
|
|
5317
|
-
} else if (s === 60 && !this.ignoreTag &&
|
|
5318
|
-
var
|
|
5319
|
-
if (
|
|
5320
|
-
return
|
|
5321
|
-
i.push(
|
|
5342
|
+
return this.error(w.UNMATCHED_CLOSING_TAG, H(this.clonePosition(), this.clonePosition()));
|
|
5343
|
+
} else if (s === 60 && !this.ignoreTag && Ur(this.peek() || 0)) {
|
|
5344
|
+
var o = this.parseTag(t, r);
|
|
5345
|
+
if (o.err)
|
|
5346
|
+
return o;
|
|
5347
|
+
i.push(o.val);
|
|
5322
5348
|
} else {
|
|
5323
|
-
var
|
|
5324
|
-
if (
|
|
5325
|
-
return
|
|
5326
|
-
i.push(
|
|
5349
|
+
var o = this.parseLiteral(t, r);
|
|
5350
|
+
if (o.err)
|
|
5351
|
+
return o;
|
|
5352
|
+
i.push(o.val);
|
|
5327
5353
|
}
|
|
5328
5354
|
}
|
|
5329
5355
|
}
|
|
@@ -5345,24 +5371,24 @@ var Lo = (
|
|
|
5345
5371
|
var s = this.parseMessage(t + 1, r, !0);
|
|
5346
5372
|
if (s.err)
|
|
5347
5373
|
return s;
|
|
5348
|
-
var
|
|
5374
|
+
var o = s.val, a = this.clonePosition();
|
|
5349
5375
|
if (this.bumpIf("</")) {
|
|
5350
|
-
if (this.isEOF() || !
|
|
5351
|
-
return this.error(
|
|
5376
|
+
if (this.isEOF() || !Ur(this.char()))
|
|
5377
|
+
return this.error(w.INVALID_TAG, H(a, this.clonePosition()));
|
|
5352
5378
|
var u = this.clonePosition(), l = this.parseTagName();
|
|
5353
|
-
return i !== l ? this.error(
|
|
5379
|
+
return i !== l ? this.error(w.UNMATCHED_CLOSING_TAG, H(u, this.clonePosition())) : (this.bumpSpace(), this.bumpIf(">") ? {
|
|
5354
5380
|
val: {
|
|
5355
5381
|
type: M.tag,
|
|
5356
5382
|
value: i,
|
|
5357
|
-
children:
|
|
5383
|
+
children: o,
|
|
5358
5384
|
location: H(n, this.clonePosition())
|
|
5359
5385
|
},
|
|
5360
5386
|
err: null
|
|
5361
|
-
} : this.error(
|
|
5387
|
+
} : this.error(w.INVALID_TAG, H(a, this.clonePosition())));
|
|
5362
5388
|
} else
|
|
5363
|
-
return this.error(
|
|
5389
|
+
return this.error(w.UNCLOSED_TAG, H(n, this.clonePosition()));
|
|
5364
5390
|
} else
|
|
5365
|
-
return this.error(
|
|
5391
|
+
return this.error(w.INVALID_TAG, H(n, this.clonePosition()));
|
|
5366
5392
|
}, e.prototype.parseTagName = function() {
|
|
5367
5393
|
var t = this.offset();
|
|
5368
5394
|
for (this.bump(); !this.isEOF() && Mo(this.char()); )
|
|
@@ -5375,16 +5401,16 @@ var Lo = (
|
|
|
5375
5401
|
i += s;
|
|
5376
5402
|
continue;
|
|
5377
5403
|
}
|
|
5378
|
-
var
|
|
5379
|
-
if (a) {
|
|
5380
|
-
i += a;
|
|
5381
|
-
continue;
|
|
5382
|
-
}
|
|
5383
|
-
var o = this.tryParseLeftAngleBracket();
|
|
5404
|
+
var o = this.tryParseUnquoted(t, r);
|
|
5384
5405
|
if (o) {
|
|
5385
5406
|
i += o;
|
|
5386
5407
|
continue;
|
|
5387
5408
|
}
|
|
5409
|
+
var a = this.tryParseLeftAngleBracket();
|
|
5410
|
+
if (a) {
|
|
5411
|
+
i += a;
|
|
5412
|
+
continue;
|
|
5413
|
+
}
|
|
5388
5414
|
break;
|
|
5389
5415
|
}
|
|
5390
5416
|
var u = H(n, this.clonePosition());
|
|
@@ -5428,23 +5454,23 @@ var Lo = (
|
|
|
5428
5454
|
r.push(n);
|
|
5429
5455
|
this.bump();
|
|
5430
5456
|
}
|
|
5431
|
-
return
|
|
5457
|
+
return kr.apply(void 0, r);
|
|
5432
5458
|
}, e.prototype.tryParseUnquoted = function(t, r) {
|
|
5433
5459
|
if (this.isEOF())
|
|
5434
5460
|
return null;
|
|
5435
5461
|
var n = this.char();
|
|
5436
|
-
return n === 60 || n === 123 || n === 35 && (r === "plural" || r === "selectordinal") || n === 125 && t > 0 ? null : (this.bump(),
|
|
5462
|
+
return n === 60 || n === 123 || n === 35 && (r === "plural" || r === "selectordinal") || n === 125 && t > 0 ? null : (this.bump(), kr(n));
|
|
5437
5463
|
}, e.prototype.parseArgument = function(t, r) {
|
|
5438
5464
|
var n = this.clonePosition();
|
|
5439
5465
|
if (this.bump(), this.bumpSpace(), this.isEOF())
|
|
5440
|
-
return this.error(
|
|
5466
|
+
return this.error(w.EXPECT_ARGUMENT_CLOSING_BRACE, H(n, this.clonePosition()));
|
|
5441
5467
|
if (this.char() === 125)
|
|
5442
|
-
return this.bump(), this.error(
|
|
5468
|
+
return this.bump(), this.error(w.EMPTY_ARGUMENT, H(n, this.clonePosition()));
|
|
5443
5469
|
var i = this.parseIdentifierIfPossible().value;
|
|
5444
5470
|
if (!i)
|
|
5445
|
-
return this.error(
|
|
5471
|
+
return this.error(w.MALFORMED_ARGUMENT, H(n, this.clonePosition()));
|
|
5446
5472
|
if (this.bumpSpace(), this.isEOF())
|
|
5447
|
-
return this.error(
|
|
5473
|
+
return this.error(w.EXPECT_ARGUMENT_CLOSING_BRACE, H(n, this.clonePosition()));
|
|
5448
5474
|
switch (this.char()) {
|
|
5449
5475
|
case 125:
|
|
5450
5476
|
return this.bump(), {
|
|
@@ -5457,20 +5483,20 @@ var Lo = (
|
|
|
5457
5483
|
err: null
|
|
5458
5484
|
};
|
|
5459
5485
|
case 44:
|
|
5460
|
-
return this.bump(), this.bumpSpace(), this.isEOF() ? this.error(
|
|
5486
|
+
return this.bump(), this.bumpSpace(), this.isEOF() ? this.error(w.EXPECT_ARGUMENT_CLOSING_BRACE, H(n, this.clonePosition())) : this.parseArgumentOptions(t, r, i, n);
|
|
5461
5487
|
default:
|
|
5462
|
-
return this.error(
|
|
5488
|
+
return this.error(w.MALFORMED_ARGUMENT, H(n, this.clonePosition()));
|
|
5463
5489
|
}
|
|
5464
5490
|
}, e.prototype.parseIdentifierIfPossible = function() {
|
|
5465
|
-
var t = this.clonePosition(), r = this.offset(), n =
|
|
5491
|
+
var t = this.clonePosition(), r = this.offset(), n = Fr(this.message, r), i = r + n.length;
|
|
5466
5492
|
this.bumpTo(i);
|
|
5467
|
-
var s = this.clonePosition(),
|
|
5468
|
-
return { value: n, location:
|
|
5493
|
+
var s = this.clonePosition(), o = H(t, s);
|
|
5494
|
+
return { value: n, location: o };
|
|
5469
5495
|
}, e.prototype.parseArgumentOptions = function(t, r, n, i) {
|
|
5470
|
-
var s,
|
|
5471
|
-
switch (
|
|
5496
|
+
var s, o = this.clonePosition(), a = this.parseIdentifierIfPossible().value, u = this.clonePosition();
|
|
5497
|
+
switch (a) {
|
|
5472
5498
|
case "":
|
|
5473
|
-
return this.error(
|
|
5499
|
+
return this.error(w.EXPECT_ARGUMENT_TYPE, H(o, u));
|
|
5474
5500
|
case "number":
|
|
5475
5501
|
case "date":
|
|
5476
5502
|
case "time": {
|
|
@@ -5483,7 +5509,7 @@ var Lo = (
|
|
|
5483
5509
|
return h;
|
|
5484
5510
|
var c = Bo(h.val);
|
|
5485
5511
|
if (c.length === 0)
|
|
5486
|
-
return this.error(
|
|
5512
|
+
return this.error(w.EXPECT_ARGUMENT_STYLE, H(this.clonePosition(), this.clonePosition()));
|
|
5487
5513
|
var d = H(f, this.clonePosition());
|
|
5488
5514
|
l = { style: c, styleLocation: d };
|
|
5489
5515
|
}
|
|
@@ -5491,9 +5517,9 @@ var Lo = (
|
|
|
5491
5517
|
if (p.err)
|
|
5492
5518
|
return p;
|
|
5493
5519
|
var b = H(i, this.clonePosition());
|
|
5494
|
-
if (l &&
|
|
5520
|
+
if (l && On(l?.style, "::", 0)) {
|
|
5495
5521
|
var N = Oo(l.style.slice(2));
|
|
5496
|
-
if (
|
|
5522
|
+
if (a === "number") {
|
|
5497
5523
|
var h = this.parseNumberSkeletonFromString(N, l.styleLocation);
|
|
5498
5524
|
return h.err ? h : {
|
|
5499
5525
|
val: { type: M.number, value: n, location: b, style: h.val },
|
|
@@ -5501,15 +5527,15 @@ var Lo = (
|
|
|
5501
5527
|
};
|
|
5502
5528
|
} else {
|
|
5503
5529
|
if (N.length === 0)
|
|
5504
|
-
return this.error(
|
|
5530
|
+
return this.error(w.EXPECT_DATE_TIME_SKELETON, b);
|
|
5505
5531
|
var G = N;
|
|
5506
5532
|
this.locale && (G = _o(N, this.locale));
|
|
5507
5533
|
var c = {
|
|
5508
|
-
type:
|
|
5534
|
+
type: ct.dateTime,
|
|
5509
5535
|
pattern: G,
|
|
5510
5536
|
location: l.styleLocation,
|
|
5511
5537
|
parsedOptions: this.shouldParseSkeletons ? uo(G) : {}
|
|
5512
|
-
}, W =
|
|
5538
|
+
}, W = a === "date" ? M.date : M.time;
|
|
5513
5539
|
return {
|
|
5514
5540
|
val: { type: W, value: n, location: b, style: c },
|
|
5515
5541
|
err: null
|
|
@@ -5518,7 +5544,7 @@ var Lo = (
|
|
|
5518
5544
|
}
|
|
5519
5545
|
return {
|
|
5520
5546
|
val: {
|
|
5521
|
-
type:
|
|
5547
|
+
type: a === "number" ? M.number : a === "date" ? M.date : M.time,
|
|
5522
5548
|
value: n,
|
|
5523
5549
|
location: b,
|
|
5524
5550
|
style: (s = l?.style) !== null && s !== void 0 ? s : null
|
|
@@ -5529,32 +5555,32 @@ var Lo = (
|
|
|
5529
5555
|
case "plural":
|
|
5530
5556
|
case "selectordinal":
|
|
5531
5557
|
case "select": {
|
|
5532
|
-
var
|
|
5558
|
+
var U = this.clonePosition();
|
|
5533
5559
|
if (this.bumpSpace(), !this.bumpIf(","))
|
|
5534
|
-
return this.error(
|
|
5560
|
+
return this.error(w.EXPECT_SELECT_ARGUMENT_OPTIONS, H(U, tr({}, U)));
|
|
5535
5561
|
this.bumpSpace();
|
|
5536
5562
|
var Ae = this.parseIdentifierIfPossible(), Z = 0;
|
|
5537
|
-
if (
|
|
5563
|
+
if (a !== "select" && Ae.value === "offset") {
|
|
5538
5564
|
if (!this.bumpIf(":"))
|
|
5539
|
-
return this.error(
|
|
5565
|
+
return this.error(w.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, H(this.clonePosition(), this.clonePosition()));
|
|
5540
5566
|
this.bumpSpace();
|
|
5541
|
-
var h = this.tryParseDecimalInteger(
|
|
5567
|
+
var h = this.tryParseDecimalInteger(w.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, w.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);
|
|
5542
5568
|
if (h.err)
|
|
5543
5569
|
return h;
|
|
5544
5570
|
this.bumpSpace(), Ae = this.parseIdentifierIfPossible(), Z = h.val;
|
|
5545
5571
|
}
|
|
5546
|
-
var Q = this.tryParsePluralOrSelectOptions(t,
|
|
5572
|
+
var Q = this.tryParsePluralOrSelectOptions(t, a, r, Ae);
|
|
5547
5573
|
if (Q.err)
|
|
5548
5574
|
return Q;
|
|
5549
5575
|
var p = this.tryParseArgumentClose(i);
|
|
5550
5576
|
if (p.err)
|
|
5551
5577
|
return p;
|
|
5552
5578
|
var B = H(i, this.clonePosition());
|
|
5553
|
-
return
|
|
5579
|
+
return a === "select" ? {
|
|
5554
5580
|
val: {
|
|
5555
5581
|
type: M.select,
|
|
5556
5582
|
value: n,
|
|
5557
|
-
options:
|
|
5583
|
+
options: Bn(Q.val),
|
|
5558
5584
|
location: B
|
|
5559
5585
|
},
|
|
5560
5586
|
err: null
|
|
@@ -5562,19 +5588,19 @@ var Lo = (
|
|
|
5562
5588
|
val: {
|
|
5563
5589
|
type: M.plural,
|
|
5564
5590
|
value: n,
|
|
5565
|
-
options:
|
|
5591
|
+
options: Bn(Q.val),
|
|
5566
5592
|
offset: Z,
|
|
5567
|
-
pluralType:
|
|
5593
|
+
pluralType: a === "plural" ? "cardinal" : "ordinal",
|
|
5568
5594
|
location: B
|
|
5569
5595
|
},
|
|
5570
5596
|
err: null
|
|
5571
5597
|
};
|
|
5572
5598
|
}
|
|
5573
5599
|
default:
|
|
5574
|
-
return this.error(
|
|
5600
|
+
return this.error(w.INVALID_ARGUMENT_TYPE, H(o, u));
|
|
5575
5601
|
}
|
|
5576
5602
|
}, e.prototype.tryParseArgumentClose = function(t) {
|
|
5577
|
-
return this.isEOF() || this.char() !== 125 ? this.error(
|
|
5603
|
+
return this.isEOF() || this.char() !== 125 ? this.error(w.EXPECT_ARGUMENT_CLOSING_BRACE, H(t, this.clonePosition())) : (this.bump(), { val: !0, err: null });
|
|
5578
5604
|
}, e.prototype.parseSimpleArgStyleIfPossible = function() {
|
|
5579
5605
|
for (var t = 0, r = this.clonePosition(); !this.isEOF(); ) {
|
|
5580
5606
|
var n = this.char();
|
|
@@ -5583,7 +5609,7 @@ var Lo = (
|
|
|
5583
5609
|
this.bump();
|
|
5584
5610
|
var i = this.clonePosition();
|
|
5585
5611
|
if (!this.bumpUntil("'"))
|
|
5586
|
-
return this.error(
|
|
5612
|
+
return this.error(w.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE, H(i, this.clonePosition()));
|
|
5587
5613
|
this.bump();
|
|
5588
5614
|
break;
|
|
5589
5615
|
}
|
|
@@ -5615,11 +5641,11 @@ var Lo = (
|
|
|
5615
5641
|
try {
|
|
5616
5642
|
n = fo(t);
|
|
5617
5643
|
} catch {
|
|
5618
|
-
return this.error(
|
|
5644
|
+
return this.error(w.INVALID_NUMBER_SKELETON, r);
|
|
5619
5645
|
}
|
|
5620
5646
|
return {
|
|
5621
5647
|
val: {
|
|
5622
|
-
type:
|
|
5648
|
+
type: ct.number,
|
|
5623
5649
|
tokens: n,
|
|
5624
5650
|
location: r,
|
|
5625
5651
|
parsedOptions: this.shouldParseSkeletons ? vo(n) : {}
|
|
@@ -5627,11 +5653,11 @@ var Lo = (
|
|
|
5627
5653
|
err: null
|
|
5628
5654
|
};
|
|
5629
5655
|
}, e.prototype.tryParsePluralOrSelectOptions = function(t, r, n, i) {
|
|
5630
|
-
for (var s,
|
|
5656
|
+
for (var s, o = !1, a = [], u = /* @__PURE__ */ new Set(), l = i.value, f = i.location; ; ) {
|
|
5631
5657
|
if (l.length === 0) {
|
|
5632
5658
|
var h = this.clonePosition();
|
|
5633
5659
|
if (r !== "select" && this.bumpIf("=")) {
|
|
5634
|
-
var c = this.tryParseDecimalInteger(
|
|
5660
|
+
var c = this.tryParseDecimalInteger(w.EXPECT_PLURAL_ARGUMENT_SELECTOR, w.INVALID_PLURAL_ARGUMENT_SELECTOR);
|
|
5635
5661
|
if (c.err)
|
|
5636
5662
|
return c;
|
|
5637
5663
|
f = H(h, this.clonePosition()), l = this.message.slice(h.offset, this.offset());
|
|
@@ -5639,18 +5665,18 @@ var Lo = (
|
|
|
5639
5665
|
break;
|
|
5640
5666
|
}
|
|
5641
5667
|
if (u.has(l))
|
|
5642
|
-
return this.error(r === "select" ?
|
|
5643
|
-
l === "other" && (
|
|
5668
|
+
return this.error(r === "select" ? w.DUPLICATE_SELECT_ARGUMENT_SELECTOR : w.DUPLICATE_PLURAL_ARGUMENT_SELECTOR, f);
|
|
5669
|
+
l === "other" && (o = !0), this.bumpSpace();
|
|
5644
5670
|
var d = this.clonePosition();
|
|
5645
5671
|
if (!this.bumpIf("{"))
|
|
5646
|
-
return this.error(r === "select" ?
|
|
5672
|
+
return this.error(r === "select" ? w.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT : w.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT, H(this.clonePosition(), this.clonePosition()));
|
|
5647
5673
|
var p = this.parseMessage(t + 1, r, n);
|
|
5648
5674
|
if (p.err)
|
|
5649
5675
|
return p;
|
|
5650
5676
|
var b = this.tryParseArgumentClose(d);
|
|
5651
5677
|
if (b.err)
|
|
5652
5678
|
return b;
|
|
5653
|
-
|
|
5679
|
+
a.push([
|
|
5654
5680
|
l,
|
|
5655
5681
|
{
|
|
5656
5682
|
value: p.val,
|
|
@@ -5658,19 +5684,19 @@ var Lo = (
|
|
|
5658
5684
|
}
|
|
5659
5685
|
]), u.add(l), this.bumpSpace(), s = this.parseIdentifierIfPossible(), l = s.value, f = s.location;
|
|
5660
5686
|
}
|
|
5661
|
-
return
|
|
5687
|
+
return a.length === 0 ? this.error(r === "select" ? w.EXPECT_SELECT_ARGUMENT_SELECTOR : w.EXPECT_PLURAL_ARGUMENT_SELECTOR, H(this.clonePosition(), this.clonePosition())) : this.requiresOtherClause && !o ? this.error(w.MISSING_OTHER_CLAUSE, H(this.clonePosition(), this.clonePosition())) : { val: a, err: null };
|
|
5662
5688
|
}, e.prototype.tryParseDecimalInteger = function(t, r) {
|
|
5663
5689
|
var n = 1, i = this.clonePosition();
|
|
5664
5690
|
this.bumpIf("+") || this.bumpIf("-") && (n = -1);
|
|
5665
|
-
for (var s = !1,
|
|
5666
|
-
var
|
|
5667
|
-
if (
|
|
5668
|
-
s = !0,
|
|
5691
|
+
for (var s = !1, o = 0; !this.isEOF(); ) {
|
|
5692
|
+
var a = this.char();
|
|
5693
|
+
if (a >= 48 && a <= 57)
|
|
5694
|
+
s = !0, o = o * 10 + (a - 48), this.bump();
|
|
5669
5695
|
else
|
|
5670
5696
|
break;
|
|
5671
5697
|
}
|
|
5672
5698
|
var u = H(i, this.clonePosition());
|
|
5673
|
-
return s ? (
|
|
5699
|
+
return s ? (o *= n, Ao(o) ? { val: o, err: null } : this.error(r, u)) : this.error(t, u);
|
|
5674
5700
|
}, e.prototype.offset = function() {
|
|
5675
5701
|
return this.position.offset;
|
|
5676
5702
|
}, e.prototype.isEOF = function() {
|
|
@@ -5704,7 +5730,7 @@ var Lo = (
|
|
|
5704
5730
|
t === 10 ? (this.position.line += 1, this.position.column = 1, this.position.offset += 1) : (this.position.column += 1, this.position.offset += t < 65536 ? 1 : 2);
|
|
5705
5731
|
}
|
|
5706
5732
|
}, e.prototype.bumpIf = function(t) {
|
|
5707
|
-
if (
|
|
5733
|
+
if (On(this.message, t, this.offset())) {
|
|
5708
5734
|
for (var r = 0; r < t.length; r++)
|
|
5709
5735
|
this.bump();
|
|
5710
5736
|
return !0;
|
|
@@ -5736,11 +5762,11 @@ var Lo = (
|
|
|
5736
5762
|
}, e;
|
|
5737
5763
|
}()
|
|
5738
5764
|
);
|
|
5739
|
-
function
|
|
5765
|
+
function Ur(e) {
|
|
5740
5766
|
return e >= 97 && e <= 122 || e >= 65 && e <= 90;
|
|
5741
5767
|
}
|
|
5742
5768
|
function Po(e) {
|
|
5743
|
-
return
|
|
5769
|
+
return Ur(e) || e === 47;
|
|
5744
5770
|
}
|
|
5745
5771
|
function Mo(e) {
|
|
5746
5772
|
return e === 45 || e === 46 || e >= 48 && e <= 57 || e === 95 || e >= 97 && e <= 122 || e >= 65 && e <= 90 || e == 183 || e >= 192 && e <= 214 || e >= 216 && e <= 246 || e >= 248 && e <= 893 || e >= 895 && e <= 8191 || e >= 8204 && e <= 8205 || e >= 8255 && e <= 8256 || e >= 8304 && e <= 8591 || e >= 11264 && e <= 12271 || e >= 12289 && e <= 55295 || e >= 63744 && e <= 64975 || e >= 65008 && e <= 65533 || e >= 65536 && e <= 983039;
|
|
@@ -5751,27 +5777,27 @@ function qi(e) {
|
|
|
5751
5777
|
function No(e) {
|
|
5752
5778
|
return e >= 33 && e <= 35 || e === 36 || e >= 37 && e <= 39 || e === 40 || e === 41 || e === 42 || e === 43 || e === 44 || e === 45 || e >= 46 && e <= 47 || e >= 58 && e <= 59 || e >= 60 && e <= 62 || e >= 63 && e <= 64 || e === 91 || e === 92 || e === 93 || e === 94 || e === 96 || e === 123 || e === 124 || e === 125 || e === 126 || e === 161 || e >= 162 && e <= 165 || e === 166 || e === 167 || e === 169 || e === 171 || e === 172 || e === 174 || e === 176 || e === 177 || e === 182 || e === 187 || e === 191 || e === 215 || e === 247 || e >= 8208 && e <= 8213 || e >= 8214 && e <= 8215 || e === 8216 || e === 8217 || e === 8218 || e >= 8219 && e <= 8220 || e === 8221 || e === 8222 || e === 8223 || e >= 8224 && e <= 8231 || e >= 8240 && e <= 8248 || e === 8249 || e === 8250 || e >= 8251 && e <= 8254 || e >= 8257 && e <= 8259 || e === 8260 || e === 8261 || e === 8262 || e >= 8263 && e <= 8273 || e === 8274 || e === 8275 || e >= 8277 && e <= 8286 || e >= 8592 && e <= 8596 || e >= 8597 && e <= 8601 || e >= 8602 && e <= 8603 || e >= 8604 && e <= 8607 || e === 8608 || e >= 8609 && e <= 8610 || e === 8611 || e >= 8612 && e <= 8613 || e === 8614 || e >= 8615 && e <= 8621 || e === 8622 || e >= 8623 && e <= 8653 || e >= 8654 && e <= 8655 || e >= 8656 && e <= 8657 || e === 8658 || e === 8659 || e === 8660 || e >= 8661 && e <= 8691 || e >= 8692 && e <= 8959 || e >= 8960 && e <= 8967 || e === 8968 || e === 8969 || e === 8970 || e === 8971 || e >= 8972 && e <= 8991 || e >= 8992 && e <= 8993 || e >= 8994 && e <= 9e3 || e === 9001 || e === 9002 || e >= 9003 && e <= 9083 || e === 9084 || e >= 9085 && e <= 9114 || e >= 9115 && e <= 9139 || e >= 9140 && e <= 9179 || e >= 9180 && e <= 9185 || e >= 9186 && e <= 9254 || e >= 9255 && e <= 9279 || e >= 9280 && e <= 9290 || e >= 9291 && e <= 9311 || e >= 9472 && e <= 9654 || e === 9655 || e >= 9656 && e <= 9664 || e === 9665 || e >= 9666 && e <= 9719 || e >= 9720 && e <= 9727 || e >= 9728 && e <= 9838 || e === 9839 || e >= 9840 && e <= 10087 || e === 10088 || e === 10089 || e === 10090 || e === 10091 || e === 10092 || e === 10093 || e === 10094 || e === 10095 || e === 10096 || e === 10097 || e === 10098 || e === 10099 || e === 10100 || e === 10101 || e >= 10132 && e <= 10175 || e >= 10176 && e <= 10180 || e === 10181 || e === 10182 || e >= 10183 && e <= 10213 || e === 10214 || e === 10215 || e === 10216 || e === 10217 || e === 10218 || e === 10219 || e === 10220 || e === 10221 || e === 10222 || e === 10223 || e >= 10224 && e <= 10239 || e >= 10240 && e <= 10495 || e >= 10496 && e <= 10626 || e === 10627 || e === 10628 || e === 10629 || e === 10630 || e === 10631 || e === 10632 || e === 10633 || e === 10634 || e === 10635 || e === 10636 || e === 10637 || e === 10638 || e === 10639 || e === 10640 || e === 10641 || e === 10642 || e === 10643 || e === 10644 || e === 10645 || e === 10646 || e === 10647 || e === 10648 || e >= 10649 && e <= 10711 || e === 10712 || e === 10713 || e === 10714 || e === 10715 || e >= 10716 && e <= 10747 || e === 10748 || e === 10749 || e >= 10750 && e <= 11007 || e >= 11008 && e <= 11055 || e >= 11056 && e <= 11076 || e >= 11077 && e <= 11078 || e >= 11079 && e <= 11084 || e >= 11085 && e <= 11123 || e >= 11124 && e <= 11125 || e >= 11126 && e <= 11157 || e === 11158 || e >= 11159 && e <= 11263 || e >= 11776 && e <= 11777 || e === 11778 || e === 11779 || e === 11780 || e === 11781 || e >= 11782 && e <= 11784 || e === 11785 || e === 11786 || e === 11787 || e === 11788 || e === 11789 || e >= 11790 && e <= 11798 || e === 11799 || e >= 11800 && e <= 11801 || e === 11802 || e === 11803 || e === 11804 || e === 11805 || e >= 11806 && e <= 11807 || e === 11808 || e === 11809 || e === 11810 || e === 11811 || e === 11812 || e === 11813 || e === 11814 || e === 11815 || e === 11816 || e === 11817 || e >= 11818 && e <= 11822 || e === 11823 || e >= 11824 && e <= 11833 || e >= 11834 && e <= 11835 || e >= 11836 && e <= 11839 || e === 11840 || e === 11841 || e === 11842 || e >= 11843 && e <= 11855 || e >= 11856 && e <= 11857 || e === 11858 || e >= 11859 && e <= 11903 || e >= 12289 && e <= 12291 || e === 12296 || e === 12297 || e === 12298 || e === 12299 || e === 12300 || e === 12301 || e === 12302 || e === 12303 || e === 12304 || e === 12305 || e >= 12306 && e <= 12307 || e === 12308 || e === 12309 || e === 12310 || e === 12311 || e === 12312 || e === 12313 || e === 12314 || e === 12315 || e === 12316 || e === 12317 || e >= 12318 && e <= 12319 || e === 12320 || e === 12336 || e === 64830 || e === 64831 || e >= 65093 && e <= 65094;
|
|
5753
5779
|
}
|
|
5754
|
-
function
|
|
5780
|
+
function Gr(e) {
|
|
5755
5781
|
e.forEach(function(t) {
|
|
5756
5782
|
if (delete t.location, ki(t) || Fi(t))
|
|
5757
5783
|
for (var r in t.options)
|
|
5758
|
-
delete t.options[r].location,
|
|
5759
|
-
else
|
|
5784
|
+
delete t.options[r].location, Gr(t.options[r].value);
|
|
5785
|
+
else Ci(t) && Gi(t.style) || (Ri(t) || Di(t)) && Rr(t.style) ? delete t.style.location : Ui(t) && Gr(t.children);
|
|
5760
5786
|
});
|
|
5761
5787
|
}
|
|
5762
5788
|
function Io(e, t) {
|
|
5763
5789
|
t === void 0 && (t = {}), t = tr({ shouldParseSkeletons: !0, requiresOtherClause: !0 }, t);
|
|
5764
5790
|
var r = new Lo(e, t).parse();
|
|
5765
5791
|
if (r.err) {
|
|
5766
|
-
var n = SyntaxError(
|
|
5792
|
+
var n = SyntaxError(w[r.err.kind]);
|
|
5767
5793
|
throw n.location = r.err.location, n.originalMessage = r.err.message, n;
|
|
5768
5794
|
}
|
|
5769
|
-
return t?.captureLocation ||
|
|
5795
|
+
return t?.captureLocation || Gr(r.val), r.val;
|
|
5770
5796
|
}
|
|
5771
|
-
var
|
|
5797
|
+
var dt;
|
|
5772
5798
|
(function(e) {
|
|
5773
5799
|
e.MISSING_VALUE = "MISSING_VALUE", e.INVALID_VALUE = "INVALID_VALUE", e.MISSING_INTL_API = "MISSING_INTL_API";
|
|
5774
|
-
})(
|
|
5800
|
+
})(dt || (dt = {}));
|
|
5775
5801
|
var hr = (
|
|
5776
5802
|
/** @class */
|
|
5777
5803
|
function(e) {
|
|
@@ -5784,30 +5810,30 @@ var hr = (
|
|
|
5784
5810
|
return "[formatjs Error: ".concat(this.code, "] ").concat(this.message);
|
|
5785
5811
|
}, t;
|
|
5786
5812
|
}(Error)
|
|
5787
|
-
),
|
|
5813
|
+
), Pn = (
|
|
5788
5814
|
/** @class */
|
|
5789
5815
|
function(e) {
|
|
5790
5816
|
fr(t, e);
|
|
5791
5817
|
function t(r, n, i, s) {
|
|
5792
|
-
return e.call(this, 'Invalid values for "'.concat(r, '": "').concat(n, '". Options are "').concat(Object.keys(i).join('", "'), '"'),
|
|
5818
|
+
return e.call(this, 'Invalid values for "'.concat(r, '": "').concat(n, '". Options are "').concat(Object.keys(i).join('", "'), '"'), dt.INVALID_VALUE, s) || this;
|
|
5793
5819
|
}
|
|
5794
5820
|
return t;
|
|
5795
5821
|
}(hr)
|
|
5796
|
-
),
|
|
5822
|
+
), Co = (
|
|
5797
5823
|
/** @class */
|
|
5798
5824
|
function(e) {
|
|
5799
5825
|
fr(t, e);
|
|
5800
5826
|
function t(r, n, i) {
|
|
5801
|
-
return e.call(this, 'Value for "'.concat(r, '" must be of type ').concat(n),
|
|
5827
|
+
return e.call(this, 'Value for "'.concat(r, '" must be of type ').concat(n), dt.INVALID_VALUE, i) || this;
|
|
5802
5828
|
}
|
|
5803
5829
|
return t;
|
|
5804
5830
|
}(hr)
|
|
5805
|
-
),
|
|
5831
|
+
), Ro = (
|
|
5806
5832
|
/** @class */
|
|
5807
5833
|
function(e) {
|
|
5808
5834
|
fr(t, e);
|
|
5809
5835
|
function t(r, n) {
|
|
5810
|
-
return e.call(this, 'The intl string context variable "'.concat(r, '" was not provided to the string "').concat(n, '"'),
|
|
5836
|
+
return e.call(this, 'The intl string context variable "'.concat(r, '" was not provided to the string "').concat(n, '"'), dt.MISSING_VALUE, n) || this;
|
|
5811
5837
|
}
|
|
5812
5838
|
return t;
|
|
5813
5839
|
}(hr)
|
|
@@ -5824,25 +5850,25 @@ function Do(e) {
|
|
|
5824
5850
|
function ko(e) {
|
|
5825
5851
|
return typeof e == "function";
|
|
5826
5852
|
}
|
|
5827
|
-
function Wt(e, t, r, n, i, s,
|
|
5828
|
-
if (e.length === 1 &&
|
|
5853
|
+
function Wt(e, t, r, n, i, s, o) {
|
|
5854
|
+
if (e.length === 1 && Sn(e[0]))
|
|
5829
5855
|
return [
|
|
5830
5856
|
{
|
|
5831
5857
|
type: J.literal,
|
|
5832
5858
|
value: e[0].value
|
|
5833
5859
|
}
|
|
5834
5860
|
];
|
|
5835
|
-
for (var
|
|
5861
|
+
for (var a = [], u = 0, l = e; u < l.length; u++) {
|
|
5836
5862
|
var f = l[u];
|
|
5837
|
-
if (
|
|
5838
|
-
|
|
5863
|
+
if (Sn(f)) {
|
|
5864
|
+
a.push({
|
|
5839
5865
|
type: J.literal,
|
|
5840
5866
|
value: f.value
|
|
5841
5867
|
});
|
|
5842
5868
|
continue;
|
|
5843
5869
|
}
|
|
5844
5870
|
if (ao(f)) {
|
|
5845
|
-
typeof s == "number" &&
|
|
5871
|
+
typeof s == "number" && a.push({
|
|
5846
5872
|
type: J.literal,
|
|
5847
5873
|
value: r.getNumberFormat(t).format(s)
|
|
5848
5874
|
});
|
|
@@ -5850,18 +5876,18 @@ function Wt(e, t, r, n, i, s, a) {
|
|
|
5850
5876
|
}
|
|
5851
5877
|
var h = f.value;
|
|
5852
5878
|
if (!(i && h in i))
|
|
5853
|
-
throw new
|
|
5879
|
+
throw new Ro(h, o);
|
|
5854
5880
|
var c = i[h];
|
|
5855
5881
|
if (so(f)) {
|
|
5856
|
-
(!c || typeof c == "string" || typeof c == "number") && (c = typeof c == "string" || typeof c == "number" ? String(c) : ""),
|
|
5882
|
+
(!c || typeof c == "string" || typeof c == "number") && (c = typeof c == "string" || typeof c == "number" ? String(c) : ""), a.push({
|
|
5857
5883
|
type: typeof c == "string" ? J.literal : J.object,
|
|
5858
5884
|
value: c
|
|
5859
5885
|
});
|
|
5860
5886
|
continue;
|
|
5861
5887
|
}
|
|
5862
|
-
if (
|
|
5888
|
+
if (Ri(f)) {
|
|
5863
5889
|
var d = typeof f.style == "string" ? n.date[f.style] : Rr(f.style) ? f.style.parsedOptions : void 0;
|
|
5864
|
-
|
|
5890
|
+
a.push({
|
|
5865
5891
|
type: J.literal,
|
|
5866
5892
|
value: r.getDateTimeFormat(t, d).format(c)
|
|
5867
5893
|
});
|
|
@@ -5869,15 +5895,15 @@ function Wt(e, t, r, n, i, s, a) {
|
|
|
5869
5895
|
}
|
|
5870
5896
|
if (Di(f)) {
|
|
5871
5897
|
var d = typeof f.style == "string" ? n.time[f.style] : Rr(f.style) ? f.style.parsedOptions : n.time.medium;
|
|
5872
|
-
|
|
5898
|
+
a.push({
|
|
5873
5899
|
type: J.literal,
|
|
5874
5900
|
value: r.getDateTimeFormat(t, d).format(c)
|
|
5875
5901
|
});
|
|
5876
5902
|
continue;
|
|
5877
5903
|
}
|
|
5878
|
-
if (
|
|
5904
|
+
if (Ci(f)) {
|
|
5879
5905
|
var d = typeof f.style == "string" ? n.number[f.style] : Gi(f.style) ? f.style.parsedOptions : void 0;
|
|
5880
|
-
d && d.scale && (c = c * (d.scale || 1)),
|
|
5906
|
+
d && d.scale && (c = c * (d.scale || 1)), a.push({
|
|
5881
5907
|
type: J.literal,
|
|
5882
5908
|
value: r.getNumberFormat(t, d).format(c)
|
|
5883
5909
|
});
|
|
@@ -5886,11 +5912,11 @@ function Wt(e, t, r, n, i, s, a) {
|
|
|
5886
5912
|
if (Ui(f)) {
|
|
5887
5913
|
var p = f.children, b = f.value, N = i[b];
|
|
5888
5914
|
if (!ko(N))
|
|
5889
|
-
throw new
|
|
5915
|
+
throw new Co(b, "function", o);
|
|
5890
5916
|
var G = Wt(p, t, r, n, i, s), W = N(G.map(function(Z) {
|
|
5891
5917
|
return Z.value;
|
|
5892
5918
|
}));
|
|
5893
|
-
Array.isArray(W) || (W = [W]),
|
|
5919
|
+
Array.isArray(W) || (W = [W]), a.push.apply(a, W.map(function(Z) {
|
|
5894
5920
|
return {
|
|
5895
5921
|
type: typeof Z == "string" ? J.literal : J.object,
|
|
5896
5922
|
value: Z
|
|
@@ -5898,29 +5924,29 @@ function Wt(e, t, r, n, i, s, a) {
|
|
|
5898
5924
|
}));
|
|
5899
5925
|
}
|
|
5900
5926
|
if (ki(f)) {
|
|
5901
|
-
var
|
|
5902
|
-
if (!
|
|
5903
|
-
throw new
|
|
5904
|
-
|
|
5927
|
+
var U = f.options[c] || f.options.other;
|
|
5928
|
+
if (!U)
|
|
5929
|
+
throw new Pn(f.value, c, Object.keys(f.options), o);
|
|
5930
|
+
a.push.apply(a, Wt(U.value, t, r, n, i));
|
|
5905
5931
|
continue;
|
|
5906
5932
|
}
|
|
5907
5933
|
if (Fi(f)) {
|
|
5908
|
-
var
|
|
5909
|
-
if (!
|
|
5934
|
+
var U = f.options["=".concat(c)];
|
|
5935
|
+
if (!U) {
|
|
5910
5936
|
if (!Intl.PluralRules)
|
|
5911
5937
|
throw new hr(`Intl.PluralRules is not available in this environment.
|
|
5912
5938
|
Try polyfilling it using "@formatjs/intl-pluralrules"
|
|
5913
|
-
`,
|
|
5939
|
+
`, dt.MISSING_INTL_API, o);
|
|
5914
5940
|
var Ae = r.getPluralRules(t, { type: f.pluralType }).select(c - (f.offset || 0));
|
|
5915
|
-
|
|
5941
|
+
U = f.options[Ae] || f.options.other;
|
|
5916
5942
|
}
|
|
5917
|
-
if (!
|
|
5918
|
-
throw new
|
|
5919
|
-
|
|
5943
|
+
if (!U)
|
|
5944
|
+
throw new Pn(f.value, c, Object.keys(f.options), o);
|
|
5945
|
+
a.push.apply(a, Wt(U.value, t, r, n, i, c - (f.offset || 0)));
|
|
5920
5946
|
continue;
|
|
5921
5947
|
}
|
|
5922
5948
|
}
|
|
5923
|
-
return Do(
|
|
5949
|
+
return Do(a);
|
|
5924
5950
|
}
|
|
5925
5951
|
function Fo(e, t) {
|
|
5926
5952
|
return t ? Ee(Ee(Ee({}, e || {}), t || {}), Object.keys(e).reduce(function(r, n) {
|
|
@@ -6008,10 +6034,10 @@ var jo = (
|
|
|
6008
6034
|
}, this.locales = r, this.resolvedLocale = e.resolveLocale(r), typeof t == "string") {
|
|
6009
6035
|
if (this.message = t, !e.__parse)
|
|
6010
6036
|
throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");
|
|
6011
|
-
var
|
|
6012
|
-
|
|
6013
|
-
var
|
|
6014
|
-
this.ast = e.__parse(t, Ee(Ee({},
|
|
6037
|
+
var o = i || {};
|
|
6038
|
+
o.formatters;
|
|
6039
|
+
var a = Ja(o, ["formatters"]);
|
|
6040
|
+
this.ast = e.__parse(t, Ee(Ee({}, a), { locale: this.resolvedLocale }));
|
|
6015
6041
|
} else
|
|
6016
6042
|
this.ast = t;
|
|
6017
6043
|
if (!Array.isArray(this.ast))
|
|
@@ -6111,11 +6137,11 @@ function Vo(e, t) {
|
|
|
6111
6137
|
n = void 0;
|
|
6112
6138
|
return n;
|
|
6113
6139
|
}
|
|
6114
|
-
const
|
|
6140
|
+
const Ce = {}, Wo = (e, t, r) => r && (t in Ce || (Ce[t] = {}), e in Ce[t] || (Ce[t][e] = r), r), Zi = (e, t) => {
|
|
6115
6141
|
if (t == null)
|
|
6116
6142
|
return;
|
|
6117
|
-
if (t in
|
|
6118
|
-
return
|
|
6143
|
+
if (t in Ce && e in Ce[t])
|
|
6144
|
+
return Ce[t][e];
|
|
6119
6145
|
const r = cr(t);
|
|
6120
6146
|
for (let n = 0; n < r.length; n++) {
|
|
6121
6147
|
const i = r[n], s = Yo(i, e);
|
|
@@ -6123,13 +6149,13 @@ const Re = {}, Wo = (e, t, r) => r && (t in Re || (Re[t] = {}), e in Re[t] || (R
|
|
|
6123
6149
|
return Wo(e, t, s);
|
|
6124
6150
|
}
|
|
6125
6151
|
};
|
|
6126
|
-
let
|
|
6127
|
-
const
|
|
6152
|
+
let on;
|
|
6153
|
+
const _t = lr({});
|
|
6128
6154
|
function Xo(e) {
|
|
6129
|
-
return
|
|
6155
|
+
return on[e] || null;
|
|
6130
6156
|
}
|
|
6131
6157
|
function Ji(e) {
|
|
6132
|
-
return e in
|
|
6158
|
+
return e in on;
|
|
6133
6159
|
}
|
|
6134
6160
|
function Yo(e, t) {
|
|
6135
6161
|
if (!Ji(e))
|
|
@@ -6148,13 +6174,13 @@ function zo(e) {
|
|
|
6148
6174
|
}
|
|
6149
6175
|
}
|
|
6150
6176
|
function Qi(e, ...t) {
|
|
6151
|
-
delete
|
|
6177
|
+
delete Ce[e], _t.update((r) => (r[e] = Za.all([r[e] || {}, ...t]), r));
|
|
6152
6178
|
}
|
|
6153
|
-
|
|
6154
|
-
[
|
|
6179
|
+
vt(
|
|
6180
|
+
[_t],
|
|
6155
6181
|
([e]) => Object.keys(e)
|
|
6156
6182
|
);
|
|
6157
|
-
|
|
6183
|
+
_t.subscribe((e) => on = e);
|
|
6158
6184
|
const Xt = {};
|
|
6159
6185
|
function qo(e, t) {
|
|
6160
6186
|
Xt[e].delete(t), Xt[e].size === 0 && delete Xt[e];
|
|
@@ -6168,7 +6194,7 @@ function Zo(e) {
|
|
|
6168
6194
|
return [t, r ? [...r] : []];
|
|
6169
6195
|
}).filter(([, t]) => t.length > 0);
|
|
6170
6196
|
}
|
|
6171
|
-
function
|
|
6197
|
+
function jr(e) {
|
|
6172
6198
|
return e == null ? !1 : cr(e).some(
|
|
6173
6199
|
(t) => {
|
|
6174
6200
|
var r;
|
|
@@ -6181,20 +6207,20 @@ function Jo(e, t) {
|
|
|
6181
6207
|
t.map((n) => (qo(e, n), n().then((i) => i.default || i)))
|
|
6182
6208
|
).then((n) => Qi(e, ...n));
|
|
6183
6209
|
}
|
|
6184
|
-
const
|
|
6210
|
+
const Et = {};
|
|
6185
6211
|
function es(e) {
|
|
6186
|
-
if (!
|
|
6187
|
-
return e in
|
|
6212
|
+
if (!jr(e))
|
|
6213
|
+
return e in Et ? Et[e] : Promise.resolve();
|
|
6188
6214
|
const t = Zo(e);
|
|
6189
|
-
return
|
|
6215
|
+
return Et[e] = Promise.all(
|
|
6190
6216
|
t.map(
|
|
6191
6217
|
([r, n]) => Jo(r, n)
|
|
6192
6218
|
)
|
|
6193
6219
|
).then(() => {
|
|
6194
|
-
if (
|
|
6220
|
+
if (jr(e))
|
|
6195
6221
|
return es(e);
|
|
6196
|
-
delete
|
|
6197
|
-
}),
|
|
6222
|
+
delete Et[e];
|
|
6223
|
+
}), Et[e];
|
|
6198
6224
|
}
|
|
6199
6225
|
const Qo = {
|
|
6200
6226
|
number: {
|
|
@@ -6233,36 +6259,36 @@ const Qo = {
|
|
|
6233
6259
|
handleMissingMessage: void 0,
|
|
6234
6260
|
ignoreTag: !0
|
|
6235
6261
|
}, eu = Ko;
|
|
6236
|
-
function
|
|
6262
|
+
function pt() {
|
|
6237
6263
|
return eu;
|
|
6238
6264
|
}
|
|
6239
|
-
const Hr =
|
|
6240
|
-
var tu = Object.defineProperty, ru = Object.defineProperties, nu = Object.getOwnPropertyDescriptors,
|
|
6265
|
+
const Hr = lr(!1);
|
|
6266
|
+
var tu = Object.defineProperty, ru = Object.defineProperties, nu = Object.getOwnPropertyDescriptors, Mn = Object.getOwnPropertySymbols, iu = Object.prototype.hasOwnProperty, su = Object.prototype.propertyIsEnumerable, Nn = (e, t, r) => t in e ? tu(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, au = (e, t) => {
|
|
6241
6267
|
for (var r in t || (t = {}))
|
|
6242
|
-
iu.call(t, r) &&
|
|
6243
|
-
if (
|
|
6244
|
-
for (var r of
|
|
6245
|
-
su.call(t, r) &&
|
|
6268
|
+
iu.call(t, r) && Nn(e, r, t[r]);
|
|
6269
|
+
if (Mn)
|
|
6270
|
+
for (var r of Mn(t))
|
|
6271
|
+
su.call(t, r) && Nn(e, r, t[r]);
|
|
6246
6272
|
return e;
|
|
6247
6273
|
}, ou = (e, t) => ru(e, nu(t));
|
|
6248
|
-
let
|
|
6249
|
-
const rr =
|
|
6250
|
-
function
|
|
6274
|
+
let Vr;
|
|
6275
|
+
const rr = lr(null);
|
|
6276
|
+
function In(e) {
|
|
6251
6277
|
return e.split("-").map((t, r, n) => n.slice(0, r + 1).join("-")).reverse();
|
|
6252
6278
|
}
|
|
6253
|
-
function cr(e, t =
|
|
6254
|
-
const r =
|
|
6255
|
-
return t ? [.../* @__PURE__ */ new Set([...r, ...
|
|
6279
|
+
function cr(e, t = pt().fallbackLocale) {
|
|
6280
|
+
const r = In(e);
|
|
6281
|
+
return t ? [.../* @__PURE__ */ new Set([...r, ...In(t)])] : r;
|
|
6256
6282
|
}
|
|
6257
6283
|
function qe() {
|
|
6258
|
-
return
|
|
6284
|
+
return Vr ?? void 0;
|
|
6259
6285
|
}
|
|
6260
6286
|
rr.subscribe((e) => {
|
|
6261
|
-
|
|
6287
|
+
Vr = e ?? void 0, typeof window < "u" && e != null && document.documentElement.setAttribute("lang", e);
|
|
6262
6288
|
});
|
|
6263
6289
|
const uu = (e) => {
|
|
6264
|
-
if (e && zo(e) &&
|
|
6265
|
-
const { loadingDelay: t } =
|
|
6290
|
+
if (e && zo(e) && jr(e)) {
|
|
6291
|
+
const { loadingDelay: t } = pt();
|
|
6266
6292
|
let r;
|
|
6267
6293
|
return typeof window < "u" && qe() != null && t ? r = window.setTimeout(
|
|
6268
6294
|
() => Hr.set(!0),
|
|
@@ -6283,14 +6309,14 @@ const uu = (e) => {
|
|
|
6283
6309
|
return i in t ? t[i] : t[i] = e(n);
|
|
6284
6310
|
};
|
|
6285
6311
|
};
|
|
6286
|
-
var lu = Object.defineProperty, nr = Object.getOwnPropertySymbols, ts = Object.prototype.hasOwnProperty, rs = Object.prototype.propertyIsEnumerable,
|
|
6312
|
+
var lu = Object.defineProperty, nr = Object.getOwnPropertySymbols, ts = Object.prototype.hasOwnProperty, rs = Object.prototype.propertyIsEnumerable, Cn = (e, t, r) => t in e ? lu(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, un = (e, t) => {
|
|
6287
6313
|
for (var r in t || (t = {}))
|
|
6288
|
-
ts.call(t, r) &&
|
|
6314
|
+
ts.call(t, r) && Cn(e, r, t[r]);
|
|
6289
6315
|
if (nr)
|
|
6290
6316
|
for (var r of nr(t))
|
|
6291
|
-
rs.call(t, r) &&
|
|
6317
|
+
rs.call(t, r) && Cn(e, r, t[r]);
|
|
6292
6318
|
return e;
|
|
6293
|
-
},
|
|
6319
|
+
}, mt = (e, t) => {
|
|
6294
6320
|
var r = {};
|
|
6295
6321
|
for (var n in e)
|
|
6296
6322
|
ts.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
@@ -6300,27 +6326,27 @@ var lu = Object.defineProperty, nr = Object.getOwnPropertySymbols, ts = Object.p
|
|
|
6300
6326
|
return r;
|
|
6301
6327
|
};
|
|
6302
6328
|
const Pt = (e, t) => {
|
|
6303
|
-
const { formats: r } =
|
|
6329
|
+
const { formats: r } = pt();
|
|
6304
6330
|
if (e in r && t in r[e])
|
|
6305
6331
|
return r[e][t];
|
|
6306
6332
|
throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`);
|
|
6307
6333
|
}, fu = dr(
|
|
6308
6334
|
(e) => {
|
|
6309
|
-
var t = e, { locale: r, format: n } = t, i =
|
|
6335
|
+
var t = e, { locale: r, format: n } = t, i = mt(t, ["locale", "format"]);
|
|
6310
6336
|
if (r == null)
|
|
6311
6337
|
throw new Error('[svelte-i18n] A "locale" must be set to format numbers');
|
|
6312
6338
|
return n && (i = Pt("number", n)), new Intl.NumberFormat(r, i);
|
|
6313
6339
|
}
|
|
6314
6340
|
), hu = dr(
|
|
6315
6341
|
(e) => {
|
|
6316
|
-
var t = e, { locale: r, format: n } = t, i =
|
|
6342
|
+
var t = e, { locale: r, format: n } = t, i = mt(t, ["locale", "format"]);
|
|
6317
6343
|
if (r == null)
|
|
6318
6344
|
throw new Error('[svelte-i18n] A "locale" must be set to format dates');
|
|
6319
6345
|
return n ? i = Pt("date", n) : Object.keys(i).length === 0 && (i = Pt("date", "short")), new Intl.DateTimeFormat(r, i);
|
|
6320
6346
|
}
|
|
6321
6347
|
), cu = dr(
|
|
6322
6348
|
(e) => {
|
|
6323
|
-
var t = e, { locale: r, format: n } = t, i =
|
|
6349
|
+
var t = e, { locale: r, format: n } = t, i = mt(t, ["locale", "format"]);
|
|
6324
6350
|
if (r == null)
|
|
6325
6351
|
throw new Error(
|
|
6326
6352
|
'[svelte-i18n] A "locale" must be set to format time values'
|
|
@@ -6330,54 +6356,54 @@ const Pt = (e, t) => {
|
|
|
6330
6356
|
), du = (e = {}) => {
|
|
6331
6357
|
var t = e, {
|
|
6332
6358
|
locale: r = qe()
|
|
6333
|
-
} = t, n =
|
|
6359
|
+
} = t, n = mt(t, [
|
|
6334
6360
|
"locale"
|
|
6335
6361
|
]);
|
|
6336
|
-
return fu(
|
|
6362
|
+
return fu(un({ locale: r }, n));
|
|
6337
6363
|
}, pu = (e = {}) => {
|
|
6338
6364
|
var t = e, {
|
|
6339
6365
|
locale: r = qe()
|
|
6340
|
-
} = t, n =
|
|
6366
|
+
} = t, n = mt(t, [
|
|
6341
6367
|
"locale"
|
|
6342
6368
|
]);
|
|
6343
|
-
return hu(
|
|
6369
|
+
return hu(un({ locale: r }, n));
|
|
6344
6370
|
}, vu = (e = {}) => {
|
|
6345
6371
|
var t = e, {
|
|
6346
6372
|
locale: r = qe()
|
|
6347
|
-
} = t, n =
|
|
6373
|
+
} = t, n = mt(t, [
|
|
6348
6374
|
"locale"
|
|
6349
6375
|
]);
|
|
6350
|
-
return cu(
|
|
6376
|
+
return cu(un({ locale: r }, n));
|
|
6351
6377
|
}, _u = dr(
|
|
6352
6378
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
6353
|
-
(e, t = qe()) => new jo(e, t,
|
|
6354
|
-
ignoreTag:
|
|
6379
|
+
(e, t = qe()) => new jo(e, t, pt().formats, {
|
|
6380
|
+
ignoreTag: pt().ignoreTag
|
|
6355
6381
|
})
|
|
6356
6382
|
), mu = (e, t = {}) => {
|
|
6357
6383
|
var r, n, i, s;
|
|
6358
|
-
let
|
|
6359
|
-
typeof e == "object" && (
|
|
6384
|
+
let o = t;
|
|
6385
|
+
typeof e == "object" && (o = e, e = o.id);
|
|
6360
6386
|
const {
|
|
6361
|
-
values:
|
|
6387
|
+
values: a,
|
|
6362
6388
|
locale: u = qe(),
|
|
6363
6389
|
default: l
|
|
6364
|
-
} =
|
|
6390
|
+
} = o;
|
|
6365
6391
|
if (u == null)
|
|
6366
6392
|
throw new Error(
|
|
6367
6393
|
"[svelte-i18n] Cannot format a message without first setting the initial locale."
|
|
6368
6394
|
);
|
|
6369
6395
|
let f = Zi(e, u);
|
|
6370
6396
|
if (!f)
|
|
6371
|
-
f = (s = (i = (n = (r =
|
|
6397
|
+
f = (s = (i = (n = (r = pt()).handleMissingMessage) == null ? void 0 : n.call(r, { locale: u, id: e, defaultValue: l })) != null ? i : l) != null ? s : e;
|
|
6372
6398
|
else if (typeof f != "string")
|
|
6373
6399
|
return console.warn(
|
|
6374
6400
|
`[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof f}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`
|
|
6375
6401
|
), f;
|
|
6376
|
-
if (!
|
|
6402
|
+
if (!a)
|
|
6377
6403
|
return f;
|
|
6378
6404
|
let h = f;
|
|
6379
6405
|
try {
|
|
6380
|
-
h = _u(f, u).format(
|
|
6406
|
+
h = _u(f, u).format(a);
|
|
6381
6407
|
} catch (c) {
|
|
6382
6408
|
c instanceof Error && console.warn(
|
|
6383
6409
|
`[svelte-i18n] Message "${e}" has syntax error:`,
|
|
@@ -6385,25 +6411,25 @@ const Pt = (e, t) => {
|
|
|
6385
6411
|
);
|
|
6386
6412
|
}
|
|
6387
6413
|
return h;
|
|
6388
|
-
}, gu = (e, t) => vu(t).format(e), bu = (e, t) => pu(t).format(e), yu = (e, t) => du(t).format(e), Eu = (e, t = qe()) => Zi(e, t), xu =
|
|
6389
|
-
|
|
6390
|
-
|
|
6391
|
-
|
|
6392
|
-
|
|
6414
|
+
}, gu = (e, t) => vu(t).format(e), bu = (e, t) => pu(t).format(e), yu = (e, t) => du(t).format(e), Eu = (e, t = qe()) => Zi(e, t), xu = vt([Xe, _t], () => mu);
|
|
6415
|
+
vt([Xe], () => gu);
|
|
6416
|
+
vt([Xe], () => bu);
|
|
6417
|
+
vt([Xe], () => yu);
|
|
6418
|
+
vt([Xe, _t], () => Eu);
|
|
6393
6419
|
function wu({ withLocale: e, translations: t }) {
|
|
6394
6420
|
Xe.subscribe((r) => {
|
|
6395
|
-
r == null && (
|
|
6421
|
+
r == null && (_t.set(t), Xe.set(e));
|
|
6396
6422
|
});
|
|
6397
6423
|
}
|
|
6398
6424
|
function Tu(e, t) {
|
|
6399
6425
|
Qi(e, t);
|
|
6400
6426
|
}
|
|
6401
6427
|
const Su = (e) => {
|
|
6402
|
-
let t = /* @__PURE__ */ te(void 0), r = /* @__PURE__ */ te(void 0), n = /* @__PURE__ */ te(void 0), i = /* @__PURE__ */ te(void 0), s = /* @__PURE__ */ te(!1),
|
|
6403
|
-
const
|
|
6428
|
+
let t = /* @__PURE__ */ te(void 0), r = /* @__PURE__ */ te(void 0), n = /* @__PURE__ */ te(void 0), i = /* @__PURE__ */ te(void 0), s = /* @__PURE__ */ te(!1), o = /* @__PURE__ */ te(void 0);
|
|
6429
|
+
const a = async () => {
|
|
6404
6430
|
const { apiEndpoint: u, userSession: l, locale: f, loadLevels: h, onLevelLoaded: c } = e();
|
|
6405
6431
|
if (!(!u || !l)) {
|
|
6406
|
-
Y(s, !0), Y(
|
|
6432
|
+
Y(s, !0), Y(o, void 0);
|
|
6407
6433
|
try {
|
|
6408
6434
|
const d = [
|
|
6409
6435
|
Oa({ apiEndpoint: u, userSession: l, locale: f }).then((p) => {
|
|
@@ -6416,22 +6442,22 @@ const Su = (e) => {
|
|
|
6416
6442
|
];
|
|
6417
6443
|
h && d.push(Ba({ apiEndpoint: u, userSession: l, locale: f }).then((p) => {
|
|
6418
6444
|
Y(r, p, !0);
|
|
6419
|
-
})), await Promise.all(d), await
|
|
6445
|
+
})), await Promise.all(d), await sa(), $(r) && $(t) && c?.({
|
|
6420
6446
|
calculatedLevelFlag: La($(r), $(t).loyaltyPoints ?? 0)
|
|
6421
6447
|
});
|
|
6422
6448
|
} catch (d) {
|
|
6423
|
-
Y(
|
|
6449
|
+
Y(o, d, !0), console.error("Failed to load elevate info:", d);
|
|
6424
6450
|
} finally {
|
|
6425
6451
|
Y(s, !1);
|
|
6426
6452
|
}
|
|
6427
6453
|
}
|
|
6428
6454
|
};
|
|
6429
|
-
return
|
|
6455
|
+
return vn(() => {
|
|
6430
6456
|
const { apiEndpoint: u, userSession: l, locale: f, loadLevels: h } = e();
|
|
6431
|
-
|
|
6432
|
-
}),
|
|
6457
|
+
a();
|
|
6458
|
+
}), vn(() => {
|
|
6433
6459
|
const u = () => {
|
|
6434
|
-
|
|
6460
|
+
a();
|
|
6435
6461
|
};
|
|
6436
6462
|
return window.addEventListener("redeemRewardButton", u), () => window.removeEventListener("redeemRewardButton", u);
|
|
6437
6463
|
}), {
|
|
@@ -6451,9 +6477,9 @@ const Su = (e) => {
|
|
|
6451
6477
|
return $(s);
|
|
6452
6478
|
},
|
|
6453
6479
|
get error() {
|
|
6454
|
-
return $(
|
|
6480
|
+
return $(o);
|
|
6455
6481
|
},
|
|
6456
|
-
reload:
|
|
6482
|
+
reload: a
|
|
6457
6483
|
};
|
|
6458
6484
|
}, Hu = {
|
|
6459
6485
|
en: {
|
|
@@ -6521,19 +6547,19 @@ const Bu = {
|
|
|
6521
6547
|
}`
|
|
6522
6548
|
};
|
|
6523
6549
|
function ns(e, t) {
|
|
6524
|
-
|
|
6525
|
-
const r = () =>
|
|
6550
|
+
Yr(t, !0), ya(e, Bu);
|
|
6551
|
+
const r = () => wa(xu, "$_", n), [n, i] = Ta(), s = ye(t, "apiEndpoint", 7, ""), o = ye(t, "userSession", 7, ""), a = ye(t, "locale", 7, ""), u = ye(t, "dateFormat", 7, er), l = ye(t, "onLevelLoaded", 7, (B) => {
|
|
6526
6552
|
});
|
|
6527
|
-
wu({ withLocale:
|
|
6553
|
+
wu({ withLocale: a(), translations: {} }), Object.entries(Hu).forEach(([B, K]) => {
|
|
6528
6554
|
Tu(B, K);
|
|
6529
6555
|
});
|
|
6530
6556
|
const f = Su(() => ({
|
|
6531
6557
|
apiEndpoint: s(),
|
|
6532
|
-
userSession:
|
|
6533
|
-
locale:
|
|
6558
|
+
userSession: o(),
|
|
6559
|
+
locale: a(),
|
|
6534
6560
|
loadLevels: !1,
|
|
6535
6561
|
onLevelLoaded: l()
|
|
6536
|
-
})), h = /* @__PURE__ */
|
|
6562
|
+
})), h = /* @__PURE__ */ Qe(() => f.spendableWalletTotal), c = /* @__PURE__ */ Qe(() => $(h)?.points ?? 0), d = /* @__PURE__ */ Qe(() => $(c).toLocaleString()), p = /* @__PURE__ */ Qe(() => f.loading && $(h) === void 0), b = /* @__PURE__ */ Qe(() => [...$(h)?.aboutToExpire ?? []].filter((B) => B.points > 0).sort((B, K) => new Date(B.expireTime).getTime() - new Date(K.expireTime).getTime())[0]), N = /* @__PURE__ */ Qe(() => $(b) ? Ia($(b).expireTime, u()) : "");
|
|
6537
6563
|
var G = {
|
|
6538
6564
|
get apiEndpoint() {
|
|
6539
6565
|
return s();
|
|
@@ -6542,16 +6568,16 @@ function ns(e, t) {
|
|
|
6542
6568
|
s(B), le();
|
|
6543
6569
|
},
|
|
6544
6570
|
get userSession() {
|
|
6545
|
-
return
|
|
6571
|
+
return o();
|
|
6546
6572
|
},
|
|
6547
6573
|
set userSession(B = "") {
|
|
6548
|
-
|
|
6574
|
+
o(B), le();
|
|
6549
6575
|
},
|
|
6550
6576
|
get locale() {
|
|
6551
|
-
return
|
|
6577
|
+
return a();
|
|
6552
6578
|
},
|
|
6553
6579
|
set locale(B = "") {
|
|
6554
|
-
|
|
6580
|
+
a(B), le();
|
|
6555
6581
|
},
|
|
6556
6582
|
get dateFormat() {
|
|
6557
6583
|
return u();
|
|
@@ -6566,43 +6592,43 @@ function ns(e, t) {
|
|
|
6566
6592
|
}) {
|
|
6567
6593
|
l(B), le();
|
|
6568
6594
|
}
|
|
6569
|
-
}, W =
|
|
6595
|
+
}, W = fa(), U = Ws(W);
|
|
6570
6596
|
{
|
|
6571
6597
|
var Ae = (B) => {
|
|
6572
6598
|
var K = Au();
|
|
6573
|
-
|
|
6599
|
+
Tt(B, K);
|
|
6574
6600
|
}, Z = (B) => {
|
|
6575
|
-
var K = Ou(), De = Gt(K),
|
|
6601
|
+
var K = Ou(), De = Gt(K), R = Gt(De), O = Gt(R), Ze = mr(O), gt = pn(O, 2), y = mr(gt, !0), m = pn(gt, 2);
|
|
6576
6602
|
{
|
|
6577
6603
|
var v = (g) => {
|
|
6578
6604
|
var _ = $u(), E = mr(_, !0);
|
|
6579
|
-
|
|
6605
|
+
_n((x) => yr(E, x), [
|
|
6580
6606
|
() => r()("pointsToExpire", {
|
|
6581
6607
|
values: {
|
|
6582
6608
|
points: $(b).points.toLocaleString(),
|
|
6583
6609
|
date: $(N)
|
|
6584
6610
|
}
|
|
6585
6611
|
})
|
|
6586
|
-
]),
|
|
6612
|
+
]), Tt(g, _);
|
|
6587
6613
|
};
|
|
6588
|
-
|
|
6614
|
+
wn(m, (g) => {
|
|
6589
6615
|
$(b) && g(v);
|
|
6590
6616
|
});
|
|
6591
6617
|
}
|
|
6592
|
-
Ft(
|
|
6618
|
+
Ft(R), Ft(De), Ft(K), _n(
|
|
6593
6619
|
(g, _) => {
|
|
6594
6620
|
yr(Ze, `${$(d) ?? ""}
|
|
6595
6621
|
${g ?? ""}`), yr(y, _);
|
|
6596
6622
|
},
|
|
6597
6623
|
[() => r()("tokens"), () => r()("tokenBalance")]
|
|
6598
|
-
),
|
|
6624
|
+
), Tt(B, K);
|
|
6599
6625
|
};
|
|
6600
|
-
|
|
6626
|
+
wn(U, (B) => {
|
|
6601
6627
|
$(p) ? B(Ae) : B(Z, -1);
|
|
6602
6628
|
});
|
|
6603
6629
|
}
|
|
6604
|
-
|
|
6605
|
-
var Q =
|
|
6630
|
+
Tt(e, W);
|
|
6631
|
+
var Q = zr(G);
|
|
6606
6632
|
return i(), Q;
|
|
6607
6633
|
}
|
|
6608
6634
|
Bi(
|
|
@@ -6619,9 +6645,9 @@ Bi(
|
|
|
6619
6645
|
{ mode: "open" }
|
|
6620
6646
|
);
|
|
6621
6647
|
function is(e, t) {
|
|
6622
|
-
|
|
6623
|
-
let r = ye(t, "apiEndpoint", 7, ""), n = ye(t, "userSession", 7, ""), i = ye(t, "locale", 7, ""), s = ye(t, "dateFormat", 7, er),
|
|
6624
|
-
var
|
|
6648
|
+
Yr(t, !0);
|
|
6649
|
+
let r = ye(t, "apiEndpoint", 7, ""), n = ye(t, "userSession", 7, ""), i = ye(t, "locale", 7, ""), s = ye(t, "dateFormat", 7, er), o = ye(t, "onLevelLoaded");
|
|
6650
|
+
var a = {
|
|
6625
6651
|
get apiEndpoint() {
|
|
6626
6652
|
return r();
|
|
6627
6653
|
},
|
|
@@ -6647,10 +6673,10 @@ function is(e, t) {
|
|
|
6647
6673
|
s(u), le();
|
|
6648
6674
|
},
|
|
6649
6675
|
get onLevelLoaded() {
|
|
6650
|
-
return
|
|
6676
|
+
return o();
|
|
6651
6677
|
},
|
|
6652
6678
|
set onLevelLoaded(u) {
|
|
6653
|
-
|
|
6679
|
+
o(u), le();
|
|
6654
6680
|
}
|
|
6655
6681
|
};
|
|
6656
6682
|
return ns(e, {
|
|
@@ -6667,9 +6693,9 @@ function is(e, t) {
|
|
|
6667
6693
|
return s();
|
|
6668
6694
|
},
|
|
6669
6695
|
get onLevelLoaded() {
|
|
6670
|
-
return
|
|
6696
|
+
return o();
|
|
6671
6697
|
}
|
|
6672
|
-
}),
|
|
6698
|
+
}), zr(a);
|
|
6673
6699
|
}
|
|
6674
6700
|
customElements.define("loyalty-points-card", Bi(
|
|
6675
6701
|
is,
|