@ukpc-lib/react 0.1.7 → 0.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/GlobalMenu/components/MenuItem.d.ts +4 -1
- package/dist/components/GlobalMenu/index.d.ts +4 -4
- package/dist/components/index.cjs +4 -4
- package/dist/components/index.js +937 -936
- package/dist/{index-60dc34b2.js → interceptor.const-3d8c3adc.js} +11 -1
- package/dist/{index-e55ba232.cjs → interceptor.const-abe41a95.cjs} +2 -2
- package/dist/share/index.cjs +23 -23
- package/dist/share/index.js +108 -113
- package/package.json +1 -1
- package/web-components-bundle/global-menu/index.cjs +8 -8
- package/web-components-bundle/global-menu/index.js +1031 -1027
- /package/dist/{index.css → interceptor.css} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as
|
|
1
|
+
import { r as x, R as Ia, g as Wa, e as ws, a as Ua, j as R, p as I, S as za, L as Ha, s as $a } from "../index-6ba7e1d4.js";
|
|
2
2
|
/**
|
|
3
3
|
* @remix-run/router v1.14.2
|
|
4
4
|
*
|
|
@@ -100,34 +100,34 @@ function Xa(e, t, n, r) {
|
|
|
100
100
|
let {
|
|
101
101
|
window: i = document.defaultView,
|
|
102
102
|
v5Compat: o = !1
|
|
103
|
-
} = r, s = i.history, a = De.Pop, l = null,
|
|
104
|
-
|
|
105
|
-
idx:
|
|
103
|
+
} = r, s = i.history, a = De.Pop, l = null, c = f();
|
|
104
|
+
c == null && (c = 0, s.replaceState(dt({}, s.state, {
|
|
105
|
+
idx: c
|
|
106
106
|
}), ""));
|
|
107
107
|
function f() {
|
|
108
108
|
return (s.state || {
|
|
109
109
|
idx: null
|
|
110
110
|
}).idx;
|
|
111
111
|
}
|
|
112
|
-
function
|
|
112
|
+
function u() {
|
|
113
113
|
a = De.Pop;
|
|
114
|
-
let g = f(),
|
|
115
|
-
|
|
114
|
+
let g = f(), v = g == null ? null : g - c;
|
|
115
|
+
c = g, l && l({
|
|
116
116
|
action: a,
|
|
117
117
|
location: m.location,
|
|
118
|
-
delta:
|
|
118
|
+
delta: v
|
|
119
119
|
});
|
|
120
120
|
}
|
|
121
|
-
function h(g,
|
|
121
|
+
function h(g, v) {
|
|
122
122
|
a = De.Push;
|
|
123
|
-
let
|
|
124
|
-
n && n(
|
|
125
|
-
let y = Ir(
|
|
123
|
+
let w = Bn(m.location, g, v);
|
|
124
|
+
n && n(w, g), c = f() + 1;
|
|
125
|
+
let y = Ir(w, c), S = m.createHref(w);
|
|
126
126
|
try {
|
|
127
127
|
s.pushState(y, "", S);
|
|
128
|
-
} catch (
|
|
129
|
-
if (
|
|
130
|
-
throw
|
|
128
|
+
} catch (E) {
|
|
129
|
+
if (E instanceof DOMException && E.name === "DataCloneError")
|
|
130
|
+
throw E;
|
|
131
131
|
i.location.assign(S);
|
|
132
132
|
}
|
|
133
133
|
o && l && l({
|
|
@@ -136,11 +136,11 @@ function Xa(e, t, n, r) {
|
|
|
136
136
|
delta: 1
|
|
137
137
|
});
|
|
138
138
|
}
|
|
139
|
-
function d(g,
|
|
139
|
+
function d(g, v) {
|
|
140
140
|
a = De.Replace;
|
|
141
|
-
let
|
|
142
|
-
n && n(
|
|
143
|
-
let y = Ir(
|
|
141
|
+
let w = Bn(m.location, g, v);
|
|
142
|
+
n && n(w, g), c = f();
|
|
143
|
+
let y = Ir(w, c), S = m.createHref(w);
|
|
144
144
|
s.replaceState(y, "", S), o && l && l({
|
|
145
145
|
action: a,
|
|
146
146
|
location: m.location,
|
|
@@ -148,8 +148,8 @@ function Xa(e, t, n, r) {
|
|
|
148
148
|
});
|
|
149
149
|
}
|
|
150
150
|
function p(g) {
|
|
151
|
-
let
|
|
152
|
-
return ne(
|
|
151
|
+
let v = i.location.origin !== "null" ? i.location.origin : i.location.href, w = typeof g == "string" ? g : Nt(g);
|
|
152
|
+
return ne(v, "No window.location.(origin|href) available to create URL for href: " + w), new URL(w, v);
|
|
153
153
|
}
|
|
154
154
|
let m = {
|
|
155
155
|
get action() {
|
|
@@ -161,8 +161,8 @@ function Xa(e, t, n, r) {
|
|
|
161
161
|
listen(g) {
|
|
162
162
|
if (l)
|
|
163
163
|
throw new Error("A history only accepts one active listener");
|
|
164
|
-
return i.addEventListener(Br,
|
|
165
|
-
i.removeEventListener(Br,
|
|
164
|
+
return i.addEventListener(Br, u), l = g, () => {
|
|
165
|
+
i.removeEventListener(Br, u), l = null;
|
|
166
166
|
};
|
|
167
167
|
},
|
|
168
168
|
createHref(g) {
|
|
@@ -170,11 +170,11 @@ function Xa(e, t, n, r) {
|
|
|
170
170
|
},
|
|
171
171
|
createURL: p,
|
|
172
172
|
encodeLocation(g) {
|
|
173
|
-
let
|
|
173
|
+
let v = p(g);
|
|
174
174
|
return {
|
|
175
|
-
pathname:
|
|
176
|
-
search:
|
|
177
|
-
hash:
|
|
175
|
+
pathname: v.pathname,
|
|
176
|
+
search: v.search,
|
|
177
|
+
hash: v.hash
|
|
178
178
|
};
|
|
179
179
|
},
|
|
180
180
|
push: h,
|
|
@@ -234,21 +234,21 @@ function Ts(e, t, n, r) {
|
|
|
234
234
|
if (s == null)
|
|
235
235
|
a = n;
|
|
236
236
|
else {
|
|
237
|
-
let
|
|
237
|
+
let u = t.length - 1;
|
|
238
238
|
if (!r && s.startsWith("..")) {
|
|
239
239
|
let h = s.split("/");
|
|
240
240
|
for (; h[0] === ".."; )
|
|
241
|
-
h.shift(),
|
|
241
|
+
h.shift(), u -= 1;
|
|
242
242
|
i.pathname = h.join("/");
|
|
243
243
|
}
|
|
244
|
-
a =
|
|
244
|
+
a = u >= 0 ? t[u] : "/";
|
|
245
245
|
}
|
|
246
|
-
let l = Ka(i, a),
|
|
247
|
-
return !l.pathname.endsWith("/") && (
|
|
246
|
+
let l = Ka(i, a), c = s && s !== "/" && s.endsWith("/"), f = (o || s === ".") && n.endsWith("/");
|
|
247
|
+
return !l.pathname.endsWith("/") && (c || f) && (l.pathname += "/"), l;
|
|
248
248
|
}
|
|
249
|
-
const
|
|
250
|
-
new Set(
|
|
251
|
-
const el = ["get", ...
|
|
249
|
+
const Ps = (e) => e.join("/").replace(/\/\/+/g, "/"), Za = (e) => !e || e === "?" ? "" : e.startsWith("?") ? e : "?" + e, Qa = (e) => !e || e === "#" ? "" : e.startsWith("#") ? e : "#" + e, As = ["post", "put", "patch", "delete"];
|
|
250
|
+
new Set(As);
|
|
251
|
+
const el = ["get", ...As];
|
|
252
252
|
new Set(el);
|
|
253
253
|
/**
|
|
254
254
|
* React Router v6.21.3
|
|
@@ -270,7 +270,7 @@ function Bt() {
|
|
|
270
270
|
return e;
|
|
271
271
|
}, Bt.apply(this, arguments);
|
|
272
272
|
}
|
|
273
|
-
const Cs = /* @__PURE__ */
|
|
273
|
+
const Cs = /* @__PURE__ */ x.createContext(null), Qe = /* @__PURE__ */ x.createContext(null), ar = /* @__PURE__ */ x.createContext(null), en = /* @__PURE__ */ x.createContext({
|
|
274
274
|
outlet: null,
|
|
275
275
|
matches: [],
|
|
276
276
|
isDataRoute: !1
|
|
@@ -283,56 +283,56 @@ function tl(e, t) {
|
|
|
283
283
|
let {
|
|
284
284
|
basename: r,
|
|
285
285
|
navigator: i
|
|
286
|
-
} =
|
|
286
|
+
} = x.useContext(Qe), {
|
|
287
287
|
hash: o,
|
|
288
288
|
pathname: s,
|
|
289
289
|
search: a
|
|
290
290
|
} = Os(e, {
|
|
291
291
|
relative: n
|
|
292
292
|
}), l = s;
|
|
293
|
-
return r !== "/" && (l = s === "/" ? r :
|
|
293
|
+
return r !== "/" && (l = s === "/" ? r : Ps([r, s])), i.createHref({
|
|
294
294
|
pathname: l,
|
|
295
295
|
search: a,
|
|
296
296
|
hash: o
|
|
297
297
|
});
|
|
298
298
|
}
|
|
299
299
|
function tn() {
|
|
300
|
-
return
|
|
300
|
+
return x.useContext(ar) != null;
|
|
301
301
|
}
|
|
302
302
|
function nn() {
|
|
303
|
-
return tn() || ne(!1),
|
|
303
|
+
return tn() || ne(!1), x.useContext(ar).location;
|
|
304
304
|
}
|
|
305
305
|
function Rs(e) {
|
|
306
|
-
|
|
306
|
+
x.useContext(Qe).static || x.useLayoutEffect(e);
|
|
307
307
|
}
|
|
308
308
|
function nl() {
|
|
309
309
|
let {
|
|
310
310
|
isDataRoute: e
|
|
311
|
-
} =
|
|
311
|
+
} = x.useContext(en);
|
|
312
312
|
return e ? al() : rl();
|
|
313
313
|
}
|
|
314
314
|
function rl() {
|
|
315
315
|
tn() || ne(!1);
|
|
316
|
-
let e =
|
|
316
|
+
let e = x.useContext(Cs), {
|
|
317
317
|
basename: t,
|
|
318
318
|
future: n,
|
|
319
319
|
navigator: r
|
|
320
|
-
} =
|
|
320
|
+
} = x.useContext(Qe), {
|
|
321
321
|
matches: i
|
|
322
|
-
} =
|
|
322
|
+
} = x.useContext(en), {
|
|
323
323
|
pathname: o
|
|
324
|
-
} = nn(), s = JSON.stringify(Es(i, n.v7_relativeSplatPath)), a =
|
|
324
|
+
} = nn(), s = JSON.stringify(Es(i, n.v7_relativeSplatPath)), a = x.useRef(!1);
|
|
325
325
|
return Rs(() => {
|
|
326
326
|
a.current = !0;
|
|
327
|
-
}),
|
|
327
|
+
}), x.useCallback(function(c, f) {
|
|
328
328
|
if (f === void 0 && (f = {}), !a.current)
|
|
329
329
|
return;
|
|
330
|
-
if (typeof
|
|
331
|
-
r.go(
|
|
330
|
+
if (typeof c == "number") {
|
|
331
|
+
r.go(c);
|
|
332
332
|
return;
|
|
333
333
|
}
|
|
334
|
-
let
|
|
335
|
-
e == null && t !== "/" && (
|
|
334
|
+
let u = Ts(c, JSON.parse(s), o, f.relative === "path");
|
|
335
|
+
e == null && t !== "/" && (u.pathname = u.pathname === "/" ? t : Ps([t, u.pathname])), (f.replace ? r.replace : r.push)(u, f.state, f);
|
|
336
336
|
}, [t, r, s, o, e]);
|
|
337
337
|
}
|
|
338
338
|
function Os(e, t) {
|
|
@@ -340,12 +340,12 @@ function Os(e, t) {
|
|
|
340
340
|
relative: n
|
|
341
341
|
} = t === void 0 ? {} : t, {
|
|
342
342
|
future: r
|
|
343
|
-
} =
|
|
343
|
+
} = x.useContext(Qe), {
|
|
344
344
|
matches: i
|
|
345
|
-
} =
|
|
345
|
+
} = x.useContext(en), {
|
|
346
346
|
pathname: o
|
|
347
347
|
} = nn(), s = JSON.stringify(Es(i, r.v7_relativeSplatPath));
|
|
348
|
-
return
|
|
348
|
+
return x.useMemo(() => Ts(e, JSON.parse(s), o, n === "path"), [e, s, o, n]);
|
|
349
349
|
}
|
|
350
350
|
var Vs = /* @__PURE__ */ function(e) {
|
|
351
351
|
return e.UseBlocker = "useBlocker", e.UseRevalidator = "useRevalidator", e.UseNavigateStable = "useNavigate", e;
|
|
@@ -353,11 +353,11 @@ var Vs = /* @__PURE__ */ function(e) {
|
|
|
353
353
|
return e.UseBlocker = "useBlocker", e.UseLoaderData = "useLoaderData", e.UseActionData = "useActionData", e.UseRouteError = "useRouteError", e.UseNavigation = "useNavigation", e.UseRouteLoaderData = "useRouteLoaderData", e.UseMatches = "useMatches", e.UseRevalidator = "useRevalidator", e.UseNavigateStable = "useNavigate", e.UseRouteId = "useRouteId", e;
|
|
354
354
|
}(ks || {});
|
|
355
355
|
function il(e) {
|
|
356
|
-
let t =
|
|
356
|
+
let t = x.useContext(Cs);
|
|
357
357
|
return t || ne(!1), t;
|
|
358
358
|
}
|
|
359
359
|
function sl(e) {
|
|
360
|
-
let t =
|
|
360
|
+
let t = x.useContext(en);
|
|
361
361
|
return t || ne(!1), t;
|
|
362
362
|
}
|
|
363
363
|
function ol(e) {
|
|
@@ -367,10 +367,10 @@ function ol(e) {
|
|
|
367
367
|
function al() {
|
|
368
368
|
let {
|
|
369
369
|
router: e
|
|
370
|
-
} = il(Vs.UseNavigateStable), t = ol(ks.UseNavigateStable), n =
|
|
370
|
+
} = il(Vs.UseNavigateStable), t = ol(ks.UseNavigateStable), n = x.useRef(!1);
|
|
371
371
|
return Rs(() => {
|
|
372
372
|
n.current = !0;
|
|
373
|
-
}),
|
|
373
|
+
}), x.useCallback(function(i, o) {
|
|
374
374
|
o === void 0 && (o = {}), n.current && (typeof i == "number" ? e.navigate(i) : e.navigate(i, Bt({
|
|
375
375
|
fromRouteId: t
|
|
376
376
|
}, o)));
|
|
@@ -387,7 +387,7 @@ function ll(e) {
|
|
|
387
387
|
future: a
|
|
388
388
|
} = e;
|
|
389
389
|
tn() && ne(!1);
|
|
390
|
-
let l = t.replace(/^\/*/, "/"),
|
|
390
|
+
let l = t.replace(/^\/*/, "/"), c = x.useMemo(() => ({
|
|
391
391
|
basename: l,
|
|
392
392
|
navigator: o,
|
|
393
393
|
static: s,
|
|
@@ -398,26 +398,26 @@ function ll(e) {
|
|
|
398
398
|
typeof r == "string" && (r = Qt(r));
|
|
399
399
|
let {
|
|
400
400
|
pathname: f = "/",
|
|
401
|
-
search:
|
|
401
|
+
search: u = "",
|
|
402
402
|
hash: h = "",
|
|
403
403
|
state: d = null,
|
|
404
404
|
key: p = "default"
|
|
405
|
-
} = r, m =
|
|
405
|
+
} = r, m = x.useMemo(() => {
|
|
406
406
|
let g = Ss(f, l);
|
|
407
407
|
return g == null ? null : {
|
|
408
408
|
location: {
|
|
409
409
|
pathname: g,
|
|
410
|
-
search:
|
|
410
|
+
search: u,
|
|
411
411
|
hash: h,
|
|
412
412
|
state: d,
|
|
413
413
|
key: p
|
|
414
414
|
},
|
|
415
415
|
navigationType: i
|
|
416
416
|
};
|
|
417
|
-
}, [l, f,
|
|
418
|
-
return m == null ? null : /* @__PURE__ */
|
|
419
|
-
value:
|
|
420
|
-
}, /* @__PURE__ */
|
|
417
|
+
}, [l, f, u, h, d, p, i]);
|
|
418
|
+
return m == null ? null : /* @__PURE__ */ x.createElement(Qe.Provider, {
|
|
419
|
+
value: c
|
|
420
|
+
}, /* @__PURE__ */ x.createElement(ar.Provider, {
|
|
421
421
|
children: n,
|
|
422
422
|
value: m
|
|
423
423
|
}));
|
|
@@ -467,20 +467,20 @@ function pl(e) {
|
|
|
467
467
|
children: n,
|
|
468
468
|
future: r,
|
|
469
469
|
window: i
|
|
470
|
-
} = e, o =
|
|
470
|
+
} = e, o = x.useRef();
|
|
471
471
|
o.current == null && (o.current = qa({
|
|
472
472
|
window: i,
|
|
473
473
|
v5Compat: !0
|
|
474
474
|
}));
|
|
475
|
-
let s = o.current, [a, l] =
|
|
475
|
+
let s = o.current, [a, l] = x.useState({
|
|
476
476
|
action: s.action,
|
|
477
477
|
location: s.location
|
|
478
478
|
}), {
|
|
479
|
-
v7_startTransition:
|
|
480
|
-
} = r || {}, f =
|
|
481
|
-
|
|
482
|
-
}, [l,
|
|
483
|
-
return
|
|
479
|
+
v7_startTransition: c
|
|
480
|
+
} = r || {}, f = x.useCallback((u) => {
|
|
481
|
+
c && Ur ? Ur(() => l(u)) : l(u);
|
|
482
|
+
}, [l, c]);
|
|
483
|
+
return x.useLayoutEffect(() => s.listen(f), [s, f]), /* @__PURE__ */ x.createElement(ll, {
|
|
484
484
|
basename: t,
|
|
485
485
|
children: n,
|
|
486
486
|
location: a.location,
|
|
@@ -489,7 +489,7 @@ function pl(e) {
|
|
|
489
489
|
future: r
|
|
490
490
|
});
|
|
491
491
|
}
|
|
492
|
-
const ml = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u", gl = /^(?:[a-z][a-z0-9+.-]*:|\/\/)/i, yl = /* @__PURE__ */
|
|
492
|
+
const ml = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u", gl = /^(?:[a-z][a-z0-9+.-]*:|\/\/)/i, yl = /* @__PURE__ */ x.forwardRef(function(t, n) {
|
|
493
493
|
let {
|
|
494
494
|
onClick: r,
|
|
495
495
|
relative: i,
|
|
@@ -497,36 +497,36 @@ const ml = typeof window < "u" && typeof window.document < "u" && typeof window.
|
|
|
497
497
|
replace: s,
|
|
498
498
|
state: a,
|
|
499
499
|
target: l,
|
|
500
|
-
to:
|
|
500
|
+
to: c,
|
|
501
501
|
preventScrollReset: f,
|
|
502
|
-
unstable_viewTransition:
|
|
502
|
+
unstable_viewTransition: u
|
|
503
503
|
} = t, h = cl(t, hl), {
|
|
504
504
|
basename: d
|
|
505
|
-
} =
|
|
506
|
-
if (typeof
|
|
505
|
+
} = x.useContext(Qe), p, m = !1;
|
|
506
|
+
if (typeof c == "string" && gl.test(c) && (p = c, ml))
|
|
507
507
|
try {
|
|
508
|
-
let y = new URL(window.location.href), S =
|
|
509
|
-
S.origin === y.origin &&
|
|
508
|
+
let y = new URL(window.location.href), S = c.startsWith("//") ? new URL(y.protocol + c) : new URL(c), E = Ss(S.pathname, d);
|
|
509
|
+
S.origin === y.origin && E != null ? c = E + S.search + S.hash : m = !0;
|
|
510
510
|
} catch {
|
|
511
511
|
}
|
|
512
|
-
let g = tl(
|
|
512
|
+
let g = tl(c, {
|
|
513
513
|
relative: i
|
|
514
|
-
}),
|
|
514
|
+
}), v = vl(c, {
|
|
515
515
|
replace: s,
|
|
516
516
|
state: a,
|
|
517
517
|
target: l,
|
|
518
518
|
preventScrollReset: f,
|
|
519
519
|
relative: i,
|
|
520
|
-
unstable_viewTransition:
|
|
520
|
+
unstable_viewTransition: u
|
|
521
521
|
});
|
|
522
|
-
function
|
|
523
|
-
r && r(y), y.defaultPrevented ||
|
|
522
|
+
function w(y) {
|
|
523
|
+
r && r(y), y.defaultPrevented || v(y);
|
|
524
524
|
}
|
|
525
525
|
return (
|
|
526
526
|
// eslint-disable-next-line jsx-a11y/anchor-has-content
|
|
527
|
-
/* @__PURE__ */
|
|
527
|
+
/* @__PURE__ */ x.createElement("a", In({}, h, {
|
|
528
528
|
href: p || g,
|
|
529
|
-
onClick: m || o ? r :
|
|
529
|
+
onClick: m || o ? r : w,
|
|
530
530
|
ref: n,
|
|
531
531
|
target: l
|
|
532
532
|
}))
|
|
@@ -548,13 +548,13 @@ function vl(e, t) {
|
|
|
548
548
|
preventScrollReset: o,
|
|
549
549
|
relative: s,
|
|
550
550
|
unstable_viewTransition: a
|
|
551
|
-
} = t === void 0 ? {} : t, l = nl(),
|
|
551
|
+
} = t === void 0 ? {} : t, l = nl(), c = nn(), f = Os(e, {
|
|
552
552
|
relative: s
|
|
553
553
|
});
|
|
554
|
-
return
|
|
555
|
-
if (fl(
|
|
556
|
-
|
|
557
|
-
let h = r !== void 0 ? r : Nt(
|
|
554
|
+
return x.useCallback((u) => {
|
|
555
|
+
if (fl(u, n)) {
|
|
556
|
+
u.preventDefault();
|
|
557
|
+
let h = r !== void 0 ? r : Nt(c) === Nt(f);
|
|
558
558
|
l(e, {
|
|
559
559
|
replace: h,
|
|
560
560
|
state: i,
|
|
@@ -563,7 +563,7 @@ function vl(e, t) {
|
|
|
563
563
|
unstable_viewTransition: a
|
|
564
564
|
});
|
|
565
565
|
}
|
|
566
|
-
}, [
|
|
566
|
+
}, [c, l, f, r, i, n, e, o, s, a]);
|
|
567
567
|
}
|
|
568
568
|
var bl = typeof global == "object" && global && global.Object === Object && global;
|
|
569
569
|
const xl = bl;
|
|
@@ -571,15 +571,15 @@ var wl = typeof self == "object" && self && self.Object === Object && self, Sl =
|
|
|
571
571
|
const Ms = Sl;
|
|
572
572
|
var El = Ms.Symbol;
|
|
573
573
|
const It = El;
|
|
574
|
-
var Ls = Object.prototype, Tl = Ls.hasOwnProperty,
|
|
575
|
-
function
|
|
574
|
+
var Ls = Object.prototype, Tl = Ls.hasOwnProperty, Pl = Ls.toString, nt = It ? It.toStringTag : void 0;
|
|
575
|
+
function Al(e) {
|
|
576
576
|
var t = Tl.call(e, nt), n = e[nt];
|
|
577
577
|
try {
|
|
578
578
|
e[nt] = void 0;
|
|
579
579
|
var r = !0;
|
|
580
580
|
} catch {
|
|
581
581
|
}
|
|
582
|
-
var i =
|
|
582
|
+
var i = Pl.call(e);
|
|
583
583
|
return r && (t ? e[nt] = n : delete e[nt]), i;
|
|
584
584
|
}
|
|
585
585
|
var Cl = Object.prototype, Rl = Cl.toString;
|
|
@@ -588,7 +588,7 @@ function Ol(e) {
|
|
|
588
588
|
}
|
|
589
589
|
var Vl = "[object Null]", kl = "[object Undefined]", $r = It ? It.toStringTag : void 0;
|
|
590
590
|
function Ml(e) {
|
|
591
|
-
return e == null ? e === void 0 ? kl : Vl : $r && $r in Object(e) ?
|
|
591
|
+
return e == null ? e === void 0 ? kl : Vl : $r && $r in Object(e) ? Al(e) : Ol(e);
|
|
592
592
|
}
|
|
593
593
|
function Ll(e) {
|
|
594
594
|
return e != null && typeof e == "object";
|
|
@@ -633,51 +633,51 @@ var Hl = function() {
|
|
|
633
633
|
const bn = Hl;
|
|
634
634
|
var $l = "Expected a function", ql = Math.max, Gl = Math.min;
|
|
635
635
|
function Mt(e, t, n) {
|
|
636
|
-
var r, i, o, s, a, l,
|
|
636
|
+
var r, i, o, s, a, l, c = 0, f = !1, u = !1, h = !0;
|
|
637
637
|
if (typeof e != "function")
|
|
638
638
|
throw new TypeError($l);
|
|
639
|
-
t = Gr(t) || 0, Wt(n) && (f = !!n.leading,
|
|
640
|
-
function d(
|
|
641
|
-
var
|
|
642
|
-
return r = i = void 0,
|
|
639
|
+
t = Gr(t) || 0, Wt(n) && (f = !!n.leading, u = "maxWait" in n, o = u ? ql(Gr(n.maxWait) || 0, t) : o, h = "trailing" in n ? !!n.trailing : h);
|
|
640
|
+
function d(T) {
|
|
641
|
+
var P = r, A = i;
|
|
642
|
+
return r = i = void 0, c = T, s = e.apply(A, P), s;
|
|
643
643
|
}
|
|
644
|
-
function p(
|
|
645
|
-
return
|
|
644
|
+
function p(T) {
|
|
645
|
+
return c = T, a = setTimeout(v, t), f ? d(T) : s;
|
|
646
646
|
}
|
|
647
|
-
function m(
|
|
648
|
-
var
|
|
649
|
-
return
|
|
647
|
+
function m(T) {
|
|
648
|
+
var P = T - l, A = T - c, O = t - P;
|
|
649
|
+
return u ? Gl(O, o - A) : O;
|
|
650
650
|
}
|
|
651
|
-
function g(
|
|
652
|
-
var
|
|
653
|
-
return l === void 0 ||
|
|
651
|
+
function g(T) {
|
|
652
|
+
var P = T - l, A = T - c;
|
|
653
|
+
return l === void 0 || P >= t || P < 0 || u && A >= o;
|
|
654
654
|
}
|
|
655
|
-
function
|
|
656
|
-
var
|
|
657
|
-
if (g(
|
|
658
|
-
return
|
|
659
|
-
a = setTimeout(
|
|
655
|
+
function v() {
|
|
656
|
+
var T = bn();
|
|
657
|
+
if (g(T))
|
|
658
|
+
return w(T);
|
|
659
|
+
a = setTimeout(v, m(T));
|
|
660
660
|
}
|
|
661
|
-
function
|
|
662
|
-
return a = void 0, h && r ? d(
|
|
661
|
+
function w(T) {
|
|
662
|
+
return a = void 0, h && r ? d(T) : (r = i = void 0, s);
|
|
663
663
|
}
|
|
664
664
|
function y() {
|
|
665
|
-
a !== void 0 && clearTimeout(a),
|
|
665
|
+
a !== void 0 && clearTimeout(a), c = 0, r = l = i = a = void 0;
|
|
666
666
|
}
|
|
667
667
|
function S() {
|
|
668
|
-
return a === void 0 ? s :
|
|
668
|
+
return a === void 0 ? s : w(bn());
|
|
669
669
|
}
|
|
670
|
-
function
|
|
671
|
-
var
|
|
672
|
-
if (r = arguments, i = this, l =
|
|
670
|
+
function E() {
|
|
671
|
+
var T = bn(), P = g(T);
|
|
672
|
+
if (r = arguments, i = this, l = T, P) {
|
|
673
673
|
if (a === void 0)
|
|
674
674
|
return p(l);
|
|
675
|
-
if (
|
|
676
|
-
return clearTimeout(a), a = setTimeout(
|
|
675
|
+
if (u)
|
|
676
|
+
return clearTimeout(a), a = setTimeout(v, t), d(l);
|
|
677
677
|
}
|
|
678
|
-
return a === void 0 && (a = setTimeout(
|
|
678
|
+
return a === void 0 && (a = setTimeout(v, t)), s;
|
|
679
679
|
}
|
|
680
|
-
return
|
|
680
|
+
return E.cancel = y, E.flush = S, E;
|
|
681
681
|
}
|
|
682
682
|
var Xl = "Expected a function";
|
|
683
683
|
function Kl(e, t, n) {
|
|
@@ -767,7 +767,7 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
767
767
|
addClasses: Ns,
|
|
768
768
|
removeClasses: Bs,
|
|
769
769
|
classNamesToQuery: Is
|
|
770
|
-
}), ye = js, xn = _s, Ql = Fs, ve = Ns, be = Bs,
|
|
770
|
+
}), ye = js, xn = _s, Ql = Fs, ve = Ns, be = Bs, G = Is, Pt = (
|
|
771
771
|
/** @class */
|
|
772
772
|
function() {
|
|
773
773
|
function e(t, n) {
|
|
@@ -802,14 +802,14 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
802
802
|
r.axis.x.track.rect = r.axis.x.track.el.getBoundingClientRect(), r.axis.y.track.rect = r.axis.y.track.el.getBoundingClientRect(), (r.axis.x.isOverflowing || r.axis.x.forceVisible) && (o = r.isWithinBounds(r.axis.x.track.rect)), (r.axis.y.isOverflowing || r.axis.y.forceVisible) && (s = r.isWithinBounds(r.axis.y.track.rect)), (o || s) && (i.stopPropagation(), i.type === "pointerdown" && i.pointerType !== "touch" && (o && (r.axis.x.scrollbar.rect = r.axis.x.scrollbar.el.getBoundingClientRect(), r.isWithinBounds(r.axis.x.scrollbar.rect) ? r.onDragStart(i, "x") : r.onTrackClick(i, "x")), s && (r.axis.y.scrollbar.rect = r.axis.y.scrollbar.el.getBoundingClientRect(), r.isWithinBounds(r.axis.y.scrollbar.rect) ? r.onDragStart(i, "y") : r.onTrackClick(i, "y"))));
|
|
803
803
|
}
|
|
804
804
|
}, this.drag = function(i) {
|
|
805
|
-
var o, s, a, l,
|
|
805
|
+
var o, s, a, l, c, f, u, h, d, p, m;
|
|
806
806
|
if (!(!r.draggedAxis || !r.contentWrapperEl)) {
|
|
807
|
-
var g,
|
|
807
|
+
var g, v = r.axis[r.draggedAxis].track, w = (s = (o = v.rect) === null || o === void 0 ? void 0 : o[r.axis[r.draggedAxis].sizeAttr]) !== null && s !== void 0 ? s : 0, y = r.axis[r.draggedAxis].scrollbar, S = (l = (a = r.contentWrapperEl) === null || a === void 0 ? void 0 : a[r.axis[r.draggedAxis].scrollSizeAttr]) !== null && l !== void 0 ? l : 0, E = parseInt((f = (c = r.elStyles) === null || c === void 0 ? void 0 : c[r.axis[r.draggedAxis].sizeAttr]) !== null && f !== void 0 ? f : "0px", 10);
|
|
808
808
|
i.preventDefault(), i.stopPropagation(), r.draggedAxis === "y" ? g = i.pageY : g = i.pageX;
|
|
809
|
-
var
|
|
810
|
-
|
|
811
|
-
var
|
|
812
|
-
r.draggedAxis === "x" && r.isRtl && (
|
|
809
|
+
var T = g - ((h = (u = v.rect) === null || u === void 0 ? void 0 : u[r.axis[r.draggedAxis].offsetAttr]) !== null && h !== void 0 ? h : 0) - r.axis[r.draggedAxis].dragOffset;
|
|
810
|
+
T = r.draggedAxis === "x" && r.isRtl ? ((p = (d = v.rect) === null || d === void 0 ? void 0 : d[r.axis[r.draggedAxis].sizeAttr]) !== null && p !== void 0 ? p : 0) - y.size - T : T;
|
|
811
|
+
var P = T / (w - y.size), A = P * (S - E);
|
|
812
|
+
r.draggedAxis === "x" && r.isRtl && (A = !((m = e.getRtlHelpers()) === null || m === void 0) && m.isScrollingToNegative ? -A : A), r.contentWrapperEl[r.axis[r.draggedAxis].scrollOffsetAttr] = A;
|
|
813
813
|
}
|
|
814
814
|
}, this.onEndDrag = function(i) {
|
|
815
815
|
var o = xn(r.el), s = ye(r.el);
|
|
@@ -883,7 +883,7 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
883
883
|
Ds && (this.initDOM(), this.rtlHelpers = e.getRtlHelpers(), this.scrollbarWidth = this.getScrollbarWidth(), this.recalculate(), this.initListeners());
|
|
884
884
|
}, e.prototype.initDOM = function() {
|
|
885
885
|
var t, n;
|
|
886
|
-
this.wrapperEl = this.el.querySelector(
|
|
886
|
+
this.wrapperEl = this.el.querySelector(G(this.classNames.wrapper)), this.contentWrapperEl = this.options.scrollableNode || this.el.querySelector(G(this.classNames.contentWrapper)), this.contentEl = this.options.contentNode || this.el.querySelector(G(this.classNames.contentEl)), this.offsetEl = this.el.querySelector(G(this.classNames.offset)), this.maskEl = this.el.querySelector(G(this.classNames.mask)), this.placeholderEl = this.findChild(this.wrapperEl, G(this.classNames.placeholder)), this.heightAutoObserverWrapperEl = this.el.querySelector(G(this.classNames.heightAutoObserverWrapperEl)), this.heightAutoObserverEl = this.el.querySelector(G(this.classNames.heightAutoObserverEl)), this.axis.x.track.el = this.findChild(this.el, "".concat(G(this.classNames.track)).concat(G(this.classNames.horizontal))), this.axis.y.track.el = this.findChild(this.el, "".concat(G(this.classNames.track)).concat(G(this.classNames.vertical))), this.axis.x.scrollbar.el = ((t = this.axis.x.track.el) === null || t === void 0 ? void 0 : t.querySelector(G(this.classNames.scrollbar))) || null, this.axis.y.scrollbar.el = ((n = this.axis.y.track.el) === null || n === void 0 ? void 0 : n.querySelector(G(this.classNames.scrollbar))) || null, this.options.autoHide || (ve(this.axis.x.scrollbar.el, this.classNames.visible), ve(this.axis.y.scrollbar.el, this.classNames.visible));
|
|
887
887
|
}, e.prototype.initListeners = function() {
|
|
888
888
|
var t = this, n, r = ye(this.el);
|
|
889
889
|
if (this.el.addEventListener("mouseenter", this.onMouseEnter), this.el.addEventListener("pointerdown", this.onPointerEvent, !0), this.el.addEventListener("mousemove", this.onMouseMove), this.el.addEventListener("mouseleave", this.onMouseLeave), (n = this.contentWrapperEl) === null || n === void 0 || n.addEventListener("scroll", this.onScroll), r.addEventListener("resize", this.onWindowResize), !!this.contentEl) {
|
|
@@ -913,12 +913,12 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
913
913
|
this.elStyles = t.getComputedStyle(this.el), this.isRtl = this.elStyles.direction === "rtl";
|
|
914
914
|
var n = this.contentEl.offsetWidth, r = this.heightAutoObserverEl.offsetHeight <= 1, i = this.heightAutoObserverEl.offsetWidth <= 1 || n > 0, o = this.contentWrapperEl.offsetWidth, s = this.elStyles.overflowX, a = this.elStyles.overflowY;
|
|
915
915
|
this.contentEl.style.padding = "".concat(this.elStyles.paddingTop, " ").concat(this.elStyles.paddingRight, " ").concat(this.elStyles.paddingBottom, " ").concat(this.elStyles.paddingLeft), this.wrapperEl.style.margin = "-".concat(this.elStyles.paddingTop, " -").concat(this.elStyles.paddingRight, " -").concat(this.elStyles.paddingBottom, " -").concat(this.elStyles.paddingLeft);
|
|
916
|
-
var l = this.contentEl.scrollHeight,
|
|
917
|
-
this.contentWrapperEl.style.height = r ? "auto" : "100%", this.placeholderEl.style.width = i ? "".concat(n ||
|
|
916
|
+
var l = this.contentEl.scrollHeight, c = this.contentEl.scrollWidth;
|
|
917
|
+
this.contentWrapperEl.style.height = r ? "auto" : "100%", this.placeholderEl.style.width = i ? "".concat(n || c, "px") : "auto", this.placeholderEl.style.height = "".concat(l, "px");
|
|
918
918
|
var f = this.contentWrapperEl.offsetHeight;
|
|
919
|
-
this.axis.x.isOverflowing = n !== 0 &&
|
|
920
|
-
var
|
|
921
|
-
this.axis.x.isOverflowing = this.axis.x.isOverflowing &&
|
|
919
|
+
this.axis.x.isOverflowing = n !== 0 && c > n, this.axis.y.isOverflowing = l > f, this.axis.x.isOverflowing = s === "hidden" ? !1 : this.axis.x.isOverflowing, this.axis.y.isOverflowing = a === "hidden" ? !1 : this.axis.y.isOverflowing, this.axis.x.forceVisible = this.options.forceVisible === "x" || this.options.forceVisible === !0, this.axis.y.forceVisible = this.options.forceVisible === "y" || this.options.forceVisible === !0, this.hideNativeScrollbar();
|
|
920
|
+
var u = this.axis.x.isOverflowing ? this.scrollbarWidth : 0, h = this.axis.y.isOverflowing ? this.scrollbarWidth : 0;
|
|
921
|
+
this.axis.x.isOverflowing = this.axis.x.isOverflowing && c > o - h, this.axis.y.isOverflowing = this.axis.y.isOverflowing && l > f - u, this.axis.x.scrollbar.size = this.getScrollbarSize("x"), this.axis.y.scrollbar.size = this.getScrollbarSize("y"), this.axis.x.scrollbar.el && (this.axis.x.scrollbar.el.style.width = "".concat(this.axis.x.scrollbar.size, "px")), this.axis.y.scrollbar.el && (this.axis.y.scrollbar.el.style.height = "".concat(this.axis.y.scrollbar.size, "px")), this.positionScrollbar("x"), this.positionScrollbar("y"), this.toggleTrackVisibility("x"), this.toggleTrackVisibility("y");
|
|
922
922
|
}
|
|
923
923
|
}, e.prototype.getScrollbarSize = function(t) {
|
|
924
924
|
var n, r;
|
|
@@ -931,10 +931,10 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
931
931
|
t === void 0 && (t = "y");
|
|
932
932
|
var o = this.axis[t].scrollbar;
|
|
933
933
|
if (!(!this.axis[t].isOverflowing || !this.contentWrapperEl || !o.el || !this.elStyles)) {
|
|
934
|
-
var s = this.contentWrapperEl[this.axis[t].scrollSizeAttr], a = ((n = this.axis[t].track.el) === null || n === void 0 ? void 0 : n[this.axis[t].offsetSizeAttr]) || 0, l = parseInt(this.elStyles[this.axis[t].sizeAttr], 10),
|
|
935
|
-
|
|
936
|
-
var f =
|
|
937
|
-
|
|
934
|
+
var s = this.contentWrapperEl[this.axis[t].scrollSizeAttr], a = ((n = this.axis[t].track.el) === null || n === void 0 ? void 0 : n[this.axis[t].offsetSizeAttr]) || 0, l = parseInt(this.elStyles[this.axis[t].sizeAttr], 10), c = this.contentWrapperEl[this.axis[t].scrollOffsetAttr];
|
|
935
|
+
c = t === "x" && this.isRtl && (!((r = e.getRtlHelpers()) === null || r === void 0) && r.isScrollOriginAtZero) ? -c : c, t === "x" && this.isRtl && (c = !((i = e.getRtlHelpers()) === null || i === void 0) && i.isScrollingToNegative ? c : -c);
|
|
936
|
+
var f = c / (s - l), u = ~~((a - o.size) * f);
|
|
937
|
+
u = t === "x" && this.isRtl ? -u + (a - o.size) : u, o.el.style.transform = t === "x" ? "translate3d(".concat(u, "px, 0, 0)") : "translate3d(0, ".concat(u, "px, 0)");
|
|
938
938
|
}
|
|
939
939
|
}, e.prototype.toggleTrackVisibility = function(t) {
|
|
940
940
|
t === void 0 && (t = "y");
|
|
@@ -963,12 +963,12 @@ var Zl = /* @__PURE__ */ Object.freeze({
|
|
|
963
963
|
var l = this.axis[n];
|
|
964
964
|
if (!(!this.options.clickOnTrack || !l.scrollbar.el || !this.contentWrapperEl)) {
|
|
965
965
|
t.preventDefault();
|
|
966
|
-
var
|
|
966
|
+
var c = ye(this.el);
|
|
967
967
|
this.axis[n].scrollbar.rect = l.scrollbar.el.getBoundingClientRect();
|
|
968
|
-
var f = this.axis[n].scrollbar,
|
|
969
|
-
r.contentWrapperEl && (m === -1 ? d > g && (d -=
|
|
968
|
+
var f = this.axis[n].scrollbar, u = (o = (i = f.rect) === null || i === void 0 ? void 0 : i[this.axis[n].offsetAttr]) !== null && o !== void 0 ? o : 0, h = parseInt((a = (s = this.elStyles) === null || s === void 0 ? void 0 : s[this.axis[n].sizeAttr]) !== null && a !== void 0 ? a : "0px", 10), d = this.contentWrapperEl[this.axis[n].scrollOffsetAttr], p = n === "y" ? this.mouseY - u : this.mouseX - u, m = p < 0 ? -1 : 1, g = m === -1 ? d - h : d + h, v = 40, w = function() {
|
|
969
|
+
r.contentWrapperEl && (m === -1 ? d > g && (d -= v, r.contentWrapperEl[r.axis[n].scrollOffsetAttr] = d, c.requestAnimationFrame(w)) : d < g && (d += v, r.contentWrapperEl[r.axis[n].scrollOffsetAttr] = d, c.requestAnimationFrame(w)));
|
|
970
970
|
};
|
|
971
|
-
|
|
971
|
+
w();
|
|
972
972
|
}
|
|
973
973
|
}, e.prototype.getContentElement = function() {
|
|
974
974
|
return this.contentEl;
|
|
@@ -1036,71 +1036,71 @@ function ec(e, t) {
|
|
|
1036
1036
|
t.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (n[r[i]] = e[r[i]]);
|
|
1037
1037
|
return n;
|
|
1038
1038
|
}
|
|
1039
|
-
var Ws =
|
|
1040
|
-
var n = e.children, r = e.scrollableNodeProps, i = r === void 0 ? {} : r, o = ec(e, ["children", "scrollableNodeProps"]), s =
|
|
1039
|
+
var Ws = x.forwardRef(function(e, t) {
|
|
1040
|
+
var n = e.children, r = e.scrollableNodeProps, i = r === void 0 ? {} : r, o = ec(e, ["children", "scrollableNodeProps"]), s = x.useRef(), a = x.useRef(), l = x.useRef(), c = {}, f = {};
|
|
1041
1041
|
Object.keys(o).forEach(function(d) {
|
|
1042
|
-
Object.prototype.hasOwnProperty.call(
|
|
1042
|
+
Object.prototype.hasOwnProperty.call(Pt.defaultOptions, d) ? c[d] = o[d] : f[d] = o[d];
|
|
1043
1043
|
});
|
|
1044
|
-
var
|
|
1045
|
-
return
|
|
1044
|
+
var u = Y(Y({}, Pt.defaultOptions.classNames), c.classNames), h = Y(Y({}, i), { className: "".concat(u.contentWrapper).concat(i.className ? " ".concat(i.className) : ""), tabIndex: 0, role: "region", "aria-label": c.ariaLabel || Pt.defaultOptions.ariaLabel });
|
|
1045
|
+
return x.useEffect(function() {
|
|
1046
1046
|
var d;
|
|
1047
|
-
return a.current = h.ref ? h.ref.current : a.current, s.current && (d = new
|
|
1047
|
+
return a.current = h.ref ? h.ref.current : a.current, s.current && (d = new Pt(s.current, Y(Y(Y({}, c), a.current && {
|
|
1048
1048
|
scrollableNode: a.current
|
|
1049
1049
|
}), l.current && {
|
|
1050
1050
|
contentNode: l.current
|
|
1051
1051
|
})), typeof t == "function" ? t(d) : t && (t.current = d)), function() {
|
|
1052
1052
|
d == null || d.unMount(), d = null, typeof t == "function" && t(null);
|
|
1053
1053
|
};
|
|
1054
|
-
}, []),
|
|
1054
|
+
}, []), x.createElement(
|
|
1055
1055
|
"div",
|
|
1056
1056
|
Y({ "data-simplebar": "init", ref: s }, f),
|
|
1057
|
-
|
|
1057
|
+
x.createElement(
|
|
1058
1058
|
"div",
|
|
1059
|
-
{ className:
|
|
1060
|
-
|
|
1059
|
+
{ className: u.wrapper },
|
|
1060
|
+
x.createElement(
|
|
1061
1061
|
"div",
|
|
1062
|
-
{ className:
|
|
1063
|
-
|
|
1062
|
+
{ className: u.heightAutoObserverWrapperEl },
|
|
1063
|
+
x.createElement("div", { className: u.heightAutoObserverEl })
|
|
1064
1064
|
),
|
|
1065
|
-
|
|
1065
|
+
x.createElement(
|
|
1066
1066
|
"div",
|
|
1067
|
-
{ className:
|
|
1068
|
-
|
|
1067
|
+
{ className: u.mask },
|
|
1068
|
+
x.createElement("div", { className: u.offset }, typeof n == "function" ? n({
|
|
1069
1069
|
scrollableNodeRef: a,
|
|
1070
1070
|
scrollableNodeProps: Y(Y({}, h), { ref: a }),
|
|
1071
1071
|
contentNodeRef: l,
|
|
1072
1072
|
contentNodeProps: {
|
|
1073
|
-
className:
|
|
1073
|
+
className: u.contentEl,
|
|
1074
1074
|
ref: l
|
|
1075
1075
|
}
|
|
1076
|
-
}) :
|
|
1076
|
+
}) : x.createElement(
|
|
1077
1077
|
"div",
|
|
1078
1078
|
Y({}, h),
|
|
1079
|
-
|
|
1079
|
+
x.createElement("div", { className: u.contentEl }, n)
|
|
1080
1080
|
))
|
|
1081
1081
|
),
|
|
1082
|
-
|
|
1082
|
+
x.createElement("div", { className: u.placeholder })
|
|
1083
1083
|
),
|
|
1084
|
-
|
|
1084
|
+
x.createElement(
|
|
1085
1085
|
"div",
|
|
1086
|
-
{ className: "".concat(
|
|
1087
|
-
|
|
1086
|
+
{ className: "".concat(u.track, " simplebar-horizontal") },
|
|
1087
|
+
x.createElement("div", { className: u.scrollbar })
|
|
1088
1088
|
),
|
|
1089
|
-
|
|
1089
|
+
x.createElement(
|
|
1090
1090
|
"div",
|
|
1091
|
-
{ className: "".concat(
|
|
1092
|
-
|
|
1091
|
+
{ className: "".concat(u.track, " simplebar-vertical") },
|
|
1092
|
+
x.createElement("div", { className: u.scrollbar })
|
|
1093
1093
|
)
|
|
1094
1094
|
);
|
|
1095
1095
|
});
|
|
1096
1096
|
Ws.displayName = "SimpleBar";
|
|
1097
|
-
const Us =
|
|
1097
|
+
const Us = x.createContext({
|
|
1098
1098
|
transformPagePoint: (e) => e,
|
|
1099
1099
|
isStatic: !1,
|
|
1100
1100
|
reducedMotion: "never"
|
|
1101
|
-
}), rn =
|
|
1101
|
+
}), rn = x.createContext({}), lr = x.createContext(null), sn = typeof document < "u", tc = sn ? x.useLayoutEffect : x.useEffect, zs = x.createContext({ strict: !1 }), cr = (e) => e.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase(), nc = "framerAppearId", Hs = "data-" + cr(nc);
|
|
1102
1102
|
function rc(e, t, n, r) {
|
|
1103
|
-
const { visualElement: i } =
|
|
1103
|
+
const { visualElement: i } = x.useContext(rn), o = x.useContext(zs), s = x.useContext(lr), a = x.useContext(Us).reducedMotion, l = x.useRef();
|
|
1104
1104
|
r = r || o.renderer, !l.current && r && (l.current = r(e, {
|
|
1105
1105
|
visualState: t,
|
|
1106
1106
|
parent: i,
|
|
@@ -1109,22 +1109,22 @@ function rc(e, t, n, r) {
|
|
|
1109
1109
|
blockInitialAnimation: s ? s.initial === !1 : !1,
|
|
1110
1110
|
reducedMotionConfig: a
|
|
1111
1111
|
}));
|
|
1112
|
-
const
|
|
1113
|
-
|
|
1114
|
-
|
|
1112
|
+
const c = l.current;
|
|
1113
|
+
x.useInsertionEffect(() => {
|
|
1114
|
+
c && c.update(n, s);
|
|
1115
1115
|
});
|
|
1116
|
-
const f =
|
|
1116
|
+
const f = x.useRef(!!(n[Hs] && !window.HandoffComplete));
|
|
1117
1117
|
return tc(() => {
|
|
1118
|
-
|
|
1119
|
-
}),
|
|
1120
|
-
|
|
1121
|
-
}),
|
|
1118
|
+
c && (c.render(), f.current && c.animationState && c.animationState.animateChanges());
|
|
1119
|
+
}), x.useEffect(() => {
|
|
1120
|
+
c && (c.updateFeatures(), !f.current && c.animationState && c.animationState.animateChanges(), f.current && (f.current = !1, window.HandoffComplete = !0));
|
|
1121
|
+
}), c;
|
|
1122
1122
|
}
|
|
1123
1123
|
function qe(e) {
|
|
1124
1124
|
return e && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "current");
|
|
1125
1125
|
}
|
|
1126
1126
|
function ic(e, t, n) {
|
|
1127
|
-
return
|
|
1127
|
+
return x.useCallback(
|
|
1128
1128
|
(r) => {
|
|
1129
1129
|
r && e.mount && e.mount(r), t && (r ? t.mount(r) : t.unmount()), n && (typeof n == "function" ? n(r) : qe(n) && (n.current = r));
|
|
1130
1130
|
},
|
|
@@ -1168,8 +1168,8 @@ function sc(e, t) {
|
|
|
1168
1168
|
return e.inherit !== !1 ? t : {};
|
|
1169
1169
|
}
|
|
1170
1170
|
function oc(e) {
|
|
1171
|
-
const { initial: t, animate: n } = sc(e,
|
|
1172
|
-
return
|
|
1171
|
+
const { initial: t, animate: n } = sc(e, x.useContext(rn));
|
|
1172
|
+
return x.useMemo(() => ({ initial: t, animate: n }), [Yr(t), Yr(n)]);
|
|
1173
1173
|
}
|
|
1174
1174
|
function Yr(e) {
|
|
1175
1175
|
return Array.isArray(e) ? e.join(" ") : e;
|
|
@@ -1205,20 +1205,20 @@ function ac(e) {
|
|
|
1205
1205
|
...e[t]
|
|
1206
1206
|
};
|
|
1207
1207
|
}
|
|
1208
|
-
const qs =
|
|
1208
|
+
const qs = x.createContext({}), Gs = x.createContext({}), lc = Symbol.for("motionComponentSymbol");
|
|
1209
1209
|
function cc({ preloadedFeatures: e, createVisualElement: t, useRender: n, useVisualState: r, Component: i }) {
|
|
1210
1210
|
e && ac(e);
|
|
1211
1211
|
function o(a, l) {
|
|
1212
|
-
let
|
|
1212
|
+
let c;
|
|
1213
1213
|
const f = {
|
|
1214
|
-
...
|
|
1214
|
+
...x.useContext(Us),
|
|
1215
1215
|
...a,
|
|
1216
1216
|
layoutId: uc(a)
|
|
1217
|
-
}, { isStatic:
|
|
1218
|
-
if (!
|
|
1217
|
+
}, { isStatic: u } = f, h = oc(a), d = r(a, u);
|
|
1218
|
+
if (!u && sn) {
|
|
1219
1219
|
h.visualElement = rc(i, d, f, t);
|
|
1220
|
-
const p =
|
|
1221
|
-
h.visualElement && (
|
|
1220
|
+
const p = x.useContext(Gs), m = x.useContext(zs).strict;
|
|
1221
|
+
h.visualElement && (c = h.visualElement.loadFeatures(
|
|
1222
1222
|
// Note: Pass the full new combined props to correctly re-render dynamic feature components.
|
|
1223
1223
|
f,
|
|
1224
1224
|
m,
|
|
@@ -1226,18 +1226,18 @@ function cc({ preloadedFeatures: e, createVisualElement: t, useRender: n, useVis
|
|
|
1226
1226
|
p
|
|
1227
1227
|
));
|
|
1228
1228
|
}
|
|
1229
|
-
return
|
|
1229
|
+
return x.createElement(
|
|
1230
1230
|
rn.Provider,
|
|
1231
1231
|
{ value: h },
|
|
1232
|
-
|
|
1233
|
-
n(i, a, ic(d, h.visualElement, l), d,
|
|
1232
|
+
c && h.visualElement ? x.createElement(c, { visualElement: h.visualElement, ...f }) : null,
|
|
1233
|
+
n(i, a, ic(d, h.visualElement, l), d, u, h.visualElement)
|
|
1234
1234
|
);
|
|
1235
1235
|
}
|
|
1236
|
-
const s =
|
|
1236
|
+
const s = x.forwardRef(o);
|
|
1237
1237
|
return s[lc] = i, s;
|
|
1238
1238
|
}
|
|
1239
1239
|
function uc({ layoutId: e }) {
|
|
1240
|
-
const t =
|
|
1240
|
+
const t = x.useContext(qs).id;
|
|
1241
1241
|
return t && e !== void 0 ? t + "-" + e : e;
|
|
1242
1242
|
}
|
|
1243
1243
|
function fc(e) {
|
|
@@ -1329,7 +1329,7 @@ const vt = [
|
|
|
1329
1329
|
function Xs(e, { layout: t, layoutId: n }) {
|
|
1330
1330
|
return _e.has(e) || e.startsWith("origin") || (t || n !== void 0) && (!!Ut[e] || e === "opacity");
|
|
1331
1331
|
}
|
|
1332
|
-
const
|
|
1332
|
+
const X = (e) => !!(e && e.getVelocity), pc = {
|
|
1333
1333
|
x: "translateX",
|
|
1334
1334
|
y: "translateY",
|
|
1335
1335
|
z: "translateZ",
|
|
@@ -1346,14 +1346,14 @@ function gc(e, { enableHardwareAcceleration: t = !0, allowTransformNone: n = !0
|
|
|
1346
1346
|
}
|
|
1347
1347
|
return t && !e.z && (o += "translateZ(0)"), o = o.trim(), i ? o = i(e, r ? "" : o) : n && r && (o = "none"), o;
|
|
1348
1348
|
}
|
|
1349
|
-
const Ks = (e) => (t) => typeof t == "string" && t.startsWith(e), Ys = Ks("--"), Wn = Ks("var(--"), yc = /var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g, vc = (e, t) => t && typeof e == "number" ? t.transform(e) : e,
|
|
1349
|
+
const Ks = (e) => (t) => typeof t == "string" && t.startsWith(e), Ys = Ks("--"), Wn = Ks("var(--"), yc = /var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g, vc = (e, t) => t && typeof e == "number" ? t.transform(e) : e, Ae = (e, t, n) => Math.min(Math.max(n, e), t), Fe = {
|
|
1350
1350
|
test: (e) => typeof e == "number",
|
|
1351
1351
|
parse: parseFloat,
|
|
1352
1352
|
transform: (e) => e
|
|
1353
1353
|
}, at = {
|
|
1354
1354
|
...Fe,
|
|
1355
|
-
transform: (e) =>
|
|
1356
|
-
},
|
|
1355
|
+
transform: (e) => Ae(0, 1, e)
|
|
1356
|
+
}, At = {
|
|
1357
1357
|
...Fe,
|
|
1358
1358
|
default: 1
|
|
1359
1359
|
}, lt = (e) => Math.round(e * 1e5) / 1e5, ln = /(-)?([\d]*\.?[\d])+/g, Js = /(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi, bc = /^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;
|
|
@@ -1410,10 +1410,10 @@ const xt = (e) => ({
|
|
|
1410
1410
|
rotateX: we,
|
|
1411
1411
|
rotateY: we,
|
|
1412
1412
|
rotateZ: we,
|
|
1413
|
-
scale:
|
|
1414
|
-
scaleX:
|
|
1415
|
-
scaleY:
|
|
1416
|
-
scaleZ:
|
|
1413
|
+
scale: At,
|
|
1414
|
+
scaleX: At,
|
|
1415
|
+
scaleY: At,
|
|
1416
|
+
scaleZ: At,
|
|
1417
1417
|
skew: we,
|
|
1418
1418
|
skewX: we,
|
|
1419
1419
|
skewY: we,
|
|
@@ -1439,24 +1439,24 @@ const xt = (e) => ({
|
|
|
1439
1439
|
};
|
|
1440
1440
|
function dr(e, t, n, r) {
|
|
1441
1441
|
const { style: i, vars: o, transform: s, transformOrigin: a } = e;
|
|
1442
|
-
let l = !1,
|
|
1443
|
-
for (const
|
|
1444
|
-
const h = t[
|
|
1445
|
-
if (Ys(
|
|
1446
|
-
o[
|
|
1442
|
+
let l = !1, c = !1, f = !0;
|
|
1443
|
+
for (const u in t) {
|
|
1444
|
+
const h = t[u];
|
|
1445
|
+
if (Ys(u)) {
|
|
1446
|
+
o[u] = h;
|
|
1447
1447
|
continue;
|
|
1448
1448
|
}
|
|
1449
|
-
const d = Zs[
|
|
1450
|
-
if (_e.has(
|
|
1451
|
-
if (l = !0, s[
|
|
1449
|
+
const d = Zs[u], p = vc(h, d);
|
|
1450
|
+
if (_e.has(u)) {
|
|
1451
|
+
if (l = !0, s[u] = p, !f)
|
|
1452
1452
|
continue;
|
|
1453
1453
|
h !== (d.default || 0) && (f = !1);
|
|
1454
1454
|
} else
|
|
1455
|
-
|
|
1455
|
+
u.startsWith("origin") ? (c = !0, a[u] = p) : i[u] = p;
|
|
1456
1456
|
}
|
|
1457
|
-
if (t.transform || (l || r ? i.transform = gc(e.transform, n, f, r) : i.transform && (i.transform = "none")),
|
|
1458
|
-
const { originX:
|
|
1459
|
-
i.transformOrigin = `${
|
|
1457
|
+
if (t.transform || (l || r ? i.transform = gc(e.transform, n, f, r) : i.transform && (i.transform = "none")), c) {
|
|
1458
|
+
const { originX: u = "50%", originY: h = "50%", originZ: d = 0 } = a;
|
|
1459
|
+
i.transformOrigin = `${u} ${h} ${d}`;
|
|
1460
1460
|
}
|
|
1461
1461
|
}
|
|
1462
1462
|
const pr = () => ({
|
|
@@ -1467,10 +1467,10 @@ const pr = () => ({
|
|
|
1467
1467
|
});
|
|
1468
1468
|
function Qs(e, t, n) {
|
|
1469
1469
|
for (const r in t)
|
|
1470
|
-
!
|
|
1470
|
+
!X(t[r]) && !Xs(r, n) && (e[r] = t[r]);
|
|
1471
1471
|
}
|
|
1472
1472
|
function Sc({ transformTemplate: e }, t, n) {
|
|
1473
|
-
return
|
|
1473
|
+
return x.useMemo(() => {
|
|
1474
1474
|
const r = pr();
|
|
1475
1475
|
return dr(r, t, { enableHardwareAcceleration: !n }, e), Object.assign({}, r.vars, r.style);
|
|
1476
1476
|
}, [t]);
|
|
@@ -1483,7 +1483,7 @@ function Tc(e, t, n) {
|
|
|
1483
1483
|
const r = {}, i = Ec(e, t, n);
|
|
1484
1484
|
return e.drag && e.dragListener !== !1 && (r.draggable = !1, i.userSelect = i.WebkitUserSelect = i.WebkitTouchCallout = "none", i.touchAction = e.drag === !0 ? "none" : `pan-${e.drag === "x" ? "y" : "x"}`), e.tabIndex === void 0 && (e.onTap || e.onTapStart || e.whileTap) && (r.tabIndex = 0), r.style = i, r;
|
|
1485
1485
|
}
|
|
1486
|
-
const
|
|
1486
|
+
const Pc = /* @__PURE__ */ new Set([
|
|
1487
1487
|
"animate",
|
|
1488
1488
|
"exit",
|
|
1489
1489
|
"variants",
|
|
@@ -1517,14 +1517,14 @@ const Ac = /* @__PURE__ */ new Set([
|
|
|
1517
1517
|
"viewport"
|
|
1518
1518
|
]);
|
|
1519
1519
|
function zt(e) {
|
|
1520
|
-
return e.startsWith("while") || e.startsWith("drag") && e !== "draggable" || e.startsWith("layout") || e.startsWith("onTap") || e.startsWith("onPan") || e.startsWith("onLayout") ||
|
|
1520
|
+
return e.startsWith("while") || e.startsWith("drag") && e !== "draggable" || e.startsWith("layout") || e.startsWith("onTap") || e.startsWith("onPan") || e.startsWith("onLayout") || Pc.has(e);
|
|
1521
1521
|
}
|
|
1522
1522
|
let eo = (e) => !zt(e);
|
|
1523
|
-
function
|
|
1523
|
+
function Ac(e) {
|
|
1524
1524
|
e && (eo = (t) => t.startsWith("on") ? !zt(t) : e(t));
|
|
1525
1525
|
}
|
|
1526
1526
|
try {
|
|
1527
|
-
|
|
1527
|
+
Ac(require("@emotion/is-prop-valid").default);
|
|
1528
1528
|
} catch {
|
|
1529
1529
|
}
|
|
1530
1530
|
function Cc(e, t, n) {
|
|
@@ -1565,9 +1565,9 @@ function mr(e, {
|
|
|
1565
1565
|
pathSpacing: a = 1,
|
|
1566
1566
|
pathOffset: l = 0,
|
|
1567
1567
|
// This is object creation, which we try to avoid per-frame.
|
|
1568
|
-
...
|
|
1569
|
-
}, f,
|
|
1570
|
-
if (dr(e,
|
|
1568
|
+
...c
|
|
1569
|
+
}, f, u, h) {
|
|
1570
|
+
if (dr(e, c, f, h), u) {
|
|
1571
1571
|
e.style.viewBox && (e.attrs.viewBox = e.style.viewBox);
|
|
1572
1572
|
return;
|
|
1573
1573
|
}
|
|
@@ -1580,7 +1580,7 @@ const to = () => ({
|
|
|
1580
1580
|
attrs: {}
|
|
1581
1581
|
}), gr = (e) => typeof e == "string" && e.toLowerCase() === "svg";
|
|
1582
1582
|
function Mc(e, t, n, r) {
|
|
1583
|
-
const i =
|
|
1583
|
+
const i = x.useMemo(() => {
|
|
1584
1584
|
const o = to();
|
|
1585
1585
|
return mr(o, t, { enableHardwareAcceleration: !1 }, gr(r), e.transformTemplate), {
|
|
1586
1586
|
...o.attrs,
|
|
@@ -1599,8 +1599,8 @@ function Lc(e = !1) {
|
|
|
1599
1599
|
...Cc(r, typeof n == "string", e),
|
|
1600
1600
|
...l,
|
|
1601
1601
|
ref: i
|
|
1602
|
-
}, { children:
|
|
1603
|
-
return
|
|
1602
|
+
}, { children: u } = r, h = x.useMemo(() => X(u) ? u.get() : u, [u]);
|
|
1603
|
+
return x.createElement(n, {
|
|
1604
1604
|
...f,
|
|
1605
1605
|
children: h
|
|
1606
1606
|
});
|
|
@@ -1644,13 +1644,13 @@ function io(e, t, n, r) {
|
|
|
1644
1644
|
function yr(e, t) {
|
|
1645
1645
|
const { style: n } = e, r = {};
|
|
1646
1646
|
for (const i in n)
|
|
1647
|
-
(
|
|
1647
|
+
(X(n[i]) || t.style && X(t.style[i]) || Xs(i, e)) && (r[i] = n[i]);
|
|
1648
1648
|
return r;
|
|
1649
1649
|
}
|
|
1650
1650
|
function so(e, t) {
|
|
1651
1651
|
const n = yr(e, t);
|
|
1652
1652
|
for (const r in e)
|
|
1653
|
-
if (
|
|
1653
|
+
if (X(e[r]) || X(t[r])) {
|
|
1654
1654
|
const i = vt.indexOf(r) !== -1 ? "attr" + r.charAt(0).toUpperCase() + r.substring(1) : r;
|
|
1655
1655
|
n[i] = e[r];
|
|
1656
1656
|
}
|
|
@@ -1660,12 +1660,12 @@ function vr(e, t, n, r = {}, i = {}) {
|
|
|
1660
1660
|
return typeof t == "function" && (t = t(n !== void 0 ? n : e.custom, r, i)), typeof t == "string" && (t = e.variants && e.variants[t]), typeof t == "function" && (t = t(n !== void 0 ? n : e.custom, r, i)), t;
|
|
1661
1661
|
}
|
|
1662
1662
|
function Dc(e) {
|
|
1663
|
-
const t =
|
|
1663
|
+
const t = x.useRef(null);
|
|
1664
1664
|
return t.current === null && (t.current = e()), t.current;
|
|
1665
1665
|
}
|
|
1666
1666
|
const Ht = (e) => Array.isArray(e), jc = (e) => !!(e && typeof e == "object" && e.mix && e.toValue), _c = (e) => Ht(e) ? e[e.length - 1] || 0 : e;
|
|
1667
1667
|
function Lt(e) {
|
|
1668
|
-
const t =
|
|
1668
|
+
const t = X(e) ? e.get() : e;
|
|
1669
1669
|
return jc(t) ? t.toValue() : t;
|
|
1670
1670
|
}
|
|
1671
1671
|
function Fc({ scrapeMotionValuesFromProps: e, createRenderState: t, onMount: n }, r, i, o) {
|
|
@@ -1676,7 +1676,7 @@ function Fc({ scrapeMotionValuesFromProps: e, createRenderState: t, onMount: n }
|
|
|
1676
1676
|
return n && (s.mount = (a) => n(r, a, s)), s;
|
|
1677
1677
|
}
|
|
1678
1678
|
const oo = (e) => (t, n) => {
|
|
1679
|
-
const r =
|
|
1679
|
+
const r = x.useContext(rn), i = x.useContext(lr), o = () => Fc(e, t, r, i);
|
|
1680
1680
|
return n ? o() : Dc(o);
|
|
1681
1681
|
};
|
|
1682
1682
|
function Nc(e, t, n, r) {
|
|
@@ -1684,26 +1684,26 @@ function Nc(e, t, n, r) {
|
|
|
1684
1684
|
for (const h in o)
|
|
1685
1685
|
i[h] = Lt(o[h]);
|
|
1686
1686
|
let { initial: s, animate: a } = e;
|
|
1687
|
-
const l = an(e),
|
|
1688
|
-
t &&
|
|
1687
|
+
const l = an(e), c = $s(e);
|
|
1688
|
+
t && c && !l && e.inherit !== !1 && (s === void 0 && (s = t.initial), a === void 0 && (a = t.animate));
|
|
1689
1689
|
let f = n ? n.initial === !1 : !1;
|
|
1690
1690
|
f = f || s === !1;
|
|
1691
|
-
const
|
|
1692
|
-
return
|
|
1691
|
+
const u = f ? a : s;
|
|
1692
|
+
return u && typeof u != "boolean" && !on(u) && (Array.isArray(u) ? u : [u]).forEach((d) => {
|
|
1693
1693
|
const p = vr(e, d);
|
|
1694
1694
|
if (!p)
|
|
1695
1695
|
return;
|
|
1696
|
-
const { transitionEnd: m, transition: g, ...
|
|
1697
|
-
for (const
|
|
1698
|
-
let y =
|
|
1696
|
+
const { transitionEnd: m, transition: g, ...v } = p;
|
|
1697
|
+
for (const w in v) {
|
|
1698
|
+
let y = v[w];
|
|
1699
1699
|
if (Array.isArray(y)) {
|
|
1700
1700
|
const S = f ? y.length - 1 : 0;
|
|
1701
1701
|
y = y[S];
|
|
1702
1702
|
}
|
|
1703
|
-
y !== null && (i[
|
|
1703
|
+
y !== null && (i[w] = y);
|
|
1704
1704
|
}
|
|
1705
|
-
for (const
|
|
1706
|
-
i[
|
|
1705
|
+
for (const w in m)
|
|
1706
|
+
i[w] = m[w];
|
|
1707
1707
|
}), i;
|
|
1708
1708
|
}
|
|
1709
1709
|
const j = (e) => e;
|
|
@@ -1729,9 +1729,9 @@ function Bc(e) {
|
|
|
1729
1729
|
/**
|
|
1730
1730
|
* Schedule a process to run on the next frame.
|
|
1731
1731
|
*/
|
|
1732
|
-
schedule: (l,
|
|
1733
|
-
const
|
|
1734
|
-
return
|
|
1732
|
+
schedule: (l, c = !1, f = !1) => {
|
|
1733
|
+
const u = f && i, h = u ? t : n;
|
|
1734
|
+
return c && s.add(l), h.add(l) && u && i && (r = t.order.length), l;
|
|
1735
1735
|
},
|
|
1736
1736
|
/**
|
|
1737
1737
|
* Cancel the provided callback from running on the next frame.
|
|
@@ -1748,8 +1748,8 @@ function Bc(e) {
|
|
|
1748
1748
|
return;
|
|
1749
1749
|
}
|
|
1750
1750
|
if (i = !0, [t, n] = [n, t], n.clear(), r = t.order.length, r)
|
|
1751
|
-
for (let
|
|
1752
|
-
const f = t.order[
|
|
1751
|
+
for (let c = 0; c < r; c++) {
|
|
1752
|
+
const f = t.order[c];
|
|
1753
1753
|
f(l), s.has(f) && (a.schedule(f), e());
|
|
1754
1754
|
}
|
|
1755
1755
|
i = !1, o && (o = !1, a.process(l));
|
|
@@ -1771,18 +1771,18 @@ function Wc(e, t) {
|
|
|
1771
1771
|
delta: 0,
|
|
1772
1772
|
timestamp: 0,
|
|
1773
1773
|
isProcessing: !1
|
|
1774
|
-
}, o = Ct.reduce((
|
|
1775
|
-
const
|
|
1776
|
-
n = !1, i.delta = r ? 1e3 / 60 : Math.max(Math.min(
|
|
1774
|
+
}, o = Ct.reduce((u, h) => (u[h] = Bc(() => n = !0), u), {}), s = (u) => o[u].process(i), a = () => {
|
|
1775
|
+
const u = performance.now();
|
|
1776
|
+
n = !1, i.delta = r ? 1e3 / 60 : Math.max(Math.min(u - i.timestamp, Ic), 1), i.timestamp = u, i.isProcessing = !0, Ct.forEach(s), i.isProcessing = !1, n && t && (r = !1, e(a));
|
|
1777
1777
|
}, l = () => {
|
|
1778
1778
|
n = !0, r = !0, i.isProcessing || e(a);
|
|
1779
1779
|
};
|
|
1780
|
-
return { schedule: Ct.reduce((
|
|
1780
|
+
return { schedule: Ct.reduce((u, h) => {
|
|
1781
1781
|
const d = o[h];
|
|
1782
|
-
return
|
|
1783
|
-
}, {}), cancel: (
|
|
1782
|
+
return u[h] = (p, m = !1, g = !1) => (n || l(), d.schedule(p, m, g)), u;
|
|
1783
|
+
}, {}), cancel: (u) => Ct.forEach((h) => o[h].cancel(u)), state: i, steps: o };
|
|
1784
1784
|
}
|
|
1785
|
-
const { schedule: M, cancel: me, state:
|
|
1785
|
+
const { schedule: M, cancel: me, state: $, steps: wn } = Wc(typeof requestAnimationFrame < "u" ? requestAnimationFrame : j, !0), Uc = {
|
|
1786
1786
|
useVisualState: oo({
|
|
1787
1787
|
scrapeMotionValuesFromProps: so,
|
|
1788
1788
|
createRenderState: to,
|
|
@@ -1926,9 +1926,9 @@ class Kc extends Re {
|
|
|
1926
1926
|
const r = this.node.getProps(), o = he(window, "pointerup", (a, l) => {
|
|
1927
1927
|
if (!this.checkPressEnd())
|
|
1928
1928
|
return;
|
|
1929
|
-
const { onTap:
|
|
1929
|
+
const { onTap: c, onTapCancel: f, globalTapTarget: u } = this.node.getProps();
|
|
1930
1930
|
M.update(() => {
|
|
1931
|
-
!
|
|
1931
|
+
!u && !fo(this.node.current, a.target) ? f && f(a, l) : c && c(a, l);
|
|
1932
1932
|
});
|
|
1933
1933
|
}, { passive: !(r.onTap || r.onPointerUp) }), s = he(window, "pointercancel", (a, l) => this.cancelPress(a, l), { passive: !(r.onTapCancel || r.onPointerCancel) });
|
|
1934
1934
|
this.removeEndListeners = Te(o, s), this.startPress(t, n);
|
|
@@ -1937,9 +1937,9 @@ class Kc extends Re {
|
|
|
1937
1937
|
if (o.key !== "Enter" || this.isPressing)
|
|
1938
1938
|
return;
|
|
1939
1939
|
const s = (a) => {
|
|
1940
|
-
a.key !== "Enter" || !this.checkPressEnd() || Sn("up", (l,
|
|
1940
|
+
a.key !== "Enter" || !this.checkPressEnd() || Sn("up", (l, c) => {
|
|
1941
1941
|
const { onTap: f } = this.node.getProps();
|
|
1942
|
-
f && M.update(() => f(l,
|
|
1942
|
+
f && M.update(() => f(l, c));
|
|
1943
1943
|
});
|
|
1944
1944
|
};
|
|
1945
1945
|
this.removeEndListeners(), this.removeEndListeners = fe(this.node.current, "keyup", s), Sn("down", (a, l) => {
|
|
@@ -2006,11 +2006,11 @@ class tu extends Re {
|
|
|
2006
2006
|
rootMargin: r,
|
|
2007
2007
|
threshold: typeof i == "number" ? i : eu[i]
|
|
2008
2008
|
}, a = (l) => {
|
|
2009
|
-
const { isIntersecting:
|
|
2010
|
-
if (this.isInView ===
|
|
2009
|
+
const { isIntersecting: c } = l;
|
|
2010
|
+
if (this.isInView === c || (this.isInView = c, o && !c && this.hasEnteredView))
|
|
2011
2011
|
return;
|
|
2012
|
-
|
|
2013
|
-
const { onViewportEnter: f, onViewportLeave:
|
|
2012
|
+
c && (this.hasEnteredView = !0), this.node.animationState && this.node.animationState.setActive("whileInView", c);
|
|
2013
|
+
const { onViewportEnter: f, onViewportLeave: u } = this.node.getProps(), h = c ? f : u;
|
|
2014
2014
|
h && h(l);
|
|
2015
2015
|
};
|
|
2016
2016
|
return Qc(this.node.current, s, a);
|
|
@@ -2068,7 +2068,7 @@ function un(e, t, n) {
|
|
|
2068
2068
|
return vr(r, t, n !== void 0 ? n : r.custom, iu(e), su(e));
|
|
2069
2069
|
}
|
|
2070
2070
|
let ou = j, br = j;
|
|
2071
|
-
const
|
|
2071
|
+
const Pe = (e) => e * 1e3, de = (e) => e / 1e3, au = {
|
|
2072
2072
|
current: !1
|
|
2073
2073
|
}, po = (e) => Array.isArray(e) && typeof e[0] == "number";
|
|
2074
2074
|
function mo(e) {
|
|
@@ -2090,10 +2090,10 @@ function yo(e) {
|
|
|
2090
2090
|
return po(e) ? ot(e) : Array.isArray(e) ? e.map(yo) : go[e];
|
|
2091
2091
|
}
|
|
2092
2092
|
function lu(e, t, n, { delay: r = 0, duration: i, repeat: o = 0, repeatType: s = "loop", ease: a, times: l } = {}) {
|
|
2093
|
-
const
|
|
2094
|
-
l && (
|
|
2093
|
+
const c = { [t]: n };
|
|
2094
|
+
l && (c.offset = l);
|
|
2095
2095
|
const f = yo(a);
|
|
2096
|
-
return Array.isArray(f) && (
|
|
2096
|
+
return Array.isArray(f) && (c.easing = f), e.animate(c, {
|
|
2097
2097
|
delay: r,
|
|
2098
2098
|
duration: i,
|
|
2099
2099
|
easing: Array.isArray(f) ? "linear" : f,
|
|
@@ -2150,7 +2150,7 @@ const du = wt(0.42, 0, 1, 1), pu = wt(0, 0, 0.58, 1), bo = wt(0.42, 0, 0.58, 1),
|
|
|
2150
2150
|
[n]: parseFloat(s),
|
|
2151
2151
|
alpha: a !== void 0 ? parseFloat(a) : 1
|
|
2152
2152
|
};
|
|
2153
|
-
}, xu = (e) =>
|
|
2153
|
+
}, xu = (e) => Ae(0, 255, e), Tn = {
|
|
2154
2154
|
...Fe,
|
|
2155
2155
|
transform: (e) => Math.round(xu(e))
|
|
2156
2156
|
}, je = {
|
|
@@ -2175,12 +2175,12 @@ const zn = {
|
|
|
2175
2175
|
test: Sr("hsl", "hue"),
|
|
2176
2176
|
parse: To("hue", "saturation", "lightness"),
|
|
2177
2177
|
transform: ({ hue: e, saturation: t, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(e) + ", " + le.transform(lt(t)) + ", " + le.transform(lt(n)) + ", " + lt(at.transform(r)) + ")"
|
|
2178
|
-
},
|
|
2178
|
+
}, q = {
|
|
2179
2179
|
test: (e) => je.test(e) || zn.test(e) || Ge.test(e),
|
|
2180
2180
|
parse: (e) => je.test(e) ? je.parse(e) : Ge.test(e) ? Ge.parse(e) : zn.parse(e),
|
|
2181
2181
|
transform: (e) => bt(e) ? e : e.hasOwnProperty("red") ? je.transform(e) : Ge.transform(e)
|
|
2182
2182
|
}, D = (e, t, n) => -n * e + n * t + e;
|
|
2183
|
-
function
|
|
2183
|
+
function Pn(e, t, n) {
|
|
2184
2184
|
return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e;
|
|
2185
2185
|
}
|
|
2186
2186
|
function Su({ hue: e, saturation: t, lightness: n, alpha: r }) {
|
|
@@ -2190,7 +2190,7 @@ function Su({ hue: e, saturation: t, lightness: n, alpha: r }) {
|
|
|
2190
2190
|
i = o = s = n;
|
|
2191
2191
|
else {
|
|
2192
2192
|
const a = n < 0.5 ? n * (1 + t) : n + t - n * t, l = 2 * n - a;
|
|
2193
|
-
i =
|
|
2193
|
+
i = Pn(l, a, e + 1 / 3), o = Pn(l, a, e), s = Pn(l, a, e - 1 / 3);
|
|
2194
2194
|
}
|
|
2195
2195
|
return {
|
|
2196
2196
|
red: Math.round(i * 255),
|
|
@@ -2199,7 +2199,7 @@ function Su({ hue: e, saturation: t, lightness: n, alpha: r }) {
|
|
|
2199
2199
|
alpha: r
|
|
2200
2200
|
};
|
|
2201
2201
|
}
|
|
2202
|
-
const
|
|
2202
|
+
const An = (e, t, n) => {
|
|
2203
2203
|
const r = e * e;
|
|
2204
2204
|
return Math.sqrt(Math.max(0, n * (t * t - r) + r));
|
|
2205
2205
|
}, Eu = [zn, je, Ge], Tu = (e) => Eu.find((t) => t.test(e));
|
|
@@ -2208,15 +2208,15 @@ function oi(e) {
|
|
|
2208
2208
|
let n = t.parse(e);
|
|
2209
2209
|
return t === Ge && (n = Su(n)), n;
|
|
2210
2210
|
}
|
|
2211
|
-
const
|
|
2211
|
+
const Po = (e, t) => {
|
|
2212
2212
|
const n = oi(e), r = oi(t), i = { ...n };
|
|
2213
|
-
return (o) => (i.red =
|
|
2213
|
+
return (o) => (i.red = An(n.red, r.red, o), i.green = An(n.green, r.green, o), i.blue = An(n.blue, r.blue, o), i.alpha = D(n.alpha, r.alpha, o), je.transform(i));
|
|
2214
2214
|
};
|
|
2215
|
-
function
|
|
2215
|
+
function Pu(e) {
|
|
2216
2216
|
var t, n;
|
|
2217
2217
|
return isNaN(e) && bt(e) && (((t = e.match(ln)) === null || t === void 0 ? void 0 : t.length) || 0) + (((n = e.match(Js)) === null || n === void 0 ? void 0 : n.length) || 0) > 0;
|
|
2218
2218
|
}
|
|
2219
|
-
const
|
|
2219
|
+
const Ao = {
|
|
2220
2220
|
regex: yc,
|
|
2221
2221
|
countKey: "Vars",
|
|
2222
2222
|
token: "${v}",
|
|
@@ -2225,7 +2225,7 @@ const Po = {
|
|
|
2225
2225
|
regex: Js,
|
|
2226
2226
|
countKey: "Colors",
|
|
2227
2227
|
token: "${c}",
|
|
2228
|
-
parse:
|
|
2228
|
+
parse: q.parse
|
|
2229
2229
|
}, Ro = {
|
|
2230
2230
|
regex: ln,
|
|
2231
2231
|
countKey: "Numbers",
|
|
@@ -2245,7 +2245,7 @@ function $t(e) {
|
|
|
2245
2245
|
numColors: 0,
|
|
2246
2246
|
numNumbers: 0
|
|
2247
2247
|
};
|
|
2248
|
-
return n.value.includes("var(--") && Cn(n,
|
|
2248
|
+
return n.value.includes("var(--") && Cn(n, Ao), Cn(n, Co), Cn(n, Ro), n;
|
|
2249
2249
|
}
|
|
2250
2250
|
function Oo(e) {
|
|
2251
2251
|
return $t(e).values;
|
|
@@ -2255,23 +2255,23 @@ function Vo(e) {
|
|
|
2255
2255
|
return (s) => {
|
|
2256
2256
|
let a = i;
|
|
2257
2257
|
for (let l = 0; l < o; l++)
|
|
2258
|
-
l < r ? a = a.replace(
|
|
2258
|
+
l < r ? a = a.replace(Ao.token, s[l]) : l < r + n ? a = a.replace(Co.token, q.transform(s[l])) : a = a.replace(Ro.token, lt(s[l]));
|
|
2259
2259
|
return a;
|
|
2260
2260
|
};
|
|
2261
2261
|
}
|
|
2262
|
-
const
|
|
2262
|
+
const Au = (e) => typeof e == "number" ? 0 : e;
|
|
2263
2263
|
function Cu(e) {
|
|
2264
2264
|
const t = Oo(e);
|
|
2265
|
-
return Vo(e)(t.map(
|
|
2265
|
+
return Vo(e)(t.map(Au));
|
|
2266
2266
|
}
|
|
2267
2267
|
const Ce = {
|
|
2268
|
-
test:
|
|
2268
|
+
test: Pu,
|
|
2269
2269
|
parse: Oo,
|
|
2270
2270
|
createTransformer: Vo,
|
|
2271
2271
|
getAnimatableNone: Cu
|
|
2272
2272
|
}, ko = (e, t) => (n) => `${n > 0 ? t : e}`;
|
|
2273
2273
|
function Mo(e, t) {
|
|
2274
|
-
return typeof e == "number" ? (n) => D(e, t, n) :
|
|
2274
|
+
return typeof e == "number" ? (n) => D(e, t, n) : q.test(e) ? Po(e, t) : e.startsWith("var(") ? ko(e, t) : Do(e, t);
|
|
2275
2275
|
}
|
|
2276
2276
|
const Lo = (e, t) => {
|
|
2277
2277
|
const n = [...e], r = n.length, i = e.map((o, s) => Mo(o, t[s]));
|
|
@@ -2297,7 +2297,7 @@ const Lo = (e, t) => {
|
|
|
2297
2297
|
return r === 0 ? 1 : (n - e) / r;
|
|
2298
2298
|
}, ai = (e, t) => (n) => D(e, t, n);
|
|
2299
2299
|
function Ou(e) {
|
|
2300
|
-
return typeof e == "number" ? ai : typeof e == "string" ?
|
|
2300
|
+
return typeof e == "number" ? ai : typeof e == "string" ? q.test(e) ? Po : Do : Array.isArray(e) ? Lo : typeof e == "object" ? Ru : ai;
|
|
2301
2301
|
}
|
|
2302
2302
|
function Vu(e, t, n) {
|
|
2303
2303
|
const r = [], i = n || Ou(e[0]), o = e.length - 1;
|
|
@@ -2316,15 +2316,15 @@ function jo(e, t, { clamp: n = !0, ease: r, mixer: i } = {}) {
|
|
|
2316
2316
|
if (br(o === t.length), o === 1)
|
|
2317
2317
|
return () => t[0];
|
|
2318
2318
|
e[0] > e[o - 1] && (e = [...e].reverse(), t = [...t].reverse());
|
|
2319
|
-
const s = Vu(t, r, i), a = s.length, l = (
|
|
2319
|
+
const s = Vu(t, r, i), a = s.length, l = (c) => {
|
|
2320
2320
|
let f = 0;
|
|
2321
2321
|
if (a > 1)
|
|
2322
|
-
for (; f < e.length - 2 && !(
|
|
2322
|
+
for (; f < e.length - 2 && !(c < e[f + 1]); f++)
|
|
2323
2323
|
;
|
|
2324
|
-
const
|
|
2325
|
-
return s[f](
|
|
2324
|
+
const u = gt(e[f], e[f + 1], c);
|
|
2325
|
+
return s[f](u);
|
|
2326
2326
|
};
|
|
2327
|
-
return n ? (
|
|
2327
|
+
return n ? (c) => l(Ae(e[0], e[o - 1], c)) : l;
|
|
2328
2328
|
}
|
|
2329
2329
|
function ku(e, t) {
|
|
2330
2330
|
const n = e[e.length - 1];
|
|
@@ -2371,33 +2371,33 @@ function Fo(e, t, n) {
|
|
|
2371
2371
|
const Rn = 1e-3, _u = 0.01, li = 10, Fu = 0.05, Nu = 1;
|
|
2372
2372
|
function Bu({ duration: e = 800, bounce: t = 0.25, velocity: n = 0, mass: r = 1 }) {
|
|
2373
2373
|
let i, o;
|
|
2374
|
-
ou(e <=
|
|
2374
|
+
ou(e <= Pe(li));
|
|
2375
2375
|
let s = 1 - t;
|
|
2376
|
-
s =
|
|
2377
|
-
const f =
|
|
2376
|
+
s = Ae(Fu, Nu, s), e = Ae(_u, li, de(e)), s < 1 ? (i = (c) => {
|
|
2377
|
+
const f = c * s, u = f * e, h = f - n, d = Hn(c, s), p = Math.exp(-u);
|
|
2378
2378
|
return Rn - h / d * p;
|
|
2379
|
-
}, o = (
|
|
2380
|
-
const
|
|
2381
|
-
return (-i(
|
|
2382
|
-
}) : (i = (
|
|
2383
|
-
const f = Math.exp(-
|
|
2384
|
-
return -Rn + f *
|
|
2385
|
-
}, o = (
|
|
2386
|
-
const f = Math.exp(-
|
|
2387
|
-
return f *
|
|
2379
|
+
}, o = (c) => {
|
|
2380
|
+
const u = c * s * e, h = u * n + n, d = Math.pow(s, 2) * Math.pow(c, 2) * e, p = Math.exp(-u), m = Hn(Math.pow(c, 2), s);
|
|
2381
|
+
return (-i(c) + Rn > 0 ? -1 : 1) * ((h - d) * p) / m;
|
|
2382
|
+
}) : (i = (c) => {
|
|
2383
|
+
const f = Math.exp(-c * e), u = (c - n) * e + 1;
|
|
2384
|
+
return -Rn + f * u;
|
|
2385
|
+
}, o = (c) => {
|
|
2386
|
+
const f = Math.exp(-c * e), u = (n - c) * (e * e);
|
|
2387
|
+
return f * u;
|
|
2388
2388
|
});
|
|
2389
2389
|
const a = 5 / e, l = Wu(i, o, a);
|
|
2390
|
-
if (e =
|
|
2390
|
+
if (e = Pe(e), isNaN(l))
|
|
2391
2391
|
return {
|
|
2392
2392
|
stiffness: 100,
|
|
2393
2393
|
damping: 10,
|
|
2394
2394
|
duration: e
|
|
2395
2395
|
};
|
|
2396
2396
|
{
|
|
2397
|
-
const
|
|
2397
|
+
const c = Math.pow(l, 2) * r;
|
|
2398
2398
|
return {
|
|
2399
|
-
stiffness:
|
|
2400
|
-
damping: s * 2 * Math.sqrt(r *
|
|
2399
|
+
stiffness: c,
|
|
2400
|
+
damping: s * 2 * Math.sqrt(r * c),
|
|
2401
2401
|
duration: e
|
|
2402
2402
|
};
|
|
2403
2403
|
}
|
|
@@ -2436,71 +2436,71 @@ function Hu(e) {
|
|
|
2436
2436
|
return t;
|
|
2437
2437
|
}
|
|
2438
2438
|
function No({ keyframes: e, restDelta: t, restSpeed: n, ...r }) {
|
|
2439
|
-
const i = e[0], o = e[e.length - 1], s = { done: !1, value: i }, { stiffness: a, damping: l, mass:
|
|
2439
|
+
const i = e[0], o = e[e.length - 1], s = { done: !1, value: i }, { stiffness: a, damping: l, mass: c, duration: f, velocity: u, isResolvedFromDuration: h } = Hu({
|
|
2440
2440
|
...r,
|
|
2441
2441
|
velocity: -de(r.velocity || 0)
|
|
2442
|
-
}), d =
|
|
2443
|
-
n || (n =
|
|
2444
|
-
let
|
|
2442
|
+
}), d = u || 0, p = l / (2 * Math.sqrt(a * c)), m = o - i, g = de(Math.sqrt(a / c)), v = Math.abs(m) < 5;
|
|
2443
|
+
n || (n = v ? 0.01 : 2), t || (t = v ? 5e-3 : 0.5);
|
|
2444
|
+
let w;
|
|
2445
2445
|
if (p < 1) {
|
|
2446
2446
|
const y = Hn(g, p);
|
|
2447
|
-
|
|
2448
|
-
const
|
|
2449
|
-
return o -
|
|
2447
|
+
w = (S) => {
|
|
2448
|
+
const E = Math.exp(-p * g * S);
|
|
2449
|
+
return o - E * ((d + p * g * m) / y * Math.sin(y * S) + m * Math.cos(y * S));
|
|
2450
2450
|
};
|
|
2451
2451
|
} else if (p === 1)
|
|
2452
|
-
|
|
2452
|
+
w = (y) => o - Math.exp(-g * y) * (m + (d + g * m) * y);
|
|
2453
2453
|
else {
|
|
2454
2454
|
const y = g * Math.sqrt(p * p - 1);
|
|
2455
|
-
|
|
2456
|
-
const
|
|
2457
|
-
return o -
|
|
2455
|
+
w = (S) => {
|
|
2456
|
+
const E = Math.exp(-p * g * S), T = Math.min(y * S, 300);
|
|
2457
|
+
return o - E * ((d + p * g * m) * Math.sinh(T) + y * m * Math.cosh(T)) / y;
|
|
2458
2458
|
};
|
|
2459
2459
|
}
|
|
2460
2460
|
return {
|
|
2461
2461
|
calculatedDuration: h && f || null,
|
|
2462
2462
|
next: (y) => {
|
|
2463
|
-
const S =
|
|
2463
|
+
const S = w(y);
|
|
2464
2464
|
if (h)
|
|
2465
2465
|
s.done = y >= f;
|
|
2466
2466
|
else {
|
|
2467
|
-
let
|
|
2468
|
-
y !== 0 && (p < 1 ?
|
|
2469
|
-
const
|
|
2470
|
-
s.done =
|
|
2467
|
+
let E = d;
|
|
2468
|
+
y !== 0 && (p < 1 ? E = Fo(w, y, S) : E = 0);
|
|
2469
|
+
const T = Math.abs(E) <= n, P = Math.abs(o - S) <= t;
|
|
2470
|
+
s.done = T && P;
|
|
2471
2471
|
}
|
|
2472
2472
|
return s.value = s.done ? o : S, s;
|
|
2473
2473
|
}
|
|
2474
2474
|
};
|
|
2475
2475
|
}
|
|
2476
|
-
function ui({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: r = 325, bounceDamping: i = 10, bounceStiffness: o = 500, modifyTarget: s, min: a, max: l, restDelta:
|
|
2477
|
-
const
|
|
2476
|
+
function ui({ keyframes: e, velocity: t = 0, power: n = 0.8, timeConstant: r = 325, bounceDamping: i = 10, bounceStiffness: o = 500, modifyTarget: s, min: a, max: l, restDelta: c = 0.5, restSpeed: f }) {
|
|
2477
|
+
const u = e[0], h = {
|
|
2478
2478
|
done: !1,
|
|
2479
|
-
value:
|
|
2480
|
-
}, d = (
|
|
2479
|
+
value: u
|
|
2480
|
+
}, d = (A) => a !== void 0 && A < a || l !== void 0 && A > l, p = (A) => a === void 0 ? l : l === void 0 || Math.abs(a - A) < Math.abs(l - A) ? a : l;
|
|
2481
2481
|
let m = n * t;
|
|
2482
|
-
const g =
|
|
2483
|
-
|
|
2484
|
-
const
|
|
2485
|
-
const O =
|
|
2486
|
-
h.done = Math.abs(O) <=
|
|
2482
|
+
const g = u + m, v = s === void 0 ? g : s(g);
|
|
2483
|
+
v !== g && (m = v - u);
|
|
2484
|
+
const w = (A) => -m * Math.exp(-A / r), y = (A) => v + w(A), S = (A) => {
|
|
2485
|
+
const O = w(A), W = y(A);
|
|
2486
|
+
h.done = Math.abs(O) <= c, h.value = h.done ? v : W;
|
|
2487
2487
|
};
|
|
2488
|
-
let
|
|
2489
|
-
const
|
|
2490
|
-
d(h.value) && (
|
|
2488
|
+
let E, T;
|
|
2489
|
+
const P = (A) => {
|
|
2490
|
+
d(h.value) && (E = A, T = No({
|
|
2491
2491
|
keyframes: [h.value, p(h.value)],
|
|
2492
|
-
velocity: Fo(y,
|
|
2492
|
+
velocity: Fo(y, A, h.value),
|
|
2493
2493
|
damping: i,
|
|
2494
2494
|
stiffness: o,
|
|
2495
|
-
restDelta:
|
|
2495
|
+
restDelta: c,
|
|
2496
2496
|
restSpeed: f
|
|
2497
2497
|
}));
|
|
2498
2498
|
};
|
|
2499
|
-
return
|
|
2499
|
+
return P(0), {
|
|
2500
2500
|
calculatedDuration: null,
|
|
2501
|
-
next: (
|
|
2501
|
+
next: (A) => {
|
|
2502
2502
|
let O = !1;
|
|
2503
|
-
return !
|
|
2503
|
+
return !T && E === void 0 && (O = !0, S(A), P(A)), E !== void 0 && A > E ? T.next(A - E) : (!O && S(A), h);
|
|
2504
2504
|
}
|
|
2505
2505
|
};
|
|
2506
2506
|
}
|
|
@@ -2513,7 +2513,7 @@ const $u = (e) => {
|
|
|
2513
2513
|
* If we're processing this frame we can use the
|
|
2514
2514
|
* framelocked timestamp to keep things in sync.
|
|
2515
2515
|
*/
|
|
2516
|
-
now: () =>
|
|
2516
|
+
now: () => $.isProcessing ? $.timestamp : performance.now()
|
|
2517
2517
|
};
|
|
2518
2518
|
}, fi = 2e4;
|
|
2519
2519
|
function hi(e) {
|
|
@@ -2531,63 +2531,63 @@ const qu = {
|
|
|
2531
2531
|
keyframes: qt,
|
|
2532
2532
|
spring: No
|
|
2533
2533
|
};
|
|
2534
|
-
function Gt({ autoplay: e = !0, delay: t = 0, driver: n = $u, keyframes: r, type: i = "keyframes", repeat: o = 0, repeatDelay: s = 0, repeatType: a = "loop", onPlay: l, onStop:
|
|
2534
|
+
function Gt({ autoplay: e = !0, delay: t = 0, driver: n = $u, keyframes: r, type: i = "keyframes", repeat: o = 0, repeatDelay: s = 0, repeatType: a = "loop", onPlay: l, onStop: c, onComplete: f, onUpdate: u, ...h }) {
|
|
2535
2535
|
let d = 1, p = !1, m, g;
|
|
2536
|
-
const
|
|
2536
|
+
const v = () => {
|
|
2537
2537
|
g = new Promise((k) => {
|
|
2538
2538
|
m = k;
|
|
2539
2539
|
});
|
|
2540
2540
|
};
|
|
2541
|
-
|
|
2542
|
-
let
|
|
2541
|
+
v();
|
|
2542
|
+
let w;
|
|
2543
2543
|
const y = qu[i] || qt;
|
|
2544
2544
|
let S;
|
|
2545
2545
|
y !== qt && typeof r[0] != "number" && (S = jo([0, 100], r, {
|
|
2546
2546
|
clamp: !1
|
|
2547
2547
|
}), r = [0, 100]);
|
|
2548
|
-
const
|
|
2549
|
-
let
|
|
2550
|
-
a === "mirror" && (
|
|
2548
|
+
const E = y({ ...h, keyframes: r });
|
|
2549
|
+
let T;
|
|
2550
|
+
a === "mirror" && (T = y({
|
|
2551
2551
|
...h,
|
|
2552
2552
|
keyframes: [...r].reverse(),
|
|
2553
2553
|
velocity: -(h.velocity || 0)
|
|
2554
2554
|
}));
|
|
2555
|
-
let
|
|
2556
|
-
|
|
2557
|
-
const { calculatedDuration:
|
|
2558
|
-
let
|
|
2559
|
-
|
|
2555
|
+
let P = "idle", A = null, O = null, W = null;
|
|
2556
|
+
E.calculatedDuration === null && o && (E.calculatedDuration = hi(E));
|
|
2557
|
+
const { calculatedDuration: K } = E;
|
|
2558
|
+
let N = 1 / 0, H = 1 / 0;
|
|
2559
|
+
K !== null && (N = K + s, H = N * (o + 1) - s);
|
|
2560
2560
|
let U = 0;
|
|
2561
2561
|
const re = (k) => {
|
|
2562
2562
|
if (O === null)
|
|
2563
2563
|
return;
|
|
2564
|
-
d > 0 && (O = Math.min(O, k)), d < 0 && (O = Math.min(k -
|
|
2565
|
-
const Be = U - t * (d >= 0 ? 1 : -1), Ie = d >= 0 ? Be < 0 : Be >
|
|
2566
|
-
U = Math.max(Be, 0),
|
|
2567
|
-
let gn = U, Oe =
|
|
2564
|
+
d > 0 && (O = Math.min(O, k)), d < 0 && (O = Math.min(k - H / d, O)), A !== null ? U = A : U = Math.round(k - O) * d;
|
|
2565
|
+
const Be = U - t * (d >= 0 ? 1 : -1), Ie = d >= 0 ? Be < 0 : Be > H;
|
|
2566
|
+
U = Math.max(Be, 0), P === "finished" && A === null && (U = H);
|
|
2567
|
+
let gn = U, Oe = E;
|
|
2568
2568
|
if (o) {
|
|
2569
|
-
const tt = Math.min(U,
|
|
2569
|
+
const tt = Math.min(U, H) / N;
|
|
2570
2570
|
let Ve = Math.floor(tt), te = tt % 1;
|
|
2571
|
-
!te && tt >= 1 && (te = 1), te === 1 && Ve--, Ve = Math.min(Ve, o + 1), !!(Ve % 2) && (a === "reverse" ? (te = 1 - te, s && (te -= s /
|
|
2571
|
+
!te && tt >= 1 && (te = 1), te === 1 && Ve--, Ve = Math.min(Ve, o + 1), !!(Ve % 2) && (a === "reverse" ? (te = 1 - te, s && (te -= s / N)) : a === "mirror" && (Oe = T)), gn = Ae(0, 1, te) * N;
|
|
2572
2572
|
}
|
|
2573
2573
|
const ue = Ie ? { done: !1, value: r[0] } : Oe.next(gn);
|
|
2574
2574
|
S && (ue.value = S(ue.value));
|
|
2575
2575
|
let { done: We } = ue;
|
|
2576
|
-
!Ie &&
|
|
2577
|
-
const Ue =
|
|
2578
|
-
return
|
|
2579
|
-
},
|
|
2580
|
-
|
|
2576
|
+
!Ie && K !== null && (We = d >= 0 ? U >= H : U <= 0);
|
|
2577
|
+
const Ue = A === null && (P === "finished" || P === "running" && We);
|
|
2578
|
+
return u && u(ue.value), Ue && z(), ue;
|
|
2579
|
+
}, B = () => {
|
|
2580
|
+
w && w.stop(), w = void 0;
|
|
2581
2581
|
}, ie = () => {
|
|
2582
|
-
|
|
2582
|
+
P = "idle", B(), m(), v(), O = W = null;
|
|
2583
2583
|
}, z = () => {
|
|
2584
|
-
|
|
2584
|
+
P = "finished", f && f(), B(), m();
|
|
2585
2585
|
}, ge = () => {
|
|
2586
2586
|
if (p)
|
|
2587
2587
|
return;
|
|
2588
|
-
|
|
2589
|
-
const k =
|
|
2590
|
-
l && l(),
|
|
2588
|
+
w || (w = n(re));
|
|
2589
|
+
const k = w.now();
|
|
2590
|
+
l && l(), A !== null ? O = k - A : (!O || P === "finished") && (O = k), P === "finished" && v(), W = O, A = null, P = "running", w.start();
|
|
2591
2591
|
};
|
|
2592
2592
|
e && ge();
|
|
2593
2593
|
const Ne = {
|
|
@@ -2598,33 +2598,33 @@ function Gt({ autoplay: e = !0, delay: t = 0, driver: n = $u, keyframes: r, type
|
|
|
2598
2598
|
return de(U);
|
|
2599
2599
|
},
|
|
2600
2600
|
set time(k) {
|
|
2601
|
-
k =
|
|
2601
|
+
k = Pe(k), U = k, A !== null || !w || d === 0 ? A = k : O = w.now() - k / d;
|
|
2602
2602
|
},
|
|
2603
2603
|
get duration() {
|
|
2604
|
-
const k =
|
|
2604
|
+
const k = E.calculatedDuration === null ? hi(E) : E.calculatedDuration;
|
|
2605
2605
|
return de(k);
|
|
2606
2606
|
},
|
|
2607
2607
|
get speed() {
|
|
2608
2608
|
return d;
|
|
2609
2609
|
},
|
|
2610
2610
|
set speed(k) {
|
|
2611
|
-
k === d || !
|
|
2611
|
+
k === d || !w || (d = k, Ne.time = de(U));
|
|
2612
2612
|
},
|
|
2613
2613
|
get state() {
|
|
2614
|
-
return
|
|
2614
|
+
return P;
|
|
2615
2615
|
},
|
|
2616
2616
|
play: ge,
|
|
2617
2617
|
pause: () => {
|
|
2618
|
-
|
|
2618
|
+
P = "paused", A = U;
|
|
2619
2619
|
},
|
|
2620
2620
|
stop: () => {
|
|
2621
|
-
p = !0,
|
|
2621
|
+
p = !0, P !== "idle" && (P = "idle", c && c(), ie());
|
|
2622
2622
|
},
|
|
2623
2623
|
cancel: () => {
|
|
2624
|
-
|
|
2624
|
+
W !== null && re(W), ie();
|
|
2625
2625
|
},
|
|
2626
2626
|
complete: () => {
|
|
2627
|
-
|
|
2627
|
+
P = "finished";
|
|
2628
2628
|
},
|
|
2629
2629
|
sample: (k) => (O = 0, re(k))
|
|
2630
2630
|
};
|
|
@@ -2644,28 +2644,28 @@ const Xu = Gu(() => Object.hasOwnProperty.call(Element.prototype, "animate")), K
|
|
|
2644
2644
|
function Zu(e, t, { onUpdate: n, onComplete: r, ...i }) {
|
|
2645
2645
|
if (!(Xu() && Ku.has(t) && !i.repeatDelay && i.repeatType !== "mirror" && i.damping !== 0 && i.type !== "inertia"))
|
|
2646
2646
|
return !1;
|
|
2647
|
-
let s = !1, a, l,
|
|
2647
|
+
let s = !1, a, l, c = !1;
|
|
2648
2648
|
const f = () => {
|
|
2649
2649
|
l = new Promise((y) => {
|
|
2650
2650
|
a = y;
|
|
2651
2651
|
});
|
|
2652
2652
|
};
|
|
2653
2653
|
f();
|
|
2654
|
-
let { keyframes:
|
|
2654
|
+
let { keyframes: u, duration: h = 300, ease: d, times: p } = i;
|
|
2655
2655
|
if (Ju(t, i)) {
|
|
2656
2656
|
const y = Gt({
|
|
2657
2657
|
...i,
|
|
2658
2658
|
repeat: 0,
|
|
2659
2659
|
delay: 0
|
|
2660
2660
|
});
|
|
2661
|
-
let S = { done: !1, value:
|
|
2662
|
-
const
|
|
2663
|
-
let
|
|
2664
|
-
for (; !S.done &&
|
|
2665
|
-
S = y.sample(
|
|
2666
|
-
p = void 0,
|
|
2667
|
-
}
|
|
2668
|
-
const m = lu(e.owner.current, t,
|
|
2661
|
+
let S = { done: !1, value: u[0] };
|
|
2662
|
+
const E = [];
|
|
2663
|
+
let T = 0;
|
|
2664
|
+
for (; !S.done && T < Yu; )
|
|
2665
|
+
S = y.sample(T), E.push(S.value), T += Rt;
|
|
2666
|
+
p = void 0, u = E, h = T - Rt, d = "linear";
|
|
2667
|
+
}
|
|
2668
|
+
const m = lu(e.owner.current, t, u, {
|
|
2669
2669
|
...i,
|
|
2670
2670
|
duration: h,
|
|
2671
2671
|
/**
|
|
@@ -2679,12 +2679,12 @@ function Zu(e, t, { onUpdate: n, onComplete: r, ...i }) {
|
|
|
2679
2679
|
ease: d,
|
|
2680
2680
|
times: p
|
|
2681
2681
|
}), g = () => {
|
|
2682
|
-
|
|
2683
|
-
},
|
|
2684
|
-
|
|
2682
|
+
c = !1, m.cancel();
|
|
2683
|
+
}, v = () => {
|
|
2684
|
+
c = !0, M.update(g), a(), f();
|
|
2685
2685
|
};
|
|
2686
2686
|
return m.onfinish = () => {
|
|
2687
|
-
|
|
2687
|
+
c || (e.set(cu(u, i)), r && r(), v());
|
|
2688
2688
|
}, {
|
|
2689
2689
|
then(y, S) {
|
|
2690
2690
|
return l.then(y, S);
|
|
@@ -2696,7 +2696,7 @@ function Zu(e, t, { onUpdate: n, onComplete: r, ...i }) {
|
|
|
2696
2696
|
return de(m.currentTime || 0);
|
|
2697
2697
|
},
|
|
2698
2698
|
set time(y) {
|
|
2699
|
-
m.currentTime =
|
|
2699
|
+
m.currentTime = Pe(y);
|
|
2700
2700
|
},
|
|
2701
2701
|
get speed() {
|
|
2702
2702
|
return m.playbackRate;
|
|
@@ -2722,12 +2722,12 @@ function Zu(e, t, { onUpdate: n, onComplete: r, ...i }) {
|
|
|
2722
2722
|
});
|
|
2723
2723
|
e.setWithVelocity(S.sample(y - Rt).value, S.sample(y).value, Rt);
|
|
2724
2724
|
}
|
|
2725
|
-
|
|
2725
|
+
v();
|
|
2726
2726
|
},
|
|
2727
2727
|
complete: () => {
|
|
2728
|
-
|
|
2728
|
+
c || m.finish();
|
|
2729
2729
|
},
|
|
2730
|
-
cancel:
|
|
2730
|
+
cancel: v
|
|
2731
2731
|
};
|
|
2732
2732
|
}
|
|
2733
2733
|
function Qu({ keyframes: e, delay: t, onUpdate: n, onComplete: r }) {
|
|
@@ -2789,17 +2789,17 @@ const lf = /([a-z-]*)\(.*?\)/g, qn = {
|
|
|
2789
2789
|
}, cf = {
|
|
2790
2790
|
...Zs,
|
|
2791
2791
|
// Color props
|
|
2792
|
-
color:
|
|
2793
|
-
backgroundColor:
|
|
2794
|
-
outlineColor:
|
|
2795
|
-
fill:
|
|
2796
|
-
stroke:
|
|
2792
|
+
color: q,
|
|
2793
|
+
backgroundColor: q,
|
|
2794
|
+
outlineColor: q,
|
|
2795
|
+
fill: q,
|
|
2796
|
+
stroke: q,
|
|
2797
2797
|
// Border props
|
|
2798
|
-
borderColor:
|
|
2799
|
-
borderTopColor:
|
|
2800
|
-
borderRightColor:
|
|
2801
|
-
borderBottomColor:
|
|
2802
|
-
borderLeftColor:
|
|
2798
|
+
borderColor: q,
|
|
2799
|
+
borderTopColor: q,
|
|
2800
|
+
borderRightColor: q,
|
|
2801
|
+
borderBottomColor: q,
|
|
2802
|
+
borderLeftColor: q,
|
|
2803
2803
|
filter: qn,
|
|
2804
2804
|
WebkitFilter: qn
|
|
2805
2805
|
}, Er = (e) => cf[e];
|
|
@@ -2821,16 +2821,16 @@ function ff(e, t, n, r) {
|
|
|
2821
2821
|
const s = r.from !== void 0 ? r.from : e.get();
|
|
2822
2822
|
let a;
|
|
2823
2823
|
const l = [];
|
|
2824
|
-
for (let
|
|
2825
|
-
o[
|
|
2824
|
+
for (let c = 0; c < o.length; c++)
|
|
2825
|
+
o[c] === null && (o[c] = c === 0 ? s : o[c - 1]), uf(o[c]) && l.push(c), typeof o[c] == "string" && o[c] !== "none" && o[c] !== "0" && (a = o[c]);
|
|
2826
2826
|
if (i && l.length && a)
|
|
2827
|
-
for (let
|
|
2828
|
-
const f = l[
|
|
2827
|
+
for (let c = 0; c < l.length; c++) {
|
|
2828
|
+
const f = l[c];
|
|
2829
2829
|
o[f] = Bo(t, a);
|
|
2830
2830
|
}
|
|
2831
2831
|
return o;
|
|
2832
2832
|
}
|
|
2833
|
-
function hf({ when: e, delay: t, delayChildren: n, staggerChildren: r, staggerDirection: i, repeat: o, repeatType: s, repeatDelay: a, from: l, elapsed:
|
|
2833
|
+
function hf({ when: e, delay: t, delayChildren: n, staggerChildren: r, staggerDirection: i, repeat: o, repeatType: s, repeatDelay: a, from: l, elapsed: c, ...f }) {
|
|
2834
2834
|
return !!Object.keys(f).length;
|
|
2835
2835
|
}
|
|
2836
2836
|
function Tr(e, t) {
|
|
@@ -2838,11 +2838,11 @@ function Tr(e, t) {
|
|
|
2838
2838
|
}
|
|
2839
2839
|
const df = {
|
|
2840
2840
|
skipAnimations: !1
|
|
2841
|
-
},
|
|
2841
|
+
}, Pr = (e, t, n, r = {}) => (i) => {
|
|
2842
2842
|
const o = Tr(r, e) || {}, s = o.delay || r.delay || 0;
|
|
2843
2843
|
let { elapsed: a = 0 } = r;
|
|
2844
|
-
a = a -
|
|
2845
|
-
const l = ff(t, e, n, o),
|
|
2844
|
+
a = a - Pe(s);
|
|
2845
|
+
const l = ff(t, e, n, o), c = l[0], f = l[l.length - 1], u = $n(e, c), h = $n(e, f);
|
|
2846
2846
|
let d = {
|
|
2847
2847
|
keyframes: l,
|
|
2848
2848
|
velocity: t.getVelocity(),
|
|
@@ -2859,7 +2859,7 @@ const df = {
|
|
|
2859
2859
|
if (hf(o) || (d = {
|
|
2860
2860
|
...d,
|
|
2861
2861
|
...sf(e, d)
|
|
2862
|
-
}), d.duration && (d.duration =
|
|
2862
|
+
}), d.duration && (d.duration = Pe(d.duration)), d.repeatDelay && (d.repeatDelay = Pe(d.repeatDelay)), !u || !h || au.current || o.type === !1 || df.skipAnimations)
|
|
2863
2863
|
return Qu(d);
|
|
2864
2864
|
if (
|
|
2865
2865
|
/**
|
|
@@ -2880,10 +2880,10 @@ const df = {
|
|
|
2880
2880
|
return Gt(d);
|
|
2881
2881
|
};
|
|
2882
2882
|
function Xt(e) {
|
|
2883
|
-
return !!(
|
|
2883
|
+
return !!(X(e) && e.add);
|
|
2884
2884
|
}
|
|
2885
2885
|
const Wo = (e) => /^\-?\d*\.?\d+$/.test(e);
|
|
2886
|
-
function
|
|
2886
|
+
function Ar(e, t) {
|
|
2887
2887
|
e.indexOf(t) === -1 && e.push(t);
|
|
2888
2888
|
}
|
|
2889
2889
|
function Cr(e, t) {
|
|
@@ -2895,7 +2895,7 @@ class Rr {
|
|
|
2895
2895
|
this.subscriptions = [];
|
|
2896
2896
|
}
|
|
2897
2897
|
add(t) {
|
|
2898
|
-
return
|
|
2898
|
+
return Ar(this.subscriptions, t), () => Cr(this.subscriptions, t);
|
|
2899
2899
|
}
|
|
2900
2900
|
notify(t, n, r) {
|
|
2901
2901
|
const i = this.subscriptions.length;
|
|
@@ -2928,7 +2928,7 @@ class mf {
|
|
|
2928
2928
|
constructor(t, n = {}) {
|
|
2929
2929
|
this.version = "10.18.0", this.timeDelta = 0, this.lastUpdated = 0, this.canTrackVelocity = !1, this.events = {}, this.updateAndNotify = (r, i = !0) => {
|
|
2930
2930
|
this.prev = this.current, this.current = r;
|
|
2931
|
-
const { delta: o, timestamp: s } =
|
|
2931
|
+
const { delta: o, timestamp: s } = $;
|
|
2932
2932
|
this.lastUpdated !== s && (this.timeDelta = o, this.lastUpdated = s, M.postRender(this.scheduleVelocityCheck)), this.prev !== this.current && this.events.change && this.events.change.notify(this.current), this.events.velocityChange && this.events.velocityChange.notify(this.getVelocity()), i && this.events.renderRequest && this.events.renderRequest.notify(this.current);
|
|
2933
2933
|
}, this.scheduleVelocityCheck = () => M.postRender(this.velocityCheck), this.velocityCheck = ({ timestamp: r }) => {
|
|
2934
2934
|
r !== this.lastUpdated && (this.prev = this.current, this.events.velocityChange && this.events.velocityChange.notify(this.getVelocity()));
|
|
@@ -3112,7 +3112,7 @@ function Ye(e, t) {
|
|
|
3112
3112
|
const Uo = (e) => (t) => t.test(e), gf = {
|
|
3113
3113
|
test: (e) => e === "auto",
|
|
3114
3114
|
parse: (e) => e
|
|
3115
|
-
}, zo = [Fe, C, le, we, wc, xc, gf], rt = (e) => zo.find(Uo(e)), yf = [...zo,
|
|
3115
|
+
}, zo = [Fe, C, le, we, wc, xc, gf], rt = (e) => zo.find(Uo(e)), yf = [...zo, q, Ce], vf = (e) => yf.find(Uo(e));
|
|
3116
3116
|
function bf(e, t, n) {
|
|
3117
3117
|
e.hasValue(t) ? e.getValue(t).set(n) : e.addValue(t, Ye(n));
|
|
3118
3118
|
}
|
|
@@ -3130,9 +3130,9 @@ function wf(e, t, n) {
|
|
|
3130
3130
|
const o = Object.keys(t).filter((a) => !e.hasValue(a)), s = o.length;
|
|
3131
3131
|
if (s)
|
|
3132
3132
|
for (let a = 0; a < s; a++) {
|
|
3133
|
-
const l = o[a],
|
|
3133
|
+
const l = o[a], c = t[l];
|
|
3134
3134
|
let f = null;
|
|
3135
|
-
Array.isArray(
|
|
3135
|
+
Array.isArray(c) && (f = c[0]), f === null && (f = (i = (r = n[l]) !== null && r !== void 0 ? r : e.readValue(l)) !== null && i !== void 0 ? i : t[l]), f != null && (typeof f == "string" && (Wo(f) || Io(f)) ? f = parseFloat(f) : !vf(f) && Ce.test(c) && (f = Bo(l, c)), e.addValue(l, Ye(f, { owner: e })), n[l] === void 0 && (n[l] = f), f !== null && e.setBaseTarget(l, f));
|
|
3136
3136
|
}
|
|
3137
3137
|
}
|
|
3138
3138
|
function Sf(e, t) {
|
|
@@ -3155,7 +3155,7 @@ function Tf({ protectedKeys: e, needsAnimating: t }, n) {
|
|
|
3155
3155
|
const r = e.hasOwnProperty(n) && t[n] !== !0;
|
|
3156
3156
|
return t[n] = !1, r;
|
|
3157
3157
|
}
|
|
3158
|
-
function
|
|
3158
|
+
function Pf(e, t) {
|
|
3159
3159
|
const n = e.get();
|
|
3160
3160
|
if (Array.isArray(t)) {
|
|
3161
3161
|
for (let r = 0; r < t.length; r++)
|
|
@@ -3168,55 +3168,55 @@ function Ho(e, t, { delay: n = 0, transitionOverride: r, type: i } = {}) {
|
|
|
3168
3168
|
let { transition: o = e.getDefaultTransition(), transitionEnd: s, ...a } = e.makeTargetAnimatable(t);
|
|
3169
3169
|
const l = e.getValue("willChange");
|
|
3170
3170
|
r && (o = r);
|
|
3171
|
-
const
|
|
3172
|
-
for (const
|
|
3173
|
-
const h = e.getValue(
|
|
3174
|
-
if (!h || d === void 0 || f && Tf(f,
|
|
3171
|
+
const c = [], f = i && e.animationState && e.animationState.getState()[i];
|
|
3172
|
+
for (const u in a) {
|
|
3173
|
+
const h = e.getValue(u), d = a[u];
|
|
3174
|
+
if (!h || d === void 0 || f && Tf(f, u))
|
|
3175
3175
|
continue;
|
|
3176
3176
|
const p = {
|
|
3177
3177
|
delay: n,
|
|
3178
3178
|
elapsed: 0,
|
|
3179
|
-
...Tr(o || {},
|
|
3179
|
+
...Tr(o || {}, u)
|
|
3180
3180
|
};
|
|
3181
3181
|
if (window.HandoffAppearAnimations) {
|
|
3182
|
-
const
|
|
3183
|
-
if (
|
|
3184
|
-
const
|
|
3185
|
-
|
|
3182
|
+
const v = e.getProps()[Hs];
|
|
3183
|
+
if (v) {
|
|
3184
|
+
const w = window.HandoffAppearAnimations(v, u, h, M);
|
|
3185
|
+
w !== null && (p.elapsed = w, p.isHandoff = !0);
|
|
3186
3186
|
}
|
|
3187
3187
|
}
|
|
3188
|
-
let m = !p.isHandoff && !
|
|
3188
|
+
let m = !p.isHandoff && !Pf(h, d);
|
|
3189
3189
|
if (p.type === "spring" && (h.getVelocity() || p.velocity) && (m = !1), h.animation && (m = !1), m)
|
|
3190
3190
|
continue;
|
|
3191
|
-
h.start(
|
|
3191
|
+
h.start(Pr(u, h, d, e.shouldReduceMotion && _e.has(u) ? { type: !1 } : p));
|
|
3192
3192
|
const g = h.animation;
|
|
3193
|
-
Xt(l) && (l.add(
|
|
3193
|
+
Xt(l) && (l.add(u), g.then(() => l.remove(u))), c.push(g);
|
|
3194
3194
|
}
|
|
3195
|
-
return s && Promise.all(
|
|
3195
|
+
return s && Promise.all(c).then(() => {
|
|
3196
3196
|
s && xf(e, s);
|
|
3197
|
-
}),
|
|
3197
|
+
}), c;
|
|
3198
3198
|
}
|
|
3199
3199
|
function Gn(e, t, n = {}) {
|
|
3200
3200
|
const r = un(e, t, n.custom);
|
|
3201
3201
|
let { transition: i = e.getDefaultTransition() || {} } = r || {};
|
|
3202
3202
|
n.transitionOverride && (i = n.transitionOverride);
|
|
3203
3203
|
const o = r ? () => Promise.all(Ho(e, r, n)) : () => Promise.resolve(), s = e.variantChildren && e.variantChildren.size ? (l = 0) => {
|
|
3204
|
-
const { delayChildren:
|
|
3205
|
-
return
|
|
3204
|
+
const { delayChildren: c = 0, staggerChildren: f, staggerDirection: u } = i;
|
|
3205
|
+
return Af(e, t, c + l, f, u, n);
|
|
3206
3206
|
} : () => Promise.resolve(), { when: a } = i;
|
|
3207
3207
|
if (a) {
|
|
3208
|
-
const [l,
|
|
3209
|
-
return l().then(() =>
|
|
3208
|
+
const [l, c] = a === "beforeChildren" ? [o, s] : [s, o];
|
|
3209
|
+
return l().then(() => c());
|
|
3210
3210
|
} else
|
|
3211
3211
|
return Promise.all([o(), s(n.delay)]);
|
|
3212
3212
|
}
|
|
3213
|
-
function
|
|
3214
|
-
const s = [], a = (e.variantChildren.size - 1) * r, l = i === 1 ? (
|
|
3215
|
-
return Array.from(e.variantChildren).sort(Cf).forEach((
|
|
3216
|
-
|
|
3213
|
+
function Af(e, t, n = 0, r = 0, i = 1, o) {
|
|
3214
|
+
const s = [], a = (e.variantChildren.size - 1) * r, l = i === 1 ? (c = 0) => c * r : (c = 0) => a - c * r;
|
|
3215
|
+
return Array.from(e.variantChildren).sort(Cf).forEach((c, f) => {
|
|
3216
|
+
c.notify("AnimationStart", t), s.push(Gn(c, t, {
|
|
3217
3217
|
...o,
|
|
3218
3218
|
delay: n + l(f)
|
|
3219
|
-
}).then(() =>
|
|
3219
|
+
}).then(() => c.notify("AnimationComplete", t)));
|
|
3220
3220
|
}), Promise.all(s);
|
|
3221
3221
|
}
|
|
3222
3222
|
function Cf(e, t) {
|
|
@@ -3244,10 +3244,10 @@ function Mf(e) {
|
|
|
3244
3244
|
let t = kf(e);
|
|
3245
3245
|
const n = Df();
|
|
3246
3246
|
let r = !0;
|
|
3247
|
-
const i = (l,
|
|
3248
|
-
const f = un(e,
|
|
3247
|
+
const i = (l, c) => {
|
|
3248
|
+
const f = un(e, c);
|
|
3249
3249
|
if (f) {
|
|
3250
|
-
const { transition:
|
|
3250
|
+
const { transition: u, transitionEnd: h, ...d } = f;
|
|
3251
3251
|
l = { ...l, ...d, ...h };
|
|
3252
3252
|
}
|
|
3253
3253
|
return l;
|
|
@@ -3255,60 +3255,60 @@ function Mf(e) {
|
|
|
3255
3255
|
function o(l) {
|
|
3256
3256
|
t = l(e);
|
|
3257
3257
|
}
|
|
3258
|
-
function s(l,
|
|
3259
|
-
const f = e.getProps(),
|
|
3258
|
+
function s(l, c) {
|
|
3259
|
+
const f = e.getProps(), u = e.getVariantContext(!0) || {}, h = [], d = /* @__PURE__ */ new Set();
|
|
3260
3260
|
let p = {}, m = 1 / 0;
|
|
3261
|
-
for (let
|
|
3262
|
-
const
|
|
3263
|
-
|
|
3264
|
-
let
|
|
3265
|
-
if (
|
|
3266
|
-
!y.isActive &&
|
|
3261
|
+
for (let v = 0; v < Vf; v++) {
|
|
3262
|
+
const w = Of[v], y = n[w], S = f[w] !== void 0 ? f[w] : u[w], E = pt(S), T = w === c ? y.isActive : null;
|
|
3263
|
+
T === !1 && (m = v);
|
|
3264
|
+
let P = S === u[w] && S !== f[w] && E;
|
|
3265
|
+
if (P && r && e.manuallyAnimateOnMount && (P = !1), y.protectedKeys = { ...p }, // If it isn't active and hasn't *just* been set as inactive
|
|
3266
|
+
!y.isActive && T === null || // If we didn't and don't have any defined prop for this animation type
|
|
3267
3267
|
!S && !y.prevProp || // Or if the prop doesn't define an animation
|
|
3268
3268
|
on(S) || typeof S == "boolean")
|
|
3269
3269
|
continue;
|
|
3270
3270
|
let O = Lf(y.prevProp, S) || // If we're making this variant active, we want to always make it active
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
const
|
|
3274
|
-
let
|
|
3275
|
-
|
|
3276
|
-
const { prevResolvedValues:
|
|
3277
|
-
|
|
3278
|
-
...
|
|
3279
|
-
}, re = (
|
|
3280
|
-
O = !0, d.has(
|
|
3271
|
+
w === c && y.isActive && !P && E || // If we removed a higher-priority variant (i is in reverse order)
|
|
3272
|
+
v > m && E, W = !1;
|
|
3273
|
+
const K = Array.isArray(S) ? S : [S];
|
|
3274
|
+
let N = K.reduce(i, {});
|
|
3275
|
+
T === !1 && (N = {});
|
|
3276
|
+
const { prevResolvedValues: H = {} } = y, U = {
|
|
3277
|
+
...H,
|
|
3278
|
+
...N
|
|
3279
|
+
}, re = (B) => {
|
|
3280
|
+
O = !0, d.has(B) && (W = !0, d.delete(B)), y.needsAnimating[B] = !0;
|
|
3281
3281
|
};
|
|
3282
|
-
for (const
|
|
3283
|
-
const ie = B
|
|
3284
|
-
if (p.hasOwnProperty(
|
|
3282
|
+
for (const B in U) {
|
|
3283
|
+
const ie = N[B], z = H[B];
|
|
3284
|
+
if (p.hasOwnProperty(B))
|
|
3285
3285
|
continue;
|
|
3286
3286
|
let ge = !1;
|
|
3287
|
-
Ht(ie) && Ht(z) ? ge = !ho(ie, z) : ge = ie !== z, ge ? ie !== void 0 ? re(
|
|
3287
|
+
Ht(ie) && Ht(z) ? ge = !ho(ie, z) : ge = ie !== z, ge ? ie !== void 0 ? re(B) : d.add(B) : ie !== void 0 && d.has(B) ? re(B) : y.protectedKeys[B] = !0;
|
|
3288
3288
|
}
|
|
3289
|
-
y.prevProp = S, y.prevResolvedValues =
|
|
3290
|
-
animation:
|
|
3291
|
-
options: { type:
|
|
3289
|
+
y.prevProp = S, y.prevResolvedValues = N, y.isActive && (p = { ...p, ...N }), r && e.blockInitialAnimation && (O = !1), O && (!P || W) && h.push(...K.map((B) => ({
|
|
3290
|
+
animation: B,
|
|
3291
|
+
options: { type: w, ...l }
|
|
3292
3292
|
})));
|
|
3293
3293
|
}
|
|
3294
3294
|
if (d.size) {
|
|
3295
|
-
const
|
|
3296
|
-
d.forEach((
|
|
3297
|
-
const y = e.getBaseTarget(
|
|
3298
|
-
y !== void 0 && (
|
|
3299
|
-
}), h.push({ animation:
|
|
3295
|
+
const v = {};
|
|
3296
|
+
d.forEach((w) => {
|
|
3297
|
+
const y = e.getBaseTarget(w);
|
|
3298
|
+
y !== void 0 && (v[w] = y);
|
|
3299
|
+
}), h.push({ animation: v });
|
|
3300
3300
|
}
|
|
3301
3301
|
let g = !!h.length;
|
|
3302
3302
|
return r && (f.initial === !1 || f.initial === f.animate) && !e.manuallyAnimateOnMount && (g = !1), r = !1, g ? t(h) : Promise.resolve();
|
|
3303
3303
|
}
|
|
3304
|
-
function a(l,
|
|
3305
|
-
var
|
|
3306
|
-
if (n[l].isActive ===
|
|
3304
|
+
function a(l, c, f) {
|
|
3305
|
+
var u;
|
|
3306
|
+
if (n[l].isActive === c)
|
|
3307
3307
|
return Promise.resolve();
|
|
3308
|
-
(
|
|
3308
|
+
(u = e.variantChildren) === null || u === void 0 || u.forEach((d) => {
|
|
3309
3309
|
var p;
|
|
3310
|
-
return (p = d.animationState) === null || p === void 0 ? void 0 : p.setActive(l,
|
|
3311
|
-
}), n[l].isActive =
|
|
3310
|
+
return (p = d.animationState) === null || p === void 0 ? void 0 : p.setActive(l, c);
|
|
3311
|
+
}), n[l].isActive = c;
|
|
3312
3312
|
const h = s(f, l);
|
|
3313
3313
|
for (const d in n)
|
|
3314
3314
|
n[d].protectedKeys = {};
|
|
@@ -3407,27 +3407,27 @@ class $o {
|
|
|
3407
3407
|
if (this.startEvent = null, this.lastMoveEvent = null, this.lastMoveEventInfo = null, this.handlers = {}, this.contextWindow = window, this.updatePoint = () => {
|
|
3408
3408
|
if (!(this.lastMoveEvent && this.lastMoveEventInfo))
|
|
3409
3409
|
return;
|
|
3410
|
-
const
|
|
3410
|
+
const u = Vn(this.lastMoveEventInfo, this.history), h = this.startEvent !== null, d = Bf(u.offset, { x: 0, y: 0 }) >= 3;
|
|
3411
3411
|
if (!h && !d)
|
|
3412
3412
|
return;
|
|
3413
|
-
const { point: p } =
|
|
3413
|
+
const { point: p } = u, { timestamp: m } = $;
|
|
3414
3414
|
this.history.push({ ...p, timestamp: m });
|
|
3415
|
-
const { onStart: g, onMove:
|
|
3416
|
-
h || (g && g(this.lastMoveEvent,
|
|
3417
|
-
}, this.handlePointerMove = (
|
|
3418
|
-
this.lastMoveEvent =
|
|
3419
|
-
}, this.handlePointerUp = (
|
|
3415
|
+
const { onStart: g, onMove: v } = this.handlers;
|
|
3416
|
+
h || (g && g(this.lastMoveEvent, u), this.startEvent = this.lastMoveEvent), v && v(this.lastMoveEvent, u);
|
|
3417
|
+
}, this.handlePointerMove = (u, h) => {
|
|
3418
|
+
this.lastMoveEvent = u, this.lastMoveEventInfo = On(h, this.transformPagePoint), M.update(this.updatePoint, !0);
|
|
3419
|
+
}, this.handlePointerUp = (u, h) => {
|
|
3420
3420
|
this.end();
|
|
3421
3421
|
const { onEnd: d, onSessionEnd: p, resumeAnimation: m } = this.handlers;
|
|
3422
3422
|
if (this.dragSnapToOrigin && m && m(), !(this.lastMoveEvent && this.lastMoveEventInfo))
|
|
3423
3423
|
return;
|
|
3424
|
-
const g = Vn(
|
|
3425
|
-
this.startEvent && d && d(
|
|
3424
|
+
const g = Vn(u.type === "pointercancel" ? this.lastMoveEventInfo : On(h, this.transformPagePoint), this.history);
|
|
3425
|
+
this.startEvent && d && d(u, g), p && p(u, g);
|
|
3426
3426
|
}, !ao(t))
|
|
3427
3427
|
return;
|
|
3428
3428
|
this.dragSnapToOrigin = o, this.handlers = n, this.transformPagePoint = r, this.contextWindow = i || window;
|
|
3429
|
-
const s = cn(t), a = On(s, this.transformPagePoint), { point: l } = a, { timestamp:
|
|
3430
|
-
this.history = [{ ...l, timestamp:
|
|
3429
|
+
const s = cn(t), a = On(s, this.transformPagePoint), { point: l } = a, { timestamp: c } = $;
|
|
3430
|
+
this.history = [{ ...l, timestamp: c }];
|
|
3431
3431
|
const { onSessionStart: f } = n;
|
|
3432
3432
|
f && f(t, Vn(a, this.history)), this.removeListeners = Te(he(this.contextWindow, "pointermove", this.handlePointerMove), he(this.contextWindow, "pointerup", this.handlePointerUp), he(this.contextWindow, "pointercancel", this.handlePointerUp));
|
|
3433
3433
|
}
|
|
@@ -3463,7 +3463,7 @@ function Wf(e, t) {
|
|
|
3463
3463
|
return { x: 0, y: 0 };
|
|
3464
3464
|
let n = e.length - 1, r = null;
|
|
3465
3465
|
const i = qo(e);
|
|
3466
|
-
for (; n >= 0 && (r = e[n], !(i.timestamp - r.timestamp >
|
|
3466
|
+
for (; n >= 0 && (r = e[n], !(i.timestamp - r.timestamp > Pe(t))); )
|
|
3467
3467
|
n--;
|
|
3468
3468
|
if (!r)
|
|
3469
3469
|
return { x: 0, y: 0 };
|
|
@@ -3528,7 +3528,7 @@ function $f(e, t) {
|
|
|
3528
3528
|
function qf(e, t) {
|
|
3529
3529
|
let n = 0.5;
|
|
3530
3530
|
const r = J(e), i = J(t);
|
|
3531
|
-
return i > r ? n = gt(t.min, t.max - r, e.min) : r > i && (n = gt(e.min, e.max - i, t.min)),
|
|
3531
|
+
return i > r ? n = gt(t.min, t.max - r, e.min) : r > i && (n = gt(e.min, e.max - i, t.min)), Ae(0, 1, n);
|
|
3532
3532
|
}
|
|
3533
3533
|
function Gf(e, t) {
|
|
3534
3534
|
const n = {};
|
|
@@ -3558,7 +3558,7 @@ const Si = () => ({
|
|
|
3558
3558
|
}), Xe = () => ({
|
|
3559
3559
|
x: Si(),
|
|
3560
3560
|
y: Si()
|
|
3561
|
-
}), Ei = () => ({ min: 0, max: 0 }),
|
|
3561
|
+
}), Ei = () => ({ min: 0, max: 0 }), _ = () => ({
|
|
3562
3562
|
x: Ei(),
|
|
3563
3563
|
y: Ei()
|
|
3564
3564
|
});
|
|
@@ -3604,11 +3604,11 @@ function Kt(e, t, n) {
|
|
|
3604
3604
|
const r = e - n, i = t * r;
|
|
3605
3605
|
return n + i;
|
|
3606
3606
|
}
|
|
3607
|
-
function
|
|
3607
|
+
function Pi(e, t, n, r, i) {
|
|
3608
3608
|
return i !== void 0 && (e = Kt(e, i, r)), Kt(e, n, r) + t;
|
|
3609
3609
|
}
|
|
3610
3610
|
function Jn(e, t = 0, n = 1, r, i) {
|
|
3611
|
-
e.min =
|
|
3611
|
+
e.min = Pi(e.min, t, n, r, i), e.max = Pi(e.max, t, n, r, i);
|
|
3612
3612
|
}
|
|
3613
3613
|
function Ko(e, { x: t, y: n }) {
|
|
3614
3614
|
Jn(e.x, t.translate, t.scale, t.originPoint), Jn(e.y, n.translate, n.scale, n.originPoint);
|
|
@@ -3627,9 +3627,9 @@ function Jf(e, t, n, r = !1) {
|
|
|
3627
3627
|
y: -o.scroll.offset.y
|
|
3628
3628
|
}), s && (t.x *= s.x.scale, t.y *= s.y.scale, Ko(e, s)), r && Me(o.latestValues) && Ke(e, o.latestValues));
|
|
3629
3629
|
}
|
|
3630
|
-
t.x =
|
|
3630
|
+
t.x = Ai(t.x), t.y = Ai(t.y);
|
|
3631
3631
|
}
|
|
3632
|
-
function
|
|
3632
|
+
function Ai(e) {
|
|
3633
3633
|
return Number.isInteger(e) || e > 1.0000000000001 || e < 0.999999999999 ? e : 1;
|
|
3634
3634
|
}
|
|
3635
3635
|
function Se(e, t) {
|
|
@@ -3653,46 +3653,46 @@ function eh(e, t, n) {
|
|
|
3653
3653
|
const Jo = ({ current: e }) => e ? e.ownerDocument.defaultView : null, th = /* @__PURE__ */ new WeakMap();
|
|
3654
3654
|
class nh {
|
|
3655
3655
|
constructor(t) {
|
|
3656
|
-
this.openGlobalLock = null, this.isDragging = !1, this.currentDirection = null, this.originPoint = { x: 0, y: 0 }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic =
|
|
3656
|
+
this.openGlobalLock = null, this.isDragging = !1, this.currentDirection = null, this.originPoint = { x: 0, y: 0 }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic = _(), this.visualElement = t;
|
|
3657
3657
|
}
|
|
3658
3658
|
start(t, { snapToCursor: n = !1 } = {}) {
|
|
3659
3659
|
const { presenceContext: r } = this.visualElement;
|
|
3660
3660
|
if (r && r.isPresent === !1)
|
|
3661
3661
|
return;
|
|
3662
3662
|
const i = (f) => {
|
|
3663
|
-
const { dragSnapToOrigin:
|
|
3664
|
-
|
|
3665
|
-
}, o = (f,
|
|
3663
|
+
const { dragSnapToOrigin: u } = this.getProps();
|
|
3664
|
+
u ? this.pauseAnimation() : this.stopAnimation(), n && this.snapToCursor(cn(f, "page").point);
|
|
3665
|
+
}, o = (f, u) => {
|
|
3666
3666
|
const { drag: h, dragPropagation: d, onDragStart: p } = this.getProps();
|
|
3667
3667
|
if (h && !d && (this.openGlobalLock && this.openGlobalLock(), this.openGlobalLock = co(h), !this.openGlobalLock))
|
|
3668
3668
|
return;
|
|
3669
3669
|
this.isDragging = !0, this.currentDirection = null, this.resolveConstraints(), this.visualElement.projection && (this.visualElement.projection.isAnimationBlocked = !0, this.visualElement.projection.target = void 0), Q((g) => {
|
|
3670
|
-
let
|
|
3671
|
-
if (le.test(
|
|
3672
|
-
const { projection:
|
|
3673
|
-
if (
|
|
3674
|
-
const y =
|
|
3675
|
-
y && (
|
|
3670
|
+
let v = this.getAxisMotionValue(g).get() || 0;
|
|
3671
|
+
if (le.test(v)) {
|
|
3672
|
+
const { projection: w } = this.visualElement;
|
|
3673
|
+
if (w && w.layout) {
|
|
3674
|
+
const y = w.layout.layoutBox[g];
|
|
3675
|
+
y && (v = J(y) * (parseFloat(v) / 100));
|
|
3676
3676
|
}
|
|
3677
3677
|
}
|
|
3678
|
-
this.originPoint[g] =
|
|
3679
|
-
}), p && M.update(() => p(f,
|
|
3678
|
+
this.originPoint[g] = v;
|
|
3679
|
+
}), p && M.update(() => p(f, u), !1, !0);
|
|
3680
3680
|
const { animationState: m } = this.visualElement;
|
|
3681
3681
|
m && m.setActive("whileDrag", !0);
|
|
3682
|
-
}, s = (f,
|
|
3682
|
+
}, s = (f, u) => {
|
|
3683
3683
|
const { dragPropagation: h, dragDirectionLock: d, onDirectionLock: p, onDrag: m } = this.getProps();
|
|
3684
3684
|
if (!h && !this.openGlobalLock)
|
|
3685
3685
|
return;
|
|
3686
|
-
const { offset: g } =
|
|
3686
|
+
const { offset: g } = u;
|
|
3687
3687
|
if (d && this.currentDirection === null) {
|
|
3688
3688
|
this.currentDirection = rh(g), this.currentDirection !== null && p && p(this.currentDirection);
|
|
3689
3689
|
return;
|
|
3690
3690
|
}
|
|
3691
|
-
this.updateAxis("x",
|
|
3692
|
-
}, a = (f,
|
|
3693
|
-
var
|
|
3694
|
-
return this.getAnimationState(f) === "paused" && ((
|
|
3695
|
-
}), { dragSnapToOrigin:
|
|
3691
|
+
this.updateAxis("x", u.point, g), this.updateAxis("y", u.point, g), this.visualElement.render(), m && m(f, u);
|
|
3692
|
+
}, a = (f, u) => this.stop(f, u), l = () => Q((f) => {
|
|
3693
|
+
var u;
|
|
3694
|
+
return this.getAnimationState(f) === "paused" && ((u = this.getAxisMotionValue(f).animation) === null || u === void 0 ? void 0 : u.play());
|
|
3695
|
+
}), { dragSnapToOrigin: c } = this.getProps();
|
|
3696
3696
|
this.panSession = new $o(t, {
|
|
3697
3697
|
onSessionStart: i,
|
|
3698
3698
|
onStart: o,
|
|
@@ -3701,7 +3701,7 @@ class nh {
|
|
|
3701
3701
|
resumeAnimation: l
|
|
3702
3702
|
}, {
|
|
3703
3703
|
transformPagePoint: this.visualElement.getTransformPagePoint(),
|
|
3704
|
-
dragSnapToOrigin:
|
|
3704
|
+
dragSnapToOrigin: c,
|
|
3705
3705
|
contextWindow: Jo(this.visualElement)
|
|
3706
3706
|
});
|
|
3707
3707
|
}
|
|
@@ -3752,11 +3752,11 @@ class nh {
|
|
|
3752
3752
|
return s;
|
|
3753
3753
|
}
|
|
3754
3754
|
startAnimation(t) {
|
|
3755
|
-
const { drag: n, dragMomentum: r, dragElastic: i, dragTransition: o, dragSnapToOrigin: s, onDragTransitionEnd: a } = this.getProps(), l = this.constraints || {},
|
|
3755
|
+
const { drag: n, dragMomentum: r, dragElastic: i, dragTransition: o, dragSnapToOrigin: s, onDragTransitionEnd: a } = this.getProps(), l = this.constraints || {}, c = Q((f) => {
|
|
3756
3756
|
if (!Ot(f, n, this.currentDirection))
|
|
3757
3757
|
return;
|
|
3758
|
-
let
|
|
3759
|
-
s && (
|
|
3758
|
+
let u = l && l[f] || {};
|
|
3759
|
+
s && (u = { min: 0, max: 0 });
|
|
3760
3760
|
const h = i ? 200 : 1e6, d = i ? 40 : 1e7, p = {
|
|
3761
3761
|
type: "inertia",
|
|
3762
3762
|
velocity: r ? t[f] : 0,
|
|
@@ -3766,15 +3766,15 @@ class nh {
|
|
|
3766
3766
|
restDelta: 1,
|
|
3767
3767
|
restSpeed: 10,
|
|
3768
3768
|
...o,
|
|
3769
|
-
...
|
|
3769
|
+
...u
|
|
3770
3770
|
};
|
|
3771
3771
|
return this.startAxisValueAnimation(f, p);
|
|
3772
3772
|
});
|
|
3773
|
-
return Promise.all(
|
|
3773
|
+
return Promise.all(c).then(a);
|
|
3774
3774
|
}
|
|
3775
3775
|
startAxisValueAnimation(t, n) {
|
|
3776
3776
|
const r = this.getAxisMotionValue(t);
|
|
3777
|
-
return r.start(
|
|
3777
|
+
return r.start(Pr(t, r, 0, n));
|
|
3778
3778
|
}
|
|
3779
3779
|
stopAnimation() {
|
|
3780
3780
|
Q((t) => this.getAxisMotionValue(t).stop());
|
|
@@ -3835,8 +3835,8 @@ class nh {
|
|
|
3835
3835
|
this.visualElement.current.style.transform = o ? o({}, "") : "none", r.root && r.root.updateScroll(), r.updateLayout(), this.resolveConstraints(), Q((s) => {
|
|
3836
3836
|
if (!Ot(s, t, null))
|
|
3837
3837
|
return;
|
|
3838
|
-
const a = this.getAxisMotionValue(s), { min: l, max:
|
|
3839
|
-
a.set(D(l,
|
|
3838
|
+
const a = this.getAxisMotionValue(s), { min: l, max: c } = this.constraints[s];
|
|
3839
|
+
a.set(D(l, c, i[s]));
|
|
3840
3840
|
});
|
|
3841
3841
|
}
|
|
3842
3842
|
addListeners() {
|
|
@@ -3844,17 +3844,17 @@ class nh {
|
|
|
3844
3844
|
return;
|
|
3845
3845
|
th.set(this.visualElement, this);
|
|
3846
3846
|
const t = this.visualElement.current, n = he(t, "pointerdown", (l) => {
|
|
3847
|
-
const { drag:
|
|
3848
|
-
|
|
3847
|
+
const { drag: c, dragListener: f = !0 } = this.getProps();
|
|
3848
|
+
c && f && this.start(l);
|
|
3849
3849
|
}), r = () => {
|
|
3850
3850
|
const { dragConstraints: l } = this.getProps();
|
|
3851
3851
|
qe(l) && (this.constraints = this.resolveRefConstraints());
|
|
3852
3852
|
}, { projection: i } = this.visualElement, o = i.addEventListener("measure", r);
|
|
3853
3853
|
i && !i.layout && (i.root && i.root.updateScroll(), i.updateLayout()), r();
|
|
3854
|
-
const s = fe(window, "resize", () => this.scalePositionWithinConstraints()), a = i.addEventListener("didUpdate", ({ delta: l, hasLayoutChanged:
|
|
3855
|
-
this.isDragging &&
|
|
3856
|
-
const
|
|
3857
|
-
|
|
3854
|
+
const s = fe(window, "resize", () => this.scalePositionWithinConstraints()), a = i.addEventListener("didUpdate", ({ delta: l, hasLayoutChanged: c }) => {
|
|
3855
|
+
this.isDragging && c && (Q((f) => {
|
|
3856
|
+
const u = this.getAxisMotionValue(f);
|
|
3857
|
+
u && (this.originPoint[f] += l[f].translate, u.set(u.get() + l[f].translate));
|
|
3858
3858
|
}), this.visualElement.render());
|
|
3859
3859
|
});
|
|
3860
3860
|
return () => {
|
|
@@ -3928,11 +3928,11 @@ class sh extends Re {
|
|
|
3928
3928
|
}
|
|
3929
3929
|
}
|
|
3930
3930
|
function oh() {
|
|
3931
|
-
const e =
|
|
3931
|
+
const e = x.useContext(lr);
|
|
3932
3932
|
if (e === null)
|
|
3933
3933
|
return [!0, null];
|
|
3934
|
-
const { isPresent: t, onExitComplete: n, register: r } = e, i =
|
|
3935
|
-
return
|
|
3934
|
+
const { isPresent: t, onExitComplete: n, register: r } = e, i = x.useId();
|
|
3935
|
+
return x.useEffect(() => r(i), []), !t && n ? [!1, () => n && n(i)] : [!0];
|
|
3936
3936
|
}
|
|
3937
3937
|
const Dt = {
|
|
3938
3938
|
/**
|
|
@@ -3968,8 +3968,8 @@ const it = {
|
|
|
3968
3968
|
return r;
|
|
3969
3969
|
const o = Ce.createTransformer(e), s = typeof i[0] != "number" ? 1 : 0, a = n.x.scale * t.x, l = n.y.scale * t.y;
|
|
3970
3970
|
i[0 + s] /= a, i[1 + s] /= l;
|
|
3971
|
-
const
|
|
3972
|
-
return typeof i[2 + s] == "number" && (i[2 + s] /=
|
|
3971
|
+
const c = D(a, l, 0.5);
|
|
3972
|
+
return typeof i[2 + s] == "number" && (i[2 + s] /= c), typeof i[3 + s] == "number" && (i[3 + s] /= c), o(i);
|
|
3973
3973
|
}
|
|
3974
3974
|
};
|
|
3975
3975
|
class lh extends ws.Component {
|
|
@@ -4013,8 +4013,8 @@ class lh extends ws.Component {
|
|
|
4013
4013
|
}
|
|
4014
4014
|
}
|
|
4015
4015
|
function Zo(e) {
|
|
4016
|
-
const [t, n] = oh(), r =
|
|
4017
|
-
return ws.createElement(lh, { ...e, layoutGroup: r, switchLayoutGroup:
|
|
4016
|
+
const [t, n] = oh(), r = x.useContext(qs);
|
|
4017
|
+
return ws.createElement(lh, { ...e, layoutGroup: r, switchLayoutGroup: x.useContext(Gs), isPresent: t, safeToRemove: n });
|
|
4018
4018
|
}
|
|
4019
4019
|
const ch = {
|
|
4020
4020
|
borderRadius: {
|
|
@@ -4041,10 +4041,10 @@ function fh(e, t, n, r, i, o) {
|
|
|
4041
4041
|
), e.opacityExit = D(t.opacity !== void 0 ? t.opacity : 1, 0, dh(r))) : o && (e.opacity = D(t.opacity !== void 0 ? t.opacity : 1, n.opacity !== void 0 ? n.opacity : 1, r));
|
|
4042
4042
|
for (let s = 0; s < uh; s++) {
|
|
4043
4043
|
const a = `border${Qo[s]}Radius`;
|
|
4044
|
-
let l = Mi(t, a),
|
|
4045
|
-
if (l === void 0 &&
|
|
4044
|
+
let l = Mi(t, a), c = Mi(n, a);
|
|
4045
|
+
if (l === void 0 && c === void 0)
|
|
4046
4046
|
continue;
|
|
4047
|
-
l || (l = 0),
|
|
4047
|
+
l || (l = 0), c || (c = 0), l === 0 || c === 0 || ki(l) === ki(c) ? (e[a] = Math.max(D(Vi(l), Vi(c), r), 0), (le.test(c) || le.test(l)) && (e[a] += "%")) : e[a] = c;
|
|
4048
4048
|
}
|
|
4049
4049
|
(t.rotate || n.rotate) && (e.rotate = D(t.rotate || 0, n.rotate || 0, r));
|
|
4050
4050
|
}
|
|
@@ -4097,7 +4097,7 @@ class vh {
|
|
|
4097
4097
|
this.members = [];
|
|
4098
4098
|
}
|
|
4099
4099
|
add(t) {
|
|
4100
|
-
|
|
4100
|
+
Ar(this.members, t), t.scheduleRender();
|
|
4101
4101
|
}
|
|
4102
4102
|
remove(t) {
|
|
4103
4103
|
if (Cr(this.members, t), t === this.prevLead && (this.prevLead = void 0), t === this.lead) {
|
|
@@ -4150,8 +4150,8 @@ function Bi(e, t, n) {
|
|
|
4150
4150
|
let r = "";
|
|
4151
4151
|
const i = e.x.translate / t.x, o = e.y.translate / t.y;
|
|
4152
4152
|
if ((i || o) && (r = `translate3d(${i}px, ${o}px, 0) `), (t.x !== 1 || t.y !== 1) && (r += `scale(${1 / t.x}, ${1 / t.y}) `), n) {
|
|
4153
|
-
const { rotate: l, rotateX:
|
|
4154
|
-
l && (r += `rotate(${l}deg) `),
|
|
4153
|
+
const { rotate: l, rotateX: c, rotateY: f } = n;
|
|
4154
|
+
l && (r += `rotate(${l}deg) `), c && (r += `rotateX(${c}deg) `), f && (r += `rotateY(${f}deg) `);
|
|
4155
4155
|
}
|
|
4156
4156
|
const s = e.x.scale * t.x, a = e.y.scale * t.y;
|
|
4157
4157
|
return (s !== 1 || a !== 1) && (r += `scale(${s}, ${a})`), r || "none";
|
|
@@ -4162,7 +4162,7 @@ class xh {
|
|
|
4162
4162
|
this.children = [], this.isDirty = !1;
|
|
4163
4163
|
}
|
|
4164
4164
|
add(t) {
|
|
4165
|
-
|
|
4165
|
+
Ar(this.children, t), this.isDirty = !0;
|
|
4166
4166
|
}
|
|
4167
4167
|
remove(t) {
|
|
4168
4168
|
Cr(this.children, t), this.isDirty = !0;
|
|
@@ -4185,11 +4185,11 @@ function Eh(e) {
|
|
|
4185
4185
|
return e instanceof SVGElement && e.tagName !== "svg";
|
|
4186
4186
|
}
|
|
4187
4187
|
function Th(e, t, n) {
|
|
4188
|
-
const r =
|
|
4189
|
-
return r.start(
|
|
4188
|
+
const r = X(e) ? e : Ye(e);
|
|
4189
|
+
return r.start(Pr("", r, t, n)), r.animation;
|
|
4190
4190
|
}
|
|
4191
|
-
const Ii = ["", "X", "Y", "Z"],
|
|
4192
|
-
let
|
|
4191
|
+
const Ii = ["", "X", "Y", "Z"], Ph = { visibility: "hidden" }, Wi = 1e3;
|
|
4192
|
+
let Ah = 0;
|
|
4193
4193
|
const Le = {
|
|
4194
4194
|
type: "projectionFrame",
|
|
4195
4195
|
totalNodes: 0,
|
|
@@ -4199,7 +4199,7 @@ const Le = {
|
|
|
4199
4199
|
function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, checkIsScrollRoot: r, resetTransform: i }) {
|
|
4200
4200
|
return class {
|
|
4201
4201
|
constructor(s = {}, a = t == null ? void 0 : t()) {
|
|
4202
|
-
this.id =
|
|
4202
|
+
this.id = Ah++, this.animationId = 0, this.children = /* @__PURE__ */ new Set(), this.options = {}, this.isTreeAnimating = !1, this.isAnimationBlocked = !1, this.isLayoutDirty = !1, this.isProjectionDirty = !1, this.isSharedProjectionDirty = !1, this.isTransformDirty = !1, this.updateManuallyBlocked = !1, this.updateBlockedByResize = !1, this.isUpdating = !1, this.isSVG = !1, this.needsReset = !1, this.shouldResetTransform = !1, this.treeScale = { x: 1, y: 1 }, this.eventHandlers = /* @__PURE__ */ new Map(), this.hasTreeAnimated = !1, this.updateScheduled = !1, this.projectionUpdateScheduled = !1, this.checkUpdateFailed = () => {
|
|
4203
4203
|
this.isUpdating && (this.isUpdating = !1, this.clearAllSnapshots());
|
|
4204
4204
|
}, this.updateProjection = () => {
|
|
4205
4205
|
this.projectionUpdateScheduled = !1, Le.totalNodes = Le.resolvedTargetDeltas = Le.recalculatedProjection = 0, this.nodes.forEach(Oh), this.nodes.forEach(Dh), this.nodes.forEach(jh), this.nodes.forEach(Vh), Sh(Le);
|
|
@@ -4225,26 +4225,26 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4225
4225
|
if (this.instance)
|
|
4226
4226
|
return;
|
|
4227
4227
|
this.isSVG = Eh(s), this.instance = s;
|
|
4228
|
-
const { layoutId: l, layout:
|
|
4229
|
-
if (f && !f.current && f.mount(s), this.root.nodes.add(this), this.parent && this.parent.children.add(this), a && (
|
|
4230
|
-
let
|
|
4228
|
+
const { layoutId: l, layout: c, visualElement: f } = this.options;
|
|
4229
|
+
if (f && !f.current && f.mount(s), this.root.nodes.add(this), this.parent && this.parent.children.add(this), a && (c || l) && (this.isLayoutDirty = !0), e) {
|
|
4230
|
+
let u;
|
|
4231
4231
|
const h = () => this.root.updateBlockedByResize = !1;
|
|
4232
4232
|
e(s, () => {
|
|
4233
|
-
this.root.updateBlockedByResize = !0,
|
|
4233
|
+
this.root.updateBlockedByResize = !0, u && u(), u = wh(h, 250), Dt.hasAnimatedSinceResize && (Dt.hasAnimatedSinceResize = !1, this.nodes.forEach(zi));
|
|
4234
4234
|
});
|
|
4235
4235
|
}
|
|
4236
|
-
l && this.root.registerSharedNode(l, this), this.options.animate !== !1 && f && (l ||
|
|
4236
|
+
l && this.root.registerSharedNode(l, this), this.options.animate !== !1 && f && (l || c) && this.addEventListener("didUpdate", ({ delta: u, hasLayoutChanged: h, hasRelativeTargetChanged: d, layout: p }) => {
|
|
4237
4237
|
if (this.isTreeAnimationBlocked()) {
|
|
4238
4238
|
this.target = void 0, this.relativeTarget = void 0;
|
|
4239
4239
|
return;
|
|
4240
4240
|
}
|
|
4241
|
-
const m = this.options.transition || f.getDefaultTransition() || Ih, { onLayoutAnimationStart: g, onLayoutAnimationComplete:
|
|
4242
|
-
if (this.options.layoutRoot || this.resumeFrom && this.resumeFrom.instance || y || h && (
|
|
4243
|
-
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0), this.setAnimationOrigin(
|
|
4241
|
+
const m = this.options.transition || f.getDefaultTransition() || Ih, { onLayoutAnimationStart: g, onLayoutAnimationComplete: v } = f.getProps(), w = !this.targetLayout || !na(this.targetLayout, p) || d, y = !h && d;
|
|
4242
|
+
if (this.options.layoutRoot || this.resumeFrom && this.resumeFrom.instance || y || h && (w || !this.currentAnimation)) {
|
|
4243
|
+
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0), this.setAnimationOrigin(u, y);
|
|
4244
4244
|
const S = {
|
|
4245
4245
|
...Tr(m, "layout"),
|
|
4246
4246
|
onPlay: g,
|
|
4247
|
-
onComplete:
|
|
4247
|
+
onComplete: v
|
|
4248
4248
|
};
|
|
4249
4249
|
(f.shouldReduceMotion || this.options.layoutRoot) && (S.delay = 0, S.type = !1), this.startAnimation(S);
|
|
4250
4250
|
} else
|
|
@@ -4287,14 +4287,14 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4287
4287
|
return;
|
|
4288
4288
|
this.isLayoutDirty = !0;
|
|
4289
4289
|
for (let f = 0; f < this.path.length; f++) {
|
|
4290
|
-
const
|
|
4291
|
-
|
|
4290
|
+
const u = this.path[f];
|
|
4291
|
+
u.shouldResetTransform = !0, u.updateScroll("snapshot"), u.options.layoutRoot && u.willUpdate(!1);
|
|
4292
4292
|
}
|
|
4293
4293
|
const { layoutId: a, layout: l } = this.options;
|
|
4294
4294
|
if (a === void 0 && !l)
|
|
4295
4295
|
return;
|
|
4296
|
-
const
|
|
4297
|
-
this.prevTransformTemplateValue =
|
|
4296
|
+
const c = this.getTransformTemplate();
|
|
4297
|
+
this.prevTransformTemplateValue = c ? c(this.latestValues, "") : void 0, this.updateSnapshot(), s && this.notifyListeners("willUpdate");
|
|
4298
4298
|
}
|
|
4299
4299
|
update() {
|
|
4300
4300
|
if (this.updateScheduled = !1, this.isUpdateBlocked()) {
|
|
@@ -4303,7 +4303,7 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4303
4303
|
}
|
|
4304
4304
|
this.isUpdating || this.nodes.forEach(Mh), this.isUpdating = !1, this.nodes.forEach(Lh), this.nodes.forEach(Ch), this.nodes.forEach(Rh), this.clearAllSnapshots();
|
|
4305
4305
|
const a = performance.now();
|
|
4306
|
-
|
|
4306
|
+
$.delta = Ae(0, 1e3 / 60, a - $.timestamp), $.timestamp = a, $.isProcessing = !0, wn.update.process($), wn.preRender.process($), wn.render.process($), $.isProcessing = !1;
|
|
4307
4307
|
}
|
|
4308
4308
|
didUpdate() {
|
|
4309
4309
|
this.updateScheduled || (this.updateScheduled = !0, queueMicrotask(() => this.update()));
|
|
@@ -4332,7 +4332,7 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4332
4332
|
for (let l = 0; l < this.path.length; l++)
|
|
4333
4333
|
this.path[l].updateScroll();
|
|
4334
4334
|
const s = this.layout;
|
|
4335
|
-
this.layout = this.measure(!1), this.layoutCorrected =
|
|
4335
|
+
this.layout = this.measure(!1), this.layoutCorrected = _(), this.isLayoutDirty = !1, this.projectionDelta = void 0, this.notifyListeners("measure", this.layout.layoutBox);
|
|
4336
4336
|
const { visualElement: a } = this.options;
|
|
4337
4337
|
a && a.notify("LayoutMeasure", this.layout.layoutBox, s ? s.layoutBox : void 0);
|
|
4338
4338
|
}
|
|
@@ -4348,8 +4348,8 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4348
4348
|
resetTransform() {
|
|
4349
4349
|
if (!i)
|
|
4350
4350
|
return;
|
|
4351
|
-
const s = this.isLayoutDirty || this.shouldResetTransform, a = this.projectionDelta && !ta(this.projectionDelta), l = this.getTransformTemplate(),
|
|
4352
|
-
s && (a || Me(this.latestValues) || f) && (i(this.instance,
|
|
4351
|
+
const s = this.isLayoutDirty || this.shouldResetTransform, a = this.projectionDelta && !ta(this.projectionDelta), l = this.getTransformTemplate(), c = l ? l(this.latestValues, "") : void 0, f = c !== this.prevTransformTemplateValue;
|
|
4352
|
+
s && (a || Me(this.latestValues) || f) && (i(this.instance, c), this.shouldResetTransform = !1, this.scheduleRender());
|
|
4353
4353
|
}
|
|
4354
4354
|
measure(s = !0) {
|
|
4355
4355
|
const a = this.measurePageBox();
|
|
@@ -4365,16 +4365,16 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4365
4365
|
measurePageBox() {
|
|
4366
4366
|
const { visualElement: s } = this.options;
|
|
4367
4367
|
if (!s)
|
|
4368
|
-
return
|
|
4368
|
+
return _();
|
|
4369
4369
|
const a = s.measureViewportBox(), { scroll: l } = this.root;
|
|
4370
4370
|
return l && (Se(a.x, l.offset.x), Se(a.y, l.offset.y)), a;
|
|
4371
4371
|
}
|
|
4372
4372
|
removeElementScroll(s) {
|
|
4373
|
-
const a =
|
|
4373
|
+
const a = _();
|
|
4374
4374
|
Z(a, s);
|
|
4375
4375
|
for (let l = 0; l < this.path.length; l++) {
|
|
4376
|
-
const
|
|
4377
|
-
if (
|
|
4376
|
+
const c = this.path[l], { scroll: f, options: u } = c;
|
|
4377
|
+
if (c !== this.root && f && u.layoutScroll) {
|
|
4378
4378
|
if (f.isRoot) {
|
|
4379
4379
|
Z(a, s);
|
|
4380
4380
|
const { scroll: h } = this.root;
|
|
@@ -4386,10 +4386,10 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4386
4386
|
return a;
|
|
4387
4387
|
}
|
|
4388
4388
|
applyTransform(s, a = !1) {
|
|
4389
|
-
const l =
|
|
4389
|
+
const l = _();
|
|
4390
4390
|
Z(l, s);
|
|
4391
|
-
for (let
|
|
4392
|
-
const f = this.path[
|
|
4391
|
+
for (let c = 0; c < this.path.length; c++) {
|
|
4392
|
+
const f = this.path[c];
|
|
4393
4393
|
!a && f.options.layoutScroll && f.scroll && f !== f.root && Ke(l, {
|
|
4394
4394
|
x: -f.scroll.offset.x,
|
|
4395
4395
|
y: -f.scroll.offset.y
|
|
@@ -4398,15 +4398,15 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4398
4398
|
return Me(this.latestValues) && Ke(l, this.latestValues), l;
|
|
4399
4399
|
}
|
|
4400
4400
|
removeTransform(s) {
|
|
4401
|
-
const a =
|
|
4401
|
+
const a = _();
|
|
4402
4402
|
Z(a, s);
|
|
4403
4403
|
for (let l = 0; l < this.path.length; l++) {
|
|
4404
|
-
const
|
|
4405
|
-
if (!
|
|
4404
|
+
const c = this.path[l];
|
|
4405
|
+
if (!c.instance || !Me(c.latestValues))
|
|
4406
4406
|
continue;
|
|
4407
|
-
Yn(
|
|
4408
|
-
const f =
|
|
4409
|
-
Z(f,
|
|
4407
|
+
Yn(c.latestValues) && c.updateSnapshot();
|
|
4408
|
+
const f = _(), u = c.measurePageBox();
|
|
4409
|
+
Z(f, u), _i(a, c.latestValues, c.snapshot ? c.snapshot.layoutBox : void 0, f);
|
|
4410
4410
|
}
|
|
4411
4411
|
return Me(this.latestValues) && _i(a, this.latestValues), a;
|
|
4412
4412
|
}
|
|
@@ -4424,26 +4424,26 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4424
4424
|
this.scroll = void 0, this.layout = void 0, this.snapshot = void 0, this.prevTransformTemplateValue = void 0, this.targetDelta = void 0, this.target = void 0, this.isLayoutDirty = !1;
|
|
4425
4425
|
}
|
|
4426
4426
|
forceRelativeParentToResolveTarget() {
|
|
4427
|
-
this.relativeParent && this.relativeParent.resolvedRelativeTargetAt !==
|
|
4427
|
+
this.relativeParent && this.relativeParent.resolvedRelativeTargetAt !== $.timestamp && this.relativeParent.resolveTargetDelta(!0);
|
|
4428
4428
|
}
|
|
4429
4429
|
resolveTargetDelta(s = !1) {
|
|
4430
4430
|
var a;
|
|
4431
4431
|
const l = this.getLead();
|
|
4432
4432
|
this.isProjectionDirty || (this.isProjectionDirty = l.isProjectionDirty), this.isTransformDirty || (this.isTransformDirty = l.isTransformDirty), this.isSharedProjectionDirty || (this.isSharedProjectionDirty = l.isSharedProjectionDirty);
|
|
4433
|
-
const
|
|
4434
|
-
if (!(s ||
|
|
4433
|
+
const c = !!this.resumingFrom || this !== l;
|
|
4434
|
+
if (!(s || c && this.isSharedProjectionDirty || this.isProjectionDirty || !((a = this.parent) === null || a === void 0) && a.isProjectionDirty || this.attemptToResolveRelativeTarget))
|
|
4435
4435
|
return;
|
|
4436
|
-
const { layout:
|
|
4437
|
-
if (!(!this.layout || !(
|
|
4438
|
-
if (this.resolvedRelativeTargetAt =
|
|
4436
|
+
const { layout: u, layoutId: h } = this.options;
|
|
4437
|
+
if (!(!this.layout || !(u || h))) {
|
|
4438
|
+
if (this.resolvedRelativeTargetAt = $.timestamp, !this.targetDelta && !this.relativeTarget) {
|
|
4439
4439
|
const d = this.getClosestProjectingParent();
|
|
4440
|
-
d && d.layout && this.animationProgress !== 1 ? (this.relativeParent = d, this.forceRelativeParentToResolveTarget(), this.relativeTarget =
|
|
4440
|
+
d && d.layout && this.animationProgress !== 1 ? (this.relativeParent = d, this.forceRelativeParentToResolveTarget(), this.relativeTarget = _(), this.relativeTargetOrigin = _(), ut(this.relativeTargetOrigin, this.layout.layoutBox, d.layout.layoutBox), Z(this.relativeTarget, this.relativeTargetOrigin)) : this.relativeParent = this.relativeTarget = void 0;
|
|
4441
4441
|
}
|
|
4442
4442
|
if (!(!this.relativeTarget && !this.targetDelta)) {
|
|
4443
|
-
if (this.target || (this.target =
|
|
4443
|
+
if (this.target || (this.target = _(), this.targetWithTransforms = _()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), Uf(this.target, this.relativeTarget, this.relativeParent.target)) : this.targetDelta ? (this.resumingFrom ? this.target = this.applyTransform(this.layout.layoutBox) : Z(this.target, this.layout.layoutBox), Ko(this.target, this.targetDelta)) : Z(this.target, this.layout.layoutBox), this.attemptToResolveRelativeTarget) {
|
|
4444
4444
|
this.attemptToResolveRelativeTarget = !1;
|
|
4445
4445
|
const d = this.getClosestProjectingParent();
|
|
4446
|
-
d && !!d.resumingFrom == !!this.resumingFrom && !d.options.layoutScroll && d.target && this.animationProgress !== 1 ? (this.relativeParent = d, this.forceRelativeParentToResolveTarget(), this.relativeTarget =
|
|
4446
|
+
d && !!d.resumingFrom == !!this.resumingFrom && !d.options.layoutScroll && d.target && this.animationProgress !== 1 ? (this.relativeParent = d, this.forceRelativeParentToResolveTarget(), this.relativeTarget = _(), this.relativeTargetOrigin = _(), ut(this.relativeTargetOrigin, this.target, d.target), Z(this.relativeTarget, this.relativeTargetOrigin)) : this.relativeParent = this.relativeTarget = void 0;
|
|
4447
4447
|
}
|
|
4448
4448
|
Le.resolvedTargetDeltas++;
|
|
4449
4449
|
}
|
|
@@ -4459,11 +4459,11 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4459
4459
|
calcProjection() {
|
|
4460
4460
|
var s;
|
|
4461
4461
|
const a = this.getLead(), l = !!this.resumingFrom || this !== a;
|
|
4462
|
-
let
|
|
4463
|
-
if ((this.isProjectionDirty || !((s = this.parent) === null || s === void 0) && s.isProjectionDirty) && (
|
|
4462
|
+
let c = !0;
|
|
4463
|
+
if ((this.isProjectionDirty || !((s = this.parent) === null || s === void 0) && s.isProjectionDirty) && (c = !1), l && (this.isSharedProjectionDirty || this.isTransformDirty) && (c = !1), this.resolvedRelativeTargetAt === $.timestamp && (c = !1), c)
|
|
4464
4464
|
return;
|
|
4465
|
-
const { layout: f, layoutId:
|
|
4466
|
-
if (this.isTreeAnimating = !!(this.parent && this.parent.isTreeAnimating || this.currentAnimation || this.pendingAnimation), this.isTreeAnimating || (this.targetDelta = this.relativeTarget = void 0), !this.layout || !(f ||
|
|
4465
|
+
const { layout: f, layoutId: u } = this.options;
|
|
4466
|
+
if (this.isTreeAnimating = !!(this.parent && this.parent.isTreeAnimating || this.currentAnimation || this.pendingAnimation), this.isTreeAnimating || (this.targetDelta = this.relativeTarget = void 0), !this.layout || !(f || u))
|
|
4467
4467
|
return;
|
|
4468
4468
|
Z(this.layoutCorrected, this.layout.layoutBox);
|
|
4469
4469
|
const h = this.treeScale.x, d = this.treeScale.y;
|
|
@@ -4491,14 +4491,14 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4491
4491
|
this.resumingFrom && !this.resumingFrom.instance && (this.resumingFrom = void 0);
|
|
4492
4492
|
}
|
|
4493
4493
|
setAnimationOrigin(s, a = !1) {
|
|
4494
|
-
const l = this.snapshot,
|
|
4494
|
+
const l = this.snapshot, c = l ? l.latestValues : {}, f = { ...this.latestValues }, u = Xe();
|
|
4495
4495
|
(!this.relativeParent || !this.relativeParent.options.layoutRoot) && (this.relativeTarget = this.relativeTargetOrigin = void 0), this.attemptToResolveRelativeTarget = !a;
|
|
4496
|
-
const h =
|
|
4496
|
+
const h = _(), d = l ? l.source : void 0, p = this.layout ? this.layout.source : void 0, m = d !== p, g = this.getStack(), v = !g || g.members.length <= 1, w = !!(m && !v && this.options.crossfade === !0 && !this.path.some(Bh));
|
|
4497
4497
|
this.animationProgress = 0;
|
|
4498
4498
|
let y;
|
|
4499
4499
|
this.mixTargetDelta = (S) => {
|
|
4500
|
-
const
|
|
4501
|
-
Hi(
|
|
4500
|
+
const E = S / 1e3;
|
|
4501
|
+
Hi(u.x, s.x, E), Hi(u.y, s.y, E), this.setTargetDelta(u), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (ut(h, this.layout.layoutBox, this.relativeParent.layout.layoutBox), Nh(this.relativeTarget, this.relativeTargetOrigin, h, E), y && yh(this.relativeTarget, y) && (this.isProjectionDirty = !1), y || (y = _()), Z(y, this.relativeTarget)), m && (this.animationValues = f, fh(f, c, this.latestValues, E, w, v)), this.root.scheduleUpdateProjection(), this.scheduleRender(), this.animationProgress = E;
|
|
4502
4502
|
}, this.mixTargetDelta(this.options.layoutRoot ? 1e3 : 0);
|
|
4503
4503
|
}
|
|
4504
4504
|
startAnimation(s) {
|
|
@@ -4524,12 +4524,12 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4524
4524
|
}
|
|
4525
4525
|
applyTransformsToTarget() {
|
|
4526
4526
|
const s = this.getLead();
|
|
4527
|
-
let { targetWithTransforms: a, target: l, layout:
|
|
4528
|
-
if (!(!a || !l || !
|
|
4529
|
-
if (this !== s && this.layout &&
|
|
4530
|
-
l = this.target ||
|
|
4531
|
-
const
|
|
4532
|
-
l.x.min = s.target.x.min, l.x.max = l.x.min +
|
|
4527
|
+
let { targetWithTransforms: a, target: l, layout: c, latestValues: f } = s;
|
|
4528
|
+
if (!(!a || !l || !c)) {
|
|
4529
|
+
if (this !== s && this.layout && c && ia(this.options.animationType, this.layout.layoutBox, c.layoutBox)) {
|
|
4530
|
+
l = this.target || _();
|
|
4531
|
+
const u = J(this.layout.layoutBox.x);
|
|
4532
|
+
l.x.min = s.target.x.min, l.x.max = l.x.min + u;
|
|
4533
4533
|
const h = J(this.layout.layoutBox.y);
|
|
4534
4534
|
l.y.min = s.target.y.min, l.y.max = l.y.min + h;
|
|
4535
4535
|
}
|
|
@@ -4538,10 +4538,10 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4538
4538
|
}
|
|
4539
4539
|
registerSharedNode(s, a) {
|
|
4540
4540
|
this.sharedNodes.has(s) || this.sharedNodes.set(s, new vh()), this.sharedNodes.get(s).add(a);
|
|
4541
|
-
const
|
|
4541
|
+
const c = a.options.initialPromotionConfig;
|
|
4542
4542
|
a.promote({
|
|
4543
|
-
transition:
|
|
4544
|
-
preserveFollowOpacity:
|
|
4543
|
+
transition: c ? c.transition : void 0,
|
|
4544
|
+
preserveFollowOpacity: c && c.shouldPreserveFollowOpacity ? c.shouldPreserveFollowOpacity(a) : void 0
|
|
4545
4545
|
});
|
|
4546
4546
|
}
|
|
4547
4547
|
isLead() {
|
|
@@ -4564,8 +4564,8 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4564
4564
|
return this.root.sharedNodes.get(s);
|
|
4565
4565
|
}
|
|
4566
4566
|
promote({ needsReset: s, transition: a, preserveFollowOpacity: l } = {}) {
|
|
4567
|
-
const
|
|
4568
|
-
|
|
4567
|
+
const c = this.getStack();
|
|
4568
|
+
c && c.promote(this, l), s && (this.projectionDelta = void 0, this.needsReset = !0), a && this.setOptions({ transition: a });
|
|
4569
4569
|
}
|
|
4570
4570
|
relegate() {
|
|
4571
4571
|
const s = this.getStack();
|
|
@@ -4579,14 +4579,14 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4579
4579
|
const { latestValues: l } = s;
|
|
4580
4580
|
if ((l.rotate || l.rotateX || l.rotateY || l.rotateZ) && (a = !0), !a)
|
|
4581
4581
|
return;
|
|
4582
|
-
const
|
|
4582
|
+
const c = {};
|
|
4583
4583
|
for (let f = 0; f < Ii.length; f++) {
|
|
4584
|
-
const
|
|
4585
|
-
l[
|
|
4584
|
+
const u = "rotate" + Ii[f];
|
|
4585
|
+
l[u] && (c[u] = l[u], s.setStaticValue(u, 0));
|
|
4586
4586
|
}
|
|
4587
4587
|
s.render();
|
|
4588
|
-
for (const f in
|
|
4589
|
-
s.setStaticValue(f,
|
|
4588
|
+
for (const f in c)
|
|
4589
|
+
s.setStaticValue(f, c[f]);
|
|
4590
4590
|
s.scheduleRender();
|
|
4591
4591
|
}
|
|
4592
4592
|
getProjectionStyles(s) {
|
|
@@ -4594,33 +4594,33 @@ function ra({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
|
|
|
4594
4594
|
if (!this.instance || this.isSVG)
|
|
4595
4595
|
return;
|
|
4596
4596
|
if (!this.isVisible)
|
|
4597
|
-
return
|
|
4598
|
-
const
|
|
4597
|
+
return Ph;
|
|
4598
|
+
const c = {
|
|
4599
4599
|
visibility: ""
|
|
4600
4600
|
}, f = this.getTransformTemplate();
|
|
4601
4601
|
if (this.needsReset)
|
|
4602
|
-
return this.needsReset = !1,
|
|
4603
|
-
const
|
|
4604
|
-
if (!this.projectionDelta || !this.layout || !
|
|
4602
|
+
return this.needsReset = !1, c.opacity = "", c.pointerEvents = Lt(s == null ? void 0 : s.pointerEvents) || "", c.transform = f ? f(this.latestValues, "") : "none", c;
|
|
4603
|
+
const u = this.getLead();
|
|
4604
|
+
if (!this.projectionDelta || !this.layout || !u.target) {
|
|
4605
4605
|
const m = {};
|
|
4606
4606
|
return this.options.layoutId && (m.opacity = this.latestValues.opacity !== void 0 ? this.latestValues.opacity : 1, m.pointerEvents = Lt(s == null ? void 0 : s.pointerEvents) || ""), this.hasProjected && !Me(this.latestValues) && (m.transform = f ? f({}, "") : "none", this.hasProjected = !1), m;
|
|
4607
4607
|
}
|
|
4608
|
-
const h =
|
|
4609
|
-
this.applyTransformsToTarget(),
|
|
4608
|
+
const h = u.animationValues || u.latestValues;
|
|
4609
|
+
this.applyTransformsToTarget(), c.transform = Bi(this.projectionDeltaWithTransform, this.treeScale, h), f && (c.transform = f(h, c.transform));
|
|
4610
4610
|
const { x: d, y: p } = this.projectionDelta;
|
|
4611
|
-
|
|
4611
|
+
c.transformOrigin = `${d.origin * 100}% ${p.origin * 100}% 0`, u.animationValues ? c.opacity = u === this ? (l = (a = h.opacity) !== null && a !== void 0 ? a : this.latestValues.opacity) !== null && l !== void 0 ? l : 1 : this.preserveOpacity ? this.latestValues.opacity : h.opacityExit : c.opacity = u === this ? h.opacity !== void 0 ? h.opacity : "" : h.opacityExit !== void 0 ? h.opacityExit : 0;
|
|
4612
4612
|
for (const m in Ut) {
|
|
4613
4613
|
if (h[m] === void 0)
|
|
4614
4614
|
continue;
|
|
4615
|
-
const { correct: g, applyTo:
|
|
4616
|
-
if (
|
|
4617
|
-
const y =
|
|
4615
|
+
const { correct: g, applyTo: v } = Ut[m], w = c.transform === "none" ? h[m] : g(h[m], u);
|
|
4616
|
+
if (v) {
|
|
4617
|
+
const y = v.length;
|
|
4618
4618
|
for (let S = 0; S < y; S++)
|
|
4619
|
-
|
|
4619
|
+
c[v[S]] = w;
|
|
4620
4620
|
} else
|
|
4621
|
-
|
|
4621
|
+
c[m] = w;
|
|
4622
4622
|
}
|
|
4623
|
-
return this.options.layoutId && (
|
|
4623
|
+
return this.options.layoutId && (c.pointerEvents = u === this ? Lt(s == null ? void 0 : s.pointerEvents) || "" : "none"), c;
|
|
4624
4624
|
}
|
|
4625
4625
|
clearSnapshot() {
|
|
4626
4626
|
this.resumeFrom = this.snapshot = void 0;
|
|
@@ -4642,28 +4642,28 @@ function Rh(e) {
|
|
|
4642
4642
|
const n = ((t = e.resumeFrom) === null || t === void 0 ? void 0 : t.snapshot) || e.snapshot;
|
|
4643
4643
|
if (e.isLead() && e.layout && n && e.hasListeners("didUpdate")) {
|
|
4644
4644
|
const { layoutBox: r, measuredBox: i } = e.layout, { animationType: o } = e.options, s = n.source !== e.layout.source;
|
|
4645
|
-
o === "size" ? Q((
|
|
4646
|
-
const h = s ? n.measuredBox[
|
|
4647
|
-
h.min = r[
|
|
4648
|
-
}) : ia(o, n.layoutBox, r) && Q((
|
|
4649
|
-
const h = s ? n.measuredBox[
|
|
4650
|
-
h.max = h.min + d, e.relativeTarget && !e.currentAnimation && (e.isProjectionDirty = !0, e.relativeTarget[
|
|
4645
|
+
o === "size" ? Q((u) => {
|
|
4646
|
+
const h = s ? n.measuredBox[u] : n.layoutBox[u], d = J(h);
|
|
4647
|
+
h.min = r[u].min, h.max = h.min + d;
|
|
4648
|
+
}) : ia(o, n.layoutBox, r) && Q((u) => {
|
|
4649
|
+
const h = s ? n.measuredBox[u] : n.layoutBox[u], d = J(r[u]);
|
|
4650
|
+
h.max = h.min + d, e.relativeTarget && !e.currentAnimation && (e.isProjectionDirty = !0, e.relativeTarget[u].max = e.relativeTarget[u].min + d);
|
|
4651
4651
|
});
|
|
4652
4652
|
const a = Xe();
|
|
4653
4653
|
ct(a, r, n.layoutBox);
|
|
4654
4654
|
const l = Xe();
|
|
4655
4655
|
s ? ct(l, e.applyTransform(i, !0), n.measuredBox) : ct(l, r, n.layoutBox);
|
|
4656
|
-
const
|
|
4656
|
+
const c = !ta(a);
|
|
4657
4657
|
let f = !1;
|
|
4658
4658
|
if (!e.resumeFrom) {
|
|
4659
|
-
const
|
|
4660
|
-
if (
|
|
4661
|
-
const { snapshot: h, layout: d } =
|
|
4659
|
+
const u = e.getClosestProjectingParent();
|
|
4660
|
+
if (u && !u.resumeFrom) {
|
|
4661
|
+
const { snapshot: h, layout: d } = u;
|
|
4662
4662
|
if (h && d) {
|
|
4663
|
-
const p =
|
|
4663
|
+
const p = _();
|
|
4664
4664
|
ut(p, n.layoutBox, h.layoutBox);
|
|
4665
|
-
const m =
|
|
4666
|
-
ut(m, r, d.layoutBox), na(p, m) || (f = !0),
|
|
4665
|
+
const m = _();
|
|
4666
|
+
ut(m, r, d.layoutBox), na(p, m) || (f = !0), u.options.layoutRoot && (e.relativeTarget = m, e.relativeTargetOrigin = p, e.relativeParent = u);
|
|
4667
4667
|
}
|
|
4668
4668
|
}
|
|
4669
4669
|
}
|
|
@@ -4672,7 +4672,7 @@ function Rh(e) {
|
|
|
4672
4672
|
snapshot: n,
|
|
4673
4673
|
delta: l,
|
|
4674
4674
|
layoutDelta: a,
|
|
4675
|
-
hasLayoutChanged:
|
|
4675
|
+
hasLayoutChanged: c,
|
|
4676
4676
|
hasRelativeTargetChanged: f
|
|
4677
4677
|
});
|
|
4678
4678
|
} else if (e.isLead()) {
|
|
@@ -4858,13 +4858,13 @@ Je.translateX = Je.x;
|
|
|
4858
4858
|
Je.translateY = Je.y;
|
|
4859
4859
|
const Zh = (e, t, n) => {
|
|
4860
4860
|
const r = t.measureViewportBox(), i = t.current, o = getComputedStyle(i), { display: s } = o, a = {};
|
|
4861
|
-
s === "none" && t.setStaticValue("display", e.display || "block"), n.forEach((
|
|
4862
|
-
a[
|
|
4861
|
+
s === "none" && t.setStaticValue("display", e.display || "block"), n.forEach((c) => {
|
|
4862
|
+
a[c] = Je[c](r, o);
|
|
4863
4863
|
}), t.render();
|
|
4864
4864
|
const l = t.measureViewportBox();
|
|
4865
|
-
return n.forEach((
|
|
4866
|
-
const f = t.getValue(
|
|
4867
|
-
f && f.jump(a[
|
|
4865
|
+
return n.forEach((c) => {
|
|
4866
|
+
const f = t.getValue(c);
|
|
4867
|
+
f && f.jump(a[c]), e[c] = Je[c](l, o);
|
|
4868
4868
|
}), e;
|
|
4869
4869
|
}, Qh = (e, t, n = {}, r = {}) => {
|
|
4870
4870
|
t = { ...t }, r = { ...r };
|
|
@@ -4872,30 +4872,30 @@ const Zh = (e, t, n) => {
|
|
|
4872
4872
|
let o = [], s = !1;
|
|
4873
4873
|
const a = [];
|
|
4874
4874
|
if (i.forEach((l) => {
|
|
4875
|
-
const
|
|
4875
|
+
const c = e.getValue(l);
|
|
4876
4876
|
if (!e.hasValue(l))
|
|
4877
4877
|
return;
|
|
4878
|
-
let f = n[l],
|
|
4878
|
+
let f = n[l], u = rt(f);
|
|
4879
4879
|
const h = t[l];
|
|
4880
4880
|
let d;
|
|
4881
4881
|
if (Ht(h)) {
|
|
4882
4882
|
const p = h.length, m = h[0] === null ? 1 : 0;
|
|
4883
|
-
f = h[m],
|
|
4883
|
+
f = h[m], u = rt(f);
|
|
4884
4884
|
for (let g = m; g < p && h[g] !== null; g++)
|
|
4885
4885
|
d ? br(rt(h[g]) === d) : d = rt(h[g]);
|
|
4886
4886
|
} else
|
|
4887
4887
|
d = rt(h);
|
|
4888
|
-
if (
|
|
4889
|
-
if (Ki(
|
|
4890
|
-
const p =
|
|
4891
|
-
typeof p == "string" &&
|
|
4888
|
+
if (u !== d)
|
|
4889
|
+
if (Ki(u) && Ki(d)) {
|
|
4890
|
+
const p = c.get();
|
|
4891
|
+
typeof p == "string" && c.set(parseFloat(p)), typeof h == "string" ? t[l] = parseFloat(h) : Array.isArray(h) && d === C && (t[l] = h.map(parseFloat));
|
|
4892
4892
|
} else
|
|
4893
|
-
|
|
4893
|
+
u != null && u.transform && (d != null && d.transform) && (f === 0 || h === 0) ? f === 0 ? c.set(d.transform(f)) : t[l] = u.transform(h) : (s || (o = Jh(e), s = !0), a.push(l), r[l] = r[l] !== void 0 ? r[l] : t[l], c.jump(h));
|
|
4894
4894
|
}), a.length) {
|
|
4895
|
-
const l = a.indexOf("height") >= 0 ? window.pageYOffset : null,
|
|
4896
|
-
return o.length && o.forEach(([f,
|
|
4897
|
-
e.getValue(f).set(
|
|
4898
|
-
}), e.render(), sn && l !== null && window.scrollTo({ top: l }), { target:
|
|
4895
|
+
const l = a.indexOf("height") >= 0 ? window.pageYOffset : null, c = Zh(t, e, a);
|
|
4896
|
+
return o.length && o.forEach(([f, u]) => {
|
|
4897
|
+
e.getValue(f).set(u);
|
|
4898
|
+
}), e.render(), sn && l !== null && window.scrollTo({ top: l }), { target: c, transitionEnd: r };
|
|
4899
4899
|
} else
|
|
4900
4900
|
return { target: t, transitionEnd: r };
|
|
4901
4901
|
};
|
|
@@ -4918,9 +4918,9 @@ function rd(e, t, n) {
|
|
|
4918
4918
|
const { willChange: r } = t;
|
|
4919
4919
|
for (const i in t) {
|
|
4920
4920
|
const o = t[i], s = n[i];
|
|
4921
|
-
if (
|
|
4921
|
+
if (X(o))
|
|
4922
4922
|
e.addValue(i, o), Xt(r) && r.add(i);
|
|
4923
|
-
else if (
|
|
4923
|
+
else if (X(s))
|
|
4924
4924
|
e.addValue(i, Ye(o, { owner: e })), Xt(r) && r.remove(i);
|
|
4925
4925
|
else if (s !== o)
|
|
4926
4926
|
if (e.hasValue(i)) {
|
|
@@ -4951,10 +4951,10 @@ class od {
|
|
|
4951
4951
|
}, this.scheduleRender = () => M.render(this.render, !1, !0);
|
|
4952
4952
|
const { latestValues: a, renderState: l } = o;
|
|
4953
4953
|
this.latestValues = a, this.baseTarget = { ...a }, this.initialValues = n.initial ? { ...a } : {}, this.renderState = l, this.parent = t, this.props = n, this.presenceContext = r, this.depth = t ? t.depth + 1 : 0, this.reducedMotionConfig = i, this.options = s, this.isControllingVariants = an(n), this.isVariantNode = $s(n), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(t && t.current);
|
|
4954
|
-
const { willChange:
|
|
4955
|
-
for (const
|
|
4956
|
-
const h = f[
|
|
4957
|
-
a[
|
|
4954
|
+
const { willChange: c, ...f } = this.scrapeMotionValuesFromProps(n, {});
|
|
4955
|
+
for (const u in f) {
|
|
4956
|
+
const h = f[u];
|
|
4957
|
+
a[u] !== void 0 && X(h) && (h.set(a[u], !1), Xt(c) && c.add(u));
|
|
4958
4958
|
}
|
|
4959
4959
|
}
|
|
4960
4960
|
/**
|
|
@@ -4992,16 +4992,16 @@ class od {
|
|
|
4992
4992
|
loadFeatures({ children: t, ...n }, r, i, o) {
|
|
4993
4993
|
let s, a;
|
|
4994
4994
|
for (let l = 0; l < id; l++) {
|
|
4995
|
-
const
|
|
4996
|
-
h && (s = h), f(n) && (!this.features[
|
|
4995
|
+
const c = la[l], { isEnabled: f, Feature: u, ProjectionNode: h, MeasureLayout: d } = mt[c];
|
|
4996
|
+
h && (s = h), f(n) && (!this.features[c] && u && (this.features[c] = new u(this)), d && (a = d));
|
|
4997
4997
|
}
|
|
4998
4998
|
if ((this.type === "html" || this.type === "svg") && !this.projection && s) {
|
|
4999
4999
|
this.projection = new s(this.latestValues, this.parent && this.parent.projection);
|
|
5000
|
-
const { layoutId: l, layout:
|
|
5000
|
+
const { layoutId: l, layout: c, drag: f, dragConstraints: u, layoutScroll: h, layoutRoot: d } = n;
|
|
5001
5001
|
this.projection.setOptions({
|
|
5002
5002
|
layoutId: l,
|
|
5003
|
-
layout:
|
|
5004
|
-
alwaysMeasureLayout: !!f ||
|
|
5003
|
+
layout: c,
|
|
5004
|
+
alwaysMeasureLayout: !!f || u && qe(u),
|
|
5005
5005
|
visualElement: this,
|
|
5006
5006
|
scheduleRender: () => this.scheduleRender(),
|
|
5007
5007
|
/**
|
|
@@ -5011,7 +5011,7 @@ class od {
|
|
|
5011
5011
|
* ensuring it gets called if there's no potential layout animations.
|
|
5012
5012
|
*
|
|
5013
5013
|
*/
|
|
5014
|
-
animationType: typeof
|
|
5014
|
+
animationType: typeof c == "string" ? c : "both",
|
|
5015
5015
|
initialPromotionConfig: o,
|
|
5016
5016
|
layoutScroll: h,
|
|
5017
5017
|
layoutRoot: d
|
|
@@ -5034,7 +5034,7 @@ class od {
|
|
|
5034
5034
|
* removed with a re-render to work.
|
|
5035
5035
|
*/
|
|
5036
5036
|
measureViewportBox() {
|
|
5037
|
-
return this.current ? this.measureInstanceViewportBox(this.current, this.props) :
|
|
5037
|
+
return this.current ? this.measureInstanceViewportBox(this.current, this.props) : _();
|
|
5038
5038
|
}
|
|
5039
5039
|
getStaticValue(t) {
|
|
5040
5040
|
return this.latestValues[t];
|
|
@@ -5161,7 +5161,7 @@ class od {
|
|
|
5161
5161
|
if (r && i !== void 0)
|
|
5162
5162
|
return i;
|
|
5163
5163
|
const o = this.getBaseTargetFromProps(this.props, t);
|
|
5164
|
-
return o !== void 0 && !
|
|
5164
|
+
return o !== void 0 && !X(o) ? o : this.initialValues[t] !== void 0 && i === void 0 ? void 0 : this.baseTarget[t];
|
|
5165
5165
|
}
|
|
5166
5166
|
on(t, n) {
|
|
5167
5167
|
return this.events[t] || (this.events[t] = new Rr()), this.events[t].add(n);
|
|
@@ -5222,7 +5222,7 @@ class ld extends ca {
|
|
|
5222
5222
|
handleChildMotionValue() {
|
|
5223
5223
|
this.childSubscription && (this.childSubscription(), delete this.childSubscription);
|
|
5224
5224
|
const { children: t } = this.props;
|
|
5225
|
-
|
|
5225
|
+
X(t) && (this.childSubscription = t.on("change", (n) => {
|
|
5226
5226
|
this.current && (this.current.textContent = `${n}`);
|
|
5227
5227
|
}));
|
|
5228
5228
|
}
|
|
@@ -5245,7 +5245,7 @@ class cd extends ca {
|
|
|
5245
5245
|
return n = ro.has(n) ? n : cr(n), t.getAttribute(n);
|
|
5246
5246
|
}
|
|
5247
5247
|
measureInstanceViewportBox() {
|
|
5248
|
-
return
|
|
5248
|
+
return _();
|
|
5249
5249
|
}
|
|
5250
5250
|
scrapeMotionValuesFromProps(t, n) {
|
|
5251
5251
|
return so(t, n);
|
|
@@ -5272,8 +5272,8 @@ const ud = (e, t) => hr(e) ? new cd(t, { enableHardwareAcceleration: !1 }) : new
|
|
|
5272
5272
|
...fd
|
|
5273
5273
|
}, ua = /* @__PURE__ */ fc((e, t) => Hc(e, t, hd, ud));
|
|
5274
5274
|
function dd(e) {
|
|
5275
|
-
const { children: t, parentRef: n, onlyChild: r } = e, [i, o] =
|
|
5276
|
-
return
|
|
5275
|
+
const { children: t, parentRef: n, onlyChild: r } = e, [i, o] = x.useState({ top: 0, left: 0 });
|
|
5276
|
+
return x.useLayoutEffect(() => {
|
|
5277
5277
|
if (n.current) {
|
|
5278
5278
|
const s = n.current.getBoundingClientRect();
|
|
5279
5279
|
o({
|
|
@@ -5423,8 +5423,8 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5423
5423
|
for (var n = function(s, a) {
|
|
5424
5424
|
setTimeout(function() {
|
|
5425
5425
|
if (Array.isArray(Ee[t])) {
|
|
5426
|
-
var l = He.get(t),
|
|
5427
|
-
l instanceof SVGSVGElement &&
|
|
5426
|
+
var l = He.get(t), c = Ee[t][s];
|
|
5427
|
+
l instanceof SVGSVGElement && c(null, fa(l)), l instanceof Error && c(l), s === Ee[t].length - 1 && delete Ee[t];
|
|
5428
5428
|
}
|
|
5429
5429
|
}, 0);
|
|
5430
5430
|
}, r = 0, i = Ee[t].length; r < i; r++)
|
|
@@ -5445,13 +5445,13 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5445
5445
|
var a;
|
|
5446
5446
|
o ? He.set(t, o) : ((a = s.responseXML) === null || a === void 0 ? void 0 : a.documentElement) instanceof SVGSVGElement && He.set(t, s.responseXML.documentElement), Ed(t);
|
|
5447
5447
|
});
|
|
5448
|
-
},
|
|
5448
|
+
}, Pd = function(t, n, r) {
|
|
5449
5449
|
ha(t, n, function(i, o) {
|
|
5450
5450
|
var s;
|
|
5451
5451
|
i ? r(i) : ((s = o.responseXML) === null || s === void 0 ? void 0 : s.documentElement) instanceof SVGSVGElement && r(null, o.responseXML.documentElement);
|
|
5452
5452
|
});
|
|
5453
|
-
},
|
|
5454
|
-
return ++
|
|
5453
|
+
}, Ad = 0, Cd = function() {
|
|
5454
|
+
return ++Ad;
|
|
5455
5455
|
}, se = [], rs = {}, Rd = "http://www.w3.org/2000/svg", Dn = "http://www.w3.org/1999/xlink", is = function(t, n, r, i, o, s, a) {
|
|
5456
5456
|
var l = t.getAttribute("data-src") || t.getAttribute("src");
|
|
5457
5457
|
if (!l) {
|
|
@@ -5463,29 +5463,29 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5463
5463
|
return;
|
|
5464
5464
|
}
|
|
5465
5465
|
se.push(t), t.setAttribute("src", "");
|
|
5466
|
-
var
|
|
5467
|
-
|
|
5468
|
-
if (!
|
|
5466
|
+
var c = i ? Td : Pd;
|
|
5467
|
+
c(l, o, function(f, u) {
|
|
5468
|
+
if (!u) {
|
|
5469
5469
|
se.splice(se.indexOf(t), 1), t = null, a(f);
|
|
5470
5470
|
return;
|
|
5471
5471
|
}
|
|
5472
5472
|
var h = t.getAttribute("id");
|
|
5473
|
-
h &&
|
|
5473
|
+
h && u.setAttribute("id", h);
|
|
5474
5474
|
var d = t.getAttribute("title");
|
|
5475
|
-
d &&
|
|
5475
|
+
d && u.setAttribute("title", d);
|
|
5476
5476
|
var p = t.getAttribute("width");
|
|
5477
|
-
p &&
|
|
5477
|
+
p && u.setAttribute("width", p);
|
|
5478
5478
|
var m = t.getAttribute("height");
|
|
5479
|
-
m &&
|
|
5480
|
-
var g = Array.from(new Set(Ln(Ln(Ln([], (
|
|
5481
|
-
|
|
5482
|
-
var
|
|
5483
|
-
|
|
5484
|
-
var
|
|
5479
|
+
m && u.setAttribute("height", m);
|
|
5480
|
+
var g = Array.from(new Set(Ln(Ln(Ln([], (u.getAttribute("class") || "").split(" "), !0), ["injected-svg"], !1), (t.getAttribute("class") || "").split(" "), !0))).join(" ").trim();
|
|
5481
|
+
u.setAttribute("class", g);
|
|
5482
|
+
var v = t.getAttribute("style");
|
|
5483
|
+
v && u.setAttribute("style", v), u.setAttribute("data-src", l);
|
|
5484
|
+
var w = [].filter.call(t.attributes, function(z) {
|
|
5485
5485
|
return /^data-\w[\w-]*$/.test(z.name);
|
|
5486
5486
|
});
|
|
5487
|
-
if (Array.prototype.forEach.call(
|
|
5488
|
-
z.name && z.value &&
|
|
5487
|
+
if (Array.prototype.forEach.call(w, function(z) {
|
|
5488
|
+
z.name && z.value && u.setAttribute(z.name, z.value);
|
|
5489
5489
|
}), r) {
|
|
5490
5490
|
var y = {
|
|
5491
5491
|
clipPath: ["clip-path"],
|
|
@@ -5498,60 +5498,60 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5498
5498
|
path: [],
|
|
5499
5499
|
pattern: ["fill", "stroke"],
|
|
5500
5500
|
radialGradient: ["fill", "stroke"]
|
|
5501
|
-
}, S, T,
|
|
5501
|
+
}, S, E, T, P, A;
|
|
5502
5502
|
Object.keys(y).forEach(function(z) {
|
|
5503
|
-
S = z,
|
|
5503
|
+
S = z, T = y[z], E = u.querySelectorAll(S + "[id]");
|
|
5504
5504
|
for (var ge = function(Ie, gn) {
|
|
5505
|
-
|
|
5505
|
+
P = E[Ie].id, A = P + "-" + Cd();
|
|
5506
5506
|
var Oe;
|
|
5507
|
-
Array.prototype.forEach.call(
|
|
5508
|
-
Oe =
|
|
5507
|
+
Array.prototype.forEach.call(T, function(yn) {
|
|
5508
|
+
Oe = u.querySelectorAll("[" + yn + '*="' + P + '"]');
|
|
5509
5509
|
for (var Tt = 0, Ba = Oe.length; Tt < Ba; Tt++) {
|
|
5510
5510
|
var Nr = Oe[Tt].getAttribute(yn);
|
|
5511
|
-
Nr && !Nr.match(new RegExp('url\\("?#' +
|
|
5511
|
+
Nr && !Nr.match(new RegExp('url\\("?#' + P + '"?\\)')) || Oe[Tt].setAttribute(yn, "url(#" + A + ")");
|
|
5512
5512
|
}
|
|
5513
5513
|
});
|
|
5514
|
-
for (var ue =
|
|
5514
|
+
for (var ue = u.querySelectorAll("[*|href]"), We = [], Ue = 0, tt = ue.length; Ue < tt; Ue++) {
|
|
5515
5515
|
var Ve = ue[Ue].getAttributeNS(Dn, "href");
|
|
5516
|
-
Ve && Ve.toString() === "#" +
|
|
5516
|
+
Ve && Ve.toString() === "#" + E[Ie].id && We.push(ue[Ue]);
|
|
5517
5517
|
}
|
|
5518
5518
|
for (var te = 0, Fr = We.length; te < Fr; te++)
|
|
5519
|
-
We[te].setAttributeNS(Dn, "href", "#" +
|
|
5520
|
-
|
|
5521
|
-
}, Ne = 0, k =
|
|
5519
|
+
We[te].setAttributeNS(Dn, "href", "#" + A);
|
|
5520
|
+
E[Ie].id = A;
|
|
5521
|
+
}, Ne = 0, k = E.length; Ne < k; Ne++)
|
|
5522
5522
|
ge(Ne);
|
|
5523
5523
|
});
|
|
5524
5524
|
}
|
|
5525
|
-
|
|
5526
|
-
for (var O =
|
|
5527
|
-
|
|
5528
|
-
if (
|
|
5529
|
-
for (var re = 0,
|
|
5530
|
-
new Function(
|
|
5525
|
+
u.removeAttribute("xmlns:a");
|
|
5526
|
+
for (var O = u.querySelectorAll("script"), W = [], K, N, H = 0, U = O.length; H < U; H++)
|
|
5527
|
+
N = O[H].getAttribute("type"), (!N || N === "application/ecmascript" || N === "application/javascript" || N === "text/javascript") && (K = O[H].innerText || O[H].textContent, K && W.push(K), u.removeChild(O[H]));
|
|
5528
|
+
if (W.length > 0 && (n === "always" || n === "once" && !rs[l])) {
|
|
5529
|
+
for (var re = 0, B = W.length; re < B; re++)
|
|
5530
|
+
new Function(W[re])(window);
|
|
5531
5531
|
rs[l] = !0;
|
|
5532
5532
|
}
|
|
5533
|
-
var ie =
|
|
5533
|
+
var ie = u.querySelectorAll("style");
|
|
5534
5534
|
if (Array.prototype.forEach.call(ie, function(z) {
|
|
5535
5535
|
z.textContent += "";
|
|
5536
|
-
}),
|
|
5536
|
+
}), u.setAttribute("xmlns", Rd), u.setAttribute("xmlns:xlink", Dn), s(u), !t.parentNode) {
|
|
5537
5537
|
se.splice(se.indexOf(t), 1), t = null, a(new Error("Parent node is null"));
|
|
5538
5538
|
return;
|
|
5539
5539
|
}
|
|
5540
|
-
t.parentNode.replaceChild(
|
|
5540
|
+
t.parentNode.replaceChild(u, t), se.splice(se.indexOf(t), 1), t = null, a(null, u);
|
|
5541
5541
|
});
|
|
5542
5542
|
}, Od = function(t, n) {
|
|
5543
5543
|
var r = n === void 0 ? {} : n, i = r.afterAll, o = i === void 0 ? function() {
|
|
5544
5544
|
} : i, s = r.afterEach, a = s === void 0 ? function() {
|
|
5545
|
-
} : s, l = r.beforeEach,
|
|
5546
|
-
} : l, f = r.cacheRequests,
|
|
5545
|
+
} : s, l = r.beforeEach, c = l === void 0 ? function() {
|
|
5546
|
+
} : l, f = r.cacheRequests, u = f === void 0 ? !0 : f, h = r.evalScripts, d = h === void 0 ? "never" : h, p = r.httpRequestWithCredentials, m = p === void 0 ? !1 : p, g = r.renumerateIRIElements, v = g === void 0 ? !0 : g;
|
|
5547
5547
|
if (t && "length" in t)
|
|
5548
|
-
for (var
|
|
5549
|
-
is(t[y], d,
|
|
5550
|
-
a(
|
|
5548
|
+
for (var w = 0, y = 0, S = t.length; y < S; y++)
|
|
5549
|
+
is(t[y], d, v, u, m, c, function(E, T) {
|
|
5550
|
+
a(E, T), t && "length" in t && t.length === ++w && o(w);
|
|
5551
5551
|
});
|
|
5552
5552
|
else
|
|
5553
|
-
t ? is(t, d,
|
|
5554
|
-
a(
|
|
5553
|
+
t ? is(t, d, v, u, m, c, function(E, T) {
|
|
5554
|
+
a(E, T), o(1), t = null;
|
|
5555
5555
|
}) : o(0);
|
|
5556
5556
|
}, Vd = function(t) {
|
|
5557
5557
|
var n = (t == null ? void 0 : t.ownerDocument) || document;
|
|
@@ -5580,11 +5580,11 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5580
5580
|
return n.renderSVG = function() {
|
|
5581
5581
|
var i = this;
|
|
5582
5582
|
if (this.reactWrapper instanceof Vd(this.reactWrapper).Node) {
|
|
5583
|
-
var o = this.props, s = o.desc, a = o.evalScripts, l = o.httpRequestWithCredentials,
|
|
5584
|
-
g === "svg" ? (
|
|
5585
|
-
var y = function(
|
|
5583
|
+
var o = this.props, s = o.desc, a = o.evalScripts, l = o.httpRequestWithCredentials, c = o.renumerateIRIElements, f = o.src, u = o.title, h = o.useRequestCache, d = this.props.onError, p = this.props.beforeInjection, m = this.props.afterInjection, g = this.props.wrapper, v, w;
|
|
5584
|
+
g === "svg" ? (v = document.createElementNS(Vt, g), v.setAttribute("xmlns", Vt), v.setAttribute("xmlns:xlink", ss), w = document.createElementNS(Vt, g)) : (v = document.createElement(g), w = document.createElement(g)), v.appendChild(w), w.dataset.src = f, this.nonReactWrapper = this.reactWrapper.appendChild(v);
|
|
5585
|
+
var y = function(P) {
|
|
5586
5586
|
if (i.removeSVG(), !i._isMounted) {
|
|
5587
|
-
d(
|
|
5587
|
+
d(P);
|
|
5588
5588
|
return;
|
|
5589
5589
|
}
|
|
5590
5590
|
i.setState(function() {
|
|
@@ -5593,11 +5593,11 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5593
5593
|
isLoading: !1
|
|
5594
5594
|
};
|
|
5595
5595
|
}, function() {
|
|
5596
|
-
d(
|
|
5596
|
+
d(P);
|
|
5597
5597
|
});
|
|
5598
|
-
}, S = function(
|
|
5599
|
-
if (
|
|
5600
|
-
y(
|
|
5598
|
+
}, S = function(P, A) {
|
|
5599
|
+
if (P) {
|
|
5600
|
+
y(P);
|
|
5601
5601
|
return;
|
|
5602
5602
|
}
|
|
5603
5603
|
i._isMounted && i.setState(function() {
|
|
@@ -5606,37 +5606,37 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5606
5606
|
};
|
|
5607
5607
|
}, function() {
|
|
5608
5608
|
try {
|
|
5609
|
-
m(
|
|
5609
|
+
m(A);
|
|
5610
5610
|
} catch (O) {
|
|
5611
5611
|
y(O);
|
|
5612
5612
|
}
|
|
5613
5613
|
});
|
|
5614
|
-
},
|
|
5615
|
-
if (
|
|
5616
|
-
var
|
|
5617
|
-
|
|
5614
|
+
}, E = function(P) {
|
|
5615
|
+
if (P.setAttribute("role", "img"), s) {
|
|
5616
|
+
var A = P.querySelector(":scope > desc");
|
|
5617
|
+
A && P.removeChild(A);
|
|
5618
5618
|
var O = document.createElement("desc");
|
|
5619
|
-
O.innerHTML = s,
|
|
5619
|
+
O.innerHTML = s, P.prepend(O);
|
|
5620
5620
|
}
|
|
5621
|
-
if (
|
|
5622
|
-
var
|
|
5623
|
-
|
|
5624
|
-
var
|
|
5625
|
-
|
|
5621
|
+
if (u) {
|
|
5622
|
+
var W = P.querySelector(":scope > title");
|
|
5623
|
+
W && P.removeChild(W);
|
|
5624
|
+
var K = document.createElement("title");
|
|
5625
|
+
K.innerHTML = u, P.prepend(K);
|
|
5626
5626
|
}
|
|
5627
5627
|
try {
|
|
5628
|
-
p(
|
|
5629
|
-
} catch (
|
|
5630
|
-
y(
|
|
5628
|
+
p(P);
|
|
5629
|
+
} catch (N) {
|
|
5630
|
+
y(N);
|
|
5631
5631
|
}
|
|
5632
5632
|
};
|
|
5633
|
-
Od(
|
|
5633
|
+
Od(w, {
|
|
5634
5634
|
afterEach: S,
|
|
5635
|
-
beforeEach:
|
|
5635
|
+
beforeEach: E,
|
|
5636
5636
|
cacheRequests: h,
|
|
5637
5637
|
evalScripts: a,
|
|
5638
5638
|
httpRequestWithCredentials: l,
|
|
5639
|
-
renumerateIRIElements:
|
|
5639
|
+
renumerateIRIElements: c
|
|
5640
5640
|
});
|
|
5641
5641
|
}
|
|
5642
5642
|
}, n.removeSVG = function() {
|
|
@@ -5660,15 +5660,15 @@ var He = /* @__PURE__ */ new Map(), fa = function(t) {
|
|
|
5660
5660
|
i.httpRequestWithCredentials;
|
|
5661
5661
|
var s = i.loading;
|
|
5662
5662
|
i.renumerateIRIElements, i.src, i.title, i.useRequestCache;
|
|
5663
|
-
var a = i.wrapper, l = md(i, Md),
|
|
5664
|
-
return /* @__PURE__ */
|
|
5663
|
+
var a = i.wrapper, l = md(i, Md), c = a;
|
|
5664
|
+
return /* @__PURE__ */ x.createElement(c, Yt({}, l, {
|
|
5665
5665
|
ref: this.refCallback
|
|
5666
5666
|
}, a === "svg" ? {
|
|
5667
5667
|
xmlns: Vt,
|
|
5668
5668
|
xmlnsXlink: ss
|
|
5669
|
-
} : {}), this.state.isLoading && s && /* @__PURE__ */
|
|
5669
|
+
} : {}), this.state.isLoading && s && /* @__PURE__ */ x.createElement(s, null), this.state.hasError && o && /* @__PURE__ */ x.createElement(o, null));
|
|
5670
5670
|
}, t;
|
|
5671
|
-
}(
|
|
5671
|
+
}(x.Component);
|
|
5672
5672
|
Or.defaultProps = {
|
|
5673
5673
|
afterInjection: function() {
|
|
5674
5674
|
},
|
|
@@ -5687,48 +5687,48 @@ Or.defaultProps = {
|
|
|
5687
5687
|
wrapper: "div"
|
|
5688
5688
|
};
|
|
5689
5689
|
Or.propTypes = {
|
|
5690
|
-
afterInjection:
|
|
5691
|
-
beforeInjection:
|
|
5692
|
-
desc:
|
|
5693
|
-
evalScripts:
|
|
5694
|
-
fallback:
|
|
5695
|
-
httpRequestWithCredentials:
|
|
5696
|
-
loading:
|
|
5697
|
-
onError:
|
|
5698
|
-
renumerateIRIElements:
|
|
5699
|
-
src:
|
|
5700
|
-
title:
|
|
5701
|
-
useRequestCache:
|
|
5702
|
-
wrapper:
|
|
5690
|
+
afterInjection: I.func,
|
|
5691
|
+
beforeInjection: I.func,
|
|
5692
|
+
desc: I.string,
|
|
5693
|
+
evalScripts: I.oneOf(["always", "once", "never"]),
|
|
5694
|
+
fallback: I.oneOfType([I.func, I.object, I.string]),
|
|
5695
|
+
httpRequestWithCredentials: I.bool,
|
|
5696
|
+
loading: I.oneOfType([I.func, I.object, I.string]),
|
|
5697
|
+
onError: I.func,
|
|
5698
|
+
renumerateIRIElements: I.bool,
|
|
5699
|
+
src: I.string.isRequired,
|
|
5700
|
+
title: I.string,
|
|
5701
|
+
useRequestCache: I.bool,
|
|
5702
|
+
wrapper: I.oneOf(["div", "span", "svg"])
|
|
5703
5703
|
};
|
|
5704
5704
|
function da({ item: e, level: t = 0, ...n }) {
|
|
5705
|
-
var
|
|
5706
|
-
const { isActive: r, isCollapsed: i, expanded: o, toggleExpand: s } = n, a = `level-${t}`, l = i ? "collapsed" : "expanded",
|
|
5707
|
-
function m(
|
|
5708
|
-
var
|
|
5709
|
-
const { level:
|
|
5710
|
-
return !
|
|
5705
|
+
var w;
|
|
5706
|
+
const { isActive: r, isCollapsed: i, expanded: o, toggleExpand: s } = n, a = `level-${t}`, l = i ? "collapsed" : "expanded", c = r(e.id) ? "active" : "", f = (y, S = a) => `${y} ${S} ${l} ${c}`, u = !!((w = e.children) != null && w.length), [h, d] = x.useState(!1), p = x.useRef();
|
|
5707
|
+
function m(y) {
|
|
5708
|
+
var P;
|
|
5709
|
+
const { level: S, hovered: E, parentRef: T } = y;
|
|
5710
|
+
return !u || i && S >= 2 && !E ? null : /* @__PURE__ */ R.jsx(
|
|
5711
5711
|
dd,
|
|
5712
5712
|
{
|
|
5713
|
-
parentRef:
|
|
5714
|
-
onlyChild: !i || i &&
|
|
5713
|
+
parentRef: T,
|
|
5714
|
+
onlyChild: !i || i && S < 2,
|
|
5715
5715
|
children: /* @__PURE__ */ R.jsx(
|
|
5716
5716
|
ua.div,
|
|
5717
5717
|
{
|
|
5718
|
-
className: f("menu-item__dropdown", `level-${
|
|
5718
|
+
className: f("menu-item__dropdown", `level-${S}`),
|
|
5719
5719
|
initial: { height: i ? "auto" : 0 },
|
|
5720
5720
|
animate: {
|
|
5721
5721
|
height: i || o(e.id) ? "auto" : 0
|
|
5722
5722
|
},
|
|
5723
5723
|
transition: { duration: 0.2 },
|
|
5724
|
-
children: (
|
|
5724
|
+
children: (P = e.children) == null ? void 0 : P.map((A) => /* @__PURE__ */ x.createElement(da, { ...n, key: A.id, item: A, level: S }))
|
|
5725
5725
|
},
|
|
5726
5726
|
+i
|
|
5727
5727
|
)
|
|
5728
5728
|
}
|
|
5729
5729
|
);
|
|
5730
5730
|
}
|
|
5731
|
-
const g =
|
|
5731
|
+
const g = e.path && n.replacePath ? n.replacePath(e.path) : e.path || "#", v = u ? "div" : yl;
|
|
5732
5732
|
return /* @__PURE__ */ R.jsxs(
|
|
5733
5733
|
"div",
|
|
5734
5734
|
{
|
|
@@ -5738,20 +5738,20 @@ function da({ item: e, level: t = 0, ...n }) {
|
|
|
5738
5738
|
onMouseLeave: () => i && d(!1),
|
|
5739
5739
|
children: [
|
|
5740
5740
|
/* @__PURE__ */ R.jsxs(
|
|
5741
|
-
|
|
5741
|
+
v,
|
|
5742
5742
|
{
|
|
5743
|
-
...
|
|
5743
|
+
...v === "div" ? {} : { to: g },
|
|
5744
5744
|
style: {
|
|
5745
5745
|
paddingLeft: `${i ? "0.5rem" : `${t * 1}rem`}`
|
|
5746
5746
|
},
|
|
5747
5747
|
className: f("menu-item__link"),
|
|
5748
|
-
onClick: (
|
|
5749
|
-
|
|
5748
|
+
onClick: (y) => {
|
|
5749
|
+
u && (y.preventDefault(), i || s(e.id));
|
|
5750
5750
|
},
|
|
5751
5751
|
children: [
|
|
5752
5752
|
t !== 0 && /* @__PURE__ */ R.jsx(Ld, { cls: f, item: e }),
|
|
5753
5753
|
/* @__PURE__ */ R.jsx("span", { className: f("menu-item__label"), children: e.name }),
|
|
5754
|
-
|
|
5754
|
+
u && /* @__PURE__ */ R.jsx("div", { className: f("menu-item__icon-arrow__wrapper"), children: /* @__PURE__ */ R.jsx(
|
|
5755
5755
|
pd,
|
|
5756
5756
|
{
|
|
5757
5757
|
className: f(
|
|
@@ -5770,7 +5770,7 @@ function da({ item: e, level: t = 0, ...n }) {
|
|
|
5770
5770
|
}
|
|
5771
5771
|
function Ld({ item: e, cls: t }) {
|
|
5772
5772
|
var s, a;
|
|
5773
|
-
const [n, r] =
|
|
5773
|
+
const [n, r] = x.useState(!1), i = () => {
|
|
5774
5774
|
r(!0);
|
|
5775
5775
|
}, o = (s = e.icon) == null ? void 0 : s.endsWith(".svg");
|
|
5776
5776
|
return /* @__PURE__ */ R.jsx("div", { className: t("menu-item__icon"), children: n ? /* @__PURE__ */ R.jsx(
|
|
@@ -6017,7 +6017,7 @@ const hp = (e) => {
|
|
|
6017
6017
|
return r;
|
|
6018
6018
|
};
|
|
6019
6019
|
return n(e, 0);
|
|
6020
|
-
}, dp = ce("AsyncFunction"), pp = (e) => e && (dn(e) || ee(e)) && ee(e.then) && ee(e.catch),
|
|
6020
|
+
}, dp = ce("AsyncFunction"), pp = (e) => e && (dn(e) || ee(e)) && ee(e.then) && ee(e.catch), b = {
|
|
6021
6021
|
isArray: et,
|
|
6022
6022
|
isArrayBuffer: ga,
|
|
6023
6023
|
isBuffer: _d,
|
|
@@ -6074,7 +6074,7 @@ const hp = (e) => {
|
|
|
6074
6074
|
function V(e, t, n, r, i) {
|
|
6075
6075
|
Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), i && (this.response = i);
|
|
6076
6076
|
}
|
|
6077
|
-
|
|
6077
|
+
b.inherits(V, Error, {
|
|
6078
6078
|
toJSON: function() {
|
|
6079
6079
|
return {
|
|
6080
6080
|
// Standard
|
|
@@ -6089,7 +6089,7 @@ v.inherits(V, Error, {
|
|
|
6089
6089
|
columnNumber: this.columnNumber,
|
|
6090
6090
|
stack: this.stack,
|
|
6091
6091
|
// Axios
|
|
6092
|
-
config:
|
|
6092
|
+
config: b.toJSONObject(this.config),
|
|
6093
6093
|
code: this.code,
|
|
6094
6094
|
status: this.response && this.response.status ? this.response.status : null
|
|
6095
6095
|
};
|
|
@@ -6117,87 +6117,87 @@ Object.defineProperties(V, Ta);
|
|
|
6117
6117
|
Object.defineProperty(Ea, "isAxiosError", { value: !0 });
|
|
6118
6118
|
V.from = (e, t, n, r, i, o) => {
|
|
6119
6119
|
const s = Object.create(Ea);
|
|
6120
|
-
return
|
|
6120
|
+
return b.toFlatObject(e, s, function(l) {
|
|
6121
6121
|
return l !== Error.prototype;
|
|
6122
6122
|
}, (a) => a !== "isAxiosError"), V.call(s, e.message, t, n, r, i), s.cause = e, s.name = e.name, o && Object.assign(s, o), s;
|
|
6123
6123
|
};
|
|
6124
6124
|
const mp = null;
|
|
6125
6125
|
function nr(e) {
|
|
6126
|
-
return
|
|
6126
|
+
return b.isPlainObject(e) || b.isArray(e);
|
|
6127
6127
|
}
|
|
6128
|
-
function
|
|
6129
|
-
return
|
|
6128
|
+
function Pa(e) {
|
|
6129
|
+
return b.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
6130
6130
|
}
|
|
6131
6131
|
function cs(e, t, n) {
|
|
6132
6132
|
return e ? e.concat(t).map(function(i, o) {
|
|
6133
|
-
return i =
|
|
6133
|
+
return i = Pa(i), !n && o ? "[" + i + "]" : i;
|
|
6134
6134
|
}).join(n ? "." : "") : t;
|
|
6135
6135
|
}
|
|
6136
6136
|
function gp(e) {
|
|
6137
|
-
return
|
|
6137
|
+
return b.isArray(e) && !e.some(nr);
|
|
6138
6138
|
}
|
|
6139
|
-
const yp =
|
|
6139
|
+
const yp = b.toFlatObject(b, {}, null, function(t) {
|
|
6140
6140
|
return /^is[A-Z]/.test(t);
|
|
6141
6141
|
});
|
|
6142
6142
|
function pn(e, t, n) {
|
|
6143
|
-
if (!
|
|
6143
|
+
if (!b.isObject(e))
|
|
6144
6144
|
throw new TypeError("target must be an object");
|
|
6145
|
-
t = t || new FormData(), n =
|
|
6145
|
+
t = t || new FormData(), n = b.toFlatObject(n, {
|
|
6146
6146
|
metaTokens: !0,
|
|
6147
6147
|
dots: !1,
|
|
6148
6148
|
indexes: !1
|
|
6149
6149
|
}, !1, function(m, g) {
|
|
6150
|
-
return !
|
|
6150
|
+
return !b.isUndefined(g[m]);
|
|
6151
6151
|
});
|
|
6152
|
-
const r = n.metaTokens, i = n.visitor || f, o = n.dots, s = n.indexes, l = (n.Blob || typeof Blob < "u" && Blob) &&
|
|
6153
|
-
if (!
|
|
6152
|
+
const r = n.metaTokens, i = n.visitor || f, o = n.dots, s = n.indexes, l = (n.Blob || typeof Blob < "u" && Blob) && b.isSpecCompliantForm(t);
|
|
6153
|
+
if (!b.isFunction(i))
|
|
6154
6154
|
throw new TypeError("visitor must be a function");
|
|
6155
|
-
function
|
|
6155
|
+
function c(p) {
|
|
6156
6156
|
if (p === null)
|
|
6157
6157
|
return "";
|
|
6158
|
-
if (
|
|
6158
|
+
if (b.isDate(p))
|
|
6159
6159
|
return p.toISOString();
|
|
6160
|
-
if (!l &&
|
|
6160
|
+
if (!l && b.isBlob(p))
|
|
6161
6161
|
throw new V("Blob is not supported. Use a Buffer instead.");
|
|
6162
|
-
return
|
|
6162
|
+
return b.isArrayBuffer(p) || b.isTypedArray(p) ? l && typeof Blob == "function" ? new Blob([p]) : Buffer.from(p) : p;
|
|
6163
6163
|
}
|
|
6164
6164
|
function f(p, m, g) {
|
|
6165
|
-
let
|
|
6165
|
+
let v = p;
|
|
6166
6166
|
if (p && !g && typeof p == "object") {
|
|
6167
|
-
if (
|
|
6167
|
+
if (b.endsWith(m, "{}"))
|
|
6168
6168
|
m = r ? m : m.slice(0, -2), p = JSON.stringify(p);
|
|
6169
|
-
else if (
|
|
6170
|
-
return m =
|
|
6171
|
-
!(
|
|
6169
|
+
else if (b.isArray(p) && gp(p) || (b.isFileList(p) || b.endsWith(m, "[]")) && (v = b.toArray(p)))
|
|
6170
|
+
return m = Pa(m), v.forEach(function(y, S) {
|
|
6171
|
+
!(b.isUndefined(y) || y === null) && t.append(
|
|
6172
6172
|
// eslint-disable-next-line no-nested-ternary
|
|
6173
6173
|
s === !0 ? cs([m], S, o) : s === null ? m : m + "[]",
|
|
6174
|
-
|
|
6174
|
+
c(y)
|
|
6175
6175
|
);
|
|
6176
6176
|
}), !1;
|
|
6177
6177
|
}
|
|
6178
|
-
return nr(p) ? !0 : (t.append(cs(g, m, o),
|
|
6178
|
+
return nr(p) ? !0 : (t.append(cs(g, m, o), c(p)), !1);
|
|
6179
6179
|
}
|
|
6180
|
-
const
|
|
6180
|
+
const u = [], h = Object.assign(yp, {
|
|
6181
6181
|
defaultVisitor: f,
|
|
6182
|
-
convertValue:
|
|
6182
|
+
convertValue: c,
|
|
6183
6183
|
isVisitable: nr
|
|
6184
6184
|
});
|
|
6185
6185
|
function d(p, m) {
|
|
6186
|
-
if (!
|
|
6187
|
-
if (
|
|
6186
|
+
if (!b.isUndefined(p)) {
|
|
6187
|
+
if (u.indexOf(p) !== -1)
|
|
6188
6188
|
throw Error("Circular reference detected in " + m.join("."));
|
|
6189
|
-
|
|
6190
|
-
(!(
|
|
6189
|
+
u.push(p), b.forEach(p, function(v, w) {
|
|
6190
|
+
(!(b.isUndefined(v) || v === null) && i.call(
|
|
6191
6191
|
t,
|
|
6192
|
-
|
|
6193
|
-
|
|
6192
|
+
v,
|
|
6193
|
+
b.isString(w) ? w.trim() : w,
|
|
6194
6194
|
m,
|
|
6195
6195
|
h
|
|
6196
|
-
)) === !0 && d(
|
|
6197
|
-
}),
|
|
6196
|
+
)) === !0 && d(v, m ? m.concat(w) : [w]);
|
|
6197
|
+
}), u.pop();
|
|
6198
6198
|
}
|
|
6199
6199
|
}
|
|
6200
|
-
if (!
|
|
6200
|
+
if (!b.isObject(e))
|
|
6201
6201
|
throw new TypeError("data must be an object");
|
|
6202
6202
|
return d(e), t;
|
|
6203
6203
|
}
|
|
@@ -6218,11 +6218,11 @@ function us(e) {
|
|
|
6218
6218
|
function kr(e, t) {
|
|
6219
6219
|
this._pairs = [], e && pn(e, this, t);
|
|
6220
6220
|
}
|
|
6221
|
-
const
|
|
6222
|
-
|
|
6221
|
+
const Aa = kr.prototype;
|
|
6222
|
+
Aa.append = function(t, n) {
|
|
6223
6223
|
this._pairs.push([t, n]);
|
|
6224
6224
|
};
|
|
6225
|
-
|
|
6225
|
+
Aa.toString = function(t) {
|
|
6226
6226
|
const n = t ? function(r) {
|
|
6227
6227
|
return t.call(this, r, us);
|
|
6228
6228
|
} : us;
|
|
@@ -6238,7 +6238,7 @@ function Ca(e, t, n) {
|
|
|
6238
6238
|
return e;
|
|
6239
6239
|
const r = n && n.encode || vp, i = n && n.serialize;
|
|
6240
6240
|
let o;
|
|
6241
|
-
if (i ? o = i(t, n) : o =
|
|
6241
|
+
if (i ? o = i(t, n) : o = b.isURLSearchParams(t) ? t.toString() : new kr(t, n).toString(r), o) {
|
|
6242
6242
|
const s = e.indexOf("#");
|
|
6243
6243
|
s !== -1 && (e = e.slice(0, s)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
|
|
6244
6244
|
}
|
|
@@ -6293,7 +6293,7 @@ class bp {
|
|
|
6293
6293
|
* @returns {void}
|
|
6294
6294
|
*/
|
|
6295
6295
|
forEach(t) {
|
|
6296
|
-
|
|
6296
|
+
b.forEach(this.handlers, function(r) {
|
|
6297
6297
|
r !== null && t(r);
|
|
6298
6298
|
});
|
|
6299
6299
|
}
|
|
@@ -6310,25 +6310,25 @@ const fs = bp, Ra = {
|
|
|
6310
6310
|
Blob: Sp
|
|
6311
6311
|
},
|
|
6312
6312
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
6313
|
-
}, Oa = typeof window < "u" && typeof document < "u", Tp = ((e) => Oa && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator < "u" && navigator.product),
|
|
6314
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function")(),
|
|
6313
|
+
}, Oa = typeof window < "u" && typeof document < "u", Tp = ((e) => Oa && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator < "u" && navigator.product), Pp = (() => typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
6314
|
+
self instanceof WorkerGlobalScope && typeof self.importScripts == "function")(), Ap = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
6315
6315
|
__proto__: null,
|
|
6316
6316
|
hasBrowserEnv: Oa,
|
|
6317
6317
|
hasStandardBrowserEnv: Tp,
|
|
6318
|
-
hasStandardBrowserWebWorkerEnv:
|
|
6318
|
+
hasStandardBrowserWebWorkerEnv: Pp
|
|
6319
6319
|
}, Symbol.toStringTag, { value: "Module" })), ae = {
|
|
6320
|
-
...
|
|
6320
|
+
...Ap,
|
|
6321
6321
|
...Ep
|
|
6322
6322
|
};
|
|
6323
6323
|
function Cp(e, t) {
|
|
6324
6324
|
return pn(e, new ae.classes.URLSearchParams(), Object.assign({
|
|
6325
6325
|
visitor: function(n, r, i, o) {
|
|
6326
|
-
return ae.isNode &&
|
|
6326
|
+
return ae.isNode && b.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
|
|
6327
6327
|
}
|
|
6328
6328
|
}, t));
|
|
6329
6329
|
}
|
|
6330
6330
|
function Rp(e) {
|
|
6331
|
-
return
|
|
6331
|
+
return b.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
|
|
6332
6332
|
}
|
|
6333
6333
|
function Op(e) {
|
|
6334
6334
|
const t = {}, n = Object.keys(e);
|
|
@@ -6345,20 +6345,20 @@ function Va(e) {
|
|
|
6345
6345
|
if (s === "__proto__")
|
|
6346
6346
|
return !0;
|
|
6347
6347
|
const a = Number.isFinite(+s), l = o >= n.length;
|
|
6348
|
-
return s = !s &&
|
|
6348
|
+
return s = !s && b.isArray(i) ? i.length : s, l ? (b.hasOwnProp(i, s) ? i[s] = [i[s], r] : i[s] = r, !a) : ((!i[s] || !b.isObject(i[s])) && (i[s] = []), t(n, r, i[s], o) && b.isArray(i[s]) && (i[s] = Op(i[s])), !a);
|
|
6349
6349
|
}
|
|
6350
|
-
if (
|
|
6350
|
+
if (b.isFormData(e) && b.isFunction(e.entries)) {
|
|
6351
6351
|
const n = {};
|
|
6352
|
-
return
|
|
6352
|
+
return b.forEachEntry(e, (r, i) => {
|
|
6353
6353
|
t(Rp(r), i, n, 0);
|
|
6354
6354
|
}), n;
|
|
6355
6355
|
}
|
|
6356
6356
|
return null;
|
|
6357
6357
|
}
|
|
6358
6358
|
function Vp(e, t, n) {
|
|
6359
|
-
if (
|
|
6359
|
+
if (b.isString(e))
|
|
6360
6360
|
try {
|
|
6361
|
-
return (t || JSON.parse)(e),
|
|
6361
|
+
return (t || JSON.parse)(e), b.trim(e);
|
|
6362
6362
|
} catch (r) {
|
|
6363
6363
|
if (r.name !== "SyntaxError")
|
|
6364
6364
|
throw r;
|
|
@@ -6369,20 +6369,20 @@ const Mr = {
|
|
|
6369
6369
|
transitional: Ra,
|
|
6370
6370
|
adapter: ["xhr", "http"],
|
|
6371
6371
|
transformRequest: [function(t, n) {
|
|
6372
|
-
const r = n.getContentType() || "", i = r.indexOf("application/json") > -1, o =
|
|
6373
|
-
if (o &&
|
|
6372
|
+
const r = n.getContentType() || "", i = r.indexOf("application/json") > -1, o = b.isObject(t);
|
|
6373
|
+
if (o && b.isHTMLForm(t) && (t = new FormData(t)), b.isFormData(t))
|
|
6374
6374
|
return i && i ? JSON.stringify(Va(t)) : t;
|
|
6375
|
-
if (
|
|
6375
|
+
if (b.isArrayBuffer(t) || b.isBuffer(t) || b.isStream(t) || b.isFile(t) || b.isBlob(t))
|
|
6376
6376
|
return t;
|
|
6377
|
-
if (
|
|
6377
|
+
if (b.isArrayBufferView(t))
|
|
6378
6378
|
return t.buffer;
|
|
6379
|
-
if (
|
|
6379
|
+
if (b.isURLSearchParams(t))
|
|
6380
6380
|
return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
|
|
6381
6381
|
let a;
|
|
6382
6382
|
if (o) {
|
|
6383
6383
|
if (r.indexOf("application/x-www-form-urlencoded") > -1)
|
|
6384
6384
|
return Cp(t, this.formSerializer).toString();
|
|
6385
|
-
if ((a =
|
|
6385
|
+
if ((a = b.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
|
|
6386
6386
|
const l = this.env && this.env.FormData;
|
|
6387
6387
|
return pn(
|
|
6388
6388
|
a ? { "files[]": t } : t,
|
|
@@ -6395,7 +6395,7 @@ const Mr = {
|
|
|
6395
6395
|
}],
|
|
6396
6396
|
transformResponse: [function(t) {
|
|
6397
6397
|
const n = this.transitional || Mr.transitional, r = n && n.forcedJSONParsing, i = this.responseType === "json";
|
|
6398
|
-
if (t &&
|
|
6398
|
+
if (t && b.isString(t) && (r && !this.responseType || i)) {
|
|
6399
6399
|
const s = !(n && n.silentJSONParsing) && i;
|
|
6400
6400
|
try {
|
|
6401
6401
|
return JSON.parse(t);
|
|
@@ -6429,10 +6429,10 @@ const Mr = {
|
|
|
6429
6429
|
}
|
|
6430
6430
|
}
|
|
6431
6431
|
};
|
|
6432
|
-
|
|
6432
|
+
b.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
6433
6433
|
Mr.headers[e] = {};
|
|
6434
6434
|
});
|
|
6435
|
-
const Lr = Mr, kp =
|
|
6435
|
+
const Lr = Mr, kp = b.toObjectSet([
|
|
6436
6436
|
"age",
|
|
6437
6437
|
"authorization",
|
|
6438
6438
|
"content-length",
|
|
@@ -6462,7 +6462,7 @@ function st(e) {
|
|
|
6462
6462
|
return e && String(e).trim().toLowerCase();
|
|
6463
6463
|
}
|
|
6464
6464
|
function _t(e) {
|
|
6465
|
-
return e === !1 || e == null ? e :
|
|
6465
|
+
return e === !1 || e == null ? e : b.isArray(e) ? e.map(_t) : String(e);
|
|
6466
6466
|
}
|
|
6467
6467
|
function Lp(e) {
|
|
6468
6468
|
const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
@@ -6473,12 +6473,12 @@ function Lp(e) {
|
|
|
6473
6473
|
}
|
|
6474
6474
|
const Dp = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
6475
6475
|
function _n(e, t, n, r, i) {
|
|
6476
|
-
if (
|
|
6476
|
+
if (b.isFunction(r))
|
|
6477
6477
|
return r.call(this, t, n);
|
|
6478
|
-
if (i && (t = n), !!
|
|
6479
|
-
if (
|
|
6478
|
+
if (i && (t = n), !!b.isString(t)) {
|
|
6479
|
+
if (b.isString(r))
|
|
6480
6480
|
return t.indexOf(r) !== -1;
|
|
6481
|
-
if (
|
|
6481
|
+
if (b.isRegExp(r))
|
|
6482
6482
|
return r.test(t);
|
|
6483
6483
|
}
|
|
6484
6484
|
}
|
|
@@ -6486,7 +6486,7 @@ function jp(e) {
|
|
|
6486
6486
|
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
|
|
6487
6487
|
}
|
|
6488
6488
|
function _p(e, t) {
|
|
6489
|
-
const n =
|
|
6489
|
+
const n = b.toCamelCase(" " + t);
|
|
6490
6490
|
["get", "set", "has"].forEach((r) => {
|
|
6491
6491
|
Object.defineProperty(e, r + n, {
|
|
6492
6492
|
value: function(i, o, s) {
|
|
@@ -6502,28 +6502,28 @@ class mn {
|
|
|
6502
6502
|
}
|
|
6503
6503
|
set(t, n, r) {
|
|
6504
6504
|
const i = this;
|
|
6505
|
-
function o(a, l,
|
|
6505
|
+
function o(a, l, c) {
|
|
6506
6506
|
const f = st(l);
|
|
6507
6507
|
if (!f)
|
|
6508
6508
|
throw new Error("header name must be a non-empty string");
|
|
6509
|
-
const
|
|
6510
|
-
(!
|
|
6509
|
+
const u = b.findKey(i, f);
|
|
6510
|
+
(!u || i[u] === void 0 || c === !0 || c === void 0 && i[u] !== !1) && (i[u || l] = _t(a));
|
|
6511
6511
|
}
|
|
6512
|
-
const s = (a, l) =>
|
|
6513
|
-
return
|
|
6512
|
+
const s = (a, l) => b.forEach(a, (c, f) => o(c, f, l));
|
|
6513
|
+
return b.isPlainObject(t) || t instanceof this.constructor ? s(t, n) : b.isString(t) && (t = t.trim()) && !Dp(t) ? s(Mp(t), n) : t != null && o(n, t, r), this;
|
|
6514
6514
|
}
|
|
6515
6515
|
get(t, n) {
|
|
6516
6516
|
if (t = st(t), t) {
|
|
6517
|
-
const r =
|
|
6517
|
+
const r = b.findKey(this, t);
|
|
6518
6518
|
if (r) {
|
|
6519
6519
|
const i = this[r];
|
|
6520
6520
|
if (!n)
|
|
6521
6521
|
return i;
|
|
6522
6522
|
if (n === !0)
|
|
6523
6523
|
return Lp(i);
|
|
6524
|
-
if (
|
|
6524
|
+
if (b.isFunction(n))
|
|
6525
6525
|
return n.call(this, i, r);
|
|
6526
|
-
if (
|
|
6526
|
+
if (b.isRegExp(n))
|
|
6527
6527
|
return n.exec(i);
|
|
6528
6528
|
throw new TypeError("parser must be boolean|regexp|function");
|
|
6529
6529
|
}
|
|
@@ -6531,7 +6531,7 @@ class mn {
|
|
|
6531
6531
|
}
|
|
6532
6532
|
has(t, n) {
|
|
6533
6533
|
if (t = st(t), t) {
|
|
6534
|
-
const r =
|
|
6534
|
+
const r = b.findKey(this, t);
|
|
6535
6535
|
return !!(r && this[r] !== void 0 && (!n || _n(this, this[r], r, n)));
|
|
6536
6536
|
}
|
|
6537
6537
|
return !1;
|
|
@@ -6541,11 +6541,11 @@ class mn {
|
|
|
6541
6541
|
let i = !1;
|
|
6542
6542
|
function o(s) {
|
|
6543
6543
|
if (s = st(s), s) {
|
|
6544
|
-
const a =
|
|
6544
|
+
const a = b.findKey(r, s);
|
|
6545
6545
|
a && (!n || _n(r, r[a], a, n)) && (delete r[a], i = !0);
|
|
6546
6546
|
}
|
|
6547
6547
|
}
|
|
6548
|
-
return
|
|
6548
|
+
return b.isArray(t) ? t.forEach(o) : o(t), i;
|
|
6549
6549
|
}
|
|
6550
6550
|
clear(t) {
|
|
6551
6551
|
const n = Object.keys(this);
|
|
@@ -6558,8 +6558,8 @@ class mn {
|
|
|
6558
6558
|
}
|
|
6559
6559
|
normalize(t) {
|
|
6560
6560
|
const n = this, r = {};
|
|
6561
|
-
return
|
|
6562
|
-
const s =
|
|
6561
|
+
return b.forEach(this, (i, o) => {
|
|
6562
|
+
const s = b.findKey(r, o);
|
|
6563
6563
|
if (s) {
|
|
6564
6564
|
n[s] = _t(i), delete n[o];
|
|
6565
6565
|
return;
|
|
@@ -6573,8 +6573,8 @@ class mn {
|
|
|
6573
6573
|
}
|
|
6574
6574
|
toJSON(t) {
|
|
6575
6575
|
const n = /* @__PURE__ */ Object.create(null);
|
|
6576
|
-
return
|
|
6577
|
-
r != null && r !== !1 && (n[i] = t &&
|
|
6576
|
+
return b.forEach(this, (r, i) => {
|
|
6577
|
+
r != null && r !== !1 && (n[i] = t && b.isArray(r) ? r.join(", ") : r);
|
|
6578
6578
|
}), n;
|
|
6579
6579
|
}
|
|
6580
6580
|
[Symbol.iterator]() {
|
|
@@ -6602,11 +6602,11 @@ class mn {
|
|
|
6602
6602
|
const a = st(s);
|
|
6603
6603
|
r[a] || (_p(i, s), r[a] = !0);
|
|
6604
6604
|
}
|
|
6605
|
-
return
|
|
6605
|
+
return b.isArray(t) ? t.forEach(o) : o(t), this;
|
|
6606
6606
|
}
|
|
6607
6607
|
}
|
|
6608
6608
|
mn.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
|
|
6609
|
-
|
|
6609
|
+
b.reduceDescriptors(mn.prototype, ({ value: e }, t) => {
|
|
6610
6610
|
let n = t[0].toUpperCase() + t.slice(1);
|
|
6611
6611
|
return {
|
|
6612
6612
|
get: () => e,
|
|
@@ -6615,12 +6615,12 @@ v.reduceDescriptors(mn.prototype, ({ value: e }, t) => {
|
|
|
6615
6615
|
}
|
|
6616
6616
|
};
|
|
6617
6617
|
});
|
|
6618
|
-
|
|
6618
|
+
b.freezeMethods(mn);
|
|
6619
6619
|
const pe = mn;
|
|
6620
6620
|
function Fn(e, t) {
|
|
6621
6621
|
const n = this || Lr, r = t || n, i = pe.from(r.headers);
|
|
6622
6622
|
let o = r.data;
|
|
6623
|
-
return
|
|
6623
|
+
return b.forEach(e, function(a) {
|
|
6624
6624
|
o = a.call(n, o, i.normalize(), t ? t.status : void 0);
|
|
6625
6625
|
}), i.normalize(), o;
|
|
6626
6626
|
}
|
|
@@ -6630,7 +6630,7 @@ function ka(e) {
|
|
|
6630
6630
|
function Et(e, t, n) {
|
|
6631
6631
|
V.call(this, e ?? "canceled", V.ERR_CANCELED, t, n), this.name = "CanceledError";
|
|
6632
6632
|
}
|
|
6633
|
-
|
|
6633
|
+
b.inherits(Et, V, {
|
|
6634
6634
|
__CANCEL__: !0
|
|
6635
6635
|
});
|
|
6636
6636
|
function Fp(e, t, n) {
|
|
@@ -6648,7 +6648,7 @@ const Np = ae.hasStandardBrowserEnv ? (
|
|
|
6648
6648
|
{
|
|
6649
6649
|
write(e, t, n, r, i, o) {
|
|
6650
6650
|
const s = [e + "=" + encodeURIComponent(t)];
|
|
6651
|
-
|
|
6651
|
+
b.isNumber(n) && s.push("expires=" + new Date(n).toGMTString()), b.isString(r) && s.push("path=" + r), b.isString(i) && s.push("domain=" + i), o === !0 && s.push("secure"), document.cookie = s.join("; ");
|
|
6652
6652
|
},
|
|
6653
6653
|
read(e) {
|
|
6654
6654
|
const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
|
|
@@ -6699,7 +6699,7 @@ const Wp = ae.hasStandardBrowserEnv ? (
|
|
|
6699
6699
|
};
|
|
6700
6700
|
}
|
|
6701
6701
|
return r = i(window.location.href), function(s) {
|
|
6702
|
-
const a =
|
|
6702
|
+
const a = b.isString(s) ? i(s) : s;
|
|
6703
6703
|
return a.protocol === r.protocol && a.host === r.host;
|
|
6704
6704
|
};
|
|
6705
6705
|
}()
|
|
@@ -6720,14 +6720,14 @@ function zp(e, t) {
|
|
|
6720
6720
|
const n = new Array(e), r = new Array(e);
|
|
6721
6721
|
let i = 0, o = 0, s;
|
|
6722
6722
|
return t = t !== void 0 ? t : 1e3, function(l) {
|
|
6723
|
-
const
|
|
6724
|
-
s || (s =
|
|
6725
|
-
let
|
|
6726
|
-
for (;
|
|
6727
|
-
h += n[
|
|
6728
|
-
if (i = (i + 1) % e, i === o && (o = (o + 1) % e),
|
|
6723
|
+
const c = Date.now(), f = r[o];
|
|
6724
|
+
s || (s = c), n[i] = l, r[i] = c;
|
|
6725
|
+
let u = o, h = 0;
|
|
6726
|
+
for (; u !== i; )
|
|
6727
|
+
h += n[u++], u = u % e;
|
|
6728
|
+
if (i = (i + 1) % e, i === o && (o = (o + 1) % e), c - s < t)
|
|
6729
6729
|
return;
|
|
6730
|
-
const d = f &&
|
|
6730
|
+
const d = f && c - f;
|
|
6731
6731
|
return d ? Math.round(h * 1e3 / d) : void 0;
|
|
6732
6732
|
};
|
|
6733
6733
|
}
|
|
@@ -6735,7 +6735,7 @@ function ds(e, t) {
|
|
|
6735
6735
|
let n = 0;
|
|
6736
6736
|
const r = zp(50, 250);
|
|
6737
6737
|
return (i) => {
|
|
6738
|
-
const o = i.loaded, s = i.lengthComputable ? i.total : void 0, a = o - n, l = r(a),
|
|
6738
|
+
const o = i.loaded, s = i.lengthComputable ? i.total : void 0, a = o - n, l = r(a), c = o <= s;
|
|
6739
6739
|
n = o;
|
|
6740
6740
|
const f = {
|
|
6741
6741
|
loaded: o,
|
|
@@ -6743,7 +6743,7 @@ function ds(e, t) {
|
|
|
6743
6743
|
progress: s ? o / s : void 0,
|
|
6744
6744
|
bytes: a,
|
|
6745
6745
|
rate: l || void 0,
|
|
6746
|
-
estimated: l && s &&
|
|
6746
|
+
estimated: l && s && c ? (s - o) / l : void 0,
|
|
6747
6747
|
event: i
|
|
6748
6748
|
};
|
|
6749
6749
|
f[t ? "download" : "upload"] = !0, e(f);
|
|
@@ -6754,80 +6754,80 @@ const Hp = typeof XMLHttpRequest < "u", $p = Hp && function(e) {
|
|
|
6754
6754
|
let i = e.data;
|
|
6755
6755
|
const o = pe.from(e.headers).normalize();
|
|
6756
6756
|
let { responseType: s, withXSRFToken: a } = e, l;
|
|
6757
|
-
function
|
|
6757
|
+
function c() {
|
|
6758
6758
|
e.cancelToken && e.cancelToken.unsubscribe(l), e.signal && e.signal.removeEventListener("abort", l);
|
|
6759
6759
|
}
|
|
6760
6760
|
let f;
|
|
6761
|
-
if (
|
|
6761
|
+
if (b.isFormData(i)) {
|
|
6762
6762
|
if (ae.hasStandardBrowserEnv || ae.hasStandardBrowserWebWorkerEnv)
|
|
6763
6763
|
o.setContentType(!1);
|
|
6764
6764
|
else if ((f = o.getContentType()) !== !1) {
|
|
6765
|
-
const [m, ...g] = f ? f.split(";").map((
|
|
6765
|
+
const [m, ...g] = f ? f.split(";").map((v) => v.trim()).filter(Boolean) : [];
|
|
6766
6766
|
o.setContentType([m || "multipart/form-data", ...g].join("; "));
|
|
6767
6767
|
}
|
|
6768
6768
|
}
|
|
6769
|
-
let
|
|
6769
|
+
let u = new XMLHttpRequest();
|
|
6770
6770
|
if (e.auth) {
|
|
6771
6771
|
const m = e.auth.username || "", g = e.auth.password ? unescape(encodeURIComponent(e.auth.password)) : "";
|
|
6772
6772
|
o.set("Authorization", "Basic " + btoa(m + ":" + g));
|
|
6773
6773
|
}
|
|
6774
6774
|
const h = Ma(e.baseURL, e.url);
|
|
6775
|
-
|
|
6775
|
+
u.open(e.method.toUpperCase(), Ca(h, e.params, e.paramsSerializer), !0), u.timeout = e.timeout;
|
|
6776
6776
|
function d() {
|
|
6777
|
-
if (!
|
|
6777
|
+
if (!u)
|
|
6778
6778
|
return;
|
|
6779
6779
|
const m = pe.from(
|
|
6780
|
-
"getAllResponseHeaders" in
|
|
6781
|
-
),
|
|
6782
|
-
data: !s || s === "text" || s === "json" ?
|
|
6783
|
-
status:
|
|
6784
|
-
statusText:
|
|
6780
|
+
"getAllResponseHeaders" in u && u.getAllResponseHeaders()
|
|
6781
|
+
), v = {
|
|
6782
|
+
data: !s || s === "text" || s === "json" ? u.responseText : u.response,
|
|
6783
|
+
status: u.status,
|
|
6784
|
+
statusText: u.statusText,
|
|
6785
6785
|
headers: m,
|
|
6786
6786
|
config: e,
|
|
6787
|
-
request:
|
|
6787
|
+
request: u
|
|
6788
6788
|
};
|
|
6789
6789
|
Fp(function(y) {
|
|
6790
|
-
n(y),
|
|
6790
|
+
n(y), c();
|
|
6791
6791
|
}, function(y) {
|
|
6792
|
-
r(y),
|
|
6793
|
-
},
|
|
6794
|
-
}
|
|
6795
|
-
if ("onloadend" in
|
|
6796
|
-
!
|
|
6797
|
-
},
|
|
6798
|
-
|
|
6799
|
-
},
|
|
6800
|
-
r(new V("Network Error", V.ERR_NETWORK, e,
|
|
6801
|
-
},
|
|
6792
|
+
r(y), c();
|
|
6793
|
+
}, v), u = null;
|
|
6794
|
+
}
|
|
6795
|
+
if ("onloadend" in u ? u.onloadend = d : u.onreadystatechange = function() {
|
|
6796
|
+
!u || u.readyState !== 4 || u.status === 0 && !(u.responseURL && u.responseURL.indexOf("file:") === 0) || setTimeout(d);
|
|
6797
|
+
}, u.onabort = function() {
|
|
6798
|
+
u && (r(new V("Request aborted", V.ECONNABORTED, e, u)), u = null);
|
|
6799
|
+
}, u.onerror = function() {
|
|
6800
|
+
r(new V("Network Error", V.ERR_NETWORK, e, u)), u = null;
|
|
6801
|
+
}, u.ontimeout = function() {
|
|
6802
6802
|
let g = e.timeout ? "timeout of " + e.timeout + "ms exceeded" : "timeout exceeded";
|
|
6803
|
-
const
|
|
6803
|
+
const v = e.transitional || Ra;
|
|
6804
6804
|
e.timeoutErrorMessage && (g = e.timeoutErrorMessage), r(new V(
|
|
6805
6805
|
g,
|
|
6806
|
-
|
|
6806
|
+
v.clarifyTimeoutError ? V.ETIMEDOUT : V.ECONNABORTED,
|
|
6807
6807
|
e,
|
|
6808
|
-
|
|
6809
|
-
)),
|
|
6810
|
-
}, ae.hasStandardBrowserEnv && (a &&
|
|
6808
|
+
u
|
|
6809
|
+
)), u = null;
|
|
6810
|
+
}, ae.hasStandardBrowserEnv && (a && b.isFunction(a) && (a = a(e)), a || a !== !1 && Wp(h))) {
|
|
6811
6811
|
const m = e.xsrfHeaderName && e.xsrfCookieName && Np.read(e.xsrfCookieName);
|
|
6812
6812
|
m && o.set(e.xsrfHeaderName, m);
|
|
6813
6813
|
}
|
|
6814
|
-
i === void 0 && o.setContentType(null), "setRequestHeader" in
|
|
6815
|
-
|
|
6816
|
-
}),
|
|
6817
|
-
|
|
6814
|
+
i === void 0 && o.setContentType(null), "setRequestHeader" in u && b.forEach(o.toJSON(), function(g, v) {
|
|
6815
|
+
u.setRequestHeader(v, g);
|
|
6816
|
+
}), b.isUndefined(e.withCredentials) || (u.withCredentials = !!e.withCredentials), s && s !== "json" && (u.responseType = e.responseType), typeof e.onDownloadProgress == "function" && u.addEventListener("progress", ds(e.onDownloadProgress, !0)), typeof e.onUploadProgress == "function" && u.upload && u.upload.addEventListener("progress", ds(e.onUploadProgress)), (e.cancelToken || e.signal) && (l = (m) => {
|
|
6817
|
+
u && (r(!m || m.type ? new Et(null, e, u) : m), u.abort(), u = null);
|
|
6818
6818
|
}, e.cancelToken && e.cancelToken.subscribe(l), e.signal && (e.signal.aborted ? l() : e.signal.addEventListener("abort", l)));
|
|
6819
6819
|
const p = Up(h);
|
|
6820
6820
|
if (p && ae.protocols.indexOf(p) === -1) {
|
|
6821
6821
|
r(new V("Unsupported protocol " + p + ":", V.ERR_BAD_REQUEST, e));
|
|
6822
6822
|
return;
|
|
6823
6823
|
}
|
|
6824
|
-
|
|
6824
|
+
u.send(i || null);
|
|
6825
6825
|
});
|
|
6826
6826
|
}, rr = {
|
|
6827
6827
|
http: mp,
|
|
6828
6828
|
xhr: $p
|
|
6829
6829
|
};
|
|
6830
|
-
|
|
6830
|
+
b.forEach(rr, (e, t) => {
|
|
6831
6831
|
if (e) {
|
|
6832
6832
|
try {
|
|
6833
6833
|
Object.defineProperty(e, "name", { value: t });
|
|
@@ -6836,9 +6836,9 @@ v.forEach(rr, (e, t) => {
|
|
|
6836
6836
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
6837
6837
|
}
|
|
6838
6838
|
});
|
|
6839
|
-
const ps = (e) => `- ${e}`, qp = (e) =>
|
|
6839
|
+
const ps = (e) => `- ${e}`, qp = (e) => b.isFunction(e) || e === null || e === !1, La = {
|
|
6840
6840
|
getAdapter: (e) => {
|
|
6841
|
-
e =
|
|
6841
|
+
e = b.isArray(e) ? e : [e];
|
|
6842
6842
|
const { length: t } = e;
|
|
6843
6843
|
let n, r;
|
|
6844
6844
|
const i = {};
|
|
@@ -6893,32 +6893,32 @@ const gs = (e) => e instanceof pe ? e.toJSON() : e;
|
|
|
6893
6893
|
function Ze(e, t) {
|
|
6894
6894
|
t = t || {};
|
|
6895
6895
|
const n = {};
|
|
6896
|
-
function r(
|
|
6897
|
-
return
|
|
6896
|
+
function r(c, f, u) {
|
|
6897
|
+
return b.isPlainObject(c) && b.isPlainObject(f) ? b.merge.call({ caseless: u }, c, f) : b.isPlainObject(f) ? b.merge({}, f) : b.isArray(f) ? f.slice() : f;
|
|
6898
6898
|
}
|
|
6899
|
-
function i(
|
|
6900
|
-
if (
|
|
6901
|
-
if (!
|
|
6902
|
-
return r(void 0,
|
|
6899
|
+
function i(c, f, u) {
|
|
6900
|
+
if (b.isUndefined(f)) {
|
|
6901
|
+
if (!b.isUndefined(c))
|
|
6902
|
+
return r(void 0, c, u);
|
|
6903
6903
|
} else
|
|
6904
|
-
return r(
|
|
6904
|
+
return r(c, f, u);
|
|
6905
6905
|
}
|
|
6906
|
-
function o(
|
|
6907
|
-
if (!
|
|
6906
|
+
function o(c, f) {
|
|
6907
|
+
if (!b.isUndefined(f))
|
|
6908
6908
|
return r(void 0, f);
|
|
6909
6909
|
}
|
|
6910
|
-
function s(
|
|
6911
|
-
if (
|
|
6912
|
-
if (!
|
|
6913
|
-
return r(void 0,
|
|
6910
|
+
function s(c, f) {
|
|
6911
|
+
if (b.isUndefined(f)) {
|
|
6912
|
+
if (!b.isUndefined(c))
|
|
6913
|
+
return r(void 0, c);
|
|
6914
6914
|
} else
|
|
6915
6915
|
return r(void 0, f);
|
|
6916
6916
|
}
|
|
6917
|
-
function a(
|
|
6918
|
-
if (
|
|
6919
|
-
return r(
|
|
6920
|
-
if (
|
|
6921
|
-
return r(void 0,
|
|
6917
|
+
function a(c, f, u) {
|
|
6918
|
+
if (u in t)
|
|
6919
|
+
return r(c, f);
|
|
6920
|
+
if (u in e)
|
|
6921
|
+
return r(void 0, c);
|
|
6922
6922
|
}
|
|
6923
6923
|
const l = {
|
|
6924
6924
|
url: o,
|
|
@@ -6949,11 +6949,11 @@ function Ze(e, t) {
|
|
|
6949
6949
|
socketPath: s,
|
|
6950
6950
|
responseEncoding: s,
|
|
6951
6951
|
validateStatus: a,
|
|
6952
|
-
headers: (
|
|
6952
|
+
headers: (c, f) => i(gs(c), gs(f), !0)
|
|
6953
6953
|
};
|
|
6954
|
-
return
|
|
6955
|
-
const
|
|
6956
|
-
|
|
6954
|
+
return b.forEach(Object.keys(Object.assign({}, e, t)), function(f) {
|
|
6955
|
+
const u = l[f] || i, h = u(e[f], t[f], f);
|
|
6956
|
+
b.isUndefined(h) && u !== a || (n[f] = h);
|
|
6957
6957
|
}), n;
|
|
6958
6958
|
}
|
|
6959
6959
|
const Da = "1.6.5", Dr = {};
|
|
@@ -7024,17 +7024,17 @@ class Jt {
|
|
|
7024
7024
|
silentJSONParsing: xe.transitional(xe.boolean),
|
|
7025
7025
|
forcedJSONParsing: xe.transitional(xe.boolean),
|
|
7026
7026
|
clarifyTimeoutError: xe.transitional(xe.boolean)
|
|
7027
|
-
}, !1), i != null && (
|
|
7027
|
+
}, !1), i != null && (b.isFunction(i) ? n.paramsSerializer = {
|
|
7028
7028
|
serialize: i
|
|
7029
7029
|
} : ir.assertOptions(i, {
|
|
7030
7030
|
encode: xe.function,
|
|
7031
7031
|
serialize: xe.function
|
|
7032
7032
|
}, !0)), n.method = (n.method || this.defaults.method || "get").toLowerCase();
|
|
7033
|
-
let s = o &&
|
|
7033
|
+
let s = o && b.merge(
|
|
7034
7034
|
o.common,
|
|
7035
7035
|
o[n.method]
|
|
7036
7036
|
);
|
|
7037
|
-
o &&
|
|
7037
|
+
o && b.forEach(
|
|
7038
7038
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
7039
7039
|
(p) => {
|
|
7040
7040
|
delete o[p];
|
|
@@ -7045,21 +7045,21 @@ class Jt {
|
|
|
7045
7045
|
this.interceptors.request.forEach(function(m) {
|
|
7046
7046
|
typeof m.runWhen == "function" && m.runWhen(n) === !1 || (l = l && m.synchronous, a.unshift(m.fulfilled, m.rejected));
|
|
7047
7047
|
});
|
|
7048
|
-
const
|
|
7048
|
+
const c = [];
|
|
7049
7049
|
this.interceptors.response.forEach(function(m) {
|
|
7050
|
-
|
|
7050
|
+
c.push(m.fulfilled, m.rejected);
|
|
7051
7051
|
});
|
|
7052
|
-
let f,
|
|
7052
|
+
let f, u = 0, h;
|
|
7053
7053
|
if (!l) {
|
|
7054
7054
|
const p = [ms.bind(this), void 0];
|
|
7055
|
-
for (p.unshift.apply(p, a), p.push.apply(p,
|
|
7056
|
-
f = f.then(p[
|
|
7055
|
+
for (p.unshift.apply(p, a), p.push.apply(p, c), h = p.length, f = Promise.resolve(n); u < h; )
|
|
7056
|
+
f = f.then(p[u++], p[u++]);
|
|
7057
7057
|
return f;
|
|
7058
7058
|
}
|
|
7059
7059
|
h = a.length;
|
|
7060
7060
|
let d = n;
|
|
7061
|
-
for (
|
|
7062
|
-
const p = a[
|
|
7061
|
+
for (u = 0; u < h; ) {
|
|
7062
|
+
const p = a[u++], m = a[u++];
|
|
7063
7063
|
try {
|
|
7064
7064
|
d = p(d);
|
|
7065
7065
|
} catch (g) {
|
|
@@ -7072,8 +7072,8 @@ class Jt {
|
|
|
7072
7072
|
} catch (p) {
|
|
7073
7073
|
return Promise.reject(p);
|
|
7074
7074
|
}
|
|
7075
|
-
for (
|
|
7076
|
-
f = f.then(u
|
|
7075
|
+
for (u = 0, h = c.length; u < h; )
|
|
7076
|
+
f = f.then(c[u++], c[u++]);
|
|
7077
7077
|
return f;
|
|
7078
7078
|
}
|
|
7079
7079
|
getUri(t) {
|
|
@@ -7082,7 +7082,7 @@ class Jt {
|
|
|
7082
7082
|
return Ca(n, t.params, t.paramsSerializer);
|
|
7083
7083
|
}
|
|
7084
7084
|
}
|
|
7085
|
-
|
|
7085
|
+
b.forEach(["delete", "get", "head", "options"], function(t) {
|
|
7086
7086
|
Jt.prototype[t] = function(n, r) {
|
|
7087
7087
|
return this.request(Ze(r || {}, {
|
|
7088
7088
|
method: t,
|
|
@@ -7091,7 +7091,7 @@ v.forEach(["delete", "get", "head", "options"], function(t) {
|
|
|
7091
7091
|
}));
|
|
7092
7092
|
};
|
|
7093
7093
|
});
|
|
7094
|
-
|
|
7094
|
+
b.forEach(["post", "put", "patch"], function(t) {
|
|
7095
7095
|
function n(r) {
|
|
7096
7096
|
return function(o, s, a) {
|
|
7097
7097
|
return this.request(Ze(a || {}, {
|
|
@@ -7182,7 +7182,7 @@ function Kp(e) {
|
|
|
7182
7182
|
};
|
|
7183
7183
|
}
|
|
7184
7184
|
function Yp(e) {
|
|
7185
|
-
return
|
|
7185
|
+
return b.isObject(e) && e.isAxiosError === !0;
|
|
7186
7186
|
}
|
|
7187
7187
|
const sr = {
|
|
7188
7188
|
Continue: 100,
|
|
@@ -7255,31 +7255,31 @@ Object.entries(sr).forEach(([e, t]) => {
|
|
|
7255
7255
|
const Jp = sr;
|
|
7256
7256
|
function ja(e) {
|
|
7257
7257
|
const t = new Ft(e), n = ma(Ft.prototype.request, t);
|
|
7258
|
-
return
|
|
7258
|
+
return b.extend(n, Ft.prototype, t, { allOwnKeys: !0 }), b.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(i) {
|
|
7259
7259
|
return ja(Ze(e, i));
|
|
7260
7260
|
}, n;
|
|
7261
7261
|
}
|
|
7262
|
-
const
|
|
7263
|
-
|
|
7264
|
-
|
|
7265
|
-
|
|
7266
|
-
|
|
7267
|
-
|
|
7268
|
-
|
|
7269
|
-
|
|
7270
|
-
|
|
7271
|
-
|
|
7262
|
+
const F = ja(Lr);
|
|
7263
|
+
F.Axios = Ft;
|
|
7264
|
+
F.CanceledError = Et;
|
|
7265
|
+
F.CancelToken = Xp;
|
|
7266
|
+
F.isCancel = ka;
|
|
7267
|
+
F.VERSION = Da;
|
|
7268
|
+
F.toFormData = pn;
|
|
7269
|
+
F.AxiosError = V;
|
|
7270
|
+
F.Cancel = F.CanceledError;
|
|
7271
|
+
F.all = function(t) {
|
|
7272
7272
|
return Promise.all(t);
|
|
7273
7273
|
};
|
|
7274
|
-
|
|
7275
|
-
|
|
7276
|
-
|
|
7277
|
-
|
|
7278
|
-
|
|
7279
|
-
|
|
7280
|
-
|
|
7281
|
-
|
|
7282
|
-
const Zp =
|
|
7274
|
+
F.spread = Kp;
|
|
7275
|
+
F.isAxiosError = Yp;
|
|
7276
|
+
F.mergeConfig = Ze;
|
|
7277
|
+
F.AxiosHeaders = pe;
|
|
7278
|
+
F.formToJSON = (e) => Va(b.isHTMLForm(e) ? new FormData(e) : e);
|
|
7279
|
+
F.getAdapter = La.getAdapter;
|
|
7280
|
+
F.HttpStatusCode = Jp;
|
|
7281
|
+
F.default = F;
|
|
7282
|
+
const Zp = F, Qp = `[data-simplebar]{position:relative;flex-direction:column;flex-wrap:wrap;justify-content:flex-start;align-content:flex-start;align-items:flex-start}.simplebar-wrapper{overflow:hidden;width:inherit;height:inherit;max-width:inherit;max-height:inherit}.simplebar-mask{direction:inherit;position:absolute;overflow:hidden;padding:0;margin:0;left:0;top:0;bottom:0;right:0;width:auto!important;height:auto!important;z-index:0}.simplebar-offset{direction:inherit!important;box-sizing:inherit!important;resize:none!important;position:absolute;top:0;left:0;bottom:0;right:0;padding:0;margin:0;-webkit-overflow-scrolling:touch}.simplebar-content-wrapper{direction:inherit;box-sizing:border-box!important;position:relative;display:block;height:100%;width:auto;max-width:100%;max-height:100%;overflow:auto;scrollbar-width:none;-ms-overflow-style:none}.simplebar-content-wrapper::-webkit-scrollbar,.simplebar-hide-scrollbar::-webkit-scrollbar{display:none;width:0;height:0}.simplebar-content:after,.simplebar-content:before{content:" ";display:table}.simplebar-placeholder{max-height:100%;max-width:100%;width:100%;pointer-events:none}.simplebar-height-auto-observer-wrapper{box-sizing:inherit!important;height:100%;width:100%;max-width:1px;position:relative;float:left;max-height:1px;overflow:hidden;z-index:-1;padding:0;margin:0;pointer-events:none;flex-grow:inherit;flex-shrink:0;flex-basis:0}.simplebar-height-auto-observer{box-sizing:inherit;display:block;opacity:0;position:absolute;top:0;left:0;height:1000%;width:1000%;min-height:1px;min-width:1px;overflow:hidden;pointer-events:none;z-index:-1}.simplebar-track{z-index:1;position:absolute;right:0;bottom:0;pointer-events:none;overflow:hidden}[data-simplebar].simplebar-dragging,[data-simplebar].simplebar-dragging .simplebar-content{pointer-events:none;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}[data-simplebar].simplebar-dragging .simplebar-track{pointer-events:all}.simplebar-scrollbar{position:absolute;left:0;right:0;min-height:10px}.simplebar-scrollbar:before{position:absolute;content:"";background:#000;border-radius:7px;left:2px;right:2px;opacity:0;transition:opacity .2s .5s linear}.simplebar-scrollbar.simplebar-visible:before{opacity:.5;transition-delay:0s;transition-duration:0s}.simplebar-track.simplebar-vertical{top:0;width:11px}.simplebar-scrollbar:before{top:2px;bottom:2px;left:2px;right:2px}.simplebar-track.simplebar-horizontal{left:0;height:11px}.simplebar-track.simplebar-horizontal .simplebar-scrollbar{right:auto;left:0;top:0;bottom:0;min-height:0;min-width:10px;width:auto}[data-simplebar-direction=rtl] .simplebar-track.simplebar-vertical{right:auto;left:0}.simplebar-dummy-scrollbar-size{direction:rtl;position:fixed;opacity:0;visibility:hidden;height:500px;width:500px;overflow-y:hidden;overflow-x:scroll;-ms-overflow-style:scrollbar!important}.simplebar-dummy-scrollbar-size>div{width:200%;height:200%;margin:10px 0}.simplebar-hide-scrollbar{position:fixed;left:0;visibility:hidden;overflow-y:scroll;scrollbar-width:none;-ms-overflow-style:none}
|
|
7283
7283
|
`;
|
|
7284
7284
|
function em() {
|
|
7285
7285
|
return /* @__PURE__ */ R.jsx(
|
|
@@ -7312,7 +7312,7 @@ function tm() {
|
|
|
7312
7312
|
);
|
|
7313
7313
|
}
|
|
7314
7314
|
const nm = `.side-bar{display:flex;flex-direction:column;max-width:18rem;height:calc(100vh - 64px);border-right:1px solid #ddd;background-color:#fafafa;transition:all .3s;padding:0 8px}.side-bar.expanded{width:18rem}.side-bar.collapsed{width:64px;padding-left:4px;padding-right:4px}.side-bar__menu{margin-left:-8px;margin-right:-8px;padding-left:8px;padding-right:8px}.side-bar__menu.collapsed{margin-left:-4px;margin-right:-4px;padding-left:4px;padding-right:4px}.side-bar__wrap-btn-logout,.side-bar__btn-logout{margin:40px 0}.side-bar__logout-btn__text{margin-left:12px}.side-bar__logout-btn__text.collapsed{display:none}.side-bar__wrapper-toggle-btn{display:flex;flex-direction:row;justify-content:flex-end;transition:all .3s;margin-right:-8px;margin-top:40px}.side-bar__wrapper-toggle-btn.collapsed{justify-content:center;width:100%}.side-bar__toggle-btn{margin-top:-6px;color:#85858a}.side-bar__logout-btn{width:100%;text-align:left;display:flex;flex-direction:row;align-items:center;padding:0 16px;min-height:48px;border-radius:.375rem}.side-bar__logout-btn:hover{background-color:#919eab14}.side-bar__logout-btn.collapsed{justify-content:center}.menu-item__wrapper{display:flex;flex-direction:column;position:relative;width:100%;margin-top:4px}.menu-item__wrapper:first-child,.menu-item__wrapper.collapsed{margin-top:0}.menu-item__wrapper.collapsed.level-1{margin-top:4px}.menu-item__link{display:flex;flex-direction:row;border-radius:.375rem;align-items:center;padding:.5rem;position:relative;height:48px;cursor:pointer;color:#85858a}.menu-item__link:hover{background-color:#919eab14}.menu-item__link.active{background-color:#009d4f1a!important;color:#009d4f!important}.menu-item__link.level-0{height:auto}.menu-item__link.menu-item__link.collapsed.level-0{display:none}.menu-item__icon{width:1.5rem;height:1.5rem;flex-shrink:0}.menu-item__icon.collapsed.level-1{width:100%}.menu-item__icon.collapsed.level-1>*{margin:0 auto}.menu-item__label{font-size:.875rem;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:100%;flex-shrink:1;margin-left:12px;padding-right:12px;color:#292929}.menu-item__label.active{color:inherit}.menu-item__label.collapsed{margin-left:8px;font-size:.75rem;line-height:1rem}.menu-item__label.collapsed.level-1{text-align:center;margin-left:0;display:none}.menu-item__label.level-0{color:#85858a}.menu-item__icon-arrow__wrapper{display:grid;place-items:center;position:absolute;top:50%;transform:translateY(-50%);right:-3px}.menu-item__icon-arrow__wrapper.expanded{right:0}.menu-item__icon-arrow__icon{transition:all .3s!important;transform:rotate(-90deg)!important}.menu-item__icon-arrow__icon.active{color:inherit}.menu-item__icon-arrow__icon.expanded.open{transform:rotate(0)!important}.menu-item__dropdown.collapsed{background-color:#fafafa;border:1px solid #ddd;box-shadow:#0000001a 0 10px 15px -3px,#0000000d 0 4px 6px -2px;border-radius:4px;width:180px;max-width:180px;padding:4px;z-index:1200}.menu-item__dropdown.collapsed .menu-item__link{height:40px}.menu-item__dropdown.collapsed .menu-item__link.level-1{height:48px}.menu-item__dropdown.collapsed.level-1{width:auto;max-width:unset;box-shadow:none;border:none;padding:0;background-color:unset}.menu-item__dropdown.expanded{margin-top:4px;overflow:hidden}.icon-btn{display:inline-flex;align-items:center;justify-content:center;padding:8px;border-radius:50%;background-color:transparent;transition:background-color .3s ease;border:none}.icon-btn:hover{background-color:var(--btn-bg-hover)}.simplebar-scrollbar:before{background-color:#0000002d}
|
|
7315
|
-
`, _r = (e) => typeof e == "number" && !isNaN(e), ft = (e) => typeof e == "string", _a = (e) => typeof e == "function", rm = (e) =>
|
|
7315
|
+
`, _r = (e) => typeof e == "number" && !isNaN(e), ft = (e) => typeof e == "string", _a = (e) => typeof e == "function", rm = (e) => x.isValidElement(e) || ft(e) || _a(e) || _r(e), oe = /* @__PURE__ */ new Map();
|
|
7316
7316
|
let or = [];
|
|
7317
7317
|
const vs = /* @__PURE__ */ new Set(), Fa = () => oe.size > 0;
|
|
7318
7318
|
function im(e, t) {
|
|
@@ -7354,13 +7354,13 @@ function L(e, t) {
|
|
|
7354
7354
|
L.loading = (e, t) => ht(e, Zt("default", { isLoading: !0, autoClose: !1, closeOnClick: !1, closeButton: !1, draggable: !1, ...t })), L.promise = function(e, t, n) {
|
|
7355
7355
|
let r, { pending: i, error: o, success: s } = t;
|
|
7356
7356
|
i && (r = ft(i) ? L.loading(i, n) : L.loading(i.render, { ...n, ...i }));
|
|
7357
|
-
const a = { isLoading: null, autoClose: null, closeOnClick: null, closeButton: null, draggable: null }, l = (f,
|
|
7358
|
-
if (
|
|
7357
|
+
const a = { isLoading: null, autoClose: null, closeOnClick: null, closeButton: null, draggable: null }, l = (f, u, h) => {
|
|
7358
|
+
if (u == null)
|
|
7359
7359
|
return void L.dismiss(r);
|
|
7360
|
-
const d = { type: f, ...a, ...n, data: h }, p = ft(
|
|
7360
|
+
const d = { type: f, ...a, ...n, data: h }, p = ft(u) ? { render: u } : u;
|
|
7361
7361
|
return r ? L.update(r, { ...d, ...p }) : L(p.render, { ...d, ...p }), h;
|
|
7362
|
-
},
|
|
7363
|
-
return
|
|
7362
|
+
}, c = _a(e) ? e() : e;
|
|
7363
|
+
return c.then((f) => l("success", s, f)).catch((f) => l("error", o, f)), c;
|
|
7364
7364
|
}, L.success = kt("success"), L.info = kt("info"), L.error = kt("error"), L.warning = kt("warning"), L.warn = L.warning, L.dark = (e, t) => ht(e, Zt("default", { theme: "dark", ...t })), L.dismiss = function(e) {
|
|
7365
7365
|
(function(t) {
|
|
7366
7366
|
var n;
|
|
@@ -7500,48 +7500,50 @@ const cm = {
|
|
|
7500
7500
|
color: xs.danger
|
|
7501
7501
|
}
|
|
7502
7502
|
});
|
|
7503
|
+
}, fm = (e) => {
|
|
7504
|
+
window.location.href = `${e}/authentication/logout?callbackUrl=${window.location.href}`;
|
|
7503
7505
|
};
|
|
7504
|
-
function fm(e) {
|
|
7505
|
-
return /* @__PURE__ */ R.jsx(za, { styles: [Qp, nm], style: { zIndex: 1200 }, children: /* @__PURE__ */ R.jsx(hm, { ...e }) });
|
|
7506
|
-
}
|
|
7507
7506
|
function hm(e) {
|
|
7508
|
-
|
|
7509
|
-
|
|
7510
|
-
|
|
7511
|
-
|
|
7507
|
+
return /* @__PURE__ */ R.jsx(za, { styles: [Qp, nm], style: { zIndex: 1200 }, children: /* @__PURE__ */ R.jsx(dm, { ...e }) });
|
|
7508
|
+
}
|
|
7509
|
+
function dm(e) {
|
|
7510
|
+
const { baseUrl: t, menuPath: n } = e, r = nn(), [i, o] = x.useState([]), [s, a] = x.useState(!1), l = (pa(i, r.pathname) || []).filter((v) => v.parentKey !== 0), [c, f] = x.useState({}), u = (v) => {
|
|
7511
|
+
f({
|
|
7512
|
+
...c,
|
|
7513
|
+
[v]: !c[v]
|
|
7512
7514
|
});
|
|
7513
|
-
},
|
|
7514
|
-
|
|
7515
|
+
}, h = () => {
|
|
7516
|
+
a(!s);
|
|
7515
7517
|
};
|
|
7516
|
-
|
|
7518
|
+
x.useEffect(() => {
|
|
7517
7519
|
(async () => {
|
|
7518
|
-
const
|
|
7520
|
+
const w = t + (n || "/global-menu-config/api/v1/menu-items/user"), y = await Zp.get(w, {
|
|
7519
7521
|
withCredentials: !0
|
|
7520
7522
|
}).then((E) => E.data).catch((E) => {
|
|
7521
|
-
var
|
|
7523
|
+
var T, P;
|
|
7522
7524
|
um(
|
|
7523
|
-
((P = (
|
|
7525
|
+
((P = (T = E.response) == null ? void 0 : T.data) == null ? void 0 : P.errorMessage) || "Have error when get menu items"
|
|
7524
7526
|
);
|
|
7525
|
-
}),
|
|
7526
|
-
|
|
7527
|
-
E.children && (
|
|
7528
|
-
}),
|
|
7527
|
+
}), S = {};
|
|
7528
|
+
y.forEach((E) => {
|
|
7529
|
+
E.children && (S[E.id] = !0);
|
|
7530
|
+
}), f(S), o(y.map((E) => ({ ...E, parentKey: 0 })));
|
|
7529
7531
|
})();
|
|
7530
7532
|
}, [t, n]);
|
|
7531
|
-
const [
|
|
7532
|
-
return /* @__PURE__ */ R.jsxs("div", { className:
|
|
7533
|
-
/* @__PURE__ */ R.jsx("div", { className:
|
|
7533
|
+
const [d, p] = x.useState(!1), m = s ? "collapsed" : "expanded", g = (v) => `${v} ${m}`;
|
|
7534
|
+
return /* @__PURE__ */ R.jsxs("div", { className: g("side-bar"), children: [
|
|
7535
|
+
/* @__PURE__ */ R.jsx("div", { className: g("side-bar__wrapper-toggle-btn"), children: /* @__PURE__ */ R.jsx(
|
|
7534
7536
|
"button",
|
|
7535
7537
|
{
|
|
7536
7538
|
className: "icon-btn side-bar__toggle-btn",
|
|
7537
|
-
onClick:
|
|
7538
|
-
children:
|
|
7539
|
+
onClick: h,
|
|
7540
|
+
children: s ? /* @__PURE__ */ R.jsx(tm, {}) : /* @__PURE__ */ R.jsx(em, {})
|
|
7539
7541
|
}
|
|
7540
7542
|
) }),
|
|
7541
7543
|
/* @__PURE__ */ R.jsx(
|
|
7542
7544
|
Ws,
|
|
7543
7545
|
{
|
|
7544
|
-
className:
|
|
7546
|
+
className: g("side-bar__menu"),
|
|
7545
7547
|
style: {
|
|
7546
7548
|
marginTop: 24,
|
|
7547
7549
|
flex: 1,
|
|
@@ -7549,54 +7551,56 @@ function hm(e) {
|
|
|
7549
7551
|
height: "100%",
|
|
7550
7552
|
overflowX: "hidden"
|
|
7551
7553
|
},
|
|
7552
|
-
children:
|
|
7553
|
-
const
|
|
7554
|
+
children: i.map((v) => {
|
|
7555
|
+
const w = (y) => l.some((S) => S.id === y);
|
|
7554
7556
|
return /* @__PURE__ */ R.jsx(
|
|
7555
7557
|
da,
|
|
7556
7558
|
{
|
|
7557
|
-
item:
|
|
7558
|
-
isActive:
|
|
7559
|
-
isCollapsed:
|
|
7560
|
-
expanded: (
|
|
7561
|
-
toggleExpand:
|
|
7559
|
+
item: v,
|
|
7560
|
+
isActive: w,
|
|
7561
|
+
isCollapsed: s,
|
|
7562
|
+
expanded: (y) => c[y],
|
|
7563
|
+
toggleExpand: u,
|
|
7564
|
+
replacePath: e.replacePath
|
|
7562
7565
|
},
|
|
7563
|
-
|
|
7566
|
+
v.id
|
|
7564
7567
|
);
|
|
7565
7568
|
})
|
|
7566
7569
|
}
|
|
7567
7570
|
),
|
|
7568
|
-
/* @__PURE__ */ R.jsxs("div", { className:
|
|
7571
|
+
/* @__PURE__ */ R.jsxs("div", { className: g("side-bar__wrap-btn-logout"), children: [
|
|
7569
7572
|
/* @__PURE__ */ R.jsxs(
|
|
7570
7573
|
"button",
|
|
7571
7574
|
{
|
|
7572
|
-
className:
|
|
7573
|
-
onClick: () =>
|
|
7575
|
+
className: g("side-bar__logout-btn"),
|
|
7576
|
+
onClick: () => p(!0),
|
|
7574
7577
|
children: [
|
|
7575
7578
|
/* @__PURE__ */ R.jsx(Dd, {}),
|
|
7576
|
-
/* @__PURE__ */ R.jsx("span", { className:
|
|
7579
|
+
/* @__PURE__ */ R.jsx("span", { className: g("side-bar__logout-btn__text"), children: "Logout" })
|
|
7577
7580
|
]
|
|
7578
7581
|
}
|
|
7579
7582
|
),
|
|
7580
7583
|
/* @__PURE__ */ R.jsx(
|
|
7581
7584
|
Ha,
|
|
7582
7585
|
{
|
|
7583
|
-
isOpen:
|
|
7584
|
-
onClose: () =>
|
|
7585
|
-
onConfirm:
|
|
7586
|
+
isOpen: d,
|
|
7587
|
+
onClose: () => p(!1),
|
|
7588
|
+
onConfirm: () => e.logout ? e.logout() : fm(e.baseUrl)
|
|
7586
7589
|
}
|
|
7587
7590
|
)
|
|
7588
7591
|
] })
|
|
7589
7592
|
] });
|
|
7590
7593
|
}
|
|
7591
|
-
function
|
|
7592
|
-
return /* @__PURE__ */ R.jsx(pl, { children: /* @__PURE__ */ R.jsx(
|
|
7594
|
+
function pm(e) {
|
|
7595
|
+
return /* @__PURE__ */ R.jsx(pl, { children: /* @__PURE__ */ R.jsx(hm, { ...e }) });
|
|
7593
7596
|
}
|
|
7594
|
-
const
|
|
7597
|
+
const mm = $a(pm, {
|
|
7595
7598
|
props: {
|
|
7596
7599
|
baseUrl: "string",
|
|
7597
7600
|
menuPath: "string",
|
|
7598
|
-
logout: "function"
|
|
7601
|
+
logout: "function",
|
|
7602
|
+
replacePath: "function"
|
|
7599
7603
|
}
|
|
7600
7604
|
// shadow: 'open',
|
|
7601
7605
|
});
|
|
7602
|
-
customElements.define("global-menu",
|
|
7606
|
+
customElements.define("global-menu", mm);
|