@lazycatcloud/lzc-toolkit 0.0.51 → 0.0.52

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 CHANGED
@@ -1,106 +1,120 @@
1
- import { unref as y, getCurrentScope as Ce, onScopeDispose as Re, getCurrentInstance as Be, onMounted as te, nextTick as ne, ref as g, watch as $, shallowRef as Pe, computed as f, onUnmounted as ve, inject as T, provide as x, defineComponent as A, openBlock as I, createBlock as fe, Transition as pe, withCtx as he, createElementBlock as R, createElementVNode as H, withModifiers as $e, normalizeClass as Fe, renderSlot as oe, createCommentVNode as Ae, render as J, h as P, normalizeStyle as F, toDisplayString as Le, useSlots as De, withDirectives as We, vShow as Me, pushScopeId as ke, popScopeId as ze, toRef as Ve, mergeProps as je, normalizeProps as le, guardReactiveProps as se, Fragment as Ke, renderList as Ne } from "vue";
2
- var re;
3
- const L = typeof window < "u";
4
- L && ((re = window?.navigator) == null ? void 0 : re.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
5
- function X(t) {
6
- return typeof t == "function" ? t() : y(t);
1
+ import { unref as B, getCurrentScope as Ke, onScopeDispose as Qe, getCurrentInstance as Ue, onMounted as de, nextTick as fe, ref as w, watch as ne, shallowRef as qe, computed as S, onUnmounted as Te, inject as F, provide as $, defineComponent as Z, h as Q, render as ae, openBlock as k, createBlock as Oe, Transition as Re, withCtx as De, createElementBlock as J, createElementVNode as M, withModifiers as Ye, normalizeClass as Ge, renderSlot as he, createCommentVNode as Xe, normalizeStyle as le, toDisplayString as Je, useSlots as Ze, withDirectives as et, vShow as tt, pushScopeId as nt, popScopeId as lt, toRef as ot, mergeProps as rt, normalizeProps as me, guardReactiveProps as ge, Fragment as at, renderList as st } from "vue";
2
+ var ye;
3
+ const Ce = typeof window < "u";
4
+ Ce && ((ye = window?.navigator) == null ? void 0 : ye.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
5
+ function se(t) {
6
+ return typeof t == "function" ? t() : B(t);
7
7
  }
8
- function Qe(t, e) {
9
- function n(...o) {
10
- t(() => e.apply(this, o), { fn: e, thisArg: this, args: o });
8
+ function Be(t, e) {
9
+ function n(...l) {
10
+ t(() => e.apply(this, l), { fn: e, thisArg: this, args: l });
11
11
  }
12
12
  return n;
13
13
  }
14
- function Ue(t, e = {}) {
15
- let n, o;
16
- return (r) => {
17
- const l = X(t), c = X(e.maxWait);
18
- if (n && clearTimeout(n), l <= 0 || c !== void 0 && c <= 0)
19
- return o && (clearTimeout(o), o = null), r();
20
- c && !o && (o = setTimeout(() => {
21
- n && clearTimeout(n), o = null, r();
22
- }, c)), n = setTimeout(() => {
23
- o && clearTimeout(o), o = null, r();
24
- }, l);
14
+ function ut(t, e = {}) {
15
+ let n, l;
16
+ return (a) => {
17
+ const r = se(t), i = se(e.maxWait);
18
+ if (n && clearTimeout(n), r <= 0 || i !== void 0 && i <= 0)
19
+ return l && (clearTimeout(l), l = null), a();
20
+ i && !l && (l = setTimeout(() => {
21
+ n && clearTimeout(n), l = null, a();
22
+ }, i)), n = setTimeout(() => {
23
+ l && clearTimeout(l), l = null, a();
24
+ }, r);
25
25
  };
26
26
  }
27
- function qe(t) {
27
+ function it(t, e = !0, n = !0) {
28
+ let l = 0, o, a = !0;
29
+ const r = () => {
30
+ o && (clearTimeout(o), o = void 0);
31
+ };
32
+ return (m) => {
33
+ const p = se(t), d = Date.now() - l;
34
+ if (r(), p <= 0)
35
+ return l = Date.now(), m();
36
+ d > p && (n || !a) ? (l = Date.now(), m()) : e && (o = setTimeout(() => {
37
+ l = Date.now(), a = !0, r(), m();
38
+ }, p)), !n && !o && (o = setTimeout(() => a = !0, p)), a = !1;
39
+ };
40
+ }
41
+ function ct(t) {
28
42
  return t;
29
43
  }
30
- function Ye(t) {
31
- return Ce() ? (Re(t), !0) : !1;
44
+ function vt(t) {
45
+ return Ke() ? (Qe(t), !0) : !1;
46
+ }
47
+ function Ie(t, e = 200, n = {}) {
48
+ return Be(ut(e, n), t);
32
49
  }
33
- function me(t, e = 200, n = {}) {
34
- return Qe(Ue(e, n), t);
50
+ function be(t, e = 200, n = !1, l = !0) {
51
+ return Be(it(e, n, l), t);
35
52
  }
36
- function Ge(t, e = !0) {
37
- Be() ? te(t) : e ? t() : ne(t);
53
+ function dt(t, e = !0) {
54
+ Ue() ? de(t) : e ? t() : fe(t);
38
55
  }
39
- function ge(t) {
56
+ function Le(t) {
40
57
  var e;
41
- const n = X(t);
58
+ const n = se(t);
42
59
  return (e = n?.$el) != null ? e : n;
43
60
  }
44
- const Je = L ? window : void 0;
45
- L && window.document;
46
- L && window.navigator;
47
- L && window.location;
48
- function Xe(t, e = !1) {
49
- const n = g(), o = () => n.value = Boolean(t());
50
- return o(), Ge(o, e), n;
61
+ const ft = Ce ? window : void 0;
62
+ function ht(t, e = !1) {
63
+ const n = w(), l = () => n.value = Boolean(t());
64
+ return l(), dt(l, e), n;
51
65
  }
52
- const Z = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, ee = "__vueuse_ssr_handlers__";
53
- Z[ee] = Z[ee] || {};
54
- Z[ee];
55
- var ae = Object.getOwnPropertySymbols, Ze = Object.prototype.hasOwnProperty, et = Object.prototype.propertyIsEnumerable, tt = (t, e) => {
66
+ const ce = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, ve = "__vueuse_ssr_handlers__";
67
+ ce[ve] = ce[ve] || {};
68
+ ce[ve];
69
+ var Se = Object.getOwnPropertySymbols, pt = Object.prototype.hasOwnProperty, mt = Object.prototype.propertyIsEnumerable, gt = (t, e) => {
56
70
  var n = {};
57
- for (var o in t)
58
- Ze.call(t, o) && e.indexOf(o) < 0 && (n[o] = t[o]);
59
- if (t != null && ae)
60
- for (var o of ae(t))
61
- e.indexOf(o) < 0 && et.call(t, o) && (n[o] = t[o]);
71
+ for (var l in t)
72
+ pt.call(t, l) && e.indexOf(l) < 0 && (n[l] = t[l]);
73
+ if (t != null && Se)
74
+ for (var l of Se(t))
75
+ e.indexOf(l) < 0 && mt.call(t, l) && (n[l] = t[l]);
62
76
  return n;
63
77
  };
64
- function nt(t, e, n = {}) {
65
- const o = n, { window: s = Je } = o, r = tt(o, ["window"]);
66
- let l;
67
- const c = Xe(() => s && "ResizeObserver" in s), m = () => {
68
- l && (l.disconnect(), l = void 0);
69
- }, p = $(() => ge(t), (h) => {
70
- m(), c.value && s && h && (l = new ResizeObserver(e), l.observe(h, r));
71
- }, { immediate: !0, flush: "post" }), v = () => {
78
+ function yt(t, e, n = {}) {
79
+ const l = n, { window: o = ft } = l, a = gt(l, ["window"]);
80
+ let r;
81
+ const i = ht(() => o && "ResizeObserver" in o), m = () => {
82
+ r && (r.disconnect(), r = void 0);
83
+ }, p = ne(() => Le(t), (c) => {
84
+ m(), i.value && o && c && (r = new ResizeObserver(e), r.observe(c, a));
85
+ }, { immediate: !0, flush: "post" }), d = () => {
72
86
  m(), p();
73
87
  };
74
- return Ye(v), {
75
- isSupported: c,
76
- stop: v
88
+ return vt(d), {
89
+ isSupported: i,
90
+ stop: d
77
91
  };
78
92
  }
79
- function ot(t, e = { width: 0, height: 0 }, n = {}) {
80
- const { box: o = "content-box" } = n, s = g(e.width), r = g(e.height);
81
- return nt(t, ([l]) => {
82
- const c = o === "border-box" ? l.borderBoxSize : o === "content-box" ? l.contentBoxSize : l.devicePixelContentBoxSize;
83
- c ? (s.value = c.reduce((m, { inlineSize: p }) => m + p, 0), r.value = c.reduce((m, { blockSize: p }) => m + p, 0)) : (s.value = l.contentRect.width, r.value = l.contentRect.height);
84
- }, n), $(() => ge(t), (l) => {
85
- s.value = l ? e.width : 0, r.value = l ? e.height : 0;
93
+ function bt(t, e = { width: 0, height: 0 }, n = {}) {
94
+ const { box: l = "content-box" } = n, o = w(e.width), a = w(e.height);
95
+ return yt(t, ([r]) => {
96
+ const i = l === "border-box" ? r.borderBoxSize : l === "content-box" ? r.contentBoxSize : r.devicePixelContentBoxSize;
97
+ i ? (o.value = i.reduce((m, { inlineSize: p }) => m + p, 0), a.value = i.reduce((m, { blockSize: p }) => m + p, 0)) : (o.value = r.contentRect.width, a.value = r.contentRect.height);
98
+ }, n), ne(() => Le(t), (r) => {
99
+ o.value = r ? e.width : 0, a.value = r ? e.height : 0;
86
100
  }), {
87
- width: s,
88
- height: r
101
+ width: o,
102
+ height: a
89
103
  };
90
104
  }
91
- var ie;
105
+ var Ee;
92
106
  (function(t) {
93
107
  t.UP = "UP", t.RIGHT = "RIGHT", t.DOWN = "DOWN", t.LEFT = "LEFT", t.NONE = "NONE";
94
- })(ie || (ie = {}));
95
- var lt = Object.defineProperty, ue = Object.getOwnPropertySymbols, st = Object.prototype.hasOwnProperty, rt = Object.prototype.propertyIsEnumerable, ce = (t, e, n) => e in t ? lt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, at = (t, e) => {
108
+ })(Ee || (Ee = {}));
109
+ var St = Object.defineProperty, we = Object.getOwnPropertySymbols, Et = Object.prototype.hasOwnProperty, wt = Object.prototype.propertyIsEnumerable, _e = (t, e, n) => e in t ? St(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, _t = (t, e) => {
96
110
  for (var n in e || (e = {}))
97
- st.call(e, n) && ce(t, n, e[n]);
98
- if (ue)
99
- for (var n of ue(e))
100
- rt.call(e, n) && ce(t, n, e[n]);
111
+ Et.call(e, n) && _e(t, n, e[n]);
112
+ if (we)
113
+ for (var n of we(e))
114
+ wt.call(e, n) && _e(t, n, e[n]);
101
115
  return t;
102
116
  };
103
- const it = {
117
+ const xt = {
104
118
  easeInSine: [0.12, 0, 0.39, 0],
105
119
  easeOutSine: [0.61, 1, 0.88, 1],
106
120
  easeInOutSine: [0.37, 0, 0.63, 1],
@@ -126,183 +140,415 @@ const it = {
126
140
  easeOutBack: [0.34, 1.56, 0.64, 1],
127
141
  easeInOutBack: [0.68, -0.6, 0.32, 1.6]
128
142
  };
129
- at({
130
- linear: qe
131
- }, it);
132
- function ut(t, e) {
133
- const { scrollEndHook: n, itemHeight: o, overscan: s = 5 } = e, r = g(null), l = ot(r), c = g(!0), m = me(Q, 100);
143
+ _t({
144
+ linear: ct
145
+ }, xt);
146
+ function Tt(t, e) {
147
+ const { scrollEndHook: n, itemHeight: l, overscan: o = 5 } = e, a = w(null), r = bt(a), i = w(!0), m = Ie(ee, 100);
134
148
  let p;
135
- const v = Pe(t), h = g(0), i = g({ start: 0, end: 10 });
149
+ const d = qe(t), c = w(0), s = w({ start: 0, end: 10 });
136
150
  let u = 0;
137
- const E = g([]), b = f(() => {
138
- let { sum: a, height: d } = { sum: 0, height: 0 };
139
- return v.value.map((w, _) => (typeof o == "number" ? d = o : d = o(_), a += d, { height: d, sum: a }));
140
- }), N = f(() => V(i.value.start)), C = f(() => typeof o == "number" ? b.value.length * o : b.value[b.value.length - 1]?.sum || 0), D = f(() => {
141
- let a = E.value.length - s, d = Math.max(a - u, 0);
142
- return E.value.slice(d, a);
151
+ const b = w([]), _ = S(() => {
152
+ let { sum: f, height: y } = { sum: 0, height: 0 };
153
+ return d.value.map((I, C) => (typeof l == "number" ? y = l : y = l(C), f += y, { height: y, sum: f }));
154
+ }), E = S(() => V(s.value.start)), g = S(() => typeof l == "number" ? _.value.length * l : _.value[_.value.length - 1]?.sum || 0), R = S(() => {
155
+ let f = b.value.length - o, y = Math.max(f - u, 0);
156
+ return b.value.slice(y, f);
143
157
  });
144
- te(() => {
145
- }), ve(() => cancelAnimationFrame(p)), $(
146
- [l.width, l.height, v],
147
- ([a, d]) => {
148
- (a || d) && M();
158
+ de(() => {
159
+ }), Te(() => cancelAnimationFrame(p)), ne(
160
+ [r.width, r.height, d],
161
+ ([f, y]) => {
162
+ (f || y) && U();
149
163
  },
150
164
  { deep: !0 }
151
- ), $(h, () => {
152
- W(), m();
165
+ ), ne(c, () => {
166
+ L(), m();
153
167
  });
154
- function W() {
155
- c.value = !1;
156
- }
157
- function Q() {
158
- c.value = !0, n?.();
168
+ function L() {
169
+ i.value = !1;
159
170
  }
160
- function M() {
161
- cancelAnimationFrame(p), p = requestAnimationFrame(k);
171
+ function ee() {
172
+ i.value = !0, n?.();
162
173
  }
163
- function k() {
164
- if (r.value) {
165
- h.value = r.value.scrollTop, u = B();
166
- let a = z(h.value), d = a + u + s;
167
- a = a - s, a = a < 0 ? 0 : a, d = d > v.value.length ? v.value.length : d, i.value = { start: a, end: d }, E.value = v.value.slice(a, d).map((w, _) => ({
168
- data: w,
169
- index: _ + a
174
+ function U() {
175
+ cancelAnimationFrame(p), p = requestAnimationFrame(N);
176
+ }
177
+ function N() {
178
+ if (a.value) {
179
+ c.value = a.value.scrollTop, u = z();
180
+ let f = A(c.value), y = f + u + o;
181
+ f = f - o, f = f < 0 ? 0 : f, y = y > d.value.length ? d.value.length : y, s.value = { start: f, end: y }, b.value = d.value.slice(f, y).map((I, C) => ({
182
+ data: I,
183
+ index: C + f
170
184
  }));
171
185
  }
172
186
  }
173
- function z(a) {
174
- let d = 0, w = b.value.length - 1, _ = -1;
175
- for (; d <= w; ) {
176
- const S = Math.floor((d + w) / 2);
177
- b.value[S].sum >= a ? (_ = S, w = S - 1) : d = S + 1;
187
+ function A(f) {
188
+ let y = 0, I = _.value.length - 1, C = -1;
189
+ for (; y <= I; ) {
190
+ const O = Math.floor((y + I) / 2);
191
+ _.value[O].sum >= f ? (C = O, I = O - 1) : y = O + 1;
178
192
  }
179
- return Math.max(0, _);
193
+ return Math.max(0, C);
180
194
  }
181
- function B() {
182
- let a = 0, d = 0, w = U();
183
- for (let _ = w; _ < b.value.length && (a++, d += b.value[_].height, !(d >= l.height.value)); _++)
195
+ function z() {
196
+ let f = 0, y = 0, I = H();
197
+ for (let C = I; C < _.value.length && (f++, y += _.value[C].height, !(y >= r.height.value)); C++)
184
198
  ;
185
- return a;
199
+ return f;
186
200
  }
187
- function V(a) {
188
- if (typeof o == "number")
189
- return a * o;
190
- let d = b.value[a];
191
- return d ? d.sum - d.height : 0;
201
+ function V(f) {
202
+ if (typeof l == "number")
203
+ return f * l;
204
+ let y = _.value[f];
205
+ return y ? y.sum - y.height : 0;
192
206
  }
193
- function j(a) {
194
- return b.value[a] || { sum: 0, height: 0 };
207
+ function j(f) {
208
+ return _.value[f] || { sum: 0, height: 0 };
195
209
  }
196
- function U() {
197
- let a = i.value.start;
198
- return a >= s && (a += s), a;
210
+ function H() {
211
+ let f = s.value.start;
212
+ return f >= o && (f += o), f;
199
213
  }
200
- function q(a) {
201
- if (r.value) {
202
- const d = j(a);
203
- r.value.scrollTop = d.sum - d.height, k();
214
+ function q(f) {
215
+ if (a.value) {
216
+ const y = j(f);
217
+ a.value.scrollTop = y.sum - y.height, N();
204
218
  }
205
219
  }
206
- const Y = f(() => ({
220
+ const te = S(() => ({
207
221
  style: {
208
222
  width: "100%",
209
- height: `${C.value}px`,
210
- pointerEvents: c.value ? void 0 : "none"
223
+ height: `${g.value}px`,
224
+ pointerEvents: i.value ? void 0 : "none"
211
225
  }
212
- })), K = f(() => ({
226
+ })), K = S(() => ({
213
227
  style: {
214
- transform: `translate3d(0, ${N.value}px, 0)`,
228
+ transform: `translate3d(0, ${E.value}px, 0)`,
215
229
  "will-change": "transform"
216
230
  }
217
- })), G = {
231
+ })), Y = {
218
232
  overflowY: "auto"
219
233
  };
220
234
  return {
221
- list: E,
222
- visiableList: D,
235
+ list: b,
236
+ visiableList: R,
223
237
  getItemHeightData: j,
224
- getoffsetTopIndex: z,
225
- totalHeight: C,
226
- clientHeight: l.height,
238
+ getoffsetTopIndex: A,
239
+ totalHeight: g,
240
+ clientHeight: r.height,
227
241
  scrollTo: q,
228
- scrollTop: h,
229
- isScrollEnd: c,
242
+ scrollTop: c,
243
+ isScrollEnd: i,
230
244
  containerProps: {
231
- ref: r,
245
+ ref: a,
232
246
  onScroll: () => {
233
- M();
247
+ U();
234
248
  },
235
- style: G
249
+ style: Y
236
250
  },
237
- wrapperProps: Y,
251
+ wrapperProps: te,
238
252
  innerProps: K
239
253
  };
240
254
  }
241
- const be = Symbol(), ye = Symbol(), _e = Symbol(), Se = Symbol(), we = Symbol(), Oe = Symbol(), xe = Symbol(), Ee = Symbol(), Te = Symbol();
242
- function wt() {
243
- const { voidFn: t, boolFn: e, boolRef: n, arrayRef: o } = {
255
+ const He = Symbol(), $e = Symbol(), Ae = Symbol(), Pe = Symbol(), Fe = Symbol(), Me = Symbol(), ze = Symbol(), We = Symbol(), ke = Symbol();
256
+ function Mt() {
257
+ const { voidFn: t, boolFn: e, boolRef: n, arrayRef: l } = {
244
258
  voidFn: (u) => {
245
259
  },
246
260
  boolFn: (u) => !1,
247
- boolRef: f(() => !1),
248
- arrayRef: f(() => [])
249
- }, s = T(Se, o), r = T(_e, e), l = T(Ee, n), c = T(ye, t), m = T(be, t), p = T(we, t), v = T(Oe, t), h = T(xe, t), i = T(Te, t);
261
+ boolRef: S(() => !1),
262
+ arrayRef: S(() => [])
263
+ }, o = F(Pe, l), a = F(Ae, e), r = F(We, n), i = F($e, t), m = F(He, t), p = F(Fe, t), d = F(Me, t), c = F(ze, t), s = F(ke, t);
250
264
  return {
251
- selected: s,
252
- isSelected: r,
253
- isAllSelected: l,
254
- toggle: c,
265
+ selected: o,
266
+ isSelected: a,
267
+ isAllSelected: r,
268
+ toggle: i,
255
269
  toggleAll: m,
256
270
  select: p,
257
- selectAll: v,
258
- unselect: h,
259
- unselectAll: i
271
+ selectAll: d,
272
+ unselect: c,
273
+ unselectAll: s
260
274
  };
261
275
  }
262
- function Ot(t, e) {
263
- const n = g({}), o = f(() => t.value.filter((i) => n.value[i[e]])), s = f(() => o.value.length != 0 && Object.keys(n.value).length == t.value.length);
264
- function r() {
265
- t.value.forEach((i) => {
266
- n.value[i[e]] = !0;
276
+ function zt(t, e) {
277
+ const n = w({}), l = S(() => t.value.filter((s) => n.value[s[e]])), o = S(() => l.value.length != 0 && Object.keys(n.value).length == t.value.length);
278
+ function a() {
279
+ t.value.forEach((s) => {
280
+ n.value[s[e]] = !0;
267
281
  });
268
282
  }
269
- function l() {
283
+ function r() {
270
284
  n.value = {};
271
285
  }
272
- function c(i) {
273
- i.forEach((u) => {
286
+ function i(s) {
287
+ s.forEach((u) => {
274
288
  n.value[u[e]] || (n.value[u[e]] = !0);
275
289
  });
276
290
  }
277
- function m(i) {
278
- i.forEach((u) => {
291
+ function m(s) {
292
+ s.forEach((u) => {
279
293
  n.value[u[e]] && delete n.value[u[e]];
280
294
  });
281
295
  }
282
- function p(i) {
283
- return !!n.value[i[e]];
296
+ function p(s) {
297
+ return !!n.value[s[e]];
284
298
  }
285
- function v(i) {
286
- i.forEach((u) => {
299
+ function d(s) {
300
+ s.forEach((u) => {
287
301
  p(u) ? delete n.value[u[e]] : n.value[u[e]] = !0;
288
302
  });
289
303
  }
290
- function h() {
291
- s.value ? l() : r();
304
+ function c() {
305
+ o.value ? r() : a();
292
306
  }
293
- return x(be, h), x(ye, v), x(_e, p), x(Se, o), x(we, c), x(Oe, r), x(xe, m), x(Ee, s), x(Te, l), {
294
- selected: o,
295
- select: c,
296
- selectAll: r,
307
+ return $(He, c), $($e, d), $(Ae, p), $(Pe, l), $(Fe, i), $(Me, a), $(ze, m), $(We, o), $(ke, r), {
308
+ selected: l,
309
+ select: i,
310
+ selectAll: a,
297
311
  unselect: m,
298
- unselectAll: l,
299
- toggle: v,
300
- toggleAll: h,
312
+ unselectAll: r,
313
+ toggle: d,
314
+ toggleAll: c,
301
315
  isSelected: p,
302
- isAllSelected: s
316
+ isAllSelected: o
317
+ };
318
+ }
319
+ function ie(t) {
320
+ return () => {
321
+ console.debug(`\u9ED8\u8BA4${t}\u65B9\u6CD5,\u9700\u8981\u81EA\u5B9A\u4E49\u751F\u6548`);
322
+ };
323
+ }
324
+ function Ne({
325
+ attribute: t,
326
+ selectWay: e = "colum",
327
+ scrollOptions: n = {},
328
+ getSelectMap: l = () => ({})
329
+ }) {
330
+ const {
331
+ select: o = ie("\u9009\u62E9"),
332
+ unselect: a = ie("\u53D6\u6D88\u9009\u62E9"),
333
+ unselectAll: r = ie("\u53D6\u6D88\u5168\u9009")
334
+ } = l();
335
+ let i = {};
336
+ const m = S(
337
+ () => be(e === "colum" ? W : oe, 50)
338
+ ), p = /* @__PURE__ */ new Set(), d = w(!0), c = w(), s = w(!1), u = w({ x: 0, y: 0 }), b = w({ x: 0, y: 0, scrollTop: 0 }), _ = new ResizeObserver(
339
+ (v) => E.value = v[0].target.getBoundingClientRect()
340
+ ), E = w({}), g = w({
341
+ top: 0,
342
+ height: 0,
343
+ sync(v = !1) {
344
+ g.value.top = c.value?.scrollTop || 0, v && (g.value.height = c.value?.scrollHeight || 0);
345
+ }
346
+ }), R = S(() => s.value ? {
347
+ left: Math.min(u.value.x, b.value.x) - E.value.left,
348
+ top: Math.min(u.value.y, b.value.y) - E.value.top,
349
+ width: Math.abs(u.value.x - b.value.x),
350
+ height: Math.abs(u.value.y - b.value.y)
351
+ } : { left: 0, top: 0, width: 0, height: 0 }), { margin: L = 50, startSpeed: ee = 30, maxSpeed: U = 30 } = n;
352
+ let N;
353
+ const A = L, z = ee, V = U, j = (v) => v ** 1;
354
+ let H = 0;
355
+ function q(v) {
356
+ if (cancelAnimationFrame(N), H = te(v), H = Math.max(
357
+ Math.min(H, V),
358
+ -V
359
+ ), H !== 0) {
360
+ const h = c.value;
361
+ if (!h || !s.value)
362
+ return;
363
+ const D = g.value.height - E.value.height;
364
+ let x = g.value.top + Number(H);
365
+ x = Math.min(Math.max(0, x), D), h.scrollTop = x, Y(), N = requestAnimationFrame(() => q(v));
366
+ }
367
+ }
368
+ function te(v) {
369
+ if (c.value) {
370
+ const D = E.value, x = D.bottom - v;
371
+ if (x < A)
372
+ return z * j(1 - x / A);
373
+ const P = v - D.top;
374
+ if (P < A)
375
+ return -z * j(1 - P / A);
376
+ }
377
+ return 0;
378
+ }
379
+ function K(v) {
380
+ const h = { ...R.value, right: 0, bottom: 0 };
381
+ return h.left += E.value.left, h.top += E.value.top - g.value.top, h.right = h.width + h.left, h.bottom = h.height + h.top, h.left < v.right && h.right > v.left && h.top < v.bottom && h.bottom > v.top;
382
+ }
383
+ function Y() {
384
+ g.value.sync();
385
+ const { top: v, height: h } = g.value;
386
+ b.value.y = Math.min(
387
+ h + E.value.top,
388
+ b.value.y + v - b.value.scrollTop
389
+ ), b.value.scrollTop = v;
390
+ }
391
+ function f(v, h, D = "dynamic-styles") {
392
+ let x = document.getElementById(D);
393
+ x || (x = document.createElement("style"), x.id = D, document.head.appendChild(x));
394
+ const P = x.sheet.cssRules, X = P.length, je = `${v} { ${h} }`;
395
+ for (let ue = 0; ue < X; ue++) {
396
+ const pe = P[ue];
397
+ if (pe.selectorText === v && pe.style.cssText === h)
398
+ return;
399
+ }
400
+ x.sheet.insertRule(je, X);
401
+ }
402
+ function y(v, h) {
403
+ d.value = !0, s.value = !0, g.value.height ? g.value.sync() : g.value.sync(!0), u.value.x = v, u.value.y = h + g.value.top, b.value.x = u.value.x, b.value.y = u.value.y, c.value?.classList.add("disable-scroll-behavior"), p.clear();
404
+ }
405
+ function I(v, h, D) {
406
+ !s.value || (d.value && e === "colum" && !T() && (r(), d.value = !1), D?.(), q(h), b.value.x = Math.max(v, E.value.left), b.value.y = Math.min(
407
+ h + g.value.top,
408
+ g.value.height + E.value.top
409
+ ), b.value.scrollTop = g.value.top, m.value());
410
+ }
411
+ function C() {
412
+ s.value = !1, c.value?.classList.remove("disable-scroll-behavior");
413
+ }
414
+ function O() {
415
+ !s.value || (H || Y(), m.value());
416
+ }
417
+ function T() {
418
+ if (!s.value)
419
+ return !1;
420
+ const { width: v, height: h } = R.value;
421
+ return !(Math.max(v, h) > 5);
422
+ }
423
+ function G() {
424
+ T() && r();
425
+ }
426
+ function W() {
427
+ T() || c.value?.querySelectorAll(`[${t}]`).forEach((v) => {
428
+ i[`${t}`] = v.getAttribute(`${t}`), K(v.getBoundingClientRect()) ? o([i]) : a([i]);
429
+ });
430
+ }
431
+ function oe() {
432
+ const v = [];
433
+ let h = null, D = 0;
434
+ c.value?.querySelectorAll(`[${t}]`).forEach((x, P) => {
435
+ const X = x.getAttribute(`${t}`);
436
+ v.push(X), K(x.getBoundingClientRect()) ? (h === null && (h = P), h = Math.min(h, P), D = Math.max(D, P)) : (i[`${t}`] = X, p.has(X) && a([i]));
437
+ });
438
+ for (let x = h; x < D + 1; x++)
439
+ i[`${t}`] = v[x], o([i]), p.add(v[x]);
440
+ }
441
+ function re(v) {
442
+ return !v?.value || (c.value = v.value, !c?.value) ? !1 : (_.observe(c.value), f(
443
+ ".disable-scroll-behavior",
444
+ "scroll-behavior: unset !important;"
445
+ ), !0);
446
+ }
447
+ return {
448
+ init: re,
449
+ dragStart: y,
450
+ dragMove: I,
451
+ dragEnd: C,
452
+ onScroll: O,
453
+ isSingleClick: T,
454
+ cancelSelectAllBySingleClick: G,
455
+ selectFn: m,
456
+ selectRange: R,
457
+ isPressing: s,
458
+ containerEl: c,
459
+ observer: _
303
460
  };
304
461
  }
305
- const ct = Symbol(), dt = /* @__PURE__ */ A({
462
+ function Wt(t) {
463
+ const e = Ne(t), { observer: n, selectRange: l } = e, {
464
+ onScroll: o,
465
+ dragStart: a,
466
+ dragMove: r,
467
+ dragEnd: i,
468
+ cancelSelectAllBySingleClick: m
469
+ } = e, p = S(() => ({
470
+ left: `${l.value.left}px`,
471
+ top: `${l.value.top}px`,
472
+ width: `${l.value.width}px`,
473
+ height: `${l.value.height}px`
474
+ })), d = Z({
475
+ render() {
476
+ return Q("div", {
477
+ id: "selectBoxEl",
478
+ class: "absolute z-50 bg-blue-200 opacity-50",
479
+ style: p.value
480
+ });
481
+ }
482
+ });
483
+ function c(E) {
484
+ E.button === 0 && a(E.x, E.y);
485
+ }
486
+ function s(E) {
487
+ r(E.x, E.y);
488
+ }
489
+ function u(E) {
490
+ E.composedPath().some((R) => R?.getAttribute?.(t.attribute)) || m(), i();
491
+ }
492
+ function b(E) {
493
+ try {
494
+ if (!e.init(E))
495
+ throw "\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";
496
+ if (!e.containerEl?.value)
497
+ return !1;
498
+ ae(Q(d), e.containerEl.value), e.containerEl.value?.addEventListener("scroll", o), e.containerEl.value?.addEventListener("mousedown", c), window.addEventListener("mousemove", s), window.addEventListener("mouseup", u);
499
+ } catch (g) {
500
+ console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25", g);
501
+ }
502
+ }
503
+ function _() {
504
+ n.disconnect(), e.containerEl.value?.removeEventListener("scroll", o), e.containerEl.value?.removeEventListener("mousedown", c), window.removeEventListener("mousemove", s), window.removeEventListener("mouseup", u);
505
+ }
506
+ return { init: b, unMount: _ };
507
+ }
508
+ function kt(t, e, n = 600) {
509
+ const l = Ne({
510
+ ...t,
511
+ selectWay: "row",
512
+ scrollOptions: {
513
+ startSpeed: 5,
514
+ maxSpeed: 5
515
+ }
516
+ }), { observer: o } = l, { onScroll: a, dragStart: r, dragMove: i, dragEnd: m, selectFn: p } = l;
517
+ let d;
518
+ function c() {
519
+ clearTimeout(d);
520
+ }
521
+ function s(g) {
522
+ c(), d = setTimeout(() => {
523
+ const { clientX: R, clientY: L } = g.targetTouches[0];
524
+ r(R, L), e?.(), p.value(), g.preventDefault();
525
+ }, n);
526
+ }
527
+ function u(g) {
528
+ c();
529
+ const { clientX: R, clientY: L } = g.targetTouches[0];
530
+ i(R, L, () => g.preventDefault());
531
+ }
532
+ function b() {
533
+ c(), m();
534
+ }
535
+ function _(g) {
536
+ try {
537
+ if (!l.init(g))
538
+ throw "\u521D\u59CB\u5316\u5931\u8D25,Ref\u5143\u7D20\u4E0D\u6B63\u786E";
539
+ if (!l.containerEl?.value)
540
+ return !1;
541
+ l.containerEl.value?.addEventListener("scroll", a), l.containerEl.value?.addEventListener("touchstart", s), l.containerEl.value?.addEventListener("touchmove", u), window.addEventListener("touchcancel", b), window.addEventListener("touchend", b);
542
+ } catch (R) {
543
+ console.error("\u62D6\u9009\u529F\u80FD\u521D\u59CB\u5316\u5931\u8D25", R);
544
+ }
545
+ }
546
+ function E() {
547
+ o.disconnect(), l.containerEl.value?.removeEventListener("scroll", a), l.containerEl.value?.removeEventListener("touchstart", s), l.containerEl.value?.removeEventListener("touchmove", u), window.removeEventListener("touchcancel", b), window.removeEventListener("touchEnd", b);
548
+ }
549
+ return { init: _, unMount: E };
550
+ }
551
+ const Ot = Symbol(), Rt = /* @__PURE__ */ Z({
306
552
  __name: "Dialog",
307
553
  props: {
308
554
  visiable: { type: Boolean, default: !1 },
@@ -311,64 +557,64 @@ const ct = Symbol(), dt = /* @__PURE__ */ A({
311
557
  },
312
558
  emits: ["update:visiable"],
313
559
  setup(t, { emit: e }) {
314
- const n = t, o = () => {
560
+ const n = t, l = () => {
315
561
  n.closeOnClickOverlay && e("update:visiable", !1);
316
562
  };
317
- return x(ct, () => e("update:visiable", !1)), (s, r) => (I(), fe(pe, { name: "modal" }, {
318
- default: he(() => [
319
- t.visiable ? (I(), R("div", {
563
+ return $(Ot, () => e("update:visiable", !1)), (o, a) => (k(), Oe(Re, { name: "modal" }, {
564
+ default: De(() => [
565
+ t.visiable ? (k(), J("div", {
320
566
  key: 0,
321
- onClick: o,
322
- class: "modal absolute inset-0 bottom-0 flex bg-stone-900 bg-opacity-50 z-[999]"
567
+ onClick: l,
568
+ class: "modal absolute left-0 right-0 top-0 bottom-0 flex bg-stone-900 bg-opacity-50 z-[999]"
323
569
  }, [
324
- H("div", {
325
- onClick: r[0] || (r[0] = $e(() => {
570
+ M("div", {
571
+ onClick: a[0] || (a[0] = Ye(() => {
326
572
  }, ["stop"])),
327
- class: Fe(["dialog m-auto flex flex-col", t.dialogClass])
573
+ class: Ge(["dialog m-auto flex flex-col", t.dialogClass])
328
574
  }, [
329
- oe(s.$slots, "default")
575
+ he(o.$slots, "default")
330
576
  ], 2)
331
- ])) : Ae("", !0)
577
+ ])) : Xe("", !0)
332
578
  ]),
333
579
  _: 3
334
580
  }));
335
581
  }
336
582
  });
337
- function xt(t) {
338
- function e(n, o) {
339
- const s = document.createElement("div"), r = {
583
+ function Nt(t) {
584
+ function e(n, l) {
585
+ const o = document.createElement("div"), a = {
340
586
  setup() {
341
- return () => P(
342
- dt,
587
+ return () => Q(
588
+ Rt,
343
589
  {
344
590
  visiable: !0,
345
591
  "onUpdate:visiable": () => {
346
- s?.remove();
592
+ o?.remove();
347
593
  },
348
594
  ...t
349
595
  },
350
596
  {
351
- default: () => P(n, o)
597
+ default: () => Q(n, l)
352
598
  }
353
599
  );
354
600
  }
355
601
  };
356
- return document.body.appendChild(s), J(P(r), s), {
357
- close: () => s?.remove()
602
+ return document.body.appendChild(o), ae(Q(a), o), {
603
+ close: () => o?.remove()
358
604
  };
359
605
  }
360
606
  return {
361
607
  create: e
362
608
  };
363
609
  }
364
- const vt = /* @__PURE__ */ A({
610
+ const Dt = /* @__PURE__ */ Z({
365
611
  __name: "Toast",
366
612
  props: {
367
613
  message: null,
368
614
  position: null
369
615
  },
370
616
  setup(t) {
371
- const e = t, n = g(), o = g(), s = g(), r = f(() => {
617
+ const e = t, n = w(), l = w(), o = w(), a = S(() => {
372
618
  switch (e.position) {
373
619
  case "top":
374
620
  return 10;
@@ -377,14 +623,14 @@ const vt = /* @__PURE__ */ A({
377
623
  case "bottom":
378
624
  return 85;
379
625
  }
380
- }), l = f(() => ({
626
+ }), r = S(() => ({
381
627
  position: "absolute",
382
628
  borderRadius: "10px",
383
629
  backgroundColor: "rgba(0, 0, 0, 0.8)",
384
630
  padding: "14px 19px",
385
- top: `calc(${r.value}% - ${s.value}px)`,
386
- left: `calc(50% - ${o.value}px)`
387
- })), c = f(() => ({
631
+ top: `calc(${a.value}% - ${o.value}px)`,
632
+ left: `calc(50% - ${l.value}px)`
633
+ })), i = S(() => ({
388
634
  width: "fit-content",
389
635
  display: "flex",
390
636
  justifyContent: "center",
@@ -392,48 +638,48 @@ const vt = /* @__PURE__ */ A({
392
638
  color: "white",
393
639
  fontSize: "14px"
394
640
  }));
395
- return ne(() => {
396
- o.value = n.value.offsetWidth / 2, s.value = n.value.offsetHeight / 2;
397
- }), (m, p) => (I(), R("div", {
641
+ return fe(() => {
642
+ l.value = n.value.offsetWidth / 2, o.value = n.value.offsetHeight / 2;
643
+ }), (m, p) => (k(), J("div", {
398
644
  id: "toastWrapper",
399
645
  ref_key: "toastWrapper",
400
646
  ref: n,
401
647
  class: "toastWrapper",
402
- style: F([y(l), { zIndex: 9999 }])
648
+ style: le([B(r), { zIndex: 9999 }])
403
649
  }, [
404
- H("div", {
405
- style: F(y(c))
650
+ M("div", {
651
+ style: le(B(i))
406
652
  }, [
407
- H("span", null, Le(t.message), 1)
653
+ M("span", null, Je(t.message), 1)
408
654
  ], 4)
409
655
  ], 4));
410
656
  }
411
- }), de = {
657
+ }), xe = {
412
658
  message: "\u61D2\u732B\u4E91 Yes!!!",
413
659
  position: "middle",
414
660
  duration: 1500
415
661
  };
416
- class Et {
662
+ class Vt {
417
663
  options;
418
664
  container;
419
665
  constructor(e) {
420
666
  this.options = e, this.container = document.createElement("div");
421
667
  }
422
668
  present() {
423
- const e = P(P(vt), { ...de, ...this.options });
424
- J(e, this.container), document.body.insertBefore(this.container, document.body.firstChild);
425
- const n = this.options.duration || de.duration;
669
+ const e = Q(Q(Dt), { ...xe, ...this.options });
670
+ ae(e, this.container), document.body.insertBefore(this.container, document.body.firstChild);
671
+ const n = this.options.duration || xe.duration;
426
672
  setTimeout(() => {
427
673
  this.dismiss();
428
674
  }, n);
429
675
  }
430
676
  dismiss() {
431
677
  this.container && (this.container.querySelector("#toastWrapper")?.classList.add("animate-toastAnimation"), setTimeout(() => {
432
- this.container && (J(null, this.container), document.body.removeChild(this.container));
678
+ this.container && (ae(null, this.container), document.body.removeChild(this.container));
433
679
  }, 500));
434
680
  }
435
681
  }
436
- const ft = ["xlink:href", "fill", "color"], Tt = /* @__PURE__ */ A({
682
+ const Ct = ["xlink:href", "fill", "color"], jt = /* @__PURE__ */ Z({
437
683
  __name: "SvgIcon",
438
684
  props: {
439
685
  name: null,
@@ -443,127 +689,132 @@ const ft = ["xlink:href", "fill", "color"], Tt = /* @__PURE__ */ A({
443
689
  height: null
444
690
  },
445
691
  setup(t) {
446
- const e = t, n = f(() => `#${e.prefix}-${e.name}`), o = f(() => ({
692
+ const e = t, n = S(() => `#${e.prefix}-${e.name}`), l = S(() => ({
447
693
  width: `${e.width ?? e.height}px`,
448
694
  height: `${e.height ?? e.width}px`,
449
695
  aspectRatio: e.width && e.height ? void 0 : "1/1"
450
696
  }));
451
- return (s, r) => (I(), R("svg", {
697
+ return (o, a) => (k(), J("svg", {
452
698
  "aria-hidden": "",
453
- style: F(y(o))
699
+ style: le(B(l))
454
700
  }, [
455
- H("use", {
456
- "xlink:href": y(n),
701
+ M("use", {
702
+ "xlink:href": B(n),
457
703
  fill: t.color,
458
704
  color: t.color
459
- }, null, 8, ft)
705
+ }, null, 8, Ct)
460
706
  ], 4));
461
707
  }
462
708
  });
463
- function pt(t) {
709
+ function Bt(t) {
464
710
  const {
465
711
  containerEl: e,
466
712
  sliderEl: n,
467
- autoHeight: o,
468
- performance: s = {},
469
- maxHeightRatio: r = 0.9
470
- } = t, l = g(!0), c = me(V, 100);
713
+ autoHeight: l,
714
+ performance: o = {},
715
+ maxHeightRatio: a = 0.9
716
+ } = t, r = w(!0), i = Ie(V, 100);
471
717
  let m, p = "";
472
- const v = g(0), h = g(0), i = g(0), u = g({
718
+ const d = w(0), c = w(0), s = w(0), u = w({
473
719
  top: 0,
474
720
  scrollTop: 0,
475
721
  scrollHeight: 0,
476
722
  clientHeight: 0
477
- }), E = g({
723
+ }), b = w({
478
724
  clientHeight: 0
479
- }), b = f(() => !!h.value), N = f(() => u.value.scrollHeight > u.value.clientHeight), C = f(() => u.value.clientHeight - E.value.clientHeight), D = f(() => u.value.scrollHeight - u.value.clientHeight), W = f(() => Math.max(
725
+ }), _ = S(() => !!c.value), E = S(() => u.value.scrollHeight > u.value.clientHeight), g = S(() => u.value.clientHeight - b.value.clientHeight), R = S(() => u.value.scrollHeight - u.value.clientHeight), L = S(() => Math.max(
480
726
  u.value.clientHeight / u.value.scrollHeight,
481
727
  0.05
482
- )), Q = f(() => W.value > r ? 0 : W.value * u.value.clientHeight), M = f(() => ({
728
+ )), ee = S(() => L.value > a ? 0 : L.value * u.value.clientHeight), U = S(() => ({
483
729
  willChange: "transform",
484
- transform: `translate3d(0,${i.value}px,0)`,
485
- height: o ? `${Q.value}px` : void 0
730
+ transform: `translate3d(0,${s.value}px,0)`,
731
+ height: l ? `${ee.value}px` : void 0
486
732
  }));
487
- function k(S) {
488
- B(), h.value = S.clientY - n.value.getBoundingClientRect().top || 1, p = getComputedStyle(e.value).scrollBehavior, p === "smooth" && (e.value.style.scrollBehavior = "unset");
733
+ function N(O) {
734
+ z(), c.value = O.clientY - n.value.getBoundingClientRect().top || 1, p = getComputedStyle(e.value).scrollBehavior, p === "smooth" && (e.value.style.scrollBehavior = "unset");
489
735
  }
490
- function z() {
491
- e.value.style.scrollBehavior = p, h.value = 0, c();
736
+ function A() {
737
+ e.value.style.scrollBehavior = p, c.value = 0, i();
492
738
  }
493
- function B() {
494
- l.value = !1;
739
+ function z() {
740
+ r.value = !1;
495
741
  }
496
742
  function V() {
497
- b.value || (l.value = !0);
743
+ _.value || (r.value = !0);
498
744
  }
499
- function j(S) {
500
- if (!b.value)
745
+ function j(O) {
746
+ if (!_.value)
501
747
  return;
502
- let O = S.clientY - u.value.top - h.value;
503
- O < 0 ? i.value = 0 : O >= C.value ? i.value = C.value : i.value = O, e.value.scrollTo({
504
- top: i.value / C.value * D.value
748
+ let T = O.clientY - u.value.top - c.value;
749
+ T < 0 ? s.value = 0 : T >= g.value ? s.value = g.value : s.value = T, e.value.scrollTo({
750
+ top: s.value / g.value * R.value
505
751
  });
506
752
  }
507
- function U() {
508
- b.value || q();
753
+ function H() {
754
+ _.value || q();
509
755
  }
510
756
  function q() {
511
- cancelAnimationFrame(m), m = requestAnimationFrame(Y);
757
+ cancelAnimationFrame(m), m = requestAnimationFrame(te);
512
758
  }
513
- function Y() {
514
- e.value && (v.value = s.scrollTop?.value ?? e.value.scrollTop, i.value = v.value / D.value * C.value);
759
+ function te() {
760
+ e.value && (d.value = o.scrollTop?.value ?? e.value.scrollTop, s.value = d.value / R.value * g.value);
515
761
  }
516
- function K(S) {
517
- let O = "addEventListener";
518
- S === "add" ? O = "addEventListener" : O = "removeEventListener", n.value?.[O]("pointerdown", k, {
762
+ function K(O) {
763
+ let T = "addEventListener";
764
+ O === "add" ? T = "addEventListener" : T = "removeEventListener", n.value?.[T]("pointerdown", N, {
519
765
  passive: !0
520
- }), window[O]("pointermove", j, { passive: !0 }), window[O]("pointerup", z, { passive: !0 });
766
+ }), window[T]("pointermove", j, { passive: !0 }), window[T]("pointerup", A, { passive: !0 });
521
767
  }
522
- const G = new MutationObserver((S) => {
523
- S.map((Ie) => Ie.oldValue).join().includes("height") && a();
768
+ const Y = new MutationObserver((O) => {
769
+ O.map((G) => G.oldValue).join().includes("height") && f();
524
770
  });
525
- function a() {
771
+ function f() {
526
772
  u.value.top = e.value?.getBoundingClientRect().top ?? 0, u.value.scrollHeight = e.value?.scrollHeight ?? 0, u.value.clientHeight = e.value?.clientHeight ?? 0;
527
773
  }
528
- function d() {
529
- B(), setTimeout(() => {
530
- E.value.clientHeight = n.value?.clientHeight ?? 0, V();
774
+ function y() {
775
+ z(), setTimeout(() => {
776
+ b.value.clientHeight = n.value?.clientHeight ?? 0, V();
531
777
  }, 150);
532
778
  }
533
- function w() {
534
- document.styleSheets[0].insertRule(
535
- ".hide-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }",
536
- 0
537
- ), document.styleSheets[0].insertRule(
538
- ".hide-scrollbar::-webkit-scrollbar{ display: none }",
539
- 0
540
- ), e.value?.classList.add("hide-scrollbar");
779
+ function I(O, T, G = "dynamic-styles") {
780
+ let W = document.getElementById(G);
781
+ W || (W = document.createElement("style"), W.id = G, document.head.appendChild(W));
782
+ const oe = W.sheet.cssRules, re = oe.length, v = `${O} { ${T} }`;
783
+ for (let h = 0; h < re; h++) {
784
+ const D = oe[h];
785
+ if (D.selectorText === O && D.style.cssText === T)
786
+ return;
787
+ }
788
+ W.sheet.insertRule(v, re);
541
789
  }
542
- function _() {
543
- e.value && n.value ? (w(), e.value.addEventListener("scroll", U, {
790
+ function C() {
791
+ e.value && n.value ? (I(
792
+ ".hide-scrollbar",
793
+ "scrollbar-width: none; -ms-overflow-style: none;"
794
+ ), I(".hide-scrollbar::-webkit-scrollbar", "display: none"), e.value.addEventListener("scroll", H, {
544
795
  passive: !0
545
- }), K("add"), G.observe(e.value, {
796
+ }), K("add"), Y.observe(e.value, {
546
797
  subtree: !0,
547
798
  attributeOldValue: !0,
548
799
  attributeFilter: ["style"]
549
800
  }), setTimeout(() => {
550
- a();
551
- }, 100), d()) : console.error("useScrollBar:", "\u521D\u59CB\u5316\u5931\u8D25!", { containerEl: e, sliderEl: n });
801
+ f();
802
+ }, 100), y()) : console.error("useScrollBar:", "\u521D\u59CB\u5316\u5931\u8D25!", { containerEl: e, sliderEl: n });
552
803
  }
553
- return $(v, () => {
554
- B(), c();
804
+ return ne(d, () => {
805
+ z(), i();
555
806
  }), {
556
- isScrollEnd: l,
557
- isDragSlider: b,
558
- offsetTop: i,
559
- scrollTop: v,
560
- scrollable: N,
561
- sliderPos: M,
562
- init: _,
807
+ isScrollEnd: r,
808
+ isDragSlider: _,
809
+ offsetTop: s,
810
+ scrollTop: d,
811
+ scrollable: E,
812
+ sliderPos: U,
813
+ init: C,
563
814
  modifySliderEventListener: K
564
815
  };
565
816
  }
566
- const ht = (t) => (ke("data-v-edec7292"), t = t(), ze(), t), mt = /* @__PURE__ */ ht(() => /* @__PURE__ */ H("div", { class: "default-slider" }, null, -1)), gt = /* @__PURE__ */ A({
817
+ const It = (t) => (nt("data-v-edec7292"), t = t(), lt(), t), Lt = /* @__PURE__ */ It(() => /* @__PURE__ */ M("div", { class: "default-slider" }, null, -1)), Ht = /* @__PURE__ */ Z({
567
818
  __name: "ScrollBar",
568
819
  props: {
569
820
  containerEl: null,
@@ -572,55 +823,55 @@ const ht = (t) => (ke("data-v-edec7292"), t = t(), ze(), t), mt = /* @__PURE__ *
572
823
  performance: null
573
824
  },
574
825
  setup(t, { expose: e }) {
575
- const n = t, o = !!De().default, s = g(null), r = f(() => n.containerEl), l = pt({
576
- containerEl: r,
577
- sliderEl: s,
578
- autoHeight: o ? n.autoHeight : !0,
826
+ const n = t, l = !!Ze().default, o = w(null), a = S(() => n.containerEl), r = Bt({
827
+ containerEl: a,
828
+ sliderEl: o,
829
+ autoHeight: l ? n.autoHeight : !0,
579
830
  performance: n.performance
580
- }), { scrollable: c, isScrollEnd: m, sliderPos: p } = l, v = g(!1), h = n.autoHide ? f(() => v.value || !m.value) : f(() => c.value);
581
- te(() => {
582
- ne(() => {
583
- l.init();
831
+ }), { scrollable: i, isScrollEnd: m, sliderPos: p } = r, d = w(!1), c = n.autoHide ? S(() => d.value || !m.value) : S(() => i.value);
832
+ de(() => {
833
+ fe(() => {
834
+ r.init();
584
835
  });
585
- }), ve(() => {
586
- l.modifySliderEventListener("remove");
836
+ }), Te(() => {
837
+ r.modifySliderEventListener("remove");
587
838
  });
588
- function i() {
589
- v.value = !0;
839
+ function s() {
840
+ d.value = !0;
590
841
  }
591
842
  function u() {
592
- v.value = !1;
843
+ d.value = !1;
593
844
  }
594
- return e({ uScrollBarReturn: l }), (E, b) => (I(), fe(pe, null, {
595
- default: he(() => [
596
- We(H("div", {
845
+ return e({ uScrollBarReturn: r }), (b, _) => (k(), Oe(Re, null, {
846
+ default: De(() => [
847
+ et(M("div", {
597
848
  ref_key: "sliderRef",
598
- ref: s,
849
+ ref: o,
599
850
  class: "slider-wrapper",
600
- onMouseenter: i,
851
+ onMouseenter: s,
601
852
  onMouseleave: u,
602
- style: F(y(p))
853
+ style: le(B(p))
603
854
  }, [
604
- oe(E.$slots, "default", {}, () => [
605
- mt
855
+ he(b.$slots, "default", {}, () => [
856
+ Lt
606
857
  ], !0)
607
858
  ], 36), [
608
- [Me, y(h)]
859
+ [tt, B(c)]
609
860
  ])
610
861
  ]),
611
862
  _: 3
612
863
  }));
613
864
  }
614
865
  });
615
- const He = (t, e) => {
866
+ const Ve = (t, e) => {
616
867
  const n = t.__vccOpts || t;
617
- for (const [o, s] of e)
618
- n[o] = s;
868
+ for (const [l, o] of e)
869
+ n[l] = o;
619
870
  return n;
620
- }, Ht = /* @__PURE__ */ He(gt, [["__scopeId", "data-v-edec7292"]]), bt = { class: "virtualListWrapper" }, yt = {
871
+ }, Kt = /* @__PURE__ */ Ve(Ht, [["__scopeId", "data-v-edec7292"]]), $t = { class: "virtualListWrapper" }, At = {
621
872
  inheritAttrs: !1
622
- }, _t = /* @__PURE__ */ A({
623
- ...yt,
873
+ }, Pt = /* @__PURE__ */ Z({
874
+ ...At,
624
875
  __name: "VirtualList",
625
876
  props: {
626
877
  data: null,
@@ -629,33 +880,33 @@ const He = (t, e) => {
629
880
  },
630
881
  emits: ["scrollEnd"],
631
882
  setup(t, { expose: e, emit: n }) {
632
- const o = t, s = ut(Ve(o, "data"), {
633
- itemHeight: (v) => o.itemHeight(o.data[v]),
634
- overscan: o.overscan,
883
+ const l = t, o = Tt(ot(l, "data"), {
884
+ itemHeight: (d) => l.itemHeight(l.data[d]),
885
+ overscan: l.overscan,
635
886
  scrollEndHook: () => {
636
887
  n("scrollEnd");
637
888
  }
638
- }), { list: r, containerProps: l, wrapperProps: c, innerProps: m, getItemHeightData: p } = s;
889
+ }), { list: a, containerProps: r, wrapperProps: i, innerProps: m, getItemHeightData: p } = o;
639
890
  return e({
640
- vListReturn: s
641
- }), (v, h) => (I(), R("div", bt, [
642
- H("div", je({
643
- onScrollPassive: h[0] || (h[0] = (...i) => y(l).onScroll && y(l).onScroll(...i)),
644
- ref: y(l).ref,
891
+ vListReturn: o
892
+ }), (d, c) => (k(), J("div", $t, [
893
+ M("div", rt({
894
+ onScrollPassive: c[0] || (c[0] = (...s) => B(r).onScroll && B(r).onScroll(...s)),
895
+ ref: B(r).ref,
645
896
  class: "virtualList"
646
- }, v.$attrs), [
647
- H("div", le(se(y(c))), [
648
- H("div", le(se(y(m))), [
649
- (I(!0), R(Ke, null, Ne(y(r), ({ index: i, data: u }) => (I(), R("div", {
650
- key: i,
651
- style: F({
652
- height: `${y(p)(i).height}px`,
897
+ }, d.$attrs), [
898
+ M("div", me(ge(B(i))), [
899
+ M("div", me(ge(B(m))), [
900
+ (k(!0), J(at, null, st(B(a), ({ index: s, data: u }) => (k(), J("div", {
901
+ key: s,
902
+ style: le({
903
+ height: `${B(p)(s).height}px`,
653
904
  display: "flex"
654
905
  })
655
906
  }, [
656
- oe(v.$slots, "default", {
907
+ he(d.$slots, "default", {
657
908
  data: u,
658
- index: i
909
+ index: s
659
910
  }, void 0, !0)
660
911
  ], 4))), 128))
661
912
  ], 16)
@@ -664,24 +915,27 @@ const He = (t, e) => {
664
915
  ]));
665
916
  }
666
917
  });
667
- const It = /* @__PURE__ */ He(_t, [["__scopeId", "data-v-4ba97cce"]]);
918
+ const Qt = /* @__PURE__ */ Ve(Pt, [["__scopeId", "data-v-4ba97cce"]]);
668
919
  export {
669
- Ht as ScrollBar,
670
- Tt as SvgIcon,
671
- Et as ToastCreator,
672
- It as VirtualList,
673
- Se as allSelectedKey,
674
- ct as closeDialogKey,
675
- xt as dialogController,
676
- Ee as isAllSelectedKey,
677
- _e as isSelectedKey,
678
- Oe as selectAllKey,
679
- we as selectKey,
680
- be as toggleAllKey,
681
- ye as toggleKey,
682
- Te as unselectAllKey,
683
- xe as unselectKey,
684
- Ot as useSelectable,
685
- wt as useSelectableInjectors,
686
- ut as useVirtualList
920
+ Kt as ScrollBar,
921
+ jt as SvgIcon,
922
+ Vt as ToastCreator,
923
+ Qt as VirtualList,
924
+ Pe as allSelectedKey,
925
+ Ot as closeDialogKey,
926
+ Nt as dialogController,
927
+ We as isAllSelectedKey,
928
+ Ae as isSelectedKey,
929
+ Me as selectAllKey,
930
+ Fe as selectKey,
931
+ He as toggleAllKey,
932
+ $e as toggleKey,
933
+ ke as unselectAllKey,
934
+ ze as unselectKey,
935
+ Ne as useDragSelect,
936
+ kt as useDragSelectByMobile,
937
+ Wt as useDragSelectByPc,
938
+ zt as useSelectable,
939
+ Mt as useSelectableInjectors,
940
+ Tt as useVirtualList
687
941
  };