@pie-players/pie-section-player-tools-session-debugger 0.1.1 → 0.1.3
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.
|
@@ -1,144 +1,144 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var xs = Object.defineProperty;
|
|
2
|
+
var Gn = (e) => {
|
|
3
3
|
throw TypeError(e);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var l = (e, t, n) => (
|
|
8
|
-
var
|
|
9
|
-
typeof window < "u" && ((
|
|
10
|
-
const
|
|
11
|
-
var
|
|
12
|
-
const
|
|
5
|
+
var ks = (e, t, n) => t in e ? xs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
6
|
+
var A = (e, t, n) => ks(e, typeof t != "symbol" ? t + "" : t, n), cn = (e, t, n) => t.has(e) || Gn("Cannot " + n);
|
|
7
|
+
var l = (e, t, n) => (cn(e, t, "read from private field"), n ? n.call(e) : t.get(e)), w = (e, t, n) => t.has(e) ? Gn("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), p = (e, t, n, r) => (cn(e, t, "write to private field"), r ? r.call(e, n) : t.set(e, n), n), j = (e, t, n) => (cn(e, t, "access private method"), n);
|
|
8
|
+
var ur;
|
|
9
|
+
typeof window < "u" && ((ur = window.__svelte ?? (window.__svelte = {})).v ?? (ur.v = /* @__PURE__ */ new Set())).add("5");
|
|
10
|
+
const Is = 2, Mn = "[", Tn = "[!", ar = "]", ut = {}, O = /* @__PURE__ */ Symbol(), fr = "http://www.w3.org/1999/xhtml", _n = !1;
|
|
11
|
+
var cr = Array.isArray, As = Array.prototype.indexOf, at = Array.prototype.includes, Ms = Array.from, Vt = Object.keys, Yt = Object.defineProperty, Qe = Object.getOwnPropertyDescriptor, Ts = Object.getOwnPropertyDescriptors, Cs = Object.prototype, Rs = Array.prototype, dr = Object.getPrototypeOf, Zn = Object.isExtensible;
|
|
12
|
+
const Ns = () => {
|
|
13
13
|
};
|
|
14
|
-
function
|
|
14
|
+
function Os(e) {
|
|
15
15
|
for (var t = 0; t < e.length; t++)
|
|
16
16
|
e[t]();
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function hr() {
|
|
19
19
|
var e, t, n = new Promise((r, s) => {
|
|
20
20
|
e = r, t = s;
|
|
21
21
|
});
|
|
22
22
|
return { promise: n, resolve: e, reject: t };
|
|
23
23
|
}
|
|
24
|
-
const
|
|
24
|
+
const L = 2, Bt = 4, Xt = 8, vr = 1 << 24, Se = 16, he = 32, Oe = 64, pn = 128, K = 512, C = 1024, P = 2048, re = 4096, ae = 8192, $e = 16384, _t = 32768, ft = 65536, Qn = 1 << 17, _r = 1 << 18, Je = 1 << 19, Ds = 1 << 20, Ue = 65536, gn = 1 << 21, Cn = 1 << 22, Ce = 1 << 23, dn = /* @__PURE__ */ Symbol("$state"), Ls = /* @__PURE__ */ Symbol("legacy props"), Pe = new class extends Error {
|
|
25
25
|
constructor() {
|
|
26
26
|
super(...arguments);
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
A(this, "name", "StaleReactionError");
|
|
28
|
+
A(this, "message", "The reaction that called `getAbortSignal()` was re-run or destroyed");
|
|
29
29
|
}
|
|
30
|
-
}(),
|
|
31
|
-
function
|
|
30
|
+
}(), Rn = 3, Jt = 8;
|
|
31
|
+
function pr(e) {
|
|
32
32
|
throw new Error("https://svelte.dev/e/lifecycle_outside_component");
|
|
33
33
|
}
|
|
34
|
-
function
|
|
34
|
+
function Ps() {
|
|
35
35
|
throw new Error("https://svelte.dev/e/async_derived_orphan");
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function Fs(e) {
|
|
38
38
|
throw new Error("https://svelte.dev/e/effect_in_teardown");
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function js() {
|
|
41
41
|
throw new Error("https://svelte.dev/e/effect_in_unowned_derived");
|
|
42
42
|
}
|
|
43
|
-
function
|
|
43
|
+
function Hs(e) {
|
|
44
44
|
throw new Error("https://svelte.dev/e/effect_orphan");
|
|
45
45
|
}
|
|
46
|
-
function
|
|
46
|
+
function zs() {
|
|
47
47
|
throw new Error("https://svelte.dev/e/effect_update_depth_exceeded");
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function Vs() {
|
|
50
50
|
throw new Error("https://svelte.dev/e/hydration_failed");
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function Ys() {
|
|
53
53
|
throw new Error("https://svelte.dev/e/state_descriptors_fixed");
|
|
54
54
|
}
|
|
55
|
-
function
|
|
55
|
+
function Bs() {
|
|
56
56
|
throw new Error("https://svelte.dev/e/state_prototype_fixed");
|
|
57
57
|
}
|
|
58
|
-
function
|
|
58
|
+
function Ws() {
|
|
59
59
|
throw new Error("https://svelte.dev/e/state_unsafe_mutation");
|
|
60
60
|
}
|
|
61
|
-
function
|
|
61
|
+
function qs() {
|
|
62
62
|
throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror");
|
|
63
63
|
}
|
|
64
|
-
function
|
|
64
|
+
function Kt(e) {
|
|
65
65
|
console.warn("https://svelte.dev/e/hydration_mismatch");
|
|
66
66
|
}
|
|
67
|
-
function
|
|
67
|
+
function Us() {
|
|
68
68
|
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
69
69
|
}
|
|
70
|
-
let
|
|
71
|
-
function
|
|
72
|
-
|
|
70
|
+
let I = !1;
|
|
71
|
+
function Ge(e) {
|
|
72
|
+
I = e;
|
|
73
73
|
}
|
|
74
|
-
let
|
|
75
|
-
function
|
|
74
|
+
let k;
|
|
75
|
+
function fe(e) {
|
|
76
76
|
if (e === null)
|
|
77
|
-
throw
|
|
78
|
-
return
|
|
77
|
+
throw Kt(), ut;
|
|
78
|
+
return k = e;
|
|
79
79
|
}
|
|
80
|
-
function
|
|
81
|
-
return
|
|
80
|
+
function Nn() {
|
|
81
|
+
return fe(/* @__PURE__ */ De(k));
|
|
82
82
|
}
|
|
83
|
-
function
|
|
84
|
-
if (
|
|
85
|
-
if (/* @__PURE__ */
|
|
86
|
-
throw
|
|
87
|
-
|
|
83
|
+
function Ie(e) {
|
|
84
|
+
if (I) {
|
|
85
|
+
if (/* @__PURE__ */ De(k) !== null)
|
|
86
|
+
throw Kt(), ut;
|
|
87
|
+
k = e;
|
|
88
88
|
}
|
|
89
89
|
}
|
|
90
|
-
function
|
|
91
|
-
if (
|
|
92
|
-
for (var t = e, n =
|
|
90
|
+
function Xs(e = 1) {
|
|
91
|
+
if (I) {
|
|
92
|
+
for (var t = e, n = k; t--; )
|
|
93
93
|
n = /** @type {TemplateNode} */
|
|
94
|
-
/* @__PURE__ */
|
|
95
|
-
|
|
94
|
+
/* @__PURE__ */ De(n);
|
|
95
|
+
k = n;
|
|
96
96
|
}
|
|
97
97
|
}
|
|
98
|
-
function
|
|
99
|
-
for (var t = 0, n =
|
|
100
|
-
if (n.nodeType ===
|
|
98
|
+
function gr(e = !0) {
|
|
99
|
+
for (var t = 0, n = k; ; ) {
|
|
100
|
+
if (n.nodeType === Jt) {
|
|
101
101
|
var r = (
|
|
102
102
|
/** @type {Comment} */
|
|
103
103
|
n.data
|
|
104
104
|
);
|
|
105
|
-
if (r ===
|
|
105
|
+
if (r === ar) {
|
|
106
106
|
if (t === 0) return n;
|
|
107
107
|
t -= 1;
|
|
108
|
-
} else (r ===
|
|
108
|
+
} else (r === Mn || r === Tn || // "[1", "[2", etc. for if blocks
|
|
109
109
|
r[0] === "[" && !isNaN(Number(r.slice(1)))) && (t += 1);
|
|
110
110
|
}
|
|
111
111
|
var s = (
|
|
112
112
|
/** @type {TemplateNode} */
|
|
113
|
-
/* @__PURE__ */
|
|
113
|
+
/* @__PURE__ */ De(n)
|
|
114
114
|
);
|
|
115
115
|
e && n.remove(), n = s;
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
|
-
function
|
|
119
|
-
if (!e || e.nodeType !==
|
|
120
|
-
throw
|
|
118
|
+
function Js(e) {
|
|
119
|
+
if (!e || e.nodeType !== Jt)
|
|
120
|
+
throw Kt(), ut;
|
|
121
121
|
return (
|
|
122
122
|
/** @type {Comment} */
|
|
123
123
|
e.data
|
|
124
124
|
);
|
|
125
125
|
}
|
|
126
|
-
function
|
|
126
|
+
function mr(e) {
|
|
127
127
|
return e === this.v;
|
|
128
128
|
}
|
|
129
|
-
function
|
|
129
|
+
function Ks(e, t) {
|
|
130
130
|
return e != e ? t == t : e !== t || e !== null && typeof e == "object" || typeof e == "function";
|
|
131
131
|
}
|
|
132
|
-
function
|
|
133
|
-
return !
|
|
132
|
+
function Gs(e) {
|
|
133
|
+
return !Ks(e, this.v);
|
|
134
134
|
}
|
|
135
|
-
let
|
|
136
|
-
function
|
|
137
|
-
|
|
135
|
+
let Zs = !1, Y = null;
|
|
136
|
+
function ct(e) {
|
|
137
|
+
Y = e;
|
|
138
138
|
}
|
|
139
|
-
function
|
|
140
|
-
|
|
141
|
-
p:
|
|
139
|
+
function wr(e, t = !1, n) {
|
|
140
|
+
Y = {
|
|
141
|
+
p: Y,
|
|
142
142
|
i: !1,
|
|
143
143
|
c: null,
|
|
144
144
|
e: null,
|
|
@@ -147,52 +147,52 @@ function ur(e, t = !1, n) {
|
|
|
147
147
|
l: null
|
|
148
148
|
};
|
|
149
149
|
}
|
|
150
|
-
function
|
|
150
|
+
function br(e) {
|
|
151
151
|
var t = (
|
|
152
152
|
/** @type {ComponentContext} */
|
|
153
|
-
|
|
153
|
+
Y
|
|
154
154
|
), n = t.e;
|
|
155
155
|
if (n !== null) {
|
|
156
156
|
t.e = null;
|
|
157
157
|
for (var r of n)
|
|
158
|
-
|
|
158
|
+
Yr(r);
|
|
159
159
|
}
|
|
160
|
-
return e !== void 0 && (t.x = e), t.i = !0,
|
|
160
|
+
return e !== void 0 && (t.x = e), t.i = !0, Y = t.p, e ?? /** @type {T} */
|
|
161
161
|
{};
|
|
162
162
|
}
|
|
163
|
-
function
|
|
163
|
+
function yr() {
|
|
164
164
|
return !0;
|
|
165
165
|
}
|
|
166
|
-
let
|
|
167
|
-
function
|
|
168
|
-
var e =
|
|
169
|
-
|
|
166
|
+
let Fe = [];
|
|
167
|
+
function $r() {
|
|
168
|
+
var e = Fe;
|
|
169
|
+
Fe = [], Os(e);
|
|
170
170
|
}
|
|
171
|
-
function
|
|
172
|
-
if (
|
|
173
|
-
var t =
|
|
171
|
+
function et(e) {
|
|
172
|
+
if (Fe.length === 0 && !mt) {
|
|
173
|
+
var t = Fe;
|
|
174
174
|
queueMicrotask(() => {
|
|
175
|
-
t ===
|
|
175
|
+
t === Fe && $r();
|
|
176
176
|
});
|
|
177
177
|
}
|
|
178
|
-
|
|
178
|
+
Fe.push(e);
|
|
179
179
|
}
|
|
180
|
-
function
|
|
181
|
-
for (;
|
|
182
|
-
|
|
180
|
+
function Qs() {
|
|
181
|
+
for (; Fe.length > 0; )
|
|
182
|
+
$r();
|
|
183
183
|
}
|
|
184
|
-
function
|
|
185
|
-
var t =
|
|
184
|
+
function Er(e) {
|
|
185
|
+
var t = y;
|
|
186
186
|
if (t === null)
|
|
187
|
-
return b.f |=
|
|
188
|
-
if ((t.f &
|
|
187
|
+
return b.f |= Ce, e;
|
|
188
|
+
if ((t.f & _t) === 0 && (t.f & Bt) === 0)
|
|
189
189
|
throw e;
|
|
190
|
-
|
|
190
|
+
dt(e, t);
|
|
191
191
|
}
|
|
192
|
-
function
|
|
192
|
+
function dt(e, t) {
|
|
193
193
|
for (; t !== null; ) {
|
|
194
|
-
if ((t.f &
|
|
195
|
-
if ((t.f &
|
|
194
|
+
if ((t.f & pn) !== 0) {
|
|
195
|
+
if ((t.f & _t) === 0)
|
|
196
196
|
throw e;
|
|
197
197
|
try {
|
|
198
198
|
t.b.error(e);
|
|
@@ -205,78 +205,78 @@ function at(e, t) {
|
|
|
205
205
|
}
|
|
206
206
|
throw e;
|
|
207
207
|
}
|
|
208
|
-
const
|
|
208
|
+
const ei = -7169;
|
|
209
209
|
function M(e, t) {
|
|
210
|
-
e.f = e.f &
|
|
210
|
+
e.f = e.f & ei | t;
|
|
211
211
|
}
|
|
212
|
-
function
|
|
213
|
-
(e.f &
|
|
212
|
+
function On(e) {
|
|
213
|
+
(e.f & K) !== 0 || e.deps === null ? M(e, C) : M(e, re);
|
|
214
214
|
}
|
|
215
|
-
function
|
|
215
|
+
function Sr(e) {
|
|
216
216
|
if (e !== null)
|
|
217
217
|
for (const t of e)
|
|
218
|
-
(t.f &
|
|
218
|
+
(t.f & L) === 0 || (t.f & Ue) === 0 || (t.f ^= Ue, Sr(
|
|
219
219
|
/** @type {Derived} */
|
|
220
220
|
t.deps
|
|
221
221
|
));
|
|
222
222
|
}
|
|
223
|
-
function
|
|
224
|
-
(e.f &
|
|
223
|
+
function xr(e, t, n) {
|
|
224
|
+
(e.f & P) !== 0 ? t.add(e) : (e.f & re) !== 0 && n.add(e), Sr(e.deps), M(e, C);
|
|
225
225
|
}
|
|
226
|
-
const
|
|
227
|
-
let x = null,
|
|
228
|
-
var
|
|
229
|
-
const
|
|
226
|
+
const Ot = /* @__PURE__ */ new Set();
|
|
227
|
+
let x = null, ee = null, H = [], Gt = null, mn = !1, mt = !1;
|
|
228
|
+
var tt, nt, ze, rt, Et, St, Ve, ge, st, de, wn, bn, kr;
|
|
229
|
+
const jn = class jn {
|
|
230
230
|
constructor() {
|
|
231
|
-
|
|
232
|
-
|
|
231
|
+
w(this, de);
|
|
232
|
+
A(this, "committed", !1);
|
|
233
233
|
/**
|
|
234
234
|
* The current values of any sources that are updated in this batch
|
|
235
235
|
* They keys of this map are identical to `this.#previous`
|
|
236
236
|
* @type {Map<Source, any>}
|
|
237
237
|
*/
|
|
238
|
-
|
|
238
|
+
A(this, "current", /* @__PURE__ */ new Map());
|
|
239
239
|
/**
|
|
240
240
|
* The values of any sources that are updated in this batch _before_ those updates took place.
|
|
241
241
|
* They keys of this map are identical to `this.#current`
|
|
242
242
|
* @type {Map<Source, any>}
|
|
243
243
|
*/
|
|
244
|
-
|
|
244
|
+
A(this, "previous", /* @__PURE__ */ new Map());
|
|
245
245
|
/**
|
|
246
246
|
* When the batch is committed (and the DOM is updated), we need to remove old branches
|
|
247
247
|
* and append new ones by calling the functions added inside (if/each/key/etc) blocks
|
|
248
248
|
* @type {Set<() => void>}
|
|
249
249
|
*/
|
|
250
|
-
|
|
250
|
+
w(this, tt, /* @__PURE__ */ new Set());
|
|
251
251
|
/**
|
|
252
252
|
* If a fork is discarded, we need to destroy any effects that are no longer needed
|
|
253
253
|
* @type {Set<(batch: Batch) => void>}
|
|
254
254
|
*/
|
|
255
|
-
|
|
255
|
+
w(this, nt, /* @__PURE__ */ new Set());
|
|
256
256
|
/**
|
|
257
257
|
* The number of async effects that are currently in flight
|
|
258
258
|
*/
|
|
259
|
-
|
|
259
|
+
w(this, ze, 0);
|
|
260
260
|
/**
|
|
261
261
|
* The number of async effects that are currently in flight, _not_ inside a pending boundary
|
|
262
262
|
*/
|
|
263
|
-
|
|
263
|
+
w(this, rt, 0);
|
|
264
264
|
/**
|
|
265
265
|
* A deferred that resolves when the batch is committed, used with `settled()`
|
|
266
266
|
* TODO replace with Promise.withResolvers once supported widely enough
|
|
267
267
|
* @type {{ promise: Promise<void>, resolve: (value?: any) => void, reject: (reason: unknown) => void } | null}
|
|
268
268
|
*/
|
|
269
|
-
|
|
269
|
+
w(this, Et, null);
|
|
270
270
|
/**
|
|
271
271
|
* Deferred effects (which run after async work has completed) that are DIRTY
|
|
272
272
|
* @type {Set<Effect>}
|
|
273
273
|
*/
|
|
274
|
-
|
|
274
|
+
w(this, St, /* @__PURE__ */ new Set());
|
|
275
275
|
/**
|
|
276
276
|
* Deferred effects that are MAYBE_DIRTY
|
|
277
277
|
* @type {Set<Effect>}
|
|
278
278
|
*/
|
|
279
|
-
|
|
279
|
+
w(this, Ve, /* @__PURE__ */ new Set());
|
|
280
280
|
/**
|
|
281
281
|
* A map of branches that still exist, but will be destroyed when this batch
|
|
282
282
|
* is committed — we skip over these during `process`.
|
|
@@ -284,19 +284,19 @@ const An = class An {
|
|
|
284
284
|
* so they can be rescheduled if the branch survives.
|
|
285
285
|
* @type {Map<Effect, { d: Effect[], m: Effect[] }>}
|
|
286
286
|
*/
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
287
|
+
w(this, ge, /* @__PURE__ */ new Map());
|
|
288
|
+
A(this, "is_fork", !1);
|
|
289
|
+
w(this, st, !1);
|
|
290
290
|
}
|
|
291
291
|
is_deferred() {
|
|
292
|
-
return this.is_fork || l(this,
|
|
292
|
+
return this.is_fork || l(this, rt) > 0;
|
|
293
293
|
}
|
|
294
294
|
/**
|
|
295
295
|
* Add an effect to the #skipped_branches map and reset its children
|
|
296
296
|
* @param {Effect} effect
|
|
297
297
|
*/
|
|
298
298
|
skip_effect(t) {
|
|
299
|
-
l(this,
|
|
299
|
+
l(this, ge).has(t) || l(this, ge).set(t, { d: [], m: [] });
|
|
300
300
|
}
|
|
301
301
|
/**
|
|
302
302
|
* Remove an effect from the #skipped_branches map and reschedule
|
|
@@ -304,13 +304,13 @@ const An = class An {
|
|
|
304
304
|
* @param {Effect} effect
|
|
305
305
|
*/
|
|
306
306
|
unskip_effect(t) {
|
|
307
|
-
var n = l(this,
|
|
307
|
+
var n = l(this, ge).get(t);
|
|
308
308
|
if (n) {
|
|
309
|
-
l(this,
|
|
309
|
+
l(this, ge).delete(t);
|
|
310
310
|
for (var r of n.d)
|
|
311
|
-
M(r,
|
|
311
|
+
M(r, P), te(r);
|
|
312
312
|
for (r of n.m)
|
|
313
|
-
M(r,
|
|
313
|
+
M(r, re), te(r);
|
|
314
314
|
}
|
|
315
315
|
}
|
|
316
316
|
/**
|
|
@@ -318,19 +318,19 @@ const An = class An {
|
|
|
318
318
|
* @param {Effect[]} root_effects
|
|
319
319
|
*/
|
|
320
320
|
process(t) {
|
|
321
|
-
|
|
321
|
+
H = [], this.apply();
|
|
322
322
|
var n = [], r = [];
|
|
323
323
|
for (const s of t)
|
|
324
|
-
j(this,
|
|
324
|
+
j(this, de, wn).call(this, s, n, r);
|
|
325
325
|
if (this.is_deferred()) {
|
|
326
|
-
j(this,
|
|
327
|
-
for (const [s, i] of l(this,
|
|
328
|
-
|
|
326
|
+
j(this, de, bn).call(this, r), j(this, de, bn).call(this, n);
|
|
327
|
+
for (const [s, i] of l(this, ge))
|
|
328
|
+
Tr(s, i);
|
|
329
329
|
} else {
|
|
330
|
-
for (const s of l(this,
|
|
331
|
-
l(this,
|
|
330
|
+
for (const s of l(this, tt)) s();
|
|
331
|
+
l(this, tt).clear(), l(this, ze) === 0 && j(this, de, kr).call(this), x = null, er(r), er(n), l(this, Et)?.resolve();
|
|
332
332
|
}
|
|
333
|
-
|
|
333
|
+
ee = null;
|
|
334
334
|
}
|
|
335
335
|
/**
|
|
336
336
|
* Associate a change to a given source with the current
|
|
@@ -339,63 +339,63 @@ const An = class An {
|
|
|
339
339
|
* @param {any} value
|
|
340
340
|
*/
|
|
341
341
|
capture(t, n) {
|
|
342
|
-
n !==
|
|
342
|
+
n !== O && !this.previous.has(t) && this.previous.set(t, n), (t.f & Ce) === 0 && (this.current.set(t, t.v), ee?.set(t, t.v));
|
|
343
343
|
}
|
|
344
344
|
activate() {
|
|
345
345
|
x = this, this.apply();
|
|
346
346
|
}
|
|
347
347
|
deactivate() {
|
|
348
|
-
x === this && (x = null,
|
|
348
|
+
x === this && (x = null, ee = null);
|
|
349
349
|
}
|
|
350
350
|
flush() {
|
|
351
|
-
if (this.activate(),
|
|
352
|
-
if (
|
|
351
|
+
if (this.activate(), H.length > 0) {
|
|
352
|
+
if (Ir(), x !== null && x !== this)
|
|
353
353
|
return;
|
|
354
|
-
} else l(this,
|
|
354
|
+
} else l(this, ze) === 0 && this.process([]);
|
|
355
355
|
this.deactivate();
|
|
356
356
|
}
|
|
357
357
|
discard() {
|
|
358
|
-
for (const t of l(this,
|
|
359
|
-
l(this,
|
|
358
|
+
for (const t of l(this, nt)) t(this);
|
|
359
|
+
l(this, nt).clear();
|
|
360
360
|
}
|
|
361
361
|
/**
|
|
362
362
|
*
|
|
363
363
|
* @param {boolean} blocking
|
|
364
364
|
*/
|
|
365
365
|
increment(t) {
|
|
366
|
-
p(this,
|
|
366
|
+
p(this, ze, l(this, ze) + 1), t && p(this, rt, l(this, rt) + 1);
|
|
367
367
|
}
|
|
368
368
|
/**
|
|
369
369
|
*
|
|
370
370
|
* @param {boolean} blocking
|
|
371
371
|
*/
|
|
372
372
|
decrement(t) {
|
|
373
|
-
p(this,
|
|
374
|
-
p(this,
|
|
373
|
+
p(this, ze, l(this, ze) - 1), t && p(this, rt, l(this, rt) - 1), !l(this, st) && (p(this, st, !0), et(() => {
|
|
374
|
+
p(this, st, !1), this.is_deferred() ? H.length > 0 && this.flush() : this.revive();
|
|
375
375
|
}));
|
|
376
376
|
}
|
|
377
377
|
revive() {
|
|
378
|
-
for (const t of l(this,
|
|
379
|
-
l(this,
|
|
380
|
-
for (const t of l(this,
|
|
381
|
-
M(t,
|
|
378
|
+
for (const t of l(this, St))
|
|
379
|
+
l(this, Ve).delete(t), M(t, P), te(t);
|
|
380
|
+
for (const t of l(this, Ve))
|
|
381
|
+
M(t, re), te(t);
|
|
382
382
|
this.flush();
|
|
383
383
|
}
|
|
384
384
|
/** @param {() => void} fn */
|
|
385
385
|
oncommit(t) {
|
|
386
|
-
l(this,
|
|
386
|
+
l(this, tt).add(t);
|
|
387
387
|
}
|
|
388
388
|
/** @param {(batch: Batch) => void} fn */
|
|
389
389
|
ondiscard(t) {
|
|
390
|
-
l(this,
|
|
390
|
+
l(this, nt).add(t);
|
|
391
391
|
}
|
|
392
392
|
settled() {
|
|
393
|
-
return (l(this,
|
|
393
|
+
return (l(this, Et) ?? p(this, Et, hr())).promise;
|
|
394
394
|
}
|
|
395
395
|
static ensure() {
|
|
396
396
|
if (x === null) {
|
|
397
|
-
const t = x = new
|
|
398
|
-
|
|
397
|
+
const t = x = new jn();
|
|
398
|
+
Ot.add(x), mt || et(() => {
|
|
399
399
|
x === t && t.flush();
|
|
400
400
|
});
|
|
401
401
|
}
|
|
@@ -404,19 +404,19 @@ const An = class An {
|
|
|
404
404
|
apply() {
|
|
405
405
|
}
|
|
406
406
|
};
|
|
407
|
-
|
|
407
|
+
tt = new WeakMap(), nt = new WeakMap(), ze = new WeakMap(), rt = new WeakMap(), Et = new WeakMap(), St = new WeakMap(), Ve = new WeakMap(), ge = new WeakMap(), st = new WeakMap(), de = new WeakSet(), /**
|
|
408
408
|
* Traverse the effect tree, executing effects or stashing
|
|
409
409
|
* them for later execution as appropriate
|
|
410
410
|
* @param {Effect} root
|
|
411
411
|
* @param {Effect[]} effects
|
|
412
412
|
* @param {Effect[]} render_effects
|
|
413
413
|
*/
|
|
414
|
-
|
|
415
|
-
t.f ^=
|
|
414
|
+
wn = function(t, n, r) {
|
|
415
|
+
t.f ^= C;
|
|
416
416
|
for (var s = t.first, i = null; s !== null; ) {
|
|
417
|
-
var o = s.f,
|
|
418
|
-
if (!
|
|
419
|
-
|
|
417
|
+
var o = s.f, u = (o & (he | Oe)) !== 0, a = u && (o & C) !== 0, f = a || (o & ae) !== 0 || l(this, ge).has(s);
|
|
418
|
+
if (!f && s.fn !== null) {
|
|
419
|
+
u ? s.f ^= C : i !== null && (o & (Bt | Xt | vr)) !== 0 ? i.b.defer_effect(s) : (o & Bt) !== 0 ? n.push(s) : Mt(s) && ((o & Se) !== 0 && l(this, Ve).add(s), vt(s));
|
|
420
420
|
var c = s.first;
|
|
421
421
|
if (c !== null) {
|
|
422
422
|
s = c;
|
|
@@ -425,9 +425,9 @@ an = function(t, n, r) {
|
|
|
425
425
|
}
|
|
426
426
|
for (; s !== null; ) {
|
|
427
427
|
s === i && (i = null);
|
|
428
|
-
var
|
|
429
|
-
if (
|
|
430
|
-
s =
|
|
428
|
+
var v = s.next;
|
|
429
|
+
if (v !== null) {
|
|
430
|
+
s = v;
|
|
431
431
|
break;
|
|
432
432
|
}
|
|
433
433
|
s = s.parent;
|
|
@@ -436,137 +436,137 @@ an = function(t, n, r) {
|
|
|
436
436
|
}, /**
|
|
437
437
|
* @param {Effect[]} effects
|
|
438
438
|
*/
|
|
439
|
-
|
|
439
|
+
bn = function(t) {
|
|
440
440
|
for (var n = 0; n < t.length; n += 1)
|
|
441
|
-
|
|
442
|
-
},
|
|
441
|
+
xr(t[n], l(this, St), l(this, Ve));
|
|
442
|
+
}, kr = function() {
|
|
443
443
|
var s;
|
|
444
|
-
if (
|
|
444
|
+
if (Ot.size > 1) {
|
|
445
445
|
this.previous.clear();
|
|
446
|
-
var t =
|
|
447
|
-
for (const i of
|
|
446
|
+
var t = ee, n = !0;
|
|
447
|
+
for (const i of Ot) {
|
|
448
448
|
if (i === this) {
|
|
449
449
|
n = !1;
|
|
450
450
|
continue;
|
|
451
451
|
}
|
|
452
452
|
const o = [];
|
|
453
|
-
for (const [
|
|
454
|
-
if (i.current.has(
|
|
455
|
-
if (n &&
|
|
456
|
-
i.current.set(
|
|
453
|
+
for (const [a, f] of this.current) {
|
|
454
|
+
if (i.current.has(a))
|
|
455
|
+
if (n && f !== i.current.get(a))
|
|
456
|
+
i.current.set(a, f);
|
|
457
457
|
else
|
|
458
458
|
continue;
|
|
459
|
-
o.push(
|
|
459
|
+
o.push(a);
|
|
460
460
|
}
|
|
461
461
|
if (o.length === 0)
|
|
462
462
|
continue;
|
|
463
|
-
const
|
|
464
|
-
if (
|
|
465
|
-
var r =
|
|
466
|
-
|
|
467
|
-
const
|
|
463
|
+
const u = [...i.current.keys()].filter((a) => !this.current.has(a));
|
|
464
|
+
if (u.length > 0) {
|
|
465
|
+
var r = H;
|
|
466
|
+
H = [];
|
|
467
|
+
const a = /* @__PURE__ */ new Set(), f = /* @__PURE__ */ new Map();
|
|
468
468
|
for (const c of o)
|
|
469
|
-
|
|
470
|
-
if (
|
|
469
|
+
Ar(c, u, a, f);
|
|
470
|
+
if (H.length > 0) {
|
|
471
471
|
x = i, i.apply();
|
|
472
|
-
for (const c of
|
|
473
|
-
j(s = i,
|
|
472
|
+
for (const c of H)
|
|
473
|
+
j(s = i, de, wn).call(s, c, [], []);
|
|
474
474
|
i.deactivate();
|
|
475
475
|
}
|
|
476
|
-
|
|
476
|
+
H = r;
|
|
477
477
|
}
|
|
478
478
|
}
|
|
479
|
-
x = null,
|
|
479
|
+
x = null, ee = t;
|
|
480
480
|
}
|
|
481
|
-
this.committed = !0,
|
|
481
|
+
this.committed = !0, Ot.delete(this);
|
|
482
482
|
};
|
|
483
|
-
let
|
|
484
|
-
function
|
|
485
|
-
var t =
|
|
486
|
-
|
|
483
|
+
let Ee = jn;
|
|
484
|
+
function Ft(e) {
|
|
485
|
+
var t = mt;
|
|
486
|
+
mt = !0;
|
|
487
487
|
try {
|
|
488
488
|
for (var n; ; ) {
|
|
489
|
-
if (
|
|
490
|
-
return
|
|
489
|
+
if (Qs(), H.length === 0 && (x?.flush(), H.length === 0))
|
|
490
|
+
return Gt = null, /** @type {T} */
|
|
491
491
|
n;
|
|
492
|
-
|
|
492
|
+
Ir();
|
|
493
493
|
}
|
|
494
494
|
} finally {
|
|
495
|
-
|
|
495
|
+
mt = t;
|
|
496
496
|
}
|
|
497
497
|
}
|
|
498
|
-
function
|
|
499
|
-
|
|
498
|
+
function Ir() {
|
|
499
|
+
mn = !0;
|
|
500
500
|
var e = null;
|
|
501
501
|
try {
|
|
502
|
-
for (var t = 0;
|
|
503
|
-
var n =
|
|
502
|
+
for (var t = 0; H.length > 0; ) {
|
|
503
|
+
var n = Ee.ensure();
|
|
504
504
|
if (t++ > 1e3) {
|
|
505
505
|
var r, s;
|
|
506
|
-
|
|
506
|
+
ti();
|
|
507
507
|
}
|
|
508
|
-
n.process(
|
|
508
|
+
n.process(H), Re.clear();
|
|
509
509
|
}
|
|
510
510
|
} finally {
|
|
511
|
-
|
|
511
|
+
H = [], mn = !1, Gt = null;
|
|
512
512
|
}
|
|
513
513
|
}
|
|
514
|
-
function
|
|
514
|
+
function ti() {
|
|
515
515
|
try {
|
|
516
|
-
|
|
516
|
+
zs();
|
|
517
517
|
} catch (e) {
|
|
518
|
-
|
|
518
|
+
dt(e, Gt);
|
|
519
519
|
}
|
|
520
520
|
}
|
|
521
|
-
let
|
|
522
|
-
function
|
|
521
|
+
let pe = null;
|
|
522
|
+
function er(e) {
|
|
523
523
|
var t = e.length;
|
|
524
524
|
if (t !== 0) {
|
|
525
525
|
for (var n = 0; n < t; ) {
|
|
526
526
|
var r = e[n++];
|
|
527
|
-
if ((r.f & (
|
|
528
|
-
|
|
529
|
-
for (const s of
|
|
530
|
-
if ((s.f & (
|
|
527
|
+
if ((r.f & ($e | ae)) === 0 && Mt(r) && (pe = /* @__PURE__ */ new Set(), vt(r), r.deps === null && r.first === null && r.nodes === null && r.teardown === null && r.ac === null && Ur(r), pe?.size > 0)) {
|
|
528
|
+
Re.clear();
|
|
529
|
+
for (const s of pe) {
|
|
530
|
+
if ((s.f & ($e | ae)) !== 0) continue;
|
|
531
531
|
const i = [s];
|
|
532
532
|
let o = s.parent;
|
|
533
533
|
for (; o !== null; )
|
|
534
|
-
|
|
535
|
-
for (let
|
|
536
|
-
const
|
|
537
|
-
(
|
|
534
|
+
pe.has(o) && (pe.delete(o), i.push(o)), o = o.parent;
|
|
535
|
+
for (let u = i.length - 1; u >= 0; u--) {
|
|
536
|
+
const a = i[u];
|
|
537
|
+
(a.f & ($e | ae)) === 0 && vt(a);
|
|
538
538
|
}
|
|
539
539
|
}
|
|
540
|
-
|
|
540
|
+
pe.clear();
|
|
541
541
|
}
|
|
542
542
|
}
|
|
543
|
-
|
|
543
|
+
pe = null;
|
|
544
544
|
}
|
|
545
545
|
}
|
|
546
|
-
function
|
|
546
|
+
function Ar(e, t, n, r) {
|
|
547
547
|
if (!n.has(e) && (n.add(e), e.reactions !== null))
|
|
548
548
|
for (const s of e.reactions) {
|
|
549
549
|
const i = s.f;
|
|
550
|
-
(i &
|
|
550
|
+
(i & L) !== 0 ? Ar(
|
|
551
551
|
/** @type {Derived} */
|
|
552
552
|
s,
|
|
553
553
|
t,
|
|
554
554
|
n,
|
|
555
555
|
r
|
|
556
|
-
) : (i & (
|
|
556
|
+
) : (i & (Cn | Se)) !== 0 && (i & P) === 0 && Mr(s, t, r) && (M(s, P), te(
|
|
557
557
|
/** @type {Effect} */
|
|
558
558
|
s
|
|
559
559
|
));
|
|
560
560
|
}
|
|
561
561
|
}
|
|
562
|
-
function
|
|
562
|
+
function Mr(e, t, n) {
|
|
563
563
|
const r = n.get(e);
|
|
564
564
|
if (r !== void 0) return r;
|
|
565
565
|
if (e.deps !== null)
|
|
566
566
|
for (const s of e.deps) {
|
|
567
|
-
if (
|
|
567
|
+
if (at.call(t, s))
|
|
568
568
|
return !0;
|
|
569
|
-
if ((s.f &
|
|
569
|
+
if ((s.f & L) !== 0 && Mr(
|
|
570
570
|
/** @type {Derived} */
|
|
571
571
|
s,
|
|
572
572
|
t,
|
|
@@ -580,77 +580,77 @@ function wr(e, t, n) {
|
|
|
580
580
|
}
|
|
581
581
|
return n.set(e, !1), !1;
|
|
582
582
|
}
|
|
583
|
-
function
|
|
584
|
-
for (var t =
|
|
583
|
+
function te(e) {
|
|
584
|
+
for (var t = Gt = e; t.parent !== null; ) {
|
|
585
585
|
t = t.parent;
|
|
586
586
|
var n = t.f;
|
|
587
|
-
if (
|
|
587
|
+
if (mn && t === y && (n & Se) !== 0 && (n & _r) === 0)
|
|
588
588
|
return;
|
|
589
|
-
if ((n & (
|
|
590
|
-
if ((n &
|
|
591
|
-
t.f ^=
|
|
589
|
+
if ((n & (Oe | he)) !== 0) {
|
|
590
|
+
if ((n & C) === 0) return;
|
|
591
|
+
t.f ^= C;
|
|
592
592
|
}
|
|
593
593
|
}
|
|
594
|
-
|
|
594
|
+
H.push(t);
|
|
595
595
|
}
|
|
596
|
-
function
|
|
597
|
-
if (!((e.f &
|
|
598
|
-
(e.f &
|
|
596
|
+
function Tr(e, t) {
|
|
597
|
+
if (!((e.f & he) !== 0 && (e.f & C) !== 0)) {
|
|
598
|
+
(e.f & P) !== 0 ? t.d.push(e) : (e.f & re) !== 0 && t.m.push(e), M(e, C);
|
|
599
599
|
for (var n = e.first; n !== null; )
|
|
600
|
-
|
|
600
|
+
Tr(n, t), n = n.next;
|
|
601
601
|
}
|
|
602
602
|
}
|
|
603
|
-
function
|
|
604
|
-
let t = 0, n =
|
|
603
|
+
function ni(e) {
|
|
604
|
+
let t = 0, n = At(0), r;
|
|
605
605
|
return () => {
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
t -= 1, t === 0 && (r?.(), r = void 0,
|
|
606
|
+
Pn() && (m(n), Br(() => (t === 0 && (r = ss(() => e(() => wt(n)))), t += 1, () => {
|
|
607
|
+
et(() => {
|
|
608
|
+
t -= 1, t === 0 && (r?.(), r = void 0, wt(n));
|
|
609
609
|
});
|
|
610
610
|
})));
|
|
611
611
|
};
|
|
612
612
|
}
|
|
613
|
-
var
|
|
614
|
-
function
|
|
615
|
-
new
|
|
613
|
+
var ri = ft | Je;
|
|
614
|
+
function si(e, t, n) {
|
|
615
|
+
new ii(e, t, n);
|
|
616
616
|
}
|
|
617
|
-
var
|
|
618
|
-
class
|
|
617
|
+
var X, xt, me, Ye, ie, oe, W, le, we, Be, Te, it, ot, lt, be, qt, F, Cr, Rr, yn, jt, $n;
|
|
618
|
+
class ii {
|
|
619
619
|
/**
|
|
620
620
|
* @param {TemplateNode} node
|
|
621
621
|
* @param {BoundaryProps} props
|
|
622
622
|
* @param {((anchor: Node) => void)} children
|
|
623
623
|
*/
|
|
624
624
|
constructor(t, n, r) {
|
|
625
|
-
|
|
625
|
+
w(this, F);
|
|
626
626
|
/** @type {Boundary | null} */
|
|
627
|
-
|
|
628
|
-
|
|
627
|
+
A(this, "parent");
|
|
628
|
+
A(this, "is_pending", !1);
|
|
629
629
|
/** @type {TemplateNode} */
|
|
630
|
-
|
|
630
|
+
w(this, X);
|
|
631
631
|
/** @type {TemplateNode | null} */
|
|
632
|
-
|
|
632
|
+
w(this, xt, I ? k : null);
|
|
633
633
|
/** @type {BoundaryProps} */
|
|
634
|
-
|
|
634
|
+
w(this, me);
|
|
635
635
|
/** @type {((anchor: Node) => void)} */
|
|
636
|
-
|
|
636
|
+
w(this, Ye);
|
|
637
637
|
/** @type {Effect} */
|
|
638
|
-
|
|
638
|
+
w(this, ie);
|
|
639
639
|
/** @type {Effect | null} */
|
|
640
|
-
|
|
640
|
+
w(this, oe, null);
|
|
641
641
|
/** @type {Effect | null} */
|
|
642
|
-
|
|
642
|
+
w(this, W, null);
|
|
643
643
|
/** @type {Effect | null} */
|
|
644
|
-
|
|
644
|
+
w(this, le, null);
|
|
645
645
|
/** @type {DocumentFragment | null} */
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
646
|
+
w(this, we, null);
|
|
647
|
+
w(this, Be, 0);
|
|
648
|
+
w(this, Te, 0);
|
|
649
|
+
w(this, it, !1);
|
|
650
650
|
/** @type {Set<Effect>} */
|
|
651
|
-
|
|
651
|
+
w(this, ot, /* @__PURE__ */ new Set());
|
|
652
652
|
/** @type {Set<Effect>} */
|
|
653
|
-
|
|
653
|
+
w(this, lt, /* @__PURE__ */ new Set());
|
|
654
654
|
/**
|
|
655
655
|
* A source containing the number of pending async deriveds/expressions.
|
|
656
656
|
* Only created if `$effect.pending()` is used inside the boundary,
|
|
@@ -658,34 +658,34 @@ class Xs {
|
|
|
658
658
|
* calls followed by no-op flushes
|
|
659
659
|
* @type {Source<number> | null}
|
|
660
660
|
*/
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
p(this,
|
|
661
|
+
w(this, be, null);
|
|
662
|
+
w(this, qt, ni(() => (p(this, be, At(l(this, Be))), () => {
|
|
663
|
+
p(this, be, null);
|
|
664
664
|
})));
|
|
665
|
-
p(this,
|
|
665
|
+
p(this, X, t), p(this, me, n), p(this, Ye, (s) => {
|
|
666
666
|
var i = (
|
|
667
667
|
/** @type {Effect} */
|
|
668
|
-
|
|
668
|
+
y
|
|
669
669
|
);
|
|
670
|
-
i.b = this, i.f |=
|
|
670
|
+
i.b = this, i.f |= pn, r(s);
|
|
671
671
|
}), this.parent = /** @type {Effect} */
|
|
672
|
-
|
|
673
|
-
if (
|
|
672
|
+
y.b, p(this, ie, Wr(() => {
|
|
673
|
+
if (I) {
|
|
674
674
|
const s = (
|
|
675
675
|
/** @type {Comment} */
|
|
676
|
-
l(this,
|
|
676
|
+
l(this, xt)
|
|
677
677
|
);
|
|
678
|
-
|
|
678
|
+
Nn(), s.data === Tn ? j(this, F, Rr).call(this) : j(this, F, Cr).call(this);
|
|
679
679
|
} else
|
|
680
|
-
j(this,
|
|
681
|
-
},
|
|
680
|
+
j(this, F, yn).call(this);
|
|
681
|
+
}, ri)), I && p(this, X, k);
|
|
682
682
|
}
|
|
683
683
|
/**
|
|
684
684
|
* Defer an effect inside a pending boundary until the boundary resolves
|
|
685
685
|
* @param {Effect} effect
|
|
686
686
|
*/
|
|
687
687
|
defer_effect(t) {
|
|
688
|
-
|
|
688
|
+
xr(t, l(this, ot), l(this, lt));
|
|
689
689
|
}
|
|
690
690
|
/**
|
|
691
691
|
* Returns `false` if the effect exists inside a boundary whose pending snippet is shown
|
|
@@ -695,7 +695,7 @@ class Xs {
|
|
|
695
695
|
return !this.is_pending && (!this.parent || this.parent.is_rendered());
|
|
696
696
|
}
|
|
697
697
|
has_pending_snippet() {
|
|
698
|
-
return !!l(this,
|
|
698
|
+
return !!l(this, me).pending;
|
|
699
699
|
}
|
|
700
700
|
/**
|
|
701
701
|
* Update the source that powers `$effect.pending()` inside this boundary,
|
|
@@ -704,99 +704,99 @@ class Xs {
|
|
|
704
704
|
* @param {1 | -1} d
|
|
705
705
|
*/
|
|
706
706
|
update_pending_count(t) {
|
|
707
|
-
j(this,
|
|
708
|
-
p(this,
|
|
707
|
+
j(this, F, $n).call(this, t), p(this, Be, l(this, Be) + t), !(!l(this, be) || l(this, it)) && (p(this, it, !0), et(() => {
|
|
708
|
+
p(this, it, !1), l(this, be) && Wt(l(this, be), l(this, Be));
|
|
709
709
|
}));
|
|
710
710
|
}
|
|
711
711
|
get_effect_pending() {
|
|
712
|
-
return l(this,
|
|
712
|
+
return l(this, qt).call(this), m(
|
|
713
713
|
/** @type {Source<number>} */
|
|
714
|
-
l(this,
|
|
714
|
+
l(this, be)
|
|
715
715
|
);
|
|
716
716
|
}
|
|
717
717
|
/** @param {unknown} error */
|
|
718
718
|
error(t) {
|
|
719
|
-
var n = l(this,
|
|
720
|
-
let r = l(this,
|
|
719
|
+
var n = l(this, me).onerror;
|
|
720
|
+
let r = l(this, me).failed;
|
|
721
721
|
if (!n && !r)
|
|
722
722
|
throw t;
|
|
723
|
-
l(this,
|
|
723
|
+
l(this, oe) && (V(l(this, oe)), p(this, oe, null)), l(this, W) && (V(l(this, W)), p(this, W, null)), l(this, le) && (V(l(this, le)), p(this, le, null)), I && (fe(
|
|
724
724
|
/** @type {TemplateNode} */
|
|
725
|
-
l(this,
|
|
726
|
-
),
|
|
725
|
+
l(this, xt)
|
|
726
|
+
), Xs(), fe(gr()));
|
|
727
727
|
var s = !1, i = !1;
|
|
728
728
|
const o = () => {
|
|
729
729
|
if (s) {
|
|
730
|
-
|
|
730
|
+
Us();
|
|
731
731
|
return;
|
|
732
732
|
}
|
|
733
|
-
s = !0, i &&
|
|
734
|
-
p(this,
|
|
735
|
-
}), j(this,
|
|
736
|
-
|
|
733
|
+
s = !0, i && qs(), l(this, le) !== null && bt(l(this, le), () => {
|
|
734
|
+
p(this, le, null);
|
|
735
|
+
}), j(this, F, jt).call(this, () => {
|
|
736
|
+
Ee.ensure(), j(this, F, yn).call(this);
|
|
737
737
|
});
|
|
738
738
|
};
|
|
739
|
-
|
|
739
|
+
et(() => {
|
|
740
740
|
try {
|
|
741
741
|
i = !0, n?.(t, o), i = !1;
|
|
742
|
-
} catch (
|
|
743
|
-
|
|
742
|
+
} catch (u) {
|
|
743
|
+
dt(u, l(this, ie) && l(this, ie).parent);
|
|
744
744
|
}
|
|
745
|
-
r && p(this,
|
|
746
|
-
|
|
745
|
+
r && p(this, le, j(this, F, jt).call(this, () => {
|
|
746
|
+
Ee.ensure();
|
|
747
747
|
try {
|
|
748
|
-
return
|
|
749
|
-
var
|
|
748
|
+
return Me(() => {
|
|
749
|
+
var u = (
|
|
750
750
|
/** @type {Effect} */
|
|
751
|
-
|
|
751
|
+
y
|
|
752
752
|
);
|
|
753
|
-
|
|
754
|
-
l(this,
|
|
753
|
+
u.b = this, u.f |= pn, r(
|
|
754
|
+
l(this, X),
|
|
755
755
|
() => t,
|
|
756
756
|
() => o
|
|
757
757
|
);
|
|
758
758
|
});
|
|
759
|
-
} catch (
|
|
760
|
-
return
|
|
761
|
-
|
|
759
|
+
} catch (u) {
|
|
760
|
+
return dt(
|
|
761
|
+
u,
|
|
762
762
|
/** @type {Effect} */
|
|
763
|
-
l(this,
|
|
763
|
+
l(this, ie).parent
|
|
764
764
|
), null;
|
|
765
765
|
}
|
|
766
766
|
}));
|
|
767
767
|
});
|
|
768
768
|
}
|
|
769
769
|
}
|
|
770
|
-
|
|
770
|
+
X = new WeakMap(), xt = new WeakMap(), me = new WeakMap(), Ye = new WeakMap(), ie = new WeakMap(), oe = new WeakMap(), W = new WeakMap(), le = new WeakMap(), we = new WeakMap(), Be = new WeakMap(), Te = new WeakMap(), it = new WeakMap(), ot = new WeakMap(), lt = new WeakMap(), be = new WeakMap(), qt = new WeakMap(), F = new WeakSet(), Cr = function() {
|
|
771
771
|
try {
|
|
772
|
-
p(this,
|
|
772
|
+
p(this, oe, Me(() => l(this, Ye).call(this, l(this, X))));
|
|
773
773
|
} catch (t) {
|
|
774
774
|
this.error(t);
|
|
775
775
|
}
|
|
776
|
-
},
|
|
777
|
-
const t = l(this,
|
|
778
|
-
t && (this.is_pending = !0, p(this,
|
|
779
|
-
var n = p(this,
|
|
780
|
-
n.append(r), p(this,
|
|
776
|
+
}, Rr = function() {
|
|
777
|
+
const t = l(this, me).pending;
|
|
778
|
+
t && (this.is_pending = !0, p(this, W, Me(() => t(l(this, X)))), et(() => {
|
|
779
|
+
var n = p(this, we, document.createDocumentFragment()), r = Xe();
|
|
780
|
+
n.append(r), p(this, oe, j(this, F, jt).call(this, () => (Ee.ensure(), Me(() => l(this, Ye).call(this, r))))), l(this, Te) === 0 && (l(this, X).before(n), p(this, we, null), bt(
|
|
781
781
|
/** @type {Effect} */
|
|
782
|
-
l(this,
|
|
782
|
+
l(this, W),
|
|
783
783
|
() => {
|
|
784
|
-
p(this,
|
|
784
|
+
p(this, W, null);
|
|
785
785
|
}
|
|
786
786
|
), this.is_pending = !1);
|
|
787
787
|
}));
|
|
788
|
-
},
|
|
788
|
+
}, yn = function() {
|
|
789
789
|
try {
|
|
790
|
-
if (this.is_pending = this.has_pending_snippet(), p(this, Te, 0), p(this,
|
|
791
|
-
l(this,
|
|
790
|
+
if (this.is_pending = this.has_pending_snippet(), p(this, Te, 0), p(this, Be, 0), p(this, oe, Me(() => {
|
|
791
|
+
l(this, Ye).call(this, l(this, X));
|
|
792
792
|
})), l(this, Te) > 0) {
|
|
793
|
-
var t = p(this,
|
|
794
|
-
|
|
793
|
+
var t = p(this, we, document.createDocumentFragment());
|
|
794
|
+
Kr(l(this, oe), t);
|
|
795
795
|
const n = (
|
|
796
796
|
/** @type {(anchor: Node) => void} */
|
|
797
|
-
l(this,
|
|
797
|
+
l(this, me).pending
|
|
798
798
|
);
|
|
799
|
-
p(this,
|
|
799
|
+
p(this, W, Me(() => n(l(this, X))));
|
|
800
800
|
} else
|
|
801
801
|
this.is_pending = !1;
|
|
802
802
|
} catch (n) {
|
|
@@ -806,107 +806,107 @@ U = new WeakMap(), Et = new WeakMap(), _e = new WeakMap(), He = new WeakMap(), s
|
|
|
806
806
|
* @template T
|
|
807
807
|
* @param {() => T} fn
|
|
808
808
|
*/
|
|
809
|
-
|
|
810
|
-
var n =
|
|
811
|
-
|
|
809
|
+
jt = function(t) {
|
|
810
|
+
var n = y, r = b, s = Y;
|
|
811
|
+
ce(l(this, ie)), Z(l(this, ie)), ct(l(this, ie).ctx);
|
|
812
812
|
try {
|
|
813
813
|
return t();
|
|
814
814
|
} catch (i) {
|
|
815
|
-
return
|
|
815
|
+
return Er(i), null;
|
|
816
816
|
} finally {
|
|
817
|
-
|
|
817
|
+
ce(n), Z(r), ct(s);
|
|
818
818
|
}
|
|
819
819
|
}, /**
|
|
820
820
|
* Updates the pending count associated with the currently visible pending snippet,
|
|
821
821
|
* if any, such that we can replace the snippet with content once work is done
|
|
822
822
|
* @param {1 | -1} d
|
|
823
823
|
*/
|
|
824
|
-
|
|
824
|
+
$n = function(t) {
|
|
825
825
|
var n;
|
|
826
826
|
if (!this.has_pending_snippet()) {
|
|
827
|
-
this.parent && j(n = this.parent,
|
|
827
|
+
this.parent && j(n = this.parent, F, $n).call(n, t);
|
|
828
828
|
return;
|
|
829
829
|
}
|
|
830
830
|
if (p(this, Te, l(this, Te) + t), l(this, Te) === 0) {
|
|
831
831
|
this.is_pending = !1;
|
|
832
|
-
for (const r of l(this,
|
|
833
|
-
M(r,
|
|
834
|
-
for (const r of l(this,
|
|
835
|
-
M(r,
|
|
836
|
-
l(this,
|
|
837
|
-
p(this,
|
|
838
|
-
}), l(this,
|
|
832
|
+
for (const r of l(this, ot))
|
|
833
|
+
M(r, P), te(r);
|
|
834
|
+
for (const r of l(this, lt))
|
|
835
|
+
M(r, re), te(r);
|
|
836
|
+
l(this, ot).clear(), l(this, lt).clear(), l(this, W) && bt(l(this, W), () => {
|
|
837
|
+
p(this, W, null);
|
|
838
|
+
}), l(this, we) && (l(this, X).before(l(this, we)), p(this, we, null));
|
|
839
839
|
}
|
|
840
840
|
};
|
|
841
|
-
function
|
|
842
|
-
const s =
|
|
841
|
+
function oi(e, t, n, r) {
|
|
842
|
+
const s = Dn;
|
|
843
843
|
var i = e.filter((d) => !d.settled);
|
|
844
844
|
if (n.length === 0 && i.length === 0) {
|
|
845
845
|
r(t.map(s));
|
|
846
846
|
return;
|
|
847
847
|
}
|
|
848
|
-
var o = x,
|
|
848
|
+
var o = x, u = (
|
|
849
849
|
/** @type {Effect} */
|
|
850
|
-
|
|
851
|
-
),
|
|
850
|
+
y
|
|
851
|
+
), a = li(), f = i.length === 1 ? i[0].promise : i.length > 1 ? Promise.all(i.map((d) => d.promise)) : null;
|
|
852
852
|
function c(d) {
|
|
853
|
-
|
|
853
|
+
a();
|
|
854
854
|
try {
|
|
855
855
|
r(d);
|
|
856
856
|
} catch (g) {
|
|
857
|
-
(
|
|
857
|
+
(u.f & $e) === 0 && dt(g, u);
|
|
858
858
|
}
|
|
859
|
-
o?.deactivate(),
|
|
859
|
+
o?.deactivate(), En();
|
|
860
860
|
}
|
|
861
861
|
if (n.length === 0) {
|
|
862
|
-
|
|
862
|
+
f.then(() => c(t.map(s)));
|
|
863
863
|
return;
|
|
864
864
|
}
|
|
865
|
-
function
|
|
866
|
-
|
|
865
|
+
function v() {
|
|
866
|
+
a(), Promise.all(n.map((d) => /* @__PURE__ */ ui(d))).then((d) => c([...t.map(s), ...d])).catch((d) => dt(d, u));
|
|
867
867
|
}
|
|
868
|
-
|
|
868
|
+
f ? f.then(v) : v();
|
|
869
869
|
}
|
|
870
|
-
function
|
|
871
|
-
var e =
|
|
870
|
+
function li() {
|
|
871
|
+
var e = y, t = b, n = Y, r = x;
|
|
872
872
|
return function(i = !0) {
|
|
873
|
-
|
|
873
|
+
ce(e), Z(t), ct(n), i && r?.activate();
|
|
874
874
|
};
|
|
875
875
|
}
|
|
876
|
-
function
|
|
877
|
-
|
|
876
|
+
function En() {
|
|
877
|
+
ce(null), Z(null), ct(null);
|
|
878
878
|
}
|
|
879
879
|
// @__NO_SIDE_EFFECTS__
|
|
880
|
-
function
|
|
881
|
-
var t =
|
|
880
|
+
function Dn(e) {
|
|
881
|
+
var t = L | P, n = b !== null && (b.f & L) !== 0 ? (
|
|
882
882
|
/** @type {Derived} */
|
|
883
883
|
b
|
|
884
884
|
) : null;
|
|
885
|
-
return
|
|
886
|
-
ctx:
|
|
885
|
+
return y !== null && (y.f |= Je), {
|
|
886
|
+
ctx: Y,
|
|
887
887
|
deps: null,
|
|
888
888
|
effects: null,
|
|
889
|
-
equals:
|
|
889
|
+
equals: mr,
|
|
890
890
|
f: t,
|
|
891
891
|
fn: e,
|
|
892
892
|
reactions: null,
|
|
893
893
|
rv: 0,
|
|
894
894
|
v: (
|
|
895
895
|
/** @type {V} */
|
|
896
|
-
|
|
896
|
+
O
|
|
897
897
|
),
|
|
898
898
|
wv: 0,
|
|
899
|
-
parent: n ??
|
|
899
|
+
parent: n ?? y,
|
|
900
900
|
ac: null
|
|
901
901
|
};
|
|
902
902
|
}
|
|
903
903
|
// @__NO_SIDE_EFFECTS__
|
|
904
|
-
function
|
|
904
|
+
function ui(e, t, n) {
|
|
905
905
|
let r = (
|
|
906
906
|
/** @type {Effect | null} */
|
|
907
|
-
|
|
907
|
+
y
|
|
908
908
|
);
|
|
909
|
-
r === null &&
|
|
909
|
+
r === null && Ps();
|
|
910
910
|
var s = (
|
|
911
911
|
/** @type {Boundary} */
|
|
912
912
|
r.b
|
|
@@ -914,74 +914,74 @@ function Gs(e, t, n) {
|
|
|
914
914
|
/** @type {Promise<V>} */
|
|
915
915
|
/** @type {unknown} */
|
|
916
916
|
void 0
|
|
917
|
-
), o =
|
|
917
|
+
), o = At(
|
|
918
918
|
/** @type {V} */
|
|
919
|
-
|
|
920
|
-
),
|
|
921
|
-
return
|
|
922
|
-
var
|
|
923
|
-
i =
|
|
919
|
+
O
|
|
920
|
+
), u = !b, a = /* @__PURE__ */ new Map();
|
|
921
|
+
return $i(() => {
|
|
922
|
+
var f = hr();
|
|
923
|
+
i = f.promise;
|
|
924
924
|
try {
|
|
925
|
-
Promise.resolve(e()).then(
|
|
926
|
-
c === x && c.committed && c.deactivate(),
|
|
925
|
+
Promise.resolve(e()).then(f.resolve, f.reject).then(() => {
|
|
926
|
+
c === x && c.committed && c.deactivate(), En();
|
|
927
927
|
});
|
|
928
928
|
} catch (g) {
|
|
929
|
-
|
|
929
|
+
f.reject(g), En();
|
|
930
930
|
}
|
|
931
931
|
var c = (
|
|
932
932
|
/** @type {Batch} */
|
|
933
933
|
x
|
|
934
934
|
);
|
|
935
|
-
if (
|
|
936
|
-
var
|
|
937
|
-
s.update_pending_count(1), c.increment(
|
|
935
|
+
if (u) {
|
|
936
|
+
var v = s.is_rendered();
|
|
937
|
+
s.update_pending_count(1), c.increment(v), a.get(c)?.reject(Pe), a.delete(c), a.set(c, f);
|
|
938
938
|
}
|
|
939
|
-
const d = (g,
|
|
940
|
-
if (c.activate(),
|
|
941
|
-
|
|
939
|
+
const d = (g, _ = void 0) => {
|
|
940
|
+
if (c.activate(), _)
|
|
941
|
+
_ !== Pe && (o.f |= Ce, Wt(o, _));
|
|
942
942
|
else {
|
|
943
|
-
(o.f &
|
|
944
|
-
for (const [
|
|
945
|
-
if (
|
|
946
|
-
|
|
943
|
+
(o.f & Ce) !== 0 && (o.f ^= Ce), Wt(o, g);
|
|
944
|
+
for (const [T, E] of a) {
|
|
945
|
+
if (a.delete(T), T === c) break;
|
|
946
|
+
E.reject(Pe);
|
|
947
947
|
}
|
|
948
948
|
}
|
|
949
|
-
|
|
949
|
+
u && (s.update_pending_count(-1), c.decrement(v));
|
|
950
950
|
};
|
|
951
|
-
|
|
952
|
-
}),
|
|
953
|
-
for (const
|
|
954
|
-
|
|
955
|
-
}), new Promise((
|
|
956
|
-
function c(
|
|
951
|
+
f.promise.then(d, (g) => d(null, g || "unknown"));
|
|
952
|
+
}), wi(() => {
|
|
953
|
+
for (const f of a.values())
|
|
954
|
+
f.reject(Pe);
|
|
955
|
+
}), new Promise((f) => {
|
|
956
|
+
function c(v) {
|
|
957
957
|
function d() {
|
|
958
|
-
|
|
958
|
+
v === i ? f(o) : c(i);
|
|
959
959
|
}
|
|
960
|
-
|
|
960
|
+
v.then(d, d);
|
|
961
961
|
}
|
|
962
962
|
c(i);
|
|
963
963
|
});
|
|
964
964
|
}
|
|
965
965
|
// @__NO_SIDE_EFFECTS__
|
|
966
|
-
function
|
|
967
|
-
const t = /* @__PURE__ */
|
|
968
|
-
return
|
|
966
|
+
function ai(e) {
|
|
967
|
+
const t = /* @__PURE__ */ Dn(e);
|
|
968
|
+
return Gr(t), t;
|
|
969
969
|
}
|
|
970
|
-
function
|
|
970
|
+
function fi(e) {
|
|
971
971
|
var t = e.effects;
|
|
972
972
|
if (t !== null) {
|
|
973
973
|
e.effects = null;
|
|
974
974
|
for (var n = 0; n < t.length; n += 1)
|
|
975
|
-
|
|
975
|
+
V(
|
|
976
976
|
/** @type {Effect} */
|
|
977
977
|
t[n]
|
|
978
978
|
);
|
|
979
979
|
}
|
|
980
980
|
}
|
|
981
|
-
function
|
|
981
|
+
function ci(e) {
|
|
982
982
|
for (var t = e.parent; t !== null; ) {
|
|
983
|
-
if ((t.f &
|
|
984
|
-
return (t.f &
|
|
983
|
+
if ((t.f & L) === 0)
|
|
984
|
+
return (t.f & $e) === 0 ? (
|
|
985
985
|
/** @type {Effect} */
|
|
986
986
|
t
|
|
987
987
|
) : null;
|
|
@@ -989,172 +989,172 @@ function ei(e) {
|
|
|
989
989
|
}
|
|
990
990
|
return null;
|
|
991
991
|
}
|
|
992
|
-
function
|
|
993
|
-
var t, n =
|
|
994
|
-
|
|
992
|
+
function Ln(e) {
|
|
993
|
+
var t, n = y;
|
|
994
|
+
ce(ci(e));
|
|
995
995
|
try {
|
|
996
|
-
e.f &= ~
|
|
996
|
+
e.f &= ~Ue, fi(e), t = ts(e);
|
|
997
997
|
} finally {
|
|
998
|
-
|
|
998
|
+
ce(n);
|
|
999
999
|
}
|
|
1000
1000
|
return t;
|
|
1001
1001
|
}
|
|
1002
|
-
function
|
|
1003
|
-
var t =
|
|
1004
|
-
if (!e.equals(t) && (e.wv =
|
|
1005
|
-
M(e,
|
|
1002
|
+
function Nr(e) {
|
|
1003
|
+
var t = Ln(e);
|
|
1004
|
+
if (!e.equals(t) && (e.wv = Qr(), (!x?.is_fork || e.deps === null) && (e.v = t, e.deps === null))) {
|
|
1005
|
+
M(e, C);
|
|
1006
1006
|
return;
|
|
1007
1007
|
}
|
|
1008
|
-
|
|
1008
|
+
Ne || (ee !== null ? (Pn() || x?.is_fork) && ee.set(e, t) : On(e));
|
|
1009
1009
|
}
|
|
1010
|
-
function
|
|
1010
|
+
function di(e) {
|
|
1011
1011
|
if (e.effects !== null)
|
|
1012
1012
|
for (const t of e.effects)
|
|
1013
|
-
(t.teardown || t.ac) && (t.teardown?.(), t.ac?.abort(
|
|
1013
|
+
(t.teardown || t.ac) && (t.teardown?.(), t.ac?.abort(Pe), t.teardown = Ns, t.ac = null, yt(t, 0), Fn(t));
|
|
1014
1014
|
}
|
|
1015
|
-
function
|
|
1015
|
+
function Or(e) {
|
|
1016
1016
|
if (e.effects !== null)
|
|
1017
1017
|
for (const t of e.effects)
|
|
1018
|
-
t.teardown &&
|
|
1018
|
+
t.teardown && vt(t);
|
|
1019
1019
|
}
|
|
1020
|
-
let
|
|
1021
|
-
const
|
|
1022
|
-
let
|
|
1023
|
-
function
|
|
1020
|
+
let Sn = /* @__PURE__ */ new Set();
|
|
1021
|
+
const Re = /* @__PURE__ */ new Map();
|
|
1022
|
+
let Dr = !1;
|
|
1023
|
+
function At(e, t) {
|
|
1024
1024
|
var n = {
|
|
1025
1025
|
f: 0,
|
|
1026
1026
|
// TODO ideally we could skip this altogether, but it causes type errors
|
|
1027
1027
|
v: e,
|
|
1028
1028
|
reactions: null,
|
|
1029
|
-
equals:
|
|
1029
|
+
equals: mr,
|
|
1030
1030
|
rv: 0,
|
|
1031
1031
|
wv: 0
|
|
1032
1032
|
};
|
|
1033
1033
|
return n;
|
|
1034
1034
|
}
|
|
1035
1035
|
// @__NO_SIDE_EFFECTS__
|
|
1036
|
-
function
|
|
1037
|
-
const n =
|
|
1038
|
-
return
|
|
1036
|
+
function D(e, t) {
|
|
1037
|
+
const n = At(e);
|
|
1038
|
+
return Gr(n), n;
|
|
1039
1039
|
}
|
|
1040
1040
|
// @__NO_SIDE_EFFECTS__
|
|
1041
|
-
function
|
|
1042
|
-
const r =
|
|
1043
|
-
return t || (r.equals =
|
|
1041
|
+
function hi(e, t = !1, n = !0) {
|
|
1042
|
+
const r = At(e);
|
|
1043
|
+
return t || (r.equals = Gs), r;
|
|
1044
1044
|
}
|
|
1045
|
-
function
|
|
1045
|
+
function $(e, t, n = !1) {
|
|
1046
1046
|
b !== null && // since we are untracking the function inside `$inspect.with` we need to add this check
|
|
1047
1047
|
// to ensure we error if state is set inside an inspect effect
|
|
1048
|
-
(!
|
|
1049
|
-
let r = n ?
|
|
1050
|
-
return
|
|
1048
|
+
(!ne || (b.f & Qn) !== 0) && yr() && (b.f & (L | Se | Cn | Qn)) !== 0 && (G === null || !at.call(G, e)) && Ws();
|
|
1049
|
+
let r = n ? Ze(t) : t;
|
|
1050
|
+
return Wt(e, r);
|
|
1051
1051
|
}
|
|
1052
|
-
function
|
|
1052
|
+
function Wt(e, t) {
|
|
1053
1053
|
if (!e.equals(t)) {
|
|
1054
1054
|
var n = e.v;
|
|
1055
|
-
|
|
1056
|
-
var r =
|
|
1057
|
-
if (r.capture(e, n), (e.f &
|
|
1055
|
+
Ne ? Re.set(e, t) : Re.set(e, n), e.v = t;
|
|
1056
|
+
var r = Ee.ensure();
|
|
1057
|
+
if (r.capture(e, n), (e.f & L) !== 0) {
|
|
1058
1058
|
const s = (
|
|
1059
1059
|
/** @type {Derived} */
|
|
1060
1060
|
e
|
|
1061
1061
|
);
|
|
1062
|
-
(e.f &
|
|
1062
|
+
(e.f & P) !== 0 && Ln(s), On(s);
|
|
1063
1063
|
}
|
|
1064
|
-
e.wv =
|
|
1064
|
+
e.wv = Qr(), Lr(e, P), y !== null && (y.f & C) !== 0 && (y.f & (he | Oe)) === 0 && (U === null ? ki([e]) : U.push(e)), !r.is_fork && Sn.size > 0 && !Dr && vi();
|
|
1065
1065
|
}
|
|
1066
1066
|
return t;
|
|
1067
1067
|
}
|
|
1068
|
-
function
|
|
1069
|
-
|
|
1070
|
-
for (const e of
|
|
1071
|
-
(e.f &
|
|
1072
|
-
|
|
1068
|
+
function vi() {
|
|
1069
|
+
Dr = !1;
|
|
1070
|
+
for (const e of Sn)
|
|
1071
|
+
(e.f & C) !== 0 && M(e, re), Mt(e) && vt(e);
|
|
1072
|
+
Sn.clear();
|
|
1073
1073
|
}
|
|
1074
|
-
function
|
|
1075
|
-
|
|
1074
|
+
function wt(e) {
|
|
1075
|
+
$(e, e.v + 1);
|
|
1076
1076
|
}
|
|
1077
|
-
function
|
|
1077
|
+
function Lr(e, t) {
|
|
1078
1078
|
var n = e.reactions;
|
|
1079
1079
|
if (n !== null)
|
|
1080
1080
|
for (var r = n.length, s = 0; s < r; s++) {
|
|
1081
|
-
var i = n[s], o = i.f,
|
|
1082
|
-
if (
|
|
1083
|
-
var
|
|
1081
|
+
var i = n[s], o = i.f, u = (o & P) === 0;
|
|
1082
|
+
if (u && M(i, t), (o & L) !== 0) {
|
|
1083
|
+
var a = (
|
|
1084
1084
|
/** @type {Derived} */
|
|
1085
1085
|
i
|
|
1086
1086
|
);
|
|
1087
|
-
|
|
1088
|
-
} else
|
|
1087
|
+
ee?.delete(a), (o & Ue) === 0 && (o & K && (i.f |= Ue), Lr(a, re));
|
|
1088
|
+
} else u && ((o & Se) !== 0 && pe !== null && pe.add(
|
|
1089
1089
|
/** @type {Effect} */
|
|
1090
1090
|
i
|
|
1091
|
-
),
|
|
1091
|
+
), te(
|
|
1092
1092
|
/** @type {Effect} */
|
|
1093
1093
|
i
|
|
1094
1094
|
));
|
|
1095
1095
|
}
|
|
1096
1096
|
}
|
|
1097
|
-
function
|
|
1098
|
-
if (typeof e != "object" || e === null ||
|
|
1097
|
+
function Ze(e) {
|
|
1098
|
+
if (typeof e != "object" || e === null || dn in e)
|
|
1099
1099
|
return e;
|
|
1100
|
-
const t =
|
|
1101
|
-
if (t !==
|
|
1100
|
+
const t = dr(e);
|
|
1101
|
+
if (t !== Cs && t !== Rs)
|
|
1102
1102
|
return e;
|
|
1103
|
-
var n = /* @__PURE__ */ new Map(), r =
|
|
1104
|
-
if (
|
|
1105
|
-
return
|
|
1106
|
-
var
|
|
1107
|
-
|
|
1108
|
-
var c =
|
|
1109
|
-
return
|
|
1103
|
+
var n = /* @__PURE__ */ new Map(), r = cr(e), s = /* @__PURE__ */ D(0), i = qe, o = (u) => {
|
|
1104
|
+
if (qe === i)
|
|
1105
|
+
return u();
|
|
1106
|
+
var a = b, f = qe;
|
|
1107
|
+
Z(null), rr(i);
|
|
1108
|
+
var c = u();
|
|
1109
|
+
return Z(a), rr(f), c;
|
|
1110
1110
|
};
|
|
1111
|
-
return r && n.set("length", /* @__PURE__ */
|
|
1111
|
+
return r && n.set("length", /* @__PURE__ */ D(
|
|
1112
1112
|
/** @type {any[]} */
|
|
1113
1113
|
e.length
|
|
1114
1114
|
)), new Proxy(
|
|
1115
1115
|
/** @type {any} */
|
|
1116
1116
|
e,
|
|
1117
1117
|
{
|
|
1118
|
-
defineProperty(
|
|
1119
|
-
(!("value" in
|
|
1120
|
-
var c = n.get(
|
|
1118
|
+
defineProperty(u, a, f) {
|
|
1119
|
+
(!("value" in f) || f.configurable === !1 || f.enumerable === !1 || f.writable === !1) && Ys();
|
|
1120
|
+
var c = n.get(a);
|
|
1121
1121
|
return c === void 0 ? o(() => {
|
|
1122
|
-
var
|
|
1123
|
-
return n.set(
|
|
1124
|
-
}) :
|
|
1122
|
+
var v = /* @__PURE__ */ D(f.value);
|
|
1123
|
+
return n.set(a, v), v;
|
|
1124
|
+
}) : $(c, f.value, !0), !0;
|
|
1125
1125
|
},
|
|
1126
|
-
deleteProperty(
|
|
1127
|
-
var
|
|
1128
|
-
if (
|
|
1129
|
-
if (
|
|
1130
|
-
const c = o(() => /* @__PURE__ */
|
|
1131
|
-
n.set(
|
|
1126
|
+
deleteProperty(u, a) {
|
|
1127
|
+
var f = n.get(a);
|
|
1128
|
+
if (f === void 0) {
|
|
1129
|
+
if (a in u) {
|
|
1130
|
+
const c = o(() => /* @__PURE__ */ D(O));
|
|
1131
|
+
n.set(a, c), wt(s);
|
|
1132
1132
|
}
|
|
1133
1133
|
} else
|
|
1134
|
-
|
|
1134
|
+
$(f, O), wt(s);
|
|
1135
1135
|
return !0;
|
|
1136
1136
|
},
|
|
1137
|
-
get(
|
|
1138
|
-
if (
|
|
1137
|
+
get(u, a, f) {
|
|
1138
|
+
if (a === dn)
|
|
1139
1139
|
return e;
|
|
1140
|
-
var c = n.get(
|
|
1141
|
-
if (c === void 0 && (!
|
|
1142
|
-
var g =
|
|
1143
|
-
return
|
|
1144
|
-
}), n.set(
|
|
1145
|
-
var d =
|
|
1146
|
-
return d ===
|
|
1140
|
+
var c = n.get(a), v = a in u;
|
|
1141
|
+
if (c === void 0 && (!v || Qe(u, a)?.writable) && (c = o(() => {
|
|
1142
|
+
var g = Ze(v ? u[a] : O), _ = /* @__PURE__ */ D(g);
|
|
1143
|
+
return _;
|
|
1144
|
+
}), n.set(a, c)), c !== void 0) {
|
|
1145
|
+
var d = m(c);
|
|
1146
|
+
return d === O ? void 0 : d;
|
|
1147
1147
|
}
|
|
1148
|
-
return Reflect.get(
|
|
1148
|
+
return Reflect.get(u, a, f);
|
|
1149
1149
|
},
|
|
1150
|
-
getOwnPropertyDescriptor(
|
|
1151
|
-
var
|
|
1152
|
-
if (
|
|
1153
|
-
var c = n.get(
|
|
1154
|
-
c && (
|
|
1155
|
-
} else if (
|
|
1156
|
-
var
|
|
1157
|
-
if (
|
|
1150
|
+
getOwnPropertyDescriptor(u, a) {
|
|
1151
|
+
var f = Reflect.getOwnPropertyDescriptor(u, a);
|
|
1152
|
+
if (f && "value" in f) {
|
|
1153
|
+
var c = n.get(a);
|
|
1154
|
+
c && (f.value = m(c));
|
|
1155
|
+
} else if (f === void 0) {
|
|
1156
|
+
var v = n.get(a), d = v?.v;
|
|
1157
|
+
if (v !== void 0 && d !== O)
|
|
1158
1158
|
return {
|
|
1159
1159
|
enumerable: !0,
|
|
1160
1160
|
configurable: !0,
|
|
@@ -1162,173 +1162,173 @@ function Ke(e) {
|
|
|
1162
1162
|
writable: !0
|
|
1163
1163
|
};
|
|
1164
1164
|
}
|
|
1165
|
-
return
|
|
1165
|
+
return f;
|
|
1166
1166
|
},
|
|
1167
|
-
has(
|
|
1168
|
-
if (
|
|
1167
|
+
has(u, a) {
|
|
1168
|
+
if (a === dn)
|
|
1169
1169
|
return !0;
|
|
1170
|
-
var
|
|
1171
|
-
if (
|
|
1172
|
-
|
|
1173
|
-
var d = c ?
|
|
1170
|
+
var f = n.get(a), c = f !== void 0 && f.v !== O || Reflect.has(u, a);
|
|
1171
|
+
if (f !== void 0 || y !== null && (!c || Qe(u, a)?.writable)) {
|
|
1172
|
+
f === void 0 && (f = o(() => {
|
|
1173
|
+
var d = c ? Ze(u[a]) : O, g = /* @__PURE__ */ D(d);
|
|
1174
1174
|
return g;
|
|
1175
|
-
}), n.set(
|
|
1176
|
-
var
|
|
1177
|
-
if (
|
|
1175
|
+
}), n.set(a, f));
|
|
1176
|
+
var v = m(f);
|
|
1177
|
+
if (v === O)
|
|
1178
1178
|
return !1;
|
|
1179
1179
|
}
|
|
1180
1180
|
return c;
|
|
1181
1181
|
},
|
|
1182
|
-
set(
|
|
1183
|
-
var
|
|
1184
|
-
if (r &&
|
|
1185
|
-
for (var g =
|
|
1186
|
-
|
|
1187
|
-
var
|
|
1188
|
-
|
|
1182
|
+
set(u, a, f, c) {
|
|
1183
|
+
var v = n.get(a), d = a in u;
|
|
1184
|
+
if (r && a === "length")
|
|
1185
|
+
for (var g = f; g < /** @type {Source<number>} */
|
|
1186
|
+
v.v; g += 1) {
|
|
1187
|
+
var _ = n.get(g + "");
|
|
1188
|
+
_ !== void 0 ? $(_, O) : g in u && (_ = o(() => /* @__PURE__ */ D(O)), n.set(g + "", _));
|
|
1189
1189
|
}
|
|
1190
|
-
if (
|
|
1191
|
-
(!d ||
|
|
1190
|
+
if (v === void 0)
|
|
1191
|
+
(!d || Qe(u, a)?.writable) && (v = o(() => /* @__PURE__ */ D(void 0)), $(v, Ze(f)), n.set(a, v));
|
|
1192
1192
|
else {
|
|
1193
|
-
d =
|
|
1194
|
-
var
|
|
1195
|
-
|
|
1193
|
+
d = v.v !== O;
|
|
1194
|
+
var T = o(() => Ze(f));
|
|
1195
|
+
$(v, T);
|
|
1196
1196
|
}
|
|
1197
|
-
var
|
|
1198
|
-
if (
|
|
1199
|
-
if (r && typeof
|
|
1200
|
-
var
|
|
1197
|
+
var E = Reflect.getOwnPropertyDescriptor(u, a);
|
|
1198
|
+
if (E?.set && E.set.call(c, f), !d) {
|
|
1199
|
+
if (r && typeof a == "string") {
|
|
1200
|
+
var ke = (
|
|
1201
1201
|
/** @type {Source<number>} */
|
|
1202
1202
|
n.get("length")
|
|
1203
|
-
),
|
|
1204
|
-
Number.isInteger(
|
|
1203
|
+
), se = Number(a);
|
|
1204
|
+
Number.isInteger(se) && se >= ke.v && $(ke, se + 1);
|
|
1205
1205
|
}
|
|
1206
|
-
|
|
1206
|
+
wt(s);
|
|
1207
1207
|
}
|
|
1208
1208
|
return !0;
|
|
1209
1209
|
},
|
|
1210
|
-
ownKeys(
|
|
1211
|
-
|
|
1212
|
-
var
|
|
1213
|
-
var d = n.get(
|
|
1214
|
-
return d === void 0 || d.v !==
|
|
1210
|
+
ownKeys(u) {
|
|
1211
|
+
m(s);
|
|
1212
|
+
var a = Reflect.ownKeys(u).filter((v) => {
|
|
1213
|
+
var d = n.get(v);
|
|
1214
|
+
return d === void 0 || d.v !== O;
|
|
1215
1215
|
});
|
|
1216
|
-
for (var [
|
|
1217
|
-
c.v !==
|
|
1218
|
-
return
|
|
1216
|
+
for (var [f, c] of n)
|
|
1217
|
+
c.v !== O && !(f in u) && a.push(f);
|
|
1218
|
+
return a;
|
|
1219
1219
|
},
|
|
1220
1220
|
setPrototypeOf() {
|
|
1221
|
-
|
|
1221
|
+
Bs();
|
|
1222
1222
|
}
|
|
1223
1223
|
}
|
|
1224
1224
|
);
|
|
1225
1225
|
}
|
|
1226
|
-
var
|
|
1227
|
-
function
|
|
1228
|
-
if (
|
|
1229
|
-
|
|
1226
|
+
var tr, Pr, Fr, jr;
|
|
1227
|
+
function xn() {
|
|
1228
|
+
if (tr === void 0) {
|
|
1229
|
+
tr = window, Pr = /Firefox/.test(navigator.userAgent);
|
|
1230
1230
|
var e = Element.prototype, t = Node.prototype, n = Text.prototype;
|
|
1231
|
-
|
|
1231
|
+
Fr = Qe(t, "firstChild").get, jr = Qe(t, "nextSibling").get, Zn(e) && (e.__click = void 0, e.__className = void 0, e.__attributes = null, e.__style = void 0, e.__e = void 0), Zn(n) && (n.__t = void 0);
|
|
1232
1232
|
}
|
|
1233
1233
|
}
|
|
1234
|
-
function
|
|
1234
|
+
function Xe(e = "") {
|
|
1235
1235
|
return document.createTextNode(e);
|
|
1236
1236
|
}
|
|
1237
1237
|
// @__NO_SIDE_EFFECTS__
|
|
1238
|
-
function
|
|
1238
|
+
function ht(e) {
|
|
1239
1239
|
return (
|
|
1240
1240
|
/** @type {TemplateNode | null} */
|
|
1241
|
-
|
|
1241
|
+
Fr.call(e)
|
|
1242
1242
|
);
|
|
1243
1243
|
}
|
|
1244
1244
|
// @__NO_SIDE_EFFECTS__
|
|
1245
|
-
function
|
|
1245
|
+
function De(e) {
|
|
1246
1246
|
return (
|
|
1247
1247
|
/** @type {TemplateNode | null} */
|
|
1248
|
-
|
|
1248
|
+
jr.call(e)
|
|
1249
1249
|
);
|
|
1250
1250
|
}
|
|
1251
|
-
function
|
|
1252
|
-
if (!
|
|
1253
|
-
return /* @__PURE__ */
|
|
1254
|
-
var n = /* @__PURE__ */
|
|
1251
|
+
function Ae(e, t) {
|
|
1252
|
+
if (!I)
|
|
1253
|
+
return /* @__PURE__ */ ht(e);
|
|
1254
|
+
var n = /* @__PURE__ */ ht(k);
|
|
1255
1255
|
if (n === null)
|
|
1256
|
-
n =
|
|
1257
|
-
else if (t && n.nodeType !==
|
|
1258
|
-
var r =
|
|
1259
|
-
return n?.before(r),
|
|
1256
|
+
n = k.appendChild(Xe());
|
|
1257
|
+
else if (t && n.nodeType !== Rn) {
|
|
1258
|
+
var r = Xe();
|
|
1259
|
+
return n?.before(r), fe(r), r;
|
|
1260
1260
|
}
|
|
1261
|
-
return t &&
|
|
1261
|
+
return t && zr(
|
|
1262
1262
|
/** @type {Text} */
|
|
1263
1263
|
n
|
|
1264
|
-
),
|
|
1264
|
+
), fe(n), n;
|
|
1265
1265
|
}
|
|
1266
|
-
function
|
|
1267
|
-
let r =
|
|
1266
|
+
function Ke(e, t = 1, n = !1) {
|
|
1267
|
+
let r = I ? k : e;
|
|
1268
1268
|
for (var s; t--; )
|
|
1269
1269
|
s = r, r = /** @type {TemplateNode} */
|
|
1270
|
-
/* @__PURE__ */
|
|
1271
|
-
if (!
|
|
1270
|
+
/* @__PURE__ */ De(r);
|
|
1271
|
+
if (!I)
|
|
1272
1272
|
return r;
|
|
1273
1273
|
if (n) {
|
|
1274
|
-
if (r?.nodeType !==
|
|
1275
|
-
var i =
|
|
1276
|
-
return r === null ? s?.after(i) : r.before(i),
|
|
1274
|
+
if (r?.nodeType !== Rn) {
|
|
1275
|
+
var i = Xe();
|
|
1276
|
+
return r === null ? s?.after(i) : r.before(i), fe(i), i;
|
|
1277
1277
|
}
|
|
1278
|
-
|
|
1278
|
+
zr(
|
|
1279
1279
|
/** @type {Text} */
|
|
1280
1280
|
r
|
|
1281
1281
|
);
|
|
1282
1282
|
}
|
|
1283
|
-
return
|
|
1283
|
+
return fe(r), r;
|
|
1284
1284
|
}
|
|
1285
|
-
function
|
|
1285
|
+
function _i(e) {
|
|
1286
1286
|
e.textContent = "";
|
|
1287
1287
|
}
|
|
1288
|
-
function
|
|
1288
|
+
function pi() {
|
|
1289
1289
|
return !1;
|
|
1290
1290
|
}
|
|
1291
|
-
function
|
|
1291
|
+
function Hr(e, t, n) {
|
|
1292
1292
|
return (
|
|
1293
1293
|
/** @type {T extends keyof HTMLElementTagNameMap ? HTMLElementTagNameMap[T] : Element} */
|
|
1294
|
-
document.createElementNS(
|
|
1294
|
+
document.createElementNS(fr, e, void 0)
|
|
1295
1295
|
);
|
|
1296
1296
|
}
|
|
1297
|
-
function
|
|
1297
|
+
function zr(e) {
|
|
1298
1298
|
if (
|
|
1299
1299
|
/** @type {string} */
|
|
1300
1300
|
e.nodeValue.length < 65536
|
|
1301
1301
|
)
|
|
1302
1302
|
return;
|
|
1303
1303
|
let t = e.nextSibling;
|
|
1304
|
-
for (; t !== null && t.nodeType ===
|
|
1304
|
+
for (; t !== null && t.nodeType === Rn; )
|
|
1305
1305
|
t.remove(), e.nodeValue += /** @type {string} */
|
|
1306
1306
|
t.nodeValue, t = e.nextSibling;
|
|
1307
1307
|
}
|
|
1308
|
-
function
|
|
1309
|
-
var t = b, n =
|
|
1310
|
-
|
|
1308
|
+
function Vr(e) {
|
|
1309
|
+
var t = b, n = y;
|
|
1310
|
+
Z(null), ce(null);
|
|
1311
1311
|
try {
|
|
1312
1312
|
return e();
|
|
1313
1313
|
} finally {
|
|
1314
|
-
|
|
1314
|
+
Z(t), ce(n);
|
|
1315
1315
|
}
|
|
1316
1316
|
}
|
|
1317
|
-
function
|
|
1318
|
-
|
|
1317
|
+
function gi(e) {
|
|
1318
|
+
y === null && (b === null && Hs(), js()), Ne && Fs();
|
|
1319
1319
|
}
|
|
1320
|
-
function
|
|
1320
|
+
function mi(e, t) {
|
|
1321
1321
|
var n = t.last;
|
|
1322
1322
|
n === null ? t.last = t.first = e : (n.next = e, e.prev = n, t.last = e);
|
|
1323
1323
|
}
|
|
1324
|
-
function
|
|
1325
|
-
var r =
|
|
1326
|
-
r !== null && (r.f &
|
|
1324
|
+
function xe(e, t, n) {
|
|
1325
|
+
var r = y;
|
|
1326
|
+
r !== null && (r.f & ae) !== 0 && (e |= ae);
|
|
1327
1327
|
var s = {
|
|
1328
|
-
ctx:
|
|
1328
|
+
ctx: Y,
|
|
1329
1329
|
deps: null,
|
|
1330
1330
|
nodes: null,
|
|
1331
|
-
f: e |
|
|
1331
|
+
f: e | P | K,
|
|
1332
1332
|
first: null,
|
|
1333
1333
|
fn: t,
|
|
1334
1334
|
last: null,
|
|
@@ -1342,14 +1342,14 @@ function ye(e, t, n) {
|
|
|
1342
1342
|
};
|
|
1343
1343
|
if (n)
|
|
1344
1344
|
try {
|
|
1345
|
-
|
|
1346
|
-
} catch (
|
|
1347
|
-
throw
|
|
1345
|
+
vt(s);
|
|
1346
|
+
} catch (u) {
|
|
1347
|
+
throw V(s), u;
|
|
1348
1348
|
}
|
|
1349
|
-
else t !== null &&
|
|
1349
|
+
else t !== null && te(s);
|
|
1350
1350
|
var i = s;
|
|
1351
1351
|
if (n && i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && // either `null`, or a singular child
|
|
1352
|
-
(i.f &
|
|
1352
|
+
(i.f & Je) === 0 && (i = i.first, (e & Se) !== 0 && (e & ft) !== 0 && i !== null && (i.f |= ft)), i !== null && (i.parent = r, r !== null && mi(i, r), b !== null && (b.f & L) !== 0 && (e & Oe) === 0)) {
|
|
1353
1353
|
var o = (
|
|
1354
1354
|
/** @type {Derived} */
|
|
1355
1355
|
b
|
|
@@ -1358,157 +1358,157 @@ function ye(e, t, n) {
|
|
|
1358
1358
|
}
|
|
1359
1359
|
return s;
|
|
1360
1360
|
}
|
|
1361
|
-
function
|
|
1362
|
-
return b !== null && !
|
|
1361
|
+
function Pn() {
|
|
1362
|
+
return b !== null && !ne;
|
|
1363
1363
|
}
|
|
1364
|
-
function
|
|
1365
|
-
const t =
|
|
1366
|
-
return M(t,
|
|
1364
|
+
function wi(e) {
|
|
1365
|
+
const t = xe(Xt, null, !1);
|
|
1366
|
+
return M(t, C), t.teardown = e, t;
|
|
1367
1367
|
}
|
|
1368
|
-
function
|
|
1369
|
-
|
|
1368
|
+
function kn(e) {
|
|
1369
|
+
gi();
|
|
1370
1370
|
var t = (
|
|
1371
1371
|
/** @type {Effect} */
|
|
1372
|
-
|
|
1373
|
-
), n = !b && (t &
|
|
1372
|
+
y.f
|
|
1373
|
+
), n = !b && (t & he) !== 0 && (t & _t) === 0;
|
|
1374
1374
|
if (n) {
|
|
1375
1375
|
var r = (
|
|
1376
1376
|
/** @type {ComponentContext} */
|
|
1377
|
-
|
|
1377
|
+
Y
|
|
1378
1378
|
);
|
|
1379
1379
|
(r.e ?? (r.e = [])).push(e);
|
|
1380
1380
|
} else
|
|
1381
|
-
return
|
|
1381
|
+
return Yr(e);
|
|
1382
1382
|
}
|
|
1383
|
-
function
|
|
1384
|
-
return
|
|
1383
|
+
function Yr(e) {
|
|
1384
|
+
return xe(Bt | Ds, e, !1);
|
|
1385
1385
|
}
|
|
1386
|
-
function
|
|
1387
|
-
|
|
1388
|
-
const t =
|
|
1386
|
+
function bi(e) {
|
|
1387
|
+
Ee.ensure();
|
|
1388
|
+
const t = xe(Oe | Je, e, !0);
|
|
1389
1389
|
return () => {
|
|
1390
|
-
|
|
1390
|
+
V(t);
|
|
1391
1391
|
};
|
|
1392
1392
|
}
|
|
1393
|
-
function
|
|
1394
|
-
|
|
1395
|
-
const t =
|
|
1393
|
+
function yi(e) {
|
|
1394
|
+
Ee.ensure();
|
|
1395
|
+
const t = xe(Oe | Je, e, !0);
|
|
1396
1396
|
return (n = {}) => new Promise((r) => {
|
|
1397
|
-
n.outro ?
|
|
1398
|
-
|
|
1399
|
-
}) : (
|
|
1397
|
+
n.outro ? bt(t, () => {
|
|
1398
|
+
V(t), r(void 0);
|
|
1399
|
+
}) : (V(t), r(void 0));
|
|
1400
1400
|
});
|
|
1401
1401
|
}
|
|
1402
|
-
function
|
|
1403
|
-
return
|
|
1402
|
+
function $i(e) {
|
|
1403
|
+
return xe(Cn | Je, e, !0);
|
|
1404
1404
|
}
|
|
1405
|
-
function
|
|
1406
|
-
return
|
|
1405
|
+
function Br(e, t = 0) {
|
|
1406
|
+
return xe(Xt | t, e, !0);
|
|
1407
1407
|
}
|
|
1408
|
-
function
|
|
1409
|
-
|
|
1410
|
-
|
|
1408
|
+
function hn(e, t = [], n = [], r = []) {
|
|
1409
|
+
oi(r, t, n, (s) => {
|
|
1410
|
+
xe(Xt, () => e(...s.map(m)), !0);
|
|
1411
1411
|
});
|
|
1412
1412
|
}
|
|
1413
|
-
function
|
|
1414
|
-
var n =
|
|
1413
|
+
function Wr(e, t = 0) {
|
|
1414
|
+
var n = xe(Se | t, e, !0);
|
|
1415
1415
|
return n;
|
|
1416
1416
|
}
|
|
1417
|
-
function
|
|
1418
|
-
return
|
|
1417
|
+
function Me(e) {
|
|
1418
|
+
return xe(he | Je, e, !0);
|
|
1419
1419
|
}
|
|
1420
|
-
function
|
|
1420
|
+
function qr(e) {
|
|
1421
1421
|
var t = e.teardown;
|
|
1422
1422
|
if (t !== null) {
|
|
1423
|
-
const n =
|
|
1424
|
-
|
|
1423
|
+
const n = Ne, r = b;
|
|
1424
|
+
nr(!0), Z(null);
|
|
1425
1425
|
try {
|
|
1426
1426
|
t.call(null);
|
|
1427
1427
|
} finally {
|
|
1428
|
-
|
|
1428
|
+
nr(n), Z(r);
|
|
1429
1429
|
}
|
|
1430
1430
|
}
|
|
1431
1431
|
}
|
|
1432
|
-
function
|
|
1432
|
+
function Fn(e, t = !1) {
|
|
1433
1433
|
var n = e.first;
|
|
1434
1434
|
for (e.first = e.last = null; n !== null; ) {
|
|
1435
1435
|
const s = n.ac;
|
|
1436
|
-
s !== null &&
|
|
1437
|
-
s.abort(
|
|
1436
|
+
s !== null && Vr(() => {
|
|
1437
|
+
s.abort(Pe);
|
|
1438
1438
|
});
|
|
1439
1439
|
var r = n.next;
|
|
1440
|
-
(n.f &
|
|
1440
|
+
(n.f & Oe) !== 0 ? n.parent = null : V(n, t), n = r;
|
|
1441
1441
|
}
|
|
1442
1442
|
}
|
|
1443
|
-
function
|
|
1443
|
+
function Ei(e) {
|
|
1444
1444
|
for (var t = e.first; t !== null; ) {
|
|
1445
1445
|
var n = t.next;
|
|
1446
|
-
(t.f &
|
|
1446
|
+
(t.f & he) === 0 && V(t), t = n;
|
|
1447
1447
|
}
|
|
1448
1448
|
}
|
|
1449
|
-
function
|
|
1449
|
+
function V(e, t = !0) {
|
|
1450
1450
|
var n = !1;
|
|
1451
|
-
(t || (e.f &
|
|
1451
|
+
(t || (e.f & _r) !== 0) && e.nodes !== null && e.nodes.end !== null && (Si(
|
|
1452
1452
|
e.nodes.start,
|
|
1453
1453
|
/** @type {TemplateNode} */
|
|
1454
1454
|
e.nodes.end
|
|
1455
|
-
), n = !0),
|
|
1455
|
+
), n = !0), Fn(e, t && !n), yt(e, 0), M(e, $e);
|
|
1456
1456
|
var r = e.nodes && e.nodes.t;
|
|
1457
1457
|
if (r !== null)
|
|
1458
1458
|
for (const i of r)
|
|
1459
1459
|
i.stop();
|
|
1460
|
-
|
|
1460
|
+
qr(e);
|
|
1461
1461
|
var s = e.parent;
|
|
1462
|
-
s !== null && s.first !== null &&
|
|
1462
|
+
s !== null && s.first !== null && Ur(e), e.next = e.prev = e.teardown = e.ctx = e.deps = e.fn = e.nodes = e.ac = null;
|
|
1463
1463
|
}
|
|
1464
|
-
function
|
|
1464
|
+
function Si(e, t) {
|
|
1465
1465
|
for (; e !== null; ) {
|
|
1466
|
-
var n = e === t ? null : /* @__PURE__ */
|
|
1466
|
+
var n = e === t ? null : /* @__PURE__ */ De(e);
|
|
1467
1467
|
e.remove(), e = n;
|
|
1468
1468
|
}
|
|
1469
1469
|
}
|
|
1470
|
-
function
|
|
1470
|
+
function Ur(e) {
|
|
1471
1471
|
var t = e.parent, n = e.prev, r = e.next;
|
|
1472
1472
|
n !== null && (n.next = r), r !== null && (r.prev = n), t !== null && (t.first === e && (t.first = r), t.last === e && (t.last = n));
|
|
1473
1473
|
}
|
|
1474
|
-
function
|
|
1474
|
+
function bt(e, t, n = !0) {
|
|
1475
1475
|
var r = [];
|
|
1476
|
-
|
|
1476
|
+
Xr(e, r, !0);
|
|
1477
1477
|
var s = () => {
|
|
1478
|
-
n &&
|
|
1478
|
+
n && V(e), t && t();
|
|
1479
1479
|
}, i = r.length;
|
|
1480
1480
|
if (i > 0) {
|
|
1481
1481
|
var o = () => --i || s();
|
|
1482
|
-
for (var
|
|
1483
|
-
|
|
1482
|
+
for (var u of r)
|
|
1483
|
+
u.out(o);
|
|
1484
1484
|
} else
|
|
1485
1485
|
s();
|
|
1486
1486
|
}
|
|
1487
|
-
function
|
|
1488
|
-
if ((e.f &
|
|
1489
|
-
e.f ^=
|
|
1487
|
+
function Xr(e, t, n) {
|
|
1488
|
+
if ((e.f & ae) === 0) {
|
|
1489
|
+
e.f ^= ae;
|
|
1490
1490
|
var r = e.nodes && e.nodes.t;
|
|
1491
1491
|
if (r !== null)
|
|
1492
|
-
for (const
|
|
1493
|
-
(
|
|
1492
|
+
for (const u of r)
|
|
1493
|
+
(u.is_global || n) && t.push(u);
|
|
1494
1494
|
for (var s = e.first; s !== null; ) {
|
|
1495
1495
|
var i = s.next, o = (s.f & ft) !== 0 || // If this is a branch effect without a block effect parent,
|
|
1496
1496
|
// it means the parent block effect was pruned. In that case,
|
|
1497
1497
|
// transparency information was transferred to the branch effect.
|
|
1498
|
-
(s.f &
|
|
1499
|
-
|
|
1498
|
+
(s.f & he) !== 0 && (e.f & Se) !== 0;
|
|
1499
|
+
Xr(s, t, o ? n : !1), s = i;
|
|
1500
1500
|
}
|
|
1501
1501
|
}
|
|
1502
1502
|
}
|
|
1503
|
-
function
|
|
1504
|
-
|
|
1503
|
+
function xi(e) {
|
|
1504
|
+
Jr(e, !0);
|
|
1505
1505
|
}
|
|
1506
|
-
function
|
|
1507
|
-
if ((e.f &
|
|
1508
|
-
e.f ^=
|
|
1506
|
+
function Jr(e, t) {
|
|
1507
|
+
if ((e.f & ae) !== 0) {
|
|
1508
|
+
e.f ^= ae, (e.f & C) === 0 && (M(e, P), te(e));
|
|
1509
1509
|
for (var n = e.first; n !== null; ) {
|
|
1510
|
-
var r = n.next, s = (n.f & ft) !== 0 || (n.f &
|
|
1511
|
-
|
|
1510
|
+
var r = n.next, s = (n.f & ft) !== 0 || (n.f & he) !== 0;
|
|
1511
|
+
Jr(n, s ? t : !1), n = r;
|
|
1512
1512
|
}
|
|
1513
1513
|
var i = e.nodes && e.nodes.t;
|
|
1514
1514
|
if (i !== null)
|
|
@@ -1516,252 +1516,252 @@ function Fr(e, t) {
|
|
|
1516
1516
|
(o.is_global || t) && o.in();
|
|
1517
1517
|
}
|
|
1518
1518
|
}
|
|
1519
|
-
function
|
|
1519
|
+
function Kr(e, t) {
|
|
1520
1520
|
if (e.nodes)
|
|
1521
1521
|
for (var n = e.nodes.start, r = e.nodes.end; n !== null; ) {
|
|
1522
|
-
var s = n === r ? null : /* @__PURE__ */
|
|
1522
|
+
var s = n === r ? null : /* @__PURE__ */ De(n);
|
|
1523
1523
|
t.append(n), n = s;
|
|
1524
1524
|
}
|
|
1525
1525
|
}
|
|
1526
|
-
let
|
|
1527
|
-
function
|
|
1528
|
-
|
|
1526
|
+
let Ht = !1, Ne = !1;
|
|
1527
|
+
function nr(e) {
|
|
1528
|
+
Ne = e;
|
|
1529
1529
|
}
|
|
1530
|
-
let b = null,
|
|
1531
|
-
function
|
|
1530
|
+
let b = null, ne = !1;
|
|
1531
|
+
function Z(e) {
|
|
1532
1532
|
b = e;
|
|
1533
1533
|
}
|
|
1534
|
-
let
|
|
1535
|
-
function
|
|
1536
|
-
|
|
1534
|
+
let y = null;
|
|
1535
|
+
function ce(e) {
|
|
1536
|
+
y = e;
|
|
1537
1537
|
}
|
|
1538
|
-
let
|
|
1539
|
-
function
|
|
1540
|
-
b !== null && (
|
|
1538
|
+
let G = null;
|
|
1539
|
+
function Gr(e) {
|
|
1540
|
+
b !== null && (G === null ? G = [e] : G.push(e));
|
|
1541
1541
|
}
|
|
1542
|
-
let
|
|
1543
|
-
function
|
|
1544
|
-
|
|
1542
|
+
let z = null, B = 0, U = null;
|
|
1543
|
+
function ki(e) {
|
|
1544
|
+
U = e;
|
|
1545
1545
|
}
|
|
1546
|
-
let
|
|
1547
|
-
function
|
|
1548
|
-
|
|
1546
|
+
let Zr = 1, je = 0, qe = je;
|
|
1547
|
+
function rr(e) {
|
|
1548
|
+
qe = e;
|
|
1549
1549
|
}
|
|
1550
|
-
function
|
|
1551
|
-
return ++
|
|
1550
|
+
function Qr() {
|
|
1551
|
+
return ++Zr;
|
|
1552
1552
|
}
|
|
1553
|
-
function
|
|
1553
|
+
function Mt(e) {
|
|
1554
1554
|
var t = e.f;
|
|
1555
|
-
if ((t &
|
|
1555
|
+
if ((t & P) !== 0)
|
|
1556
1556
|
return !0;
|
|
1557
|
-
if (t &
|
|
1557
|
+
if (t & L && (e.f &= ~Ue), (t & re) !== 0) {
|
|
1558
1558
|
for (var n = (
|
|
1559
1559
|
/** @type {Value[]} */
|
|
1560
1560
|
e.deps
|
|
1561
1561
|
), r = n.length, s = 0; s < r; s++) {
|
|
1562
1562
|
var i = n[s];
|
|
1563
|
-
if (
|
|
1563
|
+
if (Mt(
|
|
1564
1564
|
/** @type {Derived} */
|
|
1565
1565
|
i
|
|
1566
|
-
) &&
|
|
1566
|
+
) && Nr(
|
|
1567
1567
|
/** @type {Derived} */
|
|
1568
1568
|
i
|
|
1569
1569
|
), i.wv > e.wv)
|
|
1570
1570
|
return !0;
|
|
1571
1571
|
}
|
|
1572
|
-
(t &
|
|
1572
|
+
(t & K) !== 0 && // During time traveling we don't want to reset the status so that
|
|
1573
1573
|
// traversal of the graph in the other batches still happens
|
|
1574
|
-
|
|
1574
|
+
ee === null && M(e, C);
|
|
1575
1575
|
}
|
|
1576
1576
|
return !1;
|
|
1577
1577
|
}
|
|
1578
|
-
function
|
|
1578
|
+
function es(e, t, n = !0) {
|
|
1579
1579
|
var r = e.reactions;
|
|
1580
|
-
if (r !== null && !(
|
|
1580
|
+
if (r !== null && !(G !== null && at.call(G, e)))
|
|
1581
1581
|
for (var s = 0; s < r.length; s++) {
|
|
1582
1582
|
var i = r[s];
|
|
1583
|
-
(i.f &
|
|
1583
|
+
(i.f & L) !== 0 ? es(
|
|
1584
1584
|
/** @type {Derived} */
|
|
1585
1585
|
i,
|
|
1586
1586
|
t,
|
|
1587
1587
|
!1
|
|
1588
|
-
) : t === i && (n ? M(i,
|
|
1588
|
+
) : t === i && (n ? M(i, P) : (i.f & C) !== 0 && M(i, re), te(
|
|
1589
1589
|
/** @type {Effect} */
|
|
1590
1590
|
i
|
|
1591
1591
|
));
|
|
1592
1592
|
}
|
|
1593
1593
|
}
|
|
1594
|
-
function
|
|
1595
|
-
var
|
|
1596
|
-
var t =
|
|
1597
|
-
|
|
1598
|
-
null,
|
|
1599
|
-
e.ac.abort(
|
|
1594
|
+
function ts(e) {
|
|
1595
|
+
var T;
|
|
1596
|
+
var t = z, n = B, r = U, s = b, i = G, o = Y, u = ne, a = qe, f = e.f;
|
|
1597
|
+
z = /** @type {null | Value[]} */
|
|
1598
|
+
null, B = 0, U = null, b = (f & (he | Oe)) === 0 ? e : null, G = null, ct(e.ctx), ne = !1, qe = ++je, e.ac !== null && (Vr(() => {
|
|
1599
|
+
e.ac.abort(Pe);
|
|
1600
1600
|
}), e.ac = null);
|
|
1601
1601
|
try {
|
|
1602
|
-
e.f |=
|
|
1602
|
+
e.f |= gn;
|
|
1603
1603
|
var c = (
|
|
1604
1604
|
/** @type {Function} */
|
|
1605
1605
|
e.fn
|
|
1606
|
-
),
|
|
1607
|
-
e.f |=
|
|
1606
|
+
), v = c();
|
|
1607
|
+
e.f |= _t;
|
|
1608
1608
|
var d = e.deps, g = x?.is_fork;
|
|
1609
|
-
if (
|
|
1610
|
-
var
|
|
1611
|
-
if (g ||
|
|
1612
|
-
for (d.length =
|
|
1613
|
-
d[
|
|
1609
|
+
if (z !== null) {
|
|
1610
|
+
var _;
|
|
1611
|
+
if (g || yt(e, B), d !== null && B > 0)
|
|
1612
|
+
for (d.length = B + z.length, _ = 0; _ < z.length; _++)
|
|
1613
|
+
d[B + _] = z[_];
|
|
1614
1614
|
else
|
|
1615
|
-
e.deps = d =
|
|
1616
|
-
if (
|
|
1617
|
-
for (
|
|
1618
|
-
((
|
|
1619
|
-
} else !g && d !== null &&
|
|
1620
|
-
if (
|
|
1621
|
-
for (
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1615
|
+
e.deps = d = z;
|
|
1616
|
+
if (Pn() && (e.f & K) !== 0)
|
|
1617
|
+
for (_ = B; _ < d.length; _++)
|
|
1618
|
+
((T = d[_]).reactions ?? (T.reactions = [])).push(e);
|
|
1619
|
+
} else !g && d !== null && B < d.length && (yt(e, B), d.length = B);
|
|
1620
|
+
if (yr() && U !== null && !ne && d !== null && (e.f & (L | re | P)) === 0)
|
|
1621
|
+
for (_ = 0; _ < /** @type {Source[]} */
|
|
1622
|
+
U.length; _++)
|
|
1623
|
+
es(
|
|
1624
|
+
U[_],
|
|
1625
1625
|
/** @type {Effect} */
|
|
1626
1626
|
e
|
|
1627
1627
|
);
|
|
1628
1628
|
if (s !== null && s !== e) {
|
|
1629
|
-
if (
|
|
1630
|
-
for (let
|
|
1631
|
-
s.deps[
|
|
1629
|
+
if (je++, s.deps !== null)
|
|
1630
|
+
for (let E = 0; E < n; E += 1)
|
|
1631
|
+
s.deps[E].rv = je;
|
|
1632
1632
|
if (t !== null)
|
|
1633
|
-
for (const
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1633
|
+
for (const E of t)
|
|
1634
|
+
E.rv = je;
|
|
1635
|
+
U !== null && (r === null ? r = U : r.push(.../** @type {Source[]} */
|
|
1636
|
+
U));
|
|
1637
1637
|
}
|
|
1638
|
-
return (e.f &
|
|
1639
|
-
} catch (
|
|
1640
|
-
return
|
|
1638
|
+
return (e.f & Ce) !== 0 && (e.f ^= Ce), v;
|
|
1639
|
+
} catch (E) {
|
|
1640
|
+
return Er(E);
|
|
1641
1641
|
} finally {
|
|
1642
|
-
e.f ^=
|
|
1642
|
+
e.f ^= gn, z = t, B = n, U = r, b = s, G = i, ct(o), ne = u, qe = a;
|
|
1643
1643
|
}
|
|
1644
1644
|
}
|
|
1645
|
-
function
|
|
1645
|
+
function Ii(e, t) {
|
|
1646
1646
|
let n = t.reactions;
|
|
1647
1647
|
if (n !== null) {
|
|
1648
|
-
var r =
|
|
1648
|
+
var r = As.call(n, e);
|
|
1649
1649
|
if (r !== -1) {
|
|
1650
1650
|
var s = n.length - 1;
|
|
1651
1651
|
s === 0 ? n = t.reactions = null : (n[r] = n[s], n.pop());
|
|
1652
1652
|
}
|
|
1653
1653
|
}
|
|
1654
|
-
if (n === null && (t.f &
|
|
1654
|
+
if (n === null && (t.f & L) !== 0 && // Destroying a child effect while updating a parent effect can cause a dependency to appear
|
|
1655
1655
|
// to be unused, when in fact it is used by the currently-updating parent. Checking `new_deps`
|
|
1656
1656
|
// allows us to skip the expensive work of disconnecting and immediately reconnecting it
|
|
1657
|
-
(
|
|
1657
|
+
(z === null || !at.call(z, t))) {
|
|
1658
1658
|
var i = (
|
|
1659
1659
|
/** @type {Derived} */
|
|
1660
1660
|
t
|
|
1661
1661
|
);
|
|
1662
|
-
(i.f &
|
|
1662
|
+
(i.f & K) !== 0 && (i.f ^= K, i.f &= ~Ue), On(i), di(i), yt(i, 0);
|
|
1663
1663
|
}
|
|
1664
1664
|
}
|
|
1665
|
-
function
|
|
1665
|
+
function yt(e, t) {
|
|
1666
1666
|
var n = e.deps;
|
|
1667
1667
|
if (n !== null)
|
|
1668
1668
|
for (var r = t; r < n.length; r++)
|
|
1669
|
-
|
|
1669
|
+
Ii(e, n[r]);
|
|
1670
1670
|
}
|
|
1671
|
-
function
|
|
1671
|
+
function vt(e) {
|
|
1672
1672
|
var t = e.f;
|
|
1673
|
-
if ((t &
|
|
1674
|
-
M(e,
|
|
1675
|
-
var n =
|
|
1676
|
-
|
|
1673
|
+
if ((t & $e) === 0) {
|
|
1674
|
+
M(e, C);
|
|
1675
|
+
var n = y, r = Ht;
|
|
1676
|
+
y = e, Ht = !0;
|
|
1677
1677
|
try {
|
|
1678
|
-
(t & (
|
|
1679
|
-
var s =
|
|
1680
|
-
e.teardown = typeof s == "function" ? s : null, e.wv =
|
|
1678
|
+
(t & (Se | vr)) !== 0 ? Ei(e) : Fn(e), qr(e);
|
|
1679
|
+
var s = ts(e);
|
|
1680
|
+
e.teardown = typeof s == "function" ? s : null, e.wv = Zr;
|
|
1681
1681
|
var i;
|
|
1682
|
-
|
|
1682
|
+
_n && Zs && (e.f & P) !== 0 && e.deps;
|
|
1683
1683
|
} finally {
|
|
1684
|
-
|
|
1684
|
+
Ht = r, y = n;
|
|
1685
1685
|
}
|
|
1686
1686
|
}
|
|
1687
1687
|
}
|
|
1688
|
-
function
|
|
1689
|
-
var t = e.f, n = (t &
|
|
1690
|
-
if (b !== null && !
|
|
1691
|
-
var r =
|
|
1692
|
-
if (!r && (
|
|
1688
|
+
function m(e) {
|
|
1689
|
+
var t = e.f, n = (t & L) !== 0;
|
|
1690
|
+
if (b !== null && !ne) {
|
|
1691
|
+
var r = y !== null && (y.f & $e) !== 0;
|
|
1692
|
+
if (!r && (G === null || !at.call(G, e))) {
|
|
1693
1693
|
var s = b.deps;
|
|
1694
|
-
if ((b.f &
|
|
1695
|
-
e.rv <
|
|
1694
|
+
if ((b.f & gn) !== 0)
|
|
1695
|
+
e.rv < je && (e.rv = je, z === null && s !== null && s[B] === e ? B++ : z === null ? z = [e] : z.push(e));
|
|
1696
1696
|
else {
|
|
1697
1697
|
(b.deps ?? (b.deps = [])).push(e);
|
|
1698
1698
|
var i = e.reactions;
|
|
1699
|
-
i === null ? e.reactions = [b] :
|
|
1699
|
+
i === null ? e.reactions = [b] : at.call(i, b) || i.push(b);
|
|
1700
1700
|
}
|
|
1701
1701
|
}
|
|
1702
1702
|
}
|
|
1703
|
-
if (
|
|
1704
|
-
return
|
|
1703
|
+
if (Ne && Re.has(e))
|
|
1704
|
+
return Re.get(e);
|
|
1705
1705
|
if (n) {
|
|
1706
1706
|
var o = (
|
|
1707
1707
|
/** @type {Derived} */
|
|
1708
1708
|
e
|
|
1709
1709
|
);
|
|
1710
|
-
if (
|
|
1711
|
-
var
|
|
1712
|
-
return ((o.f &
|
|
1710
|
+
if (Ne) {
|
|
1711
|
+
var u = o.v;
|
|
1712
|
+
return ((o.f & C) === 0 && o.reactions !== null || rs(o)) && (u = Ln(o)), Re.set(o, u), u;
|
|
1713
1713
|
}
|
|
1714
|
-
var
|
|
1715
|
-
|
|
1714
|
+
var a = (o.f & K) === 0 && !ne && b !== null && (Ht || (b.f & K) !== 0), f = (o.f & _t) === 0;
|
|
1715
|
+
Mt(o) && (a && (o.f |= K), Nr(o)), a && !f && (Or(o), ns(o));
|
|
1716
1716
|
}
|
|
1717
|
-
if (
|
|
1718
|
-
return
|
|
1719
|
-
if ((e.f &
|
|
1717
|
+
if (ee?.has(e))
|
|
1718
|
+
return ee.get(e);
|
|
1719
|
+
if ((e.f & Ce) !== 0)
|
|
1720
1720
|
throw e.v;
|
|
1721
1721
|
return e.v;
|
|
1722
1722
|
}
|
|
1723
|
-
function
|
|
1724
|
-
if (e.f |=
|
|
1723
|
+
function ns(e) {
|
|
1724
|
+
if (e.f |= K, e.deps !== null)
|
|
1725
1725
|
for (const t of e.deps)
|
|
1726
|
-
(t.reactions ?? (t.reactions = [])).push(e), (t.f &
|
|
1726
|
+
(t.reactions ?? (t.reactions = [])).push(e), (t.f & L) !== 0 && (t.f & K) === 0 && (Or(
|
|
1727
1727
|
/** @type {Derived} */
|
|
1728
1728
|
t
|
|
1729
|
-
),
|
|
1729
|
+
), ns(
|
|
1730
1730
|
/** @type {Derived} */
|
|
1731
1731
|
t
|
|
1732
1732
|
));
|
|
1733
1733
|
}
|
|
1734
|
-
function
|
|
1735
|
-
if (e.v ===
|
|
1734
|
+
function rs(e) {
|
|
1735
|
+
if (e.v === O) return !0;
|
|
1736
1736
|
if (e.deps === null) return !1;
|
|
1737
1737
|
for (const t of e.deps)
|
|
1738
|
-
if (
|
|
1738
|
+
if (Re.has(t) || (t.f & L) !== 0 && rs(
|
|
1739
1739
|
/** @type {Derived} */
|
|
1740
1740
|
t
|
|
1741
1741
|
))
|
|
1742
1742
|
return !0;
|
|
1743
1743
|
return !1;
|
|
1744
1744
|
}
|
|
1745
|
-
function
|
|
1746
|
-
var t =
|
|
1745
|
+
function ss(e) {
|
|
1746
|
+
var t = ne;
|
|
1747
1747
|
try {
|
|
1748
|
-
return
|
|
1748
|
+
return ne = !0, e();
|
|
1749
1749
|
} finally {
|
|
1750
|
-
|
|
1750
|
+
ne = t;
|
|
1751
1751
|
}
|
|
1752
1752
|
}
|
|
1753
|
-
const
|
|
1754
|
-
function
|
|
1755
|
-
(t[
|
|
1753
|
+
const He = /* @__PURE__ */ Symbol("events"), is = /* @__PURE__ */ new Set(), In = /* @__PURE__ */ new Set();
|
|
1754
|
+
function Dt(e, t, n) {
|
|
1755
|
+
(t[He] ?? (t[He] = {}))[e] = n;
|
|
1756
1756
|
}
|
|
1757
|
-
function
|
|
1757
|
+
function Ai(e) {
|
|
1758
1758
|
for (var t = 0; t < e.length; t++)
|
|
1759
|
-
|
|
1760
|
-
for (var n of
|
|
1759
|
+
is.add(e[t]);
|
|
1760
|
+
for (var n of In)
|
|
1761
1761
|
n(e);
|
|
1762
1762
|
}
|
|
1763
|
-
let
|
|
1764
|
-
function
|
|
1763
|
+
let sr = null;
|
|
1764
|
+
function ir(e) {
|
|
1765
1765
|
var t = this, n = (
|
|
1766
1766
|
/** @type {Node} */
|
|
1767
1767
|
t.ownerDocument
|
|
@@ -1769,133 +1769,133 @@ function Jn(e) {
|
|
|
1769
1769
|
/** @type {null | Element} */
|
|
1770
1770
|
s[0] || e.target
|
|
1771
1771
|
);
|
|
1772
|
-
|
|
1773
|
-
var o = 0,
|
|
1774
|
-
if (
|
|
1775
|
-
var
|
|
1776
|
-
if (
|
|
1772
|
+
sr = e;
|
|
1773
|
+
var o = 0, u = sr === e && e[He];
|
|
1774
|
+
if (u) {
|
|
1775
|
+
var a = s.indexOf(u);
|
|
1776
|
+
if (a !== -1 && (t === document || t === /** @type {any} */
|
|
1777
1777
|
window)) {
|
|
1778
|
-
e[
|
|
1778
|
+
e[He] = t;
|
|
1779
1779
|
return;
|
|
1780
1780
|
}
|
|
1781
|
-
var
|
|
1782
|
-
if (
|
|
1781
|
+
var f = s.indexOf(t);
|
|
1782
|
+
if (f === -1)
|
|
1783
1783
|
return;
|
|
1784
|
-
|
|
1784
|
+
a <= f && (o = a);
|
|
1785
1785
|
}
|
|
1786
1786
|
if (i = /** @type {Element} */
|
|
1787
1787
|
s[o] || e.target, i !== t) {
|
|
1788
|
-
|
|
1788
|
+
Yt(e, "currentTarget", {
|
|
1789
1789
|
configurable: !0,
|
|
1790
1790
|
get() {
|
|
1791
1791
|
return i || n;
|
|
1792
1792
|
}
|
|
1793
1793
|
});
|
|
1794
|
-
var c = b,
|
|
1795
|
-
|
|
1794
|
+
var c = b, v = y;
|
|
1795
|
+
Z(null), ce(null);
|
|
1796
1796
|
try {
|
|
1797
1797
|
for (var d, g = []; i !== null; ) {
|
|
1798
|
-
var
|
|
1798
|
+
var _ = i.assignedSlot || i.parentNode || /** @type {any} */
|
|
1799
1799
|
i.host || null;
|
|
1800
1800
|
try {
|
|
1801
|
-
var
|
|
1802
|
-
|
|
1801
|
+
var T = i[He]?.[r];
|
|
1802
|
+
T != null && (!/** @type {any} */
|
|
1803
1803
|
i.disabled || // DOM could've been updated already by the time this is reached, so we check this as well
|
|
1804
1804
|
// -> the target could not have been disabled because it emits the event in the first place
|
|
1805
|
-
e.target === i) &&
|
|
1806
|
-
} catch (
|
|
1807
|
-
d ? g.push(
|
|
1805
|
+
e.target === i) && T.call(i, e);
|
|
1806
|
+
} catch (E) {
|
|
1807
|
+
d ? g.push(E) : d = E;
|
|
1808
1808
|
}
|
|
1809
|
-
if (e.cancelBubble ||
|
|
1809
|
+
if (e.cancelBubble || _ === t || _ === null)
|
|
1810
1810
|
break;
|
|
1811
|
-
i =
|
|
1811
|
+
i = _;
|
|
1812
1812
|
}
|
|
1813
1813
|
if (d) {
|
|
1814
|
-
for (let
|
|
1814
|
+
for (let E of g)
|
|
1815
1815
|
queueMicrotask(() => {
|
|
1816
|
-
throw
|
|
1816
|
+
throw E;
|
|
1817
1817
|
});
|
|
1818
1818
|
throw d;
|
|
1819
1819
|
}
|
|
1820
1820
|
} finally {
|
|
1821
|
-
e[
|
|
1821
|
+
e[He] = t, delete e.currentTarget, Z(c), ce(v);
|
|
1822
1822
|
}
|
|
1823
1823
|
}
|
|
1824
1824
|
}
|
|
1825
|
-
const
|
|
1825
|
+
const Mi = (
|
|
1826
1826
|
// We gotta write it like this because after downleveling the pure comment may end up in the wrong location
|
|
1827
1827
|
globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", {
|
|
1828
1828
|
/** @param {string} html */
|
|
1829
1829
|
createHTML: (e) => e
|
|
1830
1830
|
})
|
|
1831
1831
|
);
|
|
1832
|
-
function
|
|
1832
|
+
function Ti(e) {
|
|
1833
1833
|
return (
|
|
1834
1834
|
/** @type {string} */
|
|
1835
|
-
|
|
1835
|
+
Mi?.createHTML(e) ?? e
|
|
1836
1836
|
);
|
|
1837
1837
|
}
|
|
1838
|
-
function
|
|
1839
|
-
var n =
|
|
1840
|
-
return e = e.replaceAll("<!>", "<!---->"), n.innerHTML = t ?
|
|
1838
|
+
function os(e, t = !1) {
|
|
1839
|
+
var n = Hr("template");
|
|
1840
|
+
return e = e.replaceAll("<!>", "<!---->"), n.innerHTML = t ? Ti(e) : e, n.content;
|
|
1841
1841
|
}
|
|
1842
|
-
function
|
|
1842
|
+
function $t(e, t) {
|
|
1843
1843
|
var n = (
|
|
1844
1844
|
/** @type {Effect} */
|
|
1845
|
-
|
|
1845
|
+
y
|
|
1846
1846
|
);
|
|
1847
1847
|
n.nodes === null && (n.nodes = { start: e, end: t, a: null, t: null });
|
|
1848
1848
|
}
|
|
1849
1849
|
// @__NO_SIDE_EFFECTS__
|
|
1850
|
-
function
|
|
1851
|
-
var n = (t &
|
|
1850
|
+
function pt(e, t) {
|
|
1851
|
+
var n = (t & Is) !== 0, r, s = !e.startsWith("<!>");
|
|
1852
1852
|
return () => {
|
|
1853
|
-
if (
|
|
1854
|
-
return
|
|
1855
|
-
r === void 0 && (r =
|
|
1856
|
-
/* @__PURE__ */
|
|
1853
|
+
if (I)
|
|
1854
|
+
return $t(k, null), k;
|
|
1855
|
+
r === void 0 && (r = os(s ? e : "<!>" + e, !0), r = /** @type {TemplateNode} */
|
|
1856
|
+
/* @__PURE__ */ ht(r));
|
|
1857
1857
|
var i = (
|
|
1858
1858
|
/** @type {TemplateNode} */
|
|
1859
|
-
n ||
|
|
1859
|
+
n || Pr ? document.importNode(r, !0) : r.cloneNode(!0)
|
|
1860
1860
|
);
|
|
1861
|
-
return
|
|
1861
|
+
return $t(i, i), i;
|
|
1862
1862
|
};
|
|
1863
1863
|
}
|
|
1864
1864
|
// @__NO_SIDE_EFFECTS__
|
|
1865
|
-
function
|
|
1865
|
+
function Ci(e, t, n = "svg") {
|
|
1866
1866
|
var r = !e.startsWith("<!>"), s = `<${n}>${r ? e : "<!>" + e}</${n}>`, i;
|
|
1867
1867
|
return () => {
|
|
1868
|
-
if (
|
|
1869
|
-
return
|
|
1868
|
+
if (I)
|
|
1869
|
+
return $t(k, null), k;
|
|
1870
1870
|
if (!i) {
|
|
1871
1871
|
var o = (
|
|
1872
1872
|
/** @type {DocumentFragment} */
|
|
1873
|
-
|
|
1874
|
-
),
|
|
1873
|
+
os(s, !0)
|
|
1874
|
+
), u = (
|
|
1875
1875
|
/** @type {Element} */
|
|
1876
|
-
/* @__PURE__ */
|
|
1876
|
+
/* @__PURE__ */ ht(o)
|
|
1877
1877
|
);
|
|
1878
1878
|
i = /** @type {Element} */
|
|
1879
|
-
/* @__PURE__ */
|
|
1879
|
+
/* @__PURE__ */ ht(u);
|
|
1880
1880
|
}
|
|
1881
|
-
var
|
|
1881
|
+
var a = (
|
|
1882
1882
|
/** @type {TemplateNode} */
|
|
1883
1883
|
i.cloneNode(!0)
|
|
1884
1884
|
);
|
|
1885
|
-
return
|
|
1885
|
+
return $t(a, a), a;
|
|
1886
1886
|
};
|
|
1887
1887
|
}
|
|
1888
1888
|
// @__NO_SIDE_EFFECTS__
|
|
1889
|
-
function
|
|
1890
|
-
return /* @__PURE__ */
|
|
1889
|
+
function ls(e, t) {
|
|
1890
|
+
return /* @__PURE__ */ Ci(e, t, "svg");
|
|
1891
1891
|
}
|
|
1892
|
-
function
|
|
1893
|
-
if (
|
|
1892
|
+
function _e(e, t) {
|
|
1893
|
+
if (I) {
|
|
1894
1894
|
var n = (
|
|
1895
1895
|
/** @type {Effect & { nodes: EffectNodes }} */
|
|
1896
|
-
|
|
1896
|
+
y
|
|
1897
1897
|
);
|
|
1898
|
-
((n.f &
|
|
1898
|
+
((n.f & _t) === 0 || n.nodes.end === null) && (n.nodes.end = k), Nn();
|
|
1899
1899
|
return;
|
|
1900
1900
|
}
|
|
1901
1901
|
e !== null && e.before(
|
|
@@ -1903,118 +1903,118 @@ function ke(e, t) {
|
|
|
1903
1903
|
t
|
|
1904
1904
|
);
|
|
1905
1905
|
}
|
|
1906
|
-
const
|
|
1907
|
-
function
|
|
1908
|
-
return
|
|
1906
|
+
const Ri = ["touchstart", "touchmove"];
|
|
1907
|
+
function Ni(e) {
|
|
1908
|
+
return Ri.includes(e);
|
|
1909
1909
|
}
|
|
1910
|
-
function
|
|
1910
|
+
function Oi(e, t) {
|
|
1911
1911
|
var n = t == null ? "" : typeof t == "object" ? t + "" : t;
|
|
1912
1912
|
n !== (e.__t ?? (e.__t = e.nodeValue)) && (e.__t = n, e.nodeValue = n + "");
|
|
1913
1913
|
}
|
|
1914
|
-
function
|
|
1915
|
-
return
|
|
1914
|
+
function us(e, t) {
|
|
1915
|
+
return as(e, t);
|
|
1916
1916
|
}
|
|
1917
|
-
function
|
|
1918
|
-
|
|
1919
|
-
const n = t.target, r =
|
|
1917
|
+
function Di(e, t) {
|
|
1918
|
+
xn(), t.intro = t.intro ?? !1;
|
|
1919
|
+
const n = t.target, r = I, s = k;
|
|
1920
1920
|
try {
|
|
1921
|
-
for (var i = /* @__PURE__ */
|
|
1922
|
-
i.data !==
|
|
1923
|
-
i = /* @__PURE__ */
|
|
1921
|
+
for (var i = /* @__PURE__ */ ht(n); i && (i.nodeType !== Jt || /** @type {Comment} */
|
|
1922
|
+
i.data !== Mn); )
|
|
1923
|
+
i = /* @__PURE__ */ De(i);
|
|
1924
1924
|
if (!i)
|
|
1925
|
-
throw
|
|
1926
|
-
|
|
1925
|
+
throw ut;
|
|
1926
|
+
Ge(!0), fe(
|
|
1927
1927
|
/** @type {Comment} */
|
|
1928
1928
|
i
|
|
1929
1929
|
);
|
|
1930
|
-
const o =
|
|
1931
|
-
return
|
|
1930
|
+
const o = as(e, { ...t, anchor: i });
|
|
1931
|
+
return Ge(!1), /** @type {Exports} */
|
|
1932
1932
|
o;
|
|
1933
1933
|
} catch (o) {
|
|
1934
1934
|
if (o instanceof Error && o.message.split(`
|
|
1935
|
-
`).some((
|
|
1935
|
+
`).some((u) => u.startsWith("https://svelte.dev/e/")))
|
|
1936
1936
|
throw o;
|
|
1937
|
-
return o !==
|
|
1937
|
+
return o !== ut && console.warn("Failed to hydrate: ", o), t.recover === !1 && Vs(), xn(), _i(n), Ge(!1), us(e, t);
|
|
1938
1938
|
} finally {
|
|
1939
|
-
|
|
1939
|
+
Ge(r), fe(s);
|
|
1940
1940
|
}
|
|
1941
1941
|
}
|
|
1942
|
-
const
|
|
1943
|
-
function
|
|
1944
|
-
|
|
1945
|
-
var
|
|
1946
|
-
var
|
|
1947
|
-
|
|
1942
|
+
const Lt = /* @__PURE__ */ new Map();
|
|
1943
|
+
function as(e, { target: t, anchor: n, props: r = {}, events: s, context: i, intro: o = !0 }) {
|
|
1944
|
+
xn();
|
|
1945
|
+
var u = void 0, a = yi(() => {
|
|
1946
|
+
var f = n ?? t.appendChild(Xe());
|
|
1947
|
+
si(
|
|
1948
1948
|
/** @type {TemplateNode} */
|
|
1949
|
-
|
|
1949
|
+
f,
|
|
1950
1950
|
{
|
|
1951
1951
|
pending: () => {
|
|
1952
1952
|
}
|
|
1953
1953
|
},
|
|
1954
1954
|
(d) => {
|
|
1955
|
-
|
|
1955
|
+
wr({});
|
|
1956
1956
|
var g = (
|
|
1957
1957
|
/** @type {ComponentContext} */
|
|
1958
|
-
|
|
1958
|
+
Y
|
|
1959
1959
|
);
|
|
1960
|
-
if (i && (g.c = i), s && (r.$$events = s),
|
|
1960
|
+
if (i && (g.c = i), s && (r.$$events = s), I && $t(
|
|
1961
1961
|
/** @type {TemplateNode} */
|
|
1962
1962
|
d,
|
|
1963
1963
|
null
|
|
1964
|
-
),
|
|
1965
|
-
|
|
1966
|
-
throw
|
|
1967
|
-
|
|
1964
|
+
), u = e(d, r) || {}, I && (y.nodes.end = k, k === null || k.nodeType !== Jt || /** @type {Comment} */
|
|
1965
|
+
k.data !== ar))
|
|
1966
|
+
throw Kt(), ut;
|
|
1967
|
+
br();
|
|
1968
1968
|
}
|
|
1969
1969
|
);
|
|
1970
|
-
var c = /* @__PURE__ */ new Set(),
|
|
1970
|
+
var c = /* @__PURE__ */ new Set(), v = (d) => {
|
|
1971
1971
|
for (var g = 0; g < d.length; g++) {
|
|
1972
|
-
var
|
|
1973
|
-
if (!c.has(
|
|
1974
|
-
c.add(
|
|
1975
|
-
var
|
|
1976
|
-
for (const
|
|
1977
|
-
var
|
|
1978
|
-
|
|
1979
|
-
var
|
|
1980
|
-
|
|
1972
|
+
var _ = d[g];
|
|
1973
|
+
if (!c.has(_)) {
|
|
1974
|
+
c.add(_);
|
|
1975
|
+
var T = Ni(_);
|
|
1976
|
+
for (const se of [t, document]) {
|
|
1977
|
+
var E = Lt.get(se);
|
|
1978
|
+
E === void 0 && (E = /* @__PURE__ */ new Map(), Lt.set(se, E));
|
|
1979
|
+
var ke = E.get(_);
|
|
1980
|
+
ke === void 0 ? (se.addEventListener(_, ir, { passive: T }), E.set(_, 1)) : E.set(_, ke + 1);
|
|
1981
1981
|
}
|
|
1982
1982
|
}
|
|
1983
1983
|
}
|
|
1984
1984
|
};
|
|
1985
|
-
return
|
|
1985
|
+
return v(Ms(is)), In.add(v), () => {
|
|
1986
1986
|
for (var d of c)
|
|
1987
|
-
for (const
|
|
1987
|
+
for (const T of [t, document]) {
|
|
1988
1988
|
var g = (
|
|
1989
1989
|
/** @type {Map<string, number>} */
|
|
1990
|
-
|
|
1991
|
-
),
|
|
1990
|
+
Lt.get(T)
|
|
1991
|
+
), _ = (
|
|
1992
1992
|
/** @type {number} */
|
|
1993
1993
|
g.get(d)
|
|
1994
1994
|
);
|
|
1995
|
-
--
|
|
1995
|
+
--_ == 0 ? (T.removeEventListener(d, ir), g.delete(d), g.size === 0 && Lt.delete(T)) : g.set(d, _);
|
|
1996
1996
|
}
|
|
1997
|
-
|
|
1997
|
+
In.delete(v), f !== n && f.parentNode?.removeChild(f);
|
|
1998
1998
|
};
|
|
1999
1999
|
});
|
|
2000
|
-
return
|
|
2000
|
+
return An.set(u, a), u;
|
|
2001
2001
|
}
|
|
2002
|
-
let
|
|
2003
|
-
function
|
|
2004
|
-
const n =
|
|
2005
|
-
return n ? (
|
|
2002
|
+
let An = /* @__PURE__ */ new WeakMap();
|
|
2003
|
+
function Li(e, t) {
|
|
2004
|
+
const n = An.get(e);
|
|
2005
|
+
return n ? (An.delete(e), n(t)) : Promise.resolve();
|
|
2006
2006
|
}
|
|
2007
|
-
var
|
|
2008
|
-
class
|
|
2007
|
+
var Q, ue, q, We, kt, It, Ut;
|
|
2008
|
+
class Pi {
|
|
2009
2009
|
/**
|
|
2010
2010
|
* @param {TemplateNode} anchor
|
|
2011
2011
|
* @param {boolean} transition
|
|
2012
2012
|
*/
|
|
2013
2013
|
constructor(t, n = !0) {
|
|
2014
2014
|
/** @type {TemplateNode} */
|
|
2015
|
-
|
|
2015
|
+
A(this, "anchor");
|
|
2016
2016
|
/** @type {Map<Batch, Key>} */
|
|
2017
|
-
|
|
2017
|
+
w(this, Q, /* @__PURE__ */ new Map());
|
|
2018
2018
|
/**
|
|
2019
2019
|
* Map of keys to effects that are currently rendered in the DOM.
|
|
2020
2020
|
* These effects are visible and actively part of the document tree.
|
|
@@ -2029,69 +2029,69 @@ class ki {
|
|
|
2029
2029
|
* Can result in the entries `true->Effect` and `false->Effect`
|
|
2030
2030
|
* @type {Map<Key, Effect>}
|
|
2031
2031
|
*/
|
|
2032
|
-
|
|
2032
|
+
w(this, ue, /* @__PURE__ */ new Map());
|
|
2033
2033
|
/**
|
|
2034
2034
|
* Similar to #onscreen with respect to the keys, but contains branches that are not yet
|
|
2035
2035
|
* in the DOM, because their insertion is deferred.
|
|
2036
2036
|
* @type {Map<Key, Branch>}
|
|
2037
2037
|
*/
|
|
2038
|
-
|
|
2038
|
+
w(this, q, /* @__PURE__ */ new Map());
|
|
2039
2039
|
/**
|
|
2040
2040
|
* Keys of effects that are currently outroing
|
|
2041
2041
|
* @type {Set<Key>}
|
|
2042
2042
|
*/
|
|
2043
|
-
|
|
2043
|
+
w(this, We, /* @__PURE__ */ new Set());
|
|
2044
2044
|
/**
|
|
2045
2045
|
* Whether to pause (i.e. outro) on change, or destroy immediately.
|
|
2046
2046
|
* This is necessary for `<svelte:element>`
|
|
2047
2047
|
*/
|
|
2048
|
-
|
|
2049
|
-
|
|
2048
|
+
w(this, kt, !0);
|
|
2049
|
+
w(this, It, () => {
|
|
2050
2050
|
var t = (
|
|
2051
2051
|
/** @type {Batch} */
|
|
2052
2052
|
x
|
|
2053
2053
|
);
|
|
2054
|
-
if (l(this,
|
|
2054
|
+
if (l(this, Q).has(t)) {
|
|
2055
2055
|
var n = (
|
|
2056
2056
|
/** @type {Key} */
|
|
2057
|
-
l(this,
|
|
2058
|
-
), r = l(this,
|
|
2057
|
+
l(this, Q).get(t)
|
|
2058
|
+
), r = l(this, ue).get(n);
|
|
2059
2059
|
if (r)
|
|
2060
|
-
|
|
2060
|
+
xi(r), l(this, We).delete(n);
|
|
2061
2061
|
else {
|
|
2062
|
-
var s = l(this,
|
|
2063
|
-
s && (l(this,
|
|
2062
|
+
var s = l(this, q).get(n);
|
|
2063
|
+
s && (l(this, ue).set(n, s.effect), l(this, q).delete(n), s.fragment.lastChild.remove(), this.anchor.before(s.fragment), r = s.effect);
|
|
2064
2064
|
}
|
|
2065
|
-
for (const [i, o] of l(this,
|
|
2066
|
-
if (l(this,
|
|
2065
|
+
for (const [i, o] of l(this, Q)) {
|
|
2066
|
+
if (l(this, Q).delete(i), i === t)
|
|
2067
2067
|
break;
|
|
2068
|
-
const
|
|
2069
|
-
|
|
2068
|
+
const u = l(this, q).get(o);
|
|
2069
|
+
u && (V(u.effect), l(this, q).delete(o));
|
|
2070
2070
|
}
|
|
2071
|
-
for (const [i, o] of l(this,
|
|
2072
|
-
if (i === n || l(this,
|
|
2073
|
-
const
|
|
2074
|
-
if (Array.from(l(this,
|
|
2075
|
-
var
|
|
2076
|
-
|
|
2071
|
+
for (const [i, o] of l(this, ue)) {
|
|
2072
|
+
if (i === n || l(this, We).has(i)) continue;
|
|
2073
|
+
const u = () => {
|
|
2074
|
+
if (Array.from(l(this, Q).values()).includes(i)) {
|
|
2075
|
+
var f = document.createDocumentFragment();
|
|
2076
|
+
Kr(o, f), f.append(Xe()), l(this, q).set(i, { effect: o, fragment: f });
|
|
2077
2077
|
} else
|
|
2078
|
-
|
|
2079
|
-
l(this,
|
|
2078
|
+
V(o);
|
|
2079
|
+
l(this, We).delete(i), l(this, ue).delete(i);
|
|
2080
2080
|
};
|
|
2081
|
-
l(this,
|
|
2081
|
+
l(this, kt) || !r ? (l(this, We).add(i), bt(o, u, !1)) : u();
|
|
2082
2082
|
}
|
|
2083
2083
|
}
|
|
2084
2084
|
});
|
|
2085
2085
|
/**
|
|
2086
2086
|
* @param {Batch} batch
|
|
2087
2087
|
*/
|
|
2088
|
-
|
|
2089
|
-
l(this,
|
|
2090
|
-
const n = Array.from(l(this,
|
|
2091
|
-
for (const [r, s] of l(this,
|
|
2092
|
-
n.includes(r) || (
|
|
2088
|
+
w(this, Ut, (t) => {
|
|
2089
|
+
l(this, Q).delete(t);
|
|
2090
|
+
const n = Array.from(l(this, Q).values());
|
|
2091
|
+
for (const [r, s] of l(this, q))
|
|
2092
|
+
n.includes(r) || (V(s.effect), l(this, q).delete(r));
|
|
2093
2093
|
});
|
|
2094
|
-
this.anchor = t, p(this,
|
|
2094
|
+
this.anchor = t, p(this, kt, n);
|
|
2095
2095
|
}
|
|
2096
2096
|
/**
|
|
2097
2097
|
*
|
|
@@ -2102,45 +2102,45 @@ class ki {
|
|
|
2102
2102
|
var r = (
|
|
2103
2103
|
/** @type {Batch} */
|
|
2104
2104
|
x
|
|
2105
|
-
), s =
|
|
2106
|
-
if (n && !l(this,
|
|
2105
|
+
), s = pi();
|
|
2106
|
+
if (n && !l(this, ue).has(t) && !l(this, q).has(t))
|
|
2107
2107
|
if (s) {
|
|
2108
|
-
var i = document.createDocumentFragment(), o =
|
|
2109
|
-
i.append(o), l(this,
|
|
2110
|
-
effect:
|
|
2108
|
+
var i = document.createDocumentFragment(), o = Xe();
|
|
2109
|
+
i.append(o), l(this, q).set(t, {
|
|
2110
|
+
effect: Me(() => n(o)),
|
|
2111
2111
|
fragment: i
|
|
2112
2112
|
});
|
|
2113
2113
|
} else
|
|
2114
|
-
l(this,
|
|
2114
|
+
l(this, ue).set(
|
|
2115
2115
|
t,
|
|
2116
|
-
|
|
2116
|
+
Me(() => n(this.anchor))
|
|
2117
2117
|
);
|
|
2118
|
-
if (l(this,
|
|
2119
|
-
for (const [
|
|
2120
|
-
|
|
2121
|
-
for (const [
|
|
2122
|
-
|
|
2123
|
-
r.oncommit(l(this,
|
|
2118
|
+
if (l(this, Q).set(r, t), s) {
|
|
2119
|
+
for (const [u, a] of l(this, ue))
|
|
2120
|
+
u === t ? r.unskip_effect(a) : r.skip_effect(a);
|
|
2121
|
+
for (const [u, a] of l(this, q))
|
|
2122
|
+
u === t ? r.unskip_effect(a.effect) : r.skip_effect(a.effect);
|
|
2123
|
+
r.oncommit(l(this, It)), r.ondiscard(l(this, Ut));
|
|
2124
2124
|
} else
|
|
2125
|
-
|
|
2125
|
+
I && (this.anchor = k), l(this, It).call(this);
|
|
2126
2126
|
}
|
|
2127
2127
|
}
|
|
2128
|
-
|
|
2129
|
-
function
|
|
2130
|
-
|
|
2131
|
-
const t =
|
|
2128
|
+
Q = new WeakMap(), ue = new WeakMap(), q = new WeakMap(), We = new WeakMap(), kt = new WeakMap(), It = new WeakMap(), Ut = new WeakMap();
|
|
2129
|
+
function Fi(e) {
|
|
2130
|
+
Y === null && pr(), kn(() => {
|
|
2131
|
+
const t = ss(e);
|
|
2132
2132
|
if (typeof t == "function") return (
|
|
2133
2133
|
/** @type {() => void} */
|
|
2134
2134
|
t
|
|
2135
2135
|
);
|
|
2136
2136
|
});
|
|
2137
2137
|
}
|
|
2138
|
-
function
|
|
2138
|
+
function ji(e, t, { bubbles: n = !1, cancelable: r = !1 } = {}) {
|
|
2139
2139
|
return new CustomEvent(e, { detail: t, bubbles: n, cancelable: r });
|
|
2140
2140
|
}
|
|
2141
|
-
function
|
|
2142
|
-
const e =
|
|
2143
|
-
return e === null &&
|
|
2141
|
+
function Hi() {
|
|
2142
|
+
const e = Y;
|
|
2143
|
+
return e === null && pr(), (t, n, r) => {
|
|
2144
2144
|
const s = (
|
|
2145
2145
|
/** @type {Record<string, Function | Function[]>} */
|
|
2146
2146
|
e.s.$$events?.[
|
|
@@ -2149,116 +2149,116 @@ function Mi() {
|
|
|
2149
2149
|
]
|
|
2150
2150
|
);
|
|
2151
2151
|
if (s) {
|
|
2152
|
-
const i =
|
|
2152
|
+
const i = cr(s) ? s.slice() : [s], o = ji(
|
|
2153
2153
|
/** @type {string} */
|
|
2154
2154
|
t,
|
|
2155
2155
|
n,
|
|
2156
2156
|
r
|
|
2157
2157
|
);
|
|
2158
|
-
for (const
|
|
2159
|
-
|
|
2158
|
+
for (const u of i)
|
|
2159
|
+
u.call(e.x, o);
|
|
2160
2160
|
return !o.defaultPrevented;
|
|
2161
2161
|
}
|
|
2162
2162
|
return !0;
|
|
2163
2163
|
};
|
|
2164
2164
|
}
|
|
2165
|
-
function
|
|
2166
|
-
|
|
2167
|
-
var r = new
|
|
2168
|
-
function i(o,
|
|
2169
|
-
if (
|
|
2170
|
-
const c =
|
|
2171
|
-
var
|
|
2172
|
-
if (c ===
|
|
2173
|
-
var
|
|
2174
|
-
|
|
2165
|
+
function Pt(e, t, n = !1) {
|
|
2166
|
+
I && Nn();
|
|
2167
|
+
var r = new Pi(e), s = n ? ft : 0;
|
|
2168
|
+
function i(o, u) {
|
|
2169
|
+
if (I) {
|
|
2170
|
+
const c = Js(e);
|
|
2171
|
+
var a;
|
|
2172
|
+
if (c === Mn ? a = 0 : c === Tn ? a = !1 : a = parseInt(c.substring(1)), o !== a) {
|
|
2173
|
+
var f = gr();
|
|
2174
|
+
fe(f), r.anchor = f, Ge(!1), r.ensure(o, u), Ge(!0);
|
|
2175
2175
|
return;
|
|
2176
2176
|
}
|
|
2177
2177
|
}
|
|
2178
|
-
r.ensure(o,
|
|
2178
|
+
r.ensure(o, u);
|
|
2179
2179
|
}
|
|
2180
|
-
|
|
2180
|
+
Wr(() => {
|
|
2181
2181
|
var o = !1;
|
|
2182
|
-
t((
|
|
2183
|
-
o = !0, i(
|
|
2182
|
+
t((u, a = 0) => {
|
|
2183
|
+
o = !0, i(a, u);
|
|
2184
2184
|
}), o || i(!1, null);
|
|
2185
2185
|
}, s);
|
|
2186
2186
|
}
|
|
2187
|
-
function
|
|
2187
|
+
function zi(e, t) {
|
|
2188
2188
|
return e == null ? null : String(e);
|
|
2189
2189
|
}
|
|
2190
|
-
function
|
|
2190
|
+
function or(e, t, n, r) {
|
|
2191
2191
|
var s = e.__style;
|
|
2192
|
-
if (
|
|
2193
|
-
var i =
|
|
2194
|
-
(!
|
|
2192
|
+
if (I || s !== t) {
|
|
2193
|
+
var i = zi(t);
|
|
2194
|
+
(!I || i !== e.getAttribute("style")) && (i == null ? e.removeAttribute("style") : e.style.cssText = i), e.__style = t;
|
|
2195
2195
|
}
|
|
2196
2196
|
return r;
|
|
2197
2197
|
}
|
|
2198
|
-
const
|
|
2199
|
-
function
|
|
2200
|
-
var s =
|
|
2201
|
-
|
|
2198
|
+
const Vi = /* @__PURE__ */ Symbol("is custom element"), Yi = /* @__PURE__ */ Symbol("is html");
|
|
2199
|
+
function Bi(e, t, n, r) {
|
|
2200
|
+
var s = Wi(e);
|
|
2201
|
+
I && (s[t] = e.getAttribute(t)), s[t] !== (s[t] = n) && (n == null ? e.removeAttribute(t) : typeof n != "string" && qi(e).includes(t) ? e[t] = n : e.setAttribute(t, n));
|
|
2202
2202
|
}
|
|
2203
|
-
function
|
|
2203
|
+
function Wi(e) {
|
|
2204
2204
|
return (
|
|
2205
2205
|
/** @type {Record<string | symbol, unknown>} **/
|
|
2206
2206
|
// @ts-expect-error
|
|
2207
2207
|
e.__attributes ?? (e.__attributes = {
|
|
2208
|
-
[
|
|
2209
|
-
[
|
|
2208
|
+
[Vi]: e.nodeName.includes("-"),
|
|
2209
|
+
[Yi]: e.namespaceURI === fr
|
|
2210
2210
|
})
|
|
2211
2211
|
);
|
|
2212
2212
|
}
|
|
2213
|
-
var
|
|
2214
|
-
function
|
|
2215
|
-
var t = e.getAttribute("is") || e.nodeName, n =
|
|
2213
|
+
var lr = /* @__PURE__ */ new Map();
|
|
2214
|
+
function qi(e) {
|
|
2215
|
+
var t = e.getAttribute("is") || e.nodeName, n = lr.get(t);
|
|
2216
2216
|
if (n) return n;
|
|
2217
|
-
|
|
2217
|
+
lr.set(t, n = []);
|
|
2218
2218
|
for (var r, s = e, i = Element.prototype; i !== s; ) {
|
|
2219
|
-
r =
|
|
2219
|
+
r = Ts(s);
|
|
2220
2220
|
for (var o in r)
|
|
2221
2221
|
r[o].set && n.push(o);
|
|
2222
|
-
s =
|
|
2222
|
+
s = dr(s);
|
|
2223
2223
|
}
|
|
2224
2224
|
return n;
|
|
2225
2225
|
}
|
|
2226
|
-
function
|
|
2226
|
+
function vn(e, t, n, r) {
|
|
2227
2227
|
var s = (
|
|
2228
2228
|
/** @type {V} */
|
|
2229
2229
|
r
|
|
2230
2230
|
), i = !0, o = () => (i && (i = !1, s = /** @type {V} */
|
|
2231
|
-
r), s),
|
|
2232
|
-
|
|
2233
|
-
e[t],
|
|
2234
|
-
var
|
|
2235
|
-
|
|
2231
|
+
r), s), u;
|
|
2232
|
+
u = /** @type {V} */
|
|
2233
|
+
e[t], u === void 0 && r !== void 0 && (u = o());
|
|
2234
|
+
var a;
|
|
2235
|
+
a = () => {
|
|
2236
2236
|
var d = (
|
|
2237
2237
|
/** @type {V} */
|
|
2238
2238
|
e[t]
|
|
2239
2239
|
);
|
|
2240
2240
|
return d === void 0 ? o() : (i = !0, d);
|
|
2241
2241
|
};
|
|
2242
|
-
var
|
|
2242
|
+
var f = !1, c = /* @__PURE__ */ Dn(() => (f = !1, a())), v = (
|
|
2243
2243
|
/** @type {Effect} */
|
|
2244
|
-
|
|
2244
|
+
y
|
|
2245
2245
|
);
|
|
2246
2246
|
return (
|
|
2247
2247
|
/** @type {() => V} */
|
|
2248
2248
|
(function(d, g) {
|
|
2249
2249
|
if (arguments.length > 0) {
|
|
2250
|
-
const
|
|
2251
|
-
return
|
|
2250
|
+
const _ = g ? m(c) : d;
|
|
2251
|
+
return $(c, _), f = !0, s !== void 0 && (s = _), d;
|
|
2252
2252
|
}
|
|
2253
|
-
return
|
|
2253
|
+
return Ne && f || (v.f & $e) !== 0 ? c.v : m(c);
|
|
2254
2254
|
})
|
|
2255
2255
|
);
|
|
2256
2256
|
}
|
|
2257
|
-
function
|
|
2258
|
-
return new
|
|
2257
|
+
function Ui(e) {
|
|
2258
|
+
return new Xi(e);
|
|
2259
2259
|
}
|
|
2260
|
-
var
|
|
2261
|
-
class
|
|
2260
|
+
var ye, J;
|
|
2261
|
+
class Xi {
|
|
2262
2262
|
/**
|
|
2263
2263
|
* @param {ComponentConstructorOptions & {
|
|
2264
2264
|
* component: any;
|
|
@@ -2266,56 +2266,56 @@ class Li {
|
|
|
2266
2266
|
*/
|
|
2267
2267
|
constructor(t) {
|
|
2268
2268
|
/** @type {any} */
|
|
2269
|
-
|
|
2269
|
+
w(this, ye);
|
|
2270
2270
|
/** @type {Record<string, any>} */
|
|
2271
|
-
|
|
2271
|
+
w(this, J);
|
|
2272
2272
|
var n = /* @__PURE__ */ new Map(), r = (i, o) => {
|
|
2273
|
-
var
|
|
2274
|
-
return n.set(i,
|
|
2273
|
+
var u = /* @__PURE__ */ hi(o, !1, !1);
|
|
2274
|
+
return n.set(i, u), u;
|
|
2275
2275
|
};
|
|
2276
2276
|
const s = new Proxy(
|
|
2277
2277
|
{ ...t.props || {}, $$events: {} },
|
|
2278
2278
|
{
|
|
2279
2279
|
get(i, o) {
|
|
2280
|
-
return
|
|
2280
|
+
return m(n.get(o) ?? r(o, Reflect.get(i, o)));
|
|
2281
2281
|
},
|
|
2282
2282
|
has(i, o) {
|
|
2283
|
-
return o ===
|
|
2283
|
+
return o === Ls ? !0 : (m(n.get(o) ?? r(o, Reflect.get(i, o))), Reflect.has(i, o));
|
|
2284
2284
|
},
|
|
2285
|
-
set(i, o,
|
|
2286
|
-
return
|
|
2285
|
+
set(i, o, u) {
|
|
2286
|
+
return $(n.get(o) ?? r(o, u), u), Reflect.set(i, o, u);
|
|
2287
2287
|
}
|
|
2288
2288
|
}
|
|
2289
2289
|
);
|
|
2290
|
-
p(this,
|
|
2290
|
+
p(this, J, (t.hydrate ? Di : us)(t.component, {
|
|
2291
2291
|
target: t.target,
|
|
2292
2292
|
anchor: t.anchor,
|
|
2293
2293
|
props: s,
|
|
2294
2294
|
context: t.context,
|
|
2295
2295
|
intro: t.intro ?? !1,
|
|
2296
2296
|
recover: t.recover
|
|
2297
|
-
})), (!t?.props?.$$host || t.sync === !1) &&
|
|
2298
|
-
for (const i of Object.keys(l(this,
|
|
2299
|
-
i === "$set" || i === "$destroy" || i === "$on" ||
|
|
2297
|
+
})), (!t?.props?.$$host || t.sync === !1) && Ft(), p(this, ye, s.$$events);
|
|
2298
|
+
for (const i of Object.keys(l(this, J)))
|
|
2299
|
+
i === "$set" || i === "$destroy" || i === "$on" || Yt(this, i, {
|
|
2300
2300
|
get() {
|
|
2301
|
-
return l(this,
|
|
2301
|
+
return l(this, J)[i];
|
|
2302
2302
|
},
|
|
2303
2303
|
/** @param {any} value */
|
|
2304
2304
|
set(o) {
|
|
2305
|
-
l(this,
|
|
2305
|
+
l(this, J)[i] = o;
|
|
2306
2306
|
},
|
|
2307
2307
|
enumerable: !0
|
|
2308
2308
|
});
|
|
2309
|
-
l(this,
|
|
2309
|
+
l(this, J).$set = /** @param {Record<string, any>} next */
|
|
2310
2310
|
(i) => {
|
|
2311
2311
|
Object.assign(s, i);
|
|
2312
|
-
}, l(this,
|
|
2313
|
-
|
|
2312
|
+
}, l(this, J).$destroy = () => {
|
|
2313
|
+
Li(l(this, J));
|
|
2314
2314
|
};
|
|
2315
2315
|
}
|
|
2316
2316
|
/** @param {Record<string, any>} props */
|
|
2317
2317
|
$set(t) {
|
|
2318
|
-
l(this,
|
|
2318
|
+
l(this, J).$set(t);
|
|
2319
2319
|
}
|
|
2320
2320
|
/**
|
|
2321
2321
|
* @param {string} event
|
|
@@ -2323,22 +2323,22 @@ class Li {
|
|
|
2323
2323
|
* @returns {any}
|
|
2324
2324
|
*/
|
|
2325
2325
|
$on(t, n) {
|
|
2326
|
-
l(this,
|
|
2326
|
+
l(this, ye)[t] = l(this, ye)[t] || [];
|
|
2327
2327
|
const r = (...s) => n.call(this, ...s);
|
|
2328
|
-
return l(this,
|
|
2329
|
-
l(this,
|
|
2328
|
+
return l(this, ye)[t].push(r), () => {
|
|
2329
|
+
l(this, ye)[t] = l(this, ye)[t].filter(
|
|
2330
2330
|
/** @param {any} fn */
|
|
2331
2331
|
(s) => s !== r
|
|
2332
2332
|
);
|
|
2333
2333
|
};
|
|
2334
2334
|
}
|
|
2335
2335
|
$destroy() {
|
|
2336
|
-
l(this,
|
|
2336
|
+
l(this, J).$destroy();
|
|
2337
2337
|
}
|
|
2338
2338
|
}
|
|
2339
|
-
|
|
2340
|
-
let
|
|
2341
|
-
typeof HTMLElement == "function" && (
|
|
2339
|
+
ye = new WeakMap(), J = new WeakMap();
|
|
2340
|
+
let fs;
|
|
2341
|
+
typeof HTMLElement == "function" && (fs = class extends HTMLElement {
|
|
2342
2342
|
/**
|
|
2343
2343
|
* @param {*} $$componentCtor
|
|
2344
2344
|
* @param {*} $$slots
|
|
@@ -2347,27 +2347,27 @@ typeof HTMLElement == "function" && (es = class extends HTMLElement {
|
|
|
2347
2347
|
constructor(t, n, r) {
|
|
2348
2348
|
super();
|
|
2349
2349
|
/** The Svelte component constructor */
|
|
2350
|
-
|
|
2350
|
+
A(this, "$$ctor");
|
|
2351
2351
|
/** Slots */
|
|
2352
|
-
|
|
2352
|
+
A(this, "$$s");
|
|
2353
2353
|
/** @type {any} The Svelte component instance */
|
|
2354
|
-
|
|
2354
|
+
A(this, "$$c");
|
|
2355
2355
|
/** Whether or not the custom element is connected */
|
|
2356
|
-
|
|
2356
|
+
A(this, "$$cn", !1);
|
|
2357
2357
|
/** @type {Record<string, any>} Component props data */
|
|
2358
|
-
|
|
2358
|
+
A(this, "$$d", {});
|
|
2359
2359
|
/** `true` if currently in the process of reflecting component props back to attributes */
|
|
2360
|
-
|
|
2360
|
+
A(this, "$$r", !1);
|
|
2361
2361
|
/** @type {Record<string, CustomElementPropDefinition>} Props definition (name, reflected, type etc) */
|
|
2362
|
-
|
|
2362
|
+
A(this, "$$p_d", {});
|
|
2363
2363
|
/** @type {Record<string, EventListenerOrEventListenerObject[]>} Event listeners */
|
|
2364
|
-
|
|
2364
|
+
A(this, "$$l", {});
|
|
2365
2365
|
/** @type {Map<EventListenerOrEventListenerObject, Function>} Event listener unsubscribe functions */
|
|
2366
|
-
|
|
2366
|
+
A(this, "$$l_u", /* @__PURE__ */ new Map());
|
|
2367
2367
|
/** @type {any} The managed render effect for reflecting attributes */
|
|
2368
|
-
|
|
2368
|
+
A(this, "$$me");
|
|
2369
2369
|
/** @type {ShadowRoot | null} The ShadowRoot of the custom element */
|
|
2370
|
-
|
|
2370
|
+
A(this, "$$shadowRoot", null);
|
|
2371
2371
|
this.$$ctor = t, this.$$s = n, r && (this.$$shadowRoot = this.attachShadow(r));
|
|
2372
2372
|
}
|
|
2373
2373
|
/**
|
|
@@ -2397,22 +2397,22 @@ typeof HTMLElement == "function" && (es = class extends HTMLElement {
|
|
|
2397
2397
|
if (this.$$cn = !0, !this.$$c) {
|
|
2398
2398
|
let t = function(s) {
|
|
2399
2399
|
return (i) => {
|
|
2400
|
-
const o =
|
|
2401
|
-
s !== "default" && (o.name = s),
|
|
2400
|
+
const o = Hr("slot");
|
|
2401
|
+
s !== "default" && (o.name = s), _e(i, o);
|
|
2402
2402
|
};
|
|
2403
2403
|
};
|
|
2404
2404
|
if (await Promise.resolve(), !this.$$cn || this.$$c)
|
|
2405
2405
|
return;
|
|
2406
|
-
const n = {}, r =
|
|
2406
|
+
const n = {}, r = Ji(this);
|
|
2407
2407
|
for (const s of this.$$s)
|
|
2408
2408
|
s in r && (s === "default" && !this.$$d.children ? (this.$$d.children = t(s), n.default = !0) : n[s] = t(s));
|
|
2409
2409
|
for (const s of this.attributes) {
|
|
2410
2410
|
const i = this.$$g_p(s.name);
|
|
2411
|
-
i in this.$$d || (this.$$d[i] =
|
|
2411
|
+
i in this.$$d || (this.$$d[i] = zt(i, s.value, this.$$p_d, "toProp"));
|
|
2412
2412
|
}
|
|
2413
2413
|
for (const s in this.$$p_d)
|
|
2414
2414
|
!(s in this.$$d) && this[s] !== void 0 && (this.$$d[s] = this[s], delete this[s]);
|
|
2415
|
-
this.$$c =
|
|
2415
|
+
this.$$c = Ui({
|
|
2416
2416
|
component: this.$$ctor,
|
|
2417
2417
|
target: this.$$shadowRoot || this,
|
|
2418
2418
|
props: {
|
|
@@ -2420,13 +2420,13 @@ typeof HTMLElement == "function" && (es = class extends HTMLElement {
|
|
|
2420
2420
|
$$slots: n,
|
|
2421
2421
|
$$host: this
|
|
2422
2422
|
}
|
|
2423
|
-
}), this.$$me =
|
|
2424
|
-
|
|
2423
|
+
}), this.$$me = bi(() => {
|
|
2424
|
+
Br(() => {
|
|
2425
2425
|
this.$$r = !0;
|
|
2426
|
-
for (const s of
|
|
2426
|
+
for (const s of Vt(this.$$c)) {
|
|
2427
2427
|
if (!this.$$p_d[s]?.reflect) continue;
|
|
2428
2428
|
this.$$d[s] = this.$$c[s];
|
|
2429
|
-
const i =
|
|
2429
|
+
const i = zt(
|
|
2430
2430
|
s,
|
|
2431
2431
|
this.$$d[s],
|
|
2432
2432
|
this.$$p_d,
|
|
@@ -2453,7 +2453,7 @@ typeof HTMLElement == "function" && (es = class extends HTMLElement {
|
|
|
2453
2453
|
* @param {string} newValue
|
|
2454
2454
|
*/
|
|
2455
2455
|
attributeChangedCallback(t, n, r) {
|
|
2456
|
-
this.$$r || (t = this.$$g_p(t), this.$$d[t] =
|
|
2456
|
+
this.$$r || (t = this.$$g_p(t), this.$$d[t] = zt(t, r, this.$$p_d, "toProp"), this.$$c?.$set({ [t]: this.$$d[t] }));
|
|
2457
2457
|
}
|
|
2458
2458
|
disconnectedCallback() {
|
|
2459
2459
|
this.$$cn = !1, Promise.resolve().then(() => {
|
|
@@ -2464,12 +2464,12 @@ typeof HTMLElement == "function" && (es = class extends HTMLElement {
|
|
|
2464
2464
|
* @param {string} attribute_name
|
|
2465
2465
|
*/
|
|
2466
2466
|
$$g_p(t) {
|
|
2467
|
-
return
|
|
2467
|
+
return Vt(this.$$p_d).find(
|
|
2468
2468
|
(n) => this.$$p_d[n].attribute === t || !this.$$p_d[n].attribute && n.toLowerCase() === t
|
|
2469
2469
|
) || t;
|
|
2470
2470
|
}
|
|
2471
2471
|
});
|
|
2472
|
-
function
|
|
2472
|
+
function zt(e, t, n, r) {
|
|
2473
2473
|
const s = n[e]?.type;
|
|
2474
2474
|
if (t = s === "Boolean" && typeof t != "boolean" ? t != null : t, !r || !n[e])
|
|
2475
2475
|
return t;
|
|
@@ -2499,7 +2499,7 @@ function jt(e, t, n, r) {
|
|
|
2499
2499
|
return t;
|
|
2500
2500
|
}
|
|
2501
2501
|
}
|
|
2502
|
-
function
|
|
2502
|
+
function Ji(e) {
|
|
2503
2503
|
const t = {};
|
|
2504
2504
|
return e.childNodes.forEach((n) => {
|
|
2505
2505
|
t[
|
|
@@ -2508,202 +2508,253 @@ function ji(e) {
|
|
|
2508
2508
|
] = !0;
|
|
2509
2509
|
}), t;
|
|
2510
2510
|
}
|
|
2511
|
-
function
|
|
2512
|
-
let o = class extends
|
|
2511
|
+
function Ki(e, t, n, r, s, i) {
|
|
2512
|
+
let o = class extends fs {
|
|
2513
2513
|
constructor() {
|
|
2514
2514
|
super(e, n, s), this.$$p_d = t;
|
|
2515
2515
|
}
|
|
2516
2516
|
static get observedAttributes() {
|
|
2517
|
-
return
|
|
2518
|
-
(
|
|
2517
|
+
return Vt(t).map(
|
|
2518
|
+
(u) => (t[u].attribute || u).toLowerCase()
|
|
2519
2519
|
);
|
|
2520
2520
|
}
|
|
2521
2521
|
};
|
|
2522
|
-
return
|
|
2523
|
-
|
|
2522
|
+
return Vt(t).forEach((u) => {
|
|
2523
|
+
Yt(o.prototype, u, {
|
|
2524
2524
|
get() {
|
|
2525
|
-
return this.$$c &&
|
|
2525
|
+
return this.$$c && u in this.$$c ? this.$$c[u] : this.$$d[u];
|
|
2526
2526
|
},
|
|
2527
|
-
set(
|
|
2528
|
-
|
|
2529
|
-
var
|
|
2530
|
-
if (
|
|
2531
|
-
var c =
|
|
2532
|
-
c ?
|
|
2527
|
+
set(a) {
|
|
2528
|
+
a = zt(u, a, t), this.$$d[u] = a;
|
|
2529
|
+
var f = this.$$c;
|
|
2530
|
+
if (f) {
|
|
2531
|
+
var c = Qe(f, u)?.get;
|
|
2532
|
+
c ? f[u] = a : f.$set({ [u]: a });
|
|
2533
2533
|
}
|
|
2534
2534
|
}
|
|
2535
2535
|
});
|
|
2536
|
-
}), r.forEach((
|
|
2537
|
-
|
|
2536
|
+
}), r.forEach((u) => {
|
|
2537
|
+
Yt(o.prototype, u, {
|
|
2538
2538
|
get() {
|
|
2539
|
-
return this.$$c?.[
|
|
2539
|
+
return this.$$c?.[u];
|
|
2540
2540
|
}
|
|
2541
2541
|
});
|
|
2542
2542
|
}), e.element = /** @type {any} */
|
|
2543
2543
|
o, o;
|
|
2544
2544
|
}
|
|
2545
|
-
var
|
|
2546
|
-
function
|
|
2547
|
-
|
|
2548
|
-
const n =
|
|
2549
|
-
let r =
|
|
2545
|
+
var Gi = /* @__PURE__ */ ls('<svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-xs" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 15l7-7 7 7"></path></svg>'), Zi = /* @__PURE__ */ ls('<svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-xs" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>'), Qi = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger__alert pie-section-player-tools-session-debugger__alert--warning"><svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-md" fill="none" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 9v2m0 4h.01M5.07 19h13.86c1.54 0 2.5-1.67 1.73-3L13.73 4c-.77-1.33-2.69-1.33-3.46 0L3.34 16c-.77 1.33.19 3 1.73 3z"></path></svg> <span class="pie-section-player-tools-session-debugger__text-xs">Section controller not available for this section yet.</span></div>'), eo = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger__alert pie-section-player-tools-session-debugger__alert--info"><svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-md" fill="none" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg> <span class="pie-section-player-tools-session-debugger__text-xs">No section session data yet. Interact with the questions to see updates.</span></div>'), to = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger__card"><div class="pie-section-player-tools-session-debugger__card-title">Item Sessions Snapshot</div> <pre class="pie-section-player-tools-session-debugger__card-pre"> </pre></div>'), no = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger__content-shell"><div class="pie-section-player-tools-session-debugger__content"><div class="pie-section-player-tools-session-debugger__section-intro"><div class="pie-section-player-tools-session-debugger__heading">PIE Session Data (Persistent)</div></div> <!></div></div>'), ro = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger__resize-handle" role="button" tabindex="0" title="Resize window"><svg class="pie-section-player-tools-session-debugger__resize-icon" viewBox="0 0 16 16" fill="currentColor"><path d="M16 16V14H14V16H16Z"></path><path d="M16 11V9H14V11H16Z"></path><path d="M13 16V14H11V16H13Z"></path></svg></div>'), so = /* @__PURE__ */ pt('<div class="pie-section-player-tools-session-debugger"><div class="pie-section-player-tools-session-debugger__header" role="button" tabindex="0" aria-label="Drag session panel"><div class="pie-section-player-tools-session-debugger__header-title"><svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-sm" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"></path></svg> <h3 class="pie-section-player-tools-session-debugger__title">Session Data</h3></div> <div class="pie-section-player-tools-session-debugger__header-actions"><button class="pie-section-player-tools-session-debugger__icon-button"><!></button> <button class="pie-section-player-tools-session-debugger__icon-button" title="Close"><svg xmlns="http://www.w3.org/2000/svg" class="pie-section-player-tools-session-debugger__icon-xs" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"></path></svg></button></div></div> <!> <!></div>');
|
|
2546
|
+
function io(e, t) {
|
|
2547
|
+
wr(t, !0);
|
|
2548
|
+
const n = Hi();
|
|
2549
|
+
let r = vn(t, "toolkitCoordinator", 7, null), s = vn(t, "sectionId", 7, ""), i = vn(t, "attemptId", 7, void 0), o = /* @__PURE__ */ D(!1), u = /* @__PURE__ */ D(24), a = /* @__PURE__ */ D(100), f = /* @__PURE__ */ D(220), c = /* @__PURE__ */ D(600), v = /* @__PURE__ */ D(!1), d = /* @__PURE__ */ D(!1), g = 0, _ = 0, T = 0, E = 0, ke = 0, se = 0, Hn = 0, zn = 0, Tt = /* @__PURE__ */ D(Ze({
|
|
2550
2550
|
currentItemIndex: null,
|
|
2551
2551
|
currentItemId: null,
|
|
2552
2552
|
visitedItemIdentifiers: [],
|
|
2553
2553
|
updatedAt: null,
|
|
2554
2554
|
lastChangedItemId: null,
|
|
2555
2555
|
itemSessions: {}
|
|
2556
|
-
}));
|
|
2557
|
-
function
|
|
2556
|
+
})), Zt = null, Qt = null, en = null, tn = /* @__PURE__ */ D(!1), nn = !1;
|
|
2557
|
+
function Vn(h) {
|
|
2558
2558
|
try {
|
|
2559
|
-
return structuredClone(
|
|
2559
|
+
return structuredClone(h);
|
|
2560
2560
|
} catch {
|
|
2561
|
-
|
|
2561
|
+
try {
|
|
2562
|
+
return JSON.parse(JSON.stringify(h));
|
|
2563
|
+
} catch {
|
|
2564
|
+
return h;
|
|
2565
|
+
}
|
|
2562
2566
|
}
|
|
2563
2567
|
}
|
|
2564
|
-
function
|
|
2568
|
+
function Yn() {
|
|
2565
2569
|
if (!(!r() || !s()))
|
|
2566
2570
|
return r().getSectionController?.({ sectionId: s(), attemptId: i() });
|
|
2567
2571
|
}
|
|
2568
|
-
function
|
|
2569
|
-
const
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
+
function Ct(h, S) {
|
|
2573
|
+
const R = S || Yn(), N = R?.getCurrentSectionAttemptSlice?.() || null;
|
|
2574
|
+
$(tn, !!R, !0), $(
|
|
2575
|
+
Tt,
|
|
2572
2576
|
{
|
|
2573
|
-
currentItemIndex: typeof
|
|
2574
|
-
currentItemId: typeof
|
|
2575
|
-
visitedItemIdentifiers:
|
|
2576
|
-
updatedAt:
|
|
2577
|
-
lastChangedItemId:
|
|
2578
|
-
itemSessions:
|
|
2577
|
+
currentItemIndex: typeof N?.currentItemIndex == "number" && N.currentItemIndex >= 0 ? N.currentItemIndex : null,
|
|
2578
|
+
currentItemId: typeof N?.currentItemId == "string" && N.currentItemId ? N.currentItemId : null,
|
|
2579
|
+
visitedItemIdentifiers: Vn(N?.visitedItemIdentifiers || []),
|
|
2580
|
+
updatedAt: h?.updatedAt || Date.now(),
|
|
2581
|
+
lastChangedItemId: h?.itemId || null,
|
|
2582
|
+
itemSessions: Vn(N?.itemSessions || {})
|
|
2579
2583
|
},
|
|
2580
2584
|
!0
|
|
2581
2585
|
);
|
|
2582
2586
|
}
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2587
|
+
function Bn(h) {
|
|
2588
|
+
nn || (nn = !0, queueMicrotask(() => {
|
|
2589
|
+
nn = !1, sn(), Ct(h || { updatedAt: Date.now() });
|
|
2590
|
+
}));
|
|
2591
|
+
}
|
|
2592
|
+
function rn() {
|
|
2593
|
+
Qt?.(), Qt = null, Zt = null;
|
|
2594
|
+
}
|
|
2595
|
+
function Wn() {
|
|
2596
|
+
en?.(), en = null;
|
|
2597
|
+
}
|
|
2598
|
+
function sn() {
|
|
2599
|
+
const h = Yn() || null;
|
|
2600
|
+
if (!h) {
|
|
2601
|
+
rn(), $(tn, !1), $(
|
|
2602
|
+
Tt,
|
|
2603
|
+
{
|
|
2604
|
+
currentItemIndex: null,
|
|
2605
|
+
currentItemId: null,
|
|
2606
|
+
visitedItemIdentifiers: [],
|
|
2607
|
+
updatedAt: Date.now(),
|
|
2608
|
+
lastChangedItemId: null,
|
|
2609
|
+
itemSessions: {}
|
|
2610
|
+
},
|
|
2611
|
+
!0
|
|
2612
|
+
);
|
|
2613
|
+
return;
|
|
2614
|
+
}
|
|
2615
|
+
if (h === Zt) return;
|
|
2616
|
+
rn(), Zt = h, Qt = (typeof h.subscribe == "function" ? h.subscribe.bind(h) : null)?.((R) => {
|
|
2617
|
+
Ct(
|
|
2618
|
+
{
|
|
2619
|
+
itemId: R?.itemId,
|
|
2620
|
+
updatedAt: R?.timestamp || Date.now()
|
|
2621
|
+
},
|
|
2622
|
+
h
|
|
2623
|
+
);
|
|
2624
|
+
}) || null, Ct(void 0, h);
|
|
2625
|
+
}
|
|
2626
|
+
function cs() {
|
|
2627
|
+
Bn({ updatedAt: Date.now() });
|
|
2628
|
+
}
|
|
2629
|
+
kn(() => {
|
|
2630
|
+
if (!(!r() || !s()))
|
|
2631
|
+
return sn(), Wn(), en = r().onSectionControllerLifecycle?.((h) => {
|
|
2632
|
+
const S = h?.key?.sectionId || "", R = h?.key?.attemptId || void 0;
|
|
2633
|
+
S === s() && (R || void 0) === (i() || void 0) && (sn(), Ct({ updatedAt: Date.now() }));
|
|
2634
|
+
}) || null, () => {
|
|
2635
|
+
rn(), Wn();
|
|
2636
|
+
};
|
|
2637
|
+
}), Fi(() => {
|
|
2638
|
+
const h = (un, an, fn) => Math.max(an, Math.min(un, fn)), S = window.innerWidth, R = window.innerHeight;
|
|
2639
|
+
$(f, h(Math.round(S * 0.29), 280, 560), !0), $(c, h(Math.round(R * 0.72), 360, 860), !0), $(u, Math.max(16, Math.round(S * 0.08)), !0), $(a, Math.max(16, Math.round((R - m(c)) / 2)), !0);
|
|
2640
|
+
const N = () => {
|
|
2641
|
+
Bn({ updatedAt: Date.now() });
|
|
2642
|
+
};
|
|
2643
|
+
return document.addEventListener("session-changed", N, !0), document.addEventListener("item-session-changed", N, !0), document.addEventListener("composition-changed", N, !0), () => {
|
|
2644
|
+
document.removeEventListener("session-changed", N, !0), document.removeEventListener("item-session-changed", N, !0), document.removeEventListener("composition-changed", N, !0);
|
|
2594
2645
|
};
|
|
2595
|
-
}), Ii(() => {
|
|
2596
|
-
const _ = (Zt, Qt, en) => Math.max(Qt, Math.min(Zt, en)), I = window.innerWidth, A = window.innerHeight;
|
|
2597
|
-
E(a, _(Math.round(I * 0.29), 280, 560), !0), E(c, _(Math.round(A * 0.72), 360, 860), !0), E(f, Math.max(16, Math.round(I * 0.08)), !0), E(u, Math.max(16, Math.round((A - w(c)) / 2)), !0);
|
|
2598
2646
|
});
|
|
2599
|
-
function
|
|
2600
|
-
|
|
2647
|
+
function ds(h) {
|
|
2648
|
+
$(v, !0), g = h.clientX, _ = h.clientY, T = m(u), E = m(a), document.addEventListener("mousemove", qn), document.addEventListener("mouseup", on);
|
|
2601
2649
|
}
|
|
2602
|
-
function
|
|
2603
|
-
if (!
|
|
2604
|
-
const
|
|
2605
|
-
|
|
2650
|
+
function qn(h) {
|
|
2651
|
+
if (!m(v)) return;
|
|
2652
|
+
const S = h.clientX - g, R = h.clientY - _;
|
|
2653
|
+
$(u, T + S), $(a, E + R), $(u, Math.max(0, Math.min(m(u), window.innerWidth - m(f))), !0), $(a, Math.max(0, Math.min(m(a), window.innerHeight - 100)), !0);
|
|
2606
2654
|
}
|
|
2607
|
-
function
|
|
2608
|
-
|
|
2655
|
+
function on() {
|
|
2656
|
+
$(v, !1), document.removeEventListener("mousemove", qn), document.removeEventListener("mouseup", on);
|
|
2609
2657
|
}
|
|
2610
|
-
function
|
|
2611
|
-
|
|
2658
|
+
function hs(h) {
|
|
2659
|
+
$(d, !0), ke = h.clientX, se = h.clientY, Hn = m(f), zn = m(c), document.addEventListener("mousemove", Un), document.addEventListener("mouseup", ln), h.stopPropagation();
|
|
2612
2660
|
}
|
|
2613
|
-
function
|
|
2614
|
-
if (!
|
|
2615
|
-
const
|
|
2616
|
-
|
|
2661
|
+
function Un(h) {
|
|
2662
|
+
if (!m(d)) return;
|
|
2663
|
+
const S = h.clientX - ke, R = h.clientY - se;
|
|
2664
|
+
$(f, Math.max(300, Math.min(Hn + S, window.innerWidth - m(u))), !0), $(c, Math.max(200, Math.min(zn + R, window.innerHeight - m(a))), !0);
|
|
2617
2665
|
}
|
|
2618
|
-
function
|
|
2619
|
-
|
|
2666
|
+
function ln() {
|
|
2667
|
+
$(d, !1), document.removeEventListener("mousemove", Un), document.removeEventListener("mouseup", ln);
|
|
2620
2668
|
}
|
|
2621
|
-
|
|
2622
|
-
|
|
2669
|
+
kn(() => () => {
|
|
2670
|
+
on(), ln();
|
|
2623
2671
|
});
|
|
2624
|
-
var
|
|
2672
|
+
var vs = {
|
|
2673
|
+
refreshFromHost: cs,
|
|
2625
2674
|
get toolkitCoordinator() {
|
|
2626
2675
|
return r();
|
|
2627
2676
|
},
|
|
2628
|
-
set toolkitCoordinator(
|
|
2629
|
-
r(
|
|
2677
|
+
set toolkitCoordinator(h = null) {
|
|
2678
|
+
r(h), Ft();
|
|
2630
2679
|
},
|
|
2631
2680
|
get sectionId() {
|
|
2632
2681
|
return s();
|
|
2633
2682
|
},
|
|
2634
|
-
set sectionId(
|
|
2635
|
-
s(
|
|
2683
|
+
set sectionId(h = "") {
|
|
2684
|
+
s(h), Ft();
|
|
2636
2685
|
},
|
|
2637
2686
|
get attemptId() {
|
|
2638
2687
|
return i();
|
|
2639
2688
|
},
|
|
2640
|
-
set attemptId(
|
|
2641
|
-
i(
|
|
2689
|
+
set attemptId(h = void 0) {
|
|
2690
|
+
i(h), Ft();
|
|
2642
2691
|
}
|
|
2643
|
-
},
|
|
2692
|
+
}, Rt = so(), Nt = Ae(Rt), Xn = Ke(Ae(Nt), 2), gt = Ae(Xn), _s = Ae(gt);
|
|
2644
2693
|
{
|
|
2645
|
-
var
|
|
2646
|
-
var
|
|
2647
|
-
|
|
2648
|
-
},
|
|
2649
|
-
var
|
|
2650
|
-
|
|
2694
|
+
var ps = (h) => {
|
|
2695
|
+
var S = Gi();
|
|
2696
|
+
_e(h, S);
|
|
2697
|
+
}, gs = (h) => {
|
|
2698
|
+
var S = Zi();
|
|
2699
|
+
_e(h, S);
|
|
2651
2700
|
};
|
|
2652
|
-
|
|
2653
|
-
|
|
2701
|
+
Pt(_s, (h) => {
|
|
2702
|
+
m(o) ? h(ps) : h(gs, !1);
|
|
2654
2703
|
});
|
|
2655
2704
|
}
|
|
2656
|
-
|
|
2657
|
-
var
|
|
2658
|
-
|
|
2659
|
-
var
|
|
2705
|
+
Ie(gt);
|
|
2706
|
+
var ms = Ke(gt, 2);
|
|
2707
|
+
Ie(Xn), Ie(Nt);
|
|
2708
|
+
var Jn = Ke(Nt, 2);
|
|
2660
2709
|
{
|
|
2661
|
-
var
|
|
2662
|
-
var
|
|
2710
|
+
var ws = (h) => {
|
|
2711
|
+
var S = no(), R = Ae(S), N = Ke(Ae(R), 2);
|
|
2663
2712
|
{
|
|
2664
|
-
var
|
|
2665
|
-
var
|
|
2666
|
-
|
|
2667
|
-
},
|
|
2668
|
-
var
|
|
2669
|
-
|
|
2713
|
+
var un = (ve) => {
|
|
2714
|
+
var Le = Qi();
|
|
2715
|
+
_e(ve, Le);
|
|
2716
|
+
}, an = (ve) => {
|
|
2717
|
+
var Le = eo();
|
|
2718
|
+
_e(ve, Le);
|
|
2719
|
+
}, fn = /* @__PURE__ */ ai(() => Object.keys(m(Tt).itemSessions || {}).length === 0), $s = (ve) => {
|
|
2720
|
+
var Le = to(), Kn = Ke(Ae(Le), 2), Es = Ae(Kn, !0);
|
|
2721
|
+
Ie(Kn), Ie(Le), hn((Ss) => Oi(Es, Ss), [() => JSON.stringify(m(Tt), null, 2)]), _e(ve, Le);
|
|
2670
2722
|
};
|
|
2671
|
-
|
|
2672
|
-
|
|
2723
|
+
Pt(N, (ve) => {
|
|
2724
|
+
m(tn) ? m(fn) ? ve(an, 1) : ve($s, !1) : ve(un);
|
|
2673
2725
|
});
|
|
2674
2726
|
}
|
|
2675
|
-
|
|
2727
|
+
Ie(R), Ie(S), hn(() => or(S, `height: ${m(c) - 60}px;`)), _e(h, S);
|
|
2676
2728
|
};
|
|
2677
|
-
|
|
2678
|
-
|
|
2729
|
+
Pt(Jn, (h) => {
|
|
2730
|
+
m(o) || h(ws);
|
|
2679
2731
|
});
|
|
2680
2732
|
}
|
|
2681
|
-
var
|
|
2733
|
+
var bs = Ke(Jn, 2);
|
|
2682
2734
|
{
|
|
2683
|
-
var
|
|
2684
|
-
var
|
|
2685
|
-
|
|
2735
|
+
var ys = (h) => {
|
|
2736
|
+
var S = ro();
|
|
2737
|
+
Dt("mousedown", S, hs), _e(h, S);
|
|
2686
2738
|
};
|
|
2687
|
-
|
|
2688
|
-
|
|
2739
|
+
Pt(bs, (h) => {
|
|
2740
|
+
m(o) || h(ys);
|
|
2689
2741
|
});
|
|
2690
2742
|
}
|
|
2691
|
-
return
|
|
2692
|
-
|
|
2693
|
-
}),
|
|
2743
|
+
return Ie(Rt), hn(() => {
|
|
2744
|
+
or(Rt, `left: ${m(u) ?? ""}px; top: ${m(a) ?? ""}px; width: ${m(f) ?? ""}px; ${m(o) ? "height: auto;" : `height: ${m(c)}px;`}`), Bi(gt, "title", m(o) ? "Maximize" : "Minimize");
|
|
2745
|
+
}), Dt("mousedown", Nt, ds), Dt("click", gt, () => $(o, !m(o))), Dt("click", ms, () => n("close")), _e(e, Rt), br(vs);
|
|
2694
2746
|
}
|
|
2695
|
-
|
|
2696
|
-
customElements.define("pie-section-player-tools-session-debugger",
|
|
2697
|
-
|
|
2747
|
+
Ai(["mousedown", "click"]);
|
|
2748
|
+
customElements.define("pie-section-player-tools-session-debugger", Ki(
|
|
2749
|
+
io,
|
|
2698
2750
|
{
|
|
2699
2751
|
sectionId: { attribute: "section-id", type: "String" },
|
|
2700
2752
|
attemptId: { attribute: "attempt-id", type: "String" },
|
|
2701
2753
|
toolkitCoordinator: { attribute: "toolkit-coordinator", type: "Object" }
|
|
2702
2754
|
},
|
|
2703
2755
|
[],
|
|
2704
|
-
[]
|
|
2705
|
-
{ mode: "open" }
|
|
2756
|
+
["refreshFromHost"]
|
|
2706
2757
|
));
|
|
2707
2758
|
export {
|
|
2708
|
-
|
|
2759
|
+
io as default
|
|
2709
2760
|
};
|