@paroicms/content-loading-plugin 0.1.0 → 0.1.2
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.
|
@@ -2,26 +2,26 @@ const gt = (e, t) => e === t, ge = Symbol("solid-proxy"), Z = {
|
|
|
2
2
|
equals: gt
|
|
3
3
|
};
|
|
4
4
|
let Fe = He;
|
|
5
|
-
const T = 1, z = 2,
|
|
5
|
+
const T = 1, z = 2, je = {
|
|
6
6
|
owned: null,
|
|
7
7
|
cleanups: null,
|
|
8
8
|
context: null,
|
|
9
9
|
owner: null
|
|
10
10
|
};
|
|
11
|
-
var
|
|
11
|
+
var w = null;
|
|
12
12
|
let ue = null, mt = null, b = null, R = null, k = null, re = 0;
|
|
13
13
|
function Be(e, t) {
|
|
14
|
-
const n = b, r =
|
|
14
|
+
const n = b, r = w, o = e.length === 0, i = t === void 0 ? r : t, a = o ? je : {
|
|
15
15
|
owned: null,
|
|
16
16
|
cleanups: null,
|
|
17
17
|
context: i ? i.context : null,
|
|
18
18
|
owner: i
|
|
19
19
|
}, s = o ? e : () => e(() => I(() => oe(a)));
|
|
20
|
-
|
|
20
|
+
w = a, b = null;
|
|
21
21
|
try {
|
|
22
22
|
return N(s, !0);
|
|
23
23
|
} finally {
|
|
24
|
-
b = n,
|
|
24
|
+
b = n, w = r;
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
function x(e, t) {
|
|
@@ -34,7 +34,7 @@ function x(e, t) {
|
|
|
34
34
|
}, r = (o) => (typeof o == "function" && (o = o(n.value)), Ke(n, o));
|
|
35
35
|
return [Ge.bind(n), r];
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function _(e, t, n) {
|
|
38
38
|
const r = $e(e, t, !1, T);
|
|
39
39
|
H(r);
|
|
40
40
|
}
|
|
@@ -52,8 +52,7 @@ function yt(e) {
|
|
|
52
52
|
return N(e, !1);
|
|
53
53
|
}
|
|
54
54
|
function I(e) {
|
|
55
|
-
if (b === null)
|
|
56
|
-
return e();
|
|
55
|
+
if (b === null) return e();
|
|
57
56
|
const t = b;
|
|
58
57
|
b = null;
|
|
59
58
|
try {
|
|
@@ -69,10 +68,8 @@ function K(e, t, n) {
|
|
|
69
68
|
let s;
|
|
70
69
|
if (r) {
|
|
71
70
|
s = Array(e.length);
|
|
72
|
-
for (let l = 0; l < e.length; l++)
|
|
73
|
-
|
|
74
|
-
} else
|
|
75
|
-
s = e();
|
|
71
|
+
for (let l = 0; l < e.length; l++) s[l] = e[l]();
|
|
72
|
+
} else s = e();
|
|
76
73
|
if (i)
|
|
77
74
|
return i = !1, a;
|
|
78
75
|
const c = I(() => t(s, o, a));
|
|
@@ -80,28 +77,28 @@ function K(e, t, n) {
|
|
|
80
77
|
};
|
|
81
78
|
}
|
|
82
79
|
function Me(e) {
|
|
83
|
-
return
|
|
80
|
+
return w === null || (w.cleanups === null ? w.cleanups = [e] : w.cleanups.push(e)), e;
|
|
84
81
|
}
|
|
85
|
-
function
|
|
86
|
-
return
|
|
82
|
+
function De() {
|
|
83
|
+
return w;
|
|
87
84
|
}
|
|
88
85
|
function qe(e, t) {
|
|
89
|
-
const n =
|
|
90
|
-
|
|
86
|
+
const n = w, r = b;
|
|
87
|
+
w = e, b = null;
|
|
91
88
|
try {
|
|
92
89
|
return N(t, !0);
|
|
93
90
|
} catch (o) {
|
|
94
91
|
Ae(o);
|
|
95
92
|
} finally {
|
|
96
|
-
|
|
93
|
+
w = n, b = r;
|
|
97
94
|
}
|
|
98
95
|
}
|
|
99
96
|
function wt(e) {
|
|
100
|
-
const t = b, n =
|
|
97
|
+
const t = b, n = w;
|
|
101
98
|
return Promise.resolve().then(() => {
|
|
102
|
-
b = t,
|
|
99
|
+
b = t, w = n;
|
|
103
100
|
let r;
|
|
104
|
-
return N(e, !1), b =
|
|
101
|
+
return N(e, !1), b = w = null, r ? r.done : void 0;
|
|
105
102
|
});
|
|
106
103
|
}
|
|
107
104
|
function Ve(e, t) {
|
|
@@ -114,7 +111,7 @@ function Ve(e, t) {
|
|
|
114
111
|
}
|
|
115
112
|
function We(e) {
|
|
116
113
|
let t;
|
|
117
|
-
return
|
|
114
|
+
return w && w.context && (t = w.context[e.id]) !== void 0 ? t : e.defaultValue;
|
|
118
115
|
}
|
|
119
116
|
function Se(e) {
|
|
120
117
|
const t = E(e), n = E(() => me(t()));
|
|
@@ -125,8 +122,7 @@ function Se(e) {
|
|
|
125
122
|
}
|
|
126
123
|
function Ge() {
|
|
127
124
|
if (this.sources && this.state)
|
|
128
|
-
if (this.state === T)
|
|
129
|
-
H(this);
|
|
125
|
+
if (this.state === T) H(this);
|
|
130
126
|
else {
|
|
131
127
|
const e = R;
|
|
132
128
|
R = null, N(() => te(this), !1), R = e;
|
|
@@ -149,22 +145,25 @@ function Ke(e, t, n) {
|
|
|
149
145
|
}, !1)), t;
|
|
150
146
|
}
|
|
151
147
|
function H(e) {
|
|
152
|
-
if (!e.fn)
|
|
153
|
-
return;
|
|
148
|
+
if (!e.fn) return;
|
|
154
149
|
oe(e);
|
|
155
150
|
const t = re;
|
|
156
|
-
vt(
|
|
151
|
+
vt(
|
|
152
|
+
e,
|
|
153
|
+
e.value,
|
|
154
|
+
t
|
|
155
|
+
);
|
|
157
156
|
}
|
|
158
157
|
function vt(e, t, n) {
|
|
159
158
|
let r;
|
|
160
|
-
const o =
|
|
161
|
-
b =
|
|
159
|
+
const o = w, i = b;
|
|
160
|
+
b = w = e;
|
|
162
161
|
try {
|
|
163
162
|
r = e.fn(t);
|
|
164
163
|
} catch (a) {
|
|
165
164
|
return e.pure && (e.state = T, e.owned && e.owned.forEach(oe), e.owned = null), e.updatedAt = n + 1, Ae(a);
|
|
166
165
|
} finally {
|
|
167
|
-
b = i,
|
|
166
|
+
b = i, w = o;
|
|
168
167
|
}
|
|
169
168
|
(!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ? Ke(e, r) : e.value = r, e.updatedAt = n);
|
|
170
169
|
}
|
|
@@ -178,19 +177,16 @@ function $e(e, t, n, r = T, o) {
|
|
|
178
177
|
sourceSlots: null,
|
|
179
178
|
cleanups: null,
|
|
180
179
|
value: t,
|
|
181
|
-
owner:
|
|
182
|
-
context:
|
|
180
|
+
owner: w,
|
|
181
|
+
context: w ? w.context : null,
|
|
183
182
|
pure: n
|
|
184
183
|
};
|
|
185
|
-
return
|
|
184
|
+
return w === null || w !== je && (w.owned ? w.owned.push(i) : w.owned = [i]), i;
|
|
186
185
|
}
|
|
187
186
|
function ee(e) {
|
|
188
|
-
if (e.state === 0)
|
|
189
|
-
|
|
190
|
-
if (e.
|
|
191
|
-
return te(e);
|
|
192
|
-
if (e.suspense && I(e.suspense.inFallback))
|
|
193
|
-
return e.suspense.effects.push(e);
|
|
187
|
+
if (e.state === 0) return;
|
|
188
|
+
if (e.state === z) return te(e);
|
|
189
|
+
if (e.suspense && I(e.suspense.inFallback)) return e.suspense.effects.push(e);
|
|
194
190
|
const t = [e];
|
|
195
191
|
for (; (e = e.owner) && (!e.updatedAt || e.updatedAt < re); )
|
|
196
192
|
e.state && t.push(e);
|
|
@@ -203,8 +199,7 @@ function ee(e) {
|
|
|
203
199
|
}
|
|
204
200
|
}
|
|
205
201
|
function N(e, t) {
|
|
206
|
-
if (R)
|
|
207
|
-
return e();
|
|
202
|
+
if (R) return e();
|
|
208
203
|
let n = !1;
|
|
209
204
|
t || (R = []), k ? n = !0 : k = [], re++;
|
|
210
205
|
try {
|
|
@@ -215,14 +210,12 @@ function N(e, t) {
|
|
|
215
210
|
}
|
|
216
211
|
}
|
|
217
212
|
function bt(e) {
|
|
218
|
-
if (R && (He(R), R = null), e)
|
|
219
|
-
return;
|
|
213
|
+
if (R && (He(R), R = null), e) return;
|
|
220
214
|
const t = k;
|
|
221
215
|
k = null, t.length && N(() => Fe(t), !1);
|
|
222
216
|
}
|
|
223
217
|
function He(e) {
|
|
224
|
-
for (let t = 0; t < e.length; t++)
|
|
225
|
-
ee(e[t]);
|
|
218
|
+
for (let t = 0; t < e.length; t++) ee(e[t]);
|
|
226
219
|
}
|
|
227
220
|
function St(e) {
|
|
228
221
|
let t, n = 0;
|
|
@@ -230,8 +223,7 @@ function St(e) {
|
|
|
230
223
|
const r = e[t];
|
|
231
224
|
r.user ? e[n++] = r : ee(r);
|
|
232
225
|
}
|
|
233
|
-
for (t = 0; t < n; t++)
|
|
234
|
-
ee(e[t]);
|
|
226
|
+
for (t = 0; t < n; t++) ee(e[t]);
|
|
235
227
|
}
|
|
236
228
|
function te(e, t) {
|
|
237
229
|
e.state = 0;
|
|
@@ -260,13 +252,11 @@ function oe(e) {
|
|
|
260
252
|
}
|
|
261
253
|
}
|
|
262
254
|
if (e.owned) {
|
|
263
|
-
for (t = e.owned.length - 1; t >= 0; t--)
|
|
264
|
-
oe(e.owned[t]);
|
|
255
|
+
for (t = e.owned.length - 1; t >= 0; t--) oe(e.owned[t]);
|
|
265
256
|
e.owned = null;
|
|
266
257
|
}
|
|
267
258
|
if (e.cleanups) {
|
|
268
|
-
for (t = e.cleanups.length - 1; t >= 0; t--)
|
|
269
|
-
e.cleanups[t]();
|
|
259
|
+
for (t = e.cleanups.length - 1; t >= 0; t--) e.cleanups[t]();
|
|
270
260
|
e.cleanups = null;
|
|
271
261
|
}
|
|
272
262
|
e.state = 0;
|
|
@@ -276,12 +266,11 @@ function $t(e) {
|
|
|
276
266
|
cause: e
|
|
277
267
|
});
|
|
278
268
|
}
|
|
279
|
-
function Ae(e, t =
|
|
269
|
+
function Ae(e, t = w) {
|
|
280
270
|
throw $t(e);
|
|
281
271
|
}
|
|
282
272
|
function me(e) {
|
|
283
|
-
if (typeof e == "function" && !e.length)
|
|
284
|
-
return me(e());
|
|
273
|
+
if (typeof e == "function" && !e.length) return me(e());
|
|
285
274
|
if (Array.isArray(e)) {
|
|
286
275
|
const t = [];
|
|
287
276
|
for (let n = 0; n < e.length; n++) {
|
|
@@ -295,10 +284,13 @@ function me(e) {
|
|
|
295
284
|
function At(e, t) {
|
|
296
285
|
return function(r) {
|
|
297
286
|
let o;
|
|
298
|
-
return
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
287
|
+
return _(
|
|
288
|
+
() => o = I(() => (w.context = {
|
|
289
|
+
...w.context,
|
|
290
|
+
[e]: r.value
|
|
291
|
+
}, Se(() => r.children))),
|
|
292
|
+
void 0
|
|
293
|
+
), o;
|
|
302
294
|
};
|
|
303
295
|
}
|
|
304
296
|
function A(e, t) {
|
|
@@ -337,8 +329,7 @@ function fe(e) {
|
|
|
337
329
|
function Rt() {
|
|
338
330
|
for (let e = 0, t = this.length; e < t; ++e) {
|
|
339
331
|
const n = this[e]();
|
|
340
|
-
if (n !== void 0)
|
|
341
|
-
return n;
|
|
332
|
+
if (n !== void 0) return n;
|
|
342
333
|
}
|
|
343
334
|
}
|
|
344
335
|
function Ct(...e) {
|
|
@@ -348,37 +339,36 @@ function Ct(...e) {
|
|
|
348
339
|
t = t || !!s && ge in s, e[a] = typeof s == "function" ? (t = !0, E(s)) : s;
|
|
349
340
|
}
|
|
350
341
|
if (t)
|
|
351
|
-
return new Proxy(
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
return c;
|
|
342
|
+
return new Proxy(
|
|
343
|
+
{
|
|
344
|
+
get(a) {
|
|
345
|
+
for (let s = e.length - 1; s >= 0; s--) {
|
|
346
|
+
const c = fe(e[s])[a];
|
|
347
|
+
if (c !== void 0) return c;
|
|
348
|
+
}
|
|
349
|
+
},
|
|
350
|
+
has(a) {
|
|
351
|
+
for (let s = e.length - 1; s >= 0; s--)
|
|
352
|
+
if (a in fe(e[s])) return !0;
|
|
353
|
+
return !1;
|
|
354
|
+
},
|
|
355
|
+
keys() {
|
|
356
|
+
const a = [];
|
|
357
|
+
for (let s = 0; s < e.length; s++)
|
|
358
|
+
a.push(...Object.keys(fe(e[s])));
|
|
359
|
+
return [...new Set(a)];
|
|
357
360
|
}
|
|
358
361
|
},
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
if (a in fe(e[s]))
|
|
362
|
-
return !0;
|
|
363
|
-
return !1;
|
|
364
|
-
},
|
|
365
|
-
keys() {
|
|
366
|
-
const a = [];
|
|
367
|
-
for (let s = 0; s < e.length; s++)
|
|
368
|
-
a.push(...Object.keys(fe(e[s])));
|
|
369
|
-
return [...new Set(a)];
|
|
370
|
-
}
|
|
371
|
-
}, Et);
|
|
362
|
+
Et
|
|
363
|
+
);
|
|
372
364
|
const n = {}, r = /* @__PURE__ */ Object.create(null);
|
|
373
365
|
for (let a = e.length - 1; a >= 0; a--) {
|
|
374
366
|
const s = e[a];
|
|
375
|
-
if (!s)
|
|
376
|
-
continue;
|
|
367
|
+
if (!s) continue;
|
|
377
368
|
const c = Object.getOwnPropertyNames(s);
|
|
378
369
|
for (let l = c.length - 1; l >= 0; l--) {
|
|
379
370
|
const u = c[l];
|
|
380
|
-
if (u === "__proto__" || u === "constructor")
|
|
381
|
-
continue;
|
|
371
|
+
if (u === "__proto__" || u === "constructor") continue;
|
|
382
372
|
const h = Object.getOwnPropertyDescriptor(s, u);
|
|
383
373
|
if (!r[u])
|
|
384
374
|
r[u] = h.get ? {
|
|
@@ -404,18 +394,25 @@ function q(e) {
|
|
|
404
394
|
const t = e.keyed, n = E(() => e.when, void 0, {
|
|
405
395
|
equals: (r, o) => t ? r === o : !r == !o
|
|
406
396
|
});
|
|
407
|
-
return E(
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
397
|
+
return E(
|
|
398
|
+
() => {
|
|
399
|
+
const r = n();
|
|
400
|
+
if (r) {
|
|
401
|
+
const o = e.children;
|
|
402
|
+
return typeof o == "function" && o.length > 0 ? I(
|
|
403
|
+
() => o(
|
|
404
|
+
t ? r : () => {
|
|
405
|
+
if (!I(n)) throw Lt("Show");
|
|
406
|
+
return e.when;
|
|
407
|
+
}
|
|
408
|
+
)
|
|
409
|
+
) : o;
|
|
410
|
+
}
|
|
411
|
+
return e.fallback;
|
|
412
|
+
},
|
|
413
|
+
void 0,
|
|
414
|
+
void 0
|
|
415
|
+
);
|
|
419
416
|
}
|
|
420
417
|
function Pt(e, t, n) {
|
|
421
418
|
let r = n.length, o = t.length, i = r, a = 0, s = 0, c = t[o - 1].nextSibling, l = null;
|
|
@@ -428,8 +425,7 @@ function Pt(e, t, n) {
|
|
|
428
425
|
o--, i--;
|
|
429
426
|
if (o === a) {
|
|
430
427
|
const u = i < r ? s ? n[s - 1].nextSibling : n[i - s] : c;
|
|
431
|
-
for (; s < i; )
|
|
432
|
-
e.insertBefore(n[s++], u);
|
|
428
|
+
for (; s < i; ) e.insertBefore(n[s++], u);
|
|
433
429
|
} else if (i === s)
|
|
434
430
|
for (; a < o; )
|
|
435
431
|
(!l || !l.has(t[a])) && t[a].remove(), a++;
|
|
@@ -440,8 +436,7 @@ function Pt(e, t, n) {
|
|
|
440
436
|
if (!l) {
|
|
441
437
|
l = /* @__PURE__ */ new Map();
|
|
442
438
|
let h = s;
|
|
443
|
-
for (; h < i; )
|
|
444
|
-
l.set(n[h], h++);
|
|
439
|
+
for (; h < i; ) l.set(n[h], h++);
|
|
445
440
|
}
|
|
446
441
|
const u = l.get(t[a]);
|
|
447
442
|
if (u != null)
|
|
@@ -450,15 +445,11 @@ function Pt(e, t, n) {
|
|
|
450
445
|
for (; ++h < o && h < i && !((m = l.get(t[h])) == null || m !== u + p); )
|
|
451
446
|
p++;
|
|
452
447
|
if (p > u - s) {
|
|
453
|
-
const
|
|
454
|
-
for (; s < u; )
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
} else
|
|
459
|
-
a++;
|
|
460
|
-
else
|
|
461
|
-
t[a++].remove();
|
|
448
|
+
const y = t[a];
|
|
449
|
+
for (; s < u; ) e.insertBefore(n[s++], y);
|
|
450
|
+
} else e.replaceChild(n[s++], t[a++]);
|
|
451
|
+
} else a++;
|
|
452
|
+
else t[a++].remove();
|
|
462
453
|
}
|
|
463
454
|
}
|
|
464
455
|
}
|
|
@@ -483,7 +474,7 @@ function se(e, t = window.document) {
|
|
|
483
474
|
const n = t[xe] || (t[xe] = /* @__PURE__ */ new Set());
|
|
484
475
|
for (let r = 0, o = e.length; r < o; r++) {
|
|
485
476
|
const i = e[r];
|
|
486
|
-
n.has(i) || (n.add(i), t.addEventListener(i,
|
|
477
|
+
n.has(i) || (n.add(i), t.addEventListener(i, Ot));
|
|
487
478
|
}
|
|
488
479
|
}
|
|
489
480
|
function ie(e, t, n) {
|
|
@@ -496,11 +487,10 @@ function xt(e, t, n) {
|
|
|
496
487
|
return I(() => e(t, n));
|
|
497
488
|
}
|
|
498
489
|
function P(e, t, n, r) {
|
|
499
|
-
if (n !== void 0 && !r && (r = []), typeof t != "function")
|
|
500
|
-
|
|
501
|
-
O((o) => ne(e, t(), o, n), r);
|
|
490
|
+
if (n !== void 0 && !r && (r = []), typeof t != "function") return ne(e, t, r, n);
|
|
491
|
+
_((o) => ne(e, t(), o, n), r);
|
|
502
492
|
}
|
|
503
|
-
function
|
|
493
|
+
function Ot(e) {
|
|
504
494
|
const t = `$$${e.type}`;
|
|
505
495
|
let n = e.composedPath && e.composedPath()[0] || e.target;
|
|
506
496
|
for (e.target !== n && Object.defineProperty(e, "target", {
|
|
@@ -515,53 +505,45 @@ function _t(e) {
|
|
|
515
505
|
const r = n[t];
|
|
516
506
|
if (r && !n.disabled) {
|
|
517
507
|
const o = n[`${t}Data`];
|
|
518
|
-
if (o !== void 0 ? r.call(n, o, e) : r.call(n, e), e.cancelBubble)
|
|
519
|
-
return;
|
|
508
|
+
if (o !== void 0 ? r.call(n, o, e) : r.call(n, e), e.cancelBubble) return;
|
|
520
509
|
}
|
|
521
510
|
n = n._$host || n.parentNode || n.host;
|
|
522
511
|
}
|
|
523
512
|
}
|
|
524
513
|
function ne(e, t, n, r, o) {
|
|
525
|
-
for (; typeof n == "function"; )
|
|
526
|
-
|
|
527
|
-
if (t === n)
|
|
528
|
-
return n;
|
|
514
|
+
for (; typeof n == "function"; ) n = n();
|
|
515
|
+
if (t === n) return n;
|
|
529
516
|
const i = typeof t, a = r !== void 0;
|
|
530
517
|
if (e = a && n[0] && n[0].parentNode || e, i === "string" || i === "number") {
|
|
531
518
|
if (i === "number" && (t = t.toString(), t === n))
|
|
532
519
|
return n;
|
|
533
520
|
if (a) {
|
|
534
521
|
let s = n[0];
|
|
535
|
-
s && s.nodeType === 3 ? s.data !== t && (s.data = t) : s = document.createTextNode(t), n =
|
|
522
|
+
s && s.nodeType === 3 ? s.data !== t && (s.data = t) : s = document.createTextNode(t), n = D(e, n, r, s);
|
|
536
523
|
} else
|
|
537
524
|
n !== "" && typeof n == "string" ? n = e.firstChild.data = t : n = e.textContent = t;
|
|
538
525
|
} else if (t == null || i === "boolean")
|
|
539
|
-
n =
|
|
526
|
+
n = D(e, n, r);
|
|
540
527
|
else {
|
|
541
528
|
if (i === "function")
|
|
542
|
-
return
|
|
529
|
+
return _(() => {
|
|
543
530
|
let s = t();
|
|
544
|
-
for (; typeof s == "function"; )
|
|
545
|
-
s = s();
|
|
531
|
+
for (; typeof s == "function"; ) s = s();
|
|
546
532
|
n = ne(e, s, n, r);
|
|
547
533
|
}), () => n;
|
|
548
534
|
if (Array.isArray(t)) {
|
|
549
535
|
const s = [], c = n && Array.isArray(n);
|
|
550
536
|
if (ye(s, t, n, o))
|
|
551
|
-
return
|
|
537
|
+
return _(() => n = ne(e, s, n, r, !0)), () => n;
|
|
552
538
|
if (s.length === 0) {
|
|
553
|
-
if (n =
|
|
554
|
-
|
|
555
|
-
} else
|
|
556
|
-
c ? n.length === 0 ? _e(e, s, r) : Pt(e, n, s) : (n && j(e), _e(e, s));
|
|
539
|
+
if (n = D(e, n, r), a) return n;
|
|
540
|
+
} else c ? n.length === 0 ? Oe(e, s, r) : Pt(e, n, s) : (n && D(e), Oe(e, s));
|
|
557
541
|
n = s;
|
|
558
542
|
} else if (t.nodeType) {
|
|
559
543
|
if (Array.isArray(n)) {
|
|
560
|
-
if (a)
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
} else
|
|
564
|
-
n == null || n === "" || !e.firstChild ? e.appendChild(t) : e.replaceChild(t, e.firstChild);
|
|
544
|
+
if (a) return n = D(e, n, r, t);
|
|
545
|
+
D(e, n, null, t);
|
|
546
|
+
} else n == null || n === "" || !e.firstChild ? e.appendChild(t) : e.replaceChild(t, e.firstChild);
|
|
565
547
|
n = t;
|
|
566
548
|
}
|
|
567
549
|
}
|
|
@@ -571,32 +553,32 @@ function ye(e, t, n, r) {
|
|
|
571
553
|
let o = !1;
|
|
572
554
|
for (let i = 0, a = t.length; i < a; i++) {
|
|
573
555
|
let s = t[i], c = n && n[e.length], l;
|
|
574
|
-
if (!(s == null || s === !0 || s === !1))
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
else
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
556
|
+
if (!(s == null || s === !0 || s === !1)) if ((l = typeof s) == "object" && s.nodeType)
|
|
557
|
+
e.push(s);
|
|
558
|
+
else if (Array.isArray(s))
|
|
559
|
+
o = ye(e, s, c) || o;
|
|
560
|
+
else if (l === "function")
|
|
561
|
+
if (r) {
|
|
562
|
+
for (; typeof s == "function"; ) s = s();
|
|
563
|
+
o = ye(
|
|
564
|
+
e,
|
|
565
|
+
Array.isArray(s) ? s : [s],
|
|
566
|
+
Array.isArray(c) ? c : [c]
|
|
567
|
+
) || o;
|
|
568
|
+
} else
|
|
569
|
+
e.push(s), o = !0;
|
|
570
|
+
else {
|
|
571
|
+
const u = String(s);
|
|
572
|
+
c && c.nodeType === 3 && c.data === u ? e.push(c) : e.push(document.createTextNode(u));
|
|
573
|
+
}
|
|
590
574
|
}
|
|
591
575
|
return o;
|
|
592
576
|
}
|
|
593
|
-
function
|
|
594
|
-
for (let r = 0, o = t.length; r < o; r++)
|
|
595
|
-
e.insertBefore(t[r], n);
|
|
577
|
+
function Oe(e, t, n = null) {
|
|
578
|
+
for (let r = 0, o = t.length; r < o; r++) e.insertBefore(t[r], n);
|
|
596
579
|
}
|
|
597
|
-
function
|
|
598
|
-
if (n === void 0)
|
|
599
|
-
return e.textContent = "";
|
|
580
|
+
function D(e, t, n, r) {
|
|
581
|
+
if (n === void 0) return e.textContent = "";
|
|
600
582
|
const o = r || document.createTextNode("");
|
|
601
583
|
if (t.length) {
|
|
602
584
|
let i = !1;
|
|
@@ -605,14 +587,12 @@ function j(e, t, n, r) {
|
|
|
605
587
|
if (o !== s) {
|
|
606
588
|
const c = s.parentNode === e;
|
|
607
589
|
!i && !a ? c ? e.replaceChild(o, s) : e.insertBefore(o, n) : c && s.remove();
|
|
608
|
-
} else
|
|
609
|
-
i = !0;
|
|
590
|
+
} else i = !0;
|
|
610
591
|
}
|
|
611
|
-
} else
|
|
612
|
-
e.insertBefore(o, n);
|
|
592
|
+
} else e.insertBefore(o, n);
|
|
613
593
|
return [o];
|
|
614
594
|
}
|
|
615
|
-
const
|
|
595
|
+
const _t = !1;
|
|
616
596
|
function we(e) {
|
|
617
597
|
return e.varName ? ` for '${e.varName}'` : "";
|
|
618
598
|
}
|
|
@@ -642,12 +622,10 @@ function kt(e, t = {}) {
|
|
|
642
622
|
function J(e, t = {}) {
|
|
643
623
|
return e == null ? void 0 : kt(e, t);
|
|
644
624
|
}
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
async function Nt(e) {
|
|
625
|
+
const _e = W(void 0, { varName: "VITE_API_PORT" }), Je = _e ? `//${document.location.hostname}:${_e}/api/plugin/content-loading` : `//${document.location.host}/api/plugin/content-loading`, Ye = "/assets/plugin/content-loading/0.1.1";
|
|
626
|
+
async function Tt(e) {
|
|
648
627
|
const t = `${Je}${e}`, n = await fetch(t);
|
|
649
|
-
if (n.status !== 200)
|
|
650
|
-
throw new Error(`api error ${n.status}`);
|
|
628
|
+
if (n.status !== 200) throw new Error(`api error ${n.status}`);
|
|
651
629
|
return await n.text();
|
|
652
630
|
}
|
|
653
631
|
var Ze = (e) => e != null && (e = Object.getPrototypeOf(e), e === Array.prototype || e === Object.prototype);
|
|
@@ -657,19 +635,19 @@ function ze(e, t, n) {
|
|
|
657
635
|
e[i] = o, Ze(o) && ze(e, o, i);
|
|
658
636
|
}
|
|
659
637
|
}
|
|
660
|
-
function
|
|
638
|
+
function Nt(e) {
|
|
661
639
|
const t = { ...e };
|
|
662
640
|
for (const [n, r] of Object.entries(e))
|
|
663
641
|
Ze(r) && ze(t, r, n);
|
|
664
642
|
return t;
|
|
665
643
|
}
|
|
666
|
-
var
|
|
644
|
+
var Ft = (e, t) => {
|
|
667
645
|
if (t)
|
|
668
646
|
for (const [n, r] of Object.entries(t))
|
|
669
647
|
e = e.replace(new RegExp(`{{\\s*${n}\\s*}}`, "g"), r);
|
|
670
648
|
return e;
|
|
671
|
-
},
|
|
672
|
-
function
|
|
649
|
+
}, jt = (e) => e;
|
|
650
|
+
function Bt(e, t = jt) {
|
|
673
651
|
return (n, ...r) => {
|
|
674
652
|
n[0] === "." && (n = n.slice(1));
|
|
675
653
|
const o = e()?.[n];
|
|
@@ -683,39 +661,38 @@ function Mt(e, t = Bt) {
|
|
|
683
661
|
}
|
|
684
662
|
};
|
|
685
663
|
}
|
|
686
|
-
const
|
|
664
|
+
const Mt = {
|
|
687
665
|
nothingGet: "No results found for",
|
|
688
666
|
search: "Search"
|
|
689
|
-
},
|
|
667
|
+
}, Dt = {
|
|
690
668
|
loadMore: "Load more"
|
|
669
|
+
}, qt = {
|
|
670
|
+
searchApp: Mt,
|
|
671
|
+
infiniteLoading: Dt
|
|
691
672
|
}, Vt = {
|
|
692
|
-
searchApp: jt,
|
|
693
|
-
infiniteLoading: qt
|
|
694
|
-
}, Wt = {
|
|
695
673
|
nothingGet: "Aucun résultat trouvé pour",
|
|
696
674
|
search: "Rechercher"
|
|
697
|
-
},
|
|
675
|
+
}, Wt = {
|
|
698
676
|
loadMore: "Charger la suite"
|
|
699
|
-
},
|
|
700
|
-
searchApp:
|
|
701
|
-
infiniteLoading:
|
|
702
|
-
}, Ie = { en:
|
|
677
|
+
}, Gt = {
|
|
678
|
+
searchApp: Vt,
|
|
679
|
+
infiniteLoading: Wt
|
|
680
|
+
}, Ie = { en: qt, fr: Gt };
|
|
703
681
|
function ae(e) {
|
|
704
682
|
const t = E(() => {
|
|
705
683
|
const r = e in Ie ? e : "en";
|
|
706
|
-
return
|
|
684
|
+
return Nt(Ie[r]);
|
|
707
685
|
});
|
|
708
|
-
return { t:
|
|
686
|
+
return { t: Bt(t, Ft) };
|
|
709
687
|
}
|
|
710
|
-
var
|
|
711
|
-
function
|
|
688
|
+
var Kt = /* @__PURE__ */ C("<button class=InfiniteLoading-btn type=button>"), Ht = /* @__PURE__ */ C("<div class=InfiniteLoading-actionArea>"), Xt = /* @__PURE__ */ C("<img class=InfiniteLoading-spinner width=50 height=50 alt=…>");
|
|
689
|
+
function Qt(e, {
|
|
712
690
|
language: t
|
|
713
691
|
}) {
|
|
714
692
|
const n = J(e.dataset.start), r = J(e.dataset.total), o = J(e.dataset.limit), i = W(e.dataset.parentId), a = W(e.dataset.template), s = W(e.dataset.labeledById);
|
|
715
693
|
if (!(n === void 0 || r === void 0 || i === void 0 || o === void 0 || a === void 0)) {
|
|
716
|
-
if (!t)
|
|
717
|
-
|
|
718
|
-
Yt({
|
|
694
|
+
if (!t) throw new Error("Missing language");
|
|
695
|
+
Jt({
|
|
719
696
|
language: t,
|
|
720
697
|
limit: o,
|
|
721
698
|
parentId: i,
|
|
@@ -727,7 +704,7 @@ function Jt(e, {
|
|
|
727
704
|
});
|
|
728
705
|
}
|
|
729
706
|
}
|
|
730
|
-
function
|
|
707
|
+
function Jt({
|
|
731
708
|
language: e,
|
|
732
709
|
limit: t,
|
|
733
710
|
root: n,
|
|
@@ -741,41 +718,40 @@ function Yt({
|
|
|
741
718
|
t: c
|
|
742
719
|
} = ae(e);
|
|
743
720
|
let l = r;
|
|
744
|
-
if (l >= o)
|
|
745
|
-
return;
|
|
721
|
+
if (l >= o) return;
|
|
746
722
|
const u = (() => {
|
|
747
|
-
var
|
|
748
|
-
return
|
|
723
|
+
var y = Kt();
|
|
724
|
+
return y.$$click = m, P(y, () => c("infiniteLoading.loadMore")), y;
|
|
749
725
|
})(), h = (() => {
|
|
750
|
-
var
|
|
751
|
-
return P(
|
|
726
|
+
var y = Ht();
|
|
727
|
+
return P(y, u), y;
|
|
752
728
|
})(), p = (() => {
|
|
753
|
-
var
|
|
754
|
-
return ie(
|
|
729
|
+
var y = Xt();
|
|
730
|
+
return ie(y, "src", `${Ye}/spinner.svg`), y;
|
|
755
731
|
})();
|
|
756
732
|
n.appendChild(h);
|
|
757
733
|
async function m() {
|
|
758
734
|
n.appendChild(p);
|
|
759
|
-
const
|
|
735
|
+
const y = await Yt({
|
|
760
736
|
limit: t,
|
|
761
737
|
newStart: l,
|
|
762
738
|
parentId: i,
|
|
763
739
|
templateName: a,
|
|
764
740
|
labeledById: s
|
|
765
741
|
});
|
|
766
|
-
for (const f of
|
|
742
|
+
for (const f of y)
|
|
767
743
|
n.insertBefore(f, h);
|
|
768
744
|
l += t, l >= o && h.remove(), p.remove();
|
|
769
745
|
}
|
|
770
746
|
}
|
|
771
|
-
async function
|
|
747
|
+
async function Yt({
|
|
772
748
|
limit: e,
|
|
773
749
|
newStart: t,
|
|
774
750
|
parentId: n,
|
|
775
751
|
templateName: r,
|
|
776
752
|
labeledById: o
|
|
777
753
|
}) {
|
|
778
|
-
const i = o ? `?labeled=${encodeURIComponent(o)}` : "", a = `/partials?templateName=${encodeURIComponent(r)}&children-of=${encodeURIComponent(n)}&start=${encodeURIComponent(t)}&limit=${encodeURIComponent(e)}${i}`, s = await
|
|
754
|
+
const i = o ? `?labeled=${encodeURIComponent(o)}` : "", a = `/partials?templateName=${encodeURIComponent(r)}&children-of=${encodeURIComponent(n)}&start=${encodeURIComponent(t)}&limit=${encodeURIComponent(e)}${i}`, s = await Tt(a), c = document.createElement("div");
|
|
779
755
|
return c.innerHTML = s, [...c.children];
|
|
780
756
|
}
|
|
781
757
|
se(["click"]);
|
|
@@ -814,13 +790,13 @@ function Re() {
|
|
|
814
790
|
(!window.history.state || window.history.state._depth == null) && window.history.replaceState({ ...window.history.state, _depth: window.history.length - 1 }, ""), ve = window.history.state._depth;
|
|
815
791
|
}
|
|
816
792
|
Re();
|
|
817
|
-
function
|
|
793
|
+
function Zt(e) {
|
|
818
794
|
return {
|
|
819
795
|
...e,
|
|
820
796
|
_depth: window.history.state && window.history.state._depth
|
|
821
797
|
};
|
|
822
798
|
}
|
|
823
|
-
function
|
|
799
|
+
function zt(e, t) {
|
|
824
800
|
let n = !1;
|
|
825
801
|
return () => {
|
|
826
802
|
const r = ve;
|
|
@@ -833,24 +809,24 @@ function en(e, t) {
|
|
|
833
809
|
o && t(o) ? (n = !0, window.history.go(-o)) : e();
|
|
834
810
|
};
|
|
835
811
|
}
|
|
836
|
-
const
|
|
812
|
+
const en = /^(?:[a-z0-9]+:)?\/\//i, tn = /^\/+|(\/)\/+$/g, tt = "http://sr";
|
|
837
813
|
function G(e, t = !1) {
|
|
838
|
-
const n = e.replace(
|
|
814
|
+
const n = e.replace(tn, "$1");
|
|
839
815
|
return n ? t || /^[?#]/.test(n) ? n : "/" + n : "";
|
|
840
816
|
}
|
|
841
817
|
function Y(e, t, n) {
|
|
842
|
-
if (
|
|
818
|
+
if (en.test(t))
|
|
843
819
|
return;
|
|
844
820
|
const r = G(e), o = n && G(n);
|
|
845
821
|
let i = "";
|
|
846
822
|
return !o || t.startsWith("/") ? i = r : o.toLowerCase().indexOf(r.toLowerCase()) !== 0 ? i = r + o : i = o, (i || "/") + G(t, !i);
|
|
847
823
|
}
|
|
848
|
-
function
|
|
824
|
+
function nn(e, t) {
|
|
849
825
|
if (e == null)
|
|
850
826
|
throw new Error(t);
|
|
851
827
|
return e;
|
|
852
828
|
}
|
|
853
|
-
function
|
|
829
|
+
function rn(e, t) {
|
|
854
830
|
return G(e).replace(/\/*(\*.*)?$/g, "") + G(t);
|
|
855
831
|
}
|
|
856
832
|
function nt(e) {
|
|
@@ -859,7 +835,7 @@ function nt(e) {
|
|
|
859
835
|
t[r] = n;
|
|
860
836
|
}), t;
|
|
861
837
|
}
|
|
862
|
-
function
|
|
838
|
+
function on(e, t, n) {
|
|
863
839
|
const [r, o] = e.split("/*", 2), i = r.split("/").filter(Boolean), a = i.length;
|
|
864
840
|
return (s) => {
|
|
865
841
|
const c = s.split("/").filter(Boolean), l = c.length - a;
|
|
@@ -870,12 +846,12 @@ function sn(e, t, n) {
|
|
|
870
846
|
params: {}
|
|
871
847
|
}, h = (p) => n === void 0 ? void 0 : n[p];
|
|
872
848
|
for (let p = 0; p < a; p++) {
|
|
873
|
-
const m = i[p],
|
|
874
|
-
if (f && he(
|
|
875
|
-
u.params[d] =
|
|
876
|
-
else if (f || !he(
|
|
849
|
+
const m = i[p], y = c[p], f = m[0] === ":", d = f ? m.slice(1) : m;
|
|
850
|
+
if (f && he(y, h(d)))
|
|
851
|
+
u.params[d] = y;
|
|
852
|
+
else if (f || !he(y, m))
|
|
877
853
|
return null;
|
|
878
|
-
u.path += `/${
|
|
854
|
+
u.path += `/${y}`;
|
|
879
855
|
}
|
|
880
856
|
if (o) {
|
|
881
857
|
const p = l ? c.slice(-l).join("/") : "";
|
|
@@ -891,12 +867,12 @@ function he(e, t) {
|
|
|
891
867
|
const n = (r) => r.localeCompare(e, void 0, { sensitivity: "base" }) === 0;
|
|
892
868
|
return t === void 0 ? !0 : typeof t == "string" ? n(t) : typeof t == "function" ? t(e) : Array.isArray(t) ? t.some(n) : t instanceof RegExp ? t.test(e) : !1;
|
|
893
869
|
}
|
|
894
|
-
function
|
|
870
|
+
function sn(e) {
|
|
895
871
|
const [t, n] = e.pattern.split("/*", 2), r = t.split("/").filter(Boolean);
|
|
896
872
|
return r.reduce((o, i) => o + (i.startsWith(":") ? 2 : 3), r.length - (n === void 0 ? 0 : 1));
|
|
897
873
|
}
|
|
898
874
|
function rt(e) {
|
|
899
|
-
const t = /* @__PURE__ */ new Map(), n =
|
|
875
|
+
const t = /* @__PURE__ */ new Map(), n = De();
|
|
900
876
|
return new Proxy({}, {
|
|
901
877
|
get(r, o) {
|
|
902
878
|
return t.has(o) || qe(n, () => t.set(o, E(() => e()[o]))), t.get(o)();
|
|
@@ -922,32 +898,32 @@ function ot(e) {
|
|
|
922
898
|
o.push(n += t[1]), r = r.slice(t[0].length);
|
|
923
899
|
return ot(r).reduce((i, a) => [...i, ...o.map((s) => s + a)], []);
|
|
924
900
|
}
|
|
925
|
-
const
|
|
926
|
-
function
|
|
927
|
-
const { component: n,
|
|
901
|
+
const an = 100, st = Ve(), it = Ve(), Ce = () => nn(We(st), "<A> and 'use' router primitives can be only used inside a Route."), at = () => Ce().navigatorFactory(), ln = () => Ce().location, cn = () => Ce().params;
|
|
902
|
+
function un(e, t = "") {
|
|
903
|
+
const { component: n, preload: r, load: o, children: i, info: a } = e, s = !i || Array.isArray(i) && !i.length, c = {
|
|
928
904
|
key: e,
|
|
929
905
|
component: n,
|
|
930
|
-
|
|
931
|
-
info:
|
|
906
|
+
preload: r || o,
|
|
907
|
+
info: a
|
|
932
908
|
};
|
|
933
|
-
return lt(e.path).reduce((
|
|
934
|
-
for (const
|
|
935
|
-
const
|
|
936
|
-
let
|
|
937
|
-
|
|
938
|
-
...
|
|
939
|
-
originalPath:
|
|
940
|
-
pattern:
|
|
941
|
-
matcher:
|
|
909
|
+
return lt(e.path).reduce((l, u) => {
|
|
910
|
+
for (const h of ot(u)) {
|
|
911
|
+
const p = rn(t, h);
|
|
912
|
+
let m = s ? p : p.split("/*", 1)[0];
|
|
913
|
+
m = m.split("/").map((y) => y.startsWith(":") || y.startsWith("*") ? y : encodeURIComponent(y)).join("/"), l.push({
|
|
914
|
+
...c,
|
|
915
|
+
originalPath: u,
|
|
916
|
+
pattern: m,
|
|
917
|
+
matcher: on(m, !s, e.matchFilters)
|
|
942
918
|
});
|
|
943
919
|
}
|
|
944
|
-
return
|
|
920
|
+
return l;
|
|
945
921
|
}, []);
|
|
946
922
|
}
|
|
947
|
-
function
|
|
923
|
+
function fn(e, t = 0) {
|
|
948
924
|
return {
|
|
949
925
|
routes: e,
|
|
950
|
-
score:
|
|
926
|
+
score: sn(e[e.length - 1]) * 1e4 - t,
|
|
951
927
|
matcher(n) {
|
|
952
928
|
const r = [];
|
|
953
929
|
for (let o = e.length - 1; o >= 0; o--) {
|
|
@@ -972,14 +948,14 @@ function ct(e, t = "", n = [], r = []) {
|
|
|
972
948
|
const s = o[i];
|
|
973
949
|
if (s && typeof s == "object") {
|
|
974
950
|
s.hasOwnProperty("path") || (s.path = "");
|
|
975
|
-
const c =
|
|
951
|
+
const c = un(s, t);
|
|
976
952
|
for (const l of c) {
|
|
977
953
|
n.push(l);
|
|
978
954
|
const u = Array.isArray(s.children) && s.children.length === 0;
|
|
979
955
|
if (s.children && !u)
|
|
980
956
|
ct(s.children, l.pattern, n, r);
|
|
981
957
|
else {
|
|
982
|
-
const h =
|
|
958
|
+
const h = fn([...n], r.length);
|
|
983
959
|
r.push(h);
|
|
984
960
|
}
|
|
985
961
|
n.pop();
|
|
@@ -996,7 +972,7 @@ function de(e, t) {
|
|
|
996
972
|
}
|
|
997
973
|
return [];
|
|
998
974
|
}
|
|
999
|
-
function
|
|
975
|
+
function hn(e, t) {
|
|
1000
976
|
const n = new URL(tt), r = E((c) => {
|
|
1001
977
|
const l = e();
|
|
1002
978
|
try {
|
|
@@ -1027,38 +1003,38 @@ function dn(e, t) {
|
|
|
1027
1003
|
};
|
|
1028
1004
|
}
|
|
1029
1005
|
let B;
|
|
1030
|
-
function
|
|
1006
|
+
function dn() {
|
|
1031
1007
|
return B;
|
|
1032
1008
|
}
|
|
1033
|
-
function
|
|
1034
|
-
const { signal: [o, i], utils: a = {} } = e, s = a.parsePath || ((
|
|
1009
|
+
function pn(e, t, n, r = {}) {
|
|
1010
|
+
const { signal: [o, i], utils: a = {} } = e, s = a.parsePath || ((v) => v), c = a.renderPath || ((v) => v), l = a.beforeLeave || et(), u = Y("", r.base || "");
|
|
1035
1011
|
if (u === void 0)
|
|
1036
1012
|
throw new Error(`${u} is not a valid base path`);
|
|
1037
1013
|
u && !o().value && i({ value: u, replace: !0, scroll: !1 });
|
|
1038
1014
|
const [h, p] = x(!1);
|
|
1039
1015
|
let m;
|
|
1040
|
-
const
|
|
1041
|
-
$.value === f() && $.state === S() || (m === void 0 && p(!0), B =
|
|
1016
|
+
const y = (v, $) => {
|
|
1017
|
+
$.value === f() && $.state === S() || (m === void 0 && p(!0), B = v, m = $, wt(() => {
|
|
1042
1018
|
m === $ && (d(m.value), g(m.state), F[1]([]));
|
|
1043
1019
|
}).finally(() => {
|
|
1044
1020
|
m === $ && yt(() => {
|
|
1045
|
-
B = void 0,
|
|
1021
|
+
B = void 0, v === "navigate" && dt(m), p(!1), m = void 0;
|
|
1046
1022
|
});
|
|
1047
1023
|
}));
|
|
1048
|
-
}, [f, d] = x(o().value), [S, g] = x(o().state), U =
|
|
1049
|
-
const
|
|
1050
|
-
for (let
|
|
1051
|
-
Object.assign($,
|
|
1024
|
+
}, [f, d] = x(o().value), [S, g] = x(o().state), U = hn(f, S), L = [], F = x([]), V = E(() => typeof r.transformUrl == "function" ? de(t(), r.transformUrl(U.pathname)) : de(t(), U.pathname)), ut = rt(() => {
|
|
1025
|
+
const v = V(), $ = {};
|
|
1026
|
+
for (let O = 0; O < v.length; O++)
|
|
1027
|
+
Object.assign($, v[O].params);
|
|
1052
1028
|
return $;
|
|
1053
1029
|
}), Le = {
|
|
1054
1030
|
pattern: u,
|
|
1055
1031
|
path: () => u,
|
|
1056
1032
|
outlet: () => null,
|
|
1057
|
-
resolvePath(
|
|
1058
|
-
return Y(u,
|
|
1033
|
+
resolvePath(v) {
|
|
1034
|
+
return Y(u, v);
|
|
1059
1035
|
}
|
|
1060
1036
|
};
|
|
1061
|
-
return
|
|
1037
|
+
return _(K(o, (v) => y("native", v), { defer: !0 })), {
|
|
1062
1038
|
base: Le,
|
|
1063
1039
|
location: U,
|
|
1064
1040
|
params: ut,
|
|
@@ -1072,7 +1048,7 @@ function gn(e, t, n, r = {}) {
|
|
|
1072
1048
|
singleFlight: r.singleFlight === void 0 ? !0 : r.singleFlight,
|
|
1073
1049
|
submissions: F
|
|
1074
1050
|
};
|
|
1075
|
-
function ft(
|
|
1051
|
+
function ft(v, $, O) {
|
|
1076
1052
|
I(() => {
|
|
1077
1053
|
if (typeof $ == "number") {
|
|
1078
1054
|
$ && (a.go ? a.go($) : console.warn("Router integration does not support relative routing"));
|
|
@@ -1082,44 +1058,44 @@ function gn(e, t, n, r = {}) {
|
|
|
1082
1058
|
replace: !1,
|
|
1083
1059
|
resolve: !0,
|
|
1084
1060
|
scroll: !0,
|
|
1085
|
-
...
|
|
1086
|
-
},
|
|
1087
|
-
if (
|
|
1061
|
+
...O
|
|
1062
|
+
}, j = ce ? v.resolvePath($) : Y("", $);
|
|
1063
|
+
if (j === void 0)
|
|
1088
1064
|
throw new Error(`Path '${$}' is not a routable path`);
|
|
1089
|
-
if (L.length >=
|
|
1065
|
+
if (L.length >= an)
|
|
1090
1066
|
throw new Error("Too many redirects");
|
|
1091
1067
|
const Pe = f();
|
|
1092
|
-
(
|
|
1093
|
-
value:
|
|
1068
|
+
(j !== Pe || X !== S()) && (_t || l.confirm(j, O) && (L.push({ value: Pe, replace: le, scroll: M, state: S() }), y("navigate", {
|
|
1069
|
+
value: j,
|
|
1094
1070
|
state: X
|
|
1095
1071
|
})));
|
|
1096
1072
|
});
|
|
1097
1073
|
}
|
|
1098
|
-
function ht(
|
|
1099
|
-
return
|
|
1074
|
+
function ht(v) {
|
|
1075
|
+
return v = v || We(it) || Le, ($, O) => ft(v, $, O);
|
|
1100
1076
|
}
|
|
1101
|
-
function dt(
|
|
1077
|
+
function dt(v) {
|
|
1102
1078
|
const $ = L[0];
|
|
1103
1079
|
$ && (i({
|
|
1104
|
-
...
|
|
1080
|
+
...v,
|
|
1105
1081
|
replace: $.replace,
|
|
1106
1082
|
scroll: $.scroll
|
|
1107
1083
|
}), L.length = 0);
|
|
1108
1084
|
}
|
|
1109
|
-
function pt(
|
|
1110
|
-
const
|
|
1085
|
+
function pt(v, $ = {}) {
|
|
1086
|
+
const O = de(t(), v.pathname), le = B;
|
|
1111
1087
|
B = "preload";
|
|
1112
|
-
for (let ce in
|
|
1113
|
-
const { route: M, params: X } =
|
|
1088
|
+
for (let ce in O) {
|
|
1089
|
+
const { route: M, params: X } = O[ce];
|
|
1114
1090
|
M.component && M.component.preload && M.component.preload();
|
|
1115
|
-
const {
|
|
1116
|
-
$.preloadData &&
|
|
1091
|
+
const { preload: j } = M;
|
|
1092
|
+
$.preloadData && j && qe(n(), () => j({
|
|
1117
1093
|
params: X,
|
|
1118
1094
|
location: {
|
|
1119
|
-
pathname:
|
|
1120
|
-
search:
|
|
1121
|
-
hash:
|
|
1122
|
-
query: nt(
|
|
1095
|
+
pathname: v.pathname,
|
|
1096
|
+
search: v.search,
|
|
1097
|
+
hash: v.hash,
|
|
1098
|
+
query: nt(v),
|
|
1123
1099
|
state: null,
|
|
1124
1100
|
key: ""
|
|
1125
1101
|
},
|
|
@@ -1129,8 +1105,8 @@ function gn(e, t, n, r = {}) {
|
|
|
1129
1105
|
B = le;
|
|
1130
1106
|
}
|
|
1131
1107
|
}
|
|
1132
|
-
function
|
|
1133
|
-
const { base: o, location: i, params: a } = e, { pattern: s, component: c,
|
|
1108
|
+
function gn(e, t, n, r) {
|
|
1109
|
+
const { base: o, location: i, params: a } = e, { pattern: s, component: c, preload: l } = r().route, u = E(() => r().path);
|
|
1134
1110
|
c && c.preload && c.preload();
|
|
1135
1111
|
const h = l ? l({ params: a, location: i, intent: B || "initial" }) : void 0;
|
|
1136
1112
|
return {
|
|
@@ -1150,12 +1126,12 @@ function mn(e, t, n, r) {
|
|
|
1150
1126
|
}
|
|
1151
1127
|
};
|
|
1152
1128
|
}
|
|
1153
|
-
const
|
|
1129
|
+
const mn = (e) => (t) => {
|
|
1154
1130
|
const {
|
|
1155
1131
|
base: n
|
|
1156
1132
|
} = t, r = Se(() => t.children), o = E(() => ct(r(), t.base || ""));
|
|
1157
1133
|
let i;
|
|
1158
|
-
const a =
|
|
1134
|
+
const a = pn(e, o, () => i, {
|
|
1159
1135
|
base: n,
|
|
1160
1136
|
singleFlight: t.singleFlight,
|
|
1161
1137
|
transformUrl: t.transformUrl
|
|
@@ -1163,16 +1139,16 @@ const yn = (e) => (t) => {
|
|
|
1163
1139
|
return e.create && e.create(a), A(st.Provider, {
|
|
1164
1140
|
value: a,
|
|
1165
1141
|
get children() {
|
|
1166
|
-
return A(
|
|
1142
|
+
return A(yn, {
|
|
1167
1143
|
routerState: a,
|
|
1168
1144
|
get root() {
|
|
1169
1145
|
return t.root;
|
|
1170
1146
|
},
|
|
1171
|
-
get
|
|
1172
|
-
return t.rootLoad;
|
|
1147
|
+
get preload() {
|
|
1148
|
+
return t.rootPreload || t.rootLoad;
|
|
1173
1149
|
},
|
|
1174
1150
|
get children() {
|
|
1175
|
-
return [E(() => (i =
|
|
1151
|
+
return [E(() => (i = De()) && null), A(wn, {
|
|
1176
1152
|
routerState: a,
|
|
1177
1153
|
get branches() {
|
|
1178
1154
|
return o();
|
|
@@ -1183,12 +1159,12 @@ const yn = (e) => (t) => {
|
|
|
1183
1159
|
}
|
|
1184
1160
|
});
|
|
1185
1161
|
};
|
|
1186
|
-
function
|
|
1187
|
-
const t = e.routerState.location, n = e.routerState.params, r = E(() => e.
|
|
1188
|
-
e.
|
|
1162
|
+
function yn(e) {
|
|
1163
|
+
const t = e.routerState.location, n = e.routerState.params, r = E(() => e.preload && I(() => {
|
|
1164
|
+
e.preload({
|
|
1189
1165
|
params: n,
|
|
1190
1166
|
location: t,
|
|
1191
|
-
intent:
|
|
1167
|
+
intent: dn() || "initial"
|
|
1192
1168
|
});
|
|
1193
1169
|
}));
|
|
1194
1170
|
return A(q, {
|
|
@@ -1211,7 +1187,7 @@ function wn(e) {
|
|
|
1211
1187
|
})
|
|
1212
1188
|
});
|
|
1213
1189
|
}
|
|
1214
|
-
function
|
|
1190
|
+
function wn(e) {
|
|
1215
1191
|
const t = [];
|
|
1216
1192
|
let n;
|
|
1217
1193
|
const r = E(K(e.routerState.matches, (o, i, a) => {
|
|
@@ -1220,7 +1196,7 @@ function vn(e) {
|
|
|
1220
1196
|
for (let l = 0, u = o.length; l < u; l++) {
|
|
1221
1197
|
const h = i && i[l], p = o[l];
|
|
1222
1198
|
a && h && p.route.key === h.route.key ? c[l] = a[l] : (s = !1, t[l] && t[l](), Be((m) => {
|
|
1223
|
-
t[l] = m, c[l] =
|
|
1199
|
+
t[l] = m, c[l] = gn(e.routerState, c[l - 1] || e.routerState.base, Ue(() => r()[l + 1]), () => e.routerState.matches()[l]);
|
|
1224
1200
|
}));
|
|
1225
1201
|
}
|
|
1226
1202
|
return t.splice(o.length).forEach((l) => l()), a && s ? a : (n = c[0], c);
|
|
@@ -1246,10 +1222,10 @@ const Ue = (e) => () => A(q, {
|
|
|
1246
1222
|
}
|
|
1247
1223
|
});
|
|
1248
1224
|
};
|
|
1249
|
-
function
|
|
1225
|
+
function vn([e, t], n, r) {
|
|
1250
1226
|
return [e, r ? (o) => t(r(o)) : t];
|
|
1251
1227
|
}
|
|
1252
|
-
function
|
|
1228
|
+
function bn(e) {
|
|
1253
1229
|
if (e === "#")
|
|
1254
1230
|
return null;
|
|
1255
1231
|
try {
|
|
@@ -1258,28 +1234,28 @@ function Sn(e) {
|
|
|
1258
1234
|
return null;
|
|
1259
1235
|
}
|
|
1260
1236
|
}
|
|
1261
|
-
function
|
|
1237
|
+
function Sn(e) {
|
|
1262
1238
|
let t = !1;
|
|
1263
|
-
const n = (o) => typeof o == "string" ? { value: o } : o, r =
|
|
1239
|
+
const n = (o) => typeof o == "string" ? { value: o } : o, r = vn(x(n(e.get()), {
|
|
1264
1240
|
equals: (o, i) => o.value === i.value && o.state === i.state
|
|
1265
1241
|
}), void 0, (o) => (!t && e.set(o), o));
|
|
1266
1242
|
return e.init && Me(e.init((o = e.get()) => {
|
|
1267
1243
|
t = !0, r[1](n(o)), t = !1;
|
|
1268
|
-
})),
|
|
1244
|
+
})), mn({
|
|
1269
1245
|
signal: r,
|
|
1270
1246
|
create: e.create,
|
|
1271
1247
|
utils: e.utils
|
|
1272
1248
|
});
|
|
1273
1249
|
}
|
|
1274
|
-
function
|
|
1250
|
+
function $n(e, t, n) {
|
|
1275
1251
|
return e.addEventListener(t, n), () => e.removeEventListener(t, n);
|
|
1276
1252
|
}
|
|
1277
|
-
function
|
|
1278
|
-
const n =
|
|
1253
|
+
function An(e, t) {
|
|
1254
|
+
const n = bn(`#${e}`);
|
|
1279
1255
|
n ? n.scrollIntoView() : t && window.scrollTo(0, 0);
|
|
1280
1256
|
}
|
|
1281
|
-
const
|
|
1282
|
-
function
|
|
1257
|
+
const En = /* @__PURE__ */ new Map();
|
|
1258
|
+
function Rn(e = !0, t = !1, n = "/_server", r) {
|
|
1283
1259
|
return (o) => {
|
|
1284
1260
|
const i = o.base.path(), a = o.navigatorFactory(o.base);
|
|
1285
1261
|
let s = {};
|
|
@@ -1337,7 +1313,7 @@ function Cn(e = !0, t = !1, n = "/_server", r) {
|
|
|
1337
1313
|
const [, S] = d;
|
|
1338
1314
|
s[S.pathname] && (clearTimeout(s[S.pathname]), delete s[S.pathname]);
|
|
1339
1315
|
}
|
|
1340
|
-
function
|
|
1316
|
+
function y(f) {
|
|
1341
1317
|
if (f.defaultPrevented)
|
|
1342
1318
|
return;
|
|
1343
1319
|
let d = f.submitter && f.submitter.hasAttribute("formaction") ? f.submitter.getAttribute("formaction") : f.target.getAttribute("action");
|
|
@@ -1350,19 +1326,19 @@ function Cn(e = !0, t = !1, n = "/_server", r) {
|
|
|
1350
1326
|
}
|
|
1351
1327
|
if (f.target.method.toUpperCase() !== "POST")
|
|
1352
1328
|
throw new Error("Only POST forms are supported for Actions");
|
|
1353
|
-
const S =
|
|
1329
|
+
const S = En.get(d);
|
|
1354
1330
|
if (S) {
|
|
1355
1331
|
f.preventDefault();
|
|
1356
|
-
const g = new FormData(f.target);
|
|
1357
|
-
|
|
1332
|
+
const g = new FormData(f.target, f.submitter);
|
|
1333
|
+
S.call({ r: o, f: f.target }, f.target.enctype === "multipart/form-data" ? g : new URLSearchParams(g));
|
|
1358
1334
|
}
|
|
1359
1335
|
}
|
|
1360
|
-
se(["click", "submit"]), document.addEventListener("click", u), e && (document.addEventListener("mouseover", p), document.addEventListener("mouseout", m), document.addEventListener("focusin", h), document.addEventListener("touchstart", h)), document.addEventListener("submit",
|
|
1361
|
-
document.removeEventListener("click", u), e && (document.removeEventListener("mouseover", p), document.removeEventListener("mouseout", m), document.removeEventListener("focusin", h), document.removeEventListener("touchstart", h)), document.removeEventListener("submit",
|
|
1336
|
+
se(["click", "submit"]), document.addEventListener("click", u), e && (document.addEventListener("mouseover", p), document.addEventListener("mouseout", m), document.addEventListener("focusin", h), document.addEventListener("touchstart", h)), document.addEventListener("submit", y), Me(() => {
|
|
1337
|
+
document.removeEventListener("click", u), e && (document.removeEventListener("mouseover", p), document.removeEventListener("mouseout", m), document.removeEventListener("focusin", h), document.removeEventListener("touchstart", h)), document.removeEventListener("submit", y);
|
|
1362
1338
|
});
|
|
1363
1339
|
};
|
|
1364
1340
|
}
|
|
1365
|
-
function
|
|
1341
|
+
function Cn(e) {
|
|
1366
1342
|
const t = e.replace(/^.*?#/, "");
|
|
1367
1343
|
if (!t.startsWith("/")) {
|
|
1368
1344
|
const [, n = "/"] = window.location.hash.split("#", 2);
|
|
@@ -1370,27 +1346,27 @@ function Ln(e) {
|
|
|
1370
1346
|
}
|
|
1371
1347
|
return t;
|
|
1372
1348
|
}
|
|
1373
|
-
function
|
|
1349
|
+
function Ln(e) {
|
|
1374
1350
|
const t = () => window.location.hash.slice(1), n = et();
|
|
1375
|
-
return
|
|
1351
|
+
return Sn({
|
|
1376
1352
|
get: t,
|
|
1377
1353
|
set({ value: r, replace: o, scroll: i, state: a }) {
|
|
1378
|
-
o ? window.history.replaceState(
|
|
1354
|
+
o ? window.history.replaceState(Zt(a), "", "#" + r) : window.history.pushState(a, "", "#" + r);
|
|
1379
1355
|
const s = r.indexOf("#"), c = s >= 0 ? r.slice(s + 1) : "";
|
|
1380
|
-
|
|
1356
|
+
An(c, i), Re();
|
|
1381
1357
|
},
|
|
1382
|
-
init: (r) =>
|
|
1383
|
-
create:
|
|
1358
|
+
init: (r) => $n(window, "hashchange", zt(r, (o) => !n.confirm(o && o < 0 ? o : t()))),
|
|
1359
|
+
create: Rn(e.preload, e.explicitLinks, e.actionBase),
|
|
1384
1360
|
utils: {
|
|
1385
1361
|
go: (r) => window.history.go(r),
|
|
1386
1362
|
renderPath: (r) => `#${r}`,
|
|
1387
|
-
parsePath:
|
|
1363
|
+
parsePath: Cn,
|
|
1388
1364
|
beforeLeave: n
|
|
1389
1365
|
}
|
|
1390
1366
|
})(e);
|
|
1391
1367
|
}
|
|
1392
|
-
function
|
|
1393
|
-
const t = at(), n =
|
|
1368
|
+
function Pn(e) {
|
|
1369
|
+
const t = at(), n = ln(), {
|
|
1394
1370
|
href: r,
|
|
1395
1371
|
state: o
|
|
1396
1372
|
} = e, i = typeof r == "function" ? r({
|
|
@@ -1402,7 +1378,7 @@ function xn(e) {
|
|
|
1402
1378
|
state: o
|
|
1403
1379
|
}), null;
|
|
1404
1380
|
}
|
|
1405
|
-
const
|
|
1381
|
+
const xn = {};
|
|
1406
1382
|
async function ke({
|
|
1407
1383
|
language: e,
|
|
1408
1384
|
text: t,
|
|
@@ -1423,11 +1399,11 @@ async function ke({
|
|
|
1423
1399
|
}
|
|
1424
1400
|
return await a.json();
|
|
1425
1401
|
}
|
|
1426
|
-
const On = "_SearchForm_1a5n6_1",
|
|
1402
|
+
const On = "_SearchForm_1a5n6_1", _n = {
|
|
1427
1403
|
SearchForm: On
|
|
1428
1404
|
};
|
|
1429
|
-
var
|
|
1430
|
-
const
|
|
1405
|
+
var In = /* @__PURE__ */ C("<form><input type=search><button type=submit>");
|
|
1406
|
+
const Un = (e) => {
|
|
1431
1407
|
const t = at(), [n, r] = x(e.value ?? ""), {
|
|
1432
1408
|
t: o
|
|
1433
1409
|
} = ae(e.language);
|
|
@@ -1436,17 +1412,17 @@ const kn = (e) => {
|
|
|
1436
1412
|
a.preventDefault(), t(`/q/${encodeURIComponent(n())}`);
|
|
1437
1413
|
};
|
|
1438
1414
|
return (() => {
|
|
1439
|
-
var a =
|
|
1440
|
-
return a.addEventListener("submit", i), s.addEventListener("change", (l) => r(l.currentTarget.value)), P(c, () => o("searchApp.search")),
|
|
1441
|
-
var u =
|
|
1415
|
+
var a = In(), s = a.firstChild, c = s.nextSibling;
|
|
1416
|
+
return a.addEventListener("submit", i), s.addEventListener("change", (l) => r(l.currentTarget.value)), P(c, () => o("searchApp.search")), _((l) => {
|
|
1417
|
+
var u = _n.SearchForm, h = o("searchApp.search");
|
|
1442
1418
|
return u !== l.e && Qe(a, l.e = u), h !== l.t && ie(s, "placeholder", l.t = h), l;
|
|
1443
1419
|
}, {
|
|
1444
1420
|
e: void 0,
|
|
1445
1421
|
t: void 0
|
|
1446
|
-
}),
|
|
1422
|
+
}), _(() => s.value = n()), a;
|
|
1447
1423
|
})();
|
|
1448
1424
|
};
|
|
1449
|
-
var
|
|
1425
|
+
var kn = /* @__PURE__ */ C("<div class=SearchPageResponse>"), Te = /* @__PURE__ */ C("<div>"), Tn = /* @__PURE__ */ C("<img class=SearchPageResponse-spinner width=80 height=80 alt=…>"), Nn = /* @__PURE__ */ C("<button type=button>"), Fn = /* @__PURE__ */ C("<div class=SearchPageResponse-noResultMessage> <span>");
|
|
1450
1426
|
function Ne({
|
|
1451
1427
|
language: e,
|
|
1452
1428
|
limit: t,
|
|
@@ -1454,7 +1430,7 @@ function Ne({
|
|
|
1454
1430
|
}) {
|
|
1455
1431
|
const {
|
|
1456
1432
|
t: r
|
|
1457
|
-
} = ae(e), o =
|
|
1433
|
+
} = ae(e), o = cn(), [i, a] = x(""), [s, c] = x(0), [l, u] = x(0), [h, p] = x(!1);
|
|
1458
1434
|
be(K(() => o.searchString, m));
|
|
1459
1435
|
async function m() {
|
|
1460
1436
|
if (o.searchString) {
|
|
@@ -1468,20 +1444,17 @@ function Ne({
|
|
|
1468
1444
|
start: l(),
|
|
1469
1445
|
templateName: n
|
|
1470
1446
|
});
|
|
1471
|
-
if (c(f.total), u(l() + t), !f.html)
|
|
1472
|
-
return;
|
|
1447
|
+
if (c(f.total), u(l() + t), !f.html) return;
|
|
1473
1448
|
a(f.html);
|
|
1474
1449
|
} finally {
|
|
1475
1450
|
p(!1);
|
|
1476
1451
|
}
|
|
1477
1452
|
}
|
|
1478
1453
|
}
|
|
1479
|
-
async function
|
|
1480
|
-
if (!o.searchString)
|
|
1481
|
-
return;
|
|
1454
|
+
async function y() {
|
|
1455
|
+
if (!o.searchString) return;
|
|
1482
1456
|
const f = s();
|
|
1483
|
-
if (f === void 0 || l() >= f)
|
|
1484
|
-
return;
|
|
1457
|
+
if (f === void 0 || l() >= f) return;
|
|
1485
1458
|
const d = await ke({
|
|
1486
1459
|
language: e,
|
|
1487
1460
|
text: decodeURIComponent(o.searchString),
|
|
@@ -1493,7 +1466,7 @@ function Ne({
|
|
|
1493
1466
|
}
|
|
1494
1467
|
return (() => {
|
|
1495
1468
|
var f = Te();
|
|
1496
|
-
return P(f, A(
|
|
1469
|
+
return P(f, A(Un, {
|
|
1497
1470
|
language: e,
|
|
1498
1471
|
get value() {
|
|
1499
1472
|
return E(() => !!o.searchString)() ? decodeURIComponent(o.searchString) : void 0;
|
|
@@ -1503,11 +1476,11 @@ function Ne({
|
|
|
1503
1476
|
return o.searchString;
|
|
1504
1477
|
},
|
|
1505
1478
|
get children() {
|
|
1506
|
-
var d =
|
|
1479
|
+
var d = kn();
|
|
1507
1480
|
return P(d, (() => {
|
|
1508
1481
|
var S = E(() => !!h());
|
|
1509
1482
|
return () => S() ? (() => {
|
|
1510
|
-
var g =
|
|
1483
|
+
var g = Tn();
|
|
1511
1484
|
return ie(g, "src", `${Ye}/spinner.svg`), g;
|
|
1512
1485
|
})() : A(q, {
|
|
1513
1486
|
get when() {
|
|
@@ -1515,43 +1488,42 @@ function Ne({
|
|
|
1515
1488
|
},
|
|
1516
1489
|
get fallback() {
|
|
1517
1490
|
return (() => {
|
|
1518
|
-
var g =
|
|
1491
|
+
var g = Fn(), U = g.firstChild, L = U.nextSibling;
|
|
1519
1492
|
return P(g, () => r("searchApp.nothingGet"), U), P(L, () => o.searchString), g;
|
|
1520
1493
|
})();
|
|
1521
1494
|
},
|
|
1522
1495
|
get children() {
|
|
1523
1496
|
return [(() => {
|
|
1524
1497
|
var g = Te();
|
|
1525
|
-
return
|
|
1498
|
+
return _(() => g.innerHTML = i()), g;
|
|
1526
1499
|
})(), A(q, {
|
|
1527
1500
|
get when() {
|
|
1528
1501
|
return l() < s();
|
|
1529
1502
|
},
|
|
1530
1503
|
get children() {
|
|
1531
|
-
var g =
|
|
1532
|
-
return g.$$click =
|
|
1504
|
+
var g = Nn();
|
|
1505
|
+
return g.$$click = y, P(g, () => r("infiniteLoading.loadMore")), g;
|
|
1533
1506
|
}
|
|
1534
1507
|
})];
|
|
1535
1508
|
}
|
|
1536
1509
|
});
|
|
1537
1510
|
})()), d;
|
|
1538
1511
|
}
|
|
1539
|
-
}), null),
|
|
1512
|
+
}), null), _(() => Qe(f, xn.SiteApp)), f;
|
|
1540
1513
|
})();
|
|
1541
1514
|
}
|
|
1542
1515
|
se(["click"]);
|
|
1543
|
-
function
|
|
1516
|
+
function jn(e, {
|
|
1544
1517
|
language: t
|
|
1545
1518
|
}) {
|
|
1546
|
-
if (!t)
|
|
1547
|
-
throw new Error("Missing language");
|
|
1519
|
+
if (!t) throw new Error("Missing language");
|
|
1548
1520
|
const n = J(e.dataset.limit), r = W(e.dataset.template);
|
|
1549
|
-
n === void 0 || r === void 0 || Ee(() => A(
|
|
1521
|
+
n === void 0 || r === void 0 || Ee(() => A(Ln, {
|
|
1550
1522
|
explicitLinks: !0,
|
|
1551
1523
|
get children() {
|
|
1552
1524
|
return [A(pe, {
|
|
1553
1525
|
path: "/",
|
|
1554
|
-
component: () => A(
|
|
1526
|
+
component: () => A(Pn, {
|
|
1555
1527
|
href: "/q"
|
|
1556
1528
|
})
|
|
1557
1529
|
}), A(pe, {
|
|
@@ -1572,8 +1544,8 @@ function Bn(e, {
|
|
|
1572
1544
|
}
|
|
1573
1545
|
}), e);
|
|
1574
1546
|
}
|
|
1575
|
-
var
|
|
1576
|
-
function
|
|
1547
|
+
var Bn = /* @__PURE__ */ C("<input class=SearchOpenerOverlay-input type=search required>"), Mn = /* @__PURE__ */ C("<div class=SearchOpenerOverlay><form class=SearchOpenerOverlay-form><button class=SearchOpenerOverlay-btn type=submit>");
|
|
1548
|
+
function Dn({
|
|
1577
1549
|
searchURL: e,
|
|
1578
1550
|
language: t,
|
|
1579
1551
|
setSearchFormOverlayIsOpen: n
|
|
@@ -1582,15 +1554,15 @@ function qn({
|
|
|
1582
1554
|
const [o, i] = x(""), {
|
|
1583
1555
|
t: a
|
|
1584
1556
|
} = ae(t), s = (() => {
|
|
1585
|
-
var l =
|
|
1586
|
-
return l.addEventListener("change", (u) => i(u.currentTarget.value)),
|
|
1557
|
+
var l = Bn();
|
|
1558
|
+
return l.addEventListener("change", (u) => i(u.currentTarget.value)), _(() => ie(l, "placeholder", a("searchApp.search"))), _(() => l.value = o()), l;
|
|
1587
1559
|
})(), c = (l) => {
|
|
1588
1560
|
l.preventDefault(), window.location.href = `${e}#/q/${encodeURIComponent(o())}`, n(!1);
|
|
1589
1561
|
};
|
|
1590
1562
|
return be(() => {
|
|
1591
1563
|
s.focus();
|
|
1592
1564
|
}), (() => {
|
|
1593
|
-
var l =
|
|
1565
|
+
var l = Mn(), u = l.firstChild, h = u.firstChild;
|
|
1594
1566
|
l.$$click = (m) => {
|
|
1595
1567
|
m.target === r && n(!1);
|
|
1596
1568
|
};
|
|
@@ -1599,22 +1571,22 @@ function qn({
|
|
|
1599
1571
|
})();
|
|
1600
1572
|
}
|
|
1601
1573
|
se(["click"]);
|
|
1602
|
-
var
|
|
1603
|
-
function
|
|
1574
|
+
var qn = /* @__PURE__ */ C('<button type=button class=SearchOpenerBtn><svg class=SearchOpenerBtn-svg width=20 height=20 version=1.1 id=Capa_1 xmlns=http://www.w3.org/2000/svg viewBox="0 0 490.4 490.4"><title>Search Icon</title><g id=SVGRepo_bgCarrier stroke-width=0></g><g id=SVGRepo_tracerCarrier stroke-linecap=round stroke-linejoin=round></g><g id=SVGRepo_iconCarrier><g><path d="M484.1,454.796l-110.5-110.6c29.8-36.3,47.6-82.8,47.6-133.4c0-116.3-94.3-210.6-210.6-210.6S0,94.496,0,210.796 s94.3,210.6,210.6,210.6c50.8,0,97.4-18,133.8-48l110.5,110.5c12.9,11.8,25,4.2,29.2,0C492.5,475.596,492.5,463.096,484.1,454.796z M41.1,210.796c0-93.6,75.9-169.5,169.5-169.5s169.6,75.9,169.6,169.5s-75.9,169.5-169.5,169.5S41.1,304.396,41.1,210.796z"></path> '), Vn = /* @__PURE__ */ C("<div>");
|
|
1575
|
+
function Wn({
|
|
1604
1576
|
searchIconColor: e,
|
|
1605
1577
|
language: t,
|
|
1606
1578
|
searchURL: n
|
|
1607
1579
|
}) {
|
|
1608
1580
|
const [r, o] = x(!1), i = (() => {
|
|
1609
|
-
var s =
|
|
1581
|
+
var s = qn(), c = s.firstChild;
|
|
1610
1582
|
return e != null ? c.style.setProperty("fill", e) : c.style.removeProperty("fill"), s;
|
|
1611
|
-
})(), a =
|
|
1583
|
+
})(), a = Vn();
|
|
1612
1584
|
return document.body.appendChild(a), i.addEventListener("click", () => o(!0)), Ee(() => A(q, {
|
|
1613
1585
|
get when() {
|
|
1614
1586
|
return r();
|
|
1615
1587
|
},
|
|
1616
1588
|
get children() {
|
|
1617
|
-
return A(
|
|
1589
|
+
return A(Dn, {
|
|
1618
1590
|
searchURL: n,
|
|
1619
1591
|
language: t,
|
|
1620
1592
|
setSearchFormOverlayIsOpen: o
|
|
@@ -1622,15 +1594,13 @@ function Gn({
|
|
|
1622
1594
|
}
|
|
1623
1595
|
}), a), i;
|
|
1624
1596
|
}
|
|
1625
|
-
function
|
|
1597
|
+
function Gn(e, {
|
|
1626
1598
|
language: t
|
|
1627
1599
|
}) {
|
|
1628
1600
|
const n = e.dataset.searchUrl, r = e.dataset.iconColor;
|
|
1629
|
-
if (!t)
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
throw new Error("Missing search url");
|
|
1633
|
-
Ee(() => A(Gn, {
|
|
1601
|
+
if (!t) throw new Error("Missing language");
|
|
1602
|
+
if (!n) throw new Error("Missing search url");
|
|
1603
|
+
Ee(() => A(Wn, {
|
|
1634
1604
|
language: t,
|
|
1635
1605
|
searchURL: n,
|
|
1636
1606
|
searchIconColor: r
|
|
@@ -1638,14 +1608,13 @@ function Kn(e, {
|
|
|
1638
1608
|
}
|
|
1639
1609
|
document.addEventListener("DOMContentLoaded", () => {
|
|
1640
1610
|
const e = document.documentElement.lang, t = {
|
|
1641
|
-
searchOpener:
|
|
1642
|
-
searchForm:
|
|
1643
|
-
infiniteLoading:
|
|
1611
|
+
searchOpener: Gn,
|
|
1612
|
+
searchForm: jn,
|
|
1613
|
+
infiniteLoading: Qt
|
|
1644
1614
|
}, n = document.querySelectorAll("[data-effect]");
|
|
1645
1615
|
for (const r of n) {
|
|
1646
1616
|
const o = r.dataset.effect;
|
|
1647
|
-
if (!o)
|
|
1648
|
-
continue;
|
|
1617
|
+
if (!o) continue;
|
|
1649
1618
|
const i = t[o];
|
|
1650
1619
|
i && i(r, {
|
|
1651
1620
|
language: e
|