@pie-players/pie-tool-line-reader 0.3.36 → 0.3.38
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 +87 -87
- package/package.json +4 -4
package/dist/tool-line-reader.js
CHANGED
|
@@ -52,10 +52,10 @@ function Mo(e) {
|
|
|
52
52
|
function Oo() {
|
|
53
53
|
throw new Error("https://svelte.dev/e/state_descriptors_fixed");
|
|
54
54
|
}
|
|
55
|
-
function
|
|
55
|
+
function Po() {
|
|
56
56
|
throw new Error("https://svelte.dev/e/state_prototype_fixed");
|
|
57
57
|
}
|
|
58
|
-
function
|
|
58
|
+
function xo() {
|
|
59
59
|
throw new Error("https://svelte.dev/e/state_unsafe_mutation");
|
|
60
60
|
}
|
|
61
61
|
function Lo() {
|
|
@@ -184,9 +184,9 @@ function Ui(e) {
|
|
|
184
184
|
return I.f |= zt, e;
|
|
185
185
|
if ((t.f & 32768) === 0 && (t.f & 4) === 0)
|
|
186
186
|
throw e;
|
|
187
|
-
|
|
187
|
+
xe(e, t);
|
|
188
188
|
}
|
|
189
|
-
function
|
|
189
|
+
function xe(e, t) {
|
|
190
190
|
for (; t !== null; ) {
|
|
191
191
|
if ((t.f & 128) !== 0) {
|
|
192
192
|
if ((t.f & 32768) === 0) throw e;
|
|
@@ -205,7 +205,7 @@ var Vo = ~(oe | Ue | J);
|
|
|
205
205
|
function R(e, t) {
|
|
206
206
|
e.f = e.f & Vo | t;
|
|
207
207
|
}
|
|
208
|
-
function
|
|
208
|
+
function Pr(e) {
|
|
209
209
|
(e.f & 512) !== 0 || e.deps === null ? R(e, J) : R(e, Ue);
|
|
210
210
|
}
|
|
211
211
|
function Gi(e) {
|
|
@@ -228,7 +228,7 @@ function Ho(e) {
|
|
|
228
228
|
function Yi(e, t) {
|
|
229
229
|
if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object");
|
|
230
230
|
}
|
|
231
|
-
function
|
|
231
|
+
function xr(e, t) {
|
|
232
232
|
Yi(e, t), t.add(e);
|
|
233
233
|
}
|
|
234
234
|
function y(e, t, r) {
|
|
@@ -245,26 +245,26 @@ function w(e, t, r) {
|
|
|
245
245
|
return e.set($(e, t), r), r;
|
|
246
246
|
}
|
|
247
247
|
var Ki, ce = /* @__PURE__ */ new Set(), S = null, si = null, D = null, dr = null, vt = !1, tr = !1, nt = null, Vt = null, Xi = 0;
|
|
248
|
-
var Fo = 1, Wt = /* @__PURE__ */ new WeakMap(), At = /* @__PURE__ */ new WeakMap(), ct = /* @__PURE__ */ new WeakMap(), Ce = /* @__PURE__ */ new WeakMap(), Oe = /* @__PURE__ */ new WeakMap(),
|
|
248
|
+
var Fo = 1, Wt = /* @__PURE__ */ new WeakMap(), At = /* @__PURE__ */ new WeakMap(), ct = /* @__PURE__ */ new WeakMap(), Ce = /* @__PURE__ */ new WeakMap(), Oe = /* @__PURE__ */ new WeakMap(), Pt = /* @__PURE__ */ new WeakMap(), te = /* @__PURE__ */ new WeakMap(), hr = /* @__PURE__ */ new WeakMap(), ot = /* @__PURE__ */ new WeakMap(), ze = /* @__PURE__ */ new WeakMap(), Pe = /* @__PURE__ */ new WeakMap(), xt = /* @__PURE__ */ new WeakMap(), Et = /* @__PURE__ */ new WeakMap(), Qe = /* @__PURE__ */ new WeakMap(), z = /* @__PURE__ */ new WeakSet(), Ge = class Ji {
|
|
249
249
|
constructor() {
|
|
250
|
-
|
|
250
|
+
xr(this, z), g(this, "id", Fo++), g(this, "current", /* @__PURE__ */ new Map()), g(this, "previous", /* @__PURE__ */ new Map()), y(this, Wt, /* @__PURE__ */ new Set()), y(this, At, /* @__PURE__ */ new Set()), y(this, ct, /* @__PURE__ */ new Set()), y(this, Ce, /* @__PURE__ */ new Map()), y(this, Oe, /* @__PURE__ */ new Map()), y(this, Pt, null), y(this, te, []), y(this, hr, []), y(this, ot, /* @__PURE__ */ new Set()), y(this, ze, /* @__PURE__ */ new Set()), y(this, Pe, /* @__PURE__ */ new Map()), y(this, xt, /* @__PURE__ */ new Set()), g(this, "is_fork", !1), y(this, Et, !1), y(this, Qe, /* @__PURE__ */ new Set());
|
|
251
251
|
}
|
|
252
252
|
skip_effect(t) {
|
|
253
|
-
l(
|
|
253
|
+
l(Pe, this).has(t) || l(Pe, this).set(t, {
|
|
254
254
|
d: [],
|
|
255
255
|
m: []
|
|
256
|
-
}), l(
|
|
256
|
+
}), l(xt, this).delete(t);
|
|
257
257
|
}
|
|
258
258
|
unskip_effect(t, r = (i) => this.schedule(i)) {
|
|
259
|
-
var i = l(
|
|
259
|
+
var i = l(Pe, this).get(t);
|
|
260
260
|
if (i) {
|
|
261
|
-
l(
|
|
261
|
+
l(Pe, this).delete(t);
|
|
262
262
|
for (var n of i.d)
|
|
263
263
|
R(n, oe), r(n);
|
|
264
264
|
for (n of i.m)
|
|
265
265
|
R(n, Ue), r(n);
|
|
266
266
|
}
|
|
267
|
-
l(
|
|
267
|
+
l(xt, this).add(t);
|
|
268
268
|
}
|
|
269
269
|
capture(t, r, i = !1) {
|
|
270
270
|
t.v !== N && !this.previous.has(t) && this.previous.set(t, t.v), (t.f & 8388608) === 0 && (this.current.set(t, [r, i]), D?.set(t, r)), this.is_fork || (t.v = r);
|
|
@@ -326,7 +326,7 @@ var Fo = 1, Wt = /* @__PURE__ */ new WeakMap(), At = /* @__PURE__ */ new WeakMap
|
|
|
326
326
|
l(ct, this).clear();
|
|
327
327
|
}
|
|
328
328
|
settled() {
|
|
329
|
-
return (l(
|
|
329
|
+
return (l(Pt, this) ?? w(Pt, this, Ni())).promise;
|
|
330
330
|
}
|
|
331
331
|
static ensure() {
|
|
332
332
|
if (S === null) {
|
|
@@ -378,7 +378,7 @@ function pr() {
|
|
|
378
378
|
function Bo() {
|
|
379
379
|
for (const r of l(Qe, this)) for (const i of l(Oe, r).keys()) {
|
|
380
380
|
for (var e = !1, t = i; t.parent !== null; ) {
|
|
381
|
-
if (l(
|
|
381
|
+
if (l(Pe, this).has(t)) {
|
|
382
382
|
e = !0;
|
|
383
383
|
break;
|
|
384
384
|
}
|
|
@@ -409,11 +409,11 @@ function Lr() {
|
|
|
409
409
|
}
|
|
410
410
|
if (nt = null, Vt = null, $(z, this, pr).call(this) || $(z, this, Bo).call(this)) {
|
|
411
411
|
$(z, this, vr).call(this, r), $(z, this, vr).call(this, t);
|
|
412
|
-
for (const [s, a] of l(
|
|
412
|
+
for (const [s, a] of l(Pe, this)) en(s, a);
|
|
413
413
|
} else {
|
|
414
414
|
l(Ce, this).size === 0 && ce.delete(this), l(ot, this).clear(), l(ze, this).clear();
|
|
415
415
|
for (const s of l(Wt, this)) s(this);
|
|
416
|
-
l(Wt, this).clear(), si = this, ai(r), ai(t), si = null, l(
|
|
416
|
+
l(Wt, this).clear(), si = this, ai(r), ai(t), si = null, l(Pt, this)?.resolve();
|
|
417
417
|
}
|
|
418
418
|
var o = S;
|
|
419
419
|
if (l(te, this).length > 0) {
|
|
@@ -426,7 +426,7 @@ function Qi(e, t, r) {
|
|
|
426
426
|
e.f ^= J;
|
|
427
427
|
for (var i = e.first; i !== null; ) {
|
|
428
428
|
var n = i.f, o = (n & 96) !== 0;
|
|
429
|
-
if (!(o && (n & 1024) !== 0 || (n & 8192) !== 0 || l(
|
|
429
|
+
if (!(o && (n & 1024) !== 0 || (n & 8192) !== 0 || l(Pe, this).has(i)) && i.fn !== null) {
|
|
430
430
|
o ? i.f ^= J : (n & 4) !== 0 ? t.push(i) : me && (n & 16777224) !== 0 ? r.push(i) : St(i) && ((n & 16) !== 0 && l(ze, this).add(i), at(i));
|
|
431
431
|
var s = i.first;
|
|
432
432
|
if (s !== null) {
|
|
@@ -462,7 +462,7 @@ function Uo() {
|
|
|
462
462
|
if (i.length === 0)
|
|
463
463
|
e && f.discard();
|
|
464
464
|
else if (t.length > 0) {
|
|
465
|
-
if (e) for (const u of l(
|
|
465
|
+
if (e) for (const u of l(xt, this)) f.unskip_effect(u, (h) => {
|
|
466
466
|
(h.f & 4194320) !== 0 ? f.schedule(h) : $(z, f, vr).call(f, [h]);
|
|
467
467
|
});
|
|
468
468
|
f.activate();
|
|
@@ -503,7 +503,7 @@ function Go() {
|
|
|
503
503
|
try {
|
|
504
504
|
Ao();
|
|
505
505
|
} catch (r) {
|
|
506
|
-
|
|
506
|
+
xe(r, dr);
|
|
507
507
|
}
|
|
508
508
|
}
|
|
509
509
|
var ae = null;
|
|
@@ -579,7 +579,7 @@ function Ko(e, t, r, i) {
|
|
|
579
579
|
}
|
|
580
580
|
var ie = /* @__PURE__ */ new WeakMap(), gr = /* @__PURE__ */ new WeakMap(), le = /* @__PURE__ */ new WeakMap(), gt = /* @__PURE__ */ new WeakMap(), K = /* @__PURE__ */ new WeakMap(), fe = /* @__PURE__ */ new WeakMap(), B = /* @__PURE__ */ new WeakMap(), ee = /* @__PURE__ */ new WeakMap(), Ve = /* @__PURE__ */ new WeakMap(), Ye = /* @__PURE__ */ new WeakMap(), We = /* @__PURE__ */ new WeakMap(), Mt = /* @__PURE__ */ new WeakMap(), mr = /* @__PURE__ */ new WeakMap(), br = /* @__PURE__ */ new WeakMap(), Le = /* @__PURE__ */ new WeakMap(), li = /* @__PURE__ */ new WeakMap(), j = /* @__PURE__ */ new WeakSet(), Xo = class {
|
|
581
581
|
constructor(e, t, r, i) {
|
|
582
|
-
|
|
582
|
+
xr(this, j), g(this, "parent", void 0), g(this, "is_pending", !1), g(this, "transform_error", void 0), y(this, ie, void 0), y(this, gr, O ? A : null), y(this, le, void 0), y(this, gt, void 0), y(this, K, void 0), y(this, fe, null), y(this, B, null), y(this, ee, null), y(this, Ve, null), y(this, Ye, 0), y(this, We, 0), y(this, Mt, !1), y(this, mr, /* @__PURE__ */ new Set()), y(this, br, /* @__PURE__ */ new Set()), y(this, Le, null), y(this, li, qo(() => (w(Le, this, Tt(l(Ye, this))), () => {
|
|
583
583
|
w(Le, this, null);
|
|
584
584
|
}))), w(ie, this, e), w(le, this, t), w(gt, this, (n) => {
|
|
585
585
|
var o = k;
|
|
@@ -702,7 +702,7 @@ function ci(e) {
|
|
|
702
702
|
try {
|
|
703
703
|
n = !0, t?.(a, o), n = !1;
|
|
704
704
|
} catch (c) {
|
|
705
|
-
|
|
705
|
+
xe(c, l(K, this) && l(K, this).parent);
|
|
706
706
|
}
|
|
707
707
|
r && w(ee, this, $(j, this, yr).call(this, () => {
|
|
708
708
|
try {
|
|
@@ -711,7 +711,7 @@ function ci(e) {
|
|
|
711
711
|
c.b = this, c.f |= 128, r(l(ie, this), () => a, () => o);
|
|
712
712
|
});
|
|
713
713
|
} catch (c) {
|
|
714
|
-
return
|
|
714
|
+
return xe(c, l(K, this).parent), null;
|
|
715
715
|
}
|
|
716
716
|
}));
|
|
717
717
|
};
|
|
@@ -720,10 +720,10 @@ function ci(e) {
|
|
|
720
720
|
try {
|
|
721
721
|
a = this.transform_error(e);
|
|
722
722
|
} catch (c) {
|
|
723
|
-
|
|
723
|
+
xe(c, l(K, this) && l(K, this).parent);
|
|
724
724
|
return;
|
|
725
725
|
}
|
|
726
|
-
a !== null && typeof a == "object" && typeof a.then == "function" ? a.then(s, (c) =>
|
|
726
|
+
a !== null && typeof a == "object" && typeof a.then == "function" ? a.then(s, (c) => xe(c, l(K, this) && l(K, this).parent)) : s(a);
|
|
727
727
|
});
|
|
728
728
|
}
|
|
729
729
|
function es(e, t, r, i) {
|
|
@@ -739,7 +739,7 @@ function es(e, t, r, i) {
|
|
|
739
739
|
try {
|
|
740
740
|
i(d);
|
|
741
741
|
} catch (v) {
|
|
742
|
-
(s.f & 16384) === 0 &&
|
|
742
|
+
(s.f & 16384) === 0 && xe(v, s);
|
|
743
743
|
}
|
|
744
744
|
Ht();
|
|
745
745
|
}
|
|
@@ -749,7 +749,7 @@ function es(e, t, r, i) {
|
|
|
749
749
|
}
|
|
750
750
|
var u = on();
|
|
751
751
|
function h() {
|
|
752
|
-
Promise.all(r.map((d) => /* @__PURE__ */ rs(d))).then((d) => f([...t.map(n), ...d])).catch((d) =>
|
|
752
|
+
Promise.all(r.map((d) => /* @__PURE__ */ rs(d))).then((d) => f([...t.map(n), ...d])).catch((d) => xe(d, s)).finally(() => u());
|
|
753
753
|
}
|
|
754
754
|
c ? c.then(() => {
|
|
755
755
|
a(), h(), Ht();
|
|
@@ -875,7 +875,7 @@ function an(e) {
|
|
|
875
875
|
R(e, J);
|
|
876
876
|
return;
|
|
877
877
|
}
|
|
878
|
-
we || (D !== null ? (Vr() || S?.is_fork) && D.set(e, t) :
|
|
878
|
+
we || (D !== null ? (Vr() || S?.is_fork) && D.set(e, t) : Pr(e));
|
|
879
879
|
}
|
|
880
880
|
function ns(e) {
|
|
881
881
|
if (e.effects !== null)
|
|
@@ -899,7 +899,7 @@ function Tt(e, t) {
|
|
|
899
899
|
return r;
|
|
900
900
|
}
|
|
901
901
|
// @__NO_SIDE_EFFECTS__
|
|
902
|
-
function
|
|
902
|
+
function x(e, t) {
|
|
903
903
|
const r = Tt(e, t);
|
|
904
904
|
return kn(r), r;
|
|
905
905
|
}
|
|
@@ -912,8 +912,8 @@ function os(e, t = !1, r = !0) {
|
|
|
912
912
|
}
|
|
913
913
|
return i;
|
|
914
914
|
}
|
|
915
|
-
function
|
|
916
|
-
I !== null && (!re || (I.f & 131072) !== 0) && wt() && (I.f & 4325394) !== 0 && (X === null || !tt.call(X, e)) &&
|
|
915
|
+
function P(e, t, r = !1) {
|
|
916
|
+
I !== null && (!re || (I.f & 131072) !== 0) && wt() && (I.f & 4325394) !== 0 && (X === null || !tt.call(X, e)) && xo();
|
|
917
917
|
let i = r ? ue(t) : t;
|
|
918
918
|
return Ft(e, i, Vt);
|
|
919
919
|
}
|
|
@@ -923,7 +923,7 @@ function Ft(e, t, r = null) {
|
|
|
923
923
|
var i = Ge.ensure();
|
|
924
924
|
if (i.capture(e, t), (e.f & 2) !== 0) {
|
|
925
925
|
const n = e;
|
|
926
|
-
(e.f & 2048) !== 0 && jr(n), D === null &&
|
|
926
|
+
(e.f & 2048) !== 0 && jr(n), D === null && Pr(n);
|
|
927
927
|
}
|
|
928
928
|
e.wv = In(), un(e, oe, r), wt() && k !== null && (k.f & 1024) !== 0 && (k.f & 96) === 0 && (Y === null ? Ts([e]) : Y.push(e)), !i.is_fork && wr.size > 0 && !cn && ss();
|
|
929
929
|
}
|
|
@@ -936,7 +936,7 @@ function ss() {
|
|
|
936
936
|
wr.clear();
|
|
937
937
|
}
|
|
938
938
|
function _t(e) {
|
|
939
|
-
|
|
939
|
+
P(e, e.v + 1);
|
|
940
940
|
}
|
|
941
941
|
function un(e, t, r) {
|
|
942
942
|
var i = e.reactions;
|
|
@@ -960,14 +960,14 @@ function ue(e) {
|
|
|
960
960
|
if (typeof e != "object" || e === null || pt in e) return e;
|
|
961
961
|
const t = Ci(e);
|
|
962
962
|
if (t !== fo && t !== ho) return e;
|
|
963
|
-
var r = /* @__PURE__ */ new Map(), i = ao(e), n = /* @__PURE__ */
|
|
963
|
+
var r = /* @__PURE__ */ new Map(), i = ao(e), n = /* @__PURE__ */ x(0), o = null, s = Fe, a = (h) => {
|
|
964
964
|
if (Fe === s) return h();
|
|
965
965
|
var d = I, v = Fe;
|
|
966
966
|
Q(null), vi(s);
|
|
967
967
|
var _ = h();
|
|
968
968
|
return Q(d), vi(v), _;
|
|
969
969
|
};
|
|
970
|
-
i && r.set("length", /* @__PURE__ */
|
|
970
|
+
i && r.set("length", /* @__PURE__ */ x(e.length, o));
|
|
971
971
|
var c = "";
|
|
972
972
|
let f = !1;
|
|
973
973
|
function u(h) {
|
|
@@ -982,26 +982,26 @@ function ue(e) {
|
|
|
982
982
|
(!("value" in v) || v.configurable === !1 || v.enumerable === !1 || v.writable === !1) && Oo();
|
|
983
983
|
var _ = r.get(d);
|
|
984
984
|
return _ === void 0 ? a(() => {
|
|
985
|
-
var m = /* @__PURE__ */
|
|
985
|
+
var m = /* @__PURE__ */ x(v.value, o);
|
|
986
986
|
return r.set(d, m), m;
|
|
987
|
-
}) :
|
|
987
|
+
}) : P(_, v.value, !0), !0;
|
|
988
988
|
},
|
|
989
989
|
deleteProperty(h, d) {
|
|
990
990
|
var v = r.get(d);
|
|
991
991
|
if (v === void 0) {
|
|
992
992
|
if (d in h) {
|
|
993
|
-
const _ = a(() => /* @__PURE__ */
|
|
993
|
+
const _ = a(() => /* @__PURE__ */ x(N, o));
|
|
994
994
|
r.set(d, _), _t(n);
|
|
995
995
|
}
|
|
996
996
|
} else
|
|
997
|
-
|
|
997
|
+
P(v, N), _t(n);
|
|
998
998
|
return !0;
|
|
999
999
|
},
|
|
1000
1000
|
get(h, d, v) {
|
|
1001
1001
|
if (d === pt) return e;
|
|
1002
1002
|
var _ = r.get(d), m = d in h;
|
|
1003
1003
|
if (_ === void 0 && (!m || De(h, d)?.writable) && (_ = a(() => {
|
|
1004
|
-
var E = /* @__PURE__ */
|
|
1004
|
+
var E = /* @__PURE__ */ x(ue(m ? h[d] : N), o);
|
|
1005
1005
|
return E;
|
|
1006
1006
|
}), r.set(d, _)), _ !== void 0) {
|
|
1007
1007
|
var b = p(_);
|
|
@@ -1029,7 +1029,7 @@ function ue(e) {
|
|
|
1029
1029
|
if (d === pt) return !0;
|
|
1030
1030
|
var v = r.get(d), _ = v !== void 0 && v.v !== N || Reflect.has(h, d);
|
|
1031
1031
|
return (v !== void 0 || k !== null && (!_ || De(h, d)?.writable)) && (v === void 0 && (v = a(() => {
|
|
1032
|
-
var m = /* @__PURE__ */
|
|
1032
|
+
var m = /* @__PURE__ */ x(_ ? ue(h[d]) : N, o);
|
|
1033
1033
|
return m;
|
|
1034
1034
|
}), r.set(d, v)), p(v) === N) ? !1 : _;
|
|
1035
1035
|
},
|
|
@@ -1037,20 +1037,20 @@ function ue(e) {
|
|
|
1037
1037
|
var m = r.get(d), b = d in h;
|
|
1038
1038
|
if (i && d === "length") for (var E = v; E < m.v; E += 1) {
|
|
1039
1039
|
var U = r.get(E + "");
|
|
1040
|
-
U !== void 0 ?
|
|
1040
|
+
U !== void 0 ? P(U, N) : E in h && (U = a(() => /* @__PURE__ */ x(N, o)), r.set(E + "", U));
|
|
1041
1041
|
}
|
|
1042
1042
|
if (m === void 0)
|
|
1043
|
-
(!b || De(h, d)?.writable) && (m = a(() => /* @__PURE__ */
|
|
1043
|
+
(!b || De(h, d)?.writable) && (m = a(() => /* @__PURE__ */ x(void 0, o)), P(m, ue(v)), r.set(d, m));
|
|
1044
1044
|
else {
|
|
1045
1045
|
b = m.v !== N;
|
|
1046
1046
|
var M = a(() => ue(v));
|
|
1047
|
-
|
|
1047
|
+
P(m, M);
|
|
1048
1048
|
}
|
|
1049
1049
|
var G = Reflect.getOwnPropertyDescriptor(h, d);
|
|
1050
1050
|
if (G?.set && G.set.call(_, v), !b) {
|
|
1051
1051
|
if (i && typeof d == "string") {
|
|
1052
1052
|
var Ie = r.get("length"), H = Number(d);
|
|
1053
|
-
Number.isInteger(H) && H >= Ie.v &&
|
|
1053
|
+
Number.isInteger(H) && H >= Ie.v && P(Ie, H + 1);
|
|
1054
1054
|
}
|
|
1055
1055
|
_t(n);
|
|
1056
1056
|
}
|
|
@@ -1066,7 +1066,7 @@ function ue(e) {
|
|
|
1066
1066
|
return d;
|
|
1067
1067
|
},
|
|
1068
1068
|
setPrototypeOf() {
|
|
1069
|
-
|
|
1069
|
+
Po();
|
|
1070
1070
|
}
|
|
1071
1071
|
});
|
|
1072
1072
|
}
|
|
@@ -1441,7 +1441,7 @@ function ks(e, t) {
|
|
|
1441
1441
|
}
|
|
1442
1442
|
if (r === null && (t.f & 2) !== 0 && (V === null || !tt.call(V, t))) {
|
|
1443
1443
|
var o = t;
|
|
1444
|
-
(o.f & 512) !== 0 && (o.f ^= 512, o.f &= ~bt), o.v !== N &&
|
|
1444
|
+
(o.f & 512) !== 0 && (o.f ^= 512, o.f &= ~bt), o.v !== N && Pr(o), ns(o), mt(o, 0);
|
|
1445
1445
|
}
|
|
1446
1446
|
}
|
|
1447
1447
|
function mt(e, t) {
|
|
@@ -1594,7 +1594,7 @@ function Ze(e, t) {
|
|
|
1594
1594
|
});
|
|
1595
1595
|
}
|
|
1596
1596
|
// @__NO_SIDE_EFFECTS__
|
|
1597
|
-
function
|
|
1597
|
+
function Pn(e, t) {
|
|
1598
1598
|
var r = (t & 1) !== 0, i = (t & 2) !== 0, n, o = !e.startsWith("<!>");
|
|
1599
1599
|
return () => {
|
|
1600
1600
|
if (O)
|
|
@@ -1668,16 +1668,16 @@ var Ms = [
|
|
|
1668
1668
|
"disablePictureInPicture",
|
|
1669
1669
|
"disableRemotePlayback"
|
|
1670
1670
|
], Os = ["touchstart", "touchmove"];
|
|
1671
|
-
function
|
|
1671
|
+
function Ps(e) {
|
|
1672
1672
|
return Os.includes(e);
|
|
1673
1673
|
}
|
|
1674
|
-
var
|
|
1674
|
+
var xs = [
|
|
1675
1675
|
"$state",
|
|
1676
1676
|
"$state.raw",
|
|
1677
1677
|
"$derived",
|
|
1678
1678
|
"$derived.by"
|
|
1679
1679
|
], pl = [
|
|
1680
|
-
...
|
|
1680
|
+
...xs,
|
|
1681
1681
|
"$state.eager",
|
|
1682
1682
|
"$state.snapshot",
|
|
1683
1683
|
"$props",
|
|
@@ -1697,7 +1697,7 @@ function Ls(e, t) {
|
|
|
1697
1697
|
var r = t == null ? "" : typeof t == "object" ? `${t}` : t;
|
|
1698
1698
|
r !== (e.__t ?? (e.__t = e.nodeValue)) && (e.__t = r, e.nodeValue = `${r}`);
|
|
1699
1699
|
}
|
|
1700
|
-
function
|
|
1700
|
+
function xn(e, t) {
|
|
1701
1701
|
return Ln(e, t);
|
|
1702
1702
|
}
|
|
1703
1703
|
function Rs(e, t) {
|
|
@@ -1715,7 +1715,7 @@ function Rs(e, t) {
|
|
|
1715
1715
|
} catch (s) {
|
|
1716
1716
|
if (s instanceof Error && s.message.split(`
|
|
1717
1717
|
`).some((a) => a.startsWith("https://svelte.dev/e/"))) throw s;
|
|
1718
|
-
return s !== et && console.warn("Failed to hydrate: ", s), t.recover === !1 && Eo(), Tr(), us(r), Xe(!1),
|
|
1718
|
+
return s !== et && console.warn("Failed to hydrate: ", s), t.recover === !1 && Eo(), Tr(), us(r), Xe(!1), xn(e, t);
|
|
1719
1719
|
} finally {
|
|
1720
1720
|
Xe(i), ne(n);
|
|
1721
1721
|
}
|
|
@@ -1738,7 +1738,7 @@ function Ln(e, { target: t, anchor: r, props: i = {}, events: n, context: o, int
|
|
|
1738
1738
|
var m = v[_];
|
|
1739
1739
|
if (!h.has(m)) {
|
|
1740
1740
|
h.add(m);
|
|
1741
|
-
var b =
|
|
1741
|
+
var b = Ps(m);
|
|
1742
1742
|
for (const M of [t, document]) {
|
|
1743
1743
|
var E = Ot.get(M);
|
|
1744
1744
|
E === void 0 && (E = /* @__PURE__ */ new Map(), Ot.set(M, E));
|
|
@@ -1972,7 +1972,7 @@ function Ys(e) {
|
|
|
1972
1972
|
}
|
|
1973
1973
|
var Rn, Ke = /* @__PURE__ */ new WeakMap(), Bt = /* @__PURE__ */ new WeakMap(), ar = /* @__PURE__ */ new WeakMap(), Ii = /* @__PURE__ */ new WeakSet(), Cn = class {
|
|
1974
1974
|
constructor(e) {
|
|
1975
|
-
|
|
1975
|
+
xr(this, Ii), y(this, Ke, /* @__PURE__ */ new WeakMap()), y(this, Bt, void 0), y(this, ar, void 0), w(ar, this, e);
|
|
1976
1976
|
}
|
|
1977
1977
|
observe(e, t) {
|
|
1978
1978
|
var r = l(Ke, this).get(e) || /* @__PURE__ */ new Set();
|
|
@@ -2044,7 +2044,7 @@ function Ai(e, t, r, i) {
|
|
|
2044
2044
|
return (function(M, G) {
|
|
2045
2045
|
if (arguments.length > 0) {
|
|
2046
2046
|
const Ie = G ? p(E) : n && o ? ue(M) : M;
|
|
2047
|
-
return
|
|
2047
|
+
return P(E, Ie), b = !0, a !== void 0 && (a = Ie), M;
|
|
2048
2048
|
}
|
|
2049
2049
|
return we && b || (U.f & 16384) !== 0 ? E.v : p(E);
|
|
2050
2050
|
});
|
|
@@ -2070,10 +2070,10 @@ var Re = /* @__PURE__ */ new WeakMap(), se = /* @__PURE__ */ new WeakMap(), Qs =
|
|
|
2070
2070
|
return o === ji ? !0 : (p(t.get(o) ?? r(o, Reflect.get(n, o))), Reflect.has(n, o));
|
|
2071
2071
|
},
|
|
2072
2072
|
set(n, o, s) {
|
|
2073
|
-
return
|
|
2073
|
+
return P(t.get(o) ?? r(o, s), s), Reflect.set(n, o, s);
|
|
2074
2074
|
}
|
|
2075
2075
|
});
|
|
2076
|
-
w(se, this, (e.hydrate ? Rs :
|
|
2076
|
+
w(se, this, (e.hydrate ? Rs : xn)(e.component, {
|
|
2077
2077
|
target: e.target,
|
|
2078
2078
|
anchor: e.anchor,
|
|
2079
2079
|
props: i,
|
|
@@ -2376,15 +2376,15 @@ function Me(e) {
|
|
|
2376
2376
|
}
|
|
2377
2377
|
return Array.from(t);
|
|
2378
2378
|
}
|
|
2379
|
-
function fa(e) {
|
|
2379
|
+
function fa(e, t) {
|
|
2380
2380
|
if (e != null) {
|
|
2381
2381
|
if (e === "on" || e === "off") return e;
|
|
2382
|
-
throw new Error(`Invalid tools config at "
|
|
2382
|
+
throw new Error(`Invalid tools config at "${t}": expected "on" or "off", got ${JSON.stringify(e)}.`);
|
|
2383
2383
|
}
|
|
2384
2384
|
}
|
|
2385
2385
|
function da(e) {
|
|
2386
2386
|
if (e != null && !Be(e)) throw new Error('Invalid tools config: expected an object with "policy", "placement", and "providers".');
|
|
2387
|
-
const t = la(e?.policy), r = aa(e?.placement), i = ua(e?.providers), n = fa(e?.
|
|
2387
|
+
const t = la(e?.policy), r = aa(e?.placement), i = ua(e?.providers), n = fa(e?.pnpEnforcement, "pnpEnforcement"), o = {
|
|
2388
2388
|
policy: {
|
|
2389
2389
|
allowed: Me(Ee(t?.allowed, "policy.allowed")),
|
|
2390
2390
|
blocked: Me(Ee(t?.blocked, "policy.blocked"))
|
|
@@ -2396,7 +2396,7 @@ function da(e) {
|
|
|
2396
2396
|
},
|
|
2397
2397
|
providers: i
|
|
2398
2398
|
};
|
|
2399
|
-
return n && (o.
|
|
2399
|
+
return n && (o.pnpEnforcement = n), o;
|
|
2400
2400
|
}
|
|
2401
2401
|
var ha = [
|
|
2402
2402
|
"assessment",
|
|
@@ -3095,7 +3095,7 @@ var Sa = class {
|
|
|
3095
3095
|
"font-face-format",
|
|
3096
3096
|
"font-face-name",
|
|
3097
3097
|
"missing-glyph"
|
|
3098
|
-
]), Oa = /^[a-z][a-z0-9._-]*-[a-z0-9._-]*$/,
|
|
3098
|
+
]), Oa = /^[a-z][a-z0-9._-]*-[a-z0-9._-]*$/, Pa = (e, t = "custom element tag") => {
|
|
3099
3099
|
if (!e || typeof e != "string") throw new Error(`Invalid ${t}: expected a non-empty string`);
|
|
3100
3100
|
const r = e.trim();
|
|
3101
3101
|
if (!r) throw new Error(`Invalid ${t}: tag is empty`);
|
|
@@ -3117,8 +3117,8 @@ var Sa = class {
|
|
|
3117
3117
|
annotationToolbar: "pie-tool-annotation-toolbar",
|
|
3118
3118
|
graph: "pie-tool-graph",
|
|
3119
3119
|
periodicTable: "pie-tool-periodic-table"
|
|
3120
|
-
},
|
|
3121
|
-
const n =
|
|
3120
|
+
}, xa = (e, t) => Pa(t?.toolTagMap?.[e] ?? Wn[e] ?? e, `tool component tag for "${e}"`), La = (e) => document.createElement(e), pe = (e, t, r, i) => {
|
|
3121
|
+
const n = xa(e, i), o = i?.toolComponentFactories?.[e] ?? i?.toolComponentFactory;
|
|
3122
3122
|
return o ? o({
|
|
3123
3123
|
toolId: e,
|
|
3124
3124
|
tagName: n,
|
|
@@ -3203,8 +3203,8 @@ var Sa = class {
|
|
|
3203
3203
|
"expanding-row",
|
|
3204
3204
|
"floating-overlay",
|
|
3205
3205
|
"left-aligned"
|
|
3206
|
-
]),
|
|
3207
|
-
if (!Array.isArray(e)) return [...
|
|
3206
|
+
]), Pi = (e) => e && typeof e == "object" ? e : {}, Na = (e) => e === "polly" || e === "google" || e === "server", q = (e, t) => e === void 0 ? t : e, Ut = (e, t = "left-aligned") => typeof e == "string" && Ca.has(e) ? e : t, xi = Object.freeze([0.8, 1.25]), ur = (e) => {
|
|
3207
|
+
if (!Array.isArray(e)) return [...xi];
|
|
3208
3208
|
if (e.length === 0) return [];
|
|
3209
3209
|
const t = /* @__PURE__ */ new Set();
|
|
3210
3210
|
for (const r of e) {
|
|
@@ -3212,7 +3212,7 @@ var Sa = class {
|
|
|
3212
3212
|
const i = Math.round(r * 100) / 100;
|
|
3213
3213
|
i !== 1 && t.add(i);
|
|
3214
3214
|
}
|
|
3215
|
-
return t.size ? Array.from(t) : [...
|
|
3215
|
+
return t.size ? Array.from(t) : [...xi];
|
|
3216
3216
|
}, ja = (e) => {
|
|
3217
3217
|
const t = {
|
|
3218
3218
|
...e,
|
|
@@ -3240,7 +3240,7 @@ var Sa = class {
|
|
|
3240
3240
|
defaultVoice: q(i.defaultVoice, "en-US-Wavenet-A")
|
|
3241
3241
|
} : i;
|
|
3242
3242
|
}, fr = (e) => {
|
|
3243
|
-
const t =
|
|
3243
|
+
const t = Pi(e), r = Pi(e?.settings);
|
|
3244
3244
|
return ja({
|
|
3245
3245
|
...t,
|
|
3246
3246
|
...r
|
|
@@ -4013,7 +4013,7 @@ var Tl = da({
|
|
|
4013
4013
|
passage: []
|
|
4014
4014
|
},
|
|
4015
4015
|
providers: {}
|
|
4016
|
-
}), nl = /* @__PURE__ */
|
|
4016
|
+
}), nl = /* @__PURE__ */ Pn('<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), ol = /* @__PURE__ */ Pn('<div class="pie-sr-only svelte-1a3d6dx" role="status" aria-live="polite" aria-atomic="true"> </div> <!> <div role="group" 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), sl = {
|
|
4017
4017
|
hash: "svelte-1a3d6dx",
|
|
4018
4018
|
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:none;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-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:-12px;left:50%;transform:translateX(-50%);width:44px;height:24px;background-color:color-mix(in srgb, var(--pie-background, #fff) 90%, transparent);border-radius:12px;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;}
|
|
4019
4019
|
|
|
@@ -4031,22 +4031,22 @@ function al(e, t) {
|
|
|
4031
4031
|
Hi(t, !0), zs(e, sl);
|
|
4032
4032
|
let r = Ai(t, "visible", 7, !1), i = Ai(t, "toolId", 7, "lineReader");
|
|
4033
4033
|
const n = typeof window < "u";
|
|
4034
|
-
let o = /* @__PURE__ */
|
|
4034
|
+
let o = /* @__PURE__ */ x(void 0), s = /* @__PURE__ */ x(null);
|
|
4035
4035
|
const a = /* @__PURE__ */ ui(() => p(s)?.toolCoordinator);
|
|
4036
|
-
let c = /* @__PURE__ */
|
|
4036
|
+
let c = /* @__PURE__ */ x(!1), f = /* @__PURE__ */ x(!1), u = /* @__PURE__ */ x(ue({
|
|
4037
4037
|
x: n ? window.innerWidth / 2 : 400,
|
|
4038
4038
|
y: n ? window.innerHeight / 2 : 300
|
|
4039
|
-
})), h = /* @__PURE__ */
|
|
4039
|
+
})), h = /* @__PURE__ */ x(ue({
|
|
4040
4040
|
width: 600,
|
|
4041
4041
|
height: 60
|
|
4042
|
-
})), d = /* @__PURE__ */
|
|
4042
|
+
})), d = /* @__PURE__ */ x(ue({
|
|
4043
4043
|
x: 0,
|
|
4044
4044
|
y: 0
|
|
4045
|
-
})), v = /* @__PURE__ */
|
|
4045
|
+
})), v = /* @__PURE__ */ x(ue({
|
|
4046
4046
|
width: 0,
|
|
4047
4047
|
height: 0,
|
|
4048
4048
|
mouseY: 0
|
|
4049
|
-
})), _ = /* @__PURE__ */
|
|
4049
|
+
})), _ = /* @__PURE__ */ x(""), m = /* @__PURE__ */ x("#ffff00"), b = /* @__PURE__ */ x(0.3), E = /* @__PURE__ */ x("highlight"), U = /* @__PURE__ */ x(!1);
|
|
4050
4050
|
const M = [
|
|
4051
4051
|
{
|
|
4052
4052
|
name: "Yellow",
|
|
@@ -4072,40 +4072,40 @@ function al(e, t) {
|
|
|
4072
4072
|
ht(() => {
|
|
4073
4073
|
if (p(o))
|
|
4074
4074
|
return sa(p(o), (T) => {
|
|
4075
|
-
|
|
4075
|
+
P(s, T, !0);
|
|
4076
4076
|
});
|
|
4077
4077
|
});
|
|
4078
4078
|
function H(T) {
|
|
4079
|
-
|
|
4079
|
+
P(_, T, !0), setTimeout(() => P(_, ""), 1e3);
|
|
4080
4080
|
}
|
|
4081
4081
|
function Un() {
|
|
4082
4082
|
const T = (M.findIndex((C) => C.value === p(m)) + 1) % M.length;
|
|
4083
|
-
|
|
4083
|
+
P(m, M[T].value, !0), H(`Color changed to ${M[T].name}`);
|
|
4084
4084
|
}
|
|
4085
4085
|
function Gr(T) {
|
|
4086
|
-
|
|
4086
|
+
P(b, Math.max(0.1, Math.min(0.9, p(b) + T)), !0), H(`Opacity ${Math.round(p(b) * 100)}%`);
|
|
4087
4087
|
}
|
|
4088
4088
|
function Gn() {
|
|
4089
|
-
|
|
4089
|
+
P(E, p(E) === "highlight" ? "obscure" : "highlight", !0), H(`Mode changed to ${p(E) === "highlight" ? "highlight" : "masking"}`);
|
|
4090
4090
|
}
|
|
4091
4091
|
function qn(T) {
|
|
4092
4092
|
T.target.closest(".resize-handle") ? Kn(T) : Yn(T);
|
|
4093
4093
|
}
|
|
4094
4094
|
function Yn(T) {
|
|
4095
|
-
p(o) && (p(o).setPointerCapture(T.pointerId),
|
|
4095
|
+
p(o) && (p(o).setPointerCapture(T.pointerId), P(c, !0), P(d, {
|
|
4096
4096
|
x: T.clientX - p(u).x,
|
|
4097
4097
|
y: T.clientY - p(u).y
|
|
4098
4098
|
}, !0), p(a)?.bringToFront(p(o)), p(o).addEventListener("pointermove", Qt), p(o).addEventListener("pointerup", Zt), T.preventDefault());
|
|
4099
4099
|
}
|
|
4100
4100
|
function Kn(T) {
|
|
4101
|
-
p(o) && (p(o).setPointerCapture(T.pointerId),
|
|
4101
|
+
p(o) && (p(o).setPointerCapture(T.pointerId), P(f, !0), P(v, {
|
|
4102
4102
|
width: p(h).width,
|
|
4103
4103
|
height: p(h).height,
|
|
4104
4104
|
mouseY: T.clientY
|
|
4105
4105
|
}, !0), p(a)?.bringToFront(p(o)), p(o).addEventListener("pointermove", Qt), p(o).addEventListener("pointerup", Zt), T.preventDefault(), T.stopPropagation());
|
|
4106
4106
|
}
|
|
4107
4107
|
function Qt(T) {
|
|
4108
|
-
if (p(c))
|
|
4108
|
+
if (p(c)) P(u, {
|
|
4109
4109
|
x: T.clientX - p(d).x,
|
|
4110
4110
|
y: T.clientY - p(d).y
|
|
4111
4111
|
}, !0);
|
|
@@ -4115,7 +4115,7 @@ function al(e, t) {
|
|
|
4115
4115
|
}
|
|
4116
4116
|
}
|
|
4117
4117
|
function Zt(T) {
|
|
4118
|
-
p(o) && (p(o).releasePointerCapture(T.pointerId), p(o).removeEventListener("pointermove", Qt), p(o).removeEventListener("pointerup", Zt),
|
|
4118
|
+
p(o) && (p(o).releasePointerCapture(T.pointerId), p(o).removeEventListener("pointermove", Qt), p(o).removeEventListener("pointerup", Zt), P(c, !1), P(f, !1));
|
|
4119
4119
|
}
|
|
4120
4120
|
function Xn(T) {
|
|
4121
4121
|
let C = !1;
|
|
@@ -4158,7 +4158,7 @@ function al(e, t) {
|
|
|
4158
4158
|
C && T.preventDefault();
|
|
4159
4159
|
}
|
|
4160
4160
|
ht(() => {
|
|
4161
|
-
p(a) && i() && !p(U) && (p(a).registerTool(i(), "Line Reader", void 0, $r.TOOL),
|
|
4161
|
+
p(a) && i() && !p(U) && (p(a).registerTool(i(), "Line Reader", void 0, $r.TOOL), P(U, !0));
|
|
4162
4162
|
}), js(() => () => {
|
|
4163
4163
|
p(a) && i() && p(a).unregisterTool(i());
|
|
4164
4164
|
}), ht(() => {
|
|
@@ -4195,7 +4195,7 @@ function al(e, t) {
|
|
|
4195
4195
|
var $e = ut(Yr, 2);
|
|
4196
4196
|
let Kr;
|
|
4197
4197
|
var io = di($e);
|
|
4198
|
-
Di(2), ni($e), Xs($e, (ve) =>
|
|
4198
|
+
Di(2), ni($e), Xs($e, (ve) => P(o, ve), () => p(o)), hi((ve, It) => {
|
|
4199
4199
|
Ls(to, p(_)), Kr = Hs($e, 1, "pie-tool-line-reader svelte-1a3d6dx", null, Kr, { "pie-tool-line-reader--masking-mode": p(E) === "obscure" }), qe($e, `left: ${p(u).x ?? ""}px; top: ${p(u).y ?? ""}px; width: ${p(h).width ?? ""}px; height: ${p(h).height ?? ""}px;`), Gs($e, "aria-label", `Line Reader tool. Mode: ${p(E) === "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: ${ve ?? ""}, Opacity: ${It ?? ""}%`), qe(io, `background-color: ${p(Jn) ?? ""};`);
|
|
4200
4200
|
}, [() => M.find((ve) => ve.value === p(m))?.name, () => Math.round(p(b) * 100)]), _i("pointerdown", $e, qn), _i("keydown", $e, Xn), Rt(T, C);
|
|
4201
4201
|
};
|
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.38",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Reading guide overlay tool for PIE assessment player",
|
|
6
6
|
"repository": {
|
|
@@ -37,9 +37,9 @@
|
|
|
37
37
|
"unpkg": "./dist/tool-line-reader.js",
|
|
38
38
|
"jsdelivr": "./dist/tool-line-reader.js",
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@pie-players/pie-assessment-toolkit": "0.3.
|
|
41
|
-
"@pie-players/pie-context": "0.3.
|
|
42
|
-
"@pie-players/pie-players-shared": "0.3.
|
|
40
|
+
"@pie-players/pie-assessment-toolkit": "0.3.38",
|
|
41
|
+
"@pie-players/pie-context": "0.3.38",
|
|
42
|
+
"@pie-players/pie-players-shared": "0.3.38"
|
|
43
43
|
},
|
|
44
44
|
"types": "./dist/index.d.ts",
|
|
45
45
|
"scripts": {
|