@pie-players/pie-section-player 0.3.29 → 0.3.31
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/README.md +261 -21
- package/dist/chunks/dist-24a90544.js +193 -138
- package/dist/chunks/{dist-Bud4G4lv-b2620662.js → dist-DIBQdekL-ec6db34a.js} +120 -66
- package/dist/chunks/dist-c4148994.js +14 -2
- package/dist/chunks/{dist-DwP27yIs-cfd207a3.js → dist-rF11IR1B-adc4857f.js} +13 -1
- package/dist/chunks/module-c1d68911.js +1819 -1835
- package/dist/chunks/tool-annotation-toolbar-db5bfbec.js +1642 -1473
- package/dist/components/section-player-tabbed-element.d.ts +2 -0
- package/dist/components/section-player-tabbed-element.d.ts.map +1 -0
- package/dist/components/shared/player-preload.d.ts +88 -71
- package/dist/components/shared/player-preload.d.ts.map +1 -1
- package/dist/components/shared/section-player-host-runtime.d.ts +72 -0
- package/dist/components/shared/section-player-host-runtime.d.ts.map +1 -0
- package/dist/components/shared/section-player-runtime-callbacks.d.ts +33 -0
- package/dist/components/shared/section-player-runtime-callbacks.d.ts.map +1 -0
- package/dist/components/shared/section-player-view-state.d.ts.map +1 -1
- package/dist/contracts/host-hooks.d.ts +20 -0
- package/dist/contracts/host-hooks.d.ts.map +1 -1
- package/dist/contracts/layout-contract.d.ts +3 -3
- package/dist/contracts/layout-contract.d.ts.map +1 -1
- package/dist/contracts/layout-parity-metadata.d.ts +1 -0
- package/dist/contracts/layout-parity-metadata.d.ts.map +1 -1
- package/dist/contracts/public-events.d.ts +86 -10
- package/dist/contracts/public-events.d.ts.map +1 -1
- package/dist/contracts/runtime-host-contract.d.ts +13 -0
- package/dist/contracts/runtime-host-contract.d.ts.map +1 -1
- package/dist/contracts/stages.d.ts +11 -0
- package/dist/contracts/stages.d.ts.map +1 -0
- package/dist/controllers/SectionController.d.ts.map +1 -1
- package/dist/controllers/SectionItemNavigationService.d.ts +0 -1
- package/dist/controllers/SectionItemNavigationService.d.ts.map +1 -1
- package/dist/controllers/types.d.ts +16 -0
- package/dist/controllers/types.d.ts.map +1 -1
- package/dist/pie-section-player.d.ts +4 -4
- package/dist/pie-section-player.d.ts.map +1 -1
- package/dist/pie-section-player.js +19513 -6465
- package/dist/policies/index.d.ts +26 -1
- package/dist/policies/index.d.ts.map +1 -1
- package/dist/policies/types.d.ts +18 -1
- package/dist/policies/types.d.ts.map +1 -1
- package/package.json +21 -19
- package/dist/chunks/player-preload-79b07366.js +0 -7066
- package/dist/components/shared/section-player-readiness.d.ts +0 -14
- package/dist/components/shared/section-player-readiness.d.ts.map +0 -1
- package/dist/components/shared/section-player-runtime.d.ts +0 -154
- package/dist/components/shared/section-player-runtime.d.ts.map +0 -1
- package/dist/utils/player-preload.d.ts +0 -2
- package/dist/utils/player-preload.d.ts.map +0 -1
- package/dist/utils/player-preload.js +0 -8
- /package/dist/chunks/{defineProperty-318b8855.js → defineProperty-aab5a8e0.js} +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { t as y } from "./defineProperty-CyepwRr5-3800a70a.js";
|
|
2
2
|
if (typeof window < "u") {
|
|
3
|
-
var
|
|
4
|
-
((
|
|
3
|
+
var Ln, Pn;
|
|
4
|
+
((Ln = (Pn = window).__svelte ?? (Pn.__svelte = {})).v ?? (Ln.v = /* @__PURE__ */ new Set())).add("5");
|
|
5
5
|
}
|
|
6
|
-
var
|
|
6
|
+
var me = {}, N = Symbol(), li = Array.isArray, Ar = Array.prototype.indexOf, be = Array.prototype.includes, To = Array.from, ho = Object.keys, fo = Object.defineProperty, Qt = Object.getOwnPropertyDescriptor, xr = Object.getOwnPropertyDescriptors, _r = Object.prototype, Cr = Array.prototype, ci = Object.getPrototypeOf, On = Object.isExtensible, Er = () => {
|
|
7
7
|
};
|
|
8
|
-
function
|
|
8
|
+
function Mr(t) {
|
|
9
9
|
for (var e = 0; e < t.length; e++) t[e]();
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function ui() {
|
|
12
12
|
var t, e;
|
|
13
13
|
return {
|
|
14
14
|
promise: new Promise((o, n) => {
|
|
@@ -18,79 +18,82 @@ function ti() {
|
|
|
18
18
|
reject: e
|
|
19
19
|
};
|
|
20
20
|
}
|
|
21
|
-
var
|
|
21
|
+
var nt = 1024, vt = 2048, ce = 4096, nn = 8192, Lr = 16384, rn = 32768, Rn = 1 << 25, sn = 65536, $e = 1 << 19, Pr = 1 << 20, Oe = 1 << 25, ze = 65536, jn = 1 << 21, Or = 1 << 22, po = 1 << 23, Re = Symbol("$state"), di = Symbol("legacy props"), Rr = Symbol(""), Mt = new class extends Error {
|
|
22
22
|
constructor(...t) {
|
|
23
23
|
super(...t), y(this, "name", "StaleReactionError"), y(this, "message", "The reaction that called `getAbortSignal()` was re-run or destroyed");
|
|
24
24
|
}
|
|
25
|
-
}(),
|
|
26
|
-
function
|
|
25
|
+
}(), jr = !!globalThis.document?.contentType && /* @__PURE__ */ globalThis.document.contentType.includes("xml");
|
|
26
|
+
function Nr() {
|
|
27
27
|
throw new Error("https://svelte.dev/e/async_derived_orphan");
|
|
28
28
|
}
|
|
29
|
-
function
|
|
29
|
+
function Wr(t, e, o) {
|
|
30
30
|
throw new Error("https://svelte.dev/e/each_key_duplicate");
|
|
31
31
|
}
|
|
32
|
-
function
|
|
32
|
+
function Vr(t) {
|
|
33
33
|
throw new Error("https://svelte.dev/e/effect_in_teardown");
|
|
34
34
|
}
|
|
35
|
-
function
|
|
35
|
+
function zr() {
|
|
36
36
|
throw new Error("https://svelte.dev/e/effect_in_unowned_derived");
|
|
37
37
|
}
|
|
38
|
-
function
|
|
38
|
+
function qr(t) {
|
|
39
39
|
throw new Error("https://svelte.dev/e/effect_orphan");
|
|
40
40
|
}
|
|
41
|
-
function
|
|
41
|
+
function Dr() {
|
|
42
42
|
throw new Error("https://svelte.dev/e/effect_update_depth_exceeded");
|
|
43
43
|
}
|
|
44
|
-
function
|
|
44
|
+
function Hr() {
|
|
45
45
|
throw new Error("https://svelte.dev/e/hydration_failed");
|
|
46
46
|
}
|
|
47
|
-
function
|
|
47
|
+
function Br(t) {
|
|
48
48
|
throw new Error("https://svelte.dev/e/props_invalid_value");
|
|
49
49
|
}
|
|
50
|
-
function
|
|
50
|
+
function Fr() {
|
|
51
51
|
throw new Error("https://svelte.dev/e/state_descriptors_fixed");
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function Gr() {
|
|
54
54
|
throw new Error("https://svelte.dev/e/state_prototype_fixed");
|
|
55
55
|
}
|
|
56
|
-
function
|
|
56
|
+
function Ur() {
|
|
57
57
|
throw new Error("https://svelte.dev/e/state_unsafe_mutation");
|
|
58
58
|
}
|
|
59
|
-
function
|
|
59
|
+
function Jr() {
|
|
60
60
|
throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror");
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function Kr() {
|
|
63
|
+
console.warn("https://svelte.dev/e/derived_inert");
|
|
64
|
+
}
|
|
65
|
+
function Io(t) {
|
|
63
66
|
console.warn("https://svelte.dev/e/hydration_mismatch");
|
|
64
67
|
}
|
|
65
|
-
function
|
|
68
|
+
function Zr() {
|
|
66
69
|
console.warn("https://svelte.dev/e/svelte_boundary_reset_noop");
|
|
67
70
|
}
|
|
68
|
-
var
|
|
69
|
-
function
|
|
70
|
-
|
|
71
|
+
var P = !1;
|
|
72
|
+
function Lt(t) {
|
|
73
|
+
P = t;
|
|
71
74
|
}
|
|
72
|
-
var
|
|
73
|
-
function
|
|
74
|
-
if (t === null) throw
|
|
75
|
-
return
|
|
75
|
+
var L;
|
|
76
|
+
function U(t) {
|
|
77
|
+
if (t === null) throw Io(), me;
|
|
78
|
+
return L = t;
|
|
76
79
|
}
|
|
77
|
-
function
|
|
78
|
-
return
|
|
80
|
+
function ko() {
|
|
81
|
+
return U(/* @__PURE__ */ St(L));
|
|
79
82
|
}
|
|
80
|
-
function
|
|
81
|
-
if (
|
|
82
|
-
if (/* @__PURE__ */
|
|
83
|
-
|
|
83
|
+
function Ue(t) {
|
|
84
|
+
if (P) {
|
|
85
|
+
if (/* @__PURE__ */ St(L) !== null) throw Io(), me;
|
|
86
|
+
L = t;
|
|
84
87
|
}
|
|
85
88
|
}
|
|
86
|
-
function
|
|
87
|
-
if (
|
|
88
|
-
for (var e = t, o =
|
|
89
|
-
|
|
89
|
+
function Yr(t = 1) {
|
|
90
|
+
if (P) {
|
|
91
|
+
for (var e = t, o = L; e--; ) o = /* @__PURE__ */ St(o);
|
|
92
|
+
L = o;
|
|
90
93
|
}
|
|
91
94
|
}
|
|
92
|
-
function
|
|
93
|
-
for (var e = 0, o =
|
|
95
|
+
function vo(t = !0) {
|
|
96
|
+
for (var e = 0, o = L; ; ) {
|
|
94
97
|
if (o.nodeType === 8) {
|
|
95
98
|
var n = o.data;
|
|
96
99
|
if (n === "]") {
|
|
@@ -98,78 +101,78 @@ function ao(t = !0) {
|
|
|
98
101
|
e -= 1;
|
|
99
102
|
} else (n === "[" || n === "[!" || n[0] === "[" && !isNaN(Number(n.slice(1)))) && (e += 1);
|
|
100
103
|
}
|
|
101
|
-
var i = /* @__PURE__ */
|
|
104
|
+
var i = /* @__PURE__ */ St(o);
|
|
102
105
|
t && o.remove(), o = i;
|
|
103
106
|
}
|
|
104
107
|
}
|
|
105
|
-
function
|
|
106
|
-
if (!t || t.nodeType !== 8) throw
|
|
108
|
+
function hi(t) {
|
|
109
|
+
if (!t || t.nodeType !== 8) throw Io(), me;
|
|
107
110
|
return t.data;
|
|
108
111
|
}
|
|
109
|
-
function
|
|
112
|
+
function fi(t) {
|
|
110
113
|
return t === this.v;
|
|
111
114
|
}
|
|
112
|
-
function
|
|
115
|
+
function Xr(t, e) {
|
|
113
116
|
return t != t ? e == e : t !== e || t !== null && typeof t == "object" || typeof t == "function";
|
|
114
117
|
}
|
|
115
|
-
function
|
|
116
|
-
return !
|
|
118
|
+
function pi(t) {
|
|
119
|
+
return !Xr(t, this.v);
|
|
117
120
|
}
|
|
118
|
-
var
|
|
119
|
-
function
|
|
120
|
-
|
|
121
|
+
var Pt = !1, $o = !1, V = null;
|
|
122
|
+
function ye(t) {
|
|
123
|
+
V = t;
|
|
121
124
|
}
|
|
122
|
-
function
|
|
123
|
-
|
|
124
|
-
p:
|
|
125
|
+
function vi(t, e = !1, o) {
|
|
126
|
+
V = {
|
|
127
|
+
p: V,
|
|
125
128
|
i: !1,
|
|
126
129
|
c: null,
|
|
127
130
|
e: null,
|
|
128
131
|
s: t,
|
|
129
132
|
x: null,
|
|
130
|
-
r:
|
|
131
|
-
l:
|
|
133
|
+
r: S,
|
|
134
|
+
l: $o && !e ? {
|
|
132
135
|
s: null,
|
|
133
136
|
u: null,
|
|
134
137
|
$: []
|
|
135
138
|
} : null
|
|
136
139
|
};
|
|
137
140
|
}
|
|
138
|
-
function
|
|
139
|
-
var e =
|
|
141
|
+
function gi(t) {
|
|
142
|
+
var e = V, o = e.e;
|
|
140
143
|
if (o !== null) {
|
|
141
144
|
e.e = null;
|
|
142
|
-
for (var n of o)
|
|
145
|
+
for (var n of o) Hi(n);
|
|
143
146
|
}
|
|
144
|
-
return t !== void 0 && (e.x = t), e.i = !0,
|
|
147
|
+
return t !== void 0 && (e.x = t), e.i = !0, V = e.p, t ?? {};
|
|
145
148
|
}
|
|
146
|
-
function
|
|
147
|
-
return
|
|
149
|
+
function qe() {
|
|
150
|
+
return !$o || V !== null && V.l === null;
|
|
148
151
|
}
|
|
149
|
-
var
|
|
150
|
-
function
|
|
151
|
-
var t =
|
|
152
|
-
|
|
152
|
+
var Zt = [];
|
|
153
|
+
function mi() {
|
|
154
|
+
var t = Zt;
|
|
155
|
+
Zt = [], Mr(t);
|
|
153
156
|
}
|
|
154
|
-
function
|
|
155
|
-
if (
|
|
156
|
-
var e =
|
|
157
|
+
function se(t) {
|
|
158
|
+
if (Zt.length === 0 && !je) {
|
|
159
|
+
var e = Zt;
|
|
157
160
|
queueMicrotask(() => {
|
|
158
|
-
e ===
|
|
161
|
+
e === Zt && mi();
|
|
159
162
|
});
|
|
160
163
|
}
|
|
161
|
-
|
|
164
|
+
Zt.push(t);
|
|
162
165
|
}
|
|
163
|
-
function
|
|
164
|
-
for (;
|
|
166
|
+
function Qr() {
|
|
167
|
+
for (; Zt.length > 0; ) mi();
|
|
165
168
|
}
|
|
166
|
-
function
|
|
167
|
-
var e =
|
|
168
|
-
if (e === null) return
|
|
169
|
+
function bi(t) {
|
|
170
|
+
var e = S;
|
|
171
|
+
if (e === null) return _.f |= po, t;
|
|
169
172
|
if (!(e.f & 32768) && !(e.f & 4)) throw t;
|
|
170
|
-
|
|
173
|
+
Bt(t, e);
|
|
171
174
|
}
|
|
172
|
-
function
|
|
175
|
+
function Bt(t, e) {
|
|
173
176
|
for (; e !== null; ) {
|
|
174
177
|
if (e.f & 128) {
|
|
175
178
|
if (!(e.f & 32768)) throw t;
|
|
@@ -184,183 +187,222 @@ function Vt(t, e) {
|
|
|
184
187
|
}
|
|
185
188
|
throw t;
|
|
186
189
|
}
|
|
187
|
-
var
|
|
188
|
-
function
|
|
189
|
-
t.f = t.f &
|
|
190
|
+
var ts = ~(vt | ce | nt);
|
|
191
|
+
function j(t, e) {
|
|
192
|
+
t.f = t.f & ts | e;
|
|
190
193
|
}
|
|
191
|
-
function
|
|
192
|
-
t.f & 512 || t.deps === null ?
|
|
194
|
+
function an(t) {
|
|
195
|
+
t.f & 512 || t.deps === null ? j(t, nt) : j(t, ce);
|
|
193
196
|
}
|
|
194
|
-
function
|
|
195
|
-
if (t !== null) for (const e of t) !(e.f & 2) || !(e.f & 65536) || (e.f ^=
|
|
197
|
+
function yi(t) {
|
|
198
|
+
if (t !== null) for (const e of t) !(e.f & 2) || !(e.f & 65536) || (e.f ^= ze, yi(e.deps));
|
|
196
199
|
}
|
|
197
|
-
function
|
|
198
|
-
t.f & 2048 ? e.add(t) : t.f & 4096 && o.add(t),
|
|
200
|
+
function wi(t, e, o) {
|
|
201
|
+
t.f & 2048 ? e.add(t) : t.f & 4096 && o.add(t), yi(t.deps), j(t, nt);
|
|
199
202
|
}
|
|
200
|
-
var
|
|
201
|
-
function
|
|
202
|
-
var e =
|
|
203
|
+
var es = !1, Je = !1;
|
|
204
|
+
function os(t) {
|
|
205
|
+
var e = Je;
|
|
203
206
|
try {
|
|
204
|
-
return
|
|
207
|
+
return Je = !1, [t(), Je];
|
|
205
208
|
} finally {
|
|
206
|
-
|
|
209
|
+
Je = e;
|
|
207
210
|
}
|
|
208
211
|
}
|
|
209
|
-
function
|
|
212
|
+
function Ti(t, e) {
|
|
210
213
|
if (e.has(t)) throw new TypeError("Cannot initialize the same private elements twice on an object");
|
|
211
214
|
}
|
|
212
|
-
function
|
|
213
|
-
|
|
215
|
+
function ln(t, e) {
|
|
216
|
+
Ti(t, e), e.add(t);
|
|
214
217
|
}
|
|
215
|
-
function
|
|
216
|
-
|
|
218
|
+
function I(t, e, o) {
|
|
219
|
+
Ti(t, e), e.set(t, o);
|
|
217
220
|
}
|
|
218
|
-
function
|
|
221
|
+
function E(t, e, o) {
|
|
219
222
|
if (typeof t == "function" ? t === e : t.has(e)) return arguments.length < 3 ? e : o;
|
|
220
223
|
throw new TypeError("Private element is not present on this object");
|
|
221
224
|
}
|
|
222
|
-
function
|
|
223
|
-
return t.get(
|
|
225
|
+
function c(t, e) {
|
|
226
|
+
return t.get(E(t, e));
|
|
224
227
|
}
|
|
225
|
-
function
|
|
226
|
-
return t.set(
|
|
228
|
+
function $(t, e, o) {
|
|
229
|
+
return t.set(E(t, e), o), o;
|
|
227
230
|
}
|
|
228
|
-
var
|
|
231
|
+
var Ii, It = /* @__PURE__ */ new Set(), x = null, q = null, Ho = null, je = !1, Co = !1, we = null, go = null, ki = 0, ns = 1, mo = /* @__PURE__ */ new WeakMap(), Ke = /* @__PURE__ */ new WeakMap(), xe = /* @__PURE__ */ new WeakMap(), Kt = /* @__PURE__ */ new WeakMap(), qt = /* @__PURE__ */ new WeakMap(), oo = /* @__PURE__ */ new WeakMap(), dt = /* @__PURE__ */ new WeakMap(), Bo = /* @__PURE__ */ new WeakMap(), Te = /* @__PURE__ */ new WeakMap(), te = /* @__PURE__ */ new WeakMap(), Ht = /* @__PURE__ */ new WeakMap(), no = /* @__PURE__ */ new WeakMap(), Ze = /* @__PURE__ */ new WeakMap(), ge = /* @__PURE__ */ new WeakMap(), F = /* @__PURE__ */ new WeakSet(), ue = class $i {
|
|
229
232
|
constructor() {
|
|
230
|
-
|
|
233
|
+
ln(this, F), y(this, "id", ns++), y(this, "current", /* @__PURE__ */ new Map()), y(this, "previous", /* @__PURE__ */ new Map()), I(this, mo, /* @__PURE__ */ new Set()), I(this, Ke, /* @__PURE__ */ new Set()), I(this, xe, /* @__PURE__ */ new Set()), I(this, Kt, /* @__PURE__ */ new Map()), I(this, qt, /* @__PURE__ */ new Map()), I(this, oo, null), I(this, dt, []), I(this, Bo, []), I(this, Te, /* @__PURE__ */ new Set()), I(this, te, /* @__PURE__ */ new Set()), I(this, Ht, /* @__PURE__ */ new Map()), I(this, no, /* @__PURE__ */ new Set()), y(this, "is_fork", !1), I(this, Ze, !1), I(this, ge, /* @__PURE__ */ new Set());
|
|
231
234
|
}
|
|
232
235
|
skip_effect(e) {
|
|
233
|
-
|
|
236
|
+
c(Ht, this).has(e) || c(Ht, this).set(e, {
|
|
234
237
|
d: [],
|
|
235
238
|
m: []
|
|
236
|
-
});
|
|
237
|
-
}
|
|
238
|
-
unskip_effect(e) {
|
|
239
|
-
var
|
|
240
|
-
if (
|
|
241
|
-
|
|
242
|
-
for (var
|
|
243
|
-
for (
|
|
239
|
+
}), c(no, this).delete(e);
|
|
240
|
+
}
|
|
241
|
+
unskip_effect(e, o = (n) => this.schedule(n)) {
|
|
242
|
+
var n = c(Ht, this).get(e);
|
|
243
|
+
if (n) {
|
|
244
|
+
c(Ht, this).delete(e);
|
|
245
|
+
for (var i of n.d) j(i, vt), o(i);
|
|
246
|
+
for (i of n.m) j(i, ce), o(i);
|
|
244
247
|
}
|
|
248
|
+
c(no, this).add(e);
|
|
245
249
|
}
|
|
246
|
-
capture(e, o) {
|
|
247
|
-
|
|
250
|
+
capture(e, o, n = !1) {
|
|
251
|
+
e.v !== N && !this.previous.has(e) && this.previous.set(e, e.v), e.f & 8388608 || (this.current.set(e, [o, n]), q?.set(e, o)), this.is_fork || (e.v = o);
|
|
248
252
|
}
|
|
249
253
|
activate() {
|
|
250
|
-
|
|
254
|
+
x = this;
|
|
251
255
|
}
|
|
252
256
|
deactivate() {
|
|
253
|
-
|
|
257
|
+
x = null, q = null;
|
|
254
258
|
}
|
|
255
259
|
flush() {
|
|
256
260
|
try {
|
|
257
|
-
|
|
261
|
+
Co = !0, x = this, E(F, this, cn).call(this);
|
|
258
262
|
} finally {
|
|
259
|
-
|
|
263
|
+
ki = 0, Ho = null, we = null, go = null, Co = !1, x = null, q = null, ne.clear();
|
|
260
264
|
}
|
|
261
265
|
}
|
|
262
266
|
discard() {
|
|
263
|
-
for (const e of
|
|
264
|
-
|
|
267
|
+
for (const e of c(Ke, this)) e(this);
|
|
268
|
+
c(Ke, this).clear(), c(xe, this).clear(), It.delete(this);
|
|
265
269
|
}
|
|
266
|
-
|
|
267
|
-
|
|
270
|
+
register_created_effect(e) {
|
|
271
|
+
c(Bo, this).push(e);
|
|
272
|
+
}
|
|
273
|
+
increment(e, o) {
|
|
274
|
+
let n = c(Kt, this).get(o) ?? 0;
|
|
275
|
+
if (c(Kt, this).set(o, n + 1), e) {
|
|
276
|
+
let i = c(qt, this).get(o) ?? 0;
|
|
277
|
+
c(qt, this).set(o, i + 1);
|
|
278
|
+
}
|
|
268
279
|
}
|
|
269
|
-
decrement(e, o) {
|
|
270
|
-
|
|
271
|
-
|
|
280
|
+
decrement(e, o, n) {
|
|
281
|
+
let i = c(Kt, this).get(o) ?? 0;
|
|
282
|
+
if (i === 1 ? c(Kt, this).delete(o) : c(Kt, this).set(o, i - 1), e) {
|
|
283
|
+
let r = c(qt, this).get(o) ?? 0;
|
|
284
|
+
r === 1 ? c(qt, this).delete(o) : c(qt, this).set(o, r - 1);
|
|
285
|
+
}
|
|
286
|
+
c(Ze, this) || n || ($(Ze, this, !0), se(() => {
|
|
287
|
+
$(Ze, this, !1), this.flush();
|
|
272
288
|
}));
|
|
273
289
|
}
|
|
274
290
|
transfer_effects(e, o) {
|
|
275
|
-
for (const n of e)
|
|
276
|
-
for (const n of o)
|
|
291
|
+
for (const n of e) c(Te, this).add(n);
|
|
292
|
+
for (const n of o) c(te, this).add(n);
|
|
277
293
|
e.clear(), o.clear();
|
|
278
294
|
}
|
|
279
295
|
oncommit(e) {
|
|
280
|
-
|
|
296
|
+
c(mo, this).add(e);
|
|
281
297
|
}
|
|
282
298
|
ondiscard(e) {
|
|
283
|
-
|
|
299
|
+
c(Ke, this).add(e);
|
|
300
|
+
}
|
|
301
|
+
on_fork_commit(e) {
|
|
302
|
+
c(xe, this).add(e);
|
|
303
|
+
}
|
|
304
|
+
run_fork_commit_callbacks() {
|
|
305
|
+
for (const e of c(xe, this)) e(this);
|
|
306
|
+
c(xe, this).clear();
|
|
284
307
|
}
|
|
285
308
|
settled() {
|
|
286
|
-
return (
|
|
309
|
+
return (c(oo, this) ?? $(oo, this, ui())).promise;
|
|
287
310
|
}
|
|
288
311
|
static ensure() {
|
|
289
|
-
if (
|
|
290
|
-
const e =
|
|
291
|
-
|
|
292
|
-
|
|
312
|
+
if (x === null) {
|
|
313
|
+
const e = x = new $i();
|
|
314
|
+
Co || (It.add(x), je || se(() => {
|
|
315
|
+
x === e && e.flush();
|
|
293
316
|
}));
|
|
294
317
|
}
|
|
295
|
-
return
|
|
318
|
+
return x;
|
|
296
319
|
}
|
|
297
320
|
apply() {
|
|
298
|
-
if (!
|
|
299
|
-
|
|
321
|
+
if (!Pt || !this.is_fork && It.size === 1) {
|
|
322
|
+
q = null;
|
|
300
323
|
return;
|
|
301
324
|
}
|
|
302
|
-
|
|
303
|
-
for (const
|
|
325
|
+
q = /* @__PURE__ */ new Map();
|
|
326
|
+
for (const [n, [i]] of this.current) q.set(n, i);
|
|
327
|
+
for (const n of It) if (!(n === this || n.is_fork)) {
|
|
328
|
+
var e = !1, o = !1;
|
|
329
|
+
if (n.id < this.id) for (const [i, [, r]] of n.current) r || (e || (e = this.current.has(i)), o || (o = !this.current.has(i)));
|
|
330
|
+
if (e && o) c(ge, this).add(n);
|
|
331
|
+
else for (const [i, r] of n.previous) q.has(i) || q.set(i, r);
|
|
332
|
+
}
|
|
304
333
|
}
|
|
305
334
|
schedule(e) {
|
|
306
|
-
if (
|
|
335
|
+
if (Ho = e, e.b?.is_pending && e.f & 16777228 && !(e.f & 32768)) {
|
|
307
336
|
e.b.defer_effect(e);
|
|
308
337
|
return;
|
|
309
338
|
}
|
|
310
339
|
for (var o = e; o.parent !== null; ) {
|
|
311
340
|
o = o.parent;
|
|
312
341
|
var n = o.f;
|
|
313
|
-
if (
|
|
342
|
+
if (we !== null && o === S && (Pt || (_ === null || !(_.f & 2)) && !es)) return;
|
|
314
343
|
if (n & 96) {
|
|
315
344
|
if (!(n & 1024)) return;
|
|
316
|
-
o.f ^=
|
|
345
|
+
o.f ^= nt;
|
|
317
346
|
}
|
|
318
347
|
}
|
|
319
|
-
|
|
348
|
+
c(dt, this).push(o);
|
|
320
349
|
}
|
|
321
350
|
};
|
|
322
|
-
|
|
323
|
-
function
|
|
324
|
-
return this.is_fork ||
|
|
325
|
-
}
|
|
326
|
-
function
|
|
327
|
-
|
|
328
|
-
for (
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
351
|
+
Ii = ue;
|
|
352
|
+
function Fo() {
|
|
353
|
+
return this.is_fork || c(qt, this).size > 0;
|
|
354
|
+
}
|
|
355
|
+
function is() {
|
|
356
|
+
for (const o of c(ge, this)) for (const n of c(qt, o).keys()) {
|
|
357
|
+
for (var t = !1, e = n; e.parent !== null; ) {
|
|
358
|
+
if (c(Ht, this).has(e)) {
|
|
359
|
+
t = !0;
|
|
360
|
+
break;
|
|
361
|
+
}
|
|
362
|
+
e = e.parent;
|
|
363
|
+
}
|
|
364
|
+
if (!t) return !0;
|
|
365
|
+
}
|
|
366
|
+
return !1;
|
|
367
|
+
}
|
|
368
|
+
function cn() {
|
|
369
|
+
if (ki++ > 1e3 && (It.delete(this), ss()), !E(F, this, Fo).call(this)) {
|
|
370
|
+
for (const s of c(Te, this)) c(te, this).delete(s), j(s, vt), this.schedule(s);
|
|
371
|
+
for (const s of c(te, this)) j(s, ce), this.schedule(s);
|
|
372
|
+
}
|
|
373
|
+
const t = c(dt, this);
|
|
374
|
+
$(dt, this, []), this.apply();
|
|
375
|
+
var e = we = [], o = [], n = go = [];
|
|
334
376
|
for (const s of t) try {
|
|
335
|
-
|
|
336
|
-
} catch (
|
|
337
|
-
throw
|
|
377
|
+
E(F, this, Si).call(this, s, e, o);
|
|
378
|
+
} catch (a) {
|
|
379
|
+
throw _i(s), a;
|
|
338
380
|
}
|
|
339
|
-
if (
|
|
340
|
-
var i =
|
|
381
|
+
if (x = null, n.length > 0) {
|
|
382
|
+
var i = Ii.ensure();
|
|
341
383
|
for (const s of n) i.schedule(s);
|
|
342
384
|
}
|
|
343
|
-
if (
|
|
344
|
-
|
|
345
|
-
for (const [s,
|
|
385
|
+
if (we = null, go = null, E(F, this, Fo).call(this) || E(F, this, is).call(this)) {
|
|
386
|
+
E(F, this, Go).call(this, o), E(F, this, Go).call(this, e);
|
|
387
|
+
for (const [s, a] of c(Ht, this)) xi(s, a);
|
|
346
388
|
} else {
|
|
347
|
-
|
|
348
|
-
for (const s of
|
|
349
|
-
|
|
389
|
+
c(Kt, this).size === 0 && It.delete(this), c(Te, this).clear(), c(te, this).clear();
|
|
390
|
+
for (const s of c(mo, this)) s(this);
|
|
391
|
+
c(mo, this).clear(), Nn(o), Nn(e), c(oo, this)?.resolve();
|
|
350
392
|
}
|
|
351
|
-
var r =
|
|
352
|
-
if (
|
|
393
|
+
var r = x;
|
|
394
|
+
if (c(dt, this).length > 0) {
|
|
353
395
|
const s = r ?? (r = this);
|
|
354
|
-
|
|
396
|
+
c(dt, s).push(...c(dt, this).filter((a) => !c(dt, s).includes(a)));
|
|
355
397
|
}
|
|
356
|
-
r !== null && (
|
|
398
|
+
r !== null && (It.add(r), E(F, r, cn).call(r)), Pt && !It.has(this) && E(F, this, rs).call(this);
|
|
357
399
|
}
|
|
358
|
-
function
|
|
359
|
-
t.f ^=
|
|
400
|
+
function Si(t, e, o) {
|
|
401
|
+
t.f ^= nt;
|
|
360
402
|
for (var n = t.first; n !== null; ) {
|
|
361
403
|
var i = n.f, r = (i & 96) !== 0;
|
|
362
|
-
if (!(r && i & 1024 || i & 8192 ||
|
|
363
|
-
r ? n.f ^=
|
|
404
|
+
if (!(r && i & 1024 || i & 8192 || c(Ht, this).has(n)) && n.fn !== null) {
|
|
405
|
+
r ? n.f ^= nt : i & 4 ? e.push(n) : Pt && i & 16777224 ? o.push(n) : De(n) && (i & 16 && c(te, this).add(n), ke(n));
|
|
364
406
|
var s = n.first;
|
|
365
407
|
if (s !== null) {
|
|
366
408
|
n = s;
|
|
@@ -368,542 +410,550 @@ function gi(t, e, o) {
|
|
|
368
410
|
}
|
|
369
411
|
}
|
|
370
412
|
for (; n !== null; ) {
|
|
371
|
-
var
|
|
372
|
-
if (
|
|
373
|
-
n =
|
|
413
|
+
var a = n.next;
|
|
414
|
+
if (a !== null) {
|
|
415
|
+
n = a;
|
|
374
416
|
break;
|
|
375
417
|
}
|
|
376
418
|
n = n.parent;
|
|
377
419
|
}
|
|
378
420
|
}
|
|
379
421
|
}
|
|
380
|
-
function
|
|
381
|
-
for (var e = 0; e < t.length; e += 1)
|
|
422
|
+
function Go(t) {
|
|
423
|
+
for (var e = 0; e < t.length; e += 1) wi(t[e], c(Te, this), c(te, this));
|
|
382
424
|
}
|
|
383
|
-
function
|
|
384
|
-
for (const l of
|
|
425
|
+
function rs() {
|
|
426
|
+
for (const l of It) {
|
|
385
427
|
var t = l.id < this.id, e = [];
|
|
386
|
-
for (const [
|
|
387
|
-
if (l.current.has(
|
|
388
|
-
|
|
389
|
-
|
|
428
|
+
for (const [d, [h, f]] of this.current) {
|
|
429
|
+
if (l.current.has(d)) {
|
|
430
|
+
var o = l.current.get(d)[0];
|
|
431
|
+
if (t && h !== o) l.current.set(d, [h, f]);
|
|
432
|
+
else continue;
|
|
433
|
+
}
|
|
434
|
+
e.push(d);
|
|
390
435
|
}
|
|
391
|
-
var
|
|
392
|
-
if (
|
|
436
|
+
var n = [...l.current.keys()].filter((d) => !this.current.has(d));
|
|
437
|
+
if (n.length === 0) t && l.discard();
|
|
393
438
|
else if (e.length > 0) {
|
|
439
|
+
if (t) for (const d of c(no, this)) l.unskip_effect(d, (h) => {
|
|
440
|
+
h.f & 4194320 ? l.schedule(h) : E(F, l, Go).call(l, [h]);
|
|
441
|
+
});
|
|
394
442
|
l.activate();
|
|
395
|
-
var
|
|
396
|
-
for (var
|
|
397
|
-
|
|
443
|
+
var i = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Map();
|
|
444
|
+
for (var s of e) Ai(s, n, i, r);
|
|
445
|
+
r = /* @__PURE__ */ new Map();
|
|
446
|
+
var a = [...l.current.keys()].filter((d) => this.current.has(d) ? this.current.get(d)[0] !== d : !0);
|
|
447
|
+
for (const d of c(Bo, this)) !(d.f & 155648) && un(d, a, r) && (d.f & 4194320 ? (j(d, vt), l.schedule(d)) : c(Te, l).add(d));
|
|
448
|
+
if (c(dt, l).length > 0) {
|
|
398
449
|
l.apply();
|
|
399
|
-
for (var
|
|
400
|
-
|
|
450
|
+
for (var u of c(dt, l)) E(F, l, Si).call(l, u, [], []);
|
|
451
|
+
$(dt, l, []);
|
|
401
452
|
}
|
|
402
453
|
l.deactivate();
|
|
403
454
|
}
|
|
404
455
|
}
|
|
456
|
+
for (const l of It) c(ge, l).has(this) && (c(ge, l).delete(this), c(ge, l).size === 0 && !E(F, l, Fo).call(l) && (l.activate(), E(F, l, cn).call(l)));
|
|
405
457
|
}
|
|
406
|
-
function
|
|
407
|
-
var e =
|
|
408
|
-
|
|
458
|
+
function io(t) {
|
|
459
|
+
var e = je;
|
|
460
|
+
je = !0;
|
|
409
461
|
try {
|
|
410
462
|
var o;
|
|
411
|
-
for (t && (
|
|
412
|
-
if (
|
|
413
|
-
|
|
463
|
+
for (t && (x !== null && !x.is_fork && x.flush(), o = t()); ; ) {
|
|
464
|
+
if (Qr(), x === null) return o;
|
|
465
|
+
x.flush();
|
|
414
466
|
}
|
|
415
467
|
} finally {
|
|
416
|
-
|
|
468
|
+
je = e;
|
|
417
469
|
}
|
|
418
470
|
}
|
|
419
|
-
function
|
|
471
|
+
function ss() {
|
|
420
472
|
try {
|
|
421
|
-
|
|
473
|
+
Dr();
|
|
422
474
|
} catch (t) {
|
|
423
|
-
|
|
475
|
+
Bt(t, Ho);
|
|
424
476
|
}
|
|
425
477
|
}
|
|
426
|
-
var
|
|
427
|
-
function
|
|
478
|
+
var wt = null;
|
|
479
|
+
function Nn(t) {
|
|
428
480
|
var e = t.length;
|
|
429
481
|
if (e !== 0) {
|
|
430
482
|
for (var o = 0; o < e; ) {
|
|
431
483
|
var n = t[o++];
|
|
432
|
-
if (!(n.f & 24576) &&
|
|
433
|
-
|
|
434
|
-
for (const i of
|
|
484
|
+
if (!(n.f & 24576) && De(n) && (wt = /* @__PURE__ */ new Set(), ke(n), n.deps === null && n.first === null && n.nodes === null && n.teardown === null && n.ac === null && Gi(n), wt?.size > 0)) {
|
|
485
|
+
ne.clear();
|
|
486
|
+
for (const i of wt) {
|
|
435
487
|
if (i.f & 24576) continue;
|
|
436
488
|
const r = [i];
|
|
437
489
|
let s = i.parent;
|
|
438
|
-
for (; s !== null; )
|
|
439
|
-
for (let
|
|
440
|
-
const
|
|
441
|
-
|
|
490
|
+
for (; s !== null; ) wt.has(s) && (wt.delete(s), r.push(s)), s = s.parent;
|
|
491
|
+
for (let a = r.length - 1; a >= 0; a--) {
|
|
492
|
+
const u = r[a];
|
|
493
|
+
u.f & 24576 || ke(u);
|
|
442
494
|
}
|
|
443
495
|
}
|
|
444
|
-
|
|
496
|
+
wt.clear();
|
|
445
497
|
}
|
|
446
498
|
}
|
|
447
|
-
|
|
499
|
+
wt = null;
|
|
448
500
|
}
|
|
449
501
|
}
|
|
450
|
-
function
|
|
502
|
+
function Ai(t, e, o, n) {
|
|
451
503
|
if (!o.has(t) && (o.add(t), t.reactions !== null)) for (const i of t.reactions) {
|
|
452
504
|
const r = i.f;
|
|
453
|
-
r & 2 ?
|
|
505
|
+
r & 2 ? Ai(i, e, o, n) : r & 4194320 && !(r & 2048) && un(i, e, n) && (j(i, vt), dn(i));
|
|
454
506
|
}
|
|
455
507
|
}
|
|
456
|
-
function
|
|
508
|
+
function un(t, e, o) {
|
|
457
509
|
const n = o.get(t);
|
|
458
510
|
if (n !== void 0) return n;
|
|
459
511
|
if (t.deps !== null) for (const i of t.deps) {
|
|
460
|
-
if (
|
|
461
|
-
if (i.f & 2 &&
|
|
512
|
+
if (be.call(e, i)) return !0;
|
|
513
|
+
if (i.f & 2 && un(i, e, o)) return o.set(i, !0), !0;
|
|
462
514
|
}
|
|
463
515
|
return o.set(t, !1), !1;
|
|
464
516
|
}
|
|
465
|
-
function
|
|
466
|
-
|
|
517
|
+
function dn(t) {
|
|
518
|
+
x.schedule(t);
|
|
467
519
|
}
|
|
468
|
-
function
|
|
520
|
+
function xi(t, e) {
|
|
469
521
|
if (!(t.f & 32 && t.f & 1024)) {
|
|
470
|
-
t.f & 2048 ? e.d.push(t) : t.f & 4096 && e.m.push(t),
|
|
471
|
-
for (var o = t.first; o !== null; )
|
|
522
|
+
t.f & 2048 ? e.d.push(t) : t.f & 4096 && e.m.push(t), j(t, nt);
|
|
523
|
+
for (var o = t.first; o !== null; ) xi(o, e), o = o.next;
|
|
472
524
|
}
|
|
473
525
|
}
|
|
474
|
-
function
|
|
475
|
-
|
|
476
|
-
for (var e = t.first; e !== null; )
|
|
526
|
+
function _i(t) {
|
|
527
|
+
j(t, nt);
|
|
528
|
+
for (var e = t.first; e !== null; ) _i(e), e = e.next;
|
|
477
529
|
}
|
|
478
|
-
function
|
|
479
|
-
let e = 0, o =
|
|
530
|
+
function as(t) {
|
|
531
|
+
let e = 0, o = ae(0), n;
|
|
480
532
|
return () => {
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
e -= 1, e === 0 && (n?.(), n = void 0,
|
|
533
|
+
mn() && (g(o), bn(() => (e === 0 && (n = kn(() => t(() => Ne(o)))), e += 1, () => {
|
|
534
|
+
se(() => {
|
|
535
|
+
e -= 1, e === 0 && (n?.(), n = void 0, Ne(o));
|
|
484
536
|
});
|
|
485
537
|
})));
|
|
486
538
|
};
|
|
487
539
|
}
|
|
488
|
-
var
|
|
489
|
-
function
|
|
490
|
-
new
|
|
540
|
+
var ls = sn | $e;
|
|
541
|
+
function cs(t, e, o, n) {
|
|
542
|
+
new us(t, e, o, n);
|
|
491
543
|
}
|
|
492
|
-
var
|
|
544
|
+
var ft = /* @__PURE__ */ new WeakMap(), Uo = /* @__PURE__ */ new WeakMap(), Tt = /* @__PURE__ */ new WeakMap(), We = /* @__PURE__ */ new WeakMap(), et = /* @__PURE__ */ new WeakMap(), kt = /* @__PURE__ */ new WeakMap(), X = /* @__PURE__ */ new WeakMap(), ut = /* @__PURE__ */ new WeakMap(), ee = /* @__PURE__ */ new WeakMap(), fe = /* @__PURE__ */ new WeakMap(), oe = /* @__PURE__ */ new WeakMap(), Ye = /* @__PURE__ */ new WeakMap(), Jo = /* @__PURE__ */ new WeakMap(), Ko = /* @__PURE__ */ new WeakMap(), Ut = /* @__PURE__ */ new WeakMap(), Wn = /* @__PURE__ */ new WeakMap(), z = /* @__PURE__ */ new WeakSet(), us = class {
|
|
493
545
|
constructor(t, e, o, n) {
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
}))),
|
|
497
|
-
var r =
|
|
546
|
+
ln(this, z), y(this, "parent", void 0), y(this, "is_pending", !1), y(this, "transform_error", void 0), I(this, ft, void 0), I(this, Uo, P ? L : null), I(this, Tt, void 0), I(this, We, void 0), I(this, et, void 0), I(this, kt, null), I(this, X, null), I(this, ut, null), I(this, ee, null), I(this, fe, 0), I(this, oe, 0), I(this, Ye, !1), I(this, Jo, /* @__PURE__ */ new Set()), I(this, Ko, /* @__PURE__ */ new Set()), I(this, Ut, null), I(this, Wn, as(() => ($(Ut, this, ae(c(fe, this))), () => {
|
|
547
|
+
$(Ut, this, null);
|
|
548
|
+
}))), $(ft, this, t), $(Tt, this, e), $(We, this, (i) => {
|
|
549
|
+
var r = S;
|
|
498
550
|
r.b = this, r.f |= 128, o(i);
|
|
499
|
-
}), this.parent =
|
|
500
|
-
if (
|
|
501
|
-
const i =
|
|
502
|
-
|
|
551
|
+
}), this.parent = S.b, this.transform_error = n ?? this.parent?.transform_error ?? ((i) => i), $(et, this, yn(() => {
|
|
552
|
+
if (P) {
|
|
553
|
+
const i = c(Uo, this);
|
|
554
|
+
ko();
|
|
503
555
|
const r = i.data === "[!";
|
|
504
556
|
if (i.data.startsWith("[?")) {
|
|
505
557
|
const s = JSON.parse(i.data.slice(2));
|
|
506
|
-
|
|
507
|
-
} else r ?
|
|
508
|
-
} else
|
|
509
|
-
},
|
|
558
|
+
E(z, this, hs).call(this, s);
|
|
559
|
+
} else r ? E(z, this, fs).call(this) : E(z, this, ds).call(this);
|
|
560
|
+
} else E(z, this, Ci).call(this);
|
|
561
|
+
}, ls)), P && $(ft, this, L);
|
|
510
562
|
}
|
|
511
563
|
defer_effect(t) {
|
|
512
|
-
|
|
564
|
+
wi(t, c(Jo, this), c(Ko, this));
|
|
513
565
|
}
|
|
514
566
|
is_rendered() {
|
|
515
567
|
return !this.is_pending && (!this.parent || this.parent.is_rendered());
|
|
516
568
|
}
|
|
517
569
|
has_pending_snippet() {
|
|
518
|
-
return !!
|
|
570
|
+
return !!c(Tt, this).pending;
|
|
519
571
|
}
|
|
520
572
|
update_pending_count(t, e) {
|
|
521
|
-
|
|
522
|
-
|
|
573
|
+
E(z, this, Ei).call(this, t, e), $(fe, this, c(fe, this) + t), !(!c(Ut, this) || c(Ye, this)) && ($(Ye, this, !0), se(() => {
|
|
574
|
+
$(Ye, this, !1), c(Ut, this) && Ie(c(Ut, this), c(fe, this));
|
|
523
575
|
}));
|
|
524
576
|
}
|
|
525
577
|
get_effect_pending() {
|
|
526
|
-
return
|
|
578
|
+
return c(Wn, this).call(this), g(c(Ut, this));
|
|
527
579
|
}
|
|
528
580
|
error(t) {
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
var n = !1, i = !1;
|
|
534
|
-
const r = () => {
|
|
535
|
-
if (n) {
|
|
536
|
-
jr();
|
|
537
|
-
return;
|
|
538
|
-
}
|
|
539
|
-
n = !0, i && Wr(), u(xt, this) !== null && se(u(xt, this), () => {
|
|
540
|
-
T(xt, this, null);
|
|
541
|
-
}), O(q, this, zo).call(this, () => {
|
|
542
|
-
O(q, this, Cn).call(this);
|
|
543
|
-
});
|
|
544
|
-
}, s = (l) => {
|
|
545
|
-
try {
|
|
546
|
-
i = !0, e?.(l, r), i = !1;
|
|
547
|
-
} catch (a) {
|
|
548
|
-
Vt(a, u(Y, this) && u(Y, this).parent);
|
|
549
|
-
}
|
|
550
|
-
o && T(xt, this, O(q, this, zo).call(this, () => {
|
|
551
|
-
try {
|
|
552
|
-
return ot(() => {
|
|
553
|
-
var a = k;
|
|
554
|
-
a.b = this, a.f |= 128, o(u(ct, this), () => l, () => r);
|
|
555
|
-
});
|
|
556
|
-
} catch (a) {
|
|
557
|
-
return Vt(a, u(Y, this).parent), null;
|
|
558
|
-
}
|
|
559
|
-
}));
|
|
560
|
-
};
|
|
561
|
-
ee(() => {
|
|
562
|
-
var l;
|
|
563
|
-
try {
|
|
564
|
-
l = this.transform_error(t);
|
|
565
|
-
} catch (a) {
|
|
566
|
-
Vt(a, u(Y, this) && u(Y, this).parent);
|
|
567
|
-
return;
|
|
568
|
-
}
|
|
569
|
-
l !== null && typeof l == "object" && typeof l.then == "function" ? l.then(s, (a) => Vt(a, u(Y, this) && u(Y, this).parent)) : s(l);
|
|
570
|
-
});
|
|
581
|
+
if (!c(Tt, this).onerror && !c(Tt, this).failed) throw t;
|
|
582
|
+
x?.is_fork ? (c(kt, this) && x.skip_effect(c(kt, this)), c(X, this) && x.skip_effect(c(X, this)), c(ut, this) && x.skip_effect(c(ut, this)), x.on_fork_commit(() => {
|
|
583
|
+
E(z, this, Vn).call(this, t);
|
|
584
|
+
})) : E(z, this, Vn).call(this, t);
|
|
571
585
|
}
|
|
572
586
|
};
|
|
573
|
-
function
|
|
587
|
+
function ds() {
|
|
574
588
|
try {
|
|
575
|
-
|
|
589
|
+
$(kt, this, it(() => c(We, this).call(this, c(ft, this))));
|
|
576
590
|
} catch (t) {
|
|
577
591
|
this.error(t);
|
|
578
592
|
}
|
|
579
593
|
}
|
|
580
|
-
function
|
|
581
|
-
const e =
|
|
582
|
-
e &&
|
|
583
|
-
e(
|
|
594
|
+
function hs(t) {
|
|
595
|
+
const e = c(Tt, this).failed;
|
|
596
|
+
e && $(ut, this, it(() => {
|
|
597
|
+
e(c(ft, this), () => t, () => () => {
|
|
584
598
|
});
|
|
585
599
|
}));
|
|
586
600
|
}
|
|
587
|
-
function
|
|
588
|
-
const t =
|
|
589
|
-
t && (this.is_pending = !0,
|
|
590
|
-
var e =
|
|
591
|
-
e.append(o),
|
|
592
|
-
|
|
593
|
-
}),
|
|
601
|
+
function fs() {
|
|
602
|
+
const t = c(Tt, this).pending;
|
|
603
|
+
t && (this.is_pending = !0, $(X, this, it(() => t(c(ft, this)))), se(() => {
|
|
604
|
+
var e = $(ee, this, document.createDocumentFragment()), o = pt();
|
|
605
|
+
e.append(o), $(kt, this, E(z, this, Zo).call(this, () => it(() => c(We, this).call(this, o)))), c(oe, this) === 0 && (c(ft, this).before(e), $(ee, this, null), de(c(X, this), () => {
|
|
606
|
+
$(X, this, null);
|
|
607
|
+
}), E(z, this, hn).call(this, x));
|
|
594
608
|
}));
|
|
595
609
|
}
|
|
596
|
-
function
|
|
610
|
+
function Ci() {
|
|
597
611
|
try {
|
|
598
|
-
if (this.is_pending = this.has_pending_snippet(),
|
|
599
|
-
|
|
600
|
-
})),
|
|
601
|
-
var t =
|
|
602
|
-
|
|
603
|
-
const e =
|
|
604
|
-
|
|
605
|
-
} else
|
|
612
|
+
if (this.is_pending = this.has_pending_snippet(), $(oe, this, 0), $(fe, this, 0), $(kt, this, it(() => {
|
|
613
|
+
c(We, this).call(this, c(ft, this));
|
|
614
|
+
})), c(oe, this) > 0) {
|
|
615
|
+
var t = $(ee, this, document.createDocumentFragment());
|
|
616
|
+
In(c(kt, this), t);
|
|
617
|
+
const e = c(Tt, this).pending;
|
|
618
|
+
$(X, this, it(() => e(c(ft, this))));
|
|
619
|
+
} else E(z, this, hn).call(this, x);
|
|
606
620
|
} catch (e) {
|
|
607
621
|
this.error(e);
|
|
608
622
|
}
|
|
609
623
|
}
|
|
610
|
-
function
|
|
611
|
-
this.is_pending = !1, t.transfer_effects(
|
|
624
|
+
function hn(t) {
|
|
625
|
+
this.is_pending = !1, t.transfer_effects(c(Jo, this), c(Ko, this));
|
|
612
626
|
}
|
|
613
|
-
function
|
|
614
|
-
var e =
|
|
615
|
-
|
|
627
|
+
function Zo(t) {
|
|
628
|
+
var e = S, o = _, n = V;
|
|
629
|
+
$t(c(et, this)), rt(c(et, this)), ye(c(et, this).ctx);
|
|
616
630
|
try {
|
|
617
|
-
return
|
|
631
|
+
return ue.ensure(), t();
|
|
618
632
|
} catch (i) {
|
|
619
|
-
return
|
|
633
|
+
return bi(i), null;
|
|
620
634
|
} finally {
|
|
621
|
-
|
|
635
|
+
$t(e), rt(o), ye(n);
|
|
622
636
|
}
|
|
623
637
|
}
|
|
624
|
-
function
|
|
638
|
+
function Ei(t, e) {
|
|
625
639
|
if (!this.has_pending_snippet()) {
|
|
626
640
|
if (this.parent) {
|
|
627
641
|
var o;
|
|
628
|
-
|
|
642
|
+
E(z, o = this.parent, Ei).call(o, t, e);
|
|
629
643
|
}
|
|
630
644
|
return;
|
|
631
645
|
}
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
}),
|
|
646
|
+
$(oe, this, c(oe, this) + t), c(oe, this) === 0 && (E(z, this, hn).call(this, e), c(X, this) && de(c(X, this), () => {
|
|
647
|
+
$(X, this, null);
|
|
648
|
+
}), c(ee, this) && (c(ft, this).before(c(ee, this)), $(ee, this, null)));
|
|
649
|
+
}
|
|
650
|
+
function Vn(t) {
|
|
651
|
+
c(kt, this) && (D(c(kt, this)), $(kt, this, null)), c(X, this) && (D(c(X, this)), $(X, this, null)), c(ut, this) && (D(c(ut, this)), $(ut, this, null)), P && (U(c(Uo, this)), Yr(), U(vo()));
|
|
652
|
+
var e = c(Tt, this).onerror;
|
|
653
|
+
let o = c(Tt, this).failed;
|
|
654
|
+
var n = !1, i = !1;
|
|
655
|
+
const r = () => {
|
|
656
|
+
if (n) {
|
|
657
|
+
Zr();
|
|
658
|
+
return;
|
|
659
|
+
}
|
|
660
|
+
n = !0, i && Jr(), c(ut, this) !== null && de(c(ut, this), () => {
|
|
661
|
+
$(ut, this, null);
|
|
662
|
+
}), E(z, this, Zo).call(this, () => {
|
|
663
|
+
E(z, this, Ci).call(this);
|
|
664
|
+
});
|
|
665
|
+
}, s = (a) => {
|
|
666
|
+
try {
|
|
667
|
+
i = !0, e?.(a, r), i = !1;
|
|
668
|
+
} catch (u) {
|
|
669
|
+
Bt(u, c(et, this) && c(et, this).parent);
|
|
670
|
+
}
|
|
671
|
+
o && $(ut, this, E(z, this, Zo).call(this, () => {
|
|
672
|
+
try {
|
|
673
|
+
return it(() => {
|
|
674
|
+
var u = S;
|
|
675
|
+
u.b = this, u.f |= 128, o(c(ft, this), () => a, () => r);
|
|
676
|
+
});
|
|
677
|
+
} catch (u) {
|
|
678
|
+
return Bt(u, c(et, this).parent), null;
|
|
679
|
+
}
|
|
680
|
+
}));
|
|
681
|
+
};
|
|
682
|
+
se(() => {
|
|
683
|
+
var a;
|
|
684
|
+
try {
|
|
685
|
+
a = this.transform_error(t);
|
|
686
|
+
} catch (u) {
|
|
687
|
+
Bt(u, c(et, this) && c(et, this).parent);
|
|
688
|
+
return;
|
|
689
|
+
}
|
|
690
|
+
a !== null && typeof a == "object" && typeof a.then == "function" ? a.then(s, (u) => Bt(u, c(et, this) && c(et, this).parent)) : s(a);
|
|
691
|
+
});
|
|
635
692
|
}
|
|
636
|
-
function
|
|
637
|
-
const i =
|
|
638
|
-
var r = t.filter((
|
|
693
|
+
function ps(t, e, o, n) {
|
|
694
|
+
const i = qe() ? So : fn;
|
|
695
|
+
var r = t.filter((f) => !f.settled);
|
|
639
696
|
if (o.length === 0 && r.length === 0) {
|
|
640
697
|
n(e.map(i));
|
|
641
698
|
return;
|
|
642
699
|
}
|
|
643
|
-
var s =
|
|
644
|
-
function
|
|
645
|
-
|
|
700
|
+
var s = S, a = vs(), u = r.length === 1 ? r[0].promise : r.length > 1 ? Promise.all(r.map((f) => f.promise)) : null;
|
|
701
|
+
function l(f) {
|
|
702
|
+
a();
|
|
646
703
|
try {
|
|
647
|
-
n(
|
|
704
|
+
n(f);
|
|
648
705
|
} catch (v) {
|
|
649
|
-
s.f & 16384 ||
|
|
706
|
+
s.f & 16384 || Bt(v, s);
|
|
650
707
|
}
|
|
651
|
-
|
|
708
|
+
bo();
|
|
652
709
|
}
|
|
653
710
|
if (o.length === 0) {
|
|
654
|
-
|
|
711
|
+
u.then(() => l(e.map(i)));
|
|
655
712
|
return;
|
|
656
713
|
}
|
|
657
|
-
var d =
|
|
658
|
-
function
|
|
659
|
-
Promise.all(o.map((
|
|
714
|
+
var d = Mi();
|
|
715
|
+
function h() {
|
|
716
|
+
Promise.all(o.map((f) => /* @__PURE__ */ gs(f))).then((f) => l([...e.map(i), ...f])).catch((f) => Bt(f, s)).finally(() => d());
|
|
660
717
|
}
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
}) :
|
|
718
|
+
u ? u.then(() => {
|
|
719
|
+
a(), h(), bo();
|
|
720
|
+
}) : h();
|
|
664
721
|
}
|
|
665
|
-
function
|
|
666
|
-
var t =
|
|
722
|
+
function vs() {
|
|
723
|
+
var t = S, e = _, o = V, n = x;
|
|
667
724
|
return function(i = !0) {
|
|
668
|
-
|
|
725
|
+
$t(t), rt(e), ye(o), i && !(t.f & 16384) && (n?.activate(), n?.apply());
|
|
669
726
|
};
|
|
670
727
|
}
|
|
671
|
-
function
|
|
672
|
-
|
|
728
|
+
function bo(t = !0) {
|
|
729
|
+
$t(null), rt(null), ye(null), t && x?.deactivate();
|
|
673
730
|
}
|
|
674
|
-
function
|
|
675
|
-
var t =
|
|
676
|
-
return
|
|
677
|
-
|
|
731
|
+
function Mi() {
|
|
732
|
+
var t = S, e = t.b, o = x, n = e.is_rendered();
|
|
733
|
+
return e.update_pending_count(1, o), o.increment(n, t), (i = !1) => {
|
|
734
|
+
e.update_pending_count(-1, o), o.decrement(n, t, i);
|
|
678
735
|
};
|
|
679
736
|
}
|
|
680
737
|
// @__NO_SIDE_EFFECTS__
|
|
681
|
-
function
|
|
682
|
-
var e = 2 |
|
|
683
|
-
return
|
|
684
|
-
ctx:
|
|
738
|
+
function So(t) {
|
|
739
|
+
var e = 2 | vt;
|
|
740
|
+
return S !== null && (S.f |= $e), {
|
|
741
|
+
ctx: V,
|
|
685
742
|
deps: null,
|
|
686
743
|
effects: null,
|
|
687
|
-
equals:
|
|
744
|
+
equals: fi,
|
|
688
745
|
f: e,
|
|
689
746
|
fn: t,
|
|
690
747
|
reactions: null,
|
|
691
748
|
rv: 0,
|
|
692
|
-
v:
|
|
749
|
+
v: N,
|
|
693
750
|
wv: 0,
|
|
694
|
-
parent:
|
|
751
|
+
parent: S,
|
|
695
752
|
ac: null
|
|
696
753
|
};
|
|
697
754
|
}
|
|
698
755
|
// @__NO_SIDE_EFFECTS__
|
|
699
|
-
function
|
|
700
|
-
let n =
|
|
701
|
-
n === null &&
|
|
702
|
-
var i = void 0, r =
|
|
703
|
-
return
|
|
704
|
-
var
|
|
705
|
-
i =
|
|
756
|
+
function gs(t, e, o) {
|
|
757
|
+
let n = S;
|
|
758
|
+
n === null && Nr();
|
|
759
|
+
var i = void 0, r = ae(N), s = !_, a = /* @__PURE__ */ new Map();
|
|
760
|
+
return Ss(() => {
|
|
761
|
+
var u = S, l = ui();
|
|
762
|
+
i = l.promise;
|
|
706
763
|
try {
|
|
707
|
-
Promise.resolve(t()).then(
|
|
764
|
+
Promise.resolve(t()).then(l.resolve, l.reject).finally(bo);
|
|
708
765
|
} catch (v) {
|
|
709
|
-
|
|
766
|
+
l.reject(v), bo();
|
|
710
767
|
}
|
|
711
|
-
var d =
|
|
768
|
+
var d = x;
|
|
712
769
|
if (s) {
|
|
713
|
-
if (
|
|
714
|
-
if (n.b.is_rendered())
|
|
770
|
+
if (u.f & 32768) var h = Mi();
|
|
771
|
+
if (n.b.is_rendered()) a.get(d)?.reject(Mt), a.delete(d);
|
|
715
772
|
else {
|
|
716
|
-
for (const v of
|
|
717
|
-
|
|
773
|
+
for (const v of a.values()) v.reject(Mt);
|
|
774
|
+
a.clear();
|
|
718
775
|
}
|
|
719
|
-
|
|
776
|
+
a.set(d, l);
|
|
720
777
|
}
|
|
721
|
-
const
|
|
722
|
-
if (
|
|
723
|
-
if (d.activate(), m) r.f |=
|
|
778
|
+
const f = (v, m = void 0) => {
|
|
779
|
+
if (h && h(m === Mt), !(m === Mt || u.f & 16384)) {
|
|
780
|
+
if (d.activate(), m) r.f |= po, Ie(r, m);
|
|
724
781
|
else {
|
|
725
|
-
r.f & 8388608 && (r.f ^=
|
|
726
|
-
for (const [
|
|
727
|
-
if (
|
|
728
|
-
p.reject(
|
|
782
|
+
r.f & 8388608 && (r.f ^= po), Ie(r, v);
|
|
783
|
+
for (const [k, p] of a) {
|
|
784
|
+
if (a.delete(k), k === d) break;
|
|
785
|
+
p.reject(Mt);
|
|
729
786
|
}
|
|
730
787
|
}
|
|
731
788
|
d.deactivate();
|
|
732
789
|
}
|
|
733
790
|
};
|
|
734
|
-
|
|
735
|
-
}),
|
|
736
|
-
for (const
|
|
737
|
-
}), new Promise((
|
|
738
|
-
function
|
|
739
|
-
function
|
|
740
|
-
d === i ?
|
|
791
|
+
l.promise.then(f, (v) => f(null, v || "unknown"));
|
|
792
|
+
}), Is(() => {
|
|
793
|
+
for (const u of a.values()) u.reject(Mt);
|
|
794
|
+
}), new Promise((u) => {
|
|
795
|
+
function l(d) {
|
|
796
|
+
function h() {
|
|
797
|
+
d === i ? u(r) : l(i);
|
|
741
798
|
}
|
|
742
|
-
d.then(
|
|
799
|
+
d.then(h, h);
|
|
743
800
|
}
|
|
744
|
-
|
|
801
|
+
l(i);
|
|
745
802
|
});
|
|
746
803
|
}
|
|
747
804
|
// @__NO_SIDE_EFFECTS__
|
|
748
|
-
function
|
|
749
|
-
const e = /* @__PURE__ */
|
|
750
|
-
return
|
|
805
|
+
function Eo(t) {
|
|
806
|
+
const e = /* @__PURE__ */ So(t);
|
|
807
|
+
return Pt || Ki(e), e;
|
|
751
808
|
}
|
|
752
809
|
// @__NO_SIDE_EFFECTS__
|
|
753
|
-
function
|
|
754
|
-
const e = /* @__PURE__ */
|
|
755
|
-
return e.equals =
|
|
810
|
+
function fn(t) {
|
|
811
|
+
const e = /* @__PURE__ */ So(t);
|
|
812
|
+
return e.equals = pi, e;
|
|
756
813
|
}
|
|
757
|
-
function
|
|
814
|
+
function ms(t) {
|
|
758
815
|
var e = t.effects;
|
|
759
816
|
if (e !== null) {
|
|
760
817
|
t.effects = null;
|
|
761
|
-
for (var o = 0; o < e.length; o += 1)
|
|
818
|
+
for (var o = 0; o < e.length; o += 1) D(e[o]);
|
|
762
819
|
}
|
|
763
820
|
}
|
|
764
|
-
function
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
}
|
|
769
|
-
return null;
|
|
770
|
-
}
|
|
771
|
-
function en(t) {
|
|
772
|
-
var e, o = k;
|
|
773
|
-
yt(ss(t));
|
|
821
|
+
function pn(t) {
|
|
822
|
+
var e, o = S, n = t.parent;
|
|
823
|
+
if (!Ot && n !== null && n.f & 24576) return Kr(), t.v;
|
|
824
|
+
$t(n);
|
|
774
825
|
try {
|
|
775
|
-
t.f &= ~
|
|
826
|
+
t.f &= ~ze, ms(t), e = Qi(t);
|
|
776
827
|
} finally {
|
|
777
|
-
|
|
828
|
+
$t(o);
|
|
778
829
|
}
|
|
779
830
|
return e;
|
|
780
831
|
}
|
|
781
|
-
function
|
|
782
|
-
var e =
|
|
783
|
-
if (!t.equals(
|
|
784
|
-
|
|
832
|
+
function Li(t) {
|
|
833
|
+
var e = pn(t);
|
|
834
|
+
if (!t.equals(e) && (t.wv = Yi(), (!x?.is_fork || t.deps === null) && (x !== null ? x.capture(t, e, !0) : t.v = e, t.deps === null))) {
|
|
835
|
+
j(t, nt);
|
|
785
836
|
return;
|
|
786
837
|
}
|
|
787
|
-
|
|
838
|
+
Ot || (q !== null ? (mn() || x?.is_fork) && q.set(t, e) : an(t));
|
|
788
839
|
}
|
|
789
|
-
function
|
|
790
|
-
if (t.effects !== null) for (const e of t.effects) (e.teardown || e.ac) && (e.teardown?.(), e.ac?.abort(
|
|
840
|
+
function bs(t) {
|
|
841
|
+
if (t.effects !== null) for (const e of t.effects) (e.teardown || e.ac) && (e.teardown?.(), e.ac?.abort(Mt), e.teardown = Er, e.ac = null, Ve(e, 0), wn(e));
|
|
791
842
|
}
|
|
792
|
-
function
|
|
793
|
-
if (t.effects !== null) for (const e of t.effects) e.teardown &&
|
|
843
|
+
function Pi(t) {
|
|
844
|
+
if (t.effects !== null) for (const e of t.effects) e.teardown && ke(e);
|
|
794
845
|
}
|
|
795
|
-
var
|
|
796
|
-
function
|
|
846
|
+
var Yo = /* @__PURE__ */ new Set(), ne = /* @__PURE__ */ new Map(), Oi = !1;
|
|
847
|
+
function ae(t, e) {
|
|
797
848
|
return {
|
|
798
849
|
f: 0,
|
|
799
850
|
v: t,
|
|
800
851
|
reactions: null,
|
|
801
|
-
equals:
|
|
852
|
+
equals: fi,
|
|
802
853
|
rv: 0,
|
|
803
854
|
wv: 0
|
|
804
855
|
};
|
|
805
856
|
}
|
|
806
857
|
// @__NO_SIDE_EFFECTS__
|
|
807
|
-
function
|
|
808
|
-
const o =
|
|
809
|
-
return
|
|
858
|
+
function W(t, e) {
|
|
859
|
+
const o = ae(t, e);
|
|
860
|
+
return Ki(o), o;
|
|
810
861
|
}
|
|
811
862
|
// @__NO_SIDE_EFFECTS__
|
|
812
|
-
function
|
|
813
|
-
const n =
|
|
814
|
-
if (e || (n.equals =
|
|
863
|
+
function Ri(t, e = !1, o = !0) {
|
|
864
|
+
const n = ae(t);
|
|
865
|
+
if (e || (n.equals = pi), $o && o && V !== null && V.l !== null) {
|
|
815
866
|
var i;
|
|
816
|
-
((i =
|
|
867
|
+
((i = V.l).s ?? (i.s = [])).push(n);
|
|
817
868
|
}
|
|
818
869
|
return n;
|
|
819
870
|
}
|
|
820
|
-
function
|
|
821
|
-
return
|
|
871
|
+
function C(t, e, o = !1) {
|
|
872
|
+
return _ !== null && (!ht || _.f & 131072) && qe() && _.f & 4325394 && (ot === null || !be.call(ot, t)) && Ur(), Ie(t, o ? Yt(e) : e, go);
|
|
822
873
|
}
|
|
823
|
-
function
|
|
874
|
+
function Ie(t, e, o = null) {
|
|
824
875
|
if (!t.equals(e)) {
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
t.f & 2048 && en(r), F === null && Zo(r);
|
|
876
|
+
ne.set(t, Ot ? e : t.v);
|
|
877
|
+
var n = ue.ensure();
|
|
878
|
+
if (n.capture(t, e), t.f & 2) {
|
|
879
|
+
const i = t;
|
|
880
|
+
t.f & 2048 && pn(i), q === null && an(i);
|
|
831
881
|
}
|
|
832
|
-
t.wv =
|
|
882
|
+
t.wv = Yi(), ji(t, vt, o), qe() && S !== null && S.f & 1024 && !(S.f & 96) && (tt === null ? Cs([t]) : tt.push(t)), !n.is_fork && Yo.size > 0 && !Oi && ys();
|
|
833
883
|
}
|
|
834
884
|
return e;
|
|
835
885
|
}
|
|
836
|
-
function
|
|
837
|
-
|
|
838
|
-
for (const t of
|
|
839
|
-
|
|
886
|
+
function ys() {
|
|
887
|
+
Oi = !1;
|
|
888
|
+
for (const t of Yo) t.f & 1024 && j(t, ce), De(t) && ke(t);
|
|
889
|
+
Yo.clear();
|
|
840
890
|
}
|
|
841
|
-
function
|
|
842
|
-
|
|
891
|
+
function Ne(t) {
|
|
892
|
+
C(t, t.v + 1);
|
|
843
893
|
}
|
|
844
|
-
function
|
|
894
|
+
function ji(t, e, o) {
|
|
845
895
|
var n = t.reactions;
|
|
846
|
-
if (n !== null) for (var i =
|
|
847
|
-
var
|
|
848
|
-
if (!(!i &&
|
|
849
|
-
var
|
|
850
|
-
if (
|
|
851
|
-
var d =
|
|
852
|
-
|
|
853
|
-
} else if (
|
|
854
|
-
var
|
|
855
|
-
|
|
896
|
+
if (n !== null) for (var i = qe(), r = n.length, s = 0; s < r; s++) {
|
|
897
|
+
var a = n[s], u = a.f;
|
|
898
|
+
if (!(!i && a === S)) {
|
|
899
|
+
var l = (u & vt) === 0;
|
|
900
|
+
if (l && j(a, e), u & 2) {
|
|
901
|
+
var d = a;
|
|
902
|
+
q?.delete(d), u & 65536 || (u & 512 && (a.f |= ze), ji(d, ce, o));
|
|
903
|
+
} else if (l) {
|
|
904
|
+
var h = a;
|
|
905
|
+
u & 16 && wt !== null && wt.add(h), o !== null ? o.push(h) : dn(h);
|
|
856
906
|
}
|
|
857
907
|
}
|
|
858
908
|
}
|
|
859
909
|
}
|
|
860
|
-
function
|
|
861
|
-
if (typeof t != "object" || t === null ||
|
|
862
|
-
const e =
|
|
863
|
-
if (e !==
|
|
864
|
-
var o = /* @__PURE__ */ new Map(), n =
|
|
865
|
-
if (
|
|
866
|
-
var
|
|
867
|
-
|
|
868
|
-
var
|
|
869
|
-
return
|
|
910
|
+
function Yt(t) {
|
|
911
|
+
if (typeof t != "object" || t === null || Re in t) return t;
|
|
912
|
+
const e = ci(t);
|
|
913
|
+
if (e !== _r && e !== Cr) return t;
|
|
914
|
+
var o = /* @__PURE__ */ new Map(), n = li(t), i = /* @__PURE__ */ W(0), r = null, s = ie, a = (u) => {
|
|
915
|
+
if (ie === s) return u();
|
|
916
|
+
var l = _, d = ie;
|
|
917
|
+
rt(null), Hn(s);
|
|
918
|
+
var h = u();
|
|
919
|
+
return rt(l), Hn(d), h;
|
|
870
920
|
};
|
|
871
|
-
return n && o.set("length", /* @__PURE__ */
|
|
872
|
-
defineProperty(
|
|
873
|
-
(!("value" in d) || d.configurable === !1 || d.enumerable === !1 || d.writable === !1) &&
|
|
874
|
-
var
|
|
875
|
-
return
|
|
876
|
-
var
|
|
877
|
-
return o.set(
|
|
878
|
-
}) :
|
|
921
|
+
return n && o.set("length", /* @__PURE__ */ W(t.length, r)), new Proxy(t, {
|
|
922
|
+
defineProperty(u, l, d) {
|
|
923
|
+
(!("value" in d) || d.configurable === !1 || d.enumerable === !1 || d.writable === !1) && Fr();
|
|
924
|
+
var h = o.get(l);
|
|
925
|
+
return h === void 0 ? a(() => {
|
|
926
|
+
var f = /* @__PURE__ */ W(d.value, r);
|
|
927
|
+
return o.set(l, f), f;
|
|
928
|
+
}) : C(h, d.value, !0), !0;
|
|
879
929
|
},
|
|
880
|
-
deleteProperty(
|
|
881
|
-
var d = o.get(
|
|
930
|
+
deleteProperty(u, l) {
|
|
931
|
+
var d = o.get(l);
|
|
882
932
|
if (d === void 0) {
|
|
883
|
-
if (
|
|
884
|
-
const
|
|
885
|
-
o.set(
|
|
933
|
+
if (l in u) {
|
|
934
|
+
const h = a(() => /* @__PURE__ */ W(N, r));
|
|
935
|
+
o.set(l, h), Ne(i);
|
|
886
936
|
}
|
|
887
|
-
} else
|
|
937
|
+
} else C(d, N), Ne(i);
|
|
888
938
|
return !0;
|
|
889
939
|
},
|
|
890
|
-
get(
|
|
891
|
-
if (
|
|
892
|
-
var
|
|
893
|
-
if (
|
|
894
|
-
var v = g(
|
|
895
|
-
return v ===
|
|
940
|
+
get(u, l, d) {
|
|
941
|
+
if (l === Re) return t;
|
|
942
|
+
var h = o.get(l), f = l in u;
|
|
943
|
+
if (h === void 0 && (!f || Qt(u, l)?.writable) && (h = a(() => /* @__PURE__ */ W(Yt(f ? u[l] : N), r)), o.set(l, h)), h !== void 0) {
|
|
944
|
+
var v = g(h);
|
|
945
|
+
return v === N ? void 0 : v;
|
|
896
946
|
}
|
|
897
|
-
return Reflect.get(
|
|
947
|
+
return Reflect.get(u, l, d);
|
|
898
948
|
},
|
|
899
|
-
getOwnPropertyDescriptor(
|
|
900
|
-
var d = Reflect.getOwnPropertyDescriptor(
|
|
949
|
+
getOwnPropertyDescriptor(u, l) {
|
|
950
|
+
var d = Reflect.getOwnPropertyDescriptor(u, l);
|
|
901
951
|
if (d && "value" in d) {
|
|
902
|
-
var
|
|
903
|
-
|
|
952
|
+
var h = o.get(l);
|
|
953
|
+
h && (d.value = g(h));
|
|
904
954
|
} else if (d === void 0) {
|
|
905
|
-
var
|
|
906
|
-
if (
|
|
955
|
+
var f = o.get(l), v = f?.v;
|
|
956
|
+
if (f !== void 0 && v !== N) return {
|
|
907
957
|
enumerable: !0,
|
|
908
958
|
configurable: !0,
|
|
909
959
|
value: v,
|
|
@@ -912,142 +962,142 @@ function Kt(t) {
|
|
|
912
962
|
}
|
|
913
963
|
return d;
|
|
914
964
|
},
|
|
915
|
-
has(
|
|
916
|
-
if (
|
|
917
|
-
var d = o.get(
|
|
918
|
-
return (d !== void 0 ||
|
|
965
|
+
has(u, l) {
|
|
966
|
+
if (l === Re) return !0;
|
|
967
|
+
var d = o.get(l), h = d !== void 0 && d.v !== N || Reflect.has(u, l);
|
|
968
|
+
return (d !== void 0 || S !== null && (!h || Qt(u, l)?.writable)) && (d === void 0 && (d = a(() => /* @__PURE__ */ W(h ? Yt(u[l]) : N, r)), o.set(l, d)), g(d) === N) ? !1 : h;
|
|
919
969
|
},
|
|
920
|
-
set(
|
|
921
|
-
var
|
|
922
|
-
if (n &&
|
|
923
|
-
var
|
|
924
|
-
|
|
970
|
+
set(u, l, d, h) {
|
|
971
|
+
var f = o.get(l), v = l in u;
|
|
972
|
+
if (n && l === "length") for (var m = d; m < f.v; m += 1) {
|
|
973
|
+
var k = o.get(m + "");
|
|
974
|
+
k !== void 0 ? C(k, N) : m in u && (k = a(() => /* @__PURE__ */ W(N, r)), o.set(m + "", k));
|
|
925
975
|
}
|
|
926
|
-
if (
|
|
976
|
+
if (f === void 0) (!v || Qt(u, l)?.writable) && (f = a(() => /* @__PURE__ */ W(void 0, r)), C(f, Yt(d)), o.set(l, f));
|
|
927
977
|
else {
|
|
928
|
-
v =
|
|
929
|
-
var p =
|
|
930
|
-
|
|
978
|
+
v = f.v !== N;
|
|
979
|
+
var p = a(() => Yt(d));
|
|
980
|
+
C(f, p);
|
|
931
981
|
}
|
|
932
|
-
var w = Reflect.getOwnPropertyDescriptor(
|
|
933
|
-
if (w?.set && w.set.call(
|
|
934
|
-
if (n && typeof
|
|
935
|
-
var R = o.get("length"),
|
|
936
|
-
Number.isInteger(
|
|
982
|
+
var w = Reflect.getOwnPropertyDescriptor(u, l);
|
|
983
|
+
if (w?.set && w.set.call(h, d), !v) {
|
|
984
|
+
if (n && typeof l == "string") {
|
|
985
|
+
var R = o.get("length"), A = Number(l);
|
|
986
|
+
Number.isInteger(A) && A >= R.v && C(R, A + 1);
|
|
937
987
|
}
|
|
938
|
-
|
|
988
|
+
Ne(i);
|
|
939
989
|
}
|
|
940
990
|
return !0;
|
|
941
991
|
},
|
|
942
|
-
ownKeys(
|
|
992
|
+
ownKeys(u) {
|
|
943
993
|
g(i);
|
|
944
|
-
var
|
|
945
|
-
var v = o.get(
|
|
946
|
-
return v === void 0 || v.v !==
|
|
994
|
+
var l = Reflect.ownKeys(u).filter((f) => {
|
|
995
|
+
var v = o.get(f);
|
|
996
|
+
return v === void 0 || v.v !== N;
|
|
947
997
|
});
|
|
948
|
-
for (var [d,
|
|
949
|
-
return
|
|
998
|
+
for (var [d, h] of o) h.v !== N && !(d in u) && l.push(d);
|
|
999
|
+
return l;
|
|
950
1000
|
},
|
|
951
1001
|
setPrototypeOf() {
|
|
952
|
-
|
|
1002
|
+
Gr();
|
|
953
1003
|
}
|
|
954
1004
|
});
|
|
955
1005
|
}
|
|
956
|
-
var
|
|
957
|
-
function
|
|
958
|
-
if (
|
|
959
|
-
|
|
1006
|
+
var zn, Ni, Wi, Vi;
|
|
1007
|
+
function Xo() {
|
|
1008
|
+
if (zn === void 0) {
|
|
1009
|
+
zn = window, Ni = /Firefox/.test(navigator.userAgent);
|
|
960
1010
|
var t = Element.prototype, e = Node.prototype, o = Text.prototype;
|
|
961
|
-
|
|
1011
|
+
Wi = Qt(e, "firstChild").get, Vi = Qt(e, "nextSibling").get, On(t) && (t.__click = void 0, t.__className = void 0, t.__attributes = null, t.__style = void 0, t.__e = void 0), On(o) && (o.__t = void 0);
|
|
962
1012
|
}
|
|
963
1013
|
}
|
|
964
|
-
function
|
|
1014
|
+
function pt(t = "") {
|
|
965
1015
|
return document.createTextNode(t);
|
|
966
1016
|
}
|
|
967
1017
|
// @__NO_SIDE_EFFECTS__
|
|
968
|
-
function
|
|
969
|
-
return
|
|
1018
|
+
function le(t) {
|
|
1019
|
+
return Wi.call(t);
|
|
970
1020
|
}
|
|
971
1021
|
// @__NO_SIDE_EFFECTS__
|
|
972
|
-
function
|
|
973
|
-
return
|
|
1022
|
+
function St(t) {
|
|
1023
|
+
return Vi.call(t);
|
|
974
1024
|
}
|
|
975
|
-
function
|
|
976
|
-
if (!
|
|
977
|
-
var o = /* @__PURE__ */
|
|
978
|
-
if (o === null) o =
|
|
1025
|
+
function Xe(t, e) {
|
|
1026
|
+
if (!P) return /* @__PURE__ */ le(t);
|
|
1027
|
+
var o = /* @__PURE__ */ le(L);
|
|
1028
|
+
if (o === null) o = L.appendChild(pt());
|
|
979
1029
|
else if (e && o.nodeType !== 3) {
|
|
980
|
-
var n =
|
|
981
|
-
return o?.before(n),
|
|
1030
|
+
var n = pt();
|
|
1031
|
+
return o?.before(n), U(n), n;
|
|
982
1032
|
}
|
|
983
|
-
return e &&
|
|
1033
|
+
return e && gn(o), U(o), o;
|
|
984
1034
|
}
|
|
985
|
-
function
|
|
986
|
-
if (!
|
|
987
|
-
var o = /* @__PURE__ */
|
|
988
|
-
return o instanceof Comment && o.data === "" ? /* @__PURE__ */
|
|
1035
|
+
function Mo(t, e = !1) {
|
|
1036
|
+
if (!P) {
|
|
1037
|
+
var o = /* @__PURE__ */ le(t);
|
|
1038
|
+
return o instanceof Comment && o.data === "" ? /* @__PURE__ */ St(o) : o;
|
|
989
1039
|
}
|
|
990
1040
|
if (e) {
|
|
991
|
-
if (
|
|
992
|
-
var n =
|
|
993
|
-
return
|
|
1041
|
+
if (L?.nodeType !== 3) {
|
|
1042
|
+
var n = pt();
|
|
1043
|
+
return L?.before(n), U(n), n;
|
|
994
1044
|
}
|
|
995
|
-
|
|
1045
|
+
gn(L);
|
|
996
1046
|
}
|
|
997
|
-
return
|
|
1047
|
+
return L;
|
|
998
1048
|
}
|
|
999
|
-
function
|
|
1000
|
-
let n =
|
|
1001
|
-
for (var i; e--; ) i = n, n = /* @__PURE__ */
|
|
1002
|
-
if (!
|
|
1049
|
+
function Rt(t, e = 1, o = !1) {
|
|
1050
|
+
let n = P ? L : t;
|
|
1051
|
+
for (var i; e--; ) i = n, n = /* @__PURE__ */ St(n);
|
|
1052
|
+
if (!P) return n;
|
|
1003
1053
|
if (o) {
|
|
1004
1054
|
if (n?.nodeType !== 3) {
|
|
1005
|
-
var r =
|
|
1006
|
-
return n === null ? i?.after(r) : n.before(r),
|
|
1055
|
+
var r = pt();
|
|
1056
|
+
return n === null ? i?.after(r) : n.before(r), U(r), r;
|
|
1007
1057
|
}
|
|
1008
|
-
|
|
1058
|
+
gn(n);
|
|
1009
1059
|
}
|
|
1010
|
-
return
|
|
1060
|
+
return U(n), n;
|
|
1011
1061
|
}
|
|
1012
|
-
function
|
|
1062
|
+
function zi(t) {
|
|
1013
1063
|
t.textContent = "";
|
|
1014
1064
|
}
|
|
1015
|
-
function
|
|
1016
|
-
return !
|
|
1065
|
+
function qi() {
|
|
1066
|
+
return !Pt || wt !== null ? !1 : (S.f & rn) !== 0;
|
|
1017
1067
|
}
|
|
1018
|
-
function
|
|
1068
|
+
function vn(t, e, o) {
|
|
1019
1069
|
let n = o ? { is: o } : void 0;
|
|
1020
1070
|
return document.createElementNS(e ?? "http://www.w3.org/1999/xhtml", t, n);
|
|
1021
1071
|
}
|
|
1022
|
-
function
|
|
1072
|
+
function gn(t) {
|
|
1023
1073
|
if (t.nodeValue.length < 65536) return;
|
|
1024
1074
|
let e = t.nextSibling;
|
|
1025
1075
|
for (; e !== null && e.nodeType === 3; ) e.remove(), t.nodeValue += e.nodeValue, e = t.nextSibling;
|
|
1026
1076
|
}
|
|
1027
|
-
function
|
|
1028
|
-
var e =
|
|
1029
|
-
|
|
1077
|
+
function Di(t) {
|
|
1078
|
+
var e = _, o = S;
|
|
1079
|
+
rt(null), $t(null);
|
|
1030
1080
|
try {
|
|
1031
1081
|
return t();
|
|
1032
1082
|
} finally {
|
|
1033
|
-
|
|
1083
|
+
rt(e), $t(o);
|
|
1034
1084
|
}
|
|
1035
1085
|
}
|
|
1036
|
-
function
|
|
1037
|
-
|
|
1086
|
+
function ws(t) {
|
|
1087
|
+
S === null && (_ === null && qr(t), zr()), Ot && Vr(t);
|
|
1038
1088
|
}
|
|
1039
|
-
function
|
|
1089
|
+
function Ts(t, e) {
|
|
1040
1090
|
var o = e.last;
|
|
1041
1091
|
o === null ? e.last = e.first = t : (o.next = t, t.prev = o, e.last = t);
|
|
1042
1092
|
}
|
|
1043
|
-
function
|
|
1044
|
-
var o =
|
|
1045
|
-
o !== null && o.f & 8192 && (t |=
|
|
1093
|
+
function At(t, e) {
|
|
1094
|
+
var o = S;
|
|
1095
|
+
o !== null && o.f & 8192 && (t |= nn);
|
|
1046
1096
|
var n = {
|
|
1047
|
-
ctx:
|
|
1097
|
+
ctx: V,
|
|
1048
1098
|
deps: null,
|
|
1049
1099
|
nodes: null,
|
|
1050
|
-
f: t |
|
|
1100
|
+
f: t | vt | 512,
|
|
1051
1101
|
first: null,
|
|
1052
1102
|
fn: e,
|
|
1053
1103
|
last: null,
|
|
@@ -1058,385 +1108,391 @@ function It(t, e) {
|
|
|
1058
1108
|
teardown: null,
|
|
1059
1109
|
wv: 0,
|
|
1060
1110
|
ac: null
|
|
1061
|
-
}
|
|
1062
|
-
|
|
1111
|
+
};
|
|
1112
|
+
x?.register_created_effect(n);
|
|
1113
|
+
var i = n;
|
|
1114
|
+
if (t & 4) we !== null ? we.push(n) : ue.ensure().schedule(n);
|
|
1063
1115
|
else if (e !== null) {
|
|
1064
1116
|
try {
|
|
1065
|
-
|
|
1117
|
+
ke(n);
|
|
1066
1118
|
} catch (s) {
|
|
1067
|
-
throw
|
|
1119
|
+
throw D(n), s;
|
|
1068
1120
|
}
|
|
1069
|
-
i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && !(i.f & 524288) && (i = i.first, t & 16 && t & 65536 && i !== null && (i.f |=
|
|
1121
|
+
i.deps === null && i.teardown === null && i.nodes === null && i.first === i.last && !(i.f & 524288) && (i = i.first, t & 16 && t & 65536 && i !== null && (i.f |= sn));
|
|
1070
1122
|
}
|
|
1071
|
-
if (i !== null && (i.parent = o, o !== null &&
|
|
1072
|
-
var r =
|
|
1123
|
+
if (i !== null && (i.parent = o, o !== null && Ts(i, o), _ !== null && _.f & 2 && !(t & 64))) {
|
|
1124
|
+
var r = _;
|
|
1073
1125
|
(r.effects ?? (r.effects = [])).push(i);
|
|
1074
1126
|
}
|
|
1075
1127
|
return n;
|
|
1076
1128
|
}
|
|
1077
|
-
function
|
|
1078
|
-
return
|
|
1079
|
-
}
|
|
1080
|
-
function ds(t) {
|
|
1081
|
-
const e = It(8, null);
|
|
1082
|
-
return N(e, et), e.teardown = t, e;
|
|
1129
|
+
function mn() {
|
|
1130
|
+
return _ !== null && !ht;
|
|
1083
1131
|
}
|
|
1084
|
-
function
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1132
|
+
function Is(t) {
|
|
1133
|
+
const e = At(8, null);
|
|
1134
|
+
return j(e, nt), e.teardown = t, e;
|
|
1135
|
+
}
|
|
1136
|
+
function qn(t) {
|
|
1137
|
+
ws("$effect");
|
|
1138
|
+
var e = S.f;
|
|
1139
|
+
if (!_ && e & 32 && !(e & 32768)) {
|
|
1140
|
+
var o = V;
|
|
1089
1141
|
(o.e ?? (o.e = [])).push(t);
|
|
1090
|
-
} else return
|
|
1142
|
+
} else return Hi(t);
|
|
1091
1143
|
}
|
|
1092
|
-
function
|
|
1093
|
-
return
|
|
1144
|
+
function Hi(t) {
|
|
1145
|
+
return At(4 | Pr, t);
|
|
1094
1146
|
}
|
|
1095
|
-
function
|
|
1096
|
-
|
|
1097
|
-
const e =
|
|
1147
|
+
function ks(t) {
|
|
1148
|
+
ue.ensure();
|
|
1149
|
+
const e = At(64 | $e, t);
|
|
1098
1150
|
return () => {
|
|
1099
|
-
|
|
1151
|
+
D(e);
|
|
1100
1152
|
};
|
|
1101
1153
|
}
|
|
1102
|
-
function
|
|
1103
|
-
|
|
1104
|
-
const e =
|
|
1154
|
+
function $s(t) {
|
|
1155
|
+
ue.ensure();
|
|
1156
|
+
const e = At(64 | $e, t);
|
|
1105
1157
|
return (o = {}) => new Promise((n) => {
|
|
1106
|
-
o.outro ?
|
|
1107
|
-
|
|
1108
|
-
}) : (
|
|
1158
|
+
o.outro ? de(e, () => {
|
|
1159
|
+
D(e), n(void 0);
|
|
1160
|
+
}) : (D(e), n(void 0));
|
|
1109
1161
|
});
|
|
1110
1162
|
}
|
|
1111
|
-
function
|
|
1112
|
-
return
|
|
1163
|
+
function Bi(t) {
|
|
1164
|
+
return At(4, t);
|
|
1113
1165
|
}
|
|
1114
|
-
function
|
|
1115
|
-
return
|
|
1166
|
+
function Ss(t) {
|
|
1167
|
+
return At(Or | $e, t);
|
|
1116
1168
|
}
|
|
1117
|
-
function
|
|
1118
|
-
return
|
|
1169
|
+
function bn(t, e = 0) {
|
|
1170
|
+
return At(8 | e, t);
|
|
1119
1171
|
}
|
|
1120
|
-
function
|
|
1121
|
-
|
|
1122
|
-
|
|
1172
|
+
function Qe(t, e = [], o = [], n = []) {
|
|
1173
|
+
ps(n, e, o, (i) => {
|
|
1174
|
+
At(8, () => t(...i.map(g)));
|
|
1123
1175
|
});
|
|
1124
1176
|
}
|
|
1125
|
-
function
|
|
1126
|
-
return
|
|
1177
|
+
function yn(t, e = 0) {
|
|
1178
|
+
return At(16 | e, t);
|
|
1127
1179
|
}
|
|
1128
|
-
function
|
|
1129
|
-
return
|
|
1180
|
+
function it(t) {
|
|
1181
|
+
return At(32 | $e, t);
|
|
1130
1182
|
}
|
|
1131
|
-
function
|
|
1183
|
+
function Fi(t) {
|
|
1132
1184
|
var e = t.teardown;
|
|
1133
1185
|
if (e !== null) {
|
|
1134
|
-
const o =
|
|
1135
|
-
|
|
1186
|
+
const o = Ot, n = _;
|
|
1187
|
+
Dn(!0), rt(null);
|
|
1136
1188
|
try {
|
|
1137
1189
|
e.call(null);
|
|
1138
1190
|
} finally {
|
|
1139
|
-
|
|
1191
|
+
Dn(o), rt(n);
|
|
1140
1192
|
}
|
|
1141
1193
|
}
|
|
1142
1194
|
}
|
|
1143
|
-
function
|
|
1195
|
+
function wn(t, e = !1) {
|
|
1144
1196
|
var o = t.first;
|
|
1145
1197
|
for (t.first = t.last = null; o !== null; ) {
|
|
1146
1198
|
const i = o.ac;
|
|
1147
|
-
i !== null &&
|
|
1148
|
-
i.abort(
|
|
1199
|
+
i !== null && Di(() => {
|
|
1200
|
+
i.abort(Mt);
|
|
1149
1201
|
});
|
|
1150
1202
|
var n = o.next;
|
|
1151
|
-
o.f & 64 ? o.parent = null :
|
|
1203
|
+
o.f & 64 ? o.parent = null : D(o, e), o = n;
|
|
1152
1204
|
}
|
|
1153
1205
|
}
|
|
1154
|
-
function
|
|
1206
|
+
function As(t) {
|
|
1155
1207
|
for (var e = t.first; e !== null; ) {
|
|
1156
1208
|
var o = e.next;
|
|
1157
|
-
e.f & 32 ||
|
|
1209
|
+
e.f & 32 || D(e), e = o;
|
|
1158
1210
|
}
|
|
1159
1211
|
}
|
|
1160
|
-
function
|
|
1212
|
+
function D(t, e = !0) {
|
|
1161
1213
|
var o = !1;
|
|
1162
|
-
(e || t.f & 262144) && t.nodes !== null && t.nodes.end !== null && (
|
|
1214
|
+
(e || t.f & 262144) && t.nodes !== null && t.nodes.end !== null && (xs(t.nodes.start, t.nodes.end), o = !0), j(t, Rn), wn(t, e && !o), Ve(t, 0);
|
|
1163
1215
|
var n = t.nodes && t.nodes.t;
|
|
1164
1216
|
if (n !== null) for (const r of n) r.stop();
|
|
1165
|
-
|
|
1217
|
+
Fi(t), t.f ^= Rn, t.f |= Lr;
|
|
1166
1218
|
var i = t.parent;
|
|
1167
|
-
i !== null && i.first !== null &&
|
|
1219
|
+
i !== null && i.first !== null && Gi(t), t.next = t.prev = t.teardown = t.ctx = t.deps = t.fn = t.nodes = t.ac = t.b = null;
|
|
1168
1220
|
}
|
|
1169
|
-
function
|
|
1221
|
+
function xs(t, e) {
|
|
1170
1222
|
for (; t !== null; ) {
|
|
1171
|
-
var o = t === e ? null : /* @__PURE__ */
|
|
1223
|
+
var o = t === e ? null : /* @__PURE__ */ St(t);
|
|
1172
1224
|
t.remove(), t = o;
|
|
1173
1225
|
}
|
|
1174
1226
|
}
|
|
1175
|
-
function
|
|
1227
|
+
function Gi(t) {
|
|
1176
1228
|
var e = t.parent, o = t.prev, n = t.next;
|
|
1177
1229
|
o !== null && (o.next = n), n !== null && (n.prev = o), e !== null && (e.first === t && (e.first = n), e.last === t && (e.last = o));
|
|
1178
1230
|
}
|
|
1179
|
-
function
|
|
1231
|
+
function de(t, e, o = !0) {
|
|
1180
1232
|
var n = [];
|
|
1181
|
-
|
|
1233
|
+
Ui(t, n, !0);
|
|
1182
1234
|
var i = () => {
|
|
1183
|
-
o &&
|
|
1235
|
+
o && D(t), e && e();
|
|
1184
1236
|
}, r = n.length;
|
|
1185
1237
|
if (r > 0) {
|
|
1186
1238
|
var s = () => --r || i();
|
|
1187
|
-
for (var
|
|
1239
|
+
for (var a of n) a.out(s);
|
|
1188
1240
|
} else i();
|
|
1189
1241
|
}
|
|
1190
|
-
function
|
|
1242
|
+
function Ui(t, e, o) {
|
|
1191
1243
|
if (!(t.f & 8192)) {
|
|
1192
|
-
t.f ^=
|
|
1244
|
+
t.f ^= nn;
|
|
1193
1245
|
var n = t.nodes && t.nodes.t;
|
|
1194
|
-
if (n !== null) for (const
|
|
1246
|
+
if (n !== null) for (const a of n) (a.is_global || o) && e.push(a);
|
|
1195
1247
|
for (var i = t.first; i !== null; ) {
|
|
1196
|
-
var r = i.next
|
|
1197
|
-
|
|
1248
|
+
var r = i.next;
|
|
1249
|
+
if (!(i.f & 64)) {
|
|
1250
|
+
var s = (i.f & 65536) !== 0 || (i.f & 32) !== 0 && (t.f & 16) !== 0;
|
|
1251
|
+
Ui(i, e, s ? o : !1);
|
|
1252
|
+
}
|
|
1253
|
+
i = r;
|
|
1198
1254
|
}
|
|
1199
1255
|
}
|
|
1200
1256
|
}
|
|
1201
|
-
function
|
|
1202
|
-
|
|
1257
|
+
function Tn(t) {
|
|
1258
|
+
Ji(t, !0);
|
|
1203
1259
|
}
|
|
1204
|
-
function
|
|
1260
|
+
function Ji(t, e) {
|
|
1205
1261
|
if (t.f & 8192) {
|
|
1206
|
-
t.f ^=
|
|
1262
|
+
t.f ^= nn, t.f & 1024 || (j(t, vt), ue.ensure().schedule(t));
|
|
1207
1263
|
for (var o = t.first; o !== null; ) {
|
|
1208
1264
|
var n = o.next, i = (o.f & 65536) !== 0 || (o.f & 32) !== 0;
|
|
1209
|
-
|
|
1265
|
+
Ji(o, i ? e : !1), o = n;
|
|
1210
1266
|
}
|
|
1211
1267
|
var r = t.nodes && t.nodes.t;
|
|
1212
1268
|
if (r !== null) for (const s of r) (s.is_global || e) && s.in();
|
|
1213
1269
|
}
|
|
1214
1270
|
}
|
|
1215
|
-
function
|
|
1271
|
+
function In(t, e) {
|
|
1216
1272
|
if (t.nodes) for (var o = t.nodes.start, n = t.nodes.end; o !== null; ) {
|
|
1217
|
-
var i = o === n ? null : /* @__PURE__ */
|
|
1273
|
+
var i = o === n ? null : /* @__PURE__ */ St(o);
|
|
1218
1274
|
e.append(o), o = i;
|
|
1219
1275
|
}
|
|
1220
1276
|
}
|
|
1221
|
-
var
|
|
1222
|
-
function
|
|
1223
|
-
|
|
1277
|
+
var _s = null, ro = !1, Ot = !1;
|
|
1278
|
+
function Dn(t) {
|
|
1279
|
+
Ot = t;
|
|
1224
1280
|
}
|
|
1225
|
-
var
|
|
1226
|
-
function
|
|
1227
|
-
|
|
1281
|
+
var _ = null, ht = !1;
|
|
1282
|
+
function rt(t) {
|
|
1283
|
+
_ = t;
|
|
1228
1284
|
}
|
|
1229
|
-
var
|
|
1230
|
-
function
|
|
1231
|
-
|
|
1285
|
+
var S = null;
|
|
1286
|
+
function $t(t) {
|
|
1287
|
+
S = t;
|
|
1232
1288
|
}
|
|
1233
|
-
var
|
|
1234
|
-
function
|
|
1235
|
-
|
|
1289
|
+
var ot = null;
|
|
1290
|
+
function Ki(t) {
|
|
1291
|
+
_ !== null && (!Pt || _.f & 2) && (ot === null ? ot = [t] : ot.push(t));
|
|
1236
1292
|
}
|
|
1237
|
-
var
|
|
1238
|
-
function
|
|
1239
|
-
|
|
1293
|
+
var G = null, Y = 0, tt = null;
|
|
1294
|
+
function Cs(t) {
|
|
1295
|
+
tt = t;
|
|
1240
1296
|
}
|
|
1241
|
-
var
|
|
1242
|
-
function
|
|
1243
|
-
|
|
1297
|
+
var Zi = 1, Xt = 0, ie = Xt;
|
|
1298
|
+
function Hn(t) {
|
|
1299
|
+
ie = t;
|
|
1244
1300
|
}
|
|
1245
|
-
function
|
|
1246
|
-
return ++
|
|
1301
|
+
function Yi() {
|
|
1302
|
+
return ++Zi;
|
|
1247
1303
|
}
|
|
1248
|
-
function
|
|
1304
|
+
function De(t) {
|
|
1249
1305
|
var e = t.f;
|
|
1250
1306
|
if (e & 2048) return !0;
|
|
1251
|
-
if (e & 2 && (t.f &= ~
|
|
1307
|
+
if (e & 2 && (t.f &= ~ze), e & 4096) {
|
|
1252
1308
|
for (var o = t.deps, n = o.length, i = 0; i < n; i++) {
|
|
1253
1309
|
var r = o[i];
|
|
1254
|
-
if (
|
|
1310
|
+
if (De(r) && Li(r), r.wv > t.wv) return !0;
|
|
1255
1311
|
}
|
|
1256
|
-
e & 512 &&
|
|
1312
|
+
e & 512 && q === null && j(t, nt);
|
|
1257
1313
|
}
|
|
1258
1314
|
return !1;
|
|
1259
1315
|
}
|
|
1260
|
-
function
|
|
1316
|
+
function Xi(t, e, o = !0) {
|
|
1261
1317
|
var n = t.reactions;
|
|
1262
|
-
if (n !== null && !(!
|
|
1318
|
+
if (n !== null && !(!Pt && ot !== null && be.call(ot, t))) for (var i = 0; i < n.length; i++) {
|
|
1263
1319
|
var r = n[i];
|
|
1264
|
-
r.f & 2 ?
|
|
1320
|
+
r.f & 2 ? Xi(r, e, !1) : e === r && (o ? j(r, vt) : r.f & 1024 && j(r, ce), dn(r));
|
|
1265
1321
|
}
|
|
1266
1322
|
}
|
|
1267
|
-
function
|
|
1268
|
-
var e =
|
|
1269
|
-
|
|
1270
|
-
t.ac.abort(
|
|
1323
|
+
function Qi(t) {
|
|
1324
|
+
var e = G, o = Y, n = tt, i = _, r = ot, s = V, a = ht, u = ie, l = t.f;
|
|
1325
|
+
G = null, Y = 0, tt = null, _ = l & 96 ? null : t, ot = null, ye(t.ctx), ht = !1, ie = ++Xt, t.ac !== null && (Di(() => {
|
|
1326
|
+
t.ac.abort(Mt);
|
|
1271
1327
|
}), t.ac = null);
|
|
1272
1328
|
try {
|
|
1273
|
-
t.f |=
|
|
1274
|
-
var d = t.fn,
|
|
1275
|
-
t.f |=
|
|
1276
|
-
var
|
|
1277
|
-
if (
|
|
1329
|
+
t.f |= jn;
|
|
1330
|
+
var d = t.fn, h = d();
|
|
1331
|
+
t.f |= rn;
|
|
1332
|
+
var f = t.deps, v = x?.is_fork;
|
|
1333
|
+
if (G !== null) {
|
|
1278
1334
|
var m;
|
|
1279
|
-
if (v ||
|
|
1280
|
-
else t.deps =
|
|
1281
|
-
if (
|
|
1282
|
-
var
|
|
1283
|
-
((
|
|
1335
|
+
if (v || Ve(t, Y), f !== null && Y > 0) for (f.length = Y + G.length, m = 0; m < G.length; m++) f[Y + m] = G[m];
|
|
1336
|
+
else t.deps = f = G;
|
|
1337
|
+
if (mn() && t.f & 512) for (m = Y; m < f.length; m++) {
|
|
1338
|
+
var k;
|
|
1339
|
+
((k = f[m]).reactions ?? (k.reactions = [])).push(t);
|
|
1284
1340
|
}
|
|
1285
|
-
} else !v &&
|
|
1286
|
-
if (
|
|
1341
|
+
} else !v && f !== null && Y < f.length && (Ve(t, Y), f.length = Y);
|
|
1342
|
+
if (qe() && tt !== null && !ht && f !== null && !(t.f & 6146)) for (m = 0; m < tt.length; m++) Xi(tt[m], t);
|
|
1287
1343
|
if (i !== null && i !== t) {
|
|
1288
|
-
if (
|
|
1289
|
-
if (e !== null) for (const p of e) p.rv =
|
|
1290
|
-
|
|
1344
|
+
if (Xt++, i.deps !== null) for (let p = 0; p < o; p += 1) i.deps[p].rv = Xt;
|
|
1345
|
+
if (e !== null) for (const p of e) p.rv = Xt;
|
|
1346
|
+
tt !== null && (n === null ? n = tt : n.push(...tt));
|
|
1291
1347
|
}
|
|
1292
|
-
return t.f & 8388608 && (t.f ^=
|
|
1348
|
+
return t.f & 8388608 && (t.f ^= po), h;
|
|
1293
1349
|
} catch (p) {
|
|
1294
|
-
return
|
|
1350
|
+
return bi(p);
|
|
1295
1351
|
} finally {
|
|
1296
|
-
t.f ^=
|
|
1352
|
+
t.f ^= jn, G = e, Y = o, tt = n, _ = i, ot = r, ye(s), ht = a, ie = u;
|
|
1297
1353
|
}
|
|
1298
1354
|
}
|
|
1299
|
-
function
|
|
1355
|
+
function Es(t, e) {
|
|
1300
1356
|
let o = e.reactions;
|
|
1301
1357
|
if (o !== null) {
|
|
1302
|
-
var n =
|
|
1358
|
+
var n = Ar.call(o, t);
|
|
1303
1359
|
if (n !== -1) {
|
|
1304
1360
|
var i = o.length - 1;
|
|
1305
1361
|
i === 0 ? o = e.reactions = null : (o[n] = o[i], o.pop());
|
|
1306
1362
|
}
|
|
1307
1363
|
}
|
|
1308
|
-
if (o === null && e.f & 2 && (
|
|
1364
|
+
if (o === null && e.f & 2 && (G === null || !be.call(G, e))) {
|
|
1309
1365
|
var r = e;
|
|
1310
|
-
r.f & 512 && (r.f ^= 512, r.f &= ~
|
|
1366
|
+
r.f & 512 && (r.f ^= 512, r.f &= ~ze), r.v !== N && an(r), bs(r), Ve(r, 0);
|
|
1311
1367
|
}
|
|
1312
1368
|
}
|
|
1313
|
-
function
|
|
1369
|
+
function Ve(t, e) {
|
|
1314
1370
|
var o = t.deps;
|
|
1315
|
-
if (o !== null) for (var n = e; n < o.length; n++)
|
|
1371
|
+
if (o !== null) for (var n = e; n < o.length; n++) Es(t, o[n]);
|
|
1316
1372
|
}
|
|
1317
|
-
function
|
|
1373
|
+
function ke(t) {
|
|
1318
1374
|
var e = t.f;
|
|
1319
1375
|
if (!(e & 16384)) {
|
|
1320
|
-
|
|
1321
|
-
var o =
|
|
1322
|
-
|
|
1376
|
+
j(t, nt);
|
|
1377
|
+
var o = S, n = ro;
|
|
1378
|
+
S = t, ro = !0;
|
|
1323
1379
|
try {
|
|
1324
|
-
e & 16777232 ?
|
|
1325
|
-
var i =
|
|
1326
|
-
t.teardown = typeof i == "function" ? i : null, t.wv =
|
|
1380
|
+
e & 16777232 ? As(t) : wn(t), Fi(t);
|
|
1381
|
+
var i = Qi(t);
|
|
1382
|
+
t.teardown = typeof i == "function" ? i : null, t.wv = Zi;
|
|
1327
1383
|
} finally {
|
|
1328
|
-
|
|
1384
|
+
ro = n, S = o;
|
|
1329
1385
|
}
|
|
1330
1386
|
}
|
|
1331
1387
|
}
|
|
1332
1388
|
function g(t) {
|
|
1333
1389
|
var e = (t.f & 2) !== 0;
|
|
1334
|
-
if (
|
|
1335
|
-
var o =
|
|
1336
|
-
if (
|
|
1390
|
+
if (_s?.add(t), _ !== null && !ht && !(S !== null && S.f & 16384) && (ot === null || !be.call(ot, t))) {
|
|
1391
|
+
var o = _.deps;
|
|
1392
|
+
if (_.f & 2097152) t.rv < Xt && (t.rv = Xt, G === null && o !== null && o[Y] === t ? Y++ : G === null ? G = [t] : G.push(t));
|
|
1337
1393
|
else {
|
|
1338
1394
|
var n;
|
|
1339
|
-
((n =
|
|
1395
|
+
((n = _).deps ?? (n.deps = [])).push(t);
|
|
1340
1396
|
var i = t.reactions;
|
|
1341
|
-
i === null ? t.reactions = [
|
|
1397
|
+
i === null ? t.reactions = [_] : be.call(i, _) || i.push(_);
|
|
1342
1398
|
}
|
|
1343
1399
|
}
|
|
1344
|
-
if (
|
|
1400
|
+
if (Ot && ne.has(t)) return ne.get(t);
|
|
1345
1401
|
if (e) {
|
|
1346
1402
|
var r = t;
|
|
1347
|
-
if (
|
|
1403
|
+
if (Ot) {
|
|
1348
1404
|
var s = r.v;
|
|
1349
|
-
return (!(r.f & 1024) && r.reactions !== null ||
|
|
1405
|
+
return (!(r.f & 1024) && r.reactions !== null || er(r)) && (s = pn(r)), ne.set(r, s), s;
|
|
1350
1406
|
}
|
|
1351
|
-
var
|
|
1352
|
-
|
|
1407
|
+
var a = (r.f & 512) === 0 && !ht && _ !== null && (ro || (_.f & 512) !== 0), u = (r.f & rn) === 0;
|
|
1408
|
+
De(r) && (a && (r.f |= 512), Li(r)), a && !u && (Pi(r), tr(r));
|
|
1353
1409
|
}
|
|
1354
|
-
if (
|
|
1410
|
+
if (q?.has(t)) return q.get(t);
|
|
1355
1411
|
if (t.f & 8388608) throw t.v;
|
|
1356
1412
|
return t.v;
|
|
1357
1413
|
}
|
|
1358
|
-
function
|
|
1359
|
-
if (t.f |= 512, t.deps !== null) for (const e of t.deps) (e.reactions ?? (e.reactions = [])).push(t), e.f & 2 && !(e.f & 512) && (
|
|
1414
|
+
function tr(t) {
|
|
1415
|
+
if (t.f |= 512, t.deps !== null) for (const e of t.deps) (e.reactions ?? (e.reactions = [])).push(t), e.f & 2 && !(e.f & 512) && (Pi(e), tr(e));
|
|
1360
1416
|
}
|
|
1361
|
-
function
|
|
1362
|
-
if (t.v ===
|
|
1417
|
+
function er(t) {
|
|
1418
|
+
if (t.v === N) return !0;
|
|
1363
1419
|
if (t.deps === null) return !1;
|
|
1364
|
-
for (const e of t.deps) if (
|
|
1420
|
+
for (const e of t.deps) if (ne.has(e) || e.f & 2 && er(e)) return !0;
|
|
1365
1421
|
return !1;
|
|
1366
1422
|
}
|
|
1367
|
-
function
|
|
1368
|
-
var e =
|
|
1423
|
+
function kn(t) {
|
|
1424
|
+
var e = ht;
|
|
1369
1425
|
try {
|
|
1370
|
-
return
|
|
1426
|
+
return ht = !0, t();
|
|
1371
1427
|
} finally {
|
|
1372
|
-
|
|
1428
|
+
ht = e;
|
|
1373
1429
|
}
|
|
1374
1430
|
}
|
|
1375
|
-
var
|
|
1376
|
-
function
|
|
1377
|
-
(e[
|
|
1431
|
+
var ve = Symbol("events"), or = /* @__PURE__ */ new Set(), Qo = /* @__PURE__ */ new Set();
|
|
1432
|
+
function _e(t, e, o) {
|
|
1433
|
+
(e[ve] ?? (e[ve] = {}))[t] = o;
|
|
1378
1434
|
}
|
|
1379
|
-
function
|
|
1380
|
-
for (var e = 0; e < t.length; e++)
|
|
1381
|
-
for (var o of
|
|
1435
|
+
function Ms(t) {
|
|
1436
|
+
for (var e = 0; e < t.length; e++) or.add(t[e]);
|
|
1437
|
+
for (var o of Qo) o(t);
|
|
1382
1438
|
}
|
|
1383
|
-
var
|
|
1384
|
-
function
|
|
1439
|
+
var Bn = null;
|
|
1440
|
+
function Fn(t) {
|
|
1385
1441
|
var e = this, o = e.ownerDocument, n = t.type, i = t.composedPath?.() || [], r = i[0] || t.target;
|
|
1386
|
-
|
|
1387
|
-
var s = 0,
|
|
1388
|
-
if (
|
|
1389
|
-
var
|
|
1390
|
-
if (
|
|
1391
|
-
t[
|
|
1442
|
+
Bn = t;
|
|
1443
|
+
var s = 0, a = Bn === t && t[ve];
|
|
1444
|
+
if (a) {
|
|
1445
|
+
var u = i.indexOf(a);
|
|
1446
|
+
if (u !== -1 && (e === document || e === window)) {
|
|
1447
|
+
t[ve] = e;
|
|
1392
1448
|
return;
|
|
1393
1449
|
}
|
|
1394
|
-
var
|
|
1395
|
-
if (
|
|
1396
|
-
|
|
1450
|
+
var l = i.indexOf(e);
|
|
1451
|
+
if (l === -1) return;
|
|
1452
|
+
u <= l && (s = u);
|
|
1397
1453
|
}
|
|
1398
1454
|
if (r = i[s] || t.target, r !== e) {
|
|
1399
|
-
|
|
1455
|
+
fo(t, "currentTarget", {
|
|
1400
1456
|
configurable: !0,
|
|
1401
1457
|
get() {
|
|
1402
1458
|
return r || o;
|
|
1403
1459
|
}
|
|
1404
1460
|
});
|
|
1405
|
-
var d =
|
|
1406
|
-
|
|
1461
|
+
var d = _, h = S;
|
|
1462
|
+
rt(null), $t(null);
|
|
1407
1463
|
try {
|
|
1408
|
-
for (var
|
|
1464
|
+
for (var f, v = []; r !== null; ) {
|
|
1409
1465
|
var m = r.assignedSlot || r.parentNode || r.host || null;
|
|
1410
1466
|
try {
|
|
1411
|
-
var
|
|
1412
|
-
|
|
1467
|
+
var k = r[ve]?.[n];
|
|
1468
|
+
k != null && (!r.disabled || t.target === r) && k.call(r, t);
|
|
1413
1469
|
} catch (p) {
|
|
1414
|
-
|
|
1470
|
+
f ? v.push(p) : f = p;
|
|
1415
1471
|
}
|
|
1416
1472
|
if (t.cancelBubble || m === e || m === null) break;
|
|
1417
1473
|
r = m;
|
|
1418
1474
|
}
|
|
1419
|
-
if (
|
|
1475
|
+
if (f) {
|
|
1420
1476
|
for (let p of v) queueMicrotask(() => {
|
|
1421
1477
|
throw p;
|
|
1422
1478
|
});
|
|
1423
|
-
throw
|
|
1479
|
+
throw f;
|
|
1424
1480
|
}
|
|
1425
1481
|
} finally {
|
|
1426
|
-
t[
|
|
1482
|
+
t[ve] = e, delete t.currentTarget, rt(d), $t(h);
|
|
1427
1483
|
}
|
|
1428
1484
|
}
|
|
1429
1485
|
}
|
|
1430
|
-
var
|
|
1431
|
-
function
|
|
1432
|
-
return
|
|
1486
|
+
var Ls = globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", { createHTML: (t) => t });
|
|
1487
|
+
function Ps(t) {
|
|
1488
|
+
return Ls?.createHTML(t) ?? t;
|
|
1433
1489
|
}
|
|
1434
|
-
function
|
|
1435
|
-
var e =
|
|
1436
|
-
return e.innerHTML =
|
|
1490
|
+
function Os(t) {
|
|
1491
|
+
var e = vn("template");
|
|
1492
|
+
return e.innerHTML = Ps(t.replaceAll("<!>", "<!---->")), e.content;
|
|
1437
1493
|
}
|
|
1438
|
-
function
|
|
1439
|
-
var o =
|
|
1494
|
+
function so(t, e) {
|
|
1495
|
+
var o = S;
|
|
1440
1496
|
o.nodes === null && (o.nodes = {
|
|
1441
1497
|
start: t,
|
|
1442
1498
|
end: e,
|
|
@@ -1445,341 +1501,341 @@ function to(t, e) {
|
|
|
1445
1501
|
});
|
|
1446
1502
|
}
|
|
1447
1503
|
// @__NO_SIDE_EFFECTS__
|
|
1448
|
-
function
|
|
1504
|
+
function he(t, e) {
|
|
1449
1505
|
var o = (e & 1) !== 0, n = (e & 2) !== 0, i, r = !t.startsWith("<!>");
|
|
1450
1506
|
return () => {
|
|
1451
|
-
if (
|
|
1452
|
-
i === void 0 && (i =
|
|
1453
|
-
var s = n ||
|
|
1507
|
+
if (P) return so(L, null), L;
|
|
1508
|
+
i === void 0 && (i = Os(r ? t : "<!>" + t), o || (i = /* @__PURE__ */ le(i)));
|
|
1509
|
+
var s = n || Ni ? document.importNode(i, !0) : i.cloneNode(!0);
|
|
1454
1510
|
if (o) {
|
|
1455
|
-
var
|
|
1456
|
-
|
|
1457
|
-
} else
|
|
1511
|
+
var a = /* @__PURE__ */ le(s), u = s.lastChild;
|
|
1512
|
+
so(a, u);
|
|
1513
|
+
} else so(s, s);
|
|
1458
1514
|
return s;
|
|
1459
1515
|
};
|
|
1460
1516
|
}
|
|
1461
|
-
function
|
|
1462
|
-
if (
|
|
1463
|
-
var o =
|
|
1464
|
-
(!(o.f & 32768) || o.nodes.end === null) && (o.nodes.end =
|
|
1517
|
+
function zt(t, e) {
|
|
1518
|
+
if (P) {
|
|
1519
|
+
var o = S;
|
|
1520
|
+
(!(o.f & 32768) || o.nodes.end === null) && (o.nodes.end = L), ko();
|
|
1465
1521
|
return;
|
|
1466
1522
|
}
|
|
1467
1523
|
t !== null && t.before(e);
|
|
1468
1524
|
}
|
|
1469
|
-
var
|
|
1470
|
-
function
|
|
1471
|
-
return
|
|
1525
|
+
var Rs = ["touchstart", "touchmove"];
|
|
1526
|
+
function js(t) {
|
|
1527
|
+
return Rs.includes(t);
|
|
1472
1528
|
}
|
|
1473
|
-
function
|
|
1529
|
+
function Gn(t, e) {
|
|
1474
1530
|
var o = e == null ? "" : typeof e == "object" ? `${e}` : e;
|
|
1475
1531
|
o !== (t.__t ?? (t.__t = t.nodeValue)) && (t.__t = o, t.nodeValue = `${o}`);
|
|
1476
1532
|
}
|
|
1477
|
-
function
|
|
1478
|
-
return
|
|
1533
|
+
function nr(t, e) {
|
|
1534
|
+
return ir(t, e);
|
|
1479
1535
|
}
|
|
1480
|
-
function
|
|
1481
|
-
|
|
1482
|
-
const o = e.target, n =
|
|
1536
|
+
function Ns(t, e) {
|
|
1537
|
+
Xo(), e.intro = e.intro ?? !1;
|
|
1538
|
+
const o = e.target, n = P, i = L;
|
|
1483
1539
|
try {
|
|
1484
|
-
for (var r = /* @__PURE__ */
|
|
1485
|
-
if (!r) throw
|
|
1486
|
-
|
|
1487
|
-
const s =
|
|
1540
|
+
for (var r = /* @__PURE__ */ le(o); r && (r.nodeType !== 8 || r.data !== "["); ) r = /* @__PURE__ */ St(r);
|
|
1541
|
+
if (!r) throw me;
|
|
1542
|
+
Lt(!0), U(r);
|
|
1543
|
+
const s = ir(t, {
|
|
1488
1544
|
...e,
|
|
1489
1545
|
anchor: r
|
|
1490
1546
|
});
|
|
1491
|
-
return
|
|
1547
|
+
return Lt(!1), s;
|
|
1492
1548
|
} catch (s) {
|
|
1493
1549
|
if (s instanceof Error && s.message.split(`
|
|
1494
|
-
`).some((
|
|
1495
|
-
return s !==
|
|
1550
|
+
`).some((a) => a.startsWith("https://svelte.dev/e/"))) throw s;
|
|
1551
|
+
return s !== me && console.warn("Failed to hydrate: ", s), e.recover === !1 && Hr(), Xo(), zi(o), Lt(!1), nr(t, e);
|
|
1496
1552
|
} finally {
|
|
1497
|
-
|
|
1553
|
+
Lt(n), U(i);
|
|
1498
1554
|
}
|
|
1499
1555
|
}
|
|
1500
|
-
var
|
|
1501
|
-
function
|
|
1502
|
-
|
|
1503
|
-
var
|
|
1504
|
-
var d = o ?? e.appendChild(
|
|
1505
|
-
|
|
1556
|
+
var to = /* @__PURE__ */ new Map();
|
|
1557
|
+
function ir(t, { target: e, anchor: o, props: n = {}, events: i, context: r, intro: s = !0, transformError: a }) {
|
|
1558
|
+
Xo();
|
|
1559
|
+
var u = void 0, l = $s(() => {
|
|
1560
|
+
var d = o ?? e.appendChild(pt());
|
|
1561
|
+
cs(d, { pending: () => {
|
|
1506
1562
|
} }, (v) => {
|
|
1507
|
-
|
|
1508
|
-
var m =
|
|
1509
|
-
if (r && (m.c = r), i && (n.$$events = i),
|
|
1510
|
-
|
|
1511
|
-
},
|
|
1512
|
-
var
|
|
1563
|
+
vi({});
|
|
1564
|
+
var m = V;
|
|
1565
|
+
if (r && (m.c = r), i && (n.$$events = i), P && so(v, null), u = t(v, n) || {}, P && (S.nodes.end = L, L === null || L.nodeType !== 8 || L.data !== "]")) throw Io(), me;
|
|
1566
|
+
gi();
|
|
1567
|
+
}, a);
|
|
1568
|
+
var h = /* @__PURE__ */ new Set(), f = (v) => {
|
|
1513
1569
|
for (var m = 0; m < v.length; m++) {
|
|
1514
|
-
var
|
|
1515
|
-
if (!
|
|
1516
|
-
|
|
1517
|
-
var p =
|
|
1518
|
-
for (const
|
|
1519
|
-
var w =
|
|
1520
|
-
w === void 0 && (w = /* @__PURE__ */ new Map(),
|
|
1521
|
-
var R = w.get(
|
|
1522
|
-
R === void 0 ? (
|
|
1570
|
+
var k = v[m];
|
|
1571
|
+
if (!h.has(k)) {
|
|
1572
|
+
h.add(k);
|
|
1573
|
+
var p = js(k);
|
|
1574
|
+
for (const A of [e, document]) {
|
|
1575
|
+
var w = to.get(A);
|
|
1576
|
+
w === void 0 && (w = /* @__PURE__ */ new Map(), to.set(A, w));
|
|
1577
|
+
var R = w.get(k);
|
|
1578
|
+
R === void 0 ? (A.addEventListener(k, Fn, { passive: p }), w.set(k, 1)) : w.set(k, R + 1);
|
|
1523
1579
|
}
|
|
1524
1580
|
}
|
|
1525
1581
|
}
|
|
1526
1582
|
};
|
|
1527
|
-
return
|
|
1528
|
-
for (var v of
|
|
1529
|
-
var m =
|
|
1530
|
-
--
|
|
1583
|
+
return f(To(or)), Qo.add(f), () => {
|
|
1584
|
+
for (var v of h) for (const p of [e, document]) {
|
|
1585
|
+
var m = to.get(p), k = m.get(v);
|
|
1586
|
+
--k == 0 ? (p.removeEventListener(v, Fn), m.delete(v), m.size === 0 && to.delete(p)) : m.set(v, k);
|
|
1531
1587
|
}
|
|
1532
|
-
|
|
1588
|
+
Qo.delete(f), d !== o && d.parentNode?.removeChild(d);
|
|
1533
1589
|
};
|
|
1534
1590
|
});
|
|
1535
|
-
return
|
|
1591
|
+
return tn.set(u, l), u;
|
|
1536
1592
|
}
|
|
1537
|
-
var
|
|
1538
|
-
function
|
|
1539
|
-
const o =
|
|
1540
|
-
return o ? (
|
|
1593
|
+
var tn = /* @__PURE__ */ new WeakMap();
|
|
1594
|
+
function Ws(t, e) {
|
|
1595
|
+
const o = tn.get(t);
|
|
1596
|
+
return o ? (tn.delete(t), o(e)) : Promise.resolve();
|
|
1541
1597
|
}
|
|
1542
|
-
var
|
|
1598
|
+
var _t = /* @__PURE__ */ new WeakMap(), jt = /* @__PURE__ */ new WeakMap(), ct = /* @__PURE__ */ new WeakMap(), Ce = /* @__PURE__ */ new WeakMap(), Lo = /* @__PURE__ */ new WeakMap(), Po = /* @__PURE__ */ new WeakMap(), Un = /* @__PURE__ */ new WeakMap(), Vs = class {
|
|
1543
1599
|
constructor(t, e = !0) {
|
|
1544
|
-
y(this, "anchor", void 0),
|
|
1545
|
-
if (
|
|
1546
|
-
var n =
|
|
1547
|
-
if (i)
|
|
1600
|
+
y(this, "anchor", void 0), I(this, _t, /* @__PURE__ */ new Map()), I(this, jt, /* @__PURE__ */ new Map()), I(this, ct, /* @__PURE__ */ new Map()), I(this, Ce, /* @__PURE__ */ new Set()), I(this, Lo, !0), I(this, Po, (o) => {
|
|
1601
|
+
if (c(_t, this).has(o)) {
|
|
1602
|
+
var n = c(_t, this).get(o), i = c(jt, this).get(n);
|
|
1603
|
+
if (i) Tn(i), c(Ce, this).delete(n);
|
|
1548
1604
|
else {
|
|
1549
|
-
var r =
|
|
1550
|
-
r && (
|
|
1605
|
+
var r = c(ct, this).get(n);
|
|
1606
|
+
r && (c(jt, this).set(n, r.effect), c(ct, this).delete(n), r.fragment.lastChild.remove(), this.anchor.before(r.fragment), i = r.effect);
|
|
1551
1607
|
}
|
|
1552
|
-
for (const [s,
|
|
1553
|
-
if (
|
|
1554
|
-
const
|
|
1555
|
-
|
|
1608
|
+
for (const [s, a] of c(_t, this)) {
|
|
1609
|
+
if (c(_t, this).delete(s), s === o) break;
|
|
1610
|
+
const u = c(ct, this).get(a);
|
|
1611
|
+
u && (D(u.effect), c(ct, this).delete(a));
|
|
1556
1612
|
}
|
|
1557
|
-
for (const [s,
|
|
1558
|
-
if (s === n ||
|
|
1559
|
-
const
|
|
1560
|
-
if (Array.from(
|
|
1561
|
-
var
|
|
1562
|
-
|
|
1563
|
-
effect:
|
|
1564
|
-
fragment:
|
|
1613
|
+
for (const [s, a] of c(jt, this)) {
|
|
1614
|
+
if (s === n || c(Ce, this).has(s)) continue;
|
|
1615
|
+
const u = () => {
|
|
1616
|
+
if (Array.from(c(_t, this).values()).includes(s)) {
|
|
1617
|
+
var l = document.createDocumentFragment();
|
|
1618
|
+
In(a, l), l.append(pt()), c(ct, this).set(s, {
|
|
1619
|
+
effect: a,
|
|
1620
|
+
fragment: l
|
|
1565
1621
|
});
|
|
1566
|
-
} else
|
|
1567
|
-
|
|
1622
|
+
} else D(a);
|
|
1623
|
+
c(Ce, this).delete(s), c(jt, this).delete(s);
|
|
1568
1624
|
};
|
|
1569
|
-
|
|
1625
|
+
c(Lo, this) || !i ? (c(Ce, this).add(s), de(a, u, !1)) : u();
|
|
1570
1626
|
}
|
|
1571
1627
|
}
|
|
1572
|
-
}),
|
|
1573
|
-
|
|
1574
|
-
const n = Array.from(
|
|
1575
|
-
for (const [i, r] of
|
|
1576
|
-
}), this.anchor = t,
|
|
1628
|
+
}), I(this, Un, (o) => {
|
|
1629
|
+
c(_t, this).delete(o);
|
|
1630
|
+
const n = Array.from(c(_t, this).values());
|
|
1631
|
+
for (const [i, r] of c(ct, this)) n.includes(i) || (D(r.effect), c(ct, this).delete(i));
|
|
1632
|
+
}), this.anchor = t, $(Lo, this, e);
|
|
1577
1633
|
}
|
|
1578
1634
|
ensure(t, e) {
|
|
1579
|
-
var o =
|
|
1580
|
-
if (e && !
|
|
1581
|
-
var i = document.createDocumentFragment(), r =
|
|
1582
|
-
i.append(r),
|
|
1583
|
-
effect:
|
|
1635
|
+
var o = x, n = qi();
|
|
1636
|
+
if (e && !c(jt, this).has(t) && !c(ct, this).has(t)) if (n) {
|
|
1637
|
+
var i = document.createDocumentFragment(), r = pt();
|
|
1638
|
+
i.append(r), c(ct, this).set(t, {
|
|
1639
|
+
effect: it(() => e(r)),
|
|
1584
1640
|
fragment: i
|
|
1585
1641
|
});
|
|
1586
|
-
} else
|
|
1587
|
-
if (
|
|
1588
|
-
for (const [s,
|
|
1589
|
-
for (const [s,
|
|
1590
|
-
o.oncommit(
|
|
1591
|
-
} else
|
|
1642
|
+
} else c(jt, this).set(t, it(() => e(this.anchor)));
|
|
1643
|
+
if (c(_t, this).set(o, t), n) {
|
|
1644
|
+
for (const [s, a] of c(jt, this)) s === t ? o.unskip_effect(a) : o.skip_effect(a);
|
|
1645
|
+
for (const [s, a] of c(ct, this)) s === t ? o.unskip_effect(a.effect) : o.skip_effect(a.effect);
|
|
1646
|
+
o.oncommit(c(Po, this)), o.ondiscard(c(Un, this));
|
|
1647
|
+
} else P && (this.anchor = L), c(Po, this).call(this, o);
|
|
1592
1648
|
}
|
|
1593
1649
|
};
|
|
1594
|
-
function
|
|
1650
|
+
function Ee(t, e, o = !1) {
|
|
1595
1651
|
var n;
|
|
1596
|
-
|
|
1597
|
-
var i = new
|
|
1598
|
-
function s(
|
|
1599
|
-
if (
|
|
1600
|
-
var
|
|
1601
|
-
if (
|
|
1602
|
-
var d =
|
|
1603
|
-
|
|
1652
|
+
P && (n = L, ko());
|
|
1653
|
+
var i = new Vs(t), r = o ? sn : 0;
|
|
1654
|
+
function s(a, u) {
|
|
1655
|
+
if (P) {
|
|
1656
|
+
var l = hi(n);
|
|
1657
|
+
if (a !== parseInt(l.substring(1))) {
|
|
1658
|
+
var d = vo();
|
|
1659
|
+
U(d), i.anchor = d, Lt(!1), i.ensure(a, u), Lt(!0);
|
|
1604
1660
|
return;
|
|
1605
1661
|
}
|
|
1606
1662
|
}
|
|
1607
|
-
i.ensure(
|
|
1663
|
+
i.ensure(a, u);
|
|
1608
1664
|
}
|
|
1609
|
-
|
|
1610
|
-
var
|
|
1611
|
-
e((
|
|
1612
|
-
|
|
1613
|
-
}),
|
|
1665
|
+
yn(() => {
|
|
1666
|
+
var a = !1;
|
|
1667
|
+
e((u, l = 0) => {
|
|
1668
|
+
a = !0, s(l, u);
|
|
1669
|
+
}), a || s(-1, null);
|
|
1614
1670
|
}, r);
|
|
1615
1671
|
}
|
|
1616
|
-
function
|
|
1672
|
+
function zs(t, e) {
|
|
1617
1673
|
return e;
|
|
1618
1674
|
}
|
|
1619
|
-
function
|
|
1620
|
-
for (var n = [], i = e.length, r, s = e.length,
|
|
1621
|
-
let
|
|
1622
|
-
|
|
1675
|
+
function qs(t, e, o) {
|
|
1676
|
+
for (var n = [], i = e.length, r, s = e.length, a = 0; a < i; a++) {
|
|
1677
|
+
let h = e[a];
|
|
1678
|
+
de(h, () => {
|
|
1623
1679
|
if (r) {
|
|
1624
|
-
if (r.pending.delete(
|
|
1625
|
-
var
|
|
1626
|
-
|
|
1680
|
+
if (r.pending.delete(h), r.done.add(h), r.pending.size === 0) {
|
|
1681
|
+
var f = t.outrogroups;
|
|
1682
|
+
en(t, To(r.done)), f.delete(r), f.size === 0 && (t.outrogroups = null);
|
|
1627
1683
|
}
|
|
1628
1684
|
} else s -= 1;
|
|
1629
1685
|
}, !1);
|
|
1630
1686
|
}
|
|
1631
1687
|
if (s === 0) {
|
|
1632
|
-
var
|
|
1633
|
-
if (
|
|
1634
|
-
var
|
|
1635
|
-
|
|
1688
|
+
var u = n.length === 0 && o !== null;
|
|
1689
|
+
if (u) {
|
|
1690
|
+
var l = o, d = l.parentNode;
|
|
1691
|
+
zi(d), d.append(l), t.items.clear();
|
|
1636
1692
|
}
|
|
1637
|
-
|
|
1693
|
+
en(t, e, !u);
|
|
1638
1694
|
} else r = {
|
|
1639
1695
|
pending: new Set(e),
|
|
1640
1696
|
done: /* @__PURE__ */ new Set()
|
|
1641
1697
|
}, (t.outrogroups ?? (t.outrogroups = /* @__PURE__ */ new Set())).add(r);
|
|
1642
1698
|
}
|
|
1643
|
-
function
|
|
1699
|
+
function en(t, e, o = !0) {
|
|
1644
1700
|
var n;
|
|
1645
1701
|
if (t.pending.size > 0) {
|
|
1646
1702
|
n = /* @__PURE__ */ new Set();
|
|
1647
|
-
for (const s of t.pending.values()) for (const
|
|
1703
|
+
for (const s of t.pending.values()) for (const a of s) n.add(t.items.get(a).e);
|
|
1648
1704
|
}
|
|
1649
1705
|
for (var i = 0; i < e.length; i++) {
|
|
1650
1706
|
var r = e[i];
|
|
1651
|
-
n?.has(r) ? (r.f |=
|
|
1707
|
+
n?.has(r) ? (r.f |= Oe, In(r, document.createDocumentFragment())) : D(e[i], o);
|
|
1652
1708
|
}
|
|
1653
1709
|
}
|
|
1654
|
-
var
|
|
1655
|
-
function
|
|
1656
|
-
var s = t,
|
|
1710
|
+
var eo;
|
|
1711
|
+
function Ds(t, e, o, n, i, r = null) {
|
|
1712
|
+
var s = t, a = /* @__PURE__ */ new Map();
|
|
1657
1713
|
if (e & 4) {
|
|
1658
|
-
var
|
|
1659
|
-
s =
|
|
1714
|
+
var u = t;
|
|
1715
|
+
s = P ? U(/* @__PURE__ */ le(u)) : u.appendChild(pt());
|
|
1660
1716
|
}
|
|
1661
|
-
|
|
1662
|
-
var
|
|
1717
|
+
P && ko();
|
|
1718
|
+
var l = null, d = /* @__PURE__ */ fn(() => {
|
|
1663
1719
|
var w = o();
|
|
1664
|
-
return
|
|
1665
|
-
}),
|
|
1720
|
+
return li(w) ? w : w == null ? [] : To(w);
|
|
1721
|
+
}), h, f = /* @__PURE__ */ new Map(), v = !0;
|
|
1666
1722
|
function m(w) {
|
|
1667
|
-
p.effect.f & 16384 || (p.pending.delete(w), p.fallback =
|
|
1668
|
-
|
|
1723
|
+
p.effect.f & 16384 || (p.pending.delete(w), p.fallback = l, Hs(p, h, s, e, n), l !== null && (h.length === 0 ? l.f & 33554432 ? (l.f ^= Oe, Pe(l, null, s)) : Tn(l) : de(l, () => {
|
|
1724
|
+
l = null;
|
|
1669
1725
|
})));
|
|
1670
1726
|
}
|
|
1671
|
-
function
|
|
1727
|
+
function k(w) {
|
|
1672
1728
|
p.pending.delete(w);
|
|
1673
1729
|
}
|
|
1674
1730
|
var p = {
|
|
1675
|
-
effect:
|
|
1676
|
-
|
|
1677
|
-
var w =
|
|
1731
|
+
effect: yn(() => {
|
|
1732
|
+
h = g(d);
|
|
1733
|
+
var w = h.length;
|
|
1678
1734
|
let R = !1;
|
|
1679
|
-
|
|
1680
|
-
for (var
|
|
1681
|
-
|
|
1682
|
-
var
|
|
1683
|
-
K ? (K.v &&
|
|
1735
|
+
P && hi(s) === "[!" != (w === 0) && (s = vo(), U(s), Lt(!1), R = !0);
|
|
1736
|
+
for (var A = /* @__PURE__ */ new Set(), O = x, J = qi(), H = 0; H < w; H += 1) {
|
|
1737
|
+
P && L.nodeType === 8 && L.data === "]" && (s = L, R = !0, Lt(!1));
|
|
1738
|
+
var B = h[H], gt = n(B, H), K = v ? null : a.get(gt);
|
|
1739
|
+
K ? (K.v && Ie(K.v, B), K.i && Ie(K.i, H), J && O.unskip_effect(K.e)) : (K = Bs(a, v ? s : eo ?? (eo = pt()), B, gt, H, i, e, o), v || (K.e.f |= Oe), a.set(gt, K)), A.add(gt);
|
|
1684
1740
|
}
|
|
1685
|
-
if (w === 0 && r && !
|
|
1686
|
-
for (const [
|
|
1687
|
-
|
|
1688
|
-
} else m(
|
|
1689
|
-
R &&
|
|
1741
|
+
if (w === 0 && r && !l && (v ? l = it(() => r(s)) : (l = it(() => r(eo ?? (eo = pt()))), l.f |= Oe)), w > A.size && Wr("", "", ""), P && w > 0 && U(vo()), !v) if (f.set(O, A), J) {
|
|
1742
|
+
for (const [mt, He] of a) A.has(mt) || O.skip_effect(He.e);
|
|
1743
|
+
O.oncommit(m), O.ondiscard(k);
|
|
1744
|
+
} else m(O);
|
|
1745
|
+
R && Lt(!0), g(d);
|
|
1690
1746
|
}),
|
|
1691
1747
|
flags: e,
|
|
1692
|
-
items:
|
|
1693
|
-
pending:
|
|
1748
|
+
items: a,
|
|
1749
|
+
pending: f,
|
|
1694
1750
|
outrogroups: null,
|
|
1695
|
-
fallback:
|
|
1751
|
+
fallback: l
|
|
1696
1752
|
};
|
|
1697
|
-
v = !1,
|
|
1753
|
+
v = !1, P && (s = L);
|
|
1698
1754
|
}
|
|
1699
|
-
function
|
|
1755
|
+
function Me(t) {
|
|
1700
1756
|
for (; t !== null && !(t.f & 32); ) t = t.next;
|
|
1701
1757
|
return t;
|
|
1702
1758
|
}
|
|
1703
|
-
function
|
|
1704
|
-
var r = (n & 8) !== 0, s = e.length,
|
|
1705
|
-
if (r) for (w = 0; w < s; w += 1) m = e[w],
|
|
1759
|
+
function Hs(t, e, o, n, i) {
|
|
1760
|
+
var r = (n & 8) !== 0, s = e.length, a = t.items, u = Me(t.effect.first), l, d = null, h, f = [], v = [], m, k, p, w;
|
|
1761
|
+
if (r) for (w = 0; w < s; w += 1) m = e[w], k = i(m, w), p = a.get(k).e, p.f & 33554432 || (p.nodes?.a?.measure(), (h ?? (h = /* @__PURE__ */ new Set())).add(p));
|
|
1706
1762
|
for (w = 0; w < s; w += 1) {
|
|
1707
|
-
if (m = e[w],
|
|
1708
|
-
if (p.f & 8192 && (
|
|
1763
|
+
if (m = e[w], k = i(m, w), p = a.get(k).e, t.outrogroups !== null) for (const mt of t.outrogroups) mt.pending.delete(p), mt.done.delete(p);
|
|
1764
|
+
if (p.f & 8192 && (Tn(p), r && (p.nodes?.a?.unfix(), (h ?? (h = /* @__PURE__ */ new Set())).delete(p))), p.f & 33554432) if (p.f ^= Oe, p === u) Pe(p, null, o);
|
|
1709
1765
|
else {
|
|
1710
|
-
var R = d ? d.next :
|
|
1711
|
-
p === t.effect.last && (t.effect.last = p.prev), p.prev && (p.prev.next = p.next), p.next && (p.next.prev = p.prev),
|
|
1766
|
+
var R = d ? d.next : u;
|
|
1767
|
+
p === t.effect.last && (t.effect.last = p.prev), p.prev && (p.prev.next = p.next), p.next && (p.next.prev = p.prev), Nt(t, d, p), Nt(t, p, R), Pe(p, R, o), d = p, f = [], v = [], u = Me(d.next);
|
|
1712
1768
|
continue;
|
|
1713
1769
|
}
|
|
1714
|
-
if (p !==
|
|
1715
|
-
if (
|
|
1716
|
-
if (
|
|
1717
|
-
var
|
|
1718
|
-
d =
|
|
1719
|
-
var
|
|
1720
|
-
for (
|
|
1721
|
-
for (
|
|
1722
|
-
|
|
1723
|
-
} else
|
|
1770
|
+
if (p !== u) {
|
|
1771
|
+
if (l !== void 0 && l.has(p)) {
|
|
1772
|
+
if (f.length < v.length) {
|
|
1773
|
+
var A = v[0], O;
|
|
1774
|
+
d = A.prev;
|
|
1775
|
+
var J = f[0], H = f[f.length - 1];
|
|
1776
|
+
for (O = 0; O < f.length; O += 1) Pe(f[O], A, o);
|
|
1777
|
+
for (O = 0; O < v.length; O += 1) l.delete(v[O]);
|
|
1778
|
+
Nt(t, J.prev, H.next), Nt(t, d, J), Nt(t, H, A), u = A, d = H, w -= 1, f = [], v = [];
|
|
1779
|
+
} else l.delete(p), Pe(p, u, o), Nt(t, p.prev, p.next), Nt(t, p, d === null ? t.effect.first : d.next), Nt(t, d, p), d = p;
|
|
1724
1780
|
continue;
|
|
1725
1781
|
}
|
|
1726
|
-
for (
|
|
1727
|
-
if (
|
|
1782
|
+
for (f = [], v = []; u !== null && u !== p; ) (l ?? (l = /* @__PURE__ */ new Set())).add(u), v.push(u), u = Me(u.next);
|
|
1783
|
+
if (u === null) continue;
|
|
1728
1784
|
}
|
|
1729
|
-
p.f & 33554432 ||
|
|
1785
|
+
p.f & 33554432 || f.push(p), d = p, u = Me(p.next);
|
|
1730
1786
|
}
|
|
1731
1787
|
if (t.outrogroups !== null) {
|
|
1732
|
-
for (const
|
|
1788
|
+
for (const mt of t.outrogroups) mt.pending.size === 0 && (en(t, To(mt.done)), t.outrogroups?.delete(mt));
|
|
1733
1789
|
t.outrogroups.size === 0 && (t.outrogroups = null);
|
|
1734
1790
|
}
|
|
1735
|
-
if (
|
|
1736
|
-
var
|
|
1737
|
-
if (
|
|
1738
|
-
for (;
|
|
1739
|
-
var
|
|
1740
|
-
if (
|
|
1791
|
+
if (u !== null || l !== void 0) {
|
|
1792
|
+
var B = [];
|
|
1793
|
+
if (l !== void 0) for (p of l) p.f & 8192 || B.push(p);
|
|
1794
|
+
for (; u !== null; ) !(u.f & 8192) && u !== t.fallback && B.push(u), u = Me(u.next);
|
|
1795
|
+
var gt = B.length;
|
|
1796
|
+
if (gt > 0) {
|
|
1741
1797
|
var K = n & 4 && s === 0 ? o : null;
|
|
1742
1798
|
if (r) {
|
|
1743
|
-
for (w = 0; w <
|
|
1744
|
-
for (w = 0; w <
|
|
1799
|
+
for (w = 0; w < gt; w += 1) B[w].nodes?.a?.measure();
|
|
1800
|
+
for (w = 0; w < gt; w += 1) B[w].nodes?.a?.fix();
|
|
1745
1801
|
}
|
|
1746
|
-
|
|
1802
|
+
qs(t, B, K);
|
|
1747
1803
|
}
|
|
1748
1804
|
}
|
|
1749
|
-
r &&
|
|
1750
|
-
if (
|
|
1805
|
+
r && se(() => {
|
|
1806
|
+
if (h !== void 0) for (p of h) p.nodes?.a?.apply();
|
|
1751
1807
|
});
|
|
1752
1808
|
}
|
|
1753
|
-
function
|
|
1754
|
-
var
|
|
1809
|
+
function Bs(t, e, o, n, i, r, s, a) {
|
|
1810
|
+
var u = s & 1 ? s & 16 ? ae(o) : /* @__PURE__ */ Ri(o, !1, !1) : null, l = s & 2 ? ae(i) : null;
|
|
1755
1811
|
return {
|
|
1756
|
-
v:
|
|
1757
|
-
i:
|
|
1758
|
-
e:
|
|
1812
|
+
v: u,
|
|
1813
|
+
i: l,
|
|
1814
|
+
e: it(() => (r(e, u ?? o, l ?? i, a), () => {
|
|
1759
1815
|
t.delete(n);
|
|
1760
1816
|
}))
|
|
1761
1817
|
};
|
|
1762
1818
|
}
|
|
1763
|
-
function
|
|
1819
|
+
function Pe(t, e, o) {
|
|
1764
1820
|
if (t.nodes) for (var n = t.nodes.start, i = t.nodes.end, r = e && !(e.f & 33554432) ? e.nodes.start : o; n !== null; ) {
|
|
1765
|
-
var s = /* @__PURE__ */
|
|
1821
|
+
var s = /* @__PURE__ */ St(n);
|
|
1766
1822
|
if (r.before(n), n === i) return;
|
|
1767
1823
|
n = s;
|
|
1768
1824
|
}
|
|
1769
1825
|
}
|
|
1770
|
-
function
|
|
1826
|
+
function Nt(t, e, o) {
|
|
1771
1827
|
e === null ? t.effect.first = o : e.next = o, o === null ? t.effect.last = e : o.prev = e;
|
|
1772
1828
|
}
|
|
1773
|
-
function
|
|
1774
|
-
|
|
1829
|
+
function Fs(t, e) {
|
|
1830
|
+
Bi(() => {
|
|
1775
1831
|
var o = t.getRootNode(), n = o.host ? o : o.head ?? o.ownerDocument.head;
|
|
1776
1832
|
if (!n.querySelector("#" + e.hash)) {
|
|
1777
|
-
const i =
|
|
1833
|
+
const i = vn("style");
|
|
1778
1834
|
i.id = e.hash, i.textContent = e.code, n.appendChild(i);
|
|
1779
1835
|
}
|
|
1780
1836
|
});
|
|
1781
1837
|
}
|
|
1782
|
-
function
|
|
1838
|
+
function Jn(t, e = !1) {
|
|
1783
1839
|
var o = e ? " !important;" : ";", n = "";
|
|
1784
1840
|
for (var i of Object.keys(t)) {
|
|
1785
1841
|
var r = t[i];
|
|
@@ -1787,164 +1843,164 @@ function Wn(t, e = !1) {
|
|
|
1787
1843
|
}
|
|
1788
1844
|
return n;
|
|
1789
1845
|
}
|
|
1790
|
-
function
|
|
1846
|
+
function Oo(t) {
|
|
1791
1847
|
return t[0] !== "-" || t[1] !== "-" ? t.toLowerCase() : t;
|
|
1792
1848
|
}
|
|
1793
|
-
function
|
|
1849
|
+
function Gs(t, e) {
|
|
1794
1850
|
if (e) {
|
|
1795
1851
|
var o = "", n, i;
|
|
1796
1852
|
if (Array.isArray(e) ? (n = e[0], i = e[1]) : n = e, t) {
|
|
1797
1853
|
t = String(t).replaceAll(/\s*\/\*.*?\*\/\s*/g, "").trim();
|
|
1798
|
-
var r = !1, s = 0,
|
|
1799
|
-
n &&
|
|
1800
|
-
var
|
|
1801
|
-
const
|
|
1802
|
-
for (var
|
|
1803
|
-
var
|
|
1804
|
-
if (
|
|
1805
|
-
if (
|
|
1806
|
-
else if (
|
|
1854
|
+
var r = !1, s = 0, a = !1, u = [];
|
|
1855
|
+
n && u.push(...Object.keys(n).map(Oo)), i && u.push(...Object.keys(i).map(Oo));
|
|
1856
|
+
var l = 0, d = -1;
|
|
1857
|
+
const k = t.length;
|
|
1858
|
+
for (var h = 0; h < k; h++) {
|
|
1859
|
+
var f = t[h];
|
|
1860
|
+
if (a ? f === "/" && t[h - 1] === "*" && (a = !1) : r ? r === f && (r = !1) : f === "/" && t[h + 1] === "*" ? a = !0 : f === '"' || f === "'" ? r = f : f === "(" ? s++ : f === ")" && s--, !a && r === !1 && s === 0) {
|
|
1861
|
+
if (f === ":" && d === -1) d = h;
|
|
1862
|
+
else if (f === ";" || h === k - 1) {
|
|
1807
1863
|
if (d !== -1) {
|
|
1808
|
-
var v =
|
|
1809
|
-
if (!
|
|
1810
|
-
|
|
1811
|
-
var m = t.substring(
|
|
1864
|
+
var v = Oo(t.substring(l, d).trim());
|
|
1865
|
+
if (!u.includes(v)) {
|
|
1866
|
+
f !== ";" && h++;
|
|
1867
|
+
var m = t.substring(l, h).trim();
|
|
1812
1868
|
o += " " + m + ";";
|
|
1813
1869
|
}
|
|
1814
1870
|
}
|
|
1815
|
-
|
|
1871
|
+
l = h + 1, d = -1;
|
|
1816
1872
|
}
|
|
1817
1873
|
}
|
|
1818
1874
|
}
|
|
1819
1875
|
}
|
|
1820
|
-
return n && (o +=
|
|
1876
|
+
return n && (o += Jn(n)), i && (o += Jn(i, !0)), o = o.trim(), o === "" ? null : o;
|
|
1821
1877
|
}
|
|
1822
1878
|
return t == null ? null : String(t);
|
|
1823
1879
|
}
|
|
1824
|
-
function
|
|
1880
|
+
function Ro(t, e = {}, o, n) {
|
|
1825
1881
|
for (var i in o) {
|
|
1826
1882
|
var r = o[i];
|
|
1827
1883
|
e[i] !== r && (o[i] == null ? t.style.removeProperty(i) : t.style.setProperty(i, r, n));
|
|
1828
1884
|
}
|
|
1829
1885
|
}
|
|
1830
|
-
function
|
|
1886
|
+
function Kn(t, e, o, n) {
|
|
1831
1887
|
var i = t.__style;
|
|
1832
|
-
if (
|
|
1833
|
-
var r =
|
|
1834
|
-
(!
|
|
1835
|
-
} else n && (Array.isArray(n) ? (
|
|
1888
|
+
if (P || i !== e) {
|
|
1889
|
+
var r = Gs(e, n);
|
|
1890
|
+
(!P || r !== t.getAttribute("style")) && (r == null ? t.removeAttribute("style") : t.style.cssText = r), t.__style = e;
|
|
1891
|
+
} else n && (Array.isArray(n) ? (Ro(t, o?.[0], n[0]), Ro(t, o?.[1], n[1], "important")) : Ro(t, o, n));
|
|
1836
1892
|
return n;
|
|
1837
1893
|
}
|
|
1838
|
-
var
|
|
1839
|
-
function
|
|
1840
|
-
var i =
|
|
1841
|
-
|
|
1894
|
+
var Us = Symbol("is custom element"), Js = Symbol("is html"), Ks = jr ? "link" : "LINK";
|
|
1895
|
+
function Zn(t, e, o, n) {
|
|
1896
|
+
var i = Zs(t);
|
|
1897
|
+
P && (i[e] = t.getAttribute(e), e === "src" || e === "srcset" || e === "href" && t.nodeName === Ks) || i[e] !== (i[e] = o) && (e === "loading" && (t[Rr] = o), o == null ? t.removeAttribute(e) : typeof o != "string" && Ys(t).includes(e) ? t[e] = o : t.setAttribute(e, o));
|
|
1842
1898
|
}
|
|
1843
|
-
function
|
|
1899
|
+
function Zs(t) {
|
|
1844
1900
|
return t.__attributes ?? (t.__attributes = {
|
|
1845
|
-
[
|
|
1846
|
-
[
|
|
1901
|
+
[Us]: t.nodeName.includes("-"),
|
|
1902
|
+
[Js]: t.namespaceURI === "http://www.w3.org/1999/xhtml"
|
|
1847
1903
|
});
|
|
1848
1904
|
}
|
|
1849
|
-
var
|
|
1850
|
-
function
|
|
1851
|
-
var e = t.getAttribute("is") || t.nodeName, o =
|
|
1905
|
+
var Yn = /* @__PURE__ */ new Map();
|
|
1906
|
+
function Ys(t) {
|
|
1907
|
+
var e = t.getAttribute("is") || t.nodeName, o = Yn.get(e);
|
|
1852
1908
|
if (o) return o;
|
|
1853
|
-
|
|
1909
|
+
Yn.set(e, o = []);
|
|
1854
1910
|
for (var n, i = t, r = Element.prototype; r !== i; ) {
|
|
1855
|
-
n =
|
|
1911
|
+
n = xr(i);
|
|
1856
1912
|
for (var s in n) n[s].set && o.push(s);
|
|
1857
|
-
i =
|
|
1913
|
+
i = ci(i);
|
|
1858
1914
|
}
|
|
1859
1915
|
return o;
|
|
1860
1916
|
}
|
|
1861
|
-
var
|
|
1917
|
+
var rr, pe = /* @__PURE__ */ new WeakMap(), yo = /* @__PURE__ */ new WeakMap(), jo = /* @__PURE__ */ new WeakMap(), Xn = /* @__PURE__ */ new WeakSet(), sr = class {
|
|
1862
1918
|
constructor(t) {
|
|
1863
|
-
|
|
1919
|
+
ln(this, Xn), I(this, pe, /* @__PURE__ */ new WeakMap()), I(this, yo, void 0), I(this, jo, void 0), $(jo, this, t);
|
|
1864
1920
|
}
|
|
1865
1921
|
observe(t, e) {
|
|
1866
|
-
var o =
|
|
1867
|
-
return o.add(e),
|
|
1868
|
-
var n =
|
|
1869
|
-
n.delete(e), n.size === 0 && (
|
|
1922
|
+
var o = c(pe, this).get(t) || /* @__PURE__ */ new Set();
|
|
1923
|
+
return o.add(e), c(pe, this).set(t, o), E(Xn, this, Xs).call(this).observe(t, c(jo, this)), () => {
|
|
1924
|
+
var n = c(pe, this).get(t);
|
|
1925
|
+
n.delete(e), n.size === 0 && (c(pe, this).delete(t), c(yo, this).unobserve(t));
|
|
1870
1926
|
};
|
|
1871
1927
|
}
|
|
1872
1928
|
};
|
|
1873
|
-
|
|
1874
|
-
function
|
|
1875
|
-
return
|
|
1929
|
+
rr = sr;
|
|
1930
|
+
function Xs() {
|
|
1931
|
+
return c(yo, this) ?? $(yo, this, new ResizeObserver((t) => {
|
|
1876
1932
|
for (var e of t) {
|
|
1877
|
-
|
|
1878
|
-
for (var o of
|
|
1933
|
+
rr.entries.set(e.target, e);
|
|
1934
|
+
for (var o of c(pe, this).get(e.target) || []) o(e);
|
|
1879
1935
|
}
|
|
1880
1936
|
}));
|
|
1881
1937
|
}
|
|
1882
|
-
y(
|
|
1883
|
-
function
|
|
1884
|
-
return t === e || t?.[
|
|
1885
|
-
}
|
|
1886
|
-
function
|
|
1887
|
-
var i =
|
|
1888
|
-
return
|
|
1889
|
-
var s,
|
|
1890
|
-
return
|
|
1891
|
-
s =
|
|
1892
|
-
t !== o(...
|
|
1938
|
+
y(sr, "entries", /* @__PURE__ */ new WeakMap());
|
|
1939
|
+
function Qn(t, e) {
|
|
1940
|
+
return t === e || t?.[Re] === e;
|
|
1941
|
+
}
|
|
1942
|
+
function ti(t = {}, e, o, n) {
|
|
1943
|
+
var i = V.r, r = S;
|
|
1944
|
+
return Bi(() => {
|
|
1945
|
+
var s, a;
|
|
1946
|
+
return bn(() => {
|
|
1947
|
+
s = a, a = n?.() || [], kn(() => {
|
|
1948
|
+
t !== o(...a) && (e(t, ...a), s && Qn(o(...s), t) && e(null, ...s));
|
|
1893
1949
|
});
|
|
1894
1950
|
}), () => {
|
|
1895
|
-
let
|
|
1896
|
-
for (;
|
|
1897
|
-
const
|
|
1898
|
-
|
|
1899
|
-
}, d =
|
|
1900
|
-
|
|
1901
|
-
|
|
1951
|
+
let u = r;
|
|
1952
|
+
for (; u !== i && u.parent !== null && u.parent.f & 33554432; ) u = u.parent;
|
|
1953
|
+
const l = () => {
|
|
1954
|
+
a && Qn(o(...a), t) && e(null, ...a);
|
|
1955
|
+
}, d = u.teardown;
|
|
1956
|
+
u.teardown = () => {
|
|
1957
|
+
l(), d?.();
|
|
1902
1958
|
};
|
|
1903
1959
|
};
|
|
1904
1960
|
}), t;
|
|
1905
1961
|
}
|
|
1906
|
-
function
|
|
1907
|
-
var i =
|
|
1962
|
+
function No(t, e, o, n) {
|
|
1963
|
+
var i = !$o || (o & 2) !== 0, r = (o & 8) !== 0, s = (o & 16) !== 0, a = n, u = !0, l = () => (u && (u = !1, a = s ? kn(n) : n), a);
|
|
1908
1964
|
let d;
|
|
1909
1965
|
if (r) {
|
|
1910
|
-
var
|
|
1911
|
-
d =
|
|
1966
|
+
var h = Re in t || di in t;
|
|
1967
|
+
d = Qt(t, e)?.set ?? (h && e in t ? (A) => t[e] = A : void 0);
|
|
1912
1968
|
}
|
|
1913
|
-
var
|
|
1914
|
-
r ? [
|
|
1969
|
+
var f, v = !1;
|
|
1970
|
+
r ? [f, v] = os(() => t[e]) : f = t[e], f === void 0 && n !== void 0 && (f = l(), d && (i && Br(e), d(f)));
|
|
1915
1971
|
var m;
|
|
1916
1972
|
if (i ? m = () => {
|
|
1917
|
-
var
|
|
1918
|
-
return
|
|
1973
|
+
var A = t[e];
|
|
1974
|
+
return A === void 0 ? l() : (u = !0, A);
|
|
1919
1975
|
} : m = () => {
|
|
1920
|
-
var
|
|
1921
|
-
return
|
|
1976
|
+
var A = t[e];
|
|
1977
|
+
return A !== void 0 && (a = void 0), A === void 0 ? a : A;
|
|
1922
1978
|
}, i && !(o & 4)) return m;
|
|
1923
1979
|
if (d) {
|
|
1924
|
-
var
|
|
1925
|
-
return function(
|
|
1926
|
-
return arguments.length > 0 ? ((!i || !
|
|
1980
|
+
var k = t.$$legacy;
|
|
1981
|
+
return function(A, O) {
|
|
1982
|
+
return arguments.length > 0 ? ((!i || !O || k || v) && d(O ? m() : A), A) : m();
|
|
1927
1983
|
};
|
|
1928
1984
|
}
|
|
1929
|
-
var p = !1, w = (o & 1 ?
|
|
1985
|
+
var p = !1, w = (o & 1 ? So : fn)(() => (p = !1, m()));
|
|
1930
1986
|
r && g(w);
|
|
1931
|
-
var R =
|
|
1932
|
-
return function(
|
|
1987
|
+
var R = S;
|
|
1988
|
+
return function(A, O) {
|
|
1933
1989
|
if (arguments.length > 0) {
|
|
1934
|
-
const
|
|
1935
|
-
return
|
|
1990
|
+
const J = O ? g(w) : i && r ? Yt(A) : A;
|
|
1991
|
+
return C(w, J), p = !0, a !== void 0 && (a = J), A;
|
|
1936
1992
|
}
|
|
1937
|
-
return
|
|
1993
|
+
return Ot && p || R.f & 16384 ? w.v : g(w);
|
|
1938
1994
|
};
|
|
1939
1995
|
}
|
|
1940
|
-
function
|
|
1941
|
-
return new
|
|
1996
|
+
function Qs(t) {
|
|
1997
|
+
return new ta(t);
|
|
1942
1998
|
}
|
|
1943
|
-
var
|
|
1999
|
+
var Jt = /* @__PURE__ */ new WeakMap(), bt = /* @__PURE__ */ new WeakMap(), ta = class {
|
|
1944
2000
|
constructor(t) {
|
|
1945
|
-
|
|
2001
|
+
I(this, Jt, void 0), I(this, bt, void 0);
|
|
1946
2002
|
var e = /* @__PURE__ */ new Map(), o = (i, r) => {
|
|
1947
|
-
var s = /* @__PURE__ */
|
|
2003
|
+
var s = /* @__PURE__ */ Ri(r, !1, !1);
|
|
1948
2004
|
return e.set(i, s), s;
|
|
1949
2005
|
};
|
|
1950
2006
|
const n = new Proxy({
|
|
@@ -1955,13 +2011,13 @@ var Ft = /* @__PURE__ */ new WeakMap(), vt = /* @__PURE__ */ new WeakMap(), qs =
|
|
|
1955
2011
|
return g(e.get(r) ?? o(r, Reflect.get(i, r)));
|
|
1956
2012
|
},
|
|
1957
2013
|
has(i, r) {
|
|
1958
|
-
return r ===
|
|
2014
|
+
return r === di ? !0 : (g(e.get(r) ?? o(r, Reflect.get(i, r))), Reflect.has(i, r));
|
|
1959
2015
|
},
|
|
1960
2016
|
set(i, r, s) {
|
|
1961
|
-
return
|
|
2017
|
+
return C(e.get(r) ?? o(r, s), s), Reflect.set(i, r, s);
|
|
1962
2018
|
}
|
|
1963
2019
|
});
|
|
1964
|
-
|
|
2020
|
+
$(bt, this, (t.hydrate ? Ns : nr)(t.component, {
|
|
1965
2021
|
target: t.target,
|
|
1966
2022
|
anchor: t.anchor,
|
|
1967
2023
|
props: n,
|
|
@@ -1969,37 +2025,37 @@ var Ft = /* @__PURE__ */ new WeakMap(), vt = /* @__PURE__ */ new WeakMap(), qs =
|
|
|
1969
2025
|
intro: t.intro ?? !1,
|
|
1970
2026
|
recover: t.recover,
|
|
1971
2027
|
transformError: t.transformError
|
|
1972
|
-
})), !
|
|
1973
|
-
for (const i of Object.keys(
|
|
2028
|
+
})), !Pt && (!t?.props?.$$host || t.sync === !1) && io(), $(Jt, this, n.$$events);
|
|
2029
|
+
for (const i of Object.keys(c(bt, this))) i === "$set" || i === "$destroy" || i === "$on" || fo(this, i, {
|
|
1974
2030
|
get() {
|
|
1975
|
-
return
|
|
2031
|
+
return c(bt, this)[i];
|
|
1976
2032
|
},
|
|
1977
2033
|
set(r) {
|
|
1978
|
-
|
|
2034
|
+
c(bt, this)[i] = r;
|
|
1979
2035
|
},
|
|
1980
2036
|
enumerable: !0
|
|
1981
2037
|
});
|
|
1982
|
-
|
|
2038
|
+
c(bt, this).$set = (i) => {
|
|
1983
2039
|
Object.assign(n, i);
|
|
1984
|
-
},
|
|
1985
|
-
|
|
2040
|
+
}, c(bt, this).$destroy = () => {
|
|
2041
|
+
Ws(c(bt, this));
|
|
1986
2042
|
};
|
|
1987
2043
|
}
|
|
1988
2044
|
$set(t) {
|
|
1989
|
-
|
|
2045
|
+
c(bt, this).$set(t);
|
|
1990
2046
|
}
|
|
1991
2047
|
$on(t, e) {
|
|
1992
|
-
|
|
2048
|
+
c(Jt, this)[t] = c(Jt, this)[t] || [];
|
|
1993
2049
|
const o = (...n) => e.call(this, ...n);
|
|
1994
|
-
return
|
|
1995
|
-
|
|
2050
|
+
return c(Jt, this)[t].push(o), () => {
|
|
2051
|
+
c(Jt, this)[t] = c(Jt, this)[t].filter((n) => n !== o);
|
|
1996
2052
|
};
|
|
1997
2053
|
}
|
|
1998
2054
|
$destroy() {
|
|
1999
|
-
|
|
2055
|
+
c(bt, this).$destroy();
|
|
2000
2056
|
}
|
|
2001
|
-
},
|
|
2002
|
-
typeof HTMLElement == "function" && (
|
|
2057
|
+
}, ar;
|
|
2058
|
+
typeof HTMLElement == "function" && (ar = class extends HTMLElement {
|
|
2003
2059
|
constructor(t, e, o) {
|
|
2004
2060
|
super(), y(this, "$$ctor", void 0), y(this, "$$s", void 0), y(this, "$$c", void 0), y(this, "$$cn", !1), y(this, "$$d", {}), y(this, "$$r", !1), y(this, "$$p_d", {}), y(this, "$$l", {}), y(this, "$$l_u", /* @__PURE__ */ new Map()), y(this, "$$me", void 0), y(this, "$$shadowRoot", null), this.$$ctor = t, this.$$s = e, o && (this.$$shadowRoot = this.attachShadow(o));
|
|
2005
2061
|
}
|
|
@@ -2020,19 +2076,19 @@ typeof HTMLElement == "function" && (Yi = class extends HTMLElement {
|
|
|
2020
2076
|
if (this.$$cn = !0, !this.$$c) {
|
|
2021
2077
|
let t = function(n) {
|
|
2022
2078
|
return (i) => {
|
|
2023
|
-
const r =
|
|
2024
|
-
n !== "default" && (r.name = n),
|
|
2079
|
+
const r = vn("slot");
|
|
2080
|
+
n !== "default" && (r.name = n), zt(i, r);
|
|
2025
2081
|
};
|
|
2026
2082
|
};
|
|
2027
2083
|
if (await Promise.resolve(), !this.$$cn || this.$$c) return;
|
|
2028
|
-
const e = {}, o =
|
|
2084
|
+
const e = {}, o = ea(this);
|
|
2029
2085
|
for (const n of this.$$s) n in o && (n === "default" && !this.$$d.children ? (this.$$d.children = t(n), e.default = !0) : e[n] = t(n));
|
|
2030
2086
|
for (const n of this.attributes) {
|
|
2031
2087
|
const i = this.$$g_p(n.name);
|
|
2032
|
-
i in this.$$d || (this.$$d[i] =
|
|
2088
|
+
i in this.$$d || (this.$$d[i] = ao(i, n.value, this.$$p_d, "toProp"));
|
|
2033
2089
|
}
|
|
2034
2090
|
for (const n in this.$$p_d) !(n in this.$$d) && this[n] !== void 0 && (this.$$d[n] = this[n], delete this[n]);
|
|
2035
|
-
this.$$c =
|
|
2091
|
+
this.$$c = Qs({
|
|
2036
2092
|
component: this.$$ctor,
|
|
2037
2093
|
target: this.$$shadowRoot || this,
|
|
2038
2094
|
props: {
|
|
@@ -2040,13 +2096,13 @@ typeof HTMLElement == "function" && (Yi = class extends HTMLElement {
|
|
|
2040
2096
|
$$slots: e,
|
|
2041
2097
|
$$host: this
|
|
2042
2098
|
}
|
|
2043
|
-
}), this.$$me =
|
|
2044
|
-
|
|
2099
|
+
}), this.$$me = ks(() => {
|
|
2100
|
+
bn(() => {
|
|
2045
2101
|
this.$$r = !0;
|
|
2046
|
-
for (const n of
|
|
2102
|
+
for (const n of ho(this.$$c)) {
|
|
2047
2103
|
if (!this.$$p_d[n]?.reflect) continue;
|
|
2048
2104
|
this.$$d[n] = this.$$c[n];
|
|
2049
|
-
const i =
|
|
2105
|
+
const i = ao(n, this.$$d[n], this.$$p_d, "toAttribute");
|
|
2050
2106
|
i == null ? this.removeAttribute(this.$$p_d[n].attribute || n) : this.setAttribute(this.$$p_d[n].attribute || n, i);
|
|
2051
2107
|
}
|
|
2052
2108
|
this.$$r = !1;
|
|
@@ -2060,7 +2116,7 @@ typeof HTMLElement == "function" && (Yi = class extends HTMLElement {
|
|
|
2060
2116
|
}
|
|
2061
2117
|
}
|
|
2062
2118
|
attributeChangedCallback(t, e, o) {
|
|
2063
|
-
this.$$r || (t = this.$$g_p(t), this.$$d[t] =
|
|
2119
|
+
this.$$r || (t = this.$$g_p(t), this.$$d[t] = ao(t, o, this.$$p_d, "toProp"), this.$$c?.$set({ [t]: this.$$d[t] }));
|
|
2064
2120
|
}
|
|
2065
2121
|
disconnectedCallback() {
|
|
2066
2122
|
this.$$cn = !1, Promise.resolve().then(() => {
|
|
@@ -2068,10 +2124,10 @@ typeof HTMLElement == "function" && (Yi = class extends HTMLElement {
|
|
|
2068
2124
|
});
|
|
2069
2125
|
}
|
|
2070
2126
|
$$g_p(t) {
|
|
2071
|
-
return
|
|
2127
|
+
return ho(this.$$p_d).find((e) => this.$$p_d[e].attribute === t || !this.$$p_d[e].attribute && e.toLowerCase() === t) || t;
|
|
2072
2128
|
}
|
|
2073
2129
|
});
|
|
2074
|
-
function
|
|
2130
|
+
function ao(t, e, o, n) {
|
|
2075
2131
|
const i = o[t]?.type;
|
|
2076
2132
|
if (e = i === "Boolean" && typeof e != "boolean" ? e != null : e, !n || !o[t]) return e;
|
|
2077
2133
|
if (n === "toAttribute") switch (i) {
|
|
@@ -2097,46 +2153,46 @@ function eo(t, e, o, n) {
|
|
|
2097
2153
|
return e;
|
|
2098
2154
|
}
|
|
2099
2155
|
}
|
|
2100
|
-
function
|
|
2156
|
+
function ea(t) {
|
|
2101
2157
|
const e = {};
|
|
2102
2158
|
return t.childNodes.forEach((o) => {
|
|
2103
2159
|
e[o.slot || "default"] = !0;
|
|
2104
2160
|
}), e;
|
|
2105
2161
|
}
|
|
2106
|
-
function
|
|
2107
|
-
let s = class extends
|
|
2162
|
+
function oa(t, e, o, n, i, r) {
|
|
2163
|
+
let s = class extends ar {
|
|
2108
2164
|
constructor() {
|
|
2109
2165
|
super(t, o, i), this.$$p_d = e;
|
|
2110
2166
|
}
|
|
2111
2167
|
static get observedAttributes() {
|
|
2112
|
-
return
|
|
2168
|
+
return ho(e).map((a) => (e[a].attribute || a).toLowerCase());
|
|
2113
2169
|
}
|
|
2114
2170
|
};
|
|
2115
|
-
return
|
|
2116
|
-
|
|
2171
|
+
return ho(e).forEach((a) => {
|
|
2172
|
+
fo(s.prototype, a, {
|
|
2117
2173
|
get() {
|
|
2118
|
-
return this.$$c &&
|
|
2174
|
+
return this.$$c && a in this.$$c ? this.$$c[a] : this.$$d[a];
|
|
2119
2175
|
},
|
|
2120
|
-
set(
|
|
2121
|
-
|
|
2122
|
-
var
|
|
2123
|
-
|
|
2176
|
+
set(u) {
|
|
2177
|
+
u = ao(a, u, e), this.$$d[a] = u;
|
|
2178
|
+
var l = this.$$c;
|
|
2179
|
+
l && (Qt(l, a)?.get ? l[a] = u : l.$set({ [a]: u }));
|
|
2124
2180
|
}
|
|
2125
2181
|
});
|
|
2126
|
-
}), n.forEach((
|
|
2127
|
-
|
|
2128
|
-
return this.$$c?.[
|
|
2182
|
+
}), n.forEach((a) => {
|
|
2183
|
+
fo(s.prototype, a, { get() {
|
|
2184
|
+
return this.$$c?.[a];
|
|
2129
2185
|
} });
|
|
2130
2186
|
}), r && (s = r(s)), t.element = s, s;
|
|
2131
2187
|
}
|
|
2132
|
-
var
|
|
2188
|
+
var na = class extends Event {
|
|
2133
2189
|
constructor(t, e, o, n) {
|
|
2134
2190
|
super("context-request", {
|
|
2135
2191
|
bubbles: !0,
|
|
2136
2192
|
composed: !0
|
|
2137
2193
|
}), y(this, "context", void 0), y(this, "contextTarget", void 0), y(this, "callback", void 0), y(this, "subscribe", void 0), this.context = t, this.contextTarget = e, this.callback = o, this.subscribe = n ?? !1;
|
|
2138
2194
|
}
|
|
2139
|
-
},
|
|
2195
|
+
}, ia = class {
|
|
2140
2196
|
constructor(t, e) {
|
|
2141
2197
|
y(this, "host", void 0), y(this, "context", void 0), y(this, "subscribe", void 0), y(this, "onValue", void 0), y(this, "isConnected", !1), y(this, "unsubscribe", void 0), y(this, "currentValue", void 0), y(this, "handleValue", (o, n) => {
|
|
2142
2198
|
n !== this.unsubscribe && (this.unsubscribe?.(), this.unsubscribe = n), !this.subscribe && this.unsubscribe && (this.unsubscribe(), this.unsubscribe = void 0), this.currentValue = o, this.onValue?.(o);
|
|
@@ -2152,71 +2208,143 @@ var Gs = class extends Event {
|
|
|
2152
2208
|
return this.currentValue;
|
|
2153
2209
|
}
|
|
2154
2210
|
requestValue() {
|
|
2155
|
-
this.host.dispatchEvent(new
|
|
2211
|
+
this.host.dispatchEvent(new na(this.context, this.host, this.handleValue, this.subscribe));
|
|
2156
2212
|
}
|
|
2157
|
-
},
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
var
|
|
2161
|
-
function
|
|
2213
|
+
}, Ao = (t) => t;
|
|
2214
|
+
Ao(Symbol.for("pie.assessmentToolkit.runtimeContext"));
|
|
2215
|
+
Ao(Symbol.for("pie.assessmentToolkit.hostRuntimeContext"));
|
|
2216
|
+
var ra = Ao(Symbol.for("pie.assessmentToolkit.shellContext")), sa = Ao(Symbol.for("pie.assessmentToolkit.regionScopeContext"));
|
|
2217
|
+
function lr(t, e, o) {
|
|
2162
2218
|
let n = !1;
|
|
2163
|
-
const i = new
|
|
2219
|
+
const i = new ia(t, {
|
|
2164
2220
|
context: e,
|
|
2165
2221
|
subscribe: !0,
|
|
2166
|
-
onValue: (
|
|
2167
|
-
n = !0, o(
|
|
2222
|
+
onValue: (l) => {
|
|
2223
|
+
n = !0, o(l);
|
|
2168
2224
|
}
|
|
2169
2225
|
});
|
|
2170
2226
|
i.connect();
|
|
2171
|
-
const r = (
|
|
2172
|
-
|
|
2227
|
+
const r = (l) => {
|
|
2228
|
+
l.context === e && i.requestValue();
|
|
2173
2229
|
};
|
|
2174
2230
|
t.addEventListener("context-provider", r);
|
|
2175
2231
|
let s = 0;
|
|
2176
|
-
const
|
|
2177
|
-
if (n || s >=
|
|
2178
|
-
globalThis.clearInterval(
|
|
2232
|
+
const a = 200, u = globalThis.setInterval(() => {
|
|
2233
|
+
if (n || s >= a) {
|
|
2234
|
+
globalThis.clearInterval(u);
|
|
2179
2235
|
return;
|
|
2180
2236
|
}
|
|
2181
2237
|
s += 1, i.requestValue();
|
|
2182
2238
|
}, 50);
|
|
2183
2239
|
return () => {
|
|
2184
|
-
globalThis.clearInterval(
|
|
2240
|
+
globalThis.clearInterval(u), t.removeEventListener("context-provider", r), i.disconnect();
|
|
2185
2241
|
};
|
|
2186
2242
|
}
|
|
2187
|
-
function
|
|
2188
|
-
return
|
|
2243
|
+
function aa(t, e) {
|
|
2244
|
+
return lr(t, ra, e);
|
|
2189
2245
|
}
|
|
2190
|
-
function
|
|
2191
|
-
return
|
|
2246
|
+
function la(t, e) {
|
|
2247
|
+
return lr(t, sa, e);
|
|
2192
2248
|
}
|
|
2193
|
-
var
|
|
2249
|
+
var ei;
|
|
2194
2250
|
(function(t) {
|
|
2195
2251
|
t.TTS_WORD = "tts-word", t.TTS_SENTENCE = "tts-sentence", t.ANNOTATION = "annotation";
|
|
2196
|
-
})(
|
|
2197
|
-
var
|
|
2252
|
+
})(ei || (ei = {}));
|
|
2253
|
+
var Dt;
|
|
2198
2254
|
(function(t) {
|
|
2199
2255
|
t.YELLOW = "yellow", t.GREEN = "green", t.BLUE = "blue", t.PINK = "pink", t.ORANGE = "orange", t.UNDERLINE = "underline";
|
|
2200
|
-
})(
|
|
2201
|
-
function
|
|
2256
|
+
})(Dt || (Dt = {}));
|
|
2257
|
+
function cr(t) {
|
|
2202
2258
|
return (...e) => {
|
|
2203
2259
|
console.debug(`[${t}]`, ...e);
|
|
2204
2260
|
};
|
|
2205
2261
|
}
|
|
2206
|
-
|
|
2207
|
-
var
|
|
2262
|
+
cr("I18nService");
|
|
2263
|
+
var Wo = {
|
|
2208
2264
|
assessment: [],
|
|
2209
2265
|
section: [],
|
|
2210
2266
|
item: [],
|
|
2211
2267
|
passage: [],
|
|
2212
2268
|
rubric: [],
|
|
2213
2269
|
element: []
|
|
2270
|
+
}, Vo = {
|
|
2271
|
+
section: [...Wo.section],
|
|
2272
|
+
item: [...Wo.item],
|
|
2273
|
+
passage: [...Wo.passage]
|
|
2214
2274
|
};
|
|
2215
|
-
|
|
2216
|
-
|
|
2275
|
+
function re(t) {
|
|
2276
|
+
return typeof t == "object" && t !== null && !Array.isArray(t);
|
|
2277
|
+
}
|
|
2278
|
+
function Wt(t, e) {
|
|
2279
|
+
if (t == null) return [];
|
|
2280
|
+
if (!Array.isArray(t)) throw new Error(`Invalid tools config at "${e}": expected an array of tool ids.`);
|
|
2281
|
+
if (t.find((o) => typeof o != "string") !== void 0) throw new Error(`Invalid tools config at "${e}": all entries must be strings.`);
|
|
2282
|
+
return t;
|
|
2283
|
+
}
|
|
2284
|
+
function ca(t) {
|
|
2285
|
+
if (t != null) {
|
|
2286
|
+
if (!re(t)) throw new Error('Invalid tools config at "placement": expected an object with section/item/passage arrays.');
|
|
2287
|
+
return t;
|
|
2288
|
+
}
|
|
2289
|
+
}
|
|
2290
|
+
function ua(t) {
|
|
2291
|
+
if (t != null) {
|
|
2292
|
+
if (!re(t)) throw new Error('Invalid tools config at "policy": expected an object with allowed/blocked arrays.');
|
|
2293
|
+
return t;
|
|
2294
|
+
}
|
|
2295
|
+
}
|
|
2296
|
+
function da(t, e) {
|
|
2297
|
+
if (e == null) return;
|
|
2298
|
+
if (!re(e)) throw new Error(`Invalid tools config at "providers.${t}": expected an object.`);
|
|
2299
|
+
const o = e;
|
|
2300
|
+
if ("enabled" in o && o.enabled !== void 0 && typeof o.enabled != "boolean") throw new Error(`Invalid tools config at "providers.${t}.enabled": expected a boolean.`);
|
|
2301
|
+
if ("settings" in o && o.settings !== void 0 && !re(o.settings)) throw new Error(`Invalid tools config at "providers.${t}.settings": expected an object.`);
|
|
2302
|
+
if ("provider" in o && o.provider !== void 0 && !re(o.provider)) throw new Error(`Invalid tools config at "providers.${t}.provider": expected an object.`);
|
|
2303
|
+
return o;
|
|
2304
|
+
}
|
|
2305
|
+
function ha(t) {
|
|
2306
|
+
if (t == null) return {};
|
|
2307
|
+
if (!re(t)) throw new Error('Invalid tools config at "providers": expected an object keyed by tool id.');
|
|
2308
|
+
const e = {};
|
|
2309
|
+
for (const [o, n] of Object.entries(t)) e[o] = da(o, n);
|
|
2310
|
+
return e;
|
|
2311
|
+
}
|
|
2312
|
+
function ur(t) {
|
|
2217
2313
|
return t.trim() || "";
|
|
2218
2314
|
}
|
|
2219
|
-
|
|
2315
|
+
function Vt(t) {
|
|
2316
|
+
if (!t || t.length === 0) return [];
|
|
2317
|
+
const e = /* @__PURE__ */ new Set();
|
|
2318
|
+
for (const o of t) {
|
|
2319
|
+
if (typeof o != "string") throw new Error("Invalid tools config: tool list entries must be strings.");
|
|
2320
|
+
const n = ur(o);
|
|
2321
|
+
n && e.add(n);
|
|
2322
|
+
}
|
|
2323
|
+
return Array.from(e);
|
|
2324
|
+
}
|
|
2325
|
+
function fa(t) {
|
|
2326
|
+
if (t != null) {
|
|
2327
|
+
if (t === "on" || t === "off") return t;
|
|
2328
|
+
throw new Error(`Invalid tools config at "qtiEnforcement": expected "on" or "off", got ${JSON.stringify(t)}.`);
|
|
2329
|
+
}
|
|
2330
|
+
}
|
|
2331
|
+
function pa(t) {
|
|
2332
|
+
if (t != null && !re(t)) throw new Error('Invalid tools config: expected an object with "policy", "placement", and "providers".');
|
|
2333
|
+
const e = ua(t?.policy), o = ca(t?.placement), n = ha(t?.providers), i = fa(t?.qtiEnforcement), r = {
|
|
2334
|
+
policy: {
|
|
2335
|
+
allowed: Vt(Wt(e?.allowed, "policy.allowed")),
|
|
2336
|
+
blocked: Vt(Wt(e?.blocked, "policy.blocked"))
|
|
2337
|
+
},
|
|
2338
|
+
placement: {
|
|
2339
|
+
section: Vt(Wt(o?.section, "placement.section")).length ? Vt(Wt(o?.section, "placement.section")) : [...Vo.section],
|
|
2340
|
+
item: Vt(Wt(o?.item, "placement.item")).length ? Vt(Wt(o?.item, "placement.item")) : [...Vo.item],
|
|
2341
|
+
passage: Vt(Wt(o?.passage, "placement.passage")).length ? Vt(Wt(o?.passage, "placement.passage")) : [...Vo.passage]
|
|
2342
|
+
},
|
|
2343
|
+
providers: n
|
|
2344
|
+
};
|
|
2345
|
+
return i && (r.qtiEnforcement = i), r;
|
|
2346
|
+
}
|
|
2347
|
+
var va = [
|
|
2220
2348
|
"assessment",
|
|
2221
2349
|
"section",
|
|
2222
2350
|
"item",
|
|
@@ -2224,13 +2352,38 @@ var Qs = [
|
|
|
2224
2352
|
"rubric",
|
|
2225
2353
|
"element"
|
|
2226
2354
|
];
|
|
2227
|
-
function
|
|
2355
|
+
function lo(t, e) {
|
|
2228
2356
|
if (typeof t != "string" || t.trim().length === 0) throw new Error(`Invalid tool registration: "${e}" must be a non-empty string.`);
|
|
2229
2357
|
}
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2358
|
+
var ga = [
|
|
2359
|
+
{
|
|
2360
|
+
pattern: /<script\b/i,
|
|
2361
|
+
reason: "contains a <script> tag"
|
|
2362
|
+
},
|
|
2363
|
+
{
|
|
2364
|
+
pattern: /\son[a-z]+\s*=/i,
|
|
2365
|
+
reason: "contains an inline event handler (on*=) attribute"
|
|
2366
|
+
},
|
|
2367
|
+
{
|
|
2368
|
+
pattern: /javascript:/i,
|
|
2369
|
+
reason: "contains a javascript: URL"
|
|
2370
|
+
},
|
|
2371
|
+
{
|
|
2372
|
+
pattern: /<foreignObject\b/i,
|
|
2373
|
+
reason: "contains a <foreignObject> element"
|
|
2374
|
+
}
|
|
2375
|
+
];
|
|
2376
|
+
function ma(t, e, o) {
|
|
2377
|
+
const n = e.trimStart(), i = n.toLowerCase().startsWith("<svg"), r = /^https?:/i.test(n);
|
|
2378
|
+
if (/^data:/i.test(n)) throw new Error(`Invalid tool registration "${t}": "${o}" may not be a data: URL.`);
|
|
2379
|
+
if (!(!i && !r)) {
|
|
2380
|
+
for (const { pattern: s, reason: a } of ga) if (s.test(e)) throw new Error(`Invalid tool registration "${t}": "${o}" ${a}. Inline SVG icons must not include scriptable content.`);
|
|
2381
|
+
}
|
|
2382
|
+
}
|
|
2383
|
+
function oi(t) {
|
|
2384
|
+
if (lo(t.toolId, "toolId"), lo(t.name, "name"), lo(t.description, "description"), typeof t.icon != "string" && typeof t.icon != "function") throw new Error(`Invalid tool registration "${t.toolId}": "icon" must be a string or function.`);
|
|
2385
|
+
if (typeof t.icon == "string" && ma(t.toolId, t.icon, "icon"), !Array.isArray(t.supportedLevels) || t.supportedLevels.length === 0) throw new Error(`Invalid tool registration "${t.toolId}": "supportedLevels" must be a non-empty array.`);
|
|
2386
|
+
const e = t.supportedLevels.find((o) => !va.includes(o));
|
|
2234
2387
|
if (e) throw new Error(`Invalid tool registration "${t.toolId}": unsupported level "${e}".`);
|
|
2235
2388
|
if (t.activation !== void 0 && t.activation !== "toolbar-toggle" && t.activation !== "selection-gateway") throw new Error(`Invalid tool registration "${t.toolId}": unsupported activation "${String(t.activation)}".`);
|
|
2236
2389
|
if (t.singletonScope !== void 0 && t.singletonScope !== "section") throw new Error(`Invalid tool registration "${t.toolId}": unsupported singletonScope "${String(t.singletonScope)}".`);
|
|
@@ -2239,22 +2392,22 @@ function Gn(t) {
|
|
|
2239
2392
|
if (typeof t.isVisibleInContext != "function") throw new Error(`Invalid tool registration "${t.toolId}": "isVisibleInContext" must be a function.`);
|
|
2240
2393
|
if (typeof t.renderToolbar != "function") throw new Error(`Invalid tool registration "${t.toolId}": "renderToolbar" must be a function.`);
|
|
2241
2394
|
}
|
|
2242
|
-
var
|
|
2395
|
+
var ba = class {
|
|
2243
2396
|
constructor() {
|
|
2244
2397
|
y(this, "tools", /* @__PURE__ */ new Map()), y(this, "pnpIndex", /* @__PURE__ */ new Map()), y(this, "componentOverrides", {}), y(this, "moduleLoaders", /* @__PURE__ */ new Map()), y(this, "loadedToolModules", /* @__PURE__ */ new Set()), y(this, "moduleLoadPromises", /* @__PURE__ */ new Map());
|
|
2245
2398
|
}
|
|
2246
2399
|
normalizeToolId(t) {
|
|
2247
|
-
return
|
|
2400
|
+
return ur(t);
|
|
2248
2401
|
}
|
|
2249
2402
|
normalizeToolIds(t) {
|
|
2250
2403
|
return t.map((e) => this.normalizeToolId(e));
|
|
2251
2404
|
}
|
|
2252
2405
|
register(t) {
|
|
2253
|
-
if (
|
|
2406
|
+
if (oi(t), this.tools.has(t.toolId)) throw new Error(`Tool '${t.toolId}' is already registered`);
|
|
2254
2407
|
if (this.tools.set(t.toolId, t), t.pnpSupportIds) for (const e of t.pnpSupportIds) this.pnpIndex.has(e) || this.pnpIndex.set(e, /* @__PURE__ */ new Set()), this.pnpIndex.get(e).add(t.toolId);
|
|
2255
2408
|
}
|
|
2256
2409
|
override(t) {
|
|
2257
|
-
if (
|
|
2410
|
+
if (oi(t), !this.tools.has(t.toolId)) throw new Error(`Cannot override non-existent tool '${t.toolId}'`);
|
|
2258
2411
|
const e = this.tools.get(t.toolId);
|
|
2259
2412
|
if (e.pnpSupportIds) for (const o of e.pnpSupportIds) this.pnpIndex.get(o)?.delete(t.toolId);
|
|
2260
2413
|
if (this.tools.set(t.toolId, t), t.pnpSupportIds) for (const o of t.pnpSupportIds) this.pnpIndex.has(o) || this.pnpIndex.set(o, /* @__PURE__ */ new Set()), this.pnpIndex.get(o).add(t.toolId);
|
|
@@ -2336,7 +2489,7 @@ var tl = class {
|
|
|
2336
2489
|
}
|
|
2337
2490
|
setToolModuleLoaders(t) {
|
|
2338
2491
|
for (const [e, o] of Object.entries(t)) if (o) {
|
|
2339
|
-
if (
|
|
2492
|
+
if (lo(e, "tool module loader id"), typeof o != "function") throw new Error(`Invalid tool module loader for "${e}": expected a function.`);
|
|
2340
2493
|
this.moduleLoaders.set(e, o);
|
|
2341
2494
|
}
|
|
2342
2495
|
}
|
|
@@ -2378,70 +2531,70 @@ var tl = class {
|
|
|
2378
2531
|
return n.renderToolbar(e, i);
|
|
2379
2532
|
}
|
|
2380
2533
|
};
|
|
2381
|
-
function
|
|
2534
|
+
function dr(t) {
|
|
2382
2535
|
return t.level === "item";
|
|
2383
2536
|
}
|
|
2384
|
-
function
|
|
2537
|
+
function ya(t) {
|
|
2385
2538
|
return t.level === "passage";
|
|
2386
2539
|
}
|
|
2387
|
-
function
|
|
2540
|
+
function wa(t) {
|
|
2388
2541
|
return t.level === "rubric";
|
|
2389
2542
|
}
|
|
2390
|
-
function
|
|
2543
|
+
function hr(t) {
|
|
2391
2544
|
return t.level === "element";
|
|
2392
2545
|
}
|
|
2393
|
-
function
|
|
2394
|
-
if (
|
|
2546
|
+
function $n(t) {
|
|
2547
|
+
if (hr(t)) {
|
|
2395
2548
|
const e = t.item.config;
|
|
2396
2549
|
if (!e) return "";
|
|
2397
|
-
const o = [], n = (
|
|
2550
|
+
const o = [], n = (a) => a.replace(/<[^>]*>/g, " ").trim(), i = e.elements?.[t.elementId];
|
|
2398
2551
|
i && typeof i == "string" && o.push(n(i));
|
|
2399
|
-
const r = e.models, s = (Array.isArray(r) ? r : r && typeof r == "object" ? Object.values(r) : []).find((
|
|
2552
|
+
const r = e.models, s = (Array.isArray(r) ? r : r && typeof r == "object" ? Object.values(r) : []).find((a) => a && typeof a == "object" && a.id === t.elementId);
|
|
2400
2553
|
if (s) {
|
|
2401
|
-
for (const
|
|
2402
|
-
for (const
|
|
2554
|
+
for (const a of Object.values(s)) if (typeof a == "string" && o.push(n(a)), Array.isArray(a)) {
|
|
2555
|
+
for (const u of a) if (u && typeof u == "object") for (const l of Object.values(u)) typeof l == "string" && o.push(n(l));
|
|
2403
2556
|
}
|
|
2404
2557
|
}
|
|
2405
2558
|
return o.filter(Boolean).join(" ").trim();
|
|
2406
2559
|
}
|
|
2407
|
-
if (
|
|
2560
|
+
if (dr(t)) {
|
|
2408
2561
|
const e = t.item;
|
|
2409
2562
|
if (!e?.config) return "";
|
|
2410
|
-
const o = e.config, n = [], i = (
|
|
2563
|
+
const o = e.config, n = [], i = (u) => u.replace(/<[^>]*>/g, " ").trim();
|
|
2411
2564
|
typeof o.markup == "string" && n.push(i(o.markup));
|
|
2412
2565
|
const r = o.elements;
|
|
2413
|
-
if (r && typeof r == "object") for (const
|
|
2414
|
-
const s = o.models,
|
|
2415
|
-
for (const
|
|
2416
|
-
for (const
|
|
2417
|
-
for (const d of
|
|
2566
|
+
if (r && typeof r == "object") for (const u of Object.values(r)) typeof u == "string" && n.push(i(u));
|
|
2567
|
+
const s = o.models, a = Array.isArray(s) ? s : s && typeof s == "object" ? Object.values(s) : [];
|
|
2568
|
+
for (const u of a) if (!(!u || typeof u != "object")) {
|
|
2569
|
+
for (const l of Object.values(u)) if (typeof l == "string" && n.push(i(l)), Array.isArray(l)) {
|
|
2570
|
+
for (const d of l) if (d && typeof d == "object") for (const h of Object.values(d)) typeof h == "string" && n.push(i(h));
|
|
2418
2571
|
}
|
|
2419
2572
|
}
|
|
2420
2573
|
return n.filter(Boolean).join(" ").trim();
|
|
2421
2574
|
}
|
|
2422
|
-
if (
|
|
2575
|
+
if (ya(t)) {
|
|
2423
2576
|
const e = t.passage;
|
|
2424
2577
|
if (!e?.config) return "";
|
|
2425
|
-
const o = e.config, n = [], i = (
|
|
2578
|
+
const o = e.config, n = [], i = (u) => u.replace(/<[^>]*>/g, " ").trim();
|
|
2426
2579
|
typeof o.markup == "string" && n.push(i(o.markup)), typeof o.content == "string" && n.push(i(o.content)), typeof o.prompt == "string" && n.push(i(o.prompt));
|
|
2427
2580
|
const r = o.elements;
|
|
2428
|
-
if (r && typeof r == "object") for (const
|
|
2429
|
-
const s = o.models,
|
|
2430
|
-
for (const
|
|
2431
|
-
for (const
|
|
2432
|
-
for (const d of
|
|
2581
|
+
if (r && typeof r == "object") for (const u of Object.values(r)) typeof u == "string" && n.push(i(u));
|
|
2582
|
+
const s = o.models, a = Array.isArray(s) ? s : s && typeof s == "object" ? Object.values(s) : [];
|
|
2583
|
+
for (const u of a) if (!(!u || typeof u != "object")) {
|
|
2584
|
+
for (const l of Object.values(u)) if (typeof l == "string" && n.push(i(l)), Array.isArray(l)) {
|
|
2585
|
+
for (const d of l) if (d && typeof d == "object") for (const h of Object.values(d)) typeof h == "string" && n.push(i(h));
|
|
2433
2586
|
}
|
|
2434
2587
|
}
|
|
2435
2588
|
return n.filter(Boolean).join(" ").trim();
|
|
2436
2589
|
}
|
|
2437
|
-
if (
|
|
2590
|
+
if (wa(t)) {
|
|
2438
2591
|
const e = t.rubricBlock;
|
|
2439
2592
|
return e.passage?.config ? (e.passage.config.markup || "").replace(/<[^>]*>/g, " ").trim() : (e.content || "").replace(/<[^>]*>/g, " ").trim();
|
|
2440
2593
|
}
|
|
2441
2594
|
return "";
|
|
2442
2595
|
}
|
|
2443
|
-
function
|
|
2444
|
-
const e =
|
|
2596
|
+
function co(t) {
|
|
2597
|
+
const e = $n(t);
|
|
2445
2598
|
return [
|
|
2446
2599
|
/<math[>\s]/i,
|
|
2447
2600
|
/\\\[([^\]]+)\\\]/,
|
|
@@ -2451,7 +2604,7 @@ function no(t) {
|
|
|
2451
2604
|
/\d+\s*[+\-*/=]\s*\d+/
|
|
2452
2605
|
].some((o) => o.test(e));
|
|
2453
2606
|
}
|
|
2454
|
-
function
|
|
2607
|
+
function Ta(t) {
|
|
2455
2608
|
const e = [
|
|
2456
2609
|
"pie-multiple-choice",
|
|
2457
2610
|
"pie-inline-choice",
|
|
@@ -2460,7 +2613,7 @@ function nl(t) {
|
|
|
2460
2613
|
"inline-choice",
|
|
2461
2614
|
"select-text"
|
|
2462
2615
|
];
|
|
2463
|
-
if (
|
|
2616
|
+
if (hr(t)) {
|
|
2464
2617
|
const o = t.item.config;
|
|
2465
2618
|
if (!o?.models) return !1;
|
|
2466
2619
|
const n = (Array.isArray(o.models) ? o.models : Object.values(o.models)).find((r) => r && typeof r == "object" && r.id === t.elementId);
|
|
@@ -2468,7 +2621,7 @@ function nl(t) {
|
|
|
2468
2621
|
const i = n.element || "";
|
|
2469
2622
|
return e.includes(i);
|
|
2470
2623
|
}
|
|
2471
|
-
if (
|
|
2624
|
+
if (dr(t)) {
|
|
2472
2625
|
const o = t.item.config?.models;
|
|
2473
2626
|
return (Array.isArray(o) ? o : o && typeof o == "object" ? Object.values(o) : []).some((n) => {
|
|
2474
2627
|
if (!n || typeof n != "object") return !1;
|
|
@@ -2478,11 +2631,11 @@ function nl(t) {
|
|
|
2478
2631
|
}
|
|
2479
2632
|
return !1;
|
|
2480
2633
|
}
|
|
2481
|
-
function
|
|
2482
|
-
return
|
|
2634
|
+
function uo(t) {
|
|
2635
|
+
return $n(t).trim().length >= 10;
|
|
2483
2636
|
}
|
|
2484
|
-
function
|
|
2485
|
-
const e =
|
|
2637
|
+
function Ia(t) {
|
|
2638
|
+
const e = $n(t);
|
|
2486
2639
|
return [
|
|
2487
2640
|
/chemistry|chemical|element|atom|molecule|compound/i,
|
|
2488
2641
|
/periodic\s+table/i,
|
|
@@ -2492,23 +2645,23 @@ function il(t) {
|
|
|
2492
2645
|
/physics|force|energy|velocity|acceleration/i
|
|
2493
2646
|
].some((o) => o.test(e));
|
|
2494
2647
|
}
|
|
2495
|
-
var
|
|
2648
|
+
var ka = /* @__PURE__ */ new Set([
|
|
2496
2649
|
"assessment",
|
|
2497
2650
|
"section",
|
|
2498
2651
|
"item",
|
|
2499
2652
|
"passage",
|
|
2500
2653
|
"rubric"
|
|
2501
2654
|
]);
|
|
2502
|
-
function
|
|
2503
|
-
return
|
|
2655
|
+
function $a(t) {
|
|
2656
|
+
return ka.has(t);
|
|
2504
2657
|
}
|
|
2505
|
-
function
|
|
2658
|
+
function Sn(t, e, o) {
|
|
2506
2659
|
const n = t.trim(), i = o.trim();
|
|
2507
2660
|
if (!n || !i) throw new Error("Tool instance ids require non-empty tool and scope ids");
|
|
2508
|
-
if (
|
|
2661
|
+
if (!$a(e)) throw new Error(`Unknown tool scope level '${e}'. Register custom levels with registerToolScopeLevel().`);
|
|
2509
2662
|
return `${n}:${e}:${i}`;
|
|
2510
2663
|
}
|
|
2511
|
-
var
|
|
2664
|
+
var Sa = class {
|
|
2512
2665
|
constructor() {
|
|
2513
2666
|
y(this, "providerId", "desmos-calculator"), y(this, "providerName", "Desmos Calculator"), y(this, "category", "calculator"), y(this, "version", "1.10"), y(this, "requiresAuth", !0), y(this, "desmosProvider", null), y(this, "config", null);
|
|
2514
2667
|
}
|
|
@@ -2530,34 +2683,36 @@ var ll = class {
|
|
|
2530
2683
|
toolId: "calculator",
|
|
2531
2684
|
operation: "desmos-provider-module-import",
|
|
2532
2685
|
backend: "desmos"
|
|
2533
|
-
})
|
|
2686
|
+
});
|
|
2687
|
+
const o = await (async () => {
|
|
2534
2688
|
try {
|
|
2535
|
-
const
|
|
2689
|
+
const n = await import("./dist-rF11IR1B-adc4857f.js");
|
|
2536
2690
|
return await this.emitTelemetry("pie-tool-library-load-success", {
|
|
2537
2691
|
toolId: "calculator",
|
|
2538
2692
|
operation: "desmos-provider-module-import",
|
|
2539
2693
|
backend: "desmos",
|
|
2540
2694
|
duration: Date.now() - e
|
|
2541
|
-
}),
|
|
2542
|
-
} catch (
|
|
2695
|
+
}), n;
|
|
2696
|
+
} catch (n) {
|
|
2543
2697
|
throw await this.emitTelemetry("pie-tool-library-load-error", {
|
|
2544
2698
|
toolId: "calculator",
|
|
2545
2699
|
operation: "desmos-provider-module-import",
|
|
2546
2700
|
backend: "desmos",
|
|
2547
2701
|
duration: Date.now() - e,
|
|
2548
2702
|
errorType: "ToolLibraryLoadError",
|
|
2549
|
-
message:
|
|
2550
|
-
}),
|
|
2703
|
+
message: n instanceof Error ? n.message : String(n)
|
|
2704
|
+
}), n;
|
|
2551
2705
|
}
|
|
2552
|
-
})()
|
|
2706
|
+
})();
|
|
2707
|
+
this.desmosProvider = new o.DesmosCalculatorProvider();
|
|
2553
2708
|
try {
|
|
2554
2709
|
await this.desmosProvider.initialize({
|
|
2555
2710
|
apiKey: t.apiKey,
|
|
2556
2711
|
proxyEndpoint: t.proxyEndpoint,
|
|
2557
2712
|
onTelemetry: t.onTelemetry
|
|
2558
2713
|
}), console.log(`[DesmosToolProvider] Initialized successfully ${t.proxyEndpoint ? "(using proxy)" : t.apiKey ? "(direct API key)" : "(no auth)"}`);
|
|
2559
|
-
} catch (
|
|
2560
|
-
throw console.error("[DesmosToolProvider] Initialization failed:",
|
|
2714
|
+
} catch (n) {
|
|
2715
|
+
throw console.error("[DesmosToolProvider] Initialization failed:", n), /* @__PURE__ */ new Error("Failed to initialize Desmos calculator provider. Check API key or proxy endpoint.");
|
|
2561
2716
|
}
|
|
2562
2717
|
}
|
|
2563
2718
|
async createInstance(t) {
|
|
@@ -2583,41 +2738,41 @@ var ll = class {
|
|
|
2583
2738
|
destroy() {
|
|
2584
2739
|
this.desmosProvider && (this.desmosProvider.destroy(), this.desmosProvider = null), this.config = null, console.log("[DesmosToolProvider] Destroyed");
|
|
2585
2740
|
}
|
|
2586
|
-
},
|
|
2741
|
+
}, Aa = (t, e) => {
|
|
2587
2742
|
const o = e?.useSentenceSegmenter !== !1;
|
|
2588
2743
|
try {
|
|
2589
2744
|
if (!o) throw new Error("Segmenter disabled by policy");
|
|
2590
2745
|
const s = globalThis.Intl?.Segmenter;
|
|
2591
2746
|
if (typeof s == "function") {
|
|
2592
|
-
const
|
|
2593
|
-
text:
|
|
2594
|
-
offset:
|
|
2595
|
-
})).filter((
|
|
2596
|
-
if (
|
|
2747
|
+
const a = new s(e?.locale, { granularity: "sentence" }), u = Array.from(a.segment(t)).map((l) => ({
|
|
2748
|
+
text: l.segment,
|
|
2749
|
+
offset: l.index
|
|
2750
|
+
})).filter((l) => l.text.trim().length > 0);
|
|
2751
|
+
if (u.length > 0) return u;
|
|
2597
2752
|
}
|
|
2598
2753
|
} catch {
|
|
2599
2754
|
}
|
|
2600
2755
|
const n = t.match(/[^.!?]+(?:[.!?]+|$)/g) || [t], i = [];
|
|
2601
2756
|
let r = 0;
|
|
2602
2757
|
for (const s of n) {
|
|
2603
|
-
const
|
|
2604
|
-
|
|
2758
|
+
const a = t.indexOf(s, r);
|
|
2759
|
+
a !== -1 && (i.push({
|
|
2605
2760
|
text: s,
|
|
2606
|
-
offset:
|
|
2607
|
-
}), r =
|
|
2761
|
+
offset: a
|
|
2762
|
+
}), r = a + s.length);
|
|
2608
2763
|
}
|
|
2609
2764
|
return i.length > 0 ? i : [{
|
|
2610
2765
|
text: t,
|
|
2611
2766
|
offset: 0
|
|
2612
2767
|
}];
|
|
2613
|
-
},
|
|
2768
|
+
}, xa = class {
|
|
2614
2769
|
constructor() {
|
|
2615
2770
|
y(this, "providerId", "browser"), y(this, "providerName", "Browser Speech Synthesis"), y(this, "version", "1.0.0");
|
|
2616
2771
|
}
|
|
2617
2772
|
async initialize(t) {
|
|
2618
2773
|
if (typeof window > "u") throw new Error("BrowserTTSProvider requires browser environment");
|
|
2619
2774
|
if (!("speechSynthesis" in window)) throw new Error("Browser does not support Speech Synthesis API");
|
|
2620
|
-
return new
|
|
2775
|
+
return new _a(t);
|
|
2621
2776
|
}
|
|
2622
2777
|
supportsFeature(t) {
|
|
2623
2778
|
return !0;
|
|
@@ -2634,7 +2789,7 @@ var ll = class {
|
|
|
2634
2789
|
}
|
|
2635
2790
|
destroy() {
|
|
2636
2791
|
}
|
|
2637
|
-
},
|
|
2792
|
+
}, _a = class {
|
|
2638
2793
|
constructor(t) {
|
|
2639
2794
|
y(this, "utterance", null), y(this, "config", null), y(this, "_isPlaying", !1), y(this, "_isPaused", !1), y(this, "speakRunId", 0), y(this, "onWordBoundary", void 0), this.config = t;
|
|
2640
2795
|
}
|
|
@@ -2669,16 +2824,16 @@ var ll = class {
|
|
|
2669
2824
|
for (const r of e) {
|
|
2670
2825
|
const s = r.text.trim();
|
|
2671
2826
|
if (!s) continue;
|
|
2672
|
-
const
|
|
2827
|
+
const a = r.text.search(/\S/), u = r.offset + (a === -1 ? 0 : a);
|
|
2673
2828
|
if (!n) {
|
|
2674
|
-
n = s, i =
|
|
2829
|
+
n = s, i = u;
|
|
2675
2830
|
continue;
|
|
2676
2831
|
}
|
|
2677
|
-
const
|
|
2678
|
-
|
|
2832
|
+
const l = `${n} ${s}`;
|
|
2833
|
+
l.length <= 260 ? n = l : (o.push({
|
|
2679
2834
|
text: n,
|
|
2680
2835
|
offset: i
|
|
2681
|
-
}), n = s, i =
|
|
2836
|
+
}), n = s, i = u);
|
|
2682
2837
|
}
|
|
2683
2838
|
return n && o.push({
|
|
2684
2839
|
text: n,
|
|
@@ -2701,7 +2856,7 @@ var ll = class {
|
|
|
2701
2856
|
}
|
|
2702
2857
|
segmentSentences(t) {
|
|
2703
2858
|
const e = this.getSegmentationPolicy();
|
|
2704
|
-
return
|
|
2859
|
+
return Aa(t, {
|
|
2705
2860
|
locale: e.locale,
|
|
2706
2861
|
useSentenceSegmenter: e.useSentenceSegmenter
|
|
2707
2862
|
});
|
|
@@ -2744,8 +2899,8 @@ var ll = class {
|
|
|
2744
2899
|
o === this.speakRunId && (this._isPaused = !1);
|
|
2745
2900
|
}, this.utterance.onboundary = (r) => {
|
|
2746
2901
|
if (o !== this.speakRunId || (console.log("[BrowserProvider] Boundary event:", r.name, "charIndex:", r.charIndex, "charLength:", r.charLength), r.name !== "word" || !this.onWordBoundary) || this.getHighlightMode() === "sentence") return;
|
|
2747
|
-
const s = Math.max(0, Math.min(r.charIndex, Math.max(0, t.length - 1))),
|
|
2748
|
-
console.log("[BrowserProvider] Calling onWordBoundary with word:", d, "at position:",
|
|
2902
|
+
const s = Math.max(0, Math.min(r.charIndex, Math.max(0, t.length - 1))), a = Number(r.charLength || 0), u = this.inferWordLength(t, s), l = Number.isFinite(a) && a > 0 && a <= 80 && s + a <= t.length ? a : u, d = t.substring(s, Math.min(t.length, s + l)).trim(), h = e + s;
|
|
2903
|
+
console.log("[BrowserProvider] Calling onWordBoundary with word:", d, "at position:", h), this.onWordBoundary(d, h, l);
|
|
2749
2904
|
}, speechSynthesis.speak(this.utterance);
|
|
2750
2905
|
});
|
|
2751
2906
|
}
|
|
@@ -2770,7 +2925,7 @@ var ll = class {
|
|
|
2770
2925
|
...t.providerOptions || {}
|
|
2771
2926
|
});
|
|
2772
2927
|
}
|
|
2773
|
-
},
|
|
2928
|
+
}, Ca = class {
|
|
2774
2929
|
async emitTelemetry(t, e) {
|
|
2775
2930
|
try {
|
|
2776
2931
|
await this.config?.onTelemetry?.(t, e);
|
|
@@ -2802,7 +2957,7 @@ var ll = class {
|
|
|
2802
2957
|
}
|
|
2803
2958
|
async _initializeBrowserTTS(t) {
|
|
2804
2959
|
if (typeof window > "u" || !("speechSynthesis" in window)) throw new Error("[TTSToolProvider] Browser TTS not supported (Web Speech API not available)");
|
|
2805
|
-
this.ttsProvider = new
|
|
2960
|
+
this.ttsProvider = new xa(), console.log("[TTSToolProvider] Browser TTS initialized (Web Speech API)");
|
|
2806
2961
|
}
|
|
2807
2962
|
async _initializeServerTTS(t) {
|
|
2808
2963
|
if (!t.apiEndpoint) throw new Error("[TTSToolProvider] apiEndpoint required for server-based TTS backends");
|
|
@@ -2811,26 +2966,28 @@ var ll = class {
|
|
|
2811
2966
|
toolId: "tts",
|
|
2812
2967
|
operation: "server-provider-module-import",
|
|
2813
2968
|
backend: t.serverProvider || t.backend
|
|
2814
|
-
})
|
|
2969
|
+
});
|
|
2970
|
+
const o = await (async () => {
|
|
2815
2971
|
try {
|
|
2816
|
-
const
|
|
2972
|
+
const n = await import("./dist-DIBQdekL-ec6db34a.js");
|
|
2817
2973
|
return await this.emitTelemetry("pie-tool-library-load-success", {
|
|
2818
2974
|
toolId: "tts",
|
|
2819
2975
|
operation: "server-provider-module-import",
|
|
2820
2976
|
backend: t.serverProvider || t.backend,
|
|
2821
2977
|
duration: Date.now() - e
|
|
2822
|
-
}),
|
|
2823
|
-
} catch (
|
|
2978
|
+
}), n;
|
|
2979
|
+
} catch (n) {
|
|
2824
2980
|
throw await this.emitTelemetry("pie-tool-library-load-error", {
|
|
2825
2981
|
toolId: "tts",
|
|
2826
2982
|
operation: "server-provider-module-import",
|
|
2827
2983
|
backend: t.serverProvider || t.backend,
|
|
2828
2984
|
duration: Date.now() - e,
|
|
2829
2985
|
errorType: "ToolLibraryLoadError",
|
|
2830
|
-
message:
|
|
2831
|
-
}),
|
|
2986
|
+
message: n instanceof Error ? n.message : String(n)
|
|
2987
|
+
}), n;
|
|
2832
2988
|
}
|
|
2833
|
-
})()
|
|
2989
|
+
})();
|
|
2990
|
+
this.ttsProvider = new o.ServerTTSProvider(), console.log(`[TTSToolProvider] Server TTS initialized (provider: ${t.serverProvider || t.backend})`);
|
|
2834
2991
|
}
|
|
2835
2992
|
async createInstance(t) {
|
|
2836
2993
|
if (!this.ttsProvider) throw new Error("[TTSToolProvider] Provider not initialized. Call initialize() first.");
|
|
@@ -2858,7 +3015,7 @@ var ll = class {
|
|
|
2858
3015
|
destroy() {
|
|
2859
3016
|
this.ttsProvider && (this.ttsProvider.destroy(), this.ttsProvider = null), this.config = null, console.log("[TTSToolProvider] Destroyed");
|
|
2860
3017
|
}
|
|
2861
|
-
},
|
|
3018
|
+
}, Ea = /* @__PURE__ */ new Set([
|
|
2862
3019
|
"annotation-xml",
|
|
2863
3020
|
"color-profile",
|
|
2864
3021
|
"font-face",
|
|
@@ -2867,16 +3024,16 @@ var ll = class {
|
|
|
2867
3024
|
"font-face-format",
|
|
2868
3025
|
"font-face-name",
|
|
2869
3026
|
"missing-glyph"
|
|
2870
|
-
]),
|
|
3027
|
+
]), Ma = /^[a-z][a-z0-9._-]*-[a-z0-9._-]*$/, La = (t, e = "custom element tag") => {
|
|
2871
3028
|
if (!t || typeof t != "string") throw new Error(`Invalid ${e}: expected a non-empty string`);
|
|
2872
3029
|
const o = t.trim();
|
|
2873
3030
|
if (!o) throw new Error(`Invalid ${e}: tag is empty`);
|
|
2874
3031
|
if (o !== o.toLowerCase()) throw new Error(`Invalid ${e} "${o}": custom element names must be lowercase`);
|
|
2875
3032
|
if (!o.includes("-")) throw new Error(`Invalid ${e} "${o}": custom element names must include a hyphen`);
|
|
2876
|
-
if (
|
|
2877
|
-
if (!
|
|
3033
|
+
if (Ea.has(o)) throw new Error(`Invalid ${e} "${o}": this name is reserved by the HTML spec`);
|
|
3034
|
+
if (!Ma.test(o)) throw new Error(`Invalid ${e} "${o}": allowed characters are lowercase letters, numbers, ".", "_" and "-"`);
|
|
2878
3035
|
return o;
|
|
2879
|
-
},
|
|
3036
|
+
}, fr = {
|
|
2880
3037
|
calculator: "pie-tool-calculator",
|
|
2881
3038
|
textToSpeech: "pie-tool-text-to-speech",
|
|
2882
3039
|
ruler: "pie-tool-ruler",
|
|
@@ -2889,22 +3046,22 @@ var ll = class {
|
|
|
2889
3046
|
annotationToolbar: "pie-tool-annotation-toolbar",
|
|
2890
3047
|
graph: "pie-tool-graph",
|
|
2891
3048
|
periodicTable: "pie-tool-periodic-table"
|
|
2892
|
-
},
|
|
2893
|
-
const i =
|
|
3049
|
+
}, Pa = (t, e) => La(e?.toolTagMap?.[t] ?? fr[t] ?? t, `tool component tag for "${t}"`), Oa = (t) => document.createElement(t), yt = (t, e, o, n) => {
|
|
3050
|
+
const i = Pa(t, n), r = n?.toolComponentFactories?.[t] ?? n?.toolComponentFactory;
|
|
2894
3051
|
return r ? r({
|
|
2895
3052
|
toolId: t,
|
|
2896
3053
|
tagName: i,
|
|
2897
3054
|
context: e,
|
|
2898
3055
|
toolbarContext: o
|
|
2899
|
-
}) :
|
|
2900
|
-
},
|
|
3056
|
+
}) : Oa(i);
|
|
3057
|
+
}, Ra = {
|
|
2901
3058
|
toolId: "calculator",
|
|
2902
3059
|
name: "Calculator",
|
|
2903
3060
|
description: "Multi-type calculator (basic, scientific, graphing)",
|
|
2904
3061
|
icon: "calculator",
|
|
2905
3062
|
provider: {
|
|
2906
3063
|
getProviderId: (t) => typeof t?.provider?.id == "string" && t.provider.id.length > 0 ? t.provider.id : "calculator-desmos",
|
|
2907
|
-
createProvider: () => new
|
|
3064
|
+
createProvider: () => new Sa(),
|
|
2908
3065
|
getInitConfig: (t) => t?.provider?.init ?? {},
|
|
2909
3066
|
getAuthFetcher: (t) => {
|
|
2910
3067
|
const e = t?.provider?.runtime?.authFetcher;
|
|
@@ -2927,10 +3084,10 @@ var ll = class {
|
|
|
2927
3084
|
"scientificCalculator"
|
|
2928
3085
|
],
|
|
2929
3086
|
isVisibleInContext(t) {
|
|
2930
|
-
return
|
|
3087
|
+
return co(t);
|
|
2931
3088
|
},
|
|
2932
3089
|
renderToolbar(t, e) {
|
|
2933
|
-
const o =
|
|
3090
|
+
const o = Sn(this.toolId, e.scope.level, e.scope.scopeId), n = e.componentOverrides, i = yt(this.toolId, t, e, n);
|
|
2934
3091
|
i.setAttribute("tool-id", o), i.toolkitCoordinator = e.toolkitCoordinator;
|
|
2935
3092
|
const r = {
|
|
2936
3093
|
toolId: this.toolId,
|
|
@@ -2961,22 +3118,22 @@ var ll = class {
|
|
|
2961
3118
|
}],
|
|
2962
3119
|
button: r,
|
|
2963
3120
|
sync: () => {
|
|
2964
|
-
const
|
|
2965
|
-
r.active =
|
|
3121
|
+
const a = e.isToolVisible(o);
|
|
3122
|
+
r.active = a, r.ariaLabel = a ? "Close scientific calculator" : "Open scientific calculator", r.tooltip = a ? "Close calculator" : "Calculator", s !== a && (i.visible = a, s = a), i.toolkitCoordinator !== e.toolkitCoordinator && (i.toolkitCoordinator = e.toolkitCoordinator);
|
|
2966
3123
|
},
|
|
2967
|
-
subscribeActive: (
|
|
2968
|
-
|
|
3124
|
+
subscribeActive: (a) => e.subscribeVisibility ? e.subscribeVisibility(() => {
|
|
3125
|
+
a(e.isToolVisible(o));
|
|
2969
3126
|
}) : () => {
|
|
2970
3127
|
}
|
|
2971
3128
|
};
|
|
2972
3129
|
}
|
|
2973
|
-
},
|
|
3130
|
+
}, ja = /* @__PURE__ */ new Set([
|
|
2974
3131
|
"reserved-row",
|
|
2975
3132
|
"expanding-row",
|
|
2976
3133
|
"floating-overlay",
|
|
2977
3134
|
"left-aligned"
|
|
2978
|
-
]),
|
|
2979
|
-
if (!Array.isArray(t)) return [...
|
|
3135
|
+
]), ni = (t) => t && typeof t == "object" ? t : {}, Na = (t) => t === "polly" || t === "google" || t === "server", Q = (t, e) => t === void 0 ? e : t, wo = (t, e = "left-aligned") => typeof t == "string" && ja.has(t) ? t : e, ii = Object.freeze([0.8, 1.25]), zo = (t) => {
|
|
3136
|
+
if (!Array.isArray(t)) return [...ii];
|
|
2980
3137
|
if (t.length === 0) return [];
|
|
2981
3138
|
const e = /* @__PURE__ */ new Set();
|
|
2982
3139
|
for (const o of t) {
|
|
@@ -2984,41 +3141,41 @@ var ll = class {
|
|
|
2984
3141
|
const n = Math.round(o * 100) / 100;
|
|
2985
3142
|
n !== 1 && e.add(n);
|
|
2986
3143
|
}
|
|
2987
|
-
return e.size ? Array.from(e) : [...
|
|
2988
|
-
},
|
|
3144
|
+
return e.size ? Array.from(e) : [...ii];
|
|
3145
|
+
}, Wa = (t) => {
|
|
2989
3146
|
const e = {
|
|
2990
3147
|
...t,
|
|
2991
|
-
layoutMode:
|
|
3148
|
+
layoutMode: wo(t.layoutMode)
|
|
2992
3149
|
}, o = t.backend || "browser";
|
|
2993
|
-
if (!
|
|
3150
|
+
if (!Na(o)) return e;
|
|
2994
3151
|
const n = {
|
|
2995
3152
|
...e,
|
|
2996
|
-
apiEndpoint:
|
|
2997
|
-
transportMode:
|
|
2998
|
-
endpointValidationMode:
|
|
2999
|
-
validateEndpoint:
|
|
3000
|
-
includeAuthOnAssetFetch:
|
|
3001
|
-
rate:
|
|
3002
|
-
language:
|
|
3153
|
+
apiEndpoint: Q(e.apiEndpoint, "/api/tts"),
|
|
3154
|
+
transportMode: Q(e.transportMode, "pie"),
|
|
3155
|
+
endpointValidationMode: Q(e.endpointValidationMode, "voices"),
|
|
3156
|
+
validateEndpoint: Q(e.validateEndpoint, !0),
|
|
3157
|
+
includeAuthOnAssetFetch: Q(e.includeAuthOnAssetFetch, !1),
|
|
3158
|
+
rate: Q(e.rate, 1),
|
|
3159
|
+
language: Q(e.language, "en-US")
|
|
3003
3160
|
};
|
|
3004
3161
|
return o === "polly" ? {
|
|
3005
3162
|
...n,
|
|
3006
|
-
defaultVoice:
|
|
3007
|
-
engine:
|
|
3008
|
-
format:
|
|
3009
|
-
speechMarksMode:
|
|
3163
|
+
defaultVoice: Q(n.defaultVoice, "Joanna"),
|
|
3164
|
+
engine: Q(n.engine, "neural"),
|
|
3165
|
+
format: Q(n.format, "mp3"),
|
|
3166
|
+
speechMarksMode: Q(n.speechMarksMode, "word+sentence")
|
|
3010
3167
|
} : o === "google" ? {
|
|
3011
3168
|
...n,
|
|
3012
|
-
defaultVoice:
|
|
3169
|
+
defaultVoice: Q(n.defaultVoice, "en-US-Wavenet-A")
|
|
3013
3170
|
} : n;
|
|
3014
|
-
},
|
|
3015
|
-
const e =
|
|
3016
|
-
return
|
|
3171
|
+
}, qo = (t) => {
|
|
3172
|
+
const e = ni(t), o = ni(t?.settings);
|
|
3173
|
+
return Wa({
|
|
3017
3174
|
...e,
|
|
3018
3175
|
...o
|
|
3019
3176
|
});
|
|
3020
|
-
},
|
|
3021
|
-
const e =
|
|
3177
|
+
}, on = (t) => t.backend || "browser", pr = (t, e) => e === "polly" || e === "google" ? e : t.serverProvider || t.provider, vr = (t, e) => t.transportMode || (e === "custom" ? "custom" : "pie"), Va = (t) => {
|
|
3178
|
+
const e = on(t), o = pr(t, e), n = vr(t, o);
|
|
3022
3179
|
return {
|
|
3023
3180
|
voice: t.defaultVoice,
|
|
3024
3181
|
rate: t.rate,
|
|
@@ -3042,8 +3199,8 @@ var ll = class {
|
|
|
3042
3199
|
includeAuthOnAssetFetch: t.includeAuthOnAssetFetch,
|
|
3043
3200
|
validateEndpoint: t.validateEndpoint
|
|
3044
3201
|
};
|
|
3045
|
-
},
|
|
3046
|
-
switch (
|
|
3202
|
+
}, gr = (t) => wo(t.layoutMode), za = (t) => {
|
|
3203
|
+
switch (gr(t)) {
|
|
3047
3204
|
case "reserved-row":
|
|
3048
3205
|
return {
|
|
3049
3206
|
mount: "before-buttons",
|
|
@@ -3069,21 +3226,21 @@ var ll = class {
|
|
|
3069
3226
|
}
|
|
3070
3227
|
};
|
|
3071
3228
|
}
|
|
3072
|
-
},
|
|
3229
|
+
}, Le = /* @__PURE__ */ new Map(), qa = "__pieToolElementUnmount", ri = "pie-tool-active-change", Da = {
|
|
3073
3230
|
toolId: "textToSpeech",
|
|
3074
3231
|
name: "Text to Speech",
|
|
3075
3232
|
description: "Read content aloud",
|
|
3076
3233
|
icon: "volume-up",
|
|
3077
3234
|
provider: {
|
|
3078
3235
|
getProviderId: () => "tts",
|
|
3079
|
-
createProvider: (t) => new
|
|
3236
|
+
createProvider: (t) => new Ca(on(qo(t))),
|
|
3080
3237
|
getInitConfig: (t) => {
|
|
3081
|
-
const e =
|
|
3238
|
+
const e = qo(t), o = on(e), n = pr(e, o);
|
|
3082
3239
|
return {
|
|
3083
3240
|
backend: o,
|
|
3084
3241
|
serverProvider: n,
|
|
3085
|
-
transportMode:
|
|
3086
|
-
...
|
|
3242
|
+
transportMode: vr(e, n),
|
|
3243
|
+
...Va(e)
|
|
3087
3244
|
};
|
|
3088
3245
|
},
|
|
3089
3246
|
getAuthFetcher: (t) => {
|
|
@@ -3092,9 +3249,9 @@ var ll = class {
|
|
|
3092
3249
|
},
|
|
3093
3250
|
sanitizeConfig: (t) => {
|
|
3094
3251
|
const e = t.settings && typeof t.settings == "object" ? { ...t.settings } : void 0;
|
|
3095
|
-
e && "layoutMode" in e && (e.layoutMode =
|
|
3252
|
+
e && "layoutMode" in e && (e.layoutMode = wo(e.layoutMode)), e && "speedOptions" in e && (e.speedOptions = zo(e.speedOptions));
|
|
3096
3253
|
const o = { ...t };
|
|
3097
|
-
return "layoutMode" in o && (o.layoutMode =
|
|
3254
|
+
return "layoutMode" in o && (o.layoutMode = wo(o.layoutMode)), "speedOptions" in o && (o.speedOptions = zo(o.speedOptions)), e && (o.settings = e), o;
|
|
3098
3255
|
},
|
|
3099
3256
|
lazy: !0
|
|
3100
3257
|
},
|
|
@@ -3106,47 +3263,47 @@ var ll = class {
|
|
|
3106
3263
|
"speechOutput"
|
|
3107
3264
|
],
|
|
3108
3265
|
isVisibleInContext(t) {
|
|
3109
|
-
return
|
|
3266
|
+
return uo(t);
|
|
3110
3267
|
},
|
|
3111
3268
|
renderToolbar(t, e) {
|
|
3112
|
-
const o = () =>
|
|
3269
|
+
const o = () => qo(e.toolkitCoordinator?.getToolConfig(this.toolId) || void 0), n = () => zo(o().speedOptions), i = () => gr(o()), r = () => za(o()), s = Sn(this.toolId, e.scope.level, e.scope.scopeId), a = () => {
|
|
3113
3270
|
const d = e.ui?.size;
|
|
3114
3271
|
return d === "sm" || d === "lg" ? d : "md";
|
|
3115
|
-
},
|
|
3116
|
-
let d =
|
|
3117
|
-
return d && typeof d.isConnected == "boolean" && !d.isConnected && (
|
|
3118
|
-
|
|
3119
|
-
},
|
|
3120
|
-
},
|
|
3272
|
+
}, u = () => {
|
|
3273
|
+
let d = Le.get(s);
|
|
3274
|
+
return d && typeof d.isConnected == "boolean" && !d.isConnected && (Le.delete(s), d = void 0), d || (d = document.createElement("pie-tool-tts-inline"), d[qa] = () => {
|
|
3275
|
+
Le.get(s) === d && Le.delete(s);
|
|
3276
|
+
}, Le.set(s, d)), d.setAttribute("tool-id", s), d.setAttribute("catalog-id", e.catalogId || e.itemId), d.setAttribute("language", e.language || "en-US"), d.setAttribute("size", a()), d.setAttribute("layout-mode", i()), d.speedOptions = n(), d;
|
|
3277
|
+
}, l = r();
|
|
3121
3278
|
return {
|
|
3122
3279
|
toolId: this.toolId,
|
|
3123
3280
|
button: null,
|
|
3124
3281
|
elements: [{
|
|
3125
|
-
element:
|
|
3126
|
-
mount:
|
|
3282
|
+
element: u(),
|
|
3283
|
+
mount: l.mount,
|
|
3127
3284
|
layoutHints: { controlsRow: {
|
|
3128
|
-
reserveSpace:
|
|
3129
|
-
showWhenToolActive:
|
|
3285
|
+
reserveSpace: l.controlsRow.reserveSpace,
|
|
3286
|
+
showWhenToolActive: l.controlsRow.expandWhenToolActive
|
|
3130
3287
|
} }
|
|
3131
3288
|
}],
|
|
3132
3289
|
subscribeActive: (d) => {
|
|
3133
|
-
const
|
|
3290
|
+
const h = u(), f = (v) => {
|
|
3134
3291
|
const m = v.detail;
|
|
3135
3292
|
d(m?.active === !0);
|
|
3136
3293
|
};
|
|
3137
|
-
return
|
|
3138
|
-
|
|
3294
|
+
return h.addEventListener(ri, f), () => {
|
|
3295
|
+
h.removeEventListener(ri, f);
|
|
3139
3296
|
};
|
|
3140
3297
|
},
|
|
3141
3298
|
sync: () => {
|
|
3142
|
-
const d =
|
|
3143
|
-
d.setAttribute("tool-id", s), d.setAttribute("catalog-id", e.catalogId || e.itemId), d.setAttribute("language", e.language || "en-US"), d.setAttribute("size",
|
|
3299
|
+
const d = u();
|
|
3300
|
+
d.setAttribute("tool-id", s), d.setAttribute("catalog-id", e.catalogId || e.itemId), d.setAttribute("language", e.language || "en-US"), d.setAttribute("size", a()), d.setAttribute("layout-mode", i()), d.speedOptions = n();
|
|
3144
3301
|
}
|
|
3145
3302
|
};
|
|
3146
3303
|
}
|
|
3147
3304
|
};
|
|
3148
|
-
function
|
|
3149
|
-
const o =
|
|
3305
|
+
function Ct(t, e) {
|
|
3306
|
+
const o = Sn(t, e.scope.level, e.scope.scopeId);
|
|
3150
3307
|
return {
|
|
3151
3308
|
fullToolId: o,
|
|
3152
3309
|
isActive: () => e.isToolVisible(o),
|
|
@@ -3156,16 +3313,16 @@ function kt(t, e) {
|
|
|
3156
3313
|
}
|
|
3157
3314
|
};
|
|
3158
3315
|
}
|
|
3159
|
-
function
|
|
3316
|
+
function Et(t) {
|
|
3160
3317
|
const e = t.isActive();
|
|
3161
3318
|
t.button.active = e, t.overlay.visible = e, t.onActiveChange?.(e);
|
|
3162
3319
|
}
|
|
3163
|
-
function
|
|
3320
|
+
function Do(t, e) {
|
|
3164
3321
|
t.setAttribute("data-pie-tool-surface", e);
|
|
3165
3322
|
}
|
|
3166
|
-
var
|
|
3167
|
-
|
|
3168
|
-
|
|
3323
|
+
var Ha = [
|
|
3324
|
+
Ra,
|
|
3325
|
+
Da,
|
|
3169
3326
|
{
|
|
3170
3327
|
toolId: "ruler",
|
|
3171
3328
|
name: "Ruler",
|
|
@@ -3178,10 +3335,10 @@ var kl = [
|
|
|
3178
3335
|
],
|
|
3179
3336
|
pnpSupportIds: ["ruler", "measurement"],
|
|
3180
3337
|
isVisibleInContext(t) {
|
|
3181
|
-
return
|
|
3338
|
+
return co(t);
|
|
3182
3339
|
},
|
|
3183
3340
|
renderToolbar(t, e) {
|
|
3184
|
-
const o =
|
|
3341
|
+
const o = Ct(this.toolId, e), n = {
|
|
3185
3342
|
toolId: this.toolId,
|
|
3186
3343
|
label: this.name,
|
|
3187
3344
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3190,8 +3347,8 @@ var kl = [
|
|
|
3190
3347
|
tooltip: "Ruler",
|
|
3191
3348
|
onClick: () => e.toggleTool(this.toolId),
|
|
3192
3349
|
active: o.isActive()
|
|
3193
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3194
|
-
return r.setAttribute("tool-id", o.fullToolId),
|
|
3350
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3351
|
+
return r.setAttribute("tool-id", o.fullToolId), Do(r, "frameless"), {
|
|
3195
3352
|
toolId: this.toolId,
|
|
3196
3353
|
button: n,
|
|
3197
3354
|
elements: [{
|
|
@@ -3199,7 +3356,7 @@ var kl = [
|
|
|
3199
3356
|
mount: "after-buttons"
|
|
3200
3357
|
}],
|
|
3201
3358
|
sync: () => {
|
|
3202
|
-
|
|
3359
|
+
Et({
|
|
3203
3360
|
button: n,
|
|
3204
3361
|
overlay: r,
|
|
3205
3362
|
isActive: o.isActive
|
|
@@ -3221,10 +3378,10 @@ var kl = [
|
|
|
3221
3378
|
],
|
|
3222
3379
|
pnpSupportIds: ["protractor", "angleMeasurement"],
|
|
3223
3380
|
isVisibleInContext(t) {
|
|
3224
|
-
return
|
|
3381
|
+
return co(t);
|
|
3225
3382
|
},
|
|
3226
3383
|
renderToolbar(t, e) {
|
|
3227
|
-
const o =
|
|
3384
|
+
const o = Ct(this.toolId, e), n = {
|
|
3228
3385
|
toolId: this.toolId,
|
|
3229
3386
|
label: this.name,
|
|
3230
3387
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3233,8 +3390,8 @@ var kl = [
|
|
|
3233
3390
|
tooltip: "Protractor",
|
|
3234
3391
|
onClick: () => e.toggleTool(this.toolId),
|
|
3235
3392
|
active: o.isActive()
|
|
3236
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3237
|
-
return r.setAttribute("tool-id", o.fullToolId),
|
|
3393
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3394
|
+
return r.setAttribute("tool-id", o.fullToolId), Do(r, "frameless"), {
|
|
3238
3395
|
toolId: this.toolId,
|
|
3239
3396
|
button: n,
|
|
3240
3397
|
elements: [{
|
|
@@ -3242,7 +3399,7 @@ var kl = [
|
|
|
3242
3399
|
mount: "after-buttons"
|
|
3243
3400
|
}],
|
|
3244
3401
|
sync: () => {
|
|
3245
|
-
|
|
3402
|
+
Et({
|
|
3246
3403
|
button: n,
|
|
3247
3404
|
overlay: r,
|
|
3248
3405
|
isActive: o.isActive
|
|
@@ -3265,10 +3422,10 @@ var kl = [
|
|
|
3265
3422
|
"choiceMasking"
|
|
3266
3423
|
],
|
|
3267
3424
|
isVisibleInContext(t) {
|
|
3268
|
-
return
|
|
3425
|
+
return Ta(t);
|
|
3269
3426
|
},
|
|
3270
3427
|
renderToolbar(t, e) {
|
|
3271
|
-
const o =
|
|
3428
|
+
const o = Ct(this.toolId, e), n = e.componentOverrides ?? {}, i = yt(this.toolId, t, e, n);
|
|
3272
3429
|
i.setAttribute("tool-id", o.fullToolId), i.setAttribute("strategy", "strikethrough"), i.setAttribute("button-alignment", "inline");
|
|
3273
3430
|
const r = {
|
|
3274
3431
|
toolId: this.toolId,
|
|
@@ -3288,7 +3445,7 @@ var kl = [
|
|
|
3288
3445
|
mount: "after-buttons"
|
|
3289
3446
|
}],
|
|
3290
3447
|
sync: () => {
|
|
3291
|
-
|
|
3448
|
+
Et({
|
|
3292
3449
|
button: r,
|
|
3293
3450
|
overlay: i,
|
|
3294
3451
|
isActive: o.isActive
|
|
@@ -3318,10 +3475,10 @@ var kl = [
|
|
|
3318
3475
|
"annotation"
|
|
3319
3476
|
],
|
|
3320
3477
|
isVisibleInContext(t) {
|
|
3321
|
-
return
|
|
3478
|
+
return uo(t);
|
|
3322
3479
|
},
|
|
3323
3480
|
renderToolbar(t, e) {
|
|
3324
|
-
const o =
|
|
3481
|
+
const o = Ct(this.toolId, e), n = {
|
|
3325
3482
|
toolId: this.toolId,
|
|
3326
3483
|
label: this.name,
|
|
3327
3484
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3330,7 +3487,7 @@ var kl = [
|
|
|
3330
3487
|
tooltip: "Highlight",
|
|
3331
3488
|
onClick: () => e.toggleTool(this.toolId),
|
|
3332
3489
|
active: o.isActive()
|
|
3333
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3490
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3334
3491
|
return r.setAttribute("tool-id", o.fullToolId), {
|
|
3335
3492
|
toolId: this.toolId,
|
|
3336
3493
|
button: n,
|
|
@@ -3339,7 +3496,7 @@ var kl = [
|
|
|
3339
3496
|
mount: "after-buttons"
|
|
3340
3497
|
}],
|
|
3341
3498
|
sync: () => {
|
|
3342
|
-
|
|
3499
|
+
Et({
|
|
3343
3500
|
button: n,
|
|
3344
3501
|
overlay: r,
|
|
3345
3502
|
isActive: o.isActive,
|
|
@@ -3371,10 +3528,10 @@ var kl = [
|
|
|
3371
3528
|
"trackingGuide"
|
|
3372
3529
|
],
|
|
3373
3530
|
isVisibleInContext(t) {
|
|
3374
|
-
return
|
|
3531
|
+
return uo(t);
|
|
3375
3532
|
},
|
|
3376
3533
|
renderToolbar(t, e) {
|
|
3377
|
-
const o =
|
|
3534
|
+
const o = Ct(this.toolId, e), n = {
|
|
3378
3535
|
toolId: this.toolId,
|
|
3379
3536
|
label: this.name,
|
|
3380
3537
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3383,8 +3540,8 @@ var kl = [
|
|
|
3383
3540
|
tooltip: "Line Reader",
|
|
3384
3541
|
onClick: () => e.toggleTool(this.toolId),
|
|
3385
3542
|
active: o.isActive()
|
|
3386
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3387
|
-
return r.setAttribute("tool-id", o.fullToolId),
|
|
3543
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3544
|
+
return r.setAttribute("tool-id", o.fullToolId), Do(r, "frameless"), {
|
|
3388
3545
|
toolId: this.toolId,
|
|
3389
3546
|
button: n,
|
|
3390
3547
|
elements: [{
|
|
@@ -3392,7 +3549,7 @@ var kl = [
|
|
|
3392
3549
|
mount: "after-buttons"
|
|
3393
3550
|
}],
|
|
3394
3551
|
sync: () => {
|
|
3395
|
-
|
|
3552
|
+
Et({
|
|
3396
3553
|
button: n,
|
|
3397
3554
|
overlay: r,
|
|
3398
3555
|
isActive: o.isActive
|
|
@@ -3421,7 +3578,7 @@ var kl = [
|
|
|
3421
3578
|
return !0;
|
|
3422
3579
|
},
|
|
3423
3580
|
renderToolbar(t, e) {
|
|
3424
|
-
const o =
|
|
3581
|
+
const o = Ct(this.toolId, e), n = {
|
|
3425
3582
|
toolId: this.toolId,
|
|
3426
3583
|
label: this.name,
|
|
3427
3584
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3430,7 +3587,7 @@ var kl = [
|
|
|
3430
3587
|
tooltip: "Theme",
|
|
3431
3588
|
onClick: () => e.toggleTool(this.toolId),
|
|
3432
3589
|
active: o.isActive()
|
|
3433
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3590
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3434
3591
|
return r.setAttribute("tool-id", o.fullToolId), {
|
|
3435
3592
|
toolId: this.toolId,
|
|
3436
3593
|
button: n,
|
|
@@ -3449,7 +3606,7 @@ var kl = [
|
|
|
3449
3606
|
}
|
|
3450
3607
|
}],
|
|
3451
3608
|
sync: () => {
|
|
3452
|
-
|
|
3609
|
+
Et({
|
|
3453
3610
|
button: n,
|
|
3454
3611
|
overlay: r,
|
|
3455
3612
|
isActive: o.isActive
|
|
@@ -3480,10 +3637,10 @@ var kl = [
|
|
|
3480
3637
|
"annotation"
|
|
3481
3638
|
],
|
|
3482
3639
|
isVisibleInContext(t) {
|
|
3483
|
-
return
|
|
3640
|
+
return uo(t);
|
|
3484
3641
|
},
|
|
3485
3642
|
renderToolbar(t, e) {
|
|
3486
|
-
const o =
|
|
3643
|
+
const o = Ct(this.toolId, e), n = {
|
|
3487
3644
|
toolId: this.toolId,
|
|
3488
3645
|
label: this.name,
|
|
3489
3646
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3492,7 +3649,7 @@ var kl = [
|
|
|
3492
3649
|
tooltip: "Highlight",
|
|
3493
3650
|
onClick: () => e.toggleTool(this.toolId),
|
|
3494
3651
|
active: o.isActive()
|
|
3495
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3652
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3496
3653
|
return r.setAttribute("tool-id", o.fullToolId), {
|
|
3497
3654
|
toolId: this.toolId,
|
|
3498
3655
|
button: n,
|
|
@@ -3501,7 +3658,7 @@ var kl = [
|
|
|
3501
3658
|
mount: "after-buttons"
|
|
3502
3659
|
}],
|
|
3503
3660
|
sync: () => {
|
|
3504
|
-
|
|
3661
|
+
Et({
|
|
3505
3662
|
button: n,
|
|
3506
3663
|
overlay: r,
|
|
3507
3664
|
isActive: o.isActive
|
|
@@ -3524,10 +3681,10 @@ var kl = [
|
|
|
3524
3681
|
"graphingTool"
|
|
3525
3682
|
],
|
|
3526
3683
|
isVisibleInContext(t) {
|
|
3527
|
-
return
|
|
3684
|
+
return co(t);
|
|
3528
3685
|
},
|
|
3529
3686
|
renderToolbar(t, e) {
|
|
3530
|
-
const o =
|
|
3687
|
+
const o = Ct(this.toolId, e), n = {
|
|
3531
3688
|
toolId: this.toolId,
|
|
3532
3689
|
label: this.name,
|
|
3533
3690
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3536,7 +3693,7 @@ var kl = [
|
|
|
3536
3693
|
tooltip: "Graph",
|
|
3537
3694
|
onClick: () => e.toggleTool(this.toolId),
|
|
3538
3695
|
active: o.isActive()
|
|
3539
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3696
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3540
3697
|
return r.setAttribute("tool-id", o.fullToolId), {
|
|
3541
3698
|
toolId: this.toolId,
|
|
3542
3699
|
button: n,
|
|
@@ -3555,7 +3712,7 @@ var kl = [
|
|
|
3555
3712
|
}
|
|
3556
3713
|
}],
|
|
3557
3714
|
sync: () => {
|
|
3558
|
-
|
|
3715
|
+
Et({
|
|
3559
3716
|
button: n,
|
|
3560
3717
|
overlay: r,
|
|
3561
3718
|
isActive: o.isActive
|
|
@@ -3577,10 +3734,10 @@ var kl = [
|
|
|
3577
3734
|
"elementReference"
|
|
3578
3735
|
],
|
|
3579
3736
|
isVisibleInContext(t) {
|
|
3580
|
-
return
|
|
3737
|
+
return Ia(t);
|
|
3581
3738
|
},
|
|
3582
3739
|
renderToolbar(t, e) {
|
|
3583
|
-
const o =
|
|
3740
|
+
const o = Ct(this.toolId, e), n = {
|
|
3584
3741
|
toolId: this.toolId,
|
|
3585
3742
|
label: this.name,
|
|
3586
3743
|
icon: typeof this.icon == "function" ? this.icon(t) : this.icon,
|
|
@@ -3589,7 +3746,7 @@ var kl = [
|
|
|
3589
3746
|
tooltip: "Periodic Table",
|
|
3590
3747
|
onClick: () => e.toggleTool(this.toolId),
|
|
3591
3748
|
active: o.isActive()
|
|
3592
|
-
}, i = e.componentOverrides ?? {}, r =
|
|
3749
|
+
}, i = e.componentOverrides ?? {}, r = yt(this.toolId, t, e, i);
|
|
3593
3750
|
return r.setAttribute("tool-id", o.fullToolId), {
|
|
3594
3751
|
toolId: this.toolId,
|
|
3595
3752
|
button: n,
|
|
@@ -3608,7 +3765,7 @@ var kl = [
|
|
|
3608
3765
|
}
|
|
3609
3766
|
}],
|
|
3610
3767
|
sync: () => {
|
|
3611
|
-
|
|
3768
|
+
Et({
|
|
3612
3769
|
button: n,
|
|
3613
3770
|
overlay: r,
|
|
3614
3771
|
isActive: o.isActive
|
|
@@ -3619,36 +3776,36 @@ var kl = [
|
|
|
3619
3776
|
}
|
|
3620
3777
|
}
|
|
3621
3778
|
];
|
|
3622
|
-
function
|
|
3623
|
-
const e = new
|
|
3779
|
+
function Ba(t = {}) {
|
|
3780
|
+
const e = new ba(), o = {
|
|
3624
3781
|
toolTagMap: {
|
|
3625
|
-
...
|
|
3782
|
+
...fr,
|
|
3626
3783
|
...t.toolTagMap || {}
|
|
3627
3784
|
},
|
|
3628
3785
|
toolComponentFactory: t.toolComponentFactory,
|
|
3629
3786
|
toolComponentFactories: t.toolComponentFactories
|
|
3630
3787
|
}, n = (i) => t.overrides?.[i.toolId] || i;
|
|
3631
|
-
return t.includePackagedTools &&
|
|
3788
|
+
return t.includePackagedTools && Fa(e, {
|
|
3632
3789
|
toolIds: t.toolIds,
|
|
3633
3790
|
applyOverrides: n
|
|
3634
3791
|
}), t.toolModuleLoaders && Object.keys(t.toolModuleLoaders).length > 0 && e.setToolModuleLoaders(t.toolModuleLoaders), e.setComponentOverrides(o), e;
|
|
3635
3792
|
}
|
|
3636
|
-
function
|
|
3793
|
+
function Fa(t, e = {}) {
|
|
3637
3794
|
const o = e.toolIds && e.toolIds.length > 0 ? new Set(e.toolIds) : null, n = e.applyOverrides || ((i) => i);
|
|
3638
|
-
for (const i of
|
|
3795
|
+
for (const i of Ha) o && !o.has(i.toolId) || t.register(n(i));
|
|
3639
3796
|
}
|
|
3640
|
-
function
|
|
3641
|
-
return
|
|
3797
|
+
function Ga(t = {}) {
|
|
3798
|
+
return Ba({
|
|
3642
3799
|
...t,
|
|
3643
3800
|
includePackagedTools: !0
|
|
3644
3801
|
});
|
|
3645
3802
|
}
|
|
3646
|
-
function
|
|
3647
|
-
const t =
|
|
3803
|
+
function Ua() {
|
|
3804
|
+
const t = Ga(), e = /* @__PURE__ */ new Set();
|
|
3648
3805
|
for (const o of t.getAllTools()) for (const n of o.pnpSupportIds || []) e.add(n);
|
|
3649
3806
|
return [...e].sort();
|
|
3650
3807
|
}
|
|
3651
|
-
[...
|
|
3808
|
+
[...Ua()];
|
|
3652
3809
|
Object.values({
|
|
3653
3810
|
visual: {
|
|
3654
3811
|
magnification: "magnification",
|
|
@@ -3763,16 +3920,28 @@ Object.values({
|
|
|
3763
3920
|
tutorialAvailable: "tutorialAvailable"
|
|
3764
3921
|
}
|
|
3765
3922
|
}).flatMap((t) => Object.values(t));
|
|
3766
|
-
|
|
3767
|
-
var
|
|
3923
|
+
cr("ToolCoordinator");
|
|
3924
|
+
var si;
|
|
3768
3925
|
(function(t) {
|
|
3769
3926
|
t[t.BASE = 0] = "BASE", t[t.TOOL = 1e3] = "TOOL", t[t.MODAL = 2e3] = "MODAL", t[t.CONTROL = 3e3] = "CONTROL", t[t.HIGHLIGHT = 4e3] = "HIGHLIGHT";
|
|
3770
|
-
})(
|
|
3771
|
-
var
|
|
3927
|
+
})(si || (si = {}));
|
|
3928
|
+
var ai;
|
|
3772
3929
|
(function(t) {
|
|
3773
3930
|
t.IDLE = "idle", t.LOADING = "loading", t.PLAYING = "playing", t.PAUSED = "paused", t.ERROR = "error";
|
|
3774
|
-
})(
|
|
3775
|
-
|
|
3931
|
+
})(ai || (ai = {}));
|
|
3932
|
+
pa({
|
|
3933
|
+
policy: {
|
|
3934
|
+
allowed: [],
|
|
3935
|
+
blocked: []
|
|
3936
|
+
},
|
|
3937
|
+
placement: {
|
|
3938
|
+
section: [],
|
|
3939
|
+
item: [],
|
|
3940
|
+
passage: []
|
|
3941
|
+
},
|
|
3942
|
+
providers: {}
|
|
3943
|
+
});
|
|
3944
|
+
var Ja = /* @__PURE__ */ he('<button class="pie-tool-annotation-toolbar__highlight-swatch svelte-g8qu62"><span class="pie-sr-only svelte-g8qu62"> </span></button>'), Ka = /* @__PURE__ */ he('<div class="divider divider-horizontal mx-0 w-px svelte-g8qu62"></div> <button class="pie-tool-annotation-toolbar__button pie-tool-annotation-toolbar__button--icon svelte-g8qu62" aria-label="Read selected text aloud" title="Read Aloud"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="18" height="18" fill="currentColor" aria-hidden="true" class="svelte-g8qu62"><path d="M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z"></path></svg></button>', 1), Za = /* @__PURE__ */ he('<button class="pie-tool-annotation-toolbar__button pie-tool-annotation-toolbar__button--warning svelte-g8qu62" aria-label="Remove this annotation" title="Remove"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="18" height="18" fill="currentColor" aria-hidden="true" class="svelte-g8qu62"><path d="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z"></path></svg></button>'), Ya = /* @__PURE__ */ he('<button class="pie-tool-annotation-toolbar__button pie-tool-annotation-toolbar__button--danger svelte-g8qu62" aria-label="Clear all annotations from document" title="Clear All">Clear All</button>'), Xa = /* @__PURE__ */ he('<div class="divider divider-horizontal mx-0 w-px svelte-g8qu62"></div> <!> <!>', 1), Qa = /* @__PURE__ */ he('<div class="pie-tool-annotation-toolbar notranslate svelte-g8qu62" role="toolbar" aria-label="Text annotation toolbar" translate="no"><!> <button class="pie-tool-annotation-toolbar__button pie-tool-annotation-toolbar__button--icon svelte-g8qu62" aria-label="Underline selected text" title="Underline"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="18" height="18" fill="currentColor" aria-hidden="true" class="svelte-g8qu62"><path d="M5,21H19V19H5V21M12,17A6,6 0 0,0 18,11V3H15.5V11A3.5,3.5 0 0,1 12,14.5A3.5,3.5 0 0,1 8.5,11V3H6V11A6,6 0 0,0 12,17Z"></path></svg></button> <!> <!></div>'), tl = /* @__PURE__ */ he('<div style="display: none;" aria-hidden="true"></div> <!> <div role="status" aria-live="polite" aria-atomic="true" class="pie-sr-only svelte-g8qu62"> </div>', 1), el = {
|
|
3776
3945
|
hash: "svelte-g8qu62",
|
|
3777
3946
|
code: `.pie-tool-annotation-toolbar.svelte-g8qu62 {position:fixed;z-index:4200;display:flex;gap:0.25rem;padding:0.5rem;border-radius:0.5rem;background:var(--pie-background, #fff);color:var(--pie-text, #111827);border:1px solid var(--pie-border, #d1d5db);box-shadow:0 10px 25px -8px rgb(0 0 0 / 0.3);user-select:none;}.pie-tool-annotation-toolbar__highlight-swatch.svelte-g8qu62 {width:2.5rem;height:2rem;border:2px solid color-mix(in srgb, var(--pie-border-dark, #111827) 20%, transparent);border-radius:0.375rem;cursor:pointer;transition:all 0.15s ease;display:flex;align-items:center;justify-content:center;padding:0;}.pie-tool-annotation-toolbar__highlight-swatch.svelte-g8qu62:hover {transform:scale(1.1);border-color:color-mix(in srgb, var(--pie-border-dark, #111827) 45%, transparent);box-shadow:0 2px 8px rgb(0 0 0 / 0.15);}.pie-tool-annotation-toolbar__highlight-swatch.svelte-g8qu62:focus-visible {outline:2px solid var(--pie-button-focus-outline, var(--pie-primary, #3f51b5));outline-offset:2px;}.pie-tool-annotation-toolbar.svelte-g8qu62 .divider-horizontal:where(.svelte-g8qu62) {height:auto;width:1px;background-color:color-mix(in srgb, var(--pie-border, #d1d5db) 70%, transparent);}
|
|
3778
3947
|
|
|
@@ -3780,31 +3949,31 @@ var El = /* @__PURE__ */ le('<button class="pie-tool-annotation-toolbar__highlig
|
|
|
3780
3949
|
|
|
3781
3950
|
/* Button styling */.pie-tool-annotation-toolbar__button.svelte-g8qu62 {display:inline-flex;align-items:center;justify-content:center;gap:0.35rem;padding:0.4rem 0.55rem;border:1px solid var(--pie-button-border, #d1d5db);border-radius:0.4rem;background:var(--pie-button-bg, #fff);color:var(--pie-button-color, var(--pie-text, #111827));cursor:pointer;}.pie-tool-annotation-toolbar__button--icon.svelte-g8qu62 {min-width:2rem;min-height:2rem;padding:0.45rem;}.pie-tool-annotation-toolbar__button.svelte-g8qu62:hover {background:var(--pie-button-hover-bg, #f9fafb);color:var(--pie-button-hover-color, var(--pie-text, #111827));border-color:var(--pie-button-hover-border, #9ca3af);}.pie-tool-annotation-toolbar__button.svelte-g8qu62:focus-visible {outline:2px solid var(--pie-button-focus-outline, var(--pie-primary, #3f51b5));outline-offset:2px;}.pie-tool-annotation-toolbar__button.svelte-g8qu62:disabled {opacity:0.6;cursor:not-allowed;}.pie-tool-annotation-toolbar__button--warning.svelte-g8qu62 {color:var(--pie-missing-icon, #92400e);}.pie-tool-annotation-toolbar__button--danger.svelte-g8qu62 {color:var(--pie-incorrect-icon, #b91c1c);}.pie-tool-annotation-toolbar__button.svelte-g8qu62 svg:where(.svelte-g8qu62) {width:18px;height:18px;}`
|
|
3782
3951
|
};
|
|
3783
|
-
function
|
|
3784
|
-
|
|
3785
|
-
let o =
|
|
3786
|
-
const r = typeof window < "u", s = "pie-annotations",
|
|
3952
|
+
function ol(t, e) {
|
|
3953
|
+
vi(e, !0), Fs(t, el);
|
|
3954
|
+
let o = No(e, "enabled", 7, !0), n = No(e, "highlightCoordinator", 7, null), i = No(e, "ttsService", 7, null);
|
|
3955
|
+
const r = typeof window < "u", s = "pie-annotations", a = [
|
|
3787
3956
|
{
|
|
3788
|
-
name:
|
|
3957
|
+
name: Dt.YELLOW,
|
|
3789
3958
|
hex: "#fde995",
|
|
3790
3959
|
label: "Yellow highlight"
|
|
3791
3960
|
},
|
|
3792
3961
|
{
|
|
3793
|
-
name:
|
|
3962
|
+
name: Dt.PINK,
|
|
3794
3963
|
hex: "#ff9fae",
|
|
3795
3964
|
label: "Pink highlight"
|
|
3796
3965
|
},
|
|
3797
3966
|
{
|
|
3798
|
-
name:
|
|
3967
|
+
name: Dt.BLUE,
|
|
3799
3968
|
hex: "#a7e0f6",
|
|
3800
3969
|
label: "Blue highlight"
|
|
3801
3970
|
},
|
|
3802
3971
|
{
|
|
3803
|
-
name:
|
|
3972
|
+
name: Dt.GREEN,
|
|
3804
3973
|
hex: "#a6e1c5",
|
|
3805
3974
|
label: "Green highlight"
|
|
3806
3975
|
}
|
|
3807
|
-
],
|
|
3976
|
+
], u = [
|
|
3808
3977
|
"button",
|
|
3809
3978
|
"input",
|
|
3810
3979
|
"select",
|
|
@@ -3815,7 +3984,7 @@ function Wl(t, e) {
|
|
|
3815
3984
|
'[role="button"]',
|
|
3816
3985
|
'[role="textbox"]'
|
|
3817
3986
|
];
|
|
3818
|
-
let
|
|
3987
|
+
let l = /* @__PURE__ */ W(null), d = /* @__PURE__ */ W(null), h = /* @__PURE__ */ W(null), f = /* @__PURE__ */ W(null), v = /* @__PURE__ */ W(Yt({
|
|
3819
3988
|
isVisible: !1,
|
|
3820
3989
|
selectedText: "",
|
|
3821
3990
|
selectedRange: null,
|
|
@@ -3823,86 +3992,86 @@ function Wl(t, e) {
|
|
|
3823
3992
|
x: 0,
|
|
3824
3993
|
y: 0
|
|
3825
3994
|
}
|
|
3826
|
-
})), m = /* @__PURE__ */
|
|
3995
|
+
})), m = /* @__PURE__ */ W(!1), k = /* @__PURE__ */ W(!1), p = /* @__PURE__ */ W(""), w = /* @__PURE__ */ W(0), R = /* @__PURE__ */ W(null), A = /* @__PURE__ */ Eo(() => g(w) > 0), O = /* @__PURE__ */ Eo(() => g(R) !== null), J = /* @__PURE__ */ Eo(() => g(f)?.scopeElement || g(h)?.scopeElement || null);
|
|
3827
3996
|
function H() {
|
|
3828
|
-
const b = g(
|
|
3829
|
-
return g(
|
|
3997
|
+
const b = g(l)?.ownerDocument;
|
|
3998
|
+
return g(J) || b?.documentElement || document.documentElement;
|
|
3830
3999
|
}
|
|
3831
|
-
function
|
|
3832
|
-
return `${s}:${g(
|
|
4000
|
+
function B() {
|
|
4001
|
+
return `${s}:${g(h)?.canonicalItemId || g(h)?.itemId || "global"}`;
|
|
3833
4002
|
}
|
|
3834
|
-
function
|
|
4003
|
+
function gt(b) {
|
|
3835
4004
|
if (!n()) return null;
|
|
3836
|
-
const
|
|
3837
|
-
for (const
|
|
3838
|
-
const
|
|
3839
|
-
if (
|
|
4005
|
+
const T = n().getAnnotations();
|
|
4006
|
+
for (const M of T) {
|
|
4007
|
+
const st = b.compareBoundaryPoints(Range.START_TO_START, M.range), Ft = b.compareBoundaryPoints(Range.END_TO_END, M.range), Se = b.compareBoundaryPoints(Range.START_TO_END, M.range), xo = b.compareBoundaryPoints(Range.END_TO_START, M.range);
|
|
4008
|
+
if (st >= 0 && Ft <= 0 || st <= 0 && Ft >= 0 || Se > 0 && xo < 0) return M.id;
|
|
3840
4009
|
}
|
|
3841
4010
|
return null;
|
|
3842
4011
|
}
|
|
3843
4012
|
function K(b) {
|
|
3844
4013
|
if (b.nodeType !== Node.ELEMENT_NODE && b.nodeType !== Node.TEXT_NODE) return !1;
|
|
3845
|
-
const
|
|
3846
|
-
return
|
|
4014
|
+
const T = b.nodeType === Node.TEXT_NODE ? b.parentElement : b;
|
|
4015
|
+
return T ? !u.some((M) => {
|
|
3847
4016
|
try {
|
|
3848
|
-
return
|
|
4017
|
+
return T.closest(M) !== null;
|
|
3849
4018
|
} catch {
|
|
3850
4019
|
return !1;
|
|
3851
4020
|
}
|
|
3852
4021
|
}) : !1;
|
|
3853
4022
|
}
|
|
3854
|
-
function
|
|
3855
|
-
if (!g(
|
|
3856
|
-
const
|
|
3857
|
-
return !!
|
|
4023
|
+
function mt(b) {
|
|
4024
|
+
if (!g(J)) return !0;
|
|
4025
|
+
const T = b.commonAncestorContainer, M = T.nodeType === Node.TEXT_NODE ? T.parentElement : T;
|
|
4026
|
+
return !!M && g(J).contains(M);
|
|
3858
4027
|
}
|
|
3859
|
-
function
|
|
4028
|
+
function He() {
|
|
3860
4029
|
if (!(!r || !n())) try {
|
|
3861
|
-
const b = H(),
|
|
3862
|
-
sessionStorage.setItem(
|
|
4030
|
+
const b = H(), T = n().exportAnnotations(b);
|
|
4031
|
+
sessionStorage.setItem(B(), JSON.stringify(T));
|
|
3863
4032
|
} catch (b) {
|
|
3864
4033
|
console.error("[AnnotationToolbar] Failed to save annotations:", b);
|
|
3865
4034
|
}
|
|
3866
4035
|
}
|
|
3867
|
-
function
|
|
4036
|
+
function mr() {
|
|
3868
4037
|
if (!(!r || !n())) try {
|
|
3869
|
-
const b = sessionStorage.getItem(
|
|
4038
|
+
const b = sessionStorage.getItem(B());
|
|
3870
4039
|
if (!b) return;
|
|
3871
|
-
const
|
|
3872
|
-
console.log(`[AnnotationToolbar] Restored ${
|
|
4040
|
+
const T = JSON.parse(b), M = H(), st = n().importAnnotations(T, M);
|
|
4041
|
+
console.log(`[AnnotationToolbar] Restored ${st} annotations`), C(w, n().getAnnotations().length, !0);
|
|
3873
4042
|
} catch (b) {
|
|
3874
4043
|
console.error("[AnnotationToolbar] Failed to load annotations:", b);
|
|
3875
4044
|
}
|
|
3876
4045
|
}
|
|
3877
|
-
function
|
|
4046
|
+
function Be() {
|
|
3878
4047
|
if (!o() || !r) return;
|
|
3879
4048
|
const b = window.getSelection();
|
|
3880
|
-
if (!b || b.rangeCount === 0) return
|
|
3881
|
-
const
|
|
3882
|
-
if (!
|
|
3883
|
-
const
|
|
3884
|
-
|
|
3885
|
-
x:
|
|
3886
|
-
y:
|
|
3887
|
-
},
|
|
3888
|
-
|
|
3889
|
-
}, 2e3),
|
|
3890
|
-
|
|
4049
|
+
if (!b || b.rangeCount === 0) return xt();
|
|
4050
|
+
const T = b.getRangeAt(0), M = b.toString().trim();
|
|
4051
|
+
if (!M || !mt(T) || !K(T.commonAncestorContainer)) return xt();
|
|
4052
|
+
const st = T.getBoundingClientRect(), Ft = st.left + st.width / 2, Se = st.top - 8;
|
|
4053
|
+
C(R, gt(T), !0), g(v).isVisible = !0, g(v).selectedText = M, g(v).selectedRange = T.cloneRange(), g(v).toolbarPosition = {
|
|
4054
|
+
x: Ft,
|
|
4055
|
+
y: Se
|
|
4056
|
+
}, C(p, `Annotation toolbar opened for "${M.length > 30 ? M.substring(0, 30) + "..." : M}"`), setTimeout(() => {
|
|
4057
|
+
C(p, "");
|
|
4058
|
+
}, 2e3), C(k, !0), setTimeout(() => {
|
|
4059
|
+
C(k, !1);
|
|
3891
4060
|
}, 100);
|
|
3892
4061
|
}
|
|
3893
|
-
function
|
|
3894
|
-
g(m) && i() && (i().stop(),
|
|
4062
|
+
function xt() {
|
|
4063
|
+
g(m) && i() && (i().stop(), C(m, !1)), g(v).isVisible = !1, g(v).selectedText = "", g(v).selectedRange = null;
|
|
3895
4064
|
}
|
|
3896
|
-
function
|
|
4065
|
+
function An(b) {
|
|
3897
4066
|
if (!g(v).selectedRange || !n()) return;
|
|
3898
|
-
const
|
|
3899
|
-
n().addAnnotation(g(v).selectedRange, b),
|
|
3900
|
-
const
|
|
3901
|
-
|
|
3902
|
-
|
|
3903
|
-
}, 3e3),
|
|
3904
|
-
}
|
|
3905
|
-
function
|
|
4067
|
+
const T = g(v).selectedText;
|
|
4068
|
+
n().addAnnotation(g(v).selectedRange, b), C(w, n().getAnnotations().length, !0), He();
|
|
4069
|
+
const M = b === Dt.UNDERLINE ? "underlined" : `highlighted in ${b}`;
|
|
4070
|
+
C(p, `"${T.length > 30 ? T.substring(0, 30) + "..." : T}" ${M}`), setTimeout(() => {
|
|
4071
|
+
C(p, "");
|
|
4072
|
+
}, 3e3), xt();
|
|
4073
|
+
}
|
|
4074
|
+
function br() {
|
|
3906
4075
|
if (!g(R) || !n()) {
|
|
3907
4076
|
console.warn("[AnnotationToolbar] No overlapping annotation to remove");
|
|
3908
4077
|
return;
|
|
@@ -3913,120 +4082,120 @@ function Wl(t, e) {
|
|
|
3913
4082
|
console.warn("[AnnotationToolbar] Annotation not found:", g(R));
|
|
3914
4083
|
return;
|
|
3915
4084
|
}
|
|
3916
|
-
const
|
|
4085
|
+
const T = b.range.toString();
|
|
3917
4086
|
n().removeAnnotation(g(R));
|
|
3918
|
-
const
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
}, 3e3),
|
|
4087
|
+
const M = n().getAnnotations().length;
|
|
4088
|
+
C(w, M, !0), console.log("[AnnotationToolbar] Annotations remaining:", M), He(), C(p, `Removed annotation from "${T.length > 30 ? T.substring(0, 30) + "..." : T}"`), setTimeout(() => {
|
|
4089
|
+
C(p, "");
|
|
4090
|
+
}, 3e3), xt();
|
|
3922
4091
|
}
|
|
3923
|
-
function
|
|
4092
|
+
function yr() {
|
|
3924
4093
|
const b = g(w);
|
|
3925
|
-
n()?.clearAnnotations(),
|
|
3926
|
-
|
|
3927
|
-
}, 3e3),
|
|
4094
|
+
n()?.clearAnnotations(), C(w, 0), sessionStorage.removeItem(B()), C(p, `${b} annotation${b === 1 ? "" : "s"} cleared`), setTimeout(() => {
|
|
4095
|
+
C(p, "");
|
|
4096
|
+
}, 3e3), xt();
|
|
3928
4097
|
}
|
|
3929
|
-
async function
|
|
4098
|
+
async function wr() {
|
|
3930
4099
|
if (!(!g(v).selectedRange || !i())) {
|
|
3931
|
-
|
|
4100
|
+
C(m, !0);
|
|
3932
4101
|
try {
|
|
3933
4102
|
console.log("[AnnotationToolbar] Speaking range:", g(v).selectedRange.toString().substring(0, 50)), await i().speakRange(g(v).selectedRange, { contentRoot: H() }), console.log("[AnnotationToolbar] TTS completed successfully");
|
|
3934
4103
|
} catch (b) {
|
|
3935
4104
|
console.error("[AnnotationToolbar] TTS error:", b), alert(`TTS failed: ${b instanceof Error ? b.message : String(b)}`);
|
|
3936
4105
|
} finally {
|
|
3937
|
-
|
|
4106
|
+
C(m, !1);
|
|
3938
4107
|
}
|
|
3939
4108
|
}
|
|
3940
4109
|
}
|
|
3941
|
-
function
|
|
3942
|
-
b.key === "Escape" && g(v).isVisible && (b.preventDefault(),
|
|
4110
|
+
function xn(b) {
|
|
4111
|
+
b.key === "Escape" && g(v).isVisible && (b.preventDefault(), xt());
|
|
3943
4112
|
}
|
|
3944
|
-
function
|
|
3945
|
-
!g(v).isVisible || g(
|
|
4113
|
+
function Fe(b) {
|
|
4114
|
+
!g(v).isVisible || g(k) || g(d) && !g(d).contains(b.target) && xt();
|
|
3946
4115
|
}
|
|
3947
|
-
|
|
4116
|
+
qn(() => {
|
|
3948
4117
|
if (!r) return;
|
|
3949
4118
|
const b = setTimeout(() => {
|
|
3950
|
-
|
|
3951
|
-
}, 2e3),
|
|
3952
|
-
return
|
|
3953
|
-
clearTimeout(b),
|
|
4119
|
+
mr();
|
|
4120
|
+
}, 2e3), T = g(J) || document;
|
|
4121
|
+
return T.addEventListener("mouseup", Be), T.addEventListener("click", Fe), T.addEventListener("touchend", Be), T.addEventListener("touchstart", Fe), document.addEventListener("keydown", xn), window.addEventListener("scroll", xt, !0), () => {
|
|
4122
|
+
clearTimeout(b), T.removeEventListener("mouseup", Be), T.removeEventListener("click", Fe), T.removeEventListener("touchend", Be), T.removeEventListener("touchstart", Fe), document.removeEventListener("keydown", xn), window.removeEventListener("scroll", xt, !0);
|
|
3954
4123
|
};
|
|
3955
|
-
}),
|
|
3956
|
-
if (!g(
|
|
3957
|
-
const b =
|
|
3958
|
-
|
|
3959
|
-
}),
|
|
3960
|
-
|
|
4124
|
+
}), qn(() => {
|
|
4125
|
+
if (!g(l)) return;
|
|
4126
|
+
const b = aa(g(l), (M) => {
|
|
4127
|
+
C(h, M, !0);
|
|
4128
|
+
}), T = la(g(l), (M) => {
|
|
4129
|
+
C(f, M, !0);
|
|
3961
4130
|
});
|
|
3962
4131
|
return () => {
|
|
3963
|
-
|
|
4132
|
+
T(), b();
|
|
3964
4133
|
};
|
|
3965
4134
|
});
|
|
3966
|
-
var
|
|
4135
|
+
var Tr = {
|
|
3967
4136
|
get enabled() {
|
|
3968
4137
|
return o();
|
|
3969
4138
|
},
|
|
3970
4139
|
set enabled(b = !0) {
|
|
3971
|
-
o(b),
|
|
4140
|
+
o(b), io();
|
|
3972
4141
|
},
|
|
3973
4142
|
get highlightCoordinator() {
|
|
3974
4143
|
return n();
|
|
3975
4144
|
},
|
|
3976
4145
|
set highlightCoordinator(b = null) {
|
|
3977
|
-
n(b),
|
|
4146
|
+
n(b), io();
|
|
3978
4147
|
},
|
|
3979
4148
|
get ttsService() {
|
|
3980
4149
|
return i();
|
|
3981
4150
|
},
|
|
3982
4151
|
set ttsService(b = null) {
|
|
3983
|
-
i(b),
|
|
3984
|
-
}
|
|
3985
|
-
},
|
|
3986
|
-
|
|
3987
|
-
var
|
|
3988
|
-
var
|
|
3989
|
-
|
|
3990
|
-
var
|
|
3991
|
-
|
|
3992
|
-
|
|
3993
|
-
}),
|
|
4152
|
+
i(b), io();
|
|
4153
|
+
}
|
|
4154
|
+
}, _n = tl(), Cn = Mo(_n);
|
|
4155
|
+
ti(Cn, (b) => C(l, b), () => g(l));
|
|
4156
|
+
var En = Rt(Cn, 2), Ir = (b) => {
|
|
4157
|
+
var T = Qa(), M = Xe(T);
|
|
4158
|
+
Ds(M, 17, () => a, zs, (at, lt) => {
|
|
4159
|
+
var Z = Ja(), Ge = Xe(Z), _o = Xe(Ge, !0);
|
|
4160
|
+
Ue(Ge), Ue(Z), Qe(() => {
|
|
4161
|
+
Kn(Z, `background-color: ${g(lt).hex ?? ""};`), Zn(Z, "aria-label", g(lt).label), Zn(Z, "title", g(lt).label), Gn(_o, g(lt).label);
|
|
4162
|
+
}), _e("click", Z, () => An(g(lt).name)), zt(at, Z);
|
|
3994
4163
|
});
|
|
3995
|
-
var
|
|
3996
|
-
var
|
|
3997
|
-
|
|
4164
|
+
var st = Rt(M, 2), Ft = Rt(st, 2), Se = (at) => {
|
|
4165
|
+
var lt = Ka(), Z = Rt(Mo(lt), 2);
|
|
4166
|
+
Qe(() => Z.disabled = g(m)), _e("click", Z, wr), zt(at, lt);
|
|
3998
4167
|
};
|
|
3999
|
-
|
|
4000
|
-
i() &&
|
|
4168
|
+
Ee(Ft, (at) => {
|
|
4169
|
+
i() && at(Se);
|
|
4001
4170
|
});
|
|
4002
|
-
var
|
|
4003
|
-
var
|
|
4004
|
-
var
|
|
4005
|
-
|
|
4171
|
+
var xo = Rt(Ft, 2), $r = (at) => {
|
|
4172
|
+
var lt = Xa(), Z = Rt(Mo(lt), 2), Ge = (Gt) => {
|
|
4173
|
+
var Ae = Za();
|
|
4174
|
+
_e("click", Ae, br), zt(Gt, Ae);
|
|
4006
4175
|
};
|
|
4007
|
-
|
|
4008
|
-
g(
|
|
4176
|
+
Ee(Z, (Gt) => {
|
|
4177
|
+
g(O) && Gt(Ge);
|
|
4009
4178
|
});
|
|
4010
|
-
var
|
|
4011
|
-
var
|
|
4012
|
-
|
|
4179
|
+
var _o = Rt(Z, 2), Sr = (Gt) => {
|
|
4180
|
+
var Ae = Ya();
|
|
4181
|
+
_e("click", Ae, yr), zt(Gt, Ae);
|
|
4013
4182
|
};
|
|
4014
|
-
|
|
4015
|
-
g(
|
|
4016
|
-
}),
|
|
4183
|
+
Ee(_o, (Gt) => {
|
|
4184
|
+
g(A) && Gt(Sr);
|
|
4185
|
+
}), zt(at, lt);
|
|
4017
4186
|
};
|
|
4018
|
-
|
|
4019
|
-
(g(
|
|
4020
|
-
}),
|
|
4187
|
+
Ee(xo, (at) => {
|
|
4188
|
+
(g(O) || g(A)) && at($r);
|
|
4189
|
+
}), Ue(T), ti(T, (at) => C(d, at), () => g(d)), Qe(() => Kn(T, `left:${g(v).toolbarPosition.x}px; top:${g(v).toolbarPosition.y}px; transform: translate(-50%, -100%);`)), _e("click", st, () => An(Dt.UNDERLINE)), zt(b, T);
|
|
4021
4190
|
};
|
|
4022
|
-
|
|
4023
|
-
g(v).isVisible && b(
|
|
4191
|
+
Ee(En, (b) => {
|
|
4192
|
+
g(v).isVisible && b(Ir);
|
|
4024
4193
|
});
|
|
4025
|
-
var
|
|
4026
|
-
return
|
|
4194
|
+
var Mn = Rt(En, 2), kr = Xe(Mn, !0);
|
|
4195
|
+
return Ue(Mn), Qe(() => Gn(kr, g(p))), zt(t, _n), gi(Tr);
|
|
4027
4196
|
}
|
|
4028
|
-
|
|
4029
|
-
customElements.define("pie-tool-annotation-toolbar",
|
|
4197
|
+
Ms(["click"]);
|
|
4198
|
+
customElements.define("pie-tool-annotation-toolbar", oa(ol, {
|
|
4030
4199
|
enabled: {
|
|
4031
4200
|
attribute: "enabled",
|
|
4032
4201
|
type: "Boolean"
|