@lazycatcloud/lzc-toolkit 0.0.185 → 0.0.186
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/index.es.js +85 -82
- package/dist/index.umd.js +4 -4
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -276,8 +276,8 @@ function Jt(e, t = {}) {
|
|
|
276
276
|
var k, X, y;
|
|
277
277
|
if (!d)
|
|
278
278
|
return;
|
|
279
|
-
const
|
|
280
|
-
!
|
|
279
|
+
const N = te(e);
|
|
280
|
+
!N || (y = N instanceof Document ? d.document.body : N) == null || y.scrollTo({
|
|
281
281
|
top: (k = te(L)) != null ? k : a.value,
|
|
282
282
|
left: (X = te(D)) != null ? X : f.value,
|
|
283
283
|
behavior: te(u)
|
|
@@ -293,16 +293,16 @@ function Jt(e, t = {}) {
|
|
|
293
293
|
right: !1,
|
|
294
294
|
top: !1,
|
|
295
295
|
bottom: !1
|
|
296
|
-
}),
|
|
296
|
+
}), w = (D) => {
|
|
297
297
|
!h.value || (h.value = !1, T.left = !1, T.right = !1, T.top = !1, T.bottom = !1, l(D));
|
|
298
|
-
}, x = Le(
|
|
298
|
+
}, x = Le(w, n + o), R = (D) => {
|
|
299
299
|
var L;
|
|
300
300
|
if (!d)
|
|
301
301
|
return;
|
|
302
|
-
const k = ((L = D?.document) == null ? void 0 : L.documentElement) || D?.documentElement || ie(D), { display: X, flexDirection: y } = getComputedStyle(k),
|
|
303
|
-
T.left =
|
|
304
|
-
const C = Math.abs(
|
|
305
|
-
X === "flex" && y === "row-reverse" ? (g.left = Q, g.right = C) : (g.left = C, g.right = Q), r.value =
|
|
302
|
+
const k = ((L = D?.document) == null ? void 0 : L.documentElement) || D?.documentElement || ie(D), { display: X, flexDirection: y } = getComputedStyle(k), N = k.scrollLeft;
|
|
303
|
+
T.left = N < r.value, T.right = N > r.value;
|
|
304
|
+
const C = Math.abs(N) <= (i.left || 0), Q = Math.abs(N) + k.clientWidth >= k.scrollWidth - (i.right || 0) - st;
|
|
305
|
+
X === "flex" && y === "row-reverse" ? (g.left = Q, g.right = C) : (g.left = C, g.right = Q), r.value = N;
|
|
306
306
|
let _ = k.scrollTop;
|
|
307
307
|
D === d.document && !_ && (_ = d.document.body.scrollTop), T.top = _ < M.value, T.bottom = _ > M.value;
|
|
308
308
|
const E = Math.abs(_) <= (i.top || 0), z = Math.abs(_) + k.clientHeight >= k.scrollHeight - (i.bottom || 0) - st;
|
|
@@ -331,7 +331,7 @@ function Jt(e, t = {}) {
|
|
|
331
331
|
}), Te(
|
|
332
332
|
e,
|
|
333
333
|
"scrollend",
|
|
334
|
-
|
|
334
|
+
w,
|
|
335
335
|
c
|
|
336
336
|
), {
|
|
337
337
|
x: f,
|
|
@@ -393,7 +393,7 @@ function nn(e, t) {
|
|
|
393
393
|
const p = m([]), h = A(() => {
|
|
394
394
|
let { sum: E, height: z } = { sum: 0, height: 0 };
|
|
395
395
|
return v.value.map((B, $) => (typeof o == "number" ? z = o : z = o($), E += z, { height: z, sum: E }));
|
|
396
|
-
}), g = A(() => X(M.value.start)), T = A(() => typeof o == "number" ? h.value.length * o : h.value[h.value.length - 1]?.sum || 0),
|
|
396
|
+
}), g = A(() => X(M.value.start)), T = A(() => typeof o == "number" ? h.value.length * o : h.value[h.value.length - 1]?.sum || 0), w = A(() => {
|
|
397
397
|
const { start: E, end: z } = f.value;
|
|
398
398
|
return p.value.slice(E, z);
|
|
399
399
|
});
|
|
@@ -460,7 +460,7 @@ function nn(e, t) {
|
|
|
460
460
|
function y(E) {
|
|
461
461
|
return h.value[E] || { sum: 0, height: 0 };
|
|
462
462
|
}
|
|
463
|
-
function
|
|
463
|
+
function N(E, z = "smooth") {
|
|
464
464
|
if (s.value) {
|
|
465
465
|
const { reset: B } = tn(
|
|
466
466
|
s.value,
|
|
@@ -490,12 +490,12 @@ function nn(e, t) {
|
|
|
490
490
|
};
|
|
491
491
|
return {
|
|
492
492
|
list: p,
|
|
493
|
-
visiableList:
|
|
493
|
+
visiableList: w,
|
|
494
494
|
getItemHeightData: y,
|
|
495
495
|
getoffsetTopIndex: L,
|
|
496
496
|
totalHeight: T,
|
|
497
497
|
clientHeight: i.height,
|
|
498
|
-
scrollTo:
|
|
498
|
+
scrollTo: N,
|
|
499
499
|
scrollTop: r,
|
|
500
500
|
isScrollEnd: c,
|
|
501
501
|
containerProps: {
|
|
@@ -538,7 +538,7 @@ function Lo(e, t, n = { deep: !0 }) {
|
|
|
538
538
|
G(
|
|
539
539
|
e,
|
|
540
540
|
(g) => {
|
|
541
|
-
s.value = g.reduce((T,
|
|
541
|
+
s.value = g.reduce((T, w) => (T.set(w[t], w), T), /* @__PURE__ */ new Map());
|
|
542
542
|
},
|
|
543
543
|
{
|
|
544
544
|
deep: n.deep,
|
|
@@ -551,8 +551,8 @@ function Lo(e, t, n = { deep: !0 }) {
|
|
|
551
551
|
o.value && (g = Array.from(s.value.values()));
|
|
552
552
|
else if (l.value.size) {
|
|
553
553
|
let T;
|
|
554
|
-
l.value.forEach((
|
|
555
|
-
T = s.value.get(
|
|
554
|
+
l.value.forEach((w) => {
|
|
555
|
+
T = s.value.get(w), T && g.push(T);
|
|
556
556
|
});
|
|
557
557
|
}
|
|
558
558
|
return g;
|
|
@@ -564,8 +564,8 @@ function Lo(e, t, n = { deep: !0 }) {
|
|
|
564
564
|
if (o.value != null)
|
|
565
565
|
g = o.value;
|
|
566
566
|
else {
|
|
567
|
-
const T = l.value.size,
|
|
568
|
-
g = T ==
|
|
567
|
+
const T = l.value.size, w = s.value.size;
|
|
568
|
+
g = T == w;
|
|
569
569
|
}
|
|
570
570
|
return g;
|
|
571
571
|
});
|
|
@@ -718,11 +718,11 @@ function Dt({
|
|
|
718
718
|
top: Math.min(f.value.y, a.value.y) - h.value.top,
|
|
719
719
|
width: Math.abs(f.value.x - a.value.x),
|
|
720
720
|
height: Math.abs(f.value.y - a.value.y)
|
|
721
|
-
} : { left: 0, top: 0, width: 0, height: 0 }), { margin:
|
|
721
|
+
} : { left: 0, top: 0, width: 0, height: 0 }), { margin: w = 50, startSpeed: x = 30, maxSpeed: R = 30 } = n;
|
|
722
722
|
let S;
|
|
723
|
-
const D =
|
|
723
|
+
const D = w, L = x, k = R, X = (j) => j ** 1;
|
|
724
724
|
let y = 0;
|
|
725
|
-
function
|
|
725
|
+
function N(j) {
|
|
726
726
|
if (cancelAnimationFrame(S), y = C(j), y = Math.max(
|
|
727
727
|
Math.min(y, k),
|
|
728
728
|
-k
|
|
@@ -732,7 +732,7 @@ function Dt({
|
|
|
732
732
|
return;
|
|
733
733
|
const Z = g.value.height - h.value.height;
|
|
734
734
|
let W = g.value.top + Number(y);
|
|
735
|
-
W = Math.min(Math.max(0, W), Z), O.scrollTop = W, _(), S = requestAnimationFrame(() =>
|
|
735
|
+
W = Math.min(Math.max(0, W), Z), O.scrollTop = W, _(), S = requestAnimationFrame(() => N(j));
|
|
736
736
|
}
|
|
737
737
|
}
|
|
738
738
|
function C(j) {
|
|
@@ -775,7 +775,7 @@ function Dt({
|
|
|
775
775
|
f.value.x = j, f.value.y = Z, a.value.x = j, a.value.y = Z, r.value?.classList.add("disable-scroll-behavior"), d.clear();
|
|
776
776
|
}
|
|
777
777
|
function B(j, O, Z) {
|
|
778
|
-
!M.value || (v.value && t === "colum" && !P() && (i(), v.value = !1), Z?.(),
|
|
778
|
+
!M.value || (v.value && t === "colum" && !P() && (i(), v.value = !1), Z?.(), N(O), a.value.x = Math.max(j, h.value.left), a.value.y = Math.min(
|
|
779
779
|
O + g.value.top,
|
|
780
780
|
g.value.height + h.value.top
|
|
781
781
|
), a.value.scrollTop = g.value.top, u.value());
|
|
@@ -864,7 +864,7 @@ function xo(e) {
|
|
|
864
864
|
i(g.x, g.y);
|
|
865
865
|
}
|
|
866
866
|
function a(g) {
|
|
867
|
-
window.removeEventListener("mousemove", f), window.removeEventListener("mouseup", a), g.composedPath().some((
|
|
867
|
+
window.removeEventListener("mousemove", f), window.removeEventListener("mouseup", a), g.composedPath().some((w) => w?.getAttribute?.(e.attribute)) || u(), c();
|
|
868
868
|
}
|
|
869
869
|
function p(g) {
|
|
870
870
|
try {
|
|
@@ -897,8 +897,8 @@ function Co(e, t, n = 600) {
|
|
|
897
897
|
}
|
|
898
898
|
function r(h) {
|
|
899
899
|
v(), h.composedPath().some((T) => !!T?.getAttribute?.(e.attribute)) && (d = setTimeout(() => {
|
|
900
|
-
const { clientX: T, clientY:
|
|
901
|
-
i(T,
|
|
900
|
+
const { clientX: T, clientY: w } = h.targetTouches[0];
|
|
901
|
+
i(T, w), t?.(), c(T, w, () => h.preventDefault()), h.preventDefault();
|
|
902
902
|
}, n));
|
|
903
903
|
}
|
|
904
904
|
function M(h) {
|
|
@@ -1361,32 +1361,32 @@ function Nt(e) {
|
|
|
1361
1361
|
});
|
|
1362
1362
|
Fe(s, (y) => f(y)), G(
|
|
1363
1363
|
[l, s],
|
|
1364
|
-
([y,
|
|
1365
|
-
a(y,
|
|
1364
|
+
([y, N]) => {
|
|
1365
|
+
a(y, N);
|
|
1366
1366
|
},
|
|
1367
1367
|
{ immediate: !0 }
|
|
1368
1368
|
);
|
|
1369
1369
|
async function f(y) {
|
|
1370
|
-
const [
|
|
1371
|
-
|
|
1370
|
+
const [N] = y;
|
|
1371
|
+
N.contentRect.width == c.value.width && N.contentRect.height == c.value.height || (await a(l.value), await h(u.level, !0));
|
|
1372
1372
|
}
|
|
1373
|
-
async function a(y,
|
|
1374
|
-
await L(y,
|
|
1373
|
+
async function a(y, N) {
|
|
1374
|
+
await L(y, N), y && k();
|
|
1375
1375
|
}
|
|
1376
1376
|
async function p(y) {
|
|
1377
1377
|
if (!u.preview)
|
|
1378
1378
|
return;
|
|
1379
1379
|
u.preview = !1, y = y ?? u.level;
|
|
1380
|
-
const
|
|
1381
|
-
if (!
|
|
1380
|
+
const N = s.value;
|
|
1381
|
+
if (!N)
|
|
1382
1382
|
return;
|
|
1383
|
-
const { scrollTop: C, scrollLeft: Q } =
|
|
1384
|
-
|
|
1383
|
+
const { scrollTop: C, scrollLeft: Q } = N, { width: _, height: E } = i.value, { scaleW: z, scaleH: B } = S(y), { top: $, left: b } = D(z, B), P = b != 0 ? b : Q * -1, J = $ != 0 ? $ : C * -1;
|
|
1384
|
+
N.scrollTop = 0, N.scrollLeft = 0;
|
|
1385
1385
|
const { value: V } = d;
|
|
1386
1386
|
V.width = `${_}px`, V.height = `${E}px`, V.maxHeight = "none", V.transitionDuration = "0s", V.transform = Oe(P, J, y), d.value = V, await Me(), u.offsetX = P, u.offsetY = J, await nt(20);
|
|
1387
1387
|
}
|
|
1388
|
-
async function h(y,
|
|
1389
|
-
if (!
|
|
1388
|
+
async function h(y, N) {
|
|
1389
|
+
if (!N && u.preview)
|
|
1390
1390
|
return;
|
|
1391
1391
|
u.preview = !0, y = y ?? u.level;
|
|
1392
1392
|
const { value: C } = d, { scaleW: Q, scaleH: _ } = S(y), { left: E, top: z } = D(Q, _);
|
|
@@ -1397,60 +1397,60 @@ function Nt(e) {
|
|
|
1397
1397
|
const { offsetX: $, offsetY: b } = u;
|
|
1398
1398
|
$ < 0 && (B.scrollLeft = Math.abs($)), b < 0 && (B.scrollTop = Math.abs(b));
|
|
1399
1399
|
}
|
|
1400
|
-
async function g(y,
|
|
1400
|
+
async function g(y, N, C) {
|
|
1401
1401
|
if (t.value || (y = ae(y), y = Se(
|
|
1402
1402
|
y,
|
|
1403
1403
|
n.value - n.value * 0.5,
|
|
1404
1404
|
o.value + o.value * 0.5
|
|
1405
1405
|
), y == u.level))
|
|
1406
1406
|
return;
|
|
1407
|
-
u.preview && await p(),
|
|
1407
|
+
u.preview && await p(), N || (N = { x: v.startX.value, y: v.startY.value });
|
|
1408
1408
|
const { value: Q } = d, { width: _, height: E } = i.value, { scaleW: z, scaleH: B } = S(y), { top: $, left: b } = D(z, B), P = y / u.level, J = {
|
|
1409
1409
|
left: Math.abs(_ * y - c.value.width) * -1,
|
|
1410
1410
|
top: Math.abs(E * y - c.value.height) * -1,
|
|
1411
1411
|
right: b,
|
|
1412
1412
|
bottom: $
|
|
1413
1413
|
};
|
|
1414
|
-
let V = b != 0 ? b : (u.offsetX -
|
|
1414
|
+
let V = b != 0 ? b : (u.offsetX - N.x) * P + N.x, oe = $ != 0 ? $ : (u.offsetY - N.y) * P + N.y;
|
|
1415
1415
|
V = ae(Se(V, J.left, J.right)), oe = ae(Se(oe, J.top, J.bottom)), Q.width = `${_}px`, Q.height = `${E}px`, Q.transitionDuration = C ? Cn(y) : "0s", Q.transform = Oe(V, oe, y), u.offsetX = V, u.offsetY = oe, u.level = y, d.value = Q, await Me(), C && r.startTransition(), e.onScale?.(y);
|
|
1416
1416
|
}
|
|
1417
1417
|
function T() {
|
|
1418
1418
|
const y = u.level > 1 ? 1 : R();
|
|
1419
1419
|
g(y, void 0, !0);
|
|
1420
1420
|
}
|
|
1421
|
-
function
|
|
1421
|
+
function w(y, N) {
|
|
1422
1422
|
if (!u.preview)
|
|
1423
1423
|
return;
|
|
1424
1424
|
const C = s.value;
|
|
1425
1425
|
!C || C.scrollTo({
|
|
1426
1426
|
left: u.offsetX - y,
|
|
1427
|
-
top: u.offsetY -
|
|
1427
|
+
top: u.offsetY - N
|
|
1428
1428
|
});
|
|
1429
1429
|
}
|
|
1430
1430
|
async function x() {
|
|
1431
1431
|
u.level >= n.value && u.level <= o.value ? u.zooming && await h() : u.level < n.value ? await g(n.value, void 0, !0) : u.level > o.value && await g(o.value, u.lastCenter, !0), u.zooming = !1;
|
|
1432
1432
|
}
|
|
1433
1433
|
function R() {
|
|
1434
|
-
const { width: y, height:
|
|
1434
|
+
const { width: y, height: N } = i.value, { width: C, height: Q } = c.value, _ = 2.5;
|
|
1435
1435
|
let E;
|
|
1436
|
-
return
|
|
1436
|
+
return N == Q ? (E = C / y, E - 1 < 0.1 && (E = _)) : E = Math.max(_, C / y, Q / N), E;
|
|
1437
1437
|
}
|
|
1438
1438
|
function S(y) {
|
|
1439
|
-
const { width:
|
|
1439
|
+
const { width: N, height: C } = i.value;
|
|
1440
1440
|
return {
|
|
1441
|
-
scaleW: ae(y *
|
|
1441
|
+
scaleW: ae(y * N),
|
|
1442
1442
|
scaleH: ae(y * C)
|
|
1443
1443
|
};
|
|
1444
1444
|
}
|
|
1445
|
-
function D(y,
|
|
1446
|
-
const { width: C, height: Q } = c.value, _ = Math.max(0, (Q -
|
|
1445
|
+
function D(y, N) {
|
|
1446
|
+
const { width: C, height: Q } = c.value, _ = Math.max(0, (Q - N) * 0.5), E = Math.max(0, (C - y) * 0.5);
|
|
1447
1447
|
return { top: _, left: E };
|
|
1448
1448
|
}
|
|
1449
|
-
async function L(y,
|
|
1450
|
-
if (y = y ?? l.value,
|
|
1449
|
+
async function L(y, N) {
|
|
1450
|
+
if (y = y ?? l.value, N = N ?? s.value, !N)
|
|
1451
1451
|
return;
|
|
1452
1452
|
let C, { clientWidth: Q = 0, clientHeight: _ = 0 } = y || {};
|
|
1453
|
-
const { clientWidth: E, clientHeight: z } =
|
|
1453
|
+
const { clientWidth: E, clientHeight: z } = N;
|
|
1454
1454
|
if (y instanceof HTMLImageElement ? C = { width: y.naturalWidth, height: y.naturalHeight } : y instanceof HTMLVideoElement && (C = { width: y.videoWidth, height: y.videoHeight }), C) {
|
|
1455
1455
|
const B = xn(
|
|
1456
1456
|
C.width,
|
|
@@ -1482,7 +1482,7 @@ function Nt(e) {
|
|
|
1482
1482
|
containerRef: s,
|
|
1483
1483
|
switchToZoom: p,
|
|
1484
1484
|
switchToPreview: h,
|
|
1485
|
-
panTo:
|
|
1485
|
+
panTo: w,
|
|
1486
1486
|
zoomTo: g,
|
|
1487
1487
|
zoomFinished: x,
|
|
1488
1488
|
toggleZoom: T,
|
|
@@ -1500,9 +1500,9 @@ function wt(e, t) {
|
|
|
1500
1500
|
}
|
|
1501
1501
|
function r(M, f, a, p) {
|
|
1502
1502
|
i.measure();
|
|
1503
|
-
const { top: h, left: g, right: T, bottom:
|
|
1503
|
+
const { top: h, left: g, right: T, bottom: w } = i.arrivedState;
|
|
1504
1504
|
if (M == "start")
|
|
1505
|
-
u = h || g || T ||
|
|
1505
|
+
u = h || g || T || w;
|
|
1506
1506
|
else if (c == 2)
|
|
1507
1507
|
u = !1;
|
|
1508
1508
|
else if (u) {
|
|
@@ -1511,7 +1511,7 @@ function wt(e, t) {
|
|
|
1511
1511
|
u = !1;
|
|
1512
1512
|
else {
|
|
1513
1513
|
const x = o.startY.value < a;
|
|
1514
|
-
u = h && x ||
|
|
1514
|
+
u = h && x || w && !x;
|
|
1515
1515
|
}
|
|
1516
1516
|
else if (o.direction.value == "horizontal") {
|
|
1517
1517
|
const x = o.startX.value < f;
|
|
@@ -1532,38 +1532,41 @@ function ko(e) {
|
|
|
1532
1532
|
let i = !1, c = null;
|
|
1533
1533
|
const u = { top: 0, left: 0 }, d = Le(h, 150), { onSwipeEdge: v } = wt(t, e.onSwipeEdge), r = m({ top: 0, left: 0 });
|
|
1534
1534
|
Te("keyup", T), Te("keydown", g);
|
|
1535
|
-
function M(
|
|
1536
|
-
const x =
|
|
1535
|
+
function M(w) {
|
|
1536
|
+
const x = t.containerRef.value;
|
|
1537
|
+
if (!x)
|
|
1538
|
+
return;
|
|
1539
|
+
const { left: R, top: S } = x.getBoundingClientRect();
|
|
1537
1540
|
r.value.left = R, r.value.top = S, l.startTap();
|
|
1538
|
-
let D =
|
|
1539
|
-
o.start(D, L), v("start", D, L,
|
|
1541
|
+
let D = w.clientX - R, L = w.clientY - S;
|
|
1542
|
+
o.start(D, L), v("start", D, L, w), s.transitioning.value || (i = !0, u.left = R, u.top = S, n.offsetX = x.scrollLeft, n.offsetY = x.scrollTop), window.addEventListener("pointermove", f), window.addEventListener("pointerup", a);
|
|
1540
1543
|
}
|
|
1541
|
-
function f(
|
|
1544
|
+
function f(w) {
|
|
1542
1545
|
if (!i)
|
|
1543
1546
|
return;
|
|
1544
|
-
let x =
|
|
1545
|
-
o.move(x, R), v("move", x - r.value.left, R - r.value.top,
|
|
1547
|
+
let x = w.clientX, R = w.clientY;
|
|
1548
|
+
o.move(x, R), v("move", x - r.value.left, R - r.value.top, w), n.level !== 1 && t.panTo(
|
|
1546
1549
|
o.deltaX.value - u.left,
|
|
1547
1550
|
o.deltaY.value - u.top
|
|
1548
1551
|
);
|
|
1549
1552
|
}
|
|
1550
|
-
function a(
|
|
1551
|
-
v("end", o.offsetX.value, o.offsetY.value,
|
|
1553
|
+
function a(w) {
|
|
1554
|
+
v("end", o.offsetX.value, o.offsetY.value, w), l.checkTap(o.offsetX.value, o.offsetY.value), o.reset(), i = !1, window.removeEventListener("pointermove", f), window.removeEventListener("pointerup", a);
|
|
1552
1555
|
}
|
|
1553
|
-
function p(
|
|
1554
|
-
if (!
|
|
1556
|
+
function p(w) {
|
|
1557
|
+
if (!w.ctrlKey)
|
|
1555
1558
|
return;
|
|
1556
|
-
n.zooming || (n.zooming = !0, c == "Control" && window.addEventListener("keyup", h)),
|
|
1557
|
-
let x = -
|
|
1558
|
-
|
|
1559
|
+
n.zooming || (n.zooming = !0, c == "Control" && window.addEventListener("keyup", h)), w.preventDefault();
|
|
1560
|
+
let x = -w.deltaY;
|
|
1561
|
+
w.deltaMode === 1 ? x *= 0.05 : x *= w.deltaMode ? 1 : 2e-3, c != "Control" && (x *= 10), x = 2 ** x;
|
|
1559
1562
|
const R = n.level * x;
|
|
1560
|
-
n.lastCenter = { x:
|
|
1563
|
+
n.lastCenter = { x: w.offsetX, y: w.offsetY }, t.zoomTo(R, n.lastCenter), c != "Control" && d();
|
|
1561
1564
|
}
|
|
1562
1565
|
function h() {
|
|
1563
1566
|
t.zoomFinished(), window.removeEventListener("keyup", h);
|
|
1564
1567
|
}
|
|
1565
|
-
function g(
|
|
1566
|
-
c =
|
|
1568
|
+
function g(w) {
|
|
1569
|
+
c = w.key;
|
|
1567
1570
|
}
|
|
1568
1571
|
function T() {
|
|
1569
1572
|
c = null;
|
|
@@ -1796,7 +1799,7 @@ function Bn(e) {
|
|
|
1796
1799
|
clientHeight: 0
|
|
1797
1800
|
}), p = m({
|
|
1798
1801
|
clientHeight: 0
|
|
1799
|
-
}), h = A(() => !!M.value), g = A(() => a.value.scrollHeight > a.value.clientHeight), T = A(() => o ? a.value.clientHeight - R.value : a.value.clientHeight - p.value.clientHeight),
|
|
1802
|
+
}), h = A(() => !!M.value), g = A(() => a.value.scrollHeight > a.value.clientHeight), T = A(() => o ? a.value.clientHeight - R.value : a.value.clientHeight - p.value.clientHeight), w = A(() => a.value.scrollHeight - a.value.clientHeight), x = A(() => !a.value.clientHeight && !a.value.scrollHeight ? 1 : Math.max(
|
|
1800
1803
|
a.value.clientHeight / a.value.scrollHeight,
|
|
1801
1804
|
0.05
|
|
1802
1805
|
)), R = A(() => x.value > s ? 0 : x.value * a.value.clientHeight), S = A(() => ({
|
|
@@ -1822,17 +1825,17 @@ function Bn(e) {
|
|
|
1822
1825
|
return;
|
|
1823
1826
|
let P = b.clientY - a.value.top - M.value;
|
|
1824
1827
|
P < 0 ? f.value = 0 : P >= T.value ? f.value = T.value : f.value = P, t.value.scrollTo({
|
|
1825
|
-
top: f.value / T.value *
|
|
1828
|
+
top: f.value / T.value * w.value
|
|
1826
1829
|
});
|
|
1827
1830
|
}
|
|
1828
|
-
function
|
|
1831
|
+
function N() {
|
|
1829
1832
|
h.value || C();
|
|
1830
1833
|
}
|
|
1831
1834
|
function C() {
|
|
1832
1835
|
cancelAnimationFrame(d), d = requestAnimationFrame(Q);
|
|
1833
1836
|
}
|
|
1834
1837
|
function Q() {
|
|
1835
|
-
t.value && (r.value = l.scrollTop?.value ?? t.value.scrollTop, f.value = r.value /
|
|
1838
|
+
t.value && (r.value = l.scrollTop?.value ?? t.value.scrollTop, f.value = r.value / w.value * T.value);
|
|
1836
1839
|
}
|
|
1837
1840
|
function _(b) {
|
|
1838
1841
|
let P = "addEventListener";
|
|
@@ -1857,7 +1860,7 @@ function Bn(e) {
|
|
|
1857
1860
|
}
|
|
1858
1861
|
function $() {
|
|
1859
1862
|
if (t.value && n.value) {
|
|
1860
|
-
t.value.classList.add("hide-scrollbar"), t.value.addEventListener("scroll",
|
|
1863
|
+
t.value.classList.add("hide-scrollbar"), t.value.addEventListener("scroll", N, {
|
|
1861
1864
|
passive: !0
|
|
1862
1865
|
}), _("add");
|
|
1863
1866
|
const b = {};
|
|
@@ -1978,7 +1981,7 @@ const Ro = /* @__PURE__ */ ne($n, [["__scopeId", "data-v-7fd39e51"]]), Hn = (e)
|
|
|
1978
1981
|
const L = Math.pow(D, n);
|
|
1979
1982
|
L === 0 && (l.value = -50), L <= 50 && L > 0 && (l.value = L - 45, i.value = Math.pow(L, 1.5), L > 15 ? u.value = !0 : u.value = !1), L > 50 && (l.value = 5, c.value = 1, f.value);
|
|
1980
1983
|
});
|
|
1981
|
-
const T = m(0),
|
|
1984
|
+
const T = m(0), w = (D) => {
|
|
1982
1985
|
T.value = D.touches[0].pageY;
|
|
1983
1986
|
}, x = (D) => {
|
|
1984
1987
|
const L = D.touches[0].pageY - T.value;
|
|
@@ -2006,7 +2009,7 @@ const Ro = /* @__PURE__ */ ne($n, [["__scopeId", "data-v-7fd39e51"]]), Hn = (e)
|
|
|
2006
2009
|
return ce(() => {
|
|
2007
2010
|
t?.refreshOff || (S.value = document.querySelector(
|
|
2008
2011
|
t.pullRefreshContainer
|
|
2009
|
-
), S.value?.addEventListener("touchstart",
|
|
2012
|
+
), S.value?.addEventListener("touchstart", w), S.value?.addEventListener("touchmove", x), S.value?.addEventListener("touchend", R));
|
|
2010
2013
|
}), (D, L) => (Y(), H("div", Pn, [
|
|
2011
2014
|
U("div", {
|
|
2012
2015
|
class: "pull-refresh-box",
|
|
@@ -2223,14 +2226,14 @@ const fo = ["title"], vo = { class: "tip" }, Mo = /* @__PURE__ */ Bt("\u5F53\u52
|
|
|
2223
2226
|
function T() {
|
|
2224
2227
|
i.value && (c.value = !0);
|
|
2225
2228
|
}
|
|
2226
|
-
async function
|
|
2229
|
+
async function w() {
|
|
2227
2230
|
g(), h.value ? (o.value?.addEventListener("animationend", x), o.value?.classList.add("showing"), await nt(10)) : o.value && t("load", o.value), o.value?.classList.remove("src-class");
|
|
2228
2231
|
}
|
|
2229
2232
|
function x() {
|
|
2230
2233
|
o.value?.removeEventListener("animationend", x), o.value?.classList.remove("showing"), o.value && t("load", o.value), T();
|
|
2231
2234
|
}
|
|
2232
2235
|
async function R(L) {
|
|
2233
|
-
L ?
|
|
2236
|
+
L ? w() : l.value && t("load", l.value), s.value = !0;
|
|
2234
2237
|
}
|
|
2235
2238
|
function S(L) {
|
|
2236
2239
|
L ? (f(), t("loadError")) : g(), s.value = !0;
|
package/dist/index.umd.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
(function(E,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(E=typeof globalThis<"u"?globalThis:E||self,e(E.ui={},E.Vue))})(this,function(E,e){"use strict";const je={created(t,n){let o,l;function s(r){r.button==0&&(o=r.clientX,l=r.clientY)}function a(r){if(r.button!=0||o===void 0)return;const d=r.clientX,c=r.clientY,f=Math.abs(d-o),g=Math.abs(c-l);f>5||g>5||n.value&&n.value(r)}t.__mouse_down__=s,t.__mouse_up__=a,t.addEventListener("mousedown",s),t.addEventListener("mouseup",a)},unmounted(t){t.removeEventListener("mousedown",t.__mouse_down__),t.removeEventListener("mouseup",t.__mouse_up__)}},Ze={created(t,n){const{fn:o,ms:l=1500}=n.value;let s=null;function a(r){s||(o(r),s=setTimeout(()=>{s=null},l))}t.addEventListener("click",a)}},me={beforeMount(t,n){n.value()}};function Ke(t,n){var o;const l=e.shallowRef();return e.watchEffect(()=>{l.value=t()},{...n,flush:(o=n?.flush)!=null?o:"sync"}),e.readonly(l)}function Ge(t,n){let o,l,s;const a=e.ref(!0),r=()=>{a.value=!0,s()};e.watch(t,r,{flush:"sync"});const d=typeof n=="function"?n:n.get,c=typeof n=="function"?void 0:n.set,f=e.customRef((g,u)=>(l=g,s=u,{get(){return a.value&&(o=d(),a.value=!1),l(),o},set(m){c?.(m)}}));return Object.isExtensible(f)&&(f.trigger=r),f}function he(t){return e.getCurrentScope()?(e.onScopeDispose(t),!0):!1}function V(t){return typeof t=="function"?t():e.unref(t)}const Ce=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const qe=Object.prototype.toString,Je=t=>qe.call(t)==="[object Object]",q=()=>{};function Se(t,n){function o(...l){return new Promise((s,a)=>{Promise.resolve(t(()=>n.apply(this,l),{fn:n,thisArg:this,args:l})).then(s).catch(a)})}return o}function et(t,n={}){let o,l,s=q;const a=d=>{clearTimeout(d),s(),s=q};return d=>{const c=V(t),f=V(n.maxWait);return o&&a(o),c<=0||f!==void 0&&f<=0?(l&&(a(l),l=null),Promise.resolve(d())):new Promise((g,u)=>{s=n.rejectOnCancel?u:g,f&&!l&&(l=setTimeout(()=>{o&&a(o),l=null,g(d())},f)),o=setTimeout(()=>{l&&a(l),l=null,g(d())},c)})}}function tt(...t){let n=0,o,l=!0,s=q,a,r,d,c,f;!e.isRef(t[0])&&typeof t[0]=="object"?{delay:r,trailing:d=!0,leading:c=!0,rejectOnCancel:f=!1}=t[0]:[r,d=!0,c=!0,f=!1]=t;const g=()=>{o&&(clearTimeout(o),o=void 0,s(),s=q)};return m=>{const M=V(r),i=Date.now()-n,D=()=>a=m();return g(),M<=0?(n=Date.now(),D()):(i>M&&(c||!l)?(n=Date.now(),D()):d&&(a=new Promise((p,h)=>{s=f?h:p,o=setTimeout(()=>{n=Date.now(),l=!0,p(D()),g()},Math.max(0,M-i))})),!c&&!o&&(o=setTimeout(()=>l=!0,M)),l=!1,a)}}function nt(t){return t||e.getCurrentInstance()}function ne(t,n=200,o={}){return Se(et(n,o),t)}function pe(t,n=200,o=!1,l=!0,s=!1){return Se(tt(n,o,l,s),t)}function ye(t,n=!0,o){nt()?e.onMounted(t,o):n?t():e.nextTick(t)}function X(t){var n;const o=V(t);return(n=o?.$el)!=null?n:o}const oe=Ce?window:void 0,ot=Ce?window.document:void 0;function le(...t){let n,o,l,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([o,l,s]=t,n=oe):[n,o,l,s]=t,!n)return q;Array.isArray(o)||(o=[o]),Array.isArray(l)||(l=[l]);const a=[],r=()=>{a.forEach(g=>g()),a.length=0},d=(g,u,m,M)=>(g.addEventListener(u,m,M),()=>g.removeEventListener(u,m,M)),c=e.watch(()=>[X(n),V(s)],([g,u])=>{if(r(),!g)return;const m=Je(u)?{...u}:u;a.push(...o.flatMap(M=>l.map(i=>d(g,M,i,m))))},{immediate:!0,flush:"post"}),f=()=>{c(),r()};return he(f),f}function lt(){const t=e.ref(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function st(t){const n=lt();return e.computed(()=>(n.value,Boolean(t())))}function at(t){const n=e.getCurrentInstance(),o=Ge(()=>null,()=>t?X(t):n.proxy.$el);return e.onUpdated(o.trigger),e.onMounted(o.trigger),o}function De(t,n,o={}){const{window:l=oe,...s}=o;let a;const r=st(()=>l&&"ResizeObserver"in l),d=()=>{a&&(a.disconnect(),a=void 0)},c=e.computed(()=>Array.isArray(t)?t.map(u=>X(u)):[X(t)]),f=e.watch(c,u=>{if(d(),r.value&&l){a=new ResizeObserver(n);for(const m of u)m&&a.observe(m,s)}},{immediate:!0,flush:"post"}),g=()=>{d(),f()};return he(g),{isSupported:r,stop:g}}function it(t,n={width:0,height:0},o={}){const{window:l=oe,box:s="content-box"}=o,a=e.computed(()=>{var u,m;return(m=(u=X(t))==null?void 0:u.namespaceURI)==null?void 0:m.includes("svg")}),r=e.ref(n.width),d=e.ref(n.height),{stop:c}=De(t,([u])=>{const m=s==="border-box"?u.borderBoxSize:s==="content-box"?u.contentBoxSize:u.devicePixelContentBoxSize;if(l&&a.value){const M=X(t);if(M){const i=l.getComputedStyle(M);r.value=Number.parseFloat(i.width),d.value=Number.parseFloat(i.height)}}else if(m){const M=Array.isArray(m)?m:[m];r.value=M.reduce((i,{inlineSize:D})=>i+D,0),d.value=M.reduce((i,{blockSize:D})=>i+D,0)}else r.value=u.contentRect.width,d.value=u.contentRect.height},o);ye(()=>{const u=X(t);u&&(r.value="offsetWidth"in u?u.offsetWidth:n.width,d.value="offsetHeight"in u?u.offsetHeight:n.height)});const f=e.watch(()=>X(t),u=>{r.value=u?n.width:0,d.value=u?n.height:0});function g(){c(),f()}return{width:r,height:d,stop:g}}const xe=1;function rt(t,n={}){const{throttle:o=0,idle:l=200,onStop:s=q,onScroll:a=q,offset:r={left:0,right:0,top:0,bottom:0},eventListenerOptions:d={capture:!1,passive:!0},behavior:c="auto",window:f=oe,onError:g=T=>{console.error(T)}}=n,u=e.ref(0),m=e.ref(0),M=e.computed({get(){return u.value},set(T){D(T,void 0)}}),i=e.computed({get(){return m.value},set(T){D(void 0,T)}});function D(T,A){var b,$,y;if(!f)return;const v=V(t);!v||(y=v instanceof Document?f.document.body:v)==null||y.scrollTo({top:(b=V(A))!=null?b:i.value,left:($=V(T))!=null?$:M.value,behavior:V(c)})}const p=e.ref(!1),h=e.reactive({left:!0,right:!1,top:!0,bottom:!1}),N=e.reactive({left:!1,right:!1,top:!1,bottom:!1}),w=T=>{!p.value||(p.value=!1,N.left=!1,N.right=!1,N.top=!1,N.bottom=!1,s(T))},j=ne(w,o+l),Q=T=>{var A;if(!f)return;const b=((A=T?.document)==null?void 0:A.documentElement)||T?.documentElement||X(T),{display:$,flexDirection:y}=getComputedStyle(b),v=b.scrollLeft;N.left=v<u.value,N.right=v>u.value;const C=Math.abs(v)<=(r.left||0),k=Math.abs(v)+b.clientWidth>=b.scrollWidth-(r.right||0)-xe;$==="flex"&&y==="row-reverse"?(h.left=k,h.right=C):(h.left=C,h.right=k),u.value=v;let _=b.scrollTop;T===f.document&&!_&&(_=f.document.body.scrollTop),N.top=_<m.value,N.bottom=_>m.value;const I=Math.abs(_)<=(r.top||0),z=Math.abs(_)+b.clientHeight>=b.scrollHeight-(r.bottom||0)-xe;$==="flex"&&y==="column-reverse"?(h.top=z,h.bottom=I):(h.top=I,h.bottom=z),m.value=_},S=T=>{var A;if(!f)return;const b=(A=T.target.documentElement)!=null?A:T.target;Q(b),p.value=!0,j(T),a(T)};return le(t,"scroll",o?pe(S,o,!0,!1):S,d),ye(()=>{try{const T=V(t);if(!T)return;Q(T)}catch(T){g(T)}}),le(t,"scrollend",w,d),{x:M,y:i,isScrolling:p,arrivedState:h,directions:N,measure(){const T=V(t);f&&T&&Q(T)}}}let ct=0;function Te(t,n={}){const o=e.ref(!1),{document:l=ot,immediate:s=!0,manual:a=!1,id:r=`vueuse_styletag_${++ct}`}=n,d=e.ref(t);let c=()=>{};const f=()=>{if(!l)return;const u=l.getElementById(r)||l.createElement("style");u.isConnected||(u.id=r,n.media&&(u.media=n.media),l.head.appendChild(u)),!o.value&&(c=e.watch(d,m=>{u.textContent=m},{immediate:!0}),o.value=!0)},g=()=>{!l||!o.value||(c(),l.head.removeChild(l.getElementById(r)),o.value=!1)};return s&&!a&&ye(f),a||he(g),{id:r,css:d,unload:g,load:f,isLoaded:e.readonly(o)}}function ut(t,n,o){const l=t.style[n];return l!=o&&(t.style[n]=o),{reset(){l!=o&&(t.style[n]=l)}}}function _e(t,n){const{scrollEndHook:o,itemHeight:l,overscan:s=5}=n,a=e.ref(null),r=it(a),d=e.ref(!0),c=ne(Q,100);let f;const g=e.shallowRef(t),u=e.ref(0),m=e.ref({start:0,end:10}),M=e.ref({start:0,end:s});let i=0;const D=e.ref([]),p=e.computed(()=>{let{sum:I,height:z}={sum:0,height:0};return g.value.map((B,Y)=>(typeof l=="number"?z=l:z=l(Y),I+=z,{height:z,sum:I}))}),h=e.computed(()=>$(m.value.start)),N=e.computed(()=>typeof l=="number"?p.value.length*l:p.value[p.value.length-1]?.sum||0),w=e.computed(()=>{const{start:I,end:z}=M.value;return D.value.slice(I,z)});e.onMounted(()=>{}),e.onUnmounted(()=>cancelAnimationFrame(f)),e.watch(g,()=>{(r.width.value||r.height.value)&&S()},{deep:!0}),e.watch([r.width,r.height],([I,z])=>{(I||z)&&S()},{deep:!0}),e.watch(u,()=>{j(),c()});function j(){d.value=!1}function Q(){d.value=!0,o?.()}function S(){cancelAnimationFrame(f),f=requestAnimationFrame(T)}function T(){if(a.value){u.value=a.value.scrollTop;let I=A(u.value);i=b(I);let z=Math.max(0,I-s),B=Math.min(I+i+s,g.value.length);m.value={start:z,end:B},D.value=g.value.slice(z,B).map((Y,O)=>({data:Y,index:O+z})),M.value.start=I-z,M.value.end=M.value.start+i}}function A(I){let z=0,B=p.value.length-1,Y=-1;for(;z<=B;){const O=Math.floor((z+B)/2);p.value[O].sum>=I?(Y=O,B=O-1):z=O+1}return Math.max(0,Y)}function b(I){let z=0,B=0;for(let Y=I;Y<p.value.length&&(z++,B+=p.value[Y].height,!(B>=r.height.value));Y++);return z}function $(I){if(typeof l=="number")return I*l;let z=p.value[I];return z?z.sum-z.height:0}function y(I){return p.value[I]||{sum:0,height:0}}function v(I,z="smooth"){if(a.value){const{reset:B}=ut(a.value,"scrollBehavior",z),Y=y(I);a.value.scrollTop=Y.sum-Y.height,T(),B()}if(a.value){const B=y(I);a.value.scrollTop=B.sum-B.height,T()}}const C=e.computed(()=>({style:{width:"100%",height:`${N.value}px`,pointerEvents:d.value?void 0:"none"}})),k=e.computed(()=>({style:{transform:`translate3d(0, ${h.value}px, 0)`,"will-change":"transform"}})),_={overflowY:"auto"};return{list:D,visiableList:w,getItemHeightData:y,getoffsetTopIndex:A,totalHeight:N,clientHeight:r.height,scrollTo:v,scrollTop:u,isScrollEnd:d,containerProps:{ref:a,onScroll:()=>{S()},style:_},wrapperProps:C,innerProps:k}}const Ne=Symbol(),se=Symbol(),ae=Symbol(),ie=Symbol(),re=Symbol(),ce=Symbol(),ue=Symbol(),de=Symbol(),fe=Symbol(),J=Symbol(),Me=Symbol();function dt(){const{voidFn:t,boolFn:n,boolRef:o,numberRef:l,arrayRef:s}={voidFn:p=>{},boolFn:p=>!1,boolRef:e.computed(()=>!1),numberRef:e.computed(()=>0),arrayRef:e.computed(()=>[])},a=e.inject(Ne,"id"),r=e.inject(re,s),d=e.inject(ie,n),c=e.inject(fe,o),f=e.inject(ae,t),g=e.inject(se,t),u=e.inject(ce,t),m=e.inject(ue,t),M=e.inject(de,t),i=e.inject(J,t),D=e.inject(Me,l);return{itemKey:a,selected:r,isSelected:d,isAllSelected:c,toggle:f,toggleAll:g,select:u,selectAll:m,unselect:M,unselectAll:i,selectedCount:D}}function ft(t,n,o={deep:!0}){const l=e.ref(!1),s=e.ref(new Set),a=e.ref(new Map);e.watch(t,h=>{a.value=h.reduce((N,w)=>(N.set(w[n],w),N),new Map)},{deep:o.deep,immediate:!0});const r=e.computed(()=>{let h=[];if(l.value!=null)l.value&&(h=Array.from(a.value.values()));else if(s.value.size){let N;s.value.forEach(w=>{N=a.value.get(w),N&&h.push(N)})}return h}),d=e.computed(()=>{let h=0;return l.value!=null?l.value&&(h=a.value.size):h=s.value.size,h}),c=e.computed(()=>{let h;if(l.value!=null)h=l.value;else{const N=s.value.size,w=a.value.size;h=N==w}return h});function f(){l.value=!0}function g(){l.value=!1}function u(h){i(()=>{h.forEach(N=>{s.value.add(N[n])})})}function m(h){i(()=>{h.forEach(N=>{s.value.delete(N[n])})})}function M(h){return l.value!=null?l.value:s.value.has(h[n])}function i(h){l.value!=null&&(l.value?s.value=new Set(Array.from(a.value.keys())):s.value=new Set),h(),s.value.size==0?l.value=!1:s.value.size==a.value.size?l.value=!0:l.value=null}function D(h){i(()=>{h.forEach(N=>{M(N)?s.value.delete(N[n]):s.value.add(N[n])})})}function p(){const{value:h}=c;h?g():f()}return e.provide(Ne,n),e.provide(se,p),e.provide(ae,D),e.provide(ie,M),e.provide(re,r),e.provide(ce,u),e.provide(ue,f),e.provide(de,m),e.provide(fe,c),e.provide(J,g),e.provide(J,g),e.provide(Me,d),{selected:r,select:u,selectAll:f,unselect:m,unselectAll:g,toggle:D,toggleAll:p,isSelected:M,isAllSelected:c,selectedCount:d}}function Mt(t){const n=e.ref(!1),o=e.ref(new Set),l=e.computed(()=>{let i=[];return n.value!=null?n.value&&(i=t.value):o.value.size&&(i=Array.from(o.value.values())),i}),s=e.computed(()=>{let i=0;return n.value!=null?n.value&&(i=t.value.length):i=o.value.size,i}),a=e.computed(()=>{let i;if(n.value!=null)i=n.value;else{const D=o.value.size,p=t.value.length;i=D==p}return i});function r(){n.value=!0}function d(){n.value=!1}function c(i){u(()=>{i.forEach(D=>{o.value.add(D)})})}function f(i){u(()=>{i.forEach(D=>{o.value.delete(D)})})}function g(i){return n.value!=null?n.value:o.value.has(i)}function u(i){n.value!=null&&(n.value?o.value=new Set(Array.from(t.value)):o.value=new Set),i(),o.value.size==0?n.value=!1:o.value.size==t.value.length?n.value=!0:n.value=null}function m(i){u(()=>{i.forEach(D=>{g(D)?o.value.delete(D):o.value.add(D)})})}function M(){const{value:i}=a;i?d():r()}return e.provide(se,M),e.provide(ae,m),e.provide(ie,g),e.provide(re,l),e.provide(ce,c),e.provide(ue,r),e.provide(de,f),e.provide(fe,a),e.provide(J,d),e.provide(J,d),e.provide(Me,s),{selected:l,select:c,selectAll:r,unselect:f,unselectAll:d,toggle:m,toggleAll:M,isSelected:g,isAllSelected:a,selectedCount:s}}function we(t){return()=>{console.debug(`\u9ED8\u8BA4${t}\u65B9\u6CD5,\u9700\u8981\u81EA\u5B9A\u4E49\u751F\u6548`)}}function ve({attribute:t,selectWay:n="colum",scrollOptions:o={},getSelectMap:l=()=>({})}){const{select:s=we("\u9009\u62E9"),unselect:a=we("\u53D6\u6D88\u9009\u62E9"),unselectAll:r=we("\u53D6\u6D88\u5168\u9009")}=l();let d={};const c=e.computed(()=>pe(n==="colum"?H:K,50)),f=new Set,g=e.ref(!0),u=e.ref(),m=e.ref(!1),M=e.ref({x:0,y:0}),i=e.ref({x:0,y:0,scrollTop:0}),D=new ResizeObserver(L=>p.value=L[0].target.getBoundingClientRect()),p=e.ref({}),h=e.ref({top:0,height:0,sync(L=!1){h.value.top=u.value?.scrollTop||0,L&&(h.value.height=u.value?.scrollHeight||0)}}),N=e.computed(()=>m.value?{left:Math.min(M.value.x,i.value.x)-p.value.left,top:Math.min(M.value.y,i.value.y)-p.value.top,width:Math.abs(M.value.x-i.value.x),height:Math.abs(M.value.y-i.value.y)}:{left:0,top:0,width:0,height:0}),{margin:w=50,startSpeed:j=30,maxSpeed:Q=30}=o;let S;const T=w,A=j,b=Q,$=L=>L**1;let y=0;function v(L){if(cancelAnimationFrame(S),y=C(L),y=Math.max(Math.min(y,b),-b),y!==0){const x=u.value;if(!x||!m.value)return;const P=h.value.height-p.value.height;let R=h.value.top+Number(y);R=Math.min(Math.max(0,R),P),x.scrollTop=R,_(),S=requestAnimationFrame(()=>v(L))}}function C(L){if(u.value){const P=p.value,R=P.bottom-L;if(R<T)return A*$(1-R/T);const G=L-P.top;if(G<T)return-A*$(1-G/T)}return 0}function k(L){const x={...N.value,right:0,bottom:0};return x.left+=p.value.left,x.top+=p.value.top-h.value.top,x.right=x.width+x.left,x.bottom=x.height+x.top,x.left<L.right&&x.right>L.left&&x.top<L.bottom&&x.bottom>L.top}function _(){h.value.sync();const{top:L,height:x}=h.value;i.value.y=Math.min(x+p.value.top,i.value.y+L-i.value.scrollTop),i.value.scrollTop=L}function I(L,x,P="dynamic-styles"){let R=document.getElementById(P);R||(R=document.createElement("style"),R.id=P,document.head.appendChild(R));const G=R.sheet.cssRules,ee=G.length,Un=`${L} { ${x} }`;for(let Le=0;Le<ee;Le++){const Xe=G[Le];if(Xe.selectorText===L&&Xe.style.cssText===x)return}R.sheet.insertRule(Un,ee)}function z(L,x){g.value=!0,m.value=!0,h.value.sync(!0);const P=x+h.value.top;M.value.x=L,M.value.y=P,i.value.x=L,i.value.y=P,u.value?.classList.add("disable-scroll-behavior"),f.clear()}function B(L,x,P){!m.value||(g.value&&n==="colum"&&!U()&&(r(),g.value=!1),P?.(),v(x),i.value.x=Math.max(L,p.value.left),i.value.y=Math.min(x+h.value.top,h.value.height+p.value.top),i.value.scrollTop=h.value.top,c.value())}function Y(){m.value=!1,u.value?.classList.remove("disable-scroll-behavior")}function O(){!m.value||(y||_(),c.value())}function U(){if(!m.value)return!1;const{width:L,height:x}=N.value;return!(Math.max(L,x)>5)}function F(){U()&&r()}function H(){U()||u.value?.querySelectorAll(`[${t}]`).forEach(L=>{d[`${t}`]=L.getAttribute(`${t}`),k(L.getBoundingClientRect())?s([d]):a([d])})}function K(){const L=[];let x=null,P=0;u.value?.querySelectorAll(`[${t}]`).forEach((R,G)=>{const ee=R.getAttribute(`${t}`);L.push(ee),k(R.getBoundingClientRect())?(x===null&&(x=G),x=Math.min(x,G),P=Math.max(P,G)):(d[`${t}`]=ee,f.has(ee)&&a([d]))});for(let R=x;R<P+1;R++)d[`${t}`]=L[R],s([d]),f.add(L[R])}function Yn(L){return!L?.value||(u.value=L.value,!u?.value)?!1:(D.observe(u.value),I(".disable-scroll-behavior","scroll-behavior: unset !important;"),!0)}return{init:Yn,dragStart:z,dragMove:B,dragEnd:Y,onScroll:O,isSingleClick:U,cancelSelectAllBySingleClick:F,selectFn:c,selectRange:N,isPressing:m,containerEl:u,observer:D}}function gt(t){const n=ve(t),{observer:o,selectRange:l}=n,{onScroll:s,dragStart:a,dragMove:r,dragEnd:d,cancelSelectAllBySingleClick:c}=n,f=e.computed(()=>({left:`${l.value.left}px`,top:`${l.value.top}px`,width:`${l.value.width}px`,height:`${l.value.height}px`})),{load:g}=Te(`.drag-select-box {
|
|
1
|
+
(function(v,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(v=typeof globalThis<"u"?globalThis:v||self,e(v.ui={},v.Vue))})(this,function(v,e){"use strict";const je={created(t,n){let o,l;function s(r){r.button==0&&(o=r.clientX,l=r.clientY)}function a(r){if(r.button!=0||o===void 0)return;const d=r.clientX,c=r.clientY,f=Math.abs(d-o),g=Math.abs(c-l);f>5||g>5||n.value&&n.value(r)}t.__mouse_down__=s,t.__mouse_up__=a,t.addEventListener("mousedown",s),t.addEventListener("mouseup",a)},unmounted(t){t.removeEventListener("mousedown",t.__mouse_down__),t.removeEventListener("mouseup",t.__mouse_up__)}},Ze={created(t,n){const{fn:o,ms:l=1500}=n.value;let s=null;function a(r){s||(o(r),s=setTimeout(()=>{s=null},l))}t.addEventListener("click",a)}},me={beforeMount(t,n){n.value()}};function Ke(t,n){var o;const l=e.shallowRef();return e.watchEffect(()=>{l.value=t()},{...n,flush:(o=n?.flush)!=null?o:"sync"}),e.readonly(l)}function Ge(t,n){let o,l,s;const a=e.ref(!0),r=()=>{a.value=!0,s()};e.watch(t,r,{flush:"sync"});const d=typeof n=="function"?n:n.get,c=typeof n=="function"?void 0:n.set,f=e.customRef((g,u)=>(l=g,s=u,{get(){return a.value&&(o=d(),a.value=!1),l(),o},set(m){c?.(m)}}));return Object.isExtensible(f)&&(f.trigger=r),f}function he(t){return e.getCurrentScope()?(e.onScopeDispose(t),!0):!1}function V(t){return typeof t=="function"?t():e.unref(t)}const Ce=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const qe=Object.prototype.toString,Je=t=>qe.call(t)==="[object Object]",q=()=>{};function Se(t,n){function o(...l){return new Promise((s,a)=>{Promise.resolve(t(()=>n.apply(this,l),{fn:n,thisArg:this,args:l})).then(s).catch(a)})}return o}function et(t,n={}){let o,l,s=q;const a=d=>{clearTimeout(d),s(),s=q};return d=>{const c=V(t),f=V(n.maxWait);return o&&a(o),c<=0||f!==void 0&&f<=0?(l&&(a(l),l=null),Promise.resolve(d())):new Promise((g,u)=>{s=n.rejectOnCancel?u:g,f&&!l&&(l=setTimeout(()=>{o&&a(o),l=null,g(d())},f)),o=setTimeout(()=>{l&&a(l),l=null,g(d())},c)})}}function tt(...t){let n=0,o,l=!0,s=q,a,r,d,c,f;!e.isRef(t[0])&&typeof t[0]=="object"?{delay:r,trailing:d=!0,leading:c=!0,rejectOnCancel:f=!1}=t[0]:[r,d=!0,c=!0,f=!1]=t;const g=()=>{o&&(clearTimeout(o),o=void 0,s(),s=q)};return m=>{const M=V(r),i=Date.now()-n,D=()=>a=m();return g(),M<=0?(n=Date.now(),D()):(i>M&&(c||!l)?(n=Date.now(),D()):d&&(a=new Promise((p,h)=>{s=f?h:p,o=setTimeout(()=>{n=Date.now(),l=!0,p(D()),g()},Math.max(0,M-i))})),!c&&!o&&(o=setTimeout(()=>l=!0,M)),l=!1,a)}}function nt(t){return t||e.getCurrentInstance()}function ne(t,n=200,o={}){return Se(et(n,o),t)}function pe(t,n=200,o=!1,l=!0,s=!1){return Se(tt(n,o,l,s),t)}function ye(t,n=!0,o){nt()?e.onMounted(t,o):n?t():e.nextTick(t)}function X(t){var n;const o=V(t);return(n=o?.$el)!=null?n:o}const oe=Ce?window:void 0,ot=Ce?window.document:void 0;function le(...t){let n,o,l,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([o,l,s]=t,n=oe):[n,o,l,s]=t,!n)return q;Array.isArray(o)||(o=[o]),Array.isArray(l)||(l=[l]);const a=[],r=()=>{a.forEach(g=>g()),a.length=0},d=(g,u,m,M)=>(g.addEventListener(u,m,M),()=>g.removeEventListener(u,m,M)),c=e.watch(()=>[X(n),V(s)],([g,u])=>{if(r(),!g)return;const m=Je(u)?{...u}:u;a.push(...o.flatMap(M=>l.map(i=>d(g,M,i,m))))},{immediate:!0,flush:"post"}),f=()=>{c(),r()};return he(f),f}function lt(){const t=e.ref(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function st(t){const n=lt();return e.computed(()=>(n.value,Boolean(t())))}function at(t){const n=e.getCurrentInstance(),o=Ge(()=>null,()=>t?X(t):n.proxy.$el);return e.onUpdated(o.trigger),e.onMounted(o.trigger),o}function De(t,n,o={}){const{window:l=oe,...s}=o;let a;const r=st(()=>l&&"ResizeObserver"in l),d=()=>{a&&(a.disconnect(),a=void 0)},c=e.computed(()=>Array.isArray(t)?t.map(u=>X(u)):[X(t)]),f=e.watch(c,u=>{if(d(),r.value&&l){a=new ResizeObserver(n);for(const m of u)m&&a.observe(m,s)}},{immediate:!0,flush:"post"}),g=()=>{d(),f()};return he(g),{isSupported:r,stop:g}}function it(t,n={width:0,height:0},o={}){const{window:l=oe,box:s="content-box"}=o,a=e.computed(()=>{var u,m;return(m=(u=X(t))==null?void 0:u.namespaceURI)==null?void 0:m.includes("svg")}),r=e.ref(n.width),d=e.ref(n.height),{stop:c}=De(t,([u])=>{const m=s==="border-box"?u.borderBoxSize:s==="content-box"?u.contentBoxSize:u.devicePixelContentBoxSize;if(l&&a.value){const M=X(t);if(M){const i=l.getComputedStyle(M);r.value=Number.parseFloat(i.width),d.value=Number.parseFloat(i.height)}}else if(m){const M=Array.isArray(m)?m:[m];r.value=M.reduce((i,{inlineSize:D})=>i+D,0),d.value=M.reduce((i,{blockSize:D})=>i+D,0)}else r.value=u.contentRect.width,d.value=u.contentRect.height},o);ye(()=>{const u=X(t);u&&(r.value="offsetWidth"in u?u.offsetWidth:n.width,d.value="offsetHeight"in u?u.offsetHeight:n.height)});const f=e.watch(()=>X(t),u=>{r.value=u?n.width:0,d.value=u?n.height:0});function g(){c(),f()}return{width:r,height:d,stop:g}}const xe=1;function rt(t,n={}){const{throttle:o=0,idle:l=200,onStop:s=q,onScroll:a=q,offset:r={left:0,right:0,top:0,bottom:0},eventListenerOptions:d={capture:!1,passive:!0},behavior:c="auto",window:f=oe,onError:g=T=>{console.error(T)}}=n,u=e.ref(0),m=e.ref(0),M=e.computed({get(){return u.value},set(T){D(T,void 0)}}),i=e.computed({get(){return m.value},set(T){D(void 0,T)}});function D(T,A){var b,$,y;if(!f)return;const w=V(t);!w||(y=w instanceof Document?f.document.body:w)==null||y.scrollTo({top:(b=V(A))!=null?b:i.value,left:($=V(T))!=null?$:M.value,behavior:V(c)})}const p=e.ref(!1),h=e.reactive({left:!0,right:!1,top:!0,bottom:!1}),N=e.reactive({left:!1,right:!1,top:!1,bottom:!1}),E=T=>{!p.value||(p.value=!1,N.left=!1,N.right=!1,N.top=!1,N.bottom=!1,s(T))},j=ne(E,o+l),Q=T=>{var A;if(!f)return;const b=((A=T?.document)==null?void 0:A.documentElement)||T?.documentElement||X(T),{display:$,flexDirection:y}=getComputedStyle(b),w=b.scrollLeft;N.left=w<u.value,N.right=w>u.value;const C=Math.abs(w)<=(r.left||0),k=Math.abs(w)+b.clientWidth>=b.scrollWidth-(r.right||0)-xe;$==="flex"&&y==="row-reverse"?(h.left=k,h.right=C):(h.left=C,h.right=k),u.value=w;let _=b.scrollTop;T===f.document&&!_&&(_=f.document.body.scrollTop),N.top=_<m.value,N.bottom=_>m.value;const I=Math.abs(_)<=(r.top||0),z=Math.abs(_)+b.clientHeight>=b.scrollHeight-(r.bottom||0)-xe;$==="flex"&&y==="column-reverse"?(h.top=z,h.bottom=I):(h.top=I,h.bottom=z),m.value=_},S=T=>{var A;if(!f)return;const b=(A=T.target.documentElement)!=null?A:T.target;Q(b),p.value=!0,j(T),a(T)};return le(t,"scroll",o?pe(S,o,!0,!1):S,d),ye(()=>{try{const T=V(t);if(!T)return;Q(T)}catch(T){g(T)}}),le(t,"scrollend",E,d),{x:M,y:i,isScrolling:p,arrivedState:h,directions:N,measure(){const T=V(t);f&&T&&Q(T)}}}let ct=0;function Te(t,n={}){const o=e.ref(!1),{document:l=ot,immediate:s=!0,manual:a=!1,id:r=`vueuse_styletag_${++ct}`}=n,d=e.ref(t);let c=()=>{};const f=()=>{if(!l)return;const u=l.getElementById(r)||l.createElement("style");u.isConnected||(u.id=r,n.media&&(u.media=n.media),l.head.appendChild(u)),!o.value&&(c=e.watch(d,m=>{u.textContent=m},{immediate:!0}),o.value=!0)},g=()=>{!l||!o.value||(c(),l.head.removeChild(l.getElementById(r)),o.value=!1)};return s&&!a&&ye(f),a||he(g),{id:r,css:d,unload:g,load:f,isLoaded:e.readonly(o)}}function ut(t,n,o){const l=t.style[n];return l!=o&&(t.style[n]=o),{reset(){l!=o&&(t.style[n]=l)}}}function _e(t,n){const{scrollEndHook:o,itemHeight:l,overscan:s=5}=n,a=e.ref(null),r=it(a),d=e.ref(!0),c=ne(Q,100);let f;const g=e.shallowRef(t),u=e.ref(0),m=e.ref({start:0,end:10}),M=e.ref({start:0,end:s});let i=0;const D=e.ref([]),p=e.computed(()=>{let{sum:I,height:z}={sum:0,height:0};return g.value.map((B,Y)=>(typeof l=="number"?z=l:z=l(Y),I+=z,{height:z,sum:I}))}),h=e.computed(()=>$(m.value.start)),N=e.computed(()=>typeof l=="number"?p.value.length*l:p.value[p.value.length-1]?.sum||0),E=e.computed(()=>{const{start:I,end:z}=M.value;return D.value.slice(I,z)});e.onMounted(()=>{}),e.onUnmounted(()=>cancelAnimationFrame(f)),e.watch(g,()=>{(r.width.value||r.height.value)&&S()},{deep:!0}),e.watch([r.width,r.height],([I,z])=>{(I||z)&&S()},{deep:!0}),e.watch(u,()=>{j(),c()});function j(){d.value=!1}function Q(){d.value=!0,o?.()}function S(){cancelAnimationFrame(f),f=requestAnimationFrame(T)}function T(){if(a.value){u.value=a.value.scrollTop;let I=A(u.value);i=b(I);let z=Math.max(0,I-s),B=Math.min(I+i+s,g.value.length);m.value={start:z,end:B},D.value=g.value.slice(z,B).map((Y,O)=>({data:Y,index:O+z})),M.value.start=I-z,M.value.end=M.value.start+i}}function A(I){let z=0,B=p.value.length-1,Y=-1;for(;z<=B;){const O=Math.floor((z+B)/2);p.value[O].sum>=I?(Y=O,B=O-1):z=O+1}return Math.max(0,Y)}function b(I){let z=0,B=0;for(let Y=I;Y<p.value.length&&(z++,B+=p.value[Y].height,!(B>=r.height.value));Y++);return z}function $(I){if(typeof l=="number")return I*l;let z=p.value[I];return z?z.sum-z.height:0}function y(I){return p.value[I]||{sum:0,height:0}}function w(I,z="smooth"){if(a.value){const{reset:B}=ut(a.value,"scrollBehavior",z),Y=y(I);a.value.scrollTop=Y.sum-Y.height,T(),B()}if(a.value){const B=y(I);a.value.scrollTop=B.sum-B.height,T()}}const C=e.computed(()=>({style:{width:"100%",height:`${N.value}px`,pointerEvents:d.value?void 0:"none"}})),k=e.computed(()=>({style:{transform:`translate3d(0, ${h.value}px, 0)`,"will-change":"transform"}})),_={overflowY:"auto"};return{list:D,visiableList:E,getItemHeightData:y,getoffsetTopIndex:A,totalHeight:N,clientHeight:r.height,scrollTo:w,scrollTop:u,isScrollEnd:d,containerProps:{ref:a,onScroll:()=>{S()},style:_},wrapperProps:C,innerProps:k}}const Ne=Symbol(),se=Symbol(),ae=Symbol(),ie=Symbol(),re=Symbol(),ce=Symbol(),ue=Symbol(),de=Symbol(),fe=Symbol(),J=Symbol(),Me=Symbol();function dt(){const{voidFn:t,boolFn:n,boolRef:o,numberRef:l,arrayRef:s}={voidFn:p=>{},boolFn:p=>!1,boolRef:e.computed(()=>!1),numberRef:e.computed(()=>0),arrayRef:e.computed(()=>[])},a=e.inject(Ne,"id"),r=e.inject(re,s),d=e.inject(ie,n),c=e.inject(fe,o),f=e.inject(ae,t),g=e.inject(se,t),u=e.inject(ce,t),m=e.inject(ue,t),M=e.inject(de,t),i=e.inject(J,t),D=e.inject(Me,l);return{itemKey:a,selected:r,isSelected:d,isAllSelected:c,toggle:f,toggleAll:g,select:u,selectAll:m,unselect:M,unselectAll:i,selectedCount:D}}function ft(t,n,o={deep:!0}){const l=e.ref(!1),s=e.ref(new Set),a=e.ref(new Map);e.watch(t,h=>{a.value=h.reduce((N,E)=>(N.set(E[n],E),N),new Map)},{deep:o.deep,immediate:!0});const r=e.computed(()=>{let h=[];if(l.value!=null)l.value&&(h=Array.from(a.value.values()));else if(s.value.size){let N;s.value.forEach(E=>{N=a.value.get(E),N&&h.push(N)})}return h}),d=e.computed(()=>{let h=0;return l.value!=null?l.value&&(h=a.value.size):h=s.value.size,h}),c=e.computed(()=>{let h;if(l.value!=null)h=l.value;else{const N=s.value.size,E=a.value.size;h=N==E}return h});function f(){l.value=!0}function g(){l.value=!1}function u(h){i(()=>{h.forEach(N=>{s.value.add(N[n])})})}function m(h){i(()=>{h.forEach(N=>{s.value.delete(N[n])})})}function M(h){return l.value!=null?l.value:s.value.has(h[n])}function i(h){l.value!=null&&(l.value?s.value=new Set(Array.from(a.value.keys())):s.value=new Set),h(),s.value.size==0?l.value=!1:s.value.size==a.value.size?l.value=!0:l.value=null}function D(h){i(()=>{h.forEach(N=>{M(N)?s.value.delete(N[n]):s.value.add(N[n])})})}function p(){const{value:h}=c;h?g():f()}return e.provide(Ne,n),e.provide(se,p),e.provide(ae,D),e.provide(ie,M),e.provide(re,r),e.provide(ce,u),e.provide(ue,f),e.provide(de,m),e.provide(fe,c),e.provide(J,g),e.provide(J,g),e.provide(Me,d),{selected:r,select:u,selectAll:f,unselect:m,unselectAll:g,toggle:D,toggleAll:p,isSelected:M,isAllSelected:c,selectedCount:d}}function Mt(t){const n=e.ref(!1),o=e.ref(new Set),l=e.computed(()=>{let i=[];return n.value!=null?n.value&&(i=t.value):o.value.size&&(i=Array.from(o.value.values())),i}),s=e.computed(()=>{let i=0;return n.value!=null?n.value&&(i=t.value.length):i=o.value.size,i}),a=e.computed(()=>{let i;if(n.value!=null)i=n.value;else{const D=o.value.size,p=t.value.length;i=D==p}return i});function r(){n.value=!0}function d(){n.value=!1}function c(i){u(()=>{i.forEach(D=>{o.value.add(D)})})}function f(i){u(()=>{i.forEach(D=>{o.value.delete(D)})})}function g(i){return n.value!=null?n.value:o.value.has(i)}function u(i){n.value!=null&&(n.value?o.value=new Set(Array.from(t.value)):o.value=new Set),i(),o.value.size==0?n.value=!1:o.value.size==t.value.length?n.value=!0:n.value=null}function m(i){u(()=>{i.forEach(D=>{g(D)?o.value.delete(D):o.value.add(D)})})}function M(){const{value:i}=a;i?d():r()}return e.provide(se,M),e.provide(ae,m),e.provide(ie,g),e.provide(re,l),e.provide(ce,c),e.provide(ue,r),e.provide(de,f),e.provide(fe,a),e.provide(J,d),e.provide(J,d),e.provide(Me,s),{selected:l,select:c,selectAll:r,unselect:f,unselectAll:d,toggle:m,toggleAll:M,isSelected:g,isAllSelected:a,selectedCount:s}}function we(t){return()=>{console.debug(`\u9ED8\u8BA4${t}\u65B9\u6CD5,\u9700\u8981\u81EA\u5B9A\u4E49\u751F\u6548`)}}function ve({attribute:t,selectWay:n="colum",scrollOptions:o={},getSelectMap:l=()=>({})}){const{select:s=we("\u9009\u62E9"),unselect:a=we("\u53D6\u6D88\u9009\u62E9"),unselectAll:r=we("\u53D6\u6D88\u5168\u9009")}=l();let d={};const c=e.computed(()=>pe(n==="colum"?H:K,50)),f=new Set,g=e.ref(!0),u=e.ref(),m=e.ref(!1),M=e.ref({x:0,y:0}),i=e.ref({x:0,y:0,scrollTop:0}),D=new ResizeObserver(L=>p.value=L[0].target.getBoundingClientRect()),p=e.ref({}),h=e.ref({top:0,height:0,sync(L=!1){h.value.top=u.value?.scrollTop||0,L&&(h.value.height=u.value?.scrollHeight||0)}}),N=e.computed(()=>m.value?{left:Math.min(M.value.x,i.value.x)-p.value.left,top:Math.min(M.value.y,i.value.y)-p.value.top,width:Math.abs(M.value.x-i.value.x),height:Math.abs(M.value.y-i.value.y)}:{left:0,top:0,width:0,height:0}),{margin:E=50,startSpeed:j=30,maxSpeed:Q=30}=o;let S;const T=E,A=j,b=Q,$=L=>L**1;let y=0;function w(L){if(cancelAnimationFrame(S),y=C(L),y=Math.max(Math.min(y,b),-b),y!==0){const x=u.value;if(!x||!m.value)return;const P=h.value.height-p.value.height;let R=h.value.top+Number(y);R=Math.min(Math.max(0,R),P),x.scrollTop=R,_(),S=requestAnimationFrame(()=>w(L))}}function C(L){if(u.value){const P=p.value,R=P.bottom-L;if(R<T)return A*$(1-R/T);const G=L-P.top;if(G<T)return-A*$(1-G/T)}return 0}function k(L){const x={...N.value,right:0,bottom:0};return x.left+=p.value.left,x.top+=p.value.top-h.value.top,x.right=x.width+x.left,x.bottom=x.height+x.top,x.left<L.right&&x.right>L.left&&x.top<L.bottom&&x.bottom>L.top}function _(){h.value.sync();const{top:L,height:x}=h.value;i.value.y=Math.min(x+p.value.top,i.value.y+L-i.value.scrollTop),i.value.scrollTop=L}function I(L,x,P="dynamic-styles"){let R=document.getElementById(P);R||(R=document.createElement("style"),R.id=P,document.head.appendChild(R));const G=R.sheet.cssRules,ee=G.length,Un=`${L} { ${x} }`;for(let Le=0;Le<ee;Le++){const Xe=G[Le];if(Xe.selectorText===L&&Xe.style.cssText===x)return}R.sheet.insertRule(Un,ee)}function z(L,x){g.value=!0,m.value=!0,h.value.sync(!0);const P=x+h.value.top;M.value.x=L,M.value.y=P,i.value.x=L,i.value.y=P,u.value?.classList.add("disable-scroll-behavior"),f.clear()}function B(L,x,P){!m.value||(g.value&&n==="colum"&&!U()&&(r(),g.value=!1),P?.(),w(x),i.value.x=Math.max(L,p.value.left),i.value.y=Math.min(x+h.value.top,h.value.height+p.value.top),i.value.scrollTop=h.value.top,c.value())}function Y(){m.value=!1,u.value?.classList.remove("disable-scroll-behavior")}function O(){!m.value||(y||_(),c.value())}function U(){if(!m.value)return!1;const{width:L,height:x}=N.value;return!(Math.max(L,x)>5)}function F(){U()&&r()}function H(){U()||u.value?.querySelectorAll(`[${t}]`).forEach(L=>{d[`${t}`]=L.getAttribute(`${t}`),k(L.getBoundingClientRect())?s([d]):a([d])})}function K(){const L=[];let x=null,P=0;u.value?.querySelectorAll(`[${t}]`).forEach((R,G)=>{const ee=R.getAttribute(`${t}`);L.push(ee),k(R.getBoundingClientRect())?(x===null&&(x=G),x=Math.min(x,G),P=Math.max(P,G)):(d[`${t}`]=ee,f.has(ee)&&a([d]))});for(let R=x;R<P+1;R++)d[`${t}`]=L[R],s([d]),f.add(L[R])}function Yn(L){return!L?.value||(u.value=L.value,!u?.value)?!1:(D.observe(u.value),I(".disable-scroll-behavior","scroll-behavior: unset !important;"),!0)}return{init:Yn,dragStart:z,dragMove:B,dragEnd:Y,onScroll:O,isSingleClick:U,cancelSelectAllBySingleClick:F,selectFn:c,selectRange:N,isPressing:m,containerEl:u,observer:D}}function gt(t){const n=ve(t),{observer:o,selectRange:l}=n,{onScroll:s,dragStart:a,dragMove:r,dragEnd:d,cancelSelectAllBySingleClick:c}=n,f=e.computed(()=>({left:`${l.value.left}px`,top:`${l.value.top}px`,width:`${l.value.width}px`,height:`${l.value.height}px`})),{load:g}=Te(`.drag-select-box {
|
|
2
2
|
position: absolute;
|
|
3
3
|
z-index: 99999;
|
|
4
4
|
background-color: rgb(191 219 254);
|
|
5
5
|
opacity: 0.5;
|
|
6
|
-
}`,{id:"styletag_lzc_dragselect",manual:!0}),u=e.defineComponent({render(){return e.h("div",{id:"selectBoxEl",class:"drag-select-box",style:f.value})}});function m(h){h.button===0&&(a(h.x,h.y),window.addEventListener("mousemove",M),window.addEventListener("mouseup",i))}function M(h){r(h.x,h.y)}function i(h){window.removeEventListener("mousemove",M),window.removeEventListener("mouseup",i),h.composedPath().some(
|
|
6
|
+
}`,{id:"styletag_lzc_dragselect",manual:!0}),u=e.defineComponent({render(){return e.h("div",{id:"selectBoxEl",class:"drag-select-box",style:f.value})}});function m(h){h.button===0&&(a(h.x,h.y),window.addEventListener("mousemove",M),window.addEventListener("mouseup",i))}function M(h){r(h.x,h.y)}function i(h){window.removeEventListener("mousemove",M),window.removeEventListener("mouseup",i),h.composedPath().some(E=>E?.getAttribute?.(t.attribute))||c(),d()}function D(h){try{if(!n.init(h))throw"\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";if(!n.containerEl?.value)return!1;e.render(e.h(u),n.containerEl.value),g(),n.containerEl.value?.addEventListener("scroll",s),n.containerEl.value?.addEventListener("mousedown",m)}catch(N){console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25",N)}}function p(){o.disconnect(),n.containerEl.value?.removeEventListener("scroll",s),n.containerEl.value?.removeEventListener("mousedown",m)}return{init:D,unMount:p}}function mt(t,n,o=600){const l=ve({...t,selectWay:"row",scrollOptions:{startSpeed:5,maxSpeed:5}}),{observer:s}=l,{onScroll:a,dragStart:r,dragMove:d,dragEnd:c}=l;let f;function g(){clearTimeout(f)}function u(p){g(),p.composedPath().some(N=>!!N?.getAttribute?.(t.attribute))&&(f=setTimeout(()=>{const{clientX:N,clientY:E}=p.targetTouches[0];r(N,E),n?.(),d(N,E,()=>p.preventDefault()),p.preventDefault()},o))}function m(p){g();const{clientX:h,clientY:N}=p.targetTouches[0];d(h,N,()=>p.preventDefault())}function M(){g(),c()}function i(p){try{if(!l.init(p))throw"\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";if(!l.containerEl?.value)return!1;l.containerEl.value?.addEventListener("scroll",a),l.containerEl.value?.addEventListener("touchstart",u),l.containerEl.value?.addEventListener("touchmove",m),window.addEventListener("touchcancel",M),window.addEventListener("touchend",M)}catch(h){console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25",h)}}function D(){s.disconnect(),l.containerEl.value?.removeEventListener("scroll",a),l.containerEl.value?.removeEventListener("touchstart",u),l.containerEl.value?.removeEventListener("touchmove",m),window.removeEventListener("touchcancel",M),window.removeEventListener("touchEnd",M)}return{init:i,unMount:D}}const Oe=Symbol(),ht=e.defineComponent({__name:"Dialog",props:{visiable:{type:Boolean,default:!1},closeOnClickOverlay:{type:Boolean,default:!0},hiddenOverlay:{type:Boolean},dialogClass:{default:""},modalClass:{default:""},onClickOverlay:null},emits:["update:visiable"],setup(t,{emit:n}){const o=t,l=()=>{o.onClickOverlay?.(),o.closeOnClickOverlay&&n("update:visiable",!1)};return e.provide(Oe,()=>n("update:visiable",!1)),(s,a)=>(e.openBlock(),e.createBlock(e.Transition,{name:"modal"},{default:e.withCtx(()=>[t.visiable?e.withDirectives((e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([t.hiddenOverlay?"no-overlay-modal":"lzc-modal",t.modalClass])},[e.createElementVNode("div",{onMousedown:a[0]||(a[0]=e.withModifiers(()=>{},["stop"])),class:e.normalizeClass(["lzc-dialog",t.dialogClass])},[e.renderSlot(s.$slots,"default",{},void 0,!0)],34)],2)),[[e.unref(je),()=>l()]]):e.createCommentVNode("",!0)]),_:3}))}}),Rn="",W=(t,n)=>{const o=t.__vccOpts||t;for(const[l,s]of n)o[l]=s;return o},pt=W(ht,[["__scopeId","data-v-3d61e60a"]]);function yt(t){function n(o,l){const s=document.createElement("div"),a={setup(){return()=>e.h(pt,{visiable:!0,"onUpdate:visiable":()=>{s?.remove()},...t},{default:()=>e.h(o,l)})}};return document.body.appendChild(s),e.render(e.h(a),s),{close:()=>s?.remove()}}return{create:n}}function Ee({component:t,componentProps:n,delay:o=300}){const s=`lzc-delay-loading-${`${new Date().getTime()}`}`,a=`${o}ms`;return Te(`@keyframes lzcDelayLoad {
|
|
7
7
|
to {
|
|
8
8
|
opacity: 1;
|
|
9
9
|
}
|
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
.${s} {
|
|
12
12
|
opacity: 0;
|
|
13
13
|
animation: lzcDelayLoad 0s ${a} forwards;
|
|
14
|
-
}`),{LoadingComp:e.defineComponent({setup(){const d=at();return e.onMounted(()=>{d.value?.classList?.add(s)}),()=>e.h(t,n)}})}}function Dt({component:t,componentProps:n,delay:o=300}){const{LoadingComp:l}=Ee({component:t,componentProps:n,delay:o}),s=e.ref(!1);function a(){s.value=!0}function r(){s.value=!1}return{LoadingComp:l,loading:s,load:a,unload:r}}const Tt=[(t=>(e.pushScopeId("data-v-92a1804d"),t=t(),e.popScopeId(),t))(()=>e.createElementVNode("div",{class:"ldio-mm5gwljcryb"},[e.createElementVNode("div")],-1))],Nt=e.defineComponent({__name:"DefaultLoading",props:{width:{default:24},height:{default:24}},setup(t){return e.useCssVars(n=>({"4e4a9ce4":t.width+"px",e56fe5c2:t.height+"px"})),(n,o)=>(e.openBlock(),e.createElementBlock("div",e.normalizeProps(e.guardReactiveProps(n.$attrs)),Tt,16))}}),Hn="",be=W(Nt,[["__scopeId","data-v-92a1804d"]]),wt="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAQAAAC0jZKKAAAAAnNCSVQICFXsRgQAAAABc1JHQgCuzhzpAAAEM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o+D1nV/+xyqc3Bt3O11JCMmb9nn/WH3s8C68Id0QV9CV9I/6P1jUg5x4Tgar6hLoQgX9nH69/dRiy+Eh3fhofMl7QSoE4qT6Z/0Hb2tuTjyFJ10gLlTSleKzPMXx7FL75OUSUCjm11TW6yMYRBfpAURwUZroxzs+rOuaRnb4C1Ks/ZoFCNUFAZTg4oFiQeiJi4gJlOJKasnf6T38v3ZspAsv2hYq6YFCqZXFEsyDhAguVK/FiuPxvZ0X79DnDW/nM94DodRu/G+wEOriAQIlqfjNP+n7dokGcnirPma93jJf73ALWF00xVE/3HdsGc605vk6Nydb0GN38y4UqV7BjE/ggv48NfZE3UH2F3Kp4Zn6aTweAAAAAElFTkSuQmCC",vt={class:"loading-wrap"},Et=["src"],It=e.defineComponent({__name:"PageLoading",props:{delay:{default:"0.15s"},size:{default:"mini"}},setup(t){const n=t;e.useCssVars(l=>({b1cf73a8:t.delay}));const o=e.computed(()=>{const l={};return n.size==="mini"?(l.width="22px",l.height="22px"):n.size==="large"&&(l.width="28px",l.height="28px"),l});return(l,s)=>(e.openBlock(),e.createElementBlock("div",vt,[e.createElementVNode("img",{class:"loading-circle",src:e.unref(wt),style:e.normalizeStyle(e.unref(o))},null,12,Et)]))}}),Fn="",zt=W(It,[["__scopeId","data-v-3c54972f"]]);async function Ie(t){return new Promise(n=>setTimeout(()=>n(),t))}const At="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTJweCIgaGVpZ2h0PSIxMnB4IiB2aWV3Qm94PSIwIDAgMTIgMTIiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KICAgIDxnIHN0cm9rZT0ibm9uZSIgc3Ryb2tlLXdpZHRoPSIxIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPgogICAgICAgIDxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0xMTAyLjAwMDAwMCwgLTQwNi4wMDAwMDApIiBmaWxs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ljg0NzkxMzI0IDguMjk2MTcyNDEsNi44NDc5MTMyNCBDOC42ODAyNzA3OSw2Ljg0NzkxMzI0IDkuMDQ4NjMzNTYsNy4wMDA1MTQxNCA5LjMyMDIwNjksNy4yNzIxMzc5MyBMMTQuNTg2OTY1NSwxMi41Mzg4OTY2IEMxNC44NTg1ODkzLDEyLjgxMDQ2OTkgMTUuMDExMTkwMiwxMy4xNzg4MzI3IDE1LjAxMTE5MDIsMTMuNTYyOTMxIEMxNS4wMTExOTAyLDEzLjk0NzAyOTQgMTQuODU4NTg5MywxNC4zMTUzOTIyIDE0LjU4Njk2NTUsMTQuNTg2OTY1NSBDMTQuMzE1MzkyMiwxNC44NTg1ODkzIDEzLjk0NzAyOTQsMTUuMDExMTkwMiAxMy41NjI5MzEsMTUuMDExMTkwMiBDMTMuMTc4ODMyNywxNS4wMTExOTAyIDEyLjgxMDQ2OTksMTQuODU4NTg5MyAxMi41Mzg4OTY2LDE0LjU4Njk2NTUgTDcuMjcyMTM3OTMsOS4zMjAyMDY5IEM3LjAwMDUxNDE0LDkuMDQ4NjMzNTYgNi44NDc5MTMyNCw4LjY4MDI3MDc5IDYuODQ3OTEzMjQsOC4yOTYxNzI0MSBDNi44NDc5MTMyNCw3LjkxMjA3NDA0IDcuMDAwNTE0MTQsNy41NDM3MTEyNyA3LjI3MjEzNzkzLDcuMjcyMTM3OTMgWiI+PC9wYXRoPgogICAgICAgICAgICA8L2c+CiAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+",jt=["onClick"],Ct=["onClick"],St=["src"],xt=["src"],_t=e.defineComponent({__name:"index",props:{visible:null,message:{default:""},duration:{default:2e3},width:{default:void 0},maxWidth:{default:void 0},showIcon:{type:Boolean,default:!1},icon:{default:void 0},showClose:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!1},closeOnClickOverlay:{type:Boolean,default:!1},className:{default:""},overlayContentStyle:{default:void 0},captureEventP:{type:Boolean,default:!0}},emits:["close"],setup(t,{emit:n}){const o=t,l="lzc-loading-toast",s=e.computed(()=>{let f={};return o.captureEventP&&(f.pointerEvents="none"),f}),a=e.computed(()=>{let f={padding:"12px"};return(o.icon||o.showIcon)&&(f.padding="20px"),o.width&&(f.width=o.width),o.maxWidth&&(f.maxWidth=o.maxWidth),o.overlayContentStyle&&(f={...f,...o.overlayContentStyle}),f}),r=e.computed(()=>{let f={};return o.showClose&&!o.icon&&(f.paddingRight="16px"),f});function d(){o.closeOnClickOverlay&&n("close")}function c(){o.closeOnClick&&n("close")}return(f,g)=>(e.openBlock(),e.createBlock(e.Transition,{"enter-active-class":"lzc-animate-fade-in lzc-animate-duration-300","leave-active-class":"lzc-animate-fade-out lzc-animate-duration-300"},{default:e.withCtx(()=>[e.createElementVNode("div",{id:l,style:e.normalizeStyle(e.unref(s))},[e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(`${l} ${t.className}`),onClick:e.withModifiers(d,["stop"])},[e.createElementVNode("div",{class:e.normalizeClass(`${l}-wrap`),onClick:e.withModifiers(c,["stop"])},[e.createElementVNode("div",{class:e.normalizeClass(`${l}-content`),style:e.normalizeStyle(e.unref(a))},[t.showClose?(e.openBlock(),e.createElementBlock("img",{key:0,onClick:g[0]||(g[0]=e.withModifiers(u=>n("close"),["stop"])),src:e.unref(At),class:e.normalizeClass(`${l}-close`)},null,10,St)):e.createCommentVNode("",!0),t.showIcon?(e.openBlock(),e.createElementBlock("img",{key:1,src:t.icon||e.unref(Lt),class:e.normalizeClass(`${l}-icon`)},null,10,xt)):e.createCommentVNode("",!0),t.message?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(`${l}-message`),style:e.normalizeStyle(e.unref(r))},e.toDisplayString(t.message),7)):e.createCommentVNode("",!0)],6)],10,Ct)],10,jt),[[e.vShow,t.visible]])],4)]),_:1}))}}),Vn="",Wn="",Ot=W(_t,[["__scopeId","data-v-0947d1e3"]]);class ke{loadingToast;el;options;visible=e.ref(!1);animateDuration=300;constructor(n){this.options={...n,visible:this.visible},this.options.duration==null&&(this.options.duration=60*10*1e3),this.el=document.createElement("div"),this.loadingToast=Ot}async show(){const n=this.options,l={...n,onClose:()=>{this.close(),n?.onClose?.()}},s=e.createVNode(this.loadingToast,l);e.render(s,this.el),document.body.insertBefore(this.el,document.body.firstChild),this.visible.value=!0,n.duration!==0&&setTimeout(()=>{this.destory()},n.duration),await Ie(n.duration+this.animateDuration)}async destory(){!this.visible.value||(this.visible.value=!1,await new Promise(n=>{setTimeout(()=>{if(!this.el){n();return}document.body.removeChild(this.el),n()},this.animateDuration-10)}))}close(){document.querySelector("#lzc-loading-toast")?.remove()}}function bt(t,n){const o=!!n?.debug,l=n?.printErrorLog!==!1,s=n?.loading!==!1,a=n?.autoClose!==!1,r=n?.delay!==void 0?n.delay:300,d=n?.hook!==void 0?n.hook:!0,c={...n,showIcon:n?.showIcon!==!1,captureEventP:n?.captureEventP===!0};o&&console.log("useDelayAsync - loading: %s autoClose: %s delay: %s loadingToastOptions: %o",s,a,r,c);const f=e.ref(!1);let g=null;const u=new ke(c);async function m(...i){if(o&&console.log(`useDelayAsync - handler - processing: ${f.value}`),!f.value){f.value=!0,g=setTimeout(()=>{o&&console.log("useDelayAsync - handler - setTimeout - loading: %s processing: %s",s,f.value),s&&(!f.value||u.show())},r);try{o&&console.time("useDelayAsync - handler-execute-time");const D=await t(...i);return o&&console.log("useDelayAsync - execute res: ",D),o&&console.timeEnd("useDelayAsync - handler-execute-time"),await M(a),await n?.onSuccess?.(D,[...i]),D}catch(D){o&&console.timeEnd("useDelayAsync - handler-execute-time"),l&&console.error(D),await M(a),await n?.onError?.(D,[...i])}}}async function M(i=!0){o&&console.log("useDelayAsync - close - closeLoading: ",i),f.value=!1,g&&clearTimeout(g),g=null,i&&await u.destory()}return d&&e.onBeforeUnmount(()=>{o&&console.log("useDelayAsync - onBeforeUnmount - close"),M()}),{processing:f,handler:m,close:M}}function kt(t,n){return t>n?"horizontal":n>t?"vertical":""}function Bt(){const t=e.ref(0),n=e.ref(0),o=e.ref(0),l=e.ref(0),s=e.ref(0),a=e.ref(0),r=e.ref(""),d=()=>r.value==="vertical",c=()=>r.value==="horizontal",f=()=>{o.value=0,l.value=0,s.value=0,a.value=0,r.value=""};function g(m,M){f(),t.value=m,n.value=M}function u(m,M){o.value=(m<0?0:m)-t.value,l.value=M-n.value,s.value=Math.abs(o.value),a.value=Math.abs(l.value);const i=10;(!r.value||s.value<i&&a.value<i)&&(r.value=kt(s.value,a.value))}return{move:u,start:g,reset:f,startX:t,startY:n,deltaX:o,deltaY:l,offsetX:s,offsetY:a,direction:r,isVertical:d,isHorizontal:c}}const Be=250,Qe=5,Qt=500;function Yt(t){const{isDouble:n=!0}=t;let o,l;function s(){o=Date.now()}async function a(r,d){const c=Date.now()-o;r<Qe&&d<Qe&&(c<Be?n?l?(clearTimeout(l),l=null,t.onDoubleTap?.()):l=setTimeout(async()=>{t.onTap?.(),l=null},Be):t.onTap?.():c>Qt&&t.onLongPress?.())}return{startTap:s,checkTap:a}}function Ut(t,n){const o=e.ref(!1);function l(){o.value||(o.value=!0,e.unref(t)?.addEventListener("transitionend",s))}function s(){e.unref(t)?.removeEventListener("transitionend",s),o.value=!1,n.onComplate?.()}return{transitioning:o,startTransition:l}}function Rt(t,n,o,l){var s=Math.min(o/t,l/n),a=t*s,r=n*s;return{width:Z(a),height:Z(r)}}function $t(t){return t<3?"444ms":t<6?"555ms":"666ms"}function ze(t,n,o){return Math.min(Math.max(t,n),o)}function Z(t,n=2){return parseFloat(t.toFixed(n))}function ge(t,n,o){return t=Z(t),n=Z(n),`translate3d(${t}px, ${n}px, 0) scale3d(${o},${o},${o})`}function Ye(t){return Math.sqrt((t[0].clientX-t[1].clientX)**2+(t[0].clientY-t[1].clientY)**2)}function Pt(t){return{x:(t[0].clientX+t[1].clientX)/2,y:(t[0].clientY+t[1].clientY)/2}}function Ue(t){const n=e.ref(!1),o=e.ref(1),l=e.ref(9),s=e.ref(),a=e.ref(),r=e.ref({width:0,height:0}),d=e.ref({width:0,height:0}),c=e.reactive({level:1,offsetX:0,offsetY:0,zooming:!1,preview:!0,lastCenter:{x:0,y:0}}),f=e.ref({}),g=Bt(),u=Ut(a,{onComplate(){c.preview||p()}}),m=Yt({onTap(){t.onTap?.()},onDoubleTap(){t.onDoubleTap?.()},onLongPress(){t.onLongPress?.()}});De(a,y=>M(y)),e.watch([s,a],([y,v])=>{i(y,v)},{immediate:!0});async function M(y){const[v]=y;v.contentRect.width==d.value.width&&v.contentRect.height==d.value.height||(await i(s.value),await p(c.level,!0))}async function i(y,v){await A(y,v),y&&b()}async function D(y){if(!c.preview)return;c.preview=!1,y=y??c.level;const v=a.value;if(!v)return;const{scrollTop:C,scrollLeft:k}=v,{width:_,height:I}=r.value,{scaleW:z,scaleH:B}=S(y),{top:Y,left:O}=T(z,B),U=O!=0?O:k*-1,F=Y!=0?Y:C*-1;v.scrollTop=0,v.scrollLeft=0;const{value:H}=f;H.width=`${_}px`,H.height=`${I}px`,H.maxHeight="none",H.transitionDuration="0s",H.transform=ge(U,F,y),f.value=H,await e.nextTick(),c.offsetX=U,c.offsetY=F,await Ie(20)}async function p(y,v){if(!v&&c.preview)return;c.preview=!0,y=y??c.level;const{value:C}=f,{scaleW:k,scaleH:_}=S(y),{left:I,top:z}=T(k,_);y===1&&(C.maxHeight="100%"),C.width=`${k}px`,C.height=`${_}px`,C.transitionDuration="0s",C.transform=ge(I,z,1),f.value=C,await e.nextTick();const B=a.value;if(!B)return;const{offsetX:Y,offsetY:O}=c;Y<0&&(B.scrollLeft=Math.abs(Y)),O<0&&(B.scrollTop=Math.abs(O))}async function h(y,v,C){if(n.value||(y=Z(y),y=ze(y,o.value-o.value*.5,l.value+l.value*.5),y==c.level))return;c.preview&&await D(),v||(v={x:g.startX.value,y:g.startY.value});const{value:k}=f,{width:_,height:I}=r.value,{scaleW:z,scaleH:B}=S(y),{top:Y,left:O}=T(z,B),U=y/c.level,F={left:Math.abs(_*y-d.value.width)*-1,top:Math.abs(I*y-d.value.height)*-1,right:O,bottom:Y};let H=O!=0?O:(c.offsetX-v.x)*U+v.x,K=Y!=0?Y:(c.offsetY-v.y)*U+v.y;H=Z(ze(H,F.left,F.right)),K=Z(ze(K,F.top,F.bottom)),k.width=`${_}px`,k.height=`${I}px`,k.transitionDuration=C?$t(y):"0s",k.transform=ge(H,K,y),c.offsetX=H,c.offsetY=K,c.level=y,f.value=k,await e.nextTick(),C&&u.startTransition(),t.onScale?.(y)}function N(){const y=c.level>1?1:Q();h(y,void 0,!0)}function w(y,v){if(!c.preview)return;const C=a.value;!C||C.scrollTo({left:c.offsetX-y,top:c.offsetY-v})}async function j(){c.level>=o.value&&c.level<=l.value?c.zooming&&await p():c.level<o.value?await h(o.value,void 0,!0):c.level>l.value&&await h(l.value,c.lastCenter,!0),c.zooming=!1}function Q(){const{width:y,height:v}=r.value,{width:C,height:k}=d.value,_=2.5;let I;return v==k?(I=C/y,I-1<.1&&(I=_)):I=Math.max(_,C/y,k/v),I}function S(y){const{width:v,height:C}=r.value;return{scaleW:Z(y*v),scaleH:Z(y*C)}}function T(y,v){const{width:C,height:k}=d.value,_=Math.max(0,(k-v)*.5),I=Math.max(0,(C-y)*.5);return{top:_,left:I}}async function A(y,v){if(y=y??s.value,v=v??a.value,!v)return;let C,{clientWidth:k=0,clientHeight:_=0}=y||{};const{clientWidth:I,clientHeight:z}=v;if(y instanceof HTMLImageElement?C={width:y.naturalWidth,height:y.naturalHeight}:y instanceof HTMLVideoElement&&(C={width:y.videoWidth,height:y.videoHeight}),C){const B=Rt(C.width,C.height,I,z);k=B.width,_=B.height}(k===0||_===0)&&(k=r.value.width||I,_=r.value.height||z),r.value={width:Math.min(k,I),height:Math.min(_,z)},d.value={width:I,height:z},p(void 0,!0)}function b(){const y=Q();l.value=Math.max(l.value,y*2)}function $(y){n.value=y}return{touch:g,state:c,style:f,gesture:m,transition:u,imageRef:s,containerRef:a,switchToZoom:D,switchToPreview:p,panTo:w,zoomTo:h,zoomFinished:j,toggleZoom:N,setDisableZoom:$}}function Re(t,n){const{state:o,touch:l,transition:s,containerRef:a}=t,r=rt(a);let d,c;function f(m){d=m}function g(m){return d==m}function u(m,M,i,D){r.measure();const{top:p,left:h,right:N,bottom:w}=r.arrivedState;if(m=="start")c=p||h||N||w;else if(d==2)c=!1;else if(c){if(l.direction.value=="vertical")if(o.level!=1)c=!1;else{const j=l.startY.value<i;c=p&&j||w&&!j}else if(l.direction.value=="horizontal"){const j=l.startX.value<M;c=h&&j||N&&!j}}c&&s.transitioning.value&&(c=!1,D?.preventDefault()),m=="end"&&!c&&(M=l.startX.value,i=l.startY.value,c=!0),(m!="move"||c)&&n?.(m,l.direction.value,M,i,D)}return{onSwipeEdge:u,setFingerNum:f,isEqualFingerNum:g}}function Ht(t){const n=Ue({onDoubleTap(){n.toggleZoom()},...t}),{state:o,touch:l,gesture:s,transition:a}=n;let r=!1,d=null;const c={top:0,left:0},f=ne(p,150),{onSwipeEdge:g}=Re(n,t.onSwipeEdge),u=e.ref({top:0,left:0});le("keyup",N),le("keydown",h);function m(w){const j=w.target,{left:Q,top:S}=j.getBoundingClientRect();u.value.left=Q,u.value.top=S,s.startTap();let T=w.clientX-Q,A=w.clientY-S;l.start(T,A),g("start",T,A,w),a.transitioning.value||(r=!0,c.left=Q,c.top=S,o.offsetX=j.scrollLeft,o.offsetY=j.scrollTop),window.addEventListener("pointermove",M),window.addEventListener("pointerup",i)}function M(w){if(!r)return;let j=w.clientX,Q=w.clientY;l.move(j,Q),g("move",j-u.value.left,Q-u.value.top,w),o.level!==1&&n.panTo(l.deltaX.value-c.left,l.deltaY.value-c.top)}function i(w){g("end",l.offsetX.value,l.offsetY.value,w),s.checkTap(l.offsetX.value,l.offsetY.value),l.reset(),r=!1,window.removeEventListener("pointermove",M),window.removeEventListener("pointerup",i)}function D(w){if(!w.ctrlKey)return;o.zooming||(o.zooming=!0,d=="Control"&&window.addEventListener("keyup",p)),w.preventDefault();let j=-w.deltaY;w.deltaMode===1?j*=.05:j*=w.deltaMode?1:.002,d!="Control"&&(j*=10),j=2**j;const Q=o.level*j;o.lastCenter={x:w.offsetX,y:w.offsetY},n.zoomTo(Q,o.lastCenter),d!="Control"&&f()}function p(){n.zoomFinished(),window.removeEventListener("keyup",p)}function h(w){d=w.key}function N(){d=null}return{core:n,onPointerDown:m,onWheel:D}}function Ft(t){const n=Ue({onDoubleTap(){n.toggleZoom()},...t}),{state:o,touch:l,gesture:s}=n,{setFingerNum:a,onSwipeEdge:r,isEqualFingerNum:d}=Re(n,t.onSwipeEdge);let c,f;async function g(M){const{touches:i}=M;a(i.length),o.zooming=d(2),s.startTap();const{clientX:D,clientY:p}=i[0];l.start(D,p),r("start",D,p,M),o.zooming&&(M.preventDefault(),c=o.level,f=Ye(i),await n.switchToZoom(),o.lastCenter=Pt(i))}async function u(M){const{touches:i}=M;a(i.length);const{clientX:D,clientY:p}=i[0];if(l.move(D,p),r("move",D,p,M),o.zooming&&d(2)){M.preventDefault();const h=Ye(i),N=c*h/f;n.zoomTo(N,o.lastCenter)}}async function m(M){if(M.touches.length)return;const{clientX:i,clientY:D}=M.changedTouches[0];r("end",i,D,M),s.checkTap(l.offsetX.value,l.offsetY.value),n.zoomFinished(),l.reset()}return{core:n,onTouchStart:g,onTouchMove:u,onTouchEnd:m}}function Vt(){const t=e.reactive({scale:1,startX:0,startY:0,offsetX:0,offsetY:0,dragging:!1,started:!1});function n(s,a){t.startX=s,t.startY=a,t.scale=1}function o(s,a){t.started=!0,t.dragging=!0,t.offsetX=s-t.startX,t.offsetY=a-t.startY,t.scale=1-Math.abs(t.offsetY/a*.4)}function l(){!t.dragging||(Math.abs(t.offsetY)>window.innerHeight*.14?t.scale=.3:t.scale=1,t.dragging=!1,t.offsetX=0,t.offsetY=0)}return{state:t,dragStart:n,dragMove:o,dragEnd:l}}function $e(){const t=e.ref(!1),n=e.ref(!1);return e.onActivated(()=>{!n.value||(t.value=!0)}),e.onMounted(()=>{n.value=!1,setTimeout(()=>{n.value=!0})}),{isActivated:t}}function Pe(t){let n=!1;return()=>{n||(t(),n=!0)}}function Wt(t){let n=null;const{isActivated:o}=$e(),l=Pe(()=>n=window.onBackPress);function s(){l(),window.onBackPress=()=>t()}function a(){window.onBackPress=n}return e.onActivated(()=>{!o.value||s()}),e.onBeforeMount(()=>{s()}),e.onBeforeUnmount(()=>{a()}),e.onDeactivated(()=>{a()}),{register:s,unregister:a}}const Xt=["onClick"],Zt=e.defineComponent({__name:"Toast",props:{message:null,position:null,buttonClickEvent:null},setup(t){const n=t,o=e.ref(),l=e.ref(),s=e.ref(),a=e.computed(()=>{switch(n.position){case"top":return 10;case"middle":return 50;case"bottom":return 85}}),r=e.computed(()=>({position:"absolute",borderRadius:"10px",backgroundColor:"rgba(0, 0, 0, 0.8)",padding:"14px 19px",top:`calc(${a.value}% - ${s.value}px)`,left:`calc(50% - ${l.value}px)`})),d=e.computed(()=>({width:"fit-content",display:"flex",justifyContent:"center",alignItems:"center",color:"white",fontSize:"14px"}));function c(){!n.buttonClickEvent||n.buttonClickEvent()}return e.nextTick(()=>{l.value=o.value.offsetWidth/2,s.value=o.value.offsetHeight/2}),(f,g)=>(e.openBlock(),e.createElementBlock("div",{onClick:e.withModifiers(c,["stop"]),id:"toastWrapper",ref_key:"toastWrapper",ref:o,class:"toastWrapper",style:e.normalizeStyle([e.unref(r),{zIndex:9999999}])},[e.createElementVNode("div",{style:e.normalizeStyle(e.unref(d))},[e.createElementVNode("span",null,e.toDisplayString(t.message),1)],4)],12,Xt))}}),Xn="",Kt=W(Zt,[["__scopeId","data-v-25d39b90"]]),He={message:"\u61D2\u732B\u4E91 Yes!!!",position:"middle",duration:1500,buttonClickEvent:()=>{}};class Gt{options;container;constructor(n){this.options=n,this.container=document.createElement("div")}present(){const n=e.h(e.h(Kt),{...He,...this.options});e.render(n,this.container),document.body.insertBefore(this.container,document.body.firstChild);const o=this.options.duration||He.duration;setTimeout(()=>{this.dismiss()},o)}dismiss(){if(this.container){const n=this.container.querySelector("#toastWrapper");n.style.opacity="0",n.style.transition="opacity 0.4s ease-in",setTimeout(()=>{this.container&&(e.render(null,this.container),document.body.removeChild(this.container))},500)}}}const qt=["xlink:href","fill","color"],te=e.defineComponent({__name:"SvgIcon",props:{name:null,prefix:{default:"icon"},color:{default:"#FFF"},width:null,height:null},setup(t){const n=t,o=e.computed(()=>`#${n.prefix}-${n.name}`),l=e.computed(()=>({width:`${n.width??n.height}px`,height:`${n.height??n.width}px`,aspectRatio:n.width&&n.height?void 0:"1/1"}));function s(a){const{style:r}=a;return typeof r=="object"?r:{}}return(a,r)=>(e.openBlock(),e.createElementBlock("svg",{"aria-hidden":"",style:e.normalizeStyle({...e.unref(l),...s(a.$attrs)})},[e.createElementVNode("use",{"xlink:href":e.unref(o),fill:t.color,color:t.color},null,8,qt)],4))}});function Jt(t){const{containerEl:n,sliderEl:o,autoHeight:l,performance:s={},maxHeightRatio:a=.9,observeMethod:r="classList"}=t,d=e.ref(!0),c=ne($,100);let f,g="";const u=e.ref(0),m=e.ref(0),M=e.ref(0),i=e.ref({top:0,scrollTop:0,scrollHeight:0,clientHeight:0}),D=e.ref({clientHeight:0}),p=e.computed(()=>!!m.value),h=e.computed(()=>i.value.scrollHeight>i.value.clientHeight),N=e.computed(()=>l?i.value.clientHeight-Q.value:i.value.clientHeight-D.value.clientHeight),w=e.computed(()=>i.value.scrollHeight-i.value.clientHeight),j=e.computed(()=>!i.value.clientHeight&&!i.value.scrollHeight?1:Math.max(i.value.clientHeight/i.value.scrollHeight,.05)),Q=e.computed(()=>j.value>a?0:j.value*i.value.clientHeight),S=e.computed(()=>({willChange:"transform",transform:`translate3d(0,${M.value}px,0)`,height:l?`${Q.value}px`:void 0}));De(n,()=>z());function T(O){b(),m.value=O.clientY-o.value.getBoundingClientRect().top||1,g=getComputedStyle(n.value).scrollBehavior,g==="smooth"&&(n.value.style.scrollBehavior="unset")}function A(){n.value.style.scrollBehavior=g,m.value=0,c()}function b(){d.value=!1}function $(){p.value||(d.value=!0)}function y(O){if(!p.value)return;let U=O.clientY-i.value.top-m.value;U<0?M.value=0:U>=N.value?M.value=N.value:M.value=U,n.value.scrollTo({top:M.value/N.value*w.value})}function v(){p.value||C()}function C(){cancelAnimationFrame(f),f=requestAnimationFrame(k)}function k(){n.value&&(u.value=s.scrollTop?.value??n.value.scrollTop,M.value=u.value/w.value*N.value)}function _(O){let U="addEventListener";O==="add"?U="addEventListener":U="removeEventListener",o.value?.[U]("pointerdown",T,{passive:!0}),window[U]("pointermove",y,{passive:!0}),window[U]("pointerup",A,{passive:!0})}const I=new MutationObserver(O=>{(r=="classList"||O.map(F=>F.oldValue).join().includes("height"))&&z()});function z(){i.value.top=n.value?.getBoundingClientRect().top??0;const{scrollHeight:O=0,clientHeight:U=0}=n.value||{},{scrollHeight:F,clientHeight:H}=i.value;O!=F&&(i.value.scrollHeight=O,k()),U!=H&&(i.value.clientHeight=U,k());const{clientHeight:K=0}=o.value||{};K!=D.value.clientHeight&&(D.value.clientHeight=K)}function B(){b(),setTimeout(()=>{D.value.clientHeight=o.value?.clientHeight??0,$()},150)}function Y(){if(n.value&&o.value){n.value.classList.add("hide-scrollbar"),n.value.addEventListener("scroll",v,{passive:!0}),_("add");const O={};r==="classList"?Object.assign(O,{subtree:!0,childList:!0}):Object.assign(O,{subtree:!0,attributeOldValue:!0,attributeFilter:["style"]}),I.observe(n.value,O),setTimeout(()=>{z()},100),B()}else console.error("useScrollBar:","\u521D\u59CB\u5316\u5931\u8D25!",{containerEl:n,sliderEl:o})}return e.watch(u,()=>{b(),c()}),{isScrollEnd:d,isDragSlider:p,offsetTop:M,scrollTop:u,scrollable:h,sliderPos:S,init:Y,modifySliderEventListener:_,heightRatio:j}}const en=(t=>(e.pushScopeId("data-v-7fd39e51"),t=t(),e.popScopeId(),t))(()=>e.createElementVNode("div",{class:"default-slider"},null,-1)),tn=e.defineComponent({__name:"ScrollBar",props:{containerEl:null,autoHide:{type:Boolean},autoHeight:{type:Boolean},observeMethod:null,performance:null,maxHeightRatio:{default:.9}},setup(t,{expose:n}){const o=t,l=!!e.useSlots().default,s=e.ref(null),a=e.computed(()=>o.containerEl),r=Jt({containerEl:a,sliderEl:s,autoHeight:l?o.autoHeight:!0,performance:o.performance,observeMethod:o.observeMethod}),{scrollable:d,isScrollEnd:c,sliderPos:f,heightRatio:g}=r,u=e.ref(!1),m=o.autoHide?e.computed(()=>o.maxHeightRatio<g.value?!1:u.value||!c.value):e.computed(()=>o.maxHeightRatio<g.value?!1:d.value),{load:M}=Te(`.hide-scrollbar {
|
|
14
|
+
}`),{LoadingComp:e.defineComponent({setup(){const d=at();return e.onMounted(()=>{d.value?.classList?.add(s)}),()=>e.h(t,n)}})}}function Dt({component:t,componentProps:n,delay:o=300}){const{LoadingComp:l}=Ee({component:t,componentProps:n,delay:o}),s=e.ref(!1);function a(){s.value=!0}function r(){s.value=!1}return{LoadingComp:l,loading:s,load:a,unload:r}}const Tt=[(t=>(e.pushScopeId("data-v-92a1804d"),t=t(),e.popScopeId(),t))(()=>e.createElementVNode("div",{class:"ldio-mm5gwljcryb"},[e.createElementVNode("div")],-1))],Nt=e.defineComponent({__name:"DefaultLoading",props:{width:{default:24},height:{default:24}},setup(t){return e.useCssVars(n=>({"4e4a9ce4":t.width+"px",e56fe5c2:t.height+"px"})),(n,o)=>(e.openBlock(),e.createElementBlock("div",e.normalizeProps(e.guardReactiveProps(n.$attrs)),Tt,16))}}),Hn="",be=W(Nt,[["__scopeId","data-v-92a1804d"]]),wt="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAQAAAC0jZKKAAAAAnNCSVQICFXsRgQAAAABc1JHQgCuzhzpAAAEMklEQVRIx62XzW9VZRDGn2fmPff23qYtlvIRqVVQICgGoS21wYUGEA0x0YUYE/8BNTHujBsNiS5cGBeujAtXLiTGjUnFjRKNQWgJVoqxC/m2RMpX7cf9OOedcXFrg1qutPc+ZzM5b84vc+bNZOYh6sp5tKWQr2qmBZ/Biqxq03Eybsh6I63+l7z90Wirts0Vo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Tg4oFiQeiJi4gJlOJKasnf6T38v3ZspAsv2hYq6YFCqZXFEsyDhAguVK/FiuPxvZ0X79DnDW/nM94DodRu/G+wEOriAQIlqfjNP+n7dokGcnirPma93jJf73ALWF00xVE/3HdsGc605vk6Nydb0GN38y4UqV7BjE/ggv48NfZE3UH2F3Kp4Zn6aTweAAAAAElFTkSuQmCC",vt={class:"loading-wrap"},Et=["src"],It=e.defineComponent({__name:"PageLoading",props:{delay:{default:"0.15s"},size:{default:"mini"}},setup(t){const n=t;e.useCssVars(l=>({b1cf73a8:t.delay}));const o=e.computed(()=>{const l={};return n.size==="mini"?(l.width="22px",l.height="22px"):n.size==="large"&&(l.width="28px",l.height="28px"),l});return(l,s)=>(e.openBlock(),e.createElementBlock("div",vt,[e.createElementVNode("img",{class:"loading-circle",src:e.unref(wt),style:e.normalizeStyle(e.unref(o))},null,12,Et)]))}}),Fn="",zt=W(It,[["__scopeId","data-v-3c54972f"]]);async function Ie(t){return new Promise(n=>setTimeout(()=>n(),t))}const At="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTJweCIgaGVpZ2h0PSIxMnB4IiB2aWV3Qm94PSIwIDAgMTIgMTIiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KICAgIDxnIHN0cm9rZT0ibm9uZSIgc3Ryb2tlLXdpZHRoPSIxIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPgogICAgICAgIDxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0xMTAyLjAwMDAwMCwgLTQwNi4wMDAwMDApIiBmaWxsPSIjOTk5OTk5IiBmaWxsLXJ1bGU9Im5vbnplcm8iPgogICAgICAgIDxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDc5MC4wMDAwMDAsIDM5MC4wMDAwMDApIj4KICAgICAgICAgICAgPGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMzEyLjAwMDAwMCwgMTY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gxMDQ2OTkgMTUuMDExMTkwMiwxMy4xNzg4MzI3IDE1LjAxMTE5MDIsMTMuNTYyOTMxIEMxNS4wMTExOTAyLDEzLjk0NzAyOTQgMTQuODU4NTg5MywxNC4zMTUzOTIyIDE0LjU4Njk2NTUsMTQuNTg2OTY1NSBDMTQuMzE1MzkyMiwxNC44NTg1ODkzIDEzLjk0NzAyOTQsMTUuMDExMTkwMiAxMy41NjI5MzEsMTUuMDExMTkwMiBDMTMuMTc4ODMyNywxNS4wMTExOTAyIDEyLjgxMDQ2OTksMTQuODU4NTg5MyAxMi41Mzg4OTY2LDE0LjU4Njk2NTUgTDcuMjcyMTM3OTMsOS4zMjAyMDY5IEM3LjAwMDUxNDE0LDkuMDQ4NjMzNTYgNi44NDc5MTMyNCw4LjY4MDI3MDc5IDYuODQ3OTEzMjQsOC4yOTYxNzI0MSBDNi44NDc5MTMyNCw3LjkxMjA3NDA0IDcuMDAwNTE0MTQsNy41NDM3MTEyNyA3LjI3MjEzNzkzLDcuMjcyMTM3OTMgWiI+PC9wYXRoPgogICAgICAgICAgICA8L2c+CiAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+",jt=["onClick"],Ct=["onClick"],St=["src"],xt=["src"],_t=e.defineComponent({__name:"index",props:{visible:null,message:{default:""},duration:{default:2e3},width:{default:void 0},maxWidth:{default:void 0},showIcon:{type:Boolean,default:!1},icon:{default:void 0},showClose:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!1},closeOnClickOverlay:{type:Boolean,default:!1},className:{default:""},overlayContentStyle:{default:void 0},captureEventP:{type:Boolean,default:!0}},emits:["close"],setup(t,{emit:n}){const o=t,l="lzc-loading-toast",s=e.computed(()=>{let f={};return o.captureEventP&&(f.pointerEvents="none"),f}),a=e.computed(()=>{let f={padding:"12px"};return(o.icon||o.showIcon)&&(f.padding="20px"),o.width&&(f.width=o.width),o.maxWidth&&(f.maxWidth=o.maxWidth),o.overlayContentStyle&&(f={...f,...o.overlayContentStyle}),f}),r=e.computed(()=>{let f={};return o.showClose&&!o.icon&&(f.paddingRight="16px"),f});function d(){o.closeOnClickOverlay&&n("close")}function c(){o.closeOnClick&&n("close")}return(f,g)=>(e.openBlock(),e.createBlock(e.Transition,{"enter-active-class":"lzc-animate-fade-in lzc-animate-duration-300","leave-active-class":"lzc-animate-fade-out lzc-animate-duration-300"},{default:e.withCtx(()=>[e.createElementVNode("div",{id:l,style:e.normalizeStyle(e.unref(s))},[e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(`${l} ${t.className}`),onClick:e.withModifiers(d,["stop"])},[e.createElementVNode("div",{class:e.normalizeClass(`${l}-wrap`),onClick:e.withModifiers(c,["stop"])},[e.createElementVNode("div",{class:e.normalizeClass(`${l}-content`),style:e.normalizeStyle(e.unref(a))},[t.showClose?(e.openBlock(),e.createElementBlock("img",{key:0,onClick:g[0]||(g[0]=e.withModifiers(u=>n("close"),["stop"])),src:e.unref(At),class:e.normalizeClass(`${l}-close`)},null,10,St)):e.createCommentVNode("",!0),t.showIcon?(e.openBlock(),e.createElementBlock("img",{key:1,src:t.icon||e.unref(Lt),class:e.normalizeClass(`${l}-icon`)},null,10,xt)):e.createCommentVNode("",!0),t.message?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(`${l}-message`),style:e.normalizeStyle(e.unref(r))},e.toDisplayString(t.message),7)):e.createCommentVNode("",!0)],6)],10,Ct)],10,jt),[[e.vShow,t.visible]])],4)]),_:1}))}}),Vn="",Wn="",Ot=W(_t,[["__scopeId","data-v-0947d1e3"]]);class ke{loadingToast;el;options;visible=e.ref(!1);animateDuration=300;constructor(n){this.options={...n,visible:this.visible},this.options.duration==null&&(this.options.duration=60*10*1e3),this.el=document.createElement("div"),this.loadingToast=Ot}async show(){const n=this.options,l={...n,onClose:()=>{this.close(),n?.onClose?.()}},s=e.createVNode(this.loadingToast,l);e.render(s,this.el),document.body.insertBefore(this.el,document.body.firstChild),this.visible.value=!0,n.duration!==0&&setTimeout(()=>{this.destory()},n.duration),await Ie(n.duration+this.animateDuration)}async destory(){!this.visible.value||(this.visible.value=!1,await new Promise(n=>{setTimeout(()=>{if(!this.el){n();return}document.body.removeChild(this.el),n()},this.animateDuration-10)}))}close(){document.querySelector("#lzc-loading-toast")?.remove()}}function bt(t,n){const o=!!n?.debug,l=n?.printErrorLog!==!1,s=n?.loading!==!1,a=n?.autoClose!==!1,r=n?.delay!==void 0?n.delay:300,d=n?.hook!==void 0?n.hook:!0,c={...n,showIcon:n?.showIcon!==!1,captureEventP:n?.captureEventP===!0};o&&console.log("useDelayAsync - loading: %s autoClose: %s delay: %s loadingToastOptions: %o",s,a,r,c);const f=e.ref(!1);let g=null;const u=new ke(c);async function m(...i){if(o&&console.log(`useDelayAsync - handler - processing: ${f.value}`),!f.value){f.value=!0,g=setTimeout(()=>{o&&console.log("useDelayAsync - handler - setTimeout - loading: %s processing: %s",s,f.value),s&&(!f.value||u.show())},r);try{o&&console.time("useDelayAsync - handler-execute-time");const D=await t(...i);return o&&console.log("useDelayAsync - execute res: ",D),o&&console.timeEnd("useDelayAsync - handler-execute-time"),await M(a),await n?.onSuccess?.(D,[...i]),D}catch(D){o&&console.timeEnd("useDelayAsync - handler-execute-time"),l&&console.error(D),await M(a),await n?.onError?.(D,[...i])}}}async function M(i=!0){o&&console.log("useDelayAsync - close - closeLoading: ",i),f.value=!1,g&&clearTimeout(g),g=null,i&&await u.destory()}return d&&e.onBeforeUnmount(()=>{o&&console.log("useDelayAsync - onBeforeUnmount - close"),M()}),{processing:f,handler:m,close:M}}function kt(t,n){return t>n?"horizontal":n>t?"vertical":""}function Bt(){const t=e.ref(0),n=e.ref(0),o=e.ref(0),l=e.ref(0),s=e.ref(0),a=e.ref(0),r=e.ref(""),d=()=>r.value==="vertical",c=()=>r.value==="horizontal",f=()=>{o.value=0,l.value=0,s.value=0,a.value=0,r.value=""};function g(m,M){f(),t.value=m,n.value=M}function u(m,M){o.value=(m<0?0:m)-t.value,l.value=M-n.value,s.value=Math.abs(o.value),a.value=Math.abs(l.value);const i=10;(!r.value||s.value<i&&a.value<i)&&(r.value=kt(s.value,a.value))}return{move:u,start:g,reset:f,startX:t,startY:n,deltaX:o,deltaY:l,offsetX:s,offsetY:a,direction:r,isVertical:d,isHorizontal:c}}const Be=250,Qe=5,Qt=500;function Yt(t){const{isDouble:n=!0}=t;let o,l;function s(){o=Date.now()}async function a(r,d){const c=Date.now()-o;r<Qe&&d<Qe&&(c<Be?n?l?(clearTimeout(l),l=null,t.onDoubleTap?.()):l=setTimeout(async()=>{t.onTap?.(),l=null},Be):t.onTap?.():c>Qt&&t.onLongPress?.())}return{startTap:s,checkTap:a}}function Ut(t,n){const o=e.ref(!1);function l(){o.value||(o.value=!0,e.unref(t)?.addEventListener("transitionend",s))}function s(){e.unref(t)?.removeEventListener("transitionend",s),o.value=!1,n.onComplate?.()}return{transitioning:o,startTransition:l}}function Rt(t,n,o,l){var s=Math.min(o/t,l/n),a=t*s,r=n*s;return{width:Z(a),height:Z(r)}}function $t(t){return t<3?"444ms":t<6?"555ms":"666ms"}function ze(t,n,o){return Math.min(Math.max(t,n),o)}function Z(t,n=2){return parseFloat(t.toFixed(n))}function ge(t,n,o){return t=Z(t),n=Z(n),`translate3d(${t}px, ${n}px, 0) scale3d(${o},${o},${o})`}function Ye(t){return Math.sqrt((t[0].clientX-t[1].clientX)**2+(t[0].clientY-t[1].clientY)**2)}function Pt(t){return{x:(t[0].clientX+t[1].clientX)/2,y:(t[0].clientY+t[1].clientY)/2}}function Ue(t){const n=e.ref(!1),o=e.ref(1),l=e.ref(9),s=e.ref(),a=e.ref(),r=e.ref({width:0,height:0}),d=e.ref({width:0,height:0}),c=e.reactive({level:1,offsetX:0,offsetY:0,zooming:!1,preview:!0,lastCenter:{x:0,y:0}}),f=e.ref({}),g=Bt(),u=Ut(a,{onComplate(){c.preview||p()}}),m=Yt({onTap(){t.onTap?.()},onDoubleTap(){t.onDoubleTap?.()},onLongPress(){t.onLongPress?.()}});De(a,y=>M(y)),e.watch([s,a],([y,w])=>{i(y,w)},{immediate:!0});async function M(y){const[w]=y;w.contentRect.width==d.value.width&&w.contentRect.height==d.value.height||(await i(s.value),await p(c.level,!0))}async function i(y,w){await A(y,w),y&&b()}async function D(y){if(!c.preview)return;c.preview=!1,y=y??c.level;const w=a.value;if(!w)return;const{scrollTop:C,scrollLeft:k}=w,{width:_,height:I}=r.value,{scaleW:z,scaleH:B}=S(y),{top:Y,left:O}=T(z,B),U=O!=0?O:k*-1,F=Y!=0?Y:C*-1;w.scrollTop=0,w.scrollLeft=0;const{value:H}=f;H.width=`${_}px`,H.height=`${I}px`,H.maxHeight="none",H.transitionDuration="0s",H.transform=ge(U,F,y),f.value=H,await e.nextTick(),c.offsetX=U,c.offsetY=F,await Ie(20)}async function p(y,w){if(!w&&c.preview)return;c.preview=!0,y=y??c.level;const{value:C}=f,{scaleW:k,scaleH:_}=S(y),{left:I,top:z}=T(k,_);y===1&&(C.maxHeight="100%"),C.width=`${k}px`,C.height=`${_}px`,C.transitionDuration="0s",C.transform=ge(I,z,1),f.value=C,await e.nextTick();const B=a.value;if(!B)return;const{offsetX:Y,offsetY:O}=c;Y<0&&(B.scrollLeft=Math.abs(Y)),O<0&&(B.scrollTop=Math.abs(O))}async function h(y,w,C){if(n.value||(y=Z(y),y=ze(y,o.value-o.value*.5,l.value+l.value*.5),y==c.level))return;c.preview&&await D(),w||(w={x:g.startX.value,y:g.startY.value});const{value:k}=f,{width:_,height:I}=r.value,{scaleW:z,scaleH:B}=S(y),{top:Y,left:O}=T(z,B),U=y/c.level,F={left:Math.abs(_*y-d.value.width)*-1,top:Math.abs(I*y-d.value.height)*-1,right:O,bottom:Y};let H=O!=0?O:(c.offsetX-w.x)*U+w.x,K=Y!=0?Y:(c.offsetY-w.y)*U+w.y;H=Z(ze(H,F.left,F.right)),K=Z(ze(K,F.top,F.bottom)),k.width=`${_}px`,k.height=`${I}px`,k.transitionDuration=C?$t(y):"0s",k.transform=ge(H,K,y),c.offsetX=H,c.offsetY=K,c.level=y,f.value=k,await e.nextTick(),C&&u.startTransition(),t.onScale?.(y)}function N(){const y=c.level>1?1:Q();h(y,void 0,!0)}function E(y,w){if(!c.preview)return;const C=a.value;!C||C.scrollTo({left:c.offsetX-y,top:c.offsetY-w})}async function j(){c.level>=o.value&&c.level<=l.value?c.zooming&&await p():c.level<o.value?await h(o.value,void 0,!0):c.level>l.value&&await h(l.value,c.lastCenter,!0),c.zooming=!1}function Q(){const{width:y,height:w}=r.value,{width:C,height:k}=d.value,_=2.5;let I;return w==k?(I=C/y,I-1<.1&&(I=_)):I=Math.max(_,C/y,k/w),I}function S(y){const{width:w,height:C}=r.value;return{scaleW:Z(y*w),scaleH:Z(y*C)}}function T(y,w){const{width:C,height:k}=d.value,_=Math.max(0,(k-w)*.5),I=Math.max(0,(C-y)*.5);return{top:_,left:I}}async function A(y,w){if(y=y??s.value,w=w??a.value,!w)return;let C,{clientWidth:k=0,clientHeight:_=0}=y||{};const{clientWidth:I,clientHeight:z}=w;if(y instanceof HTMLImageElement?C={width:y.naturalWidth,height:y.naturalHeight}:y instanceof HTMLVideoElement&&(C={width:y.videoWidth,height:y.videoHeight}),C){const B=Rt(C.width,C.height,I,z);k=B.width,_=B.height}(k===0||_===0)&&(k=r.value.width||I,_=r.value.height||z),r.value={width:Math.min(k,I),height:Math.min(_,z)},d.value={width:I,height:z},p(void 0,!0)}function b(){const y=Q();l.value=Math.max(l.value,y*2)}function $(y){n.value=y}return{touch:g,state:c,style:f,gesture:m,transition:u,imageRef:s,containerRef:a,switchToZoom:D,switchToPreview:p,panTo:E,zoomTo:h,zoomFinished:j,toggleZoom:N,setDisableZoom:$}}function Re(t,n){const{state:o,touch:l,transition:s,containerRef:a}=t,r=rt(a);let d,c;function f(m){d=m}function g(m){return d==m}function u(m,M,i,D){r.measure();const{top:p,left:h,right:N,bottom:E}=r.arrivedState;if(m=="start")c=p||h||N||E;else if(d==2)c=!1;else if(c){if(l.direction.value=="vertical")if(o.level!=1)c=!1;else{const j=l.startY.value<i;c=p&&j||E&&!j}else if(l.direction.value=="horizontal"){const j=l.startX.value<M;c=h&&j||N&&!j}}c&&s.transitioning.value&&(c=!1,D?.preventDefault()),m=="end"&&!c&&(M=l.startX.value,i=l.startY.value,c=!0),(m!="move"||c)&&n?.(m,l.direction.value,M,i,D)}return{onSwipeEdge:u,setFingerNum:f,isEqualFingerNum:g}}function Ht(t){const n=Ue({onDoubleTap(){n.toggleZoom()},...t}),{state:o,touch:l,gesture:s,transition:a}=n;let r=!1,d=null;const c={top:0,left:0},f=ne(p,150),{onSwipeEdge:g}=Re(n,t.onSwipeEdge),u=e.ref({top:0,left:0});le("keyup",N),le("keydown",h);function m(E){const j=n.containerRef.value;if(!j)return;const{left:Q,top:S}=j.getBoundingClientRect();u.value.left=Q,u.value.top=S,s.startTap();let T=E.clientX-Q,A=E.clientY-S;l.start(T,A),g("start",T,A,E),a.transitioning.value||(r=!0,c.left=Q,c.top=S,o.offsetX=j.scrollLeft,o.offsetY=j.scrollTop),window.addEventListener("pointermove",M),window.addEventListener("pointerup",i)}function M(E){if(!r)return;let j=E.clientX,Q=E.clientY;l.move(j,Q),g("move",j-u.value.left,Q-u.value.top,E),o.level!==1&&n.panTo(l.deltaX.value-c.left,l.deltaY.value-c.top)}function i(E){g("end",l.offsetX.value,l.offsetY.value,E),s.checkTap(l.offsetX.value,l.offsetY.value),l.reset(),r=!1,window.removeEventListener("pointermove",M),window.removeEventListener("pointerup",i)}function D(E){if(!E.ctrlKey)return;o.zooming||(o.zooming=!0,d=="Control"&&window.addEventListener("keyup",p)),E.preventDefault();let j=-E.deltaY;E.deltaMode===1?j*=.05:j*=E.deltaMode?1:.002,d!="Control"&&(j*=10),j=2**j;const Q=o.level*j;o.lastCenter={x:E.offsetX,y:E.offsetY},n.zoomTo(Q,o.lastCenter),d!="Control"&&f()}function p(){n.zoomFinished(),window.removeEventListener("keyup",p)}function h(E){d=E.key}function N(){d=null}return{core:n,onPointerDown:m,onWheel:D}}function Ft(t){const n=Ue({onDoubleTap(){n.toggleZoom()},...t}),{state:o,touch:l,gesture:s}=n,{setFingerNum:a,onSwipeEdge:r,isEqualFingerNum:d}=Re(n,t.onSwipeEdge);let c,f;async function g(M){const{touches:i}=M;a(i.length),o.zooming=d(2),s.startTap();const{clientX:D,clientY:p}=i[0];l.start(D,p),r("start",D,p,M),o.zooming&&(M.preventDefault(),c=o.level,f=Ye(i),await n.switchToZoom(),o.lastCenter=Pt(i))}async function u(M){const{touches:i}=M;a(i.length);const{clientX:D,clientY:p}=i[0];if(l.move(D,p),r("move",D,p,M),o.zooming&&d(2)){M.preventDefault();const h=Ye(i),N=c*h/f;n.zoomTo(N,o.lastCenter)}}async function m(M){if(M.touches.length)return;const{clientX:i,clientY:D}=M.changedTouches[0];r("end",i,D,M),s.checkTap(l.offsetX.value,l.offsetY.value),n.zoomFinished(),l.reset()}return{core:n,onTouchStart:g,onTouchMove:u,onTouchEnd:m}}function Vt(){const t=e.reactive({scale:1,startX:0,startY:0,offsetX:0,offsetY:0,dragging:!1,started:!1});function n(s,a){t.startX=s,t.startY=a,t.scale=1}function o(s,a){t.started=!0,t.dragging=!0,t.offsetX=s-t.startX,t.offsetY=a-t.startY,t.scale=1-Math.abs(t.offsetY/a*.4)}function l(){!t.dragging||(Math.abs(t.offsetY)>window.innerHeight*.14?t.scale=.3:t.scale=1,t.dragging=!1,t.offsetX=0,t.offsetY=0)}return{state:t,dragStart:n,dragMove:o,dragEnd:l}}function $e(){const t=e.ref(!1),n=e.ref(!1);return e.onActivated(()=>{!n.value||(t.value=!0)}),e.onMounted(()=>{n.value=!1,setTimeout(()=>{n.value=!0})}),{isActivated:t}}function Pe(t){let n=!1;return()=>{n||(t(),n=!0)}}function Wt(t){let n=null;const{isActivated:o}=$e(),l=Pe(()=>n=window.onBackPress);function s(){l(),window.onBackPress=()=>t()}function a(){window.onBackPress=n}return e.onActivated(()=>{!o.value||s()}),e.onBeforeMount(()=>{s()}),e.onBeforeUnmount(()=>{a()}),e.onDeactivated(()=>{a()}),{register:s,unregister:a}}const Xt=["onClick"],Zt=e.defineComponent({__name:"Toast",props:{message:null,position:null,buttonClickEvent:null},setup(t){const n=t,o=e.ref(),l=e.ref(),s=e.ref(),a=e.computed(()=>{switch(n.position){case"top":return 10;case"middle":return 50;case"bottom":return 85}}),r=e.computed(()=>({position:"absolute",borderRadius:"10px",backgroundColor:"rgba(0, 0, 0, 0.8)",padding:"14px 19px",top:`calc(${a.value}% - ${s.value}px)`,left:`calc(50% - ${l.value}px)`})),d=e.computed(()=>({width:"fit-content",display:"flex",justifyContent:"center",alignItems:"center",color:"white",fontSize:"14px"}));function c(){!n.buttonClickEvent||n.buttonClickEvent()}return e.nextTick(()=>{l.value=o.value.offsetWidth/2,s.value=o.value.offsetHeight/2}),(f,g)=>(e.openBlock(),e.createElementBlock("div",{onClick:e.withModifiers(c,["stop"]),id:"toastWrapper",ref_key:"toastWrapper",ref:o,class:"toastWrapper",style:e.normalizeStyle([e.unref(r),{zIndex:9999999}])},[e.createElementVNode("div",{style:e.normalizeStyle(e.unref(d))},[e.createElementVNode("span",null,e.toDisplayString(t.message),1)],4)],12,Xt))}}),Xn="",Kt=W(Zt,[["__scopeId","data-v-25d39b90"]]),He={message:"\u61D2\u732B\u4E91 Yes!!!",position:"middle",duration:1500,buttonClickEvent:()=>{}};class Gt{options;container;constructor(n){this.options=n,this.container=document.createElement("div")}present(){const n=e.h(e.h(Kt),{...He,...this.options});e.render(n,this.container),document.body.insertBefore(this.container,document.body.firstChild);const o=this.options.duration||He.duration;setTimeout(()=>{this.dismiss()},o)}dismiss(){if(this.container){const n=this.container.querySelector("#toastWrapper");n.style.opacity="0",n.style.transition="opacity 0.4s ease-in",setTimeout(()=>{this.container&&(e.render(null,this.container),document.body.removeChild(this.container))},500)}}}const qt=["xlink:href","fill","color"],te=e.defineComponent({__name:"SvgIcon",props:{name:null,prefix:{default:"icon"},color:{default:"#FFF"},width:null,height:null},setup(t){const n=t,o=e.computed(()=>`#${n.prefix}-${n.name}`),l=e.computed(()=>({width:`${n.width??n.height}px`,height:`${n.height??n.width}px`,aspectRatio:n.width&&n.height?void 0:"1/1"}));function s(a){const{style:r}=a;return typeof r=="object"?r:{}}return(a,r)=>(e.openBlock(),e.createElementBlock("svg",{"aria-hidden":"",style:e.normalizeStyle({...e.unref(l),...s(a.$attrs)})},[e.createElementVNode("use",{"xlink:href":e.unref(o),fill:t.color,color:t.color},null,8,qt)],4))}});function Jt(t){const{containerEl:n,sliderEl:o,autoHeight:l,performance:s={},maxHeightRatio:a=.9,observeMethod:r="classList"}=t,d=e.ref(!0),c=ne($,100);let f,g="";const u=e.ref(0),m=e.ref(0),M=e.ref(0),i=e.ref({top:0,scrollTop:0,scrollHeight:0,clientHeight:0}),D=e.ref({clientHeight:0}),p=e.computed(()=>!!m.value),h=e.computed(()=>i.value.scrollHeight>i.value.clientHeight),N=e.computed(()=>l?i.value.clientHeight-Q.value:i.value.clientHeight-D.value.clientHeight),E=e.computed(()=>i.value.scrollHeight-i.value.clientHeight),j=e.computed(()=>!i.value.clientHeight&&!i.value.scrollHeight?1:Math.max(i.value.clientHeight/i.value.scrollHeight,.05)),Q=e.computed(()=>j.value>a?0:j.value*i.value.clientHeight),S=e.computed(()=>({willChange:"transform",transform:`translate3d(0,${M.value}px,0)`,height:l?`${Q.value}px`:void 0}));De(n,()=>z());function T(O){b(),m.value=O.clientY-o.value.getBoundingClientRect().top||1,g=getComputedStyle(n.value).scrollBehavior,g==="smooth"&&(n.value.style.scrollBehavior="unset")}function A(){n.value.style.scrollBehavior=g,m.value=0,c()}function b(){d.value=!1}function $(){p.value||(d.value=!0)}function y(O){if(!p.value)return;let U=O.clientY-i.value.top-m.value;U<0?M.value=0:U>=N.value?M.value=N.value:M.value=U,n.value.scrollTo({top:M.value/N.value*E.value})}function w(){p.value||C()}function C(){cancelAnimationFrame(f),f=requestAnimationFrame(k)}function k(){n.value&&(u.value=s.scrollTop?.value??n.value.scrollTop,M.value=u.value/E.value*N.value)}function _(O){let U="addEventListener";O==="add"?U="addEventListener":U="removeEventListener",o.value?.[U]("pointerdown",T,{passive:!0}),window[U]("pointermove",y,{passive:!0}),window[U]("pointerup",A,{passive:!0})}const I=new MutationObserver(O=>{(r=="classList"||O.map(F=>F.oldValue).join().includes("height"))&&z()});function z(){i.value.top=n.value?.getBoundingClientRect().top??0;const{scrollHeight:O=0,clientHeight:U=0}=n.value||{},{scrollHeight:F,clientHeight:H}=i.value;O!=F&&(i.value.scrollHeight=O,k()),U!=H&&(i.value.clientHeight=U,k());const{clientHeight:K=0}=o.value||{};K!=D.value.clientHeight&&(D.value.clientHeight=K)}function B(){b(),setTimeout(()=>{D.value.clientHeight=o.value?.clientHeight??0,$()},150)}function Y(){if(n.value&&o.value){n.value.classList.add("hide-scrollbar"),n.value.addEventListener("scroll",w,{passive:!0}),_("add");const O={};r==="classList"?Object.assign(O,{subtree:!0,childList:!0}):Object.assign(O,{subtree:!0,attributeOldValue:!0,attributeFilter:["style"]}),I.observe(n.value,O),setTimeout(()=>{z()},100),B()}else console.error("useScrollBar:","\u521D\u59CB\u5316\u5931\u8D25!",{containerEl:n,sliderEl:o})}return e.watch(u,()=>{b(),c()}),{isScrollEnd:d,isDragSlider:p,offsetTop:M,scrollTop:u,scrollable:h,sliderPos:S,init:Y,modifySliderEventListener:_,heightRatio:j}}const en=(t=>(e.pushScopeId("data-v-7fd39e51"),t=t(),e.popScopeId(),t))(()=>e.createElementVNode("div",{class:"default-slider"},null,-1)),tn=e.defineComponent({__name:"ScrollBar",props:{containerEl:null,autoHide:{type:Boolean},autoHeight:{type:Boolean},observeMethod:null,performance:null,maxHeightRatio:{default:.9}},setup(t,{expose:n}){const o=t,l=!!e.useSlots().default,s=e.ref(null),a=e.computed(()=>o.containerEl),r=Jt({containerEl:a,sliderEl:s,autoHeight:l?o.autoHeight:!0,performance:o.performance,observeMethod:o.observeMethod}),{scrollable:d,isScrollEnd:c,sliderPos:f,heightRatio:g}=r,u=e.ref(!1),m=o.autoHide?e.computed(()=>o.maxHeightRatio<g.value?!1:u.value||!c.value):e.computed(()=>o.maxHeightRatio<g.value?!1:d.value),{load:M}=Te(`.hide-scrollbar {
|
|
15
15
|
scrollbar-width: none;
|
|
16
16
|
-ms-overflow-style: none;
|
|
17
17
|
}
|
|
18
18
|
.hide-scrollbar::-webkit-scrollbar {
|
|
19
19
|
display: none;
|
|
20
|
-
}`,{id:"styletag_lzc_scrollbar",manual:!0});e.onMounted(()=>{M(),e.nextTick(()=>{r.init()})}),e.onUnmounted(()=>{r.modifySliderEventListener("remove")});function i(){u.value=!0}function D(){u.value=!1}return n({uScrollBarReturn:r}),(p,h)=>(e.openBlock(),e.createBlock(e.Transition,null,{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{ref_key:"sliderRef",ref:s,class:"slider-wrapper",onMouseenter:i,onMouseleave:D,style:e.normalizeStyle(e.unref(f))},[e.renderSlot(p.$slots,"default",{},()=>[en],!0)],36),[[e.vShow,e.unref(m)]])]),_:3}))}}),Kn="",nn=W(tn,[["__scopeId","data-v-7fd39e51"]]),on=t=>(e.pushScopeId("data-v-df5da876"),t=t(),e.popScopeId(),t),ln={class:"pull-refresh"},sn={key:0,class:"pull-arrow-circle"},an={key:0,class:"box-load"},rn={class:"left-load"},cn={class:"right-load"},un=on(()=>e.createElementVNode("div",{class:"among-load"},null,-1)),dn={class:"pull-arrow"},fn={key:1},Mn=e.defineComponent({__name:"PullRefresh",props:{refresh:null,refreshOff:{type:Boolean,default:!1},scrollTop:null,pullRefreshContainer:null},setup(t){const n=t,o=.7,l="#2EC1CC",s=e.ref(-999),a=e.ref(1),r=e.ref(0),d=e.ref(.3),c=e.ref(!1),f=e.ref(0),g=e.ref(0),u=e.ref(0),m=e.ref(0),M=e.ref(0),i=e.ref(),D=e.computed(()=>n.scrollTop),p=e.computed(()=>({transition:`${m.value}ms`,transform:`translate3d(0,${s.value}px, 0) scale(${a.value})`})),h=e.computed(()=>({borderColor:l,transition:m.value,transform:`rotate(${100+r.value}deg)`,opacity:d.value}));e.watch(M,T=>{T===0&&(s.value=-50,d.value=.3)}),e.watch(g,T=>{if(M.value===2)return;const A=Math.pow(T,o);A===0&&(s.value=-50),A<=50&&A>0&&(s.value=A-45,r.value=Math.pow(A,1.5),A>15?c.value=!0:c.value=!1),A>50&&(s.value=5,d.value=1,M.value)});const N=e.ref(0),w=T=>{N.value=T.touches[0].pageY},j=T=>{const A=T.touches[0].pageY-N.value;N.value=T.touches[0].pageY,!n.refreshOff&&(!n?.refresh||M.value!==2&&D.value===0&&(f.value===0&&(f.value=T.touches[0].pageY),u.value=0,S.value.style.transition=`${u.value}ms`,m.value=0,g.value=T.touches[0].pageY-f.value,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,A>0&&T.preventDefault()))},Q=()=>{if(n.refreshOff||!n?.refresh||M.value===2)return;f.value=0,u.value=300;const T=Math.pow(g.value,o);S.value.style.transition=`${u.value}ms`,T>50?(M.value=2,g.value=Math.pow(50,1/o),S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,m.value=300,n?.refresh&&n?.refresh().then(()=>{i.value="\u5237\u65B0\u6210\u529F"}).catch(()=>{i.value="\u5237\u65B0\u5931\u8D25"}).finally(()=>{setTimeout(()=>{M.value=0,g.value=0,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,setTimeout(()=>{i.value=void 0},m.value)},600)})):(g.value=0,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`)},S=e.ref(null);return e.onMounted(()=>{n?.refreshOff||(S.value=document.querySelector(n.pullRefreshContainer),S.value?.addEventListener("touchstart",w),S.value?.addEventListener("touchmove",j),S.value?.addEventListener("touchend",Q))}),(T,A)=>(e.openBlock(),e.createElementBlock("div",ln,[e.createElementVNode("div",{class:"pull-refresh-box",style:e.normalizeStyle(e.unref(p))},[i.value?(e.openBlock(),e.createElementBlock("div",fn,e.toDisplayString(i.value),1)):(e.openBlock(),e.createElementBlock("div",sn,[M.value==2?(e.openBlock(),e.createElementBlock("div",an,[e.createElementVNode("div",rn,[e.createElementVNode("div",{class:"left-circle",style:e.normalizeStyle({backgroundColor:l})},null,4)]),e.createElementVNode("div",cn,[e.createElementVNode("div",{class:"right-circle",style:e.normalizeStyle({backgroundColor:l})},null,4)]),un])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"pull-circle-line",style:e.normalizeStyle(e.unref(h))},[e.createElementVNode("div",dn,[e.createElementVNode("div",{class:e.normalizeClass(["arrows",{opacity:c.value}]),style:e.normalizeStyle({borderBottomColor:l})},null,6)])],4))]))],4)]))}}),Gn="",Fe=W(Mn,[["__scopeId","data-v-df5da876"]]),gn=["data-key"],mn={inheritAttrs:!1},hn=e.defineComponent({...mn,__name:"VirtualList",props:{data:null,getItemKey:null,itemHeight:null,overscan:{default:10},refresh:null,refreshOff:{type:Boolean,default:!1}},emits:["scrollEnd"],setup(t,{expose:n,emit:o}){const l=t,s=_e(e.toRef(l,"data"),{itemHeight:M=>l.itemHeight(l.data[M]),overscan:l.overscan,scrollEndHook:()=>{o("scrollEnd")}}),{list:a,containerProps:r,wrapperProps:d,innerProps:c,getItemHeightData:f,scrollTop:g}=s;n({vListReturn:s});const u="virtualListWrapper"+new Date().getTime();function m(M,i){return l.getItemKey?l.getItemKey(M,i):`${i}`}return(M,i)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(Fe,{refresh:t.refresh,refreshOff:t.refreshOff,scrollTop:e.unref(g),pullRefreshContainer:"#"+u},null,8,["refresh","refreshOff","scrollTop","pullRefreshContainer"]),e.createElementVNode("div",{class:"virtualListWrapper",id:u},[e.createElementVNode("div",e.mergeProps({onScrollPassive:i[0]||(i[0]=(...D)=>e.unref(r).onScroll&&e.unref(r).onScroll(...D)),ref:e.unref(r).ref,class:"virtualList"},M.$attrs),[e.createElementVNode("div",e.normalizeProps(e.guardReactiveProps(e.unref(d))),[e.createElementVNode("div",e.normalizeProps(e.guardReactiveProps(e.unref(c))),[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(a),({data:D,index:p})=>(e.openBlock(),e.createElementBlock("div",{key:m(D,p),"data-key":m(D,p),style:e.normalizeStyle({height:`${e.unref(f)(p).height}px`,display:"flex"})},[e.renderSlot(M.$slots,"default",{data:D,index:p},void 0,!0)],12,gn))),128))],16)],16)],16)])],64))}}),qn="",pn=W(hn,[["__scopeId","data-v-dfe60586"]]),Ae=t=>(e.pushScopeId("data-v-33519afd"),t=t(),e.popScopeId(),t),yn={style:{position:"absolute"}},Dn=Ae(()=>e.createElementVNode("div",{class:"wrapper"},null,-1)),Tn=["width","height"],Nn=[Ae(()=>e.createElementVNode("title",null,"logo",-1)),Ae(()=>e.createElementVNode("g",{id:"group-1",stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},[e.createElementVNode("path",{d:"M260,0 L260,260 L0,260 L0,0 L260,0 Z M173.523673,59.478426 L168.543315,62.4752911 C160.9116,67.0675753 153.089651,71.6349169 145.95806,75.5800674 C142.130471,77.697465 141.695584,77.8197038 137.842227,77.8197038 L123.620155,77.8194132 C120.16747,77.8127705 119.807362,77.673506 116.200006,75.5626777 L115.86045,75.3641139 C113.295911,73.8653877 110.281688,72.1255413 103.60737,68.2932221 C100.032855,66.2486474 96.3694634,64.1645054 92.8123362,62.1486494 L88.1098826,59.4837265 L86.4238232,64.6191026 C83.7525911,72.7551036 81.4062856,80.7653112 79.9222326,87.4417622 C78.9474243,91.8460343 78.2380884,93.2327734 74.2195073,98.9752733 C73.3694777,100.207223 72.630007,101.343155 72.0710109,102.283257 C67.5201215,110.313953 65.2975905,119.339776 65.6004928,128.457001 C66.1750084,143.318086 73.5375842,157.955758 85.6992798,168.473706 C96.9509724,178.204645 111.5737,183.826593 127.858154,184.209647 L130.088901,184.229303 C130.3376,186.684365 130.531293,189.982467 130.67329,193.770543 L130.951876,201.202421 L137.351863,197.414204 C154.766094,187.106546 169.345402,176.172255 180.160428,163.526119 C190.679421,151.226139 196.179795,138.745301 195.345608,125.762609 C194.727393,116.39373 192.289395,107.848059 187.082918,99.046007 C186.275378,97.7498121 185.738167,97.0056347 184.495395,95.37077 C181.975467,92.0558065 181.159964,90.5424149 180.493634,87.4039653 C178.713605,78.9218624 176.863265,71.4211865 175.088993,65.0761883 L173.523673,59.478426 Z M93.177,72.537 L93.8226224,72.9040486 C95.6240552,73.9292933 97.4266638,74.9575498 99.2051531,75.9748184 C106.15023,79.9626119 109.111289,81.6727026 111.728598,83.2042091 C116.752992,86.1442112 118.538634,86.6733184 123.964152,86.6733184 L137.842227,86.6733184 C143.264867,86.6733184 145.156143,86.1417146 150.243765,83.3272749 L153.915953,81.276117 C157.635687,79.179445 161.486156,76.9543599 165.360239,74.6740288 L168.062636,73.0710869 L168.527808,74.8705095 C169.630114,79.2468106 170.742831,84.0476913 171.830914,89.2325336 C172.820403,93.8931438 174.207097,96.4665356 177.447051,100.728693 C178.530829,102.154402 178.952253,102.738183 179.517404,103.643654 C183.925243,111.098001 185.980436,118.301862 186.51071,126.337939 C187.173867,136.658947 182.587388,147.066077 173.431821,157.771787 L171.503004,159.959402 C163.609627,168.649028 153.591728,176.617571 141.90907,184.187495 L139.123121,185.960576 L139.113767,185.819152 C139.047016,184.932364 138.975009,184.102769 138.897435,183.336992 C138.769034,182.069465 138.589718,180.629122 138.367155,179.053334 L137.795381,175.005053 L133.714496,175.253822 C132.500079,175.327852 131.274186,175.368647 130.037423,175.375838 C114.999567,175.463276 101.629066,170.545082 91.4908024,161.777083 C81.1421175,152.827103 74.9249947,140.466728 74.4483613,128.138982 C74.2004611,120.675327 76.0261036,113.26129 79.7275986,106.727863 C80.126032,106.059698 80.7615655,105.083428 81.4902403,104.02721 C86.0997527,97.4404488 87.2937074,95.1062887 88.5657754,89.358959 C89.6596645,84.4377825 91.2792852,78.6447463 93.1627518,72.6043699 L93.177,72.537 Z",id:"path-1",fill:"#FFF"})],-1))],wn=e.defineComponent({__name:"Loading",props:{width:{default:"90"},height:{default:"90"},duration:{default:1300}},setup(t){const n=t;e.useCssVars(l=>({"312487ac":o}));const o=`${n.duration}ms`;return(l,s)=>(e.openBlock(),e.createElementBlock("div",yn,[Dn,(e.openBlock(),e.createElementBlock("svg",{style:{position:"relative"},width:t.width,height:t.height,viewBox:"0 0 260 260",version:"1.1",xmlns:"http://www.w3.org/2000/svg"},Nn,8,Tn))]))}}),to="",vn=W(wn,[["__scopeId","data-v-33519afd"]]),En=["image/bmp","image/jpg","image/jpeg","image/gif","image/heic","image/heif","image/png","image/webp","image/svg+xml","image/x-livp"];function Ve(t,n){const o=e.ref(t?.value),l=e.computed(()=>o.value?.startsWith("/_lzc")),s=e.ref(!1),a=e.computed(()=>s.value),r=e.computed(()=>{const c=n?.value;return!c||c.startsWith("video/")?!0:c.startsWith("image/")?l.value?!0:En.includes(c):!1});t&&e.watch(t,c=>{o.value=c,s.value=!1});function d(){s.value=!0}return{imgSrc:o,isError:s,hasError:a,isSupport:r,handleError:d}}function We(){return{vImageCancel:{beforeUnmount(n){!n||(n.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7")}}}}const In=["title"],zn={class:"tip"},An=[e.createTextVNode("\u5F53\u524D\u683C\u5F0F\u4E0D\u652F\u6301")],Ln=["src"],jn=["src"],Cn=["title"],Sn={inheritAttrs:!1},xn=e.defineComponent({...Sn,__name:"Image",props:{src:null,mime:null,thumbnail:null,isShowSrc:{type:Boolean},autoRemoveThumbnail:{type:Boolean},noSupportIconName:{default:"\u4E0D\u652F\u6301\u663E\u793A"},badImageIconName:{default:"\u56FE\u7247\u635F\u574F"}},emits:["load","noSupport","loadError"],setup(t,{emit:n}){const o=t,l=e.ref(),s=e.ref(),a=e.ref(!1),r=e.ref(!1),d=e.ref(!1),{src:c,mime:f}=e.toRefs(o),{imgSrc:g,isSupport:u,hasError:m,handleError:M}=Ve(c,f),{vImageCancel:i}=We(),{LoadingComp:D}=Ee({component:be,delay:300}),p=Ke(()=>d.value&&o.autoRemoveThumbnail?!1:o.thumbnail&&!d.value);function h(){r.value=!0}function N(){r.value&&(d.value=!0)}async function w(){h(),p.value?(l.value?.addEventListener("animationend",j),l.value?.classList.add("showing"),await Ie(10)):l.value&&n("load",l.value),l.value?.classList.remove("src-class")}function j(){l.value?.removeEventListener("animationend",j),l.value?.classList.remove("showing"),l.value&&n("load",l.value),N()}async function Q(A){A?w():s.value&&n("load",s.value),a.value=!0}function S(A){A?(M(),n("loadError")):h(),a.value=!0}function T(){n("noSupport")}return(A,b)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.unref(u)&&!a.value?(e.openBlock(),e.createBlock(e.unref(D),{key:0})):e.createCommentVNode("",!0),e.unref(u)?e.unref(m)?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:3},A.$attrs,{title:e.unref(g),class:"tip-wrap"}),[e.createVNode(te,{class:"bad-image",name:t.badImageIconName},null,8,["name"])],16,Cn)):e.renderSlot(A.$slots,"default",{key:2,src:e.unref(g),onLoad:Q,onError:S},()=>[e.unref(p)?e.withDirectives((e.openBlock(),e.createElementBlock("img",e.mergeProps({key:0},A.$attrs,{ref_key:"thumbnailRef",ref:s,onLoad:b[0]||(b[0]=$=>Q()),onError:b[1]||(b[1]=$=>S()),src:t.thumbnail}),null,16,Ln)),[[e.unref(i)]]):e.createCommentVNode("",!0),t.isShowSrc||r.value?e.withDirectives((e.openBlock(),e.createElementBlock("img",e.mergeProps({key:1},A.$attrs,{ref_key:"srcRef",ref:l,class:"src-class",onLoad:b[2]||(b[2]=$=>Q(!0)),onError:b[3]||(b[3]=$=>S(!0)),src:e.unref(g)}),null,16,jn)),[[e.unref(i)],[e.vShow,r.value]]):e.createCommentVNode("",!0)],!0):(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:1},A.$attrs,{title:e.unref(g),class:"tip-wrap"}),[e.createVNode(te,{class:"no-support-icon",name:t.noSupportIconName},null,8,["name"]),e.withDirectives((e.openBlock(),e.createElementBlock("span",zn,An)),[[e.unref(me),T]])],16,In))],64))}}),oo="",_n=W(xn,[["__scopeId","data-v-c31d96e8"]]),On=["title"],bn=["src"],kn=["title"],Bn=e.defineComponent({__name:"Thumbnail",props:{src:null,mime:null},emits:["noSupport"],setup(t,{emit:n}){const o=t,l=e.ref(!1),{src:s,mime:a}=e.toRefs(o),{imgSrc:r,hasError:d,isSupport:c,handleError:f}=Ve(s,a),{vImageCancel:g}=We();function u(){n("noSupport")}return(m,M)=>e.unref(c)?e.unref(d)?(e.openBlock(),e.createElementBlock("div",{key:2,title:e.unref(r),class:"icon-wrap"},[e.createVNode(te,{class:"icon",name:"\u56FE\u7247\u635F\u574F"})],8,kn)):e.withDirectives((e.openBlock(),e.createElementBlock("img",{key:1,fetchpriority:"high",onLoad:M[0]||(M[0]=i=>l.value=!0),onError:M[1]||(M[1]=(...i)=>e.unref(f)&&e.unref(f)(...i)),src:e.unref(r)},null,40,bn)),[[e.unref(g)],[e.vShow,l.value]]):(e.openBlock(),e.createElementBlock("div",{key:0,title:e.unref(r),class:"icon-wrap"},[e.withDirectives(e.createVNode(te,{class:"icon",name:"\u672A\u77E5\u7C7B\u578B"},null,512),[[e.unref(me),u]])],8,On))}}),lo="",Qn=W(Bn,[["__scopeId","data-v-2f606efa"]]);E.DefaultLoading=be,E.Image=_n,E.Loading=vn,E.LoadingToast=ke,E.PageLoading=zt,E.PullRefresh=Fe,E.ScrollBar=nn,E.SvgIcon=te,E.Thumbnail=Qn,E.ToastCreator=Gt,E.VirtualList=pn,E.allSelectedKey=re,E.closeDialogKey=Oe,E.dialogController=yt,E.getTransform=ge,E.isAllSelectedKey=fe,E.isSelectedKey=ie,E.itemKeyKey=Ne,E.once=Pe,E.selectAllKey=ue,E.selectKey=ce,E.selectedCountKey=Me,E.toggleAllKey=se,E.toggleKey=ae,E.unselectAllKey=J,E.unselectKey=de,E.useBackPress=Wt,E.useDelayAsync=bt,E.useDelayLoad=Dt,E.useDelayLoadComp=Ee,E.useDownDrag=Vt,E.useDragSelect=ve,E.useDragSelectByMobile=mt,E.useDragSelectByPc=gt,E.useRouterActivated=$e,E.useScaleImageByMobile=Ft,E.useScaleImageByPc=Ht,E.useSelectable=ft,E.useSelectableByBase=Mt,E.useSelectableInjectors=dt,E.useVirtualList=_e,E.vDebounceClick=Ze,E.vEnter=me,E.vSingleClick=je,Object.defineProperties(E,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
20
|
+
}`,{id:"styletag_lzc_scrollbar",manual:!0});e.onMounted(()=>{M(),e.nextTick(()=>{r.init()})}),e.onUnmounted(()=>{r.modifySliderEventListener("remove")});function i(){u.value=!0}function D(){u.value=!1}return n({uScrollBarReturn:r}),(p,h)=>(e.openBlock(),e.createBlock(e.Transition,null,{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{ref_key:"sliderRef",ref:s,class:"slider-wrapper",onMouseenter:i,onMouseleave:D,style:e.normalizeStyle(e.unref(f))},[e.renderSlot(p.$slots,"default",{},()=>[en],!0)],36),[[e.vShow,e.unref(m)]])]),_:3}))}}),Kn="",nn=W(tn,[["__scopeId","data-v-7fd39e51"]]),on=t=>(e.pushScopeId("data-v-df5da876"),t=t(),e.popScopeId(),t),ln={class:"pull-refresh"},sn={key:0,class:"pull-arrow-circle"},an={key:0,class:"box-load"},rn={class:"left-load"},cn={class:"right-load"},un=on(()=>e.createElementVNode("div",{class:"among-load"},null,-1)),dn={class:"pull-arrow"},fn={key:1},Mn=e.defineComponent({__name:"PullRefresh",props:{refresh:null,refreshOff:{type:Boolean,default:!1},scrollTop:null,pullRefreshContainer:null},setup(t){const n=t,o=.7,l="#2EC1CC",s=e.ref(-999),a=e.ref(1),r=e.ref(0),d=e.ref(.3),c=e.ref(!1),f=e.ref(0),g=e.ref(0),u=e.ref(0),m=e.ref(0),M=e.ref(0),i=e.ref(),D=e.computed(()=>n.scrollTop),p=e.computed(()=>({transition:`${m.value}ms`,transform:`translate3d(0,${s.value}px, 0) scale(${a.value})`})),h=e.computed(()=>({borderColor:l,transition:m.value,transform:`rotate(${100+r.value}deg)`,opacity:d.value}));e.watch(M,T=>{T===0&&(s.value=-50,d.value=.3)}),e.watch(g,T=>{if(M.value===2)return;const A=Math.pow(T,o);A===0&&(s.value=-50),A<=50&&A>0&&(s.value=A-45,r.value=Math.pow(A,1.5),A>15?c.value=!0:c.value=!1),A>50&&(s.value=5,d.value=1,M.value)});const N=e.ref(0),E=T=>{N.value=T.touches[0].pageY},j=T=>{const A=T.touches[0].pageY-N.value;N.value=T.touches[0].pageY,!n.refreshOff&&(!n?.refresh||M.value!==2&&D.value===0&&(f.value===0&&(f.value=T.touches[0].pageY),u.value=0,S.value.style.transition=`${u.value}ms`,m.value=0,g.value=T.touches[0].pageY-f.value,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,A>0&&T.preventDefault()))},Q=()=>{if(n.refreshOff||!n?.refresh||M.value===2)return;f.value=0,u.value=300;const T=Math.pow(g.value,o);S.value.style.transition=`${u.value}ms`,T>50?(M.value=2,g.value=Math.pow(50,1/o),S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,m.value=300,n?.refresh&&n?.refresh().then(()=>{i.value="\u5237\u65B0\u6210\u529F"}).catch(()=>{i.value="\u5237\u65B0\u5931\u8D25"}).finally(()=>{setTimeout(()=>{M.value=0,g.value=0,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`,setTimeout(()=>{i.value=void 0},m.value)},600)})):(g.value=0,S.value.style.transform=`translate3d(0, ${Math.pow(g.value,o)}px, 0)`)},S=e.ref(null);return e.onMounted(()=>{n?.refreshOff||(S.value=document.querySelector(n.pullRefreshContainer),S.value?.addEventListener("touchstart",E),S.value?.addEventListener("touchmove",j),S.value?.addEventListener("touchend",Q))}),(T,A)=>(e.openBlock(),e.createElementBlock("div",ln,[e.createElementVNode("div",{class:"pull-refresh-box",style:e.normalizeStyle(e.unref(p))},[i.value?(e.openBlock(),e.createElementBlock("div",fn,e.toDisplayString(i.value),1)):(e.openBlock(),e.createElementBlock("div",sn,[M.value==2?(e.openBlock(),e.createElementBlock("div",an,[e.createElementVNode("div",rn,[e.createElementVNode("div",{class:"left-circle",style:e.normalizeStyle({backgroundColor:l})},null,4)]),e.createElementVNode("div",cn,[e.createElementVNode("div",{class:"right-circle",style:e.normalizeStyle({backgroundColor:l})},null,4)]),un])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"pull-circle-line",style:e.normalizeStyle(e.unref(h))},[e.createElementVNode("div",dn,[e.createElementVNode("div",{class:e.normalizeClass(["arrows",{opacity:c.value}]),style:e.normalizeStyle({borderBottomColor:l})},null,6)])],4))]))],4)]))}}),Gn="",Fe=W(Mn,[["__scopeId","data-v-df5da876"]]),gn=["data-key"],mn={inheritAttrs:!1},hn=e.defineComponent({...mn,__name:"VirtualList",props:{data:null,getItemKey:null,itemHeight:null,overscan:{default:10},refresh:null,refreshOff:{type:Boolean,default:!1}},emits:["scrollEnd"],setup(t,{expose:n,emit:o}){const l=t,s=_e(e.toRef(l,"data"),{itemHeight:M=>l.itemHeight(l.data[M]),overscan:l.overscan,scrollEndHook:()=>{o("scrollEnd")}}),{list:a,containerProps:r,wrapperProps:d,innerProps:c,getItemHeightData:f,scrollTop:g}=s;n({vListReturn:s});const u="virtualListWrapper"+new Date().getTime();function m(M,i){return l.getItemKey?l.getItemKey(M,i):`${i}`}return(M,i)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(Fe,{refresh:t.refresh,refreshOff:t.refreshOff,scrollTop:e.unref(g),pullRefreshContainer:"#"+u},null,8,["refresh","refreshOff","scrollTop","pullRefreshContainer"]),e.createElementVNode("div",{class:"virtualListWrapper",id:u},[e.createElementVNode("div",e.mergeProps({onScrollPassive:i[0]||(i[0]=(...D)=>e.unref(r).onScroll&&e.unref(r).onScroll(...D)),ref:e.unref(r).ref,class:"virtualList"},M.$attrs),[e.createElementVNode("div",e.normalizeProps(e.guardReactiveProps(e.unref(d))),[e.createElementVNode("div",e.normalizeProps(e.guardReactiveProps(e.unref(c))),[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(a),({data:D,index:p})=>(e.openBlock(),e.createElementBlock("div",{key:m(D,p),"data-key":m(D,p),style:e.normalizeStyle({height:`${e.unref(f)(p).height}px`,display:"flex"})},[e.renderSlot(M.$slots,"default",{data:D,index:p},void 0,!0)],12,gn))),128))],16)],16)],16)])],64))}}),qn="",pn=W(hn,[["__scopeId","data-v-dfe60586"]]),Ae=t=>(e.pushScopeId("data-v-33519afd"),t=t(),e.popScopeId(),t),yn={style:{position:"absolute"}},Dn=Ae(()=>e.createElementVNode("div",{class:"wrapper"},null,-1)),Tn=["width","height"],Nn=[Ae(()=>e.createElementVNode("title",null,"logo",-1)),Ae(()=>e.createElementVNode("g",{id:"group-1",stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},[e.createElementVNode("path",{d:"M260,0 L260,260 L0,260 L0,0 L260,0 Z M173.523673,59.478426 L168.543315,62.4752911 C160.9116,67.0675753 153.089651,71.6349169 145.95806,75.5800674 C142.130471,77.697465 141.695584,77.8197038 137.842227,77.8197038 L123.620155,77.8194132 C120.16747,77.8127705 119.807362,77.673506 116.200006,75.5626777 L115.86045,75.3641139 C113.295911,73.8653877 110.281688,72.1255413 103.60737,68.2932221 C100.032855,66.2486474 96.3694634,64.1645054 92.8123362,62.1486494 L88.1098826,59.4837265 L86.4238232,64.6191026 C83.7525911,72.7551036 81.4062856,80.7653112 79.9222326,87.4417622 C78.9474243,91.8460343 78.2380884,93.2327734 74.2195073,98.9752733 C73.3694777,100.207223 72.630007,101.343155 72.0710109,102.283257 C67.5201215,110.313953 65.2975905,119.339776 65.6004928,128.457001 C66.1750084,143.318086 73.5375842,157.955758 85.6992798,168.473706 C96.9509724,178.204645 111.5737,183.826593 127.858154,184.209647 L130.088901,184.229303 C130.3376,186.684365 130.531293,189.982467 130.67329,193.770543 L130.951876,201.202421 L137.351863,197.414204 C154.766094,187.106546 169.345402,176.172255 180.160428,163.526119 C190.679421,151.226139 196.179795,138.745301 195.345608,125.762609 C194.727393,116.39373 192.289395,107.848059 187.082918,99.046007 C186.275378,97.7498121 185.738167,97.0056347 184.495395,95.37077 C181.975467,92.0558065 181.159964,90.5424149 180.493634,87.4039653 C178.713605,78.9218624 176.863265,71.4211865 175.088993,65.0761883 L173.523673,59.478426 Z M93.177,72.537 L93.8226224,72.9040486 C95.6240552,73.9292933 97.4266638,74.9575498 99.2051531,75.9748184 C106.15023,79.9626119 109.111289,81.6727026 111.728598,83.2042091 C116.752992,86.1442112 118.538634,86.6733184 123.964152,86.6733184 L137.842227,86.6733184 C143.264867,86.6733184 145.156143,86.1417146 150.243765,83.3272749 L153.915953,81.276117 C157.635687,79.179445 161.486156,76.9543599 165.360239,74.6740288 L168.062636,73.0710869 L168.527808,74.8705095 C169.630114,79.2468106 170.742831,84.0476913 171.830914,89.2325336 C172.820403,93.8931438 174.207097,96.4665356 177.447051,100.728693 C178.530829,102.154402 178.952253,102.738183 179.517404,103.643654 C183.925243,111.098001 185.980436,118.301862 186.51071,126.337939 C187.173867,136.658947 182.587388,147.066077 173.431821,157.771787 L171.503004,159.959402 C163.609627,168.649028 153.591728,176.617571 141.90907,184.187495 L139.123121,185.960576 L139.113767,185.819152 C139.047016,184.932364 138.975009,184.102769 138.897435,183.336992 C138.769034,182.069465 138.589718,180.629122 138.367155,179.053334 L137.795381,175.005053 L133.714496,175.253822 C132.500079,175.327852 131.274186,175.368647 130.037423,175.375838 C114.999567,175.463276 101.629066,170.545082 91.4908024,161.777083 C81.1421175,152.827103 74.9249947,140.466728 74.4483613,128.138982 C74.2004611,120.675327 76.0261036,113.26129 79.7275986,106.727863 C80.126032,106.059698 80.7615655,105.083428 81.4902403,104.02721 C86.0997527,97.4404488 87.2937074,95.1062887 88.5657754,89.358959 C89.6596645,84.4377825 91.2792852,78.6447463 93.1627518,72.6043699 L93.177,72.537 Z",id:"path-1",fill:"#FFF"})],-1))],wn=e.defineComponent({__name:"Loading",props:{width:{default:"90"},height:{default:"90"},duration:{default:1300}},setup(t){const n=t;e.useCssVars(l=>({"312487ac":o}));const o=`${n.duration}ms`;return(l,s)=>(e.openBlock(),e.createElementBlock("div",yn,[Dn,(e.openBlock(),e.createElementBlock("svg",{style:{position:"relative"},width:t.width,height:t.height,viewBox:"0 0 260 260",version:"1.1",xmlns:"http://www.w3.org/2000/svg"},Nn,8,Tn))]))}}),to="",vn=W(wn,[["__scopeId","data-v-33519afd"]]),En=["image/bmp","image/jpg","image/jpeg","image/gif","image/heic","image/heif","image/png","image/webp","image/svg+xml","image/x-livp"];function Ve(t,n){const o=e.ref(t?.value),l=e.computed(()=>o.value?.startsWith("/_lzc")),s=e.ref(!1),a=e.computed(()=>s.value),r=e.computed(()=>{const c=n?.value;return!c||c.startsWith("video/")?!0:c.startsWith("image/")?l.value?!0:En.includes(c):!1});t&&e.watch(t,c=>{o.value=c,s.value=!1});function d(){s.value=!0}return{imgSrc:o,isError:s,hasError:a,isSupport:r,handleError:d}}function We(){return{vImageCancel:{beforeUnmount(n){!n||(n.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7")}}}}const In=["title"],zn={class:"tip"},An=[e.createTextVNode("\u5F53\u524D\u683C\u5F0F\u4E0D\u652F\u6301")],Ln=["src"],jn=["src"],Cn=["title"],Sn={inheritAttrs:!1},xn=e.defineComponent({...Sn,__name:"Image",props:{src:null,mime:null,thumbnail:null,isShowSrc:{type:Boolean},autoRemoveThumbnail:{type:Boolean},noSupportIconName:{default:"\u4E0D\u652F\u6301\u663E\u793A"},badImageIconName:{default:"\u56FE\u7247\u635F\u574F"}},emits:["load","noSupport","loadError"],setup(t,{emit:n}){const o=t,l=e.ref(),s=e.ref(),a=e.ref(!1),r=e.ref(!1),d=e.ref(!1),{src:c,mime:f}=e.toRefs(o),{imgSrc:g,isSupport:u,hasError:m,handleError:M}=Ve(c,f),{vImageCancel:i}=We(),{LoadingComp:D}=Ee({component:be,delay:300}),p=Ke(()=>d.value&&o.autoRemoveThumbnail?!1:o.thumbnail&&!d.value);function h(){r.value=!0}function N(){r.value&&(d.value=!0)}async function E(){h(),p.value?(l.value?.addEventListener("animationend",j),l.value?.classList.add("showing"),await Ie(10)):l.value&&n("load",l.value),l.value?.classList.remove("src-class")}function j(){l.value?.removeEventListener("animationend",j),l.value?.classList.remove("showing"),l.value&&n("load",l.value),N()}async function Q(A){A?E():s.value&&n("load",s.value),a.value=!0}function S(A){A?(M(),n("loadError")):h(),a.value=!0}function T(){n("noSupport")}return(A,b)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.unref(u)&&!a.value?(e.openBlock(),e.createBlock(e.unref(D),{key:0})):e.createCommentVNode("",!0),e.unref(u)?e.unref(m)?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:3},A.$attrs,{title:e.unref(g),class:"tip-wrap"}),[e.createVNode(te,{class:"bad-image",name:t.badImageIconName},null,8,["name"])],16,Cn)):e.renderSlot(A.$slots,"default",{key:2,src:e.unref(g),onLoad:Q,onError:S},()=>[e.unref(p)?e.withDirectives((e.openBlock(),e.createElementBlock("img",e.mergeProps({key:0},A.$attrs,{ref_key:"thumbnailRef",ref:s,onLoad:b[0]||(b[0]=$=>Q()),onError:b[1]||(b[1]=$=>S()),src:t.thumbnail}),null,16,Ln)),[[e.unref(i)]]):e.createCommentVNode("",!0),t.isShowSrc||r.value?e.withDirectives((e.openBlock(),e.createElementBlock("img",e.mergeProps({key:1},A.$attrs,{ref_key:"srcRef",ref:l,class:"src-class",onLoad:b[2]||(b[2]=$=>Q(!0)),onError:b[3]||(b[3]=$=>S(!0)),src:e.unref(g)}),null,16,jn)),[[e.unref(i)],[e.vShow,r.value]]):e.createCommentVNode("",!0)],!0):(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:1},A.$attrs,{title:e.unref(g),class:"tip-wrap"}),[e.createVNode(te,{class:"no-support-icon",name:t.noSupportIconName},null,8,["name"]),e.withDirectives((e.openBlock(),e.createElementBlock("span",zn,An)),[[e.unref(me),T]])],16,In))],64))}}),oo="",_n=W(xn,[["__scopeId","data-v-c31d96e8"]]),On=["title"],bn=["src"],kn=["title"],Bn=e.defineComponent({__name:"Thumbnail",props:{src:null,mime:null},emits:["noSupport"],setup(t,{emit:n}){const o=t,l=e.ref(!1),{src:s,mime:a}=e.toRefs(o),{imgSrc:r,hasError:d,isSupport:c,handleError:f}=Ve(s,a),{vImageCancel:g}=We();function u(){n("noSupport")}return(m,M)=>e.unref(c)?e.unref(d)?(e.openBlock(),e.createElementBlock("div",{key:2,title:e.unref(r),class:"icon-wrap"},[e.createVNode(te,{class:"icon",name:"\u56FE\u7247\u635F\u574F"})],8,kn)):e.withDirectives((e.openBlock(),e.createElementBlock("img",{key:1,fetchpriority:"high",onLoad:M[0]||(M[0]=i=>l.value=!0),onError:M[1]||(M[1]=(...i)=>e.unref(f)&&e.unref(f)(...i)),src:e.unref(r)},null,40,bn)),[[e.unref(g)],[e.vShow,l.value]]):(e.openBlock(),e.createElementBlock("div",{key:0,title:e.unref(r),class:"icon-wrap"},[e.withDirectives(e.createVNode(te,{class:"icon",name:"\u672A\u77E5\u7C7B\u578B"},null,512),[[e.unref(me),u]])],8,On))}}),lo="",Qn=W(Bn,[["__scopeId","data-v-2f606efa"]]);v.DefaultLoading=be,v.Image=_n,v.Loading=vn,v.LoadingToast=ke,v.PageLoading=zt,v.PullRefresh=Fe,v.ScrollBar=nn,v.SvgIcon=te,v.Thumbnail=Qn,v.ToastCreator=Gt,v.VirtualList=pn,v.allSelectedKey=re,v.closeDialogKey=Oe,v.dialogController=yt,v.getTransform=ge,v.isAllSelectedKey=fe,v.isSelectedKey=ie,v.itemKeyKey=Ne,v.once=Pe,v.selectAllKey=ue,v.selectKey=ce,v.selectedCountKey=Me,v.toggleAllKey=se,v.toggleKey=ae,v.unselectAllKey=J,v.unselectKey=de,v.useBackPress=Wt,v.useDelayAsync=bt,v.useDelayLoad=Dt,v.useDelayLoadComp=Ee,v.useDownDrag=Vt,v.useDragSelect=ve,v.useDragSelectByMobile=mt,v.useDragSelectByPc=gt,v.useRouterActivated=$e,v.useScaleImageByMobile=Ft,v.useScaleImageByPc=Ht,v.useSelectable=ft,v.useSelectableByBase=Mt,v.useSelectableInjectors=dt,v.useVirtualList=_e,v.vDebounceClick=Ze,v.vEnter=me,v.vSingleClick=je,Object.defineProperties(v,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|