@everymatrix/player-challenges 0.2.9 → 0.2.11
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/{ArrowLeftIcon-3qrKAvdj.js → ArrowLeftIcon-DNIV5-8g.js} +1 -1
- package/components/{ArrowLeftIcon-DfIi_ild.cjs → ArrowLeftIcon-QfqYgIQx.cjs} +1 -1
- package/components/{Badge-UAilzVOG.js → Badge-Bkp3Be8n.js} +1 -1
- package/components/{Badge-DFveO0N2.cjs → Badge-DdkXP5Yb.cjs} +1 -1
- package/components/{Button-DYIKg1bw.cjs → Button-B57Vo3G3.cjs} +1 -1
- package/components/{Button-CzKbnOcC.js → Button-BXCDdFbF.js} +1 -1
- package/components/{ChallengeBanner-CLOInO3g.cjs → ChallengeBanner-ByzDXXqn.cjs} +1 -1
- package/components/{ChallengeBanner-IgIai24t.js → ChallengeBanner-C4f--bCT.js} +2 -2
- package/components/{ChallengeBreadcrumbs-CJtVYxk1.js → ChallengeBreadcrumbs-BBsS3Bpn.js} +2 -2
- package/components/{ChallengeBreadcrumbs-BTbBzzQ7.cjs → ChallengeBreadcrumbs-Cv-9Lsbw.cjs} +1 -1
- package/components/{ChallengeCard-eycA-QQR.js → ChallengeCard-BNZlxERV.js} +11 -11
- package/components/{ChallengeCard-Bgbcplkq.cjs → ChallengeCard-_UeRbppG.cjs} +1 -1
- package/components/{ChallengeClaimCode-7_t0VrV1.js → ChallengeClaimCode-DUdzU0LC.js} +1 -1
- package/components/{ChallengeClaimCode-_w823IPm.cjs → ChallengeClaimCode-WX2oHf5N.cjs} +1 -1
- package/components/{ChallengeDetails-DG09x6Eu.cjs → ChallengeDetails-DIixz4MM.cjs} +1 -1
- package/components/{ChallengeDetails-DIlswoao.js → ChallengeDetails-zfJ8tMoS.js} +6 -6
- package/components/{ChallengeDetailsSkeleton-M5rC4gwT.js → ChallengeDetailsSkeleton-BdIJSnSi.js} +1 -1
- package/components/{ChallengeDetailsSkeleton--laE6pYH.cjs → ChallengeDetailsSkeleton-DsOKsD1R.cjs} +1 -1
- package/components/{ChallengeEvents-B3Bzqtoo.js → ChallengeEvents-Ck70Zndc.js} +2 -2
- package/components/{ChallengeEvents-eIpuL6Yk.cjs → ChallengeEvents-CnnAyR0A.cjs} +1 -1
- package/components/{ChallengeGames-L5TQ1wVu.js → ChallengeGames-6HCHFbpI.js} +1 -1
- package/components/{ChallengeGames-B8Vm2L5G.cjs → ChallengeGames-CoTRQLpo.cjs} +1 -1
- package/components/{ChallengeHistory-CfySyCJf.cjs → ChallengeHistory-DqCzIUzj.cjs} +1 -1
- package/components/{ChallengeHistory-Cpr3ZtU1.js → ChallengeHistory-_zDNsENb.js} +6 -6
- package/components/{ChallengeLevels-BcKvLTo3.js → ChallengeLevels-CR6HhrMw.js} +7 -7
- package/components/{ChallengeLevels-h_sq1iMg.cjs → ChallengeLevels-bQ3nHVNo.cjs} +1 -1
- package/components/{ChallengeList-BdM811gO.cjs → ChallengeList-D2xLWscW.cjs} +1 -1
- package/components/{ChallengeList-DynA4UU9.js → ChallengeList-D7m6ACxU.js} +3 -3
- package/components/{ChallengeProgress-Dg6HSNMv.cjs → ChallengeProgress-BUrXyqQy.cjs} +1 -1
- package/components/{ChallengeProgress-NWAKjOv2.js → ChallengeProgress-DTh7K-sN.js} +2 -2
- package/components/{ChallengeProgressItem-Cxzfd65S.cjs → ChallengeProgressItem-CgzTT7-K.cjs} +1 -1
- package/components/{ChallengeProgressItem-D44UERwx.js → ChallengeProgressItem-G2nUuOIK.js} +4 -4
- package/components/{ChallengeRules-CyKZ9sRh.js → ChallengeRules-BNa3blaQ.js} +3 -3
- package/components/{ChallengeRules-CoSSDWCX.cjs → ChallengeRules-hJ1Osrxh.cjs} +1 -1
- package/components/{ChallengeSummary-B4Vp1cu8.cjs → ChallengeSummary-C37YVioc.cjs} +1 -1
- package/components/{ChallengeSummary-BoDIsHBs.js → ChallengeSummary-CkrogcIj.js} +6 -6
- package/components/{ChallengeTabContent-qwpLkxSQ.cjs → ChallengeTabContent-CZRc31Qo.cjs} +1 -1
- package/components/{ChallengeTabContent-DjqSySNS.js → ChallengeTabContent-DhtcRBy7.js} +4 -4
- package/components/{ChallengeTabPanel-DFXF6VqV.js → ChallengeTabPanel-BPBeq2_F.js} +5 -5
- package/components/{ChallengeTabPanel-DYPhrVRz.cjs → ChallengeTabPanel-Dav8iUp5.cjs} +1 -1
- package/components/{ChallengeTabs-B5g-SF2b.cjs → ChallengeTabs-BQwyIqRw.cjs} +7 -7
- package/components/{ChallengeTabs-_vjQrF0A.js → ChallengeTabs-DlIm0kQA.js} +701 -706
- package/components/{CheckIcon-0LtHk7fE.cjs → CheckIcon-_cdi2aOf.cjs} +1 -1
- package/components/{CheckIcon-BfH-d7h_.js → CheckIcon-b6YSOHVD.js} +1 -1
- package/components/{ChevronIcon-D-mzPrXJ.js → ChevronIcon-BsSMnLDy.js} +1 -1
- package/components/{ChevronIcon-BfZDLe6C.cjs → ChevronIcon-HtcwODyx.cjs} +1 -1
- package/components/{ChipIcon-BAasRRs4.js → ChipIcon-DvWRsQ0Q.js} +1 -1
- package/components/{ChipIcon-ChCUc7Ro.cjs → ChipIcon-GS02_pQp.cjs} +1 -1
- package/components/{ChipShineIcon-BiuHUnXR.cjs → ChipShineIcon-13y5rm-O.cjs} +1 -1
- package/components/{ChipShineIcon-CoeUovBC.js → ChipShineIcon-2b4urtuI.js} +1 -1
- package/components/{ExistIcon-Dv8paf_U.js → ExistIcon-BTW-f6eh.js} +1 -1
- package/components/{ExistIcon-CfsNk2my.cjs → ExistIcon-j-Ws6wHF.cjs} +1 -1
- package/components/{GiftIcon-Mnb_Nxbd.js → GiftIcon-CGxyDjCt.js} +1 -1
- package/components/{GiftIcon-BH735MXR.cjs → GiftIcon-pxDmtiHo.cjs} +1 -1
- package/components/{LinkIcon-Du4_pcZZ.cjs → LinkIcon-DWGLGHt-.cjs} +1 -1
- package/components/{LinkIcon-DiVYY9ci.js → LinkIcon-LXZ_j-cE.js} +1 -1
- package/components/{LockIcon-QA92rEFW.cjs → LockIcon-BbtIAyXX.cjs} +1 -1
- package/components/{LockIcon-KP_pUGJo.js → LockIcon-DVWzhbJi.js} +1 -1
- package/components/{Pagination-DfqNdchM.cjs → Pagination-Bhm3RwLH.cjs} +1 -1
- package/components/{Pagination-DQklVx0w.js → Pagination-DEIFcNa_.js} +1 -1
- package/components/{PlayerChallenges-BVshv0hR.cjs → PlayerChallenges-C0vOmVPX.cjs} +1 -1
- package/components/{PlayerChallenges-Cj6-v75C.js → PlayerChallenges-Eqb2Qmj3.js} +4 -4
- package/components/{StarIcon-DturCxI3.cjs → StarIcon-CsDWGoS3.cjs} +1 -1
- package/components/{StarIcon-DTSu1OOQ.js → StarIcon-wls7CR78.js} +1 -1
- package/components/{TargetIcon-BlVaf2Xr.cjs → TargetIcon-CKQJBgFo.cjs} +1 -1
- package/components/{TargetIcon-CJJKDeVK.js → TargetIcon-Dq082mBh.js} +1 -1
- package/components/{helpers-B2y_AV0y.js → helpers-4M9dJQ89.js} +1 -1
- package/components/{helpers-BmTQLAcy.cjs → helpers-Za4oasat.cjs} +1 -1
- package/esnext/player-challenges.cjs +1 -1
- package/esnext/player-challenges.js +2 -2
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { C as Wn } from "./types-C1hrKH4R.js";
|
|
2
|
-
import { g as E2 } from "./helpers-
|
|
2
|
+
import { g as E2 } from "./helpers-4M9dJQ89.js";
|
|
3
3
|
typeof globalThis.HTMLElement > "u" && (globalThis.HTMLElement = class {
|
|
4
4
|
}, globalThis.customElements = { define() {
|
|
5
5
|
}, get() {
|
|
@@ -7,9 +7,9 @@ typeof globalThis.HTMLElement > "u" && (globalThis.HTMLElement = class {
|
|
|
7
7
|
} });
|
|
8
8
|
const A2 = "5";
|
|
9
9
|
typeof window < "u" && ((window.__svelte ??= {}).v ??= /* @__PURE__ */ new Set()).add(A2);
|
|
10
|
-
const x2 = 1, S2 = 2, wi = 4, w2 = 8, L2 = 16, B2 = 1, T2 = 4, I2 = 8, M2 = 16, _2 = 1, O2 = 2, Li = "[", d0 = "[!", Y0 = "[?", p0 = "]", _t = {},
|
|
10
|
+
const x2 = 1, S2 = 2, wi = 4, w2 = 8, L2 = 16, B2 = 1, T2 = 4, I2 = 8, M2 = 16, _2 = 1, O2 = 2, Li = "[", d0 = "[!", Y0 = "[?", p0 = "]", _t = {}, ye = Symbol("uninitialized"), P2 = "http://www.w3.org/1999/xhtml", Bi = !1;
|
|
11
11
|
var Ti = Array.isArray, F2 = Array.prototype.indexOf, Mn = Array.prototype.includes, mr = Array.from, ir = Object.keys, nn = Object.defineProperty, kt = Object.getOwnPropertyDescriptor, H2 = Object.getOwnPropertyDescriptors, D2 = Object.prototype, N2 = Array.prototype, Ii = Object.getPrototypeOf, W0 = Object.isExtensible;
|
|
12
|
-
const
|
|
12
|
+
const Ct = () => {
|
|
13
13
|
};
|
|
14
14
|
function Mi(e) {
|
|
15
15
|
for (var t = 0; t < e.length; t++)
|
|
@@ -21,7 +21,7 @@ function _i() {
|
|
|
21
21
|
});
|
|
22
22
|
return { promise: n, resolve: e, reject: t };
|
|
23
23
|
}
|
|
24
|
-
const Be = 2, rn = 4, Nn = 8, Oi = 1 << 24, qe = 16, et = 32, At = 64, jr = 128, v0 = 256, $e = 512,
|
|
24
|
+
const Be = 2, rn = 4, Nn = 8, Oi = 1 << 24, qe = 16, et = 32, At = 64, jr = 128, v0 = 256, $e = 512, Ce = 1024, le = 2048, ze = 4096, Oe = 8192, xe = 16384, zt = 32768, _n = 1 << 25, sn = 65536, sr = 1 << 17, R2 = 1 << 18, Vt = 1 << 19, Pi = 1 << 20, st = 1 << 25, or = 1 << 21, $t = 1 << 22, It = 1 << 23, wn = Symbol("$state"), Fi = Symbol("component"), Hi = Symbol("legacy props"), k2 = Symbol(""), Di = Symbol("attributes"), zr = Symbol("class"), Vr = Symbol("style"), Xr = Symbol("text"), Ni = Symbol("form reset"), Rn = new class extends Error {
|
|
25
25
|
name = "StaleReactionError";
|
|
26
26
|
message = "The reaction that called `getAbortSignal()` was re-run or destroyed";
|
|
27
27
|
}(), Ri = (
|
|
@@ -31,34 +31,34 @@ const Be = 2, rn = 4, Nn = 8, Oi = 1 << 24, qe = 16, et = 32, At = 64, jr = 128,
|
|
|
31
31
|
function G2() {
|
|
32
32
|
console.warn("https://svelte.dev/e/derived_inert");
|
|
33
33
|
}
|
|
34
|
-
function
|
|
34
|
+
function yr(e) {
|
|
35
35
|
console.warn("https://svelte.dev/e/hydration_mismatch");
|
|
36
36
|
}
|
|
37
37
|
function U2() {
|
|
38
38
|
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
39
39
|
}
|
|
40
|
-
let
|
|
41
|
-
function
|
|
42
|
-
|
|
40
|
+
let Z = !1;
|
|
41
|
+
function yt(e) {
|
|
42
|
+
Z = e;
|
|
43
43
|
}
|
|
44
44
|
let W;
|
|
45
45
|
function Re(e) {
|
|
46
46
|
if (e === null)
|
|
47
|
-
throw
|
|
47
|
+
throw yr(), _t;
|
|
48
48
|
return W = e;
|
|
49
49
|
}
|
|
50
50
|
function kn() {
|
|
51
51
|
return Re(/* @__PURE__ */ ht(W));
|
|
52
52
|
}
|
|
53
53
|
function ar(e) {
|
|
54
|
-
if (
|
|
54
|
+
if (Z) {
|
|
55
55
|
if (/* @__PURE__ */ ht(W) !== null)
|
|
56
|
-
throw
|
|
56
|
+
throw yr(), _t;
|
|
57
57
|
W = e;
|
|
58
58
|
}
|
|
59
59
|
}
|
|
60
60
|
function j2(e = 1) {
|
|
61
|
-
if (
|
|
61
|
+
if (Z) {
|
|
62
62
|
for (var t = e, n = W; t--; )
|
|
63
63
|
n = /** @type {TemplateNode} */
|
|
64
64
|
/* @__PURE__ */ ht(n);
|
|
@@ -87,7 +87,7 @@ function lr(e = !0) {
|
|
|
87
87
|
}
|
|
88
88
|
function g0(e) {
|
|
89
89
|
if (!e || e.nodeType !== dn)
|
|
90
|
-
throw
|
|
90
|
+
throw yr(), _t;
|
|
91
91
|
return (
|
|
92
92
|
/** @type {Comment} */
|
|
93
93
|
e.data
|
|
@@ -155,7 +155,7 @@ function m0(e, t = !1, n) {
|
|
|
155
155
|
x: null,
|
|
156
156
|
r: (
|
|
157
157
|
/** @type {Effect} */
|
|
158
|
-
|
|
158
|
+
K
|
|
159
159
|
),
|
|
160
160
|
l: null
|
|
161
161
|
};
|
|
@@ -170,9 +170,9 @@ function b0(e) {
|
|
|
170
170
|
for (var r of n)
|
|
171
171
|
us(r);
|
|
172
172
|
}
|
|
173
|
-
return e !== void 0 && (t.x = e), t.i = !0, Se = t.p,
|
|
173
|
+
return e !== void 0 && (t.x = e), t.i = !0, Se = t.p, y0(e);
|
|
174
174
|
}
|
|
175
|
-
function
|
|
175
|
+
function y0(e = {}) {
|
|
176
176
|
return nn(e, Fi, { value: !0 }), e;
|
|
177
177
|
}
|
|
178
178
|
function zi() {
|
|
@@ -197,14 +197,14 @@ function no() {
|
|
|
197
197
|
Vi();
|
|
198
198
|
}
|
|
199
199
|
const ro = -7169;
|
|
200
|
-
function
|
|
200
|
+
function ge(e, t) {
|
|
201
201
|
e.f = e.f & ro | t;
|
|
202
202
|
}
|
|
203
|
-
function
|
|
204
|
-
e.f & $e || e.deps === null ?
|
|
203
|
+
function C0(e) {
|
|
204
|
+
e.f & $e || e.deps === null ? ge(e, Ce) : ge(e, ze);
|
|
205
205
|
}
|
|
206
|
-
function Xi(e, t
|
|
207
|
-
e.f &
|
|
206
|
+
function Xi(e, t) {
|
|
207
|
+
e.f & le ? t.set(e, le) : e.f & ze && t.get(e) !== le && t.set(e, ze), ge(e, Ce);
|
|
208
208
|
}
|
|
209
209
|
let Q0 = !1;
|
|
210
210
|
function io() {
|
|
@@ -226,7 +226,7 @@ function io() {
|
|
|
226
226
|
));
|
|
227
227
|
}
|
|
228
228
|
function Gn(e) {
|
|
229
|
-
var t =
|
|
229
|
+
var t = J, n = K;
|
|
230
230
|
We(null), ct(null);
|
|
231
231
|
try {
|
|
232
232
|
return e();
|
|
@@ -243,7 +243,7 @@ function so(e, t, n, r) {
|
|
|
243
243
|
}
|
|
244
244
|
var a = (
|
|
245
245
|
/** @type {Effect} */
|
|
246
|
-
|
|
246
|
+
K
|
|
247
247
|
), l = oo(), u = s.length === 1 ? s[0].promise : s.length > 1 ? Promise.all(s.map((h) => h.promise)) : null;
|
|
248
248
|
function f(h) {
|
|
249
249
|
if (!(a.f & xe)) {
|
|
@@ -275,8 +275,8 @@ function so(e, t, n, r) {
|
|
|
275
275
|
function oo() {
|
|
276
276
|
var e = (
|
|
277
277
|
/** @type {Effect} */
|
|
278
|
-
|
|
279
|
-
), t =
|
|
278
|
+
K
|
|
279
|
+
), t = J, n = Se, r = (
|
|
280
280
|
/** @type {Batch} */
|
|
281
281
|
re
|
|
282
282
|
);
|
|
@@ -290,7 +290,7 @@ function ur(e = !0) {
|
|
|
290
290
|
function Yi() {
|
|
291
291
|
var e = (
|
|
292
292
|
/** @type {Effect} */
|
|
293
|
-
|
|
293
|
+
K
|
|
294
294
|
), t = e.b, n = (
|
|
295
295
|
/** @type {Batch} */
|
|
296
296
|
re
|
|
@@ -301,8 +301,8 @@ function Yi() {
|
|
|
301
301
|
}
|
|
302
302
|
// @__NO_SIDE_EFFECTS__
|
|
303
303
|
function On(e) {
|
|
304
|
-
var t = Be |
|
|
305
|
-
return
|
|
304
|
+
var t = Be | le;
|
|
305
|
+
return K !== null && (K.f |= Vt), {
|
|
306
306
|
ctx: Se,
|
|
307
307
|
deps: null,
|
|
308
308
|
effects: null,
|
|
@@ -313,19 +313,19 @@ function On(e) {
|
|
|
313
313
|
rv: 0,
|
|
314
314
|
v: (
|
|
315
315
|
/** @type {V} */
|
|
316
|
-
|
|
316
|
+
ye
|
|
317
317
|
),
|
|
318
318
|
wv: 0,
|
|
319
|
-
parent:
|
|
319
|
+
parent: K,
|
|
320
320
|
ac: null
|
|
321
321
|
};
|
|
322
322
|
}
|
|
323
|
-
const
|
|
323
|
+
const Cn = Symbol("obsolete");
|
|
324
324
|
// @__NO_SIDE_EFFECTS__
|
|
325
325
|
function ao(e, t, n) {
|
|
326
326
|
let r = (
|
|
327
327
|
/** @type {Effect | null} */
|
|
328
|
-
|
|
328
|
+
K
|
|
329
329
|
);
|
|
330
330
|
r === null && z2();
|
|
331
331
|
var i = (
|
|
@@ -334,12 +334,12 @@ function ao(e, t, n) {
|
|
|
334
334
|
void 0
|
|
335
335
|
), s = jt(
|
|
336
336
|
/** @type {V} */
|
|
337
|
-
|
|
338
|
-
), o = !
|
|
339
|
-
return
|
|
337
|
+
ye
|
|
338
|
+
), o = !J, a = /* @__PURE__ */ new Set();
|
|
339
|
+
return Co(() => {
|
|
340
340
|
var l = (
|
|
341
341
|
/** @type {Effect} */
|
|
342
|
-
|
|
342
|
+
K
|
|
343
343
|
), u = _i();
|
|
344
344
|
i = u.promise;
|
|
345
345
|
try {
|
|
@@ -360,19 +360,19 @@ function ao(e, t, n) {
|
|
|
360
360
|
// boundary can be null if the async derived is inside an $effect.root not connected to the component render tree
|
|
361
361
|
r.b?.is_rendered()
|
|
362
362
|
)
|
|
363
|
-
f.async_deriveds.get(l)?.reject(
|
|
363
|
+
f.async_deriveds.get(l)?.reject(Cn);
|
|
364
364
|
else
|
|
365
365
|
for (const h of a.values())
|
|
366
|
-
h.reject(
|
|
366
|
+
h.reject(Cn);
|
|
367
367
|
a.add(u), f.async_deriveds.set(l, u);
|
|
368
368
|
}
|
|
369
369
|
const p = (h, g = void 0) => {
|
|
370
|
-
c?.(), a.delete(u), g !==
|
|
370
|
+
c?.(), a.delete(u), g !== Cn && (f.activate(), g ? (s.f |= It, an(s, g)) : (s.f & It && (s.f ^= It), an(s, h)), f.deactivate());
|
|
371
371
|
};
|
|
372
372
|
u.promise.then(p, (h) => p(null, h || "unknown"));
|
|
373
373
|
}), T0(() => {
|
|
374
374
|
for (const l of a)
|
|
375
|
-
l.reject(
|
|
375
|
+
l.reject(Cn);
|
|
376
376
|
}), new Promise((l) => {
|
|
377
377
|
function u(f) {
|
|
378
378
|
function c() {
|
|
@@ -405,13 +405,13 @@ function lo(e) {
|
|
|
405
405
|
}
|
|
406
406
|
}
|
|
407
407
|
function E0(e) {
|
|
408
|
-
var t, n =
|
|
409
|
-
if (!St && r !== null && e.v !==
|
|
408
|
+
var t, n = K, r = e.parent;
|
|
409
|
+
if (!St && r !== null && e.v !== ye && // if it was never evaluated before, it's guaranteed to fail downstream, so we try to execute instead
|
|
410
410
|
r.f & (xe | Oe))
|
|
411
411
|
return G2(), e.v;
|
|
412
412
|
ct(r);
|
|
413
413
|
try {
|
|
414
|
-
lo(e), t =
|
|
414
|
+
lo(e), t = ys(e);
|
|
415
415
|
} finally {
|
|
416
416
|
ct(n);
|
|
417
417
|
}
|
|
@@ -420,17 +420,17 @@ function E0(e) {
|
|
|
420
420
|
function Qi(e) {
|
|
421
421
|
var t = E0(e);
|
|
422
422
|
if (!e.equals(t) && (e.wv = ms(), (!re?.is_fork || e.deps === null) && (re !== null ? (re.capture(e, t, !0), en?.capture(e, t, !0)) : e.v = t, e.deps === null))) {
|
|
423
|
-
|
|
423
|
+
ge(e, Ce);
|
|
424
424
|
return;
|
|
425
425
|
}
|
|
426
|
-
St || (Je !== null ? (B0() || re?.is_fork) && Je.set(e, t) :
|
|
426
|
+
St || (Je !== null ? (B0() || re?.is_fork) && Je.set(e, t) : C0(e));
|
|
427
427
|
}
|
|
428
428
|
function uo(e) {
|
|
429
429
|
if (e.effects !== null)
|
|
430
430
|
for (const t of e.effects)
|
|
431
431
|
(t.teardown || t.ac) && (t.teardown?.(), t.ac !== null && Gn(() => {
|
|
432
432
|
t.ac.abort(Rn), t.ac = null;
|
|
433
|
-
}), t.fn !== null && (t.teardown =
|
|
433
|
+
}), t.fn !== null && (t.teardown = Ct), Fn(t, 0), O0(t));
|
|
434
434
|
}
|
|
435
435
|
function Zi(e) {
|
|
436
436
|
if (e.effects !== null)
|
|
@@ -443,24 +443,24 @@ let fo = 1;
|
|
|
443
443
|
class xt {
|
|
444
444
|
id = fo++;
|
|
445
445
|
/** True as soon as `#process` was called */
|
|
446
|
-
|
|
446
|
+
started = !1;
|
|
447
447
|
linked = !0;
|
|
448
448
|
/** @type {Batch | null} */
|
|
449
|
-
|
|
449
|
+
prev = null;
|
|
450
450
|
/** @type {Batch | null} */
|
|
451
|
-
|
|
451
|
+
next = null;
|
|
452
452
|
/** @type {Map<Effect, ReturnType<typeof deferred<any>>>} */
|
|
453
453
|
async_deriveds = /* @__PURE__ */ new Map();
|
|
454
454
|
/**
|
|
455
455
|
* The current values of any signals that are updated in this batch.
|
|
456
456
|
* Tuple format: [value, is_derived] (note: is_derived is false for deriveds, too, if they were overridden via assignment)
|
|
457
|
-
*
|
|
457
|
+
* The keys of this map are identical to `this.previous`
|
|
458
458
|
* @type {Map<Value, [any, boolean]>}
|
|
459
459
|
*/
|
|
460
460
|
current = /* @__PURE__ */ new Map();
|
|
461
461
|
/**
|
|
462
462
|
* The values of any signals (sources and deriveds) that are updated in this batch _before_ those updates took place.
|
|
463
|
-
*
|
|
463
|
+
* The keys of this map are identical to `this.current`
|
|
464
464
|
* @type {Map<Value, any>}
|
|
465
465
|
*/
|
|
466
466
|
previous = /* @__PURE__ */ new Map();
|
|
@@ -469,27 +469,27 @@ class xt {
|
|
|
469
469
|
* and append new ones by calling the functions added inside (if/each/key/etc) blocks
|
|
470
470
|
* @type {Set<(batch: Batch) => void>}
|
|
471
471
|
*/
|
|
472
|
-
#
|
|
472
|
+
#e = /* @__PURE__ */ new Set();
|
|
473
473
|
/**
|
|
474
474
|
* If a fork is discarded, we need to destroy any effects that are no longer needed
|
|
475
475
|
* @type {Set<(batch: Batch) => void>}
|
|
476
476
|
*/
|
|
477
|
-
#
|
|
477
|
+
#t = /* @__PURE__ */ new Set();
|
|
478
478
|
/**
|
|
479
479
|
* The number of async effects that are currently in flight
|
|
480
480
|
*/
|
|
481
|
-
#
|
|
481
|
+
#n = 0;
|
|
482
482
|
/**
|
|
483
483
|
* Async effects that are currently in flight, _not_ inside a pending boundary
|
|
484
484
|
* @type {Map<Effect, number>}
|
|
485
485
|
*/
|
|
486
|
-
#
|
|
486
|
+
#s = /* @__PURE__ */ new Map();
|
|
487
487
|
/**
|
|
488
488
|
* A deferred that resolves when the batch is committed, used with `settled()`
|
|
489
489
|
* TODO replace with Promise.withResolvers once supported widely enough
|
|
490
490
|
* @type {{ promise: Promise<void>, resolve: (value?: any) => void, reject: (reason: unknown) => void } | null}
|
|
491
491
|
*/
|
|
492
|
-
#
|
|
492
|
+
#r = null;
|
|
493
493
|
/**
|
|
494
494
|
* Effects that were scheduled in this batch but not yet 'resolved' into the
|
|
495
495
|
* root effects that need to be flushed. Resolving — the upwards traversal that
|
|
@@ -501,22 +501,17 @@ class xt {
|
|
|
501
501
|
* May contain duplicates — deduplication happens during resolving
|
|
502
502
|
* @type {Effect[]}
|
|
503
503
|
*/
|
|
504
|
-
#
|
|
504
|
+
#i = [];
|
|
505
505
|
/**
|
|
506
506
|
* Effects created while this batch was active.
|
|
507
507
|
* @type {Effect[]}
|
|
508
508
|
*/
|
|
509
|
-
#
|
|
510
|
-
/**
|
|
511
|
-
* Deferred effects (which run after async work has completed) that are DIRTY
|
|
512
|
-
* @type {Set<Effect>}
|
|
513
|
-
*/
|
|
514
|
-
#u = /* @__PURE__ */ new Set();
|
|
509
|
+
#a = [];
|
|
515
510
|
/**
|
|
516
|
-
* Deferred effects
|
|
517
|
-
* @type {
|
|
511
|
+
* Deferred effects (which run after async work has completed) and their status (DIRTY or MAYBE_DIRTY)
|
|
512
|
+
* @type {Map<Effect, number>}
|
|
518
513
|
*/
|
|
519
|
-
#
|
|
514
|
+
#o = /* @__PURE__ */ new Map();
|
|
520
515
|
/**
|
|
521
516
|
* A map of branches that still exist, but will be destroyed when this batch
|
|
522
517
|
* is committed — we skip over these during `process`.
|
|
@@ -524,30 +519,34 @@ class xt {
|
|
|
524
519
|
* so they can be rescheduled if the branch survives.
|
|
525
520
|
* @type {Map<Effect, { d: Effect[], m: Effect[] }>}
|
|
526
521
|
*/
|
|
527
|
-
#
|
|
522
|
+
#l = /* @__PURE__ */ new Map();
|
|
528
523
|
/**
|
|
529
524
|
* Inverse of #skipped_branches which we need to tell prior batches to unskip them when committing
|
|
530
525
|
* @type {Set<Effect>}
|
|
531
526
|
*/
|
|
532
|
-
#
|
|
527
|
+
#d = /* @__PURE__ */ new Set();
|
|
533
528
|
is_fork = !1;
|
|
534
|
-
#
|
|
529
|
+
#u = !1;
|
|
535
530
|
constructor() {
|
|
536
|
-
qt === null ? Ir = qt = this : (qt
|
|
531
|
+
qt === null ? Ir = qt = this : (qt.next = this, this.prev = qt), qt = this;
|
|
537
532
|
}
|
|
538
|
-
#
|
|
533
|
+
#v() {
|
|
539
534
|
if (this.is_fork) return !0;
|
|
540
|
-
for (const
|
|
541
|
-
|
|
542
|
-
if (this.#h.has(t)) {
|
|
543
|
-
n = !0;
|
|
544
|
-
break;
|
|
545
|
-
}
|
|
546
|
-
t = t.parent;
|
|
547
|
-
}
|
|
548
|
-
if (!n)
|
|
535
|
+
for (const t of this.#s.keys())
|
|
536
|
+
if (!this.#m(t))
|
|
549
537
|
return !0;
|
|
550
|
-
|
|
538
|
+
return !1;
|
|
539
|
+
}
|
|
540
|
+
/**
|
|
541
|
+
* Whether `effect` is inside a branch that this batch skips
|
|
542
|
+
* @param {Effect} effect
|
|
543
|
+
*/
|
|
544
|
+
#m(t) {
|
|
545
|
+
for (var n = (
|
|
546
|
+
/** @type {Effect | null} */
|
|
547
|
+
t
|
|
548
|
+
); n !== null; n = n.parent)
|
|
549
|
+
if (this.#l.has(n)) return !0;
|
|
551
550
|
return !1;
|
|
552
551
|
}
|
|
553
552
|
/**
|
|
@@ -555,7 +554,7 @@ class xt {
|
|
|
555
554
|
* @param {Effect} effect
|
|
556
555
|
*/
|
|
557
556
|
skip_effect(t) {
|
|
558
|
-
this.#
|
|
557
|
+
this.#l.has(t) || this.#l.set(t, { d: [], m: [] }), this.#d.delete(t);
|
|
559
558
|
}
|
|
560
559
|
/**
|
|
561
560
|
* Remove an effect from the #skipped_branches map and reschedule
|
|
@@ -564,15 +563,15 @@ class xt {
|
|
|
564
563
|
* @param {(e: Effect) => void} callback
|
|
565
564
|
*/
|
|
566
565
|
unskip_effect(t, n = (r) => this.schedule(r)) {
|
|
567
|
-
var r = this.#
|
|
566
|
+
var r = this.#l.get(t);
|
|
568
567
|
if (r) {
|
|
569
|
-
this.#
|
|
568
|
+
this.#l.delete(t);
|
|
570
569
|
for (var i of r.d)
|
|
571
|
-
|
|
570
|
+
ge(i, le), n(i);
|
|
572
571
|
for (i of r.m)
|
|
573
|
-
|
|
572
|
+
ge(i, ze), n(i);
|
|
574
573
|
}
|
|
575
|
-
this.#
|
|
574
|
+
this.#d.add(t);
|
|
576
575
|
}
|
|
577
576
|
/**
|
|
578
577
|
* Convert the effects that were scheduled in this batch into the root effects
|
|
@@ -583,39 +582,37 @@ class xt {
|
|
|
583
582
|
* a single traversal — scheduling into other batches can never observe them
|
|
584
583
|
* @returns {Effect[]}
|
|
585
584
|
*/
|
|
586
|
-
#
|
|
585
|
+
#f() {
|
|
587
586
|
var t = [];
|
|
588
|
-
for (const s of this.#
|
|
589
|
-
if (!(s.f & xe || !(s.f & (
|
|
587
|
+
for (const s of this.#i)
|
|
588
|
+
if (!(s.f & xe || !(s.f & (le | ze)))) {
|
|
590
589
|
for (var n = s, r = !1; n.parent !== null; ) {
|
|
591
590
|
n = n.parent;
|
|
592
591
|
var i = n.f;
|
|
593
592
|
if (i & (At | et)) {
|
|
594
|
-
if (!(i &
|
|
593
|
+
if (!(i & Ce)) {
|
|
595
594
|
r = !0;
|
|
596
595
|
break;
|
|
597
596
|
}
|
|
598
|
-
n.f ^=
|
|
597
|
+
n.f ^= Ce;
|
|
599
598
|
}
|
|
600
599
|
}
|
|
601
600
|
r || t.push(n);
|
|
602
601
|
}
|
|
603
|
-
return this.#
|
|
602
|
+
return this.#i = [], t;
|
|
604
603
|
}
|
|
605
|
-
#
|
|
606
|
-
this
|
|
607
|
-
for (const a of this.#
|
|
608
|
-
|
|
609
|
-
for (const a of this.#f)
|
|
610
|
-
de(a, Xe), this.schedule(a);
|
|
604
|
+
#g() {
|
|
605
|
+
this.started = !0;
|
|
606
|
+
for (const [a, l] of this.#o)
|
|
607
|
+
ge(a, l), this.schedule(a);
|
|
611
608
|
this.apply();
|
|
612
|
-
for (var t = Bn = [], n = [], r = $n = []; this.#
|
|
613
|
-
Z0++ > 1e3 && (this.#
|
|
614
|
-
for (const a of this.#
|
|
609
|
+
for (var t = Bn = [], n = [], r = $n = []; this.#i.length > 0; ) {
|
|
610
|
+
Z0++ > 1e3 && (this.#h(), co());
|
|
611
|
+
for (const a of this.#f())
|
|
615
612
|
try {
|
|
616
|
-
this.#
|
|
613
|
+
this.#b(a, t, n);
|
|
617
614
|
} catch (l) {
|
|
618
|
-
throw Ki(a), this.#
|
|
615
|
+
throw Ki(a), this.#v() || this.discard(), l;
|
|
619
616
|
}
|
|
620
617
|
}
|
|
621
618
|
if (re = null, r.length > 0) {
|
|
@@ -623,35 +620,28 @@ class xt {
|
|
|
623
620
|
for (const a of r)
|
|
624
621
|
i.schedule(a);
|
|
625
622
|
}
|
|
626
|
-
if (Bn = null, $n = null, this.#
|
|
623
|
+
if (Bn = null, $n = null, this.#v()) {
|
|
627
624
|
this.#p(n), this.#p(t);
|
|
628
|
-
for (const [a, l] of this.#
|
|
625
|
+
for (const [a, l] of this.#l)
|
|
629
626
|
Ji(a, l);
|
|
630
627
|
r.length > 0 && /** @type {unknown} */
|
|
631
|
-
re.#
|
|
628
|
+
re.#g();
|
|
632
629
|
return;
|
|
633
630
|
}
|
|
634
|
-
const s = this.#
|
|
631
|
+
const s = this.#C();
|
|
635
632
|
if (s) {
|
|
636
|
-
this.#p(n), this.#p(t), s.#
|
|
633
|
+
this.#p(n), this.#p(t), s.#c(this);
|
|
637
634
|
return;
|
|
638
635
|
}
|
|
639
|
-
this.#
|
|
640
|
-
for (const a of this.#
|
|
641
|
-
this.#
|
|
636
|
+
this.#o.clear();
|
|
637
|
+
for (const a of this.#e) a(this);
|
|
638
|
+
this.#e.clear(), en = this, q0(n), q0(t), en = null, this.#r?.resolve();
|
|
642
639
|
var o = (
|
|
643
640
|
/** @type {Batch | null} */
|
|
644
641
|
/** @type {unknown} */
|
|
645
642
|
re
|
|
646
643
|
);
|
|
647
|
-
|
|
648
|
-
if (o !== null) {
|
|
649
|
-
for (const a of this.#s)
|
|
650
|
-
o.#s.push(a);
|
|
651
|
-
this.#s = [];
|
|
652
|
-
} else
|
|
653
|
-
o = this;
|
|
654
|
-
o !== null && (at.clear(), o.#b());
|
|
644
|
+
this.#n === 0 && (this.#i.length === 0 || o !== null) && this.#h(), o !== null && (at.clear(), o.#g());
|
|
655
645
|
}
|
|
656
646
|
/**
|
|
657
647
|
* Traverse the effect tree, executing effects or stashing
|
|
@@ -660,12 +650,12 @@ class xt {
|
|
|
660
650
|
* @param {Effect[]} effects
|
|
661
651
|
* @param {Effect[]} render_effects
|
|
662
652
|
*/
|
|
663
|
-
#
|
|
664
|
-
t.f ^=
|
|
653
|
+
#b(t, n, r) {
|
|
654
|
+
t.f ^= Ce;
|
|
665
655
|
for (var i = t.first; i !== null; ) {
|
|
666
|
-
var s = i.f, o = (s & (et | At)) !== 0, a = o && (s &
|
|
656
|
+
var s = i.f, o = (s & (et | At)) !== 0, a = o && (s & Ce) !== 0, l = a || (s & Oe) !== 0 || this.#l.has(i);
|
|
667
657
|
if (!l && i.fn !== null) {
|
|
668
|
-
o ? i.f ^=
|
|
658
|
+
o ? i.f ^= Ce : s & rn ? n.push(i) : Un(i) && (s & qe && this.add_dirty_reaction(i, ze), ln(i));
|
|
669
659
|
var u = i.first;
|
|
670
660
|
if (u !== null) {
|
|
671
661
|
i = u;
|
|
@@ -682,31 +672,32 @@ class xt {
|
|
|
682
672
|
}
|
|
683
673
|
}
|
|
684
674
|
}
|
|
685
|
-
#
|
|
686
|
-
for (var t = this
|
|
687
|
-
if (!t.is_fork)
|
|
688
|
-
for (const [n, [, r]] of this.current)
|
|
689
|
-
if (t.current.has(n) && !r)
|
|
690
|
-
return t;
|
|
691
|
-
}
|
|
692
|
-
t = t.#t;
|
|
693
|
-
}
|
|
675
|
+
#C() {
|
|
676
|
+
for (var t = this.prev; t !== null; t = t.prev)
|
|
677
|
+
if (!t.is_fork && this.#y(t)) return t;
|
|
694
678
|
return null;
|
|
695
679
|
}
|
|
680
|
+
/** @param {Batch} batch */
|
|
681
|
+
#y(t) {
|
|
682
|
+
for (const [n, [, r]] of this.current)
|
|
683
|
+
if (!r && t.current.has(n))
|
|
684
|
+
return !0;
|
|
685
|
+
return !1;
|
|
686
|
+
}
|
|
696
687
|
/**
|
|
697
688
|
* @param {Batch} batch
|
|
698
689
|
*/
|
|
699
|
-
#
|
|
690
|
+
#c(t) {
|
|
700
691
|
for (const [r, i] of t.current)
|
|
701
692
|
!this.previous.has(r) && t.previous.has(r) && this.previous.set(r, t.previous.get(r)), this.current.set(r, i);
|
|
702
693
|
for (const [r, i] of t.async_deriveds) {
|
|
703
694
|
const s = this.async_deriveds.get(r);
|
|
704
695
|
s && i.promise.then(s.resolve).catch(s.reject);
|
|
705
696
|
}
|
|
706
|
-
t.async_deriveds.clear(), this.
|
|
697
|
+
t.async_deriveds.clear(), this.transfer_reactions(t.#o);
|
|
707
698
|
const n = (r) => {
|
|
708
699
|
var i = r.reactions;
|
|
709
|
-
if (i !== null && !(r.f & Be && !(r.f & (
|
|
700
|
+
if (i !== null && !(r.f & Be && !(r.f & (le | ze))))
|
|
710
701
|
for (const a of i) {
|
|
711
702
|
var s = a.f;
|
|
712
703
|
if (s & Be)
|
|
@@ -719,20 +710,20 @@ class xt {
|
|
|
719
710
|
/** @type {Effect} */
|
|
720
711
|
a
|
|
721
712
|
);
|
|
722
|
-
s & ($t | qe) && !this.async_deriveds.has(o) && (this.#
|
|
713
|
+
s & ($t | qe) && !this.async_deriveds.has(o) && (this.#o.delete(o), ge(o, le), this.schedule(o));
|
|
723
714
|
}
|
|
724
715
|
}
|
|
725
716
|
};
|
|
726
717
|
for (const r of this.current.keys())
|
|
727
718
|
n(r);
|
|
728
|
-
this.oncommit(() => t.discard()), t.#
|
|
719
|
+
this.oncommit(() => t.discard()), t.#h(), re = this, this.#g();
|
|
729
720
|
}
|
|
730
721
|
/**
|
|
731
722
|
* @param {Effect[]} effects
|
|
732
723
|
*/
|
|
733
724
|
#p(t) {
|
|
734
725
|
for (var n = 0; n < t.length; n += 1)
|
|
735
|
-
Xi(t[n], this.#
|
|
726
|
+
Xi(t[n], this.#o);
|
|
736
727
|
}
|
|
737
728
|
/**
|
|
738
729
|
* Associate a change to a given source with the current
|
|
@@ -742,7 +733,7 @@ class xt {
|
|
|
742
733
|
* @param {boolean} [is_derived]
|
|
743
734
|
*/
|
|
744
735
|
capture(t, n, r = !1) {
|
|
745
|
-
t.v !==
|
|
736
|
+
t.v !== ye && !this.previous.has(t) && this.previous.set(t, t.v), t.f & It || (this.current.set(t, [n, r]), Je?.set(t, n)), this.is_fork || (t.v = n);
|
|
746
737
|
}
|
|
747
738
|
activate() {
|
|
748
739
|
re = this;
|
|
@@ -752,26 +743,26 @@ class xt {
|
|
|
752
743
|
}
|
|
753
744
|
flush() {
|
|
754
745
|
try {
|
|
755
|
-
Mr = !0, re = this, this.#
|
|
746
|
+
Mr = !0, re = this, this.#g();
|
|
756
747
|
} finally {
|
|
757
748
|
Z0 = 0, Yr = null, Bn = null, $n = null, Mr = !1, re = null, Je = null, at.clear();
|
|
758
749
|
}
|
|
759
750
|
}
|
|
760
751
|
discard() {
|
|
761
|
-
for (const t of this.#
|
|
762
|
-
this.#
|
|
752
|
+
for (const t of this.#t) t(this);
|
|
753
|
+
this.#t.clear();
|
|
763
754
|
for (const t of this.async_deriveds.values())
|
|
764
|
-
t.reject(
|
|
765
|
-
this.#
|
|
755
|
+
t.reject(Cn);
|
|
756
|
+
this.#h(), this.#r?.resolve();
|
|
766
757
|
}
|
|
767
758
|
/**
|
|
768
759
|
* @param {Effect} effect
|
|
769
760
|
*/
|
|
770
761
|
register_created_effect(t) {
|
|
771
|
-
this.#
|
|
762
|
+
this.#a.push(t);
|
|
772
763
|
}
|
|
773
|
-
#
|
|
774
|
-
for (let c = Ir; c !== null; c = c
|
|
764
|
+
#E() {
|
|
765
|
+
for (let c = Ir; c !== null; c = c.next) {
|
|
775
766
|
var t = c.id < this.id, n = [];
|
|
776
767
|
for (const [p, [h, g]] of this.current) {
|
|
777
768
|
if (c.current.has(p)) {
|
|
@@ -795,13 +786,13 @@ class xt {
|
|
|
795
786
|
(p) => !/** @type {[any, boolean]} */
|
|
796
787
|
c.current.get(p)[1]
|
|
797
788
|
);
|
|
798
|
-
if (!(!c
|
|
789
|
+
if (!(!c.started || i.length === 0)) {
|
|
799
790
|
var s = i.filter((p) => !this.current.has(p));
|
|
800
791
|
if (s.length === 0)
|
|
801
792
|
t && c.discard();
|
|
802
793
|
else if (n.length > 0) {
|
|
803
794
|
if (t)
|
|
804
|
-
for (const p of this.#
|
|
795
|
+
for (const p of this.#d)
|
|
805
796
|
c.unskip_effect(p, (h) => {
|
|
806
797
|
h.f & (qe | $t) ? c.schedule(h) : c.#p([h]);
|
|
807
798
|
});
|
|
@@ -815,12 +806,12 @@ class xt {
|
|
|
815
806
|
return g ? g[0] !== h[0] || g[1] !== h[1] : !0;
|
|
816
807
|
}).map(([p]) => p);
|
|
817
808
|
if (u.length > 0)
|
|
818
|
-
for (const p of this.#
|
|
819
|
-
!(p.f & (xe | Oe | sr)) && A0(p, u, a) && (p.f & ($t | qe) ? (
|
|
820
|
-
if (c.#
|
|
809
|
+
for (const p of this.#a)
|
|
810
|
+
!(p.f & (xe | Oe | sr)) && A0(p, u, a) && (p.f & ($t | qe) ? (ge(p, le), c.schedule(p)) : c.add_dirty_reaction(p, le));
|
|
811
|
+
if (c.#i.length > 0 && !c.#u) {
|
|
821
812
|
c.apply();
|
|
822
|
-
for (var f of c.#
|
|
823
|
-
c.#
|
|
813
|
+
for (var f of c.#f())
|
|
814
|
+
c.#b(f, [], []);
|
|
824
815
|
}
|
|
825
816
|
c.deactivate();
|
|
826
817
|
}
|
|
@@ -832,9 +823,9 @@ class xt {
|
|
|
832
823
|
* @param {Effect} effect
|
|
833
824
|
*/
|
|
834
825
|
increment(t, n) {
|
|
835
|
-
if (this.#
|
|
836
|
-
let r = this.#
|
|
837
|
-
this.#
|
|
826
|
+
if (this.#n += 1, t) {
|
|
827
|
+
let r = this.#s.get(n) ?? 0;
|
|
828
|
+
this.#s.set(n, r + 1);
|
|
838
829
|
}
|
|
839
830
|
}
|
|
840
831
|
/**
|
|
@@ -842,41 +833,45 @@ class xt {
|
|
|
842
833
|
* @param {Effect} effect
|
|
843
834
|
*/
|
|
844
835
|
decrement(t, n) {
|
|
845
|
-
if (this.#
|
|
846
|
-
let r = this.#
|
|
847
|
-
r === 1 ? this.#
|
|
836
|
+
if (this.#n -= 1, t) {
|
|
837
|
+
let r = this.#s.get(n) ?? 0;
|
|
838
|
+
r === 1 ? this.#s.delete(n) : this.#s.set(n, r - 1);
|
|
848
839
|
}
|
|
849
|
-
this.#
|
|
850
|
-
this.#
|
|
840
|
+
this.#u || (this.#u = !0, ot(() => {
|
|
841
|
+
this.#u = !1, this.linked && this.flush();
|
|
851
842
|
}));
|
|
852
843
|
}
|
|
853
844
|
/**
|
|
854
|
-
* @param {
|
|
855
|
-
|
|
845
|
+
* @param {Map<Effect, number>} dirty_reactions
|
|
846
|
+
*/
|
|
847
|
+
transfer_reactions(t) {
|
|
848
|
+
for (const [n, r] of t)
|
|
849
|
+
this.add_dirty_reaction(n, r);
|
|
850
|
+
t.clear();
|
|
851
|
+
}
|
|
852
|
+
/**
|
|
853
|
+
* @param {Effect} effect
|
|
854
|
+
* @param {number} status
|
|
856
855
|
*/
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
this.#u.add(r);
|
|
860
|
-
for (const r of n)
|
|
861
|
-
this.#f.add(r);
|
|
862
|
-
t.clear(), n.clear();
|
|
856
|
+
add_dirty_reaction(t, n) {
|
|
857
|
+
(n === le || this.#o.get(t) !== le) && this.#o.set(t, n);
|
|
863
858
|
}
|
|
864
859
|
/** @param {(batch: Batch) => void} fn */
|
|
865
860
|
oncommit(t) {
|
|
866
|
-
this.#
|
|
861
|
+
this.#e.add(t);
|
|
867
862
|
}
|
|
868
863
|
/** @param {(batch: Batch) => void} fn */
|
|
869
864
|
ondiscard(t) {
|
|
870
|
-
this.#
|
|
865
|
+
this.#t.add(t);
|
|
871
866
|
}
|
|
872
867
|
settled() {
|
|
873
|
-
return (this.#
|
|
868
|
+
return (this.#r ??= _i()).promise;
|
|
874
869
|
}
|
|
875
870
|
static ensure() {
|
|
876
871
|
if (re === null) {
|
|
877
872
|
const t = re = new xt();
|
|
878
873
|
!Mr && !Ln && ot(() => {
|
|
879
|
-
t
|
|
874
|
+
t.started || t.flush();
|
|
880
875
|
});
|
|
881
876
|
}
|
|
882
877
|
return re;
|
|
@@ -896,12 +891,12 @@ class xt {
|
|
|
896
891
|
t.b.defer_effect(t);
|
|
897
892
|
return;
|
|
898
893
|
}
|
|
899
|
-
this.#
|
|
894
|
+
this.#i.push(t);
|
|
900
895
|
}
|
|
901
|
-
#
|
|
896
|
+
#h() {
|
|
902
897
|
if (this.linked) {
|
|
903
|
-
var t = this
|
|
904
|
-
t === null ? Ir = n : t
|
|
898
|
+
var t = this.prev, n = this.next;
|
|
899
|
+
t === null ? Ir = n : t.next = n, n === null ? qt = t : n.prev = t, this.linked = !1;
|
|
905
900
|
}
|
|
906
901
|
}
|
|
907
902
|
}
|
|
@@ -963,7 +958,7 @@ function qi(e, t, n, r) {
|
|
|
963
958
|
t,
|
|
964
959
|
n,
|
|
965
960
|
r
|
|
966
|
-
) : s & ($t | qe) && !(s &
|
|
961
|
+
) : s & ($t | qe) && !(s & le) && A0(i, t, r) && (ge(i, le), x0(
|
|
967
962
|
/** @type {Effect} */
|
|
968
963
|
i
|
|
969
964
|
));
|
|
@@ -994,14 +989,14 @@ function x0(e) {
|
|
|
994
989
|
re.schedule(e);
|
|
995
990
|
}
|
|
996
991
|
function Ji(e, t) {
|
|
997
|
-
if (!(e.f & et && e.f &
|
|
998
|
-
e.f &
|
|
992
|
+
if (!(e.f & et && e.f & Ce)) {
|
|
993
|
+
e.f & le ? t.d.push(e) : e.f & ze && t.m.push(e), ge(e, Ce);
|
|
999
994
|
for (var n = e.first; n !== null; )
|
|
1000
995
|
Ji(n, t), n = n.next;
|
|
1001
996
|
}
|
|
1002
997
|
}
|
|
1003
998
|
function Ki(e) {
|
|
1004
|
-
|
|
999
|
+
ge(e, Ce);
|
|
1005
1000
|
for (var t = e.first; t !== null; )
|
|
1006
1001
|
Ki(t), t = t.next;
|
|
1007
1002
|
}
|
|
@@ -1011,7 +1006,6 @@ let $i = !1;
|
|
|
1011
1006
|
function jt(e, t) {
|
|
1012
1007
|
var n = {
|
|
1013
1008
|
f: 0,
|
|
1014
|
-
// TODO ideally we could skip this altogether, but it causes type errors
|
|
1015
1009
|
v: e,
|
|
1016
1010
|
reactions: null,
|
|
1017
1011
|
equals: ki,
|
|
@@ -1031,9 +1025,9 @@ function S0(e, t = !1, n = !0) {
|
|
|
1031
1025
|
return t || (r.equals = Ui), r;
|
|
1032
1026
|
}
|
|
1033
1027
|
function oe(e, t, n = !1) {
|
|
1034
|
-
|
|
1028
|
+
J !== null && // since we are untracking the function inside `$inspect.with` we need to add this check
|
|
1035
1029
|
// to ensure we error if state is set inside an inspect effect
|
|
1036
|
-
(!Ke ||
|
|
1030
|
+
(!Ke || J.f & sr) && zi() && J.f & (Be | qe | $t | sr) && (lt === null || !lt.has(e)) && $2();
|
|
1037
1031
|
let r = n ? De(t) : t;
|
|
1038
1032
|
return an(e, r, $n);
|
|
1039
1033
|
}
|
|
@@ -1047,16 +1041,16 @@ function an(e, t, n = null) {
|
|
|
1047
1041
|
/** @type {Derived} */
|
|
1048
1042
|
e
|
|
1049
1043
|
);
|
|
1050
|
-
e.f &
|
|
1044
|
+
e.f & le && E0(i), Je === null && C0(i);
|
|
1051
1045
|
}
|
|
1052
|
-
e.wv = ms(), Ht = null, Wr = 0, es(e,
|
|
1046
|
+
e.wv = ms(), Ht = null, Wr = 0, es(e, le, n), Ht = null, K !== null && K.f & Ce && !(K.f & (et | At)) && (Ve === null ? xo([e]) : Ve.push(e)), !r.is_fork && fr.size > 0 && !$i && ho();
|
|
1053
1047
|
}
|
|
1054
1048
|
return t;
|
|
1055
1049
|
}
|
|
1056
1050
|
function ho() {
|
|
1057
1051
|
$i = !1;
|
|
1058
1052
|
for (const e of fr) {
|
|
1059
|
-
e.f &
|
|
1053
|
+
e.f & Ce && ge(e, ze);
|
|
1060
1054
|
let t;
|
|
1061
1055
|
try {
|
|
1062
1056
|
t = Un(e);
|
|
@@ -1079,8 +1073,8 @@ function es(e, t, n) {
|
|
|
1079
1073
|
Ht.add(e);
|
|
1080
1074
|
}
|
|
1081
1075
|
for (var s = 0; s < i; s++) {
|
|
1082
|
-
var o = r[s], a = o.f, l = (a &
|
|
1083
|
-
if (l &&
|
|
1076
|
+
var o = r[s], a = o.f, l = (a & le) === 0;
|
|
1077
|
+
if (l && ge(o, t), a & sr)
|
|
1084
1078
|
fr.add(
|
|
1085
1079
|
/** @type {Effect} */
|
|
1086
1080
|
o
|
|
@@ -1090,7 +1084,7 @@ function es(e, t, n) {
|
|
|
1090
1084
|
/** @type {Derived} */
|
|
1091
1085
|
o
|
|
1092
1086
|
);
|
|
1093
|
-
Je?.delete(u), es(u,
|
|
1087
|
+
Je?.delete(u), es(u, ze, n);
|
|
1094
1088
|
} else if (l) {
|
|
1095
1089
|
var f = (
|
|
1096
1090
|
/** @type {Effect} */
|
|
@@ -1110,7 +1104,7 @@ function De(e) {
|
|
|
1110
1104
|
var n = /* @__PURE__ */ new Map(), r = Ti(e), i = /* @__PURE__ */ we(0), s = Ut, o = (a) => {
|
|
1111
1105
|
if (Ut === s)
|
|
1112
1106
|
return a();
|
|
1113
|
-
var l =
|
|
1107
|
+
var l = J, u = Ut;
|
|
1114
1108
|
We(null), $0(s);
|
|
1115
1109
|
var f = a();
|
|
1116
1110
|
return We(l), $0(u), f;
|
|
@@ -1134,11 +1128,11 @@ function De(e) {
|
|
|
1134
1128
|
var u = n.get(l);
|
|
1135
1129
|
if (u === void 0) {
|
|
1136
1130
|
if (l in a) {
|
|
1137
|
-
const f = o(() => /* @__PURE__ */ we(
|
|
1131
|
+
const f = o(() => /* @__PURE__ */ we(ye));
|
|
1138
1132
|
n.set(l, f), Tn(i);
|
|
1139
1133
|
}
|
|
1140
1134
|
} else
|
|
1141
|
-
oe(u,
|
|
1135
|
+
oe(u, ye), Tn(i);
|
|
1142
1136
|
return !0;
|
|
1143
1137
|
},
|
|
1144
1138
|
get(a, l, u) {
|
|
@@ -1146,11 +1140,11 @@ function De(e) {
|
|
|
1146
1140
|
return e;
|
|
1147
1141
|
var f = n.get(l), c = l in a;
|
|
1148
1142
|
if (f === void 0 && (!c || kt(a, l)?.writable) && (f = o(() => {
|
|
1149
|
-
var h = De(c ? a[l] :
|
|
1143
|
+
var h = De(c ? a[l] : ye), g = /* @__PURE__ */ we(h);
|
|
1150
1144
|
return g;
|
|
1151
1145
|
}), n.set(l, f)), f !== void 0) {
|
|
1152
1146
|
var p = _(f);
|
|
1153
|
-
return p ===
|
|
1147
|
+
return p === ye ? void 0 : p;
|
|
1154
1148
|
}
|
|
1155
1149
|
return Reflect.get(a, l, u);
|
|
1156
1150
|
},
|
|
@@ -1159,7 +1153,7 @@ function De(e) {
|
|
|
1159
1153
|
var u = Reflect.getOwnPropertyDescriptor(a, l), f = n.get(l);
|
|
1160
1154
|
if (f !== void 0) {
|
|
1161
1155
|
var c = _(f);
|
|
1162
|
-
if (c ===
|
|
1156
|
+
if (c === ye)
|
|
1163
1157
|
return;
|
|
1164
1158
|
if (u && "value" in u)
|
|
1165
1159
|
u.value = c;
|
|
@@ -1176,14 +1170,14 @@ function De(e) {
|
|
|
1176
1170
|
has(a, l) {
|
|
1177
1171
|
if (l === wn)
|
|
1178
1172
|
return !0;
|
|
1179
|
-
var u = n.get(l), f = u !== void 0 && u.v !==
|
|
1180
|
-
if (u !== void 0 || J !== null && (!f || kt(a, l)?.writable)) {
|
|
1173
|
+
var u = n.get(l), f = u !== void 0 && u.v !== ye || Reflect.has(a, l);
|
|
1174
|
+
if (u !== void 0 || (K !== null || J !== null) && (!f || kt(a, l)?.writable)) {
|
|
1181
1175
|
u === void 0 && (u = o(() => {
|
|
1182
|
-
var p = f ? De(a[l]) :
|
|
1176
|
+
var p = f ? De(a[l]) : ye, h = /* @__PURE__ */ we(p);
|
|
1183
1177
|
return h;
|
|
1184
1178
|
}), n.set(l, u));
|
|
1185
1179
|
var c = _(u);
|
|
1186
|
-
if (c ===
|
|
1180
|
+
if (c === ye)
|
|
1187
1181
|
return !1;
|
|
1188
1182
|
}
|
|
1189
1183
|
return f;
|
|
@@ -1194,17 +1188,17 @@ function De(e) {
|
|
|
1194
1188
|
for (var h = u; h < /** @type {Source<number>} */
|
|
1195
1189
|
c.v; h += 1) {
|
|
1196
1190
|
var g = n.get(h + "");
|
|
1197
|
-
g !== void 0 ? oe(g,
|
|
1191
|
+
g !== void 0 ? oe(g, ye) : h in a && (g = o(() => /* @__PURE__ */ we(ye)), n.set(h + "", g));
|
|
1198
1192
|
}
|
|
1199
1193
|
if (c === void 0)
|
|
1200
1194
|
(!p || kt(a, l)?.writable) && (c = o(() => /* @__PURE__ */ we(void 0)), oe(c, De(u)), n.set(l, c));
|
|
1201
1195
|
else {
|
|
1202
|
-
p = c.v !==
|
|
1196
|
+
p = c.v !== ye;
|
|
1203
1197
|
var x = o(() => De(u));
|
|
1204
1198
|
oe(c, x);
|
|
1205
1199
|
}
|
|
1206
|
-
var
|
|
1207
|
-
if (
|
|
1200
|
+
var y = Reflect.getOwnPropertyDescriptor(a, l);
|
|
1201
|
+
if (y?.set && y.set.call(f, u), !p) {
|
|
1208
1202
|
if (r && typeof l == "string") {
|
|
1209
1203
|
var T = (
|
|
1210
1204
|
/** @type {Source<number>} */
|
|
@@ -1220,10 +1214,10 @@ function De(e) {
|
|
|
1220
1214
|
_(i);
|
|
1221
1215
|
var l = Reflect.ownKeys(a).filter((c) => {
|
|
1222
1216
|
var p = n.get(c);
|
|
1223
|
-
return p === void 0 || p.v !==
|
|
1217
|
+
return p === void 0 || p.v !== ye;
|
|
1224
1218
|
});
|
|
1225
1219
|
for (var [u, f] of n)
|
|
1226
|
-
f.v !==
|
|
1220
|
+
f.v !== ye && !(u in a) && l.push(u);
|
|
1227
1221
|
return l;
|
|
1228
1222
|
},
|
|
1229
1223
|
setPrototypeOf() {
|
|
@@ -1258,7 +1252,7 @@ function ht(e) {
|
|
|
1258
1252
|
);
|
|
1259
1253
|
}
|
|
1260
1254
|
function is(e, t) {
|
|
1261
|
-
if (!
|
|
1255
|
+
if (!Z)
|
|
1262
1256
|
return /* @__PURE__ */ ft(e);
|
|
1263
1257
|
var n = /* @__PURE__ */ ft(W);
|
|
1264
1258
|
if (n === null)
|
|
@@ -1273,7 +1267,7 @@ function is(e, t) {
|
|
|
1273
1267
|
), Re(n), n;
|
|
1274
1268
|
}
|
|
1275
1269
|
function nu(e, t = !1) {
|
|
1276
|
-
if (!
|
|
1270
|
+
if (!Z) {
|
|
1277
1271
|
var n = /* @__PURE__ */ ft(e);
|
|
1278
1272
|
return n instanceof Comment && n.data === "" ? /* @__PURE__ */ ht(n) : n;
|
|
1279
1273
|
}
|
|
@@ -1290,17 +1284,17 @@ function nu(e, t = !1) {
|
|
|
1290
1284
|
return W;
|
|
1291
1285
|
}
|
|
1292
1286
|
function po(e, t = !1) {
|
|
1293
|
-
if (!
|
|
1287
|
+
if (!Z)
|
|
1294
1288
|
return /* @__PURE__ */ ft(e);
|
|
1295
1289
|
var n = is(e, t);
|
|
1296
1290
|
return ar(e), n;
|
|
1297
1291
|
}
|
|
1298
1292
|
function vo(e, t = 1, n = !1) {
|
|
1299
|
-
let r =
|
|
1293
|
+
let r = Z ? W : e;
|
|
1300
1294
|
for (var i; t--; )
|
|
1301
1295
|
i = r, r = /** @type {TemplateNode} */
|
|
1302
1296
|
/* @__PURE__ */ ht(r);
|
|
1303
|
-
if (!
|
|
1297
|
+
if (!Z)
|
|
1304
1298
|
return r;
|
|
1305
1299
|
if (n) {
|
|
1306
1300
|
if (r?.nodeType !== br) {
|
|
@@ -1338,9 +1332,9 @@ function L0(e) {
|
|
|
1338
1332
|
t.nodeValue, t = e.nextSibling;
|
|
1339
1333
|
}
|
|
1340
1334
|
function go(e) {
|
|
1341
|
-
var t =
|
|
1335
|
+
var t = K;
|
|
1342
1336
|
if (t === null)
|
|
1343
|
-
return
|
|
1337
|
+
return J.f |= It, e;
|
|
1344
1338
|
if (!(t.f & zt) && !(t.f & rn))
|
|
1345
1339
|
throw e;
|
|
1346
1340
|
rt(e, t);
|
|
@@ -1366,20 +1360,20 @@ function rt(e, t) {
|
|
|
1366
1360
|
}
|
|
1367
1361
|
}
|
|
1368
1362
|
function as(e) {
|
|
1369
|
-
|
|
1363
|
+
K === null && (J === null && W2(), Y2()), St && X2();
|
|
1370
1364
|
}
|
|
1371
1365
|
function mo(e, t) {
|
|
1372
1366
|
var n = t.last;
|
|
1373
1367
|
n === null ? t.last = t.first = e : (n.next = e, e.prev = n, t.last = e);
|
|
1374
1368
|
}
|
|
1375
1369
|
function tt(e, t) {
|
|
1376
|
-
var n =
|
|
1370
|
+
var n = K;
|
|
1377
1371
|
n !== null && n.f & Oe && (e |= Oe);
|
|
1378
1372
|
var r = {
|
|
1379
1373
|
ctx: Se,
|
|
1380
1374
|
deps: null,
|
|
1381
1375
|
nodes: null,
|
|
1382
|
-
f: e |
|
|
1376
|
+
f: e | le | $e,
|
|
1383
1377
|
first: null,
|
|
1384
1378
|
fn: t,
|
|
1385
1379
|
last: null,
|
|
@@ -1404,28 +1398,28 @@ function tt(e, t) {
|
|
|
1404
1398
|
i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && // either `null`, or a singular child
|
|
1405
1399
|
!(i.f & Vt) && (i = i.first, e & qe && e & sn && i !== null && (i.f |= sn));
|
|
1406
1400
|
}
|
|
1407
|
-
if (i !== null && (i.parent = n, n !== null && mo(i, n),
|
|
1401
|
+
if (i !== null && (i.parent = n, n !== null && mo(i, n), J !== null && J.f & Be && !(e & At))) {
|
|
1408
1402
|
var s = (
|
|
1409
1403
|
/** @type {Derived} */
|
|
1410
|
-
|
|
1404
|
+
J
|
|
1411
1405
|
);
|
|
1412
1406
|
(s.effects ??= []).push(i);
|
|
1413
1407
|
}
|
|
1414
1408
|
return r;
|
|
1415
1409
|
}
|
|
1416
1410
|
function B0() {
|
|
1417
|
-
return
|
|
1411
|
+
return J !== null && !Ke;
|
|
1418
1412
|
}
|
|
1419
1413
|
function T0(e) {
|
|
1420
1414
|
const t = tt(Nn, null);
|
|
1421
|
-
return
|
|
1415
|
+
return ge(t, Ce), t.teardown = e, t;
|
|
1422
1416
|
}
|
|
1423
1417
|
function ls(e) {
|
|
1424
1418
|
as();
|
|
1425
1419
|
var t = (
|
|
1426
1420
|
/** @type {Effect} */
|
|
1427
|
-
|
|
1428
|
-
), n = !
|
|
1421
|
+
K.f
|
|
1422
|
+
), n = !J && (t & et) !== 0 && Se !== null && !Se.i;
|
|
1429
1423
|
if (n) {
|
|
1430
1424
|
var r = (
|
|
1431
1425
|
/** @type {ComponentContext} */
|
|
@@ -1448,7 +1442,7 @@ function bo(e) {
|
|
|
1448
1442
|
Pe(t);
|
|
1449
1443
|
};
|
|
1450
1444
|
}
|
|
1451
|
-
function
|
|
1445
|
+
function yo(e) {
|
|
1452
1446
|
xt.ensure();
|
|
1453
1447
|
const t = tt(At | Vt, e);
|
|
1454
1448
|
return (n = {}) => new Promise((r) => {
|
|
@@ -1460,7 +1454,7 @@ function Co(e) {
|
|
|
1460
1454
|
function I0(e) {
|
|
1461
1455
|
return tt(rn, e);
|
|
1462
1456
|
}
|
|
1463
|
-
function
|
|
1457
|
+
function Co(e) {
|
|
1464
1458
|
return tt($t | Vt, e);
|
|
1465
1459
|
}
|
|
1466
1460
|
function M0(e, t = 0) {
|
|
@@ -1477,13 +1471,13 @@ function _0(e, t = 0) {
|
|
|
1477
1471
|
var n = tt(qe | t, e);
|
|
1478
1472
|
return n;
|
|
1479
1473
|
}
|
|
1480
|
-
function
|
|
1474
|
+
function Xe(e) {
|
|
1481
1475
|
return tt(et | Vt, e);
|
|
1482
1476
|
}
|
|
1483
1477
|
function cs(e) {
|
|
1484
1478
|
var t = e.teardown;
|
|
1485
1479
|
if (t !== null) {
|
|
1486
|
-
const n = St, r =
|
|
1480
|
+
const n = St, r = J;
|
|
1487
1481
|
K0(!0), We(null);
|
|
1488
1482
|
try {
|
|
1489
1483
|
t.call(null);
|
|
@@ -1574,7 +1568,7 @@ function cr(e) {
|
|
|
1574
1568
|
}
|
|
1575
1569
|
function ps(e, t) {
|
|
1576
1570
|
if (!(e.f & v0) && e.f & Oe) {
|
|
1577
|
-
e.f ^= Oe, e.f &
|
|
1571
|
+
e.f ^= Oe, e.f & Ce || (ge(e, le), xt.ensure().schedule(e));
|
|
1578
1572
|
for (var n = e.first; n !== null; ) {
|
|
1579
1573
|
var r = n.next, i = (n.f & sn) !== 0 || (n.f & et) !== 0;
|
|
1580
1574
|
ps(n, i ? t : !1), n = r;
|
|
@@ -1596,21 +1590,21 @@ let St = !1;
|
|
|
1596
1590
|
function K0(e) {
|
|
1597
1591
|
St = e;
|
|
1598
1592
|
}
|
|
1599
|
-
let
|
|
1593
|
+
let J = null, Ke = !1;
|
|
1600
1594
|
function We(e) {
|
|
1601
|
-
|
|
1595
|
+
J = e;
|
|
1602
1596
|
}
|
|
1603
|
-
let
|
|
1597
|
+
let K = null;
|
|
1604
1598
|
function ct(e) {
|
|
1605
|
-
|
|
1599
|
+
K = e;
|
|
1606
1600
|
}
|
|
1607
1601
|
let lt = null;
|
|
1608
1602
|
function vs(e) {
|
|
1609
|
-
|
|
1603
|
+
J !== null && (J.f & or || J.f & Be) && (lt ??= /* @__PURE__ */ new Set()).add(e);
|
|
1610
1604
|
}
|
|
1611
|
-
let Ne = null, je = 0,
|
|
1605
|
+
let Ne = null, je = 0, Ve = null;
|
|
1612
1606
|
function xo(e) {
|
|
1613
|
-
|
|
1607
|
+
Ve = e;
|
|
1614
1608
|
}
|
|
1615
1609
|
let gs = 1, Nt = 0, Ut = Nt;
|
|
1616
1610
|
function $0(e) {
|
|
@@ -1621,9 +1615,9 @@ function ms() {
|
|
|
1621
1615
|
}
|
|
1622
1616
|
function Un(e) {
|
|
1623
1617
|
var t = e.f;
|
|
1624
|
-
if (t &
|
|
1618
|
+
if (t & le)
|
|
1625
1619
|
return !0;
|
|
1626
|
-
if (t &
|
|
1620
|
+
if (t & ze) {
|
|
1627
1621
|
for (var n = (
|
|
1628
1622
|
/** @type {Value[]} */
|
|
1629
1623
|
e.deps
|
|
@@ -1640,7 +1634,7 @@ function Un(e) {
|
|
|
1640
1634
|
}
|
|
1641
1635
|
t & $e && // During time traveling we don't want to reset the status so that
|
|
1642
1636
|
// traversal of the graph in the other batches still happens
|
|
1643
|
-
Je === null &&
|
|
1637
|
+
Je === null && ge(e, Ce);
|
|
1644
1638
|
}
|
|
1645
1639
|
return !1;
|
|
1646
1640
|
}
|
|
@@ -1654,16 +1648,16 @@ function bs(e, t, n = !0) {
|
|
|
1654
1648
|
s,
|
|
1655
1649
|
t,
|
|
1656
1650
|
!1
|
|
1657
|
-
) : t === s && (n ?
|
|
1651
|
+
) : t === s && (n ? ge(s, le) : s.f & Ce && ge(s, ze), x0(
|
|
1658
1652
|
/** @type {Effect} */
|
|
1659
1653
|
s
|
|
1660
1654
|
));
|
|
1661
1655
|
}
|
|
1662
1656
|
}
|
|
1663
|
-
function
|
|
1664
|
-
var t = Ne, n = je, r =
|
|
1657
|
+
function ys(e) {
|
|
1658
|
+
var t = Ne, n = je, r = Ve, i = J, s = lt, o = Se, a = Ke, l = Ut, u = e.f;
|
|
1665
1659
|
Ne = /** @type {null | Value[]} */
|
|
1666
|
-
null, je = 0,
|
|
1660
|
+
null, je = 0, Ve = null, J = u & (et | At) ? null : e, lt = null, on(e.ctx), Ke = !1, Ut = ++Nt, e.ac !== null && (Gn(() => {
|
|
1667
1661
|
e.ac.abort(Rn);
|
|
1668
1662
|
}), e.ac = null);
|
|
1669
1663
|
try {
|
|
@@ -1674,11 +1668,11 @@ function Cs(e) {
|
|
|
1674
1668
|
), c = f();
|
|
1675
1669
|
e.f |= zt;
|
|
1676
1670
|
var p = ei(e);
|
|
1677
|
-
if (zi() &&
|
|
1671
|
+
if (zi() && Ve !== null && !Ke && p !== null && !(e.f & (Be | ze | le)))
|
|
1678
1672
|
for (var h = 0; h < /** @type {Source[]} */
|
|
1679
|
-
|
|
1673
|
+
Ve.length; h++)
|
|
1680
1674
|
bs(
|
|
1681
|
-
|
|
1675
|
+
Ve[h],
|
|
1682
1676
|
/** @type {Effect} */
|
|
1683
1677
|
e
|
|
1684
1678
|
);
|
|
@@ -1689,14 +1683,14 @@ function Cs(e) {
|
|
|
1689
1683
|
if (t !== null)
|
|
1690
1684
|
for (const g of t)
|
|
1691
1685
|
g.rv = Nt;
|
|
1692
|
-
|
|
1693
|
-
|
|
1686
|
+
Ve !== null && (r === null ? r = Ve : r.push(.../** @type {Source[]} */
|
|
1687
|
+
Ve));
|
|
1694
1688
|
}
|
|
1695
1689
|
return e.f & It && (e.f ^= It), c;
|
|
1696
1690
|
} catch (g) {
|
|
1697
1691
|
return ei(e), go(g);
|
|
1698
1692
|
} finally {
|
|
1699
|
-
e.f ^= or, Ne = t, je = n,
|
|
1693
|
+
e.f ^= or, Ne = t, je = n, Ve = r, J = i, lt = s, on(o), Ke = a, Ut = l;
|
|
1700
1694
|
}
|
|
1701
1695
|
}
|
|
1702
1696
|
function ei(e) {
|
|
@@ -1731,8 +1725,8 @@ function So(e, t) {
|
|
|
1731
1725
|
/** @type {Derived} */
|
|
1732
1726
|
t
|
|
1733
1727
|
);
|
|
1734
|
-
s.f & $e && (s.f ^= $e), s.v !==
|
|
1735
|
-
s.ac.abort(Rn), s.ac = null,
|
|
1728
|
+
s.f & $e && (s.f ^= $e), s.v !== ye && C0(s), s.ac !== null && Gn(() => {
|
|
1729
|
+
s.ac.abort(Rn), s.ac = null, ge(s, le);
|
|
1736
1730
|
}), uo(s), Fn(s, 0);
|
|
1737
1731
|
}
|
|
1738
1732
|
}
|
|
@@ -1745,32 +1739,32 @@ function Fn(e, t) {
|
|
|
1745
1739
|
function ln(e) {
|
|
1746
1740
|
var t = e.f;
|
|
1747
1741
|
if (!(t & xe)) {
|
|
1748
|
-
|
|
1749
|
-
var n =
|
|
1750
|
-
|
|
1742
|
+
ge(e, Ce);
|
|
1743
|
+
var n = K;
|
|
1744
|
+
K = e;
|
|
1751
1745
|
try {
|
|
1752
1746
|
t & (qe | Oi) ? Eo(e) : O0(e), cs(e);
|
|
1753
|
-
var r =
|
|
1747
|
+
var r = ys(e);
|
|
1754
1748
|
e.teardown = typeof r == "function" ? r : null, e.wv = gs;
|
|
1755
1749
|
var i;
|
|
1756
|
-
Bi && to && e.f &
|
|
1750
|
+
Bi && to && e.f & le && e.deps;
|
|
1757
1751
|
} finally {
|
|
1758
|
-
|
|
1752
|
+
K = n;
|
|
1759
1753
|
}
|
|
1760
1754
|
}
|
|
1761
1755
|
}
|
|
1762
1756
|
function _(e) {
|
|
1763
1757
|
var t = e.f, n = (t & Be) !== 0;
|
|
1764
|
-
if (
|
|
1765
|
-
var r =
|
|
1758
|
+
if (J !== null && !Ke) {
|
|
1759
|
+
var r = K !== null && (K.f & xe) !== 0;
|
|
1766
1760
|
if (!r && (lt === null || !lt.has(e))) {
|
|
1767
|
-
var i =
|
|
1768
|
-
if (
|
|
1761
|
+
var i = J.deps;
|
|
1762
|
+
if (J.f & or)
|
|
1769
1763
|
e.rv < Nt && (e.rv = Nt, Ne === null && i !== null && i[je] === e ? je++ : Ne === null ? Ne = [e] : Ne.push(e));
|
|
1770
1764
|
else {
|
|
1771
|
-
|
|
1765
|
+
J.deps ??= [], Mn.call(J.deps, e) || J.deps.push(e);
|
|
1772
1766
|
var s = e.reactions;
|
|
1773
|
-
s === null ? e.reactions = [
|
|
1767
|
+
s === null ? e.reactions = [J] : Mn.call(s, J) || s.push(J);
|
|
1774
1768
|
}
|
|
1775
1769
|
}
|
|
1776
1770
|
}
|
|
@@ -1783,10 +1777,10 @@ function _(e) {
|
|
|
1783
1777
|
);
|
|
1784
1778
|
if (St) {
|
|
1785
1779
|
var a = o.v;
|
|
1786
|
-
return (!(o.f &
|
|
1780
|
+
return (!(o.f & Ce) && o.reactions !== null || Es(o)) && (a = E0(o)), at.set(o, a), a;
|
|
1787
1781
|
}
|
|
1788
|
-
var l = (o.f & $e) === 0 && !Ke &&
|
|
1789
|
-
Un(o) && (l && (o.f |= $e), Qi(o)), l && !u && (Zi(o),
|
|
1782
|
+
var l = (o.f & $e) === 0 && !Ke && J !== null && (J.f & $e) !== 0, u = (o.f & zt) === 0;
|
|
1783
|
+
Un(o) && (l && (o.f |= $e), Qi(o)), l && !u && (Zi(o), Cs(o));
|
|
1790
1784
|
}
|
|
1791
1785
|
if (Je?.has(e))
|
|
1792
1786
|
return Je.get(e);
|
|
@@ -1794,21 +1788,21 @@ function _(e) {
|
|
|
1794
1788
|
throw e.v;
|
|
1795
1789
|
return e.v;
|
|
1796
1790
|
}
|
|
1797
|
-
function
|
|
1791
|
+
function Cs(e) {
|
|
1798
1792
|
if (e.f |= $e, e.deps !== null)
|
|
1799
1793
|
for (const n of e.deps) {
|
|
1800
1794
|
var t = n.reactions;
|
|
1801
1795
|
t === null ? n.reactions = [e] : Mn.call(t, e) || t.push(e), n.f & Be && !(n.f & $e) && (Zi(
|
|
1802
1796
|
/** @type {Derived} */
|
|
1803
1797
|
n
|
|
1804
|
-
),
|
|
1798
|
+
), Cs(
|
|
1805
1799
|
/** @type {Derived} */
|
|
1806
1800
|
n
|
|
1807
1801
|
));
|
|
1808
1802
|
}
|
|
1809
1803
|
}
|
|
1810
1804
|
function Es(e) {
|
|
1811
|
-
if (e.v ===
|
|
1805
|
+
if (e.v === ye) return !0;
|
|
1812
1806
|
if (e.deps === null) return !1;
|
|
1813
1807
|
for (const t of e.deps)
|
|
1814
1808
|
if (at.has(t) || t.f & Be && Es(
|
|
@@ -1828,7 +1822,7 @@ function Xt(e) {
|
|
|
1828
1822
|
}
|
|
1829
1823
|
const En = Symbol("events"), As = /* @__PURE__ */ new Set(), Zr = /* @__PURE__ */ new Set();
|
|
1830
1824
|
function iu(e) {
|
|
1831
|
-
if (!
|
|
1825
|
+
if (!Z) return;
|
|
1832
1826
|
e.removeAttribute("onload"), e.removeAttribute("onerror");
|
|
1833
1827
|
const t = e.__e;
|
|
1834
1828
|
t !== void 0 && (e.__e = void 0, queueMicrotask(() => {
|
|
@@ -1895,7 +1889,7 @@ function qr(e) {
|
|
|
1895
1889
|
return s || n;
|
|
1896
1890
|
}
|
|
1897
1891
|
});
|
|
1898
|
-
var f =
|
|
1892
|
+
var f = J, c = K;
|
|
1899
1893
|
We(null), ct(null);
|
|
1900
1894
|
try {
|
|
1901
1895
|
for (var p, h = []; s !== null && s !== t; ) {
|
|
@@ -1946,7 +1940,7 @@ function ws(e) {
|
|
|
1946
1940
|
function Mt(e, t) {
|
|
1947
1941
|
var n = (
|
|
1948
1942
|
/** @type {Effect} */
|
|
1949
|
-
|
|
1943
|
+
K
|
|
1950
1944
|
);
|
|
1951
1945
|
n.nodes === null && (n.nodes = { start: e, end: t, a: null, t: null });
|
|
1952
1946
|
}
|
|
@@ -1954,7 +1948,7 @@ function Mt(e, t) {
|
|
|
1954
1948
|
function jn(e, t) {
|
|
1955
1949
|
var n = (t & _2) !== 0, r = (t & O2) !== 0, i, s = !e.startsWith("<!>");
|
|
1956
1950
|
return () => {
|
|
1957
|
-
if (
|
|
1951
|
+
if (Z)
|
|
1958
1952
|
return Mt(W, null), W;
|
|
1959
1953
|
i === void 0 && (i = ws(s ? e : "<!>" + e), n || (i = /** @type {TemplateNode} */
|
|
1960
1954
|
/* @__PURE__ */ ft(i)));
|
|
@@ -1980,7 +1974,7 @@ function jn(e, t) {
|
|
|
1980
1974
|
function To(e, t, n = "svg") {
|
|
1981
1975
|
var r = !e.startsWith("<!>"), i = `<${n}>${r ? e : "<!>" + e}</${n}>`, s;
|
|
1982
1976
|
return () => {
|
|
1983
|
-
if (
|
|
1977
|
+
if (Z)
|
|
1984
1978
|
return Mt(W, null), W;
|
|
1985
1979
|
if (!s) {
|
|
1986
1980
|
var o = (
|
|
@@ -2005,16 +1999,16 @@ function ou(e, t) {
|
|
|
2005
1999
|
return /* @__PURE__ */ To(e, t, "svg");
|
|
2006
2000
|
}
|
|
2007
2001
|
function au() {
|
|
2008
|
-
if (
|
|
2002
|
+
if (Z)
|
|
2009
2003
|
return Mt(W, null), W;
|
|
2010
2004
|
var e = document.createDocumentFragment(), t = document.createComment(""), n = Ye();
|
|
2011
2005
|
return e.append(t, n), Mt(t, n), e;
|
|
2012
2006
|
}
|
|
2013
2007
|
function tn(e, t) {
|
|
2014
|
-
if (
|
|
2008
|
+
if (Z) {
|
|
2015
2009
|
var n = (
|
|
2016
2010
|
/** @type {Effect & { nodes: EffectNodes }} */
|
|
2017
|
-
|
|
2011
|
+
K
|
|
2018
2012
|
);
|
|
2019
2013
|
(!(n.f & zt) || n.nodes.end === null) && (n.nodes.end = W), kn();
|
|
2020
2014
|
return;
|
|
@@ -2025,7 +2019,7 @@ function tn(e, t) {
|
|
|
2025
2019
|
);
|
|
2026
2020
|
}
|
|
2027
2021
|
function lu() {
|
|
2028
|
-
if (
|
|
2022
|
+
if (Z && W && W.nodeType === dn && W.textContent?.startsWith("$")) {
|
|
2029
2023
|
const e = W.textContent.substring(1);
|
|
2030
2024
|
return kn(), e;
|
|
2031
2025
|
}
|
|
@@ -2062,28 +2056,26 @@ class Fo {
|
|
|
2062
2056
|
/** @type {TemplateNode} */
|
|
2063
2057
|
#e;
|
|
2064
2058
|
/** @type {TemplateNode | null} */
|
|
2065
|
-
#t =
|
|
2059
|
+
#t = Z ? W : null;
|
|
2066
2060
|
/** @type {BoundaryProps} */
|
|
2067
2061
|
#n;
|
|
2068
2062
|
/** @type {((anchor: Node) => void)} */
|
|
2069
|
-
#
|
|
2063
|
+
#s;
|
|
2070
2064
|
/** @type {Effect} */
|
|
2071
|
-
#
|
|
2065
|
+
#r;
|
|
2072
2066
|
/** @type {Effect | null} */
|
|
2073
|
-
#
|
|
2067
|
+
#i = null;
|
|
2074
2068
|
/** @type {Effect | null} */
|
|
2075
|
-
#
|
|
2069
|
+
#a = null;
|
|
2076
2070
|
/** @type {Effect | null} */
|
|
2077
|
-
#
|
|
2071
|
+
#o = null;
|
|
2078
2072
|
/** @type {DocumentFragment | null} */
|
|
2079
|
-
#
|
|
2080
|
-
#
|
|
2073
|
+
#l = null;
|
|
2074
|
+
#d = 0;
|
|
2081
2075
|
#u = 0;
|
|
2082
|
-
#
|
|
2083
|
-
/** @type {
|
|
2084
|
-
#
|
|
2085
|
-
/** @type {Set<Effect>} */
|
|
2086
|
-
#m = /* @__PURE__ */ new Set();
|
|
2076
|
+
#v = !1;
|
|
2077
|
+
/** @type {Map<Effect, number>} */
|
|
2078
|
+
#m = /* @__PURE__ */ new Map();
|
|
2087
2079
|
/**
|
|
2088
2080
|
* A source containing the number of pending async deriveds/expressions.
|
|
2089
2081
|
* Only created if `$effect.pending()` is used inside the boundary,
|
|
@@ -2091,9 +2083,9 @@ class Fo {
|
|
|
2091
2083
|
* calls followed by no-op flushes
|
|
2092
2084
|
* @type {Source<number> | null}
|
|
2093
2085
|
*/
|
|
2094
|
-
#
|
|
2095
|
-
#
|
|
2096
|
-
this.#
|
|
2086
|
+
#f = null;
|
|
2087
|
+
#g = _o(() => (this.#f = jt(this.#d), () => {
|
|
2088
|
+
this.#f = null;
|
|
2097
2089
|
}));
|
|
2098
2090
|
/**
|
|
2099
2091
|
* @param {TemplateNode} node
|
|
@@ -2102,15 +2094,15 @@ class Fo {
|
|
|
2102
2094
|
* @param {((error: unknown) => unknown) | undefined} [transform_error]
|
|
2103
2095
|
*/
|
|
2104
2096
|
constructor(t, n, r, i) {
|
|
2105
|
-
this.#e = t, this.#n = n, this.#
|
|
2097
|
+
this.#e = t, this.#n = n, this.#s = (s) => {
|
|
2106
2098
|
var o = (
|
|
2107
2099
|
/** @type {Effect} */
|
|
2108
|
-
|
|
2100
|
+
K
|
|
2109
2101
|
);
|
|
2110
2102
|
o.b = this, o.f |= jr, r(s);
|
|
2111
2103
|
}, this.parent = /** @type {Effect} */
|
|
2112
|
-
|
|
2113
|
-
if (
|
|
2104
|
+
K.b, this.transform_error = i ?? this.parent?.transform_error ?? ((s) => s), this.#r = _0(() => {
|
|
2105
|
+
if (Z) {
|
|
2114
2106
|
const s = g0(
|
|
2115
2107
|
/** @type {TemplateNode} */
|
|
2116
2108
|
this.#t
|
|
@@ -2119,15 +2111,15 @@ class Fo {
|
|
|
2119
2111
|
const o = s === d0;
|
|
2120
2112
|
if (s.startsWith(Y0)) {
|
|
2121
2113
|
const l = JSON.parse(s.slice(Y0.length));
|
|
2122
|
-
this.#
|
|
2123
|
-
} else o ? this.#
|
|
2114
|
+
this.#C(l);
|
|
2115
|
+
} else o ? this.#p() : this.#b();
|
|
2124
2116
|
} else
|
|
2125
|
-
this.#
|
|
2126
|
-
}, Oo),
|
|
2117
|
+
this.#E();
|
|
2118
|
+
}, Oo), Z && (this.#e = W);
|
|
2127
2119
|
}
|
|
2128
|
-
#
|
|
2120
|
+
#b() {
|
|
2129
2121
|
try {
|
|
2130
|
-
this.#
|
|
2122
|
+
this.#i = Xe(() => this.#s(this.#e));
|
|
2131
2123
|
} catch (t) {
|
|
2132
2124
|
this.error(t);
|
|
2133
2125
|
}
|
|
@@ -2135,9 +2127,9 @@ class Fo {
|
|
|
2135
2127
|
/**
|
|
2136
2128
|
* @param {unknown} error The deserialized error from the server's hydration comment
|
|
2137
2129
|
*/
|
|
2138
|
-
#
|
|
2139
|
-
const n = this.#n.failed, { reset: r, invoke_onerror: i } = this.#
|
|
2140
|
-
ot(i), n && (this.#
|
|
2130
|
+
#C(t) {
|
|
2131
|
+
const n = this.#n.failed, { reset: r, invoke_onerror: i } = this.#y(t);
|
|
2132
|
+
ot(i), n && (this.#o = Xe(() => {
|
|
2141
2133
|
n(
|
|
2142
2134
|
this.#e,
|
|
2143
2135
|
() => t,
|
|
@@ -2151,83 +2143,83 @@ class Fo {
|
|
|
2151
2143
|
* @param {unknown} error
|
|
2152
2144
|
* @returns {{ reset: () => void, invoke_onerror: () => void }}
|
|
2153
2145
|
*/
|
|
2154
|
-
#
|
|
2146
|
+
#y(t) {
|
|
2155
2147
|
var n = !1, r = !1;
|
|
2156
2148
|
const i = () => {
|
|
2157
|
-
if (!this.#
|
|
2149
|
+
if (!this.#c()) {
|
|
2158
2150
|
if (n) {
|
|
2159
2151
|
U2();
|
|
2160
2152
|
return;
|
|
2161
2153
|
}
|
|
2162
|
-
n = !0, r && eo(), this.#
|
|
2163
|
-
this.#
|
|
2164
|
-
}), this.#
|
|
2165
|
-
this.#
|
|
2154
|
+
n = !0, r && eo(), this.#o !== null && Gt(this.#o, () => {
|
|
2155
|
+
this.#o = null;
|
|
2156
|
+
}), this.#A(() => {
|
|
2157
|
+
this.#E();
|
|
2166
2158
|
});
|
|
2167
2159
|
}
|
|
2168
2160
|
};
|
|
2169
2161
|
return { reset: i, invoke_onerror: () => {
|
|
2170
|
-
if (!this.#
|
|
2162
|
+
if (!this.#c())
|
|
2171
2163
|
try {
|
|
2172
2164
|
r = !0, this.#n.onerror?.(t, i), r = !1;
|
|
2173
2165
|
} catch (o) {
|
|
2174
|
-
rt(o, this.#
|
|
2166
|
+
rt(o, this.#r && this.#r.parent);
|
|
2175
2167
|
}
|
|
2176
2168
|
} };
|
|
2177
2169
|
}
|
|
2178
|
-
#
|
|
2179
|
-
return (this.#
|
|
2170
|
+
#c() {
|
|
2171
|
+
return (this.#r.f & (xe | _n)) !== 0;
|
|
2180
2172
|
}
|
|
2181
|
-
#
|
|
2173
|
+
#p() {
|
|
2182
2174
|
const t = this.#n.pending;
|
|
2183
|
-
t && (this.is_pending = !0, this.#
|
|
2184
|
-
if (!this.#
|
|
2185
|
-
var n = this.#
|
|
2186
|
-
if (n.append(r), this.#
|
|
2175
|
+
t && (this.is_pending = !0, this.#a = Xe(() => t(this.#e)), ot(() => {
|
|
2176
|
+
if (!this.#c()) {
|
|
2177
|
+
var n = this.#l = document.createDocumentFragment(), r = Ye(), i = !1;
|
|
2178
|
+
if (n.append(r), this.#i = this.#A(() => {
|
|
2187
2179
|
try {
|
|
2188
|
-
return
|
|
2180
|
+
return Xe(() => this.#s(r));
|
|
2189
2181
|
} catch (s) {
|
|
2190
2182
|
try {
|
|
2191
2183
|
this.error(s), i = !0;
|
|
2192
2184
|
} catch (o) {
|
|
2193
|
-
rt(o, this.#
|
|
2185
|
+
rt(o, this.#r.parent);
|
|
2194
2186
|
}
|
|
2195
2187
|
return null;
|
|
2196
2188
|
}
|
|
2197
|
-
}), this.#
|
|
2198
|
-
this.#
|
|
2189
|
+
}), this.#i === null) {
|
|
2190
|
+
this.#l = null, i && this.#h(
|
|
2199
2191
|
/** @type {Batch} */
|
|
2200
2192
|
re
|
|
2201
2193
|
);
|
|
2202
2194
|
return;
|
|
2203
2195
|
}
|
|
2204
|
-
this.#u === 0 && (this.#e.before(n), this.#
|
|
2196
|
+
this.#u === 0 && (this.#e.before(n), this.#l = null, Gt(
|
|
2205
2197
|
/** @type {Effect} */
|
|
2206
|
-
this.#
|
|
2198
|
+
this.#a,
|
|
2207
2199
|
() => {
|
|
2208
|
-
this.#
|
|
2200
|
+
this.#a = null;
|
|
2209
2201
|
}
|
|
2210
|
-
), this.#
|
|
2202
|
+
), this.#h(
|
|
2211
2203
|
/** @type {Batch} */
|
|
2212
2204
|
re
|
|
2213
2205
|
));
|
|
2214
2206
|
}
|
|
2215
2207
|
}));
|
|
2216
2208
|
}
|
|
2217
|
-
#
|
|
2209
|
+
#E() {
|
|
2218
2210
|
try {
|
|
2219
|
-
if (this.is_pending = this.has_pending_snippet(), this.#u = 0, this.#
|
|
2220
|
-
this.#
|
|
2211
|
+
if (this.is_pending = this.has_pending_snippet(), this.#u = 0, this.#d = 0, this.#i = Xe(() => {
|
|
2212
|
+
this.#s(this.#e);
|
|
2221
2213
|
}), this.#u > 0) {
|
|
2222
|
-
var t = this.#
|
|
2223
|
-
P0(this.#
|
|
2214
|
+
var t = this.#l = document.createDocumentFragment();
|
|
2215
|
+
P0(this.#i, t);
|
|
2224
2216
|
const n = (
|
|
2225
2217
|
/** @type {(anchor: Node) => void} */
|
|
2226
2218
|
this.#n.pending
|
|
2227
2219
|
);
|
|
2228
|
-
this.#
|
|
2220
|
+
this.#a = Xe(() => n(this.#e));
|
|
2229
2221
|
} else
|
|
2230
|
-
this.#
|
|
2222
|
+
this.#h(
|
|
2231
2223
|
/** @type {Batch} */
|
|
2232
2224
|
re
|
|
2233
2225
|
);
|
|
@@ -2238,15 +2230,15 @@ class Fo {
|
|
|
2238
2230
|
/**
|
|
2239
2231
|
* @param {Batch} batch
|
|
2240
2232
|
*/
|
|
2241
|
-
#
|
|
2242
|
-
this.is_pending = !1, t.
|
|
2233
|
+
#h(t) {
|
|
2234
|
+
this.is_pending = !1, t.transfer_reactions(this.#m);
|
|
2243
2235
|
}
|
|
2244
2236
|
/**
|
|
2245
2237
|
* Defer an effect inside a pending boundary until the boundary resolves
|
|
2246
2238
|
* @param {Effect} effect
|
|
2247
2239
|
*/
|
|
2248
2240
|
defer_effect(t) {
|
|
2249
|
-
Xi(t, this.#
|
|
2241
|
+
Xi(t, this.#m);
|
|
2250
2242
|
}
|
|
2251
2243
|
/**
|
|
2252
2244
|
* Returns `false` if the effect exists inside a boundary whose pending snippet is shown
|
|
@@ -2262,9 +2254,9 @@ class Fo {
|
|
|
2262
2254
|
* @template T
|
|
2263
2255
|
* @param {() => T} fn
|
|
2264
2256
|
*/
|
|
2265
|
-
#
|
|
2266
|
-
var n =
|
|
2267
|
-
ct(this.#
|
|
2257
|
+
#A(t) {
|
|
2258
|
+
var n = K, r = J, i = Se;
|
|
2259
|
+
ct(this.#r), We(this.#r), on(this.#r.ctx);
|
|
2268
2260
|
try {
|
|
2269
2261
|
return xt.ensure(), t();
|
|
2270
2262
|
} finally {
|
|
@@ -2277,14 +2269,14 @@ class Fo {
|
|
|
2277
2269
|
* @param {1 | -1} d
|
|
2278
2270
|
* @param {Batch} batch
|
|
2279
2271
|
*/
|
|
2280
|
-
#
|
|
2272
|
+
#x(t, n) {
|
|
2281
2273
|
if (!this.has_pending_snippet()) {
|
|
2282
|
-
this.parent && this.parent.#
|
|
2274
|
+
this.parent && this.parent.#x(t, n);
|
|
2283
2275
|
return;
|
|
2284
2276
|
}
|
|
2285
|
-
this.#u += t, this.#u === 0 && (this.#
|
|
2286
|
-
this.#
|
|
2287
|
-
}), this.#
|
|
2277
|
+
this.#u += t, this.#u === 0 && (this.#h(n), this.#a && Gt(this.#a, () => {
|
|
2278
|
+
this.#a = null;
|
|
2279
|
+
}), this.#l && (this.#e.before(this.#l), this.#l = null));
|
|
2288
2280
|
}
|
|
2289
2281
|
/**
|
|
2290
2282
|
* Update the source that powers `$effect.pending()` inside this boundary,
|
|
@@ -2294,42 +2286,42 @@ class Fo {
|
|
|
2294
2286
|
* @param {Batch} batch
|
|
2295
2287
|
*/
|
|
2296
2288
|
update_pending_count(t, n) {
|
|
2297
|
-
this.#
|
|
2298
|
-
this.#
|
|
2289
|
+
this.#x(t, n), this.#d += t, !(!this.#f || this.#v) && (this.#v = !0, ot(() => {
|
|
2290
|
+
this.#v = !1, this.#f && an(this.#f, this.#d);
|
|
2299
2291
|
}));
|
|
2300
2292
|
}
|
|
2301
2293
|
get_effect_pending() {
|
|
2302
|
-
return this.#
|
|
2294
|
+
return this.#g(), _(
|
|
2303
2295
|
/** @type {Source<number>} */
|
|
2304
|
-
this.#
|
|
2296
|
+
this.#f
|
|
2305
2297
|
);
|
|
2306
2298
|
}
|
|
2307
2299
|
/** @param {unknown} error */
|
|
2308
2300
|
error(t) {
|
|
2309
2301
|
if (t === _t || !this.#n.onerror && !this.#n.failed)
|
|
2310
2302
|
throw t;
|
|
2311
|
-
re?.is_fork ? (this.#
|
|
2312
|
-
this.#
|
|
2313
|
-
})) : this.#
|
|
2303
|
+
re?.is_fork ? (this.#i && re.skip_effect(this.#i), this.#a && re.skip_effect(this.#a), this.#o && re.skip_effect(this.#o), re.oncommit(() => {
|
|
2304
|
+
this.#c() || this.#S(t);
|
|
2305
|
+
})) : this.#S(t);
|
|
2314
2306
|
}
|
|
2315
2307
|
/**
|
|
2316
2308
|
* @param {unknown} error
|
|
2317
2309
|
*/
|
|
2318
|
-
#
|
|
2319
|
-
this.#
|
|
2310
|
+
#S(t) {
|
|
2311
|
+
this.#i && (Pe(this.#i), this.#i = null), this.#a && (Pe(this.#a), this.#a = null), this.#o && (Pe(this.#o), this.#o = null), Z && (Re(
|
|
2320
2312
|
/** @type {TemplateNode} */
|
|
2321
2313
|
this.#t
|
|
2322
2314
|
), j2(), Re(lr()));
|
|
2323
2315
|
let n = this.#n.failed;
|
|
2324
2316
|
const r = (i) => {
|
|
2325
|
-
if (this.#
|
|
2326
|
-
const { reset: s, invoke_onerror: o } = this.#
|
|
2327
|
-
o(), n && !this.#
|
|
2317
|
+
if (this.#c()) return;
|
|
2318
|
+
const { reset: s, invoke_onerror: o } = this.#y(i);
|
|
2319
|
+
o(), n && !this.#c() && (this.#o = this.#A(() => {
|
|
2328
2320
|
try {
|
|
2329
|
-
return
|
|
2321
|
+
return Xe(() => {
|
|
2330
2322
|
var a = (
|
|
2331
2323
|
/** @type {Effect} */
|
|
2332
|
-
|
|
2324
|
+
K
|
|
2333
2325
|
);
|
|
2334
2326
|
a.b = this, a.f |= jr, n(
|
|
2335
2327
|
this.#e,
|
|
@@ -2341,25 +2333,25 @@ class Fo {
|
|
|
2341
2333
|
return rt(
|
|
2342
2334
|
a,
|
|
2343
2335
|
/** @type {Effect} */
|
|
2344
|
-
this.#
|
|
2336
|
+
this.#r.parent
|
|
2345
2337
|
), null;
|
|
2346
2338
|
}
|
|
2347
2339
|
}));
|
|
2348
2340
|
};
|
|
2349
2341
|
ot(() => {
|
|
2350
|
-
if (!this.#
|
|
2342
|
+
if (!this.#c()) {
|
|
2351
2343
|
var i;
|
|
2352
2344
|
try {
|
|
2353
2345
|
i = this.transform_error(t);
|
|
2354
2346
|
} catch (s) {
|
|
2355
|
-
rt(s, this.#
|
|
2347
|
+
rt(s, this.#r && this.#r.parent);
|
|
2356
2348
|
return;
|
|
2357
2349
|
}
|
|
2358
2350
|
i !== null && typeof i == "object" && typeof /** @type {any} */
|
|
2359
2351
|
i.then == "function" ? i.then(
|
|
2360
2352
|
r,
|
|
2361
2353
|
/** @param {unknown} e */
|
|
2362
|
-
(s) => rt(s, this.#
|
|
2354
|
+
(s) => rt(s, this.#r && this.#r.parent)
|
|
2363
2355
|
) : r(i);
|
|
2364
2356
|
}
|
|
2365
2357
|
});
|
|
@@ -2375,33 +2367,33 @@ function Bs(e, t) {
|
|
|
2375
2367
|
}
|
|
2376
2368
|
function Ho(e, t) {
|
|
2377
2369
|
Qr(), t.intro = t.intro ?? !1;
|
|
2378
|
-
const n = t.target, r =
|
|
2370
|
+
const n = t.target, r = Z, i = W;
|
|
2379
2371
|
try {
|
|
2380
2372
|
for (var s = /* @__PURE__ */ ft(n); s && (s.nodeType !== dn || /** @type {Comment} */
|
|
2381
2373
|
s.data !== Li); )
|
|
2382
2374
|
s = /* @__PURE__ */ ht(s);
|
|
2383
2375
|
if (!s)
|
|
2384
2376
|
throw _t;
|
|
2385
|
-
|
|
2377
|
+
yt(!0), Re(
|
|
2386
2378
|
/** @type {Comment} */
|
|
2387
2379
|
s
|
|
2388
2380
|
);
|
|
2389
2381
|
const o = Ts(e, { ...t, anchor: s });
|
|
2390
|
-
return
|
|
2382
|
+
return yt(!1), /** @type {Exports} */
|
|
2391
2383
|
o;
|
|
2392
2384
|
} catch (o) {
|
|
2393
2385
|
if (o instanceof Error && o.message.split(`
|
|
2394
2386
|
`).some((a) => a.startsWith("https://svelte.dev/e/")))
|
|
2395
2387
|
throw o;
|
|
2396
|
-
return o !== _t && console.warn("Failed to hydrate: ", o), t.recover === !1 && Z2(), Qr(), ss(n),
|
|
2388
|
+
return o !== _t && console.warn("Failed to hydrate: ", o), t.recover === !1 && Z2(), Qr(), ss(n), yt(!1), Bs(e, t);
|
|
2397
2389
|
} finally {
|
|
2398
|
-
|
|
2390
|
+
yt(r), Re(i);
|
|
2399
2391
|
}
|
|
2400
2392
|
}
|
|
2401
2393
|
const Qn = /* @__PURE__ */ new Map();
|
|
2402
2394
|
function Ts(e, { target: t, anchor: n, props: r = {}, events: i, context: s, intro: o = !0, transformError: a }) {
|
|
2403
2395
|
Qr();
|
|
2404
|
-
var l = void 0, u =
|
|
2396
|
+
var l = void 0, u = yo(() => {
|
|
2405
2397
|
var f = n ?? t.appendChild(Ye());
|
|
2406
2398
|
Po(
|
|
2407
2399
|
/** @type {TemplateNode} */
|
|
@@ -2416,13 +2408,13 @@ function Ts(e, { target: t, anchor: n, props: r = {}, events: i, context: s, int
|
|
|
2416
2408
|
/** @type {ComponentContext} */
|
|
2417
2409
|
Se
|
|
2418
2410
|
);
|
|
2419
|
-
if (s && (g.c = s), i && (r.$$events = i),
|
|
2411
|
+
if (s && (g.c = s), i && (r.$$events = i), Z && Mt(
|
|
2420
2412
|
/** @type {TemplateNode} */
|
|
2421
2413
|
h,
|
|
2422
2414
|
null
|
|
2423
|
-
), l = e(h, r) ||
|
|
2415
|
+
), l = e(h, r) || y0(), Z && (K.nodes.end = W, W === null || W.nodeType !== dn || /** @type {Comment} */
|
|
2424
2416
|
W.data !== p0))
|
|
2425
|
-
throw
|
|
2417
|
+
throw yr(), _t;
|
|
2426
2418
|
b0();
|
|
2427
2419
|
},
|
|
2428
2420
|
a
|
|
@@ -2432,27 +2424,27 @@ function Ts(e, { target: t, anchor: n, props: r = {}, events: i, context: s, int
|
|
|
2432
2424
|
var x = h[g];
|
|
2433
2425
|
if (!c.has(x)) {
|
|
2434
2426
|
c.add(x);
|
|
2435
|
-
var
|
|
2427
|
+
var y = Mo(x);
|
|
2436
2428
|
for (const F of [t, document]) {
|
|
2437
2429
|
var T = Qn.get(F);
|
|
2438
2430
|
T === void 0 && (T = /* @__PURE__ */ new Map(), Qn.set(F, T));
|
|
2439
2431
|
var U = T.get(x);
|
|
2440
|
-
U === void 0 ? (F.addEventListener(x, qr, { passive:
|
|
2432
|
+
U === void 0 ? (F.addEventListener(x, qr, { passive: y }), T.set(x, 1)) : T.set(x, U + 1);
|
|
2441
2433
|
}
|
|
2442
2434
|
}
|
|
2443
2435
|
}
|
|
2444
2436
|
};
|
|
2445
2437
|
return p(mr(As)), Zr.add(p), () => {
|
|
2446
2438
|
for (var h of c)
|
|
2447
|
-
for (const
|
|
2439
|
+
for (const y of [t, document]) {
|
|
2448
2440
|
var g = (
|
|
2449
2441
|
/** @type {Map<string, number>} */
|
|
2450
|
-
Qn.get(
|
|
2442
|
+
Qn.get(y)
|
|
2451
2443
|
), x = (
|
|
2452
2444
|
/** @type {number} */
|
|
2453
2445
|
g.get(h)
|
|
2454
2446
|
);
|
|
2455
|
-
--x == 0 ? (
|
|
2447
|
+
--x == 0 ? (y.removeEventListener(h, qr), g.delete(h), g.size === 0 && Qn.delete(y)) : g.set(h, x);
|
|
2456
2448
|
}
|
|
2457
2449
|
Zr.delete(p), f !== n && f.parentNode?.removeChild(f);
|
|
2458
2450
|
};
|
|
@@ -2494,30 +2486,30 @@ class No {
|
|
|
2494
2486
|
* Keys of effects that are currently outroing
|
|
2495
2487
|
* @type {Set<Key>}
|
|
2496
2488
|
*/
|
|
2497
|
-
#
|
|
2489
|
+
#s = /* @__PURE__ */ new Set();
|
|
2498
2490
|
/**
|
|
2499
2491
|
* Whether to pause (i.e. outro) on change, or destroy immediately.
|
|
2500
2492
|
* This is necessary for `<svelte:element>`
|
|
2501
2493
|
*/
|
|
2502
|
-
#
|
|
2494
|
+
#r = !0;
|
|
2503
2495
|
/**
|
|
2504
2496
|
* @param {TemplateNode} anchor
|
|
2505
2497
|
* @param {boolean} transition
|
|
2506
2498
|
*/
|
|
2507
2499
|
constructor(t, n = !0) {
|
|
2508
|
-
this.anchor = t, this.#
|
|
2500
|
+
this.anchor = t, this.#r = n;
|
|
2509
2501
|
}
|
|
2510
2502
|
/**
|
|
2511
2503
|
* @param {Batch} batch
|
|
2512
2504
|
*/
|
|
2513
|
-
#
|
|
2505
|
+
#i = (t) => {
|
|
2514
2506
|
if (this.#e.has(t)) {
|
|
2515
2507
|
var n = (
|
|
2516
2508
|
/** @type {Key} */
|
|
2517
2509
|
this.#e.get(t)
|
|
2518
2510
|
), r = this.#t.get(n);
|
|
2519
2511
|
if (r)
|
|
2520
|
-
cr(r), this.#
|
|
2512
|
+
cr(r), this.#s.delete(n);
|
|
2521
2513
|
else {
|
|
2522
2514
|
var i = this.#n.get(n);
|
|
2523
2515
|
i && (cr(i.effect), this.#t.set(n, i.effect), this.#n.delete(n), i.fragment.lastChild.remove(), this.anchor.before(i.fragment), r = i.effect);
|
|
@@ -2529,23 +2521,23 @@ class No {
|
|
|
2529
2521
|
a && (Pe(a.effect), this.#n.delete(o));
|
|
2530
2522
|
}
|
|
2531
2523
|
for (const [s, o] of this.#t) {
|
|
2532
|
-
if (s === n || this.#
|
|
2524
|
+
if (s === n || this.#s.has(s)) continue;
|
|
2533
2525
|
const a = () => {
|
|
2534
2526
|
if (Array.from(this.#e.values()).includes(s)) {
|
|
2535
2527
|
var u = document.createDocumentFragment();
|
|
2536
2528
|
P0(o, u), u.append(Ye()), this.#n.set(s, { effect: o, fragment: u });
|
|
2537
2529
|
} else
|
|
2538
2530
|
Pe(o);
|
|
2539
|
-
this.#
|
|
2531
|
+
this.#s.delete(s), this.#t.delete(s);
|
|
2540
2532
|
};
|
|
2541
|
-
this.#
|
|
2533
|
+
this.#r || !r ? (this.#s.add(s), Gt(o, a, !1)) : a();
|
|
2542
2534
|
}
|
|
2543
2535
|
}
|
|
2544
2536
|
};
|
|
2545
2537
|
/**
|
|
2546
2538
|
* @param {Batch} batch
|
|
2547
2539
|
*/
|
|
2548
|
-
#
|
|
2540
|
+
#a = (t) => {
|
|
2549
2541
|
this.#e.delete(t);
|
|
2550
2542
|
const n = Array.from(this.#e.values());
|
|
2551
2543
|
for (const [r, i] of this.#n)
|
|
@@ -2565,22 +2557,22 @@ class No {
|
|
|
2565
2557
|
if (i) {
|
|
2566
2558
|
var s = document.createDocumentFragment(), o = Ye();
|
|
2567
2559
|
s.append(o), this.#n.set(t, {
|
|
2568
|
-
effect:
|
|
2560
|
+
effect: Xe(() => n(o)),
|
|
2569
2561
|
fragment: s
|
|
2570
2562
|
});
|
|
2571
2563
|
} else
|
|
2572
2564
|
this.#t.set(
|
|
2573
2565
|
t,
|
|
2574
|
-
|
|
2566
|
+
Xe(() => n(this.anchor))
|
|
2575
2567
|
);
|
|
2576
2568
|
if (this.#e.set(r, t), i) {
|
|
2577
2569
|
for (const [a, l] of this.#t)
|
|
2578
2570
|
a === t ? r.unskip_effect(l) : r.skip_effect(l);
|
|
2579
2571
|
for (const [a, l] of this.#n)
|
|
2580
2572
|
a === t ? r.unskip_effect(l.effect) : r.skip_effect(l.effect);
|
|
2581
|
-
r.oncommit(this.#
|
|
2573
|
+
r.oncommit(this.#i), r.ondiscard(this.#a);
|
|
2582
2574
|
} else
|
|
2583
|
-
|
|
2575
|
+
Z && (this.anchor = W), this.#i(r);
|
|
2584
2576
|
}
|
|
2585
2577
|
}
|
|
2586
2578
|
function Ro(e) {
|
|
@@ -2597,17 +2589,17 @@ function uu(e) {
|
|
|
2597
2589
|
}
|
|
2598
2590
|
function ko(e, t, n = !1) {
|
|
2599
2591
|
var r;
|
|
2600
|
-
|
|
2592
|
+
Z && (r = W, kn());
|
|
2601
2593
|
var i = new No(e), s = n ? sn : 0;
|
|
2602
2594
|
function o(a, l) {
|
|
2603
|
-
if (
|
|
2595
|
+
if (Z) {
|
|
2604
2596
|
var u = g0(
|
|
2605
2597
|
/** @type {TemplateNode} */
|
|
2606
2598
|
r
|
|
2607
2599
|
);
|
|
2608
2600
|
if (a !== parseInt(u.substring(1))) {
|
|
2609
2601
|
var f = lr();
|
|
2610
|
-
Re(f), i.anchor = f,
|
|
2602
|
+
Re(f), i.anchor = f, yt(!1), i.ensure(a, l), yt(!0);
|
|
2611
2603
|
return;
|
|
2612
2604
|
}
|
|
2613
2605
|
}
|
|
@@ -2691,9 +2683,9 @@ function Is(e, t, n, r, i, s = null) {
|
|
|
2691
2683
|
/** @type {Element} */
|
|
2692
2684
|
e
|
|
2693
2685
|
);
|
|
2694
|
-
o =
|
|
2686
|
+
o = Z ? Re(/* @__PURE__ */ ft(u)) : u.appendChild(Ye());
|
|
2695
2687
|
}
|
|
2696
|
-
|
|
2688
|
+
Z && kn();
|
|
2697
2689
|
var f = null, c = /* @__PURE__ */ Wi(() => {
|
|
2698
2690
|
var U = n();
|
|
2699
2691
|
return (
|
|
@@ -2713,23 +2705,23 @@ function Is(e, t, n, r, i, s = null) {
|
|
|
2713
2705
|
function x(U) {
|
|
2714
2706
|
T.pending.delete(U);
|
|
2715
2707
|
}
|
|
2716
|
-
var
|
|
2708
|
+
var y = _0(() => {
|
|
2717
2709
|
var U = (
|
|
2718
2710
|
/** @type {V[]} */
|
|
2719
2711
|
_(c)
|
|
2720
2712
|
), F = U.length;
|
|
2721
2713
|
let k = !1;
|
|
2722
|
-
if (
|
|
2714
|
+
if (Z) {
|
|
2723
2715
|
var X = g0(o) === d0;
|
|
2724
|
-
X !== (F === 0) && (o = lr(), Re(o),
|
|
2716
|
+
X !== (F === 0) && (o = lr(), Re(o), yt(!1), k = !0);
|
|
2725
2717
|
}
|
|
2726
2718
|
for (var H = /* @__PURE__ */ new Set(), L = (
|
|
2727
2719
|
/** @type {Batch} */
|
|
2728
2720
|
re
|
|
2729
2721
|
), A = os(), j = 0; j < F; j += 1) {
|
|
2730
|
-
|
|
2722
|
+
Z && W.nodeType === dn && /** @type {Comment} */
|
|
2731
2723
|
W.data === p0 && (o = /** @type {Comment} */
|
|
2732
|
-
W, k = !0,
|
|
2724
|
+
W, k = !0, yt(!1));
|
|
2733
2725
|
var D = U[j], P = r(D, j), Y = h ? null : a.get(P);
|
|
2734
2726
|
Y ? (Y.v && an(Y.v, D), Y.i && an(Y.i, j), A && L.unskip_effect(Y.e)) : (Y = zo(
|
|
2735
2727
|
a,
|
|
@@ -2742,16 +2734,16 @@ function Is(e, t, n, r, i, s = null) {
|
|
|
2742
2734
|
n
|
|
2743
2735
|
), h || (Y.e.f |= st), a.set(P, Y)), H.add(P);
|
|
2744
2736
|
}
|
|
2745
|
-
if (F === 0 && s && !f && (h ? f =
|
|
2737
|
+
if (F === 0 && s && !f && (h ? f = Xe(() => s(o)) : (f = Xe(() => s(ti ??= Ye())), f.f |= st)), F > H.size && V2(), Z && F > 0 && Re(lr()), !h)
|
|
2746
2738
|
if (p.set(L, H), A) {
|
|
2747
|
-
for (const [
|
|
2748
|
-
H.has(
|
|
2739
|
+
for (const [fe, M] of a)
|
|
2740
|
+
H.has(fe) || L.skip_effect(M.e);
|
|
2749
2741
|
L.oncommit(g), L.ondiscard(x);
|
|
2750
2742
|
} else
|
|
2751
2743
|
g(L);
|
|
2752
|
-
k &&
|
|
2753
|
-
}), T = { effect:
|
|
2754
|
-
h = !1,
|
|
2744
|
+
k && yt(!0), _(c);
|
|
2745
|
+
}), T = { effect: y, items: a, pending: p, outrogroups: null, fallback: f };
|
|
2746
|
+
h = !1, Z && (o = W);
|
|
2755
2747
|
}
|
|
2756
2748
|
function bn(e) {
|
|
2757
2749
|
for (; e !== null && !(e.f & et); )
|
|
@@ -2759,26 +2751,26 @@ function bn(e) {
|
|
|
2759
2751
|
return e;
|
|
2760
2752
|
}
|
|
2761
2753
|
function jo(e, t, n, r, i) {
|
|
2762
|
-
var s = (r & w2) !== 0, o = t.length, a = e.items, l = bn(e.effect.first), u, f = null, c, p = [], h = [], g, x,
|
|
2754
|
+
var s = (r & w2) !== 0, o = t.length, a = e.items, l = bn(e.effect.first), u, f = null, c, p = [], h = [], g, x, y, T;
|
|
2763
2755
|
if (s)
|
|
2764
2756
|
for (T = 0; T < o; T += 1)
|
|
2765
|
-
g = t[T], x = i(g, T),
|
|
2766
|
-
a.get(x).e,
|
|
2757
|
+
g = t[T], x = i(g, T), y = /** @type {EachItem} */
|
|
2758
|
+
a.get(x).e, y.f & st || (y.nodes?.a?.measure(), (c ??= /* @__PURE__ */ new Set()).add(y));
|
|
2767
2759
|
for (T = 0; T < o; T += 1) {
|
|
2768
|
-
if (g = t[T], x = i(g, T),
|
|
2760
|
+
if (g = t[T], x = i(g, T), y = /** @type {EachItem} */
|
|
2769
2761
|
a.get(x).e, e.outrogroups !== null)
|
|
2770
2762
|
for (const D of e.outrogroups)
|
|
2771
|
-
D.pending.delete(
|
|
2772
|
-
if (
|
|
2773
|
-
if (
|
|
2774
|
-
An(
|
|
2763
|
+
D.pending.delete(y), D.done.delete(y);
|
|
2764
|
+
if (y.f & Oe && (cr(y), s && (y.nodes?.a?.unfix(), (c ??= /* @__PURE__ */ new Set()).delete(y))), y.f & st)
|
|
2765
|
+
if (y.f ^= st, y === l)
|
|
2766
|
+
An(y, null, n);
|
|
2775
2767
|
else {
|
|
2776
2768
|
var U = f ? f.next : l;
|
|
2777
|
-
|
|
2769
|
+
y === e.effect.last && (e.effect.last = y.prev), y.prev && (y.prev.next = y.next), y.next && (y.next.prev = y.prev), wt(e, f, y), wt(e, y, U), An(y, U, n), f = y, p = [], h = [], l = bn(f.next);
|
|
2778
2770
|
continue;
|
|
2779
2771
|
}
|
|
2780
|
-
if (
|
|
2781
|
-
if (u !== void 0 && u.has(
|
|
2772
|
+
if (y !== l) {
|
|
2773
|
+
if (u !== void 0 && u.has(y)) {
|
|
2782
2774
|
if (p.length < h.length) {
|
|
2783
2775
|
var F = h[0], k;
|
|
2784
2776
|
f = F.prev;
|
|
@@ -2789,15 +2781,15 @@ function jo(e, t, n, r, i) {
|
|
|
2789
2781
|
u.delete(h[k]);
|
|
2790
2782
|
wt(e, X.prev, H.next), wt(e, f, X), wt(e, H, F), l = F, f = H, T -= 1, p = [], h = [];
|
|
2791
2783
|
} else
|
|
2792
|
-
u.delete(
|
|
2784
|
+
u.delete(y), An(y, l, n), wt(e, y.prev, y.next), wt(e, y, f === null ? e.effect.first : f.next), wt(e, f, y), f = y;
|
|
2793
2785
|
continue;
|
|
2794
2786
|
}
|
|
2795
|
-
for (p = [], h = []; l !== null && l !==
|
|
2787
|
+
for (p = [], h = []; l !== null && l !== y; )
|
|
2796
2788
|
(u ??= /* @__PURE__ */ new Set()).add(l), h.push(l), l = bn(l.next);
|
|
2797
2789
|
if (l === null)
|
|
2798
2790
|
continue;
|
|
2799
2791
|
}
|
|
2800
|
-
|
|
2792
|
+
y.f & st || p.push(y), f = y, l = bn(y.next);
|
|
2801
2793
|
}
|
|
2802
2794
|
if (e.outrogroups !== null) {
|
|
2803
2795
|
for (const D of e.outrogroups)
|
|
@@ -2807,8 +2799,8 @@ function jo(e, t, n, r, i) {
|
|
|
2807
2799
|
if (l !== null || u !== void 0) {
|
|
2808
2800
|
var L = [];
|
|
2809
2801
|
if (u !== void 0)
|
|
2810
|
-
for (
|
|
2811
|
-
|
|
2802
|
+
for (y of u)
|
|
2803
|
+
y.f & Oe || L.push(y);
|
|
2812
2804
|
for (; l !== null; )
|
|
2813
2805
|
!(l.f & Oe) && l !== e.fallback && L.push(l), l = bn(l.next);
|
|
2814
2806
|
var A = L.length;
|
|
@@ -2825,8 +2817,8 @@ function jo(e, t, n, r, i) {
|
|
|
2825
2817
|
}
|
|
2826
2818
|
s && ot(() => {
|
|
2827
2819
|
if (c !== void 0)
|
|
2828
|
-
for (
|
|
2829
|
-
|
|
2820
|
+
for (y of c)
|
|
2821
|
+
y.nodes?.a?.apply();
|
|
2830
2822
|
});
|
|
2831
2823
|
}
|
|
2832
2824
|
function zo(e, t, n, r, i, s, o, a) {
|
|
@@ -2834,7 +2826,7 @@ function zo(e, t, n, r, i, s, o, a) {
|
|
|
2834
2826
|
return {
|
|
2835
2827
|
v: l,
|
|
2836
2828
|
i: u,
|
|
2837
|
-
e:
|
|
2829
|
+
e: Xe(() => (s(t, l ?? n, u ?? i, a), () => {
|
|
2838
2830
|
e.delete(r);
|
|
2839
2831
|
}))
|
|
2840
2832
|
};
|
|
@@ -2859,7 +2851,7 @@ function wt(e, t, n) {
|
|
|
2859
2851
|
}
|
|
2860
2852
|
function Ms(e, t) {
|
|
2861
2853
|
I0(() => {
|
|
2862
|
-
e =
|
|
2854
|
+
e = K?.parent?.nodes?.start ?? e;
|
|
2863
2855
|
var n = e.getRootNode(), r = (
|
|
2864
2856
|
/** @type {ShadowRoot} */
|
|
2865
2857
|
n.host ? (
|
|
@@ -2917,9 +2909,9 @@ function Os(e, t, n, r, i, s) {
|
|
|
2917
2909
|
/** @type {any} */
|
|
2918
2910
|
e[zr]
|
|
2919
2911
|
);
|
|
2920
|
-
if (
|
|
2912
|
+
if (Z || o !== n || o === void 0) {
|
|
2921
2913
|
var a = Xo(n, r, s);
|
|
2922
|
-
(!
|
|
2914
|
+
(!Z || a !== e.getAttribute("class")) && (a == null ? e.removeAttribute("class") : e.className = a), e[zr] = n;
|
|
2923
2915
|
} else if (s && i !== s)
|
|
2924
2916
|
for (var l in s) {
|
|
2925
2917
|
var u = !!s[l];
|
|
@@ -2932,15 +2924,15 @@ function cu(e, t, n, r) {
|
|
|
2932
2924
|
/** @type {any} */
|
|
2933
2925
|
e[Vr]
|
|
2934
2926
|
);
|
|
2935
|
-
if (
|
|
2927
|
+
if (Z || i !== t) {
|
|
2936
2928
|
var s = Yo(t);
|
|
2937
|
-
(!
|
|
2929
|
+
(!Z || s !== e.getAttribute("style")) && (s == null ? e.removeAttribute("style") : e.style.cssText = s), e[Vr] = t;
|
|
2938
2930
|
}
|
|
2939
2931
|
return r;
|
|
2940
2932
|
}
|
|
2941
2933
|
const Wo = Symbol("is custom element"), Qo = Symbol("is html"), Zo = Ri ? "link" : "LINK", qo = Ri ? "progress" : "PROGRESS";
|
|
2942
2934
|
function hu(e) {
|
|
2943
|
-
if (
|
|
2935
|
+
if (Z) {
|
|
2944
2936
|
var t = !1, n = () => {
|
|
2945
2937
|
if (!t) {
|
|
2946
2938
|
if (t = !0, e.hasAttribute("value")) {
|
|
@@ -2965,7 +2957,10 @@ function du(e, t) {
|
|
|
2965
2957
|
}
|
|
2966
2958
|
function $r(e, t, n, r) {
|
|
2967
2959
|
var i = Ps(e);
|
|
2968
|
-
|
|
2960
|
+
if (!(Z && (i[t] = e.getAttribute(t), t === "src" || t === "srcset" || t === "href" && e.nodeName === Zo))) {
|
|
2961
|
+
var s = i[t];
|
|
2962
|
+
s !== (i[t] = n) && (t === "loading" && (e[k2] = n), n == null ? e.removeAttribute(t) : typeof n != "string" && Jo(e).has(t) ? e[t] = n : Z && (typeof n == "number" || typeof n == "boolean") && s === String(n) || e.setAttribute(t, n));
|
|
2963
|
+
}
|
|
2969
2964
|
}
|
|
2970
2965
|
function Ps(e) {
|
|
2971
2966
|
return (
|
|
@@ -3010,12 +3005,12 @@ class F0 {
|
|
|
3010
3005
|
*/
|
|
3011
3006
|
observe(t, n) {
|
|
3012
3007
|
var r = this.#e.get(t) || /* @__PURE__ */ new Set();
|
|
3013
|
-
return r.add(n), this.#e.set(t, r), this.#
|
|
3008
|
+
return r.add(n), this.#e.set(t, r), this.#s().observe(t, this.#n), () => {
|
|
3014
3009
|
var i = this.#e.get(t);
|
|
3015
3010
|
i.delete(n), i.size === 0 && (this.#e.delete(t), this.#t.unobserve(t));
|
|
3016
3011
|
};
|
|
3017
3012
|
}
|
|
3018
|
-
#
|
|
3013
|
+
#s() {
|
|
3019
3014
|
return this.#t ?? (this.#t = new ResizeObserver(
|
|
3020
3015
|
/** @param {any} entries */
|
|
3021
3016
|
(t) => {
|
|
@@ -3038,13 +3033,13 @@ function pu(e, t, n) {
|
|
|
3038
3033
|
function Pr(e, t) {
|
|
3039
3034
|
return e === t || e?.[wn] === t;
|
|
3040
3035
|
}
|
|
3041
|
-
function vu(e =
|
|
3036
|
+
function vu(e = y0(), t, n, r) {
|
|
3042
3037
|
var i = (
|
|
3043
3038
|
/** @type {ComponentContext} */
|
|
3044
3039
|
Se.r
|
|
3045
3040
|
), s = (
|
|
3046
3041
|
/** @type {Effect} */
|
|
3047
|
-
|
|
3042
|
+
K
|
|
3048
3043
|
);
|
|
3049
3044
|
return I0(() => {
|
|
3050
3045
|
var o, a;
|
|
@@ -3067,7 +3062,7 @@ function vu(e = C0(), t, n, r) {
|
|
|
3067
3062
|
}
|
|
3068
3063
|
function H0(e, t, n) {
|
|
3069
3064
|
if (e == null)
|
|
3070
|
-
return t(void 0), n && n(void 0),
|
|
3065
|
+
return t(void 0), n && n(void 0), Ct;
|
|
3071
3066
|
const r = Xt(
|
|
3072
3067
|
() => e.subscribe(
|
|
3073
3068
|
t,
|
|
@@ -3080,10 +3075,10 @@ function H0(e, t, n) {
|
|
|
3080
3075
|
const Jt = [];
|
|
3081
3076
|
function $o(e, t) {
|
|
3082
3077
|
return {
|
|
3083
|
-
subscribe:
|
|
3078
|
+
subscribe: Cr(e, t).subscribe
|
|
3084
3079
|
};
|
|
3085
3080
|
}
|
|
3086
|
-
function
|
|
3081
|
+
function Cr(e, t = Ct) {
|
|
3087
3082
|
let n = null;
|
|
3088
3083
|
const r = /* @__PURE__ */ new Set();
|
|
3089
3084
|
function i(a) {
|
|
@@ -3104,9 +3099,9 @@ function yr(e, t = yt) {
|
|
|
3104
3099
|
e
|
|
3105
3100
|
));
|
|
3106
3101
|
}
|
|
3107
|
-
function o(a, l =
|
|
3102
|
+
function o(a, l = Ct) {
|
|
3108
3103
|
const u = [a, l];
|
|
3109
|
-
return r.add(u), r.size === 1 && (n = t(i, s) ||
|
|
3104
|
+
return r.add(u), r.size === 1 && (n = t(i, s) || Ct), a(
|
|
3110
3105
|
/** @type {T} */
|
|
3111
3106
|
e
|
|
3112
3107
|
), () => {
|
|
@@ -3123,18 +3118,18 @@ function pn(e, t, n) {
|
|
|
3123
3118
|
return $o(n, (o, a) => {
|
|
3124
3119
|
let l = !1;
|
|
3125
3120
|
const u = [];
|
|
3126
|
-
let f = 0, c =
|
|
3121
|
+
let f = 0, c = Ct;
|
|
3127
3122
|
const p = () => {
|
|
3128
3123
|
if (f)
|
|
3129
3124
|
return;
|
|
3130
3125
|
c();
|
|
3131
3126
|
const g = t(r ? u[0] : u, o, a);
|
|
3132
|
-
s ? o(g) : c = typeof g == "function" ? g :
|
|
3127
|
+
s ? o(g) : c = typeof g == "function" ? g : Ct;
|
|
3133
3128
|
}, h = i.map(
|
|
3134
3129
|
(g, x) => H0(
|
|
3135
3130
|
g,
|
|
3136
|
-
(
|
|
3137
|
-
u[x] =
|
|
3131
|
+
(y) => {
|
|
3132
|
+
u[x] = y, f &= ~(1 << x), l && p();
|
|
3138
3133
|
},
|
|
3139
3134
|
() => {
|
|
3140
3135
|
f |= 1 << x;
|
|
@@ -3155,11 +3150,11 @@ function Fs(e, t, n) {
|
|
|
3155
3150
|
const r = n[t] ??= {
|
|
3156
3151
|
store: null,
|
|
3157
3152
|
source: /* @__PURE__ */ S0(void 0),
|
|
3158
|
-
unsubscribe:
|
|
3153
|
+
unsubscribe: Ct
|
|
3159
3154
|
};
|
|
3160
3155
|
if (r.store !== e && !(e0 in n))
|
|
3161
3156
|
if (r.unsubscribe(), r.store = e ?? null, e == null)
|
|
3162
|
-
r.source.v = void 0, r.unsubscribe =
|
|
3157
|
+
r.source.v = void 0, r.unsubscribe = Ct;
|
|
3163
3158
|
else {
|
|
3164
3159
|
var i = !0;
|
|
3165
3160
|
r.unsubscribe = H0(e, (s) => {
|
|
@@ -3228,11 +3223,11 @@ function Rt(e, t, n, r) {
|
|
|
3228
3223
|
}, !(n & T2))
|
|
3229
3224
|
return x;
|
|
3230
3225
|
if (c) {
|
|
3231
|
-
var
|
|
3226
|
+
var y = e.$$legacy;
|
|
3232
3227
|
return (
|
|
3233
3228
|
/** @type {() => V} */
|
|
3234
3229
|
function(k, X) {
|
|
3235
|
-
return arguments.length > 0 ? ((!X ||
|
|
3230
|
+
return arguments.length > 0 ? ((!X || y || g) && c(X ? x() : k), k) : x();
|
|
3236
3231
|
}
|
|
3237
3232
|
);
|
|
3238
3233
|
}
|
|
@@ -3240,7 +3235,7 @@ function Rt(e, t, n, r) {
|
|
|
3240
3235
|
s && _(U);
|
|
3241
3236
|
var F = (
|
|
3242
3237
|
/** @type {Effect} */
|
|
3243
|
-
|
|
3238
|
+
K
|
|
3244
3239
|
);
|
|
3245
3240
|
return (
|
|
3246
3241
|
/** @type {() => V} */
|
|
@@ -3554,9 +3549,9 @@ const Fe = (e, t) => {
|
|
|
3554
3549
|
Fe("OptOutClicked", { id: e, name: t, status: n });
|
|
3555
3550
|
}, bu = (e, t, n) => {
|
|
3556
3551
|
Fe("ViewDetailClicked", { id: e, name: t, status: n });
|
|
3557
|
-
},
|
|
3552
|
+
}, yu = (e, t, n, r) => {
|
|
3558
3553
|
Fe("DetailTabClicked", { id: e, name: t, status: n, tabName: r });
|
|
3559
|
-
},
|
|
3554
|
+
}, Cu = (e, t) => {
|
|
3560
3555
|
Fe("DetailPageOpen", { isOpen: e, challengeId: t });
|
|
3561
3556
|
}, Eu = (e, t) => {
|
|
3562
3557
|
Fe("ChallengeUnavailable", { challengeId: e, reason: t });
|
|
@@ -3684,7 +3679,7 @@ const ga = (e, t) => new URL(`${e}/challenge/${t}`), nt = async (e, t, n, r = (i
|
|
|
3684
3679
|
...t && { PlayerSession: t }
|
|
3685
3680
|
};
|
|
3686
3681
|
return (await nt(n, "GetChallengeGames", r)).ChallengeGames;
|
|
3687
|
-
},
|
|
3682
|
+
}, ya = ({
|
|
3688
3683
|
endpoint: e,
|
|
3689
3684
|
domainId: t,
|
|
3690
3685
|
sessionId: n,
|
|
@@ -3718,7 +3713,7 @@ const ga = (e, t) => new URL(`${e}/challenge/${t}`), nt = async (e, t, n, r = (i
|
|
|
3718
3713
|
s,
|
|
3719
3714
|
(o) => o?.Message ?? o?.ErrorMessage ?? null
|
|
3720
3715
|
);
|
|
3721
|
-
},
|
|
3716
|
+
}, Ca = ({ endpoint: e, domainId: t, sessionId: n, challengeId: r }) => {
|
|
3722
3717
|
const i = {
|
|
3723
3718
|
DomainId: String(t),
|
|
3724
3719
|
...n && { PlayerSession: n },
|
|
@@ -3750,10 +3745,10 @@ var n0 = { exports: {} };
|
|
|
3750
3745
|
}), Date.now || (Date.now = function() {
|
|
3751
3746
|
return (/* @__PURE__ */ new Date()).getTime();
|
|
3752
3747
|
}), x == null) {
|
|
3753
|
-
var
|
|
3748
|
+
var y = c;
|
|
3754
3749
|
c = function(v, B) {
|
|
3755
3750
|
var O = B.signal;
|
|
3756
|
-
return
|
|
3751
|
+
return y(v, { headers: B.headers, credentials: B.credentials, cache: B.cache }).then(function(w) {
|
|
3757
3752
|
var z = w.body.getReader();
|
|
3758
3753
|
return O._reader = z, O._aborted && O._reader.cancel(), {
|
|
3759
3754
|
status: w.status,
|
|
@@ -3797,8 +3792,8 @@ var n0 = { exports: {} };
|
|
|
3797
3792
|
return 3;
|
|
3798
3793
|
throw new Error();
|
|
3799
3794
|
}
|
|
3800
|
-
for (var w = 65533, z = "", R = this.bitsNeeded, Q = this.codePoint,
|
|
3801
|
-
var te = v[
|
|
3795
|
+
for (var w = 65533, z = "", R = this.bitsNeeded, Q = this.codePoint, ce = 0; ce < v.length; ce += 1) {
|
|
3796
|
+
var te = v[ce];
|
|
3802
3797
|
R !== 0 && (te < 128 || te > 191 || !B(Q << 6 | te & 63, R - 6, O(R, Q))) && (R = 0, Q = w, z += String.fromCharCode(Q)), R === 0 ? (te >= 0 && te <= 127 ? (R = 0, Q = te) : te >= 192 && te <= 223 ? (R = 6 * 1, Q = te & 31) : te >= 224 && te <= 239 ? (R = 6 * 2, Q = te & 15) : te >= 240 && te <= 247 ? (R = 6 * 3, Q = te & 7) : (R = 0, Q = w), R !== 0 && !B(Q, R, O(R, Q)) && (R = 0, Q = w)) : (R -= 6, Q = Q << 6 | te & 63), R === 0 && (Q <= 65535 ? z += String.fromCharCode(Q) : (z += String.fromCharCode(55296 + (Q - 65535 - 1 >> 10)), z += String.fromCharCode(56320 + (Q - 65535 - 1 & 1023))));
|
|
3803
3798
|
}
|
|
3804
3799
|
return this.bitsNeeded = R, this.codePoint = Q, z;
|
|
@@ -3825,18 +3820,18 @@ var n0 = { exports: {} };
|
|
|
3825
3820
|
};
|
|
3826
3821
|
var Q = function() {
|
|
3827
3822
|
if (z === 1) {
|
|
3828
|
-
var V = 0,
|
|
3823
|
+
var V = 0, he = "", pt = void 0;
|
|
3829
3824
|
if ("contentType" in w)
|
|
3830
|
-
V = 200,
|
|
3825
|
+
V = 200, he = "OK", pt = w.contentType;
|
|
3831
3826
|
else
|
|
3832
3827
|
try {
|
|
3833
|
-
V = w.status,
|
|
3828
|
+
V = w.status, he = w.statusText, pt = w.getResponseHeader("Content-Type");
|
|
3834
3829
|
} catch {
|
|
3835
|
-
V = 0,
|
|
3830
|
+
V = 0, he = "", pt = void 0;
|
|
3836
3831
|
}
|
|
3837
|
-
V !== 0 && (z = 2, O.readyState = 2, O.status = V, O.statusText =
|
|
3832
|
+
V !== 0 && (z = 2, O.readyState = 2, O.status = V, O.statusText = he, O._contentType = pt, O.onreadystatechange());
|
|
3838
3833
|
}
|
|
3839
|
-
},
|
|
3834
|
+
}, ce = function() {
|
|
3840
3835
|
if (Q(), z === 2 || z === 3) {
|
|
3841
3836
|
z = 3;
|
|
3842
3837
|
var V = "";
|
|
@@ -3846,26 +3841,26 @@ var n0 = { exports: {} };
|
|
|
3846
3841
|
}
|
|
3847
3842
|
O.readyState = 3, O.responseText = V, O.onprogress();
|
|
3848
3843
|
}
|
|
3849
|
-
}, te = function(V,
|
|
3850
|
-
if ((
|
|
3844
|
+
}, te = function(V, he) {
|
|
3845
|
+
if ((he == null || he.preventDefault == null) && (he = {
|
|
3851
3846
|
preventDefault: F
|
|
3852
|
-
}),
|
|
3847
|
+
}), ce(), z === 1 || z === 2 || z === 3) {
|
|
3853
3848
|
if (z = 4, R !== 0 && (i(R), R = 0), O.readyState = 4, V === "load")
|
|
3854
|
-
O.onload(
|
|
3849
|
+
O.onload(he);
|
|
3855
3850
|
else if (V === "error")
|
|
3856
|
-
O.onerror(
|
|
3851
|
+
O.onerror(he);
|
|
3857
3852
|
else if (V === "abort")
|
|
3858
|
-
O.onabort(
|
|
3853
|
+
O.onabort(he);
|
|
3859
3854
|
else
|
|
3860
3855
|
throw new TypeError();
|
|
3861
3856
|
O.onreadystatechange();
|
|
3862
3857
|
}
|
|
3863
3858
|
}, se = function(V) {
|
|
3864
|
-
w != null && (w.readyState === 4 ? (!("onload" in w) || !("onerror" in w) || !("onabort" in w)) && te(w.responseText === "" ? "error" : "load", V) : w.readyState === 3 ? "onprogress" in w ||
|
|
3859
|
+
w != null && (w.readyState === 4 ? (!("onload" in w) || !("onerror" in w) || !("onabort" in w)) && te(w.responseText === "" ? "error" : "load", V) : w.readyState === 3 ? "onprogress" in w || ce() : w.readyState === 2 && Q());
|
|
3865
3860
|
}, ae = function() {
|
|
3866
3861
|
R = r(function() {
|
|
3867
3862
|
ae();
|
|
3868
|
-
}, 500), w.readyState === 3 &&
|
|
3863
|
+
}, 500), w.readyState === 3 && ce();
|
|
3869
3864
|
};
|
|
3870
3865
|
"onload" in w && (w.onload = function(V) {
|
|
3871
3866
|
te("load", V);
|
|
@@ -3873,7 +3868,7 @@ var n0 = { exports: {} };
|
|
|
3873
3868
|
te("error", V);
|
|
3874
3869
|
}), "onabort" in w && (w.onabort = function(V) {
|
|
3875
3870
|
te("abort", V);
|
|
3876
|
-
}), "onprogress" in w && (w.onprogress =
|
|
3871
|
+
}), "onprogress" in w && (w.onprogress = ce), "onreadystatechange" in w && (w.onreadystatechange = function(V) {
|
|
3877
3872
|
se(V);
|
|
3878
3873
|
}), ("contentType" in w || !("ontimeout" in s.prototype)) && (B += (B.indexOf("?") === -1 ? "?" : "&") + "padding=true"), w.open(v, B, !0), "readyState" in w && (R = r(function() {
|
|
3879
3874
|
ae();
|
|
@@ -3911,8 +3906,8 @@ var n0 = { exports: {} };
|
|
|
3911
3906
|
function H(v) {
|
|
3912
3907
|
for (var B = /* @__PURE__ */ Object.create(null), O = v.split(`\r
|
|
3913
3908
|
`), w = 0; w < O.length; w += 1) {
|
|
3914
|
-
var z = O[w], R = z.split(": "), Q = R.shift(),
|
|
3915
|
-
B[X(Q)] =
|
|
3909
|
+
var z = O[w], R = z.split(": "), Q = R.shift(), ce = R.join(": ");
|
|
3910
|
+
B[X(Q)] = ce;
|
|
3916
3911
|
}
|
|
3917
3912
|
this._map = B;
|
|
3918
3913
|
}
|
|
@@ -3923,10 +3918,10 @@ var n0 = { exports: {} };
|
|
|
3923
3918
|
}
|
|
3924
3919
|
L.prototype.open = function(v, B, O, w, z, R, Q) {
|
|
3925
3920
|
v.open("GET", z);
|
|
3926
|
-
var
|
|
3921
|
+
var ce = 0;
|
|
3927
3922
|
v.onprogress = function() {
|
|
3928
|
-
var se = v.responseText, ae = se.slice(
|
|
3929
|
-
|
|
3923
|
+
var se = v.responseText, ae = se.slice(ce);
|
|
3924
|
+
ce += ae.length, O(ae);
|
|
3930
3925
|
}, v.onerror = function(se) {
|
|
3931
3926
|
se.preventDefault(), w(new Error("NetworkError"));
|
|
3932
3927
|
}, v.onload = function() {
|
|
@@ -3935,8 +3930,8 @@ var n0 = { exports: {} };
|
|
|
3935
3930
|
w(null);
|
|
3936
3931
|
}, v.onreadystatechange = function() {
|
|
3937
3932
|
if (v.readyState === s.HEADERS_RECEIVED) {
|
|
3938
|
-
var se = v.status, ae = v.statusText, V = v.getResponseHeader("Content-Type"),
|
|
3939
|
-
B(se, ae, V, new H(
|
|
3933
|
+
var se = v.status, ae = v.statusText, V = v.getResponseHeader("Content-Type"), he = v.getAllResponseHeaders();
|
|
3934
|
+
B(se, ae, V, new H(he));
|
|
3940
3935
|
}
|
|
3941
3936
|
}, v.withCredentials = R;
|
|
3942
3937
|
for (var te in Q)
|
|
@@ -3952,18 +3947,18 @@ var n0 = { exports: {} };
|
|
|
3952
3947
|
function j() {
|
|
3953
3948
|
}
|
|
3954
3949
|
j.prototype.open = function(v, B, O, w, z, R, Q) {
|
|
3955
|
-
var
|
|
3950
|
+
var ce = null, te = new x(), se = te.signal, ae = new h();
|
|
3956
3951
|
return c(z, {
|
|
3957
3952
|
headers: Q,
|
|
3958
3953
|
credentials: R ? "include" : "same-origin",
|
|
3959
3954
|
signal: se,
|
|
3960
3955
|
cache: "no-store"
|
|
3961
3956
|
}).then(function(V) {
|
|
3962
|
-
return
|
|
3957
|
+
return ce = V.body.getReader(), B(V.status, V.statusText, V.headers.get("Content-Type"), new A(V.headers)), new f(function(he, pt) {
|
|
3963
3958
|
var gn = function() {
|
|
3964
|
-
|
|
3959
|
+
ce.read().then(function(ke) {
|
|
3965
3960
|
if (ke.done)
|
|
3966
|
-
|
|
3961
|
+
he(void 0);
|
|
3967
3962
|
else {
|
|
3968
3963
|
var Te = ae.decode(ke.value, { stream: !0 });
|
|
3969
3964
|
O(Te), gn();
|
|
@@ -3981,7 +3976,7 @@ var n0 = { exports: {} };
|
|
|
3981
3976
|
w(V);
|
|
3982
3977
|
}), {
|
|
3983
3978
|
abort: function() {
|
|
3984
|
-
|
|
3979
|
+
ce?.cancel(), te.abort();
|
|
3985
3980
|
}
|
|
3986
3981
|
};
|
|
3987
3982
|
};
|
|
@@ -4024,10 +4019,10 @@ var n0 = { exports: {} };
|
|
|
4024
4019
|
function Y(v) {
|
|
4025
4020
|
this.type = v, this.target = void 0;
|
|
4026
4021
|
}
|
|
4027
|
-
function
|
|
4022
|
+
function fe(v, B) {
|
|
4028
4023
|
Y.call(this, v), this.data = B.data, this.lastEventId = B.lastEventId;
|
|
4029
4024
|
}
|
|
4030
|
-
|
|
4025
|
+
fe.prototype = Object.create(Y.prototype);
|
|
4031
4026
|
function M(v, B) {
|
|
4032
4027
|
Y.call(this, v), this.status = B.status, this.statusText = B.statusText, this.headers = B.headers;
|
|
4033
4028
|
}
|
|
@@ -4036,7 +4031,7 @@ var n0 = { exports: {} };
|
|
|
4036
4031
|
Y.call(this, v), this.error = B.error;
|
|
4037
4032
|
}
|
|
4038
4033
|
S.prototype = Object.create(Y.prototype);
|
|
4039
|
-
var E = -1, I = 0, d = 1, m = 2, b = -1,
|
|
4034
|
+
var E = -1, I = 0, d = 1, m = 2, b = -1, C = 0, N = 1, q = 2, $ = 3, ie = /^text\/event\-stream(;.*)?$/i, pe = 1e3, He = 18e6, dt = function(v, B) {
|
|
4040
4035
|
var O = v == null ? B : parseInt(v, 10);
|
|
4041
4036
|
return O !== O && (O = B), Qe(O);
|
|
4042
4037
|
}, Qe = function(v) {
|
|
@@ -4057,7 +4052,7 @@ var n0 = { exports: {} };
|
|
|
4057
4052
|
var Wt = c != null && p != null && "body" in p.prototype;
|
|
4058
4053
|
function b2(v, B, O) {
|
|
4059
4054
|
B = String(B);
|
|
4060
|
-
var w = !!O.withCredentials, z = O.lastEventIdQueryParameterName || "lastEventId", R = Qe(1e3), Q = dt(O.heartbeatTimeout, 45e3),
|
|
4055
|
+
var w = !!O.withCredentials, z = O.lastEventIdQueryParameterName || "lastEventId", R = Qe(1e3), Q = dt(O.heartbeatTimeout, 45e3), ce = "", te = R, se = !1, ae = 0, V = O.headers || {}, he = O.Transport, pt = Wt && he == null ? void 0 : new k(he != null ? new he() : Pt()), gn = he != null && typeof he != "string" ? new he() : pt == null ? new j() : new L(), ke = void 0, Te = 0, Ze = E, Qt = "", Xn = "", vt = "", Yn = "", Ie = C, Br = 0, Ft = 0, y2 = function(Ee, be, Ge, Ue) {
|
|
4061
4056
|
if (Ze === I)
|
|
4062
4057
|
if (Ee === 200 && Ge != null && ie.test(Ge)) {
|
|
4063
4058
|
Ze = d, se = Date.now(), te = R, v.readyState = d;
|
|
@@ -4077,7 +4072,7 @@ var n0 = { exports: {} };
|
|
|
4077
4072
|
});
|
|
4078
4073
|
v.dispatchEvent(Me), ve(v, v.onerror, Me), console.error(Ae);
|
|
4079
4074
|
}
|
|
4080
|
-
},
|
|
4075
|
+
}, C2 = function(Ee) {
|
|
4081
4076
|
if (Ze === d) {
|
|
4082
4077
|
for (var be = -1, Ge = 0; Ge < Ee.length; Ge += 1) {
|
|
4083
4078
|
var Ue = Ee.charCodeAt(Ge);
|
|
@@ -4088,9 +4083,9 @@ var n0 = { exports: {} };
|
|
|
4088
4083
|
for (var Ae = 0; Ae < Me.length; Ae += 1) {
|
|
4089
4084
|
var Ue = Me.charCodeAt(Ae);
|
|
4090
4085
|
if (Ie === b && Ue === 10)
|
|
4091
|
-
Ie =
|
|
4092
|
-
else if (Ie === b && (Ie =
|
|
4093
|
-
if (Ie !==
|
|
4086
|
+
Ie = C;
|
|
4087
|
+
else if (Ie === b && (Ie = C), Ue === 13 || Ue === 10) {
|
|
4088
|
+
if (Ie !== C) {
|
|
4094
4089
|
Ie === N && (Ft = Ae + 1);
|
|
4095
4090
|
var gt = Me.slice(Br, Ft - 1), mt = Me.slice(Ft + (Ft < Ae && Me.charCodeAt(Ft) === 32 ? 1 : 0), Ae);
|
|
4096
4091
|
gt === "data" ? (Qt += `
|
|
@@ -4098,10 +4093,10 @@ var n0 = { exports: {} };
|
|
|
4098
4093
|
mn();
|
|
4099
4094
|
}, Q)));
|
|
4100
4095
|
}
|
|
4101
|
-
if (Ie ===
|
|
4096
|
+
if (Ie === C) {
|
|
4102
4097
|
if (Qt !== "") {
|
|
4103
|
-
|
|
4104
|
-
var Zt = new
|
|
4098
|
+
ce = Xn, vt === "" && (vt = "message");
|
|
4099
|
+
var Zt = new fe(vt, {
|
|
4105
4100
|
data: Qt.slice(1),
|
|
4106
4101
|
lastEventId: Xn
|
|
4107
4102
|
});
|
|
@@ -4110,9 +4105,9 @@ var n0 = { exports: {} };
|
|
|
4110
4105
|
}
|
|
4111
4106
|
Qt = "", vt = "";
|
|
4112
4107
|
}
|
|
4113
|
-
Ie = Ue === 13 ? b :
|
|
4108
|
+
Ie = Ue === 13 ? b : C;
|
|
4114
4109
|
} else
|
|
4115
|
-
Ie ===
|
|
4110
|
+
Ie === C && (Br = Ae, Ie = N), Ie === N ? Ue === 58 && (Ft = Ae + 1, Ie = q) : Ie === q && (Ie = $);
|
|
4116
4111
|
}
|
|
4117
4112
|
}
|
|
4118
4113
|
}, X0 = function(Ee) {
|
|
@@ -4139,13 +4134,13 @@ var n0 = { exports: {} };
|
|
|
4139
4134
|
}
|
|
4140
4135
|
se = !1, ae = 0, Te = r(function() {
|
|
4141
4136
|
mn();
|
|
4142
|
-
}, Q), Ze = I, Qt = "", vt = "", Xn =
|
|
4137
|
+
}, Q), Ze = I, Qt = "", vt = "", Xn = ce, Yn = "", Br = 0, Ft = 0, Ie = C;
|
|
4143
4138
|
var be = B;
|
|
4144
|
-
if (B.slice(0, 5) !== "data:" && B.slice(0, 5) !== "blob:" &&
|
|
4139
|
+
if (B.slice(0, 5) !== "data:" && B.slice(0, 5) !== "blob:" && ce !== "") {
|
|
4145
4140
|
var Ge = B.indexOf("?");
|
|
4146
4141
|
be = Ge === -1 ? B : B.slice(0, Ge + 1) + B.slice(Ge + 1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g, function(mt, Zt) {
|
|
4147
4142
|
return Zt === z ? "" : mt;
|
|
4148
|
-
}), be += (B.indexOf("?") === -1 ? "?" : "&") + z + "=" + encodeURIComponent(
|
|
4143
|
+
}), be += (B.indexOf("?") === -1 ? "?" : "&") + z + "=" + encodeURIComponent(ce);
|
|
4149
4144
|
}
|
|
4150
4145
|
var Ue = v.withCredentials, Me = {};
|
|
4151
4146
|
Me.Accept = "text/event-stream";
|
|
@@ -4154,7 +4149,7 @@ var n0 = { exports: {} };
|
|
|
4154
4149
|
for (var gt in Ae)
|
|
4155
4150
|
Object.prototype.hasOwnProperty.call(Ae, gt) && (Me[gt] = Ae[gt]);
|
|
4156
4151
|
try {
|
|
4157
|
-
ke = gn.open(pt,
|
|
4152
|
+
ke = gn.open(pt, y2, C2, X0, be, Ue, Me);
|
|
4158
4153
|
} catch (mt) {
|
|
4159
4154
|
throw Tr(), mt;
|
|
4160
4155
|
}
|
|
@@ -4276,7 +4271,7 @@ var Gs = { exports: {} };
|
|
|
4276
4271
|
(function(n, r) {
|
|
4277
4272
|
e.exports = r();
|
|
4278
4273
|
})(N0, function() {
|
|
4279
|
-
var n = 1e3, r = 6e4, i = 36e5, s = "millisecond", o = "second", a = "minute", l = "hour", u = "day", f = "week", c = "month", p = "quarter", h = "year", g = "date", x = "Invalid Date",
|
|
4274
|
+
var n = 1e3, r = 6e4, i = 36e5, s = "millisecond", o = "second", a = "minute", l = "hour", u = "day", f = "week", c = "month", p = "quarter", h = "year", g = "date", x = "Invalid Date", y = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, T = /\[([^\]]+)]|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, U = { 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(M) {
|
|
4280
4275
|
var S = ["th", "st", "nd", "rd"], E = M % 100;
|
|
4281
4276
|
return "[" + M + (S[(E - 20) % 10] || S[E] || S[0]) + "]";
|
|
4282
4277
|
} }, F = function(M, S, E) {
|
|
@@ -4308,8 +4303,8 @@ var Gs = { exports: {} };
|
|
|
4308
4303
|
var b = S.split("-");
|
|
4309
4304
|
if (!d && b.length > 1) return M(b[0]);
|
|
4310
4305
|
} else {
|
|
4311
|
-
var
|
|
4312
|
-
H[
|
|
4306
|
+
var C = S.name;
|
|
4307
|
+
H[C] = S, d = C;
|
|
4313
4308
|
}
|
|
4314
4309
|
return !I && d && (X = d), d || !I && X;
|
|
4315
4310
|
}, D = function(M, S) {
|
|
@@ -4332,10 +4327,10 @@ var Gs = { exports: {} };
|
|
|
4332
4327
|
if (P.u(d)) return /* @__PURE__ */ new Date();
|
|
4333
4328
|
if (d instanceof Date) return new Date(d);
|
|
4334
4329
|
if (typeof d == "string" && !/Z$/i.test(d)) {
|
|
4335
|
-
var b = d.match(
|
|
4330
|
+
var b = d.match(y);
|
|
4336
4331
|
if (b) {
|
|
4337
|
-
var
|
|
4338
|
-
return m ? new Date(Date.UTC(b[1],
|
|
4332
|
+
var C = b[2] - 1 || 0, N = (b[7] || "0").substring(0, 3);
|
|
4333
|
+
return m ? new Date(Date.UTC(b[1], C, b[3] || 1, b[4] || 0, b[5] || 0, b[6] || 0, N)) : new Date(b[1], C, b[3] || 1, b[4] || 0, b[5] || 0, b[6] || 0, N);
|
|
4339
4334
|
}
|
|
4340
4335
|
}
|
|
4341
4336
|
return new Date(d);
|
|
@@ -4361,20 +4356,20 @@ var Gs = { exports: {} };
|
|
|
4361
4356
|
}, S.valueOf = function() {
|
|
4362
4357
|
return this.$d.getTime();
|
|
4363
4358
|
}, S.startOf = function(E, I) {
|
|
4364
|
-
var d = this, m = !!P.u(I) || I, b = P.p(E),
|
|
4359
|
+
var d = this, m = !!P.u(I) || I, b = P.p(E), C = function(Qe, ve) {
|
|
4365
4360
|
var me = P.w(d.$u ? Date.UTC(d.$y, ve, Qe) : new Date(d.$y, ve, Qe), d);
|
|
4366
4361
|
return m ? me : me.endOf(u);
|
|
4367
4362
|
}, N = function(Qe, ve) {
|
|
4368
4363
|
return P.w(d.toDate()[Qe].apply(d.toDate("s"), (m ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(ve)), d);
|
|
4369
|
-
},
|
|
4364
|
+
}, q = this.$W, $ = this.$M, ie = this.$D, pe = "set" + (this.$u ? "UTC" : "");
|
|
4370
4365
|
switch (b) {
|
|
4371
4366
|
case h:
|
|
4372
|
-
return m ?
|
|
4367
|
+
return m ? C(1, 0) : C(31, 11);
|
|
4373
4368
|
case c:
|
|
4374
|
-
return m ?
|
|
4369
|
+
return m ? C(1, $) : C(0, $ + 1);
|
|
4375
4370
|
case f:
|
|
4376
|
-
var He = this.$locale().weekStart || 0, dt = (
|
|
4377
|
-
return
|
|
4371
|
+
var He = this.$locale().weekStart || 0, dt = (q < He ? q + 7 : q) - He;
|
|
4372
|
+
return C(m ? ie - dt : ie + (6 - dt), $);
|
|
4378
4373
|
case u:
|
|
4379
4374
|
case g:
|
|
4380
4375
|
return N(pe + "Hours", 0);
|
|
@@ -4390,11 +4385,11 @@ var Gs = { exports: {} };
|
|
|
4390
4385
|
}, S.endOf = function(E) {
|
|
4391
4386
|
return this.startOf(E, !1);
|
|
4392
4387
|
}, S.$set = function(E, I) {
|
|
4393
|
-
var d, m = P.p(E), b = "set" + (this.$u ? "UTC" : ""),
|
|
4388
|
+
var d, m = P.p(E), b = "set" + (this.$u ? "UTC" : ""), C = (d = {}, d[u] = b + "Date", d[g] = b + "Date", d[c] = b + "Month", d[h] = b + "FullYear", d[l] = b + "Hours", d[a] = b + "Minutes", d[o] = b + "Seconds", d[s] = b + "Milliseconds", d)[m], N = m === u ? this.$D + (I - this.$W) : I;
|
|
4394
4389
|
if (m === c || m === h) {
|
|
4395
|
-
var
|
|
4396
|
-
|
|
4397
|
-
} else
|
|
4390
|
+
var q = this.clone().set(g, 1);
|
|
4391
|
+
q.$d[C](N), q.init(), this.$d = q.set(g, Math.min(this.$D, q.daysInMonth())).$d;
|
|
4392
|
+
} else C && this.$d[C](N);
|
|
4398
4393
|
return this.init(), this;
|
|
4399
4394
|
}, S.set = function(E, I) {
|
|
4400
4395
|
return this.clone().$set(E, I);
|
|
@@ -4403,25 +4398,25 @@ var Gs = { exports: {} };
|
|
|
4403
4398
|
}, S.add = function(E, I) {
|
|
4404
4399
|
var d, m = this;
|
|
4405
4400
|
E = Number(E);
|
|
4406
|
-
var b = P.p(I),
|
|
4401
|
+
var b = P.p(I), C = function($) {
|
|
4407
4402
|
var ie = D(m);
|
|
4408
|
-
return P.w(ie.date(ie.date() + Math.round(
|
|
4403
|
+
return P.w(ie.date(ie.date() + Math.round($ * E)), m);
|
|
4409
4404
|
};
|
|
4410
4405
|
if (b === c) return this.set(c, this.$M + E);
|
|
4411
4406
|
if (b === h) return this.set(h, this.$y + E);
|
|
4412
|
-
if (b === u) return
|
|
4413
|
-
if (b === f) return
|
|
4414
|
-
var N = (d = {}, d[a] = r, d[l] = i, d[o] = n, d)[b] || 1,
|
|
4415
|
-
return P.w(
|
|
4407
|
+
if (b === u) return C(1);
|
|
4408
|
+
if (b === f) return C(7);
|
|
4409
|
+
var N = (d = {}, d[a] = r, d[l] = i, d[o] = n, d)[b] || 1, q = this.$d.getTime() + E * N;
|
|
4410
|
+
return P.w(q, this);
|
|
4416
4411
|
}, S.subtract = function(E, I) {
|
|
4417
4412
|
return this.add(-1 * E, I);
|
|
4418
4413
|
}, S.format = function(E) {
|
|
4419
4414
|
var I = this, d = this.$locale();
|
|
4420
4415
|
if (!this.isValid()) return d.invalidDate || x;
|
|
4421
|
-
var m = E || "YYYY-MM-DDTHH:mm:ssZ", b = P.z(this),
|
|
4416
|
+
var m = E || "YYYY-MM-DDTHH:mm:ssZ", b = P.z(this), C = this.$H, N = this.$m, q = this.$M, $ = d.weekdays, ie = d.months, pe = d.meridiem, He = function(ve, me, Pt, Wt) {
|
|
4422
4417
|
return ve && (ve[me] || ve(I, m)) || Pt[me].slice(0, Wt);
|
|
4423
4418
|
}, dt = function(ve) {
|
|
4424
|
-
return P.s(
|
|
4419
|
+
return P.s(C % 12 || 12, ve, "0");
|
|
4425
4420
|
}, Qe = pe || function(ve, me, Pt) {
|
|
4426
4421
|
var Wt = ve < 12 ? "AM" : "PM";
|
|
4427
4422
|
return Pt ? Wt.toLowerCase() : Wt;
|
|
@@ -4434,13 +4429,13 @@ var Gs = { exports: {} };
|
|
|
4434
4429
|
case "YYYY":
|
|
4435
4430
|
return P.s(I.$y, 4, "0");
|
|
4436
4431
|
case "M":
|
|
4437
|
-
return
|
|
4432
|
+
return q + 1;
|
|
4438
4433
|
case "MM":
|
|
4439
|
-
return P.s(
|
|
4434
|
+
return P.s(q + 1, 2, "0");
|
|
4440
4435
|
case "MMM":
|
|
4441
|
-
return He(d.monthsShort,
|
|
4436
|
+
return He(d.monthsShort, q, ie, 3);
|
|
4442
4437
|
case "MMMM":
|
|
4443
|
-
return He(ie,
|
|
4438
|
+
return He(ie, q);
|
|
4444
4439
|
case "D":
|
|
4445
4440
|
return I.$D;
|
|
4446
4441
|
case "DD":
|
|
@@ -4448,23 +4443,23 @@ var Gs = { exports: {} };
|
|
|
4448
4443
|
case "d":
|
|
4449
4444
|
return String(I.$W);
|
|
4450
4445
|
case "dd":
|
|
4451
|
-
return He(d.weekdaysMin, I.$W,
|
|
4446
|
+
return He(d.weekdaysMin, I.$W, $, 2);
|
|
4452
4447
|
case "ddd":
|
|
4453
|
-
return He(d.weekdaysShort, I.$W,
|
|
4448
|
+
return He(d.weekdaysShort, I.$W, $, 3);
|
|
4454
4449
|
case "dddd":
|
|
4455
|
-
return
|
|
4450
|
+
return $[I.$W];
|
|
4456
4451
|
case "H":
|
|
4457
|
-
return String(
|
|
4452
|
+
return String(C);
|
|
4458
4453
|
case "HH":
|
|
4459
|
-
return P.s(
|
|
4454
|
+
return P.s(C, 2, "0");
|
|
4460
4455
|
case "h":
|
|
4461
4456
|
return dt(1);
|
|
4462
4457
|
case "hh":
|
|
4463
4458
|
return dt(2);
|
|
4464
4459
|
case "a":
|
|
4465
|
-
return Qe(
|
|
4460
|
+
return Qe(C, N, !0);
|
|
4466
4461
|
case "A":
|
|
4467
|
-
return Qe(
|
|
4462
|
+
return Qe(C, N, !1);
|
|
4468
4463
|
case "m":
|
|
4469
4464
|
return String(N);
|
|
4470
4465
|
case "mm":
|
|
@@ -4484,10 +4479,10 @@ var Gs = { exports: {} };
|
|
|
4484
4479
|
}, S.utcOffset = function() {
|
|
4485
4480
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
4486
4481
|
}, S.diff = function(E, I, d) {
|
|
4487
|
-
var m, b = this,
|
|
4482
|
+
var m, b = this, C = P.p(I), N = D(E), q = (N.utcOffset() - this.utcOffset()) * r, $ = this - N, ie = function() {
|
|
4488
4483
|
return P.m(b, N);
|
|
4489
4484
|
};
|
|
4490
|
-
switch (
|
|
4485
|
+
switch (C) {
|
|
4491
4486
|
case h:
|
|
4492
4487
|
m = ie() / 12;
|
|
4493
4488
|
break;
|
|
@@ -4498,22 +4493,22 @@ var Gs = { exports: {} };
|
|
|
4498
4493
|
m = ie() / 3;
|
|
4499
4494
|
break;
|
|
4500
4495
|
case f:
|
|
4501
|
-
m = (
|
|
4496
|
+
m = ($ - q) / 6048e5;
|
|
4502
4497
|
break;
|
|
4503
4498
|
case u:
|
|
4504
|
-
m = (
|
|
4499
|
+
m = ($ - q) / 864e5;
|
|
4505
4500
|
break;
|
|
4506
4501
|
case l:
|
|
4507
|
-
m =
|
|
4502
|
+
m = $ / i;
|
|
4508
4503
|
break;
|
|
4509
4504
|
case a:
|
|
4510
|
-
m =
|
|
4505
|
+
m = $ / r;
|
|
4511
4506
|
break;
|
|
4512
4507
|
case o:
|
|
4513
|
-
m =
|
|
4508
|
+
m = $ / n;
|
|
4514
4509
|
break;
|
|
4515
4510
|
default:
|
|
4516
|
-
m =
|
|
4511
|
+
m = $;
|
|
4517
4512
|
}
|
|
4518
4513
|
return d ? m : P.a(m);
|
|
4519
4514
|
}, S.daysInMonth = function() {
|
|
@@ -4535,9 +4530,9 @@ var Gs = { exports: {} };
|
|
|
4535
4530
|
}, S.toString = function() {
|
|
4536
4531
|
return this.$d.toUTCString();
|
|
4537
4532
|
}, M;
|
|
4538
|
-
}(),
|
|
4539
|
-
return D.prototype =
|
|
4540
|
-
|
|
4533
|
+
}(), fe = Y.prototype;
|
|
4534
|
+
return D.prototype = fe, [["$ms", s], ["$s", o], ["$m", a], ["$H", l], ["$W", u], ["$M", c], ["$y", h], ["$D", g]].forEach(function(M) {
|
|
4535
|
+
fe[M[1]] = function(S) {
|
|
4541
4536
|
return this.$g(S, M[0], M[1]);
|
|
4542
4537
|
};
|
|
4543
4538
|
}), D.extend = function(M, S) {
|
|
@@ -4560,14 +4555,14 @@ var Us = { exports: {} };
|
|
|
4560
4555
|
return new k(H, A, L.$l);
|
|
4561
4556
|
}, x = function(H) {
|
|
4562
4557
|
return r.p(H) + "s";
|
|
4563
|
-
},
|
|
4558
|
+
}, y = function(H) {
|
|
4564
4559
|
return H < 0;
|
|
4565
4560
|
}, T = function(H) {
|
|
4566
|
-
return
|
|
4561
|
+
return y(H) ? Math.ceil(H) : Math.floor(H);
|
|
4567
4562
|
}, U = function(H) {
|
|
4568
4563
|
return Math.abs(H);
|
|
4569
4564
|
}, F = function(H, L) {
|
|
4570
|
-
return H ?
|
|
4565
|
+
return H ? y(H) ? { negative: !0, format: "" + U(H) + L } : { negative: !1, format: "" + H + L } : { negative: !1, format: "" };
|
|
4571
4566
|
}, k = function() {
|
|
4572
4567
|
function H(A, j, D) {
|
|
4573
4568
|
var P = this;
|
|
@@ -4579,10 +4574,10 @@ var Us = { exports: {} };
|
|
|
4579
4574
|
if (typeof A == "string") {
|
|
4580
4575
|
var Y = A.match(f);
|
|
4581
4576
|
if (Y) {
|
|
4582
|
-
var
|
|
4577
|
+
var fe = Y.slice(2).map(function(M) {
|
|
4583
4578
|
return M != null ? Number(M) : 0;
|
|
4584
4579
|
});
|
|
4585
|
-
return this.$d.years =
|
|
4580
|
+
return this.$d.years = fe[0], this.$d.months = fe[1], this.$d.weeks = fe[2], this.$d.days = fe[3], this.$d.hours = fe[4], this.$d.minutes = fe[5], this.$d.seconds = fe[6], this.calMilliseconds(), this;
|
|
4586
4581
|
}
|
|
4587
4582
|
}
|
|
4588
4583
|
return this;
|
|
@@ -4599,9 +4594,9 @@ var Us = { exports: {} };
|
|
|
4599
4594
|
}, L.toISOString = function() {
|
|
4600
4595
|
var A = F(this.$d.years, "Y"), j = F(this.$d.months, "M"), D = +this.$d.days || 0;
|
|
4601
4596
|
this.$d.weeks && (D += 7 * this.$d.weeks);
|
|
4602
|
-
var P = F(D, "D"), Y = F(this.$d.hours, "H"),
|
|
4597
|
+
var P = F(D, "D"), Y = F(this.$d.hours, "H"), fe = F(this.$d.minutes, "M"), M = this.$d.seconds || 0;
|
|
4603
4598
|
this.$d.milliseconds && (M += this.$d.milliseconds / 1e3, M = Math.round(1e3 * M) / 1e3);
|
|
4604
|
-
var S = F(M, "S"), E = A.negative || j.negative || P.negative || Y.negative ||
|
|
4599
|
+
var S = F(M, "S"), E = A.negative || j.negative || P.negative || Y.negative || fe.negative || S.negative, I = Y.format || fe.format || S.format ? "T" : "", d = (E ? "-" : "") + "P" + A.format + j.format + P.format + I + Y.format + fe.format + S.format;
|
|
4605
4600
|
return d === "P" || d === "-P" ? "P0D" : d;
|
|
4606
4601
|
}, L.toJSON = function() {
|
|
4607
4602
|
return this.toISOString();
|
|
@@ -4667,8 +4662,8 @@ var Us = { exports: {} };
|
|
|
4667
4662
|
};
|
|
4668
4663
|
return function(H, L, A) {
|
|
4669
4664
|
n = A, r = A().$utils(), A.duration = function(P, Y) {
|
|
4670
|
-
var
|
|
4671
|
-
return g(P, { $l:
|
|
4665
|
+
var fe = A.locale();
|
|
4666
|
+
return g(P, { $l: fe }, Y);
|
|
4672
4667
|
}, A.isDuration = h;
|
|
4673
4668
|
var j = L.prototype.add, D = L.prototype.subtract;
|
|
4674
4669
|
L.prototype.add = function(P, Y) {
|
|
@@ -4943,44 +4938,44 @@ var ll = function() {
|
|
|
4943
4938
|
return t;
|
|
4944
4939
|
}, hr.apply(this, arguments);
|
|
4945
4940
|
};
|
|
4946
|
-
var
|
|
4941
|
+
var ee;
|
|
4947
4942
|
(function(e) {
|
|
4948
4943
|
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";
|
|
4949
|
-
})(
|
|
4950
|
-
var
|
|
4944
|
+
})(ee || (ee = {}));
|
|
4945
|
+
var ue;
|
|
4951
4946
|
(function(e) {
|
|
4952
4947
|
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";
|
|
4953
|
-
})(
|
|
4948
|
+
})(ue || (ue = {}));
|
|
4954
4949
|
var fn;
|
|
4955
4950
|
(function(e) {
|
|
4956
4951
|
e[e.number = 0] = "number", e[e.dateTime = 1] = "dateTime";
|
|
4957
4952
|
})(fn || (fn = {}));
|
|
4958
4953
|
function ui(e) {
|
|
4959
|
-
return e.type ===
|
|
4954
|
+
return e.type === ue.literal;
|
|
4960
4955
|
}
|
|
4961
4956
|
function cl(e) {
|
|
4962
|
-
return e.type ===
|
|
4957
|
+
return e.type === ue.argument;
|
|
4963
4958
|
}
|
|
4964
4959
|
function Ys(e) {
|
|
4965
|
-
return e.type ===
|
|
4960
|
+
return e.type === ue.number;
|
|
4966
4961
|
}
|
|
4967
4962
|
function Ws(e) {
|
|
4968
|
-
return e.type ===
|
|
4963
|
+
return e.type === ue.date;
|
|
4969
4964
|
}
|
|
4970
4965
|
function Qs(e) {
|
|
4971
|
-
return e.type ===
|
|
4966
|
+
return e.type === ue.time;
|
|
4972
4967
|
}
|
|
4973
4968
|
function Zs(e) {
|
|
4974
|
-
return e.type ===
|
|
4969
|
+
return e.type === ue.select;
|
|
4975
4970
|
}
|
|
4976
4971
|
function qs(e) {
|
|
4977
|
-
return e.type ===
|
|
4972
|
+
return e.type === ue.plural;
|
|
4978
4973
|
}
|
|
4979
4974
|
function hl(e) {
|
|
4980
|
-
return e.type ===
|
|
4975
|
+
return e.type === ue.pound;
|
|
4981
4976
|
}
|
|
4982
4977
|
function Js(e) {
|
|
4983
|
-
return e.type ===
|
|
4978
|
+
return e.type === ue.tag;
|
|
4984
4979
|
}
|
|
4985
4980
|
function Ks(e) {
|
|
4986
4981
|
return !!(e && typeof e == "object" && e.type === fn.number);
|
|
@@ -5080,14 +5075,14 @@ function pl(e) {
|
|
|
5080
5075
|
return "";
|
|
5081
5076
|
}), t;
|
|
5082
5077
|
}
|
|
5083
|
-
var
|
|
5084
|
-
return
|
|
5078
|
+
var de = function() {
|
|
5079
|
+
return de = Object.assign || function(t) {
|
|
5085
5080
|
for (var n, r = 1, i = arguments.length; r < i; r++) {
|
|
5086
5081
|
n = arguments[r];
|
|
5087
5082
|
for (var s in n) Object.prototype.hasOwnProperty.call(n, s) && (t[s] = n[s]);
|
|
5088
5083
|
}
|
|
5089
5084
|
return t;
|
|
5090
|
-
},
|
|
5085
|
+
}, de.apply(this, arguments);
|
|
5091
5086
|
};
|
|
5092
5087
|
var vl = /[\t-\r \x85\u200E\u200F\u2028\u2029]/i;
|
|
5093
5088
|
function gl(e) {
|
|
@@ -5158,7 +5153,7 @@ function n2(e) {
|
|
|
5158
5153
|
};
|
|
5159
5154
|
}
|
|
5160
5155
|
}
|
|
5161
|
-
function
|
|
5156
|
+
function yl(e) {
|
|
5162
5157
|
var t;
|
|
5163
5158
|
if (e[0] === "E" && e[1] === "E" ? (t = {
|
|
5164
5159
|
notation: "engineering"
|
|
@@ -5176,7 +5171,7 @@ function hi(e) {
|
|
|
5176
5171
|
var t = {}, n = n2(e);
|
|
5177
5172
|
return n || t;
|
|
5178
5173
|
}
|
|
5179
|
-
function
|
|
5174
|
+
function Cl(e) {
|
|
5180
5175
|
for (var t = {}, n = 0, r = e; n < r.length; n++) {
|
|
5181
5176
|
var i = r[n];
|
|
5182
5177
|
switch (i.stem) {
|
|
@@ -5211,13 +5206,13 @@ function yl(e) {
|
|
|
5211
5206
|
t.notation = "compact", t.compactDisplay = "long";
|
|
5212
5207
|
continue;
|
|
5213
5208
|
case "scientific":
|
|
5214
|
-
t =
|
|
5215
|
-
return
|
|
5209
|
+
t = de(de(de({}, t), { notation: "scientific" }), i.options.reduce(function(l, u) {
|
|
5210
|
+
return de(de({}, l), hi(u));
|
|
5216
5211
|
}, {}));
|
|
5217
5212
|
continue;
|
|
5218
5213
|
case "engineering":
|
|
5219
|
-
t =
|
|
5220
|
-
return
|
|
5214
|
+
t = de(de(de({}, t), { notation: "engineering" }), i.options.reduce(function(l, u) {
|
|
5215
|
+
return de(de({}, l), hi(u));
|
|
5221
5216
|
}, {}));
|
|
5222
5217
|
continue;
|
|
5223
5218
|
case "notation-simple":
|
|
@@ -5286,17 +5281,17 @@ function yl(e) {
|
|
|
5286
5281
|
return f === "*" ? t.minimumFractionDigits = u.length : c && c[0] === "#" ? t.maximumFractionDigits = c.length : p && h ? (t.minimumFractionDigits = p.length, t.maximumFractionDigits = p.length + h.length) : (t.minimumFractionDigits = u.length, t.maximumFractionDigits = u.length), "";
|
|
5287
5282
|
});
|
|
5288
5283
|
var s = i.options[0];
|
|
5289
|
-
s === "w" ? t =
|
|
5284
|
+
s === "w" ? t = de(de({}, t), { trailingZeroDisplay: "stripIfInteger" }) : s && (t = de(de({}, t), ci(s)));
|
|
5290
5285
|
continue;
|
|
5291
5286
|
}
|
|
5292
5287
|
if (e2.test(i.stem)) {
|
|
5293
|
-
t =
|
|
5288
|
+
t = de(de({}, t), ci(i.stem));
|
|
5294
5289
|
continue;
|
|
5295
5290
|
}
|
|
5296
5291
|
var o = n2(i.stem);
|
|
5297
|
-
o && (t =
|
|
5298
|
-
var a =
|
|
5299
|
-
a && (t =
|
|
5292
|
+
o && (t = de(de({}, t), o));
|
|
5293
|
+
var a = yl(i.stem);
|
|
5294
|
+
a && (t = de(de({}, t), a));
|
|
5300
5295
|
}
|
|
5301
5296
|
return t;
|
|
5302
5297
|
}
|
|
@@ -6880,13 +6875,13 @@ var Dl = (
|
|
|
6880
6875
|
if (s === 35 && (n === "plural" || n === "selectordinal")) {
|
|
6881
6876
|
var a = this.clonePosition();
|
|
6882
6877
|
this.bump(), i.push({
|
|
6883
|
-
type:
|
|
6878
|
+
type: ue.pound,
|
|
6884
6879
|
location: ne(a, this.clonePosition())
|
|
6885
6880
|
});
|
|
6886
6881
|
} else if (s === 60 && !this.ignoreTag && this.peek() === 47) {
|
|
6887
6882
|
if (r)
|
|
6888
6883
|
break;
|
|
6889
|
-
return this.error(
|
|
6884
|
+
return this.error(ee.UNMATCHED_CLOSING_TAG, ne(this.clonePosition(), this.clonePosition()));
|
|
6890
6885
|
} else if (s === 60 && !this.ignoreTag && l0(this.peek() || 0)) {
|
|
6891
6886
|
var o = this.parseTag(t, n);
|
|
6892
6887
|
if (o.err)
|
|
@@ -6908,7 +6903,7 @@ var Dl = (
|
|
|
6908
6903
|
if (this.bumpSpace(), this.bumpIf("/>"))
|
|
6909
6904
|
return {
|
|
6910
6905
|
val: {
|
|
6911
|
-
type:
|
|
6906
|
+
type: ue.literal,
|
|
6912
6907
|
value: "<".concat(i, "/>"),
|
|
6913
6908
|
location: ne(r, this.clonePosition())
|
|
6914
6909
|
},
|
|
@@ -6921,21 +6916,21 @@ var Dl = (
|
|
|
6921
6916
|
var o = s.val, a = this.clonePosition();
|
|
6922
6917
|
if (this.bumpIf("</")) {
|
|
6923
6918
|
if (this.isEOF() || !l0(this.char()))
|
|
6924
|
-
return this.error(
|
|
6919
|
+
return this.error(ee.INVALID_TAG, ne(a, this.clonePosition()));
|
|
6925
6920
|
var l = this.clonePosition(), u = this.parseTagName();
|
|
6926
|
-
return i !== u ? this.error(
|
|
6921
|
+
return i !== u ? this.error(ee.UNMATCHED_CLOSING_TAG, ne(l, this.clonePosition())) : (this.bumpSpace(), this.bumpIf(">") ? {
|
|
6927
6922
|
val: {
|
|
6928
|
-
type:
|
|
6923
|
+
type: ue.tag,
|
|
6929
6924
|
value: i,
|
|
6930
6925
|
children: o,
|
|
6931
6926
|
location: ne(r, this.clonePosition())
|
|
6932
6927
|
},
|
|
6933
6928
|
err: null
|
|
6934
|
-
} : this.error(
|
|
6929
|
+
} : this.error(ee.INVALID_TAG, ne(a, this.clonePosition())));
|
|
6935
6930
|
} else
|
|
6936
|
-
return this.error(
|
|
6931
|
+
return this.error(ee.UNCLOSED_TAG, ne(r, this.clonePosition()));
|
|
6937
6932
|
} else
|
|
6938
|
-
return this.error(
|
|
6933
|
+
return this.error(ee.INVALID_TAG, ne(r, this.clonePosition()));
|
|
6939
6934
|
}, e.prototype.parseTagName = function() {
|
|
6940
6935
|
var t = this.offset();
|
|
6941
6936
|
for (this.bump(); !this.isEOF() && Rl(this.char()); )
|
|
@@ -6962,7 +6957,7 @@ var Dl = (
|
|
|
6962
6957
|
}
|
|
6963
6958
|
var l = ne(r, this.clonePosition());
|
|
6964
6959
|
return {
|
|
6965
|
-
val: { type:
|
|
6960
|
+
val: { type: ue.literal, value: i, location: l },
|
|
6966
6961
|
err: null
|
|
6967
6962
|
};
|
|
6968
6963
|
}, e.prototype.tryParseLeftAngleBracket = function() {
|
|
@@ -7010,19 +7005,19 @@ var Dl = (
|
|
|
7010
7005
|
}, e.prototype.parseArgument = function(t, n) {
|
|
7011
7006
|
var r = this.clonePosition();
|
|
7012
7007
|
if (this.bump(), this.bumpSpace(), this.isEOF())
|
|
7013
|
-
return this.error(
|
|
7008
|
+
return this.error(ee.EXPECT_ARGUMENT_CLOSING_BRACE, ne(r, this.clonePosition()));
|
|
7014
7009
|
if (this.char() === 125)
|
|
7015
|
-
return this.bump(), this.error(
|
|
7010
|
+
return this.bump(), this.error(ee.EMPTY_ARGUMENT, ne(r, this.clonePosition()));
|
|
7016
7011
|
var i = this.parseIdentifierIfPossible().value;
|
|
7017
7012
|
if (!i)
|
|
7018
|
-
return this.error(
|
|
7013
|
+
return this.error(ee.MALFORMED_ARGUMENT, ne(r, this.clonePosition()));
|
|
7019
7014
|
if (this.bumpSpace(), this.isEOF())
|
|
7020
|
-
return this.error(
|
|
7015
|
+
return this.error(ee.EXPECT_ARGUMENT_CLOSING_BRACE, ne(r, this.clonePosition()));
|
|
7021
7016
|
switch (this.char()) {
|
|
7022
7017
|
case 125:
|
|
7023
7018
|
return this.bump(), {
|
|
7024
7019
|
val: {
|
|
7025
|
-
type:
|
|
7020
|
+
type: ue.argument,
|
|
7026
7021
|
// value does not include the opening and closing braces.
|
|
7027
7022
|
value: i,
|
|
7028
7023
|
location: ne(r, this.clonePosition())
|
|
@@ -7030,9 +7025,9 @@ var Dl = (
|
|
|
7030
7025
|
err: null
|
|
7031
7026
|
};
|
|
7032
7027
|
case 44:
|
|
7033
|
-
return this.bump(), this.bumpSpace(), this.isEOF() ? this.error(
|
|
7028
|
+
return this.bump(), this.bumpSpace(), this.isEOF() ? this.error(ee.EXPECT_ARGUMENT_CLOSING_BRACE, ne(r, this.clonePosition())) : this.parseArgumentOptions(t, n, i, r);
|
|
7034
7029
|
default:
|
|
7035
|
-
return this.error(
|
|
7030
|
+
return this.error(ee.MALFORMED_ARGUMENT, ne(r, this.clonePosition()));
|
|
7036
7031
|
}
|
|
7037
7032
|
}, e.prototype.parseIdentifierIfPossible = function() {
|
|
7038
7033
|
var t = this.clonePosition(), n = this.offset(), r = a0(this.message, n), i = n + r.length;
|
|
@@ -7043,7 +7038,7 @@ var Dl = (
|
|
|
7043
7038
|
var s, o = this.clonePosition(), a = this.parseIdentifierIfPossible().value, l = this.clonePosition();
|
|
7044
7039
|
switch (a) {
|
|
7045
7040
|
case "":
|
|
7046
|
-
return this.error(
|
|
7041
|
+
return this.error(ee.EXPECT_ARGUMENT_TYPE, ne(o, l));
|
|
7047
7042
|
case "number":
|
|
7048
7043
|
case "date":
|
|
7049
7044
|
case "time": {
|
|
@@ -7056,7 +7051,7 @@ var Dl = (
|
|
|
7056
7051
|
return c;
|
|
7057
7052
|
var p = Hl(c.val);
|
|
7058
7053
|
if (p.length === 0)
|
|
7059
|
-
return this.error(
|
|
7054
|
+
return this.error(ee.EXPECT_ARGUMENT_STYLE, ne(this.clonePosition(), this.clonePosition()));
|
|
7060
7055
|
var h = ne(f, this.clonePosition());
|
|
7061
7056
|
u = { style: p, styleLocation: h };
|
|
7062
7057
|
}
|
|
@@ -7065,24 +7060,24 @@ var Dl = (
|
|
|
7065
7060
|
return g;
|
|
7066
7061
|
var x = ne(i, this.clonePosition());
|
|
7067
7062
|
if (u && di(u?.style, "::", 0)) {
|
|
7068
|
-
var
|
|
7063
|
+
var y = Fl(u.style.slice(2));
|
|
7069
7064
|
if (a === "number") {
|
|
7070
|
-
var c = this.parseNumberSkeletonFromString(
|
|
7065
|
+
var c = this.parseNumberSkeletonFromString(y, u.styleLocation);
|
|
7071
7066
|
return c.err ? c : {
|
|
7072
|
-
val: { type:
|
|
7067
|
+
val: { type: ue.number, value: r, location: x, style: c.val },
|
|
7073
7068
|
err: null
|
|
7074
7069
|
};
|
|
7075
7070
|
} else {
|
|
7076
|
-
if (
|
|
7077
|
-
return this.error(
|
|
7078
|
-
var T =
|
|
7079
|
-
this.locale && (T = El(
|
|
7071
|
+
if (y.length === 0)
|
|
7072
|
+
return this.error(ee.EXPECT_DATE_TIME_SKELETON, x);
|
|
7073
|
+
var T = y;
|
|
7074
|
+
this.locale && (T = El(y, this.locale));
|
|
7080
7075
|
var p = {
|
|
7081
7076
|
type: fn.dateTime,
|
|
7082
7077
|
pattern: T,
|
|
7083
7078
|
location: u.styleLocation,
|
|
7084
7079
|
parsedOptions: this.shouldParseSkeletons ? pl(T) : {}
|
|
7085
|
-
}, U = a === "date" ?
|
|
7080
|
+
}, U = a === "date" ? ue.date : ue.time;
|
|
7086
7081
|
return {
|
|
7087
7082
|
val: { type: U, value: r, location: x, style: p },
|
|
7088
7083
|
err: null
|
|
@@ -7091,7 +7086,7 @@ var Dl = (
|
|
|
7091
7086
|
}
|
|
7092
7087
|
return {
|
|
7093
7088
|
val: {
|
|
7094
|
-
type: a === "number" ?
|
|
7089
|
+
type: a === "number" ? ue.number : a === "date" ? ue.date : ue.time,
|
|
7095
7090
|
value: r,
|
|
7096
7091
|
location: x,
|
|
7097
7092
|
style: (s = u?.style) !== null && s !== void 0 ? s : null
|
|
@@ -7104,14 +7099,14 @@ var Dl = (
|
|
|
7104
7099
|
case "select": {
|
|
7105
7100
|
var F = this.clonePosition();
|
|
7106
7101
|
if (this.bumpSpace(), !this.bumpIf(","))
|
|
7107
|
-
return this.error(
|
|
7102
|
+
return this.error(ee.EXPECT_SELECT_ARGUMENT_OPTIONS, ne(F, hr({}, F)));
|
|
7108
7103
|
this.bumpSpace();
|
|
7109
7104
|
var k = this.parseIdentifierIfPossible(), X = 0;
|
|
7110
7105
|
if (a !== "select" && k.value === "offset") {
|
|
7111
7106
|
if (!this.bumpIf(":"))
|
|
7112
|
-
return this.error(
|
|
7107
|
+
return this.error(ee.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, ne(this.clonePosition(), this.clonePosition()));
|
|
7113
7108
|
this.bumpSpace();
|
|
7114
|
-
var c = this.tryParseDecimalInteger(
|
|
7109
|
+
var c = this.tryParseDecimalInteger(ee.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, ee.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);
|
|
7115
7110
|
if (c.err)
|
|
7116
7111
|
return c;
|
|
7117
7112
|
this.bumpSpace(), k = this.parseIdentifierIfPossible(), X = c.val;
|
|
@@ -7125,7 +7120,7 @@ var Dl = (
|
|
|
7125
7120
|
var L = ne(i, this.clonePosition());
|
|
7126
7121
|
return a === "select" ? {
|
|
7127
7122
|
val: {
|
|
7128
|
-
type:
|
|
7123
|
+
type: ue.select,
|
|
7129
7124
|
value: r,
|
|
7130
7125
|
options: pi(H.val),
|
|
7131
7126
|
location: L
|
|
@@ -7133,7 +7128,7 @@ var Dl = (
|
|
|
7133
7128
|
err: null
|
|
7134
7129
|
} : {
|
|
7135
7130
|
val: {
|
|
7136
|
-
type:
|
|
7131
|
+
type: ue.plural,
|
|
7137
7132
|
value: r,
|
|
7138
7133
|
options: pi(H.val),
|
|
7139
7134
|
offset: X,
|
|
@@ -7144,10 +7139,10 @@ var Dl = (
|
|
|
7144
7139
|
};
|
|
7145
7140
|
}
|
|
7146
7141
|
default:
|
|
7147
|
-
return this.error(
|
|
7142
|
+
return this.error(ee.INVALID_ARGUMENT_TYPE, ne(o, l));
|
|
7148
7143
|
}
|
|
7149
7144
|
}, e.prototype.tryParseArgumentClose = function(t) {
|
|
7150
|
-
return this.isEOF() || this.char() !== 125 ? this.error(
|
|
7145
|
+
return this.isEOF() || this.char() !== 125 ? this.error(ee.EXPECT_ARGUMENT_CLOSING_BRACE, ne(t, this.clonePosition())) : (this.bump(), { val: !0, err: null });
|
|
7151
7146
|
}, e.prototype.parseSimpleArgStyleIfPossible = function() {
|
|
7152
7147
|
for (var t = 0, n = this.clonePosition(); !this.isEOF(); ) {
|
|
7153
7148
|
var r = this.char();
|
|
@@ -7156,7 +7151,7 @@ var Dl = (
|
|
|
7156
7151
|
this.bump();
|
|
7157
7152
|
var i = this.clonePosition();
|
|
7158
7153
|
if (!this.bumpUntil("'"))
|
|
7159
|
-
return this.error(
|
|
7154
|
+
return this.error(ee.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE, ne(i, this.clonePosition()));
|
|
7160
7155
|
this.bump();
|
|
7161
7156
|
break;
|
|
7162
7157
|
}
|
|
@@ -7188,14 +7183,14 @@ var Dl = (
|
|
|
7188
7183
|
try {
|
|
7189
7184
|
r = gl(t);
|
|
7190
7185
|
} catch {
|
|
7191
|
-
return this.error(
|
|
7186
|
+
return this.error(ee.INVALID_NUMBER_SKELETON, n);
|
|
7192
7187
|
}
|
|
7193
7188
|
return {
|
|
7194
7189
|
val: {
|
|
7195
7190
|
type: fn.number,
|
|
7196
7191
|
tokens: r,
|
|
7197
7192
|
location: n,
|
|
7198
|
-
parsedOptions: this.shouldParseSkeletons ?
|
|
7193
|
+
parsedOptions: this.shouldParseSkeletons ? Cl(r) : {}
|
|
7199
7194
|
},
|
|
7200
7195
|
err: null
|
|
7201
7196
|
};
|
|
@@ -7204,7 +7199,7 @@ var Dl = (
|
|
|
7204
7199
|
if (u.length === 0) {
|
|
7205
7200
|
var c = this.clonePosition();
|
|
7206
7201
|
if (n !== "select" && this.bumpIf("=")) {
|
|
7207
|
-
var p = this.tryParseDecimalInteger(
|
|
7202
|
+
var p = this.tryParseDecimalInteger(ee.EXPECT_PLURAL_ARGUMENT_SELECTOR, ee.INVALID_PLURAL_ARGUMENT_SELECTOR);
|
|
7208
7203
|
if (p.err)
|
|
7209
7204
|
return p;
|
|
7210
7205
|
f = ne(c, this.clonePosition()), u = this.message.slice(c.offset, this.offset());
|
|
@@ -7212,11 +7207,11 @@ var Dl = (
|
|
|
7212
7207
|
break;
|
|
7213
7208
|
}
|
|
7214
7209
|
if (l.has(u))
|
|
7215
|
-
return this.error(n === "select" ?
|
|
7210
|
+
return this.error(n === "select" ? ee.DUPLICATE_SELECT_ARGUMENT_SELECTOR : ee.DUPLICATE_PLURAL_ARGUMENT_SELECTOR, f);
|
|
7216
7211
|
u === "other" && (o = !0), this.bumpSpace();
|
|
7217
7212
|
var h = this.clonePosition();
|
|
7218
7213
|
if (!this.bumpIf("{"))
|
|
7219
|
-
return this.error(n === "select" ?
|
|
7214
|
+
return this.error(n === "select" ? ee.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT : ee.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT, ne(this.clonePosition(), this.clonePosition()));
|
|
7220
7215
|
var g = this.parseMessage(t + 1, n, r);
|
|
7221
7216
|
if (g.err)
|
|
7222
7217
|
return g;
|
|
@@ -7231,7 +7226,7 @@ var Dl = (
|
|
|
7231
7226
|
}
|
|
7232
7227
|
]), l.add(u), this.bumpSpace(), s = this.parseIdentifierIfPossible(), u = s.value, f = s.location;
|
|
7233
7228
|
}
|
|
7234
|
-
return a.length === 0 ? this.error(n === "select" ?
|
|
7229
|
+
return a.length === 0 ? this.error(n === "select" ? ee.EXPECT_SELECT_ARGUMENT_SELECTOR : ee.EXPECT_PLURAL_ARGUMENT_SELECTOR, ne(this.clonePosition(), this.clonePosition())) : this.requiresOtherClause && !o ? this.error(ee.MISSING_OTHER_CLAUSE, ne(this.clonePosition(), this.clonePosition())) : { val: a, err: null };
|
|
7235
7230
|
}, e.prototype.tryParseDecimalInteger = function(t, n) {
|
|
7236
7231
|
var r = 1, i = this.clonePosition();
|
|
7237
7232
|
this.bumpIf("+") || this.bumpIf("-") && (r = -1);
|
|
@@ -7336,7 +7331,7 @@ function Gl(e, t) {
|
|
|
7336
7331
|
t === void 0 && (t = {}), t = hr({ shouldParseSkeletons: !0, requiresOtherClause: !0 }, t);
|
|
7337
7332
|
var n = new Dl(e, t).parse();
|
|
7338
7333
|
if (n.err) {
|
|
7339
|
-
var r = SyntaxError(
|
|
7334
|
+
var r = SyntaxError(ee[n.err.kind]);
|
|
7340
7335
|
throw r.location = n.err.location, r.originalMessage = n.err.message, r;
|
|
7341
7336
|
}
|
|
7342
7337
|
return t?.captureLocation || u0(n.val), n.val;
|
|
@@ -7457,10 +7452,10 @@ function tr(e, t, n, r, i, s, o) {
|
|
|
7457
7452
|
continue;
|
|
7458
7453
|
}
|
|
7459
7454
|
if (Js(f)) {
|
|
7460
|
-
var g = f.children, x = f.value,
|
|
7461
|
-
if (!Vl(
|
|
7455
|
+
var g = f.children, x = f.value, y = i[x];
|
|
7456
|
+
if (!Vl(y))
|
|
7462
7457
|
throw new Ul(x, "function", o);
|
|
7463
|
-
var T = tr(g, t, n, r, i, s), U =
|
|
7458
|
+
var T = tr(g, t, n, r, i, s), U = y(T.map(function(X) {
|
|
7464
7459
|
return X.value;
|
|
7465
7460
|
}));
|
|
7466
7461
|
Array.isArray(U) || (U = [U]), a.push.apply(a, U.map(function(X) {
|
|
@@ -7697,7 +7692,7 @@ const Tt = {}, Zl = (e, t, n) => n && (t in Tt || (Tt[t] = {}), e in Tt[t] || (T
|
|
|
7697
7692
|
}
|
|
7698
7693
|
};
|
|
7699
7694
|
let j0;
|
|
7700
|
-
const zn =
|
|
7695
|
+
const zn = Cr({});
|
|
7701
7696
|
function ql(e) {
|
|
7702
7697
|
return j0[e] || null;
|
|
7703
7698
|
}
|
|
@@ -7754,20 +7749,20 @@ function t1(e, t) {
|
|
|
7754
7749
|
t.map((r) => ($l(e, r), r().then((i) => i.default || i)))
|
|
7755
7750
|
).then((r) => u2(e, ...r));
|
|
7756
7751
|
}
|
|
7757
|
-
const
|
|
7752
|
+
const yn = {};
|
|
7758
7753
|
function c2(e) {
|
|
7759
7754
|
if (!dr(e))
|
|
7760
|
-
return e in
|
|
7755
|
+
return e in yn ? yn[e] : Promise.resolve();
|
|
7761
7756
|
const t = e1(e);
|
|
7762
|
-
return
|
|
7757
|
+
return yn[e] = Promise.all(
|
|
7763
7758
|
t.map(
|
|
7764
7759
|
([n, r]) => t1(n, r)
|
|
7765
7760
|
)
|
|
7766
7761
|
).then(() => {
|
|
7767
7762
|
if (dr(e))
|
|
7768
7763
|
return c2(e);
|
|
7769
|
-
delete
|
|
7770
|
-
}),
|
|
7764
|
+
delete yn[e];
|
|
7765
|
+
}), yn[e];
|
|
7771
7766
|
}
|
|
7772
7767
|
var mi = Object.getOwnPropertySymbols, n1 = Object.prototype.hasOwnProperty, r1 = Object.prototype.propertyIsEnumerable, i1 = (e, t) => {
|
|
7773
7768
|
var n = {};
|
|
@@ -7843,23 +7838,23 @@ function l1(e) {
|
|
|
7843
7838
|
'[svelte-i18n] The "warnOnMissingMessages" option is deprecated. Please use the "handleMissingMessage" option instead.'
|
|
7844
7839
|
)), Object.assign(Sn, r, { initialLocale: i }), n && ("number" in n && Object.assign(Sn.formats.number, n.number), "date" in n && Object.assign(Sn.formats.date, n.date), "time" in n && Object.assign(Sn.formats.time, n.time)), Yt.set(i);
|
|
7845
7840
|
}
|
|
7846
|
-
const Ur =
|
|
7847
|
-
var u1 = Object.defineProperty, f1 = Object.defineProperties, c1 = Object.getOwnPropertyDescriptors, bi = Object.getOwnPropertySymbols, h1 = Object.prototype.hasOwnProperty, d1 = Object.prototype.propertyIsEnumerable,
|
|
7841
|
+
const Ur = Cr(!1);
|
|
7842
|
+
var u1 = Object.defineProperty, f1 = Object.defineProperties, c1 = Object.getOwnPropertyDescriptors, bi = Object.getOwnPropertySymbols, h1 = Object.prototype.hasOwnProperty, d1 = Object.prototype.propertyIsEnumerable, yi = (e, t, n) => t in e ? u1(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, p1 = (e, t) => {
|
|
7848
7843
|
for (var n in t || (t = {}))
|
|
7849
|
-
h1.call(t, n) &&
|
|
7844
|
+
h1.call(t, n) && yi(e, n, t[n]);
|
|
7850
7845
|
if (bi)
|
|
7851
7846
|
for (var n of bi(t))
|
|
7852
|
-
d1.call(t, n) &&
|
|
7847
|
+
d1.call(t, n) && yi(e, n, t[n]);
|
|
7853
7848
|
return e;
|
|
7854
7849
|
}, v1 = (e, t) => f1(e, c1(t));
|
|
7855
7850
|
let f0;
|
|
7856
|
-
const pr =
|
|
7857
|
-
function
|
|
7851
|
+
const pr = Cr(null);
|
|
7852
|
+
function Ci(e) {
|
|
7858
7853
|
return e.split("-").map((t, n, r) => r.slice(0, n + 1).join("-")).reverse();
|
|
7859
7854
|
}
|
|
7860
7855
|
function Vn(e, t = hn().fallbackLocale) {
|
|
7861
|
-
const n =
|
|
7862
|
-
return t ? [.../* @__PURE__ */ new Set([...n, ...
|
|
7856
|
+
const n = Ci(e);
|
|
7857
|
+
return t ? [.../* @__PURE__ */ new Set([...n, ...Ci(t)])] : n;
|
|
7863
7858
|
}
|
|
7864
7859
|
function Ot() {
|
|
7865
7860
|
return f0 ?? void 0;
|
|
@@ -7918,14 +7913,14 @@ const Dn = (e, t) => {
|
|
|
7918
7913
|
throw new Error('[svelte-i18n] A "locale" must be set to format numbers');
|
|
7919
7914
|
return r && (i = Dn("number", r)), new Intl.NumberFormat(n, i);
|
|
7920
7915
|
}
|
|
7921
|
-
),
|
|
7916
|
+
), y1 = Lr(
|
|
7922
7917
|
(e) => {
|
|
7923
7918
|
var t = e, { locale: n, format: r } = t, i = vn(t, ["locale", "format"]);
|
|
7924
7919
|
if (n == null)
|
|
7925
7920
|
throw new Error('[svelte-i18n] A "locale" must be set to format dates');
|
|
7926
7921
|
return r ? i = Dn("date", r) : Object.keys(i).length === 0 && (i = Dn("date", "short")), new Intl.DateTimeFormat(n, i);
|
|
7927
7922
|
}
|
|
7928
|
-
),
|
|
7923
|
+
), C1 = Lr(
|
|
7929
7924
|
(e) => {
|
|
7930
7925
|
var t = e, { locale: n, format: r } = t, i = vn(t, ["locale", "format"]);
|
|
7931
7926
|
if (n == null)
|
|
@@ -7947,14 +7942,14 @@ const Dn = (e, t) => {
|
|
|
7947
7942
|
} = t, r = vn(t, [
|
|
7948
7943
|
"locale"
|
|
7949
7944
|
]);
|
|
7950
|
-
return
|
|
7945
|
+
return y1(z0({ locale: n }, r));
|
|
7951
7946
|
}, x1 = (e = {}) => {
|
|
7952
7947
|
var t = e, {
|
|
7953
7948
|
locale: n = Ot()
|
|
7954
7949
|
} = t, r = vn(t, [
|
|
7955
7950
|
"locale"
|
|
7956
7951
|
]);
|
|
7957
|
-
return
|
|
7952
|
+
return C1(z0({ locale: n }, r));
|
|
7958
7953
|
}, S1 = Lr(
|
|
7959
7954
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
7960
7955
|
(e, t = Ot()) => new o2(e, t, hn().formats, {
|
|
@@ -8455,9 +8450,9 @@ const _1 = (e, t) => {
|
|
|
8455
8450
|
}, g = (d) => {
|
|
8456
8451
|
oe(n, d(_(n)), !0), oe(r, d(_(r)), !0), oe(i, d(_(i)), !0);
|
|
8457
8452
|
}, x = (d, m) => {
|
|
8458
|
-
g((b) => b.map((
|
|
8459
|
-
},
|
|
8460
|
-
g((b) => b.map((
|
|
8453
|
+
g((b) => b.map((C) => C.Id === d ? qn(C, { ...C, ...m }) : C));
|
|
8454
|
+
}, y = (d, m) => {
|
|
8455
|
+
g((b) => b.map((C) => C.ChallengeId === d ? { ...C, ...m } : C));
|
|
8461
8456
|
}, T = (d) => {
|
|
8462
8457
|
if (d)
|
|
8463
8458
|
return [
|
|
@@ -8469,51 +8464,51 @@ const _1 = (e, t) => {
|
|
|
8469
8464
|
g((m) => m.filter((b) => b.Id !== d));
|
|
8470
8465
|
}, F = async (d, m, b) => {
|
|
8471
8466
|
const {
|
|
8472
|
-
endpoint:
|
|
8467
|
+
endpoint: C,
|
|
8473
8468
|
domainId: N,
|
|
8474
|
-
userSession:
|
|
8475
|
-
userId:
|
|
8469
|
+
userSession: q,
|
|
8470
|
+
userId: $,
|
|
8476
8471
|
locale: ie,
|
|
8477
8472
|
pageSize: pe = Ar
|
|
8478
8473
|
} = e();
|
|
8479
|
-
if (!
|
|
8474
|
+
if (!C)
|
|
8480
8475
|
throw new Error("challenges: endpoint is missing. Please provide a valid endpoint URL.");
|
|
8481
8476
|
const He = {
|
|
8482
|
-
endpoint:
|
|
8477
|
+
endpoint: C,
|
|
8483
8478
|
domainId: N,
|
|
8484
|
-
sessionId:
|
|
8479
|
+
sessionId: q,
|
|
8485
8480
|
locale: ie,
|
|
8486
8481
|
pageNumber: b,
|
|
8487
8482
|
pageSize: pe
|
|
8488
8483
|
};
|
|
8489
|
-
if (m) return Fr({ endpoint:
|
|
8484
|
+
if (m) return Fr({ endpoint: C, domainId: N, locale: ie, pageNumber: b, pageSize: pe });
|
|
8490
8485
|
switch (d) {
|
|
8491
8486
|
case "promo":
|
|
8492
8487
|
return ma(He);
|
|
8493
8488
|
case "pending":
|
|
8494
8489
|
return Fr({ ...He, isFutureAvailable: !0 });
|
|
8495
8490
|
case "history":
|
|
8496
|
-
return ba({ ...He, userId:
|
|
8491
|
+
return ba({ ...He, userId: $ ?? "", isFutureAvailable: !0 });
|
|
8497
8492
|
default:
|
|
8498
8493
|
return Fr({ ...He, isFutureAvailable: !1 });
|
|
8499
8494
|
}
|
|
8500
8495
|
}, k = (d, m, b) => {
|
|
8501
|
-
const
|
|
8502
|
-
if (
|
|
8496
|
+
const C = u[d];
|
|
8497
|
+
if (C.pageNumber = m.PageNumber ?? Lt, !k1(d)) {
|
|
8503
8498
|
const ie = m.Data ?? [];
|
|
8504
|
-
oe(s, b ? [..._(s), ...ie] : ie, !0),
|
|
8499
|
+
oe(s, b ? [..._(s), ...ie] : ie, !0), C.totalCount = m.TotalItem ?? _(s).length, C.hasMore = !(b && !ie.length) && _(s).length < C.totalCount;
|
|
8505
8500
|
return;
|
|
8506
8501
|
}
|
|
8507
|
-
const N = m.Data ?? [],
|
|
8508
|
-
h(d,
|
|
8509
|
-
}, X = async (d, m, { append: b = !1, page:
|
|
8502
|
+
const N = m.Data ?? [], q = d === "promo" ? N.filter((ie) => !_(a).includes(ie.ChallengeId)) : N, $ = b ? [...p(d), ...q] : q;
|
|
8503
|
+
h(d, $), C.totalCount = m.TotalCount ?? $.length, C.hasMore = !(b && !q.length) && $.length < C.totalCount;
|
|
8504
|
+
}, X = async (d, m, { append: b = !1, page: C } = {}) => {
|
|
8510
8505
|
const N = u[d];
|
|
8511
8506
|
N.loading = !0, N.error = void 0;
|
|
8512
8507
|
try {
|
|
8513
|
-
const
|
|
8514
|
-
k(d,
|
|
8515
|
-
} catch (
|
|
8516
|
-
N.error =
|
|
8508
|
+
const q = C ?? (b ? N.pageNumber + 1 : Lt), $ = await F(d, m, q);
|
|
8509
|
+
k(d, $, b);
|
|
8510
|
+
} catch (q) {
|
|
8511
|
+
N.error = q, b && (N.hasMore = !1), e().onError?.(q);
|
|
8517
8512
|
} finally {
|
|
8518
8513
|
N.loading = !1;
|
|
8519
8514
|
}
|
|
@@ -8525,14 +8520,14 @@ const _1 = (e, t) => {
|
|
|
8525
8520
|
const b = u[d];
|
|
8526
8521
|
return b.hasMore && !b.loading ? X(d, m, { append: !0 }) : Promise.resolve();
|
|
8527
8522
|
}, A = (d, m, b) => u[d].loading ? Promise.resolve() : X(d, m, { page: b }), j = async (d, m) => {
|
|
8528
|
-
const b = u[d],
|
|
8529
|
-
if (
|
|
8523
|
+
const b = u[d], C = b.pageNumber;
|
|
8524
|
+
if (C <= Lt)
|
|
8530
8525
|
return X(d, m);
|
|
8531
8526
|
b.loading = !0, b.error = void 0;
|
|
8532
8527
|
try {
|
|
8533
|
-
for (let N = Lt; N <=
|
|
8534
|
-
const
|
|
8535
|
-
k(d,
|
|
8528
|
+
for (let N = Lt; N <= C; N += 1) {
|
|
8529
|
+
const q = await F(d, m, N);
|
|
8530
|
+
k(d, q, N > Lt);
|
|
8536
8531
|
}
|
|
8537
8532
|
} catch (N) {
|
|
8538
8533
|
b.error = N, e().onError?.(N);
|
|
@@ -8541,21 +8536,21 @@ const _1 = (e, t) => {
|
|
|
8541
8536
|
}
|
|
8542
8537
|
}, D = (d) => {
|
|
8543
8538
|
_(a).includes(d) || oe(a, [..._(a), d], !0);
|
|
8544
|
-
const m = _(n).filter((
|
|
8539
|
+
const m = _(n).filter((C) => C.ChallengeId !== d), b = _(n).length - m.length;
|
|
8545
8540
|
b && (u.promo.totalCount = Math.max(0, u.promo.totalCount - b), oe(n, m, !0));
|
|
8546
8541
|
}, P = (d, m) => {
|
|
8547
8542
|
const b = _(o).includes(d);
|
|
8548
|
-
m && !b ? oe(o, [..._(o), d], !0) : !m && b && oe(o, _(o).filter((
|
|
8543
|
+
m && !b ? oe(o, [..._(o), d], !0) : !m && b && oe(o, _(o).filter((C) => C !== d), !0);
|
|
8549
8544
|
}, Y = (d, m) => {
|
|
8550
8545
|
const b = p(d);
|
|
8551
|
-
if (b.some((
|
|
8552
|
-
h(d, b.map((
|
|
8546
|
+
if (b.some((C) => C.Id === m.Id)) {
|
|
8547
|
+
h(d, b.map((C) => C.Id === m.Id ? m : C));
|
|
8553
8548
|
return;
|
|
8554
8549
|
}
|
|
8555
8550
|
h(d, [m, ...b]), u[d].totalCount += 1;
|
|
8556
|
-
},
|
|
8551
|
+
}, fe = (d, m) => {
|
|
8557
8552
|
const b = p(d);
|
|
8558
|
-
b.some((
|
|
8553
|
+
b.some((C) => C.Id === m) && (h(d, b.filter((C) => C.Id !== m)), u[d].totalCount = Math.max(0, u[d].totalCount - 1));
|
|
8559
8554
|
}, M = (d) => {
|
|
8560
8555
|
const m = [
|
|
8561
8556
|
..._(r),
|
|
@@ -8564,10 +8559,10 @@ const _1 = (e, t) => {
|
|
|
8564
8559
|
].find((N) => N.Id === d.Id);
|
|
8565
8560
|
if (!m && d.Status !== G.Started && d.Status !== G.Awaiting)
|
|
8566
8561
|
return;
|
|
8567
|
-
const b = qn(m, { ...m, ...d }),
|
|
8568
|
-
oe(n, _(n).map((N) => N.Id === b.Id ? b : N), !0),
|
|
8562
|
+
const b = qn(m, { ...m, ...d }), C = ai(b);
|
|
8563
|
+
oe(n, _(n).map((N) => N.Id === b.Id ? b : N), !0), fe(C ? "active" : "pending", b.Id), Y(C ? "pending" : "active", b);
|
|
8569
8564
|
}, S = (d, m) => {
|
|
8570
|
-
P(d, !m),
|
|
8565
|
+
P(d, !m), y(d, {
|
|
8571
8566
|
ChallengeStatus: m ? t0.Enabled : t0.Paused
|
|
8572
8567
|
});
|
|
8573
8568
|
};
|
|
@@ -8601,11 +8596,11 @@ const _1 = (e, t) => {
|
|
|
8601
8596
|
loadPage: A,
|
|
8602
8597
|
setPaused: P,
|
|
8603
8598
|
patchProgress: x,
|
|
8604
|
-
patchChallenge:
|
|
8599
|
+
patchChallenge: y,
|
|
8605
8600
|
removeProgress: U,
|
|
8606
8601
|
connect: () => {
|
|
8607
|
-
const { endpoint: d, userId: m, userSession: b, liveUpdates:
|
|
8608
|
-
if (!
|
|
8602
|
+
const { endpoint: d, userId: m, userSession: b, liveUpdates: C = !0 } = e();
|
|
8603
|
+
if (!C || c)
|
|
8609
8604
|
return;
|
|
8610
8605
|
const N = Ea({
|
|
8611
8606
|
endpoint: d,
|
|
@@ -8614,23 +8609,23 @@ const _1 = (e, t) => {
|
|
|
8614
8609
|
onNewProgress: M,
|
|
8615
8610
|
onSessionExpired: () => N.close(),
|
|
8616
8611
|
onChallengeEnabledChange: S,
|
|
8617
|
-
onProgressForfeited: (
|
|
8618
|
-
x(
|
|
8612
|
+
onProgressForfeited: ($) => {
|
|
8613
|
+
x($, { Status: G.Forfeited });
|
|
8619
8614
|
}
|
|
8620
|
-
}),
|
|
8621
|
-
onProgressUpdate: (
|
|
8622
|
-
g((ie) => ie.map((pe) => pe.Id ===
|
|
8615
|
+
}), q = xa({
|
|
8616
|
+
onProgressUpdate: ($) => {
|
|
8617
|
+
g((ie) => ie.map((pe) => pe.Id === $.ProgressId ? qn(pe, Aa(pe, $)) : pe));
|
|
8623
8618
|
},
|
|
8624
|
-
onProgressStatusChange: (
|
|
8619
|
+
onProgressStatusChange: ($, ie) => x($, { Status: ie }),
|
|
8625
8620
|
onNewProgress: M,
|
|
8626
|
-
onChallengeForfeited: (
|
|
8627
|
-
g((ie) => ie.map((pe) => pe.ChallengeId ===
|
|
8621
|
+
onChallengeForfeited: ($) => {
|
|
8622
|
+
g((ie) => ie.map((pe) => pe.ChallengeId === $ ? qn(pe, { ...pe, Status: G.Forfeited }) : pe));
|
|
8628
8623
|
},
|
|
8629
8624
|
onChallengeEnabledChange: S
|
|
8630
8625
|
});
|
|
8631
8626
|
c = {
|
|
8632
8627
|
close: () => {
|
|
8633
|
-
N.close(),
|
|
8628
|
+
N.close(), q.close();
|
|
8634
8629
|
}
|
|
8635
8630
|
};
|
|
8636
8631
|
},
|
|
@@ -8647,7 +8642,7 @@ const _1 = (e, t) => {
|
|
|
8647
8642
|
const { endpoint: l, domainId: u, userSession: f, userId: c, onStatusChange: p } = e();
|
|
8648
8643
|
oe(t, !0);
|
|
8649
8644
|
try {
|
|
8650
|
-
await
|
|
8645
|
+
await ya({
|
|
8651
8646
|
endpoint: l,
|
|
8652
8647
|
domainId: u,
|
|
8653
8648
|
sessionId: f,
|
|
@@ -8664,7 +8659,7 @@ const _1 = (e, t) => {
|
|
|
8664
8659
|
const { endpoint: o, domainId: a, userSession: l, onClaimed: u } = e();
|
|
8665
8660
|
oe(t, !0);
|
|
8666
8661
|
try {
|
|
8667
|
-
await
|
|
8662
|
+
await Ca({
|
|
8668
8663
|
endpoint: o,
|
|
8669
8664
|
domainId: a,
|
|
8670
8665
|
sessionId: l,
|
|
@@ -8791,7 +8786,7 @@ function Q1(e, t) {
|
|
|
8791
8786
|
}, c = Y1();
|
|
8792
8787
|
Is(c, 21, () => _(u), (h) => h.id, (h, g) => {
|
|
8793
8788
|
var x = X1();
|
|
8794
|
-
let
|
|
8789
|
+
let y;
|
|
8795
8790
|
var T = is(x), U = vo(T);
|
|
8796
8791
|
{
|
|
8797
8792
|
var F = (X) => {
|
|
@@ -8803,7 +8798,7 @@ function Q1(e, t) {
|
|
|
8803
8798
|
});
|
|
8804
8799
|
}
|
|
8805
8800
|
ar(x), fs(() => {
|
|
8806
|
-
|
|
8801
|
+
y = Os(x, 1, "player-challenges__tab svelte-1jf237k", null, y, { active: s() === _(g).id }), $r(x, "aria-selected", s() === _(g).id), Ls(T, `${_(g).label ?? ""} `);
|
|
8807
8802
|
}), xs("click", x, () => o()?.(_(g).id)), tn(h, x);
|
|
8808
8803
|
}), ar(c), tn(e, c);
|
|
8809
8804
|
var p = b0(f);
|
|
@@ -8857,10 +8852,10 @@ function K1(e, t) {
|
|
|
8857
8852
|
}, c = q1();
|
|
8858
8853
|
Is(c, 21, () => _(u), Go, (h, g) => {
|
|
8859
8854
|
var x = Z1();
|
|
8860
|
-
let
|
|
8855
|
+
let y;
|
|
8861
8856
|
var T = po(x, !0);
|
|
8862
8857
|
fs(() => {
|
|
8863
|
-
|
|
8858
|
+
y = Os(x, 1, "challenge-details__tab svelte-1l7spkm", null, y, { active: o() === _(g).id }), Ls(T, _(g).label);
|
|
8864
8859
|
}), xs("click", x, () => a()?.(_(g).id)), tn(h, x);
|
|
8865
8860
|
}), ar(c), tn(e, c);
|
|
8866
8861
|
var p = b0(f);
|
|
@@ -8913,7 +8908,7 @@ export {
|
|
|
8913
8908
|
Zu as aB,
|
|
8914
8909
|
Aa as aC,
|
|
8915
8910
|
K1 as aD,
|
|
8916
|
-
|
|
8911
|
+
yu as aE,
|
|
8917
8912
|
uu as aF,
|
|
8918
8913
|
hu as aG,
|
|
8919
8914
|
du as aH,
|
|
@@ -8931,7 +8926,7 @@ export {
|
|
|
8931
8926
|
Lt as aT,
|
|
8932
8927
|
of as aU,
|
|
8933
8928
|
rf as aV,
|
|
8934
|
-
|
|
8929
|
+
Cu as aW,
|
|
8935
8930
|
ef as aX,
|
|
8936
8931
|
Q1 as aY,
|
|
8937
8932
|
gu as aZ,
|