etudes 22.1.0 → 22.3.0
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/build/etudes.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
function
|
|
1
|
+
import Bs, { Fragment as Do, cloneElement as Hs, Children as jn, isValidElement as An, forwardRef as Te, useRef as we, useEffect as Ee, useLayoutEffect as $e, useState as Oe, useCallback as he, useMemo as pt, Suspense as Ys } from "react";
|
|
2
|
+
function Bo(e) {
|
|
3
3
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
4
4
|
}
|
|
5
5
|
var Jt = { exports: {} }, St = {};
|
|
@@ -35,7 +35,7 @@ function Us() {
|
|
|
35
35
|
return k.$$typeof === oe ? null : k.displayName || k.name || null;
|
|
36
36
|
if (typeof k == "string") return k;
|
|
37
37
|
switch (k) {
|
|
38
|
-
case
|
|
38
|
+
case C:
|
|
39
39
|
return "Fragment";
|
|
40
40
|
case W:
|
|
41
41
|
return "Profiler";
|
|
@@ -63,7 +63,7 @@ function Us() {
|
|
|
63
63
|
return k = k.displayName, k || (k = U.displayName || U.name || "", k = k !== "" ? "ForwardRef(" + k + ")" : "ForwardRef"), k;
|
|
64
64
|
case M:
|
|
65
65
|
return U = k.displayName || null, U !== null ? U : e(k.type) || "Memo";
|
|
66
|
-
case
|
|
66
|
+
case B:
|
|
67
67
|
U = k._payload, k = k._init;
|
|
68
68
|
try {
|
|
69
69
|
return e(k(U));
|
|
@@ -92,8 +92,8 @@ function Us() {
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
function a(k) {
|
|
95
|
-
if (k ===
|
|
96
|
-
if (typeof k == "object" && k !== null && k.$$typeof ===
|
|
95
|
+
if (k === C) return "<>";
|
|
96
|
+
if (typeof k == "object" && k !== null && k.$$typeof === B)
|
|
97
97
|
return "<...>";
|
|
98
98
|
try {
|
|
99
99
|
var U = e(k);
|
|
@@ -134,7 +134,7 @@ function Us() {
|
|
|
134
134
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
135
135
|
)), k = this.props.ref, k !== void 0 ? k : null;
|
|
136
136
|
}
|
|
137
|
-
function b(k, U, Z, G, fe,
|
|
137
|
+
function b(k, U, Z, G, fe, ge) {
|
|
138
138
|
var ue = Z.ref;
|
|
139
139
|
return k = {
|
|
140
140
|
$$typeof: A,
|
|
@@ -164,10 +164,10 @@ function Us() {
|
|
|
164
164
|
configurable: !1,
|
|
165
165
|
enumerable: !1,
|
|
166
166
|
writable: !0,
|
|
167
|
-
value:
|
|
167
|
+
value: ge
|
|
168
168
|
}), Object.freeze && (Object.freeze(k.props), Object.freeze(k)), k;
|
|
169
169
|
}
|
|
170
|
-
function T(k, U, Z, G, fe,
|
|
170
|
+
function T(k, U, Z, G, fe, ge) {
|
|
171
171
|
var ue = U.children;
|
|
172
172
|
if (ue !== void 0)
|
|
173
173
|
if (G)
|
|
@@ -182,8 +182,8 @@ function Us() {
|
|
|
182
182
|
else _(ue);
|
|
183
183
|
if (X.call(U, "key")) {
|
|
184
184
|
ue = e(k);
|
|
185
|
-
var Ne = Object.keys(U).filter(function(
|
|
186
|
-
return
|
|
185
|
+
var Ne = Object.keys(U).filter(function(Be) {
|
|
186
|
+
return Be !== "key";
|
|
187
187
|
});
|
|
188
188
|
G = 0 < Ne.length ? "{key: someKey, " + Ne.join(": ..., ") + ": ...}" : "{key: someKey}", R[ue + G] || (Ne = 0 < Ne.length ? "{" + Ne.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
189
189
|
`A props object containing a "key" prop is being spread into JSX:
|
|
@@ -212,28 +212,28 @@ React keys must be passed directly to JSX without using spread:
|
|
|
212
212
|
Z,
|
|
213
213
|
c(),
|
|
214
214
|
fe,
|
|
215
|
-
|
|
215
|
+
ge
|
|
216
216
|
);
|
|
217
217
|
}
|
|
218
218
|
function _(k) {
|
|
219
|
-
I(k) ? k._store && (k._store.validated = 1) : typeof k == "object" && k !== null && k.$$typeof ===
|
|
219
|
+
I(k) ? k._store && (k._store.validated = 1) : typeof k == "object" && k !== null && k.$$typeof === B && (k._payload.status === "fulfilled" ? I(k._payload.value) && k._payload.value._store && (k._payload.value._store.validated = 1) : k._store && (k._store.validated = 1));
|
|
220
220
|
}
|
|
221
221
|
function I(k) {
|
|
222
222
|
return typeof k == "object" && k !== null && k.$$typeof === A;
|
|
223
223
|
}
|
|
224
|
-
var
|
|
224
|
+
var $ = Bs, A = Symbol.for("react.transitional.element"), S = Symbol.for("react.portal"), C = Symbol.for("react.fragment"), q = Symbol.for("react.strict_mode"), W = Symbol.for("react.profiler"), Y = Symbol.for("react.consumer"), J = Symbol.for("react.context"), x = Symbol.for("react.forward_ref"), P = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), M = Symbol.for("react.memo"), B = Symbol.for("react.lazy"), K = Symbol.for("react.activity"), oe = Symbol.for("react.client.reference"), Q = $.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, X = Object.prototype.hasOwnProperty, D = Array.isArray, z = console.createTask ? console.createTask : function() {
|
|
225
225
|
return null;
|
|
226
226
|
};
|
|
227
|
-
|
|
227
|
+
$ = {
|
|
228
228
|
react_stack_bottom_frame: function(k) {
|
|
229
229
|
return k();
|
|
230
230
|
}
|
|
231
231
|
};
|
|
232
|
-
var te, ne = {}, ae =
|
|
233
|
-
|
|
232
|
+
var te, ne = {}, ae = $.react_stack_bottom_frame.bind(
|
|
233
|
+
$,
|
|
234
234
|
u
|
|
235
|
-
)(),
|
|
236
|
-
_t.Fragment =
|
|
235
|
+
)(), F = z(a(u)), R = {};
|
|
236
|
+
_t.Fragment = C, _t.jsx = function(k, U, Z) {
|
|
237
237
|
var G = 1e4 > Q.recentlyCreatedOwnerStacks++;
|
|
238
238
|
return T(
|
|
239
239
|
k,
|
|
@@ -241,7 +241,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
241
241
|
Z,
|
|
242
242
|
!1,
|
|
243
243
|
G ? Error("react-stack-top-frame") : ae,
|
|
244
|
-
G ? z(a(k)) :
|
|
244
|
+
G ? z(a(k)) : F
|
|
245
245
|
);
|
|
246
246
|
}, _t.jsxs = function(k, U, Z) {
|
|
247
247
|
var G = 1e4 > Q.recentlyCreatedOwnerStacks++;
|
|
@@ -251,7 +251,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
251
251
|
Z,
|
|
252
252
|
!0,
|
|
253
253
|
G ? Error("react-stack-top-frame") : ae,
|
|
254
|
-
G ? z(a(k)) :
|
|
254
|
+
G ? z(a(k)) : F
|
|
255
255
|
);
|
|
256
256
|
};
|
|
257
257
|
})()), _t;
|
|
@@ -261,17 +261,17 @@ function Ks() {
|
|
|
261
261
|
return Eo || (Eo = 1, process.env.NODE_ENV === "production" ? Jt.exports = /* @__PURE__ */ Xs() : Jt.exports = /* @__PURE__ */ Us()), Jt.exports;
|
|
262
262
|
}
|
|
263
263
|
var w = /* @__PURE__ */ Ks();
|
|
264
|
-
function
|
|
264
|
+
function Ho(e) {
|
|
265
265
|
var r, i, a = "";
|
|
266
266
|
if (typeof e == "string" || typeof e == "number") a += e;
|
|
267
267
|
else if (typeof e == "object") if (Array.isArray(e)) {
|
|
268
268
|
var c = e.length;
|
|
269
|
-
for (r = 0; r < c; r++) e[r] && (i =
|
|
269
|
+
for (r = 0; r < c; r++) e[r] && (i = Ho(e[r])) && (a && (a += " "), a += i);
|
|
270
270
|
} else for (i in e) e[i] && (a && (a += " "), a += i);
|
|
271
271
|
return a;
|
|
272
272
|
}
|
|
273
273
|
function se() {
|
|
274
|
-
for (var e, r, i = 0, a = "", c = arguments.length; i < c; i++) (e = arguments[i]) && (r =
|
|
274
|
+
for (var e, r, i = 0, a = "", c = arguments.length; i < c; i++) (e = arguments[i]) && (r = Ho(e)) && (a && (a += " "), a += r);
|
|
275
275
|
return a;
|
|
276
276
|
}
|
|
277
277
|
function nn({
|
|
@@ -284,7 +284,7 @@ function nn({
|
|
|
284
284
|
process.env.NODE_ENV === "development" && (nn.displayName = "Repeat");
|
|
285
285
|
function gr(e, r = {}, ...i) {
|
|
286
286
|
const { className: a, style: c, ...u } = r, { className: d, style: g, ...m } = e.props;
|
|
287
|
-
return
|
|
287
|
+
return Hs(e, {
|
|
288
288
|
className: `${d ?? ""} ${a ?? ""}`.split(" ").filter(Boolean).join(" ") || void 0,
|
|
289
289
|
style: {
|
|
290
290
|
...g ?? {},
|
|
@@ -294,7 +294,7 @@ function gr(e, r = {}, ...i) {
|
|
|
294
294
|
...u
|
|
295
295
|
}, ...i);
|
|
296
296
|
}
|
|
297
|
-
function
|
|
297
|
+
function me({
|
|
298
298
|
children: e,
|
|
299
299
|
element: r,
|
|
300
300
|
...i
|
|
@@ -305,13 +305,13 @@ function ge({
|
|
|
305
305
|
...e ? Array.isArray(e) ? e : [e] : []
|
|
306
306
|
);
|
|
307
307
|
}
|
|
308
|
-
process.env.NODE_ENV === "development" && (
|
|
308
|
+
process.env.NODE_ENV === "development" && (me.displayName = "Styled");
|
|
309
309
|
function Al(e) {
|
|
310
310
|
return e;
|
|
311
311
|
}
|
|
312
312
|
function ze(e, r = {}) {
|
|
313
313
|
const i = Object.keys(r), a = Object.values(r), c = {};
|
|
314
|
-
return
|
|
314
|
+
return jn.forEach(e, (u) => {
|
|
315
315
|
if (u == null)
|
|
316
316
|
return;
|
|
317
317
|
if (!An(u)) {
|
|
@@ -366,7 +366,7 @@ const Yo = /* @__PURE__ */ Te(({
|
|
|
366
366
|
ref: g,
|
|
367
367
|
className: se(r, b.root),
|
|
368
368
|
children: /* @__PURE__ */ w.jsx(nn, { count: c ? 2 : 1, children: (_) => /* @__PURE__ */ w.jsx("div", { "aria-hidden": !0, style: ce(T.section, T[`section${_}`]), children: /* @__PURE__ */ w.jsx(nn, { count: u, children: (I) => /* @__PURE__ */ w.jsx(
|
|
369
|
-
|
|
369
|
+
me,
|
|
370
370
|
{
|
|
371
371
|
"aria-hidden": !0,
|
|
372
372
|
className: se(b.bar),
|
|
@@ -468,7 +468,7 @@ const Uo = /* @__PURE__ */ Te(({
|
|
|
468
468
|
const I = () => {
|
|
469
469
|
const S = !a;
|
|
470
470
|
b?.(S), S ? g?.() : m?.();
|
|
471
|
-
},
|
|
471
|
+
}, $ = {
|
|
472
472
|
root: se({
|
|
473
473
|
active: a
|
|
474
474
|
})
|
|
@@ -479,7 +479,7 @@ const Uo = /* @__PURE__ */ Te(({
|
|
|
479
479
|
...T,
|
|
480
480
|
ref: _,
|
|
481
481
|
"aria-expanded": a,
|
|
482
|
-
className: se(r,
|
|
482
|
+
className: se(r, $.root),
|
|
483
483
|
style: ce(i, A.root),
|
|
484
484
|
onClick: I,
|
|
485
485
|
children: /* @__PURE__ */ w.jsx(
|
|
@@ -514,9 +514,9 @@ process.env.NODE_ENV === "development" && (Uo.displayName = "BurgerButton", Ko.d
|
|
|
514
514
|
var _e;
|
|
515
515
|
((e) => {
|
|
516
516
|
e.zero = r();
|
|
517
|
-
function r(S = 0,
|
|
517
|
+
function r(S = 0, C = 0) {
|
|
518
518
|
if (typeof S == "number")
|
|
519
|
-
return { x: S, y:
|
|
519
|
+
return { x: S, y: C };
|
|
520
520
|
if (!I(S)) throw Error("Invalid parameters passed to constructor");
|
|
521
521
|
return S instanceof Array ? {
|
|
522
522
|
x: S[0],
|
|
@@ -527,38 +527,38 @@ var _e;
|
|
|
527
527
|
};
|
|
528
528
|
}
|
|
529
529
|
e.make = r;
|
|
530
|
-
function i(S,
|
|
530
|
+
function i(S, C = {}) {
|
|
531
531
|
return r({
|
|
532
|
-
x: typeof
|
|
533
|
-
y: typeof
|
|
532
|
+
x: typeof C.x == "number" ? C.x : S.x,
|
|
533
|
+
y: typeof C.y == "number" ? C.y : S.y
|
|
534
534
|
});
|
|
535
535
|
}
|
|
536
536
|
e.clone = i;
|
|
537
|
-
function a(S,
|
|
537
|
+
function a(S, C) {
|
|
538
538
|
return r({
|
|
539
|
-
x: S.x +
|
|
540
|
-
y: S.y +
|
|
539
|
+
x: S.x + C.x,
|
|
540
|
+
y: S.y + C.y
|
|
541
541
|
});
|
|
542
542
|
}
|
|
543
543
|
e.add = a;
|
|
544
|
-
function c(S,
|
|
544
|
+
function c(S, C) {
|
|
545
545
|
return r({
|
|
546
|
-
x: S.x -
|
|
547
|
-
y: S.y -
|
|
546
|
+
x: S.x - C.x,
|
|
547
|
+
y: S.y - C.y
|
|
548
548
|
});
|
|
549
549
|
}
|
|
550
550
|
e.subtract = c;
|
|
551
|
-
function u(S,
|
|
551
|
+
function u(S, C) {
|
|
552
552
|
return r({
|
|
553
|
-
x: S.x *
|
|
554
|
-
y: S.y *
|
|
553
|
+
x: S.x * C.x,
|
|
554
|
+
y: S.y * C.y
|
|
555
555
|
});
|
|
556
556
|
}
|
|
557
557
|
e.multiply = u;
|
|
558
|
-
function d(S,
|
|
558
|
+
function d(S, C) {
|
|
559
559
|
return r({
|
|
560
|
-
x: S.x /
|
|
561
|
-
y: S.y /
|
|
560
|
+
x: S.x / C.x,
|
|
561
|
+
y: S.y / C.y
|
|
562
562
|
});
|
|
563
563
|
}
|
|
564
564
|
e.divide = d;
|
|
@@ -569,8 +569,8 @@ var _e;
|
|
|
569
569
|
});
|
|
570
570
|
}
|
|
571
571
|
e.reflect = g;
|
|
572
|
-
function m(S,
|
|
573
|
-
return !(S.x !==
|
|
572
|
+
function m(S, C) {
|
|
573
|
+
return !(S.x !== C.x || S.y !== C.y);
|
|
574
574
|
}
|
|
575
575
|
e.isEqual = m;
|
|
576
576
|
function b(S) {
|
|
@@ -592,10 +592,10 @@ var _e;
|
|
|
592
592
|
return S instanceof Array ? !(S.length !== 2 || typeof S[0] != "number" || typeof S[1] != "number") : typeof S == "object" ? !(typeof S.x != "number" || typeof S.y != "number") : !1;
|
|
593
593
|
}
|
|
594
594
|
e.isValidDescriptor = I;
|
|
595
|
-
function
|
|
595
|
+
function $(S) {
|
|
596
596
|
return typeof S == "object" && typeof S.x == "number" && typeof S.y == "number";
|
|
597
597
|
}
|
|
598
|
-
e.isPoint =
|
|
598
|
+
e.isPoint = $;
|
|
599
599
|
function A(S) {
|
|
600
600
|
return S.x === 0 && S.y === 0;
|
|
601
601
|
}
|
|
@@ -640,9 +640,9 @@ function Ws(e, r) {
|
|
|
640
640
|
var je;
|
|
641
641
|
((e) => {
|
|
642
642
|
e.zero = r();
|
|
643
|
-
function r(S = 0,
|
|
643
|
+
function r(S = 0, C = 0) {
|
|
644
644
|
if (typeof S == "number")
|
|
645
|
-
return { width: S, height:
|
|
645
|
+
return { width: S, height: C };
|
|
646
646
|
if (!I(S)) throw Error("Invalid parameters passed to constructor");
|
|
647
647
|
return S instanceof Array ? {
|
|
648
648
|
width: S[0],
|
|
@@ -653,38 +653,38 @@ var je;
|
|
|
653
653
|
};
|
|
654
654
|
}
|
|
655
655
|
e.make = r;
|
|
656
|
-
function i(S,
|
|
656
|
+
function i(S, C = {}) {
|
|
657
657
|
return r({
|
|
658
|
-
width: typeof
|
|
659
|
-
height: typeof
|
|
658
|
+
width: typeof C.width == "number" ? C.width : S.width,
|
|
659
|
+
height: typeof C.height == "number" ? C.height : S.height
|
|
660
660
|
});
|
|
661
661
|
}
|
|
662
662
|
e.clone = i;
|
|
663
|
-
function a(S,
|
|
663
|
+
function a(S, C) {
|
|
664
664
|
return r({
|
|
665
|
-
width: S.width +
|
|
666
|
-
height: S.height +
|
|
665
|
+
width: S.width + C.width,
|
|
666
|
+
height: S.height + C.height
|
|
667
667
|
});
|
|
668
668
|
}
|
|
669
669
|
e.add = a;
|
|
670
|
-
function c(S,
|
|
670
|
+
function c(S, C) {
|
|
671
671
|
return r({
|
|
672
|
-
width: S.width -
|
|
673
|
-
height: S.height -
|
|
672
|
+
width: S.width - C.width,
|
|
673
|
+
height: S.height - C.height
|
|
674
674
|
});
|
|
675
675
|
}
|
|
676
676
|
e.subtract = c;
|
|
677
|
-
function u(S,
|
|
677
|
+
function u(S, C) {
|
|
678
678
|
return r({
|
|
679
|
-
width: S.width *
|
|
680
|
-
height: S.height *
|
|
679
|
+
width: S.width * C.width,
|
|
680
|
+
height: S.height * C.height
|
|
681
681
|
});
|
|
682
682
|
}
|
|
683
683
|
e.multiply = u;
|
|
684
|
-
function d(S,
|
|
684
|
+
function d(S, C) {
|
|
685
685
|
return r({
|
|
686
|
-
width: S.width /
|
|
687
|
-
height: S.height /
|
|
686
|
+
width: S.width / C.width,
|
|
687
|
+
height: S.height / C.height
|
|
688
688
|
});
|
|
689
689
|
}
|
|
690
690
|
e.divide = d;
|
|
@@ -695,8 +695,8 @@ var je;
|
|
|
695
695
|
});
|
|
696
696
|
}
|
|
697
697
|
e.rotate = g;
|
|
698
|
-
function m(S,
|
|
699
|
-
return !(S.width !==
|
|
698
|
+
function m(S, C) {
|
|
699
|
+
return !(S.width !== C.width || S.height !== C.height);
|
|
700
700
|
}
|
|
701
701
|
e.isEqual = m;
|
|
702
702
|
function b(S) {
|
|
@@ -718,10 +718,10 @@ var je;
|
|
|
718
718
|
return S instanceof Array ? !(S.length !== 2 || typeof S[0] != "number" || typeof S[1] != "number") : typeof S == "object" ? !(typeof S.width != "number" || typeof S.height != "number") : !1;
|
|
719
719
|
}
|
|
720
720
|
e.isValidDescriptor = I;
|
|
721
|
-
function
|
|
721
|
+
function $(S) {
|
|
722
722
|
return typeof S == "object" && typeof S.width == "number" && typeof S.height == "number";
|
|
723
723
|
}
|
|
724
|
-
e.isSize =
|
|
724
|
+
e.isSize = $;
|
|
725
725
|
function A(S) {
|
|
726
726
|
return S.width === 0 && S.height === 0;
|
|
727
727
|
}
|
|
@@ -732,35 +732,35 @@ var be;
|
|
|
732
732
|
e.zero = r();
|
|
733
733
|
function r(x = 0, P = 0, E = 0, M = 0) {
|
|
734
734
|
if (typeof x == "number" && typeof P == "number") {
|
|
735
|
-
const
|
|
735
|
+
const B = x, K = P;
|
|
736
736
|
return {
|
|
737
737
|
top: K,
|
|
738
|
-
right:
|
|
738
|
+
right: B + E,
|
|
739
739
|
bottom: K + M,
|
|
740
|
-
left:
|
|
740
|
+
left: B,
|
|
741
741
|
width: E,
|
|
742
742
|
height: M
|
|
743
743
|
};
|
|
744
744
|
} else if (_e.isPoint(x) && je.isSize(P)) {
|
|
745
|
-
const
|
|
745
|
+
const B = x, K = P;
|
|
746
746
|
return {
|
|
747
|
-
top:
|
|
748
|
-
right:
|
|
749
|
-
bottom:
|
|
750
|
-
left:
|
|
747
|
+
top: B.y,
|
|
748
|
+
right: B.x + K.width,
|
|
749
|
+
bottom: B.y + K.height,
|
|
750
|
+
left: B.x,
|
|
751
751
|
width: K.width,
|
|
752
752
|
height: K.height
|
|
753
753
|
};
|
|
754
754
|
} else {
|
|
755
|
-
const
|
|
756
|
-
if (!W(
|
|
755
|
+
const B = x;
|
|
756
|
+
if (!W(B)) throw Error("Invalid parameters passed to constructor");
|
|
757
757
|
return {
|
|
758
|
-
top:
|
|
759
|
-
right:
|
|
760
|
-
bottom:
|
|
761
|
-
left:
|
|
762
|
-
width:
|
|
763
|
-
height:
|
|
758
|
+
top: B.y,
|
|
759
|
+
right: B.x + B.width,
|
|
760
|
+
bottom: B.y + B.height,
|
|
761
|
+
left: B.x,
|
|
762
|
+
width: B.width,
|
|
763
|
+
height: B.height
|
|
764
764
|
};
|
|
765
765
|
}
|
|
766
766
|
}
|
|
@@ -784,13 +784,13 @@ var be;
|
|
|
784
784
|
if (x == null) return;
|
|
785
785
|
if (Y(x)) return x;
|
|
786
786
|
if (Tt(x)) return c(document.documentElement || document.body.parentNode || document.body, P);
|
|
787
|
-
const E = x instanceof Array ? x : [x], M = E.length,
|
|
787
|
+
const E = x instanceof Array ? x : [x], M = E.length, B = P.reference || window, K = u(), oe = Tt(B) ? K : c(P.reference);
|
|
788
788
|
if (!K || !oe) return;
|
|
789
789
|
let Q;
|
|
790
790
|
for (let X = 0; X < M; X++) {
|
|
791
791
|
const D = E[X], z = D.getBoundingClientRect(), te = r({
|
|
792
|
-
x: z.left + K.left - (Tt(
|
|
793
|
-
y: z.top + K.top - (Tt(
|
|
792
|
+
x: z.left + K.left - (Tt(B) ? 0 : oe.left),
|
|
793
|
+
y: z.top + K.top - (Tt(B) ? 0 : oe.top),
|
|
794
794
|
width: P.overflow ? D.scrollWidth : D instanceof HTMLElement ? D.offsetWidth : z.width,
|
|
795
795
|
height: P.overflow ? D.scrollHeight : D instanceof HTMLElement ? D.offsetHeight : z.height
|
|
796
796
|
});
|
|
@@ -840,15 +840,15 @@ var be;
|
|
|
840
840
|
function T(...x) {
|
|
841
841
|
try {
|
|
842
842
|
const P = x.length, E = {};
|
|
843
|
-
let M,
|
|
843
|
+
let M, B;
|
|
844
844
|
for (let K = 0; K < P; K++) {
|
|
845
845
|
if (M || (M = c(x[K])), K === 0 && K + 1 === P)
|
|
846
|
-
|
|
846
|
+
B = u();
|
|
847
847
|
else if (K + 1 < P)
|
|
848
|
-
|
|
848
|
+
B = c(x[K + 1]);
|
|
849
849
|
else
|
|
850
850
|
break;
|
|
851
|
-
!M || !
|
|
851
|
+
!M || !B || (E.width = Math.max(0, Math.min(M.right, B.right) - Math.max(M.left, B.left)), E.height = Math.max(0, Math.min(M.bottom, B.bottom) - Math.max(M.top, B.top)), E.y = Math.max(M.top, B.top), E.x = Math.max(M.left, B.left), E.width * E.height === 0 && (E.width = 0, E.height = 0, E.y = NaN, E.x = NaN), M = r(E));
|
|
852
852
|
}
|
|
853
853
|
return r(E);
|
|
854
854
|
} catch (P) {
|
|
@@ -875,7 +875,7 @@ var be;
|
|
|
875
875
|
});
|
|
876
876
|
}
|
|
877
877
|
e.concat = I;
|
|
878
|
-
function
|
|
878
|
+
function $(x) {
|
|
879
879
|
return r({
|
|
880
880
|
x: x.left,
|
|
881
881
|
y: x.top,
|
|
@@ -883,7 +883,7 @@ var be;
|
|
|
883
883
|
height: x.width
|
|
884
884
|
});
|
|
885
885
|
}
|
|
886
|
-
e.rotate =
|
|
886
|
+
e.rotate = $;
|
|
887
887
|
function A(x, P) {
|
|
888
888
|
return !(x.top !== P.top || x.right !== P.right || x.bottom !== P.bottom || x.left !== P.left || x.width !== P.width || x.height !== P.height);
|
|
889
889
|
}
|
|
@@ -892,10 +892,10 @@ var be;
|
|
|
892
892
|
return Ws(P, x);
|
|
893
893
|
}
|
|
894
894
|
e.contains = S;
|
|
895
|
-
function
|
|
895
|
+
function C(x) {
|
|
896
896
|
return `Rect(top=${x.top}, right=${x.right}, bottom=${x.bottom}, left=${x.left}, width=${x.width}, height=${x.height})`;
|
|
897
897
|
}
|
|
898
|
-
e.toString =
|
|
898
|
+
e.toString = C;
|
|
899
899
|
function q(x) {
|
|
900
900
|
return Object.freeze({
|
|
901
901
|
top: x.top,
|
|
@@ -931,7 +931,7 @@ function Se(e) {
|
|
|
931
931
|
}
|
|
932
932
|
function Js(e, { onChange: r }) {
|
|
933
933
|
const i = Se(r);
|
|
934
|
-
|
|
934
|
+
$e(() => {
|
|
935
935
|
const a = e.current;
|
|
936
936
|
if (!a) return;
|
|
937
937
|
const c = new IntersectionObserver((u) => {
|
|
@@ -948,7 +948,7 @@ function Js(e, { onChange: r }) {
|
|
|
948
948
|
}
|
|
949
949
|
function mr(e, { onResize: r }) {
|
|
950
950
|
const i = Se(r);
|
|
951
|
-
|
|
951
|
+
$e(() => {
|
|
952
952
|
const a = e.current;
|
|
953
953
|
if (!a) return;
|
|
954
954
|
const c = new ResizeObserver(() => {
|
|
@@ -961,7 +961,7 @@ function mr(e, { onResize: r }) {
|
|
|
961
961
|
}
|
|
962
962
|
function Zs() {
|
|
963
963
|
const [e, r] = Oe(je.zero);
|
|
964
|
-
return
|
|
964
|
+
return $e(() => {
|
|
965
965
|
const i = () => {
|
|
966
966
|
const a = be.size(be.fromViewport());
|
|
967
967
|
r(a);
|
|
@@ -983,7 +983,7 @@ function nt(e) {
|
|
|
983
983
|
const u = be.from(c);
|
|
984
984
|
u && i(u);
|
|
985
985
|
}
|
|
986
|
-
}),
|
|
986
|
+
}), $e(() => {
|
|
987
987
|
const c = e.current, u = be.from(c);
|
|
988
988
|
u && i(u);
|
|
989
989
|
}, [je.toString(a)]), r;
|
|
@@ -1037,7 +1037,7 @@ var on;
|
|
|
1037
1037
|
})(on || (on = {}));
|
|
1038
1038
|
function Qs({ src: e, srcSet: r, sizes: i }, { onLoadStart: a, onLoadComplete: c, onLoadError: u } = {}) {
|
|
1039
1039
|
const d = we(void 0), g = Se(a), m = Se(c), b = Se(u);
|
|
1040
|
-
|
|
1040
|
+
$e(() => {
|
|
1041
1041
|
let T = !1;
|
|
1042
1042
|
const _ = (A) => {
|
|
1043
1043
|
if (T) return;
|
|
@@ -1047,9 +1047,9 @@ function Qs({ src: e, srcSet: r, sizes: i }, { onLoadStart: a, onLoadComplete: c
|
|
|
1047
1047
|
if (T) return;
|
|
1048
1048
|
const S = A.currentTarget;
|
|
1049
1049
|
b.current?.(S);
|
|
1050
|
-
},
|
|
1051
|
-
return
|
|
1052
|
-
T = !0,
|
|
1050
|
+
}, $ = new Image();
|
|
1051
|
+
return $.addEventListener("load", _), $.addEventListener("error", I), g.current?.($), r && ($.srcset = r), i && ($.sizes = i), $.src = e, d.current = $, () => {
|
|
1052
|
+
T = !0, $.removeEventListener("load", _), $.removeEventListener("error", I), d.current = void 0;
|
|
1053
1053
|
};
|
|
1054
1054
|
}, [e, r, i]);
|
|
1055
1055
|
}
|
|
@@ -1063,16 +1063,16 @@ function Go({
|
|
|
1063
1063
|
onLoadComplete: u,
|
|
1064
1064
|
onLoadError: d
|
|
1065
1065
|
} = {}) {
|
|
1066
|
-
const [g, m] = Oe(), b = Se(c), T = Se(u), _ = Se(d), I =
|
|
1066
|
+
const [g, m] = Oe(), b = Se(c), T = Se(u), _ = Se(d), I = he((S) => {
|
|
1067
1067
|
a || m(void 0), b.current?.(S);
|
|
1068
|
-
}, [a]),
|
|
1068
|
+
}, [a]), $ = he((S) => {
|
|
1069
1069
|
m(ea(S)), T.current?.(S);
|
|
1070
|
-
}, []), A =
|
|
1070
|
+
}, []), A = he((S) => {
|
|
1071
1071
|
a || m(void 0), _.current?.(S);
|
|
1072
1072
|
}, [a]);
|
|
1073
1073
|
return Qs({ src: e, srcSet: r, sizes: i }, {
|
|
1074
1074
|
onLoadStart: I,
|
|
1075
|
-
onLoadComplete:
|
|
1075
|
+
onLoadComplete: $,
|
|
1076
1076
|
onLoadError: A
|
|
1077
1077
|
}), g;
|
|
1078
1078
|
}
|
|
@@ -1100,7 +1100,7 @@ const qo = /* @__PURE__ */ Te(({
|
|
|
1100
1100
|
onLoadStart: u,
|
|
1101
1101
|
onLoadComplete: d,
|
|
1102
1102
|
onLoadError: g
|
|
1103
|
-
}),
|
|
1103
|
+
}), $ = ta();
|
|
1104
1104
|
return Ee(() => {
|
|
1105
1105
|
m?.(I);
|
|
1106
1106
|
}, [I?.width, I?.height]), /* @__PURE__ */ w.jsx(
|
|
@@ -1112,7 +1112,7 @@ const qo = /* @__PURE__ */ Te(({
|
|
|
1112
1112
|
alt: e,
|
|
1113
1113
|
loading: i,
|
|
1114
1114
|
src: a,
|
|
1115
|
-
style: {
|
|
1115
|
+
style: { ...$.root, ...c }
|
|
1116
1116
|
}
|
|
1117
1117
|
);
|
|
1118
1118
|
});
|
|
@@ -1165,8 +1165,8 @@ const Jo = /* @__PURE__ */ Te(({
|
|
|
1165
1165
|
...T
|
|
1166
1166
|
}, _) => {
|
|
1167
1167
|
const I = (P) => {
|
|
1168
|
-
|
|
1169
|
-
},
|
|
1168
|
+
C(P ? P.width / P.height : NaN);
|
|
1169
|
+
}, $ = we(null), A = _ ?? $, [S, C] = Oe(NaN), q = isNaN(i) ? S : i, W = nt(A), Y = W.width / W.height, J = je.make(
|
|
1170
1170
|
Y > 1 ? Math.max(W.width, W.height * q) : Math.max(W.width, Math.max(W.height, W.width / q) * q),
|
|
1171
1171
|
Y > 1 ? Math.max(W.height, Math.max(W.width, W.height * q) / q) : Math.max(W.height, W.width / q)
|
|
1172
1172
|
), x = ze(e, {
|
|
@@ -1198,7 +1198,7 @@ const Jo = /* @__PURE__ */ Te(({
|
|
|
1198
1198
|
}
|
|
1199
1199
|
),
|
|
1200
1200
|
x.viewport && /* @__PURE__ */ w.jsx(
|
|
1201
|
-
|
|
1201
|
+
me,
|
|
1202
1202
|
{
|
|
1203
1203
|
element: x.viewport,
|
|
1204
1204
|
style: ce(ar.viewport, {
|
|
@@ -1240,7 +1240,7 @@ function na(e, {
|
|
|
1240
1240
|
onLoadError: a
|
|
1241
1241
|
} = {}) {
|
|
1242
1242
|
const c = Se(r), u = Se(i), d = Se(a);
|
|
1243
|
-
|
|
1243
|
+
$e(() => {
|
|
1244
1244
|
if (!e) return;
|
|
1245
1245
|
const g = window.document.createElement("video"), m = () => u.current?.(g), b = () => d.current?.(g);
|
|
1246
1246
|
return g.addEventListener("loadedmetadata", m), g.addEventListener("error", b), g.src = e, c.current?.(g), () => {
|
|
@@ -1254,12 +1254,12 @@ function ra(e, {
|
|
|
1254
1254
|
onLoadComplete: a,
|
|
1255
1255
|
onLoadError: c
|
|
1256
1256
|
} = {}) {
|
|
1257
|
-
const [u, d] = Oe(), g = Se(i), m = Se(a), b = Se(c), T =
|
|
1258
|
-
r || d(void 0), g.current?.(
|
|
1259
|
-
}, [r]), _ =
|
|
1260
|
-
d(oa(
|
|
1261
|
-
}, []), I =
|
|
1262
|
-
r || d(void 0), b.current?.(
|
|
1257
|
+
const [u, d] = Oe(), g = Se(i), m = Se(a), b = Se(c), T = he(($) => {
|
|
1258
|
+
r || d(void 0), g.current?.($);
|
|
1259
|
+
}, [r]), _ = he(($) => {
|
|
1260
|
+
d(oa($)), m.current?.($);
|
|
1261
|
+
}, []), I = he(($) => {
|
|
1262
|
+
r || d(void 0), b.current?.($);
|
|
1263
1263
|
}, [r]);
|
|
1264
1264
|
return na(e, {
|
|
1265
1265
|
onLoadStart: T,
|
|
@@ -1285,17 +1285,17 @@ const Zo = /* @__PURE__ */ Te(({
|
|
|
1285
1285
|
onFullscreenChange: T,
|
|
1286
1286
|
onLoadMetadata: _,
|
|
1287
1287
|
onLoadMetadataComplete: I,
|
|
1288
|
-
onLoadMetadataError:
|
|
1288
|
+
onLoadMetadataError: $,
|
|
1289
1289
|
onPause: A,
|
|
1290
1290
|
onPlay: S,
|
|
1291
|
-
onSizeChange:
|
|
1291
|
+
onSizeChange: C,
|
|
1292
1292
|
onTimeUpdate: q,
|
|
1293
1293
|
...W
|
|
1294
1294
|
}, Y) => {
|
|
1295
1295
|
const J = we(null), x = Y ?? J, P = ra(d, {
|
|
1296
1296
|
onLoadStart: _,
|
|
1297
1297
|
onLoadComplete: I,
|
|
1298
|
-
onLoadError:
|
|
1298
|
+
onLoadError: $
|
|
1299
1299
|
}), E = ia();
|
|
1300
1300
|
Ee(() => {
|
|
1301
1301
|
if (!x.current) return;
|
|
@@ -1314,12 +1314,12 @@ const Zo = /* @__PURE__ */ Te(({
|
|
|
1314
1314
|
D(), x.current?.removeEventListener("webkitfullscreenchange", z), x.current?.removeEventListener("mozfullscreenchange", z), x.current?.removeEventListener("fullscreenchange", z);
|
|
1315
1315
|
};
|
|
1316
1316
|
}, [d]), Ee(() => {
|
|
1317
|
-
|
|
1317
|
+
C?.(P);
|
|
1318
1318
|
}, [P]);
|
|
1319
1319
|
const M = (z) => {
|
|
1320
1320
|
const te = z.currentTarget;
|
|
1321
1321
|
r && te.paused && X(), m?.();
|
|
1322
|
-
},
|
|
1322
|
+
}, B = (z) => {
|
|
1323
1323
|
S?.();
|
|
1324
1324
|
}, K = (z) => {
|
|
1325
1325
|
A?.();
|
|
@@ -1348,7 +1348,7 @@ const Zo = /* @__PURE__ */ Te(({
|
|
|
1348
1348
|
onCanPlay: M,
|
|
1349
1349
|
onEnded: oe,
|
|
1350
1350
|
onPause: K,
|
|
1351
|
-
onPlay:
|
|
1351
|
+
onPlay: B,
|
|
1352
1352
|
onTimeUpdate: Q,
|
|
1353
1353
|
children: /* @__PURE__ */ w.jsx("source", { src: d })
|
|
1354
1354
|
}
|
|
@@ -1376,10 +1376,10 @@ const Qo = /* @__PURE__ */ Te(({
|
|
|
1376
1376
|
src: T,
|
|
1377
1377
|
onCanPlay: _,
|
|
1378
1378
|
onEnd: I,
|
|
1379
|
-
onFullscreenChange:
|
|
1379
|
+
onFullscreenChange: $,
|
|
1380
1380
|
onLoadMetadata: A,
|
|
1381
1381
|
onLoadMetadataComplete: S,
|
|
1382
|
-
onLoadMetadataError:
|
|
1382
|
+
onLoadMetadataError: C,
|
|
1383
1383
|
onPause: q,
|
|
1384
1384
|
onPlay: W,
|
|
1385
1385
|
onSizeChange: Y,
|
|
@@ -1387,7 +1387,7 @@ const Qo = /* @__PURE__ */ Te(({
|
|
|
1387
1387
|
}, x) => {
|
|
1388
1388
|
const P = (z) => {
|
|
1389
1389
|
K(z ? z.width / z.height : NaN), Y?.(z);
|
|
1390
|
-
}, E = x ?? we(null), M = nt(E), [
|
|
1390
|
+
}, E = x ?? we(null), M = nt(E), [B, K] = Oe(NaN), oe = isNaN(a) ? B : a, Q = M.width / M.height, X = je.make(
|
|
1391
1391
|
Q > 1 ? Math.max(M.width, M.height * oe) : Math.max(M.width, Math.max(M.height, M.width / oe) * oe),
|
|
1392
1392
|
Q > 1 ? Math.max(M.height, Math.max(M.width, M.height * oe) / oe) : Math.max(M.height, M.width / oe)
|
|
1393
1393
|
), D = ze(r, {
|
|
@@ -1419,17 +1419,17 @@ const Qo = /* @__PURE__ */ Te(({
|
|
|
1419
1419
|
}),
|
|
1420
1420
|
onCanPlay: _,
|
|
1421
1421
|
onEnd: I,
|
|
1422
|
-
onFullscreenChange:
|
|
1422
|
+
onFullscreenChange: $,
|
|
1423
1423
|
onLoadMetadata: A,
|
|
1424
1424
|
onLoadMetadataComplete: S,
|
|
1425
|
-
onLoadMetadataError:
|
|
1425
|
+
onLoadMetadataError: C,
|
|
1426
1426
|
onPause: q,
|
|
1427
1427
|
onPlay: W,
|
|
1428
1428
|
onSizeChange: (z) => P(z)
|
|
1429
1429
|
}
|
|
1430
1430
|
),
|
|
1431
1431
|
D.viewport && /* @__PURE__ */ w.jsx(
|
|
1432
|
-
|
|
1432
|
+
me,
|
|
1433
1433
|
{
|
|
1434
1434
|
element: D.viewport,
|
|
1435
1435
|
style: ce(cr.viewport, {
|
|
@@ -1443,7 +1443,7 @@ const Qo = /* @__PURE__ */ Te(({
|
|
|
1443
1443
|
]
|
|
1444
1444
|
}
|
|
1445
1445
|
);
|
|
1446
|
-
}), br = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), xr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }),
|
|
1446
|
+
}), br = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), xr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), Ll = /* @__PURE__ */ Object.assign(Qo, {
|
|
1447
1447
|
/**
|
|
1448
1448
|
* Component for optional content inside a {@link CoverVideo}.
|
|
1449
1449
|
*/
|
|
@@ -1520,7 +1520,7 @@ const ca = /* @__PURE__ */ Te(({
|
|
|
1520
1520
|
onChange: a,
|
|
1521
1521
|
...c
|
|
1522
1522
|
}, u) => {
|
|
1523
|
-
const d = i.length - 1, g = i[e], m = typeof g == "string" ? g : g?.label, b =
|
|
1523
|
+
const d = i.length - 1, g = i[e], m = typeof g == "string" ? g : g?.label, b = he(() => {
|
|
1524
1524
|
if (r) return;
|
|
1525
1525
|
const T = e < d ? e + 1 : 0, _ = i[T], I = typeof _ == "string" ? _ : _?.value;
|
|
1526
1526
|
a?.(I, T);
|
|
@@ -1567,7 +1567,7 @@ function la() {
|
|
|
1567
1567
|
}), lr;
|
|
1568
1568
|
}
|
|
1569
1569
|
var ua = /* @__PURE__ */ la();
|
|
1570
|
-
const qe = /* @__PURE__ */
|
|
1570
|
+
const qe = /* @__PURE__ */ Bo(ua);
|
|
1571
1571
|
var en = { exports: {} }, fa = en.exports, So;
|
|
1572
1572
|
function da() {
|
|
1573
1573
|
return So || (So = 1, (function(e, r) {
|
|
@@ -1635,7 +1635,7 @@ function da() {
|
|
|
1635
1635
|
if (n === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1636
1636
|
return n;
|
|
1637
1637
|
}
|
|
1638
|
-
function
|
|
1638
|
+
function $(n) {
|
|
1639
1639
|
var t = (function() {
|
|
1640
1640
|
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
1641
1641
|
if (typeof Proxy == "function") return !0;
|
|
@@ -1684,7 +1684,7 @@ function da() {
|
|
|
1684
1684
|
})(n, "string");
|
|
1685
1685
|
return typeof t == "symbol" ? t : t + "";
|
|
1686
1686
|
}
|
|
1687
|
-
var
|
|
1687
|
+
var C = function(n) {
|
|
1688
1688
|
return !(!n || !n.Window) && n instanceof n.Window;
|
|
1689
1689
|
}, q = void 0, W = void 0;
|
|
1690
1690
|
function Y(n) {
|
|
@@ -1693,7 +1693,7 @@ function da() {
|
|
|
1693
1693
|
t.ownerDocument !== n.document && typeof n.wrap == "function" && n.wrap(t) === t && (n = n.wrap(n)), W = n;
|
|
1694
1694
|
}
|
|
1695
1695
|
function J(n) {
|
|
1696
|
-
return
|
|
1696
|
+
return C(n) ? n : (n.ownerDocument || n).defaultView || W.window;
|
|
1697
1697
|
}
|
|
1698
1698
|
typeof window < "u" && window && Y(window);
|
|
1699
1699
|
var x = function(n) {
|
|
@@ -1701,7 +1701,7 @@ function da() {
|
|
|
1701
1701
|
}, P = function(n) {
|
|
1702
1702
|
return typeof n == "function";
|
|
1703
1703
|
}, E = { window: function(n) {
|
|
1704
|
-
return n === W ||
|
|
1704
|
+
return n === W || C(n);
|
|
1705
1705
|
}, docFrag: function(n) {
|
|
1706
1706
|
return x(n) && n.nodeType === 11;
|
|
1707
1707
|
}, object: x, func: P, number: function(n) {
|
|
@@ -1726,7 +1726,7 @@ function da() {
|
|
|
1726
1726
|
o === "x" ? (t.coords.cur.page.y = t.coords.start.page.y, t.coords.cur.client.y = t.coords.start.client.y, t.coords.velocity.client.y = 0, t.coords.velocity.page.y = 0) : o === "y" && (t.coords.cur.page.x = t.coords.start.page.x, t.coords.cur.client.x = t.coords.start.client.x, t.coords.velocity.client.x = 0, t.coords.velocity.page.x = 0);
|
|
1727
1727
|
}
|
|
1728
1728
|
}
|
|
1729
|
-
function
|
|
1729
|
+
function B(n) {
|
|
1730
1730
|
var t = n.iEvent, o = n.interaction;
|
|
1731
1731
|
if (o.prepared.name === "drag") {
|
|
1732
1732
|
var s = o.prepared.axis;
|
|
@@ -1739,12 +1739,12 @@ function da() {
|
|
|
1739
1739
|
var K = { id: "actions/drag", install: function(n) {
|
|
1740
1740
|
var t = n.actions, o = n.Interactable, s = n.defaults;
|
|
1741
1741
|
o.prototype.draggable = K.draggable, t.map.drag = K, t.methodDict.drag = "draggable", s.actions.drag = K.defaults;
|
|
1742
|
-
}, listeners: { "interactions:before-action-move": M, "interactions:action-resume": M, "interactions:action-move":
|
|
1742
|
+
}, listeners: { "interactions:before-action-move": M, "interactions:action-resume": M, "interactions:action-move": B, "auto-start:check": function(n) {
|
|
1743
1743
|
var t = n.interaction, o = n.interactable, s = n.buttons, l = o.options.drag;
|
|
1744
1744
|
if (l && l.enabled && (!t.pointerIsDown || !/mouse|pointer/.test(t.pointerType) || (s & o.options.drag.mouseButtons) != 0)) return n.action = { name: "drag", axis: l.lockAxis === "start" ? l.startAxis : l.lockAxis }, !1;
|
|
1745
1745
|
} }, draggable: function(n) {
|
|
1746
1746
|
return E.object(n) ? (this.options.drag.enabled = n.enabled !== !1, this.setPerAction("drag", n), this.setOnEvents("drag", n), /^(xy|x|y|start)$/.test(n.lockAxis) && (this.options.drag.lockAxis = n.lockAxis), /^(xy|x|y)$/.test(n.startAxis) && (this.options.drag.startAxis = n.startAxis), this) : E.bool(n) ? (this.options.drag.enabled = n, this) : this.options.drag;
|
|
1747
|
-
}, beforeMove: M, move:
|
|
1747
|
+
}, beforeMove: M, move: B, defaults: { startAxis: "xy", lockAxis: "xy" }, getCursor: function() {
|
|
1748
1748
|
return "move";
|
|
1749
1749
|
}, filterEventType: function(n) {
|
|
1750
1750
|
return n.search("drag") === 0;
|
|
@@ -1769,11 +1769,11 @@ function da() {
|
|
|
1769
1769
|
function ae(n, t) {
|
|
1770
1770
|
for (; E.element(n); ) {
|
|
1771
1771
|
if (R(n, t)) return n;
|
|
1772
|
-
n =
|
|
1772
|
+
n = F(n);
|
|
1773
1773
|
}
|
|
1774
1774
|
return null;
|
|
1775
1775
|
}
|
|
1776
|
-
function
|
|
1776
|
+
function F(n) {
|
|
1777
1777
|
var t = n.parentNode;
|
|
1778
1778
|
if (E.docFrag(t)) {
|
|
1779
1779
|
for (; (t = t.host) && E.docFrag(t); ) ;
|
|
@@ -1794,7 +1794,7 @@ function da() {
|
|
|
1794
1794
|
function Z(n, t, o) {
|
|
1795
1795
|
for (; E.element(n); ) {
|
|
1796
1796
|
if (R(n, t)) return !0;
|
|
1797
|
-
if ((n =
|
|
1797
|
+
if ((n = F(n)) === o) return R(n, t);
|
|
1798
1798
|
}
|
|
1799
1799
|
return !1;
|
|
1800
1800
|
}
|
|
@@ -1805,7 +1805,7 @@ function da() {
|
|
|
1805
1805
|
var t = n instanceof D.SVGElement ? n.getBoundingClientRect() : n.getClientRects()[0];
|
|
1806
1806
|
return t && { left: t.left, right: t.right, top: t.top, bottom: t.bottom, width: t.width || t.right - t.left, height: t.height || t.bottom - t.top };
|
|
1807
1807
|
}
|
|
1808
|
-
function
|
|
1808
|
+
function ge(n) {
|
|
1809
1809
|
var t, o = fe(n);
|
|
1810
1810
|
if (!te.isIOS7 && o) {
|
|
1811
1811
|
var s = { x: (t = (t = J(n)) || W).scrollX || t.document.documentElement.scrollLeft, y: t.scrollY || t.document.documentElement.scrollTop };
|
|
@@ -1814,7 +1814,7 @@ function da() {
|
|
|
1814
1814
|
return o;
|
|
1815
1815
|
}
|
|
1816
1816
|
function ue(n) {
|
|
1817
|
-
for (var t = []; n; ) t.push(n), n =
|
|
1817
|
+
for (var t = []; n; ) t.push(n), n = F(n);
|
|
1818
1818
|
return t;
|
|
1819
1819
|
}
|
|
1820
1820
|
function Ne(n) {
|
|
@@ -1824,25 +1824,25 @@ function da() {
|
|
|
1824
1824
|
for (var o in t) n[o] = t[o];
|
|
1825
1825
|
return n;
|
|
1826
1826
|
}
|
|
1827
|
-
function
|
|
1828
|
-
return n === "parent" ?
|
|
1827
|
+
function Be(n, t, o) {
|
|
1828
|
+
return n === "parent" ? F(o) : n === "self" ? t.getRect(o) : ae(o, n);
|
|
1829
1829
|
}
|
|
1830
|
-
function
|
|
1830
|
+
function Ce(n, t, o, s) {
|
|
1831
1831
|
var l = n;
|
|
1832
|
-
return E.string(l) ? l =
|
|
1832
|
+
return E.string(l) ? l = Be(l, t, o) : E.func(l) && (l = l.apply(void 0, s)), E.element(l) && (l = ge(l)), l;
|
|
1833
1833
|
}
|
|
1834
1834
|
function Ie(n) {
|
|
1835
1835
|
return n && { x: "x" in n ? n.x : n.left, y: "y" in n ? n.y : n.top };
|
|
1836
1836
|
}
|
|
1837
|
-
function
|
|
1837
|
+
function He(n) {
|
|
1838
1838
|
return !n || "x" in n && "y" in n || ((n = ee({}, n)).x = n.left || 0, n.y = n.top || 0, n.width = n.width || (n.right || 0) - n.x, n.height = n.height || (n.bottom || 0) - n.y), n;
|
|
1839
1839
|
}
|
|
1840
|
-
function
|
|
1840
|
+
function Le(n, t, o) {
|
|
1841
1841
|
n.left && (t.left += o.x), n.right && (t.right += o.x), n.top && (t.top += o.y), n.bottom && (t.bottom += o.y), t.width = t.right - t.left, t.height = t.bottom - t.top;
|
|
1842
1842
|
}
|
|
1843
1843
|
function Ye(n, t, o) {
|
|
1844
1844
|
var s = o && n.options[o];
|
|
1845
|
-
return Ie(
|
|
1845
|
+
return Ie(Ce(s && s.origin || n.options.origin, n, t, [n && t])) || { x: 0, y: 0 };
|
|
1846
1846
|
}
|
|
1847
1847
|
function Xe(n, t) {
|
|
1848
1848
|
var o = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : function(v) {
|
|
@@ -1868,7 +1868,7 @@ function da() {
|
|
|
1868
1868
|
var ht = function(n, t) {
|
|
1869
1869
|
return Math.sqrt(n * n + t * t);
|
|
1870
1870
|
}, Ii = ["webkit", "moz"];
|
|
1871
|
-
function
|
|
1871
|
+
function Lt(n, t) {
|
|
1872
1872
|
n.__set || (n.__set = {});
|
|
1873
1873
|
var o = function(l) {
|
|
1874
1874
|
if (Ii.some((function(f) {
|
|
@@ -1883,35 +1883,35 @@ function da() {
|
|
|
1883
1883
|
for (var s in t) o(s);
|
|
1884
1884
|
return n;
|
|
1885
1885
|
}
|
|
1886
|
-
function
|
|
1886
|
+
function Ft(n, t) {
|
|
1887
1887
|
n.page = n.page || {}, n.page.x = t.page.x, n.page.y = t.page.y, n.client = n.client || {}, n.client.x = t.client.x, n.client.y = t.client.y, n.timeStamp = t.timeStamp;
|
|
1888
1888
|
}
|
|
1889
1889
|
function kr(n) {
|
|
1890
1890
|
n.page.x = 0, n.page.y = 0, n.client.x = 0, n.client.y = 0;
|
|
1891
1891
|
}
|
|
1892
|
-
function
|
|
1892
|
+
function Cr(n) {
|
|
1893
1893
|
return n instanceof D.Event || n instanceof D.Touch;
|
|
1894
1894
|
}
|
|
1895
1895
|
function Vt(n, t, o) {
|
|
1896
1896
|
return n = n || "page", (o = o || {}).x = t[n + "X"], o.y = t[n + "Y"], o;
|
|
1897
1897
|
}
|
|
1898
|
-
function
|
|
1899
|
-
return t = t || { x: 0, y: 0 }, te.isOperaMobile &&
|
|
1898
|
+
function $r(n, t) {
|
|
1899
|
+
return t = t || { x: 0, y: 0 }, te.isOperaMobile && Cr(n) ? (Vt("screen", n, t), t.x += window.scrollX, t.y += window.scrollY) : Vt("page", n, t), t;
|
|
1900
1900
|
}
|
|
1901
1901
|
function gt(n) {
|
|
1902
1902
|
return E.number(n.pointerId) ? n.pointerId : n.identifier;
|
|
1903
1903
|
}
|
|
1904
1904
|
function ki(n, t, o) {
|
|
1905
|
-
var s = t.length > 1 ?
|
|
1906
|
-
|
|
1907
|
-
f = f || {}, te.isOperaMobile &&
|
|
1905
|
+
var s = t.length > 1 ? jr(t) : t[0];
|
|
1906
|
+
$r(s, n.page), (function(l, f) {
|
|
1907
|
+
f = f || {}, te.isOperaMobile && Cr(l) ? Vt("screen", l, f) : Vt("client", l, f);
|
|
1908
1908
|
})(s, n.client), n.timeStamp = o;
|
|
1909
1909
|
}
|
|
1910
|
-
function
|
|
1910
|
+
function Fn(n) {
|
|
1911
1911
|
var t = [];
|
|
1912
1912
|
return E.array(n) ? (t[0] = n[0], t[1] = n[1]) : n.type === "touchend" ? n.touches.length === 1 ? (t[0] = n.touches[0], t[1] = n.changedTouches[0]) : n.touches.length === 0 && (t[0] = n.changedTouches[0], t[1] = n.changedTouches[1]) : (t[0] = n.touches[0], t[1] = n.touches[1]), t;
|
|
1913
1913
|
}
|
|
1914
|
-
function
|
|
1914
|
+
function jr(n) {
|
|
1915
1915
|
for (var t = { pageX: 0, pageY: 0, clientX: 0, clientY: 0, screenX: 0, screenY: 0 }, o = 0; o < n.length; o++) {
|
|
1916
1916
|
var s = n[o];
|
|
1917
1917
|
for (var l in t) t[l] += s[l];
|
|
@@ -1921,15 +1921,15 @@ function da() {
|
|
|
1921
1921
|
}
|
|
1922
1922
|
function Vn(n) {
|
|
1923
1923
|
if (!n.length) return null;
|
|
1924
|
-
var t =
|
|
1924
|
+
var t = Fn(n), o = Math.min(t[0].pageX, t[1].pageX), s = Math.min(t[0].pageY, t[1].pageY), l = Math.max(t[0].pageX, t[1].pageX), f = Math.max(t[0].pageY, t[1].pageY);
|
|
1925
1925
|
return { x: o, y: s, left: o, top: s, right: l, bottom: f, width: l - o, height: f - s };
|
|
1926
1926
|
}
|
|
1927
1927
|
function Dn(n, t) {
|
|
1928
|
-
var o = t + "X", s = t + "Y", l =
|
|
1928
|
+
var o = t + "X", s = t + "Y", l = Fn(n), f = l[0][o] - l[1][o], p = l[0][s] - l[1][s];
|
|
1929
1929
|
return ht(f, p);
|
|
1930
1930
|
}
|
|
1931
|
-
function
|
|
1932
|
-
var o = t + "X", s = t + "Y", l =
|
|
1931
|
+
function Bn(n, t) {
|
|
1932
|
+
var o = t + "X", s = t + "Y", l = Fn(n), f = l[1][o] - l[0][o], p = l[1][s] - l[0][s];
|
|
1933
1933
|
return 180 * Math.atan2(p, f) / Math.PI;
|
|
1934
1934
|
}
|
|
1935
1935
|
function Ar(n) {
|
|
@@ -1969,7 +1969,7 @@ function da() {
|
|
|
1969
1969
|
return n[mt(n, t)];
|
|
1970
1970
|
}, ut = (function(n) {
|
|
1971
1971
|
b(o, n);
|
|
1972
|
-
var t =
|
|
1972
|
+
var t = $(o);
|
|
1973
1973
|
function o(s, l, f) {
|
|
1974
1974
|
var p;
|
|
1975
1975
|
u(this, o), (p = t.call(this, l._interaction)).dropzone = void 0, p.dragEvent = void 0, p.relatedTarget = void 0, p.draggable = void 0, p.propagationStopped = !1, p.immediatePropagationStopped = !1;
|
|
@@ -1994,21 +1994,21 @@ function da() {
|
|
|
1994
1994
|
this.immediatePropagationStopped = this.propagationStopped = !0;
|
|
1995
1995
|
} }]), o;
|
|
1996
1996
|
})(Dt);
|
|
1997
|
-
function
|
|
1997
|
+
function Lr(n, t) {
|
|
1998
1998
|
for (var o = 0, s = n.slice(); o < s.length; o++) {
|
|
1999
1999
|
var l = s[o], f = l.dropzone, p = l.element;
|
|
2000
2000
|
t.dropzone = f, t.target = p, f.fire(t), t.propagationStopped = t.immediatePropagationStopped = !1;
|
|
2001
2001
|
}
|
|
2002
2002
|
}
|
|
2003
|
-
function
|
|
2003
|
+
function Hn(n, t) {
|
|
2004
2004
|
for (var o = (function(f, p) {
|
|
2005
2005
|
for (var h = [], v = 0, N = f.interactables.list; v < N.length; v++) {
|
|
2006
2006
|
var y = N[v];
|
|
2007
2007
|
if (y.options.drop.enabled) {
|
|
2008
2008
|
var O = y.options.drop.accept;
|
|
2009
|
-
if (!(E.element(O) && O !== p || E.string(O) && !R(p, O) || E.func(O) && !O({ dropzone: y, draggableElement: p }))) for (var
|
|
2010
|
-
var
|
|
2011
|
-
|
|
2009
|
+
if (!(E.element(O) && O !== p || E.string(O) && !R(p, O) || E.func(O) && !O({ dropzone: y, draggableElement: p }))) for (var j = 0, V = y.getAllElements(); j < V.length; j++) {
|
|
2010
|
+
var L = V[j];
|
|
2011
|
+
L !== p && h.push({ dropzone: y, element: L, rect: y.getRect(L) });
|
|
2012
2012
|
}
|
|
2013
2013
|
}
|
|
2014
2014
|
}
|
|
@@ -2019,17 +2019,17 @@ function da() {
|
|
|
2019
2019
|
}
|
|
2020
2020
|
return o;
|
|
2021
2021
|
}
|
|
2022
|
-
function
|
|
2022
|
+
function Fr(n, t, o) {
|
|
2023
2023
|
for (var s = n.dropState, l = n.interactable, f = n.element, p = [], h = 0, v = s.activeDrops; h < v.length; h++) {
|
|
2024
|
-
var N = v[h], y = N.dropzone, O = N.element,
|
|
2024
|
+
var N = v[h], y = N.dropzone, O = N.element, j = N.rect, V = y.dropCheck(t, o, l, f, O, j);
|
|
2025
2025
|
p.push(V ? O : null);
|
|
2026
2026
|
}
|
|
2027
|
-
var
|
|
2028
|
-
for (var ie, re, le, ve = [], xe = 0; xe <
|
|
2029
|
-
var de =
|
|
2027
|
+
var L = (function(H) {
|
|
2028
|
+
for (var ie, re, le, ve = [], xe = 0; xe < H.length; xe++) {
|
|
2029
|
+
var de = H[xe], ye = H[ie];
|
|
2030
2030
|
if (de && xe !== ie) if (ye) {
|
|
2031
|
-
var
|
|
2032
|
-
if (
|
|
2031
|
+
var Me = k(de), Pe = k(ye);
|
|
2032
|
+
if (Me !== de.ownerDocument) if (Pe !== de.ownerDocument) if (Me !== Pe) {
|
|
2033
2033
|
ve = ve.length ? ve : U(ye);
|
|
2034
2034
|
var Ve = void 0;
|
|
2035
2035
|
if (ye instanceof D.HTMLElement && de instanceof D.SVGElement && !(de instanceof D.SVGSVGElement)) {
|
|
@@ -2052,7 +2052,7 @@ function da() {
|
|
|
2052
2052
|
}
|
|
2053
2053
|
return ie;
|
|
2054
2054
|
})(p);
|
|
2055
|
-
return s.activeDrops[
|
|
2055
|
+
return s.activeDrops[L] || null;
|
|
2056
2056
|
}
|
|
2057
2057
|
function Yn(n, t, o) {
|
|
2058
2058
|
var s = n.dropState, l = { enter: null, leave: null, activate: null, deactivate: null, move: null, drop: null };
|
|
@@ -2060,14 +2060,14 @@ function da() {
|
|
|
2060
2060
|
}
|
|
2061
2061
|
function Xn(n, t) {
|
|
2062
2062
|
var o = n.dropState, s = o.activeDrops, l = o.cur, f = o.prev;
|
|
2063
|
-
t.leave && f.dropzone.fire(t.leave), t.enter && l.dropzone.fire(t.enter), t.move && l.dropzone.fire(t.move), t.drop && l.dropzone.fire(t.drop), t.deactivate &&
|
|
2063
|
+
t.leave && f.dropzone.fire(t.leave), t.enter && l.dropzone.fire(t.enter), t.move && l.dropzone.fire(t.move), t.drop && l.dropzone.fire(t.drop), t.deactivate && Lr(s, t.deactivate), o.prev.dropzone = l.dropzone, o.prev.element = l.element;
|
|
2064
2064
|
}
|
|
2065
2065
|
function Vr(n, t) {
|
|
2066
2066
|
var o = n.interaction, s = n.iEvent, l = n.event;
|
|
2067
2067
|
if (s.type === "dragmove" || s.type === "dragend") {
|
|
2068
2068
|
var f = o.dropState;
|
|
2069
|
-
t.dynamicDrop && (f.activeDrops =
|
|
2070
|
-
var p = s, h =
|
|
2069
|
+
t.dynamicDrop && (f.activeDrops = Hn(t, o.element));
|
|
2070
|
+
var p = s, h = Fr(o, p, l);
|
|
2071
2071
|
f.rejected = f.rejected && !!h && h.dropzone === f.cur.dropzone && h.element === f.cur.element, f.cur.dropzone = h && h.dropzone, f.cur.element = h && h.element, f.events = Yn(o, 0, p);
|
|
2072
2072
|
}
|
|
2073
2073
|
}
|
|
@@ -2077,8 +2077,8 @@ function da() {
|
|
|
2077
2077
|
return (function(p, h) {
|
|
2078
2078
|
if (E.object(h)) {
|
|
2079
2079
|
if (p.options.drop.enabled = h.enabled !== !1, h.listeners) {
|
|
2080
|
-
var v = Xe(h.listeners), N = Object.keys(v).reduce((function(O,
|
|
2081
|
-
return O[/^(enter|leave)/.test(
|
|
2080
|
+
var v = Xe(h.listeners), N = Object.keys(v).reduce((function(O, j) {
|
|
2081
|
+
return O[/^(enter|leave)/.test(j) ? "drag".concat(j) : /^(activate|deactivate|move)/.test(j) ? "drop".concat(j) : j] = v[j], O;
|
|
2082
2082
|
}), {}), y = p.options.drop.listeners;
|
|
2083
2083
|
y && p.off(y), p.on(N), p.options.drop.listeners = N;
|
|
2084
2084
|
}
|
|
@@ -2087,22 +2087,22 @@ function da() {
|
|
|
2087
2087
|
return E.bool(h) ? (p.options.drop.enabled = h, p) : p.options.drop;
|
|
2088
2088
|
})(this, f);
|
|
2089
2089
|
}, s.prototype.dropCheck = function(f, p, h, v, N, y) {
|
|
2090
|
-
return (function(O,
|
|
2090
|
+
return (function(O, j, V, L, H, ie, re) {
|
|
2091
2091
|
var le = !1;
|
|
2092
|
-
if (!(re = re || O.getRect(ie))) return !!O.options.drop.checker && O.options.drop.checker(
|
|
2092
|
+
if (!(re = re || O.getRect(ie))) return !!O.options.drop.checker && O.options.drop.checker(j, V, le, O, ie, L, H);
|
|
2093
2093
|
var ve = O.options.drop.overlap;
|
|
2094
2094
|
if (ve === "pointer") {
|
|
2095
|
-
var xe = Ye(
|
|
2095
|
+
var xe = Ye(L, H, "drag"), de = $r(j);
|
|
2096
2096
|
de.x += xe.x, de.y += xe.y;
|
|
2097
|
-
var ye = de.x > re.left && de.x < re.right,
|
|
2098
|
-
le = ye &&
|
|
2097
|
+
var ye = de.x > re.left && de.x < re.right, Me = de.y > re.top && de.y < re.bottom;
|
|
2098
|
+
le = ye && Me;
|
|
2099
2099
|
}
|
|
2100
|
-
var Pe =
|
|
2100
|
+
var Pe = L.getRect(H);
|
|
2101
2101
|
if (Pe && ve === "center") {
|
|
2102
2102
|
var Ve = Pe.left + Pe.width / 2, De = Pe.top + Pe.height / 2;
|
|
2103
2103
|
le = Ve >= re.left && Ve <= re.right && De >= re.top && De <= re.bottom;
|
|
2104
2104
|
}
|
|
2105
|
-
return Pe && E.number(ve) && (le = Math.max(0, Math.min(re.right, Pe.right) - Math.max(re.left, Pe.left)) * Math.max(0, Math.min(re.bottom, Pe.bottom) - Math.max(re.top, Pe.top)) / (Pe.width * Pe.height) >= ve), O.options.drop.checker && (le = O.options.drop.checker(
|
|
2105
|
+
return Pe && E.number(ve) && (le = Math.max(0, Math.min(re.right, Pe.right) - Math.max(re.left, Pe.left)) * Math.max(0, Math.min(re.bottom, Pe.bottom) - Math.max(re.top, Pe.top)) / (Pe.width * Pe.height) >= ve), O.options.drop.checker && (le = O.options.drop.checker(j, V, le, O, ie, L, H)), le;
|
|
2106
2106
|
})(this, f, p, h, v, N, y);
|
|
2107
2107
|
}, o.dynamicDrop = function(f) {
|
|
2108
2108
|
return E.bool(f) ? (n.dynamicDrop = f, o) : n.dynamicDrop;
|
|
@@ -2114,7 +2114,7 @@ function da() {
|
|
|
2114
2114
|
var o = n.interaction, s = n.iEvent;
|
|
2115
2115
|
if (o.prepared.name === "drag") {
|
|
2116
2116
|
var l = o.dropState;
|
|
2117
|
-
l.activeDrops = [], l.events = {}, l.activeDrops =
|
|
2117
|
+
l.activeDrops = [], l.events = {}, l.activeDrops = Hn(t, o.element), l.events = Yn(o, 0, s), l.events.activate && (Lr(l.activeDrops, l.events.activate), t.fire("actions/drop:start", { interaction: o, dragEvent: s }));
|
|
2118
2118
|
}
|
|
2119
2119
|
}, "interactions:action-move": Vr, "interactions:after-action-move": function(n, t) {
|
|
2120
2120
|
var o = n.interaction, s = n.iEvent;
|
|
@@ -2133,20 +2133,20 @@ function da() {
|
|
|
2133
2133
|
var o = t.dropState;
|
|
2134
2134
|
o && (o.activeDrops = null, o.events = null, o.cur.dropzone = null, o.cur.element = null, o.prev.dropzone = null, o.prev.element = null, o.rejected = !1);
|
|
2135
2135
|
}
|
|
2136
|
-
} }, getActiveDrops:
|
|
2136
|
+
} }, getActiveDrops: Hn, getDrop: Fr, getDropEvents: Yn, fireDropEvents: Xn, filterEventType: function(n) {
|
|
2137
2137
|
return n.search("drag") === 0 || n.search("drop") === 0;
|
|
2138
|
-
}, defaults: { enabled: !1, accept: null, overlap: "pointer" } },
|
|
2138
|
+
}, defaults: { enabled: !1, accept: null, overlap: "pointer" } }, Ci = Dr;
|
|
2139
2139
|
function Un(n) {
|
|
2140
2140
|
var t = n.interaction, o = n.iEvent, s = n.phase;
|
|
2141
2141
|
if (t.prepared.name === "gesture") {
|
|
2142
2142
|
var l = t.pointers.map((function(N) {
|
|
2143
2143
|
return N.pointer;
|
|
2144
2144
|
})), f = s === "start", p = s === "end", h = t.interactable.options.deltaSource;
|
|
2145
|
-
if (o.touches = [l[0], l[1]], f) o.distance = Dn(l, h), o.box = Vn(l), o.scale = 1, o.ds = 0, o.angle =
|
|
2145
|
+
if (o.touches = [l[0], l[1]], f) o.distance = Dn(l, h), o.box = Vn(l), o.scale = 1, o.ds = 0, o.angle = Bn(l, h), o.da = 0, t.gesture.startDistance = o.distance, t.gesture.startAngle = o.angle;
|
|
2146
2146
|
else if (p || t.pointers.length < 2) {
|
|
2147
2147
|
var v = t.prevEvent;
|
|
2148
2148
|
o.distance = v.distance, o.box = v.box, o.scale = v.scale, o.ds = 0, o.angle = v.angle, o.da = 0;
|
|
2149
|
-
} else o.distance = Dn(l, h), o.box = Vn(l), o.scale = o.distance / t.gesture.startDistance, o.angle =
|
|
2149
|
+
} else o.distance = Dn(l, h), o.box = Vn(l), o.scale = o.distance / t.gesture.startDistance, o.angle = Bn(l, h), o.ds = o.scale - t.gesture.scale, o.da = o.angle - t.gesture.angle;
|
|
2150
2150
|
t.gesture.distance = o.distance, t.gesture.angle = o.angle, E.number(o.scale) && o.scale !== 1 / 0 && !isNaN(o.scale) && (t.gesture.scale = o.scale);
|
|
2151
2151
|
}
|
|
2152
2152
|
}
|
|
@@ -2166,8 +2166,8 @@ function da() {
|
|
|
2166
2166
|
return "";
|
|
2167
2167
|
}, filterEventType: function(n) {
|
|
2168
2168
|
return n.search("gesture") === 0;
|
|
2169
|
-
} },
|
|
2170
|
-
function
|
|
2169
|
+
} }, $i = Kn;
|
|
2170
|
+
function ji(n, t, o, s, l, f, p) {
|
|
2171
2171
|
if (!t) return !1;
|
|
2172
2172
|
if (t === !0) {
|
|
2173
2173
|
var h = E.number(f.width) ? f.width : f.right - f.left, v = E.number(f.height) ? f.height : f.bottom - f.top;
|
|
@@ -2184,7 +2184,7 @@ function da() {
|
|
|
2184
2184
|
}
|
|
2185
2185
|
return !!E.element(s) && (E.element(t) ? t === s : Z(s, t, l));
|
|
2186
2186
|
}
|
|
2187
|
-
function
|
|
2187
|
+
function Br(n) {
|
|
2188
2188
|
var t = n.iEvent, o = n.interaction;
|
|
2189
2189
|
if (o.prepared.name === "resize" && o.resizeAxes) {
|
|
2190
2190
|
var s = t;
|
|
@@ -2209,28 +2209,28 @@ function da() {
|
|
|
2209
2209
|
var l = o, f = s.rect;
|
|
2210
2210
|
s._rects = { start: ee({}, f), corrected: ee({}, f), previous: ee({}, f), delta: { left: 0, right: 0, width: 0, top: 0, bottom: 0, height: 0 } }, l.edges = s.prepared.edges, l.rect = s._rects.corrected, l.deltaRect = s._rects.delta;
|
|
2211
2211
|
}
|
|
2212
|
-
})(n),
|
|
2212
|
+
})(n), Br(n);
|
|
2213
2213
|
}, "interactions:action-move": function(n) {
|
|
2214
2214
|
(function(t) {
|
|
2215
2215
|
var o = t.iEvent, s = t.interaction;
|
|
2216
2216
|
if (s.prepared.name === "resize" && s.prepared.edges) {
|
|
2217
|
-
var l = o, f = s.interactable.options.resize.invert, p = f === "reposition" || f === "negate", h = s.rect, v = s._rects, N = v.start, y = v.corrected, O = v.delta,
|
|
2218
|
-
if (ee(
|
|
2217
|
+
var l = o, f = s.interactable.options.resize.invert, p = f === "reposition" || f === "negate", h = s.rect, v = s._rects, N = v.start, y = v.corrected, O = v.delta, j = v.previous;
|
|
2218
|
+
if (ee(j, y), p) {
|
|
2219
2219
|
if (ee(y, h), f === "reposition") {
|
|
2220
2220
|
if (y.top > y.bottom) {
|
|
2221
2221
|
var V = y.top;
|
|
2222
2222
|
y.top = y.bottom, y.bottom = V;
|
|
2223
2223
|
}
|
|
2224
2224
|
if (y.left > y.right) {
|
|
2225
|
-
var
|
|
2226
|
-
y.left = y.right, y.right =
|
|
2225
|
+
var L = y.left;
|
|
2226
|
+
y.left = y.right, y.right = L;
|
|
2227
2227
|
}
|
|
2228
2228
|
}
|
|
2229
2229
|
} else y.top = Math.min(h.top, N.bottom), y.bottom = Math.max(h.bottom, N.top), y.left = Math.min(h.left, N.right), y.right = Math.max(h.right, N.left);
|
|
2230
|
-
for (var
|
|
2230
|
+
for (var H in y.width = y.right - y.left, y.height = y.bottom - y.top, y) O[H] = y[H] - j[H];
|
|
2231
2231
|
l.edges = s.prepared.edges, l.rect = y, l.deltaRect = O;
|
|
2232
2232
|
}
|
|
2233
|
-
})(n),
|
|
2233
|
+
})(n), Br(n);
|
|
2234
2234
|
}, "interactions:action-end": function(n) {
|
|
2235
2235
|
var t = n.iEvent, o = n.interaction;
|
|
2236
2236
|
if (o.prepared.name === "resize" && o.prepared.edges) {
|
|
@@ -2244,7 +2244,7 @@ function da() {
|
|
|
2244
2244
|
if (h && h.enabled && (!t.pointerIsDown || !/mouse|pointer/.test(t.pointerType) || (f & h.mouseButtons) != 0)) {
|
|
2245
2245
|
if (E.object(h.edges)) {
|
|
2246
2246
|
var v = { left: !1, right: !1, top: !1, bottom: !1 };
|
|
2247
|
-
for (var N in v) v[N] =
|
|
2247
|
+
for (var N in v) v[N] = ji(N, h.edges[N], p, t._latestPointer.eventTarget, s, l, h.margin || Ke.defaultMargin);
|
|
2248
2248
|
v.left = v.left && !v.right, v.top = v.top && !v.bottom, (v.left || v.right || v.top || v.bottom) && (n.action = { name: "resize", edges: v });
|
|
2249
2249
|
} else {
|
|
2250
2250
|
var y = h.axis !== "y" && p.x > l.right - Ke.defaultMargin, O = h.axis !== "x" && p.y > l.bottom - Ke.defaultMargin;
|
|
@@ -2267,8 +2267,8 @@ function da() {
|
|
|
2267
2267
|
}, filterEventType: function(n) {
|
|
2268
2268
|
return n.search("resize") === 0;
|
|
2269
2269
|
}, defaultMargin: null }, Ai = Ke, Mi = { id: "actions", install: function(n) {
|
|
2270
|
-
n.usePlugin(
|
|
2271
|
-
} },
|
|
2270
|
+
n.usePlugin($i), n.usePlugin(Ai), n.usePlugin(oe), n.usePlugin(Ci);
|
|
2271
|
+
} }, Hr = 0, Je = { request: function(n) {
|
|
2272
2272
|
return Ue(n);
|
|
2273
2273
|
}, cancel: function(n) {
|
|
2274
2274
|
return ot(n);
|
|
@@ -2278,10 +2278,10 @@ function da() {
|
|
|
2278
2278
|
Ue = n["".concat(s, "RequestAnimationFrame")], ot = n["".concat(s, "CancelAnimationFrame")] || n["".concat(s, "CancelRequestAnimationFrame")];
|
|
2279
2279
|
}
|
|
2280
2280
|
Ue = Ue && Ue.bind(n), ot = ot && ot.bind(n), Ue || (Ue = function(l) {
|
|
2281
|
-
var f = Date.now(), p = Math.max(0, 16 - (f -
|
|
2281
|
+
var f = Date.now(), p = Math.max(0, 16 - (f - Hr)), h = n.setTimeout((function() {
|
|
2282
2282
|
l(f + p);
|
|
2283
2283
|
}), p);
|
|
2284
|
-
return
|
|
2284
|
+
return Hr = f + p, h;
|
|
2285
2285
|
}, ot = function(l) {
|
|
2286
2286
|
return clearTimeout(l);
|
|
2287
2287
|
});
|
|
@@ -2296,8 +2296,8 @@ function da() {
|
|
|
2296
2296
|
if (N.x || N.y) {
|
|
2297
2297
|
var y = Xr(f);
|
|
2298
2298
|
E.window(f) ? f.scrollBy(N.x, N.y) : f && (f.scrollLeft += N.x, f.scrollTop += N.y);
|
|
2299
|
-
var O = Xr(f),
|
|
2300
|
-
(
|
|
2299
|
+
var O = Xr(f), j = { x: O.x - y.x, y: O.y - y.y };
|
|
2300
|
+
(j.x || j.y) && t.fire({ type: "autoscroll", target: o, interactable: t, delta: j, interaction: n, container: f });
|
|
2301
2301
|
}
|
|
2302
2302
|
pe.prevTime = p;
|
|
2303
2303
|
}
|
|
@@ -2312,14 +2312,14 @@ function da() {
|
|
|
2312
2312
|
var s, l, f, p, h = t.interactable, v = t.element, N = t.prepared.name, y = h.options[N].autoScroll, O = Yr(y.container, h, v);
|
|
2313
2313
|
if (E.window(O)) p = o.clientX < pe.margin, s = o.clientY < pe.margin, l = o.clientX > O.innerWidth - pe.margin, f = o.clientY > O.innerHeight - pe.margin;
|
|
2314
2314
|
else {
|
|
2315
|
-
var
|
|
2316
|
-
p = o.clientX <
|
|
2315
|
+
var j = fe(O);
|
|
2316
|
+
p = o.clientX < j.left + pe.margin, s = o.clientY < j.top + pe.margin, l = o.clientX > j.right - pe.margin, f = o.clientY > j.bottom - pe.margin;
|
|
2317
2317
|
}
|
|
2318
2318
|
pe.x = l ? 1 : p ? -1 : 0, pe.y = f ? 1 : s ? -1 : 0, pe.isScrolling || (pe.margin = y.margin, pe.speed = y.speed, pe.start(t));
|
|
2319
2319
|
}
|
|
2320
2320
|
} };
|
|
2321
2321
|
function Yr(n, t, o) {
|
|
2322
|
-
return (E.string(n) ?
|
|
2322
|
+
return (E.string(n) ? Be(n, t, o) : n) || J(o);
|
|
2323
2323
|
}
|
|
2324
2324
|
function Xr(n) {
|
|
2325
2325
|
return E.window(n) && (n = window.document.body), { x: n.scrollLeft, y: n.scrollTop };
|
|
@@ -2345,35 +2345,35 @@ function da() {
|
|
|
2345
2345
|
function Gn(n, t) {
|
|
2346
2346
|
return n.name = t.name, n.axis = t.axis, n.edges = t.edges, n;
|
|
2347
2347
|
}
|
|
2348
|
-
function
|
|
2348
|
+
function Li(n) {
|
|
2349
2349
|
return E.bool(n) ? (this.options.styleCursor = n, this) : n === null ? (delete this.options.styleCursor, this) : this.options.styleCursor;
|
|
2350
2350
|
}
|
|
2351
|
-
function
|
|
2351
|
+
function Fi(n) {
|
|
2352
2352
|
return E.func(n) ? (this.options.actionChecker = n, this) : n === null ? (delete this.options.actionChecker, this) : this.options.actionChecker;
|
|
2353
2353
|
}
|
|
2354
2354
|
var Vi = { id: "auto-start/interactableMethods", install: function(n) {
|
|
2355
2355
|
var t = n.Interactable;
|
|
2356
2356
|
t.prototype.getAction = function(o, s, l, f) {
|
|
2357
2357
|
var p = (function(h, v, N, y, O) {
|
|
2358
|
-
var
|
|
2359
|
-
return O.fire("auto-start:check",
|
|
2358
|
+
var j = h.getRect(y), V = v.buttons || { 0: 1, 1: 4, 3: 8, 4: 16 }[v.button], L = { action: null, interactable: h, interaction: N, element: y, rect: j, buttons: V };
|
|
2359
|
+
return O.fire("auto-start:check", L), L.action;
|
|
2360
2360
|
})(this, s, l, f, n);
|
|
2361
2361
|
return this.options.actionChecker ? this.options.actionChecker(o, s, p, this, f, l) : p;
|
|
2362
2362
|
}, t.prototype.ignoreFrom = yt((function(o) {
|
|
2363
2363
|
return this._backCompatOption("ignoreFrom", o);
|
|
2364
2364
|
}), "Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."), t.prototype.allowFrom = yt((function(o) {
|
|
2365
2365
|
return this._backCompatOption("allowFrom", o);
|
|
2366
|
-
}), "Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."), t.prototype.actionChecker =
|
|
2366
|
+
}), "Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."), t.prototype.actionChecker = Fi, t.prototype.styleCursor = Li;
|
|
2367
2367
|
} };
|
|
2368
2368
|
function Ur(n, t, o, s, l) {
|
|
2369
|
-
return t.testIgnoreAllow(t.options[n.name], o, s) && t.options[n.name].enabled &&
|
|
2369
|
+
return t.testIgnoreAllow(t.options[n.name], o, s) && t.options[n.name].enabled && Bt(t, o, n, l) ? n : null;
|
|
2370
2370
|
}
|
|
2371
2371
|
function Di(n, t, o, s, l, f, p) {
|
|
2372
2372
|
for (var h = 0, v = s.length; h < v; h++) {
|
|
2373
2373
|
var N = s[h], y = l[h], O = N.getAction(t, o, n, y);
|
|
2374
2374
|
if (O) {
|
|
2375
|
-
var
|
|
2376
|
-
if (
|
|
2375
|
+
var j = Ur(O, N, y, f, p);
|
|
2376
|
+
if (j) return { action: j, interactable: N, element: y };
|
|
2377
2377
|
}
|
|
2378
2378
|
}
|
|
2379
2379
|
return { action: null, interactable: null, element: null };
|
|
@@ -2387,7 +2387,7 @@ function da() {
|
|
|
2387
2387
|
f = [], p = [], l.interactables.forEachMatch(h, v);
|
|
2388
2388
|
var N = Di(n, t, o, f, p, s, l);
|
|
2389
2389
|
if (N.action && !N.interactable.options[N.action.name].manualStart) return N;
|
|
2390
|
-
h =
|
|
2390
|
+
h = F(h);
|
|
2391
2391
|
}
|
|
2392
2392
|
return { action: null, interactable: null, element: null };
|
|
2393
2393
|
}
|
|
@@ -2395,12 +2395,12 @@ function da() {
|
|
|
2395
2395
|
var s = t.action, l = t.interactable, f = t.element;
|
|
2396
2396
|
s = s || { name: null }, n.interactable = l, n.element = f, Gn(n.prepared, s), n.rect = l && s.name ? l.getRect(f) : null, Wr(n, o), o.fire("autoStart:prepared", { interaction: n });
|
|
2397
2397
|
}
|
|
2398
|
-
function
|
|
2398
|
+
function Bt(n, t, o, s) {
|
|
2399
2399
|
var l = n.options, f = l[o.name].max, p = l[o.name].maxPerElement, h = s.autoStart.maxInteractions, v = 0, N = 0, y = 0;
|
|
2400
2400
|
if (!(f && p && h)) return !1;
|
|
2401
|
-
for (var O = 0,
|
|
2402
|
-
var V =
|
|
2403
|
-
if (V.interacting() && (++v >= h || V.interactable === n && ((N +=
|
|
2401
|
+
for (var O = 0, j = s.interactions.list; O < j.length; O++) {
|
|
2402
|
+
var V = j[O], L = V.prepared.name;
|
|
2403
|
+
if (V.interacting() && (++v >= h || V.interactable === n && ((N += L === o.name ? 1 : 0) >= f || V.element === t && (y++, L === o.name && y >= p))))
|
|
2404
2404
|
return !1;
|
|
2405
2405
|
}
|
|
2406
2406
|
return h > 0;
|
|
@@ -2423,11 +2423,11 @@ function da() {
|
|
|
2423
2423
|
qn(n.element, f || "", t);
|
|
2424
2424
|
} else t.autoStart.cursorElement && qn(t.autoStart.cursorElement, "", t);
|
|
2425
2425
|
}
|
|
2426
|
-
var
|
|
2426
|
+
var Bi = { id: "auto-start/base", before: ["actions"], install: function(n) {
|
|
2427
2427
|
var t = n.interactStatic, o = n.defaults;
|
|
2428
2428
|
n.usePlugin(Vi), o.base.actionChecker = null, o.base.styleCursor = !0, ee(o.perAction, { manualStart: !1, max: 1 / 0, maxPerElement: 1, allowFrom: null, ignoreFrom: null, mouseButtons: 1 }), t.maxInteractions = function(s) {
|
|
2429
2429
|
return qr(s, n);
|
|
2430
|
-
}, n.autoStart = { maxInteractions: 1 / 0, withinInteractionLimit:
|
|
2430
|
+
}, n.autoStart = { maxInteractions: 1 / 0, withinInteractionLimit: Bt, cursorElement: null };
|
|
2431
2431
|
}, listeners: { "interactions:down": function(n, t) {
|
|
2432
2432
|
var o = n.interaction, s = n.pointer, l = n.event, f = n.eventTarget;
|
|
2433
2433
|
o.interacting() || Gr(o, Kr(o, s, l, f, t), t);
|
|
@@ -2440,37 +2440,37 @@ function da() {
|
|
|
2440
2440
|
if (l.pointerIsDown && !l.interacting() && l.pointerWasMoved && l.prepared.name) {
|
|
2441
2441
|
s.fire("autoStart:before-start", o);
|
|
2442
2442
|
var f = l.interactable, p = l.prepared.name;
|
|
2443
|
-
p && f && (f.options[p].manualStart || !
|
|
2443
|
+
p && f && (f.options[p].manualStart || !Bt(f, l.element, l.prepared, s) ? l.stop() : (l.start(l.prepared, f, l.element), Wr(l, s)));
|
|
2444
2444
|
}
|
|
2445
2445
|
})(n, t);
|
|
2446
2446
|
}, "interactions:stop": function(n, t) {
|
|
2447
2447
|
var o = n.interaction, s = o.interactable;
|
|
2448
2448
|
s && s.options.styleCursor && qn(o.element, "", t);
|
|
2449
|
-
} }, maxInteractions: qr, withinInteractionLimit:
|
|
2449
|
+
} }, maxInteractions: qr, withinInteractionLimit: Bt, validateAction: Ur }, Wn = Bi, Hi = { id: "auto-start/dragAxis", listeners: { "autoStart:before-start": function(n, t) {
|
|
2450
2450
|
var o = n.interaction, s = n.eventTarget, l = n.dx, f = n.dy;
|
|
2451
2451
|
if (o.prepared.name === "drag") {
|
|
2452
2452
|
var p = Math.abs(l), h = Math.abs(f), v = o.interactable.options.drag, N = v.startAxis, y = p > h ? "x" : p < h ? "y" : "xy";
|
|
2453
2453
|
if (o.prepared.axis = v.lockAxis === "start" ? y[0] : v.lockAxis, y !== "xy" && N !== "xy" && N !== y) {
|
|
2454
2454
|
o.prepared.name = null;
|
|
2455
|
-
for (var O = s,
|
|
2456
|
-
if (
|
|
2457
|
-
var
|
|
2458
|
-
if (!
|
|
2459
|
-
var ie =
|
|
2455
|
+
for (var O = s, j = function(L) {
|
|
2456
|
+
if (L !== o.interactable) {
|
|
2457
|
+
var H = o.interactable.options.drag;
|
|
2458
|
+
if (!H.manualStart && L.testIgnoreAllow(H, O, s)) {
|
|
2459
|
+
var ie = L.getAction(o.downPointer, o.downEvent, o, O);
|
|
2460
2460
|
if (ie && ie.name === "drag" && (function(re, le) {
|
|
2461
2461
|
if (!le) return !1;
|
|
2462
2462
|
var ve = le.options.drag.startAxis;
|
|
2463
2463
|
return re === "xy" || ve === "xy" || ve === re;
|
|
2464
|
-
})(y,
|
|
2464
|
+
})(y, L) && Wn.validateAction(ie, L, O, s, t)) return L;
|
|
2465
2465
|
}
|
|
2466
2466
|
}
|
|
2467
2467
|
}; E.element(O); ) {
|
|
2468
|
-
var V = t.interactables.forEachMatch(O,
|
|
2468
|
+
var V = t.interactables.forEachMatch(O, j);
|
|
2469
2469
|
if (V) {
|
|
2470
2470
|
o.prepared.name = "drag", o.interactable = V, o.element = O;
|
|
2471
2471
|
break;
|
|
2472
2472
|
}
|
|
2473
|
-
O =
|
|
2473
|
+
O = F(O);
|
|
2474
2474
|
}
|
|
2475
2475
|
}
|
|
2476
2476
|
}
|
|
@@ -2498,7 +2498,7 @@ function da() {
|
|
|
2498
2498
|
var t = n.interaction;
|
|
2499
2499
|
Jn(t) > 0 && (t.prepared.name = null);
|
|
2500
2500
|
} }, getHoldDuration: Jn }, Xi = Yi, Ui = { id: "auto-start", install: function(n) {
|
|
2501
|
-
n.usePlugin(Wn), n.usePlugin(Xi), n.usePlugin(
|
|
2501
|
+
n.usePlugin(Wn), n.usePlugin(Xi), n.usePlugin(Hi);
|
|
2502
2502
|
} }, Ki = function(n) {
|
|
2503
2503
|
return /^(always|never|auto)$/.test(n) ? (this.options.preventDefault = n, this) : E.bool(n) ? (this.options.preventDefault = n ? "always" : "never", this) : this.options.preventDefault;
|
|
2504
2504
|
};
|
|
@@ -2528,7 +2528,7 @@ function da() {
|
|
|
2528
2528
|
}, listeners: ["down", "move", "up", "cancel"].reduce((function(n, t) {
|
|
2529
2529
|
return n["interactions:".concat(t)] = Gi, n;
|
|
2530
2530
|
}), {}) };
|
|
2531
|
-
function
|
|
2531
|
+
function Ht(n, t) {
|
|
2532
2532
|
if (t.phaselessTypes[n]) return !0;
|
|
2533
2533
|
for (var o in t.map) if (n.indexOf(o) === 0 && n.substr(o.length) in t.phases) return !0;
|
|
2534
2534
|
return !1;
|
|
@@ -2548,11 +2548,11 @@ function da() {
|
|
|
2548
2548
|
return g(n, [{ key: "start", value: function(t, o) {
|
|
2549
2549
|
var s, l, f = t.phase, p = this.interaction, h = (function(N) {
|
|
2550
2550
|
var y = N.interactable.options[N.prepared.name], O = y.modifiers;
|
|
2551
|
-
return O && O.length ? O : ["snap", "snapSize", "snapEdges", "restrict", "restrictEdges", "restrictSize"].map((function(
|
|
2552
|
-
var V = y[
|
|
2551
|
+
return O && O.length ? O : ["snap", "snapSize", "snapEdges", "restrict", "restrictEdges", "restrictSize"].map((function(j) {
|
|
2552
|
+
var V = y[j];
|
|
2553
2553
|
return V && V.enabled && { options: V, methods: V._methods };
|
|
2554
|
-
})).filter((function(
|
|
2555
|
-
return !!
|
|
2554
|
+
})).filter((function(j) {
|
|
2555
|
+
return !!j;
|
|
2556
2556
|
}));
|
|
2557
2557
|
})(p);
|
|
2558
2558
|
this.prepareStates(h), this.startEdges = ee({}, p.edges), this.edges = ee({}, this.startEdges), this.startOffset = (s = p.rect, l = o, s ? { left: l.x - s.left, top: l.y - s.top, right: s.right - l.x, bottom: s.bottom - l.y } : { left: 0, top: 0, right: 0, bottom: 0 }), this.startDelta = { x: 0, y: 0 };
|
|
@@ -2570,25 +2570,25 @@ function da() {
|
|
|
2570
2570
|
var o = t.phase, s = t.preEnd, l = t.skipModifiers, f = t.rect, p = t.edges;
|
|
2571
2571
|
t.coords = ee({}, t.pageCoords), t.rect = ee({}, f), t.edges = ee({}, p);
|
|
2572
2572
|
for (var h = l ? this.states.slice(l) : this.states, v = Yt(t.coords, t.rect), N = 0; N < h.length; N++) {
|
|
2573
|
-
var y, O = h[N],
|
|
2574
|
-
(y = O.methods) != null && y.set && this.shouldDo(
|
|
2573
|
+
var y, O = h[N], j = O.options, V = ee({}, t.coords), L = null;
|
|
2574
|
+
(y = O.methods) != null && y.set && this.shouldDo(j, s, o) && (t.state = O, L = O.methods.set(t), Le(t.edges, t.rect, { x: t.coords.x - V.x, y: t.coords.y - V.y })), v.eventProps.push(L);
|
|
2575
2575
|
}
|
|
2576
2576
|
ee(this.edges, t.edges), v.delta.x = t.coords.x - t.pageCoords.x, v.delta.y = t.coords.y - t.pageCoords.y, v.rectDelta.left = t.rect.left - f.left, v.rectDelta.right = t.rect.right - f.right, v.rectDelta.top = t.rect.top - f.top, v.rectDelta.bottom = t.rect.bottom - f.bottom;
|
|
2577
|
-
var
|
|
2578
|
-
if (
|
|
2577
|
+
var H = this.result.coords, ie = this.result.rect;
|
|
2578
|
+
if (H && ie) {
|
|
2579
2579
|
var re = v.rect.left !== ie.left || v.rect.right !== ie.right || v.rect.top !== ie.top || v.rect.bottom !== ie.bottom;
|
|
2580
|
-
v.changed = re ||
|
|
2580
|
+
v.changed = re || H.x !== v.coords.x || H.y !== v.coords.y;
|
|
2581
2581
|
}
|
|
2582
2582
|
return v;
|
|
2583
2583
|
} }, { key: "applyToInteraction", value: function(t) {
|
|
2584
2584
|
var o = this.interaction, s = t.phase, l = o.coords.cur, f = o.coords.start, p = this.result, h = this.startDelta, v = p.delta;
|
|
2585
2585
|
s === "start" && ee(this.startDelta, p.delta);
|
|
2586
2586
|
for (var N = 0, y = [[f, h], [l, v]]; N < y.length; N++) {
|
|
2587
|
-
var O = y[N],
|
|
2588
|
-
|
|
2587
|
+
var O = y[N], j = O[0], V = O[1];
|
|
2588
|
+
j.page.x += V.x, j.page.y += V.y, j.client.x += V.x, j.client.y += V.y;
|
|
2589
2589
|
}
|
|
2590
|
-
var
|
|
2591
|
-
|
|
2590
|
+
var L = this.result.rectDelta, H = t.rect || o.rect;
|
|
2591
|
+
H.left += L.left, H.right += L.right, H.top += L.top, H.bottom += L.bottom, H.width = H.right - H.left, H.height = H.bottom - H.top;
|
|
2592
2592
|
} }, { key: "setAndApply", value: function(t) {
|
|
2593
2593
|
var o = this.interaction, s = t.phase, l = t.preEnd, f = t.skipModifiers, p = this.setAll(this.fillArg({ preEnd: l, phase: s, pageCoords: t.modifiedCoords || o.coords.cur.page }));
|
|
2594
2594
|
if (this.result = p, !p.changed && (!f || f < this.states.length) && o.interacting()) return !1;
|
|
@@ -2631,8 +2631,8 @@ function da() {
|
|
|
2631
2631
|
var o = t.interaction, s = o.coords, l = o.rect, f = o.modification;
|
|
2632
2632
|
if (f.result) {
|
|
2633
2633
|
for (var p = f.startDelta, h = f.result, v = h.delta, N = h.rectDelta, y = 0, O = [[s.start, p], [s.cur, v]]; y < O.length; y++) {
|
|
2634
|
-
var
|
|
2635
|
-
V.page.x -=
|
|
2634
|
+
var j = O[y], V = j[0], L = j[1];
|
|
2635
|
+
V.page.x -= L.x, V.page.y -= L.y, V.client.x -= L.x, V.client.y -= L.y;
|
|
2636
2636
|
}
|
|
2637
2637
|
l.left -= N.left, l.right -= N.right, l.top -= N.top, l.bottom -= N.bottom;
|
|
2638
2638
|
}
|
|
@@ -2688,12 +2688,12 @@ function da() {
|
|
|
2688
2688
|
return n.interaction.modification.stop(n);
|
|
2689
2689
|
} } }, Zr = qi, Qr = { base: { preventDefault: "auto", deltaSource: "page" }, perAction: { enabled: !1, origin: { x: 0, y: 0 } }, actions: {} }, Qn = (function(n) {
|
|
2690
2690
|
b(o, n);
|
|
2691
|
-
var t =
|
|
2691
|
+
var t = $(o);
|
|
2692
2692
|
function o(s, l, f, p, h, v, N) {
|
|
2693
2693
|
var y;
|
|
2694
2694
|
u(this, o), (y = t.call(this, s)).relatedTarget = null, y.screenX = void 0, y.screenY = void 0, y.button = void 0, y.buttons = void 0, y.ctrlKey = void 0, y.shiftKey = void 0, y.altKey = void 0, y.metaKey = void 0, y.page = void 0, y.client = void 0, y.delta = void 0, y.rect = void 0, y.x0 = void 0, y.y0 = void 0, y.t0 = void 0, y.dt = void 0, y.duration = void 0, y.clientX0 = void 0, y.clientY0 = void 0, y.velocity = void 0, y.speed = void 0, y.swipe = void 0, y.axes = void 0, y.preEnd = void 0, h = h || s.element;
|
|
2695
|
-
var O = s.interactable,
|
|
2696
|
-
return y.page = ee({}, re.page), y.client = ee({}, re.client), y.rect = ee({}, s.rect), y.timeStamp = re.timeStamp,
|
|
2695
|
+
var O = s.interactable, j = (O && O.options || Qr).deltaSource, V = Ye(O, h, f), L = p === "start", H = p === "end", ie = L ? I(y) : s.prevEvent, re = L ? s.coords.start : H ? { page: ie.page, client: ie.client, timeStamp: s.coords.cur.timeStamp } : s.coords.cur;
|
|
2696
|
+
return y.page = ee({}, re.page), y.client = ee({}, re.client), y.rect = ee({}, s.rect), y.timeStamp = re.timeStamp, H || (y.page.x -= V.x, y.page.y -= V.y, y.client.x -= V.x, y.client.y -= V.y), y.ctrlKey = l.ctrlKey, y.altKey = l.altKey, y.shiftKey = l.shiftKey, y.metaKey = l.metaKey, y.button = l.button, y.buttons = l.buttons, y.target = h, y.currentTarget = h, y.preEnd = v, y.type = N || f + (p || ""), y.interactable = O, y.t0 = L ? s.pointers[s.pointers.length - 1].downTime : ie.t0, y.x0 = s.coords.start.page.x - V.x, y.y0 = s.coords.start.page.y - V.y, y.clientX0 = s.coords.start.client.x - V.x, y.clientY0 = s.coords.start.client.y - V.y, y.delta = L || H ? { x: 0, y: 0 } : { x: y[j].x - ie[j].x, y: y[j].y - ie[j].y }, y.dt = s.coords.delta.timeStamp, y.duration = y.timeStamp - y.t0, y.velocity = ee({}, s.coords.velocity[j]), y.speed = ht(y.velocity.x, y.velocity.y), y.swipe = H || p === "inertiastart" ? y.getSwipe() : null, y;
|
|
2697
2697
|
}
|
|
2698
2698
|
return g(o, [{ key: "getSwipe", value: function() {
|
|
2699
2699
|
var s = this._interaction;
|
|
@@ -2782,7 +2782,7 @@ function da() {
|
|
|
2782
2782
|
var l, f, p = this.coords.cur.page.x === this.coords.prev.page.x && this.coords.cur.page.y === this.coords.prev.page.y && this.coords.cur.client.x === this.coords.prev.client.x && this.coords.cur.client.y === this.coords.prev.client.y;
|
|
2783
2783
|
this.pointerIsDown && !this.pointerWasMoved && (l = this.coords.cur.client.x - this.coords.start.client.x, f = this.coords.cur.client.y - this.coords.start.client.y, this.pointerWasMoved = ht(l, f) > this.pointerMoveTolerance);
|
|
2784
2784
|
var h, v, N, y = this.getPointerIndex(t), O = { pointer: t, pointerIndex: y, pointerInfo: this.pointers[y], event: o, type: "move", eventTarget: s, dx: l, dy: f, duplicate: p, interaction: this };
|
|
2785
|
-
p || (h = this.coords.velocity, v = this.coords.delta, N = Math.max(v.timeStamp / 1e3, 1e-3), h.page.x = v.page.x / N, h.page.y = v.page.y / N, h.client.x = v.client.x / N, h.client.y = v.client.y / N, h.timeStamp = N), this._scopeFire("interactions:move", O), p || this.simulation || (this.interacting() && (O.type = null, this.move(O)), this.pointerWasMoved &&
|
|
2785
|
+
p || (h = this.coords.velocity, v = this.coords.delta, N = Math.max(v.timeStamp / 1e3, 1e-3), h.page.x = v.page.x / N, h.page.y = v.page.y / N, h.client.x = v.client.x / N, h.client.y = v.client.y / N, h.timeStamp = N), this._scopeFire("interactions:move", O), p || this.simulation || (this.interacting() && (O.type = null, this.move(O)), this.pointerWasMoved && Ft(this.coords.prev, this.coords.cur));
|
|
2786
2786
|
} }, { key: "move", value: function(t) {
|
|
2787
2787
|
t && t.event || kr(this.coords.delta), (t = ee({ pointer: this._latestPointer.pointer, event: this._latestPointer.event, eventTarget: this._latestPointer.eventTarget, interaction: this }, t || {})).phase = "move", this._doPhase(t);
|
|
2788
2788
|
} }, { key: "pointerUp", value: function(t, o, s, l) {
|
|
@@ -2812,7 +2812,7 @@ function da() {
|
|
|
2812
2812
|
var f, p, h, v = gt(t), N = this.getPointerIndex(t), y = this.pointers[N];
|
|
2813
2813
|
return l = l !== !1 && (l || /(down|start)$/i.test(o.type)), y ? y.pointer = t : (y = new Wi(v, t, o, null, null), N = this.pointers.length, this.pointers.push(y)), ki(this.coords.cur, this.pointers.map((function(O) {
|
|
2814
2814
|
return O.pointer;
|
|
2815
|
-
})), this._now()), f = this.coords.delta, p = this.coords.prev, h = this.coords.cur, f.page.x = h.page.x - p.page.x, f.page.y = h.page.y - p.page.y, f.client.x = h.client.x - p.client.x, f.client.y = h.client.y - p.client.y, f.timeStamp = h.timeStamp - p.timeStamp, l && (this.pointerIsDown = !0, y.downTime = this.coords.cur.timeStamp, y.downTarget = s,
|
|
2815
|
+
})), this._now()), f = this.coords.delta, p = this.coords.prev, h = this.coords.cur, f.page.x = h.page.x - p.page.x, f.page.y = h.page.y - p.page.y, f.client.x = h.client.x - p.client.x, f.client.y = h.client.y - p.client.y, f.timeStamp = h.timeStamp - p.timeStamp, l && (this.pointerIsDown = !0, y.downTime = this.coords.cur.timeStamp, y.downTarget = s, Lt(this.downPointer, t), this.interacting() || (Ft(this.coords.start, this.coords.cur), Ft(this.coords.prev, this.coords.cur), this.downEvent = o, this.pointerWasMoved = !1)), this._updateLatestPointer(t, o, s), this._scopeFire("interactions:update-pointer", { pointer: t, event: o, eventTarget: s, down: l, pointerInfo: y, pointerIndex: N, interaction: this }), N;
|
|
2816
2816
|
} }, { key: "removePointer", value: function(t, o) {
|
|
2817
2817
|
var s = this.getPointerIndex(t);
|
|
2818
2818
|
if (s !== -1) {
|
|
@@ -2830,7 +2830,7 @@ function da() {
|
|
|
2830
2830
|
(o = this.interactable) == null || o.fire(t), (!this.prevEvent || t.timeStamp >= this.prevEvent.timeStamp) && (this.prevEvent = t);
|
|
2831
2831
|
} }, { key: "_doPhase", value: function(t) {
|
|
2832
2832
|
var o = t.event, s = t.phase, l = t.preEnd, f = t.type, p = this.rect;
|
|
2833
|
-
if (p && s === "move" && (
|
|
2833
|
+
if (p && s === "move" && (Le(this.edges, p, this.coords.delta[this.interactable.options.deltaSource]), p.width = p.right - p.left, p.height = p.bottom - p.top), this._scopeFire("interactions:before-action-".concat(s), t) === !1) return !1;
|
|
2834
2834
|
var h = t.iEvent = this._createPreparedEvent(o, s, l, f);
|
|
2835
2835
|
return this._scopeFire("interactions:action-".concat(s), t), s === "start" && (this.prevEvent = h), this._fireEvent(h), this._scopeFire("interactions:after-action-".concat(s), t), !0;
|
|
2836
2836
|
} }, { key: "_now", value: function() {
|
|
@@ -2845,7 +2845,7 @@ function da() {
|
|
|
2845
2845
|
return !(!o.offset.pending.x && !o.offset.pending.y);
|
|
2846
2846
|
})(n)) return !1;
|
|
2847
2847
|
var t = n.offset.pending;
|
|
2848
|
-
return er(n.coords.cur, t), er(n.coords.delta, t),
|
|
2848
|
+
return er(n.coords.cur, t), er(n.coords.delta, t), Le(n.edges, n.rect, t), t.x = 0, t.y = 0, !0;
|
|
2849
2849
|
}
|
|
2850
2850
|
function es(n) {
|
|
2851
2851
|
var t = n.x, o = n.y;
|
|
@@ -2904,10 +2904,10 @@ function da() {
|
|
|
2904
2904
|
} }, { key: "inertiaTick", value: function() {
|
|
2905
2905
|
var t, o, s, l, f, p, h, v = this, N = this.interaction, y = Xt(N).resistance, O = (N._now() - this.t0) / 1e3;
|
|
2906
2906
|
if (O < this.te) {
|
|
2907
|
-
var
|
|
2908
|
-
this.isModified ? (t = 0, o = 0, s = this.targetOffset.x, l = this.targetOffset.y, f = this.modifiedOffset.x, p = this.modifiedOffset.y,
|
|
2909
|
-
var
|
|
2910
|
-
this.currentOffset.x +=
|
|
2907
|
+
var j, V = 1 - (Math.exp(-y * O) - this.lambda_v0) / this.one_ve_v0;
|
|
2908
|
+
this.isModified ? (t = 0, o = 0, s = this.targetOffset.x, l = this.targetOffset.y, f = this.modifiedOffset.x, p = this.modifiedOffset.y, j = { x: oo(h = V, t, s, f), y: oo(h, o, l, p) }) : j = { x: this.targetOffset.x * V, y: this.targetOffset.y * V };
|
|
2909
|
+
var L = { x: j.x - this.currentOffset.x, y: j.y - this.currentOffset.y };
|
|
2910
|
+
this.currentOffset.x += L.x, this.currentOffset.y += L.y, N.offsetBy(L), N.move(), this.onNextFrame((function() {
|
|
2911
2911
|
return v.inertiaTick();
|
|
2912
2912
|
}));
|
|
2913
2913
|
} else N.offsetBy({ x: this.modifiedOffset.x - this.currentOffset.x, y: this.modifiedOffset.y - this.currentOffset.y }), this.end();
|
|
@@ -2921,7 +2921,7 @@ function da() {
|
|
|
2921
2921
|
} else o.offsetBy({ x: this.targetOffset.x - this.currentOffset.x, y: this.targetOffset.y - this.currentOffset.y }), this.end();
|
|
2922
2922
|
} }, { key: "resume", value: function(t) {
|
|
2923
2923
|
var o = t.pointer, s = t.event, l = t.eventTarget, f = this.interaction;
|
|
2924
|
-
f.offsetBy({ x: -this.currentOffset.x, y: -this.currentOffset.y }), f.updatePointer(o, s, l, !0), f._doPhase({ interaction: f, event: s, phase: "resume" }),
|
|
2924
|
+
f.offsetBy({ x: -this.currentOffset.x, y: -this.currentOffset.y }), f.updatePointer(o, s, l, !0), f._doPhase({ interaction: f, event: s, phase: "resume" }), Ft(f.coords.prev, f.coords.cur), this.stop();
|
|
2925
2925
|
} }, { key: "end", value: function() {
|
|
2926
2926
|
this.interaction.move(), this.interaction.end(), this.stop();
|
|
2927
2927
|
} }, { key: "stop", value: function() {
|
|
@@ -2948,7 +2948,7 @@ function da() {
|
|
|
2948
2948
|
s.resume(n);
|
|
2949
2949
|
break;
|
|
2950
2950
|
}
|
|
2951
|
-
l =
|
|
2951
|
+
l = F(l);
|
|
2952
2952
|
}
|
|
2953
2953
|
}, "interactions:stop": function(n) {
|
|
2954
2954
|
var t = n.interaction.inertia;
|
|
@@ -3002,7 +3002,7 @@ function da() {
|
|
|
3002
3002
|
} }]), n;
|
|
3003
3003
|
})(), is = (function() {
|
|
3004
3004
|
function n(t) {
|
|
3005
|
-
u(this, n), this.currentTarget = void 0, this.originalEvent = void 0, this.type = void 0, this.originalEvent = t,
|
|
3005
|
+
u(this, n), this.currentTarget = void 0, this.originalEvent = void 0, this.type = void 0, this.originalEvent = t, Lt(this, t);
|
|
3006
3006
|
}
|
|
3007
3007
|
return g(n, [{ key: "preventOriginalDefault", value: function() {
|
|
3008
3008
|
this.originalEvent.preventDefault();
|
|
@@ -3019,29 +3019,29 @@ function da() {
|
|
|
3019
3019
|
return n === t || (typeof n == "boolean" ? !!t.capture === n && !t.passive : !!n.capture == !!t.capture && !!n.passive == !!t.passive);
|
|
3020
3020
|
}
|
|
3021
3021
|
var ss = { id: "events", install: function(n) {
|
|
3022
|
-
var t, o = [], s = {}, l = [], f = { add: p, remove: h, addDelegate: function(y, O,
|
|
3023
|
-
var
|
|
3024
|
-
if (!s[
|
|
3025
|
-
s[
|
|
3022
|
+
var t, o = [], s = {}, l = [], f = { add: p, remove: h, addDelegate: function(y, O, j, V, L) {
|
|
3023
|
+
var H = xt(L);
|
|
3024
|
+
if (!s[j]) {
|
|
3025
|
+
s[j] = [];
|
|
3026
3026
|
for (var ie = 0; ie < l.length; ie++) {
|
|
3027
3027
|
var re = l[ie];
|
|
3028
|
-
p(re,
|
|
3028
|
+
p(re, j, v), p(re, j, N, !0);
|
|
3029
3029
|
}
|
|
3030
3030
|
}
|
|
3031
|
-
var le = s[
|
|
3031
|
+
var le = s[j], ve = vt(le, (function(xe) {
|
|
3032
3032
|
return xe.selector === y && xe.context === O;
|
|
3033
3033
|
}));
|
|
3034
|
-
ve || (ve = { selector: y, context: O, listeners: [] }, le.push(ve)), ve.listeners.push({ func: V, options:
|
|
3035
|
-
}, removeDelegate: function(y, O,
|
|
3036
|
-
var
|
|
3034
|
+
ve || (ve = { selector: y, context: O, listeners: [] }, le.push(ve)), ve.listeners.push({ func: V, options: H });
|
|
3035
|
+
}, removeDelegate: function(y, O, j, V, L) {
|
|
3036
|
+
var H, ie = xt(L), re = s[j], le = !1;
|
|
3037
3037
|
if (re)
|
|
3038
|
-
for (
|
|
3039
|
-
var ve = re[
|
|
3038
|
+
for (H = re.length - 1; H >= 0; H--) {
|
|
3039
|
+
var ve = re[H];
|
|
3040
3040
|
if (ve.selector === y && ve.context === O) {
|
|
3041
3041
|
for (var xe = ve.listeners, de = xe.length - 1; de >= 0; de--) {
|
|
3042
3042
|
var ye = xe[de];
|
|
3043
3043
|
if (ye.func === V && Ut(ye.options, ie)) {
|
|
3044
|
-
xe.splice(de, 1), xe.length || (re.splice(
|
|
3044
|
+
xe.splice(de, 1), xe.length || (re.splice(H, 1), h(O, j, v), h(O, j, N, !0)), le = !0;
|
|
3045
3045
|
break;
|
|
3046
3046
|
}
|
|
3047
3047
|
}
|
|
@@ -3049,25 +3049,25 @@ function da() {
|
|
|
3049
3049
|
}
|
|
3050
3050
|
}
|
|
3051
3051
|
}, delegateListener: v, delegateUseCapture: N, delegatedEvents: s, documents: l, targets: o, supportsOptions: !1, supportsPassive: !1 };
|
|
3052
|
-
function p(y, O,
|
|
3052
|
+
function p(y, O, j, V) {
|
|
3053
3053
|
if (y.addEventListener) {
|
|
3054
|
-
var
|
|
3054
|
+
var L = xt(V), H = vt(o, (function(ie) {
|
|
3055
3055
|
return ie.eventTarget === y;
|
|
3056
3056
|
}));
|
|
3057
|
-
|
|
3058
|
-
return ie.func ===
|
|
3059
|
-
})) || (y.addEventListener(O,
|
|
3057
|
+
H || (H = { eventTarget: y, events: {} }, o.push(H)), H.events[O] || (H.events[O] = []), vt(H.events[O], (function(ie) {
|
|
3058
|
+
return ie.func === j && Ut(ie.options, L);
|
|
3059
|
+
})) || (y.addEventListener(O, j, f.supportsOptions ? L : L.capture), H.events[O].push({ func: j, options: L }));
|
|
3060
3060
|
}
|
|
3061
3061
|
}
|
|
3062
|
-
function h(y, O,
|
|
3062
|
+
function h(y, O, j, V) {
|
|
3063
3063
|
if (y.addEventListener && y.removeEventListener) {
|
|
3064
|
-
var
|
|
3065
|
-
return
|
|
3066
|
-
})),
|
|
3067
|
-
if (
|
|
3068
|
-
var ie = !1, re =
|
|
3064
|
+
var L = mt(o, (function(Me) {
|
|
3065
|
+
return Me.eventTarget === y;
|
|
3066
|
+
})), H = o[L];
|
|
3067
|
+
if (H && H.events) if (O !== "all") {
|
|
3068
|
+
var ie = !1, re = H.events[O];
|
|
3069
3069
|
if (re) {
|
|
3070
|
-
if (
|
|
3070
|
+
if (j === "all") {
|
|
3071
3071
|
for (var le = re.length - 1; le >= 0; le--) {
|
|
3072
3072
|
var ve = re[le];
|
|
3073
3073
|
h(y, O, ve.func, ve.options);
|
|
@@ -3076,30 +3076,30 @@ function da() {
|
|
|
3076
3076
|
}
|
|
3077
3077
|
for (var xe = xt(V), de = 0; de < re.length; de++) {
|
|
3078
3078
|
var ye = re[de];
|
|
3079
|
-
if (ye.func ===
|
|
3080
|
-
y.removeEventListener(O,
|
|
3079
|
+
if (ye.func === j && Ut(ye.options, xe)) {
|
|
3080
|
+
y.removeEventListener(O, j, f.supportsOptions ? xe : xe.capture), re.splice(de, 1), re.length === 0 && (delete H.events[O], ie = !0);
|
|
3081
3081
|
break;
|
|
3082
3082
|
}
|
|
3083
3083
|
}
|
|
3084
3084
|
}
|
|
3085
|
-
ie && !Object.keys(
|
|
3086
|
-
} else for (O in
|
|
3085
|
+
ie && !Object.keys(H.events).length && o.splice(L, 1);
|
|
3086
|
+
} else for (O in H.events) H.events.hasOwnProperty(O) && h(y, O, "all");
|
|
3087
3087
|
}
|
|
3088
3088
|
}
|
|
3089
3089
|
function v(y, O) {
|
|
3090
|
-
for (var
|
|
3091
|
-
for (var re = 0; re <
|
|
3092
|
-
var le =
|
|
3093
|
-
if (R(ie, ve) && ne(xe,
|
|
3090
|
+
for (var j = xt(O), V = new is(y), L = s[y.type], H = Mr(y)[0], ie = H; E.element(ie); ) {
|
|
3091
|
+
for (var re = 0; re < L.length; re++) {
|
|
3092
|
+
var le = L[re], ve = le.selector, xe = le.context;
|
|
3093
|
+
if (R(ie, ve) && ne(xe, H) && ne(xe, ie)) {
|
|
3094
3094
|
var de = le.listeners;
|
|
3095
3095
|
V.currentTarget = ie;
|
|
3096
3096
|
for (var ye = 0; ye < de.length; ye++) {
|
|
3097
|
-
var
|
|
3098
|
-
Ut(
|
|
3097
|
+
var Me = de[ye];
|
|
3098
|
+
Ut(Me.options, j) && Me.func(V);
|
|
3099
3099
|
}
|
|
3100
3100
|
}
|
|
3101
3101
|
}
|
|
3102
|
-
ie =
|
|
3102
|
+
ie = F(ie);
|
|
3103
3103
|
}
|
|
3104
3104
|
}
|
|
3105
3105
|
function N(y) {
|
|
@@ -3123,7 +3123,7 @@ function da() {
|
|
|
3123
3123
|
var h = p[f], v = s;
|
|
3124
3124
|
if (h.simulation && h.simulation.allowResume && h.pointerType === t) for (; v; ) {
|
|
3125
3125
|
if (v === h.element) return h;
|
|
3126
|
-
v =
|
|
3126
|
+
v = F(v);
|
|
3127
3127
|
}
|
|
3128
3128
|
}
|
|
3129
3129
|
return null;
|
|
@@ -3173,16 +3173,16 @@ function da() {
|
|
|
3173
3173
|
if (/^touch/.test(o.type)) {
|
|
3174
3174
|
t.prevTouchTime = t.now();
|
|
3175
3175
|
for (var N = 0, y = o.changedTouches; N < y.length; N++) {
|
|
3176
|
-
var O = y[N],
|
|
3177
|
-
v.push([
|
|
3176
|
+
var O = y[N], j = { pointer: O, pointerId: gt(O), pointerType: l, eventType: o.type, eventTarget: p, curEventTarget: h, scope: t }, V = uo(j);
|
|
3177
|
+
v.push([j.pointer, j.eventTarget, j.curEventTarget, V]);
|
|
3178
3178
|
}
|
|
3179
3179
|
} else {
|
|
3180
|
-
var
|
|
3180
|
+
var L = !1;
|
|
3181
3181
|
if (!te.supportsPointerEvent && /mouse/.test(o.type)) {
|
|
3182
|
-
for (var
|
|
3183
|
-
|
|
3182
|
+
for (var H = 0; H < s.length && !L; H++) L = s[H].pointerType !== "mouse" && s[H].pointerIsDown;
|
|
3183
|
+
L = L || t.now() - t.prevTouchTime < 500 || o.timeStamp === 0;
|
|
3184
3184
|
}
|
|
3185
|
-
if (!
|
|
3185
|
+
if (!L) {
|
|
3186
3186
|
var ie = { pointer: o, pointerId: gt(o), pointerType: l, eventType: o.type, curEventTarget: h, eventTarget: p, scope: t }, re = uo(ie);
|
|
3187
3187
|
v.push([ie.pointer, ie.eventTarget, ie.curEventTarget, re]);
|
|
3188
3188
|
}
|
|
@@ -3215,11 +3215,11 @@ function da() {
|
|
|
3215
3215
|
for (var h = 0, v = n.interactions.list; h < v.length; h++) {
|
|
3216
3216
|
var N = v[h];
|
|
3217
3217
|
if (N.pointerIsDown && N.pointerType === "touch" && !N._interacting) for (var y = function() {
|
|
3218
|
-
var V =
|
|
3219
|
-
n.documents.some((function(
|
|
3220
|
-
return ne(
|
|
3218
|
+
var V = j[O];
|
|
3219
|
+
n.documents.some((function(L) {
|
|
3220
|
+
return ne(L.doc, V.downTarget);
|
|
3221
3221
|
})) || N.removePointer(V.pointer, V.event);
|
|
3222
|
-
}, O = 0,
|
|
3222
|
+
}, O = 0, j = N.pointers; O < j.length; O++) y();
|
|
3223
3223
|
}
|
|
3224
3224
|
}
|
|
3225
3225
|
(l = D.PointerEvent ? [{ type: f.down, listener: p }, { type: f.down, listener: t.pointerDown }, { type: f.move, listener: t.pointerMove }, { type: f.up, listener: t.pointerUp }, { type: f.cancel, listener: t.pointerUp }] : [{ type: "mousedown", listener: t.pointerDown }, { type: "mousemove", listener: t.pointerMove }, { type: "mouseup", listener: t.pointerUp }, { type: "touchstart", listener: p }, { type: "touchstart", listener: t.pointerDown }, { type: "touchmove", listener: t.pointerMove }, { type: "touchend", listener: t.pointerUp }, { type: "touchcancel", listener: t.pointerUp }]).push({ type: "blur", listener: function(h) {
|
|
@@ -3227,7 +3227,7 @@ function da() {
|
|
|
3227
3227
|
N[v].documentBlur(h);
|
|
3228
3228
|
} }), n.prevTouchTime = 0, n.Interaction = (function(h) {
|
|
3229
3229
|
b(N, h);
|
|
3230
|
-
var v =
|
|
3230
|
+
var v = $(N);
|
|
3231
3231
|
function N() {
|
|
3232
3232
|
return u(this, N), v.apply(this, arguments);
|
|
3233
3233
|
}
|
|
@@ -3266,7 +3266,7 @@ function da() {
|
|
|
3266
3266
|
return E.func(o.onstart) && this.on("".concat(t, "start"), o.onstart), E.func(o.onmove) && this.on("".concat(t, "move"), o.onmove), E.func(o.onend) && this.on("".concat(t, "end"), o.onend), E.func(o.oninertiastart) && this.on("".concat(t, "inertiastart"), o.oninertiastart), this;
|
|
3267
3267
|
} }, { key: "updatePerActionListeners", value: function(t, o, s) {
|
|
3268
3268
|
var l, f = this, p = (l = this._actions.map[t]) == null ? void 0 : l.filterEventType, h = function(v) {
|
|
3269
|
-
return (p == null || p(v)) &&
|
|
3269
|
+
return (p == null || p(v)) && Ht(v, f._actions);
|
|
3270
3270
|
};
|
|
3271
3271
|
(E.array(o) || E.object(o)) && this._onOff(Qe.Off, t, o, void 0, h), (E.array(s) || E.object(s)) && this._onOff(Qe.On, t, s, void 0, h);
|
|
3272
3272
|
} }, { key: "setPerAction", value: function(t, o) {
|
|
@@ -3276,7 +3276,7 @@ function da() {
|
|
|
3276
3276
|
f === "listeners" && this.updatePerActionListeners(t, p.listeners, h), E.array(h) ? p[f] = zr(h) : E.plainObject(h) ? (p[f] = ee(p[f] || {}, ft(h)), E.object(s.perAction[f]) && "enabled" in s.perAction[f] && (p[f].enabled = h.enabled !== !1)) : E.bool(h) && E.object(s.perAction[f]) ? p[f].enabled = h : p[f] = h;
|
|
3277
3277
|
}
|
|
3278
3278
|
} }, { key: "getRect", value: function(t) {
|
|
3279
|
-
return t = t || (E.element(this.target) ? this.target : null), E.string(this.target) && (t = t || this._context.querySelector(this.target)),
|
|
3279
|
+
return t = t || (E.element(this.target) ? this.target : null), E.string(this.target) && (t = t || this._context.querySelector(this.target)), ge(t);
|
|
3280
3280
|
} }, { key: "rectChecker", value: function(t) {
|
|
3281
3281
|
var o = this;
|
|
3282
3282
|
return E.func(t) ? (this.getRect = function(s) {
|
|
@@ -3315,7 +3315,7 @@ function da() {
|
|
|
3315
3315
|
h === "wheel" && (h = te.wheelEvent);
|
|
3316
3316
|
for (var v = 0, N = p[h]; v < N.length; v++) {
|
|
3317
3317
|
var y = N[v];
|
|
3318
|
-
|
|
3318
|
+
Ht(h, this._actions) ? this.events[t === Qe.On ? "on" : "off"](h, y) : E.string(this.target) ? this._scopeEvents[t === Qe.On ? "addDelegate" : "removeDelegate"](this.target, this._context, h, y, l) : this._scopeEvents[t === Qe.On ? "add" : "remove"](this.target, h, y, l);
|
|
3319
3319
|
}
|
|
3320
3320
|
}
|
|
3321
3321
|
return this;
|
|
@@ -3372,7 +3372,7 @@ function da() {
|
|
|
3372
3372
|
var v = s.interactables.getExisting(p, h);
|
|
3373
3373
|
return v || ((v = s.interactables.new(p, h)).events.global = f.globalEvents), v;
|
|
3374
3374
|
};
|
|
3375
|
-
return l.getPointerAverage =
|
|
3375
|
+
return l.getPointerAverage = jr, l.getTouchBBox = Vn, l.getTouchDistance = Dn, l.getTouchAngle = Bn, l.getElementRect = ge, l.getElementClientRect = fe, l.matchesSelector = R, l.closest = ae, l.globalEvents = {}, l.version = "1.10.27", l.scope = s, l.use = function(f, p) {
|
|
3376
3376
|
return this.scope.usePlugin(f, p), this;
|
|
3377
3377
|
}, l.isSet = function(f, p) {
|
|
3378
3378
|
return !!this.scope.interactables.get(f, p && p.context);
|
|
@@ -3388,7 +3388,7 @@ function da() {
|
|
|
3388
3388
|
for (var O in f) this.on(O, f[O], p);
|
|
3389
3389
|
return this;
|
|
3390
3390
|
}
|
|
3391
|
-
return
|
|
3391
|
+
return Ht(f, this.scope.actions) ? this.globalEvents[f] ? this.globalEvents[f].push(p) : this.globalEvents[f] = [p] : this.scope.events.add(this.scope.document, f, p, { options: h }), this;
|
|
3392
3392
|
}), "The interact.on() method is being deprecated"), l.off = yt((function(f, p, h) {
|
|
3393
3393
|
if (E.string(f) && f.search(" ") !== -1 && (f = f.trim().split(/ +/)), E.array(f)) {
|
|
3394
3394
|
for (var v = 0, N = f; v < N.length; v++) {
|
|
@@ -3401,8 +3401,8 @@ function da() {
|
|
|
3401
3401
|
for (var O in f) this.off(O, f[O], p);
|
|
3402
3402
|
return this;
|
|
3403
3403
|
}
|
|
3404
|
-
var
|
|
3405
|
-
return
|
|
3404
|
+
var j;
|
|
3405
|
+
return Ht(f, this.scope.actions) ? f in this.globalEvents && (j = this.globalEvents[f].indexOf(p)) !== -1 && this.globalEvents[f].splice(j, 1) : this.scope.events.remove(this.scope.document, f, p, h), this;
|
|
3406
3406
|
}), "The interact.off() method is being deprecated"), l.debug = function() {
|
|
3407
3407
|
return this.scope;
|
|
3408
3408
|
}, l.supportsTouch = function() {
|
|
@@ -3425,7 +3425,7 @@ function da() {
|
|
|
3425
3425
|
var o = this;
|
|
3426
3426
|
this.Interactable = (function(s) {
|
|
3427
3427
|
b(f, s);
|
|
3428
|
-
var l =
|
|
3428
|
+
var l = $(f);
|
|
3429
3429
|
function f() {
|
|
3430
3430
|
return u(this, f), l.apply(this, arguments);
|
|
3431
3431
|
}
|
|
@@ -3487,7 +3487,7 @@ function da() {
|
|
|
3487
3487
|
function fo(n) {
|
|
3488
3488
|
return n && n.replace(/\/.*$/, "");
|
|
3489
3489
|
}
|
|
3490
|
-
var po = new ds(),
|
|
3490
|
+
var po = new ds(), Ae = po.interactStatic, ps = typeof globalThis < "u" ? globalThis : window;
|
|
3491
3491
|
po.init(ps);
|
|
3492
3492
|
var hs = Object.freeze({ __proto__: null, edgeTarget: function() {
|
|
3493
3493
|
}, elements: function() {
|
|
@@ -3497,8 +3497,8 @@ function da() {
|
|
|
3497
3497
|
return l in n || f in n;
|
|
3498
3498
|
})), o = function(s, l) {
|
|
3499
3499
|
for (var f = n.range, p = n.limits, h = p === void 0 ? { left: -1 / 0, right: 1 / 0, top: -1 / 0, bottom: 1 / 0 } : p, v = n.offset, N = v === void 0 ? { x: 0, y: 0 } : v, y = { range: f, grid: n, x: null, y: null }, O = 0; O < t.length; O++) {
|
|
3500
|
-
var
|
|
3501
|
-
y[V] = Math.max(h.left, Math.min(h.right,
|
|
3500
|
+
var j = t[O], V = j[0], L = j[1], H = Math.round((s - N.x) / n[V]), ie = Math.round((l - N.y) / n[L]);
|
|
3501
|
+
y[V] = Math.max(h.left, Math.min(h.right, H * n[V] + N.x)), y[L] = Math.max(h.top, Math.min(h.bottom, ie * n[L] + N.y));
|
|
3502
3502
|
}
|
|
3503
3503
|
return y;
|
|
3504
3504
|
};
|
|
@@ -3511,8 +3511,8 @@ function da() {
|
|
|
3511
3511
|
p === "preserve" && (p = o.width / o.height), t.startCoords = ee({}, l), t.startRect = ee({}, o), t.ratio = p, t.equalDelta = N;
|
|
3512
3512
|
var O = t.linkedEdges = { top: s.top || s.left && !s.bottom, left: s.left || s.top && !s.right, bottom: s.bottom || s.right && !s.top, right: s.right || s.bottom && !s.left };
|
|
3513
3513
|
if (t.xIsPrimaryAxis = !(!s.left && !s.right), t.equalDelta) {
|
|
3514
|
-
var
|
|
3515
|
-
t.edgeSign = { x:
|
|
3514
|
+
var j = (O.left ? 1 : -1) * (O.top ? 1 : -1);
|
|
3515
|
+
t.edgeSign = { x: j, y: j };
|
|
3516
3516
|
} else t.edgeSign = { x: O.left ? -1 : 1, y: O.top ? -1 : 1 };
|
|
3517
3517
|
if (h !== !1 && ee(s, O), y != null && y.length) {
|
|
3518
3518
|
var V = new Zn(n.interaction);
|
|
@@ -3522,7 +3522,7 @@ function da() {
|
|
|
3522
3522
|
var t = n.state, o = n.rect, s = n.coords, l = t.linkedEdges, f = ee({}, s), p = t.equalDelta ? ys : bs;
|
|
3523
3523
|
if (ee(n.edges, l), p(t, t.xIsPrimaryAxis, s, o), !t.subModification) return null;
|
|
3524
3524
|
var h = ee({}, o);
|
|
3525
|
-
|
|
3525
|
+
Le(l, h, { x: s.x - f.x, y: s.y - f.y });
|
|
3526
3526
|
var v = t.subModification.setAll(a(a({}, n), {}, { rect: h, edges: l, pageCoords: s, prevCoords: s, prevRect: h })), N = v.delta;
|
|
3527
3527
|
return v.changed && (p(t, Math.abs(N.x) > Math.abs(N.y), v.coords, v.rect), ee(s, v.coords)), v.eventProps;
|
|
3528
3528
|
}, defaults: { ratio: "preserve", equalDelta: !1, modifiers: [], enabled: !1 } };
|
|
@@ -3545,7 +3545,7 @@ function da() {
|
|
|
3545
3545
|
ho._defaults = {};
|
|
3546
3546
|
var Kt = ho;
|
|
3547
3547
|
function it(n, t, o) {
|
|
3548
|
-
return E.func(n) ?
|
|
3548
|
+
return E.func(n) ? Ce(n, t.interactable, t.element, [o.x, o.y, t]) : Ce(n, t.interactable, t.element);
|
|
3549
3549
|
}
|
|
3550
3550
|
var Gt = { start: function(n) {
|
|
3551
3551
|
var t = n.rect, o = n.startOffset, s = n.state, l = n.interaction, f = n.pageCoords, p = s.options, h = p.elementRect, v = ee({ left: 0, top: 0, right: 0, bottom: 0 }, p.offset || {});
|
|
@@ -3591,33 +3591,33 @@ function da() {
|
|
|
3591
3591
|
}, set: function(n) {
|
|
3592
3592
|
var t = n.interaction, o = n.state, s = n.rect, l = n.edges, f = o.options;
|
|
3593
3593
|
if (l) {
|
|
3594
|
-
var p =
|
|
3594
|
+
var p = He(it(f.min, t, n.coords)) || _s, h = He(it(f.max, t, n.coords)) || Ts;
|
|
3595
3595
|
o.options = { endOnly: f.endOnly, inner: ee({}, wt.noInner), outer: ee({}, wt.noOuter) }, l.top ? (o.options.inner.top = s.bottom - p.height, o.options.outer.top = s.bottom - h.height) : l.bottom && (o.options.inner.bottom = s.top + p.height, o.options.outer.bottom = s.top + h.height), l.left ? (o.options.inner.left = s.right - p.width, o.options.outer.left = s.right - h.width) : l.right && (o.options.inner.right = s.left + p.width, o.options.outer.right = s.left + h.width), wt.set(n), o.options = f;
|
|
3596
3596
|
}
|
|
3597
3597
|
}, defaults: { min: null, max: null, endOnly: !1, enabled: !1 } }, "restrictSize"), or = { start: function(n) {
|
|
3598
|
-
var t, o = n.interaction, s = n.interactable, l = n.element, f = n.rect, p = n.state, h = n.startOffset, v = p.options, N = v.offsetWithOrigin ? (function(
|
|
3599
|
-
var V =
|
|
3600
|
-
return
|
|
3598
|
+
var t, o = n.interaction, s = n.interactable, l = n.element, f = n.rect, p = n.state, h = n.startOffset, v = p.options, N = v.offsetWithOrigin ? (function(j) {
|
|
3599
|
+
var V = j.interaction.element, L = Ie(Ce(j.state.options.origin, null, null, [V])), H = L || Ye(j.interactable, V, j.interaction.prepared.name);
|
|
3600
|
+
return H;
|
|
3601
3601
|
})(n) : { x: 0, y: 0 };
|
|
3602
3602
|
if (v.offset === "startCoords") t = { x: o.coords.start.page.x, y: o.coords.start.page.y };
|
|
3603
3603
|
else {
|
|
3604
|
-
var y =
|
|
3604
|
+
var y = Ce(v.offset, s, l, [o]);
|
|
3605
3605
|
(t = Ie(y) || { x: 0, y: 0 }).x += N.x, t.y += N.y;
|
|
3606
3606
|
}
|
|
3607
3607
|
var O = v.relativePoints;
|
|
3608
|
-
p.offsets = f && O && O.length ? O.map((function(
|
|
3609
|
-
return { index: V, relativePoint:
|
|
3608
|
+
p.offsets = f && O && O.length ? O.map((function(j, V) {
|
|
3609
|
+
return { index: V, relativePoint: j, x: h.left - f.width * j.x + t.x, y: h.top - f.height * j.y + t.y };
|
|
3610
3610
|
})) : [{ index: 0, relativePoint: null, x: t.x, y: t.y }];
|
|
3611
3611
|
}, set: function(n) {
|
|
3612
3612
|
var t = n.interaction, o = n.coords, s = n.state, l = s.options, f = s.offsets, p = Ye(t.interactable, t.element, t.prepared.name), h = ee({}, o), v = [];
|
|
3613
3613
|
l.offsetWithOrigin || (h.x -= p.x, h.y -= p.y);
|
|
3614
|
-
for (var N = 0, y = f; N < y.length; N++) for (var O = y[N],
|
|
3615
|
-
var ie = l.targets[
|
|
3616
|
-
(re = E.func(ie) ? ie(
|
|
3614
|
+
for (var N = 0, y = f; N < y.length; N++) for (var O = y[N], j = h.x - O.x, V = h.y - O.y, L = 0, H = l.targets.length; L < H; L++) {
|
|
3615
|
+
var ie = l.targets[L], re = void 0;
|
|
3616
|
+
(re = E.func(ie) ? ie(j, V, t._proxy, O, L) : ie) && v.push({ x: (E.number(re.x) ? re.x : j) + O.x, y: (E.number(re.y) ? re.y : V) + O.y, range: E.number(re.range) ? re.range : l.range, source: ie, index: L, offset: O });
|
|
3617
3617
|
}
|
|
3618
3618
|
for (var le = { target: null, inRange: !1, distance: 0, range: 0, delta: { x: 0, y: 0 } }, ve = 0; ve < v.length; ve++) {
|
|
3619
|
-
var xe = v[ve], de = xe.range, ye = xe.x - h.x,
|
|
3620
|
-
de === 1 / 0 && le.inRange && le.range !== 1 / 0 && (Ve = !1), le.target && !(Ve ? le.inRange && de !== 1 / 0 ? Pe / de < le.distance / le.range : de === 1 / 0 && le.range !== 1 / 0 || Pe < le.distance : !le.inRange && Pe < le.distance) || (le.target = xe, le.distance = Pe, le.range = de, le.inRange = Ve, le.delta.x = ye, le.delta.y =
|
|
3619
|
+
var xe = v[ve], de = xe.range, ye = xe.x - h.x, Me = xe.y - h.y, Pe = ht(ye, Me), Ve = Pe <= de;
|
|
3620
|
+
de === 1 / 0 && le.inRange && le.range !== 1 / 0 && (Ve = !1), le.target && !(Ve ? le.inRange && de !== 1 / 0 ? Pe / de < le.distance / le.range : de === 1 / 0 && le.range !== 1 / 0 || Pe < le.distance : !le.inRange && Pe < le.distance) || (le.target = xe, le.distance = Pe, le.range = de, le.inRange = Ve, le.delta.x = ye, le.delta.y = Me);
|
|
3621
3621
|
}
|
|
3622
3622
|
return le.inRange && (o.x = le.target.x, o.y = le.target.y), s.closest = le, le;
|
|
3623
3623
|
}, defaults: { range: 1 / 0, targets: null, offset: null, offsetWithOrigin: !0, origin: null, relativePoints: null, endOnly: !1, enabled: !1 } }, Ps = Ze(or, "snap"), qt = { start: function(n) {
|
|
@@ -3630,10 +3630,10 @@ function da() {
|
|
|
3630
3630
|
for (var h = 0, v = l.targets || []; h < v.length; h++) {
|
|
3631
3631
|
var N = v[h], y = void 0;
|
|
3632
3632
|
if (y = E.func(N) ? N(p.x, p.y, t) : N) {
|
|
3633
|
-
for (var O = 0,
|
|
3634
|
-
var V =
|
|
3635
|
-
if (
|
|
3636
|
-
y.x = y[
|
|
3633
|
+
for (var O = 0, j = o.targetFields; O < j.length; O++) {
|
|
3634
|
+
var V = j[O], L = V[0], H = V[1];
|
|
3635
|
+
if (L in y || H in y) {
|
|
3636
|
+
y.x = y[L], y.y = y[H];
|
|
3637
3637
|
break;
|
|
3638
3638
|
}
|
|
3639
3639
|
}
|
|
@@ -3651,12 +3651,12 @@ function da() {
|
|
|
3651
3651
|
var s = ir[o], l = s._defaults, f = s._methods;
|
|
3652
3652
|
l._methods = f, n.defaults.perAction[o] = l;
|
|
3653
3653
|
}
|
|
3654
|
-
} },
|
|
3654
|
+
} }, Cs = ks, yo = (function(n) {
|
|
3655
3655
|
b(o, n);
|
|
3656
|
-
var t =
|
|
3656
|
+
var t = $(o);
|
|
3657
3657
|
function o(s, l, f, p, h, v) {
|
|
3658
3658
|
var N;
|
|
3659
|
-
if (u(this, o),
|
|
3659
|
+
if (u(this, o), Lt(I(N = t.call(this, h)), f), f !== l && Lt(I(N), l), N.timeStamp = v, N.originalEvent = f, N.type = s, N.pointerId = gt(l), N.pointerType = Ar(l), N.target = p, N.currentTarget = null, s === "tap") {
|
|
3660
3660
|
var y = h.getPointerIndex(l);
|
|
3661
3661
|
N.dt = N.timeStamp - h.pointers[y].downTime;
|
|
3662
3662
|
var O = N.timeStamp - h.tapTime;
|
|
@@ -3686,18 +3686,18 @@ function da() {
|
|
|
3686
3686
|
n.duplicate || o.pointerIsDown && !o.pointerWasMoved || (o.pointerIsDown && sr(n), et({ interaction: o, pointer: s, event: l, eventTarget: f, type: "move" }, t));
|
|
3687
3687
|
}, "interactions:down": function(n, t) {
|
|
3688
3688
|
(function(o, s) {
|
|
3689
|
-
for (var l = o.interaction, f = o.pointer, p = o.event, h = o.eventTarget, v = o.pointerIndex, N = l.pointers[v].hold, y = ue(h), O = { interaction: l, pointer: f, event: p, eventTarget: h, type: "hold", targets: [], path: y, node: null },
|
|
3690
|
-
var V = y[
|
|
3689
|
+
for (var l = o.interaction, f = o.pointer, p = o.event, h = o.eventTarget, v = o.pointerIndex, N = l.pointers[v].hold, y = ue(h), O = { interaction: l, pointer: f, event: p, eventTarget: h, type: "hold", targets: [], path: y, node: null }, j = 0; j < y.length; j++) {
|
|
3690
|
+
var V = y[j];
|
|
3691
3691
|
O.node = V, s.fire("pointerEvents:collect-targets", O);
|
|
3692
3692
|
}
|
|
3693
3693
|
if (O.targets.length) {
|
|
3694
|
-
for (var
|
|
3695
|
-
var re = ie[
|
|
3696
|
-
re <
|
|
3694
|
+
for (var L = 1 / 0, H = 0, ie = O.targets; H < ie.length; H++) {
|
|
3695
|
+
var re = ie[H].eventable.options.holdDuration;
|
|
3696
|
+
re < L && (L = re);
|
|
3697
3697
|
}
|
|
3698
|
-
N.duration =
|
|
3698
|
+
N.duration = L, N.timeout = setTimeout((function() {
|
|
3699
3699
|
et({ interaction: l, eventTarget: h, pointer: f, event: p, type: "hold" }, s);
|
|
3700
|
-
}),
|
|
3700
|
+
}), L);
|
|
3701
3701
|
}
|
|
3702
3702
|
})(n, t), et(n, t);
|
|
3703
3703
|
}, "interactions:up": function(n, t) {
|
|
@@ -3712,14 +3712,14 @@ function da() {
|
|
|
3712
3712
|
var o = n.interaction, s = n.pointer, l = n.event, f = n.eventTarget, p = n.type, h = n.targets, v = h === void 0 ? bo(n, t) : h, N = new yo(p, s, l, f, o, t.now());
|
|
3713
3713
|
t.fire("pointerEvents:new", { pointerEvent: N });
|
|
3714
3714
|
for (var y = { interaction: o, pointer: s, event: l, eventTarget: f, targets: v, type: p, pointerEvent: N }, O = 0; O < v.length; O++) {
|
|
3715
|
-
var
|
|
3716
|
-
for (var V in
|
|
3717
|
-
var
|
|
3718
|
-
if (N._subtractOrigin(
|
|
3715
|
+
var j = v[O];
|
|
3716
|
+
for (var V in j.props || {}) N[V] = j.props[V];
|
|
3717
|
+
var L = Ye(j.eventable, j.node);
|
|
3718
|
+
if (N._subtractOrigin(L), N.eventable = j.eventable, N.currentTarget = j.node, j.eventable.fire(N), N._addOrigin(L), N.immediatePropagationStopped || N.propagationStopped && O + 1 < v.length && v[O + 1].node !== N.currentTarget) break;
|
|
3719
3719
|
}
|
|
3720
3720
|
if (t.fire("pointerEvents:fired", y), p === "tap") {
|
|
3721
|
-
var
|
|
3722
|
-
o.prevTap =
|
|
3721
|
+
var H = N.double ? et({ interaction: o, pointer: s, event: l, eventTarget: f, type: "doubletap" }, t) : N;
|
|
3722
|
+
o.prevTap = H, o.tapTime = H.timeStamp;
|
|
3723
3723
|
}
|
|
3724
3724
|
return N;
|
|
3725
3725
|
}
|
|
@@ -3727,20 +3727,20 @@ function da() {
|
|
|
3727
3727
|
var o = n.interaction, s = n.pointer, l = n.event, f = n.eventTarget, p = n.type, h = o.getPointerIndex(s), v = o.pointers[h];
|
|
3728
3728
|
if (p === "tap" && (o.pointerWasMoved || !v || v.downTarget !== f)) return [];
|
|
3729
3729
|
for (var N = ue(f), y = { interaction: o, pointer: s, event: l, eventTarget: f, type: p, path: N, targets: [], node: null }, O = 0; O < N.length; O++) {
|
|
3730
|
-
var
|
|
3731
|
-
y.node =
|
|
3730
|
+
var j = N[O];
|
|
3731
|
+
y.node = j, t.fire("pointerEvents:collect-targets", y);
|
|
3732
3732
|
}
|
|
3733
3733
|
return p === "hold" && (y.targets = y.targets.filter((function(V) {
|
|
3734
|
-
var
|
|
3735
|
-
return V.eventable.options.holdDuration === ((
|
|
3734
|
+
var L, H;
|
|
3735
|
+
return V.eventable.options.holdDuration === ((L = o.pointers[h]) == null || (H = L.hold) == null ? void 0 : H.duration);
|
|
3736
3736
|
}))), y.targets;
|
|
3737
3737
|
}
|
|
3738
3738
|
function sr(n) {
|
|
3739
3739
|
var t = n.interaction, o = n.pointerIndex, s = t.pointers[o].hold;
|
|
3740
3740
|
s && s.timeout && (clearTimeout(s.timeout), s.timeout = null);
|
|
3741
3741
|
}
|
|
3742
|
-
var
|
|
3743
|
-
function
|
|
3742
|
+
var $s = Object.freeze({ __proto__: null, default: Et });
|
|
3743
|
+
function js(n) {
|
|
3744
3744
|
var t = n.interaction;
|
|
3745
3745
|
t.holdIntervalHandle && (clearInterval(t.holdIntervalHandle), t.holdIntervalHandle = null);
|
|
3746
3746
|
}
|
|
@@ -3749,7 +3749,7 @@ function da() {
|
|
|
3749
3749
|
var t = n.pointerEvents;
|
|
3750
3750
|
t.defaults.holdRepeatInterval = 0, t.types.holdrepeat = n.actions.phaselessTypes.holdrepeat = !0;
|
|
3751
3751
|
}, listeners: ["move", "up", "cancel", "endall"].reduce((function(n, t) {
|
|
3752
|
-
return n["pointerEvents:".concat(t)] =
|
|
3752
|
+
return n["pointerEvents:".concat(t)] = js, n;
|
|
3753
3753
|
}), { "pointerEvents:new": function(n) {
|
|
3754
3754
|
var t = n.pointerEvent;
|
|
3755
3755
|
t.type === "hold" && (t.count = (t.count || 0) + 1);
|
|
@@ -3785,23 +3785,23 @@ function da() {
|
|
|
3785
3785
|
}, "interactable:set": function(n, t) {
|
|
3786
3786
|
var o = n.interactable, s = n.options;
|
|
3787
3787
|
ee(o.events.options, t.pointerEvents.defaults), ee(o.events.options, s.pointerEvents || {});
|
|
3788
|
-
} } }, zs = Rs,
|
|
3789
|
-
n.usePlugin(
|
|
3790
|
-
} },
|
|
3788
|
+
} } }, zs = Rs, Ls = { id: "pointer-events", install: function(n) {
|
|
3789
|
+
n.usePlugin($s), n.usePlugin(Ms), n.usePlugin(zs);
|
|
3790
|
+
} }, Fs = Ls, Vs = { id: "reflow", install: function(n) {
|
|
3791
3791
|
var t = n.Interactable;
|
|
3792
3792
|
n.actions.phases.reflow = !0, t.prototype.reflow = function(o) {
|
|
3793
3793
|
return (function(s, l, f) {
|
|
3794
3794
|
for (var p = s.getAllElements(), h = f.window.Promise, v = h ? [] : null, N = function() {
|
|
3795
|
-
var O = p[y],
|
|
3796
|
-
if (!
|
|
3797
|
-
var V,
|
|
3795
|
+
var O = p[y], j = s.getRect(O);
|
|
3796
|
+
if (!j) return 1;
|
|
3797
|
+
var V, L = vt(f.interactions.list, (function(re) {
|
|
3798
3798
|
return re.interacting() && re.interactable === s && re.element === O && re.prepared.name === l.name;
|
|
3799
3799
|
}));
|
|
3800
|
-
if (
|
|
3801
|
-
|
|
3800
|
+
if (L) L.move(), v && (V = L._reflowPromise || new h((function(re) {
|
|
3801
|
+
L._reflowResolve = re;
|
|
3802
3802
|
})));
|
|
3803
3803
|
else {
|
|
3804
|
-
var
|
|
3804
|
+
var H = He(j), ie = /* @__PURE__ */ (function(re) {
|
|
3805
3805
|
return { coords: re, get page() {
|
|
3806
3806
|
return this.coords.page;
|
|
3807
3807
|
}, get client() {
|
|
@@ -3828,14 +3828,14 @@ function da() {
|
|
|
3828
3828
|
return this.coords.buttons;
|
|
3829
3829
|
}, preventDefault: function() {
|
|
3830
3830
|
} };
|
|
3831
|
-
})({ page: { x:
|
|
3831
|
+
})({ page: { x: H.x, y: H.y }, client: { x: H.x, y: H.y }, timeStamp: f.now() });
|
|
3832
3832
|
V = (function(re, le, ve, xe, de) {
|
|
3833
|
-
var ye = re.interactions.new({ pointerType: "reflow" }),
|
|
3834
|
-
ye.interactable = le, ye.element = ve, ye.prevEvent = de, ye.updatePointer(de, de, ve, !0), kr(ye.coords.delta), Gn(ye.prepared, xe), ye._doPhase(
|
|
3833
|
+
var ye = re.interactions.new({ pointerType: "reflow" }), Me = { interaction: ye, event: de, pointer: de, eventTarget: ve, phase: "reflow" };
|
|
3834
|
+
ye.interactable = le, ye.element = ve, ye.prevEvent = de, ye.updatePointer(de, de, ve, !0), kr(ye.coords.delta), Gn(ye.prepared, xe), ye._doPhase(Me);
|
|
3835
3835
|
var Pe = re.window, Ve = Pe.Promise, De = Ve ? new Ve((function(Ge) {
|
|
3836
3836
|
ye._reflowResolve = Ge;
|
|
3837
3837
|
})) : void 0;
|
|
3838
|
-
return ye._reflowPromise = De, ye.start(xe, le, ve), ye._interacting ? (ye.move(
|
|
3838
|
+
return ye._reflowPromise = De, ye.start(xe, le, ve), ye._interacting ? (ye.move(Me), ye.end(de)) : (ye.stop(), ye._reflowResolve()), ye.removePointer(de, de), De;
|
|
3839
3839
|
})(f, s, O, l, ie);
|
|
3840
3840
|
}
|
|
3841
3841
|
v && v.push(V);
|
|
@@ -3851,16 +3851,16 @@ function da() {
|
|
|
3851
3851
|
s.splice(s.indexOf(l), 1);
|
|
3852
3852
|
})(t.interactions.list, o));
|
|
3853
3853
|
} } }, Ds = Vs;
|
|
3854
|
-
if (
|
|
3855
|
-
e.exports =
|
|
3854
|
+
if (Ae.use(Jr), Ae.use(ro), Ae.use(Fs), Ae.use(os), Ae.use(Cs), Ae.use(Ui), Ae.use(Mi), Ae.use(zi), Ae.use(Ds), Ae.default = Ae, c(e) === "object" && e) try {
|
|
3855
|
+
e.exports = Ae;
|
|
3856
3856
|
} catch {
|
|
3857
3857
|
}
|
|
3858
|
-
return
|
|
3858
|
+
return Ae.default = Ae, Ae;
|
|
3859
3859
|
}));
|
|
3860
3860
|
})(en)), en.exports;
|
|
3861
3861
|
}
|
|
3862
3862
|
var pa = /* @__PURE__ */ da();
|
|
3863
|
-
const ha = /* @__PURE__ */
|
|
3863
|
+
const ha = /* @__PURE__ */ Bo(pa);
|
|
3864
3864
|
function We(e) {
|
|
3865
3865
|
return e == null ? "" : typeof e == "string" || typeof e == "number" || typeof e == "boolean" ? String(e) : typeof e == "function" ? e.toString() : e instanceof Date ? e.toISOString() : e instanceof RegExp ? e.toString() : e instanceof Map ? JSON.stringify(Array.from(e.entries())) : e instanceof Set ? JSON.stringify(Array.from(e.values())) : e instanceof WeakMap || e instanceof WeakSet ? "" : e instanceof ArrayBuffer ? e.toString() : Array.isArray(e) ? JSON.stringify(e.map(We)) : typeof e == "object" ? JSON.stringify(Object.entries(e).sort(([r], [i]) => r.localeCompare(i))) : "";
|
|
3866
3866
|
}
|
|
@@ -3872,7 +3872,7 @@ function ga(e, {
|
|
|
3872
3872
|
...u
|
|
3873
3873
|
}) {
|
|
3874
3874
|
const d = Se(i), g = Se(a), m = Se(c);
|
|
3875
|
-
|
|
3875
|
+
$e(() => {
|
|
3876
3876
|
if (!r) return;
|
|
3877
3877
|
const b = e.current;
|
|
3878
3878
|
if (!b) return;
|
|
@@ -3883,12 +3883,12 @@ function ga(e, {
|
|
|
3883
3883
|
const I = _e.make(_);
|
|
3884
3884
|
d.current?.(I);
|
|
3885
3885
|
},
|
|
3886
|
-
onmove: ({ client: _, clientX0: I, clientY0:
|
|
3887
|
-
const
|
|
3888
|
-
g.current?.(W, q,
|
|
3886
|
+
onmove: ({ client: _, clientX0: I, clientY0: $, dx: A, dy: S }) => {
|
|
3887
|
+
const C = _e.make(I, $), q = _e.make(_), W = _e.make(A, S);
|
|
3888
|
+
g.current?.(W, q, C);
|
|
3889
3889
|
},
|
|
3890
|
-
onend: ({ client: _, clientX0: I, clientY0:
|
|
3891
|
-
const A = _e.make(I,
|
|
3890
|
+
onend: ({ client: _, clientX0: I, clientY0: $ }) => {
|
|
3891
|
+
const A = _e.make(I, $), S = _e.make(_);
|
|
3892
3892
|
m.current?.(S, A);
|
|
3893
3893
|
}
|
|
3894
3894
|
});
|
|
@@ -3905,17 +3905,17 @@ function zt(e, {
|
|
|
3905
3905
|
onDragEnd: u,
|
|
3906
3906
|
...d
|
|
3907
3907
|
}) {
|
|
3908
|
-
const g = we(r), [m, b] = Oe(!1), [T, _] = Oe(!1), [I,
|
|
3908
|
+
const g = we(r), [m, b] = Oe(!1), [T, _] = Oe(!1), [I, $] = Oe(r), A = Se(a), S = Se(c), C = Se(u), q = Se(i);
|
|
3909
3909
|
return ga(e, {
|
|
3910
3910
|
onDragStart: (x) => {
|
|
3911
3911
|
b(!0), _(!1), A.current?.(x);
|
|
3912
3912
|
},
|
|
3913
3913
|
onDragMove: (x, P, E) => {
|
|
3914
3914
|
const M = q.current(g.current, x.x, x.y);
|
|
3915
|
-
_o(g, M) &&
|
|
3915
|
+
_o(g, M) && $(M), b(!0), _(!1), S.current?.(x, P, E);
|
|
3916
3916
|
},
|
|
3917
3917
|
onDragEnd: (x, P) => {
|
|
3918
|
-
b(!1), _(!0),
|
|
3918
|
+
b(!1), _(!0), C.current?.(x, P);
|
|
3919
3919
|
},
|
|
3920
3920
|
...d
|
|
3921
3921
|
}), Ee(() => {
|
|
@@ -3924,7 +3924,7 @@ function zt(e, {
|
|
|
3924
3924
|
isDragging: m,
|
|
3925
3925
|
isReleasing: T,
|
|
3926
3926
|
value: I,
|
|
3927
|
-
setValue:
|
|
3927
|
+
setValue: $
|
|
3928
3928
|
};
|
|
3929
3929
|
}
|
|
3930
3930
|
function _o(e, r) {
|
|
@@ -3944,8 +3944,8 @@ const ti = /* @__PURE__ */ Te(({
|
|
|
3944
3944
|
onLoadImageError: T,
|
|
3945
3945
|
onImageSizeChange: _,
|
|
3946
3946
|
...I
|
|
3947
|
-
},
|
|
3948
|
-
const A =
|
|
3947
|
+
}, $) => {
|
|
3948
|
+
const A = he((M, B, K) => M - B * r, [r]), S = we(null), C = nt(S), q = Go({ src: i }, {
|
|
3949
3949
|
onLoadStart: m,
|
|
3950
3950
|
onLoadComplete: b,
|
|
3951
3951
|
onLoadError: T
|
|
@@ -3957,13 +3957,13 @@ const ti = /* @__PURE__ */ Te(({
|
|
|
3957
3957
|
});
|
|
3958
3958
|
Ee(() => {
|
|
3959
3959
|
if (J || !q) return;
|
|
3960
|
-
const M = va(e, q, be.size(
|
|
3960
|
+
const M = va(e, q, be.size(C), a);
|
|
3961
3961
|
M !== x && P(M), e !== W && Y(e);
|
|
3962
|
-
}, [e, q,
|
|
3962
|
+
}, [e, q, C.width, C.height, a]), Ee(() => {
|
|
3963
3963
|
if (!J || !q) return;
|
|
3964
|
-
const M = ya(x, q, be.size(
|
|
3964
|
+
const M = ya(x, q, be.size(C), a);
|
|
3965
3965
|
W !== M && Y(M);
|
|
3966
|
-
}, [x, q,
|
|
3966
|
+
}, [x, q, C.width, C.height, a]), Ee(() => {
|
|
3967
3967
|
c?.(W, J), u?.(W / 360, J);
|
|
3968
3968
|
}, [W]), Ee(() => {
|
|
3969
3969
|
_?.(q);
|
|
@@ -3973,7 +3973,7 @@ const ti = /* @__PURE__ */ Te(({
|
|
|
3973
3973
|
"div",
|
|
3974
3974
|
{
|
|
3975
3975
|
...I,
|
|
3976
|
-
ref:
|
|
3976
|
+
ref: $,
|
|
3977
3977
|
"aria-valuenow": W,
|
|
3978
3978
|
role: "slider",
|
|
3979
3979
|
children: /* @__PURE__ */ w.jsx("div", { ref: S, style: E.body })
|
|
@@ -4024,36 +4024,36 @@ const ri = /* @__PURE__ */ Te(({
|
|
|
4024
4024
|
onAngleChange: T,
|
|
4025
4025
|
onDragEnd: _,
|
|
4026
4026
|
onDragStart: I,
|
|
4027
|
-
onLoadImageComplete:
|
|
4027
|
+
onLoadImageComplete: $,
|
|
4028
4028
|
onLoadImageError: A,
|
|
4029
4029
|
onLoadImageStart: S,
|
|
4030
|
-
onImageSizeChange:
|
|
4030
|
+
onImageSizeChange: C,
|
|
4031
4031
|
onPositionChange: q,
|
|
4032
4032
|
...W
|
|
4033
4033
|
}, Y) => {
|
|
4034
|
-
const J = we(null), x = nt(J), [P, E] = Oe(), [M,
|
|
4034
|
+
const J = we(null), x = nt(J), [P, E] = Oe(), [M, B] = Oe(!1), oe = he(() => {
|
|
4035
4035
|
if (!P) return 0;
|
|
4036
4036
|
const { width: R, height: k } = P;
|
|
4037
4037
|
return k === 0 ? 0 : R / k;
|
|
4038
|
-
}, [P?.width, P?.height])(), X =
|
|
4038
|
+
}, [P?.width, P?.height])(), X = he(() => {
|
|
4039
4039
|
const R = Math.min(360, Math.max(0, u ?? (m ? m.width / (m.height * oe) * 360 : 0)));
|
|
4040
4040
|
return x.width * (R / 360);
|
|
4041
|
-
}, [m?.width, m?.height, oe, x.width, u])(), z =
|
|
4042
|
-
|
|
4043
|
-
}, [I]), ne =
|
|
4044
|
-
|
|
4041
|
+
}, [m?.width, m?.height, oe, x.width, u])(), z = he(() => x.width <= 0 ? b : ((x.width - X) * 0.5 + b * X) / x.width, [x.width, X, b])(), te = he(() => {
|
|
4042
|
+
B(!0), I?.();
|
|
4043
|
+
}, [I]), ne = he(() => {
|
|
4044
|
+
B(!1), _?.();
|
|
4045
4045
|
}, [_]), ae = ze(c, {
|
|
4046
|
-
track:
|
|
4046
|
+
track: Ct,
|
|
4047
4047
|
reticle: an,
|
|
4048
4048
|
indicator: sn
|
|
4049
|
-
}),
|
|
4049
|
+
}), F = ba({ autoDimension: a, panoramaRect: x, aspectRatio: oe, reticleWidth: X });
|
|
4050
4050
|
return /* @__PURE__ */ w.jsxs(
|
|
4051
4051
|
"div",
|
|
4052
4052
|
{
|
|
4053
4053
|
...W,
|
|
4054
4054
|
ref: Y,
|
|
4055
4055
|
className: se(e, { dragging: M }),
|
|
4056
|
-
style: ce(r,
|
|
4056
|
+
style: ce(r, F.root),
|
|
4057
4057
|
children: [
|
|
4058
4058
|
/* @__PURE__ */ w.jsx(
|
|
4059
4059
|
ti,
|
|
@@ -4062,28 +4062,28 @@ const ri = /* @__PURE__ */ Te(({
|
|
|
4062
4062
|
angle: i,
|
|
4063
4063
|
speed: d,
|
|
4064
4064
|
src: g,
|
|
4065
|
-
style:
|
|
4065
|
+
style: F.panorama,
|
|
4066
4066
|
zeroAnchor: z,
|
|
4067
4067
|
onAngleChange: T,
|
|
4068
4068
|
onDragEnd: ne,
|
|
4069
4069
|
onDragStart: te,
|
|
4070
4070
|
onImageSizeChange: E,
|
|
4071
|
-
onLoadImageComplete:
|
|
4071
|
+
onLoadImageComplete: $,
|
|
4072
4072
|
onLoadImageError: A,
|
|
4073
4073
|
onLoadImageStart: S,
|
|
4074
4074
|
onPositionChange: q
|
|
4075
4075
|
}
|
|
4076
4076
|
),
|
|
4077
|
-
/* @__PURE__ */ w.jsx("div", { style:
|
|
4078
|
-
/* @__PURE__ */ w.jsx(
|
|
4079
|
-
/* @__PURE__ */ w.jsx(
|
|
4080
|
-
/* @__PURE__ */ w.jsx(
|
|
4077
|
+
/* @__PURE__ */ w.jsx("div", { style: F.body, children: /* @__PURE__ */ w.jsxs("div", { style: F.controls, children: [
|
|
4078
|
+
/* @__PURE__ */ w.jsx(me, { className: se({ dragging: M }), element: ae.track ?? /* @__PURE__ */ w.jsx(Ct, {}), style: F.track }),
|
|
4079
|
+
/* @__PURE__ */ w.jsx(me, { className: se({ dragging: M }), element: ae.reticle ?? /* @__PURE__ */ w.jsx(an, {}), style: F.reticle }),
|
|
4080
|
+
/* @__PURE__ */ w.jsx(me, { className: se({ dragging: M }), element: ae.track ?? /* @__PURE__ */ w.jsx(Ct, {}), style: F.track })
|
|
4081
4081
|
] }) }),
|
|
4082
|
-
/* @__PURE__ */ w.jsx(
|
|
4082
|
+
/* @__PURE__ */ w.jsx(me, { className: se({ dragging: M }), element: ae.indicator ?? /* @__PURE__ */ w.jsx(sn, {}), style: F.indicator })
|
|
4083
4083
|
]
|
|
4084
4084
|
}
|
|
4085
4085
|
);
|
|
4086
|
-
}), sn = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), an = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }),
|
|
4086
|
+
}), sn = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), an = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), Ct = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), Fl = /* @__PURE__ */ Object.assign(ri, {
|
|
4087
4087
|
/**
|
|
4088
4088
|
* Component for the active indicator of a {@link PanoramaSlider}.
|
|
4089
4089
|
*/
|
|
@@ -4095,7 +4095,7 @@ const ri = /* @__PURE__ */ Te(({
|
|
|
4095
4095
|
/**
|
|
4096
4096
|
* Component for the slide track of a {@link PanoramaSlider}.
|
|
4097
4097
|
*/
|
|
4098
|
-
Track:
|
|
4098
|
+
Track: Ct
|
|
4099
4099
|
});
|
|
4100
4100
|
function ba({ autoDimension: e = "width", panoramaRect: r = be.zero, aspectRatio: i = 0, reticleWidth: a = 0 }) {
|
|
4101
4101
|
return {
|
|
@@ -4141,7 +4141,7 @@ function ba({ autoDimension: e = "width", panoramaRect: r = be.zero, aspectRatio
|
|
|
4141
4141
|
}
|
|
4142
4142
|
};
|
|
4143
4143
|
}
|
|
4144
|
-
process.env.NODE_ENV === "development" && (ri.displayName = "PanoramaSlider", sn.displayName = "PanoramaSlider.Indicator", an.displayName = "PanoramaSlider.Reticle",
|
|
4144
|
+
process.env.NODE_ENV === "development" && (ri.displayName = "PanoramaSlider", sn.displayName = "PanoramaSlider.Indicator", an.displayName = "PanoramaSlider.Reticle", Ct.displayName = "PanoramaSlider.Track");
|
|
4145
4145
|
const xa = /* @__PURE__ */ Te(({
|
|
4146
4146
|
children: e,
|
|
4147
4147
|
className: r,
|
|
@@ -4201,7 +4201,7 @@ function oi({
|
|
|
4201
4201
|
children: e,
|
|
4202
4202
|
condition: r
|
|
4203
4203
|
}) {
|
|
4204
|
-
const i =
|
|
4204
|
+
const i = jn.toArray(e);
|
|
4205
4205
|
if (i.length === 0)
|
|
4206
4206
|
return console.error("[etudes::Switch] `Switch` must have at least one child"), /* @__PURE__ */ w.jsx(w.Fragment, {});
|
|
4207
4207
|
if (!Ea(i))
|
|
@@ -4246,7 +4246,7 @@ process.env.NODE_ENV === "development" && (oi.displayName = "Switch", wr.display
|
|
|
4246
4246
|
const ii = /* @__PURE__ */ Te(({
|
|
4247
4247
|
children: e,
|
|
4248
4248
|
...r
|
|
4249
|
-
}, i) => (Array.isArray(e) && console.error(`[etudes::ExtractChild] Only one child is expected, but found ${e.length}. Only the first child is extracted while the rest are discarded.`),
|
|
4249
|
+
}, i) => (Array.isArray(e) && console.error(`[etudes::ExtractChild] Only one child is expected, but found ${e.length}. Only the first child is extracted while the rest are discarded.`), jn.map(e, (a, c) => {
|
|
4250
4250
|
if (!(c > 0))
|
|
4251
4251
|
return An(a) ? gr(a, { ...r, ref: i }) : a;
|
|
4252
4252
|
})));
|
|
@@ -4263,24 +4263,24 @@ function Na({
|
|
|
4263
4263
|
maxWidth: m = 200,
|
|
4264
4264
|
threshold: b = 100
|
|
4265
4265
|
}) {
|
|
4266
|
-
const T = we(null), _ = we(void 0), I = nt(T),
|
|
4267
|
-
const
|
|
4268
|
-
|
|
4269
|
-
const q = a ?? (T.current ? _a(T.current, b) : "tl"), W = Sa(
|
|
4270
|
-
Object.keys(J).forEach((P) =>
|
|
4266
|
+
const T = we(null), _ = we(void 0), I = nt(T), $ = he(() => {
|
|
4267
|
+
const C = window.document.createElement("span");
|
|
4268
|
+
C.className = se(r), C.innerHTML = g, C.role = "tooltip";
|
|
4269
|
+
const q = a ?? (T.current ? _a(T.current, b) : "tl"), W = Sa(C), Y = Pa({ alignment: q, arrowSize: je.make(u, c), gap: d, maxDialogWidth: m, fullDialogWidth: W.width, targetWidth: I.width }), J = ce(i, Y.dialog);
|
|
4270
|
+
Object.keys(J).forEach((P) => C.style[P] = J[P]);
|
|
4271
4271
|
const x = window.document.createElement("span");
|
|
4272
|
-
return Object.keys(Y.arrow).forEach((P) => x.style[P] = Y.arrow[P]),
|
|
4273
|
-
}, [r, a, g, m, We(i), I.width, b, c, u, d]), A =
|
|
4272
|
+
return Object.keys(Y.arrow).forEach((P) => x.style[P] = Y.arrow[P]), C.appendChild(x), C;
|
|
4273
|
+
}, [r, a, g, m, We(i), I.width, b, c, u, d]), A = he(() => {
|
|
4274
4274
|
_.current && (_.current.style.opacity = "1", _.current.ariaHidden = "false");
|
|
4275
|
-
}, []), S =
|
|
4275
|
+
}, []), S = he(() => {
|
|
4276
4276
|
_.current && (_.current.style.opacity = "0", _.current.ariaHidden = "true");
|
|
4277
4277
|
}, []);
|
|
4278
4278
|
return Ee(() => {
|
|
4279
|
-
const
|
|
4280
|
-
return T.current?.appendChild(
|
|
4281
|
-
T.current?.removeChild(
|
|
4279
|
+
const C = $();
|
|
4280
|
+
return T.current?.appendChild(C), _.current = C, () => {
|
|
4281
|
+
T.current?.removeChild(C), _.current = void 0;
|
|
4282
4282
|
};
|
|
4283
|
-
}, [
|
|
4283
|
+
}, [$]), /* @__PURE__ */ w.jsx(
|
|
4284
4284
|
ii,
|
|
4285
4285
|
{
|
|
4286
4286
|
ref: T,
|
|
@@ -4490,8 +4490,8 @@ function Dl() {
|
|
|
4490
4490
|
}
|
|
4491
4491
|
}, [e]);
|
|
4492
4492
|
}
|
|
4493
|
-
function
|
|
4494
|
-
|
|
4493
|
+
function Bl(e, { element: r, isEnabled: i = !0 } = {}) {
|
|
4494
|
+
$e(() => {
|
|
4495
4495
|
if (!i) return;
|
|
4496
4496
|
const a = r ?? window.document.documentElement, c = a.className;
|
|
4497
4497
|
return a.classList.add(e), () => {
|
|
@@ -4499,9 +4499,9 @@ function Hl(e, { element: r, isEnabled: i = !0 } = {}) {
|
|
|
4499
4499
|
};
|
|
4500
4500
|
}, [e, r, i]);
|
|
4501
4501
|
}
|
|
4502
|
-
function
|
|
4502
|
+
function Hl(e, r) {
|
|
4503
4503
|
const i = Se(r);
|
|
4504
|
-
|
|
4504
|
+
$e(() => {
|
|
4505
4505
|
const a = (c) => {
|
|
4506
4506
|
if (!(c.target instanceof Node)) return;
|
|
4507
4507
|
let u = !0, d = c.target;
|
|
@@ -4521,10 +4521,26 @@ function Bl(e, r) {
|
|
|
4521
4521
|
};
|
|
4522
4522
|
}, []);
|
|
4523
4523
|
}
|
|
4524
|
+
function Yl() {
|
|
4525
|
+
return he(async (e) => {
|
|
4526
|
+
const r = e.type, i = new ClipboardItem({ [r]: e });
|
|
4527
|
+
try {
|
|
4528
|
+
await navigator.clipboard.write([i]);
|
|
4529
|
+
} catch (a) {
|
|
4530
|
+
console.error("[etudes::useCopyBlobToClipboard] Failed to copy blob to clipboard:", a);
|
|
4531
|
+
}
|
|
4532
|
+
}, []);
|
|
4533
|
+
}
|
|
4534
|
+
function Xl() {
|
|
4535
|
+
return he((e, r) => {
|
|
4536
|
+
const i = URL.createObjectURL(e), a = document.createElement("a");
|
|
4537
|
+
a.href = i, a.download = r, document.body.appendChild(a), a.click(), document.body.removeChild(a), URL.revokeObjectURL(i);
|
|
4538
|
+
}, []);
|
|
4539
|
+
}
|
|
4524
4540
|
function Ia() {
|
|
4525
4541
|
return typeof window > "u" ? 1 : window.devicePixelRatio || 1;
|
|
4526
4542
|
}
|
|
4527
|
-
function
|
|
4543
|
+
function Ul() {
|
|
4528
4544
|
return pt(() => Ia(), []);
|
|
4529
4545
|
}
|
|
4530
4546
|
function ka(e, {
|
|
@@ -4534,43 +4550,43 @@ function ka(e, {
|
|
|
4534
4550
|
onDragMove: c,
|
|
4535
4551
|
onDragEnd: u
|
|
4536
4552
|
}) {
|
|
4537
|
-
const d = we(void 0), g = we(void 0), m = Se(a), b = Se(c), T = Se(u), _ =
|
|
4553
|
+
const d = we(void 0), g = we(void 0), m = Se(a), b = Se(c), T = Se(u), _ = he((A) => {
|
|
4538
4554
|
if (!d.current) return;
|
|
4539
|
-
const S = _e.make(A.clientX, A.clientY),
|
|
4540
|
-
g.current = S, b.current?.(
|
|
4541
|
-
}, []), I =
|
|
4555
|
+
const S = _e.make(A.clientX, A.clientY), C = _e.subtract(S, g.current ?? d.current);
|
|
4556
|
+
g.current = S, b.current?.(C, S, d.current);
|
|
4557
|
+
}, []), I = he((A) => {
|
|
4542
4558
|
const S = e.current;
|
|
4543
4559
|
if (!S || !d.current) return;
|
|
4544
|
-
const
|
|
4545
|
-
T.current?.(
|
|
4546
|
-
}, [i, _]),
|
|
4560
|
+
const C = _e.make(A.clientX, A.clientY), q = _e.subtract(g.current ?? d.current, C);
|
|
4561
|
+
T.current?.(C, q, d.current), d.current = void 0, g.current = void 0, S.removeEventListener("mousemove", _), S.removeEventListener("mouseup", I, { capture: !0 }), S.removeEventListener("mouseleave", I), i && (S.style.cursor = "grab");
|
|
4562
|
+
}, [i, _]), $ = he((A) => {
|
|
4547
4563
|
const S = e.current;
|
|
4548
4564
|
if (!S) return;
|
|
4549
4565
|
A.preventDefault();
|
|
4550
|
-
const
|
|
4551
|
-
d.current =
|
|
4566
|
+
const C = _e.make(A.clientX, A.clientY);
|
|
4567
|
+
d.current = C, g.current = C, S.addEventListener("mousemove", _), S.addEventListener("mouseup", I, { capture: !0 }), S.addEventListener("mouseleave", I), i && (S.style.cursor = "grabbing"), m.current?.(C);
|
|
4552
4568
|
}, [i, _, I]);
|
|
4553
|
-
|
|
4569
|
+
$e(() => {
|
|
4554
4570
|
const A = e.current;
|
|
4555
4571
|
if (!A || !r || !i) return;
|
|
4556
4572
|
const S = A.style.cursor;
|
|
4557
4573
|
return A.style.cursor = "grab", () => {
|
|
4558
4574
|
A.style.cursor = S;
|
|
4559
4575
|
};
|
|
4560
|
-
}, [r, i]),
|
|
4576
|
+
}, [r, i]), $e(() => {
|
|
4561
4577
|
const A = e.current;
|
|
4562
4578
|
if (!(!A || !r))
|
|
4563
|
-
return A.addEventListener("mousedown",
|
|
4564
|
-
A.removeEventListener("mousedown",
|
|
4579
|
+
return A.addEventListener("mousedown", $), () => {
|
|
4580
|
+
A.removeEventListener("mousedown", $), A.removeEventListener("mousemove", _), A.removeEventListener("mouseup", I, { capture: !0 }), A.removeEventListener("mouseleave", I);
|
|
4565
4581
|
};
|
|
4566
|
-
}, [r, _, I,
|
|
4582
|
+
}, [r, _, I, $]);
|
|
4567
4583
|
}
|
|
4568
|
-
function
|
|
4569
|
-
const [r, i] = Oe(!1), a =
|
|
4584
|
+
function Kl(e) {
|
|
4585
|
+
const [r, i] = Oe(!1), a = he((d) => {
|
|
4570
4586
|
d.preventDefault(), d.stopPropagation(), i(!0);
|
|
4571
|
-
}, []), c =
|
|
4587
|
+
}, []), c = he((d) => {
|
|
4572
4588
|
d.preventDefault(), d.stopPropagation(), i(!1);
|
|
4573
|
-
}, []), u =
|
|
4589
|
+
}, []), u = he((d) => {
|
|
4574
4590
|
d.preventDefault(), d.stopPropagation(), i(!1);
|
|
4575
4591
|
const g = d.dataTransfer.files;
|
|
4576
4592
|
if (g && g.length > 0) {
|
|
@@ -4585,33 +4601,33 @@ function Xl(e) {
|
|
|
4585
4601
|
onDrop: u
|
|
4586
4602
|
};
|
|
4587
4603
|
}
|
|
4588
|
-
function
|
|
4604
|
+
function Ca(e, {
|
|
4589
4605
|
autoStarts: r = !0,
|
|
4590
4606
|
shouldInvokeInitially: i = !1,
|
|
4591
4607
|
onInterval: a
|
|
4592
4608
|
}, c = []) {
|
|
4593
|
-
const u = we(void 0), d = Se(a), g =
|
|
4609
|
+
const u = we(void 0), d = Se(a), g = he(() => {
|
|
4594
4610
|
clearInterval(u.current), u.current = void 0;
|
|
4595
|
-
}, []), m =
|
|
4611
|
+
}, []), m = he(() => {
|
|
4596
4612
|
g(), !(e < 0) && (i && d.current(), u.current = setInterval(() => {
|
|
4597
4613
|
d.current();
|
|
4598
4614
|
}, e));
|
|
4599
4615
|
}, [e, i, g]);
|
|
4600
4616
|
return Ee(() => (r && e > 0 && m(), g), [r, e, m, g, ...c]), { start: m, stop: g };
|
|
4601
4617
|
}
|
|
4602
|
-
function
|
|
4618
|
+
function Gl() {
|
|
4603
4619
|
const [e, r] = Oe(!1);
|
|
4604
4620
|
return Ee(() => (r(!0), () => {
|
|
4605
4621
|
r(!1);
|
|
4606
4622
|
}), []), e;
|
|
4607
4623
|
}
|
|
4608
|
-
function
|
|
4624
|
+
function $a() {
|
|
4609
4625
|
return typeof window > "u" ? !1 : !!(typeof window.navigator < "u" && (window.navigator.maxTouchPoints > 0 || "msMaxTouchPoints" in window.navigator && window.navigator.msMaxTouchPoints > 0) || window.matchMedia("(pointer: coarse)").matches || window.matchMedia("(hover: none)").matches || "ontouchstart" in window || "ontouchstart" in window.document.documentElement);
|
|
4610
4626
|
}
|
|
4611
|
-
function
|
|
4612
|
-
return pt(() =>
|
|
4627
|
+
function ja() {
|
|
4628
|
+
return pt(() => $a(), []);
|
|
4613
4629
|
}
|
|
4614
|
-
function
|
|
4630
|
+
function ql(e, r, {
|
|
4615
4631
|
isEnabled: i = !0,
|
|
4616
4632
|
preventDefault: a = !0,
|
|
4617
4633
|
capture: c = !0,
|
|
@@ -4671,14 +4687,14 @@ function za(e, r, i) {
|
|
|
4671
4687
|
};
|
|
4672
4688
|
return Er?.setItem(r, JSON.stringify(a)), e;
|
|
4673
4689
|
}
|
|
4674
|
-
function
|
|
4690
|
+
function Wl(e) {
|
|
4675
4691
|
return pt(() => Aa({ defaultTTL: e }), [e]);
|
|
4676
4692
|
}
|
|
4677
|
-
function
|
|
4693
|
+
function Jl(e, r = []) {
|
|
4678
4694
|
const i = Se(e), a = we(void 0), c = we(!1);
|
|
4679
|
-
|
|
4695
|
+
$e(() => {
|
|
4680
4696
|
const u = () => {
|
|
4681
|
-
const g =
|
|
4697
|
+
const g = La();
|
|
4682
4698
|
g && (i.current(g, a.current), a.current = g);
|
|
4683
4699
|
}, d = () => {
|
|
4684
4700
|
c.current || typeof requestAnimationFrame == "function" && (c.current = !0, requestAnimationFrame(() => {
|
|
@@ -4690,7 +4706,7 @@ function ql(e, r = []) {
|
|
|
4690
4706
|
};
|
|
4691
4707
|
}, [...r]);
|
|
4692
4708
|
}
|
|
4693
|
-
function
|
|
4709
|
+
function La() {
|
|
4694
4710
|
const e = be.fromViewport(), r = be.clone(e, { x: 0, y: 0 }), i = be.from(window, { overflow: !0 });
|
|
4695
4711
|
if (!i) return;
|
|
4696
4712
|
const a = be.clone(r, { x: i.width - e.width, y: i.height - e.height }), c = _e.make(e.left / a.left, e.top / a.top);
|
|
@@ -4701,7 +4717,7 @@ function Fa() {
|
|
|
4701
4717
|
step: c
|
|
4702
4718
|
};
|
|
4703
4719
|
}
|
|
4704
|
-
function
|
|
4720
|
+
function Fa(e) {
|
|
4705
4721
|
const r = we(void 0);
|
|
4706
4722
|
return Ee(() => {
|
|
4707
4723
|
r.current = e;
|
|
@@ -4710,9 +4726,9 @@ function La(e) {
|
|
|
4710
4726
|
const Nr = typeof window < "u" ? window.sessionStorage : void 0;
|
|
4711
4727
|
function Va({ defaultTTL: e = 300 } = {}) {
|
|
4712
4728
|
return {
|
|
4713
|
-
get:
|
|
4729
|
+
get: Ba,
|
|
4714
4730
|
invalidate: ai,
|
|
4715
|
-
set: (r, i, a = e) =>
|
|
4731
|
+
set: (r, i, a = e) => Ha(r, i, a)
|
|
4716
4732
|
};
|
|
4717
4733
|
}
|
|
4718
4734
|
function ai(e) {
|
|
@@ -4722,7 +4738,7 @@ function Da(e) {
|
|
|
4722
4738
|
const { timestamp: r, ttl: i } = e;
|
|
4723
4739
|
return (Date.now() - r) / 1e3 >= i;
|
|
4724
4740
|
}
|
|
4725
|
-
function
|
|
4741
|
+
function Ba(e) {
|
|
4726
4742
|
const r = Nr?.getItem(e);
|
|
4727
4743
|
if (!r) return;
|
|
4728
4744
|
const i = JSON.parse(r);
|
|
@@ -4733,7 +4749,7 @@ function Ha(e) {
|
|
|
4733
4749
|
} else
|
|
4734
4750
|
return i.value;
|
|
4735
4751
|
}
|
|
4736
|
-
function
|
|
4752
|
+
function Ha(e, r, i) {
|
|
4737
4753
|
const a = {
|
|
4738
4754
|
value: e,
|
|
4739
4755
|
timestamp: Date.now(),
|
|
@@ -4741,7 +4757,7 @@ function Ba(e, r, i) {
|
|
|
4741
4757
|
};
|
|
4742
4758
|
return Nr?.setItem(r, JSON.stringify(a)), e;
|
|
4743
4759
|
}
|
|
4744
|
-
function
|
|
4760
|
+
function Zl(e) {
|
|
4745
4761
|
return pt(() => Va({ defaultTTL: e }), [e]);
|
|
4746
4762
|
}
|
|
4747
4763
|
function ci(e) {
|
|
@@ -4763,8 +4779,8 @@ function To(e, r, { element: i } = {}) {
|
|
|
4763
4779
|
const a = i ?? window.document.documentElement;
|
|
4764
4780
|
r === void 0 ? a.style.removeProperty(e) : a.style.setProperty(e, r);
|
|
4765
4781
|
}
|
|
4766
|
-
function
|
|
4767
|
-
|
|
4782
|
+
function Ql(e, r, { element: i, isEnabled: a = !0 } = {}) {
|
|
4783
|
+
$e(() => {
|
|
4768
4784
|
if (!a) return;
|
|
4769
4785
|
const c = i ?? window.document.documentElement, u = Ya(e, { element: c, computed: !1 });
|
|
4770
4786
|
return To(e, r, { element: c }), () => {
|
|
@@ -4772,13 +4788,25 @@ function Jl(e, r, { element: i, isEnabled: a = !0 } = {}) {
|
|
|
4772
4788
|
};
|
|
4773
4789
|
}, [e, r, i, a]);
|
|
4774
4790
|
}
|
|
4775
|
-
function
|
|
4791
|
+
function eu(e = "light") {
|
|
4792
|
+
const [r, i] = Oe(e);
|
|
4793
|
+
return $e(() => {
|
|
4794
|
+
const a = window.matchMedia("(prefers-color-scheme: dark)");
|
|
4795
|
+
function c(u) {
|
|
4796
|
+
i(u.matches ? "dark" : "light");
|
|
4797
|
+
}
|
|
4798
|
+
return i(a.matches ? "dark" : "light"), a.addEventListener("change", c), () => {
|
|
4799
|
+
a.removeEventListener("change", c);
|
|
4800
|
+
};
|
|
4801
|
+
}, []), r;
|
|
4802
|
+
}
|
|
4803
|
+
function tu(e, {
|
|
4776
4804
|
autoStarts: r = !0,
|
|
4777
4805
|
onTimeout: i
|
|
4778
4806
|
}, a = []) {
|
|
4779
|
-
const c = we(void 0), u = Se(i), d =
|
|
4807
|
+
const c = we(void 0), u = Se(i), d = he(() => {
|
|
4780
4808
|
c.current !== void 0 && (clearTimeout(c.current), c.current = void 0);
|
|
4781
|
-
}, []), g =
|
|
4809
|
+
}, []), g = he(() => {
|
|
4782
4810
|
d(), !(e < 0) && (c.current = setTimeout(() => {
|
|
4783
4811
|
d(), u.current();
|
|
4784
4812
|
}, e));
|
|
@@ -4799,15 +4827,15 @@ const li = /* @__PURE__ */ Te(({
|
|
|
4799
4827
|
selection: T,
|
|
4800
4828
|
selectionMode: _ = "none",
|
|
4801
4829
|
onActivateAt: I,
|
|
4802
|
-
onDeselectAt:
|
|
4830
|
+
onDeselectAt: $,
|
|
4803
4831
|
onCustomEvent: A,
|
|
4804
4832
|
onSelectAt: S,
|
|
4805
|
-
onSelectionChange:
|
|
4833
|
+
onSelectionChange: C,
|
|
4806
4834
|
ItemComponent: q,
|
|
4807
4835
|
...W
|
|
4808
4836
|
}, Y) => {
|
|
4809
4837
|
const J = Ua(T ?? [], d), x = Ka({ itemLength: c, itemPadding: u, layout: g, numSegments: m, orientation: b }), P = (X) => J.indexOf(X) >= 0, E = (X) => {
|
|
4810
|
-
P(X) ?
|
|
4838
|
+
P(X) ? B(X) : M(X);
|
|
4811
4839
|
}, M = (X) => {
|
|
4812
4840
|
if (P(X)) return;
|
|
4813
4841
|
let D;
|
|
@@ -4825,7 +4853,7 @@ const li = /* @__PURE__ */ Te(({
|
|
|
4825
4853
|
}
|
|
4826
4854
|
const z = J, te = D(J);
|
|
4827
4855
|
oe(z, te);
|
|
4828
|
-
},
|
|
4856
|
+
}, B = (X) => {
|
|
4829
4857
|
if (!P(X)) return;
|
|
4830
4858
|
const D = (ne) => ne.filter((ae) => ae !== X), z = J, te = D(J);
|
|
4831
4859
|
oe(z, te);
|
|
@@ -4834,7 +4862,7 @@ const li = /* @__PURE__ */ Te(({
|
|
|
4834
4862
|
}, oe = (X, D) => {
|
|
4835
4863
|
if (qe(X, D)) return;
|
|
4836
4864
|
const z = X?.filter((ne) => D.indexOf(ne) === -1) ?? [], te = D.filter((ne) => X?.indexOf(ne) === -1);
|
|
4837
|
-
z.forEach((ne) =>
|
|
4865
|
+
z.forEach((ne) => $?.(ne)), te.forEach((ne) => S?.(ne)), C?.(D);
|
|
4838
4866
|
};
|
|
4839
4867
|
Ee(() => {
|
|
4840
4868
|
const X = J;
|
|
@@ -4889,10 +4917,10 @@ const li = /* @__PURE__ */ Te(({
|
|
|
4889
4917
|
role: z,
|
|
4890
4918
|
style: ne,
|
|
4891
4919
|
onClick: () => K(D),
|
|
4892
|
-
onCustomEvent: (ae,
|
|
4920
|
+
onCustomEvent: (ae, F) => A?.(D, ae, F)
|
|
4893
4921
|
}
|
|
4894
4922
|
) : /* @__PURE__ */ w.jsx(
|
|
4895
|
-
|
|
4923
|
+
me,
|
|
4896
4924
|
{
|
|
4897
4925
|
"aria-selected": te,
|
|
4898
4926
|
className: se({ active: te }),
|
|
@@ -4978,31 +5006,31 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
4978
5006
|
onCollapseSectionAt: T,
|
|
4979
5007
|
onDeselectAt: _,
|
|
4980
5008
|
onExpandedSectionsChange: I,
|
|
4981
|
-
onExpandSectionAt:
|
|
5009
|
+
onExpandSectionAt: $,
|
|
4982
5010
|
onHeaderCustomEvent: A,
|
|
4983
5011
|
onItemCustomEvent: S,
|
|
4984
|
-
onSelectAt:
|
|
5012
|
+
onSelectAt: C,
|
|
4985
5013
|
onSelectionChange: q,
|
|
4986
5014
|
HeaderComponent: W,
|
|
4987
5015
|
ItemComponent: Y,
|
|
4988
5016
|
...J
|
|
4989
5017
|
}, x) => {
|
|
4990
|
-
const P = Wa(g ?? {}, d), E = qa(a ?? [], d), M = Ja({ orientation: c }),
|
|
5018
|
+
const P = Wa(g ?? {}, d), E = qa(a ?? [], d), M = Ja({ orientation: c }), B = d.map(() => we(null)), K = B.map((F) => ci(F)), oe = (F, R) => (P[R]?.indexOf(F) ?? -1) >= 0, Q = (F) => E.indexOf(F) >= 0, X = (F) => {
|
|
4991
5019
|
let R;
|
|
4992
|
-
Q(
|
|
4993
|
-
}, D = (
|
|
4994
|
-
if (oe(
|
|
5020
|
+
Q(F) ? R = (k) => k.filter((U) => U !== F) : i ? R = (k) => [F] : R = (k) => [...k.filter((U) => U !== F), F], te(E, R(E));
|
|
5021
|
+
}, D = (F, R) => {
|
|
5022
|
+
if (oe(F, R)) return;
|
|
4995
5023
|
let k;
|
|
4996
5024
|
switch (m) {
|
|
4997
5025
|
case "multiple":
|
|
4998
5026
|
k = (Z) => ({
|
|
4999
5027
|
...Z,
|
|
5000
|
-
[R]: fn([...(Z[R] ?? []).filter((G) => G !==
|
|
5028
|
+
[R]: fn([...(Z[R] ?? []).filter((G) => G !== F), F])
|
|
5001
5029
|
});
|
|
5002
5030
|
break;
|
|
5003
5031
|
case "single":
|
|
5004
5032
|
k = (Z) => ({
|
|
5005
|
-
[R]: [
|
|
5033
|
+
[R]: [F]
|
|
5006
5034
|
});
|
|
5007
5035
|
break;
|
|
5008
5036
|
default:
|
|
@@ -5010,26 +5038,26 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5010
5038
|
}
|
|
5011
5039
|
const U = k(P);
|
|
5012
5040
|
ne(P, U);
|
|
5013
|
-
}, z = (
|
|
5014
|
-
if (!oe(
|
|
5041
|
+
}, z = (F, R) => {
|
|
5042
|
+
if (!oe(F, R)) return;
|
|
5015
5043
|
const U = ((Z) => ({
|
|
5016
5044
|
...Z,
|
|
5017
|
-
[R]: (Z[R] ?? []).filter((G) => G !==
|
|
5045
|
+
[R]: (Z[R] ?? []).filter((G) => G !== F)
|
|
5018
5046
|
}))(P);
|
|
5019
5047
|
ne(P, U);
|
|
5020
|
-
}, te = (
|
|
5021
|
-
if (qe(
|
|
5022
|
-
const k =
|
|
5023
|
-
k.forEach((Z) => T?.(Z)), U.forEach((Z) =>
|
|
5024
|
-
}, ne = (
|
|
5025
|
-
if (qe(
|
|
5048
|
+
}, te = (F, R) => {
|
|
5049
|
+
if (qe(F, R)) return;
|
|
5050
|
+
const k = F?.filter((Z) => R.indexOf(Z) === -1) ?? [], U = R.filter((Z) => F?.indexOf(Z) === -1);
|
|
5051
|
+
k.forEach((Z) => T?.(Z)), U.forEach((Z) => $?.(Z)), I?.(R);
|
|
5052
|
+
}, ne = (F, R) => {
|
|
5053
|
+
if (qe(F, R)) return;
|
|
5026
5054
|
const k = d.length;
|
|
5027
5055
|
let U = [], Z = [];
|
|
5028
5056
|
for (let G = 0; G < k; G++) {
|
|
5029
|
-
const fe =
|
|
5057
|
+
const fe = F?.[G] ?? [], ge = R[G] ?? [], ue = fe.filter((ee) => ge.indexOf(ee) === -1), Ne = ge.filter((ee) => fe?.indexOf(ee) === -1);
|
|
5030
5058
|
U = [...U, ...ue.map((ee) => [ee, G])], Z = [...Z, ...Ne.map((ee) => [ee, G])];
|
|
5031
5059
|
}
|
|
5032
|
-
U.forEach((G) => _?.(G[0], G[1])), Z.forEach((G) =>
|
|
5060
|
+
U.forEach((G) => _?.(G[0], G[1])), Z.forEach((G) => C?.(G[0], G[1])), q?.(R);
|
|
5033
5061
|
}, ae = ze(e, {
|
|
5034
5062
|
collapseIcon: _r,
|
|
5035
5063
|
expandIcon: Sr,
|
|
@@ -5037,23 +5065,23 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5037
5065
|
item: un,
|
|
5038
5066
|
section: dr
|
|
5039
5067
|
});
|
|
5040
|
-
return /* @__PURE__ */ w.jsx("div", { ...J, ref: x, style: ce(r, M.root), children: /* @__PURE__ */ w.jsx(Mn, { in: d, children: (
|
|
5041
|
-
const { collectionPadding: k = 0, items: U = [], itemLength: Z = 50, itemPadding: G = 0, isSelectionTogglable: fe, layout:
|
|
5068
|
+
return /* @__PURE__ */ w.jsx("div", { ...J, ref: x, style: ce(r, M.root), children: /* @__PURE__ */ w.jsx(Mn, { in: d, children: (F, R) => {
|
|
5069
|
+
const { collectionPadding: k = 0, items: U = [], itemLength: Z = 50, itemPadding: G = 0, isSelectionTogglable: fe, layout: ge = "list", maxVisible: ue = -1, numSegments: Ne = 1 } = F, ee = ge === "list" ? U.length : Math.ceil(U.length / Ne), Be = ue < 0 ? ee : Math.min(ee, ue), Ce = Z * Be + G * (Be - 1), Ie = !Q(R), He = K[R];
|
|
5042
5070
|
return /* @__PURE__ */ w.jsxs(
|
|
5043
|
-
|
|
5071
|
+
me,
|
|
5044
5072
|
{
|
|
5045
5073
|
element: ae.section ?? /* @__PURE__ */ w.jsx(dr, {}),
|
|
5046
5074
|
style: ce(M.section, c === "vertical" ? {
|
|
5047
5075
|
marginTop: R === 0 ? "0px" : `${u}px`,
|
|
5048
|
-
...
|
|
5049
|
-
height: Ie ? `${
|
|
5076
|
+
...He.height > 0 ? {
|
|
5077
|
+
height: Ie ? `${He.height}px` : `${Ce + He.height + k}px`
|
|
5050
5078
|
} : {
|
|
5051
5079
|
visibility: "hidden"
|
|
5052
5080
|
}
|
|
5053
5081
|
} : {
|
|
5054
5082
|
marginLeft: R === 0 ? "0px" : `${u}px`,
|
|
5055
|
-
...
|
|
5056
|
-
width: Ie ? `${
|
|
5083
|
+
...He.width > 0 ? {
|
|
5084
|
+
width: Ie ? `${He.width}px` : `${Ce + He.width + k}px`
|
|
5057
5085
|
} : {
|
|
5058
5086
|
visibility: "hidden"
|
|
5059
5087
|
}
|
|
@@ -5062,7 +5090,7 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5062
5090
|
/* @__PURE__ */ w.jsx(
|
|
5063
5091
|
"div",
|
|
5064
5092
|
{
|
|
5065
|
-
ref:
|
|
5093
|
+
ref: B[R],
|
|
5066
5094
|
style: ce(M.headerContainer),
|
|
5067
5095
|
children: W ? /* @__PURE__ */ w.jsx(
|
|
5068
5096
|
W,
|
|
@@ -5072,13 +5100,13 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5072
5100
|
index: R,
|
|
5073
5101
|
isCollapsed: Ie,
|
|
5074
5102
|
role: "button",
|
|
5075
|
-
section:
|
|
5103
|
+
section: F,
|
|
5076
5104
|
style: ce(M.header),
|
|
5077
5105
|
onClick: () => X(R),
|
|
5078
|
-
onCustomEvent: (
|
|
5106
|
+
onCustomEvent: (Le, Ye) => A?.(R, Le, Ye)
|
|
5079
5107
|
}
|
|
5080
5108
|
) : /* @__PURE__ */ w.jsxs(
|
|
5081
|
-
|
|
5109
|
+
me,
|
|
5082
5110
|
{
|
|
5083
5111
|
"aria-expanded": !Ie,
|
|
5084
5112
|
className: se({ collapsed: Ie, expanded: !Ie }),
|
|
@@ -5087,9 +5115,9 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5087
5115
|
style: ce(M.header),
|
|
5088
5116
|
onClick: () => X(R),
|
|
5089
5117
|
children: [
|
|
5090
|
-
/* @__PURE__ */ w.jsx("span", { dangerouslySetInnerHTML: { __html:
|
|
5118
|
+
/* @__PURE__ */ w.jsx("span", { dangerouslySetInnerHTML: { __html: F.label } }),
|
|
5091
5119
|
ae.expandIcon && /* @__PURE__ */ w.jsx(
|
|
5092
|
-
|
|
5120
|
+
me,
|
|
5093
5121
|
{
|
|
5094
5122
|
className: se({ collapsed: Ie, expanded: !Ie }),
|
|
5095
5123
|
element: Ie ? ae.collapseIcon ?? ae.expandIcon : ae.expandIcon,
|
|
@@ -5109,13 +5137,13 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5109
5137
|
pointerEvents: Ie ? "none" : "auto"
|
|
5110
5138
|
}, c === "vertical" ? {
|
|
5111
5139
|
width: "100%",
|
|
5112
|
-
height: `${
|
|
5140
|
+
height: `${Ce}px`,
|
|
5113
5141
|
marginTop: `${k}px`,
|
|
5114
5142
|
overflowY: ue < 0 || ue >= ee ? "hidden" : "scroll"
|
|
5115
5143
|
} : {
|
|
5116
5144
|
marginLeft: `${k}px`,
|
|
5117
5145
|
overflowX: ue < 0 || ue >= ee ? "hidden" : "scroll",
|
|
5118
|
-
width: `${
|
|
5146
|
+
width: `${Ce}px`,
|
|
5119
5147
|
height: "100%"
|
|
5120
5148
|
}),
|
|
5121
5149
|
children: /* @__PURE__ */ w.jsx(
|
|
@@ -5127,16 +5155,16 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5127
5155
|
itemLength: Z,
|
|
5128
5156
|
itemPadding: G,
|
|
5129
5157
|
items: U,
|
|
5130
|
-
layout:
|
|
5158
|
+
layout: ge,
|
|
5131
5159
|
numSegments: Ne,
|
|
5132
5160
|
orientation: c,
|
|
5133
5161
|
selection: P[R] ?? [],
|
|
5134
5162
|
selectionMode: m,
|
|
5135
5163
|
style: ce(c === "vertical" ? { width: "100%" } : { height: "100%" }),
|
|
5136
|
-
onActivateAt: (
|
|
5137
|
-
onCustomEvent: (
|
|
5138
|
-
onDeselectAt: (
|
|
5139
|
-
onSelectAt: (
|
|
5164
|
+
onActivateAt: (Le) => b?.(Le, R),
|
|
5165
|
+
onCustomEvent: (Le, Ye, Xe) => S?.(Le, R, Ye, Xe),
|
|
5166
|
+
onDeselectAt: (Le) => z(Le, R),
|
|
5167
|
+
onSelectAt: (Le) => D(Le, R),
|
|
5140
5168
|
children: !Y && (ae.item ?? /* @__PURE__ */ w.jsx(un, {}))
|
|
5141
5169
|
}
|
|
5142
5170
|
)
|
|
@@ -5146,7 +5174,7 @@ const fi = /* @__PURE__ */ Te(({
|
|
|
5146
5174
|
}
|
|
5147
5175
|
);
|
|
5148
5176
|
} }) });
|
|
5149
|
-
}), ln = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), Sr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, children: e }), _r = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, children: e }), dr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), un = zn.Item,
|
|
5177
|
+
}), ln = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), Sr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, children: e }), _r = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, children: e }), dr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), un = zn.Item, nu = /* @__PURE__ */ Object.assign(fi, {
|
|
5150
5178
|
/**
|
|
5151
5179
|
* Component for each section header of an {@link Accordion}.
|
|
5152
5180
|
*/
|
|
@@ -5265,64 +5293,64 @@ const Za = /* @__PURE__ */ Te(({
|
|
|
5265
5293
|
ItemComponent: b,
|
|
5266
5294
|
...T
|
|
5267
5295
|
}, _) => {
|
|
5268
|
-
const I = we(void 0),
|
|
5269
|
-
|
|
5270
|
-
}, []), z =
|
|
5271
|
-
D(),
|
|
5272
|
-
clearTimeout(
|
|
5296
|
+
const I = we(void 0), $ = we(null), A = we(void 0), S = we(void 0), C = we(void 0), q = 1e3, W = Se(d), Y = Se(g), J = Se(m), x = we(!1), P = we(!1), E = ja(), [M, B] = Oe(Oo($, c)), [K, oe] = Oe(!1), Q = tc({ scrollSnapEnabled: E || !K, orientation: c }), X = e > 0, D = he(() => {
|
|
5297
|
+
C.current !== void 0 && (clearTimeout(C.current), C.current = void 0);
|
|
5298
|
+
}, []), z = he(() => {
|
|
5299
|
+
D(), C.current = setTimeout(() => {
|
|
5300
|
+
clearTimeout(C.current), C.current = void 0;
|
|
5273
5301
|
}, q);
|
|
5274
|
-
}, [q, D]), te =
|
|
5275
|
-
Qa(
|
|
5276
|
-
}, [r, c]), ne =
|
|
5277
|
-
|
|
5278
|
-
}, [c]), ae =
|
|
5302
|
+
}, [q, D]), te = he(() => {
|
|
5303
|
+
Qa($, r, c), z();
|
|
5304
|
+
}, [r, c]), ne = he(() => {
|
|
5305
|
+
B(Oo($, c));
|
|
5306
|
+
}, [c]), ae = he((G) => {
|
|
5279
5307
|
E || (A.current = _e.make(G.clientX, G.clientY), oe(!0));
|
|
5280
|
-
}, [E]),
|
|
5308
|
+
}, [E]), F = he((G) => {
|
|
5281
5309
|
E || (S.current = _e.make(G.clientX, G.clientY), te(), oe(!1));
|
|
5282
|
-
}, [E, te]), R =
|
|
5283
|
-
const fe = A.current,
|
|
5284
|
-
if (!fe || !
|
|
5285
|
-
const ue = 5, Ne = _e.subtract(fe,
|
|
5310
|
+
}, [E, te]), R = he((G) => {
|
|
5311
|
+
const fe = A.current, ge = S.current;
|
|
5312
|
+
if (!fe || !ge) return;
|
|
5313
|
+
const ue = 5, Ne = _e.subtract(fe, ge);
|
|
5286
5314
|
(Math.abs(Ne.x) > ue || Math.abs(Ne.y) > ue) && G.stopPropagation(), A.current = void 0, S.current = void 0;
|
|
5287
|
-
}, []), k =
|
|
5315
|
+
}, []), k = he(() => {
|
|
5288
5316
|
const G = (r + a.length + 1) % a.length;
|
|
5289
5317
|
J.current?.(G);
|
|
5290
|
-
}, [K, r, a.length]), U =
|
|
5291
|
-
const
|
|
5292
|
-
!
|
|
5318
|
+
}, [K, r, a.length]), U = he(({ x: G, y: fe }) => {
|
|
5319
|
+
const ge = $.current;
|
|
5320
|
+
!ge || x.current || (D(), x.current = !0, requestAnimationFrame(() => {
|
|
5293
5321
|
switch (c) {
|
|
5294
5322
|
case "horizontal":
|
|
5295
|
-
|
|
5323
|
+
ge.scrollLeft -= G * 1.5;
|
|
5296
5324
|
break;
|
|
5297
5325
|
case "vertical":
|
|
5298
|
-
|
|
5326
|
+
ge.scrollTop -= fe * 1.5;
|
|
5299
5327
|
default:
|
|
5300
5328
|
console.error(`[etudes::Carousel] Unsupported orientation: ${c}`);
|
|
5301
5329
|
}
|
|
5302
5330
|
x.current = !1;
|
|
5303
5331
|
}));
|
|
5304
|
-
}, [c]), Z =
|
|
5305
|
-
const G =
|
|
5332
|
+
}, [c]), Z = he(() => {
|
|
5333
|
+
const G = $.current;
|
|
5306
5334
|
!G || P.current || (P.current = !0, requestAnimationFrame(() => {
|
|
5307
|
-
if (u && ne(), !(
|
|
5308
|
-
const
|
|
5335
|
+
if (u && ne(), !(C.current !== void 0)) {
|
|
5336
|
+
const ge = Math.round(c === "horizontal" ? G.scrollLeft / G.clientWidth : G.scrollTop / G.clientHeight), ue = Math.max(0, Math.min(a.length - 1, ge));
|
|
5309
5337
|
ue !== r && (I.current = ue, J.current?.(ue));
|
|
5310
5338
|
}
|
|
5311
5339
|
P.current = !1;
|
|
5312
5340
|
}));
|
|
5313
5341
|
}, [a.length, r, c, u, ne]);
|
|
5314
|
-
return ka(
|
|
5342
|
+
return ka($, {
|
|
5315
5343
|
isEnabled: !E && i && a.length > 1,
|
|
5316
5344
|
onDragMove: U
|
|
5317
|
-
}),
|
|
5345
|
+
}), Ca(K || !X ? -1 : e, {
|
|
5318
5346
|
onInterval: k
|
|
5319
|
-
}, [r]),
|
|
5347
|
+
}, [r]), $e(() => {
|
|
5320
5348
|
!X || E || (K ? W.current?.() : Y.current?.());
|
|
5321
|
-
}, [E, K, X]),
|
|
5322
|
-
const G =
|
|
5349
|
+
}, [E, K, X]), $e(() => {
|
|
5350
|
+
const G = $.current;
|
|
5323
5351
|
if (!G) return;
|
|
5324
|
-
const fe = I.current === void 0,
|
|
5325
|
-
return G.addEventListener("scroll", Z), u && ne(),
|
|
5352
|
+
const fe = I.current === void 0, ge = I.current === r;
|
|
5353
|
+
return G.addEventListener("scroll", Z), u && ne(), ge || (I.current = r, fe || (J.current?.(r), te())), () => {
|
|
5326
5354
|
G.removeEventListener("scroll", Z);
|
|
5327
5355
|
};
|
|
5328
5356
|
}, [r, u, te, Z, ne]), /* @__PURE__ */ w.jsx(
|
|
@@ -5332,15 +5360,15 @@ const Za = /* @__PURE__ */ Te(({
|
|
|
5332
5360
|
ref: _,
|
|
5333
5361
|
role: "region",
|
|
5334
5362
|
onClick: R,
|
|
5335
|
-
onPointerCancel:
|
|
5363
|
+
onPointerCancel: F,
|
|
5336
5364
|
onPointerDown: ae,
|
|
5337
|
-
onPointerLeave:
|
|
5338
|
-
onPointerUp:
|
|
5339
|
-
children: /* @__PURE__ */ w.jsx("div", { ref:
|
|
5365
|
+
onPointerLeave: F,
|
|
5366
|
+
onPointerUp: F,
|
|
5367
|
+
children: /* @__PURE__ */ w.jsx("div", { ref: $, style: ce(Q.viewport), children: /* @__PURE__ */ w.jsx(Mn, { in: a, children: ({ style: G, ...fe }, ge) => /* @__PURE__ */ w.jsx("div", { style: ce(Q.itemContainer), children: /* @__PURE__ */ w.jsx(
|
|
5340
5368
|
b,
|
|
5341
5369
|
{
|
|
5342
|
-
"aria-hidden":
|
|
5343
|
-
exposure: u ? M?.[
|
|
5370
|
+
"aria-hidden": ge !== r,
|
|
5371
|
+
exposure: u ? M?.[ge] : void 0,
|
|
5344
5372
|
style: ce(G, Q.item),
|
|
5345
5373
|
...fe
|
|
5346
5374
|
}
|
|
@@ -5427,20 +5455,20 @@ const pi = /* @__PURE__ */ Te(({
|
|
|
5427
5455
|
onChange: T,
|
|
5428
5456
|
..._
|
|
5429
5457
|
}, I) => {
|
|
5430
|
-
const
|
|
5458
|
+
const $ = rc(b, g), A = we([]), S = nc(), C = ze(e, {
|
|
5431
5459
|
field: dn
|
|
5432
5460
|
}), q = (x) => {
|
|
5433
5461
|
x < 0 ? A.current[0]?.focus() : x >= g ? A.current[g - 1]?.focus() : A.current[x]?.focus();
|
|
5434
5462
|
}, W = (x) => (P) => {
|
|
5435
|
-
const E =
|
|
5436
|
-
T(
|
|
5463
|
+
const E = $[x], M = oc(P.target.value, E), B = Po($.slice(), M.split("").slice(0, g), x);
|
|
5464
|
+
T(B);
|
|
5437
5465
|
const K = Math.min(x + M.length, g - 1);
|
|
5438
5466
|
q(K);
|
|
5439
5467
|
}, Y = (x) => (P) => {
|
|
5440
5468
|
switch (P.key) {
|
|
5441
5469
|
case "Backspace": {
|
|
5442
|
-
if (P.preventDefault(),
|
|
5443
|
-
const E =
|
|
5470
|
+
if (P.preventDefault(), $[x]) {
|
|
5471
|
+
const E = $.slice();
|
|
5444
5472
|
E[x] = "", T(E), q(x - 1);
|
|
5445
5473
|
} else
|
|
5446
5474
|
q(x - 1);
|
|
@@ -5457,29 +5485,29 @@ const pi = /* @__PURE__ */ Te(({
|
|
|
5457
5485
|
}
|
|
5458
5486
|
}, J = (x) => (P) => {
|
|
5459
5487
|
P.preventDefault();
|
|
5460
|
-
const E = P.clipboardData.getData("text").trim(), M = Po(
|
|
5488
|
+
const E = P.clipboardData.getData("text").trim(), M = Po($.slice(), E.split("").slice(0, g), x);
|
|
5461
5489
|
T(M);
|
|
5462
|
-
const
|
|
5463
|
-
q(
|
|
5490
|
+
const B = Math.min(x + E.length, g - 1);
|
|
5491
|
+
q(B);
|
|
5464
5492
|
};
|
|
5465
5493
|
return Ee(() => {
|
|
5466
5494
|
if (!i) return;
|
|
5467
|
-
const x =
|
|
5495
|
+
const x = $.findIndex((P) => P === "");
|
|
5468
5496
|
x !== -1 && q(x);
|
|
5469
5497
|
}, [i]), /* @__PURE__ */ w.jsx("div", { ..._, ref: I, style: ce(m, S.root), children: /* @__PURE__ */ w.jsx(nn, { count: g, children: (x) => /* @__PURE__ */ w.jsx(
|
|
5470
|
-
|
|
5498
|
+
me,
|
|
5471
5499
|
{
|
|
5472
5500
|
ref: (P) => A.current[x] = P,
|
|
5473
5501
|
"aria-disabled": c,
|
|
5474
5502
|
"aria-required": u,
|
|
5475
5503
|
autoComplete: r,
|
|
5476
5504
|
disabled: c,
|
|
5477
|
-
element:
|
|
5505
|
+
element: C.field ?? /* @__PURE__ */ w.jsx(dn, {}),
|
|
5478
5506
|
inputMode: a,
|
|
5479
5507
|
placeholder: d,
|
|
5480
5508
|
required: u,
|
|
5481
5509
|
style: ce(S.field),
|
|
5482
|
-
value:
|
|
5510
|
+
value: $[x],
|
|
5483
5511
|
onChange: W(x),
|
|
5484
5512
|
onKeyDown: Y(x),
|
|
5485
5513
|
onPaste: J(x)
|
|
@@ -5493,7 +5521,7 @@ const pi = /* @__PURE__ */ Te(({
|
|
|
5493
5521
|
autoCorrect: "off",
|
|
5494
5522
|
type: "text"
|
|
5495
5523
|
}
|
|
5496
|
-
),
|
|
5524
|
+
), ru = /* @__PURE__ */ Object.assign(pi, {
|
|
5497
5525
|
/**
|
|
5498
5526
|
* Component for the each field in a {@link CodeInput}.
|
|
5499
5527
|
*/
|
|
@@ -5545,7 +5573,7 @@ const hi = /* @__PURE__ */ Te(({
|
|
|
5545
5573
|
onChange: T,
|
|
5546
5574
|
..._
|
|
5547
5575
|
}, I) => {
|
|
5548
|
-
const
|
|
5576
|
+
const $ = he((A) => {
|
|
5549
5577
|
const S = (g?.(A) ?? A) || r;
|
|
5550
5578
|
T?.(S);
|
|
5551
5579
|
}, [T, g]);
|
|
@@ -5564,7 +5592,7 @@ const hi = /* @__PURE__ */ Te(({
|
|
|
5564
5592
|
type: u,
|
|
5565
5593
|
value: d || r,
|
|
5566
5594
|
onBlur: ({ target: A }) => b?.(A.value),
|
|
5567
|
-
onChange: ({ target: A }) =>
|
|
5595
|
+
onChange: ({ target: A }) => $(A.value),
|
|
5568
5596
|
onFocus: ({ target: A }) => m?.(A.value)
|
|
5569
5597
|
}
|
|
5570
5598
|
);
|
|
@@ -5588,18 +5616,18 @@ const gi = /* @__PURE__ */ Te(({
|
|
|
5588
5616
|
q(P);
|
|
5589
5617
|
}, I = (P) => {
|
|
5590
5618
|
const E = A(P);
|
|
5591
|
-
E !== u ? d?.(E) : q(
|
|
5592
|
-
},
|
|
5619
|
+
E !== u ? d?.(E) : q($(E));
|
|
5620
|
+
}, $ = (P) => P.toLocaleString(), A = (P) => {
|
|
5593
5621
|
const E = parseInt(P, 10);
|
|
5594
5622
|
return E.toString() !== P.replace(/^0+/, "") ? u : S(E);
|
|
5595
5623
|
}, S = (P) => {
|
|
5596
5624
|
let E = P;
|
|
5597
5625
|
return isNaN(c) || (E = Math.max(c, E)), isNaN(a) || (E = Math.min(a, E)), E;
|
|
5598
|
-
}, [
|
|
5626
|
+
}, [C, q] = Oe($(u)), W = Fa(u), Y = !isNaN(a) && u + 1 > a, J = !isNaN(c) && u - 1 < c;
|
|
5599
5627
|
Ee(() => {
|
|
5600
5628
|
if (W === void 0 || W === u) return;
|
|
5601
5629
|
const P = S(u);
|
|
5602
|
-
q(
|
|
5630
|
+
q($(P));
|
|
5603
5631
|
}, [u, c, a]);
|
|
5604
5632
|
const x = ze(e, {
|
|
5605
5633
|
textField: pn,
|
|
@@ -5608,7 +5636,7 @@ const gi = /* @__PURE__ */ Te(({
|
|
|
5608
5636
|
});
|
|
5609
5637
|
return /* @__PURE__ */ w.jsxs("div", { ...g, ref: m, style: ce(r, Zt.root), children: [
|
|
5610
5638
|
/* @__PURE__ */ w.jsx(
|
|
5611
|
-
|
|
5639
|
+
me,
|
|
5612
5640
|
{
|
|
5613
5641
|
className: se({ disabled: J }),
|
|
5614
5642
|
element: x.subscribeButton ?? /* @__PURE__ */ w.jsx(gn, {}),
|
|
@@ -5617,18 +5645,18 @@ const gi = /* @__PURE__ */ Te(({
|
|
|
5617
5645
|
}
|
|
5618
5646
|
),
|
|
5619
5647
|
/* @__PURE__ */ w.jsx(
|
|
5620
|
-
|
|
5648
|
+
me,
|
|
5621
5649
|
{
|
|
5622
5650
|
element: x.textField ?? /* @__PURE__ */ w.jsx(pn, {}),
|
|
5623
5651
|
isDisabled: !i,
|
|
5624
5652
|
style: ce(Zt.textField),
|
|
5625
|
-
value:
|
|
5653
|
+
value: C,
|
|
5626
5654
|
onChange: _,
|
|
5627
5655
|
onUnfocus: I
|
|
5628
5656
|
}
|
|
5629
5657
|
),
|
|
5630
5658
|
/* @__PURE__ */ w.jsx(
|
|
5631
|
-
|
|
5659
|
+
me,
|
|
5632
5660
|
{
|
|
5633
5661
|
className: se({ disabled: Y }),
|
|
5634
5662
|
element: x.addButton ?? /* @__PURE__ */ w.jsx(hn, {}),
|
|
@@ -5637,7 +5665,7 @@ const gi = /* @__PURE__ */ Te(({
|
|
|
5637
5665
|
}
|
|
5638
5666
|
)
|
|
5639
5667
|
] });
|
|
5640
|
-
}), pn = ({ ...e }) => /* @__PURE__ */ w.jsx(hi, { ...e }), hn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), gn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }),
|
|
5668
|
+
}), pn = ({ ...e }) => /* @__PURE__ */ w.jsx(hi, { ...e }), hn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), gn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), ou = /* @__PURE__ */ Object.assign(gi, {
|
|
5641
5669
|
/**
|
|
5642
5670
|
* Component for the text field in a {@link Counter}.
|
|
5643
5671
|
*/
|
|
@@ -5682,10 +5710,10 @@ const ic = /* @__PURE__ */ Te(({
|
|
|
5682
5710
|
const T = u * 2, _ = Math.max(0, Math.min(360, a)), I = ze(e, {
|
|
5683
5711
|
track: mn,
|
|
5684
5712
|
knob: vn
|
|
5685
|
-
}),
|
|
5686
|
-
return /* @__PURE__ */ w.jsxs("div", { ...m, ref: b, style: ce(r,
|
|
5687
|
-
/* @__PURE__ */ w.jsx("div", { style:
|
|
5688
|
-
|
|
5713
|
+
}), $ = cc({ angle: i, diameter: T });
|
|
5714
|
+
return /* @__PURE__ */ w.jsxs("div", { ...m, ref: b, style: ce(r, $.root), children: [
|
|
5715
|
+
/* @__PURE__ */ w.jsx("div", { style: $.trackContainer, children: /* @__PURE__ */ w.jsx("svg", { height: T, style: $.svgContainer, viewBox: `0 0 ${T} ${T}`, width: T, children: /* @__PURE__ */ w.jsx(
|
|
5716
|
+
me,
|
|
5689
5717
|
{
|
|
5690
5718
|
cx: u,
|
|
5691
5719
|
cy: u,
|
|
@@ -5696,8 +5724,8 @@ const ic = /* @__PURE__ */ Te(({
|
|
|
5696
5724
|
strokeWidth: g
|
|
5697
5725
|
}
|
|
5698
5726
|
) }) }),
|
|
5699
|
-
/* @__PURE__ */ w.jsx("div", { style: ce(
|
|
5700
|
-
|
|
5727
|
+
/* @__PURE__ */ w.jsx("div", { style: ce($.knobContainer), children: /* @__PURE__ */ w.jsx("svg", { style: $.svgContainer, viewBox: `0 0 ${T} ${T}`, xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ w.jsx(
|
|
5728
|
+
me,
|
|
5701
5729
|
{
|
|
5702
5730
|
d: ac(u, u, u - c / 2 - (g - c) / 2, -_ / 2, _ / 2),
|
|
5703
5731
|
element: I.knob ?? /* @__PURE__ */ w.jsx(vn, {}),
|
|
@@ -5788,10 +5816,10 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5788
5816
|
itemLength: T,
|
|
5789
5817
|
itemPadding: _ = 0,
|
|
5790
5818
|
items: I = [],
|
|
5791
|
-
maxVisibleItems:
|
|
5819
|
+
maxVisibleItems: $ = -1,
|
|
5792
5820
|
numSegments: A = 1,
|
|
5793
5821
|
orientation: S = "vertical",
|
|
5794
|
-
selection:
|
|
5822
|
+
selection: C = [],
|
|
5795
5823
|
selectionMode: q = "single",
|
|
5796
5824
|
onActivateAt: W,
|
|
5797
5825
|
onCollapse: Y,
|
|
@@ -5800,11 +5828,11 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5800
5828
|
onSelectAt: P,
|
|
5801
5829
|
onSelectionChange: E,
|
|
5802
5830
|
onToggleCustomEvent: M,
|
|
5803
|
-
ItemComponent:
|
|
5831
|
+
ItemComponent: B,
|
|
5804
5832
|
ToggleComponent: K,
|
|
5805
5833
|
...oe
|
|
5806
5834
|
}, Q) => {
|
|
5807
|
-
const X = we(null), D = nt(X), z = I.length, te = dc(I,
|
|
5835
|
+
const X = we(null), D = nt(X), z = I.length, te = dc(I, $, A, m), ne = T ?? (S === "vertical" ? D.height : D.width), ae = ne * te + _ * (te - 1), F = uc(C, I), [R, k] = Oe(u ?? !0), U = pc({ isCollapsed: R, collectionPadding: c, isInverted: d, maxVisibleItems: $, menuLength: ae, numItems: z, orientation: S }), Z = ze(e, {
|
|
5808
5836
|
collapseIcon: Tr,
|
|
5809
5837
|
collection: yn,
|
|
5810
5838
|
expandIcon: Or,
|
|
@@ -5814,7 +5842,7 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5814
5842
|
R && (k(!1), x?.());
|
|
5815
5843
|
}, fe = () => {
|
|
5816
5844
|
R || (k(!0), Y?.());
|
|
5817
|
-
},
|
|
5845
|
+
}, ge = () => {
|
|
5818
5846
|
R ? G() : fe();
|
|
5819
5847
|
}, ue = (Ne) => {
|
|
5820
5848
|
P?.(Ne), q === "single" && a && fe();
|
|
@@ -5824,16 +5852,16 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5824
5852
|
}, [u]), Ee(() => {
|
|
5825
5853
|
const Ne = (ee) => {
|
|
5826
5854
|
if (R || !(ee.target instanceof Node)) return;
|
|
5827
|
-
let
|
|
5828
|
-
for (;
|
|
5829
|
-
if (
|
|
5830
|
-
|
|
5855
|
+
let Be = !0, Ce = ee.target;
|
|
5856
|
+
for (; Ce; ) {
|
|
5857
|
+
if (Ce === X.current) {
|
|
5858
|
+
Be = !1;
|
|
5831
5859
|
break;
|
|
5832
5860
|
}
|
|
5833
|
-
if (
|
|
5834
|
-
|
|
5861
|
+
if (!Ce.parentNode) break;
|
|
5862
|
+
Ce = Ce.parentNode;
|
|
5835
5863
|
}
|
|
5836
|
-
|
|
5864
|
+
Be && fe();
|
|
5837
5865
|
};
|
|
5838
5866
|
return window.addEventListener("click", Ne), () => {
|
|
5839
5867
|
window.removeEventListener("click", Ne);
|
|
@@ -5853,22 +5881,22 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5853
5881
|
"aria-haspopup": "listbox",
|
|
5854
5882
|
className: se({ collapsed: R, expanded: !R }),
|
|
5855
5883
|
style: ce(U.toggle),
|
|
5856
|
-
onClick:
|
|
5884
|
+
onClick: ge,
|
|
5857
5885
|
onCustomEvent: (Ne, ee) => M?.(Ne, ee)
|
|
5858
5886
|
}
|
|
5859
5887
|
) : /* @__PURE__ */ w.jsxs(
|
|
5860
|
-
|
|
5888
|
+
me,
|
|
5861
5889
|
{
|
|
5862
5890
|
"aria-expanded": !R,
|
|
5863
5891
|
"aria-haspopup": "listbox",
|
|
5864
5892
|
className: se({ collapsed: R, expanded: !R }),
|
|
5865
5893
|
element: Z.toggle ?? /* @__PURE__ */ w.jsx(xn, {}),
|
|
5866
5894
|
style: ce(U.toggle),
|
|
5867
|
-
onClick:
|
|
5895
|
+
onClick: ge,
|
|
5868
5896
|
children: [
|
|
5869
|
-
/* @__PURE__ */ w.jsx("span", { dangerouslySetInnerHTML: { __html: g?.(
|
|
5897
|
+
/* @__PURE__ */ w.jsx("span", { dangerouslySetInnerHTML: { __html: g?.(F) ?? (F.length > 0 ? F.map((Ne) => I[Ne]).join(", ") : "") } }),
|
|
5870
5898
|
Z.expandIcon && /* @__PURE__ */ w.jsx(
|
|
5871
|
-
|
|
5899
|
+
me,
|
|
5872
5900
|
{
|
|
5873
5901
|
className: se({ collapsed: R, expanded: !R }),
|
|
5874
5902
|
element: R ? Z.collapseIcon ?? Z.expandIcon : Z.expandIcon,
|
|
@@ -5879,31 +5907,31 @@ const mi = /* @__PURE__ */ Te(({
|
|
|
5879
5907
|
}
|
|
5880
5908
|
),
|
|
5881
5909
|
/* @__PURE__ */ w.jsx(
|
|
5882
|
-
|
|
5910
|
+
me,
|
|
5883
5911
|
{
|
|
5884
5912
|
element: Z.collection ?? /* @__PURE__ */ w.jsx(yn, {}),
|
|
5885
5913
|
isSelectionTogglable: b,
|
|
5886
|
-
ItemComponent:
|
|
5914
|
+
ItemComponent: B,
|
|
5887
5915
|
itemLength: ne,
|
|
5888
5916
|
itemPadding: _,
|
|
5889
5917
|
items: I,
|
|
5890
5918
|
layout: m,
|
|
5891
5919
|
numSegments: A,
|
|
5892
5920
|
orientation: S,
|
|
5893
|
-
selection:
|
|
5921
|
+
selection: F,
|
|
5894
5922
|
selectionMode: q,
|
|
5895
5923
|
style: ce(U.collection),
|
|
5896
5924
|
onActivateAt: W,
|
|
5897
5925
|
onDeselectAt: J,
|
|
5898
5926
|
onSelectAt: ue,
|
|
5899
5927
|
onSelectionChange: E,
|
|
5900
|
-
children: !
|
|
5928
|
+
children: !B && (Z.item ?? /* @__PURE__ */ w.jsx(bn, {}))
|
|
5901
5929
|
}
|
|
5902
5930
|
)
|
|
5903
5931
|
] })
|
|
5904
5932
|
}
|
|
5905
5933
|
);
|
|
5906
|
-
}), yn = zn, bn = zn.Item, xn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), Tr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, "aria-hidden": !0, children: e }), Or = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, "aria-hidden": !0, children: e }),
|
|
5934
|
+
}), yn = zn, bn = zn.Item, xn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("button", { ...r, children: e }), Tr = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, "aria-hidden": !0, children: e }), Or = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("figure", { ...r, "aria-hidden": !0, children: e }), iu = /* @__PURE__ */ Object.assign(mi, {
|
|
5907
5935
|
/**
|
|
5908
5936
|
* Component containing the items in a {@link Dropdown}.
|
|
5909
5937
|
*/
|
|
@@ -6023,7 +6051,7 @@ function yi(e, r) {
|
|
|
6023
6051
|
}
|
|
6024
6052
|
return i;
|
|
6025
6053
|
}
|
|
6026
|
-
const
|
|
6054
|
+
const Ln = function(e) {
|
|
6027
6055
|
const r = mc.exec(e);
|
|
6028
6056
|
return !(r === null || typeof r > "u");
|
|
6029
6057
|
};
|
|
@@ -6042,11 +6070,11 @@ function bc(e, r) {
|
|
|
6042
6070
|
e[0] === "\uFEFF" && (e = e.substr(1));
|
|
6043
6071
|
for (let u = 0; u < e.length; u++)
|
|
6044
6072
|
if (e[u] === "<" && e[u + 1] === "?") {
|
|
6045
|
-
if (u += 2, u =
|
|
6073
|
+
if (u += 2, u = Co(e, u), u.err) return u;
|
|
6046
6074
|
} else if (e[u] === "<") {
|
|
6047
6075
|
let d = u;
|
|
6048
6076
|
if (u++, e[u] === "!") {
|
|
6049
|
-
u =
|
|
6077
|
+
u = $o(e, u);
|
|
6050
6078
|
continue;
|
|
6051
6079
|
} else {
|
|
6052
6080
|
let g = !1;
|
|
@@ -6057,73 +6085,73 @@ function bc(e, r) {
|
|
|
6057
6085
|
m += e[u];
|
|
6058
6086
|
if (m = m.trim(), m[m.length - 1] === "/" && (m = m.substring(0, m.length - 1), u--), !Oc(m)) {
|
|
6059
6087
|
let _;
|
|
6060
|
-
return m.trim().length === 0 ? _ = "Invalid space after '<'." : _ = "Tag '" + m + "' is an invalid name.", ke("InvalidTag", _,
|
|
6088
|
+
return m.trim().length === 0 ? _ = "Invalid space after '<'." : _ = "Tag '" + m + "' is an invalid name.", ke("InvalidTag", _, Re(e, u));
|
|
6061
6089
|
}
|
|
6062
6090
|
const b = Ec(e, u);
|
|
6063
6091
|
if (b === !1)
|
|
6064
|
-
return ke("InvalidAttr", "Attributes for '" + m + "' have open quote.",
|
|
6092
|
+
return ke("InvalidAttr", "Attributes for '" + m + "' have open quote.", Re(e, u));
|
|
6065
6093
|
let T = b.value;
|
|
6066
6094
|
if (u = b.index, T[T.length - 1] === "/") {
|
|
6067
6095
|
const _ = u - T.length;
|
|
6068
6096
|
T = T.substring(0, T.length - 1);
|
|
6069
|
-
const I =
|
|
6097
|
+
const I = jo(T, r);
|
|
6070
6098
|
if (I === !0)
|
|
6071
6099
|
a = !0;
|
|
6072
6100
|
else
|
|
6073
|
-
return ke(I.err.code, I.err.msg,
|
|
6101
|
+
return ke(I.err.code, I.err.msg, Re(e, _ + I.err.line));
|
|
6074
6102
|
} else if (g)
|
|
6075
6103
|
if (b.tagClosed) {
|
|
6076
6104
|
if (T.trim().length > 0)
|
|
6077
|
-
return ke("InvalidTag", "Closing tag '" + m + "' can't have attributes or invalid starting.",
|
|
6105
|
+
return ke("InvalidTag", "Closing tag '" + m + "' can't have attributes or invalid starting.", Re(e, d));
|
|
6078
6106
|
if (i.length === 0)
|
|
6079
|
-
return ke("InvalidTag", "Closing tag '" + m + "' has not been opened.",
|
|
6107
|
+
return ke("InvalidTag", "Closing tag '" + m + "' has not been opened.", Re(e, d));
|
|
6080
6108
|
{
|
|
6081
6109
|
const _ = i.pop();
|
|
6082
6110
|
if (m !== _.tagName) {
|
|
6083
|
-
let I =
|
|
6111
|
+
let I = Re(e, _.tagStartPos);
|
|
6084
6112
|
return ke(
|
|
6085
6113
|
"InvalidTag",
|
|
6086
6114
|
"Expected closing tag '" + _.tagName + "' (opened in line " + I.line + ", col " + I.col + ") instead of closing tag '" + m + "'.",
|
|
6087
|
-
|
|
6115
|
+
Re(e, d)
|
|
6088
6116
|
);
|
|
6089
6117
|
}
|
|
6090
6118
|
i.length == 0 && (c = !0);
|
|
6091
6119
|
}
|
|
6092
|
-
} else return ke("InvalidTag", "Closing tag '" + m + "' doesn't have proper closing.",
|
|
6120
|
+
} else return ke("InvalidTag", "Closing tag '" + m + "' doesn't have proper closing.", Re(e, u));
|
|
6093
6121
|
else {
|
|
6094
|
-
const _ =
|
|
6122
|
+
const _ = jo(T, r);
|
|
6095
6123
|
if (_ !== !0)
|
|
6096
|
-
return ke(_.err.code, _.err.msg,
|
|
6124
|
+
return ke(_.err.code, _.err.msg, Re(e, u - T.length + _.err.line));
|
|
6097
6125
|
if (c === !0)
|
|
6098
|
-
return ke("InvalidXml", "Multiple possible root nodes found.",
|
|
6126
|
+
return ke("InvalidXml", "Multiple possible root nodes found.", Re(e, u));
|
|
6099
6127
|
r.unpairedTags.indexOf(m) !== -1 || i.push({ tagName: m, tagStartPos: d }), a = !0;
|
|
6100
6128
|
}
|
|
6101
6129
|
for (u++; u < e.length; u++)
|
|
6102
6130
|
if (e[u] === "<")
|
|
6103
6131
|
if (e[u + 1] === "!") {
|
|
6104
|
-
u++, u =
|
|
6132
|
+
u++, u = $o(e, u);
|
|
6105
6133
|
continue;
|
|
6106
6134
|
} else if (e[u + 1] === "?") {
|
|
6107
|
-
if (u =
|
|
6135
|
+
if (u = Co(e, ++u), u.err) return u;
|
|
6108
6136
|
} else
|
|
6109
6137
|
break;
|
|
6110
6138
|
else if (e[u] === "&") {
|
|
6111
6139
|
const _ = _c(e, u);
|
|
6112
6140
|
if (_ == -1)
|
|
6113
|
-
return ke("InvalidChar", "char '&' is not expected.",
|
|
6141
|
+
return ke("InvalidChar", "char '&' is not expected.", Re(e, u));
|
|
6114
6142
|
u = _;
|
|
6115
6143
|
} else if (c === !0 && !ko(e[u]))
|
|
6116
|
-
return ke("InvalidXml", "Extra text at the end",
|
|
6144
|
+
return ke("InvalidXml", "Extra text at the end", Re(e, u));
|
|
6117
6145
|
e[u] === "<" && u--;
|
|
6118
6146
|
}
|
|
6119
6147
|
} else {
|
|
6120
6148
|
if (ko(e[u]))
|
|
6121
6149
|
continue;
|
|
6122
|
-
return ke("InvalidChar", "char '" + e[u] + "' is not expected.",
|
|
6150
|
+
return ke("InvalidChar", "char '" + e[u] + "' is not expected.", Re(e, u));
|
|
6123
6151
|
}
|
|
6124
6152
|
if (a) {
|
|
6125
6153
|
if (i.length == 1)
|
|
6126
|
-
return ke("InvalidTag", "Unclosed tag '" + i[0].tagName + "'.",
|
|
6154
|
+
return ke("InvalidTag", "Unclosed tag '" + i[0].tagName + "'.", Re(e, i[0].tagStartPos));
|
|
6127
6155
|
if (i.length > 0)
|
|
6128
6156
|
return ke("InvalidXml", "Invalid '" + JSON.stringify(i.map((u) => u.tagName), null, 4).replace(/\r?\n/g, "") + "' found.", { line: 1, col: 1 });
|
|
6129
6157
|
} else return ke("InvalidXml", "Start tag expected.", 1);
|
|
@@ -6133,13 +6161,13 @@ function ko(e) {
|
|
|
6133
6161
|
return e === " " || e === " " || e === `
|
|
6134
6162
|
` || e === "\r";
|
|
6135
6163
|
}
|
|
6136
|
-
function
|
|
6164
|
+
function Co(e, r) {
|
|
6137
6165
|
const i = r;
|
|
6138
6166
|
for (; r < e.length; r++)
|
|
6139
6167
|
if (e[r] == "?" || e[r] == " ") {
|
|
6140
6168
|
const a = e.substr(i, r - i);
|
|
6141
6169
|
if (r > 5 && a === "xml")
|
|
6142
|
-
return ke("InvalidXml", "XML declaration allowed only at the start of the document.",
|
|
6170
|
+
return ke("InvalidXml", "XML declaration allowed only at the start of the document.", Re(e, r));
|
|
6143
6171
|
if (e[r] == "?" && e[r + 1] == ">") {
|
|
6144
6172
|
r++;
|
|
6145
6173
|
break;
|
|
@@ -6148,7 +6176,7 @@ function $o(e, r) {
|
|
|
6148
6176
|
}
|
|
6149
6177
|
return r;
|
|
6150
6178
|
}
|
|
6151
|
-
function
|
|
6179
|
+
function $o(e, r) {
|
|
6152
6180
|
if (e.length > r + 5 && e[r + 1] === "-" && e[r + 2] === "-") {
|
|
6153
6181
|
for (r += 3; r < e.length; r++)
|
|
6154
6182
|
if (e[r] === "-" && e[r + 1] === "-" && e[r + 2] === ">") {
|
|
@@ -6190,7 +6218,7 @@ function Ec(e, r) {
|
|
|
6190
6218
|
};
|
|
6191
6219
|
}
|
|
6192
6220
|
const Nc = new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`, "g");
|
|
6193
|
-
function
|
|
6221
|
+
function jo(e, r) {
|
|
6194
6222
|
const i = yi(e, Nc), a = {};
|
|
6195
6223
|
for (let c = 0; c < i.length; c++) {
|
|
6196
6224
|
if (i[c][1].length === 0)
|
|
@@ -6244,12 +6272,12 @@ function ke(e, r, i) {
|
|
|
6244
6272
|
};
|
|
6245
6273
|
}
|
|
6246
6274
|
function Tc(e) {
|
|
6247
|
-
return
|
|
6275
|
+
return Ln(e);
|
|
6248
6276
|
}
|
|
6249
6277
|
function Oc(e) {
|
|
6250
|
-
return
|
|
6278
|
+
return Ln(e);
|
|
6251
6279
|
}
|
|
6252
|
-
function
|
|
6280
|
+
function Re(e, r) {
|
|
6253
6281
|
const i = e.substring(0, r).split(/\r?\n/);
|
|
6254
6282
|
return {
|
|
6255
6283
|
line: i.length,
|
|
@@ -6366,11 +6394,11 @@ class kc {
|
|
|
6366
6394
|
return { entities: a, i };
|
|
6367
6395
|
}
|
|
6368
6396
|
readEntityExp(r, i) {
|
|
6369
|
-
i =
|
|
6397
|
+
i = Fe(r, i);
|
|
6370
6398
|
let a = "";
|
|
6371
6399
|
for (; i < r.length && !/\s/.test(r[i]) && r[i] !== '"' && r[i] !== "'"; )
|
|
6372
6400
|
a += r[i], i++;
|
|
6373
|
-
if (Pt(a), i =
|
|
6401
|
+
if (Pt(a), i = Fe(r, i), !this.suppressValidationErr) {
|
|
6374
6402
|
if (r.substring(i, i + 6).toUpperCase() === "SYSTEM")
|
|
6375
6403
|
throw new Error("External entities are not supported");
|
|
6376
6404
|
if (r[i] === "%")
|
|
@@ -6380,18 +6408,18 @@ class kc {
|
|
|
6380
6408
|
return [i, c] = this.readIdentifierVal(r, i, "entity"), i--, [a, c, i];
|
|
6381
6409
|
}
|
|
6382
6410
|
readNotationExp(r, i) {
|
|
6383
|
-
i =
|
|
6411
|
+
i = Fe(r, i);
|
|
6384
6412
|
let a = "";
|
|
6385
6413
|
for (; i < r.length && !/\s/.test(r[i]); )
|
|
6386
6414
|
a += r[i], i++;
|
|
6387
|
-
!this.suppressValidationErr && Pt(a), i =
|
|
6415
|
+
!this.suppressValidationErr && Pt(a), i = Fe(r, i);
|
|
6388
6416
|
const c = r.substring(i, i + 6).toUpperCase();
|
|
6389
6417
|
if (!this.suppressValidationErr && c !== "SYSTEM" && c !== "PUBLIC")
|
|
6390
6418
|
throw new Error(`Expected SYSTEM or PUBLIC, found "${c}"`);
|
|
6391
|
-
i += c.length, i =
|
|
6419
|
+
i += c.length, i = Fe(r, i);
|
|
6392
6420
|
let u = null, d = null;
|
|
6393
6421
|
if (c === "PUBLIC")
|
|
6394
|
-
[i, u] = this.readIdentifierVal(r, i, "publicIdentifier"), i =
|
|
6422
|
+
[i, u] = this.readIdentifierVal(r, i, "publicIdentifier"), i = Fe(r, i), (r[i] === '"' || r[i] === "'") && ([i, d] = this.readIdentifierVal(r, i, "systemIdentifier"));
|
|
6395
6423
|
else if (c === "SYSTEM" && ([i, d] = this.readIdentifierVal(r, i, "systemIdentifier"), !this.suppressValidationErr && !d))
|
|
6396
6424
|
throw new Error("Missing mandatory system identifier for SYSTEM notation");
|
|
6397
6425
|
return { notationName: a, publicIdentifier: u, systemIdentifier: d, index: --i };
|
|
@@ -6408,13 +6436,13 @@ class kc {
|
|
|
6408
6436
|
return i++, [i, c];
|
|
6409
6437
|
}
|
|
6410
6438
|
readElementExp(r, i) {
|
|
6411
|
-
i =
|
|
6439
|
+
i = Fe(r, i);
|
|
6412
6440
|
let a = "";
|
|
6413
6441
|
for (; i < r.length && !/\s/.test(r[i]); )
|
|
6414
6442
|
a += r[i], i++;
|
|
6415
|
-
if (!this.suppressValidationErr && !
|
|
6443
|
+
if (!this.suppressValidationErr && !Ln(a))
|
|
6416
6444
|
throw new Error(`Invalid element name: "${a}"`);
|
|
6417
|
-
i =
|
|
6445
|
+
i = Fe(r, i);
|
|
6418
6446
|
let c = "";
|
|
6419
6447
|
if (r[i] === "E" && st(r, "MPTY", i)) i += 4;
|
|
6420
6448
|
else if (r[i] === "A" && st(r, "NY", i)) i += 2;
|
|
@@ -6432,20 +6460,20 @@ class kc {
|
|
|
6432
6460
|
};
|
|
6433
6461
|
}
|
|
6434
6462
|
readAttlistExp(r, i) {
|
|
6435
|
-
i =
|
|
6463
|
+
i = Fe(r, i);
|
|
6436
6464
|
let a = "";
|
|
6437
6465
|
for (; i < r.length && !/\s/.test(r[i]); )
|
|
6438
6466
|
a += r[i], i++;
|
|
6439
|
-
Pt(a), i =
|
|
6467
|
+
Pt(a), i = Fe(r, i);
|
|
6440
6468
|
let c = "";
|
|
6441
6469
|
for (; i < r.length && !/\s/.test(r[i]); )
|
|
6442
6470
|
c += r[i], i++;
|
|
6443
6471
|
if (!Pt(c))
|
|
6444
6472
|
throw new Error(`Invalid attribute name: "${c}"`);
|
|
6445
|
-
i =
|
|
6473
|
+
i = Fe(r, i);
|
|
6446
6474
|
let u = "";
|
|
6447
6475
|
if (r.substring(i, i + 8).toUpperCase() === "NOTATION") {
|
|
6448
|
-
if (u = "NOTATION", i += 8, i =
|
|
6476
|
+
if (u = "NOTATION", i += 8, i = Fe(r, i), r[i] !== "(")
|
|
6449
6477
|
throw new Error(`Expected '(', found "${r[i]}"`);
|
|
6450
6478
|
i++;
|
|
6451
6479
|
let g = [];
|
|
@@ -6455,7 +6483,7 @@ class kc {
|
|
|
6455
6483
|
m += r[i], i++;
|
|
6456
6484
|
if (m = m.trim(), !Pt(m))
|
|
6457
6485
|
throw new Error(`Invalid notation name: "${m}"`);
|
|
6458
|
-
g.push(m), r[i] === "|" && (i++, i =
|
|
6486
|
+
g.push(m), r[i] === "|" && (i++, i = Fe(r, i));
|
|
6459
6487
|
}
|
|
6460
6488
|
if (r[i] !== ")")
|
|
6461
6489
|
throw new Error("Unterminated list of notations");
|
|
@@ -6467,7 +6495,7 @@ class kc {
|
|
|
6467
6495
|
if (!this.suppressValidationErr && !g.includes(u.toUpperCase()))
|
|
6468
6496
|
throw new Error(`Invalid attribute type: "${u}"`);
|
|
6469
6497
|
}
|
|
6470
|
-
i =
|
|
6498
|
+
i = Fe(r, i);
|
|
6471
6499
|
let d = "";
|
|
6472
6500
|
return r.substring(i, i + 8).toUpperCase() === "#REQUIRED" ? (d = "#REQUIRED", i += 8) : r.substring(i, i + 7).toUpperCase() === "#IMPLIED" ? (d = "#IMPLIED", i += 7) : [i, d] = this.readIdentifierVal(r, i, "ATTLIST"), {
|
|
6473
6501
|
elementName: a,
|
|
@@ -6478,7 +6506,7 @@ class kc {
|
|
|
6478
6506
|
};
|
|
6479
6507
|
}
|
|
6480
6508
|
}
|
|
6481
|
-
const
|
|
6509
|
+
const Fe = (e, r) => {
|
|
6482
6510
|
for (; r < e.length && /\s/.test(e[r]); )
|
|
6483
6511
|
r++;
|
|
6484
6512
|
return r;
|
|
@@ -6489,11 +6517,11 @@ function st(e, r, i) {
|
|
|
6489
6517
|
return !0;
|
|
6490
6518
|
}
|
|
6491
6519
|
function Pt(e) {
|
|
6492
|
-
if (
|
|
6520
|
+
if (Ln(e))
|
|
6493
6521
|
return e;
|
|
6494
6522
|
throw new Error(`Invalid entity name ${e}`);
|
|
6495
6523
|
}
|
|
6496
|
-
const
|
|
6524
|
+
const Cc = /^[-+]?0x[a-fA-F0-9]+$/, $c = /^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/, jc = {
|
|
6497
6525
|
hex: !0,
|
|
6498
6526
|
// oct: false,
|
|
6499
6527
|
leadingZeros: !0,
|
|
@@ -6502,16 +6530,16 @@ const $c = /^[-+]?0x[a-fA-F0-9]+$/, jc = /^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/, C
|
|
|
6502
6530
|
//skipLike: /regex/
|
|
6503
6531
|
};
|
|
6504
6532
|
function Ac(e, r = {}) {
|
|
6505
|
-
if (r = Object.assign({},
|
|
6533
|
+
if (r = Object.assign({}, jc, r), !e || typeof e != "string") return e;
|
|
6506
6534
|
let i = e.trim();
|
|
6507
6535
|
if (r.skipLike !== void 0 && r.skipLike.test(i)) return e;
|
|
6508
6536
|
if (e === "0") return 0;
|
|
6509
|
-
if (r.hex &&
|
|
6510
|
-
return
|
|
6537
|
+
if (r.hex && Cc.test(i))
|
|
6538
|
+
return Lc(i, 16);
|
|
6511
6539
|
if (i.search(/.+[eE].+/) !== -1)
|
|
6512
6540
|
return Rc(e, i, r);
|
|
6513
6541
|
{
|
|
6514
|
-
const a =
|
|
6542
|
+
const a = $c.exec(i);
|
|
6515
6543
|
if (a) {
|
|
6516
6544
|
const c = a[1] || "", u = a[2];
|
|
6517
6545
|
let d = zc(a[3]);
|
|
@@ -6552,7 +6580,7 @@ function Rc(e, r, i) {
|
|
|
6552
6580
|
function zc(e) {
|
|
6553
6581
|
return e && e.indexOf(".") !== -1 && (e = e.replace(/0+$/, ""), e === "." ? e = "0" : e[0] === "." ? e = "0" + e : e[e.length - 1] === "." && (e = e.substring(0, e.length - 1))), e;
|
|
6554
6582
|
}
|
|
6555
|
-
function
|
|
6583
|
+
function Lc(e, r) {
|
|
6556
6584
|
if (parseInt) return parseInt(e, r);
|
|
6557
6585
|
if (Number.parseInt) return Number.parseInt(e, r);
|
|
6558
6586
|
if (window && window.parseInt) return window.parseInt(e, r);
|
|
@@ -6565,7 +6593,7 @@ function bi(e) {
|
|
|
6565
6593
|
return !0;
|
|
6566
6594
|
} : () => !1;
|
|
6567
6595
|
}
|
|
6568
|
-
class
|
|
6596
|
+
class Fc {
|
|
6569
6597
|
constructor(r) {
|
|
6570
6598
|
if (this.options = r, this.currentNode = null, this.tagsNodeStack = [], this.docTypeEntities = {}, this.lastEntities = {
|
|
6571
6599
|
apos: { regex: /&(apos|#39|#x27);/g, val: "'" },
|
|
@@ -6588,7 +6616,7 @@ class Lc {
|
|
|
6588
6616
|
inr: { regex: /&(inr|#8377);/g, val: "₹" },
|
|
6589
6617
|
num_dec: { regex: /&#([0-9]{1,7});/g, val: (i, a) => String.fromCodePoint(Number.parseInt(a, 10)) },
|
|
6590
6618
|
num_hex: { regex: /&#x([0-9a-fA-F]{1,6});/g, val: (i, a) => String.fromCodePoint(Number.parseInt(a, 16)) }
|
|
6591
|
-
}, this.addExternalEntities = Vc, this.parseXml = Xc, this.parseTextData = Dc, this.resolveNameSpace =
|
|
6619
|
+
}, this.addExternalEntities = Vc, this.parseXml = Xc, this.parseTextData = Dc, this.resolveNameSpace = Bc, this.buildAttributesMap = Yc, this.isItStopNode = qc, this.replaceEntitiesValue = Kc, this.readStopNodeData = Jc, this.saveTextToParentTag = Gc, this.addChild = Uc, this.ignoreAttributesFn = bi(this.options.ignoreAttributes), this.options.stopNodes && this.options.stopNodes.length > 0) {
|
|
6592
6620
|
this.stopNodesExact = /* @__PURE__ */ new Set(), this.stopNodesWildcard = /* @__PURE__ */ new Set();
|
|
6593
6621
|
for (let i = 0; i < this.options.stopNodes.length; i++) {
|
|
6594
6622
|
const a = this.options.stopNodes[i];
|
|
@@ -6614,7 +6642,7 @@ function Dc(e, r, i, a, c, u, d) {
|
|
|
6614
6642
|
return g == null ? e : typeof g != typeof e || g !== e ? g : this.options.trimValues ? hr(e, this.options.parseTagValue, this.options.numberParseOptions) : e.trim() === e ? hr(e, this.options.parseTagValue, this.options.numberParseOptions) : e;
|
|
6615
6643
|
}
|
|
6616
6644
|
}
|
|
6617
|
-
function
|
|
6645
|
+
function Bc(e) {
|
|
6618
6646
|
if (this.options.removeNSPrefix) {
|
|
6619
6647
|
const r = e.split(":"), i = e.charAt(0) === "/" ? "/" : "";
|
|
6620
6648
|
if (r[0] === "xmlns")
|
|
@@ -6623,10 +6651,10 @@ function Hc(e) {
|
|
|
6623
6651
|
}
|
|
6624
6652
|
return e;
|
|
6625
6653
|
}
|
|
6626
|
-
const
|
|
6654
|
+
const Hc = new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`, "gm");
|
|
6627
6655
|
function Yc(e, r, i) {
|
|
6628
6656
|
if (this.options.ignoreAttributes !== !0 && typeof e == "string") {
|
|
6629
|
-
const a = yi(e,
|
|
6657
|
+
const a = yi(e, Hc), c = a.length, u = {};
|
|
6630
6658
|
for (let d = 0; d < c; d++) {
|
|
6631
6659
|
const g = this.resolveNameSpace(a[d][1]);
|
|
6632
6660
|
if (this.ignoreAttributesFn(g, r))
|
|
@@ -6699,34 +6727,34 @@ const Xc = function(e) {
|
|
|
6699
6727
|
} else {
|
|
6700
6728
|
let m = pr(e, d, this.options.removeNSPrefix), b = m.tagName;
|
|
6701
6729
|
const T = m.rawTagName;
|
|
6702
|
-
let _ = m.tagExp, I = m.attrExpPresent,
|
|
6730
|
+
let _ = m.tagExp, I = m.attrExpPresent, $ = m.closeIndex;
|
|
6703
6731
|
this.options.transformTagName && (b = this.options.transformTagName(b)), i && a && i.tagname !== "!xml" && (a = this.saveTextToParentTag(a, i, c, !1));
|
|
6704
6732
|
const A = i;
|
|
6705
6733
|
A && this.options.unpairedTags.indexOf(A.tagname) !== -1 && (i = this.tagsNodeStack.pop(), c = c.substring(0, c.lastIndexOf("."))), b !== r.tagname && (c += c ? "." + b : b);
|
|
6706
6734
|
const S = d;
|
|
6707
6735
|
if (this.isItStopNode(this.stopNodesExact, this.stopNodesWildcard, c, b)) {
|
|
6708
|
-
let
|
|
6736
|
+
let C = "";
|
|
6709
6737
|
if (_.length > 0 && _.lastIndexOf("/") === _.length - 1)
|
|
6710
6738
|
b[b.length - 1] === "/" ? (b = b.substr(0, b.length - 1), c = c.substr(0, c.length - 1), _ = b) : _ = _.substr(0, _.length - 1), d = m.closeIndex;
|
|
6711
6739
|
else if (this.options.unpairedTags.indexOf(b) !== -1)
|
|
6712
6740
|
d = m.closeIndex;
|
|
6713
6741
|
else {
|
|
6714
|
-
const W = this.readStopNodeData(e, T,
|
|
6742
|
+
const W = this.readStopNodeData(e, T, $ + 1);
|
|
6715
6743
|
if (!W) throw new Error(`Unexpected end of ${T}`);
|
|
6716
|
-
d = W.i,
|
|
6744
|
+
d = W.i, C = W.tagContent;
|
|
6717
6745
|
}
|
|
6718
6746
|
const q = new ct(b);
|
|
6719
|
-
b !== _ && I && (q[":@"] = this.buildAttributesMap(_, c, b)),
|
|
6747
|
+
b !== _ && I && (q[":@"] = this.buildAttributesMap(_, c, b)), C && (C = this.parseTextData(C, b, c, !0, I, !0, !0)), c = c.substr(0, c.lastIndexOf(".")), q.add(this.options.textNodeName, C), this.addChild(i, q, c, S);
|
|
6720
6748
|
} else {
|
|
6721
6749
|
if (_.length > 0 && _.lastIndexOf("/") === _.length - 1) {
|
|
6722
6750
|
b[b.length - 1] === "/" ? (b = b.substr(0, b.length - 1), c = c.substr(0, c.length - 1), _ = b) : _ = _.substr(0, _.length - 1), this.options.transformTagName && (b = this.options.transformTagName(b));
|
|
6723
|
-
const
|
|
6724
|
-
b !== _ && I && (
|
|
6751
|
+
const C = new ct(b);
|
|
6752
|
+
b !== _ && I && (C[":@"] = this.buildAttributesMap(_, c, b)), this.addChild(i, C, c, S), c = c.substr(0, c.lastIndexOf("."));
|
|
6725
6753
|
} else {
|
|
6726
|
-
const
|
|
6727
|
-
this.tagsNodeStack.push(i), b !== _ && I && (
|
|
6754
|
+
const C = new ct(b);
|
|
6755
|
+
this.tagsNodeStack.push(i), b !== _ && I && (C[":@"] = this.buildAttributesMap(_, c, b)), this.addChild(i, C, c, S), i = C;
|
|
6728
6756
|
}
|
|
6729
|
-
a = "", d =
|
|
6757
|
+
a = "", d = $;
|
|
6730
6758
|
}
|
|
6731
6759
|
}
|
|
6732
6760
|
else
|
|
@@ -6915,7 +6943,7 @@ class nl {
|
|
|
6915
6943
|
if (u !== !0)
|
|
6916
6944
|
throw Error(`${u.err.msg}:${u.err.line}:${u.err.col}`);
|
|
6917
6945
|
}
|
|
6918
|
-
const a = new
|
|
6946
|
+
const a = new Fc(this.options);
|
|
6919
6947
|
a.addExternalEntities(this.externalEntities);
|
|
6920
6948
|
const c = a.parseXml(r);
|
|
6921
6949
|
return this.options.preserveOrder || c === void 0 ? c : Zc(c, this.options);
|
|
@@ -6972,14 +7000,14 @@ function wi(e, r, i, a) {
|
|
|
6972
7000
|
continue;
|
|
6973
7001
|
} else if (m[0] === "?") {
|
|
6974
7002
|
const A = Ao(g[":@"], r), S = m === "?xml" ? "" : a;
|
|
6975
|
-
let
|
|
6976
|
-
|
|
7003
|
+
let C = g[m][0][r.textNodeName];
|
|
7004
|
+
C = C.length !== 0 ? " " + C : "", c += S + `<${m}${C}${A}?>`, u = !0;
|
|
6977
7005
|
continue;
|
|
6978
7006
|
}
|
|
6979
7007
|
let T = a;
|
|
6980
7008
|
T !== "" && (T += r.indentBy);
|
|
6981
|
-
const _ = Ao(g[":@"], r), I = a + `<${m}${_}`,
|
|
6982
|
-
r.unpairedTags.indexOf(m) !== -1 ? r.suppressUnpairedNode ? c += I + ">" : c += I + "/>" : (
|
|
7009
|
+
const _ = Ao(g[":@"], r), I = a + `<${m}${_}`, $ = wi(g[m], r, b, T);
|
|
7010
|
+
r.unpairedTags.indexOf(m) !== -1 ? r.suppressUnpairedNode ? c += I + ">" : c += I + "/>" : (!$ || $.length === 0) && r.suppressEmptyNode ? c += I + "/>" : $ && $.endsWith(">") ? c += I + `>${$}${a}</${m}>` : (c += I + ">", $ && a !== "" && ($.includes("/>") || $.includes("</")) ? c += a + r.indentBy + $ + a : c += $, c += `</${m}>`), u = !0;
|
|
6983
7011
|
}
|
|
6984
7012
|
return c;
|
|
6985
7013
|
}
|
|
@@ -7167,7 +7195,7 @@ const fl = /* @__PURE__ */ Te(({
|
|
|
7167
7195
|
shouldStripStyles: u = !0,
|
|
7168
7196
|
...d
|
|
7169
7197
|
}, g) => {
|
|
7170
|
-
const b = ["id"].map((A) => `@_${A}`), T = ["class"].map((A) => `@_${A}`), _ = ["fill", "stroke", "style"].map((A) => `@_${A}`), I = ["x", "y"].map((A) => `@_${A}`),
|
|
7198
|
+
const b = ["id"].map((A) => `@_${A}`), T = ["class"].map((A) => `@_${A}`), _ = ["fill", "stroke", "style"].map((A) => `@_${A}`), I = ["x", "y"].map((A) => `@_${A}`), $ = () => {
|
|
7171
7199
|
const A = new nl({
|
|
7172
7200
|
attributeNamePrefix: "@_",
|
|
7173
7201
|
ignoreAttributes: !1,
|
|
@@ -7198,15 +7226,15 @@ const fl = /* @__PURE__ */ Te(({
|
|
|
7198
7226
|
attributeNamePrefix: "@_",
|
|
7199
7227
|
format: !1,
|
|
7200
7228
|
ignoreAttributes: !1
|
|
7201
|
-
}),
|
|
7202
|
-
return S.build(
|
|
7229
|
+
}), C = A.parse(r);
|
|
7230
|
+
return S.build(C);
|
|
7203
7231
|
};
|
|
7204
7232
|
return /* @__PURE__ */ w.jsx(
|
|
7205
7233
|
"figure",
|
|
7206
7234
|
{
|
|
7207
7235
|
...d,
|
|
7208
7236
|
ref: g,
|
|
7209
|
-
dangerouslySetInnerHTML: { __html:
|
|
7237
|
+
dangerouslySetInnerHTML: { __html: $() },
|
|
7210
7238
|
role: "img"
|
|
7211
7239
|
}
|
|
7212
7240
|
);
|
|
@@ -7237,10 +7265,10 @@ const Mo = "base-", pl = /* @__PURE__ */ Te(({
|
|
|
7237
7265
|
verticalSpacing: g = 0,
|
|
7238
7266
|
...m
|
|
7239
7267
|
}, b) => {
|
|
7240
|
-
const T = we(null), [_, I] = Oe(NaN), [
|
|
7241
|
-
const
|
|
7242
|
-
if (!
|
|
7243
|
-
const K =
|
|
7268
|
+
const T = we(null), [_, I] = Oe(NaN), [$, A] = Oe(NaN), [S, C] = Oe(NaN), [q, W] = Oe(NaN), Y = () => be.from(T.current)?.width ?? 0, J = () => be.from(T.current)?.height ?? 0, x = () => {
|
|
7269
|
+
const B = T.current;
|
|
7270
|
+
if (!B) return;
|
|
7271
|
+
const K = B.children, oe = d;
|
|
7244
7272
|
if (oe <= 0) {
|
|
7245
7273
|
console.error("[etudes::MasonryGrid] You must specify a minimum of 1 section(s) (a.k.a. row(s) for horizontal orientation, column(s) for vertical orientation) for a MasonryGrid instance");
|
|
7246
7274
|
return;
|
|
@@ -7251,16 +7279,16 @@ const Mo = "base-", pl = /* @__PURE__ */ Te(({
|
|
|
7251
7279
|
if (!(z instanceof HTMLElement)) continue;
|
|
7252
7280
|
const te = zo(z, d), [ne, ae] = Ro(Q, te);
|
|
7253
7281
|
z.role = "gridcell", z.style.position = "absolute", z.style.width = `calc(${100 / oe * te}% - ${a * (oe - 1) / oe * te}px + ${a * (te - 1)}px)`, z.style.height = "", z.style.left = `calc(${100 / oe * ne}% - ${a * (oe - 1) / oe * ne}px + ${a * ne}px)`, z.style.top = `${ae + (ae === 0 ? 0 : g)}px`;
|
|
7254
|
-
for (let
|
|
7255
|
-
Q[ne +
|
|
7282
|
+
for (let F = 0; F < te; F++)
|
|
7283
|
+
Q[ne + F] = ae + (ae === 0 ? 0 : g) + (be.from(z)?.height ?? 0);
|
|
7256
7284
|
if (e && ne + te === oe) {
|
|
7257
|
-
const
|
|
7285
|
+
const F = kt(Q);
|
|
7258
7286
|
for (let R = 0; R < oe; R++)
|
|
7259
|
-
Q[R] =
|
|
7287
|
+
Q[R] = F;
|
|
7260
7288
|
}
|
|
7261
7289
|
}
|
|
7262
7290
|
const X = Y(), D = kt(Q, oe);
|
|
7263
|
-
if (I(X), A(D), isNaN(D) || (
|
|
7291
|
+
if (I(X), A(D), isNaN(D) || (B.style.height = `${D}px`), c)
|
|
7264
7292
|
for (const z of Array.from(K))
|
|
7265
7293
|
z instanceof HTMLElement && (z.style.left = `calc(${X}px - ${z.style.left} - ${z.getBoundingClientRect().width}px)`);
|
|
7266
7294
|
} else {
|
|
@@ -7269,35 +7297,35 @@ const Mo = "base-", pl = /* @__PURE__ */ Te(({
|
|
|
7269
7297
|
if (!(z instanceof HTMLElement)) continue;
|
|
7270
7298
|
const te = zo(z, d), [ne, ae] = Ro(Q, te);
|
|
7271
7299
|
z.style.position = "absolute", z.style.width = "", z.style.height = `calc(${100 / oe * te}% - ${g * (oe - 1) / oe * te}px + ${g * (te - 1)}px)`, z.style.top = `calc(${100 / oe * ne}% - ${g * (oe - 1) / oe * ne}px + ${g * ne}px)`, z.style.left = `${ae + (ae === 0 ? 0 : a)}px`;
|
|
7272
|
-
for (let
|
|
7273
|
-
Q[ne +
|
|
7300
|
+
for (let F = 0; F < te; F++)
|
|
7301
|
+
Q[ne + F] = ae + (ae === 0 ? 0 : a) + (be.from(z)?.width ?? 0);
|
|
7274
7302
|
if (e && ne + te === oe) {
|
|
7275
|
-
const
|
|
7303
|
+
const F = kt(Q);
|
|
7276
7304
|
for (let R = 0; R < oe; R++)
|
|
7277
|
-
Q[R] =
|
|
7305
|
+
Q[R] = F;
|
|
7278
7306
|
}
|
|
7279
7307
|
}
|
|
7280
7308
|
const X = J(), D = kt(Q, oe);
|
|
7281
|
-
if (A(X), I(D), isNaN(D) || (
|
|
7309
|
+
if (A(X), I(D), isNaN(D) || (B.style.width = `${D}px`), c)
|
|
7282
7310
|
for (const z of Array.from(K))
|
|
7283
7311
|
z instanceof HTMLElement && (z.style.top = `calc(${X}px - ${z.style.top} - ${z.getBoundingClientRect().height}px)`);
|
|
7284
7312
|
}
|
|
7285
|
-
}, P =
|
|
7286
|
-
const K = be.size(be.from(
|
|
7287
|
-
(_ !== oe ||
|
|
7313
|
+
}, P = he((B) => {
|
|
7314
|
+
const K = be.size(be.from(B) ?? be.zero), oe = Y(), Q = J();
|
|
7315
|
+
(_ !== oe || $ !== Q || K.width !== S || K.height !== q) && (x(), C(K.width), W(K.height));
|
|
7288
7316
|
}, [e, a, c, d, g, u]);
|
|
7289
7317
|
mr(T, {
|
|
7290
7318
|
onResize: P
|
|
7291
7319
|
}), Ee(() => {
|
|
7292
|
-
const
|
|
7293
|
-
if (
|
|
7294
|
-
const K =
|
|
7320
|
+
const B = ml(T.current?.innerHTML);
|
|
7321
|
+
if (B.length === 0) return x();
|
|
7322
|
+
const K = B.length;
|
|
7295
7323
|
for (let oe = 0; oe < K; oe++) {
|
|
7296
|
-
const Q =
|
|
7324
|
+
const Q = B[oe], X = new Image();
|
|
7297
7325
|
X.src = Q, X.onload = () => x();
|
|
7298
7326
|
}
|
|
7299
7327
|
}, [r]);
|
|
7300
|
-
const E = hl({ orientation: u }), M = gl({ orientation: u, minHeight:
|
|
7328
|
+
const E = hl({ orientation: u }), M = gl({ orientation: u, minHeight: $, minWidth: _ });
|
|
7301
7329
|
return /* @__PURE__ */ w.jsx(
|
|
7302
7330
|
"div",
|
|
7303
7331
|
{
|
|
@@ -7374,24 +7402,24 @@ const Ni = /* @__PURE__ */ Te(({
|
|
|
7374
7402
|
range: T,
|
|
7375
7403
|
steps: _ = -1,
|
|
7376
7404
|
onChange: I,
|
|
7377
|
-
|
|
7405
|
+
...$
|
|
7378
7406
|
}, A) => {
|
|
7379
|
-
const S = we(null),
|
|
7407
|
+
const S = we(null), C = nt(S), q = we(null), W = we(null), [Y, J] = Oe(T ?? [m, g]), x = Nl(m, g, _), [P, E] = Y.map((U) => at(U, m, g, b, C, d, c, a)), M = E - P, B = ze(e, {
|
|
7380
7408
|
gutter: En,
|
|
7381
7409
|
highlight: Nn,
|
|
7382
|
-
knob:
|
|
7410
|
+
knob: jt,
|
|
7383
7411
|
knobContainer: tn,
|
|
7384
|
-
label:
|
|
7385
|
-
}), K =
|
|
7386
|
-
const fe = b === "horizontal" ? Z : G,
|
|
7387
|
-
return
|
|
7388
|
-
}, [d, c, a, m, g, b, Y[1], be.toString(
|
|
7389
|
-
const fe = b === "horizontal" ? Z : G,
|
|
7390
|
-
return
|
|
7391
|
-
}, [d, c, a, m, g, b, Y[0], be.toString(
|
|
7412
|
+
label: $t
|
|
7413
|
+
}), K = he((U, Z, G) => {
|
|
7414
|
+
const fe = b === "horizontal" ? Z : G, ge = at(m, m, g, b, C, d, c, a), ue = at(Y[1], m, g, b, C, d, c, a), Ne = at(U, m, g, b, C, d, c, a) + fe;
|
|
7415
|
+
return Lo(Math.max(ge, Math.min(ue, Ne)), m, g, b, C, d, c, a);
|
|
7416
|
+
}, [d, c, a, m, g, b, Y[1], be.toString(C)]), oe = he((U, Z, G) => {
|
|
7417
|
+
const fe = b === "horizontal" ? Z : G, ge = at(Y[0], m, g, b, C, d, c, a), ue = at(g, m, g, b, C, d, c, a), Ne = at(U, m, g, b, C, d, c, a) + fe;
|
|
7418
|
+
return Lo(Math.max(ge, Math.min(ue, Ne)), m, g, b, C, d, c, a);
|
|
7419
|
+
}, [d, c, a, m, g, b, Y[0], be.toString(C)]), { isDragging: Q, isReleasing: X, value: D, setValue: z } = zt(q, {
|
|
7392
7420
|
initialValue: T?.[0] ?? m,
|
|
7393
7421
|
transform: K
|
|
7394
|
-
}), { isDragging: te, isReleasing: ne, value: ae, setValue:
|
|
7422
|
+
}), { isDragging: te, isReleasing: ne, value: ae, setValue: F } = zt(W, {
|
|
7395
7423
|
initialValue: T?.[1] ?? g,
|
|
7396
7424
|
transform: oe
|
|
7397
7425
|
}), R = vl({ isDraggingEndKnob: te, isDraggingStartKnob: Q, isReleasingEndKnob: ne, isReleasingStartKnob: X }), k = yl({ orientation: b, highlightLength: M, start: P, knobPadding: u, knobWidth: d, knobHeight: c });
|
|
@@ -7400,71 +7428,71 @@ const Ni = /* @__PURE__ */ Te(({
|
|
|
7400
7428
|
}, [D, ae]), Ee(() => {
|
|
7401
7429
|
I?.(Y);
|
|
7402
7430
|
}, [Y[0], Y[1]]), Ee(() => {
|
|
7403
|
-
Q || te || ne || qe(T, Y) || (J(T ?? [m, g]), z(T?.[0] ?? m),
|
|
7431
|
+
Q || te || ne || qe(T, Y) || (J(T ?? [m, g]), z(T?.[0] ?? m), F(T?.[1] ?? g));
|
|
7404
7432
|
}, [T?.[0], T?.[1], Q, te, ne]), Ee(() => {
|
|
7405
|
-
x && z(
|
|
7433
|
+
x && z(Fo(D, x));
|
|
7406
7434
|
}, [X, We(x)]), Ee(() => {
|
|
7407
|
-
!x || !ne ||
|
|
7435
|
+
!x || !ne || F(Fo(ae, x));
|
|
7408
7436
|
}, [ne, We(x)]), /* @__PURE__ */ w.jsx(
|
|
7409
7437
|
"div",
|
|
7410
7438
|
{
|
|
7411
|
-
|
|
7439
|
+
...$,
|
|
7412
7440
|
ref: A,
|
|
7413
7441
|
"aria-valuemax": g,
|
|
7414
7442
|
"aria-valuemin": m,
|
|
7415
7443
|
className: se(r, b),
|
|
7416
7444
|
role: "slider",
|
|
7417
7445
|
children: /* @__PURE__ */ w.jsxs("div", { ref: S, style: k.body, children: [
|
|
7418
|
-
/* @__PURE__ */ w.jsx(
|
|
7419
|
-
/* @__PURE__ */ w.jsx(
|
|
7446
|
+
/* @__PURE__ */ w.jsx(me, { element: B.gutter ?? /* @__PURE__ */ w.jsx(En, {}), style: ce(k.gutter) }),
|
|
7447
|
+
/* @__PURE__ */ w.jsx(me, { element: B.highlight ?? /* @__PURE__ */ w.jsx(Nn, {}), style: ce(k.highlight) }),
|
|
7420
7448
|
/* @__PURE__ */ w.jsx(
|
|
7421
|
-
|
|
7449
|
+
me,
|
|
7422
7450
|
{
|
|
7423
7451
|
ref: q,
|
|
7424
7452
|
className: R.startKnobContainer,
|
|
7425
7453
|
disabled: qe([D, ae], [m, m]),
|
|
7426
|
-
element:
|
|
7454
|
+
element: B.knobContainer ?? /* @__PURE__ */ w.jsx(tn, {}),
|
|
7427
7455
|
style: ce(k.knobContainer, {
|
|
7428
7456
|
pointerEvents: qe([D, ae], [m, m]) ? "none" : "auto"
|
|
7429
7457
|
}, b === "horizontal" ? {
|
|
7430
7458
|
left: `${P}px`,
|
|
7431
|
-
top: `${
|
|
7459
|
+
top: `${C.height * 0.5}px`
|
|
7432
7460
|
} : {
|
|
7433
|
-
left: `${
|
|
7461
|
+
left: `${C.width * 0.5}px`,
|
|
7434
7462
|
top: `${P}px`
|
|
7435
7463
|
}),
|
|
7436
|
-
children: /* @__PURE__ */ w.jsxs(
|
|
7464
|
+
children: /* @__PURE__ */ w.jsxs(me, { className: R.startKnob, element: B.knob ?? /* @__PURE__ */ w.jsx(jt, {}), style: ce(k.knob), children: [
|
|
7437
7465
|
/* @__PURE__ */ w.jsx("div", { style: k.knobHitBox }),
|
|
7438
|
-
|
|
7466
|
+
B.label && /* @__PURE__ */ w.jsx(me, { className: R.startLabel, element: B.label ?? /* @__PURE__ */ w.jsx($t, {}), style: ce(k.label), children: Number(D.toFixed(i)).toLocaleString() })
|
|
7439
7467
|
] })
|
|
7440
7468
|
}
|
|
7441
7469
|
),
|
|
7442
7470
|
/* @__PURE__ */ w.jsx(
|
|
7443
|
-
|
|
7471
|
+
me,
|
|
7444
7472
|
{
|
|
7445
7473
|
ref: W,
|
|
7446
7474
|
className: R.endKnobContainer,
|
|
7447
7475
|
disabled: qe([D, ae], [g, g]),
|
|
7448
|
-
element:
|
|
7476
|
+
element: B.knobContainer ?? /* @__PURE__ */ w.jsx(tn, {}),
|
|
7449
7477
|
style: ce(k.knobContainer, {
|
|
7450
7478
|
pointerEvents: qe([D, ae], [g, g]) ? "none" : "auto"
|
|
7451
7479
|
}, b === "horizontal" ? {
|
|
7452
7480
|
left: `${E}px`,
|
|
7453
|
-
top: `${
|
|
7481
|
+
top: `${C.height * 0.5}px`
|
|
7454
7482
|
} : {
|
|
7455
|
-
left: `${
|
|
7483
|
+
left: `${C.width * 0.5}px`,
|
|
7456
7484
|
top: `${E}px`
|
|
7457
7485
|
}),
|
|
7458
|
-
children: /* @__PURE__ */ w.jsxs(
|
|
7486
|
+
children: /* @__PURE__ */ w.jsxs(me, { className: R.endKnob, element: B.knob ?? /* @__PURE__ */ w.jsx(jt, {}), style: ce(k.knob), children: [
|
|
7459
7487
|
/* @__PURE__ */ w.jsx("div", { style: k.knobHitBox }),
|
|
7460
|
-
|
|
7488
|
+
B.label && /* @__PURE__ */ w.jsx(me, { className: R.endLabel, element: B.label ?? /* @__PURE__ */ w.jsx($t, {}), style: ce(k.label), children: Number(ae.toFixed(i)).toLocaleString() })
|
|
7461
7489
|
] })
|
|
7462
7490
|
}
|
|
7463
7491
|
)
|
|
7464
7492
|
] })
|
|
7465
7493
|
}
|
|
7466
7494
|
);
|
|
7467
|
-
}), En = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }),
|
|
7495
|
+
}), En = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), $t = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), Nn = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), jt = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), tn = ({ ...e }) => /* @__PURE__ */ w.jsx("button", { ...e }), su = /* @__PURE__ */ Object.assign(Ni, {
|
|
7468
7496
|
/**
|
|
7469
7497
|
* Component for the gutter of a {@link RangeSlider}.
|
|
7470
7498
|
*/
|
|
@@ -7476,7 +7504,7 @@ const Ni = /* @__PURE__ */ Te(({
|
|
|
7476
7504
|
/**
|
|
7477
7505
|
* Component for the knob of a {@link RangeSlider}.
|
|
7478
7506
|
*/
|
|
7479
|
-
Knob:
|
|
7507
|
+
Knob: jt,
|
|
7480
7508
|
/**
|
|
7481
7509
|
* Component for the container of the knob of a {@link RangeSlider}.
|
|
7482
7510
|
*/
|
|
@@ -7484,7 +7512,7 @@ const Ni = /* @__PURE__ */ Te(({
|
|
|
7484
7512
|
/**
|
|
7485
7513
|
* Component for the label of a {@link RangeSlider}.
|
|
7486
7514
|
*/
|
|
7487
|
-
Label:
|
|
7515
|
+
Label: $t
|
|
7488
7516
|
});
|
|
7489
7517
|
function vl({ isDraggingStartKnob: e = !1, isReleasingStartKnob: r = !1, isDraggingEndKnob: i = !1, isReleasingEndKnob: a = !1 }) {
|
|
7490
7518
|
return {
|
|
@@ -7591,7 +7619,7 @@ function xl(e, r, i, a, c, u) {
|
|
|
7591
7619
|
function wl(e, r, i) {
|
|
7592
7620
|
return e * (i - r) + r;
|
|
7593
7621
|
}
|
|
7594
|
-
function
|
|
7622
|
+
function Lo(e, r, i, a, c, u, d, g) {
|
|
7595
7623
|
const m = xl(e, a, c, u, d, g);
|
|
7596
7624
|
return wl(m, r, i);
|
|
7597
7625
|
}
|
|
@@ -7613,7 +7641,7 @@ function at(e, r, i, a, c, u, d, g) {
|
|
|
7613
7641
|
const m = bl(e, r, i);
|
|
7614
7642
|
return El(m, a, c, u, d, g);
|
|
7615
7643
|
}
|
|
7616
|
-
function
|
|
7644
|
+
function Fo(e, r) {
|
|
7617
7645
|
const i = r.length;
|
|
7618
7646
|
let a = 0, c = 1 / 0;
|
|
7619
7647
|
for (let u = 0; u < i; u++) {
|
|
@@ -7630,7 +7658,7 @@ function Nl(e, r, i) {
|
|
|
7630
7658
|
r
|
|
7631
7659
|
];
|
|
7632
7660
|
}
|
|
7633
|
-
process.env.NODE_ENV === "development" && (Ni.displayName = "RangeSlider", En.displayName = "RangeSlider.Gutter",
|
|
7661
|
+
process.env.NODE_ENV === "development" && (Ni.displayName = "RangeSlider", En.displayName = "RangeSlider.Gutter", $t.displayName = "RangeSlider.Label", Nn.displayName = "RangeSlider.Highlight", jt.displayName = "RangeSlider.Knob");
|
|
7634
7662
|
const Si = /* @__PURE__ */ Te(({
|
|
7635
7663
|
children: e,
|
|
7636
7664
|
id: r,
|
|
@@ -7649,7 +7677,7 @@ const Si = /* @__PURE__ */ Te(({
|
|
|
7649
7677
|
});
|
|
7650
7678
|
return /* @__PURE__ */ w.jsxs("div", { ...m, ref: b, style: fr.root, children: [
|
|
7651
7679
|
/* @__PURE__ */ w.jsxs(
|
|
7652
|
-
|
|
7680
|
+
me,
|
|
7653
7681
|
{
|
|
7654
7682
|
"aria-required": i ? "true" : void 0,
|
|
7655
7683
|
element: T.toggle ?? /* @__PURE__ */ w.jsx(Sn, {}),
|
|
@@ -7659,14 +7687,14 @@ const Si = /* @__PURE__ */ Te(({
|
|
|
7659
7687
|
value: d,
|
|
7660
7688
|
onChange: (_) => g?.(_.target.value),
|
|
7661
7689
|
children: [
|
|
7662
|
-
u !== void 0 && /* @__PURE__ */ w.jsx(
|
|
7663
|
-
c.map((_, I) => /* @__PURE__ */ w.jsx(
|
|
7690
|
+
u !== void 0 && /* @__PURE__ */ w.jsx(me, { disabled: !0, hidden: !0, element: T.option ?? /* @__PURE__ */ w.jsx(At, {}), value: "", children: u }),
|
|
7691
|
+
c.map((_, I) => /* @__PURE__ */ w.jsx(me, { element: T.option ?? /* @__PURE__ */ w.jsx(At, {}), value: _, children: _ }, `${I}-${_}`))
|
|
7664
7692
|
]
|
|
7665
7693
|
}
|
|
7666
7694
|
),
|
|
7667
|
-
T.expandIcon && /* @__PURE__ */ w.jsx(
|
|
7695
|
+
T.expandIcon && /* @__PURE__ */ w.jsx(me, { element: T.expandIcon, style: fr.expandIcon })
|
|
7668
7696
|
] });
|
|
7669
|
-
}), Pr = ({ children: e, style: r, ...i }) => /* @__PURE__ */ w.jsx("figure", { ...i, "aria-hidden": !0, style: ce(r, { pointerEvents: "none" }), children: e }), Sn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("select", { ...r, children: e }), At = ({ ...e }) => /* @__PURE__ */ w.jsx("option", { ...e }),
|
|
7697
|
+
}), Pr = ({ children: e, style: r, ...i }) => /* @__PURE__ */ w.jsx("figure", { ...i, "aria-hidden": !0, style: ce(r, { pointerEvents: "none" }), children: e }), Sn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("select", { ...r, children: e }), At = ({ ...e }) => /* @__PURE__ */ w.jsx("option", { ...e }), au = /* @__PURE__ */ Object.assign(Si, {
|
|
7670
7698
|
/**
|
|
7671
7699
|
* Component for the expand icon of a {@link Select}.
|
|
7672
7700
|
*/
|
|
@@ -7716,50 +7744,50 @@ const _i = /* @__PURE__ */ Te(({
|
|
|
7716
7744
|
position: T = 0,
|
|
7717
7745
|
trackPadding: _ = 0,
|
|
7718
7746
|
labelProvider: I,
|
|
7719
|
-
onDragEnd:
|
|
7747
|
+
onDragEnd: $,
|
|
7720
7748
|
onDragStart: A,
|
|
7721
7749
|
onChange: S,
|
|
7722
|
-
|
|
7750
|
+
...C
|
|
7723
7751
|
}, q) => {
|
|
7724
|
-
const W = we(null), Y = we(null), J =
|
|
7725
|
-
const
|
|
7752
|
+
const W = we(null), Y = we(null), J = he((te, ne, ae) => {
|
|
7753
|
+
const F = be.from(W.current) ?? be.zero, R = a ? 1 - te : te;
|
|
7726
7754
|
switch (b) {
|
|
7727
7755
|
case "horizontal": {
|
|
7728
|
-
const k = i ?
|
|
7756
|
+
const k = i ? F.width - g : F.width, U = R * k + ne, Z = Math.max(0, Math.min(1, U / k));
|
|
7729
7757
|
return a ? 1 - Z : Z;
|
|
7730
7758
|
}
|
|
7731
7759
|
case "vertical": {
|
|
7732
|
-
const k = i ?
|
|
7760
|
+
const k = i ? F.height - u : F.height, U = R * k + ae, Z = Math.max(0, Math.min(1, U / k));
|
|
7733
7761
|
return a ? 1 - Z : Z;
|
|
7734
7762
|
}
|
|
7735
7763
|
default:
|
|
7736
7764
|
return console.error(`[etudes::Slider] Invalid orientation: ${b}`), NaN;
|
|
7737
7765
|
}
|
|
7738
|
-
}, [W.current, i, a, g, u, b]), x =
|
|
7766
|
+
}, [W.current, i, a, g, u, b]), x = he((te) => {
|
|
7739
7767
|
if (!c) return;
|
|
7740
7768
|
const ne = be.from(W.current) ?? be.zero, ae = be.fromViewport();
|
|
7741
7769
|
switch (b) {
|
|
7742
7770
|
case "horizontal": {
|
|
7743
|
-
const
|
|
7744
|
-
|
|
7771
|
+
const F = (te.clientX + ae.left - ne.left) / ne.width, R = a ? 1 - F : F;
|
|
7772
|
+
B(R);
|
|
7745
7773
|
break;
|
|
7746
7774
|
}
|
|
7747
7775
|
case "vertical": {
|
|
7748
|
-
const
|
|
7749
|
-
|
|
7776
|
+
const F = (te.clientY + ae.top - ne.top) / ne.height, R = a ? 1 - F : F;
|
|
7777
|
+
B(R);
|
|
7750
7778
|
break;
|
|
7751
7779
|
}
|
|
7752
7780
|
default:
|
|
7753
7781
|
console.error(`[etudes::Slider] Invalid orientation: ${b}`);
|
|
7754
7782
|
}
|
|
7755
|
-
}, [W.current, a, c, b]), { isDragging: P, isReleasing: E, value: M, setValue:
|
|
7783
|
+
}, [W.current, a, c, b]), { isDragging: P, isReleasing: E, value: M, setValue: B } = zt(Y, {
|
|
7756
7784
|
initialValue: T,
|
|
7757
7785
|
transform: J,
|
|
7758
7786
|
onDragStart: A,
|
|
7759
|
-
onDragEnd:
|
|
7787
|
+
onDragEnd: $
|
|
7760
7788
|
}), K = a ? 1 - M : M, X = Sl({ orientation: b, isAtEnd: a ? M === 0 : M === 1, isAtStart: a ? M === 1 : M === 0, isDragging: P, isReleasing: E }), D = _l({ orientation: b, isClipped: i, naturalPosition: K, knobPadding: d, knobHeight: u, knobWidth: g, isTrackInteractive: c });
|
|
7761
7789
|
Ee(() => {
|
|
7762
|
-
P || T === M ||
|
|
7790
|
+
P || T === M || B(T);
|
|
7763
7791
|
}, [T]), Ee(() => {
|
|
7764
7792
|
P && m || S?.(M, P);
|
|
7765
7793
|
}, [M]), Ee(() => {
|
|
@@ -7774,7 +7802,7 @@ const _i = /* @__PURE__ */ Te(({
|
|
|
7774
7802
|
return /* @__PURE__ */ w.jsx(
|
|
7775
7803
|
"div",
|
|
7776
7804
|
{
|
|
7777
|
-
|
|
7805
|
+
...C,
|
|
7778
7806
|
ref: q,
|
|
7779
7807
|
"aria-orientation": b,
|
|
7780
7808
|
"aria-valuenow": M,
|
|
@@ -7782,7 +7810,7 @@ const _i = /* @__PURE__ */ Te(({
|
|
|
7782
7810
|
role: "slider",
|
|
7783
7811
|
children: /* @__PURE__ */ w.jsxs("div", { ref: W, style: D.body, children: [
|
|
7784
7812
|
/* @__PURE__ */ w.jsx(
|
|
7785
|
-
|
|
7813
|
+
me,
|
|
7786
7814
|
{
|
|
7787
7815
|
className: se(a ? "end" : "start", X.track),
|
|
7788
7816
|
element: z.track ?? /* @__PURE__ */ w.jsx(Mt, {}),
|
|
@@ -7798,7 +7826,7 @@ const _i = /* @__PURE__ */ Te(({
|
|
|
7798
7826
|
}
|
|
7799
7827
|
),
|
|
7800
7828
|
/* @__PURE__ */ w.jsx(
|
|
7801
|
-
|
|
7829
|
+
me,
|
|
7802
7830
|
{
|
|
7803
7831
|
className: se(a ? "start" : "end", X.track),
|
|
7804
7832
|
element: z.track ?? /* @__PURE__ */ w.jsx(Mt, {}),
|
|
@@ -7814,22 +7842,22 @@ const _i = /* @__PURE__ */ Te(({
|
|
|
7814
7842
|
}
|
|
7815
7843
|
),
|
|
7816
7844
|
/* @__PURE__ */ w.jsx(
|
|
7817
|
-
|
|
7845
|
+
me,
|
|
7818
7846
|
{
|
|
7819
7847
|
ref: Y,
|
|
7820
7848
|
className: se(X.knobContainer),
|
|
7821
7849
|
element: z.knobContainer ?? /* @__PURE__ */ w.jsx(Tn, {}),
|
|
7822
7850
|
style: D.knobContainer,
|
|
7823
|
-
children: /* @__PURE__ */ w.jsxs(
|
|
7851
|
+
children: /* @__PURE__ */ w.jsxs(me, { className: se(X.knob), element: z.knob ?? /* @__PURE__ */ w.jsx(_n, {}), style: ce(D.knob), children: [
|
|
7824
7852
|
/* @__PURE__ */ w.jsx("div", { style: D.knobHitBox }),
|
|
7825
|
-
I && /* @__PURE__ */ w.jsx(
|
|
7853
|
+
I && /* @__PURE__ */ w.jsx(me, { className: se(X.label), element: z.label ?? /* @__PURE__ */ w.jsx(On, {}), style: ce(D.label), children: I(M) })
|
|
7826
7854
|
] })
|
|
7827
7855
|
}
|
|
7828
7856
|
)
|
|
7829
7857
|
] })
|
|
7830
7858
|
}
|
|
7831
7859
|
);
|
|
7832
|
-
}), Mt = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), _n = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), Tn = ({ ...e }) => /* @__PURE__ */ w.jsx("button", { ...e }), On = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }),
|
|
7860
|
+
}), Mt = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), _n = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), Tn = ({ ...e }) => /* @__PURE__ */ w.jsx("button", { ...e }), On = ({ ...e }) => /* @__PURE__ */ w.jsx("div", { ...e }), cu = /* @__PURE__ */ Object.assign(_i, {
|
|
7833
7861
|
/**
|
|
7834
7862
|
* Component for the slide track on either side of the knob of a
|
|
7835
7863
|
* {@link Slider}.
|
|
@@ -7962,22 +7990,22 @@ const Ti = /* @__PURE__ */ Te(({
|
|
|
7962
7990
|
onlyDispatchesOnDragEnd: T = !1,
|
|
7963
7991
|
orientation: _ = "vertical",
|
|
7964
7992
|
steps: I = Oi(10),
|
|
7965
|
-
trackPadding:
|
|
7993
|
+
trackPadding: $ = 0,
|
|
7966
7994
|
onDragEnd: A,
|
|
7967
7995
|
onDragStart: S,
|
|
7968
|
-
onIndexChange:
|
|
7996
|
+
onIndexChange: C,
|
|
7969
7997
|
onPositionChange: q,
|
|
7970
7998
|
...W
|
|
7971
7999
|
}, Y) => {
|
|
7972
|
-
const J = we(null), x = we(null), P = nt(J), [E, M] = Oe(i),
|
|
8000
|
+
const J = we(null), x = we(null), P = nt(J), [E, M] = Oe(i), B = he((k, U, Z) => {
|
|
7973
8001
|
const G = c ? tt(k) : k;
|
|
7974
8002
|
switch (_) {
|
|
7975
8003
|
case "horizontal": {
|
|
7976
|
-
const fe = a ? P.width - m : P.width,
|
|
8004
|
+
const fe = a ? P.width - m : P.width, ge = G * fe + U, ue = Qt(ge / fe);
|
|
7977
8005
|
return c ? tt(ue) : ue;
|
|
7978
8006
|
}
|
|
7979
8007
|
case "vertical": {
|
|
7980
|
-
const fe = a ? P.height - d : P.height,
|
|
8008
|
+
const fe = a ? P.height - d : P.height, ge = G * fe + Z, ue = Qt(ge / fe);
|
|
7981
8009
|
return c ? tt(ue) : ue;
|
|
7982
8010
|
}
|
|
7983
8011
|
default:
|
|
@@ -7985,18 +8013,18 @@ const Ti = /* @__PURE__ */ Te(({
|
|
|
7985
8013
|
}
|
|
7986
8014
|
}, [P.width, P.height, a, c, m, d, _]), { isDragging: K, isReleasing: oe, value: Q, setValue: X } = zt(x, {
|
|
7987
8015
|
initialValue: dt(i, I),
|
|
7988
|
-
transform:
|
|
8016
|
+
transform: B,
|
|
7989
8017
|
onDragStart: S,
|
|
7990
8018
|
onDragEnd: A
|
|
7991
|
-
}), D =
|
|
8019
|
+
}), D = he((k) => {
|
|
7992
8020
|
if (!u) return;
|
|
7993
8021
|
const U = be.fromViewport();
|
|
7994
8022
|
switch (_) {
|
|
7995
8023
|
case "horizontal": {
|
|
7996
8024
|
const Z = (k.clientX + U.left - P.left) / P.width, G = c ? tt(Z) : Z, fe = It(G, I);
|
|
7997
8025
|
if (fe === E) {
|
|
7998
|
-
const
|
|
7999
|
-
M(Qt(
|
|
8026
|
+
const ge = G > Q ? fe + 1 : fe - 1;
|
|
8027
|
+
M(Qt(ge, I.length - 1));
|
|
8000
8028
|
} else
|
|
8001
8029
|
M(fe);
|
|
8002
8030
|
break;
|
|
@@ -8004,18 +8032,18 @@ const Ti = /* @__PURE__ */ Te(({
|
|
|
8004
8032
|
case "vertical": {
|
|
8005
8033
|
const Z = (k.clientY + U.top - P.top) / P.height, G = c ? tt(Z) : Z, fe = It(G, I);
|
|
8006
8034
|
if (fe === E) {
|
|
8007
|
-
const
|
|
8008
|
-
X(ue), M(Qt(
|
|
8035
|
+
const ge = G > Q ? fe + 1 : fe - 1, ue = dt(ge, I);
|
|
8036
|
+
X(ue), M(Qt(ge, I.length - 1));
|
|
8009
8037
|
} else {
|
|
8010
|
-
const
|
|
8011
|
-
X(
|
|
8038
|
+
const ge = dt(fe, I);
|
|
8039
|
+
X(ge), M(fe);
|
|
8012
8040
|
}
|
|
8013
8041
|
break;
|
|
8014
8042
|
}
|
|
8015
8043
|
default:
|
|
8016
8044
|
console.error(`[etudes::StepSlider] Invalid orientation: ${_}`);
|
|
8017
8045
|
}
|
|
8018
|
-
}, [P.width, P.left, P.top, P.height, E, Q, c, u, _, We(I)]), z = c ? tt(Q) : Q, ae = Tl({ orientation: _, isAtEnd: c ? Q === 0 : Q === 1, isAtStart: c ? Q === 1 : Q === 0, isDragging: K, isReleasing: oe }),
|
|
8046
|
+
}, [P.width, P.left, P.top, P.height, E, Q, c, u, _, We(I)]), z = c ? tt(Q) : Q, ae = Tl({ orientation: _, isAtEnd: c ? Q === 0 : Q === 1, isAtStart: c ? Q === 1 : Q === 0, isDragging: K, isReleasing: oe }), F = Ol({ orientation: _, naturalPosition: z, isClipped: a, knobPadding: g, knobHeight: d, knobWidth: m, isTrackInteractive: u }), R = ze(e, {
|
|
8019
8047
|
knob: Pn,
|
|
8020
8048
|
knobContainer: In,
|
|
8021
8049
|
label: kn,
|
|
@@ -8034,7 +8062,7 @@ const Ti = /* @__PURE__ */ Te(({
|
|
|
8034
8062
|
}, [Q, K, T, We(I)]), Ee(() => {
|
|
8035
8063
|
q?.(Q, K);
|
|
8036
8064
|
}, [Q, K]), Ee(() => {
|
|
8037
|
-
|
|
8065
|
+
C?.(E, K);
|
|
8038
8066
|
}, [E, K]), /* @__PURE__ */ w.jsx(
|
|
8039
8067
|
"div",
|
|
8040
8068
|
{
|
|
@@ -8043,49 +8071,49 @@ const Ti = /* @__PURE__ */ Te(({
|
|
|
8043
8071
|
"aria-valuenow": E,
|
|
8044
8072
|
className: se(r, ae.root),
|
|
8045
8073
|
role: "slider",
|
|
8046
|
-
children: /* @__PURE__ */ w.jsxs("div", { ref: J, style:
|
|
8074
|
+
children: /* @__PURE__ */ w.jsxs("div", { ref: J, style: F.body, children: [
|
|
8047
8075
|
/* @__PURE__ */ w.jsx(
|
|
8048
|
-
|
|
8076
|
+
me,
|
|
8049
8077
|
{
|
|
8050
8078
|
className: se(c ? "end" : "start", ae.track),
|
|
8051
8079
|
element: R.track ?? /* @__PURE__ */ w.jsx(Rt, {}),
|
|
8052
|
-
style: ce(
|
|
8053
|
-
height: `calc(${z * 100}% - ${
|
|
8080
|
+
style: ce(F.track, _ === "vertical" ? {
|
|
8081
|
+
height: `calc(${z * 100}% - ${$ <= 0 ? 0 : d * 0.5}px - ${$}px)`,
|
|
8054
8082
|
top: "0"
|
|
8055
8083
|
} : {
|
|
8056
8084
|
left: "0",
|
|
8057
|
-
width: `calc(${z * 100}% - ${
|
|
8085
|
+
width: `calc(${z * 100}% - ${$ <= 0 ? 0 : m * 0.5}px - ${$}px)`
|
|
8058
8086
|
}),
|
|
8059
8087
|
onClick: D,
|
|
8060
|
-
children: /* @__PURE__ */ w.jsx("div", { style:
|
|
8088
|
+
children: /* @__PURE__ */ w.jsx("div", { style: F.trackHitBox })
|
|
8061
8089
|
}
|
|
8062
8090
|
),
|
|
8063
8091
|
/* @__PURE__ */ w.jsx(
|
|
8064
|
-
|
|
8092
|
+
me,
|
|
8065
8093
|
{
|
|
8066
8094
|
className: se(c ? "start" : "end", ae.track),
|
|
8067
8095
|
element: R.track ?? /* @__PURE__ */ w.jsx(Rt, {}),
|
|
8068
|
-
style: ce(
|
|
8096
|
+
style: ce(F.track, _ === "vertical" ? {
|
|
8069
8097
|
bottom: "0",
|
|
8070
|
-
height: `calc(${tt(z) * 100}% - ${
|
|
8098
|
+
height: `calc(${tt(z) * 100}% - ${$ <= 0 ? 0 : d * 0.5}px - ${$}px)`
|
|
8071
8099
|
} : {
|
|
8072
8100
|
right: "0",
|
|
8073
|
-
width: `calc(${tt(z) * 100}% - ${
|
|
8101
|
+
width: `calc(${tt(z) * 100}% - ${$ <= 0 ? 0 : m * 0.5}px - ${$}px)`
|
|
8074
8102
|
}),
|
|
8075
8103
|
onClick: D,
|
|
8076
|
-
children: /* @__PURE__ */ w.jsx("div", { style:
|
|
8104
|
+
children: /* @__PURE__ */ w.jsx("div", { style: F.trackHitBox })
|
|
8077
8105
|
}
|
|
8078
8106
|
),
|
|
8079
8107
|
/* @__PURE__ */ w.jsx(
|
|
8080
|
-
|
|
8108
|
+
me,
|
|
8081
8109
|
{
|
|
8082
8110
|
ref: x,
|
|
8083
8111
|
className: se(ae.knobContainer),
|
|
8084
8112
|
element: R.knobContainer ?? /* @__PURE__ */ w.jsx(In, {}),
|
|
8085
|
-
style: ce(
|
|
8086
|
-
children: /* @__PURE__ */ w.jsxs(
|
|
8087
|
-
/* @__PURE__ */ w.jsx("div", { style:
|
|
8088
|
-
I && b && /* @__PURE__ */ w.jsx(
|
|
8113
|
+
style: ce(F.knobContainer),
|
|
8114
|
+
children: /* @__PURE__ */ w.jsxs(me, { className: se(ae.knob), element: R.knob ?? /* @__PURE__ */ w.jsx(Pn, {}), style: ce(F.knob), children: [
|
|
8115
|
+
/* @__PURE__ */ w.jsx("div", { style: F.knobHitBox }),
|
|
8116
|
+
I && b && /* @__PURE__ */ w.jsx(me, { className: se(ae.label), element: R.label ?? /* @__PURE__ */ w.jsx(kn, {}), style: ce(F.label), children: b(Q, It(Q, I)) })
|
|
8089
8117
|
] })
|
|
8090
8118
|
}
|
|
8091
8119
|
)
|
|
@@ -8101,7 +8129,7 @@ function Oi(e) {
|
|
|
8101
8129
|
const r = 1 / (e - 1);
|
|
8102
8130
|
return Array(e).fill(null).map((i, a) => r * a);
|
|
8103
8131
|
}
|
|
8104
|
-
const
|
|
8132
|
+
const lu = /* @__PURE__ */ Object.assign(Ti, {
|
|
8105
8133
|
/**
|
|
8106
8134
|
* Component for the knob of a {@link StepSlider}.
|
|
8107
8135
|
*/
|
|
@@ -8257,19 +8285,19 @@ const Pl = /* @__PURE__ */ Te(({
|
|
|
8257
8285
|
onSwipeUp: d,
|
|
8258
8286
|
...g
|
|
8259
8287
|
}, m) => {
|
|
8260
|
-
const [b, T] = Oe(void 0), [_, I] = Oe(void 0), [
|
|
8288
|
+
const [b, T] = Oe(void 0), [_, I] = Oe(void 0), [$, A] = Oe(NaN), S = (Y, J) => {
|
|
8261
8289
|
if (isNaN(Y) || isNaN(J)) return W();
|
|
8262
8290
|
T(_e.make(Y, J));
|
|
8263
|
-
},
|
|
8291
|
+
}, C = (Y, J) => {
|
|
8264
8292
|
const x = b;
|
|
8265
8293
|
if (x === void 0) return;
|
|
8266
|
-
const P = x.x !== Y || x.y !== J, E = !isNaN(
|
|
8294
|
+
const P = x.x !== Y || x.y !== J, E = !isNaN($);
|
|
8267
8295
|
P && (E || A(Date.now()), I(_e.make(Y, J)));
|
|
8268
8296
|
}, q = () => {
|
|
8269
|
-
const Y =
|
|
8297
|
+
const Y = $, J = b, x = _;
|
|
8270
8298
|
if (isNaN(Y) || J === void 0 || x === void 0) return;
|
|
8271
|
-
const P = Date.now() - Y, E = x.x - J.x, M = x.y - J.y,
|
|
8272
|
-
r && (Math.abs(
|
|
8299
|
+
const P = Date.now() - Y, E = x.x - J.x, M = x.y - J.y, B = E / P, K = M / P;
|
|
8300
|
+
r && (Math.abs(B) >= i && Math.abs(B) > Math.abs(K) ? B > 0 ? u?.() : c?.() : Math.abs(K) >= i && Math.abs(K) > Math.abs(B) && (K > 0 ? a?.() : d?.())), W();
|
|
8273
8301
|
}, W = () => {
|
|
8274
8302
|
T(void 0), I(void 0), A(NaN);
|
|
8275
8303
|
};
|
|
@@ -8280,10 +8308,10 @@ const Pl = /* @__PURE__ */ Te(({
|
|
|
8280
8308
|
ref: m,
|
|
8281
8309
|
onMouseDown: (Y) => S(Y.clientX, Y.clientY),
|
|
8282
8310
|
onMouseLeave: () => W(),
|
|
8283
|
-
onMouseMove: (Y) =>
|
|
8311
|
+
onMouseMove: (Y) => C(Y.clientX, Y.clientY),
|
|
8284
8312
|
onMouseUp: () => q(),
|
|
8285
8313
|
onTouchEnd: () => q(),
|
|
8286
|
-
onTouchMove: (Y) =>
|
|
8314
|
+
onTouchMove: (Y) => C(Y.targetTouches[0].clientX, Y.targetTouches[0].clientY),
|
|
8287
8315
|
onTouchStart: (Y) => S(Y.targetTouches[0].clientX, Y.targetTouches[0].clientY),
|
|
8288
8316
|
children: e
|
|
8289
8317
|
}
|
|
@@ -8313,22 +8341,22 @@ const Pi = /* @__PURE__ */ Te(({
|
|
|
8313
8341
|
...g
|
|
8314
8342
|
}, m) => {
|
|
8315
8343
|
const b = we(null), T = ci(b), _ = ze(r, {
|
|
8316
|
-
knob:
|
|
8317
|
-
track:
|
|
8318
|
-
}), I = kl({ isOn: a }),
|
|
8319
|
-
return /* @__PURE__ */ w.jsxs("label", { ...g, ref: m, className: se(e, I.root), style: ce(u,
|
|
8320
|
-
/* @__PURE__ */ w.jsx("input", { checked: a, style:
|
|
8321
|
-
/* @__PURE__ */ w.jsx(
|
|
8344
|
+
knob: $n,
|
|
8345
|
+
track: Cn
|
|
8346
|
+
}), I = kl({ isOn: a }), $ = Cl({ isOn: a, isInverted: i, orientation: c, knobSize: T });
|
|
8347
|
+
return /* @__PURE__ */ w.jsxs("label", { ...g, ref: m, className: se(e, I.root), style: ce(u, $.root), children: [
|
|
8348
|
+
/* @__PURE__ */ w.jsx("input", { checked: a, style: $.input, type: "checkbox", onChange: (A) => d?.(A.target.checked) }),
|
|
8349
|
+
/* @__PURE__ */ w.jsx(me, { className: I.track, element: _.track ?? /* @__PURE__ */ w.jsx(Cn, {}), style: $.track, children: /* @__PURE__ */ w.jsx("div", { style: { position: "relative", width: "100%", height: "100%" }, children: /* @__PURE__ */ w.jsx(me, { ref: b, className: I.knob, element: _.knob ?? /* @__PURE__ */ w.jsx($n, {}), style: $.knob }) }) })
|
|
8322
8350
|
] });
|
|
8323
|
-
}),
|
|
8351
|
+
}), Cn = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), $n = ({ children: e, ...r }) => /* @__PURE__ */ w.jsx("div", { ...r, children: e }), uu = /* @__PURE__ */ Object.assign(Pi, {
|
|
8324
8352
|
/**
|
|
8325
8353
|
* Component for the knob of a {@link Toggle}.
|
|
8326
8354
|
*/
|
|
8327
|
-
Knob:
|
|
8355
|
+
Knob: $n,
|
|
8328
8356
|
/**
|
|
8329
8357
|
* Component for the track of a {@link Toggle}.
|
|
8330
8358
|
*/
|
|
8331
|
-
Track:
|
|
8359
|
+
Track: Cn
|
|
8332
8360
|
});
|
|
8333
8361
|
function kl({ isOn: e = !1 }) {
|
|
8334
8362
|
return {
|
|
@@ -8337,7 +8365,7 @@ function kl({ isOn: e = !1 }) {
|
|
|
8337
8365
|
track: se({ active: e })
|
|
8338
8366
|
};
|
|
8339
8367
|
}
|
|
8340
|
-
function
|
|
8368
|
+
function Cl({ isOn: e = !1, isInverted: r = !1, knobSize: i = je.zero, orientation: a = "horizontal" }) {
|
|
8341
8369
|
return {
|
|
8342
8370
|
root: {
|
|
8343
8371
|
alignItems: "center",
|
|
@@ -8397,18 +8425,18 @@ function $l({ isOn: e = !1, isInverted: r = !1, knobSize: i = je.zero, orientati
|
|
|
8397
8425
|
}
|
|
8398
8426
|
};
|
|
8399
8427
|
}
|
|
8400
|
-
process.env.NODE_ENV === "development" && (Pi.displayName = "Toggle",
|
|
8428
|
+
process.env.NODE_ENV === "development" && (Pi.displayName = "Toggle", $n.displayName = "Toggle.Knob", Cn.displayName = "Toggle.Track");
|
|
8401
8429
|
function Vo(e) {
|
|
8402
8430
|
return e == null ? "" : Array.isArray(e) ? JSON.stringify(e.map(Vo)) : typeof e == "object" ? JSON.stringify(Object.entries(e).sort(([r], [i]) => r.localeCompare(i)).map(([r, i]) => [r, Vo(i)])) : We(e);
|
|
8403
8431
|
}
|
|
8404
|
-
function
|
|
8432
|
+
function $l({
|
|
8405
8433
|
children: e,
|
|
8406
8434
|
...r
|
|
8407
8435
|
}) {
|
|
8408
|
-
return /* @__PURE__ */ w.jsx(w.Fragment, { children:
|
|
8436
|
+
return /* @__PURE__ */ w.jsx(w.Fragment, { children: jn.map(e, (i) => An(i) ? gr(i, { ...r }) : i) });
|
|
8409
8437
|
}
|
|
8410
|
-
process.env.NODE_ENV === "development" && (
|
|
8411
|
-
function
|
|
8438
|
+
process.env.NODE_ENV === "development" && ($l.displayName = "ExtractChildren");
|
|
8439
|
+
function fu({
|
|
8412
8440
|
children: e,
|
|
8413
8441
|
fallback: r = void 0
|
|
8414
8442
|
}) {
|
|
@@ -8419,44 +8447,44 @@ function cu({
|
|
|
8419
8447
|
return /* @__PURE__ */ w.jsx(Ys, { fallback: r, children: e });
|
|
8420
8448
|
}
|
|
8421
8449
|
export {
|
|
8422
|
-
|
|
8450
|
+
nu as Accordion,
|
|
8423
8451
|
Xo as Burger,
|
|
8424
8452
|
Rl as BurgerButton,
|
|
8425
8453
|
ei as Button,
|
|
8426
8454
|
Za as Carousel,
|
|
8427
|
-
|
|
8455
|
+
ru as CodeInput,
|
|
8428
8456
|
zn as Collection,
|
|
8429
8457
|
wa as Conditional,
|
|
8430
|
-
|
|
8458
|
+
ou as Counter,
|
|
8431
8459
|
zl as CoverImage,
|
|
8432
|
-
|
|
8460
|
+
Ll as CoverVideo,
|
|
8433
8461
|
sc as Dial,
|
|
8434
|
-
|
|
8462
|
+
iu as Dropdown,
|
|
8435
8463
|
Mn as Each,
|
|
8436
8464
|
ii as ExtractChild,
|
|
8437
|
-
|
|
8465
|
+
$l as ExtractChildren,
|
|
8438
8466
|
fl as FlatSVG,
|
|
8439
8467
|
dl as Form,
|
|
8440
8468
|
qo as Image,
|
|
8441
8469
|
on as ImageSource,
|
|
8442
8470
|
pl as MasonryGrid,
|
|
8443
|
-
|
|
8471
|
+
fu as NoSSR,
|
|
8444
8472
|
ca as OptionButton,
|
|
8445
8473
|
ti as Panorama,
|
|
8446
|
-
|
|
8474
|
+
Fl as PanoramaSlider,
|
|
8447
8475
|
Wo as Picture,
|
|
8448
|
-
|
|
8476
|
+
su as RangeSlider,
|
|
8449
8477
|
nn as Repeat,
|
|
8450
|
-
|
|
8478
|
+
au as Select,
|
|
8451
8479
|
xa as SelectableButton,
|
|
8452
|
-
|
|
8453
|
-
|
|
8454
|
-
|
|
8480
|
+
cu as Slider,
|
|
8481
|
+
lu as StepSlider,
|
|
8482
|
+
me as Styled,
|
|
8455
8483
|
Pl as SwipeRegion,
|
|
8456
8484
|
Vl as Switch,
|
|
8457
8485
|
Il as TextArea,
|
|
8458
8486
|
hi as TextField,
|
|
8459
|
-
|
|
8487
|
+
uu as Toggle,
|
|
8460
8488
|
Zo as Video,
|
|
8461
8489
|
Na as WithTooltip,
|
|
8462
8490
|
vr as _Content,
|
|
@@ -8474,34 +8502,37 @@ export {
|
|
|
8474
8502
|
Aa as createLocalCache,
|
|
8475
8503
|
Va as createSessionCache,
|
|
8476
8504
|
Ya as getStyle,
|
|
8477
|
-
|
|
8505
|
+
$a as isTouchDevice,
|
|
8478
8506
|
To as setStyle,
|
|
8479
8507
|
ce as styles,
|
|
8480
8508
|
Dl as useAgent,
|
|
8481
|
-
|
|
8482
|
-
|
|
8483
|
-
Yl as
|
|
8509
|
+
Bl as useClassName,
|
|
8510
|
+
Hl as useClickOutside,
|
|
8511
|
+
Yl as useCopyBlobToClipboard,
|
|
8512
|
+
Ul as useDPR,
|
|
8513
|
+
Xl as useDownloadBlob,
|
|
8484
8514
|
ka as useDrag,
|
|
8485
|
-
|
|
8515
|
+
Kl as useDropzone,
|
|
8486
8516
|
Qs as useImageLoader,
|
|
8487
8517
|
Go as useImageSize,
|
|
8488
8518
|
ga as useInertiaDrag,
|
|
8489
8519
|
zt as useInertiaDragValue,
|
|
8490
8520
|
Js as useIntersectionObserver,
|
|
8491
|
-
|
|
8492
|
-
|
|
8493
|
-
|
|
8494
|
-
|
|
8521
|
+
Ca as useInterval,
|
|
8522
|
+
Gl as useIsMounted,
|
|
8523
|
+
ja as useIsTouchDevice,
|
|
8524
|
+
ql as useKeyboardShortcut,
|
|
8495
8525
|
Se as useLatest,
|
|
8496
|
-
|
|
8497
|
-
|
|
8498
|
-
|
|
8526
|
+
Wl as useLocalCache,
|
|
8527
|
+
Jl as usePosition,
|
|
8528
|
+
Fa as usePrevious,
|
|
8499
8529
|
nt as useRect,
|
|
8500
|
-
|
|
8530
|
+
Zl as useSessionCache,
|
|
8501
8531
|
ci as useSize,
|
|
8502
8532
|
mr as useSizeObserver,
|
|
8503
|
-
|
|
8504
|
-
|
|
8533
|
+
Ql as useStyle,
|
|
8534
|
+
eu as useSystemColorScheme,
|
|
8535
|
+
tu as useTimeout,
|
|
8505
8536
|
na as useVideoMetadataLoader,
|
|
8506
8537
|
ra as useVideoSize,
|
|
8507
8538
|
Zs as useViewportSize
|