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