zf-dbs 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,18 @@
1
+ # Vue 3 + TypeScript + Vite
2
+
3
+ This template should help get you started developing with Vue 3 and TypeScript in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.
4
+
5
+ ## Recommended IDE Setup
6
+
7
+ - [VS Code](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8
+
9
+ ## Type Support For `.vue` Imports in TS
10
+
11
+ TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12
+
13
+ If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14
+
15
+ 1. Disable the built-in TypeScript Extension
16
+ 1. Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17
+ 2. Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18
+ 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
@@ -0,0 +1,449 @@
1
+ import { defineComponent as j, useSlots as $, ref as B, onMounted as m, watch as N, onUnmounted as q, unref as v, openBlock as C, createElementBlock as z, normalizeClass as F, normalizeStyle as M, toDisplayString as P, createBlock as G, resolveDynamicComponent as L, withCtx as Q, renderSlot as O, normalizeProps as R, guardReactiveProps as W, createTextVNode as k, mergeProps as Z } from "vue";
2
+ import { _ as H } from "./CHgC5LLL.mjs";
3
+ var b = {
4
+ Linear: {
5
+ None: function(e) {
6
+ return e;
7
+ }
8
+ },
9
+ Quadratic: {
10
+ In: function(e) {
11
+ return e * e;
12
+ },
13
+ Out: function(e) {
14
+ return e * (2 - e);
15
+ },
16
+ InOut: function(e) {
17
+ return (e *= 2) < 1 ? 0.5 * e * e : -0.5 * (--e * (e - 2) - 1);
18
+ }
19
+ },
20
+ Cubic: {
21
+ In: function(e) {
22
+ return e * e * e;
23
+ },
24
+ Out: function(e) {
25
+ return --e * e * e + 1;
26
+ },
27
+ InOut: function(e) {
28
+ return (e *= 2) < 1 ? 0.5 * e * e * e : 0.5 * ((e -= 2) * e * e + 2);
29
+ }
30
+ },
31
+ Quartic: {
32
+ In: function(e) {
33
+ return e * e * e * e;
34
+ },
35
+ Out: function(e) {
36
+ return 1 - --e * e * e * e;
37
+ },
38
+ InOut: function(e) {
39
+ return (e *= 2) < 1 ? 0.5 * e * e * e * e : -0.5 * ((e -= 2) * e * e * e - 2);
40
+ }
41
+ },
42
+ Quintic: {
43
+ In: function(e) {
44
+ return e * e * e * e * e;
45
+ },
46
+ Out: function(e) {
47
+ return --e * e * e * e * e + 1;
48
+ },
49
+ InOut: function(e) {
50
+ return (e *= 2) < 1 ? 0.5 * e * e * e * e * e : 0.5 * ((e -= 2) * e * e * e * e + 2);
51
+ }
52
+ },
53
+ Sinusoidal: {
54
+ In: function(e) {
55
+ return 1 - Math.cos(e * Math.PI / 2);
56
+ },
57
+ Out: function(e) {
58
+ return Math.sin(e * Math.PI / 2);
59
+ },
60
+ InOut: function(e) {
61
+ return 0.5 * (1 - Math.cos(Math.PI * e));
62
+ }
63
+ },
64
+ Exponential: {
65
+ In: function(e) {
66
+ return e === 0 ? 0 : Math.pow(1024, e - 1);
67
+ },
68
+ Out: function(e) {
69
+ return e === 1 ? 1 : 1 - Math.pow(2, -10 * e);
70
+ },
71
+ InOut: function(e) {
72
+ return e === 0 ? 0 : e === 1 ? 1 : (e *= 2) < 1 ? 0.5 * Math.pow(1024, e - 1) : 0.5 * (-Math.pow(2, -10 * (e - 1)) + 2);
73
+ }
74
+ },
75
+ Circular: {
76
+ In: function(e) {
77
+ return 1 - Math.sqrt(1 - e * e);
78
+ },
79
+ Out: function(e) {
80
+ return Math.sqrt(1 - --e * e);
81
+ },
82
+ InOut: function(e) {
83
+ return (e *= 2) < 1 ? -0.5 * (Math.sqrt(1 - e * e) - 1) : 0.5 * (Math.sqrt(1 - (e -= 2) * e) + 1);
84
+ }
85
+ },
86
+ Elastic: {
87
+ In: function(e) {
88
+ return e === 0 ? 0 : e === 1 ? 1 : -Math.pow(2, 10 * (e - 1)) * Math.sin((e - 1.1) * 5 * Math.PI);
89
+ },
90
+ Out: function(e) {
91
+ return e === 0 ? 0 : e === 1 ? 1 : Math.pow(2, -10 * e) * Math.sin((e - 0.1) * 5 * Math.PI) + 1;
92
+ },
93
+ InOut: function(e) {
94
+ return e === 0 ? 0 : e === 1 ? 1 : (e *= 2, e < 1 ? -0.5 * Math.pow(2, 10 * (e - 1)) * Math.sin((e - 1.1) * 5 * Math.PI) : 0.5 * Math.pow(2, -10 * (e - 1)) * Math.sin((e - 1.1) * 5 * Math.PI) + 1);
95
+ }
96
+ },
97
+ Back: {
98
+ In: function(e) {
99
+ var t = 1.70158;
100
+ return e * e * ((t + 1) * e - t);
101
+ },
102
+ Out: function(e) {
103
+ var t = 1.70158;
104
+ return --e * e * ((t + 1) * e + t) + 1;
105
+ },
106
+ InOut: function(e) {
107
+ var t = 2.5949095;
108
+ return (e *= 2) < 1 ? 0.5 * (e * e * ((t + 1) * e - t)) : 0.5 * ((e -= 2) * e * ((t + 1) * e + t) + 2);
109
+ }
110
+ },
111
+ Bounce: {
112
+ In: function(e) {
113
+ return 1 - b.Bounce.Out(1 - e);
114
+ },
115
+ Out: function(e) {
116
+ return e < 1 / 2.75 ? 7.5625 * e * e : e < 2 / 2.75 ? 7.5625 * (e -= 1.5 / 2.75) * e + 0.75 : e < 2.5 / 2.75 ? 7.5625 * (e -= 2.25 / 2.75) * e + 0.9375 : 7.5625 * (e -= 2.625 / 2.75) * e + 0.984375;
117
+ },
118
+ InOut: function(e) {
119
+ return e < 0.5 ? b.Bounce.In(e * 2) * 0.5 : b.Bounce.Out(e * 2 - 1) * 0.5 + 0.5;
120
+ }
121
+ }
122
+ }, y;
123
+ typeof self > "u" && typeof process < "u" && process.hrtime ? y = function() {
124
+ var e = process.hrtime();
125
+ return e[0] * 1e3 + e[1] / 1e6;
126
+ } : typeof self < "u" && self.performance !== void 0 && self.performance.now !== void 0 ? y = self.performance.now.bind(self.performance) : Date.now !== void 0 ? y = Date.now : y = function() {
127
+ return (/* @__PURE__ */ new Date()).getTime();
128
+ };
129
+ var _ = y, A = (
130
+ /** @class */
131
+ function() {
132
+ function e() {
133
+ this._tweens = {}, this._tweensAddedDuringUpdate = {};
134
+ }
135
+ return e.prototype.getAll = function() {
136
+ var t = this;
137
+ return Object.keys(this._tweens).map(function(i) {
138
+ return t._tweens[i];
139
+ });
140
+ }, e.prototype.removeAll = function() {
141
+ this._tweens = {};
142
+ }, e.prototype.add = function(t) {
143
+ this._tweens[t.getId()] = t, this._tweensAddedDuringUpdate[t.getId()] = t;
144
+ }, e.prototype.remove = function(t) {
145
+ delete this._tweens[t.getId()], delete this._tweensAddedDuringUpdate[t.getId()];
146
+ }, e.prototype.update = function(t, i) {
147
+ t === void 0 && (t = _()), i === void 0 && (i = !1);
148
+ var n = Object.keys(this._tweens);
149
+ if (n.length === 0)
150
+ return !1;
151
+ for (; n.length > 0; ) {
152
+ this._tweensAddedDuringUpdate = {};
153
+ for (var r = 0; r < n.length; r++) {
154
+ var s = this._tweens[n[r]], a = !i;
155
+ s && s.update(t, a) === !1 && !i && delete this._tweens[n[r]];
156
+ }
157
+ n = Object.keys(this._tweensAddedDuringUpdate);
158
+ }
159
+ return !0;
160
+ }, e;
161
+ }()
162
+ ), g = {
163
+ Linear: function(e, t) {
164
+ var i = e.length - 1, n = i * t, r = Math.floor(n), s = g.Utils.Linear;
165
+ return t < 0 ? s(e[0], e[1], n) : t > 1 ? s(e[i], e[i - 1], i - n) : s(e[r], e[r + 1 > i ? i : r + 1], n - r);
166
+ },
167
+ Bezier: function(e, t) {
168
+ for (var i = 0, n = e.length - 1, r = Math.pow, s = g.Utils.Bernstein, a = 0; a <= n; a++)
169
+ i += r(1 - t, n - a) * r(t, a) * e[a] * s(n, a);
170
+ return i;
171
+ },
172
+ CatmullRom: function(e, t) {
173
+ var i = e.length - 1, n = i * t, r = Math.floor(n), s = g.Utils.CatmullRom;
174
+ return e[0] === e[i] ? (t < 0 && (r = Math.floor(n = i * (1 + t))), s(e[(r - 1 + i) % i], e[r], e[(r + 1) % i], e[(r + 2) % i], n - r)) : t < 0 ? e[0] - (s(e[0], e[0], e[1], e[1], -n) - e[0]) : t > 1 ? e[i] - (s(e[i], e[i], e[i - 1], e[i - 1], n - i) - e[i]) : s(e[r ? r - 1 : 0], e[r], e[i < r + 1 ? i : r + 1], e[i < r + 2 ? i : r + 2], n - r);
175
+ },
176
+ Utils: {
177
+ Linear: function(e, t, i) {
178
+ return (t - e) * i + e;
179
+ },
180
+ Bernstein: function(e, t) {
181
+ var i = g.Utils.Factorial;
182
+ return i(e) / i(t) / i(e - t);
183
+ },
184
+ Factorial: /* @__PURE__ */ function() {
185
+ var e = [1];
186
+ return function(t) {
187
+ var i = 1;
188
+ if (e[t])
189
+ return e[t];
190
+ for (var n = t; n > 1; n--)
191
+ i *= n;
192
+ return e[t] = i, i;
193
+ };
194
+ }(),
195
+ CatmullRom: function(e, t, i, n, r) {
196
+ var s = (i - e) * 0.5, a = (n - t) * 0.5, l = r * r, f = r * l;
197
+ return (2 * t - 2 * i + s + a) * f + (-3 * t + 3 * i - 2 * s - a) * l + s * r + t;
198
+ }
199
+ }
200
+ }, I = (
201
+ /** @class */
202
+ function() {
203
+ function e() {
204
+ }
205
+ return e.nextId = function() {
206
+ return e._nextId++;
207
+ }, e._nextId = 0, e;
208
+ }()
209
+ ), E = new A(), J = (
210
+ /** @class */
211
+ function() {
212
+ function e(t, i) {
213
+ i === void 0 && (i = E), this._object = t, this._group = i, this._isPaused = !1, this._pauseStart = 0, this._valuesStart = {}, this._valuesEnd = {}, this._valuesStartRepeat = {}, this._duration = 1e3, this._initialRepeat = 0, this._repeat = 0, this._yoyo = !1, this._isPlaying = !1, this._reversed = !1, this._delayTime = 0, this._startTime = 0, this._easingFunction = b.Linear.None, this._interpolationFunction = g.Linear, this._chainedTweens = [], this._onStartCallbackFired = !1, this._id = I.nextId(), this._isChainStopped = !1, this._goToEnd = !1;
214
+ }
215
+ return e.prototype.getId = function() {
216
+ return this._id;
217
+ }, e.prototype.isPlaying = function() {
218
+ return this._isPlaying;
219
+ }, e.prototype.isPaused = function() {
220
+ return this._isPaused;
221
+ }, e.prototype.to = function(t, i) {
222
+ return this._valuesEnd = Object.create(t), i !== void 0 && (this._duration = i), this;
223
+ }, e.prototype.duration = function(t) {
224
+ return this._duration = t, this;
225
+ }, e.prototype.start = function(t) {
226
+ if (this._isPlaying)
227
+ return this;
228
+ if (this._group && this._group.add(this), this._repeat = this._initialRepeat, this._reversed) {
229
+ this._reversed = !1;
230
+ for (var i in this._valuesStartRepeat)
231
+ this._swapEndStartRepeatValues(i), this._valuesStart[i] = this._valuesStartRepeat[i];
232
+ }
233
+ return this._isPlaying = !0, this._isPaused = !1, this._onStartCallbackFired = !1, this._isChainStopped = !1, this._startTime = t !== void 0 ? typeof t == "string" ? _() + parseFloat(t) : t : _(), this._startTime += this._delayTime, this._setupProperties(this._object, this._valuesStart, this._valuesEnd, this._valuesStartRepeat), this;
234
+ }, e.prototype._setupProperties = function(t, i, n, r) {
235
+ for (var s in n) {
236
+ var a = t[s], l = Array.isArray(a), f = l ? "array" : typeof a, d = !l && Array.isArray(n[s]);
237
+ if (!(f === "undefined" || f === "function")) {
238
+ if (d) {
239
+ var o = n[s];
240
+ if (o.length === 0)
241
+ continue;
242
+ o = o.map(this._handleRelativeValue.bind(this, a)), n[s] = [a].concat(o);
243
+ }
244
+ if ((f === "object" || l) && a && !d) {
245
+ i[s] = l ? [] : {};
246
+ for (var h in a)
247
+ i[s][h] = a[h];
248
+ r[s] = l ? [] : {}, this._setupProperties(a, i[s], n[s], r[s]);
249
+ } else
250
+ typeof i[s] > "u" && (i[s] = a), l || (i[s] *= 1), d ? r[s] = n[s].slice().reverse() : r[s] = i[s] || 0;
251
+ }
252
+ }
253
+ }, e.prototype.stop = function() {
254
+ return this._isChainStopped || (this._isChainStopped = !0, this.stopChainedTweens()), this._isPlaying ? (this._group && this._group.remove(this), this._isPlaying = !1, this._isPaused = !1, this._onStopCallback && this._onStopCallback(this._object), this) : this;
255
+ }, e.prototype.end = function() {
256
+ return this._goToEnd = !0, this.update(1 / 0), this;
257
+ }, e.prototype.pause = function(t) {
258
+ return t === void 0 && (t = _()), this._isPaused || !this._isPlaying ? this : (this._isPaused = !0, this._pauseStart = t, this._group && this._group.remove(this), this);
259
+ }, e.prototype.resume = function(t) {
260
+ return t === void 0 && (t = _()), !this._isPaused || !this._isPlaying ? this : (this._isPaused = !1, this._startTime += t - this._pauseStart, this._pauseStart = 0, this._group && this._group.add(this), this);
261
+ }, e.prototype.stopChainedTweens = function() {
262
+ for (var t = 0, i = this._chainedTweens.length; t < i; t++)
263
+ this._chainedTweens[t].stop();
264
+ return this;
265
+ }, e.prototype.group = function(t) {
266
+ return this._group = t, this;
267
+ }, e.prototype.delay = function(t) {
268
+ return this._delayTime = t, this;
269
+ }, e.prototype.repeat = function(t) {
270
+ return this._initialRepeat = t, this._repeat = t, this;
271
+ }, e.prototype.repeatDelay = function(t) {
272
+ return this._repeatDelayTime = t, this;
273
+ }, e.prototype.yoyo = function(t) {
274
+ return this._yoyo = t, this;
275
+ }, e.prototype.easing = function(t) {
276
+ return this._easingFunction = t, this;
277
+ }, e.prototype.interpolation = function(t) {
278
+ return this._interpolationFunction = t, this;
279
+ }, e.prototype.chain = function() {
280
+ for (var t = [], i = 0; i < arguments.length; i++)
281
+ t[i] = arguments[i];
282
+ return this._chainedTweens = t, this;
283
+ }, e.prototype.onStart = function(t) {
284
+ return this._onStartCallback = t, this;
285
+ }, e.prototype.onUpdate = function(t) {
286
+ return this._onUpdateCallback = t, this;
287
+ }, e.prototype.onRepeat = function(t) {
288
+ return this._onRepeatCallback = t, this;
289
+ }, e.prototype.onComplete = function(t) {
290
+ return this._onCompleteCallback = t, this;
291
+ }, e.prototype.onStop = function(t) {
292
+ return this._onStopCallback = t, this;
293
+ }, e.prototype.update = function(t, i) {
294
+ if (t === void 0 && (t = _()), i === void 0 && (i = !0), this._isPaused)
295
+ return !0;
296
+ var n, r, s = this._startTime + this._duration;
297
+ if (!this._goToEnd && !this._isPlaying) {
298
+ if (t > s)
299
+ return !1;
300
+ i && this.start(t);
301
+ }
302
+ if (this._goToEnd = !1, t < this._startTime)
303
+ return !0;
304
+ this._onStartCallbackFired === !1 && (this._onStartCallback && this._onStartCallback(this._object), this._onStartCallbackFired = !0), r = (t - this._startTime) / this._duration, r = this._duration === 0 || r > 1 ? 1 : r;
305
+ var a = this._easingFunction(r);
306
+ if (this._updateProperties(this._object, this._valuesStart, this._valuesEnd, a), this._onUpdateCallback && this._onUpdateCallback(this._object, r), r === 1)
307
+ if (this._repeat > 0) {
308
+ isFinite(this._repeat) && this._repeat--;
309
+ for (n in this._valuesStartRepeat)
310
+ !this._yoyo && typeof this._valuesEnd[n] == "string" && (this._valuesStartRepeat[n] = // eslint-disable-next-line
311
+ // @ts-ignore FIXME?
312
+ this._valuesStartRepeat[n] + parseFloat(this._valuesEnd[n])), this._yoyo && this._swapEndStartRepeatValues(n), this._valuesStart[n] = this._valuesStartRepeat[n];
313
+ return this._yoyo && (this._reversed = !this._reversed), this._repeatDelayTime !== void 0 ? this._startTime = t + this._repeatDelayTime : this._startTime = t + this._delayTime, this._onRepeatCallback && this._onRepeatCallback(this._object), !0;
314
+ } else {
315
+ this._onCompleteCallback && this._onCompleteCallback(this._object);
316
+ for (var l = 0, f = this._chainedTweens.length; l < f; l++)
317
+ this._chainedTweens[l].start(this._startTime + this._duration);
318
+ return this._isPlaying = !1, !1;
319
+ }
320
+ return !0;
321
+ }, e.prototype._updateProperties = function(t, i, n, r) {
322
+ for (var s in n)
323
+ if (i[s] !== void 0) {
324
+ var a = i[s] || 0, l = n[s], f = Array.isArray(t[s]), d = Array.isArray(l), o = !f && d;
325
+ o ? t[s] = this._interpolationFunction(l, r) : typeof l == "object" && l ? this._updateProperties(t[s], a, l, r) : (l = this._handleRelativeValue(a, l), typeof l == "number" && (t[s] = a + (l - a) * r));
326
+ }
327
+ }, e.prototype._handleRelativeValue = function(t, i) {
328
+ return typeof i != "string" ? i : i.charAt(0) === "+" || i.charAt(0) === "-" ? t + parseFloat(i) : parseFloat(i);
329
+ }, e.prototype._swapEndStartRepeatValues = function(t) {
330
+ var i = this._valuesStartRepeat[t], n = this._valuesEnd[t];
331
+ typeof n == "string" ? this._valuesStartRepeat[t] = this._valuesStartRepeat[t] + parseFloat(n) : this._valuesStartRepeat[t] = this._valuesEnd[t], this._valuesEnd[t] = i;
332
+ }, e;
333
+ }()
334
+ ), K = "18.6.4", X = I.nextId, c = E, Y = c.getAll.bind(c), V = c.removeAll.bind(c), ee = c.add.bind(c), te = c.remove.bind(c), ie = c.update.bind(c), x = {
335
+ Easing: b,
336
+ Group: A,
337
+ Interpolation: g,
338
+ now: _,
339
+ Sequence: I,
340
+ nextId: X,
341
+ Tween: J,
342
+ VERSION: K,
343
+ getAll: Y,
344
+ removeAll: V,
345
+ add: ee,
346
+ remove: te,
347
+ update: ie
348
+ };
349
+ const ne = /* @__PURE__ */ j({
350
+ __name: "zf-tween-number",
351
+ props: {
352
+ value: { default: "" },
353
+ thousand: { type: Boolean, default: void 0 },
354
+ duration: { default: 1e3 },
355
+ tag: { default: void 0 },
356
+ class: { default: "" },
357
+ style: { default: "" }
358
+ },
359
+ setup(e) {
360
+ const t = e, i = $(), n = B({
361
+ value: "",
362
+ prefix: "",
363
+ number: "",
364
+ negativeFlag: !1,
365
+ thousandFlag: !1,
366
+ integer: "",
367
+ decimalFull: "",
368
+ decimal: "",
369
+ decimalDecimal: 0,
370
+ append: ""
371
+ });
372
+ let r = null;
373
+ function s(o) {
374
+ const u = /^([^\d-]*)(((-)?(?:\d{1,3}(?=,)(?:,\d{3})+|\d+)?)(\.(\d+))?)?([\s\S]*)$/.exec(`${o}`);
375
+ return {
376
+ value: o,
377
+ prefix: u?.[1] ?? "",
378
+ number: u?.[2] ?? "",
379
+ integer: u?.[3] ?? "",
380
+ negative: u?.[4] ?? "",
381
+ decimalFull: u?.[5] ?? "",
382
+ decimal: u?.[6] ?? "",
383
+ append: u?.[7] ?? ""
384
+ };
385
+ }
386
+ function a(o) {
387
+ const h = Math.floor(o), u = `${o}`.split(".")[1] || "";
388
+ return `${h}`.replace(/\d{1,3}(?=(\d{3})+$)/g, "$&,") + (u ? `.${u}` : "");
389
+ }
390
+ function l() {
391
+ r && r.stop(), r = null;
392
+ }
393
+ function f(o) {
394
+ x.update(o) && requestAnimationFrame(f);
395
+ }
396
+ function d(o, h) {
397
+ l();
398
+ const u = s(h);
399
+ if (!u.number)
400
+ return n.value.value = u.value, n.value.prefix = u.prefix, n.value.number = u.number, n.value.negativeFlag = !!u.negative, n.value.integer = u.integer, n.value.decimalFull = u.decimalFull, n.value.decimal = u.decimal, n.value.decimalDecimal = u.decimal.length, n.value.append = u.append, f();
401
+ const w = s(o);
402
+ n.value.prefix = u.prefix, n.value.value = w.value, n.value.append = u.append, n.value.thousandFlag = u.integer.includes(","), r = new x.Tween({
403
+ value: w.number ? parseFloat(w.number.replace(/,/g, "")) : 0,
404
+ decimalDecimal: w.decimal.length
405
+ }).to({
406
+ value: u.number ? parseFloat(u.number.replace(/,/g, "")) : 0,
407
+ decimalDecimal: u.decimal.length
408
+ }, t.duration).onUpdate((T) => {
409
+ const U = Math.floor(T.decimalDecimal);
410
+ let S = T.value.toFixed(U);
411
+ (t.thousand === !0 || typeof t.thousand > "u" && n.value.thousandFlag) && (S = a(Number(S)));
412
+ const p = s(`${u.prefix}${S}${u.append}`);
413
+ n.value.value = p.value, n.value.number = p.number, n.value.negativeFlag = !!p.negative, n.value.integer = p.integer, n.value.decimalFull = p.decimalFull, n.value.decimal = p.decimal, n.value.decimalDecimal = p.decimal.length;
414
+ }).start(), f();
415
+ }
416
+ return m(() => {
417
+ d(0, t.value);
418
+ }), N(() => t.value, (o, h) => {
419
+ h !== o && d(h, o);
420
+ }), q(() => {
421
+ l();
422
+ }), (o, h) => !v(i).default && (t.class || t.style) ? (C(), z("span", {
423
+ key: 0,
424
+ class: F(t.class),
425
+ style: M(t.style)
426
+ }, P(v(n).value), 7)) : t.tag ? (C(), G(L(t.tag), {
427
+ key: 1,
428
+ class: F(t.class),
429
+ style: M(t.style)
430
+ }, {
431
+ default: Q(() => [
432
+ O(o.$slots, "default", R(W(v(n))), () => [
433
+ k(P(v(n).value), 1)
434
+ ], !0)
435
+ ]),
436
+ _: 3
437
+ }, 8, ["class", "style"])) : O(o.$slots, "default", R(Z({ key: 2 }, v(n))), () => [
438
+ k(P(v(n).value), 1)
439
+ ], !0);
440
+ }
441
+ }), D = /* @__PURE__ */ H(ne, [["__scopeId", "data-v-ff0a80ef"]]), ae = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
442
+ __proto__: null,
443
+ ZfTweenNumber: D,
444
+ default: D
445
+ }, Symbol.toStringTag, { value: "Module" }));
446
+ export {
447
+ ae as _,
448
+ D as z
449
+ };
@@ -0,0 +1,9 @@
1
+ const s = (t, r) => {
2
+ const o = t.__vccOpts || t;
3
+ for (const [c, e] of r)
4
+ o[c] = e;
5
+ return o;
6
+ };
7
+ export {
8
+ s as _
9
+ };
@@ -0,0 +1,9 @@
1
+ import { Z as e } from "./zkyql-F5.mjs";
2
+ const t = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3
+ __proto__: null,
4
+ ZfScaleContainer: e,
5
+ default: e
6
+ }, Symbol.toStringTag, { value: "Module" }));
7
+ export {
8
+ t as _
9
+ };
@@ -0,0 +1,152 @@
1
+ import { ref as y, defineComponent as v, reactive as S, computed as T, provide as z, unref as a, openBlock as p, createElementBlock as g, createVNode as b, withCtx as q, createElementVNode as w, renderSlot as f, normalizeStyle as H } from "vue";
2
+ import { Z as x } from "./zkyql-F5.mjs";
3
+ import { _ as C } from "./CHgC5LLL.mjs";
4
+ class n {
5
+ key;
6
+ // Token key
7
+ autoGetTokenHandle;
8
+ // Token 处理函数
9
+ /**
10
+ * @param key Token key
11
+ * @param autoGetTokenHandle Token 处理函数
12
+ */
13
+ constructor(e, t) {
14
+ this.key = e, this.autoGetTokenHandle = t;
15
+ }
16
+ /**
17
+ * 获取 Token
18
+ * @returns Token
19
+ */
20
+ async getToken() {
21
+ let e = n.getToken({ key: this.key });
22
+ if (!e && this.autoGetTokenHandle) {
23
+ const t = await Promise.resolve(this.autoGetTokenHandle());
24
+ e = t.token, await this.setToken(e, { expires: t.expires });
25
+ }
26
+ return e;
27
+ }
28
+ /**
29
+ * 设置 Token
30
+ * @param token Token
31
+ * @param options 选项
32
+ * @returns Token
33
+ */
34
+ async setToken(e, t) {
35
+ return n.setToken(e, { key: this.key, ...t });
36
+ }
37
+ static baseKey = "token";
38
+ // Token 基础 key
39
+ /**
40
+ * 获取 Token
41
+ * @param options 选项 { key: Token key }
42
+ * @returns Token
43
+ */
44
+ static getToken(e) {
45
+ const t = n.baseKey + ":" + (e?.key || "default"), s = Number(window.localStorage.getItem(`${t}_expires`) || 0), o = window.localStorage.getItem(t) || null;
46
+ return o && s && s < Date.now() ? (window.localStorage.removeItem(t), window.localStorage.removeItem(`${t}_expires`), null) : o;
47
+ }
48
+ /**
49
+ * 设置 Token
50
+ * @param token Token
51
+ * @param options 选项 { key: Token key, expires: Token 过期时间 }
52
+ */
53
+ static setToken(e, t) {
54
+ const s = n.baseKey + ":" + (t?.key || "default"), o = Date.now() + Number(t?.expires || 0);
55
+ window.localStorage.setItem(s, e || ""), window.localStorage.setItem(`${s}_expires`, String(o || 0));
56
+ }
57
+ }
58
+ const l = y(null);
59
+ function N(r) {
60
+ const e = new n("default", r.requestAutoGetTokenHandle);
61
+ return l.value = Object.assign({
62
+ appTitle: "zf-dbs template",
63
+ appHeight: 1080,
64
+ appWidth: r.appWidths?.[0] || 1920,
65
+ appWidths: [r.appWidth || 1920],
66
+ useScale: !0,
67
+ useStretch: !1,
68
+ useUE: !1,
69
+ pollingInterval: 1e3 * 60 * 5,
70
+ requestBaseURL: "",
71
+ requestUseMock: !1,
72
+ requestFormatCodeKey: "code",
73
+ requestFormatMessageKey: "message",
74
+ requestFormatDataKey: "data",
75
+ requestSuccessCode: [200, "200"],
76
+ requestErrorAuthCode: [],
77
+ requestErrorAuthHandle: void 0,
78
+ requestErrorIgnoreMessageCode: [],
79
+ requestTokenCacheKey: "token",
80
+ requestTokenHeaderKey: "Authorization",
81
+ requestAutoGetTokenHandle: e.autoGetTokenHandle,
82
+ sign: void 0
83
+ }, r), l;
84
+ }
85
+ function I() {
86
+ if (!l.value)
87
+ throw new Error("请先调用 defineConfig 进行配置");
88
+ return l;
89
+ }
90
+ const W = {
91
+ key: 0,
92
+ class: "app"
93
+ }, E = { class: "app__view" }, K = { class: "app__view" }, A = /* @__PURE__ */ v({
94
+ __name: "zf-app",
95
+ setup(r) {
96
+ const e = I(), t = S({
97
+ width: window.innerWidth,
98
+ height: window.innerHeight
99
+ });
100
+ window.addEventListener("resize", () => {
101
+ t.width = window.innerWidth, t.height = window.innerHeight;
102
+ });
103
+ function s(i, d) {
104
+ const h = i.width / i.height;
105
+ return d.reduce((c, u) => {
106
+ const m = c.width / c.height, _ = u.width / u.height;
107
+ return Math.abs(_ - h) < Math.abs(m - h) ? u : c;
108
+ });
109
+ }
110
+ const o = T(() => {
111
+ const i = [
112
+ ...e.value.appWidths?.map((d) => ({ width: d, height: e.value.appHeight })) ?? [],
113
+ { width: e.value.appWidth, height: e.value.appHeight }
114
+ ];
115
+ return s(t, i);
116
+ });
117
+ return z("pageSize", o), (i, d) => a(e).useScale ? (p(), g("div", W, [
118
+ b(a(x), {
119
+ width: a(o).width,
120
+ height: a(o).height,
121
+ mode: a(e).useStretch ? "scaleToFill" : "aspectFit"
122
+ }, {
123
+ default: q(() => [
124
+ w("div", E, [
125
+ f(i.$slots, "default", {}, void 0, !0)
126
+ ])
127
+ ]),
128
+ _: 3
129
+ }, 8, ["width", "height", "mode"])
130
+ ])) : (p(), g("div", {
131
+ key: 1,
132
+ class: "app",
133
+ style: H({ width: `${a(e).appWidth}px`, height: `${a(e).appHeight}px` })
134
+ }, [
135
+ w("div", K, [
136
+ f(i.$slots, "default", {}, void 0, !0)
137
+ ])
138
+ ], 4));
139
+ }
140
+ }), k = /* @__PURE__ */ C(A, [["__scopeId", "data-v-29b93127"]]), R = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
141
+ __proto__: null,
142
+ ZfApp: k,
143
+ default: k
144
+ }, Symbol.toStringTag, { value: "Module" }));
145
+ export {
146
+ n as T,
147
+ R as _,
148
+ l as c,
149
+ N as d,
150
+ I as u,
151
+ k as z
152
+ };