@pie-players/pie-tool-line-reader 0.3.1 → 0.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/tool-line-reader.js +172 -152
- package/package.json +4 -4
package/dist/tool-line-reader.js
CHANGED
|
@@ -8,7 +8,7 @@ var c = (t, e, i) => (ei(t, e, "read from private field"), i ? i.call(t) : e.get
|
|
|
8
8
|
var cn;
|
|
9
9
|
typeof window < "u" && ((cn = window.__svelte ?? (window.__svelte = {})).v ?? (cn.v = /* @__PURE__ */ new Set())).add("5");
|
|
10
10
|
const Ar = 2, mi = "[", _i = "[!", un = "]", ot = {}, C = /* @__PURE__ */ Symbol(), fn = "http://www.w3.org/1999/xhtml", ii = !1;
|
|
11
|
-
var
|
|
11
|
+
var Or = Array.isArray, Rr = Array.prototype.indexOf, lt = Array.prototype.includes, Lr = Array.from, Ft = Object.keys, Ht = Object.defineProperty, Qe = Object.getOwnPropertyDescriptor, Mr = Object.getOwnPropertyDescriptors, Vr = Object.prototype, Nr = Array.prototype, dn = Object.getPrototypeOf, Hi = Object.isExtensible;
|
|
12
12
|
const Cr = () => {
|
|
13
13
|
};
|
|
14
14
|
function Pr(t) {
|
|
@@ -40,10 +40,10 @@ function Hr(t) {
|
|
|
40
40
|
function zr() {
|
|
41
41
|
throw new Error("https://svelte.dev/e/effect_in_unowned_derived");
|
|
42
42
|
}
|
|
43
|
-
function
|
|
43
|
+
function Gr(t) {
|
|
44
44
|
throw new Error("https://svelte.dev/e/effect_orphan");
|
|
45
45
|
}
|
|
46
|
-
function
|
|
46
|
+
function Br() {
|
|
47
47
|
throw new Error("https://svelte.dev/e/effect_update_depth_exceeded");
|
|
48
48
|
}
|
|
49
49
|
function Yr() {
|
|
@@ -78,11 +78,11 @@ function re(t) {
|
|
|
78
78
|
return S = t;
|
|
79
79
|
}
|
|
80
80
|
function yi() {
|
|
81
|
-
return re(/* @__PURE__ */
|
|
81
|
+
return re(/* @__PURE__ */ Oe(S));
|
|
82
82
|
}
|
|
83
|
-
function
|
|
83
|
+
function Gi(t) {
|
|
84
84
|
if (E) {
|
|
85
|
-
if (/* @__PURE__ */
|
|
85
|
+
if (/* @__PURE__ */ Oe(S) !== null)
|
|
86
86
|
throw Kt(), ot;
|
|
87
87
|
S = t;
|
|
88
88
|
}
|
|
@@ -91,7 +91,7 @@ function gn(t = 1) {
|
|
|
91
91
|
if (E) {
|
|
92
92
|
for (var e = t, i = S; e--; )
|
|
93
93
|
i = /** @type {TemplateNode} */
|
|
94
|
-
/* @__PURE__ */
|
|
94
|
+
/* @__PURE__ */ Oe(i);
|
|
95
95
|
S = i;
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -110,7 +110,7 @@ function mn(t = !0) {
|
|
|
110
110
|
}
|
|
111
111
|
var r = (
|
|
112
112
|
/** @type {TemplateNode} */
|
|
113
|
-
/* @__PURE__ */
|
|
113
|
+
/* @__PURE__ */ Oe(i)
|
|
114
114
|
);
|
|
115
115
|
t && i.remove(), i = r;
|
|
116
116
|
}
|
|
@@ -224,7 +224,7 @@ function Sn(t, e, i) {
|
|
|
224
224
|
(t.f & D) !== 0 ? e.add(t) : (t.f & ne) !== 0 && i.add(t), $n(t.deps), L(t, N);
|
|
225
225
|
}
|
|
226
226
|
const Vt = /* @__PURE__ */ new Set();
|
|
227
|
-
let
|
|
227
|
+
let O = null, ee = null, F = [], Wt = null, si = !1, mt = !1;
|
|
228
228
|
var Ze, et, He, tt, $t, St, ze, be, it, de, oi, li, En;
|
|
229
229
|
const Li = class Li {
|
|
230
230
|
constructor() {
|
|
@@ -325,10 +325,10 @@ const Li = class Li {
|
|
|
325
325
|
if (this.is_deferred()) {
|
|
326
326
|
j(this, de, li).call(this, n), j(this, de, li).call(this, i);
|
|
327
327
|
for (const [r, s] of c(this, be))
|
|
328
|
-
|
|
328
|
+
Rn(r, s);
|
|
329
329
|
} else {
|
|
330
330
|
for (const r of c(this, Ze)) r();
|
|
331
|
-
c(this, Ze).clear(), c(this, He) === 0 && j(this, de, En).call(this),
|
|
331
|
+
c(this, Ze).clear(), c(this, He) === 0 && j(this, de, En).call(this), O = null, Bi(n), Bi(i), c(this, $t)?.resolve();
|
|
332
332
|
}
|
|
333
333
|
ee = null;
|
|
334
334
|
}
|
|
@@ -342,14 +342,14 @@ const Li = class Li {
|
|
|
342
342
|
i !== C && !this.previous.has(e) && this.previous.set(e, i), (e.f & Ve) === 0 && (this.current.set(e, e.v), ee?.set(e, e.v));
|
|
343
343
|
}
|
|
344
344
|
activate() {
|
|
345
|
-
|
|
345
|
+
O = this, this.apply();
|
|
346
346
|
}
|
|
347
347
|
deactivate() {
|
|
348
|
-
|
|
348
|
+
O === this && (O = null, ee = null);
|
|
349
349
|
}
|
|
350
350
|
flush() {
|
|
351
351
|
if (this.activate(), F.length > 0) {
|
|
352
|
-
if (kn(),
|
|
352
|
+
if (kn(), O !== null && O !== this)
|
|
353
353
|
return;
|
|
354
354
|
} else c(this, He) === 0 && this.process([]);
|
|
355
355
|
this.deactivate();
|
|
@@ -393,13 +393,13 @@ const Li = class Li {
|
|
|
393
393
|
return (c(this, $t) ?? _(this, $t, hn())).promise;
|
|
394
394
|
}
|
|
395
395
|
static ensure() {
|
|
396
|
-
if (
|
|
397
|
-
const e =
|
|
398
|
-
Vt.add(
|
|
399
|
-
|
|
396
|
+
if (O === null) {
|
|
397
|
+
const e = O = new Li();
|
|
398
|
+
Vt.add(O), mt || qe(() => {
|
|
399
|
+
O === e && e.flush();
|
|
400
400
|
});
|
|
401
401
|
}
|
|
402
|
-
return
|
|
402
|
+
return O;
|
|
403
403
|
}
|
|
404
404
|
apply() {
|
|
405
405
|
}
|
|
@@ -416,7 +416,7 @@ oi = function(e, i, n) {
|
|
|
416
416
|
for (var r = e.first, s = null; r !== null; ) {
|
|
417
417
|
var o = r.f, l = (o & (he | Pe)) !== 0, a = l && (o & N) !== 0, u = a || (o & ue) !== 0 || c(this, be).has(r);
|
|
418
418
|
if (!u && r.fn !== null) {
|
|
419
|
-
l ? r.f ^= N : s !== null && (o & (yt | Yt | pn)) !== 0 ? s.b.defer_effect(r) : (o & yt) !== 0 ? i.push(r) :
|
|
419
|
+
l ? r.f ^= N : s !== null && (o & (yt | Yt | pn)) !== 0 ? s.b.defer_effect(r) : (o & yt) !== 0 ? i.push(r) : Rt(r) && ((o & Ae) !== 0 && c(this, ze).add(r), ft(r));
|
|
420
420
|
var f = r.first;
|
|
421
421
|
if (f !== null) {
|
|
422
422
|
r = f;
|
|
@@ -468,7 +468,7 @@ li = function(e) {
|
|
|
468
468
|
for (const f of o)
|
|
469
469
|
An(f, l, a, u);
|
|
470
470
|
if (F.length > 0) {
|
|
471
|
-
|
|
471
|
+
O = s, s.apply();
|
|
472
472
|
for (const f of F)
|
|
473
473
|
j(r = s, de, oi).call(r, f, [], []);
|
|
474
474
|
s.deactivate();
|
|
@@ -476,7 +476,7 @@ li = function(e) {
|
|
|
476
476
|
F = n;
|
|
477
477
|
}
|
|
478
478
|
}
|
|
479
|
-
|
|
479
|
+
O = null, ee = e;
|
|
480
480
|
}
|
|
481
481
|
this.committed = !0, Vt.delete(this);
|
|
482
482
|
};
|
|
@@ -486,7 +486,7 @@ function ai(t) {
|
|
|
486
486
|
mt = !0;
|
|
487
487
|
try {
|
|
488
488
|
for (var i; ; ) {
|
|
489
|
-
if (ts(), F.length === 0 && (
|
|
489
|
+
if (ts(), F.length === 0 && (O?.flush(), F.length === 0))
|
|
490
490
|
return Wt = null, /** @type {T} */
|
|
491
491
|
i;
|
|
492
492
|
kn();
|
|
@@ -513,18 +513,18 @@ function kn() {
|
|
|
513
513
|
}
|
|
514
514
|
function ns() {
|
|
515
515
|
try {
|
|
516
|
-
|
|
516
|
+
Br();
|
|
517
517
|
} catch (t) {
|
|
518
518
|
ut(t, Wt);
|
|
519
519
|
}
|
|
520
520
|
}
|
|
521
521
|
let _e = null;
|
|
522
|
-
function
|
|
522
|
+
function Bi(t) {
|
|
523
523
|
var e = t.length;
|
|
524
524
|
if (e !== 0) {
|
|
525
525
|
for (var i = 0; i < e; ) {
|
|
526
526
|
var n = t[i++];
|
|
527
|
-
if ((n.f & (Se | ue)) === 0 &&
|
|
527
|
+
if ((n.f & (Se | ue)) === 0 && Rt(n) && (_e = /* @__PURE__ */ new Set(), ft(n), n.deps === null && n.first === null && n.nodes === null && n.teardown === null && n.ac === null && Yn(n), _e?.size > 0)) {
|
|
528
528
|
Ne.clear();
|
|
529
529
|
for (const r of _e) {
|
|
530
530
|
if ((r.f & (Se | ue)) !== 0) continue;
|
|
@@ -553,20 +553,20 @@ function An(t, e, i, n) {
|
|
|
553
553
|
e,
|
|
554
554
|
i,
|
|
555
555
|
n
|
|
556
|
-
) : (s & (bi | Ae)) !== 0 && (s & D) === 0 &&
|
|
556
|
+
) : (s & (bi | Ae)) !== 0 && (s & D) === 0 && On(r, e, n) && (L(r, D), te(
|
|
557
557
|
/** @type {Effect} */
|
|
558
558
|
r
|
|
559
559
|
));
|
|
560
560
|
}
|
|
561
561
|
}
|
|
562
|
-
function
|
|
562
|
+
function On(t, e, i) {
|
|
563
563
|
const n = i.get(t);
|
|
564
564
|
if (n !== void 0) return n;
|
|
565
565
|
if (t.deps !== null)
|
|
566
566
|
for (const r of t.deps) {
|
|
567
567
|
if (lt.call(e, r))
|
|
568
568
|
return !0;
|
|
569
|
-
if ((r.f & P) !== 0 &&
|
|
569
|
+
if ((r.f & P) !== 0 && On(
|
|
570
570
|
/** @type {Derived} */
|
|
571
571
|
r,
|
|
572
572
|
e,
|
|
@@ -593,17 +593,17 @@ function te(t) {
|
|
|
593
593
|
}
|
|
594
594
|
F.push(e);
|
|
595
595
|
}
|
|
596
|
-
function
|
|
596
|
+
function Rn(t, e) {
|
|
597
597
|
if (!((t.f & he) !== 0 && (t.f & N) !== 0)) {
|
|
598
598
|
(t.f & D) !== 0 ? e.d.push(t) : (t.f & ne) !== 0 && e.m.push(t), L(t, N);
|
|
599
599
|
for (var i = t.first; i !== null; )
|
|
600
|
-
|
|
600
|
+
Rn(i, e), i = i.next;
|
|
601
601
|
}
|
|
602
602
|
}
|
|
603
603
|
function rs(t) {
|
|
604
|
-
let e = 0, i =
|
|
604
|
+
let e = 0, i = Ot(0), n;
|
|
605
605
|
return () => {
|
|
606
|
-
Ei() && (d(i), ki(() => (e === 0 && (n =
|
|
606
|
+
Ei() && (d(i), ki(() => (e === 0 && (n = Oi(() => t(() => _t(i)))), e += 1, () => {
|
|
607
607
|
qe(() => {
|
|
608
608
|
e -= 1, e === 0 && (n?.(), n = void 0, _t(i));
|
|
609
609
|
});
|
|
@@ -614,7 +614,7 @@ var ss = at | We;
|
|
|
614
614
|
function os(t, e, i) {
|
|
615
615
|
new ls(t, e, i);
|
|
616
616
|
}
|
|
617
|
-
var K, Et, ye,
|
|
617
|
+
var K, Et, ye, Ge, oe, le, B, ae, we, Be, Me, nt, rt, st, Te, Gt, x, Ln, Mn, ci, Pt, ui;
|
|
618
618
|
class ls {
|
|
619
619
|
/**
|
|
620
620
|
* @param {TemplateNode} node
|
|
@@ -633,18 +633,18 @@ class ls {
|
|
|
633
633
|
/** @type {BoundaryProps} */
|
|
634
634
|
w(this, ye);
|
|
635
635
|
/** @type {((anchor: Node) => void)} */
|
|
636
|
-
w(this,
|
|
636
|
+
w(this, Ge);
|
|
637
637
|
/** @type {Effect} */
|
|
638
638
|
w(this, oe);
|
|
639
639
|
/** @type {Effect | null} */
|
|
640
640
|
w(this, le, null);
|
|
641
641
|
/** @type {Effect | null} */
|
|
642
|
-
w(this,
|
|
642
|
+
w(this, B, null);
|
|
643
643
|
/** @type {Effect | null} */
|
|
644
644
|
w(this, ae, null);
|
|
645
645
|
/** @type {DocumentFragment | null} */
|
|
646
646
|
w(this, we, null);
|
|
647
|
-
w(this,
|
|
647
|
+
w(this, Be, 0);
|
|
648
648
|
w(this, Me, 0);
|
|
649
649
|
w(this, nt, !1);
|
|
650
650
|
/** @type {Set<Effect>} */
|
|
@@ -659,17 +659,17 @@ class ls {
|
|
|
659
659
|
* @type {Source<number> | null}
|
|
660
660
|
*/
|
|
661
661
|
w(this, Te, null);
|
|
662
|
-
w(this,
|
|
662
|
+
w(this, Gt, rs(() => (_(this, Te, Ot(c(this, Be))), () => {
|
|
663
663
|
_(this, Te, null);
|
|
664
664
|
})));
|
|
665
|
-
_(this, K, e), _(this, ye, i), _(this,
|
|
665
|
+
_(this, K, e), _(this, ye, i), _(this, Ge, (r) => {
|
|
666
666
|
var s = (
|
|
667
667
|
/** @type {Effect} */
|
|
668
668
|
$
|
|
669
669
|
);
|
|
670
670
|
s.b = this, s.f |= ni, n(r);
|
|
671
671
|
}), this.parent = /** @type {Effect} */
|
|
672
|
-
$.b, _(this, oe,
|
|
672
|
+
$.b, _(this, oe, Gn(() => {
|
|
673
673
|
if (E) {
|
|
674
674
|
const r = (
|
|
675
675
|
/** @type {Comment} */
|
|
@@ -704,12 +704,12 @@ class ls {
|
|
|
704
704
|
* @param {1 | -1} d
|
|
705
705
|
*/
|
|
706
706
|
update_pending_count(e) {
|
|
707
|
-
j(this, x, ui).call(this, e), _(this,
|
|
708
|
-
_(this, nt, !1), c(this, Te) && zt(c(this, Te), c(this,
|
|
707
|
+
j(this, x, ui).call(this, e), _(this, Be, c(this, Be) + e), !(!c(this, Te) || c(this, nt)) && (_(this, nt, !0), qe(() => {
|
|
708
|
+
_(this, nt, !1), c(this, Te) && zt(c(this, Te), c(this, Be));
|
|
709
709
|
}));
|
|
710
710
|
}
|
|
711
711
|
get_effect_pending() {
|
|
712
|
-
return c(this,
|
|
712
|
+
return c(this, Gt).call(this), d(
|
|
713
713
|
/** @type {Source<number>} */
|
|
714
714
|
c(this, Te)
|
|
715
715
|
);
|
|
@@ -720,7 +720,7 @@ class ls {
|
|
|
720
720
|
let n = c(this, ye).failed;
|
|
721
721
|
if (!i && !n)
|
|
722
722
|
throw e;
|
|
723
|
-
c(this, le) && (z(c(this, le)), _(this, le, null)), c(this,
|
|
723
|
+
c(this, le) && (z(c(this, le)), _(this, le, null)), c(this, B) && (z(c(this, B)), _(this, B, null)), c(this, ae) && (z(c(this, ae)), _(this, ae, null)), E && (re(
|
|
724
724
|
/** @type {TemplateNode} */
|
|
725
725
|
c(this, Et)
|
|
726
726
|
), gn(), re(mn()));
|
|
@@ -767,28 +767,28 @@ class ls {
|
|
|
767
767
|
});
|
|
768
768
|
}
|
|
769
769
|
}
|
|
770
|
-
K = new WeakMap(), Et = new WeakMap(), ye = new WeakMap(),
|
|
770
|
+
K = new WeakMap(), Et = new WeakMap(), ye = new WeakMap(), Ge = new WeakMap(), oe = new WeakMap(), le = new WeakMap(), B = new WeakMap(), ae = new WeakMap(), we = new WeakMap(), Be = new WeakMap(), Me = new WeakMap(), nt = new WeakMap(), rt = new WeakMap(), st = new WeakMap(), Te = new WeakMap(), Gt = new WeakMap(), x = new WeakSet(), Ln = function() {
|
|
771
771
|
try {
|
|
772
|
-
_(this, le, Le(() => c(this,
|
|
772
|
+
_(this, le, Le(() => c(this, Ge).call(this, c(this, K))));
|
|
773
773
|
} catch (e) {
|
|
774
774
|
this.error(e);
|
|
775
775
|
}
|
|
776
776
|
}, Mn = function() {
|
|
777
777
|
const e = c(this, ye).pending;
|
|
778
|
-
e && (this.is_pending = !0, _(this,
|
|
778
|
+
e && (this.is_pending = !0, _(this, B, Le(() => e(c(this, K)))), qe(() => {
|
|
779
779
|
var i = _(this, we, document.createDocumentFragment()), n = ke();
|
|
780
|
-
i.append(n), _(this, le, j(this, x, Pt).call(this, () => (Ee.ensure(), Le(() => c(this,
|
|
780
|
+
i.append(n), _(this, le, j(this, x, Pt).call(this, () => (Ee.ensure(), Le(() => c(this, Ge).call(this, n))))), c(this, Me) === 0 && (c(this, K).before(i), _(this, we, null), bt(
|
|
781
781
|
/** @type {Effect} */
|
|
782
|
-
c(this,
|
|
782
|
+
c(this, B),
|
|
783
783
|
() => {
|
|
784
|
-
_(this,
|
|
784
|
+
_(this, B, null);
|
|
785
785
|
}
|
|
786
786
|
), this.is_pending = !1);
|
|
787
787
|
}));
|
|
788
788
|
}, ci = function() {
|
|
789
789
|
try {
|
|
790
|
-
if (this.is_pending = this.has_pending_snippet(), _(this, Me, 0), _(this,
|
|
791
|
-
c(this,
|
|
790
|
+
if (this.is_pending = this.has_pending_snippet(), _(this, Me, 0), _(this, Be, 0), _(this, le, Le(() => {
|
|
791
|
+
c(this, Ge).call(this, c(this, K));
|
|
792
792
|
})), c(this, Me) > 0) {
|
|
793
793
|
var e = _(this, we, document.createDocumentFragment());
|
|
794
794
|
Kn(c(this, le), e);
|
|
@@ -796,7 +796,7 @@ K = new WeakMap(), Et = new WeakMap(), ye = new WeakMap(), Be = new WeakMap(), o
|
|
|
796
796
|
/** @type {(anchor: Node) => void} */
|
|
797
797
|
c(this, ye).pending
|
|
798
798
|
);
|
|
799
|
-
_(this,
|
|
799
|
+
_(this, B, Le(() => i(c(this, K))));
|
|
800
800
|
} else
|
|
801
801
|
this.is_pending = !1;
|
|
802
802
|
} catch (i) {
|
|
@@ -833,8 +833,8 @@ ui = function(e) {
|
|
|
833
833
|
L(n, D), te(n);
|
|
834
834
|
for (const n of c(this, st))
|
|
835
835
|
L(n, ne), te(n);
|
|
836
|
-
c(this, rt).clear(), c(this, st).clear(), c(this,
|
|
837
|
-
_(this,
|
|
836
|
+
c(this, rt).clear(), c(this, st).clear(), c(this, B) && bt(c(this, B), () => {
|
|
837
|
+
_(this, B, null);
|
|
838
838
|
}), c(this, we) && (c(this, K).before(c(this, we)), _(this, we, null));
|
|
839
839
|
}
|
|
840
840
|
};
|
|
@@ -845,7 +845,7 @@ function as(t, e, i, n) {
|
|
|
845
845
|
n(e.map(r));
|
|
846
846
|
return;
|
|
847
847
|
}
|
|
848
|
-
var o =
|
|
848
|
+
var o = O, l = (
|
|
849
849
|
/** @type {Effect} */
|
|
850
850
|
$
|
|
851
851
|
), a = cs(), u = s.length === 1 ? s[0].promise : s.length > 1 ? Promise.all(s.map((h) => h.promise)) : null;
|
|
@@ -868,7 +868,7 @@ function as(t, e, i, n) {
|
|
|
868
868
|
u ? u.then(p) : p();
|
|
869
869
|
}
|
|
870
870
|
function cs() {
|
|
871
|
-
var t = $, e = T, i = q, n =
|
|
871
|
+
var t = $, e = T, i = q, n = O;
|
|
872
872
|
return function(s = !0) {
|
|
873
873
|
fe(t), Q(e), ct(i), s && n?.activate();
|
|
874
874
|
};
|
|
@@ -914,7 +914,7 @@ function us(t, e, i) {
|
|
|
914
914
|
/** @type {Promise<V>} */
|
|
915
915
|
/** @type {unknown} */
|
|
916
916
|
void 0
|
|
917
|
-
), o =
|
|
917
|
+
), o = Ot(
|
|
918
918
|
/** @type {V} */
|
|
919
919
|
C
|
|
920
920
|
), l = !T, a = /* @__PURE__ */ new Map();
|
|
@@ -923,14 +923,14 @@ function us(t, e, i) {
|
|
|
923
923
|
s = u.promise;
|
|
924
924
|
try {
|
|
925
925
|
Promise.resolve(t()).then(u.resolve, u.reject).then(() => {
|
|
926
|
-
f ===
|
|
926
|
+
f === O && f.committed && f.deactivate(), fi();
|
|
927
927
|
});
|
|
928
928
|
} catch (v) {
|
|
929
929
|
u.reject(v), fi();
|
|
930
930
|
}
|
|
931
931
|
var f = (
|
|
932
932
|
/** @type {Batch} */
|
|
933
|
-
|
|
933
|
+
O
|
|
934
934
|
);
|
|
935
935
|
if (l) {
|
|
936
936
|
var p = r.is_rendered();
|
|
@@ -1001,11 +1001,11 @@ function Ii(t) {
|
|
|
1001
1001
|
}
|
|
1002
1002
|
function Vn(t) {
|
|
1003
1003
|
var e = Ii(t);
|
|
1004
|
-
if (!t.equals(e) && (t.wv = Jn(), (!
|
|
1004
|
+
if (!t.equals(e) && (t.wv = Jn(), (!O?.is_fork || t.deps === null) && (t.v = e, t.deps === null))) {
|
|
1005
1005
|
L(t, N);
|
|
1006
1006
|
return;
|
|
1007
1007
|
}
|
|
1008
|
-
Ce || (ee !== null ? (Ei() ||
|
|
1008
|
+
Ce || (ee !== null ? (Ei() || O?.is_fork) && ee.set(t, e) : wi(t));
|
|
1009
1009
|
}
|
|
1010
1010
|
function hs(t) {
|
|
1011
1011
|
if (t.effects !== null)
|
|
@@ -1020,7 +1020,7 @@ function Nn(t) {
|
|
|
1020
1020
|
let di = /* @__PURE__ */ new Set();
|
|
1021
1021
|
const Ne = /* @__PURE__ */ new Map();
|
|
1022
1022
|
let Cn = !1;
|
|
1023
|
-
function
|
|
1023
|
+
function Ot(t, e) {
|
|
1024
1024
|
var i = {
|
|
1025
1025
|
f: 0,
|
|
1026
1026
|
// TODO ideally we could skip this altogether, but it causes type errors
|
|
@@ -1033,13 +1033,13 @@ function Rt(t, e) {
|
|
|
1033
1033
|
return i;
|
|
1034
1034
|
}
|
|
1035
1035
|
// @__NO_SIDE_EFFECTS__
|
|
1036
|
-
function
|
|
1037
|
-
const i =
|
|
1036
|
+
function R(t, e) {
|
|
1037
|
+
const i = Ot(t);
|
|
1038
1038
|
return Wn(i), i;
|
|
1039
1039
|
}
|
|
1040
1040
|
// @__NO_SIDE_EFFECTS__
|
|
1041
1041
|
function ps(t, e = !1, i = !0) {
|
|
1042
|
-
const n =
|
|
1042
|
+
const n = Ot(t);
|
|
1043
1043
|
return e || (n.equals = Zr), n;
|
|
1044
1044
|
}
|
|
1045
1045
|
function A(t, e, i = !1) {
|
|
@@ -1068,7 +1068,7 @@ function zt(t, e) {
|
|
|
1068
1068
|
function vs() {
|
|
1069
1069
|
Cn = !1;
|
|
1070
1070
|
for (const t of di)
|
|
1071
|
-
(t.f & N) !== 0 && L(t, ne),
|
|
1071
|
+
(t.f & N) !== 0 && L(t, ne), Rt(t) && ft(t);
|
|
1072
1072
|
di.clear();
|
|
1073
1073
|
}
|
|
1074
1074
|
function _t(t) {
|
|
@@ -1100,7 +1100,7 @@ function $e(t) {
|
|
|
1100
1100
|
const e = dn(t);
|
|
1101
1101
|
if (e !== Vr && e !== Nr)
|
|
1102
1102
|
return t;
|
|
1103
|
-
var i = /* @__PURE__ */ new Map(), n =
|
|
1103
|
+
var i = /* @__PURE__ */ new Map(), n = Or(t), r = /* @__PURE__ */ R(0), s = Ue, o = (l) => {
|
|
1104
1104
|
if (Ue === s)
|
|
1105
1105
|
return l();
|
|
1106
1106
|
var a = T, u = Ue;
|
|
@@ -1108,7 +1108,7 @@ function $e(t) {
|
|
|
1108
1108
|
var f = l();
|
|
1109
1109
|
return Q(a), Xi(u), f;
|
|
1110
1110
|
};
|
|
1111
|
-
return n && i.set("length", /* @__PURE__ */
|
|
1111
|
+
return n && i.set("length", /* @__PURE__ */ R(
|
|
1112
1112
|
/** @type {any[]} */
|
|
1113
1113
|
t.length
|
|
1114
1114
|
)), new Proxy(
|
|
@@ -1119,7 +1119,7 @@ function $e(t) {
|
|
|
1119
1119
|
(!("value" in u) || u.configurable === !1 || u.enumerable === !1 || u.writable === !1) && qr();
|
|
1120
1120
|
var f = i.get(a);
|
|
1121
1121
|
return f === void 0 ? o(() => {
|
|
1122
|
-
var p = /* @__PURE__ */
|
|
1122
|
+
var p = /* @__PURE__ */ R(u.value);
|
|
1123
1123
|
return i.set(a, p), p;
|
|
1124
1124
|
}) : A(f, u.value, !0), !0;
|
|
1125
1125
|
},
|
|
@@ -1127,7 +1127,7 @@ function $e(t) {
|
|
|
1127
1127
|
var u = i.get(a);
|
|
1128
1128
|
if (u === void 0) {
|
|
1129
1129
|
if (a in l) {
|
|
1130
|
-
const f = o(() => /* @__PURE__ */
|
|
1130
|
+
const f = o(() => /* @__PURE__ */ R(C));
|
|
1131
1131
|
i.set(a, f), _t(r);
|
|
1132
1132
|
}
|
|
1133
1133
|
} else
|
|
@@ -1139,7 +1139,7 @@ function $e(t) {
|
|
|
1139
1139
|
return t;
|
|
1140
1140
|
var f = i.get(a), p = a in l;
|
|
1141
1141
|
if (f === void 0 && (!p || Qe(l, a)?.writable) && (f = o(() => {
|
|
1142
|
-
var v = $e(p ? l[a] : C), g = /* @__PURE__ */
|
|
1142
|
+
var v = $e(p ? l[a] : C), g = /* @__PURE__ */ R(v);
|
|
1143
1143
|
return g;
|
|
1144
1144
|
}), i.set(a, f)), f !== void 0) {
|
|
1145
1145
|
var h = d(f);
|
|
@@ -1170,7 +1170,7 @@ function $e(t) {
|
|
|
1170
1170
|
var u = i.get(a), f = u !== void 0 && u.v !== C || Reflect.has(l, a);
|
|
1171
1171
|
if (u !== void 0 || $ !== null && (!f || Qe(l, a)?.writable)) {
|
|
1172
1172
|
u === void 0 && (u = o(() => {
|
|
1173
|
-
var h = f ? $e(l[a]) : C, v = /* @__PURE__ */
|
|
1173
|
+
var h = f ? $e(l[a]) : C, v = /* @__PURE__ */ R(h);
|
|
1174
1174
|
return v;
|
|
1175
1175
|
}), i.set(a, u));
|
|
1176
1176
|
var p = d(u);
|
|
@@ -1185,10 +1185,10 @@ function $e(t) {
|
|
|
1185
1185
|
for (var v = u; v < /** @type {Source<number>} */
|
|
1186
1186
|
p.v; v += 1) {
|
|
1187
1187
|
var g = i.get(v + "");
|
|
1188
|
-
g !== void 0 ? A(g, C) : v in l && (g = o(() => /* @__PURE__ */
|
|
1188
|
+
g !== void 0 ? A(g, C) : v in l && (g = o(() => /* @__PURE__ */ R(C)), i.set(v + "", g));
|
|
1189
1189
|
}
|
|
1190
1190
|
if (p === void 0)
|
|
1191
|
-
(!h || Qe(l, a)?.writable) && (p = o(() => /* @__PURE__ */
|
|
1191
|
+
(!h || Qe(l, a)?.writable) && (p = o(() => /* @__PURE__ */ R(void 0)), A(p, $e(u)), i.set(a, p));
|
|
1192
1192
|
else {
|
|
1193
1193
|
h = p.v !== C;
|
|
1194
1194
|
var I = o(() => $e(u));
|
|
@@ -1242,7 +1242,7 @@ function wt(t) {
|
|
|
1242
1242
|
);
|
|
1243
1243
|
}
|
|
1244
1244
|
// @__NO_SIDE_EFFECTS__
|
|
1245
|
-
function
|
|
1245
|
+
function Oe(t) {
|
|
1246
1246
|
return (
|
|
1247
1247
|
/** @type {TemplateNode | null} */
|
|
1248
1248
|
jn.call(t)
|
|
@@ -1266,7 +1266,7 @@ function Ui(t, e) {
|
|
|
1266
1266
|
function ti(t, e = !1) {
|
|
1267
1267
|
if (!E) {
|
|
1268
1268
|
var i = /* @__PURE__ */ wt(t);
|
|
1269
|
-
return i instanceof Comment && i.data === "" ? /* @__PURE__ */
|
|
1269
|
+
return i instanceof Comment && i.data === "" ? /* @__PURE__ */ Oe(i) : i;
|
|
1270
1270
|
}
|
|
1271
1271
|
if (e) {
|
|
1272
1272
|
if (S?.nodeType !== qt) {
|
|
@@ -1284,7 +1284,7 @@ function vt(t, e = 1, i = !1) {
|
|
|
1284
1284
|
let n = E ? S : t;
|
|
1285
1285
|
for (var r; e--; )
|
|
1286
1286
|
r = n, n = /** @type {TemplateNode} */
|
|
1287
|
-
/* @__PURE__ */
|
|
1287
|
+
/* @__PURE__ */ Oe(n);
|
|
1288
1288
|
if (!E)
|
|
1289
1289
|
return n;
|
|
1290
1290
|
if (i) {
|
|
@@ -1332,7 +1332,7 @@ function Fn(t) {
|
|
|
1332
1332
|
}
|
|
1333
1333
|
}
|
|
1334
1334
|
function _s(t) {
|
|
1335
|
-
$ === null && (T === null &&
|
|
1335
|
+
$ === null && (T === null && Gr(), zr()), Ce && Hr();
|
|
1336
1336
|
}
|
|
1337
1337
|
function bs(t, e) {
|
|
1338
1338
|
var i = e.last;
|
|
@@ -1430,14 +1430,14 @@ function Ki(t, e = [], i = [], n = []) {
|
|
|
1430
1430
|
pe(Yt, () => t(...r.map(d)), !0);
|
|
1431
1431
|
});
|
|
1432
1432
|
}
|
|
1433
|
-
function
|
|
1433
|
+
function Gn(t, e = 0) {
|
|
1434
1434
|
var i = pe(Ae | e, t, !0);
|
|
1435
1435
|
return i;
|
|
1436
1436
|
}
|
|
1437
1437
|
function Le(t) {
|
|
1438
1438
|
return pe(he | We, t, !0);
|
|
1439
1439
|
}
|
|
1440
|
-
function
|
|
1440
|
+
function Bn(t) {
|
|
1441
1441
|
var e = t.teardown;
|
|
1442
1442
|
if (e !== null) {
|
|
1443
1443
|
const i = Ce, n = T;
|
|
@@ -1477,13 +1477,13 @@ function z(t, e = !0) {
|
|
|
1477
1477
|
if (n !== null)
|
|
1478
1478
|
for (const s of n)
|
|
1479
1479
|
s.stop();
|
|
1480
|
-
|
|
1480
|
+
Bn(t);
|
|
1481
1481
|
var r = t.parent;
|
|
1482
1482
|
r !== null && r.first !== null && Yn(t), t.next = t.prev = t.teardown = t.ctx = t.deps = t.fn = t.nodes = t.ac = null;
|
|
1483
1483
|
}
|
|
1484
1484
|
function Ss(t, e) {
|
|
1485
1485
|
for (; t !== null; ) {
|
|
1486
|
-
var i = t === e ? null : /* @__PURE__ */
|
|
1486
|
+
var i = t === e ? null : /* @__PURE__ */ Oe(t);
|
|
1487
1487
|
t.remove(), t = i;
|
|
1488
1488
|
}
|
|
1489
1489
|
}
|
|
@@ -1539,7 +1539,7 @@ function Un(t, e) {
|
|
|
1539
1539
|
function Kn(t, e) {
|
|
1540
1540
|
if (t.nodes)
|
|
1541
1541
|
for (var i = t.nodes.start, n = t.nodes.end; i !== null; ) {
|
|
1542
|
-
var r = i === n ? null : /* @__PURE__ */
|
|
1542
|
+
var r = i === n ? null : /* @__PURE__ */ Oe(i);
|
|
1543
1543
|
e.append(i), i = r;
|
|
1544
1544
|
}
|
|
1545
1545
|
}
|
|
@@ -1559,7 +1559,7 @@ let J = null;
|
|
|
1559
1559
|
function Wn(t) {
|
|
1560
1560
|
T !== null && (J === null ? J = [t] : J.push(t));
|
|
1561
1561
|
}
|
|
1562
|
-
let H = null,
|
|
1562
|
+
let H = null, G = 0, U = null;
|
|
1563
1563
|
function ks(t) {
|
|
1564
1564
|
U = t;
|
|
1565
1565
|
}
|
|
@@ -1570,7 +1570,7 @@ function Xi(t) {
|
|
|
1570
1570
|
function Jn() {
|
|
1571
1571
|
return ++Xn;
|
|
1572
1572
|
}
|
|
1573
|
-
function
|
|
1573
|
+
function Rt(t) {
|
|
1574
1574
|
var e = t.f;
|
|
1575
1575
|
if ((e & D) !== 0)
|
|
1576
1576
|
return !0;
|
|
@@ -1580,7 +1580,7 @@ function Ot(t) {
|
|
|
1580
1580
|
t.deps
|
|
1581
1581
|
), n = i.length, r = 0; r < n; r++) {
|
|
1582
1582
|
var s = i[r];
|
|
1583
|
-
if (
|
|
1583
|
+
if (Rt(
|
|
1584
1584
|
/** @type {Derived} */
|
|
1585
1585
|
s
|
|
1586
1586
|
) && Vn(
|
|
@@ -1613,9 +1613,9 @@ function Qn(t, e, i = !0) {
|
|
|
1613
1613
|
}
|
|
1614
1614
|
function Zn(t) {
|
|
1615
1615
|
var I;
|
|
1616
|
-
var e = H, i =
|
|
1616
|
+
var e = H, i = G, n = U, r = T, s = J, o = q, l = ie, a = Ue, u = t.f;
|
|
1617
1617
|
H = /** @type {null | Value[]} */
|
|
1618
|
-
null,
|
|
1618
|
+
null, G = 0, U = null, T = (u & (he | Pe)) === 0 ? t : null, J = null, ct(t.ctx), ie = !1, Ue = ++je, t.ac !== null && (Fn(() => {
|
|
1619
1619
|
t.ac.abort(De);
|
|
1620
1620
|
}), t.ac = null);
|
|
1621
1621
|
try {
|
|
@@ -1625,18 +1625,18 @@ function Zn(t) {
|
|
|
1625
1625
|
t.fn
|
|
1626
1626
|
), p = f();
|
|
1627
1627
|
t.f |= dt;
|
|
1628
|
-
var h = t.deps, v =
|
|
1628
|
+
var h = t.deps, v = O?.is_fork;
|
|
1629
1629
|
if (H !== null) {
|
|
1630
1630
|
var g;
|
|
1631
|
-
if (v || Tt(t,
|
|
1632
|
-
for (h.length =
|
|
1633
|
-
h[
|
|
1631
|
+
if (v || Tt(t, G), h !== null && G > 0)
|
|
1632
|
+
for (h.length = G + H.length, g = 0; g < H.length; g++)
|
|
1633
|
+
h[G + g] = H[g];
|
|
1634
1634
|
else
|
|
1635
1635
|
t.deps = h = H;
|
|
1636
1636
|
if (Ei() && (t.f & X) !== 0)
|
|
1637
|
-
for (g =
|
|
1637
|
+
for (g = G; g < h.length; g++)
|
|
1638
1638
|
((I = h[g]).reactions ?? (I.reactions = [])).push(t);
|
|
1639
|
-
} else !v && h !== null &&
|
|
1639
|
+
} else !v && h !== null && G < h.length && (Tt(t, G), h.length = G);
|
|
1640
1640
|
if (wn() && U !== null && !ie && h !== null && (t.f & (P | ne | D)) === 0)
|
|
1641
1641
|
for (g = 0; g < /** @type {Source[]} */
|
|
1642
1642
|
U.length; g++)
|
|
@@ -1659,13 +1659,13 @@ function Zn(t) {
|
|
|
1659
1659
|
} catch (m) {
|
|
1660
1660
|
return In(m);
|
|
1661
1661
|
} finally {
|
|
1662
|
-
t.f ^= ri, H = e,
|
|
1662
|
+
t.f ^= ri, H = e, G = i, U = n, T = r, J = s, ct(o), ie = l, Ue = a;
|
|
1663
1663
|
}
|
|
1664
1664
|
}
|
|
1665
1665
|
function As(t, e) {
|
|
1666
1666
|
let i = e.reactions;
|
|
1667
1667
|
if (i !== null) {
|
|
1668
|
-
var n =
|
|
1668
|
+
var n = Rr.call(i, t);
|
|
1669
1669
|
if (n !== -1) {
|
|
1670
1670
|
var r = i.length - 1;
|
|
1671
1671
|
r === 0 ? i = e.reactions = null : (i[n] = i[r], i.pop());
|
|
@@ -1695,7 +1695,7 @@ function ft(t) {
|
|
|
1695
1695
|
var i = $, n = Dt;
|
|
1696
1696
|
$ = t, Dt = !0;
|
|
1697
1697
|
try {
|
|
1698
|
-
(e & (Ae | pn)) !== 0 ? $s(t) : Ai(t),
|
|
1698
|
+
(e & (Ae | pn)) !== 0 ? $s(t) : Ai(t), Bn(t);
|
|
1699
1699
|
var r = Zn(t);
|
|
1700
1700
|
t.teardown = typeof r == "function" ? r : null, t.wv = Xn;
|
|
1701
1701
|
var s;
|
|
@@ -1712,7 +1712,7 @@ function d(t) {
|
|
|
1712
1712
|
if (!n && (J === null || !lt.call(J, t))) {
|
|
1713
1713
|
var r = T.deps;
|
|
1714
1714
|
if ((T.f & ri) !== 0)
|
|
1715
|
-
t.rv < je && (t.rv = je, H === null && r !== null && r[
|
|
1715
|
+
t.rv < je && (t.rv = je, H === null && r !== null && r[G] === t ? G++ : H === null ? H = [t] : H.push(t));
|
|
1716
1716
|
else {
|
|
1717
1717
|
(T.deps ?? (T.deps = [])).push(t);
|
|
1718
1718
|
var s = t.reactions;
|
|
@@ -1732,7 +1732,7 @@ function d(t) {
|
|
|
1732
1732
|
return ((o.f & N) === 0 && o.reactions !== null || tr(o)) && (l = Ii(o)), Ne.set(o, l), l;
|
|
1733
1733
|
}
|
|
1734
1734
|
var a = (o.f & X) === 0 && !ie && T !== null && (Dt || (T.f & X) !== 0), u = (o.f & dt) === 0;
|
|
1735
|
-
|
|
1735
|
+
Rt(o) && (a && (o.f |= X), Vn(o)), a && !u && (Nn(o), er(o));
|
|
1736
1736
|
}
|
|
1737
1737
|
if (ee?.has(t))
|
|
1738
1738
|
return ee.get(t);
|
|
@@ -1762,7 +1762,7 @@ function tr(t) {
|
|
|
1762
1762
|
return !0;
|
|
1763
1763
|
return !1;
|
|
1764
1764
|
}
|
|
1765
|
-
function
|
|
1765
|
+
function Oi(t) {
|
|
1766
1766
|
var e = ie;
|
|
1767
1767
|
try {
|
|
1768
1768
|
return ie = !0, t();
|
|
@@ -1774,7 +1774,7 @@ const Fe = /* @__PURE__ */ Symbol("events"), ir = /* @__PURE__ */ new Set(), pi
|
|
|
1774
1774
|
function Ji(t, e, i) {
|
|
1775
1775
|
(e[Fe] ?? (e[Fe] = {}))[t] = i;
|
|
1776
1776
|
}
|
|
1777
|
-
function
|
|
1777
|
+
function Os(t) {
|
|
1778
1778
|
for (var e = 0; e < t.length; e++)
|
|
1779
1779
|
ir.add(t[e]);
|
|
1780
1780
|
for (var i of pi)
|
|
@@ -1842,7 +1842,7 @@ function Zi(t) {
|
|
|
1842
1842
|
}
|
|
1843
1843
|
}
|
|
1844
1844
|
}
|
|
1845
|
-
const
|
|
1845
|
+
const Rs = (
|
|
1846
1846
|
// We gotta write it like this because after downleveling the pure comment may end up in the wrong location
|
|
1847
1847
|
globalThis?.window?.trustedTypes && /* @__PURE__ */ globalThis.window.trustedTypes.createPolicy("svelte-trusted-html", {
|
|
1848
1848
|
/** @param {string} html */
|
|
@@ -1852,7 +1852,7 @@ const Os = (
|
|
|
1852
1852
|
function Ls(t) {
|
|
1853
1853
|
return (
|
|
1854
1854
|
/** @type {string} */
|
|
1855
|
-
|
|
1855
|
+
Rs?.createHTML(t) ?? t
|
|
1856
1856
|
);
|
|
1857
1857
|
}
|
|
1858
1858
|
function Ms(t, e = !1) {
|
|
@@ -1927,7 +1927,7 @@ function Ds(t, e) {
|
|
|
1927
1927
|
try {
|
|
1928
1928
|
for (var s = /* @__PURE__ */ wt(i); s && (s.nodeType !== Ut || /** @type {Comment} */
|
|
1929
1929
|
s.data !== mi); )
|
|
1930
|
-
s = /* @__PURE__ */
|
|
1930
|
+
s = /* @__PURE__ */ Oe(s);
|
|
1931
1931
|
if (!s)
|
|
1932
1932
|
throw ot;
|
|
1933
1933
|
Je(!0), re(
|
|
@@ -2011,7 +2011,7 @@ function xs(t, e) {
|
|
|
2011
2011
|
const i = vi.get(t);
|
|
2012
2012
|
return i ? (vi.delete(t), i(e)) : Promise.resolve();
|
|
2013
2013
|
}
|
|
2014
|
-
var Z, ce, Y, Ye, kt, At,
|
|
2014
|
+
var Z, ce, Y, Ye, kt, At, Bt;
|
|
2015
2015
|
class js {
|
|
2016
2016
|
/**
|
|
2017
2017
|
* @param {TemplateNode} anchor
|
|
@@ -2056,7 +2056,7 @@ class js {
|
|
|
2056
2056
|
w(this, At, () => {
|
|
2057
2057
|
var e = (
|
|
2058
2058
|
/** @type {Batch} */
|
|
2059
|
-
|
|
2059
|
+
O
|
|
2060
2060
|
);
|
|
2061
2061
|
if (c(this, Z).has(e)) {
|
|
2062
2062
|
var i = (
|
|
@@ -2092,7 +2092,7 @@ class js {
|
|
|
2092
2092
|
/**
|
|
2093
2093
|
* @param {Batch} batch
|
|
2094
2094
|
*/
|
|
2095
|
-
w(this,
|
|
2095
|
+
w(this, Bt, (e) => {
|
|
2096
2096
|
c(this, Z).delete(e);
|
|
2097
2097
|
const i = Array.from(c(this, Z).values());
|
|
2098
2098
|
for (const [n, r] of c(this, Y))
|
|
@@ -2108,7 +2108,7 @@ class js {
|
|
|
2108
2108
|
ensure(e, i) {
|
|
2109
2109
|
var n = (
|
|
2110
2110
|
/** @type {Batch} */
|
|
2111
|
-
|
|
2111
|
+
O
|
|
2112
2112
|
), r = ms();
|
|
2113
2113
|
if (i && !c(this, ce).has(e) && !c(this, Y).has(e))
|
|
2114
2114
|
if (r) {
|
|
@@ -2127,15 +2127,15 @@ class js {
|
|
|
2127
2127
|
l === e ? n.unskip_effect(a) : n.skip_effect(a);
|
|
2128
2128
|
for (const [l, a] of c(this, Y))
|
|
2129
2129
|
l === e ? n.unskip_effect(a.effect) : n.skip_effect(a.effect);
|
|
2130
|
-
n.oncommit(c(this, At)), n.ondiscard(c(this,
|
|
2130
|
+
n.oncommit(c(this, At)), n.ondiscard(c(this, Bt));
|
|
2131
2131
|
} else
|
|
2132
2132
|
E && (this.anchor = S), c(this, At).call(this);
|
|
2133
2133
|
}
|
|
2134
2134
|
}
|
|
2135
|
-
Z = new WeakMap(), ce = new WeakMap(), Y = new WeakMap(), Ye = new WeakMap(), kt = new WeakMap(), At = new WeakMap(),
|
|
2135
|
+
Z = new WeakMap(), ce = new WeakMap(), Y = new WeakMap(), Ye = new WeakMap(), kt = new WeakMap(), At = new WeakMap(), Bt = new WeakMap();
|
|
2136
2136
|
function Fs(t) {
|
|
2137
2137
|
q === null && jr(), gt(() => {
|
|
2138
|
-
const e =
|
|
2138
|
+
const e = Oi(t);
|
|
2139
2139
|
if (typeof e == "function") return (
|
|
2140
2140
|
/** @type {() => void} */
|
|
2141
2141
|
e
|
|
@@ -2157,7 +2157,7 @@ function en(t, e, i = !1) {
|
|
|
2157
2157
|
}
|
|
2158
2158
|
n.ensure(o, l);
|
|
2159
2159
|
}
|
|
2160
|
-
|
|
2160
|
+
Gn(() => {
|
|
2161
2161
|
var o = !1;
|
|
2162
2162
|
e((l, a = 0) => {
|
|
2163
2163
|
o = !0, s(a, l);
|
|
@@ -2199,10 +2199,10 @@ function zs(t, e, i) {
|
|
|
2199
2199
|
}
|
|
2200
2200
|
return n === "" ? null : n;
|
|
2201
2201
|
}
|
|
2202
|
-
function
|
|
2202
|
+
function Gs(t, e) {
|
|
2203
2203
|
return t == null ? null : String(t);
|
|
2204
2204
|
}
|
|
2205
|
-
function
|
|
2205
|
+
function Bs(t, e, i, n, r, s) {
|
|
2206
2206
|
var o = t.__className;
|
|
2207
2207
|
if (E || o !== i || o === void 0) {
|
|
2208
2208
|
var l = zs(i, n, s);
|
|
@@ -2217,7 +2217,7 @@ function Gs(t, e, i, n, r, s) {
|
|
|
2217
2217
|
function Xe(t, e, i, n) {
|
|
2218
2218
|
var r = t.__style;
|
|
2219
2219
|
if (E || r !== e) {
|
|
2220
|
-
var s =
|
|
2220
|
+
var s = Gs(e);
|
|
2221
2221
|
(!E || s !== t.getAttribute("style")) && (s == null ? t.removeAttribute("style") : t.style.cssText = s), t.__style = e;
|
|
2222
2222
|
}
|
|
2223
2223
|
return n;
|
|
@@ -2257,7 +2257,7 @@ function Xs(t = {}, e, i, n) {
|
|
|
2257
2257
|
return zn(() => {
|
|
2258
2258
|
var r, s;
|
|
2259
2259
|
return ki(() => {
|
|
2260
|
-
r = s, s = [],
|
|
2260
|
+
r = s, s = [], Oi(() => {
|
|
2261
2261
|
t !== i(...s) && (e(t, ...s), r && rn(i(...r), t) && e(null, ...r));
|
|
2262
2262
|
});
|
|
2263
2263
|
}), () => {
|
|
@@ -2954,7 +2954,7 @@ function ho(t) {
|
|
|
2954
2954
|
function ar(t) {
|
|
2955
2955
|
return t.level === "element";
|
|
2956
2956
|
}
|
|
2957
|
-
function
|
|
2957
|
+
function Ri(t) {
|
|
2958
2958
|
if (ar(t)) {
|
|
2959
2959
|
const e = t.item.config;
|
|
2960
2960
|
if (!e)
|
|
@@ -3026,7 +3026,7 @@ function Oi(t) {
|
|
|
3026
3026
|
return "";
|
|
3027
3027
|
}
|
|
3028
3028
|
function Xt(t) {
|
|
3029
|
-
const e =
|
|
3029
|
+
const e = Ri(t);
|
|
3030
3030
|
return [
|
|
3031
3031
|
/<math[>\s]/i,
|
|
3032
3032
|
// MathML
|
|
@@ -3073,10 +3073,10 @@ function po(t) {
|
|
|
3073
3073
|
return !1;
|
|
3074
3074
|
}
|
|
3075
3075
|
function Jt(t) {
|
|
3076
|
-
return
|
|
3076
|
+
return Ri(t).trim().length >= 10;
|
|
3077
3077
|
}
|
|
3078
3078
|
function vo(t) {
|
|
3079
|
-
const e =
|
|
3079
|
+
const e = Ri(t);
|
|
3080
3080
|
return [
|
|
3081
3081
|
/chemistry|chemical|element|atom|molecule|compound/i,
|
|
3082
3082
|
/periodic\s+table/i,
|
|
@@ -3484,7 +3484,7 @@ const bo = /* @__PURE__ */ new Set([
|
|
|
3484
3484
|
}
|
|
3485
3485
|
};
|
|
3486
3486
|
}
|
|
3487
|
-
},
|
|
3487
|
+
}, Oo = {
|
|
3488
3488
|
toolId: "highlighter",
|
|
3489
3489
|
name: "Highlighter",
|
|
3490
3490
|
description: "Highlight text",
|
|
@@ -3525,7 +3525,7 @@ const bo = /* @__PURE__ */ new Set([
|
|
|
3525
3525
|
}
|
|
3526
3526
|
};
|
|
3527
3527
|
}
|
|
3528
|
-
},
|
|
3528
|
+
}, Ro = {
|
|
3529
3529
|
toolId: "lineReader",
|
|
3530
3530
|
name: "Line Reader",
|
|
3531
3531
|
description: "Reading guide overlay",
|
|
@@ -3785,8 +3785,20 @@ const bo = /* @__PURE__ */ new Set([
|
|
|
3785
3785
|
}
|
|
3786
3786
|
};
|
|
3787
3787
|
}
|
|
3788
|
-
}
|
|
3789
|
-
|
|
3788
|
+
}, Po = [
|
|
3789
|
+
$o,
|
|
3790
|
+
So,
|
|
3791
|
+
Eo,
|
|
3792
|
+
ko,
|
|
3793
|
+
Ao,
|
|
3794
|
+
Oo,
|
|
3795
|
+
Ro,
|
|
3796
|
+
Mo,
|
|
3797
|
+
Vo,
|
|
3798
|
+
No,
|
|
3799
|
+
Co
|
|
3800
|
+
];
|
|
3801
|
+
function Do(t = {}) {
|
|
3790
3802
|
const e = new uo(), i = {
|
|
3791
3803
|
toolTagMap: {
|
|
3792
3804
|
...cr,
|
|
@@ -3795,17 +3807,25 @@ function Po(t = {}) {
|
|
|
3795
3807
|
toolComponentFactory: t.toolComponentFactory,
|
|
3796
3808
|
toolComponentFactories: t.toolComponentFactories
|
|
3797
3809
|
}, n = (r) => t.overrides?.[r.toolId] || r;
|
|
3798
|
-
return
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3810
|
+
return t.includePackagedTools && xo(e, {
|
|
3811
|
+
toolIds: t.toolIds,
|
|
3812
|
+
applyOverrides: n
|
|
3813
|
+
}), t.toolModuleLoaders && Object.keys(t.toolModuleLoaders).length > 0 && e.setToolModuleLoaders(t.toolModuleLoaders), e.setComponentOverrides(i), e;
|
|
3814
|
+
}
|
|
3815
|
+
function xo(t, e = {}) {
|
|
3816
|
+
const i = e.toolIds && e.toolIds.length > 0 ? new Set(e.toolIds) : null, n = e.applyOverrides || ((r) => r);
|
|
3817
|
+
for (const r of Po)
|
|
3818
|
+
i && !i.has(r.toolId) || t.register(n(r));
|
|
3819
|
+
}
|
|
3820
|
+
function jo() {
|
|
3821
|
+
const t = Do(), e = /* @__PURE__ */ new Set();
|
|
3802
3822
|
for (const i of t.getAllTools())
|
|
3803
3823
|
for (const n of i.pnpSupportIds || [])
|
|
3804
3824
|
e.add(n);
|
|
3805
3825
|
return [...e].sort();
|
|
3806
3826
|
}
|
|
3807
|
-
|
|
3808
|
-
const
|
|
3827
|
+
jo();
|
|
3828
|
+
const Fo = {
|
|
3809
3829
|
/**
|
|
3810
3830
|
* Visual accessibility features
|
|
3811
3831
|
* For students with low vision, color blindness, or visual processing needs
|
|
@@ -3976,7 +3996,7 @@ const xo = {
|
|
|
3976
3996
|
tutorialAvailable: "tutorialAvailable"
|
|
3977
3997
|
}
|
|
3978
3998
|
};
|
|
3979
|
-
Object.values(
|
|
3999
|
+
Object.values(Fo).flatMap((t) => Object.values(t));
|
|
3980
4000
|
var gi;
|
|
3981
4001
|
(function(t) {
|
|
3982
4002
|
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";
|
|
@@ -3985,8 +4005,8 @@ var an;
|
|
|
3985
4005
|
(function(t) {
|
|
3986
4006
|
t.IDLE = "idle", t.LOADING = "loading", t.PLAYING = "playing", t.PAUSED = "paused", t.ERROR = "error";
|
|
3987
4007
|
})(an || (an = {}));
|
|
3988
|
-
var
|
|
3989
|
-
const
|
|
4008
|
+
var Ho = /* @__PURE__ */ nr('<div class="pie-tool-line-reader__mask pie-tool-line-reader__mask--top svelte-1a3d6dx" aria-hidden="true"></div> <div class="pie-tool-line-reader__mask pie-tool-line-reader__mask--bottom svelte-1a3d6dx" aria-hidden="true"></div> <div class="pie-tool-line-reader__mask pie-tool-line-reader__mask--left svelte-1a3d6dx" aria-hidden="true"></div> <div class="pie-tool-line-reader__mask pie-tool-line-reader__mask--right svelte-1a3d6dx" aria-hidden="true"></div>', 1), zo = /* @__PURE__ */ nr('<div class="pie-sr-only svelte-1a3d6dx" role="status" aria-live="polite" aria-atomic="true"> </div> <!> <div role="application" tabindex="0" aria-roledescription="Draggable and resizable reading guide overlay"><div class="pie-tool-line-reader__container svelte-1a3d6dx"></div> <div class="pie-tool-line-reader__resize-handle pie-tool-line-reader__resize-handle--bottom svelte-1a3d6dx" title="Drag to resize height" role="button" tabindex="-1" aria-label="Resize handle - drag to adjust height"><svg width="20" height="8" viewBox="0 0 20 8" aria-hidden="true"><rect x="8" y="3" width="4" height="2" fill="var(--pie-primary, #4CAF50)" rx="1"></rect></svg></div></div>', 1);
|
|
4009
|
+
const Go = {
|
|
3990
4010
|
hash: "svelte-1a3d6dx",
|
|
3991
4011
|
code: `.pie-sr-only.svelte-1a3d6dx {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;}.pie-tool-line-reader.svelte-1a3d6dx {border:2px solid color-mix(in srgb, var(--pie-primary, #4caf50) 80%, transparent);cursor:move;overflow:visible;position:absolute;transform:translate(-50%, -50%);user-select:none;pointer-events:auto;touch-action:none;}.pie-tool-line-reader.svelte-1a3d6dx:focus {outline:3px solid var(--pie-button-focus-outline, var(--pie-primary, #4A90E2));outline-offset:2px;}.pie-tool-line-reader.svelte-1a3d6dx:focus-visible {outline:3px solid var(--pie-button-focus-outline, var(--pie-primary, #4A90E2));outline-offset:2px;}.pie-tool-line-reader__container.svelte-1a3d6dx {width:100%;height:100%;position:relative;transition:background-color 0.2s ease;}.pie-tool-line-reader__resize-handle.svelte-1a3d6dx {position:absolute;cursor:ns-resize;z-index:10;display:flex;align-items:center;justify-content:center;}.pie-tool-line-reader__resize-handle--bottom.svelte-1a3d6dx {bottom:-10px;left:50%;transform:translateX(-50%);width:40px;height:16px;background-color:color-mix(in srgb, var(--pie-background, #fff) 90%, transparent);border-radius:8px;border:2px solid var(--pie-primary, #4caf50);}.pie-tool-line-reader__resize-handle.svelte-1a3d6dx:hover {background-color:color-mix(in srgb, var(--pie-primary, #4caf50) 20%, transparent);}.pie-tool-line-reader__resize-handle.svelte-1a3d6dx:active {cursor:ns-resize;}.pie-tool-line-reader.svelte-1a3d6dx:active {cursor:grabbing;}
|
|
3992
4012
|
|
|
@@ -4001,19 +4021,19 @@ const Ho = {
|
|
|
4001
4021
|
|
|
4002
4022
|
/* In masking mode, the window should be transparent to show content underneath */.pie-tool-line-reader.pie-tool-line-reader--masking-mode.svelte-1a3d6dx .pie-tool-line-reader__container:where(.svelte-1a3d6dx) {background-color:transparent !important;}`
|
|
4003
4023
|
};
|
|
4004
|
-
function
|
|
4005
|
-
bn(e, !0), Hs(t,
|
|
4024
|
+
function Bo(t, e) {
|
|
4025
|
+
bn(e, !0), Hs(t, Go);
|
|
4006
4026
|
let i = sn(e, "visible", 7, !1), n = sn(e, "toolId", 7, "lineReader");
|
|
4007
4027
|
const r = typeof window < "u";
|
|
4008
|
-
let s = /* @__PURE__ */
|
|
4028
|
+
let s = /* @__PURE__ */ R(void 0), o = /* @__PURE__ */ R(null);
|
|
4009
4029
|
const l = /* @__PURE__ */ Yi(() => d(o)?.toolCoordinator);
|
|
4010
|
-
let a = /* @__PURE__ */
|
|
4030
|
+
let a = /* @__PURE__ */ R(!1), u = /* @__PURE__ */ R(!1), f = /* @__PURE__ */ R($e({
|
|
4011
4031
|
x: r ? window.innerWidth / 2 : 400,
|
|
4012
4032
|
y: r ? window.innerHeight / 2 : 300
|
|
4013
|
-
})), p = /* @__PURE__ */
|
|
4033
|
+
})), p = /* @__PURE__ */ R($e({ width: 600, height: 60 })), h = /* @__PURE__ */ R($e({ x: 0, y: 0 })), v = /* @__PURE__ */ R($e({ width: 0, height: 0, mouseY: 0 })), g = /* @__PURE__ */ R(""), I = /* @__PURE__ */ R(
|
|
4014
4034
|
"#ffff00"
|
|
4015
4035
|
// Yellow
|
|
4016
|
-
), m = /* @__PURE__ */
|
|
4036
|
+
), m = /* @__PURE__ */ R(0.3), k = /* @__PURE__ */ R("highlight"), V = /* @__PURE__ */ R(!1);
|
|
4017
4037
|
const ht = [
|
|
4018
4038
|
{ name: "Yellow", value: "#ffff00" },
|
|
4019
4039
|
{ name: "Blue", value: "#00bfff" },
|
|
@@ -4148,12 +4168,12 @@ function zo(t, e) {
|
|
|
4148
4168
|
}, Ni = Vs(), _r = ti(Ni);
|
|
4149
4169
|
{
|
|
4150
4170
|
var br = (y) => {
|
|
4151
|
-
var M =
|
|
4152
|
-
|
|
4171
|
+
var M = zo(), pt = ti(M), yr = Ui(pt, !0);
|
|
4172
|
+
Gi(pt);
|
|
4153
4173
|
var Ci = vt(pt, 2);
|
|
4154
4174
|
{
|
|
4155
4175
|
var wr = (me) => {
|
|
4156
|
-
var Mt =
|
|
4176
|
+
var Mt = Ho(), Di = ti(Mt), xi = vt(Di, 2), ji = vt(xi, 2), Ir = vt(ji, 2);
|
|
4157
4177
|
Ki(
|
|
4158
4178
|
($r, Sr) => {
|
|
4159
4179
|
Xe(Di, `height: ${$r ?? ""}px;`), Xe(xi, `top: ${d(f).y + d(p).height / 2}px;`), Xe(ji, `top: ${d(f).y - d(p).height / 2}px; height: ${d(p).height ?? ""}px; width: ${Sr ?? ""}px;`), Xe(Ir, `top: ${d(f).y - d(p).height / 2}px; height: ${d(p).height ?? ""}px; left: ${d(f).x + d(p).width / 2}px;`);
|
|
@@ -4168,20 +4188,20 @@ function zo(t, e) {
|
|
|
4168
4188
|
d(k) === "obscure" && me(wr);
|
|
4169
4189
|
});
|
|
4170
4190
|
}
|
|
4171
|
-
var
|
|
4191
|
+
var Re = vt(Ci, 2);
|
|
4172
4192
|
let Pi;
|
|
4173
|
-
var Tr = Ui(
|
|
4174
|
-
gn(2),
|
|
4193
|
+
var Tr = Ui(Re);
|
|
4194
|
+
gn(2), Gi(Re), Xs(Re, (me) => A(s, me), () => d(s)), Ki(
|
|
4175
4195
|
(me, Mt) => {
|
|
4176
|
-
Ps(yr, d(g)), Pi =
|
|
4196
|
+
Ps(yr, d(g)), Pi = Bs(Re, 1, "pie-tool-line-reader svelte-1a3d6dx", null, Pi, {
|
|
4177
4197
|
"pie-tool-line-reader--masking-mode": d(k) === "obscure"
|
|
4178
|
-
}), Xe(
|
|
4198
|
+
}), Xe(Re, `left: ${d(f).x ?? ""}px; top: ${d(f).y ?? ""}px; width: ${d(p).width ?? ""}px; height: ${d(p).height ?? ""}px;`), Us(Re, "aria-label", `Line Reader tool. Mode: ${d(k) === "highlight" ? "Highlight" : "Masking"}. Use arrow keys to move, +/- to resize height, C to change color, [ and ] to adjust opacity, M to toggle mode. Current color: ${me ?? ""}, Opacity: ${Mt ?? ""}%`), Xe(Tr, `background-color: ${d(gr) ?? ""};`);
|
|
4179
4199
|
},
|
|
4180
4200
|
[
|
|
4181
4201
|
() => ht.find((me) => me.value === d(I))?.name,
|
|
4182
4202
|
() => Math.round(d(m) * 100)
|
|
4183
4203
|
]
|
|
4184
|
-
), Ji("pointerdown",
|
|
4204
|
+
), Ji("pointerdown", Re, dr), Ji("keydown", Re, vr), xt(y, M);
|
|
4185
4205
|
};
|
|
4186
4206
|
en(_r, (y) => {
|
|
4187
4207
|
i() && y(br);
|
|
@@ -4189,9 +4209,9 @@ function zo(t, e) {
|
|
|
4189
4209
|
}
|
|
4190
4210
|
return xt(t, Ni), yn(mr);
|
|
4191
4211
|
}
|
|
4192
|
-
|
|
4212
|
+
Os(["pointerdown", "keydown"]);
|
|
4193
4213
|
customElements.define("pie-tool-line-reader", eo(
|
|
4194
|
-
|
|
4214
|
+
Bo,
|
|
4195
4215
|
{
|
|
4196
4216
|
visible: { attribute: "visible", type: "Boolean" },
|
|
4197
4217
|
toolId: { attribute: "tool-id", type: "String" }
|
|
@@ -4201,5 +4221,5 @@ customElements.define("pie-tool-line-reader", eo(
|
|
|
4201
4221
|
{ mode: "open" }
|
|
4202
4222
|
));
|
|
4203
4223
|
export {
|
|
4204
|
-
|
|
4224
|
+
Bo as default
|
|
4205
4225
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pie-players/pie-tool-line-reader",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Reading guide overlay tool for PIE assessment player",
|
|
6
6
|
"repository": {
|
|
@@ -41,9 +41,9 @@
|
|
|
41
41
|
"unpkg": "./dist/tool-line-reader.js",
|
|
42
42
|
"jsdelivr": "./dist/tool-line-reader.js",
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@pie-players/pie-assessment-toolkit": "0.3.
|
|
45
|
-
"@pie-players/pie-context": "0.3.
|
|
46
|
-
"@pie-players/pie-players-shared": "0.3.
|
|
44
|
+
"@pie-players/pie-assessment-toolkit": "0.3.3",
|
|
45
|
+
"@pie-players/pie-context": "0.3.3",
|
|
46
|
+
"@pie-players/pie-players-shared": "0.3.3",
|
|
47
47
|
"daisyui": "^5.5.18"
|
|
48
48
|
},
|
|
49
49
|
"types": "./dist/index.d.ts",
|