etudes 19.1.0 → 19.2.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 +377 -376
- package/build/etudes.umd.cjs +9 -9
- package/package.json +15 -15
package/build/etudes.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import ys, { useRef as Ee, useEffect as Ne, useLayoutEffect as De, useState as _e, Fragment as
|
|
1
|
+
import ys, { useRef as Ee, useEffect as Ne, useLayoutEffect as De, useState as _e, Fragment as Oo, cloneElement as xs, Children as an, isValidElement as cn, forwardRef as Pe, useCallback as he, useMemo as bs, createContext as ws, useContext as fr } from "react";
|
|
2
2
|
function ko(e) {
|
|
3
3
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
4
4
|
}
|
|
@@ -190,13 +190,13 @@ function Ns() {
|
|
|
190
190
|
if (Z)
|
|
191
191
|
if (F(me)) {
|
|
192
192
|
for (Z = 0; Z < me.length; Z++)
|
|
193
|
-
|
|
193
|
+
P(me[Z]);
|
|
194
194
|
Object.freeze && Object.freeze(me);
|
|
195
195
|
} else
|
|
196
196
|
console.error(
|
|
197
197
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
198
198
|
);
|
|
199
|
-
else
|
|
199
|
+
else P(me);
|
|
200
200
|
if (W.call(H, "key")) {
|
|
201
201
|
me = e(T);
|
|
202
202
|
var G = Object.keys(H).filter(function(je) {
|
|
@@ -234,18 +234,18 @@ React keys must be passed directly to JSX without using spread:
|
|
|
234
234
|
be
|
|
235
235
|
);
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function P(T) {
|
|
238
238
|
typeof T == "object" && T !== null && T.$$typeof === $ && T._store && (T._store.validated = 1);
|
|
239
239
|
}
|
|
240
240
|
var C = ys, $ = Symbol.for("react.transitional.element"), M = Symbol.for("react.portal"), w = Symbol.for("react.fragment"), j = Symbol.for("react.strict_mode"), K = Symbol.for("react.profiler"), J = Symbol.for("react.consumer"), U = Symbol.for("react.context"), B = Symbol.for("react.forward_ref"), S = Symbol.for("react.suspense"), k = Symbol.for("react.suspense_list"), E = Symbol.for("react.memo"), A = Symbol.for("react.lazy"), X = Symbol.for("react.activity"), q = Symbol.for("react.client.reference"), ne = C.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, W = Object.prototype.hasOwnProperty, F = Array.isArray, R = console.createTask ? console.createTask : function() {
|
|
241
241
|
return null;
|
|
242
242
|
};
|
|
243
243
|
C = {
|
|
244
|
-
|
|
244
|
+
react_stack_bottom_frame: function(T) {
|
|
245
245
|
return T();
|
|
246
246
|
}
|
|
247
247
|
};
|
|
248
|
-
var V, re = {}, ie = C
|
|
248
|
+
var V, re = {}, ie = C.react_stack_bottom_frame.bind(
|
|
249
249
|
C,
|
|
250
250
|
u
|
|
251
251
|
)(), ae = R(a(u)), L = {};
|
|
@@ -398,10 +398,10 @@ var Se;
|
|
|
398
398
|
});
|
|
399
399
|
}
|
|
400
400
|
e.toJSON = _;
|
|
401
|
-
function
|
|
401
|
+
function P(w) {
|
|
402
402
|
return [w.x, w.y];
|
|
403
403
|
}
|
|
404
|
-
e.toArray =
|
|
404
|
+
e.toArray = P;
|
|
405
405
|
function C(w) {
|
|
406
406
|
return w instanceof Array ? !(w.length !== 2 || typeof w[0] != "number" || typeof w[1] != "number") : typeof w == "object" ? !(typeof w.x != "number" || typeof w.y != "number") : !1;
|
|
407
407
|
}
|
|
@@ -415,7 +415,7 @@ var Se;
|
|
|
415
415
|
}
|
|
416
416
|
e.isZero = M;
|
|
417
417
|
})(Se || (Se = {}));
|
|
418
|
-
function
|
|
418
|
+
function Ps(e, r) {
|
|
419
419
|
try {
|
|
420
420
|
const s = Se.isValidDescriptor(e) && Se.make(e), a = Se.isValidDescriptor(r) && Se.make(r);
|
|
421
421
|
if (s && !a) {
|
|
@@ -524,10 +524,10 @@ var Me;
|
|
|
524
524
|
});
|
|
525
525
|
}
|
|
526
526
|
e.toJSON = _;
|
|
527
|
-
function
|
|
527
|
+
function P(w) {
|
|
528
528
|
return [w.width, w.height];
|
|
529
529
|
}
|
|
530
|
-
e.toArray =
|
|
530
|
+
e.toArray = P;
|
|
531
531
|
function C(w) {
|
|
532
532
|
return w instanceof Array ? !(w.length !== 2 || typeof w[0] != "number" || typeof w[1] != "number") : typeof w == "object" ? !(typeof w.width != "number" || typeof w.height != "number") : !1;
|
|
533
533
|
}
|
|
@@ -671,7 +671,7 @@ var xe;
|
|
|
671
671
|
}
|
|
672
672
|
}
|
|
673
673
|
e.intersecting = _;
|
|
674
|
-
function
|
|
674
|
+
function P(S, k = {}) {
|
|
675
675
|
return r({
|
|
676
676
|
x: typeof k.x == "number" ? k.x : S.left,
|
|
677
677
|
y: typeof k.y == "number" ? k.y : S.top,
|
|
@@ -679,7 +679,7 @@ var xe;
|
|
|
679
679
|
height: typeof k.height == "number" ? k.height : S.height
|
|
680
680
|
});
|
|
681
681
|
}
|
|
682
|
-
e.clone =
|
|
682
|
+
e.clone = P;
|
|
683
683
|
function C(S, k) {
|
|
684
684
|
return r({
|
|
685
685
|
x: Math.min(S.left, k.left),
|
|
@@ -703,7 +703,7 @@ var xe;
|
|
|
703
703
|
}
|
|
704
704
|
e.isEqual = M;
|
|
705
705
|
function w(S, k) {
|
|
706
|
-
return
|
|
706
|
+
return Ps(k, S);
|
|
707
707
|
}
|
|
708
708
|
e.contains = w;
|
|
709
709
|
function j(S) {
|
|
@@ -772,9 +772,9 @@ function ln({
|
|
|
772
772
|
}) {
|
|
773
773
|
if (e == null) return /* @__PURE__ */ x.jsx(x.Fragment, {});
|
|
774
774
|
if (!(e instanceof Array)) throw TypeError(`Provided list <${e}> is not an array`);
|
|
775
|
-
return /* @__PURE__ */ x.jsx(x.Fragment, { children: e.map((a, l) => /* @__PURE__ */ x.jsx(
|
|
775
|
+
return /* @__PURE__ */ x.jsx(x.Fragment, { children: e.map((a, l) => /* @__PURE__ */ x.jsx(Oo, { children: s?.(a, l) ?? (typeof r == "function" ? r(a, l) : r) }, `item-${l}`)) });
|
|
776
776
|
}
|
|
777
|
-
process.env.NODE_ENV
|
|
777
|
+
process.env.NODE_ENV === "development" && (ln.displayName = "Each");
|
|
778
778
|
function pr(e, r = {}, ...s) {
|
|
779
779
|
const { className: a, style: l, ...u } = r, { className: p, style: g, ...m } = e.props;
|
|
780
780
|
return xs(e, {
|
|
@@ -798,7 +798,7 @@ function ge({
|
|
|
798
798
|
...e ? Array.isArray(e) ? e : [e] : []
|
|
799
799
|
);
|
|
800
800
|
}
|
|
801
|
-
process.env.NODE_ENV
|
|
801
|
+
process.env.NODE_ENV === "development" && (ge.displayName = "Styled");
|
|
802
802
|
function ze(e, r = {}) {
|
|
803
803
|
const s = Object.keys(r), a = Object.values(r), l = {};
|
|
804
804
|
return an.forEach(e, (u) => {
|
|
@@ -830,7 +830,7 @@ function le(...e) {
|
|
|
830
830
|
...s || {}
|
|
831
831
|
}), {});
|
|
832
832
|
}
|
|
833
|
-
const hr = /* @__PURE__ */
|
|
833
|
+
const hr = /* @__PURE__ */ Pe(({
|
|
834
834
|
className: e,
|
|
835
835
|
children: r,
|
|
836
836
|
style: s,
|
|
@@ -842,7 +842,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
842
842
|
numSegments: m = 1,
|
|
843
843
|
orientation: N = "vertical",
|
|
844
844
|
selection: _,
|
|
845
|
-
selectionMode:
|
|
845
|
+
selectionMode: P = "none",
|
|
846
846
|
onActivateAt: C,
|
|
847
847
|
onDeselectAt: $,
|
|
848
848
|
onCustomEvent: M,
|
|
@@ -856,7 +856,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
856
856
|
}, A = (F) => {
|
|
857
857
|
if (k(F)) return;
|
|
858
858
|
let R;
|
|
859
|
-
switch (
|
|
859
|
+
switch (P) {
|
|
860
860
|
case "multiple": {
|
|
861
861
|
R = (ie) => Io([...ie.filter((ae) => ae !== F), F]);
|
|
862
862
|
break;
|
|
@@ -875,7 +875,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
875
875
|
const R = (ie) => ie.filter((ae) => ae !== F), V = B, re = R(B);
|
|
876
876
|
ne(V, re);
|
|
877
877
|
}, q = (F) => {
|
|
878
|
-
C?.(F),
|
|
878
|
+
C?.(F), P !== "none" && (a ? E(F) : A(F));
|
|
879
879
|
}, ne = (F, R) => {
|
|
880
880
|
if (Ge(F, R)) return;
|
|
881
881
|
const V = F?.filter((ie) => R.indexOf(ie) === -1) ?? [], re = R.filter((ie) => F?.indexOf(ie) === -1);
|
|
@@ -884,7 +884,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
884
884
|
Ne(() => {
|
|
885
885
|
const F = B;
|
|
886
886
|
let R;
|
|
887
|
-
switch (
|
|
887
|
+
switch (P) {
|
|
888
888
|
case "multiple":
|
|
889
889
|
R = B;
|
|
890
890
|
break;
|
|
@@ -896,7 +896,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
896
896
|
break;
|
|
897
897
|
}
|
|
898
898
|
ne(F, R);
|
|
899
|
-
}, [
|
|
899
|
+
}, [P]);
|
|
900
900
|
const W = ze(r, {
|
|
901
901
|
item: kt
|
|
902
902
|
});
|
|
@@ -905,12 +905,12 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
905
905
|
{
|
|
906
906
|
...J,
|
|
907
907
|
ref: U,
|
|
908
|
-
"aria-multiselectable":
|
|
908
|
+
"aria-multiselectable": P === "multiple",
|
|
909
909
|
className: se(e),
|
|
910
|
-
role: g === "grid" ? "grid" :
|
|
910
|
+
role: g === "grid" ? "grid" : P === "none" ? "list" : "listbox",
|
|
911
911
|
style: le(s, S.root),
|
|
912
912
|
children: /* @__PURE__ */ x.jsx(ln, { in: p, children: (F, R) => {
|
|
913
|
-
const V = g === "grid" ? "gridcell" :
|
|
913
|
+
const V = g === "grid" ? "gridcell" : P === "none" ? "listitem" : "option", re = k(R), ie = le(S.item, {
|
|
914
914
|
pointerEvents: a !== !0 && k(R) ? "none" : "auto",
|
|
915
915
|
...R >= p.length - 1 ? {} : {
|
|
916
916
|
...g === "list" ? {
|
|
@@ -943,7 +943,7 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
943
943
|
className: se({ active: re }),
|
|
944
944
|
element: W.item ?? /* @__PURE__ */ x.jsx(kt, {}),
|
|
945
945
|
role: V,
|
|
946
|
-
selectionMode:
|
|
946
|
+
selectionMode: P,
|
|
947
947
|
style: ie,
|
|
948
948
|
onActivateAt: C,
|
|
949
949
|
onClick: () => q(R),
|
|
@@ -954,11 +954,11 @@ const hr = /* @__PURE__ */ Oe(({
|
|
|
954
954
|
}
|
|
955
955
|
);
|
|
956
956
|
}), kt = ({ children: e, selectionMode: r, onActivateAt: s, ...a }) => s || r === "single" || r === "multiple" ? /* @__PURE__ */ x.jsx("button", { ...a, children: e }) : /* @__PURE__ */ x.jsx("div", { ...a, children: e });
|
|
957
|
-
function
|
|
957
|
+
function Os(e, r) {
|
|
958
958
|
return !!(isNaN(e) || e >= r.length || e < 0);
|
|
959
959
|
}
|
|
960
960
|
function ks(e, r) {
|
|
961
|
-
return Io(e).filter((s) => !
|
|
961
|
+
return Io(e).filter((s) => !Os(s, r));
|
|
962
962
|
}
|
|
963
963
|
function Io(e) {
|
|
964
964
|
return e.sort((r, s) => r - s);
|
|
@@ -1003,8 +1003,8 @@ function Cs({ itemLength: e = NaN, itemPadding: r = 0, layout: s = "collection",
|
|
|
1003
1003
|
}
|
|
1004
1004
|
};
|
|
1005
1005
|
}
|
|
1006
|
-
process.env.NODE_ENV
|
|
1007
|
-
const js = /* @__PURE__ */
|
|
1006
|
+
process.env.NODE_ENV === "development" && (hr.displayName = "Collection", kt.displayName = "CollectionItem");
|
|
1007
|
+
const js = /* @__PURE__ */ Pe(({
|
|
1008
1008
|
children: e,
|
|
1009
1009
|
style: r,
|
|
1010
1010
|
autoCollapseSections: s = !1,
|
|
@@ -1016,7 +1016,7 @@ const js = /* @__PURE__ */ Oe(({
|
|
|
1016
1016
|
selectionMode: m = "single",
|
|
1017
1017
|
onActivateAt: N,
|
|
1018
1018
|
onCollapseSectionAt: _,
|
|
1019
|
-
onDeselectAt:
|
|
1019
|
+
onDeselectAt: P,
|
|
1020
1020
|
onExpandedSectionsChange: C,
|
|
1021
1021
|
onExpandSectionAt: $,
|
|
1022
1022
|
onHeaderCustomEvent: M,
|
|
@@ -1069,7 +1069,7 @@ const js = /* @__PURE__ */ Oe(({
|
|
|
1069
1069
|
const ue = L?.[Q] ?? [], pe = T[Q] ?? [], be = ue.filter((G) => pe.indexOf(G) === -1), me = pe.filter((G) => ue?.indexOf(G) === -1);
|
|
1070
1070
|
ee = [...ee, ...be.map((G) => [G, Q])], Z = [...Z, ...me.map((G) => [G, Q])];
|
|
1071
1071
|
}
|
|
1072
|
-
ee.forEach((Q) =>
|
|
1072
|
+
ee.forEach((Q) => P?.(Q[0], Q[1])), Z.forEach((Q) => j?.(Q[0], Q[1])), K?.(T);
|
|
1073
1073
|
}, ae = ze(e, {
|
|
1074
1074
|
collapseIcon: Ao,
|
|
1075
1075
|
expandIcon: $o,
|
|
@@ -1270,19 +1270,19 @@ function Ms({ orientation: e = "vertical" }) {
|
|
|
1270
1270
|
}
|
|
1271
1271
|
};
|
|
1272
1272
|
}
|
|
1273
|
-
process.env.NODE_ENV
|
|
1273
|
+
process.env.NODE_ENV === "development" && (js.displayName = "Accordion", Ln.displayName = "AccordionHeader", $o.displayName = "AccordionExpandIcon", Ao.displayName = "AccordionCollapseIcon", Fn.displayName = "AccordionItem");
|
|
1274
1274
|
function Dn({
|
|
1275
1275
|
count: e = 1,
|
|
1276
1276
|
children: r,
|
|
1277
1277
|
render: s
|
|
1278
1278
|
}) {
|
|
1279
|
-
return /* @__PURE__ */ x.jsx(x.Fragment, { children: [...Array(e)].map((a, l) => /* @__PURE__ */ x.jsx(
|
|
1279
|
+
return /* @__PURE__ */ x.jsx(x.Fragment, { children: [...Array(e)].map((a, l) => /* @__PURE__ */ x.jsx(Oo, { children: s?.(l) ?? (typeof r == "function" ? r(l) : r) }, `element-${l}`)) });
|
|
1280
1280
|
}
|
|
1281
|
-
process.env.NODE_ENV
|
|
1281
|
+
process.env.NODE_ENV === "development" && (Dn.displayName = "Repeat");
|
|
1282
1282
|
function pl(e) {
|
|
1283
1283
|
return e;
|
|
1284
1284
|
}
|
|
1285
|
-
const Ro = /* @__PURE__ */
|
|
1285
|
+
const Ro = /* @__PURE__ */ Pe(({
|
|
1286
1286
|
children: e,
|
|
1287
1287
|
className: r,
|
|
1288
1288
|
isActive: s = !1,
|
|
@@ -1307,7 +1307,7 @@ const Ro = /* @__PURE__ */ Oe(({
|
|
|
1307
1307
|
...p,
|
|
1308
1308
|
ref: g,
|
|
1309
1309
|
className: se(r, N.root),
|
|
1310
|
-
children: /* @__PURE__ */ x.jsx(Dn, { count: l ? 2 : 1, children: (
|
|
1310
|
+
children: /* @__PURE__ */ x.jsx(Dn, { count: l ? 2 : 1, children: (P) => /* @__PURE__ */ x.jsx("div", { "aria-hidden": !0, style: le(_.section, _[`section${P}`]), children: /* @__PURE__ */ x.jsx(Dn, { count: u, children: (C) => /* @__PURE__ */ x.jsx(
|
|
1311
1311
|
ge,
|
|
1312
1312
|
{
|
|
1313
1313
|
"aria-hidden": !0,
|
|
@@ -1316,10 +1316,10 @@ const Ro = /* @__PURE__ */ Oe(({
|
|
|
1316
1316
|
style: (() => {
|
|
1317
1317
|
switch (u) {
|
|
1318
1318
|
case 2:
|
|
1319
|
-
return le(_.bar, _[`bar${
|
|
1319
|
+
return le(_.bar, _[`bar${P}${C === 0 ? 0 : 2}`]);
|
|
1320
1320
|
case 3:
|
|
1321
1321
|
default:
|
|
1322
|
-
return le(_.bar, _[`bar${
|
|
1322
|
+
return le(_.bar, _[`bar${P}${C}`]);
|
|
1323
1323
|
}
|
|
1324
1324
|
})()
|
|
1325
1325
|
}
|
|
@@ -1388,8 +1388,8 @@ function Rs({ isActive: e = !1, isSplit: r = !1, isTailHidden: s = !1 }) {
|
|
|
1388
1388
|
}
|
|
1389
1389
|
};
|
|
1390
1390
|
}
|
|
1391
|
-
process.env.NODE_ENV
|
|
1392
|
-
const zs = /* @__PURE__ */
|
|
1391
|
+
process.env.NODE_ENV === "development" && (Ro.displayName = "Burger", rn.displayName = "BurgerBar");
|
|
1392
|
+
const zs = /* @__PURE__ */ Pe(({
|
|
1393
1393
|
children: e,
|
|
1394
1394
|
className: r,
|
|
1395
1395
|
style: s,
|
|
@@ -1401,7 +1401,7 @@ const zs = /* @__PURE__ */ Oe(({
|
|
|
1401
1401
|
onDeactivate: m,
|
|
1402
1402
|
onToggle: N,
|
|
1403
1403
|
..._
|
|
1404
|
-
},
|
|
1404
|
+
}, P) => {
|
|
1405
1405
|
const C = () => {
|
|
1406
1406
|
const w = !a;
|
|
1407
1407
|
N?.(w), w ? g?.() : m?.();
|
|
@@ -1414,7 +1414,7 @@ const zs = /* @__PURE__ */ Oe(({
|
|
|
1414
1414
|
"button",
|
|
1415
1415
|
{
|
|
1416
1416
|
..._,
|
|
1417
|
-
ref:
|
|
1417
|
+
ref: P,
|
|
1418
1418
|
"aria-expanded": a,
|
|
1419
1419
|
className: se(r, $.root),
|
|
1420
1420
|
style: le(s, M.root),
|
|
@@ -1442,7 +1442,7 @@ function Fs() {
|
|
|
1442
1442
|
}
|
|
1443
1443
|
};
|
|
1444
1444
|
}
|
|
1445
|
-
process.env.NODE_ENV
|
|
1445
|
+
process.env.NODE_ENV === "development" && (zs.displayName = "BurgerButton", Ls.displayName = "BurgerButtonBar");
|
|
1446
1446
|
function Ds(e) {
|
|
1447
1447
|
switch (!0) {
|
|
1448
1448
|
case Hs(e): {
|
|
@@ -1487,7 +1487,7 @@ function Hs(e) {
|
|
|
1487
1487
|
function Vs(e) {
|
|
1488
1488
|
return typeof e.action == "function";
|
|
1489
1489
|
}
|
|
1490
|
-
process.env.NODE_ENV
|
|
1490
|
+
process.env.NODE_ENV === "development" && (Ds.displayName = "Button");
|
|
1491
1491
|
function Bs(e, {
|
|
1492
1492
|
isEnabled: r = !0,
|
|
1493
1493
|
updatesCursor: s = !0,
|
|
@@ -1495,7 +1495,7 @@ function Bs(e, {
|
|
|
1495
1495
|
onDragMove: l,
|
|
1496
1496
|
onDragEnd: u
|
|
1497
1497
|
}) {
|
|
1498
|
-
const p = Ee(void 0), g = Ee(void 0), m = Te(a), N = Te(l), _ = Te(u),
|
|
1498
|
+
const p = Ee(void 0), g = Ee(void 0), m = Te(a), N = Te(l), _ = Te(u), P = he((M) => {
|
|
1499
1499
|
if (!p.current) return;
|
|
1500
1500
|
const w = Se.make(M.clientX, M.clientY), j = Se.subtract(w, g.current ?? p.current);
|
|
1501
1501
|
g.current = w, N.current?.(j, w, p.current);
|
|
@@ -1503,14 +1503,14 @@ function Bs(e, {
|
|
|
1503
1503
|
const w = e.current;
|
|
1504
1504
|
if (!w || !p.current) return;
|
|
1505
1505
|
const j = Se.make(M.clientX, M.clientY), K = Se.subtract(g.current ?? p.current, j);
|
|
1506
|
-
_.current?.(j, K, p.current), p.current = void 0, g.current = void 0, w.removeEventListener("mousemove",
|
|
1507
|
-
}, [s,
|
|
1506
|
+
_.current?.(j, K, p.current), p.current = void 0, g.current = void 0, w.removeEventListener("mousemove", P), w.removeEventListener("mouseup", C, { capture: !0 }), w.removeEventListener("mouseleave", C), s && (w.style.cursor = "grab");
|
|
1507
|
+
}, [s, P]), $ = he((M) => {
|
|
1508
1508
|
const w = e.current;
|
|
1509
1509
|
if (!w) return;
|
|
1510
1510
|
M.preventDefault();
|
|
1511
1511
|
const j = Se.make(M.clientX, M.clientY);
|
|
1512
|
-
p.current = j, g.current = j, w.addEventListener("mousemove",
|
|
1513
|
-
}, [s,
|
|
1512
|
+
p.current = j, g.current = j, w.addEventListener("mousemove", P), w.addEventListener("mouseup", C, { capture: !0 }), w.addEventListener("mouseleave", C), s && (w.style.cursor = "grabbing"), m.current?.(j);
|
|
1513
|
+
}, [s, P, C]);
|
|
1514
1514
|
De(() => {
|
|
1515
1515
|
const M = e.current;
|
|
1516
1516
|
if (!M || !r || !s) return;
|
|
@@ -1522,9 +1522,9 @@ function Bs(e, {
|
|
|
1522
1522
|
const M = e.current;
|
|
1523
1523
|
if (!(!M || !r))
|
|
1524
1524
|
return M.addEventListener("mousedown", $), () => {
|
|
1525
|
-
M.removeEventListener("mousedown", $), M.removeEventListener("mousemove",
|
|
1525
|
+
M.removeEventListener("mousedown", $), M.removeEventListener("mousemove", P), M.removeEventListener("mouseup", C, { capture: !0 }), M.removeEventListener("mouseleave", C);
|
|
1526
1526
|
};
|
|
1527
|
-
}, [r,
|
|
1527
|
+
}, [r, P, C, $]);
|
|
1528
1528
|
}
|
|
1529
1529
|
function Ys(e, {
|
|
1530
1530
|
autoStarts: r = !0,
|
|
@@ -1546,7 +1546,7 @@ function Xs() {
|
|
|
1546
1546
|
function Us() {
|
|
1547
1547
|
return bs(() => Xs(), []);
|
|
1548
1548
|
}
|
|
1549
|
-
const qs = /* @__PURE__ */
|
|
1549
|
+
const qs = /* @__PURE__ */ Pe(({
|
|
1550
1550
|
autoAdvanceInterval: e = 0,
|
|
1551
1551
|
index: r = 0,
|
|
1552
1552
|
isDragEnabled: s = !0,
|
|
@@ -1558,7 +1558,7 @@ const qs = /* @__PURE__ */ Oe(({
|
|
|
1558
1558
|
onIndexChange: m,
|
|
1559
1559
|
ItemComponent: N,
|
|
1560
1560
|
..._
|
|
1561
|
-
},
|
|
1561
|
+
}, P) => {
|
|
1562
1562
|
const C = Ee(void 0), $ = Ee(null), M = Ee(void 0), w = Ee(void 0), j = Ee(void 0), K = 1e3, J = Te(p), U = Te(g), B = Te(m), S = Ee(!1), k = Ee(!1), E = Us(), [A, X] = _e(po($, l)), [q, ne] = _e(!1), W = Ks({ scrollSnapEnabled: E || !q, orientation: l }), F = e > 0, R = he(() => {
|
|
1563
1563
|
j.current !== void 0 && (clearTimeout(j.current), j.current = void 0);
|
|
1564
1564
|
}, []), V = he(() => {
|
|
@@ -1623,7 +1623,7 @@ const qs = /* @__PURE__ */ Oe(({
|
|
|
1623
1623
|
"div",
|
|
1624
1624
|
{
|
|
1625
1625
|
..._,
|
|
1626
|
-
ref:
|
|
1626
|
+
ref: P,
|
|
1627
1627
|
role: "region",
|
|
1628
1628
|
onClick: T,
|
|
1629
1629
|
onPointerCancel: L,
|
|
@@ -1706,14 +1706,14 @@ function Ks({ scrollSnapEnabled: e = !1, orientation: r = "horizontal" }) {
|
|
|
1706
1706
|
}
|
|
1707
1707
|
};
|
|
1708
1708
|
}
|
|
1709
|
-
process.env.NODE_ENV
|
|
1709
|
+
process.env.NODE_ENV === "development" && (qs.displayName = "Carousel");
|
|
1710
1710
|
function Js(e) {
|
|
1711
1711
|
const r = Ee(void 0);
|
|
1712
1712
|
return Ne(() => {
|
|
1713
1713
|
r.current = e;
|
|
1714
1714
|
}, [e]), r.current;
|
|
1715
1715
|
}
|
|
1716
|
-
const zo = /* @__PURE__ */
|
|
1716
|
+
const zo = /* @__PURE__ */ Pe(({
|
|
1717
1717
|
className: e,
|
|
1718
1718
|
emptyValue: r = "",
|
|
1719
1719
|
isDisabled: s = !1,
|
|
@@ -1725,7 +1725,7 @@ const zo = /* @__PURE__ */ Oe(({
|
|
|
1725
1725
|
onUnfocus: m,
|
|
1726
1726
|
onChange: N,
|
|
1727
1727
|
..._
|
|
1728
|
-
},
|
|
1728
|
+
}, P) => {
|
|
1729
1729
|
const C = he(($) => {
|
|
1730
1730
|
const M = (p?.($) ?? $) || r;
|
|
1731
1731
|
N?.(M);
|
|
@@ -1734,7 +1734,7 @@ const zo = /* @__PURE__ */ Oe(({
|
|
|
1734
1734
|
"input",
|
|
1735
1735
|
{
|
|
1736
1736
|
..._,
|
|
1737
|
-
ref:
|
|
1737
|
+
ref: P,
|
|
1738
1738
|
"aria-disabled": s,
|
|
1739
1739
|
"aria-placeholder": l,
|
|
1740
1740
|
"aria-required": a,
|
|
@@ -1750,8 +1750,8 @@ const zo = /* @__PURE__ */ Oe(({
|
|
|
1750
1750
|
}
|
|
1751
1751
|
);
|
|
1752
1752
|
});
|
|
1753
|
-
process.env.NODE_ENV
|
|
1754
|
-
const Zs = /* @__PURE__ */
|
|
1753
|
+
process.env.NODE_ENV === "development" && (zo.displayName = "TextField");
|
|
1754
|
+
const Zs = /* @__PURE__ */ Pe(({
|
|
1755
1755
|
children: e,
|
|
1756
1756
|
style: r,
|
|
1757
1757
|
allowsInput: s = !0,
|
|
@@ -1765,7 +1765,7 @@ const Zs = /* @__PURE__ */ Oe(({
|
|
|
1765
1765
|
p?.(w(u - 1));
|
|
1766
1766
|
}, _ = () => {
|
|
1767
1767
|
p?.(w(u + 1));
|
|
1768
|
-
},
|
|
1768
|
+
}, P = (k) => {
|
|
1769
1769
|
K(k);
|
|
1770
1770
|
}, C = (k) => {
|
|
1771
1771
|
const E = M(k);
|
|
@@ -1804,7 +1804,7 @@ const Zs = /* @__PURE__ */ Oe(({
|
|
|
1804
1804
|
isDisabled: !s,
|
|
1805
1805
|
style: le(Ut.textField),
|
|
1806
1806
|
value: j,
|
|
1807
|
-
onChange:
|
|
1807
|
+
onChange: P,
|
|
1808
1808
|
onUnfocus: C
|
|
1809
1809
|
}
|
|
1810
1810
|
),
|
|
@@ -1835,7 +1835,7 @@ const Zs = /* @__PURE__ */ Oe(({
|
|
|
1835
1835
|
width: "100%"
|
|
1836
1836
|
}
|
|
1837
1837
|
};
|
|
1838
|
-
process.env.NODE_ENV
|
|
1838
|
+
process.env.NODE_ENV === "development" && (Zs.displayName = "Counter", Vn.displayName = "CounterAddButton", Bn.displayName = "CounterSubtractButton", Hn.displayName = "CounterTextField");
|
|
1839
1839
|
function Qs() {
|
|
1840
1840
|
const [e, r] = _e(Me.zero);
|
|
1841
1841
|
return De(() => {
|
|
@@ -1921,12 +1921,12 @@ function ea({
|
|
|
1921
1921
|
const _ = (C) => {
|
|
1922
1922
|
const $ = C.currentTarget;
|
|
1923
1923
|
m.current?.($);
|
|
1924
|
-
},
|
|
1924
|
+
}, P = (C) => {
|
|
1925
1925
|
const $ = C.currentTarget;
|
|
1926
1926
|
N.current?.($);
|
|
1927
1927
|
};
|
|
1928
|
-
return p.current = new Image(), e && (p.current.src = e), r && (p.current.srcset = r), s && (p.current.sizes = s), g.current?.(p.current), p.current.addEventListener("load", _), p.current.addEventListener("error",
|
|
1929
|
-
p.current?.removeEventListener("load", _), p.current?.removeEventListener("error",
|
|
1928
|
+
return p.current = new Image(), e && (p.current.src = e), r && (p.current.srcset = r), s && (p.current.sizes = s), g.current?.(p.current), p.current.addEventListener("load", _), p.current.addEventListener("error", P), () => {
|
|
1929
|
+
p.current?.removeEventListener("load", _), p.current?.removeEventListener("error", P), p.current = void 0;
|
|
1930
1930
|
};
|
|
1931
1931
|
}, [e, r, s]);
|
|
1932
1932
|
}
|
|
@@ -1940,12 +1940,12 @@ function Lo({
|
|
|
1940
1940
|
onLoadComplete: u,
|
|
1941
1941
|
onLoadError: p
|
|
1942
1942
|
} = {}) {
|
|
1943
|
-
const [g, m] = _e(), N = Te(l), _ = Te(u),
|
|
1943
|
+
const [g, m] = _e(), N = Te(l), _ = Te(u), P = Te(p), C = he((w) => {
|
|
1944
1944
|
a || m(void 0), N.current?.(w);
|
|
1945
1945
|
}, [a]), $ = he((w) => {
|
|
1946
1946
|
m(ta(w)), _.current?.(w);
|
|
1947
1947
|
}, []), M = he((w) => {
|
|
1948
|
-
a || m(void 0),
|
|
1948
|
+
a || m(void 0), P.current?.(w);
|
|
1949
1949
|
}, [a]);
|
|
1950
1950
|
return ea({ src: e, srcSet: r, sizes: s }, {
|
|
1951
1951
|
onLoadStart: C,
|
|
@@ -1957,7 +1957,7 @@ function ta(e) {
|
|
|
1957
1957
|
if (e && typeof e.width == "number" && typeof e.height == "number")
|
|
1958
1958
|
return Me.make(e.width, e.height);
|
|
1959
1959
|
}
|
|
1960
|
-
const Fo = /* @__PURE__ */
|
|
1960
|
+
const Fo = /* @__PURE__ */ Pe(({
|
|
1961
1961
|
alt: e,
|
|
1962
1962
|
source: r,
|
|
1963
1963
|
loadingMode: s,
|
|
@@ -1968,7 +1968,7 @@ const Fo = /* @__PURE__ */ Oe(({
|
|
|
1968
1968
|
onSizeChange: g,
|
|
1969
1969
|
...m
|
|
1970
1970
|
}, N) => {
|
|
1971
|
-
const _ = r ? on.asProps(r) : void 0,
|
|
1971
|
+
const _ = r ? on.asProps(r) : void 0, P = Lo({
|
|
1972
1972
|
src: a,
|
|
1973
1973
|
srcSet: _?.srcSet,
|
|
1974
1974
|
sizes: _?.sizes
|
|
@@ -1978,8 +1978,8 @@ const Fo = /* @__PURE__ */ Oe(({
|
|
|
1978
1978
|
onLoadError: p
|
|
1979
1979
|
});
|
|
1980
1980
|
return Ne(() => {
|
|
1981
|
-
g?.(
|
|
1982
|
-
}, [
|
|
1981
|
+
g?.(P);
|
|
1982
|
+
}, [P?.width, P?.height]), /* @__PURE__ */ x.jsx(
|
|
1983
1983
|
"img",
|
|
1984
1984
|
{
|
|
1985
1985
|
...m,
|
|
@@ -1991,8 +1991,8 @@ const Fo = /* @__PURE__ */ Oe(({
|
|
|
1991
1991
|
}
|
|
1992
1992
|
);
|
|
1993
1993
|
});
|
|
1994
|
-
process.env.NODE_ENV
|
|
1995
|
-
const Do = /* @__PURE__ */
|
|
1994
|
+
process.env.NODE_ENV === "development" && (Fo.displayName = "Image");
|
|
1995
|
+
const Do = /* @__PURE__ */ Pe(({
|
|
1996
1996
|
alt: e,
|
|
1997
1997
|
loadingMode: r,
|
|
1998
1998
|
sources: s = [],
|
|
@@ -2003,7 +2003,7 @@ const Do = /* @__PURE__ */ Oe(({
|
|
|
2003
2003
|
onSizeChange: g,
|
|
2004
2004
|
...m
|
|
2005
2005
|
}, N) => /* @__PURE__ */ x.jsxs("picture", { ...m, ref: N, children: [
|
|
2006
|
-
s.map((_,
|
|
2006
|
+
s.map((_, P) => /* @__PURE__ */ x.jsx("source", { ...on.asProps(_) }, P)),
|
|
2007
2007
|
/* @__PURE__ */ x.jsx(
|
|
2008
2008
|
Fo,
|
|
2009
2009
|
{
|
|
@@ -2019,7 +2019,7 @@ const Do = /* @__PURE__ */ Oe(({
|
|
|
2019
2019
|
)
|
|
2020
2020
|
] }));
|
|
2021
2021
|
process.env.NODE_ENV === "development" && (Do.displayName = "Picture");
|
|
2022
|
-
const na = /* @__PURE__ */
|
|
2022
|
+
const na = /* @__PURE__ */ Pe(({
|
|
2023
2023
|
children: e,
|
|
2024
2024
|
alt: r,
|
|
2025
2025
|
aspectRatio: s = NaN,
|
|
@@ -2031,10 +2031,10 @@ const na = /* @__PURE__ */ Oe(({
|
|
|
2031
2031
|
onLoadComplete: m,
|
|
2032
2032
|
onLoadError: N,
|
|
2033
2033
|
..._
|
|
2034
|
-
},
|
|
2034
|
+
}, P) => {
|
|
2035
2035
|
const C = (k) => {
|
|
2036
2036
|
j(k ? k.width / k.height : NaN);
|
|
2037
|
-
}, $ = Ee(null), M =
|
|
2037
|
+
}, $ = Ee(null), M = P ?? $, [w, j] = _e(NaN), K = isNaN(s) ? w : s, J = nt(M), U = J.width / J.height, B = Me.make(
|
|
2038
2038
|
U > 1 ? Math.max(J.width, J.height * K) : Math.max(J.width, Math.max(J.height, J.width / K) * K),
|
|
2039
2039
|
U > 1 ? Math.max(J.height, Math.max(J.width, J.height * K) / K) : Math.max(J.height, J.width / K)
|
|
2040
2040
|
), S = ze(e, {
|
|
@@ -2092,7 +2092,7 @@ const na = /* @__PURE__ */ Oe(({
|
|
|
2092
2092
|
transform: "translate(-50%, -50%)"
|
|
2093
2093
|
}
|
|
2094
2094
|
};
|
|
2095
|
-
process.env.NODE_ENV
|
|
2095
|
+
process.env.NODE_ENV === "development" && (na.displayName = "CoverImage", Ho.displayName = "CoverImageContent", Vo.displayName = "CoverImageViewport");
|
|
2096
2096
|
function ra(e, {
|
|
2097
2097
|
onLoadStart: r,
|
|
2098
2098
|
onLoadComplete: s,
|
|
@@ -2115,14 +2115,14 @@ function oa(e, {
|
|
|
2115
2115
|
} = {}) {
|
|
2116
2116
|
const [u, p] = _e(), g = Te(s), m = Te(a), N = Te(l), _ = he(($) => {
|
|
2117
2117
|
r || p(void 0), g.current?.($);
|
|
2118
|
-
}, [r]),
|
|
2118
|
+
}, [r]), P = he(($) => {
|
|
2119
2119
|
p(ia($)), m.current?.($);
|
|
2120
2120
|
}, []), C = he(($) => {
|
|
2121
2121
|
r || p(void 0), N.current?.($);
|
|
2122
2122
|
}, [r]);
|
|
2123
2123
|
return ra(e, {
|
|
2124
2124
|
onLoadStart: _,
|
|
2125
|
-
onLoadComplete:
|
|
2125
|
+
onLoadComplete: P,
|
|
2126
2126
|
onLoadError: C
|
|
2127
2127
|
}), u;
|
|
2128
2128
|
}
|
|
@@ -2130,7 +2130,7 @@ function ia(e) {
|
|
|
2130
2130
|
if (e && typeof e.videoWidth == "number" && typeof e.videoHeight == "number")
|
|
2131
2131
|
return Me.make(e.videoWidth, e.videoHeight);
|
|
2132
2132
|
}
|
|
2133
|
-
const Bo = /* @__PURE__ */
|
|
2133
|
+
const Bo = /* @__PURE__ */ Pe(({
|
|
2134
2134
|
autoLoop: e = !0,
|
|
2135
2135
|
autoPlay: r = !0,
|
|
2136
2136
|
hasControls: s = !1,
|
|
@@ -2142,7 +2142,7 @@ const Bo = /* @__PURE__ */ Oe(({
|
|
|
2142
2142
|
onEnd: m,
|
|
2143
2143
|
onFullscreenChange: N,
|
|
2144
2144
|
onLoadMetadata: _,
|
|
2145
|
-
onLoadMetadataComplete:
|
|
2145
|
+
onLoadMetadataComplete: P,
|
|
2146
2146
|
onLoadMetadataError: C,
|
|
2147
2147
|
onPause: $,
|
|
2148
2148
|
onPlay: M,
|
|
@@ -2152,7 +2152,7 @@ const Bo = /* @__PURE__ */ Oe(({
|
|
|
2152
2152
|
}, J) => {
|
|
2153
2153
|
const U = Ee(null), B = J ?? U, S = oa(p, {
|
|
2154
2154
|
onLoadStart: _,
|
|
2155
|
-
onLoadComplete:
|
|
2155
|
+
onLoadComplete: P,
|
|
2156
2156
|
onLoadError: C
|
|
2157
2157
|
});
|
|
2158
2158
|
Ne(() => {
|
|
@@ -2211,8 +2211,8 @@ const Bo = /* @__PURE__ */ Oe(({
|
|
|
2211
2211
|
}
|
|
2212
2212
|
);
|
|
2213
2213
|
});
|
|
2214
|
-
process.env.NODE_ENV
|
|
2215
|
-
const sa = /* @__PURE__ */
|
|
2214
|
+
process.env.NODE_ENV === "development" && (Bo.displayName = "Video");
|
|
2215
|
+
const sa = /* @__PURE__ */ Pe(({
|
|
2216
2216
|
className: e,
|
|
2217
2217
|
children: r,
|
|
2218
2218
|
style: s,
|
|
@@ -2224,7 +2224,7 @@ const sa = /* @__PURE__ */ Oe(({
|
|
|
2224
2224
|
playsInline: m,
|
|
2225
2225
|
posterSrc: N,
|
|
2226
2226
|
src: _,
|
|
2227
|
-
onCanPlay:
|
|
2227
|
+
onCanPlay: P,
|
|
2228
2228
|
onEnd: C,
|
|
2229
2229
|
onFullscreenChange: $,
|
|
2230
2230
|
onLoadMetadata: M,
|
|
@@ -2267,7 +2267,7 @@ const sa = /* @__PURE__ */ Oe(({
|
|
|
2267
2267
|
height: `${F.height}px`,
|
|
2268
2268
|
maxWidth: "unset"
|
|
2269
2269
|
}),
|
|
2270
|
-
onCanPlay:
|
|
2270
|
+
onCanPlay: P,
|
|
2271
2271
|
onEnd: C,
|
|
2272
2272
|
onFullscreenChange: $,
|
|
2273
2273
|
onLoadMetadata: M,
|
|
@@ -2305,8 +2305,8 @@ const sa = /* @__PURE__ */ Oe(({
|
|
|
2305
2305
|
transform: "translate(-50%, -50%)"
|
|
2306
2306
|
}
|
|
2307
2307
|
};
|
|
2308
|
-
process.env.NODE_ENV
|
|
2309
|
-
const aa = /* @__PURE__ */
|
|
2308
|
+
process.env.NODE_ENV === "development" && (sa.displayName = "CoverVideo", Yo.displayName = "CoverVideoContent", Xo.displayName = "CoverVideoViewport");
|
|
2309
|
+
const aa = /* @__PURE__ */ Pe(({
|
|
2310
2310
|
children: e,
|
|
2311
2311
|
style: r,
|
|
2312
2312
|
angle: s = 0,
|
|
@@ -2317,7 +2317,7 @@ const aa = /* @__PURE__ */ Oe(({
|
|
|
2317
2317
|
trackThickness: g = 2,
|
|
2318
2318
|
...m
|
|
2319
2319
|
}, N) => {
|
|
2320
|
-
const _ = u * 2,
|
|
2320
|
+
const _ = u * 2, P = Math.max(0, Math.min(360, a)), C = ze(e, {
|
|
2321
2321
|
track: Yn,
|
|
2322
2322
|
knob: Xn
|
|
2323
2323
|
}), $ = la({ angle: s, diameter: _ });
|
|
@@ -2337,7 +2337,7 @@ const aa = /* @__PURE__ */ Oe(({
|
|
|
2337
2337
|
/* @__PURE__ */ x.jsx("div", { style: le($.knobContainer), children: /* @__PURE__ */ x.jsx("svg", { style: $.svgContainer, viewBox: `0 0 ${_} ${_}`, xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ x.jsx(
|
|
2338
2338
|
ge,
|
|
2339
2339
|
{
|
|
2340
|
-
d: ca(u, u, u - l / 2 - (g - l) / 2, -
|
|
2340
|
+
d: ca(u, u, u - l / 2 - (g - l) / 2, -P / 2, P / 2),
|
|
2341
2341
|
element: C.knob ?? /* @__PURE__ */ x.jsx(Xn, {}),
|
|
2342
2342
|
fill: "none",
|
|
2343
2343
|
strokeWidth: l
|
|
@@ -2402,8 +2402,8 @@ function la({ diameter: e = 0, angle: r = 0 }) {
|
|
|
2402
2402
|
}
|
|
2403
2403
|
};
|
|
2404
2404
|
}
|
|
2405
|
-
process.env.NODE_ENV
|
|
2406
|
-
const ua = /* @__PURE__ */
|
|
2405
|
+
process.env.NODE_ENV === "development" && (aa.displayName = "Dial", Yn.displayName = "DialTrack", Xn.displayName = "DialKnob");
|
|
2406
|
+
const ua = /* @__PURE__ */ Pe(({
|
|
2407
2407
|
children: e,
|
|
2408
2408
|
className: r,
|
|
2409
2409
|
style: s,
|
|
@@ -2415,7 +2415,7 @@ const ua = /* @__PURE__ */ Oe(({
|
|
|
2415
2415
|
layout: m = "list",
|
|
2416
2416
|
isSelectionTogglable: N = !1,
|
|
2417
2417
|
itemLength: _,
|
|
2418
|
-
itemPadding:
|
|
2418
|
+
itemPadding: P = 0,
|
|
2419
2419
|
items: C = [],
|
|
2420
2420
|
maxVisibleItems: $ = -1,
|
|
2421
2421
|
numSegments: M = 1,
|
|
@@ -2433,7 +2433,7 @@ const ua = /* @__PURE__ */ Oe(({
|
|
|
2433
2433
|
ToggleComponent: q,
|
|
2434
2434
|
...ne
|
|
2435
2435
|
}, W) => {
|
|
2436
|
-
const F = Ee(null), R = nt(F), V = C.length, re = ha(C, $, M, m), ie = _ ?? (w === "vertical" ? R.height : R.width), ae = ie * re +
|
|
2436
|
+
const F = Ee(null), R = nt(F), V = C.length, re = ha(C, $, M, m), ie = _ ?? (w === "vertical" ? R.height : R.width), ae = ie * re + P * (re - 1), L = da(j, C), [T, H] = _e(u ?? !0), ee = ga({ isCollapsed: T, collectionPadding: l, isInverted: p, maxVisibleItems: $, menuLength: ae, numItems: V, orientation: w }), Z = ze(e, {
|
|
2437
2437
|
collapseIcon: Uo,
|
|
2438
2438
|
collection: Un,
|
|
2439
2439
|
expandIcon: qo,
|
|
@@ -2514,7 +2514,7 @@ const ua = /* @__PURE__ */ Oe(({
|
|
|
2514
2514
|
isSelectionTogglable: N,
|
|
2515
2515
|
ItemComponent: X,
|
|
2516
2516
|
itemLength: ie,
|
|
2517
|
-
itemPadding:
|
|
2517
|
+
itemPadding: P,
|
|
2518
2518
|
items: C,
|
|
2519
2519
|
layout: m,
|
|
2520
2520
|
numSegments: M,
|
|
@@ -2616,7 +2616,7 @@ function ga({ isCollapsed: e = !0, isInverted: r = !1, collectionPadding: s = 0,
|
|
|
2616
2616
|
}
|
|
2617
2617
|
};
|
|
2618
2618
|
}
|
|
2619
|
-
process.env.NODE_ENV
|
|
2619
|
+
process.env.NODE_ENV === "development" && (ua.displayName = "Dropdown", Un.displayName = "DropdownCollection", Uo.displayName = "DropdownCollapseIcon", qo.displayName = "DropdownExpandIcon", qn.displayName = "DropdownItem", Gn.displayName = "DropdownToggle");
|
|
2620
2620
|
const Go = ":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD", ma = Go + "\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040", va = "[" + Go + "][" + ma + "]*", ya = new RegExp("^" + va + "$");
|
|
2621
2621
|
function Wo(e, r) {
|
|
2622
2622
|
const s = [];
|
|
@@ -2664,21 +2664,21 @@ function wa(e, r) {
|
|
|
2664
2664
|
` && e[u] !== "\r"; u++)
|
|
2665
2665
|
m += e[u];
|
|
2666
2666
|
if (m = m.trim(), m[m.length - 1] === "/" && (m = m.substring(0, m.length - 1), u--), !ka(m)) {
|
|
2667
|
-
let
|
|
2668
|
-
return m.trim().length === 0 ?
|
|
2667
|
+
let P;
|
|
2668
|
+
return m.trim().length === 0 ? P = "Invalid space after '<'." : P = "Tag '" + m + "' is an invalid name.", Ce("InvalidTag", P, Ae(e, u));
|
|
2669
2669
|
}
|
|
2670
2670
|
const N = Sa(e, u);
|
|
2671
2671
|
if (N === !1)
|
|
2672
2672
|
return Ce("InvalidAttr", "Attributes for '" + m + "' have open quote.", Ae(e, u));
|
|
2673
2673
|
let _ = N.value;
|
|
2674
2674
|
if (u = N.index, _[_.length - 1] === "/") {
|
|
2675
|
-
const
|
|
2675
|
+
const P = u - _.length;
|
|
2676
2676
|
_ = _.substring(0, _.length - 1);
|
|
2677
2677
|
const C = yo(_, r);
|
|
2678
2678
|
if (C === !0)
|
|
2679
2679
|
a = !0;
|
|
2680
2680
|
else
|
|
2681
|
-
return Ce(C.err.code, C.err.msg, Ae(e,
|
|
2681
|
+
return Ce(C.err.code, C.err.msg, Ae(e, P + C.err.line));
|
|
2682
2682
|
} else if (g)
|
|
2683
2683
|
if (N.tagClosed) {
|
|
2684
2684
|
if (_.trim().length > 0)
|
|
@@ -2686,12 +2686,12 @@ function wa(e, r) {
|
|
|
2686
2686
|
if (s.length === 0)
|
|
2687
2687
|
return Ce("InvalidTag", "Closing tag '" + m + "' has not been opened.", Ae(e, p));
|
|
2688
2688
|
{
|
|
2689
|
-
const
|
|
2690
|
-
if (m !==
|
|
2691
|
-
let C = Ae(e,
|
|
2689
|
+
const P = s.pop();
|
|
2690
|
+
if (m !== P.tagName) {
|
|
2691
|
+
let C = Ae(e, P.tagStartPos);
|
|
2692
2692
|
return Ce(
|
|
2693
2693
|
"InvalidTag",
|
|
2694
|
-
"Expected closing tag '" +
|
|
2694
|
+
"Expected closing tag '" + P.tagName + "' (opened in line " + C.line + ", col " + C.col + ") instead of closing tag '" + m + "'.",
|
|
2695
2695
|
Ae(e, p)
|
|
2696
2696
|
);
|
|
2697
2697
|
}
|
|
@@ -2699,9 +2699,9 @@ function wa(e, r) {
|
|
|
2699
2699
|
}
|
|
2700
2700
|
} else return Ce("InvalidTag", "Closing tag '" + m + "' doesn't have proper closing.", Ae(e, u));
|
|
2701
2701
|
else {
|
|
2702
|
-
const
|
|
2703
|
-
if (
|
|
2704
|
-
return Ce(
|
|
2702
|
+
const P = yo(_, r);
|
|
2703
|
+
if (P !== !0)
|
|
2704
|
+
return Ce(P.err.code, P.err.msg, Ae(e, u - _.length + P.err.line));
|
|
2705
2705
|
if (l === !0)
|
|
2706
2706
|
return Ce("InvalidXml", "Multiple possible root nodes found.", Ae(e, u));
|
|
2707
2707
|
r.unpairedTags.indexOf(m) !== -1 || s.push({ tagName: m, tagStartPos: p }), a = !0;
|
|
@@ -2716,10 +2716,10 @@ function wa(e, r) {
|
|
|
2716
2716
|
} else
|
|
2717
2717
|
break;
|
|
2718
2718
|
else if (e[u] === "&") {
|
|
2719
|
-
const
|
|
2720
|
-
if (
|
|
2719
|
+
const P = Pa(e, u);
|
|
2720
|
+
if (P == -1)
|
|
2721
2721
|
return Ce("InvalidChar", "char '&' is not expected.", Ae(e, u));
|
|
2722
|
-
u =
|
|
2722
|
+
u = P;
|
|
2723
2723
|
} else if (l === !0 && !go(e[u]))
|
|
2724
2724
|
return Ce("InvalidXml", "Extra text at the end", Ae(e, u));
|
|
2725
2725
|
e[u] === "<" && u--;
|
|
@@ -2808,7 +2808,7 @@ function yo(e, r) {
|
|
|
2808
2808
|
if (s[l][3] === void 0 && !r.allowBooleanAttributes)
|
|
2809
2809
|
return Ce("InvalidAttr", "boolean attribute '" + s[l][2] + "' is not allowed.", _t(s[l]));
|
|
2810
2810
|
const u = s[l][2];
|
|
2811
|
-
if (!
|
|
2811
|
+
if (!Oa(u))
|
|
2812
2812
|
return Ce("InvalidAttr", "Attribute '" + u + "' is an invalid name.", _t(s[l]));
|
|
2813
2813
|
if (!a.hasOwnProperty(u))
|
|
2814
2814
|
a[u] = 1;
|
|
@@ -2827,7 +2827,7 @@ function _a(e, r) {
|
|
|
2827
2827
|
}
|
|
2828
2828
|
return -1;
|
|
2829
2829
|
}
|
|
2830
|
-
function
|
|
2830
|
+
function Pa(e, r) {
|
|
2831
2831
|
if (r++, e[r] === ";")
|
|
2832
2832
|
return -1;
|
|
2833
2833
|
if (e[r] === "#")
|
|
@@ -2851,7 +2851,7 @@ function Ce(e, r, s) {
|
|
|
2851
2851
|
}
|
|
2852
2852
|
};
|
|
2853
2853
|
}
|
|
2854
|
-
function
|
|
2854
|
+
function Oa(e) {
|
|
2855
2855
|
return gr(e);
|
|
2856
2856
|
}
|
|
2857
2857
|
function ka(e) {
|
|
@@ -3212,8 +3212,8 @@ const Ka = function(e) {
|
|
|
3212
3212
|
const g = lt(e, ">", u, "Closing Tag is not closed.");
|
|
3213
3213
|
let m = e.substring(u + 2, g).trim();
|
|
3214
3214
|
if (this.options.removeNSPrefix) {
|
|
3215
|
-
const
|
|
3216
|
-
|
|
3215
|
+
const P = m.indexOf(":");
|
|
3216
|
+
P !== -1 && (m = m.substr(P + 1));
|
|
3217
3217
|
}
|
|
3218
3218
|
this.options.transformTagName && (m = this.options.transformTagName(m)), s && (a = this.saveTextToParentTag(a, s, l));
|
|
3219
3219
|
const N = l.substring(l.lastIndexOf(".") + 1);
|
|
@@ -3247,7 +3247,7 @@ const Ka = function(e) {
|
|
|
3247
3247
|
} else {
|
|
3248
3248
|
let g = Wn(e, u, this.options.removeNSPrefix), m = g.tagName;
|
|
3249
3249
|
const N = g.rawTagName;
|
|
3250
|
-
let _ = g.tagExp,
|
|
3250
|
+
let _ = g.tagExp, P = g.attrExpPresent, C = g.closeIndex;
|
|
3251
3251
|
this.options.transformTagName && (m = this.options.transformTagName(m)), s && a && s.tagname !== "!xml" && (a = this.saveTextToParentTag(a, s, l, !1));
|
|
3252
3252
|
const $ = s;
|
|
3253
3253
|
$ && this.options.unpairedTags.indexOf($.tagname) !== -1 && (s = this.tagsNodeStack.pop(), l = l.substring(0, l.lastIndexOf("."))), m !== r.tagname && (l += l ? "." + m : m);
|
|
@@ -3264,15 +3264,15 @@ const Ka = function(e) {
|
|
|
3264
3264
|
u = K.i, w = K.tagContent;
|
|
3265
3265
|
}
|
|
3266
3266
|
const j = new at(m);
|
|
3267
|
-
m !== _ &&
|
|
3267
|
+
m !== _ && P && (j[":@"] = this.buildAttributesMap(_, l, m)), w && (w = this.parseTextData(w, m, l, !0, P, !0, !0)), l = l.substr(0, l.lastIndexOf(".")), j.add(this.options.textNodeName, w), this.addChild(s, j, l, M);
|
|
3268
3268
|
} else {
|
|
3269
3269
|
if (_.length > 0 && _.lastIndexOf("/") === _.length - 1) {
|
|
3270
3270
|
m[m.length - 1] === "/" ? (m = m.substr(0, m.length - 1), l = l.substr(0, l.length - 1), _ = m) : _ = _.substr(0, _.length - 1), this.options.transformTagName && (m = this.options.transformTagName(m));
|
|
3271
3271
|
const w = new at(m);
|
|
3272
|
-
m !== _ &&
|
|
3272
|
+
m !== _ && P && (w[":@"] = this.buildAttributesMap(_, l, m)), this.addChild(s, w, l, M), l = l.substr(0, l.lastIndexOf("."));
|
|
3273
3273
|
} else {
|
|
3274
3274
|
const w = new at(m);
|
|
3275
|
-
this.tagsNodeStack.push(s), m !== _ &&
|
|
3275
|
+
this.tagsNodeStack.push(s), m !== _ && P && (w[":@"] = this.buildAttributesMap(_, l, m)), this.addChild(s, w, l, M), s = w;
|
|
3276
3276
|
}
|
|
3277
3277
|
a = "", u = C;
|
|
3278
3278
|
}
|
|
@@ -3362,8 +3362,8 @@ function Wn(e, r, s, a = ">") {
|
|
|
3362
3362
|
g !== -1 && (m = u.substring(0, g), u = u.substring(g + 1).trimStart());
|
|
3363
3363
|
const _ = m;
|
|
3364
3364
|
if (s) {
|
|
3365
|
-
const
|
|
3366
|
-
|
|
3365
|
+
const P = m.indexOf(":");
|
|
3366
|
+
P !== -1 && (m = m.substr(P + 1), N = m !== l.data.substr(P + 1));
|
|
3367
3367
|
}
|
|
3368
3368
|
return {
|
|
3369
3369
|
tagName: m,
|
|
@@ -3531,7 +3531,7 @@ function Zo(e, r, s, a) {
|
|
|
3531
3531
|
}
|
|
3532
3532
|
let _ = a;
|
|
3533
3533
|
_ !== "" && (_ += r.indentBy);
|
|
3534
|
-
const
|
|
3534
|
+
const P = xo(g[":@"], r), C = a + `<${m}${P}`, $ = Zo(g[m], r, N, _);
|
|
3535
3535
|
r.unpairedTags.indexOf(m) !== -1 ? r.suppressUnpairedNode ? l += C + ">" : l += C + "/>" : (!$ || $.length === 0) && r.suppressEmptyNode ? l += C + "/>" : $ && $.endsWith(">") ? l += C + `>${$}${a}</${m}>` : (l += C + ">", $ && a !== "" && ($.includes("/>") || $.includes("</")) ? l += a + r.indentBy + $ + a : l += $, l += `</${m}>`), u = !0;
|
|
3536
3536
|
}
|
|
3537
3537
|
return l;
|
|
@@ -3642,20 +3642,20 @@ rt.prototype.j2x = function(e, r, s) {
|
|
|
3642
3642
|
const g = e[p].length;
|
|
3643
3643
|
let m = "", N = "";
|
|
3644
3644
|
for (let _ = 0; _ < g; _++) {
|
|
3645
|
-
const
|
|
3646
|
-
if (!(typeof
|
|
3645
|
+
const P = e[p][_];
|
|
3646
|
+
if (!(typeof P > "u")) if (P === null)
|
|
3647
3647
|
p[0] === "?" ? l += this.indentate(r) + "<" + p + "?" + this.tagEndChar : l += this.indentate(r) + "<" + p + "/" + this.tagEndChar;
|
|
3648
|
-
else if (typeof
|
|
3648
|
+
else if (typeof P == "object")
|
|
3649
3649
|
if (this.options.oneListGroup) {
|
|
3650
|
-
const C = this.j2x(
|
|
3651
|
-
m += C.val, this.options.attributesGroupName &&
|
|
3650
|
+
const C = this.j2x(P, r + 1, s.concat(p));
|
|
3651
|
+
m += C.val, this.options.attributesGroupName && P.hasOwnProperty(this.options.attributesGroupName) && (N += C.attrStr);
|
|
3652
3652
|
} else
|
|
3653
|
-
m += this.processTextOrObjNode(
|
|
3653
|
+
m += this.processTextOrObjNode(P, p, r, s);
|
|
3654
3654
|
else if (this.options.oneListGroup) {
|
|
3655
|
-
let C = this.options.tagValueProcessor(p,
|
|
3655
|
+
let C = this.options.tagValueProcessor(p, P);
|
|
3656
3656
|
C = this.replaceEntitiesValue(C), m += C;
|
|
3657
3657
|
} else
|
|
3658
|
-
m += this.buildTextValNode(
|
|
3658
|
+
m += this.buildTextValNode(P, p, "", r);
|
|
3659
3659
|
}
|
|
3660
3660
|
this.options.oneListGroup && (m = this.buildObjectNode(m, p, N, r)), l += m;
|
|
3661
3661
|
} else if (this.options.attributesGroupName && p === this.options.attributesGroupName) {
|
|
@@ -3711,7 +3711,7 @@ function hc(e) {
|
|
|
3711
3711
|
function gc(e) {
|
|
3712
3712
|
return e.startsWith(this.options.attributeNamePrefix) && e !== this.options.textNodeName ? e.substr(this.attrPrefixLen) : !1;
|
|
3713
3713
|
}
|
|
3714
|
-
const mc = /* @__PURE__ */
|
|
3714
|
+
const mc = /* @__PURE__ */ Pe(({
|
|
3715
3715
|
fillMode: e = "preserve",
|
|
3716
3716
|
svg: r,
|
|
3717
3717
|
shouldStripClasses: s = !0,
|
|
@@ -3720,9 +3720,9 @@ const mc = /* @__PURE__ */ Oe(({
|
|
|
3720
3720
|
shouldStripStyles: u = !0,
|
|
3721
3721
|
...p
|
|
3722
3722
|
}, g) => {
|
|
3723
|
-
const
|
|
3723
|
+
const N = ["id"].map((M) => `@_${M}`), _ = ["class"].map((M) => `@_${M}`), P = ["fill", "stroke", "style"].map((M) => `@_${M}`), C = ["x", "y"].map((M) => `@_${M}`), $ = () => {
|
|
3724
3724
|
const M = new ac({
|
|
3725
|
-
attributeNamePrefix:
|
|
3725
|
+
attributeNamePrefix: "@_",
|
|
3726
3726
|
ignoreAttributes: !1,
|
|
3727
3727
|
ignoreDeclaration: !0,
|
|
3728
3728
|
ignorePiTags: !0,
|
|
@@ -3732,23 +3732,23 @@ const mc = /* @__PURE__ */ Oe(({
|
|
|
3732
3732
|
if (u && K.toLowerCase() === "style") return !1;
|
|
3733
3733
|
const B = Object.keys(U);
|
|
3734
3734
|
for (const S of B)
|
|
3735
|
-
K.toLowerCase() === "svg" && (l && C.includes(S.toLowerCase()) && delete U[S], e !== "preserve" && (S.toLowerCase() ===
|
|
3735
|
+
K.toLowerCase() === "svg" && (l && C.includes(S.toLowerCase()) && delete U[S], e !== "preserve" && (S.toLowerCase() === "@_width" && delete U[S], S.toLowerCase() === "@_height" && delete U[S])), a && N.includes(S.toLowerCase()) && delete U[S], s && _.includes(S.toLowerCase()) && delete U[S], u && P.includes(S.toLowerCase()) && delete U[S];
|
|
3736
3736
|
if (K.toLowerCase() === "svg")
|
|
3737
3737
|
switch (e) {
|
|
3738
3738
|
case "fill":
|
|
3739
|
-
U[
|
|
3739
|
+
U["@_width"] = "100%", U["@_height"] = "100%";
|
|
3740
3740
|
break;
|
|
3741
3741
|
case "width":
|
|
3742
|
-
U[
|
|
3742
|
+
U["@_width"] = "100%";
|
|
3743
3743
|
break;
|
|
3744
3744
|
case "height":
|
|
3745
|
-
U[
|
|
3745
|
+
U["@_height"] = "100%";
|
|
3746
3746
|
break;
|
|
3747
3747
|
}
|
|
3748
3748
|
return K;
|
|
3749
3749
|
}
|
|
3750
3750
|
}), w = new rt({
|
|
3751
|
-
attributeNamePrefix:
|
|
3751
|
+
attributeNamePrefix: "@_",
|
|
3752
3752
|
format: !0,
|
|
3753
3753
|
ignoreAttributes: !1
|
|
3754
3754
|
}), j = M.parse(r);
|
|
@@ -3764,8 +3764,8 @@ const mc = /* @__PURE__ */ Oe(({
|
|
|
3764
3764
|
}
|
|
3765
3765
|
);
|
|
3766
3766
|
});
|
|
3767
|
-
process.env.NODE_ENV
|
|
3768
|
-
const bo = "base-", vc = /* @__PURE__ */
|
|
3767
|
+
process.env.NODE_ENV === "development" && (mc.displayName = "FlatSVG");
|
|
3768
|
+
const bo = "base-", vc = /* @__PURE__ */ Pe(({
|
|
3769
3769
|
alignSections: e = !1,
|
|
3770
3770
|
children: r,
|
|
3771
3771
|
className: s,
|
|
@@ -3776,7 +3776,7 @@ const bo = "base-", vc = /* @__PURE__ */ Oe(({
|
|
|
3776
3776
|
verticalSpacing: g = 0,
|
|
3777
3777
|
...m
|
|
3778
3778
|
}, N) => {
|
|
3779
|
-
const _ = Ee(null), [
|
|
3779
|
+
const _ = Ee(null), [P, C] = _e(NaN), [$, M] = _e(NaN), [w, j] = _e(NaN), [K, J] = _e(NaN), U = () => xe.from(_.current)?.width ?? 0, B = () => xe.from(_.current)?.height ?? 0, S = () => {
|
|
3780
3780
|
const X = _.current;
|
|
3781
3781
|
if (!X) return;
|
|
3782
3782
|
const q = X.children, ne = p;
|
|
@@ -3793,12 +3793,12 @@ const bo = "base-", vc = /* @__PURE__ */ Oe(({
|
|
|
3793
3793
|
for (let L = 0; L < re; L++)
|
|
3794
3794
|
W[ie + L] = ae + (ae === 0 ? 0 : g) + (xe.from(V)?.height ?? 0);
|
|
3795
3795
|
if (e && ie + re === ne) {
|
|
3796
|
-
const L =
|
|
3796
|
+
const L = Ot(W);
|
|
3797
3797
|
for (let T = 0; T < ne; T++)
|
|
3798
3798
|
W[T] = L;
|
|
3799
3799
|
}
|
|
3800
3800
|
}
|
|
3801
|
-
const F = U(), R =
|
|
3801
|
+
const F = U(), R = Ot(W, ne);
|
|
3802
3802
|
if (C(F), M(R), isNaN(R) || (X.style.height = `${R}px`), l)
|
|
3803
3803
|
for (const V of Array.from(q))
|
|
3804
3804
|
V instanceof HTMLElement && (V.style.left = `calc(${F}px - ${V.style.left} - ${V.getBoundingClientRect().width}px)`);
|
|
@@ -3811,19 +3811,19 @@ const bo = "base-", vc = /* @__PURE__ */ Oe(({
|
|
|
3811
3811
|
for (let L = 0; L < re; L++)
|
|
3812
3812
|
W[ie + L] = ae + (ae === 0 ? 0 : a) + (xe.from(V)?.width ?? 0);
|
|
3813
3813
|
if (e && ie + re === ne) {
|
|
3814
|
-
const L =
|
|
3814
|
+
const L = Ot(W);
|
|
3815
3815
|
for (let T = 0; T < ne; T++)
|
|
3816
3816
|
W[T] = L;
|
|
3817
3817
|
}
|
|
3818
3818
|
}
|
|
3819
|
-
const F = B(), R =
|
|
3819
|
+
const F = B(), R = Ot(W, ne);
|
|
3820
3820
|
if (M(F), C(R), isNaN(R) || (X.style.width = `${R}px`), l)
|
|
3821
3821
|
for (const V of Array.from(q))
|
|
3822
3822
|
V instanceof HTMLElement && (V.style.top = `calc(${F}px - ${V.style.top} - ${V.getBoundingClientRect().height}px)`);
|
|
3823
3823
|
}
|
|
3824
3824
|
}, k = he((X) => {
|
|
3825
3825
|
const q = xe.size(xe.from(X) ?? xe.zero), ne = U(), W = B();
|
|
3826
|
-
(
|
|
3826
|
+
(P !== ne || $ !== W || q.width !== w || q.height !== K) && (S(), j(q.width), J(q.height));
|
|
3827
3827
|
}, [e, a, l, p, g, u]);
|
|
3828
3828
|
dr(_, {
|
|
3829
3829
|
onResize: k
|
|
@@ -3836,7 +3836,7 @@ const bo = "base-", vc = /* @__PURE__ */ Oe(({
|
|
|
3836
3836
|
F.src = W, F.onload = () => S();
|
|
3837
3837
|
}
|
|
3838
3838
|
}, [r]);
|
|
3839
|
-
const E = yc({ orientation: u }), A = xc({ orientation: u, minHeight: $, minWidth:
|
|
3839
|
+
const E = yc({ orientation: u }), A = xc({ orientation: u, minHeight: $, minWidth: P });
|
|
3840
3840
|
return /* @__PURE__ */ x.jsx(
|
|
3841
3841
|
"div",
|
|
3842
3842
|
{
|
|
@@ -3874,9 +3874,9 @@ function wo(e, r) {
|
|
|
3874
3874
|
e[u + _] > p && (N = !1);
|
|
3875
3875
|
g && m && N && (a = u, l = p);
|
|
3876
3876
|
}
|
|
3877
|
-
return isNaN(a) ? [0,
|
|
3877
|
+
return isNaN(a) ? [0, Ot(e, r)] : [a, l];
|
|
3878
3878
|
}
|
|
3879
|
-
function
|
|
3879
|
+
function Ot(e, r) {
|
|
3880
3880
|
let s = e;
|
|
3881
3881
|
return r != null && !isNaN(r) && (s = s.slice(0, Math.max(1, Math.min(r, e.length)))), s.reduce((a, l, u) => l > a ? l : a, 0);
|
|
3882
3882
|
}
|
|
@@ -3898,8 +3898,8 @@ function bc(e) {
|
|
|
3898
3898
|
}
|
|
3899
3899
|
return l;
|
|
3900
3900
|
}
|
|
3901
|
-
process.env.NODE_ENV
|
|
3902
|
-
const wc = /* @__PURE__ */
|
|
3901
|
+
process.env.NODE_ENV === "development" && (vc.displayName = "MasonryGrid");
|
|
3902
|
+
const wc = /* @__PURE__ */ Pe(({
|
|
3903
3903
|
index: e = 0,
|
|
3904
3904
|
isDisabled: r = !1,
|
|
3905
3905
|
options: s,
|
|
@@ -3908,7 +3908,7 @@ const wc = /* @__PURE__ */ Oe(({
|
|
|
3908
3908
|
}, u) => {
|
|
3909
3909
|
const p = s.length - 1, g = s[e], m = typeof g == "string" ? g : g?.label, N = () => {
|
|
3910
3910
|
if (r) return;
|
|
3911
|
-
const _ = e < p ? e + 1 : 0,
|
|
3911
|
+
const _ = e < p ? e + 1 : 0, P = s[_], C = typeof P == "string" ? P : P?.value;
|
|
3912
3912
|
a?.(C, _);
|
|
3913
3913
|
};
|
|
3914
3914
|
return /* @__PURE__ */ x.jsx(
|
|
@@ -3924,7 +3924,7 @@ const wc = /* @__PURE__ */ Oe(({
|
|
|
3924
3924
|
}
|
|
3925
3925
|
);
|
|
3926
3926
|
});
|
|
3927
|
-
process.env.NODE_ENV
|
|
3927
|
+
process.env.NODE_ENV === "development" && (wc.displayName = "OptionButton");
|
|
3928
3928
|
var Wt = { exports: {} }, Ec = Wt.exports, No;
|
|
3929
3929
|
function Nc() {
|
|
3930
3930
|
return No || (No = 1, function(e, r) {
|
|
@@ -3976,17 +3976,17 @@ function Nc() {
|
|
|
3976
3976
|
}
|
|
3977
3977
|
function N(n, t) {
|
|
3978
3978
|
if (typeof t != "function" && t !== null) throw new TypeError("Super expression must either be null or a function");
|
|
3979
|
-
n.prototype = Object.create(t && t.prototype, { constructor: { value: n, writable: !0, configurable: !0 } }), Object.defineProperty(n, "prototype", { writable: !1 }), t &&
|
|
3979
|
+
n.prototype = Object.create(t && t.prototype, { constructor: { value: n, writable: !0, configurable: !0 } }), Object.defineProperty(n, "prototype", { writable: !1 }), t && P(n, t);
|
|
3980
3980
|
}
|
|
3981
3981
|
function _(n) {
|
|
3982
3982
|
return _ = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t) {
|
|
3983
3983
|
return t.__proto__ || Object.getPrototypeOf(t);
|
|
3984
3984
|
}, _(n);
|
|
3985
3985
|
}
|
|
3986
|
-
function
|
|
3987
|
-
return
|
|
3986
|
+
function P(n, t) {
|
|
3987
|
+
return P = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(o, i) {
|
|
3988
3988
|
return o.__proto__ = i, o;
|
|
3989
|
-
},
|
|
3989
|
+
}, P(n, t);
|
|
3990
3990
|
}
|
|
3991
3991
|
function C(n) {
|
|
3992
3992
|
if (n === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
@@ -4362,8 +4362,8 @@ function Nc() {
|
|
|
4362
4362
|
for (var h = [], v = 0, b = f.interactables.list; v < b.length; v++) {
|
|
4363
4363
|
var y = b[v];
|
|
4364
4364
|
if (y.options.drop.enabled) {
|
|
4365
|
-
var
|
|
4366
|
-
if (!(E.element(
|
|
4365
|
+
var O = y.options.drop.accept;
|
|
4366
|
+
if (!(E.element(O) && O !== d || E.string(O) && !T(d, O) || E.func(O) && !O({ dropzone: y, draggableElement: d }))) for (var I = 0, D = y.getAllElements(); I < D.length; I++) {
|
|
4367
4367
|
var z = D[I];
|
|
4368
4368
|
z !== d && h.push({ dropzone: y, element: z, rect: y.getRect(z) });
|
|
4369
4369
|
}
|
|
@@ -4376,21 +4376,21 @@ function Nc() {
|
|
|
4376
4376
|
}
|
|
4377
4377
|
return o;
|
|
4378
4378
|
}
|
|
4379
|
-
function
|
|
4379
|
+
function Pr(n, t, o) {
|
|
4380
4380
|
for (var i = n.dropState, c = n.interactable, f = n.element, d = [], h = 0, v = i.activeDrops; h < v.length; h++) {
|
|
4381
|
-
var b = v[h], y = b.dropzone,
|
|
4382
|
-
d.push(D ?
|
|
4381
|
+
var b = v[h], y = b.dropzone, O = b.element, I = b.rect, D = y.dropCheck(t, o, c, f, O, I);
|
|
4382
|
+
d.push(D ? O : null);
|
|
4383
4383
|
}
|
|
4384
4384
|
var z = function(Y) {
|
|
4385
4385
|
for (var oe, te, ce, ve = [], we = 0; we < Y.length; we++) {
|
|
4386
4386
|
var fe = Y[we], ye = Y[oe];
|
|
4387
4387
|
if (fe && we !== oe) if (ye) {
|
|
4388
|
-
var $e = H(fe),
|
|
4389
|
-
if ($e !== fe.ownerDocument) if (
|
|
4388
|
+
var $e = H(fe), Oe = H(ye);
|
|
4389
|
+
if ($e !== fe.ownerDocument) if (Oe !== fe.ownerDocument) if ($e !== Oe) {
|
|
4390
4390
|
ve = ve.length ? ve : ee(ye);
|
|
4391
4391
|
var Le = void 0;
|
|
4392
4392
|
if (ye instanceof R.HTMLElement && fe instanceof R.SVGElement && !(fe instanceof R.SVGSVGElement)) {
|
|
4393
|
-
if (fe ===
|
|
4393
|
+
if (fe === Oe) continue;
|
|
4394
4394
|
Le = fe.ownerSVGElement;
|
|
4395
4395
|
} else Le = fe;
|
|
4396
4396
|
for (var He = ee(Le, ye.ownerDocument), qe = 0; He[qe] && He[qe] === ve[qe]; ) qe++;
|
|
@@ -4419,12 +4419,12 @@ function Nc() {
|
|
|
4419
4419
|
var o = n.dropState, i = o.activeDrops, c = o.cur, f = o.prev;
|
|
4420
4420
|
t.leave && f.dropzone.fire(t.leave), t.enter && c.dropzone.fire(t.enter), t.move && c.dropzone.fire(t.move), t.drop && c.dropzone.fire(t.drop), t.deactivate && _r(i, t.deactivate), o.prev.dropzone = c.dropzone, o.prev.element = c.element;
|
|
4421
4421
|
}
|
|
4422
|
-
function
|
|
4422
|
+
function Or(n, t) {
|
|
4423
4423
|
var o = n.interaction, i = n.iEvent, c = n.event;
|
|
4424
4424
|
if (i.type === "dragmove" || i.type === "dragend") {
|
|
4425
4425
|
var f = o.dropState;
|
|
4426
4426
|
t.dynamicDrop && (f.activeDrops = hn(t, o.element));
|
|
4427
|
-
var d = i, h =
|
|
4427
|
+
var d = i, h = Pr(o, d, c);
|
|
4428
4428
|
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 = gn(o, 0, d);
|
|
4429
4429
|
}
|
|
4430
4430
|
}
|
|
@@ -4434,8 +4434,8 @@ function Nc() {
|
|
|
4434
4434
|
return function(d, h) {
|
|
4435
4435
|
if (E.object(h)) {
|
|
4436
4436
|
if (d.options.drop.enabled = h.enabled !== !1, h.listeners) {
|
|
4437
|
-
var v = Ye(h.listeners), b = Object.keys(v).reduce(function(
|
|
4438
|
-
return
|
|
4437
|
+
var v = Ye(h.listeners), b = Object.keys(v).reduce(function(O, I) {
|
|
4438
|
+
return O[/^(enter|leave)/.test(I) ? "drag".concat(I) : /^(activate|deactivate|move)/.test(I) ? "drop".concat(I) : I] = v[I], O;
|
|
4439
4439
|
}, {}), y = d.options.drop.listeners;
|
|
4440
4440
|
y && d.off(y), d.on(b), d.options.drop.listeners = b;
|
|
4441
4441
|
}
|
|
@@ -4444,22 +4444,22 @@ function Nc() {
|
|
|
4444
4444
|
return E.bool(h) ? (d.options.drop.enabled = h, d) : d.options.drop;
|
|
4445
4445
|
}(this, f);
|
|
4446
4446
|
}, i.prototype.dropCheck = function(f, d, h, v, b, y) {
|
|
4447
|
-
return function(
|
|
4447
|
+
return function(O, I, D, z, Y, oe, te) {
|
|
4448
4448
|
var ce = !1;
|
|
4449
|
-
if (!(te = te ||
|
|
4450
|
-
var ve =
|
|
4449
|
+
if (!(te = te || O.getRect(oe))) return !!O.options.drop.checker && O.options.drop.checker(I, D, ce, O, oe, z, Y);
|
|
4450
|
+
var ve = O.options.drop.overlap;
|
|
4451
4451
|
if (ve === "pointer") {
|
|
4452
4452
|
var we = Be(z, Y, "drag"), fe = br(I);
|
|
4453
4453
|
fe.x += we.x, fe.y += we.y;
|
|
4454
4454
|
var ye = fe.x > te.left && fe.x < te.right, $e = fe.y > te.top && fe.y < te.bottom;
|
|
4455
4455
|
ce = ye && $e;
|
|
4456
4456
|
}
|
|
4457
|
-
var
|
|
4458
|
-
if (
|
|
4459
|
-
var Le =
|
|
4457
|
+
var Oe = z.getRect(Y);
|
|
4458
|
+
if (Oe && ve === "center") {
|
|
4459
|
+
var Le = Oe.left + Oe.width / 2, He = Oe.top + Oe.height / 2;
|
|
4460
4460
|
ce = Le >= te.left && Le <= te.right && He >= te.top && He <= te.bottom;
|
|
4461
4461
|
}
|
|
4462
|
-
return
|
|
4462
|
+
return Oe && E.number(ve) && (ce = Math.max(0, Math.min(te.right, Oe.right) - Math.max(te.left, Oe.left)) * Math.max(0, Math.min(te.bottom, Oe.bottom) - Math.max(te.top, Oe.top)) / (Oe.width * Oe.height) >= ve), O.options.drop.checker && (ce = O.options.drop.checker(I, D, ce, O, oe, z, Y)), ce;
|
|
4463
4463
|
}(this, f, d, h, v, b, y);
|
|
4464
4464
|
}, o.dynamicDrop = function(f) {
|
|
4465
4465
|
return E.bool(f) ? (n.dynamicDrop = f, o) : n.dynamicDrop;
|
|
@@ -4473,7 +4473,7 @@ function Nc() {
|
|
|
4473
4473
|
var c = o.dropState;
|
|
4474
4474
|
c.activeDrops = [], c.events = {}, c.activeDrops = hn(t, o.element), c.events = gn(o, 0, i), c.events.activate && (_r(c.activeDrops, c.events.activate), t.fire("actions/drop:start", { interaction: o, dragEvent: i }));
|
|
4475
4475
|
}
|
|
4476
|
-
}, "interactions:action-move":
|
|
4476
|
+
}, "interactions:action-move": Or, "interactions:after-action-move": function(n, t) {
|
|
4477
4477
|
var o = n.interaction, i = n.iEvent;
|
|
4478
4478
|
if (o.prepared.name === "drag") {
|
|
4479
4479
|
var c = o.dropState;
|
|
@@ -4482,7 +4482,7 @@ function Nc() {
|
|
|
4482
4482
|
}, "interactions:action-end": function(n, t) {
|
|
4483
4483
|
if (n.interaction.prepared.name === "drag") {
|
|
4484
4484
|
var o = n.interaction, i = n.iEvent;
|
|
4485
|
-
|
|
4485
|
+
Or(n, t), mn(o, o.dropState.events), t.fire("actions/drop:end", { interaction: o, dragEvent: i });
|
|
4486
4486
|
}
|
|
4487
4487
|
}, "interactions:stop": function(n) {
|
|
4488
4488
|
var t = n.interaction;
|
|
@@ -4490,7 +4490,7 @@ function Nc() {
|
|
|
4490
4490
|
var o = t.dropState;
|
|
4491
4491
|
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);
|
|
4492
4492
|
}
|
|
4493
|
-
} }, getActiveDrops: hn, getDrop:
|
|
4493
|
+
} }, getActiveDrops: hn, getDrop: Pr, getDropEvents: gn, fireDropEvents: mn, filterEventType: function(n) {
|
|
4494
4494
|
return n.search("drag") === 0 || n.search("drop") === 0;
|
|
4495
4495
|
}, defaults: { enabled: !1, accept: null, overlap: "pointer" } }, ai = kr;
|
|
4496
4496
|
function vn(n) {
|
|
@@ -4571,7 +4571,7 @@ function Nc() {
|
|
|
4571
4571
|
(function(t) {
|
|
4572
4572
|
var o = t.iEvent, i = t.interaction;
|
|
4573
4573
|
if (i.prepared.name === "resize" && i.prepared.edges) {
|
|
4574
|
-
var c = o, f = i.interactable.options.resize.invert, d = f === "reposition" || f === "negate", h = i.rect, v = i._rects, b = v.start, y = v.corrected,
|
|
4574
|
+
var c = o, f = i.interactable.options.resize.invert, d = f === "reposition" || f === "negate", h = i.rect, v = i._rects, b = v.start, y = v.corrected, O = v.delta, I = v.previous;
|
|
4575
4575
|
if (G(I, y), d) {
|
|
4576
4576
|
if (G(y, h), f === "reposition") {
|
|
4577
4577
|
if (y.top > y.bottom) {
|
|
@@ -4584,8 +4584,8 @@ function Nc() {
|
|
|
4584
4584
|
}
|
|
4585
4585
|
}
|
|
4586
4586
|
} else y.top = Math.min(h.top, b.bottom), y.bottom = Math.max(h.bottom, b.top), y.left = Math.min(h.left, b.right), y.right = Math.max(h.right, b.left);
|
|
4587
|
-
for (var Y in y.width = y.right - y.left, y.height = y.bottom - y.top, y)
|
|
4588
|
-
c.edges = i.prepared.edges, c.rect = y, c.deltaRect =
|
|
4587
|
+
for (var Y in y.width = y.right - y.left, y.height = y.bottom - y.top, y) O[Y] = y[Y] - I[Y];
|
|
4588
|
+
c.edges = i.prepared.edges, c.rect = y, c.deltaRect = O;
|
|
4589
4589
|
}
|
|
4590
4590
|
})(n), Cr(n);
|
|
4591
4591
|
}, "interactions:action-end": function(n) {
|
|
@@ -4604,8 +4604,8 @@ function Nc() {
|
|
|
4604
4604
|
for (var b in v) v[b] = li(b, h.edges[b], d, t._latestPointer.eventTarget, i, c, h.margin || Ue.defaultMargin);
|
|
4605
4605
|
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 });
|
|
4606
4606
|
} else {
|
|
4607
|
-
var y = h.axis !== "y" && d.x > c.right - Ue.defaultMargin,
|
|
4608
|
-
(y ||
|
|
4607
|
+
var y = h.axis !== "y" && d.x > c.right - Ue.defaultMargin, O = h.axis !== "x" && d.y > c.bottom - Ue.defaultMargin;
|
|
4608
|
+
(y || O) && (n.action = { name: "resize", axes: (y ? "x" : "") + (O ? "y" : "") });
|
|
4609
4609
|
}
|
|
4610
4610
|
return !n.action && void 0;
|
|
4611
4611
|
}
|
|
@@ -4653,7 +4653,7 @@ function Nc() {
|
|
|
4653
4653
|
if (b.x || b.y) {
|
|
4654
4654
|
var y = $r(f);
|
|
4655
4655
|
E.window(f) ? f.scrollBy(b.x, b.y) : f && (f.scrollLeft += b.x, f.scrollTop += b.y);
|
|
4656
|
-
var
|
|
4656
|
+
var O = $r(f), I = { x: O.x - y.x, y: O.y - y.y };
|
|
4657
4657
|
(I.x || I.y) && t.fire({ type: "autoscroll", target: o, interactable: t, delta: I, interaction: n, container: f });
|
|
4658
4658
|
}
|
|
4659
4659
|
de.prevTime = d;
|
|
@@ -4666,10 +4666,10 @@ function Nc() {
|
|
|
4666
4666
|
var t = n.interaction, o = n.pointer;
|
|
4667
4667
|
if (t.interacting() && de.check(t.interactable, t.prepared.name)) if (t.simulation) de.x = de.y = 0;
|
|
4668
4668
|
else {
|
|
4669
|
-
var i, c, f, d, h = t.interactable, v = t.element, b = t.prepared.name, y = h.options[b].autoScroll,
|
|
4670
|
-
if (E.window(
|
|
4669
|
+
var i, c, f, d, h = t.interactable, v = t.element, b = t.prepared.name, y = h.options[b].autoScroll, O = Ir(y.container, h, v);
|
|
4670
|
+
if (E.window(O)) d = o.clientX < de.margin, i = o.clientY < de.margin, c = o.clientX > O.innerWidth - de.margin, f = o.clientY > O.innerHeight - de.margin;
|
|
4671
4671
|
else {
|
|
4672
|
-
var I = ue(
|
|
4672
|
+
var I = ue(O);
|
|
4673
4673
|
d = o.clientX < I.left + de.margin, i = o.clientY < I.top + de.margin, c = o.clientX > I.right - de.margin, f = o.clientY > I.bottom - de.margin;
|
|
4674
4674
|
}
|
|
4675
4675
|
de.x = c ? 1 : d ? -1 : 0, de.y = f ? 1 : i ? -1 : 0, de.isScrolling || (de.margin = y.margin, de.speed = y.speed, de.start(t));
|
|
@@ -4711,9 +4711,9 @@ function Nc() {
|
|
|
4711
4711
|
var mi = { id: "auto-start/interactableMethods", install: function(n) {
|
|
4712
4712
|
var t = n.Interactable;
|
|
4713
4713
|
t.prototype.getAction = function(o, i, c, f) {
|
|
4714
|
-
var d = function(h, v, b, y,
|
|
4714
|
+
var d = function(h, v, b, y, O) {
|
|
4715
4715
|
var I = h.getRect(y), D = v.buttons || { 0: 1, 1: 4, 3: 8, 4: 16 }[v.button], z = { action: null, interactable: h, interaction: b, element: y, rect: I, buttons: D };
|
|
4716
|
-
return
|
|
4716
|
+
return O.fire("auto-start:check", z), z.action;
|
|
4717
4717
|
}(this, i, c, f, n);
|
|
4718
4718
|
return this.options.actionChecker ? this.options.actionChecker(o, i, d, this, f, c) : d;
|
|
4719
4719
|
}, t.prototype.ignoreFrom = vt(function(o) {
|
|
@@ -4727,9 +4727,9 @@ function Nc() {
|
|
|
4727
4727
|
}
|
|
4728
4728
|
function vi(n, t, o, i, c, f, d) {
|
|
4729
4729
|
for (var h = 0, v = i.length; h < v; h++) {
|
|
4730
|
-
var b = i[h], y = c[h],
|
|
4731
|
-
if (
|
|
4732
|
-
var I = Ar(
|
|
4730
|
+
var b = i[h], y = c[h], O = b.getAction(t, o, n, y);
|
|
4731
|
+
if (O) {
|
|
4732
|
+
var I = Ar(O, b, y, f, d);
|
|
4733
4733
|
if (I) return { action: I, interactable: b, element: y };
|
|
4734
4734
|
}
|
|
4735
4735
|
}
|
|
@@ -4755,8 +4755,8 @@ function Nc() {
|
|
|
4755
4755
|
function Rt(n, t, o, i) {
|
|
4756
4756
|
var c = n.options, f = c[o.name].max, d = c[o.name].maxPerElement, h = i.autoStart.maxInteractions, v = 0, b = 0, y = 0;
|
|
4757
4757
|
if (!(f && d && h)) return !1;
|
|
4758
|
-
for (var
|
|
4759
|
-
var D = I[
|
|
4758
|
+
for (var O = 0, I = i.interactions.list; O < I.length; O++) {
|
|
4759
|
+
var D = I[O], z = D.prepared.name;
|
|
4760
4760
|
if (D.interacting() && (++v >= h || D.interactable === n && ((b += z === o.name ? 1 : 0) >= f || D.element === t && (y++, z === o.name && y >= d))))
|
|
4761
4761
|
return !1;
|
|
4762
4762
|
}
|
|
@@ -4809,25 +4809,25 @@ function Nc() {
|
|
|
4809
4809
|
var d = Math.abs(c), h = Math.abs(f), v = o.interactable.options.drag, b = v.startAxis, y = d > h ? "x" : d < h ? "y" : "xy";
|
|
4810
4810
|
if (o.prepared.axis = v.lockAxis === "start" ? y[0] : v.lockAxis, y !== "xy" && b !== "xy" && b !== y) {
|
|
4811
4811
|
o.prepared.name = null;
|
|
4812
|
-
for (var
|
|
4812
|
+
for (var O = i, I = function(z) {
|
|
4813
4813
|
if (z !== o.interactable) {
|
|
4814
4814
|
var Y = o.interactable.options.drag;
|
|
4815
|
-
if (!Y.manualStart && z.testIgnoreAllow(Y,
|
|
4816
|
-
var oe = z.getAction(o.downPointer, o.downEvent, o,
|
|
4815
|
+
if (!Y.manualStart && z.testIgnoreAllow(Y, O, i)) {
|
|
4816
|
+
var oe = z.getAction(o.downPointer, o.downEvent, o, O);
|
|
4817
4817
|
if (oe && oe.name === "drag" && function(te, ce) {
|
|
4818
4818
|
if (!ce) return !1;
|
|
4819
4819
|
var ve = ce.options.drag.startAxis;
|
|
4820
4820
|
return te === "xy" || ve === "xy" || ve === te;
|
|
4821
|
-
}(y, z) && wn.validateAction(oe, z,
|
|
4821
|
+
}(y, z) && wn.validateAction(oe, z, O, i, t)) return z;
|
|
4822
4822
|
}
|
|
4823
4823
|
}
|
|
4824
|
-
}; E.element(
|
|
4825
|
-
var D = t.interactables.forEachMatch(
|
|
4824
|
+
}; E.element(O); ) {
|
|
4825
|
+
var D = t.interactables.forEachMatch(O, I);
|
|
4826
4826
|
if (D) {
|
|
4827
|
-
o.prepared.name = "drag", o.interactable = D, o.element =
|
|
4827
|
+
o.prepared.name = "drag", o.interactable = D, o.element = O;
|
|
4828
4828
|
break;
|
|
4829
4829
|
}
|
|
4830
|
-
|
|
4830
|
+
O = L(O);
|
|
4831
4831
|
}
|
|
4832
4832
|
}
|
|
4833
4833
|
}
|
|
@@ -4904,8 +4904,8 @@ function Nc() {
|
|
|
4904
4904
|
}
|
|
4905
4905
|
return g(n, [{ key: "start", value: function(t, o) {
|
|
4906
4906
|
var i, c, f = t.phase, d = this.interaction, h = function(b) {
|
|
4907
|
-
var y = b.interactable.options[b.prepared.name],
|
|
4908
|
-
return
|
|
4907
|
+
var y = b.interactable.options[b.prepared.name], O = y.modifiers;
|
|
4908
|
+
return O && O.length ? O : ["snap", "snapSize", "snapEdges", "restrict", "restrictEdges", "restrictSize"].map(function(I) {
|
|
4909
4909
|
var D = y[I];
|
|
4910
4910
|
return D && D.enabled && { options: D, methods: D._methods };
|
|
4911
4911
|
}).filter(function(I) {
|
|
@@ -4927,8 +4927,8 @@ function Nc() {
|
|
|
4927
4927
|
var o = t.phase, i = t.preEnd, c = t.skipModifiers, f = t.rect, d = t.edges;
|
|
4928
4928
|
t.coords = G({}, t.pageCoords), t.rect = G({}, f), t.edges = G({}, d);
|
|
4929
4929
|
for (var h = c ? this.states.slice(c) : this.states, v = Lt(t.coords, t.rect), b = 0; b < h.length; b++) {
|
|
4930
|
-
var y,
|
|
4931
|
-
(y =
|
|
4930
|
+
var y, O = h[b], I = O.options, D = G({}, t.coords), z = null;
|
|
4931
|
+
(y = O.methods) != null && y.set && this.shouldDo(I, i, o) && (t.state = O, z = O.methods.set(t), Re(t.edges, t.rect, { x: t.coords.x - D.x, y: t.coords.y - D.y })), v.eventProps.push(z);
|
|
4932
4932
|
}
|
|
4933
4933
|
G(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;
|
|
4934
4934
|
var Y = this.result.coords, oe = this.result.rect;
|
|
@@ -4941,7 +4941,7 @@ function Nc() {
|
|
|
4941
4941
|
var o = this.interaction, i = t.phase, c = o.coords.cur, f = o.coords.start, d = this.result, h = this.startDelta, v = d.delta;
|
|
4942
4942
|
i === "start" && G(this.startDelta, d.delta);
|
|
4943
4943
|
for (var b = 0, y = [[f, h], [c, v]]; b < y.length; b++) {
|
|
4944
|
-
var
|
|
4944
|
+
var O = y[b], I = O[0], D = O[1];
|
|
4945
4945
|
I.page.x += D.x, I.page.y += D.y, I.client.x += D.x, I.client.y += D.y;
|
|
4946
4946
|
}
|
|
4947
4947
|
var z = this.result.rectDelta, Y = t.rect || o.rect;
|
|
@@ -4987,8 +4987,8 @@ function Nc() {
|
|
|
4987
4987
|
} }, { key: "restoreInteractionCoords", value: function(t) {
|
|
4988
4988
|
var o = t.interaction, i = o.coords, c = o.rect, f = o.modification;
|
|
4989
4989
|
if (f.result) {
|
|
4990
|
-
for (var d = f.startDelta, h = f.result, v = h.delta, b = h.rectDelta, y = 0,
|
|
4991
|
-
var I =
|
|
4990
|
+
for (var d = f.startDelta, h = f.result, v = h.delta, b = h.rectDelta, y = 0, O = [[i.start, d], [i.cur, v]]; y < O.length; y++) {
|
|
4991
|
+
var I = O[y], D = I[0], z = I[1];
|
|
4992
4992
|
D.page.x -= z.x, D.page.y -= z.y, D.client.x -= z.x, D.client.y -= z.y;
|
|
4993
4993
|
}
|
|
4994
4994
|
c.left -= b.left, c.right -= b.right, c.top -= b.top, c.bottom -= b.bottom;
|
|
@@ -5049,8 +5049,8 @@ function Nc() {
|
|
|
5049
5049
|
function o(i, c, f, d, h, v, b) {
|
|
5050
5050
|
var y;
|
|
5051
5051
|
u(this, o), (y = t.call(this, i)).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 || i.element;
|
|
5052
|
-
var
|
|
5053
|
-
return y.page = G({}, te.page), y.client = G({}, te.client), y.rect = G({}, i.rect), y.timeStamp = te.timeStamp, Y || (y.page.x -= D.x, y.page.y -= D.y, y.client.x -= D.x, y.client.y -= D.y), y.ctrlKey = c.ctrlKey, y.altKey = c.altKey, y.shiftKey = c.shiftKey, y.metaKey = c.metaKey, y.button = c.button, y.buttons = c.buttons, y.target = h, y.currentTarget = h, y.preEnd = v, y.type = b || f + (d || ""), y.interactable =
|
|
5052
|
+
var O = i.interactable, I = (O && O.options || Hr).deltaSource, D = Be(O, h, f), z = d === "start", Y = d === "end", oe = z ? C(y) : i.prevEvent, te = z ? i.coords.start : Y ? { page: oe.page, client: oe.client, timeStamp: i.coords.cur.timeStamp } : i.coords.cur;
|
|
5053
|
+
return y.page = G({}, te.page), y.client = G({}, te.client), y.rect = G({}, i.rect), y.timeStamp = te.timeStamp, Y || (y.page.x -= D.x, y.page.y -= D.y, y.client.x -= D.x, y.client.y -= D.y), y.ctrlKey = c.ctrlKey, y.altKey = c.altKey, y.shiftKey = c.shiftKey, y.metaKey = c.metaKey, y.button = c.button, y.buttons = c.buttons, y.target = h, y.currentTarget = h, y.preEnd = v, y.type = b || f + (d || ""), y.interactable = O, y.t0 = z ? i.pointers[i.pointers.length - 1].downTime : oe.t0, y.x0 = i.coords.start.page.x - D.x, y.y0 = i.coords.start.page.y - D.y, y.clientX0 = i.coords.start.client.x - D.x, y.clientY0 = i.coords.start.client.y - D.y, y.delta = z || Y ? { x: 0, y: 0 } : { x: y[I].x - oe[I].x, y: y[I].y - oe[I].y }, y.dt = i.coords.delta.timeStamp, y.duration = y.timeStamp - y.t0, y.velocity = G({}, i.coords.velocity[I]), y.speed = pt(y.velocity.x, y.velocity.y), y.swipe = Y || d === "inertiastart" ? y.getSwipe() : null, y;
|
|
5054
5054
|
}
|
|
5055
5055
|
return g(o, [{ key: "getSwipe", value: function() {
|
|
5056
5056
|
var i = this._interaction;
|
|
@@ -5101,16 +5101,16 @@ function Nc() {
|
|
|
5101
5101
|
} } });
|
|
5102
5102
|
var _i = g(function n(t, o, i, c, f) {
|
|
5103
5103
|
u(this, n), this.id = void 0, this.pointer = void 0, this.event = void 0, this.downTime = void 0, this.downTarget = void 0, this.id = t, this.pointer = o, this.event = i, this.downTime = c, this.downTarget = f;
|
|
5104
|
-
}),
|
|
5104
|
+
}), Pi = function(n) {
|
|
5105
5105
|
return n.interactable = "", n.element = "", n.prepared = "", n.pointerIsDown = "", n.pointerWasMoved = "", n._proxy = "", n;
|
|
5106
5106
|
}({}), Vr = function(n) {
|
|
5107
5107
|
return n.start = "", n.move = "", n.end = "", n.stop = "", n.interacting = "", n;
|
|
5108
|
-
}({}),
|
|
5108
|
+
}({}), Oi = 0, ki = function() {
|
|
5109
5109
|
function n(t) {
|
|
5110
5110
|
var o = this, i = t.pointerType, c = t.scopeFire;
|
|
5111
5111
|
u(this, n), this.interactable = null, this.element = null, this.rect = null, this._rects = void 0, this.edges = null, this._scopeFire = void 0, this.prepared = { name: null, axis: null, edges: null }, this.pointerType = void 0, this.pointers = [], this.downEvent = null, this.downPointer = {}, this._latestPointer = { pointer: null, event: null, eventTarget: null }, this.prevEvent = null, this.pointerIsDown = !1, this.pointerWasMoved = !1, this._interacting = !1, this._ending = !1, this._stopped = !0, this._proxy = void 0, this.simulation = null, this.doMove = vt(function(y) {
|
|
5112
5112
|
this.move(y);
|
|
5113
|
-
}, "The interaction.doMove() method has been renamed to interaction.move()"), this.coords = { start: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, prev: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, cur: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, delta: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, velocity: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 } }, this._id =
|
|
5113
|
+
}, "The interaction.doMove() method has been renamed to interaction.move()"), this.coords = { start: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, prev: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, cur: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, delta: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, velocity: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 } }, this._id = Oi++, this._scopeFire = c, this.pointerType = i;
|
|
5114
5114
|
var f = this;
|
|
5115
5115
|
this._proxy = {};
|
|
5116
5116
|
var d = function(y) {
|
|
@@ -5118,7 +5118,7 @@ function Nc() {
|
|
|
5118
5118
|
return f[y];
|
|
5119
5119
|
} });
|
|
5120
5120
|
};
|
|
5121
|
-
for (var h in
|
|
5121
|
+
for (var h in Pi) d(h);
|
|
5122
5122
|
var v = function(y) {
|
|
5123
5123
|
Object.defineProperty(o._proxy, y, { value: function() {
|
|
5124
5124
|
return f[y].apply(f, arguments);
|
|
@@ -5138,8 +5138,8 @@ function Nc() {
|
|
|
5138
5138
|
this.simulation || this.modification && this.modification.endResult || this.updatePointer(t, o, i, !1);
|
|
5139
5139
|
var c, f, d = 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;
|
|
5140
5140
|
this.pointerIsDown && !this.pointerWasMoved && (c = this.coords.cur.client.x - this.coords.start.client.x, f = this.coords.cur.client.y - this.coords.start.client.y, this.pointerWasMoved = pt(c, f) > this.pointerMoveTolerance);
|
|
5141
|
-
var h, v, b, y = this.getPointerIndex(t),
|
|
5142
|
-
d || (h = this.coords.velocity, v = this.coords.delta, b = Math.max(v.timeStamp / 1e3, 1e-3), h.page.x = v.page.x / b, h.page.y = v.page.y / b, h.client.x = v.client.x / b, h.client.y = v.client.y / b, h.timeStamp = b), this._scopeFire("interactions:move",
|
|
5141
|
+
var h, v, b, y = this.getPointerIndex(t), O = { pointer: t, pointerIndex: y, pointerInfo: this.pointers[y], event: o, type: "move", eventTarget: i, dx: c, dy: f, duplicate: d, interaction: this };
|
|
5142
|
+
d || (h = this.coords.velocity, v = this.coords.delta, b = Math.max(v.timeStamp / 1e3, 1e-3), h.page.x = v.page.x / b, h.page.y = v.page.y / b, h.client.x = v.client.x / b, h.client.y = v.client.y / b, h.timeStamp = b), this._scopeFire("interactions:move", O), d || this.simulation || (this.interacting() && (O.type = null, this.move(O)), this.pointerWasMoved && $t(this.coords.prev, this.coords.cur));
|
|
5143
5143
|
} }, { key: "move", value: function(t) {
|
|
5144
5144
|
t && t.event || yr(this.coords.delta), (t = G({ pointer: this._latestPointer.pointer, event: this._latestPointer.event, eventTarget: this._latestPointer.eventTarget, interaction: this }, t || {})).phase = "move", this._doPhase(t);
|
|
5145
5145
|
} }, { key: "pointerUp", value: function(t, o, i, c) {
|
|
@@ -5167,8 +5167,8 @@ function Nc() {
|
|
|
5167
5167
|
return this.pointers[this.getPointerIndex(t)];
|
|
5168
5168
|
} }, { key: "updatePointer", value: function(t, o, i, c) {
|
|
5169
5169
|
var f, d, h, v = ht(t), b = this.getPointerIndex(t), y = this.pointers[b];
|
|
5170
|
-
return c = c !== !1 && (c || /(down|start)$/i.test(o.type)), y ? y.pointer = t : (y = new _i(v, t, o, null, null), b = this.pointers.length, this.pointers.push(y)), si(this.coords.cur, this.pointers.map(function(
|
|
5171
|
-
return
|
|
5170
|
+
return c = c !== !1 && (c || /(down|start)$/i.test(o.type)), y ? y.pointer = t : (y = new _i(v, t, o, null, null), b = this.pointers.length, this.pointers.push(y)), si(this.coords.cur, this.pointers.map(function(O) {
|
|
5171
|
+
return O.pointer;
|
|
5172
5172
|
}), this._now()), f = this.coords.delta, d = this.coords.prev, h = this.coords.cur, f.page.x = h.page.x - d.page.x, f.page.y = h.page.y - d.page.y, f.client.x = h.client.x - d.client.x, f.client.y = h.client.y - d.client.y, f.timeStamp = h.timeStamp - d.timeStamp, c && (this.pointerIsDown = !0, y.downTime = this.coords.cur.timeStamp, y.downTarget = i, It(this.downPointer, t), this.interacting() || ($t(this.coords.start, this.coords.cur), $t(this.coords.prev, this.coords.cur), this.downEvent = o, this.pointerWasMoved = !1)), this._updateLatestPointer(t, o, i), this._scopeFire("interactions:update-pointer", { pointer: t, event: o, eventTarget: i, down: c, pointerInfo: y, pointerIndex: b, interaction: this }), b;
|
|
5173
5173
|
} }, { key: "removePointer", value: function(t, o) {
|
|
5174
5174
|
var i = this.getPointerIndex(t);
|
|
@@ -5259,9 +5259,9 @@ function Nc() {
|
|
|
5259
5259
|
o.active && t();
|
|
5260
5260
|
});
|
|
5261
5261
|
} }, { key: "inertiaTick", value: function() {
|
|
5262
|
-
var t, o, i, c, f, d, h, v = this, b = this.interaction, y = Ft(b).resistance,
|
|
5263
|
-
if (
|
|
5264
|
-
var I, D = 1 - (Math.exp(-y *
|
|
5262
|
+
var t, o, i, c, f, d, h, v = this, b = this.interaction, y = Ft(b).resistance, O = (b._now() - this.t0) / 1e3;
|
|
5263
|
+
if (O < this.te) {
|
|
5264
|
+
var I, D = 1 - (Math.exp(-y * O) - this.lambda_v0) / this.one_ve_v0;
|
|
5265
5265
|
this.isModified ? (t = 0, o = 0, i = this.targetOffset.x, c = this.targetOffset.y, f = this.modifiedOffset.x, d = this.modifiedOffset.y, I = { x: Ur(h = D, t, i, f), y: Ur(h, o, c, d) }) : I = { x: this.targetOffset.x * D, y: this.targetOffset.y * D };
|
|
5266
5266
|
var z = { x: I.x - this.currentOffset.x, y: I.y - this.currentOffset.y };
|
|
5267
5267
|
this.currentOffset.x += z.x, this.currentOffset.y += z.y, b.offsetBy(z), b.move(), this.onNextFrame(function() {
|
|
@@ -5376,7 +5376,7 @@ function Nc() {
|
|
|
5376
5376
|
return n === t || (typeof n == "boolean" ? !!t.capture === n && !t.passive : !!n.capture == !!t.capture && !!n.passive == !!t.passive);
|
|
5377
5377
|
}
|
|
5378
5378
|
var Ri = { id: "events", install: function(n) {
|
|
5379
|
-
var t, o = [], i = {}, c = [], f = { add: d, remove: h, addDelegate: function(y,
|
|
5379
|
+
var t, o = [], i = {}, c = [], f = { add: d, remove: h, addDelegate: function(y, O, I, D, z) {
|
|
5380
5380
|
var Y = xt(z);
|
|
5381
5381
|
if (!i[I]) {
|
|
5382
5382
|
i[I] = [];
|
|
@@ -5386,19 +5386,19 @@ function Nc() {
|
|
|
5386
5386
|
}
|
|
5387
5387
|
}
|
|
5388
5388
|
var ce = i[I], ve = mt(ce, function(we) {
|
|
5389
|
-
return we.selector === y && we.context ===
|
|
5389
|
+
return we.selector === y && we.context === O;
|
|
5390
5390
|
});
|
|
5391
|
-
ve || (ve = { selector: y, context:
|
|
5392
|
-
}, removeDelegate: function(y,
|
|
5391
|
+
ve || (ve = { selector: y, context: O, listeners: [] }, ce.push(ve)), ve.listeners.push({ func: D, options: Y });
|
|
5392
|
+
}, removeDelegate: function(y, O, I, D, z) {
|
|
5393
5393
|
var Y, oe = xt(z), te = i[I], ce = !1;
|
|
5394
5394
|
if (te)
|
|
5395
5395
|
for (Y = te.length - 1; Y >= 0; Y--) {
|
|
5396
5396
|
var ve = te[Y];
|
|
5397
|
-
if (ve.selector === y && ve.context ===
|
|
5397
|
+
if (ve.selector === y && ve.context === O) {
|
|
5398
5398
|
for (var we = ve.listeners, fe = we.length - 1; fe >= 0; fe--) {
|
|
5399
5399
|
var ye = we[fe];
|
|
5400
5400
|
if (ye.func === D && Dt(ye.options, oe)) {
|
|
5401
|
-
we.splice(fe, 1), we.length || (te.splice(Y, 1), h(
|
|
5401
|
+
we.splice(fe, 1), we.length || (te.splice(Y, 1), h(O, I, v), h(O, I, b, !0)), ce = !0;
|
|
5402
5402
|
break;
|
|
5403
5403
|
}
|
|
5404
5404
|
}
|
|
@@ -5406,45 +5406,45 @@ function Nc() {
|
|
|
5406
5406
|
}
|
|
5407
5407
|
}
|
|
5408
5408
|
}, delegateListener: v, delegateUseCapture: b, delegatedEvents: i, documents: c, targets: o, supportsOptions: !1, supportsPassive: !1 };
|
|
5409
|
-
function d(y,
|
|
5409
|
+
function d(y, O, I, D) {
|
|
5410
5410
|
if (y.addEventListener) {
|
|
5411
5411
|
var z = xt(D), Y = mt(o, function(oe) {
|
|
5412
5412
|
return oe.eventTarget === y;
|
|
5413
5413
|
});
|
|
5414
|
-
Y || (Y = { eventTarget: y, events: {} }, o.push(Y)), Y.events[
|
|
5414
|
+
Y || (Y = { eventTarget: y, events: {} }, o.push(Y)), Y.events[O] || (Y.events[O] = []), mt(Y.events[O], function(oe) {
|
|
5415
5415
|
return oe.func === I && Dt(oe.options, z);
|
|
5416
|
-
}) || (y.addEventListener(
|
|
5416
|
+
}) || (y.addEventListener(O, I, f.supportsOptions ? z : z.capture), Y.events[O].push({ func: I, options: z }));
|
|
5417
5417
|
}
|
|
5418
5418
|
}
|
|
5419
|
-
function h(y,
|
|
5419
|
+
function h(y, O, I, D) {
|
|
5420
5420
|
if (y.addEventListener && y.removeEventListener) {
|
|
5421
5421
|
var z = gt(o, function($e) {
|
|
5422
5422
|
return $e.eventTarget === y;
|
|
5423
5423
|
}), Y = o[z];
|
|
5424
|
-
if (Y && Y.events) if (
|
|
5425
|
-
var oe = !1, te = Y.events[
|
|
5424
|
+
if (Y && Y.events) if (O !== "all") {
|
|
5425
|
+
var oe = !1, te = Y.events[O];
|
|
5426
5426
|
if (te) {
|
|
5427
5427
|
if (I === "all") {
|
|
5428
5428
|
for (var ce = te.length - 1; ce >= 0; ce--) {
|
|
5429
5429
|
var ve = te[ce];
|
|
5430
|
-
h(y,
|
|
5430
|
+
h(y, O, ve.func, ve.options);
|
|
5431
5431
|
}
|
|
5432
5432
|
return;
|
|
5433
5433
|
}
|
|
5434
5434
|
for (var we = xt(D), fe = 0; fe < te.length; fe++) {
|
|
5435
5435
|
var ye = te[fe];
|
|
5436
5436
|
if (ye.func === I && Dt(ye.options, we)) {
|
|
5437
|
-
y.removeEventListener(
|
|
5437
|
+
y.removeEventListener(O, I, f.supportsOptions ? we : we.capture), te.splice(fe, 1), te.length === 0 && (delete Y.events[O], oe = !0);
|
|
5438
5438
|
break;
|
|
5439
5439
|
}
|
|
5440
5440
|
}
|
|
5441
5441
|
}
|
|
5442
5442
|
oe && !Object.keys(Y.events).length && o.splice(z, 1);
|
|
5443
|
-
} else for (
|
|
5443
|
+
} else for (O in Y.events) Y.events.hasOwnProperty(O) && h(y, O, "all");
|
|
5444
5444
|
}
|
|
5445
5445
|
}
|
|
5446
|
-
function v(y,
|
|
5447
|
-
for (var I = xt(
|
|
5446
|
+
function v(y, O) {
|
|
5447
|
+
for (var I = xt(O), D = new Mi(y), z = i[y.type], Y = Nr(y)[0], oe = Y; E.element(oe); ) {
|
|
5448
5448
|
for (var te = 0; te < z.length; te++) {
|
|
5449
5449
|
var ce = z[te], ve = ce.selector, we = ce.context;
|
|
5450
5450
|
if (T(oe, ve) && ie(we, Y) && ie(we, oe)) {
|
|
@@ -5497,8 +5497,8 @@ function Nc() {
|
|
|
5497
5497
|
}
|
|
5498
5498
|
if (t) return t;
|
|
5499
5499
|
for (var b = 0, y = f.interactions.list; b < y.length; b++) {
|
|
5500
|
-
var
|
|
5501
|
-
if (!(
|
|
5500
|
+
var O = y[b];
|
|
5501
|
+
if (!(O.pointerType !== i || /down/i.test(c) && O.simulation)) return O;
|
|
5502
5502
|
}
|
|
5503
5503
|
return null;
|
|
5504
5504
|
}, hasPointer: function(n) {
|
|
@@ -5523,14 +5523,14 @@ function Nc() {
|
|
|
5523
5523
|
return o.id === t;
|
|
5524
5524
|
});
|
|
5525
5525
|
}
|
|
5526
|
-
var zi = _n,
|
|
5526
|
+
var zi = _n, Pn = ["pointerDown", "pointerMove", "pointerUp", "updatePointer", "removePointer", "windowBlur"];
|
|
5527
5527
|
function Jr(n, t) {
|
|
5528
5528
|
return function(o) {
|
|
5529
5529
|
var i = t.interactions.list, c = Er(o), f = Nr(o), d = f[0], h = f[1], v = [];
|
|
5530
5530
|
if (/^touch/.test(o.type)) {
|
|
5531
5531
|
t.prevTouchTime = t.now();
|
|
5532
5532
|
for (var b = 0, y = o.changedTouches; b < y.length; b++) {
|
|
5533
|
-
var
|
|
5533
|
+
var O = y[b], I = { pointer: O, pointerId: ht(O), pointerType: c, eventType: o.type, eventTarget: d, curEventTarget: h, scope: t }, D = Zr(I);
|
|
5534
5534
|
v.push([I.pointer, I.eventTarget, I.curEventTarget, D]);
|
|
5535
5535
|
}
|
|
5536
5536
|
} else {
|
|
@@ -5554,17 +5554,17 @@ function Nc() {
|
|
|
5554
5554
|
var t = n.pointerType, o = n.scope, i = { interaction: zi.search(n), searchDetails: n };
|
|
5555
5555
|
return o.fire("interactions:find", i), i.interaction || o.interactions.new({ pointerType: t });
|
|
5556
5556
|
}
|
|
5557
|
-
function
|
|
5557
|
+
function On(n, t) {
|
|
5558
5558
|
var o = n.doc, i = n.scope, c = n.options, f = i.interactions.docEvents, d = i.events, h = d[t];
|
|
5559
5559
|
for (var v in i.browser.isIOS && !c.events && (c.events = { passive: !1 }), d.delegatedEvents) h(o, v, d.delegateListener), h(o, v, d.delegateUseCapture, !0);
|
|
5560
5560
|
for (var b = c && c.events, y = 0; y < f.length; y++) {
|
|
5561
|
-
var
|
|
5562
|
-
h(o,
|
|
5561
|
+
var O = f[y];
|
|
5562
|
+
h(o, O.type, O.listener, b);
|
|
5563
5563
|
}
|
|
5564
5564
|
}
|
|
5565
5565
|
var Li = { id: "core/interactions", install: function(n) {
|
|
5566
|
-
for (var t = {}, o = 0; o <
|
|
5567
|
-
var i =
|
|
5566
|
+
for (var t = {}, o = 0; o < Pn.length; o++) {
|
|
5567
|
+
var i = Pn[o];
|
|
5568
5568
|
t[i] = Jr(i, n);
|
|
5569
5569
|
}
|
|
5570
5570
|
var c, f = re.pEventTypes;
|
|
@@ -5572,11 +5572,11 @@ function Nc() {
|
|
|
5572
5572
|
for (var h = 0, v = n.interactions.list; h < v.length; h++) {
|
|
5573
5573
|
var b = v[h];
|
|
5574
5574
|
if (b.pointerIsDown && b.pointerType === "touch" && !b._interacting) for (var y = function() {
|
|
5575
|
-
var D = I[
|
|
5575
|
+
var D = I[O];
|
|
5576
5576
|
n.documents.some(function(z) {
|
|
5577
5577
|
return ie(z.doc, D.downTarget);
|
|
5578
5578
|
}) || b.removePointer(D.pointer, D.event);
|
|
5579
|
-
},
|
|
5579
|
+
}, O = 0, I = b.pointers; O < I.length; O++) y();
|
|
5580
5580
|
}
|
|
5581
5581
|
}
|
|
5582
5582
|
(c = R.PointerEvent ? [{ type: f.down, listener: d }, { 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: d }, { 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) {
|
|
@@ -5603,15 +5603,15 @@ function Nc() {
|
|
|
5603
5603
|
return n.interactions.list.push(v), v;
|
|
5604
5604
|
}, listeners: t, docEvents: c, pointerMoveTolerance: 1 }, n.usePlugin(Fr);
|
|
5605
5605
|
}, listeners: { "scope:add-document": function(n) {
|
|
5606
|
-
return
|
|
5606
|
+
return On(n, "add");
|
|
5607
5607
|
}, "scope:remove-document": function(n) {
|
|
5608
|
-
return
|
|
5608
|
+
return On(n, "remove");
|
|
5609
5609
|
}, "interactable:unset": function(n, t) {
|
|
5610
5610
|
for (var o = n.interactable, i = t.interactions.list.length - 1; i >= 0; i--) {
|
|
5611
5611
|
var c = t.interactions.list[i];
|
|
5612
5612
|
c.interactable === o && (c.stop(), t.fire("interactions:destroy", { interaction: c }), c.destroy(), t.interactions.list.length > 2 && t.interactions.list.splice(i, 1));
|
|
5613
5613
|
}
|
|
5614
|
-
} }, onDocSignal:
|
|
5614
|
+
} }, onDocSignal: On, doOnInteractions: Jr, methodNames: Pn }, Fi = Li, Ze = function(n) {
|
|
5615
5615
|
return n[n.On = 0] = "On", n[n.Off = 1] = "Off", n;
|
|
5616
5616
|
}(Ze || {}), Di = function() {
|
|
5617
5617
|
function n(t, o, i, c) {
|
|
@@ -5742,7 +5742,7 @@ function Nc() {
|
|
|
5742
5742
|
return this;
|
|
5743
5743
|
}
|
|
5744
5744
|
if (E.object(f)) {
|
|
5745
|
-
for (var
|
|
5745
|
+
for (var O in f) this.on(O, f[O], d);
|
|
5746
5746
|
return this;
|
|
5747
5747
|
}
|
|
5748
5748
|
return zt(f, this.scope.actions) ? this.globalEvents[f] ? this.globalEvents[f].push(d) : this.globalEvents[f] = [d] : this.scope.events.add(this.scope.document, f, d, { options: h }), this;
|
|
@@ -5755,7 +5755,7 @@ function Nc() {
|
|
|
5755
5755
|
return this;
|
|
5756
5756
|
}
|
|
5757
5757
|
if (E.object(f)) {
|
|
5758
|
-
for (var
|
|
5758
|
+
for (var O in f) this.off(O, f[O], d);
|
|
5759
5759
|
return this;
|
|
5760
5760
|
}
|
|
5761
5761
|
var I;
|
|
@@ -5853,8 +5853,8 @@ function Nc() {
|
|
|
5853
5853
|
var c = i[0], f = i[1];
|
|
5854
5854
|
return c in n || f in n;
|
|
5855
5855
|
}), o = function(i, c) {
|
|
5856
|
-
for (var f = n.range, d = n.limits, h = d === void 0 ? { left: -1 / 0, right: 1 / 0, top: -1 / 0, bottom: 1 / 0 } : d, v = n.offset, b = v === void 0 ? { x: 0, y: 0 } : v, y = { range: f, grid: n, x: null, y: null },
|
|
5857
|
-
var I = t[
|
|
5856
|
+
for (var f = n.range, d = n.limits, h = d === void 0 ? { left: -1 / 0, right: 1 / 0, top: -1 / 0, bottom: 1 / 0 } : d, v = n.offset, b = v === void 0 ? { x: 0, y: 0 } : v, y = { range: f, grid: n, x: null, y: null }, O = 0; O < t.length; O++) {
|
|
5857
|
+
var I = t[O], D = I[0], z = I[1], Y = Math.round((i - b.x) / n[D]), oe = Math.round((c - b.y) / n[z]);
|
|
5858
5858
|
y[D] = Math.max(h.left, Math.min(h.right, Y * n[D] + b.x)), y[z] = Math.max(h.top, Math.min(h.bottom, oe * n[z] + b.y));
|
|
5859
5859
|
}
|
|
5860
5860
|
return y;
|
|
@@ -5866,12 +5866,12 @@ function Nc() {
|
|
|
5866
5866
|
} }, Ui = Xi, qi = { start: function(n) {
|
|
5867
5867
|
var t = n.state, o = n.rect, i = n.edges, c = n.pageCoords, f = t.options, d = f.ratio, h = f.enabled, v = t.options, b = v.equalDelta, y = v.modifiers;
|
|
5868
5868
|
d === "preserve" && (d = o.width / o.height), t.startCoords = G({}, c), t.startRect = G({}, o), t.ratio = d, t.equalDelta = b;
|
|
5869
|
-
var
|
|
5869
|
+
var O = t.linkedEdges = { top: i.top || i.left && !i.bottom, left: i.left || i.top && !i.right, bottom: i.bottom || i.right && !i.top, right: i.right || i.bottom && !i.left };
|
|
5870
5870
|
if (t.xIsPrimaryAxis = !(!i.left && !i.right), t.equalDelta) {
|
|
5871
|
-
var I = (
|
|
5871
|
+
var I = (O.left ? 1 : -1) * (O.top ? 1 : -1);
|
|
5872
5872
|
t.edgeSign = { x: I, y: I };
|
|
5873
|
-
} else t.edgeSign = { x:
|
|
5874
|
-
if (h !== !1 && G(i,
|
|
5873
|
+
} else t.edgeSign = { x: O.left ? -1 : 1, y: O.top ? -1 : 1 };
|
|
5874
|
+
if (h !== !1 && G(i, O), y != null && y.length) {
|
|
5875
5875
|
var D = new Nn(n.interaction);
|
|
5876
5876
|
D.copyFrom(n.interaction.modification), D.prepareStates(y), t.subModification = D, D.startAll(a({}, n));
|
|
5877
5877
|
}
|
|
@@ -5909,8 +5909,8 @@ function Nc() {
|
|
|
5909
5909
|
if (t && h) {
|
|
5910
5910
|
var b = it(d.restriction, c, f);
|
|
5911
5911
|
if (b) {
|
|
5912
|
-
var y = b.right - b.left - t.width,
|
|
5913
|
-
y < 0 && (v.left += y, v.right += y),
|
|
5912
|
+
var y = b.right - b.left - t.width, O = b.bottom - b.top - t.height;
|
|
5913
|
+
y < 0 && (v.left += y, v.right += y), O < 0 && (v.top += O, v.bottom += O);
|
|
5914
5914
|
}
|
|
5915
5915
|
v.left += o.left - t.width * h.left, v.top += o.top - t.height * h.top, v.right += o.right - t.width * (1 - h.right), v.bottom += o.bottom - t.height * (1 - h.bottom);
|
|
5916
5916
|
}
|
|
@@ -5961,20 +5961,20 @@ function Nc() {
|
|
|
5961
5961
|
var y = je(v.offset, i, c, [o]);
|
|
5962
5962
|
(t = ke(y) || { x: 0, y: 0 }).x += b.x, t.y += b.y;
|
|
5963
5963
|
}
|
|
5964
|
-
var
|
|
5965
|
-
d.offsets = f &&
|
|
5964
|
+
var O = v.relativePoints;
|
|
5965
|
+
d.offsets = f && O && O.length ? O.map(function(I, D) {
|
|
5966
5966
|
return { index: D, relativePoint: I, x: h.left - f.width * I.x + t.x, y: h.top - f.height * I.y + t.y };
|
|
5967
5967
|
}) : [{ index: 0, relativePoint: null, x: t.x, y: t.y }];
|
|
5968
5968
|
}, set: function(n) {
|
|
5969
5969
|
var t = n.interaction, o = n.coords, i = n.state, c = i.options, f = i.offsets, d = Be(t.interactable, t.element, t.prepared.name), h = G({}, o), v = [];
|
|
5970
5970
|
c.offsetWithOrigin || (h.x -= d.x, h.y -= d.y);
|
|
5971
|
-
for (var b = 0, y = f; b < y.length; b++) for (var
|
|
5971
|
+
for (var b = 0, y = f; b < y.length; b++) for (var O = y[b], I = h.x - O.x, D = h.y - O.y, z = 0, Y = c.targets.length; z < Y; z++) {
|
|
5972
5972
|
var oe = c.targets[z], te = void 0;
|
|
5973
|
-
(te = E.func(oe) ? oe(I, D, t._proxy,
|
|
5973
|
+
(te = E.func(oe) ? oe(I, D, t._proxy, O, z) : oe) && v.push({ x: (E.number(te.x) ? te.x : I) + O.x, y: (E.number(te.y) ? te.y : D) + O.y, range: E.number(te.range) ? te.range : c.range, source: oe, index: z, offset: O });
|
|
5974
5974
|
}
|
|
5975
5975
|
for (var ce = { target: null, inRange: !1, distance: 0, range: 0, delta: { x: 0, y: 0 } }, ve = 0; ve < v.length; ve++) {
|
|
5976
|
-
var we = v[ve], fe = we.range, ye = we.x - h.x, $e = we.y - h.y,
|
|
5977
|
-
fe === 1 / 0 && ce.inRange && ce.range !== 1 / 0 && (Le = !1), ce.target && !(Le ? ce.inRange && fe !== 1 / 0 ?
|
|
5976
|
+
var we = v[ve], fe = we.range, ye = we.x - h.x, $e = we.y - h.y, Oe = pt(ye, $e), Le = Oe <= fe;
|
|
5977
|
+
fe === 1 / 0 && ce.inRange && ce.range !== 1 / 0 && (Le = !1), ce.target && !(Le ? ce.inRange && fe !== 1 / 0 ? Oe / fe < ce.distance / ce.range : fe === 1 / 0 && ce.range !== 1 / 0 || Oe < ce.distance : !ce.inRange && Oe < ce.distance) || (ce.target = we, ce.distance = Oe, ce.range = fe, ce.inRange = Le, ce.delta.x = ye, ce.delta.y = $e);
|
|
5978
5978
|
}
|
|
5979
5979
|
return ce.inRange && (o.x = ce.target.x, o.y = ce.target.y), i.closest = ce, ce;
|
|
5980
5980
|
}, defaults: { range: 1 / 0, targets: null, offset: null, offsetWithOrigin: !0, origin: null, relativePoints: null, endOnly: !1, enabled: !1 } }, os = Je(kn, "snap"), Bt = { start: function(n) {
|
|
@@ -5987,8 +5987,8 @@ function Nc() {
|
|
|
5987
5987
|
for (var h = 0, v = c.targets || []; h < v.length; h++) {
|
|
5988
5988
|
var b = v[h], y = void 0;
|
|
5989
5989
|
if (y = E.func(b) ? b(d.x, d.y, t) : b) {
|
|
5990
|
-
for (var
|
|
5991
|
-
var D = I[
|
|
5990
|
+
for (var O = 0, I = o.targetFields; O < I.length; O++) {
|
|
5991
|
+
var D = I[O], z = D[0], Y = D[1];
|
|
5992
5992
|
if (z in y || Y in y) {
|
|
5993
5993
|
y.x = y[z], y.y = y[Y];
|
|
5994
5994
|
break;
|
|
@@ -6016,8 +6016,8 @@ function Nc() {
|
|
|
6016
6016
|
if (u(this, o), It(C(b = t.call(this, h)), f), f !== c && It(C(b), c), b.timeStamp = v, b.originalEvent = f, b.type = i, b.pointerId = ht(c), b.pointerType = Er(c), b.target = d, b.currentTarget = null, i === "tap") {
|
|
6017
6017
|
var y = h.getPointerIndex(c);
|
|
6018
6018
|
b.dt = b.timeStamp - h.pointers[y].downTime;
|
|
6019
|
-
var
|
|
6020
|
-
b.double = !!h.prevTap && h.prevTap.type !== "doubletap" && h.prevTap.target === b.target &&
|
|
6019
|
+
var O = b.timeStamp - h.tapTime;
|
|
6020
|
+
b.double = !!h.prevTap && h.prevTap.type !== "doubletap" && h.prevTap.target === b.target && O < 500;
|
|
6021
6021
|
} else i === "doubletap" && (b.dt = c.timeStamp - h.tapTime, b.double = !0);
|
|
6022
6022
|
return b;
|
|
6023
6023
|
}
|
|
@@ -6043,12 +6043,12 @@ function Nc() {
|
|
|
6043
6043
|
n.duplicate || o.pointerIsDown && !o.pointerWasMoved || (o.pointerIsDown && jn(n), Qe({ interaction: o, pointer: i, event: c, eventTarget: f, type: "move" }, t));
|
|
6044
6044
|
}, "interactions:down": function(n, t) {
|
|
6045
6045
|
(function(o, i) {
|
|
6046
|
-
for (var c = o.interaction, f = o.pointer, d = o.event, h = o.eventTarget, v = o.pointerIndex, b = c.pointers[v].hold, y = be(h),
|
|
6046
|
+
for (var c = o.interaction, f = o.pointer, d = o.event, h = o.eventTarget, v = o.pointerIndex, b = c.pointers[v].hold, y = be(h), O = { interaction: c, pointer: f, event: d, eventTarget: h, type: "hold", targets: [], path: y, node: null }, I = 0; I < y.length; I++) {
|
|
6047
6047
|
var D = y[I];
|
|
6048
|
-
|
|
6048
|
+
O.node = D, i.fire("pointerEvents:collect-targets", O);
|
|
6049
6049
|
}
|
|
6050
|
-
if (
|
|
6051
|
-
for (var z = 1 / 0, Y = 0, oe =
|
|
6050
|
+
if (O.targets.length) {
|
|
6051
|
+
for (var z = 1 / 0, Y = 0, oe = O.targets; Y < oe.length; Y++) {
|
|
6052
6052
|
var te = oe[Y].eventable.options.holdDuration;
|
|
6053
6053
|
te < z && (z = te);
|
|
6054
6054
|
}
|
|
@@ -6068,11 +6068,11 @@ function Nc() {
|
|
|
6068
6068
|
function Qe(n, t) {
|
|
6069
6069
|
var o = n.interaction, i = n.pointer, c = n.event, f = n.eventTarget, d = n.type, h = n.targets, v = h === void 0 ? so(n, t) : h, b = new io(d, i, c, f, o, t.now());
|
|
6070
6070
|
t.fire("pointerEvents:new", { pointerEvent: b });
|
|
6071
|
-
for (var y = { interaction: o, pointer: i, event: c, eventTarget: f, targets: v, type: d, pointerEvent: b },
|
|
6072
|
-
var I = v[
|
|
6071
|
+
for (var y = { interaction: o, pointer: i, event: c, eventTarget: f, targets: v, type: d, pointerEvent: b }, O = 0; O < v.length; O++) {
|
|
6072
|
+
var I = v[O];
|
|
6073
6073
|
for (var D in I.props || {}) b[D] = I.props[D];
|
|
6074
6074
|
var z = Be(I.eventable, I.node);
|
|
6075
|
-
if (b._subtractOrigin(z), b.eventable = I.eventable, b.currentTarget = I.node, I.eventable.fire(b), b._addOrigin(z), b.immediatePropagationStopped || b.propagationStopped &&
|
|
6075
|
+
if (b._subtractOrigin(z), b.eventable = I.eventable, b.currentTarget = I.node, I.eventable.fire(b), b._addOrigin(z), b.immediatePropagationStopped || b.propagationStopped && O + 1 < v.length && v[O + 1].node !== b.currentTarget) break;
|
|
6076
6076
|
}
|
|
6077
6077
|
if (t.fire("pointerEvents:fired", y), d === "tap") {
|
|
6078
6078
|
var Y = b.double ? Qe({ interaction: o, pointer: i, event: c, eventTarget: f, type: "doubletap" }, t) : b;
|
|
@@ -6083,8 +6083,8 @@ function Nc() {
|
|
|
6083
6083
|
function so(n, t) {
|
|
6084
6084
|
var o = n.interaction, i = n.pointer, c = n.event, f = n.eventTarget, d = n.type, h = o.getPointerIndex(i), v = o.pointers[h];
|
|
6085
6085
|
if (d === "tap" && (o.pointerWasMoved || !v || v.downTarget !== f)) return [];
|
|
6086
|
-
for (var b = be(f), y = { interaction: o, pointer: i, event: c, eventTarget: f, type: d, path: b, targets: [], node: null },
|
|
6087
|
-
var I = b[
|
|
6086
|
+
for (var b = be(f), y = { interaction: o, pointer: i, event: c, eventTarget: f, type: d, path: b, targets: [], node: null }, O = 0; O < b.length; O++) {
|
|
6087
|
+
var I = b[O];
|
|
6088
6088
|
y.node = I, t.fire("pointerEvents:collect-targets", y);
|
|
6089
6089
|
}
|
|
6090
6090
|
return d === "hold" && (y.targets = y.targets.filter(function(D) {
|
|
@@ -6149,10 +6149,10 @@ function Nc() {
|
|
|
6149
6149
|
n.actions.phases.reflow = !0, t.prototype.reflow = function(o) {
|
|
6150
6150
|
return function(i, c, f) {
|
|
6151
6151
|
for (var d = i.getAllElements(), h = f.window.Promise, v = h ? [] : null, b = function() {
|
|
6152
|
-
var
|
|
6152
|
+
var O = d[y], I = i.getRect(O);
|
|
6153
6153
|
if (!I) return 1;
|
|
6154
6154
|
var D, z = mt(f.interactions.list, function(te) {
|
|
6155
|
-
return te.interacting() && te.interactable === i && te.element ===
|
|
6155
|
+
return te.interacting() && te.interactable === i && te.element === O && te.prepared.name === c.name;
|
|
6156
6156
|
});
|
|
6157
6157
|
if (z) z.move(), v && (D = z._reflowPromise || new h(function(te) {
|
|
6158
6158
|
z._reflowResolve = te;
|
|
@@ -6189,11 +6189,11 @@ function Nc() {
|
|
|
6189
6189
|
D = function(te, ce, ve, we, fe) {
|
|
6190
6190
|
var ye = te.interactions.new({ pointerType: "reflow" }), $e = { interaction: ye, event: fe, pointer: fe, eventTarget: ve, phase: "reflow" };
|
|
6191
6191
|
ye.interactable = ce, ye.element = ve, ye.prevEvent = fe, ye.updatePointer(fe, fe, ve, !0), yr(ye.coords.delta), xn(ye.prepared, we), ye._doPhase($e);
|
|
6192
|
-
var
|
|
6192
|
+
var Oe = te.window, Le = Oe.Promise, He = Le ? new Le(function(qe) {
|
|
6193
6193
|
ye._reflowResolve = qe;
|
|
6194
6194
|
}) : void 0;
|
|
6195
6195
|
return ye._reflowPromise = He, ye.start(we, ce, ve), ye._interacting ? (ye.move($e), ye.end(fe)) : (ye.stop(), ye._reflowResolve()), ye.removePointer(fe, fe), He;
|
|
6196
|
-
}(f, i,
|
|
6196
|
+
}(f, i, O, c, oe);
|
|
6197
6197
|
}
|
|
6198
6198
|
v && v.push(D);
|
|
6199
6199
|
}, y = 0; y < d.length && !b(); y++) ;
|
|
@@ -6236,16 +6236,16 @@ function _c(e, {
|
|
|
6236
6236
|
const _ = Tc(N).draggable({
|
|
6237
6237
|
inertia: !0,
|
|
6238
6238
|
...u,
|
|
6239
|
-
onstart: ({ client:
|
|
6240
|
-
const C = Se.make(
|
|
6239
|
+
onstart: ({ client: P }) => {
|
|
6240
|
+
const C = Se.make(P);
|
|
6241
6241
|
p.current?.(C);
|
|
6242
6242
|
},
|
|
6243
|
-
onmove: ({ client:
|
|
6244
|
-
const j = Se.make(C, $), K = Se.make(
|
|
6243
|
+
onmove: ({ client: P, clientX0: C, clientY0: $, dx: M, dy: w }) => {
|
|
6244
|
+
const j = Se.make(C, $), K = Se.make(P), J = Se.make(M, w);
|
|
6245
6245
|
g.current?.(J, K, j);
|
|
6246
6246
|
},
|
|
6247
|
-
onend: ({ client:
|
|
6248
|
-
const M = Se.make(C, $), w = Se.make(
|
|
6247
|
+
onend: ({ client: P, clientX0: C, clientY0: $ }) => {
|
|
6248
|
+
const M = Se.make(C, $), w = Se.make(P);
|
|
6249
6249
|
m.current?.(w, M);
|
|
6250
6250
|
}
|
|
6251
6251
|
});
|
|
@@ -6262,17 +6262,17 @@ function Ct(e, {
|
|
|
6262
6262
|
onDragEnd: u,
|
|
6263
6263
|
...p
|
|
6264
6264
|
}) {
|
|
6265
|
-
const g = Ee(r), [m, N] = _e(!1), [_,
|
|
6265
|
+
const g = Ee(r), [m, N] = _e(!1), [_, P] = _e(!1), [C, $] = _e(r), M = Te(a), w = Te(l), j = Te(u), K = Te(s);
|
|
6266
6266
|
return _c(e, {
|
|
6267
6267
|
onDragStart: (S) => {
|
|
6268
|
-
N(!0),
|
|
6268
|
+
N(!0), P(!1), M.current?.(S);
|
|
6269
6269
|
},
|
|
6270
6270
|
onDragMove: (S, k, E) => {
|
|
6271
6271
|
const A = K.current(g.current, S.x, S.y);
|
|
6272
|
-
So(g, A) && $(A), N(!0),
|
|
6272
|
+
So(g, A) && $(A), N(!0), P(!1), w.current?.(S, k, E);
|
|
6273
6273
|
},
|
|
6274
6274
|
onDragEnd: (S, k) => {
|
|
6275
|
-
N(!1),
|
|
6275
|
+
N(!1), P(!0), j.current?.(S, k);
|
|
6276
6276
|
},
|
|
6277
6277
|
...p
|
|
6278
6278
|
}), Ne(() => {
|
|
@@ -6287,7 +6287,7 @@ function Ct(e, {
|
|
|
6287
6287
|
function So(e, r) {
|
|
6288
6288
|
return Ge(e.current, r) ? !1 : (e.current = r, !0);
|
|
6289
6289
|
}
|
|
6290
|
-
const ei = /* @__PURE__ */
|
|
6290
|
+
const ei = /* @__PURE__ */ Pe(({
|
|
6291
6291
|
angle: e = 0,
|
|
6292
6292
|
speed: r = 1,
|
|
6293
6293
|
src: s,
|
|
@@ -6299,7 +6299,7 @@ const ei = /* @__PURE__ */ Oe(({
|
|
|
6299
6299
|
onLoadImageStart: m,
|
|
6300
6300
|
onLoadImageComplete: N,
|
|
6301
6301
|
onLoadImageError: _,
|
|
6302
|
-
onImageSizeChange:
|
|
6302
|
+
onImageSizeChange: P,
|
|
6303
6303
|
...C
|
|
6304
6304
|
}, $) => {
|
|
6305
6305
|
const M = he((A, X, q) => A - X * r, [r]), w = Ee(null), j = nt(w), K = Lo({ src: s }, {
|
|
@@ -6314,7 +6314,7 @@ const ei = /* @__PURE__ */ Oe(({
|
|
|
6314
6314
|
});
|
|
6315
6315
|
Ne(() => {
|
|
6316
6316
|
if (B || !K) return;
|
|
6317
|
-
const A =
|
|
6317
|
+
const A = Oc(e, K, xe.size(j), a);
|
|
6318
6318
|
A !== S && k(A), e !== J && U(e);
|
|
6319
6319
|
}, [e, K, j.width, j.height, a]), Ne(() => {
|
|
6320
6320
|
if (!B || !K) return;
|
|
@@ -6323,9 +6323,9 @@ const ei = /* @__PURE__ */ Oe(({
|
|
|
6323
6323
|
}, [S, K, j.width, j.height, a]), Ne(() => {
|
|
6324
6324
|
l?.(J, B), u?.(J / 360, B);
|
|
6325
6325
|
}, [J]), Ne(() => {
|
|
6326
|
-
|
|
6326
|
+
P?.(K);
|
|
6327
6327
|
}, [K?.width, K?.height]);
|
|
6328
|
-
const E =
|
|
6328
|
+
const E = Pc({ src: s, displacement: S });
|
|
6329
6329
|
return /* @__PURE__ */ x.jsx(
|
|
6330
6330
|
"div",
|
|
6331
6331
|
{
|
|
@@ -6337,7 +6337,7 @@ const ei = /* @__PURE__ */ Oe(({
|
|
|
6337
6337
|
}
|
|
6338
6338
|
);
|
|
6339
6339
|
});
|
|
6340
|
-
function
|
|
6340
|
+
function Pc({ src: e = "", displacement: r = NaN }) {
|
|
6341
6341
|
return {
|
|
6342
6342
|
body: {
|
|
6343
6343
|
backgroundImage: `url(${e})`,
|
|
@@ -6356,7 +6356,7 @@ function ti(e, r) {
|
|
|
6356
6356
|
const p = l / a * s;
|
|
6357
6357
|
return Me.make(p, l);
|
|
6358
6358
|
}
|
|
6359
|
-
function
|
|
6359
|
+
function Oc(e, r, s, a) {
|
|
6360
6360
|
const { width: l } = ti(r, s), { width: u } = s, p = u * a;
|
|
6361
6361
|
return e / 360 * l - p;
|
|
6362
6362
|
}
|
|
@@ -6366,8 +6366,8 @@ function kc(e, r, s, a) {
|
|
|
6366
6366
|
for (; g < 0; ) g += 360;
|
|
6367
6367
|
return g;
|
|
6368
6368
|
}
|
|
6369
|
-
process.env.NODE_ENV
|
|
6370
|
-
const Cc = /* @__PURE__ */
|
|
6369
|
+
process.env.NODE_ENV === "development" && (ei.displayName = "Panorama");
|
|
6370
|
+
const Cc = /* @__PURE__ */ Pe(({
|
|
6371
6371
|
className: e,
|
|
6372
6372
|
style: r,
|
|
6373
6373
|
angle: s = 0,
|
|
@@ -6379,7 +6379,7 @@ const Cc = /* @__PURE__ */ Oe(({
|
|
|
6379
6379
|
viewportSize: m,
|
|
6380
6380
|
zeroAnchor: N = 0,
|
|
6381
6381
|
onAngleChange: _,
|
|
6382
|
-
onDragEnd:
|
|
6382
|
+
onDragEnd: P,
|
|
6383
6383
|
onDragStart: C,
|
|
6384
6384
|
onLoadImageComplete: $,
|
|
6385
6385
|
onLoadImageError: M,
|
|
@@ -6398,8 +6398,8 @@ const Cc = /* @__PURE__ */ Oe(({
|
|
|
6398
6398
|
}, [m?.width, m?.height, ne, S.width, u])(), V = he(() => S.width <= 0 ? N : ((S.width - F) * 0.5 + N * F) / S.width, [S.width, F, N])(), re = he(() => {
|
|
6399
6399
|
X(!0), C?.();
|
|
6400
6400
|
}, [C]), ie = he(() => {
|
|
6401
|
-
X(!1),
|
|
6402
|
-
}, [
|
|
6401
|
+
X(!1), P?.();
|
|
6402
|
+
}, [P]), ae = ze(l, {
|
|
6403
6403
|
track: Kt,
|
|
6404
6404
|
reticle: Zn,
|
|
6405
6405
|
indicator: Jn
|
|
@@ -6485,8 +6485,8 @@ function jc({ autoDimension: e = "width", panoramaRect: r = xe.zero, aspectRatio
|
|
|
6485
6485
|
}
|
|
6486
6486
|
};
|
|
6487
6487
|
}
|
|
6488
|
-
process.env.NODE_ENV
|
|
6489
|
-
const Ic = /* @__PURE__ */
|
|
6488
|
+
process.env.NODE_ENV === "development" && (Cc.displayName = "PanoramaSlider", Jn.displayName = "PanoramaSliderIndicator", Zn.displayName = "PanoramaSliderReticle", Kt.displayName = "PanoramaSliderTrack");
|
|
6489
|
+
const Ic = /* @__PURE__ */ Pe(({
|
|
6490
6490
|
children: e,
|
|
6491
6491
|
className: r,
|
|
6492
6492
|
decimalPlaces: s = 2,
|
|
@@ -6498,11 +6498,11 @@ const Ic = /* @__PURE__ */ Oe(({
|
|
|
6498
6498
|
min: m,
|
|
6499
6499
|
orientation: N = "vertical",
|
|
6500
6500
|
range: _,
|
|
6501
|
-
steps:
|
|
6501
|
+
steps: P = -1,
|
|
6502
6502
|
onChange: C,
|
|
6503
6503
|
...$
|
|
6504
6504
|
}, M) => {
|
|
6505
|
-
const w = Ee(null), j = nt(w), K = Ee(null), J = Ee(null), [U, B] = _e(_ ?? [m, g]), S = Fc(m, g,
|
|
6505
|
+
const w = Ee(null), j = nt(w), K = Ee(null), J = Ee(null), [U, B] = _e(_ ?? [m, g]), S = Fc(m, g, P), [k, E] = U.map((ee) => st(ee, m, g, N, j, p, l, a)), A = E - k, X = ze(e, {
|
|
6506
6506
|
gutter: Qn,
|
|
6507
6507
|
highlight: er,
|
|
6508
6508
|
knob: Zt,
|
|
@@ -6735,8 +6735,8 @@ function Fc(e, r, s) {
|
|
|
6735
6735
|
r
|
|
6736
6736
|
];
|
|
6737
6737
|
}
|
|
6738
|
-
process.env.NODE_ENV
|
|
6739
|
-
const Dc =
|
|
6738
|
+
process.env.NODE_ENV === "development" && (Ic.displayName = "RangeSlider", Qn.displayName = "RangeSliderGutter", Jt.displayName = "RangeSliderLabel", er.displayName = "RangeSliderHighlight", Zt.displayName = "RangeSliderKnob");
|
|
6739
|
+
const Dc = Pe(({
|
|
6740
6740
|
children: e,
|
|
6741
6741
|
id: r,
|
|
6742
6742
|
isRequired: s = !1,
|
|
@@ -6762,10 +6762,10 @@ const Dc = Oe(({
|
|
|
6762
6762
|
required: s,
|
|
6763
6763
|
style: zn.select,
|
|
6764
6764
|
value: p,
|
|
6765
|
-
onChange: (
|
|
6765
|
+
onChange: (P) => g?.(P.target.value),
|
|
6766
6766
|
children: [
|
|
6767
6767
|
u !== void 0 && /* @__PURE__ */ x.jsx(ge, { disabled: !0, hidden: !0, element: _.option ?? /* @__PURE__ */ x.jsx(Qt, {}), value: "", children: u }),
|
|
6768
|
-
l.map((
|
|
6768
|
+
l.map((P, C) => /* @__PURE__ */ x.jsx(ge, { element: _.option ?? /* @__PURE__ */ x.jsx(Qt, {}), value: P, children: P }, `${C}-${P}`))
|
|
6769
6769
|
]
|
|
6770
6770
|
}
|
|
6771
6771
|
),
|
|
@@ -6793,8 +6793,8 @@ const Dc = Oe(({
|
|
|
6793
6793
|
zIndex: 1
|
|
6794
6794
|
}
|
|
6795
6795
|
};
|
|
6796
|
-
process.env.NODE_ENV
|
|
6797
|
-
const Hc = /* @__PURE__ */
|
|
6796
|
+
process.env.NODE_ENV === "development" && (Dc.displayName = "Select", ni.displayName = "SelectExpandIcon", Qt.displayName = "SelectOption", tr.displayName = "SelectToggle");
|
|
6797
|
+
const Hc = /* @__PURE__ */ Pe(({
|
|
6798
6798
|
children: e,
|
|
6799
6799
|
className: r,
|
|
6800
6800
|
isDeselectable: s = !1,
|
|
@@ -6806,7 +6806,7 @@ const Hc = /* @__PURE__ */ Oe(({
|
|
|
6806
6806
|
onToggle: m,
|
|
6807
6807
|
...N
|
|
6808
6808
|
}, _) => {
|
|
6809
|
-
const
|
|
6809
|
+
const P = () => {
|
|
6810
6810
|
if (!a)
|
|
6811
6811
|
if (l) {
|
|
6812
6812
|
if (!s) return;
|
|
@@ -6824,13 +6824,13 @@ const Hc = /* @__PURE__ */ Oe(({
|
|
|
6824
6824
|
"aria-selected": l,
|
|
6825
6825
|
className: se(r, { active: l, disabled: a || l && !s }),
|
|
6826
6826
|
disabled: a || l && !s,
|
|
6827
|
-
onClick:
|
|
6827
|
+
onClick: P,
|
|
6828
6828
|
children: e ?? u
|
|
6829
6829
|
}
|
|
6830
6830
|
);
|
|
6831
6831
|
});
|
|
6832
|
-
process.env.NODE_ENV
|
|
6833
|
-
const Vc = /* @__PURE__ */
|
|
6832
|
+
process.env.NODE_ENV === "development" && (Hc.displayName = "SelectableButton");
|
|
6833
|
+
const Vc = /* @__PURE__ */ Pe(({
|
|
6834
6834
|
children: e,
|
|
6835
6835
|
className: r,
|
|
6836
6836
|
isClipped: s = !1,
|
|
@@ -6842,7 +6842,7 @@ const Vc = /* @__PURE__ */ Oe(({
|
|
|
6842
6842
|
onlyDispatchesOnDragEnd: m = !1,
|
|
6843
6843
|
orientation: N = "vertical",
|
|
6844
6844
|
position: _ = 0,
|
|
6845
|
-
trackPadding:
|
|
6845
|
+
trackPadding: P = 0,
|
|
6846
6846
|
labelProvider: C,
|
|
6847
6847
|
onDragEnd: $,
|
|
6848
6848
|
onDragStart: M,
|
|
@@ -6915,11 +6915,11 @@ const Vc = /* @__PURE__ */ Oe(({
|
|
|
6915
6915
|
className: se(a ? "end" : "start", F.track),
|
|
6916
6916
|
element: V.track ?? /* @__PURE__ */ x.jsx(en, {}),
|
|
6917
6917
|
style: le(R.track, N === "vertical" ? {
|
|
6918
|
-
height: `calc(${q * 100}% - ${
|
|
6918
|
+
height: `calc(${q * 100}% - ${P <= 0 ? 0 : u * 0.5}px - ${P}px)`,
|
|
6919
6919
|
top: "0"
|
|
6920
6920
|
} : {
|
|
6921
6921
|
left: "0",
|
|
6922
|
-
width: `calc(${q * 100}% - ${
|
|
6922
|
+
width: `calc(${q * 100}% - ${P <= 0 ? 0 : g * 0.5}px - ${P}px)`
|
|
6923
6923
|
}),
|
|
6924
6924
|
onClick: S,
|
|
6925
6925
|
children: /* @__PURE__ */ x.jsx("div", { style: R.trackHitBox })
|
|
@@ -6932,10 +6932,10 @@ const Vc = /* @__PURE__ */ Oe(({
|
|
|
6932
6932
|
element: V.track ?? /* @__PURE__ */ x.jsx(en, {}),
|
|
6933
6933
|
style: le(R.track, N === "vertical" ? {
|
|
6934
6934
|
bottom: "0",
|
|
6935
|
-
height: `calc(${(1 - q) * 100}% - ${
|
|
6935
|
+
height: `calc(${(1 - q) * 100}% - ${P <= 0 ? 0 : u * 0.5}px - ${P}px)`
|
|
6936
6936
|
} : {
|
|
6937
6937
|
right: "0",
|
|
6938
|
-
width: `calc(${(1 - q) * 100}% - ${
|
|
6938
|
+
width: `calc(${(1 - q) * 100}% - ${P <= 0 ? 0 : g * 0.5}px - ${P}px)`
|
|
6939
6939
|
}),
|
|
6940
6940
|
onClick: S,
|
|
6941
6941
|
children: /* @__PURE__ */ x.jsx("div", { style: R.trackHitBox })
|
|
@@ -7057,8 +7057,8 @@ function Yc({ orientation: e = "vertical", isClipped: r = !1, naturalPosition: s
|
|
|
7057
7057
|
}
|
|
7058
7058
|
};
|
|
7059
7059
|
}
|
|
7060
|
-
process.env.NODE_ENV
|
|
7061
|
-
const Xc = /* @__PURE__ */
|
|
7060
|
+
process.env.NODE_ENV === "development" && (Vc.displayName = "Slider", en.displayName = "SliderTrack", nr.displayName = "SliderKnob", rr.displayName = "SliderKnobContainer", or.displayName = "SliderLabel");
|
|
7061
|
+
const Xc = /* @__PURE__ */ Pe(({
|
|
7062
7062
|
children: e,
|
|
7063
7063
|
className: r,
|
|
7064
7064
|
index: s = 0,
|
|
@@ -7070,7 +7070,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7070
7070
|
knobWidth: m = 30,
|
|
7071
7071
|
labelProvider: N,
|
|
7072
7072
|
onlyDispatchesOnDragEnd: _ = !1,
|
|
7073
|
-
orientation:
|
|
7073
|
+
orientation: P = "vertical",
|
|
7074
7074
|
steps: C = Uc(10),
|
|
7075
7075
|
trackPadding: $ = 0,
|
|
7076
7076
|
onDragEnd: M,
|
|
@@ -7081,7 +7081,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7081
7081
|
}, U) => {
|
|
7082
7082
|
const B = Ee(null), S = Ee(null), k = nt(B), [E, A] = _e(s), X = he((H, ee, Z) => {
|
|
7083
7083
|
const Q = l ? et(H) : H;
|
|
7084
|
-
switch (
|
|
7084
|
+
switch (P) {
|
|
7085
7085
|
case "horizontal": {
|
|
7086
7086
|
const ue = a ? k.width - m : k.width, pe = Q * ue + ee, be = qt(pe / ue);
|
|
7087
7087
|
return l ? et(be) : be;
|
|
@@ -7091,9 +7091,9 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7091
7091
|
return l ? et(be) : be;
|
|
7092
7092
|
}
|
|
7093
7093
|
default:
|
|
7094
|
-
return console.error(`[etudes::StepSlider] Invalid orientation: ${
|
|
7094
|
+
return console.error(`[etudes::StepSlider] Invalid orientation: ${P}`), NaN;
|
|
7095
7095
|
}
|
|
7096
|
-
}, [k.width, k.height, a, l, m, p,
|
|
7096
|
+
}, [k.width, k.height, a, l, m, p, P]), { isDragging: q, isReleasing: ne, value: W, setValue: F } = Ct(S, {
|
|
7097
7097
|
initialValue: dt(s, C),
|
|
7098
7098
|
transform: X,
|
|
7099
7099
|
onDragStart: w,
|
|
@@ -7101,9 +7101,9 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7101
7101
|
}), R = he((H) => {
|
|
7102
7102
|
if (!u) return;
|
|
7103
7103
|
const ee = xe.fromViewport();
|
|
7104
|
-
switch (
|
|
7104
|
+
switch (P) {
|
|
7105
7105
|
case "horizontal": {
|
|
7106
|
-
const Z = (H.clientX + ee.left - k.left) / k.width, Q = l ? et(Z) : Z, ue =
|
|
7106
|
+
const Z = (H.clientX + ee.left - k.left) / k.width, Q = l ? et(Z) : Z, ue = Pt(Q, C);
|
|
7107
7107
|
if (ue === E) {
|
|
7108
7108
|
const pe = Q > W ? ue + 1 : ue - 1;
|
|
7109
7109
|
A(qt(pe, C.length - 1));
|
|
@@ -7112,7 +7112,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7112
7112
|
break;
|
|
7113
7113
|
}
|
|
7114
7114
|
case "vertical": {
|
|
7115
|
-
const Z = (H.clientY + ee.top - k.top) / k.height, Q = l ? et(Z) : Z, ue =
|
|
7115
|
+
const Z = (H.clientY + ee.top - k.top) / k.height, Q = l ? et(Z) : Z, ue = Pt(Q, C);
|
|
7116
7116
|
if (ue === E) {
|
|
7117
7117
|
const pe = Q > W ? ue + 1 : ue - 1, be = dt(pe, C);
|
|
7118
7118
|
F(be), A(qt(pe, C.length - 1));
|
|
@@ -7123,9 +7123,9 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7123
7123
|
break;
|
|
7124
7124
|
}
|
|
7125
7125
|
default:
|
|
7126
|
-
console.error(`[etudes::StepSlider] Invalid orientation: ${
|
|
7126
|
+
console.error(`[etudes::StepSlider] Invalid orientation: ${P}`);
|
|
7127
7127
|
}
|
|
7128
|
-
}, [k.width, k.left, k.top, k.height, E, W, l, u,
|
|
7128
|
+
}, [k.width, k.left, k.top, k.height, E, W, l, u, P, We(C)]), V = l ? et(W) : W, ae = qc({ orientation: P, isAtEnd: l ? W === 0 : W === 1, isAtStart: l ? W === 1 : W === 0, isDragging: q, isReleasing: ne }), L = Gc({ orientation: P, naturalPosition: V, isClipped: a, knobPadding: g, knobHeight: p, knobWidth: m, isTrackInteractive: u }), T = ze(e, {
|
|
7129
7129
|
knob: ir,
|
|
7130
7130
|
knobContainer: sr,
|
|
7131
7131
|
label: ar,
|
|
@@ -7136,9 +7136,9 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7136
7136
|
}, [s, q, We(C)]), Ne(() => {
|
|
7137
7137
|
if (q) {
|
|
7138
7138
|
if (_) return;
|
|
7139
|
-
A(
|
|
7139
|
+
A(Pt(W, C));
|
|
7140
7140
|
} else {
|
|
7141
|
-
const H =
|
|
7141
|
+
const H = Pt(W, C), ee = dt(H, C);
|
|
7142
7142
|
F(ee), A(H);
|
|
7143
7143
|
}
|
|
7144
7144
|
}, [W, q, _, We(C)]), Ne(() => {
|
|
@@ -7159,7 +7159,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7159
7159
|
{
|
|
7160
7160
|
className: se(l ? "end" : "start", ae.track),
|
|
7161
7161
|
element: T.track ?? /* @__PURE__ */ x.jsx(tn, {}),
|
|
7162
|
-
style: le(L.track,
|
|
7162
|
+
style: le(L.track, P === "vertical" ? {
|
|
7163
7163
|
height: `calc(${V * 100}% - ${$ <= 0 ? 0 : p * 0.5}px - ${$}px)`,
|
|
7164
7164
|
top: "0"
|
|
7165
7165
|
} : {
|
|
@@ -7175,7 +7175,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7175
7175
|
{
|
|
7176
7176
|
className: se(l ? "start" : "end", ae.track),
|
|
7177
7177
|
element: T.track ?? /* @__PURE__ */ x.jsx(tn, {}),
|
|
7178
|
-
style: le(L.track,
|
|
7178
|
+
style: le(L.track, P === "vertical" ? {
|
|
7179
7179
|
bottom: "0",
|
|
7180
7180
|
height: `calc(${et(V) * 100}% - ${$ <= 0 ? 0 : p * 0.5}px - ${$}px)`
|
|
7181
7181
|
} : {
|
|
@@ -7195,7 +7195,7 @@ const Xc = /* @__PURE__ */ Oe(({
|
|
|
7195
7195
|
style: le(L.knobContainer),
|
|
7196
7196
|
children: /* @__PURE__ */ x.jsxs(ge, { className: se(ae.knob), element: T.knob ?? /* @__PURE__ */ x.jsx(ir, {}), style: le(L.knob), children: [
|
|
7197
7197
|
/* @__PURE__ */ x.jsx("div", { style: L.knobHitBox }),
|
|
7198
|
-
C && N && /* @__PURE__ */ x.jsx(ge, { className: se(ae.label), element: T.label ?? /* @__PURE__ */ x.jsx(ar, {}), style: le(L.label), children: N(W,
|
|
7198
|
+
C && N && /* @__PURE__ */ x.jsx(ge, { className: se(ae.label), element: T.label ?? /* @__PURE__ */ x.jsx(ar, {}), style: le(L.label), children: N(W, Pt(W, C)) })
|
|
7199
7199
|
] })
|
|
7200
7200
|
}
|
|
7201
7201
|
)
|
|
@@ -7211,7 +7211,7 @@ function Uc(e) {
|
|
|
7211
7211
|
const r = 1 / (e - 1);
|
|
7212
7212
|
return Array(e).fill(null).map((s, a) => r * a);
|
|
7213
7213
|
}
|
|
7214
|
-
function
|
|
7214
|
+
function Pt(e, r) {
|
|
7215
7215
|
let s = -1, a = NaN;
|
|
7216
7216
|
for (let l = 0, u = r.length; l < u; l++) {
|
|
7217
7217
|
const p = dt(l, r);
|
|
@@ -7329,8 +7329,8 @@ function et(e) {
|
|
|
7329
7329
|
function qt(e, r = 1, s = 0) {
|
|
7330
7330
|
return Math.max(s, Math.min(r, e));
|
|
7331
7331
|
}
|
|
7332
|
-
process.env.NODE_ENV
|
|
7333
|
-
const Wc = /* @__PURE__ */
|
|
7332
|
+
process.env.NODE_ENV === "development" && (Xc.displayName = "StepSlider", tn.displayName = "StepSliderTrack", ir.displayName = "StepSliderKnob", sr.displayName = "StepSliderKnobContainer", ar.displayName = "StepSliderLabel");
|
|
7333
|
+
const Wc = /* @__PURE__ */ Pe(({
|
|
7334
7334
|
children: e,
|
|
7335
7335
|
isEnabled: r = !0,
|
|
7336
7336
|
threshold: s = 0.5,
|
|
@@ -7340,7 +7340,7 @@ const Wc = /* @__PURE__ */ Oe(({
|
|
|
7340
7340
|
onSwipeUp: p,
|
|
7341
7341
|
...g
|
|
7342
7342
|
}, m) => {
|
|
7343
|
-
const [N, _] = _e(void 0), [
|
|
7343
|
+
const [N, _] = _e(void 0), [P, C] = _e(void 0), [$, M] = _e(NaN), w = (U, B) => {
|
|
7344
7344
|
if (isNaN(U) || isNaN(B)) return J();
|
|
7345
7345
|
_(Se.make(U, B));
|
|
7346
7346
|
}, j = (U, B) => {
|
|
@@ -7349,7 +7349,7 @@ const Wc = /* @__PURE__ */ Oe(({
|
|
|
7349
7349
|
const k = S.x !== U || S.y !== B, E = !isNaN($);
|
|
7350
7350
|
k && (E || M(Date.now()), C(Se.make(U, B)));
|
|
7351
7351
|
}, K = () => {
|
|
7352
|
-
const U = $, B = N, S =
|
|
7352
|
+
const U = $, B = N, S = P;
|
|
7353
7353
|
if (isNaN(U) || B === void 0 || S === void 0) return;
|
|
7354
7354
|
const k = Date.now() - U, E = S.x - B.x, A = S.y - B.y, X = E / k, q = A / k;
|
|
7355
7355
|
r && (Math.abs(X) >= s && Math.abs(X) > Math.abs(q) ? X > 0 ? u?.() : l?.() : Math.abs(q) >= s && Math.abs(q) > Math.abs(X) && (q > 0 ? a?.() : p?.())), J();
|
|
@@ -7372,8 +7372,8 @@ const Wc = /* @__PURE__ */ Oe(({
|
|
|
7372
7372
|
}
|
|
7373
7373
|
);
|
|
7374
7374
|
});
|
|
7375
|
-
process.env.NODE_ENV
|
|
7376
|
-
const Kc =
|
|
7375
|
+
process.env.NODE_ENV === "development" && (Wc.displayName = "SwipeRegion");
|
|
7376
|
+
const Kc = Pe(({
|
|
7377
7377
|
onChange: e,
|
|
7378
7378
|
...r
|
|
7379
7379
|
}, s) => /* @__PURE__ */ x.jsx(
|
|
@@ -7384,8 +7384,8 @@ const Kc = Oe(({
|
|
|
7384
7384
|
onChange: (a) => e(a.target.value)
|
|
7385
7385
|
}
|
|
7386
7386
|
));
|
|
7387
|
-
process.env.NODE_ENV
|
|
7388
|
-
const Jc =
|
|
7387
|
+
process.env.NODE_ENV === "development" && (Kc.displayName = "TextArea");
|
|
7388
|
+
const Jc = Pe(({
|
|
7389
7389
|
className: e,
|
|
7390
7390
|
children: r,
|
|
7391
7391
|
isInverted: s = !1,
|
|
@@ -7395,13 +7395,13 @@ const Jc = Oe(({
|
|
|
7395
7395
|
onChange: p,
|
|
7396
7396
|
...g
|
|
7397
7397
|
}, m) => {
|
|
7398
|
-
const N = Ee(null), _ = jo(N),
|
|
7398
|
+
const N = Ee(null), _ = jo(N), P = ze(r, {
|
|
7399
7399
|
knob: lr,
|
|
7400
7400
|
track: cr
|
|
7401
7401
|
}), C = Zc({ isOn: a }), $ = Qc({ isOn: a, isInverted: s, orientation: l, knobSize: _ });
|
|
7402
7402
|
return /* @__PURE__ */ x.jsxs("label", { ...g, ref: m, className: se(e, C.root), style: le(u, $.root), children: [
|
|
7403
7403
|
/* @__PURE__ */ x.jsx("input", { checked: a, style: $.input, type: "checkbox", onChange: (M) => p?.(M.target.checked) }),
|
|
7404
|
-
/* @__PURE__ */ x.jsx(ge, { className: C.track, element:
|
|
7404
|
+
/* @__PURE__ */ x.jsx(ge, { className: C.track, element: P.track ?? /* @__PURE__ */ x.jsx(cr, {}), style: $.track, children: /* @__PURE__ */ x.jsx("div", { style: { position: "relative", width: "100%", height: "100%" }, children: /* @__PURE__ */ x.jsx(ge, { ref: N, className: C.knob, element: P.knob ?? /* @__PURE__ */ x.jsx(lr, {}), style: $.knob }) }) })
|
|
7405
7405
|
] });
|
|
7406
7406
|
}), cr = ({ children: e, ...r }) => /* @__PURE__ */ x.jsx("div", { ...r, children: e }), lr = ({ children: e, ...r }) => /* @__PURE__ */ x.jsx("div", { ...r, children: e });
|
|
7407
7407
|
function Zc({ isOn: e = !1 }) {
|
|
@@ -7471,15 +7471,15 @@ function Qc({ isOn: e = !1, isInverted: r = !1, knobSize: s = Me.zero, orientati
|
|
|
7471
7471
|
}
|
|
7472
7472
|
};
|
|
7473
7473
|
}
|
|
7474
|
-
process.env.NODE_ENV
|
|
7475
|
-
const ri = /* @__PURE__ */
|
|
7474
|
+
process.env.NODE_ENV === "development" && (Jc.displayName = "Toggle", lr.displayName = "ToggleKnob", cr.displayName = "ToggleTrack");
|
|
7475
|
+
const ri = /* @__PURE__ */ Pe(({
|
|
7476
7476
|
children: e,
|
|
7477
7477
|
...r
|
|
7478
7478
|
}, s) => (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.`), an.map(e, (a, l) => {
|
|
7479
7479
|
if (!(l > 0))
|
|
7480
7480
|
return cn(a) ? pr(a, { ...r, ref: s }) : a;
|
|
7481
7481
|
})));
|
|
7482
|
-
process.env.NODE_ENV
|
|
7482
|
+
process.env.NODE_ENV === "development" && (ri.displayName = "ExtractChild");
|
|
7483
7483
|
function el({
|
|
7484
7484
|
children: e,
|
|
7485
7485
|
className: r,
|
|
@@ -7492,7 +7492,7 @@ function el({
|
|
|
7492
7492
|
maxWidth: m = 200,
|
|
7493
7493
|
threshold: N = 100
|
|
7494
7494
|
}) {
|
|
7495
|
-
const _ = Ee(null),
|
|
7495
|
+
const _ = Ee(null), P = Ee(void 0), C = nt(_), $ = he(() => {
|
|
7496
7496
|
const j = document.createElement("span");
|
|
7497
7497
|
j.className = se(r), j.innerHTML = g, j.role = "tooltip";
|
|
7498
7498
|
const K = a ?? (_.current ? nl(_.current, N) : "tl"), J = tl(j), U = il({ alignment: K, arrowSize: Me.make(u, l), gap: p, maxDialogWidth: m, fullDialogWidth: J.width, targetWidth: C.width }), B = le(s, U.dialog);
|
|
@@ -7500,14 +7500,14 @@ function el({
|
|
|
7500
7500
|
const S = document.createElement("span");
|
|
7501
7501
|
return Object.keys(U.arrow).forEach((k) => S.style[k] = U.arrow[k]), j.appendChild(S), j;
|
|
7502
7502
|
}, [r, a, g, m, We(s), C.width, N, l, u, p]), M = he(() => {
|
|
7503
|
-
|
|
7503
|
+
P.current && (P.current.style.opacity = "1", P.current.ariaHidden = "false");
|
|
7504
7504
|
}, []), w = he(() => {
|
|
7505
|
-
|
|
7505
|
+
P.current && (P.current.style.opacity = "0", P.current.ariaHidden = "true");
|
|
7506
7506
|
}, []);
|
|
7507
7507
|
return Ne(() => {
|
|
7508
7508
|
const j = $();
|
|
7509
|
-
return _.current?.appendChild(j),
|
|
7510
|
-
_.current?.removeChild(j),
|
|
7509
|
+
return _.current?.appendChild(j), P.current = j, () => {
|
|
7510
|
+
_.current?.removeChild(j), P.current = void 0;
|
|
7511
7511
|
};
|
|
7512
7512
|
}, [$]), /* @__PURE__ */ x.jsx(
|
|
7513
7513
|
ri,
|
|
@@ -7698,7 +7698,7 @@ function il({ alignment: e, arrowSize: r, fullDialogWidth: s, gap: a, maxDialogW
|
|
|
7698
7698
|
}
|
|
7699
7699
|
};
|
|
7700
7700
|
}
|
|
7701
|
-
process.env.NODE_ENV
|
|
7701
|
+
process.env.NODE_ENV === "development" && (el.displayName = "WithTooltip");
|
|
7702
7702
|
function hl(e, r) {
|
|
7703
7703
|
const s = Te(r);
|
|
7704
7704
|
De(() => {
|
|
@@ -7806,14 +7806,14 @@ function al({ children: e, if: r }) {
|
|
|
7806
7806
|
return r ? /* @__PURE__ */ x.jsx(x.Fragment, { children: e }) : /* @__PURE__ */ x.jsx(x.Fragment, {});
|
|
7807
7807
|
}
|
|
7808
7808
|
}
|
|
7809
|
-
process.env.NODE_ENV
|
|
7809
|
+
process.env.NODE_ENV === "development" && (al.displayName = "Conditional");
|
|
7810
7810
|
function cl({
|
|
7811
7811
|
children: e,
|
|
7812
7812
|
...r
|
|
7813
7813
|
}) {
|
|
7814
7814
|
return /* @__PURE__ */ x.jsx(x.Fragment, { children: an.map(e, (s) => cn(s) ? pr(s, { ...r }) : s) });
|
|
7815
7815
|
}
|
|
7816
|
-
process.env.NODE_ENV
|
|
7816
|
+
process.env.NODE_ENV === "development" && (cl.displayName = "ExtractChildren");
|
|
7817
7817
|
function bl({
|
|
7818
7818
|
children: e,
|
|
7819
7819
|
condition: r
|
|
@@ -7854,11 +7854,12 @@ var ur;
|
|
|
7854
7854
|
})(ur || (ur = {}));
|
|
7855
7855
|
function wl({ children: e }) {
|
|
7856
7856
|
const r = () => {
|
|
7857
|
-
|
|
7857
|
+
if (typeof window > "u") return "light";
|
|
7858
|
+
const l = window.localStorage.getItem("color-scheme");
|
|
7858
7859
|
return l || (window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light");
|
|
7859
7860
|
}, [s, a] = _e(r());
|
|
7860
7861
|
return Ne(() => {
|
|
7861
|
-
localStorage.setItem("color-scheme", s), document.documentElement.classList.toggle("dark", s === "dark");
|
|
7862
|
+
typeof window > "u" || (window.localStorage.setItem("color-scheme", s), document.documentElement.classList.toggle("dark", s === "dark"));
|
|
7862
7863
|
}, [s]), /* @__PURE__ */ x.jsx(jt.Provider, { value: { colorScheme: s, setColorScheme: a }, children: e });
|
|
7863
7864
|
}
|
|
7864
7865
|
const jt = ws(void 0);
|
|
@@ -7878,9 +7879,9 @@ function Sl() {
|
|
|
7878
7879
|
}, []) : (console.error("useToggleColorScheme must be used within a ColorSchemeProvider"), () => {
|
|
7879
7880
|
});
|
|
7880
7881
|
}
|
|
7881
|
-
process.env.NODE_ENV
|
|
7882
|
-
function
|
|
7883
|
-
return e == null ? "" : Array.isArray(e) ? JSON.stringify(e.map(
|
|
7882
|
+
process.env.NODE_ENV === "development" && (jt.displayName = "ColorSchemeContext");
|
|
7883
|
+
function Po(e) {
|
|
7884
|
+
return e == null ? "" : Array.isArray(e) ? JSON.stringify(e.map(Po)) : typeof e == "object" ? JSON.stringify(Object.entries(e).sort(([r], [s]) => r.localeCompare(s)).map(([r, s]) => [r, Po(s)])) : We(e);
|
|
7884
7885
|
}
|
|
7885
7886
|
export {
|
|
7886
7887
|
js as Accordion,
|
|
@@ -7972,7 +7973,7 @@ export {
|
|
|
7972
7973
|
dl as asStyleDict,
|
|
7973
7974
|
pr as cloneStyledElement,
|
|
7974
7975
|
We as createKey,
|
|
7975
|
-
|
|
7976
|
+
Po as createKeyDeep,
|
|
7976
7977
|
Uc as generateSteps,
|
|
7977
7978
|
Xs as isTouchDevice,
|
|
7978
7979
|
le as styles,
|