@lazycatcloud/lzc-toolkit 0.0.69 → 0.0.71
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 +277 -264
- package/dist/index.umd.js +4 -4
- package/dist/types/useDelayLoad/index.d.ts +9 -3
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref as h, watch as K, customRef as tt, getCurrentScope as lt, onScopeDispose as nt, getCurrentInstance as Be, onMounted as oe, nextTick as _e, unref as $, onUpdated as ot, readonly as st, shallowRef as at, computed as S, onUnmounted as Ie, inject as j, provide as
|
|
1
|
+
import { ref as h, watch as K, customRef as tt, getCurrentScope as lt, onScopeDispose as nt, getCurrentInstance as Be, onMounted as oe, nextTick as _e, unref as $, onUpdated as ot, readonly as st, shallowRef as at, computed as S, onUnmounted as Ie, inject as j, provide as z, defineComponent as U, h as Y, render as ue, openBlock as I, createBlock as Me, Transition as Pe, withCtx as He, createElementBlock as H, createElementVNode as C, withModifiers as rt, normalizeClass as Ae, renderSlot as ye, createCommentVNode as ut, normalizeProps as he, guardReactiveProps as pe, pushScopeId as ce, popScopeId as de, normalizeStyle as W, toDisplayString as Fe, useSlots as it, withDirectives as ct, vShow as dt, toRef as vt, Fragment as Ee, createVNode as ft, mergeProps as ht, renderList as pt, useCssVars as mt } from "vue";
|
|
2
2
|
var Ce;
|
|
3
3
|
const we = typeof window < "u", xe = (e) => typeof e == "function";
|
|
4
4
|
we && ((Ce = window?.navigator) == null ? void 0 : Ce.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
@@ -14,12 +14,12 @@ function ke(e, t) {
|
|
|
14
14
|
function gt(e, t = {}) {
|
|
15
15
|
let l, n;
|
|
16
16
|
return (a) => {
|
|
17
|
-
const s = ie(e),
|
|
18
|
-
if (l && clearTimeout(l), s <= 0 ||
|
|
17
|
+
const s = ie(e), c = ie(t.maxWait);
|
|
18
|
+
if (l && clearTimeout(l), s <= 0 || c !== void 0 && c <= 0)
|
|
19
19
|
return n && (clearTimeout(n), n = null), a();
|
|
20
|
-
|
|
20
|
+
c && !n && (n = setTimeout(() => {
|
|
21
21
|
l && clearTimeout(l), n = null, a();
|
|
22
|
-
},
|
|
22
|
+
}, c)), l = setTimeout(() => {
|
|
23
23
|
n && clearTimeout(n), n = null, a();
|
|
24
24
|
}, s);
|
|
25
25
|
};
|
|
@@ -30,12 +30,12 @@ function _t(e, t = !0, l = !0) {
|
|
|
30
30
|
o && (clearTimeout(o), o = void 0);
|
|
31
31
|
};
|
|
32
32
|
return (f) => {
|
|
33
|
-
const
|
|
34
|
-
if (s(),
|
|
33
|
+
const v = ie(e), d = Date.now() - n;
|
|
34
|
+
if (s(), v <= 0)
|
|
35
35
|
return n = Date.now(), f();
|
|
36
|
-
|
|
36
|
+
d > v && (l || !a) ? (n = Date.now(), f()) : t && (o = setTimeout(() => {
|
|
37
37
|
n = Date.now(), a = !0, s(), f();
|
|
38
|
-
},
|
|
38
|
+
}, v)), !l && !o && (o = setTimeout(() => a = !0, v)), a = !1;
|
|
39
39
|
};
|
|
40
40
|
}
|
|
41
41
|
function yt(e) {
|
|
@@ -47,20 +47,20 @@ function wt(e, t) {
|
|
|
47
47
|
a.value = !0, o();
|
|
48
48
|
};
|
|
49
49
|
K(e, s, { flush: "sync" });
|
|
50
|
-
const
|
|
50
|
+
const c = xe(t) ? t : t.get, f = xe(t) ? void 0 : t.set, v = tt((d, i) => (n = d, o = i, {
|
|
51
51
|
get() {
|
|
52
|
-
return a.value && (l =
|
|
52
|
+
return a.value && (l = c(), a.value = !1), n(), l;
|
|
53
53
|
},
|
|
54
54
|
set(u) {
|
|
55
55
|
f?.(u);
|
|
56
56
|
}
|
|
57
57
|
}));
|
|
58
|
-
return Object.isExtensible(
|
|
58
|
+
return Object.isExtensible(v) && (v.trigger = s), v;
|
|
59
59
|
}
|
|
60
|
-
function
|
|
60
|
+
function ze(e) {
|
|
61
61
|
return lt() ? (nt(e), !0) : !1;
|
|
62
62
|
}
|
|
63
|
-
function
|
|
63
|
+
function We(e, t = 200, l = {}) {
|
|
64
64
|
return ke(gt(t, l), e);
|
|
65
65
|
}
|
|
66
66
|
function Te(e, t = 200, l = !1, n = !0) {
|
|
@@ -98,23 +98,23 @@ var Le = Object.getOwnPropertySymbols, xt = Object.prototype.hasOwnProperty, Tt
|
|
|
98
98
|
function Ot(e, t, l = {}) {
|
|
99
99
|
const n = l, { window: o = bt } = n, a = Lt(n, ["window"]);
|
|
100
100
|
let s;
|
|
101
|
-
const
|
|
101
|
+
const c = Et(() => o && "ResizeObserver" in o), f = () => {
|
|
102
102
|
s && (s.disconnect(), s = void 0);
|
|
103
|
-
},
|
|
104
|
-
f(),
|
|
105
|
-
}, { immediate: !0, flush: "post" }),
|
|
106
|
-
f(),
|
|
103
|
+
}, v = K(() => Ve(e), (i) => {
|
|
104
|
+
f(), c.value && o && i && (s = new ResizeObserver(t), s.observe(i, a));
|
|
105
|
+
}, { immediate: !0, flush: "post" }), d = () => {
|
|
106
|
+
f(), v();
|
|
107
107
|
};
|
|
108
|
-
return
|
|
109
|
-
isSupported:
|
|
110
|
-
stop:
|
|
108
|
+
return ze(d), {
|
|
109
|
+
isSupported: c,
|
|
110
|
+
stop: d
|
|
111
111
|
};
|
|
112
112
|
}
|
|
113
113
|
function $t(e, t = { width: 0, height: 0 }, l = {}) {
|
|
114
114
|
const { box: n = "content-box" } = l, o = h(t.width), a = h(t.height);
|
|
115
115
|
return Ot(e, ([s]) => {
|
|
116
|
-
const
|
|
117
|
-
|
|
116
|
+
const c = n === "border-box" ? s.borderBoxSize : n === "content-box" ? s.contentBoxSize : s.devicePixelContentBoxSize;
|
|
117
|
+
c ? (o.value = c.reduce((f, { inlineSize: v }) => f + v, 0), a.value = c.reduce((f, { blockSize: v }) => f + v, 0)) : (o.value = s.contentRect.width, a.value = s.contentRect.height);
|
|
118
118
|
}, l), K(() => Ve(e), (s) => {
|
|
119
119
|
o.value = s ? t.width : 0, a.value = s ? t.height : 0;
|
|
120
120
|
}), {
|
|
@@ -126,43 +126,43 @@ var Oe;
|
|
|
126
126
|
(function(e) {
|
|
127
127
|
e.UP = "UP", e.RIGHT = "RIGHT", e.DOWN = "DOWN", e.LEFT = "LEFT", e.NONE = "NONE";
|
|
128
128
|
})(Oe || (Oe = {}));
|
|
129
|
-
let
|
|
130
|
-
function
|
|
129
|
+
let Dt = 0;
|
|
130
|
+
function Rt(e, t = {}) {
|
|
131
131
|
const l = h(!1), {
|
|
132
132
|
document: n = St,
|
|
133
133
|
immediate: o = !0,
|
|
134
134
|
manual: a = !1,
|
|
135
|
-
id: s = `vueuse_styletag_${++
|
|
136
|
-
} = t,
|
|
135
|
+
id: s = `vueuse_styletag_${++Dt}`
|
|
136
|
+
} = t, c = h(e);
|
|
137
137
|
let f = () => {
|
|
138
138
|
};
|
|
139
|
-
const
|
|
139
|
+
const v = () => {
|
|
140
140
|
if (!n)
|
|
141
141
|
return;
|
|
142
|
-
const
|
|
143
|
-
|
|
144
|
-
|
|
142
|
+
const i = n.getElementById(s) || n.createElement("style");
|
|
143
|
+
i.type = "text/css", i.id = s, t.media && (i.media = t.media), n.head.appendChild(i), !l.value && (f = K(c, (u) => {
|
|
144
|
+
i.innerText = u;
|
|
145
145
|
}, { immediate: !0 }), l.value = !0);
|
|
146
|
-
},
|
|
146
|
+
}, d = () => {
|
|
147
147
|
!n || !l.value || (f(), n.head.removeChild(n.getElementById(s)), l.value = !1);
|
|
148
148
|
};
|
|
149
|
-
return o && !a && Ne(
|
|
149
|
+
return o && !a && Ne(v), a || ze(d), {
|
|
150
150
|
id: s,
|
|
151
|
-
css:
|
|
152
|
-
unload:
|
|
153
|
-
load:
|
|
151
|
+
css: c,
|
|
152
|
+
unload: d,
|
|
153
|
+
load: v,
|
|
154
154
|
isLoaded: st(l)
|
|
155
155
|
};
|
|
156
156
|
}
|
|
157
|
-
var Bt = Object.defineProperty, $e = Object.getOwnPropertySymbols, It = Object.prototype.hasOwnProperty, Mt = Object.prototype.propertyIsEnumerable,
|
|
157
|
+
var Bt = Object.defineProperty, $e = Object.getOwnPropertySymbols, It = Object.prototype.hasOwnProperty, Mt = Object.prototype.propertyIsEnumerable, De = (e, t, l) => t in e ? Bt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, Pt = (e, t) => {
|
|
158
158
|
for (var l in t || (t = {}))
|
|
159
|
-
It.call(t, l) &&
|
|
159
|
+
It.call(t, l) && De(e, l, t[l]);
|
|
160
160
|
if ($e)
|
|
161
161
|
for (var l of $e(t))
|
|
162
|
-
Mt.call(t, l) &&
|
|
162
|
+
Mt.call(t, l) && De(e, l, t[l]);
|
|
163
163
|
return e;
|
|
164
164
|
};
|
|
165
|
-
const
|
|
165
|
+
const Ht = {
|
|
166
166
|
easeInSine: [0.12, 0, 0.39, 0],
|
|
167
167
|
easeOutSine: [0.61, 1, 0.88, 1],
|
|
168
168
|
easeInOutSine: [0.37, 0, 0.63, 1],
|
|
@@ -188,61 +188,61 @@ const Pt = {
|
|
|
188
188
|
easeOutBack: [0.34, 1.56, 0.64, 1],
|
|
189
189
|
easeInOutBack: [0.68, -0.6, 0.32, 1.6]
|
|
190
190
|
};
|
|
191
|
-
|
|
191
|
+
Pt({
|
|
192
192
|
linear: yt
|
|
193
|
-
},
|
|
193
|
+
}, Ht);
|
|
194
194
|
function At(e, t) {
|
|
195
|
-
const { scrollEndHook: l, itemHeight: n, overscan: o = 5 } = t, a = h(null), s = $t(a),
|
|
196
|
-
let
|
|
197
|
-
const
|
|
195
|
+
const { scrollEndHook: l, itemHeight: n, overscan: o = 5 } = t, a = h(null), s = $t(a), c = h(!0), f = We(M, 100);
|
|
196
|
+
let v;
|
|
197
|
+
const d = at(e), i = h(0), u = h({ start: 0, end: 10 });
|
|
198
198
|
let r = 0;
|
|
199
199
|
const m = h([]), E = S(() => {
|
|
200
200
|
let { sum: g, height: b } = { sum: 0, height: 0 };
|
|
201
|
-
return
|
|
201
|
+
return d.value.map((A, P) => (typeof n == "number" ? b = n : b = n(P), g += b, { height: b, sum: g }));
|
|
202
202
|
}), y = S(() => G(u.value.start)), w = S(() => typeof n == "number" ? E.value.length * n : E.value[E.value.length - 1]?.sum || 0), T = S(() => {
|
|
203
203
|
let g = m.value.length - o, b = Math.max(g - r, 0);
|
|
204
204
|
return m.value.slice(b, g);
|
|
205
205
|
});
|
|
206
206
|
oe(() => {
|
|
207
|
-
}), Ie(() => cancelAnimationFrame(
|
|
208
|
-
[s.width, s.height,
|
|
207
|
+
}), Ie(() => cancelAnimationFrame(v)), K(
|
|
208
|
+
[s.width, s.height, d],
|
|
209
209
|
([g, b]) => {
|
|
210
|
-
(g || b) &&
|
|
210
|
+
(g || b) && D();
|
|
211
211
|
},
|
|
212
212
|
{ deep: !0 }
|
|
213
|
-
), K(
|
|
213
|
+
), K(i, () => {
|
|
214
214
|
F(), f();
|
|
215
215
|
});
|
|
216
216
|
function F() {
|
|
217
|
-
|
|
217
|
+
c.value = !1;
|
|
218
218
|
}
|
|
219
219
|
function M() {
|
|
220
|
-
|
|
221
|
-
}
|
|
222
|
-
function R() {
|
|
223
|
-
cancelAnimationFrame(d), d = requestAnimationFrame(D);
|
|
220
|
+
c.value = !0, l?.();
|
|
224
221
|
}
|
|
225
222
|
function D() {
|
|
223
|
+
cancelAnimationFrame(v), v = requestAnimationFrame(R);
|
|
224
|
+
}
|
|
225
|
+
function R() {
|
|
226
226
|
if (a.value) {
|
|
227
|
-
|
|
228
|
-
let g = N(
|
|
229
|
-
g = g - o, g = g < 0 ? 0 : g, b = b >
|
|
227
|
+
i.value = a.value.scrollTop, r = q();
|
|
228
|
+
let g = N(i.value), b = g + r + o;
|
|
229
|
+
g = g - o, g = g < 0 ? 0 : g, b = b > d.value.length ? d.value.length : b, u.value = { start: g, end: b }, m.value = d.value.slice(g, b).map((A, P) => ({
|
|
230
230
|
data: A,
|
|
231
|
-
index:
|
|
231
|
+
index: P + g
|
|
232
232
|
}));
|
|
233
233
|
}
|
|
234
234
|
}
|
|
235
235
|
function N(g) {
|
|
236
|
-
let b = 0, A = E.value.length - 1,
|
|
236
|
+
let b = 0, A = E.value.length - 1, P = -1;
|
|
237
237
|
for (; b <= A; ) {
|
|
238
238
|
const O = Math.floor((b + A) / 2);
|
|
239
|
-
E.value[O].sum >= g ? (
|
|
239
|
+
E.value[O].sum >= g ? (P = O, A = O - 1) : b = O + 1;
|
|
240
240
|
}
|
|
241
|
-
return Math.max(0,
|
|
241
|
+
return Math.max(0, P);
|
|
242
242
|
}
|
|
243
243
|
function q() {
|
|
244
244
|
let g = 0, b = 0, A = k();
|
|
245
|
-
for (let
|
|
245
|
+
for (let P = A; P < E.value.length && (g++, b += E.value[P].height, !(b >= s.height.value)); P++)
|
|
246
246
|
;
|
|
247
247
|
return g;
|
|
248
248
|
}
|
|
@@ -262,14 +262,14 @@ function At(e, t) {
|
|
|
262
262
|
function ee(g) {
|
|
263
263
|
if (a.value) {
|
|
264
264
|
const b = X(g);
|
|
265
|
-
a.value.scrollTop = b.sum - b.height,
|
|
265
|
+
a.value.scrollTop = b.sum - b.height, R();
|
|
266
266
|
}
|
|
267
267
|
}
|
|
268
268
|
const se = S(() => ({
|
|
269
269
|
style: {
|
|
270
270
|
width: "100%",
|
|
271
271
|
height: `${w.value}px`,
|
|
272
|
-
pointerEvents:
|
|
272
|
+
pointerEvents: c.value ? void 0 : "none"
|
|
273
273
|
}
|
|
274
274
|
})), Z = S(() => ({
|
|
275
275
|
style: {
|
|
@@ -287,12 +287,12 @@ function At(e, t) {
|
|
|
287
287
|
totalHeight: w,
|
|
288
288
|
clientHeight: s.height,
|
|
289
289
|
scrollTo: ee,
|
|
290
|
-
scrollTop:
|
|
291
|
-
isScrollEnd:
|
|
290
|
+
scrollTop: i,
|
|
291
|
+
isScrollEnd: c,
|
|
292
292
|
containerProps: {
|
|
293
293
|
ref: a,
|
|
294
294
|
onScroll: () => {
|
|
295
|
-
|
|
295
|
+
D();
|
|
296
296
|
},
|
|
297
297
|
style: te
|
|
298
298
|
},
|
|
@@ -301,27 +301,27 @@ function At(e, t) {
|
|
|
301
301
|
};
|
|
302
302
|
}
|
|
303
303
|
const je = Symbol(), Ke = Symbol(), Ue = Symbol(), qe = Symbol(), Qe = Symbol(), Ye = Symbol(), Ge = Symbol(), Xe = Symbol(), Ze = Symbol();
|
|
304
|
-
function
|
|
304
|
+
function bl() {
|
|
305
305
|
const { voidFn: e, boolFn: t, boolRef: l, arrayRef: n } = {
|
|
306
306
|
voidFn: (r) => {
|
|
307
307
|
},
|
|
308
308
|
boolFn: (r) => !1,
|
|
309
309
|
boolRef: S(() => !1),
|
|
310
310
|
arrayRef: S(() => [])
|
|
311
|
-
}, o = j(qe, n), a = j(Ue, t), s = j(Xe, l),
|
|
311
|
+
}, o = j(qe, n), a = j(Ue, t), s = j(Xe, l), c = j(Ke, e), f = j(je, e), v = j(Qe, e), d = j(Ye, e), i = j(Ge, e), u = j(Ze, e);
|
|
312
312
|
return {
|
|
313
313
|
selected: o,
|
|
314
314
|
isSelected: a,
|
|
315
315
|
isAllSelected: s,
|
|
316
|
-
toggle:
|
|
316
|
+
toggle: c,
|
|
317
317
|
toggleAll: f,
|
|
318
|
-
select:
|
|
319
|
-
selectAll:
|
|
320
|
-
unselect:
|
|
318
|
+
select: v,
|
|
319
|
+
selectAll: d,
|
|
320
|
+
unselect: i,
|
|
321
321
|
unselectAll: u
|
|
322
322
|
};
|
|
323
323
|
}
|
|
324
|
-
function
|
|
324
|
+
function Sl(e, t) {
|
|
325
325
|
const l = h({}), n = S(() => e.value.filter((u) => l.value[u[t]])), o = S(() => n.value.length != 0 && Object.keys(l.value).length == e.value.length);
|
|
326
326
|
function a() {
|
|
327
327
|
e.value.forEach((u) => {
|
|
@@ -331,7 +331,7 @@ function bl(e, t) {
|
|
|
331
331
|
function s() {
|
|
332
332
|
l.value = {};
|
|
333
333
|
}
|
|
334
|
-
function
|
|
334
|
+
function c(u) {
|
|
335
335
|
u.forEach((r) => {
|
|
336
336
|
l.value[r[t]] || (l.value[r[t]] = !0);
|
|
337
337
|
});
|
|
@@ -341,26 +341,26 @@ function bl(e, t) {
|
|
|
341
341
|
l.value[r[t]] && delete l.value[r[t]];
|
|
342
342
|
});
|
|
343
343
|
}
|
|
344
|
-
function
|
|
344
|
+
function v(u) {
|
|
345
345
|
return !!l.value[u[t]];
|
|
346
346
|
}
|
|
347
|
-
function
|
|
347
|
+
function d(u) {
|
|
348
348
|
u.forEach((r) => {
|
|
349
|
-
|
|
349
|
+
v(r) ? delete l.value[r[t]] : l.value[r[t]] = !0;
|
|
350
350
|
});
|
|
351
351
|
}
|
|
352
|
-
function
|
|
352
|
+
function i() {
|
|
353
353
|
o.value ? s() : a();
|
|
354
354
|
}
|
|
355
|
-
return
|
|
355
|
+
return z(je, i), z(Ke, d), z(Ue, v), z(qe, n), z(Qe, c), z(Ye, a), z(Ge, f), z(Xe, o), z(Ze, s), {
|
|
356
356
|
selected: n,
|
|
357
|
-
select:
|
|
357
|
+
select: c,
|
|
358
358
|
selectAll: a,
|
|
359
359
|
unselect: f,
|
|
360
360
|
unselectAll: s,
|
|
361
|
-
toggle:
|
|
362
|
-
toggleAll:
|
|
363
|
-
isSelected:
|
|
361
|
+
toggle: d,
|
|
362
|
+
toggleAll: i,
|
|
363
|
+
isSelected: v,
|
|
364
364
|
isAllSelected: o
|
|
365
365
|
};
|
|
366
366
|
}
|
|
@@ -380,41 +380,41 @@ function Je({
|
|
|
380
380
|
unselect: a = fe("\u53D6\u6D88\u9009\u62E9"),
|
|
381
381
|
unselectAll: s = fe("\u53D6\u6D88\u5168\u9009")
|
|
382
382
|
} = n();
|
|
383
|
-
let
|
|
383
|
+
let c = {};
|
|
384
384
|
const f = S(
|
|
385
385
|
() => Te(t === "colum" ? Q : ae, 50)
|
|
386
|
-
),
|
|
386
|
+
), v = /* @__PURE__ */ new Set(), d = h(!0), i = h(), u = h(!1), r = h({ x: 0, y: 0 }), m = h({ x: 0, y: 0, scrollTop: 0 }), E = new ResizeObserver(
|
|
387
387
|
(p) => y.value = p[0].target.getBoundingClientRect()
|
|
388
388
|
), y = h({}), w = h({
|
|
389
389
|
top: 0,
|
|
390
390
|
height: 0,
|
|
391
391
|
sync(p = !1) {
|
|
392
|
-
w.value.top =
|
|
392
|
+
w.value.top = i.value?.scrollTop || 0, p && (w.value.height = i.value?.scrollHeight || 0);
|
|
393
393
|
}
|
|
394
394
|
}), T = S(() => u.value ? {
|
|
395
395
|
left: Math.min(r.value.x, m.value.x) - y.value.left,
|
|
396
396
|
top: Math.min(r.value.y, m.value.y) - y.value.top,
|
|
397
397
|
width: Math.abs(r.value.x - m.value.x),
|
|
398
398
|
height: Math.abs(r.value.y - m.value.y)
|
|
399
|
-
} : { left: 0, top: 0, width: 0, height: 0 }), { margin: F = 50, startSpeed: M = 30, maxSpeed:
|
|
400
|
-
let
|
|
401
|
-
const N = F, q = M, G =
|
|
399
|
+
} : { left: 0, top: 0, width: 0, height: 0 }), { margin: F = 50, startSpeed: M = 30, maxSpeed: D = 30 } = l;
|
|
400
|
+
let R;
|
|
401
|
+
const N = F, q = M, G = D, X = (p) => p ** 1;
|
|
402
402
|
let k = 0;
|
|
403
403
|
function ee(p) {
|
|
404
|
-
if (cancelAnimationFrame(
|
|
404
|
+
if (cancelAnimationFrame(R), k = se(p), k = Math.max(
|
|
405
405
|
Math.min(k, G),
|
|
406
406
|
-G
|
|
407
407
|
), k !== 0) {
|
|
408
|
-
const _ =
|
|
408
|
+
const _ = i.value;
|
|
409
409
|
if (!_ || !u.value)
|
|
410
410
|
return;
|
|
411
411
|
const B = w.value.height - y.value.height;
|
|
412
412
|
let x = w.value.top + Number(k);
|
|
413
|
-
x = Math.min(Math.max(0, x), B), _.scrollTop = x, te(),
|
|
413
|
+
x = Math.min(Math.max(0, x), B), _.scrollTop = x, te(), R = requestAnimationFrame(() => ee(p));
|
|
414
414
|
}
|
|
415
415
|
}
|
|
416
416
|
function se(p) {
|
|
417
|
-
if (
|
|
417
|
+
if (i.value) {
|
|
418
418
|
const B = y.value, x = B.bottom - p;
|
|
419
419
|
if (x < N)
|
|
420
420
|
return q * X(1 - x / N);
|
|
@@ -448,16 +448,16 @@ function Je({
|
|
|
448
448
|
x.sheet.insertRule(et, ne);
|
|
449
449
|
}
|
|
450
450
|
function b(p, _) {
|
|
451
|
-
|
|
451
|
+
d.value = !0, u.value = !0, w.value.height ? w.value.sync() : w.value.sync(!0), r.value.x = p, r.value.y = _ + w.value.top, m.value.x = r.value.x, m.value.y = r.value.y, i.value?.classList.add("disable-scroll-behavior"), v.clear();
|
|
452
452
|
}
|
|
453
453
|
function A(p, _, B) {
|
|
454
|
-
!u.value || (
|
|
454
|
+
!u.value || (d.value && t === "colum" && !L() && (s(), d.value = !1), B?.(), ee(_), m.value.x = Math.max(p, y.value.left), m.value.y = Math.min(
|
|
455
455
|
_ + w.value.top,
|
|
456
456
|
w.value.height + y.value.top
|
|
457
457
|
), m.value.scrollTop = w.value.top, f.value());
|
|
458
458
|
}
|
|
459
|
-
function
|
|
460
|
-
u.value = !1,
|
|
459
|
+
function P() {
|
|
460
|
+
u.value = !1, i.value?.classList.remove("disable-scroll-behavior");
|
|
461
461
|
}
|
|
462
462
|
function O() {
|
|
463
463
|
!u.value || (k || te(), f.value());
|
|
@@ -472,22 +472,22 @@ function Je({
|
|
|
472
472
|
L() && s();
|
|
473
473
|
}
|
|
474
474
|
function Q() {
|
|
475
|
-
L() ||
|
|
476
|
-
|
|
475
|
+
L() || i.value?.querySelectorAll(`[${e}]`).forEach((p) => {
|
|
476
|
+
c[`${e}`] = p.getAttribute(`${e}`), Z(p.getBoundingClientRect()) ? o([c]) : a([c]);
|
|
477
477
|
});
|
|
478
478
|
}
|
|
479
479
|
function ae() {
|
|
480
480
|
const p = [];
|
|
481
481
|
let _ = null, B = 0;
|
|
482
|
-
|
|
482
|
+
i.value?.querySelectorAll(`[${e}]`).forEach((x, V) => {
|
|
483
483
|
const ne = x.getAttribute(`${e}`);
|
|
484
|
-
p.push(ne), Z(x.getBoundingClientRect()) ? (_ === null && (_ = V), _ = Math.min(_, V), B = Math.max(B, V)) : (
|
|
484
|
+
p.push(ne), Z(x.getBoundingClientRect()) ? (_ === null && (_ = V), _ = Math.min(_, V), B = Math.max(B, V)) : (c[`${e}`] = ne, v.has(ne) && a([c]));
|
|
485
485
|
});
|
|
486
486
|
for (let x = _; x < B + 1; x++)
|
|
487
|
-
|
|
487
|
+
c[`${e}`] = p[x], o([c]), v.add(p[x]);
|
|
488
488
|
}
|
|
489
489
|
function re(p) {
|
|
490
|
-
return !p?.value || (
|
|
490
|
+
return !p?.value || (i.value = p.value, !i?.value) ? !1 : (E.observe(i.value), g(
|
|
491
491
|
".disable-scroll-behavior",
|
|
492
492
|
"scroll-behavior: unset !important;"
|
|
493
493
|
), !0);
|
|
@@ -496,46 +496,46 @@ function Je({
|
|
|
496
496
|
init: re,
|
|
497
497
|
dragStart: b,
|
|
498
498
|
dragMove: A,
|
|
499
|
-
dragEnd:
|
|
499
|
+
dragEnd: P,
|
|
500
500
|
onScroll: O,
|
|
501
501
|
isSingleClick: L,
|
|
502
502
|
cancelSelectAllBySingleClick: le,
|
|
503
503
|
selectFn: f,
|
|
504
504
|
selectRange: T,
|
|
505
505
|
isPressing: u,
|
|
506
|
-
containerEl:
|
|
506
|
+
containerEl: i,
|
|
507
507
|
observer: E
|
|
508
508
|
};
|
|
509
509
|
}
|
|
510
|
-
function
|
|
510
|
+
function El(e) {
|
|
511
511
|
const t = Je(e), { observer: l, selectRange: n } = t, {
|
|
512
512
|
onScroll: o,
|
|
513
513
|
dragStart: a,
|
|
514
514
|
dragMove: s,
|
|
515
|
-
dragEnd:
|
|
515
|
+
dragEnd: c,
|
|
516
516
|
cancelSelectAllBySingleClick: f
|
|
517
|
-
} = t,
|
|
517
|
+
} = t, v = S(() => ({
|
|
518
518
|
left: `${n.value.left}px`,
|
|
519
519
|
top: `${n.value.top}px`,
|
|
520
520
|
width: `${n.value.width}px`,
|
|
521
521
|
height: `${n.value.height}px`
|
|
522
|
-
})),
|
|
522
|
+
})), d = U({
|
|
523
523
|
render() {
|
|
524
524
|
return Y("div", {
|
|
525
525
|
id: "selectBoxEl",
|
|
526
526
|
class: "absolute z-50 bg-blue-200 opacity-50",
|
|
527
|
-
style:
|
|
527
|
+
style: v.value
|
|
528
528
|
});
|
|
529
529
|
}
|
|
530
530
|
});
|
|
531
|
-
function
|
|
531
|
+
function i(y) {
|
|
532
532
|
y.button === 0 && a(y.x, y.y);
|
|
533
533
|
}
|
|
534
534
|
function u(y) {
|
|
535
535
|
s(y.x, y.y);
|
|
536
536
|
}
|
|
537
537
|
function r(y) {
|
|
538
|
-
y.composedPath().some((T) => T?.getAttribute?.(e.attribute)) || f(),
|
|
538
|
+
y.composedPath().some((T) => T?.getAttribute?.(e.attribute)) || f(), c();
|
|
539
539
|
}
|
|
540
540
|
function m(y) {
|
|
541
541
|
try {
|
|
@@ -543,17 +543,17 @@ function Sl(e) {
|
|
|
543
543
|
throw "\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";
|
|
544
544
|
if (!t.containerEl?.value)
|
|
545
545
|
return !1;
|
|
546
|
-
ue(Y(
|
|
546
|
+
ue(Y(d), t.containerEl.value), t.containerEl.value?.addEventListener("scroll", o), t.containerEl.value?.addEventListener("mousedown", i), window.addEventListener("mousemove", u), window.addEventListener("mouseup", r);
|
|
547
547
|
} catch (w) {
|
|
548
548
|
console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25", w);
|
|
549
549
|
}
|
|
550
550
|
}
|
|
551
551
|
function E() {
|
|
552
|
-
l.disconnect(), t.containerEl.value?.removeEventListener("scroll", o), t.containerEl.value?.removeEventListener("mousedown",
|
|
552
|
+
l.disconnect(), t.containerEl.value?.removeEventListener("scroll", o), t.containerEl.value?.removeEventListener("mousedown", i), window.removeEventListener("mousemove", u), window.removeEventListener("mouseup", r);
|
|
553
553
|
}
|
|
554
554
|
return { init: m, unMount: E };
|
|
555
555
|
}
|
|
556
|
-
function
|
|
556
|
+
function Cl(e, t, l = 600) {
|
|
557
557
|
const n = Je({
|
|
558
558
|
...e,
|
|
559
559
|
selectWay: "row",
|
|
@@ -561,24 +561,24 @@ function El(e, t, l = 600) {
|
|
|
561
561
|
startSpeed: 5,
|
|
562
562
|
maxSpeed: 5
|
|
563
563
|
}
|
|
564
|
-
}), { observer: o } = n, { onScroll: a, dragStart: s, dragMove:
|
|
565
|
-
let
|
|
566
|
-
function
|
|
567
|
-
clearTimeout(
|
|
564
|
+
}), { observer: o } = n, { onScroll: a, dragStart: s, dragMove: c, dragEnd: f } = n;
|
|
565
|
+
let v;
|
|
566
|
+
function d() {
|
|
567
|
+
clearTimeout(v);
|
|
568
568
|
}
|
|
569
|
-
function
|
|
570
|
-
|
|
569
|
+
function i(y) {
|
|
570
|
+
d(), y.composedPath().some((T) => !!T?.getAttribute?.(e.attribute)) && (v = setTimeout(() => {
|
|
571
571
|
const { clientX: T, clientY: F } = y.targetTouches[0];
|
|
572
|
-
s(T, F), t?.(),
|
|
572
|
+
s(T, F), t?.(), c(T, F, () => y.preventDefault()), y.preventDefault();
|
|
573
573
|
}, l));
|
|
574
574
|
}
|
|
575
575
|
function u(y) {
|
|
576
|
-
|
|
576
|
+
d();
|
|
577
577
|
const { clientX: w, clientY: T } = y.targetTouches[0];
|
|
578
|
-
|
|
578
|
+
c(w, T, () => y.preventDefault());
|
|
579
579
|
}
|
|
580
580
|
function r() {
|
|
581
|
-
|
|
581
|
+
d(), f();
|
|
582
582
|
}
|
|
583
583
|
function m(y) {
|
|
584
584
|
try {
|
|
@@ -586,13 +586,13 @@ function El(e, t, l = 600) {
|
|
|
586
586
|
throw "\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";
|
|
587
587
|
if (!n.containerEl?.value)
|
|
588
588
|
return !1;
|
|
589
|
-
n.containerEl.value?.addEventListener("scroll", a), n.containerEl.value?.addEventListener("touchstart",
|
|
589
|
+
n.containerEl.value?.addEventListener("scroll", a), n.containerEl.value?.addEventListener("touchstart", i), n.containerEl.value?.addEventListener("touchmove", u), window.addEventListener("touchcancel", r), window.addEventListener("touchend", r);
|
|
590
590
|
} catch (w) {
|
|
591
591
|
console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25", w);
|
|
592
592
|
}
|
|
593
593
|
}
|
|
594
594
|
function E() {
|
|
595
|
-
o.disconnect(), n.containerEl.value?.removeEventListener("scroll", a), n.containerEl.value?.removeEventListener("touchstart",
|
|
595
|
+
o.disconnect(), n.containerEl.value?.removeEventListener("scroll", a), n.containerEl.value?.removeEventListener("touchstart", i), n.containerEl.value?.removeEventListener("touchmove", u), window.removeEventListener("touchcancel", r), window.removeEventListener("touchEnd", r);
|
|
596
596
|
}
|
|
597
597
|
return { init: m, unMount: E };
|
|
598
598
|
}
|
|
@@ -608,9 +608,9 @@ const Ft = Symbol(), kt = /* @__PURE__ */ U({
|
|
|
608
608
|
const l = e, n = () => {
|
|
609
609
|
l.closeOnClickOverlay && t("update:visiable", !1);
|
|
610
610
|
};
|
|
611
|
-
return
|
|
612
|
-
default:
|
|
613
|
-
e.visiable ? (I(),
|
|
611
|
+
return z(Ft, () => t("update:visiable", !1)), (o, a) => (I(), Me(Pe, { name: "modal" }, {
|
|
612
|
+
default: He(() => [
|
|
613
|
+
e.visiable ? (I(), H("div", {
|
|
614
614
|
key: 0,
|
|
615
615
|
onClick: n,
|
|
616
616
|
class: "lzc-modal"
|
|
@@ -633,13 +633,13 @@ const J = (e, t) => {
|
|
|
633
633
|
for (const [n, o] of t)
|
|
634
634
|
l[n] = o;
|
|
635
635
|
return l;
|
|
636
|
-
},
|
|
637
|
-
function
|
|
636
|
+
}, zt = /* @__PURE__ */ J(kt, [["__scopeId", "data-v-e171c24d"]]);
|
|
637
|
+
function xl(e) {
|
|
638
638
|
function t(l, n) {
|
|
639
639
|
const o = document.createElement("div"), a = {
|
|
640
640
|
setup() {
|
|
641
641
|
return () => Y(
|
|
642
|
-
|
|
642
|
+
zt,
|
|
643
643
|
{
|
|
644
644
|
visiable: !0,
|
|
645
645
|
"onUpdate:visiable": () => {
|
|
@@ -661,46 +661,58 @@ function Cl(e) {
|
|
|
661
661
|
create: t
|
|
662
662
|
};
|
|
663
663
|
}
|
|
664
|
-
function
|
|
664
|
+
function Wt({
|
|
665
665
|
component: e,
|
|
666
666
|
componentProps: t,
|
|
667
667
|
delay: l = 300
|
|
668
668
|
}) {
|
|
669
|
-
const n = `${l}ms`,
|
|
670
|
-
`@keyframes
|
|
669
|
+
const n = `${l}ms`, { load: o } = Rt(
|
|
670
|
+
`@keyframes lzcDelayLoad {
|
|
671
671
|
to {
|
|
672
672
|
opacity: 1;
|
|
673
673
|
}
|
|
674
674
|
}
|
|
675
|
-
.delay-
|
|
675
|
+
.lzc-delay-loading {
|
|
676
676
|
opacity: 0;
|
|
677
|
-
animation:
|
|
677
|
+
animation: lzcDelayLoad 0s ${n} forwards;
|
|
678
678
|
}`
|
|
679
|
-
)
|
|
679
|
+
);
|
|
680
|
+
return { LoadingComp: U({
|
|
680
681
|
setup() {
|
|
681
|
-
const
|
|
682
|
+
const s = Ct();
|
|
682
683
|
return oe(() => {
|
|
683
|
-
|
|
684
|
-
}), () =>
|
|
684
|
+
o(), s.value.classList.add("lzc-delay-loading");
|
|
685
|
+
}), () => Y(e, t);
|
|
685
686
|
}
|
|
686
|
-
});
|
|
687
|
-
|
|
687
|
+
}) };
|
|
688
|
+
}
|
|
689
|
+
function Tl({
|
|
690
|
+
component: e,
|
|
691
|
+
componentProps: t,
|
|
692
|
+
delay: l = 300
|
|
693
|
+
}) {
|
|
694
|
+
const { LoadingComp: n } = Wt({
|
|
695
|
+
component: e,
|
|
696
|
+
componentProps: t,
|
|
697
|
+
delay: l
|
|
698
|
+
}), o = h(!1);
|
|
699
|
+
function a() {
|
|
688
700
|
o.value = !0;
|
|
689
701
|
}
|
|
690
|
-
function
|
|
702
|
+
function s() {
|
|
691
703
|
o.value = !1;
|
|
692
704
|
}
|
|
693
|
-
return { LoadingComp:
|
|
705
|
+
return { LoadingComp: n, loading: o, load: a, unload: s };
|
|
694
706
|
}
|
|
695
|
-
const
|
|
707
|
+
const Nt = {}, Vt = (e) => (ce("data-v-76a2728a"), e = e(), de(), e), jt = /* @__PURE__ */ Vt(() => /* @__PURE__ */ C("div", { class: "ldio-mm5gwljcryb" }, [
|
|
696
708
|
/* @__PURE__ */ C("div")
|
|
697
|
-
], -1)),
|
|
698
|
-
|
|
709
|
+
], -1)), Kt = [
|
|
710
|
+
jt
|
|
699
711
|
];
|
|
700
|
-
function
|
|
701
|
-
return I(),
|
|
712
|
+
function Ut(e, t) {
|
|
713
|
+
return I(), H("div", he(pe(e.$attrs)), Kt, 16);
|
|
702
714
|
}
|
|
703
|
-
const
|
|
715
|
+
const Ll = /* @__PURE__ */ J(Nt, [["render", Ut], ["__scopeId", "data-v-76a2728a"]]), qt = /* @__PURE__ */ U({
|
|
704
716
|
__name: "Toast",
|
|
705
717
|
props: {
|
|
706
718
|
message: null,
|
|
@@ -723,7 +735,7 @@ const Tl = /* @__PURE__ */ J(zt, [["render", Kt], ["__scopeId", "data-v-76a2728a
|
|
|
723
735
|
padding: "14px 19px",
|
|
724
736
|
top: `calc(${a.value}% - ${o.value}px)`,
|
|
725
737
|
left: `calc(50% - ${n.value}px)`
|
|
726
|
-
})),
|
|
738
|
+
})), c = S(() => ({
|
|
727
739
|
width: "fit-content",
|
|
728
740
|
display: "flex",
|
|
729
741
|
justifyContent: "center",
|
|
@@ -733,36 +745,36 @@ const Tl = /* @__PURE__ */ J(zt, [["render", Kt], ["__scopeId", "data-v-76a2728a
|
|
|
733
745
|
}));
|
|
734
746
|
return _e(() => {
|
|
735
747
|
n.value = l.value.offsetWidth / 2, o.value = l.value.offsetHeight / 2;
|
|
736
|
-
}), (f,
|
|
748
|
+
}), (f, v) => (I(), H("div", {
|
|
737
749
|
id: "toastWrapper",
|
|
738
750
|
ref_key: "toastWrapper",
|
|
739
751
|
ref: l,
|
|
740
752
|
class: "toastWrapper",
|
|
741
|
-
style:
|
|
753
|
+
style: W([$(s), { zIndex: 9999 }])
|
|
742
754
|
}, [
|
|
743
755
|
C("div", {
|
|
744
|
-
style:
|
|
756
|
+
style: W($(c))
|
|
745
757
|
}, [
|
|
746
758
|
C("span", null, Fe(e.message), 1)
|
|
747
759
|
], 4)
|
|
748
760
|
], 4));
|
|
749
761
|
}
|
|
750
762
|
});
|
|
751
|
-
const
|
|
763
|
+
const Qt = /* @__PURE__ */ J(qt, [["__scopeId", "data-v-15ab4094"]]), Re = {
|
|
752
764
|
message: "\u61D2\u732B\u4E91 Yes!!!",
|
|
753
765
|
position: "middle",
|
|
754
766
|
duration: 1500
|
|
755
767
|
};
|
|
756
|
-
class
|
|
768
|
+
class Ol {
|
|
757
769
|
options;
|
|
758
770
|
container;
|
|
759
771
|
constructor(t) {
|
|
760
772
|
this.options = t, this.container = document.createElement("div");
|
|
761
773
|
}
|
|
762
774
|
present() {
|
|
763
|
-
const t = Y(Y(
|
|
775
|
+
const t = Y(Y(Qt), { ...Re, ...this.options });
|
|
764
776
|
ue(t, this.container), document.body.insertBefore(this.container, document.body.firstChild);
|
|
765
|
-
const l = this.options.duration ||
|
|
777
|
+
const l = this.options.duration || Re.duration;
|
|
766
778
|
setTimeout(() => {
|
|
767
779
|
this.dismiss();
|
|
768
780
|
}, l);
|
|
@@ -778,7 +790,7 @@ class Ll {
|
|
|
778
790
|
}
|
|
779
791
|
}
|
|
780
792
|
}
|
|
781
|
-
const
|
|
793
|
+
const Yt = ["xlink:href", "fill", "color"], $l = /* @__PURE__ */ U({
|
|
782
794
|
__name: "SvgIcon",
|
|
783
795
|
props: {
|
|
784
796
|
name: null,
|
|
@@ -793,47 +805,47 @@ const Qt = ["xlink:href", "fill", "color"], Ol = /* @__PURE__ */ U({
|
|
|
793
805
|
height: `${t.height ?? t.width}px`,
|
|
794
806
|
aspectRatio: t.width && t.height ? void 0 : "1/1"
|
|
795
807
|
}));
|
|
796
|
-
return (o, a) => (I(),
|
|
808
|
+
return (o, a) => (I(), H("svg", {
|
|
797
809
|
"aria-hidden": "",
|
|
798
|
-
style:
|
|
810
|
+
style: W($(n))
|
|
799
811
|
}, [
|
|
800
812
|
C("use", {
|
|
801
813
|
"xlink:href": $(l),
|
|
802
814
|
fill: e.color,
|
|
803
815
|
color: e.color
|
|
804
|
-
}, null, 8,
|
|
816
|
+
}, null, 8, Yt)
|
|
805
817
|
], 4));
|
|
806
818
|
}
|
|
807
819
|
});
|
|
808
|
-
function
|
|
820
|
+
function Gt(e) {
|
|
809
821
|
const {
|
|
810
822
|
containerEl: t,
|
|
811
823
|
sliderEl: l,
|
|
812
824
|
autoHeight: n,
|
|
813
825
|
performance: o = {},
|
|
814
826
|
maxHeightRatio: a = 0.9
|
|
815
|
-
} = e, s = h(!0),
|
|
816
|
-
let f,
|
|
817
|
-
const
|
|
827
|
+
} = e, s = h(!0), c = We(G, 100);
|
|
828
|
+
let f, v = "";
|
|
829
|
+
const d = h(0), i = h(0), u = h(0), r = h({
|
|
818
830
|
top: 0,
|
|
819
831
|
scrollTop: 0,
|
|
820
832
|
scrollHeight: 0,
|
|
821
833
|
clientHeight: 0
|
|
822
834
|
}), m = h({
|
|
823
835
|
clientHeight: 0
|
|
824
|
-
}), E = S(() => !!
|
|
836
|
+
}), E = S(() => !!i.value), y = S(() => r.value.scrollHeight > r.value.clientHeight), w = S(() => r.value.clientHeight - m.value.clientHeight), T = S(() => r.value.scrollHeight - r.value.clientHeight), F = S(() => Math.max(
|
|
825
837
|
r.value.clientHeight / r.value.scrollHeight,
|
|
826
838
|
0.05
|
|
827
|
-
)), M = S(() => F.value > a ? 0 : F.value * r.value.clientHeight),
|
|
839
|
+
)), M = S(() => F.value > a ? 0 : F.value * r.value.clientHeight), D = S(() => ({
|
|
828
840
|
willChange: "transform",
|
|
829
841
|
transform: `translate3d(0,${u.value}px,0)`,
|
|
830
842
|
height: n ? `${M.value}px` : void 0
|
|
831
843
|
}));
|
|
832
|
-
function
|
|
833
|
-
q(),
|
|
844
|
+
function R(O) {
|
|
845
|
+
q(), i.value = O.clientY - l.value.getBoundingClientRect().top || 1, v = getComputedStyle(t.value).scrollBehavior, v === "smooth" && (t.value.style.scrollBehavior = "unset");
|
|
834
846
|
}
|
|
835
847
|
function N() {
|
|
836
|
-
t.value.style.scrollBehavior =
|
|
848
|
+
t.value.style.scrollBehavior = v, i.value = 0, c();
|
|
837
849
|
}
|
|
838
850
|
function q() {
|
|
839
851
|
s.value = !1;
|
|
@@ -844,7 +856,7 @@ function Yt(e) {
|
|
|
844
856
|
function X(O) {
|
|
845
857
|
if (!E.value)
|
|
846
858
|
return;
|
|
847
|
-
let L = O.clientY - r.value.top -
|
|
859
|
+
let L = O.clientY - r.value.top - i.value;
|
|
848
860
|
L < 0 ? u.value = 0 : L >= w.value ? u.value = w.value : u.value = L, t.value.scrollTo({
|
|
849
861
|
top: u.value / w.value * T.value
|
|
850
862
|
});
|
|
@@ -856,11 +868,11 @@ function Yt(e) {
|
|
|
856
868
|
cancelAnimationFrame(f), f = requestAnimationFrame(se);
|
|
857
869
|
}
|
|
858
870
|
function se() {
|
|
859
|
-
t.value && (
|
|
871
|
+
t.value && (d.value = o.scrollTop?.value ?? t.value.scrollTop, u.value = d.value / T.value * w.value);
|
|
860
872
|
}
|
|
861
873
|
function Z(O) {
|
|
862
874
|
let L = "addEventListener";
|
|
863
|
-
O === "add" ? L = "addEventListener" : L = "removeEventListener", l.value?.[L]("pointerdown",
|
|
875
|
+
O === "add" ? L = "addEventListener" : L = "removeEventListener", l.value?.[L]("pointerdown", R, {
|
|
864
876
|
passive: !0
|
|
865
877
|
}), window[L]("pointermove", X, { passive: !0 }), window[L]("pointerup", N, { passive: !0 });
|
|
866
878
|
}
|
|
@@ -886,7 +898,7 @@ function Yt(e) {
|
|
|
886
898
|
}
|
|
887
899
|
Q.sheet.insertRule(p, re);
|
|
888
900
|
}
|
|
889
|
-
function
|
|
901
|
+
function P() {
|
|
890
902
|
t.value && l.value ? (A(
|
|
891
903
|
".hide-scrollbar",
|
|
892
904
|
"scrollbar-width: none; -ms-overflow-style: none;"
|
|
@@ -900,20 +912,20 @@ function Yt(e) {
|
|
|
900
912
|
g();
|
|
901
913
|
}, 100), b()) : console.error("useScrollBar:", "\u521D\u59CB\u5316\u5931\u8D25!", { containerEl: t, sliderEl: l });
|
|
902
914
|
}
|
|
903
|
-
return K(
|
|
904
|
-
q(),
|
|
915
|
+
return K(d, () => {
|
|
916
|
+
q(), c();
|
|
905
917
|
}), {
|
|
906
918
|
isScrollEnd: s,
|
|
907
919
|
isDragSlider: E,
|
|
908
920
|
offsetTop: u,
|
|
909
|
-
scrollTop:
|
|
921
|
+
scrollTop: d,
|
|
910
922
|
scrollable: y,
|
|
911
|
-
sliderPos:
|
|
912
|
-
init:
|
|
923
|
+
sliderPos: D,
|
|
924
|
+
init: P,
|
|
913
925
|
modifySliderEventListener: Z
|
|
914
926
|
};
|
|
915
927
|
}
|
|
916
|
-
const
|
|
928
|
+
const Xt = (e) => (ce("data-v-edec7292"), e = e(), de(), e), Zt = /* @__PURE__ */ Xt(() => /* @__PURE__ */ C("div", { class: "default-slider" }, null, -1)), Jt = /* @__PURE__ */ U({
|
|
917
929
|
__name: "ScrollBar",
|
|
918
930
|
props: {
|
|
919
931
|
containerEl: null,
|
|
@@ -922,12 +934,12 @@ const Gt = (e) => (ce("data-v-edec7292"), e = e(), de(), e), Xt = /* @__PURE__ *
|
|
|
922
934
|
performance: null
|
|
923
935
|
},
|
|
924
936
|
setup(e, { expose: t }) {
|
|
925
|
-
const l = e, n = !!it().default, o = h(null), a = S(() => l.containerEl), s =
|
|
937
|
+
const l = e, n = !!it().default, o = h(null), a = S(() => l.containerEl), s = Gt({
|
|
926
938
|
containerEl: a,
|
|
927
939
|
sliderEl: o,
|
|
928
940
|
autoHeight: n ? l.autoHeight : !0,
|
|
929
941
|
performance: l.performance
|
|
930
|
-
}), { scrollable:
|
|
942
|
+
}), { scrollable: c, isScrollEnd: f, sliderPos: v } = s, d = h(!1), i = l.autoHide ? S(() => d.value || !f.value) : S(() => c.value);
|
|
931
943
|
oe(() => {
|
|
932
944
|
_e(() => {
|
|
933
945
|
s.init();
|
|
@@ -936,39 +948,39 @@ const Gt = (e) => (ce("data-v-edec7292"), e = e(), de(), e), Xt = /* @__PURE__ *
|
|
|
936
948
|
s.modifySliderEventListener("remove");
|
|
937
949
|
});
|
|
938
950
|
function u() {
|
|
939
|
-
|
|
951
|
+
d.value = !0;
|
|
940
952
|
}
|
|
941
953
|
function r() {
|
|
942
|
-
|
|
954
|
+
d.value = !1;
|
|
943
955
|
}
|
|
944
|
-
return t({ uScrollBarReturn: s }), (m, E) => (I(), Me(
|
|
945
|
-
default:
|
|
956
|
+
return t({ uScrollBarReturn: s }), (m, E) => (I(), Me(Pe, null, {
|
|
957
|
+
default: He(() => [
|
|
946
958
|
ct(C("div", {
|
|
947
959
|
ref_key: "sliderRef",
|
|
948
960
|
ref: o,
|
|
949
961
|
class: "slider-wrapper",
|
|
950
962
|
onMouseenter: u,
|
|
951
963
|
onMouseleave: r,
|
|
952
|
-
style:
|
|
964
|
+
style: W($(v))
|
|
953
965
|
}, [
|
|
954
966
|
ye(m.$slots, "default", {}, () => [
|
|
955
|
-
|
|
967
|
+
Zt
|
|
956
968
|
], !0)
|
|
957
969
|
], 36), [
|
|
958
|
-
[dt, $(
|
|
970
|
+
[dt, $(i)]
|
|
959
971
|
])
|
|
960
972
|
]),
|
|
961
973
|
_: 3
|
|
962
974
|
}));
|
|
963
975
|
}
|
|
964
976
|
});
|
|
965
|
-
const
|
|
977
|
+
const Dl = /* @__PURE__ */ J(Jt, [["__scopeId", "data-v-edec7292"]]), el = (e) => (ce("data-v-9bfa9cae"), e = e(), de(), e), tl = { class: "pull-refresh" }, ll = {
|
|
966
978
|
key: 0,
|
|
967
979
|
class: "pull-arrow-circle"
|
|
968
|
-
},
|
|
980
|
+
}, nl = {
|
|
969
981
|
key: 0,
|
|
970
982
|
class: "box-load"
|
|
971
|
-
},
|
|
983
|
+
}, ol = { class: "left-load" }, sl = { class: "right-load" }, al = /* @__PURE__ */ el(() => /* @__PURE__ */ C("div", { class: "among-load" }, null, -1)), rl = { class: "pull-arrow" }, ul = { key: 1 }, il = /* @__PURE__ */ U({
|
|
972
984
|
__name: "PullRefresh",
|
|
973
985
|
props: {
|
|
974
986
|
refresh: null,
|
|
@@ -977,78 +989,78 @@ const $l = /* @__PURE__ */ J(Zt, [["__scopeId", "data-v-edec7292"]]), Jt = (e) =
|
|
|
977
989
|
pullRefreshContainer: null
|
|
978
990
|
},
|
|
979
991
|
setup(e) {
|
|
980
|
-
const t = e, l = 0.7, n = "#2EC1CC", o = h(-999), a = h(1), s = h(0),
|
|
992
|
+
const t = e, l = 0.7, n = "#2EC1CC", o = h(-999), a = h(1), s = h(0), c = h(0.3), f = h(!1), v = h(0), d = h(0), i = h(0), u = h(0), r = h(0), m = h(), E = S(() => t.scrollTop), y = S(() => ({
|
|
981
993
|
transition: `${u.value}ms`,
|
|
982
994
|
transform: `translate3d(0,${o.value}px, 0) scale(${a.value})`
|
|
983
995
|
})), w = S(() => ({
|
|
984
996
|
borderColor: n,
|
|
985
997
|
transition: u.value,
|
|
986
998
|
transform: `rotate(${100 + s.value}deg)`,
|
|
987
|
-
opacity:
|
|
999
|
+
opacity: c.value
|
|
988
1000
|
}));
|
|
989
|
-
K(r, (
|
|
990
|
-
|
|
991
|
-
}), K(
|
|
1001
|
+
K(r, (D) => {
|
|
1002
|
+
D === 0 && (o.value = -50, c.value = 0.3);
|
|
1003
|
+
}), K(d, (D) => {
|
|
992
1004
|
if (r.value === 2)
|
|
993
1005
|
return;
|
|
994
|
-
const
|
|
995
|
-
|
|
1006
|
+
const R = Math.pow(D, l);
|
|
1007
|
+
R === 0 && (o.value = -50), R <= 50 && R > 0 && (o.value = R - 45, s.value = Math.pow(R, 1.5), R > 15 ? f.value = !0 : f.value = !1), R > 50 && (o.value = 5, c.value = 1, r.value);
|
|
996
1008
|
});
|
|
997
|
-
const T = (
|
|
998
|
-
t.refreshOff || !t?.refresh || r.value !== 2 && E.value === 0 && (
|
|
1009
|
+
const T = (D) => {
|
|
1010
|
+
t.refreshOff || !t?.refresh || r.value !== 2 && E.value === 0 && (v.value === 0 && (v.value = D.touches[0].pageY), i.value = 0, M.value.style.transition = `${i.value}ms`, u.value = 0, d.value = D.touches[0].pageY - v.value, M.value.style.transform = `translate3d(0, ${Math.pow(d.value, l)}px, 0)`);
|
|
999
1011
|
}, F = () => {
|
|
1000
1012
|
if (t.refreshOff || !t?.refresh || r.value === 2)
|
|
1001
1013
|
return;
|
|
1002
|
-
|
|
1003
|
-
const
|
|
1004
|
-
M.value.style.transition = `${
|
|
1014
|
+
v.value = 0, i.value = 300;
|
|
1015
|
+
const D = Math.pow(d.value, l);
|
|
1016
|
+
M.value.style.transition = `${i.value}ms`, D > 50 ? (r.value = 2, d.value = Math.pow(50, 1 / l), M.value.style.transform = `translate3d(0, ${Math.pow(d.value, l)}px, 0)`, u.value = 300, t?.refresh && t?.refresh().then(() => {
|
|
1005
1017
|
m.value = "\u5237\u65B0\u6210\u529F";
|
|
1006
1018
|
}).catch(() => {
|
|
1007
1019
|
m.value = "\u5237\u65B0\u5931\u8D25";
|
|
1008
1020
|
}).finally(() => {
|
|
1009
1021
|
setTimeout(() => {
|
|
1010
|
-
r.value = 0,
|
|
1011
|
-
|
|
1022
|
+
r.value = 0, d.value = 0, M.value.style.transform = `translate3d(0, ${Math.pow(
|
|
1023
|
+
d.value,
|
|
1012
1024
|
l
|
|
1013
1025
|
)}px, 0)`, setTimeout(() => {
|
|
1014
1026
|
m.value = void 0;
|
|
1015
1027
|
}, u.value);
|
|
1016
1028
|
}, 600);
|
|
1017
|
-
})) : (
|
|
1029
|
+
})) : (d.value = 0, M.value.style.transform = `translate3d(0, ${Math.pow(d.value, l)}px, 0)`);
|
|
1018
1030
|
}, M = h(null);
|
|
1019
1031
|
return oe(() => {
|
|
1020
1032
|
M.value = document.querySelector(
|
|
1021
1033
|
t.pullRefreshContainer
|
|
1022
1034
|
), M.value.addEventListener("touchmove", T), M.value.addEventListener("touchend", F);
|
|
1023
|
-
}), (
|
|
1035
|
+
}), (D, R) => (I(), H("div", tl, [
|
|
1024
1036
|
C("div", {
|
|
1025
1037
|
class: "pull-refresh-box",
|
|
1026
|
-
style:
|
|
1038
|
+
style: W($(y))
|
|
1027
1039
|
}, [
|
|
1028
|
-
m.value ? (I(),
|
|
1029
|
-
r.value == 2 ? (I(),
|
|
1030
|
-
C("div",
|
|
1040
|
+
m.value ? (I(), H("div", ul, Fe(m.value), 1)) : (I(), H("div", ll, [
|
|
1041
|
+
r.value == 2 ? (I(), H("div", nl, [
|
|
1042
|
+
C("div", ol, [
|
|
1031
1043
|
C("div", {
|
|
1032
1044
|
class: "left-circle",
|
|
1033
|
-
style:
|
|
1045
|
+
style: W({ backgroundColor: n })
|
|
1034
1046
|
}, null, 4)
|
|
1035
1047
|
]),
|
|
1036
|
-
C("div",
|
|
1048
|
+
C("div", sl, [
|
|
1037
1049
|
C("div", {
|
|
1038
1050
|
class: "right-circle",
|
|
1039
|
-
style:
|
|
1051
|
+
style: W({ backgroundColor: n })
|
|
1040
1052
|
}, null, 4)
|
|
1041
1053
|
]),
|
|
1042
|
-
|
|
1043
|
-
])) : (I(),
|
|
1054
|
+
al
|
|
1055
|
+
])) : (I(), H("div", {
|
|
1044
1056
|
key: 1,
|
|
1045
1057
|
class: "pull-circle-line",
|
|
1046
|
-
style:
|
|
1058
|
+
style: W($(w))
|
|
1047
1059
|
}, [
|
|
1048
|
-
C("div",
|
|
1060
|
+
C("div", rl, [
|
|
1049
1061
|
C("div", {
|
|
1050
1062
|
class: Ae(["arrows", { opacity: f.value }]),
|
|
1051
|
-
style:
|
|
1063
|
+
style: W({ borderBottomColor: n })
|
|
1052
1064
|
}, null, 6)
|
|
1053
1065
|
])
|
|
1054
1066
|
], 4))
|
|
@@ -1057,10 +1069,10 @@ const $l = /* @__PURE__ */ J(Zt, [["__scopeId", "data-v-edec7292"]]), Jt = (e) =
|
|
|
1057
1069
|
]));
|
|
1058
1070
|
}
|
|
1059
1071
|
});
|
|
1060
|
-
const
|
|
1072
|
+
const cl = /* @__PURE__ */ J(il, [["__scopeId", "data-v-9bfa9cae"]]), dl = {
|
|
1061
1073
|
inheritAttrs: !1
|
|
1062
|
-
},
|
|
1063
|
-
...
|
|
1074
|
+
}, vl = /* @__PURE__ */ U({
|
|
1075
|
+
...dl,
|
|
1064
1076
|
__name: "VirtualList",
|
|
1065
1077
|
props: {
|
|
1066
1078
|
data: null,
|
|
@@ -1080,37 +1092,37 @@ const il = /* @__PURE__ */ J(ul, [["__scopeId", "data-v-9bfa9cae"]]), cl = {
|
|
|
1080
1092
|
}), {
|
|
1081
1093
|
list: a,
|
|
1082
1094
|
containerProps: s,
|
|
1083
|
-
wrapperProps:
|
|
1095
|
+
wrapperProps: c,
|
|
1084
1096
|
innerProps: f,
|
|
1085
|
-
getItemHeightData:
|
|
1086
|
-
scrollTop:
|
|
1097
|
+
getItemHeightData: v,
|
|
1098
|
+
scrollTop: d
|
|
1087
1099
|
} = o;
|
|
1088
1100
|
t({
|
|
1089
1101
|
vListReturn: o
|
|
1090
1102
|
});
|
|
1091
|
-
const
|
|
1092
|
-
return (u, r) => (I(),
|
|
1093
|
-
ft(
|
|
1103
|
+
const i = "virtualListWrapper" + new Date().getTime();
|
|
1104
|
+
return (u, r) => (I(), H(Ee, null, [
|
|
1105
|
+
ft(cl, {
|
|
1094
1106
|
refresh: e.refresh,
|
|
1095
1107
|
refreshOff: e.refreshOff,
|
|
1096
|
-
scrollTop: $(
|
|
1097
|
-
pullRefreshContainer: "#" +
|
|
1108
|
+
scrollTop: $(d),
|
|
1109
|
+
pullRefreshContainer: "#" + i
|
|
1098
1110
|
}, null, 8, ["refresh", "refreshOff", "scrollTop", "pullRefreshContainer"]),
|
|
1099
1111
|
C("div", {
|
|
1100
1112
|
class: "virtualListWrapper",
|
|
1101
|
-
id:
|
|
1113
|
+
id: i
|
|
1102
1114
|
}, [
|
|
1103
1115
|
C("div", ht({
|
|
1104
1116
|
onScrollPassive: r[0] || (r[0] = (...m) => $(s).onScroll && $(s).onScroll(...m)),
|
|
1105
1117
|
ref: $(s).ref,
|
|
1106
1118
|
class: "virtualList"
|
|
1107
1119
|
}, u.$attrs), [
|
|
1108
|
-
C("div", he(pe($(
|
|
1120
|
+
C("div", he(pe($(c))), [
|
|
1109
1121
|
C("div", he(pe($(f))), [
|
|
1110
|
-
(I(!0),
|
|
1122
|
+
(I(!0), H(Ee, null, pt($(a), ({ index: m, data: E }) => (I(), H("div", {
|
|
1111
1123
|
key: m,
|
|
1112
|
-
style:
|
|
1113
|
-
height: `${$(
|
|
1124
|
+
style: W({
|
|
1125
|
+
height: `${$(v)(m).height}px`,
|
|
1114
1126
|
display: "flex"
|
|
1115
1127
|
})
|
|
1116
1128
|
}, [
|
|
@@ -1126,7 +1138,7 @@ const il = /* @__PURE__ */ J(ul, [["__scopeId", "data-v-9bfa9cae"]]), cl = {
|
|
|
1126
1138
|
], 64));
|
|
1127
1139
|
}
|
|
1128
1140
|
});
|
|
1129
|
-
const Rl = /* @__PURE__ */ J(
|
|
1141
|
+
const Rl = /* @__PURE__ */ J(vl, [["__scopeId", "data-v-e0fb787f"]]), be = (e) => (ce("data-v-40e00f20"), e = e(), de(), e), fl = { style: { position: "absolute" } }, hl = /* @__PURE__ */ be(() => /* @__PURE__ */ C("div", { class: "wrapper" }, null, -1)), pl = ["width", "height"], ml = /* @__PURE__ */ be(() => /* @__PURE__ */ C("title", null, "logo", -1)), gl = /* @__PURE__ */ be(() => /* @__PURE__ */ C("g", {
|
|
1130
1142
|
id: "group-1",
|
|
1131
1143
|
stroke: "none",
|
|
1132
1144
|
"stroke-width": "1",
|
|
@@ -1138,10 +1150,10 @@ const Rl = /* @__PURE__ */ J(dl, [["__scopeId", "data-v-e0fb787f"]]), be = (e) =
|
|
|
1138
1150
|
id: "path-1",
|
|
1139
1151
|
fill: "#FFF"
|
|
1140
1152
|
})
|
|
1141
|
-
], -1)),
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
],
|
|
1153
|
+
], -1)), _l = [
|
|
1154
|
+
ml,
|
|
1155
|
+
gl
|
|
1156
|
+
], yl = /* @__PURE__ */ U({
|
|
1145
1157
|
__name: "Loading",
|
|
1146
1158
|
props: {
|
|
1147
1159
|
width: { default: "90" },
|
|
@@ -1154,31 +1166,31 @@ const Rl = /* @__PURE__ */ J(dl, [["__scopeId", "data-v-e0fb787f"]]), be = (e) =
|
|
|
1154
1166
|
"703ef503": l
|
|
1155
1167
|
}));
|
|
1156
1168
|
const l = `${t.duration}ms`;
|
|
1157
|
-
return (n, o) => (I(),
|
|
1158
|
-
|
|
1159
|
-
(I(),
|
|
1169
|
+
return (n, o) => (I(), H("div", fl, [
|
|
1170
|
+
hl,
|
|
1171
|
+
(I(), H("svg", {
|
|
1160
1172
|
style: { position: "relative" },
|
|
1161
1173
|
width: e.width,
|
|
1162
1174
|
height: e.height,
|
|
1163
1175
|
viewBox: "0 0 260 260",
|
|
1164
1176
|
version: "1.1",
|
|
1165
1177
|
xmlns: "http://www.w3.org/2000/svg"
|
|
1166
|
-
},
|
|
1178
|
+
}, _l, 8, pl))
|
|
1167
1179
|
]));
|
|
1168
1180
|
}
|
|
1169
1181
|
});
|
|
1170
|
-
const
|
|
1182
|
+
const Bl = /* @__PURE__ */ J(yl, [["__scopeId", "data-v-40e00f20"]]);
|
|
1171
1183
|
export {
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1184
|
+
Ll as DefaultLoading,
|
|
1185
|
+
Bl as Loading,
|
|
1186
|
+
cl as PullRefresh,
|
|
1187
|
+
Dl as ScrollBar,
|
|
1188
|
+
$l as SvgIcon,
|
|
1189
|
+
Ol as ToastCreator,
|
|
1178
1190
|
Rl as VirtualList,
|
|
1179
1191
|
qe as allSelectedKey,
|
|
1180
1192
|
Ft as closeDialogKey,
|
|
1181
|
-
|
|
1193
|
+
xl as dialogController,
|
|
1182
1194
|
Xe as isAllSelectedKey,
|
|
1183
1195
|
Ue as isSelectedKey,
|
|
1184
1196
|
Ye as selectAllKey,
|
|
@@ -1187,11 +1199,12 @@ export {
|
|
|
1187
1199
|
Ke as toggleKey,
|
|
1188
1200
|
Ze as unselectAllKey,
|
|
1189
1201
|
Ge as unselectKey,
|
|
1190
|
-
|
|
1202
|
+
Tl as useDelayLoad,
|
|
1203
|
+
Wt as useDelayLoadComp,
|
|
1191
1204
|
Je as useDragSelect,
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1205
|
+
Cl as useDragSelectByMobile,
|
|
1206
|
+
El as useDragSelectByPc,
|
|
1207
|
+
Sl as useSelectable,
|
|
1208
|
+
bl as useSelectableInjectors,
|
|
1196
1209
|
At as useVirtualList
|
|
1197
1210
|
};
|