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