@toife/vue 1.1.11 → 1.1.12
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.css +1 -1
- package/dist/index.es.js +182 -185
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { createElementBlock as m, openBlock as
|
|
1
|
+
import { createElementBlock as m, openBlock as c, renderSlot as b, defineComponent as T, ref as y, computed as S, reactive as te, watch as R, onUnmounted as N, Fragment as A, withDirectives as W, createCommentVNode as z, normalizeStyle as w, normalizeClass as I, vShow as Y, createElementVNode as k, createVNode as M, createBlock as E, withCtx as B, toDisplayString as P, renderList as H, createTextVNode as X, createApp as U, h as j, unref as D, onMounted as J, resolveDynamicComponent as le, markRaw as ce, inject as ie, provide as ue } from "vue";
|
|
2
2
|
import { gesture as V } from "@toife/gesture";
|
|
3
|
-
import { useRouter as oe, useRoute as
|
|
3
|
+
import { useRouter as oe, useRoute as de } from "vue-router";
|
|
4
4
|
const O = (t) => t && (t.tagName == "INPUT" || t.tagName == "TEXTAREA" || t.isContentEditable), q = () => {
|
|
5
5
|
const t = document.activeElement;
|
|
6
6
|
t && (t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.isContentEditable) && t.blur();
|
|
7
|
-
},
|
|
7
|
+
}, pe = () => {
|
|
8
8
|
document.addEventListener("contextmenu", (t) => t.preventDefault()), document.addEventListener("selectstart", (t) => t.preventDefault()), document.addEventListener("pointerup", (t) => {
|
|
9
9
|
!O(t.target) && q();
|
|
10
10
|
});
|
|
@@ -13,13 +13,13 @@ const O = (t) => t && (t.tagName == "INPUT" || t.tagName == "TEXTAREA" || t.isCo
|
|
|
13
13
|
for (const [e, r] of n)
|
|
14
14
|
o[e] = r;
|
|
15
15
|
return o;
|
|
16
|
-
},
|
|
17
|
-
function
|
|
18
|
-
return
|
|
16
|
+
}, fe = {}, me = { class: "t-app" };
|
|
17
|
+
function ve(t, n) {
|
|
18
|
+
return c(), m("div", me, [
|
|
19
19
|
b(t.$slots, "default")
|
|
20
20
|
]);
|
|
21
21
|
}
|
|
22
|
-
const
|
|
22
|
+
const _e = /* @__PURE__ */ g(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
23
23
|
__name: "t-present",
|
|
24
24
|
props: {
|
|
25
25
|
keepalive: { type: Boolean, default: !0 },
|
|
@@ -29,13 +29,13 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
29
29
|
},
|
|
30
30
|
emits: ["dismiss"],
|
|
31
31
|
setup(t, { expose: n, emit: o }) {
|
|
32
|
-
const e = y(0), r = y(!1), a = y(), l = y(),
|
|
32
|
+
const e = y(0), r = y(!1), a = y(), l = y(), i = t, u = o, d = S(() => r.value || i.keepalive), v = te({
|
|
33
33
|
"--t-present-backdrop-opacity": "0.4",
|
|
34
34
|
"--t-present-transition": "0.2s",
|
|
35
35
|
"--t-present-content-transform": "0px",
|
|
36
36
|
"--t-present-content-opacity": "1"
|
|
37
37
|
}), _ = (p) => {
|
|
38
|
-
|
|
38
|
+
i.backdrop ? p?.backdropOpacity && (v["--t-present-backdrop-opacity"] = p.backdropOpacity) : v["--t-present-backdrop-opacity"] = "0", p?.transition && (v["--t-present-transition"] = p.transition, v["--t-present-transition"] = p.transition), p?.contentTransform && (v["--t-present-content-transform"] = p.contentTransform), p?.contentOpacity && (v["--t-present-content-opacity"] = p.contentOpacity);
|
|
39
39
|
}, s = () => {
|
|
40
40
|
_({
|
|
41
41
|
contentTransform: "0px",
|
|
@@ -45,15 +45,15 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
45
45
|
});
|
|
46
46
|
}, f = () => {
|
|
47
47
|
let p = "0px", x = "1";
|
|
48
|
-
|
|
48
|
+
i.placement == "bottom" || i.placement == "right" ? p = "100%" : i.placement == "top" || i.placement == "left" ? p = "-100%" : i.placement == "center" && (p = "0px", x = "0"), _({
|
|
49
49
|
contentTransform: p,
|
|
50
50
|
transition: "0.2s",
|
|
51
51
|
contentOpacity: x,
|
|
52
52
|
backdropOpacity: "0"
|
|
53
53
|
});
|
|
54
54
|
};
|
|
55
|
-
R(() =>
|
|
56
|
-
|
|
55
|
+
R(() => i.visible, () => {
|
|
56
|
+
i.visible ? (r.value = !0, e.value = Ee.getNewIndex(), setTimeout(() => {
|
|
57
57
|
s();
|
|
58
58
|
}, 50)) : (f(), setTimeout(() => {
|
|
59
59
|
r.value = !1;
|
|
@@ -75,8 +75,8 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
75
75
|
}));
|
|
76
76
|
}), N(() => {
|
|
77
77
|
h && h.destroy();
|
|
78
|
-
}), f(), (p, x) => (
|
|
79
|
-
d.value ? W((
|
|
78
|
+
}), f(), (p, x) => (c(), m(A, null, [
|
|
79
|
+
d.value ? W((c(), m("div", {
|
|
80
80
|
key: 0,
|
|
81
81
|
class: I(["t-present", { [p.placement]: !0 }]),
|
|
82
82
|
ref_key: "present",
|
|
@@ -87,7 +87,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
87
87
|
], 6)), [
|
|
88
88
|
[Y, r.value]
|
|
89
89
|
]) : z("", !0),
|
|
90
|
-
d.value ? W((
|
|
90
|
+
d.value ? W((c(), m("div", {
|
|
91
91
|
key: 1,
|
|
92
92
|
class: "t-present-backdrop",
|
|
93
93
|
ref_key: "backdrop",
|
|
@@ -98,7 +98,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
98
98
|
]) : z("", !0)
|
|
99
99
|
], 64));
|
|
100
100
|
}
|
|
101
|
-
}), L = /* @__PURE__ */ g(
|
|
101
|
+
}), L = /* @__PURE__ */ g(ye, [["__scopeId", "data-v-dc2a4bc9"]]), ge = /* @__PURE__ */ T({
|
|
102
102
|
__name: "t-loading-icon",
|
|
103
103
|
props: {
|
|
104
104
|
size: {
|
|
@@ -111,7 +111,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
111
111
|
}
|
|
112
112
|
},
|
|
113
113
|
setup(t) {
|
|
114
|
-
return (n, o) => (
|
|
114
|
+
return (n, o) => (c(), m("span", {
|
|
115
115
|
class: "t-loading-icon",
|
|
116
116
|
style: w({
|
|
117
117
|
width: t.size,
|
|
@@ -122,10 +122,10 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
122
122
|
"aria-label": "Loading..."
|
|
123
123
|
}, null, 4));
|
|
124
124
|
}
|
|
125
|
-
}),
|
|
125
|
+
}), Q = /* @__PURE__ */ g(ge, [["__scopeId", "data-v-7c463303"]]), be = {
|
|
126
126
|
key: 0,
|
|
127
127
|
class: "loader"
|
|
128
|
-
},
|
|
128
|
+
}, he = /* @__PURE__ */ T({
|
|
129
129
|
__name: "t-button",
|
|
130
130
|
props: {
|
|
131
131
|
color: { default: null },
|
|
@@ -178,7 +178,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
178
178
|
"--background": "transparent"
|
|
179
179
|
}), e;
|
|
180
180
|
});
|
|
181
|
-
return (e, r) => (
|
|
181
|
+
return (e, r) => (c(), m("button", {
|
|
182
182
|
class: I(["t-button", { "active-background": n.activeBackground, rounded: n.rounded, block: n.block, ["size-" + n.size]: !0 }]),
|
|
183
183
|
style: w(o.value)
|
|
184
184
|
}, [
|
|
@@ -187,18 +187,18 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
187
187
|
], 512), [
|
|
188
188
|
[Y, !n.loading]
|
|
189
189
|
]),
|
|
190
|
-
n.loading ? (
|
|
191
|
-
|
|
190
|
+
n.loading ? (c(), m("span", be, [
|
|
191
|
+
M(Q, {
|
|
192
192
|
color: "var(--color)",
|
|
193
193
|
type: n.loadingType
|
|
194
194
|
}, null, 8, ["type"])
|
|
195
195
|
])) : z("", !0)
|
|
196
196
|
], 6));
|
|
197
197
|
}
|
|
198
|
-
}),
|
|
198
|
+
}), F = /* @__PURE__ */ g(he, [["__scopeId", "data-v-07bf1b8d"]]), ke = {
|
|
199
199
|
key: 0,
|
|
200
200
|
class: "t-alert-header"
|
|
201
|
-
},
|
|
201
|
+
}, $e = { class: "t-alert-content" }, Te = { class: "t-alert-footer" }, we = /* @__PURE__ */ T({
|
|
202
202
|
__name: "t-alert",
|
|
203
203
|
props: {
|
|
204
204
|
title: {},
|
|
@@ -209,7 +209,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
209
209
|
emits: ["dismiss"],
|
|
210
210
|
setup(t, { expose: n, emit: o }) {
|
|
211
211
|
const e = t, r = y(!1), a = o, l = y();
|
|
212
|
-
let
|
|
212
|
+
let i;
|
|
213
213
|
const u = y(!1), d = () => {
|
|
214
214
|
r.value = !0;
|
|
215
215
|
}, v = (s) => {
|
|
@@ -222,14 +222,14 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
222
222
|
return n({
|
|
223
223
|
open: d
|
|
224
224
|
}), R(() => l.value, (s) => {
|
|
225
|
-
s && (
|
|
225
|
+
s && (i = V(l.value, {
|
|
226
226
|
beforeEvent(f) {
|
|
227
227
|
return f.stopPropagation(), O(f.target) || (f.preventDefault(), q()), !1;
|
|
228
228
|
}
|
|
229
229
|
}));
|
|
230
230
|
}), N(() => {
|
|
231
|
-
|
|
232
|
-
}), (s, f) => (
|
|
231
|
+
i && i.destroy();
|
|
232
|
+
}), (s, f) => (c(), E(L, {
|
|
233
233
|
placement: "center",
|
|
234
234
|
backdrop: !0,
|
|
235
235
|
keepalive: !1,
|
|
@@ -243,14 +243,14 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
243
243
|
ref: l
|
|
244
244
|
}, [
|
|
245
245
|
b(s.$slots, "header", {}, () => [
|
|
246
|
-
e.title ? (
|
|
246
|
+
e.title ? (c(), m("div", ke, P(e.title), 1)) : z("", !0)
|
|
247
247
|
], !0),
|
|
248
248
|
b(s.$slots, "content", {}, () => [
|
|
249
|
-
k("div",
|
|
249
|
+
k("div", $e, P(e.message), 1)
|
|
250
250
|
], !0),
|
|
251
251
|
b(s.$slots, "footer", {}, () => [
|
|
252
|
-
k("div",
|
|
253
|
-
(
|
|
252
|
+
k("div", Te, [
|
|
253
|
+
(c(!0), m(A, null, H(e.actions, (h) => (c(), E(F, {
|
|
254
254
|
color: h.color,
|
|
255
255
|
variant: h.variant,
|
|
256
256
|
onClick: (p) => v(h)
|
|
@@ -267,7 +267,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
267
267
|
_: 3
|
|
268
268
|
}, 8, ["visible"]));
|
|
269
269
|
}
|
|
270
|
-
}), ne = /* @__PURE__ */ g(
|
|
270
|
+
}), ne = /* @__PURE__ */ g(we, [["__scopeId", "data-v-5cf415ec"]]), Wt = (t = {}) => ({
|
|
271
271
|
open() {
|
|
272
272
|
return new Promise((n) => {
|
|
273
273
|
let o = document.body.querySelector(".t-app");
|
|
@@ -279,10 +279,10 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
279
279
|
return j(ne, {
|
|
280
280
|
...t,
|
|
281
281
|
ref: r,
|
|
282
|
-
onDismiss: (l,
|
|
282
|
+
onDismiss: (l, i) => {
|
|
283
283
|
setTimeout(() => {
|
|
284
284
|
a.unmount(), e.remove();
|
|
285
|
-
}, 300), n(
|
|
285
|
+
}, 300), n(i);
|
|
286
286
|
}
|
|
287
287
|
});
|
|
288
288
|
}
|
|
@@ -292,7 +292,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
292
292
|
}, 50);
|
|
293
293
|
});
|
|
294
294
|
}
|
|
295
|
-
}),
|
|
295
|
+
}), xe = /* @__PURE__ */ T({
|
|
296
296
|
__name: "t-action",
|
|
297
297
|
props: {
|
|
298
298
|
actions: {},
|
|
@@ -301,7 +301,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
301
301
|
emits: ["dismiss"],
|
|
302
302
|
setup(t, { expose: n, emit: o }) {
|
|
303
303
|
const e = t, r = y(!1), a = o, l = y();
|
|
304
|
-
let
|
|
304
|
+
let i;
|
|
305
305
|
const u = y(!1), d = () => {
|
|
306
306
|
r.value = !0;
|
|
307
307
|
}, v = (s) => {
|
|
@@ -314,14 +314,14 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
314
314
|
return n({
|
|
315
315
|
open: d
|
|
316
316
|
}), R(() => l.value, (s) => {
|
|
317
|
-
s && (
|
|
317
|
+
s && (i = V(l.value, {
|
|
318
318
|
beforeEvent(f) {
|
|
319
319
|
return f.stopPropagation(), O(f.target) || (f.preventDefault(), q()), !1;
|
|
320
320
|
}
|
|
321
321
|
}));
|
|
322
322
|
}), N(() => {
|
|
323
|
-
|
|
324
|
-
}), (s, f) => (
|
|
323
|
+
i && i.destroy();
|
|
324
|
+
}), (s, f) => (c(), E(L, {
|
|
325
325
|
placement: "bottom",
|
|
326
326
|
backdrop: !0,
|
|
327
327
|
keepalive: !1,
|
|
@@ -334,8 +334,8 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
334
334
|
ref_key: "container",
|
|
335
335
|
ref: l
|
|
336
336
|
}, [
|
|
337
|
-
(
|
|
338
|
-
(
|
|
337
|
+
(c(!0), m(A, null, H(e.actions, (h) => (c(), m("div", null, [
|
|
338
|
+
(c(!0), m(A, null, H(h, (p) => (c(), E(F, {
|
|
339
339
|
color: p.color,
|
|
340
340
|
size: p.size,
|
|
341
341
|
variant: p.variant,
|
|
@@ -353,7 +353,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
353
353
|
_: 1
|
|
354
354
|
}, 8, ["visible"]));
|
|
355
355
|
}
|
|
356
|
-
}),
|
|
356
|
+
}), Ie = /* @__PURE__ */ g(xe, [["__scopeId", "data-v-73339adc"]]), Yt = (t = {}) => ({
|
|
357
357
|
open() {
|
|
358
358
|
return new Promise((n) => {
|
|
359
359
|
let o = document.body.querySelector(".t-app");
|
|
@@ -362,13 +362,13 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
362
362
|
o.appendChild(e);
|
|
363
363
|
const a = U({
|
|
364
364
|
render() {
|
|
365
|
-
return j(
|
|
365
|
+
return j(Ie, {
|
|
366
366
|
...t,
|
|
367
367
|
ref: r,
|
|
368
|
-
onDismiss: (l,
|
|
368
|
+
onDismiss: (l, i) => {
|
|
369
369
|
setTimeout(() => {
|
|
370
370
|
a.unmount(), e.remove();
|
|
371
|
-
}, 300), n(
|
|
371
|
+
}, 300), n(i);
|
|
372
372
|
}
|
|
373
373
|
});
|
|
374
374
|
}
|
|
@@ -378,7 +378,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
378
378
|
}, 50);
|
|
379
379
|
});
|
|
380
380
|
}
|
|
381
|
-
}),
|
|
381
|
+
}), Se = /* @__PURE__ */ T({
|
|
382
382
|
__name: "t-loading",
|
|
383
383
|
props: {
|
|
384
384
|
type: { default: "spinner" }
|
|
@@ -402,7 +402,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
402
402
|
}));
|
|
403
403
|
}), N(() => {
|
|
404
404
|
l && l.destroy();
|
|
405
|
-
}), (d, v) => (
|
|
405
|
+
}), (d, v) => (c(), E(L, {
|
|
406
406
|
placement: "center",
|
|
407
407
|
backdrop: !0,
|
|
408
408
|
keepalive: !1,
|
|
@@ -415,7 +415,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
415
415
|
ref: a
|
|
416
416
|
}, [
|
|
417
417
|
b(d.$slots, "default", {}, () => [
|
|
418
|
-
|
|
418
|
+
M(Q, {
|
|
419
419
|
type: e.type
|
|
420
420
|
}, null, 8, ["type"])
|
|
421
421
|
], !0)
|
|
@@ -424,7 +424,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
424
424
|
_: 3
|
|
425
425
|
}, 8, ["visible"]));
|
|
426
426
|
}
|
|
427
|
-
}),
|
|
427
|
+
}), ze = /* @__PURE__ */ g(Se, [["__scopeId", "data-v-d048a41d"]]), Ht = (t = {}) => {
|
|
428
428
|
const n = y(), o = document.body.querySelector(".t-app");
|
|
429
429
|
let e = null, r = null;
|
|
430
430
|
return {
|
|
@@ -432,7 +432,7 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
432
432
|
return new Promise((a) => {
|
|
433
433
|
o && (r = document.createElement("div"), o.appendChild(r), e = U({
|
|
434
434
|
render() {
|
|
435
|
-
return j(
|
|
435
|
+
return j(ze, {
|
|
436
436
|
...t,
|
|
437
437
|
ref: n
|
|
438
438
|
});
|
|
@@ -450,25 +450,25 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
450
450
|
});
|
|
451
451
|
}
|
|
452
452
|
};
|
|
453
|
-
}, Z = y(1e3),
|
|
453
|
+
}, Z = y(1e3), Ee = {
|
|
454
454
|
getNewIndex() {
|
|
455
455
|
return Z.value += 2, Z.value;
|
|
456
456
|
}
|
|
457
|
-
}, C = te([]),
|
|
457
|
+
}, C = te([]), Be = (t) => {
|
|
458
458
|
C.push(t);
|
|
459
|
-
},
|
|
459
|
+
}, Ce = (t) => {
|
|
460
460
|
t || C.pop();
|
|
461
461
|
}, $ = {
|
|
462
462
|
screens: C,
|
|
463
|
-
addScreen:
|
|
464
|
-
removeScreen:
|
|
463
|
+
addScreen: Be,
|
|
464
|
+
removeScreen: Ce,
|
|
465
465
|
hasPrevious: S(() => C.length > 1),
|
|
466
466
|
currentScreen: S(() => C[C.length - 1]),
|
|
467
467
|
lastScreen: S(() => {
|
|
468
468
|
if (!(C.length < 2))
|
|
469
469
|
return C[C.length - 2];
|
|
470
470
|
})
|
|
471
|
-
},
|
|
471
|
+
}, Pe = /* @__PURE__ */ T({
|
|
472
472
|
__name: "t-toast",
|
|
473
473
|
props: {
|
|
474
474
|
message: {},
|
|
@@ -480,14 +480,14 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
480
480
|
},
|
|
481
481
|
emits: ["dismiss"],
|
|
482
482
|
setup(t, { expose: n, emit: o }) {
|
|
483
|
-
const e = t, r = o, a = y(!1), l = y(!1),
|
|
484
|
-
l.value = !0,
|
|
483
|
+
const e = t, r = o, a = y(!1), l = y(!1), i = y(!1), u = () => {
|
|
484
|
+
l.value = !0, i.value = !1, setTimeout(() => {
|
|
485
485
|
a.value = !0;
|
|
486
486
|
}, 10), setTimeout(() => {
|
|
487
487
|
d();
|
|
488
488
|
}, e.duration + 10);
|
|
489
489
|
}, d = () => {
|
|
490
|
-
|
|
490
|
+
i.value = !0, setTimeout(() => {
|
|
491
491
|
l.value = !1, a.value = !1, r("dismiss");
|
|
492
492
|
}, 300);
|
|
493
493
|
}, v = S(() => {
|
|
@@ -532,13 +532,13 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
532
532
|
});
|
|
533
533
|
return n({
|
|
534
534
|
open: u
|
|
535
|
-
}), (_, s) => l.value ? (
|
|
535
|
+
}), (_, s) => l.value ? (c(), m("div", {
|
|
536
536
|
key: 0,
|
|
537
|
-
class: I(["t-toast", { [e.placement]: !0, open: a.value, closing:
|
|
537
|
+
class: I(["t-toast", { [e.placement]: !0, open: a.value, closing: i.value }]),
|
|
538
538
|
style: w({ "--space": e.space, ...v.value })
|
|
539
539
|
}, P(e.message), 7)) : z("", !0);
|
|
540
540
|
}
|
|
541
|
-
}), re = /* @__PURE__ */ g(
|
|
541
|
+
}), re = /* @__PURE__ */ g(Pe, [["__scopeId", "data-v-98e8be37"]]), Ut = (t = {}) => ({
|
|
542
542
|
open() {
|
|
543
543
|
let n = document.body.querySelector(".t-app");
|
|
544
544
|
if (!n) return;
|
|
@@ -561,28 +561,28 @@ const ye = /* @__PURE__ */ g(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
|
561
561
|
e.value?.open?.();
|
|
562
562
|
}, 50);
|
|
563
563
|
}
|
|
564
|
-
}),
|
|
565
|
-
function
|
|
564
|
+
}), De = y(0);
|
|
565
|
+
function Re() {
|
|
566
566
|
return {
|
|
567
|
-
height:
|
|
567
|
+
height: De
|
|
568
568
|
};
|
|
569
569
|
}
|
|
570
|
-
const
|
|
570
|
+
const Ve = /* @__PURE__ */ T({
|
|
571
571
|
__name: "t-cable",
|
|
572
572
|
props: {
|
|
573
573
|
keyboard: { type: Boolean, default: !0 },
|
|
574
574
|
placement: { default: "bottom" }
|
|
575
575
|
},
|
|
576
576
|
setup(t) {
|
|
577
|
-
const n = t, { height: o } =
|
|
578
|
-
return (e, r) => (
|
|
577
|
+
const n = t, { height: o } = Re();
|
|
578
|
+
return (e, r) => (c(), m("div", {
|
|
579
579
|
class: I(["t-cable", { keyboard: n.keyboard && D(o) > 0, [n.placement]: !0 }]),
|
|
580
580
|
style: w({ "--t-keyboard-height": D(o) + "px", "--t-keyboard-transition": D(o) > 0 ? "0.3s" : "0.1s" })
|
|
581
581
|
}, [
|
|
582
582
|
b(e.$slots, "default", {}, void 0, !0)
|
|
583
583
|
], 6));
|
|
584
584
|
}
|
|
585
|
-
}),
|
|
585
|
+
}), Ae = /* @__PURE__ */ g(Ve, [["__scopeId", "data-v-ecb72421"]]), Ne = /* @__PURE__ */ T({
|
|
586
586
|
__name: "t-card",
|
|
587
587
|
props: {
|
|
588
588
|
color: { default: null }
|
|
@@ -598,31 +598,31 @@ const Ae = /* @__PURE__ */ T({
|
|
|
598
598
|
"--background": "var(--t-color-surface)"
|
|
599
599
|
}, e;
|
|
600
600
|
});
|
|
601
|
-
return (e, r) => (
|
|
601
|
+
return (e, r) => (c(), m("div", {
|
|
602
602
|
class: "t-card",
|
|
603
603
|
style: w(o.value)
|
|
604
604
|
}, [
|
|
605
605
|
b(e.$slots, "default")
|
|
606
606
|
], 4));
|
|
607
607
|
}
|
|
608
|
-
}),
|
|
609
|
-
function
|
|
610
|
-
return
|
|
608
|
+
}), Oe = {}, qe = { class: "t-content" };
|
|
609
|
+
function Xe(t, n) {
|
|
610
|
+
return c(), m("div", qe, [
|
|
611
611
|
b(t.$slots, "default", {}, void 0, !0)
|
|
612
612
|
]);
|
|
613
613
|
}
|
|
614
|
-
const
|
|
614
|
+
const Le = /* @__PURE__ */ g(Oe, [["render", Xe], ["__scopeId", "data-v-9a833657"]]), ee = 80, We = /* @__PURE__ */ T({
|
|
615
615
|
__name: "t-refresher",
|
|
616
616
|
emits: ["refresh"],
|
|
617
617
|
setup(t, { emit: n }) {
|
|
618
618
|
const o = n, e = y(0), r = y(!1), a = y();
|
|
619
|
-
let l,
|
|
619
|
+
let l, i = !1;
|
|
620
620
|
const u = () => {
|
|
621
621
|
r.value = !1, e.value = 0, l && l.cancel(), setTimeout(() => {
|
|
622
|
-
|
|
622
|
+
i = !1;
|
|
623
623
|
}, 2e3);
|
|
624
624
|
}, d = () => {
|
|
625
|
-
|
|
625
|
+
i = !0, r.value = !0, e.value = ee, o("refresh", u);
|
|
626
626
|
};
|
|
627
627
|
return R(() => a.value, () => {
|
|
628
628
|
l && l.destroy();
|
|
@@ -632,10 +632,10 @@ const We = /* @__PURE__ */ g(qe, [["render", Le], ["__scopeId", "data-v-9a833657
|
|
|
632
632
|
minDist: 60
|
|
633
633
|
},
|
|
634
634
|
move({ dy: _ }) {
|
|
635
|
-
r.value ||
|
|
635
|
+
r.value || i || _ < 0 || (_ >= 120 ? d() : e.value = _);
|
|
636
636
|
},
|
|
637
637
|
up({ dy: _ }) {
|
|
638
|
-
r.value ||
|
|
638
|
+
r.value || i || (_ > ee ? d() : e.value = 0);
|
|
639
639
|
},
|
|
640
640
|
cancel() {
|
|
641
641
|
r.value = !1, e.value = 0;
|
|
@@ -643,7 +643,7 @@ const We = /* @__PURE__ */ g(qe, [["render", Le], ["__scopeId", "data-v-9a833657
|
|
|
643
643
|
}));
|
|
644
644
|
}), N(() => {
|
|
645
645
|
l && l.destroy();
|
|
646
|
-
}), (v, _) => W((
|
|
646
|
+
}), (v, _) => W((c(), m("div", {
|
|
647
647
|
class: "t-refresher",
|
|
648
648
|
ref_key: "container",
|
|
649
649
|
ref: a,
|
|
@@ -659,18 +659,18 @@ const We = /* @__PURE__ */ g(qe, [["render", Le], ["__scopeId", "data-v-9a833657
|
|
|
659
659
|
[Y, e.value > 0]
|
|
660
660
|
]);
|
|
661
661
|
}
|
|
662
|
-
}),
|
|
663
|
-
function
|
|
664
|
-
return
|
|
662
|
+
}), Ye = /* @__PURE__ */ g(We, [["__scopeId", "data-v-688c5394"]]), He = {}, Ue = { class: "t-screen" };
|
|
663
|
+
function je(t, n) {
|
|
664
|
+
return c(), m("div", Ue, [
|
|
665
665
|
b(t.$slots, "default", {}, void 0, !0)
|
|
666
666
|
]);
|
|
667
667
|
}
|
|
668
|
-
const se = /* @__PURE__ */ g(
|
|
668
|
+
const se = /* @__PURE__ */ g(He, [["render", je], ["__scopeId", "data-v-66ea8649"]]), Fe = /* @__PURE__ */ T({
|
|
669
669
|
__name: "t-swipe-screen",
|
|
670
670
|
emits: ["change"],
|
|
671
671
|
setup(t, { emit: n }) {
|
|
672
672
|
let o = {};
|
|
673
|
-
const e = oe(), r =
|
|
673
|
+
const e = oe(), r = de(), a = e.getRoutes(), l = y(!1), i = n;
|
|
674
674
|
for (let s of a)
|
|
675
675
|
o[s.name] = s.components;
|
|
676
676
|
const u = (s) => {
|
|
@@ -682,12 +682,12 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
682
682
|
}, d = (s, f) => {
|
|
683
683
|
!f || $.screens[s].target || ($.screens[s].target = f.$el, s > 0 && (l.value = !0, f.$el.style.transform = "translateX(100vw)", f.$el.transitionOrigin = "center", document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), setTimeout(() => {
|
|
684
684
|
f.$el.style.transition = "transform 0.35s ease", f.$el.style.transform = "translateX(0px)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), $.screens.length > 1 && ($.lastScreen.value.target.style.transitionOrigin = "left center", $.lastScreen.value.target.style.transition = "transform 0.35s ease", $.lastScreen.value.target.style.transform = "translateX(-30vw) scale(0.5) perspective(100vw) rotateY(30deg)"), setTimeout(() => {
|
|
685
|
-
|
|
685
|
+
i("change"), l.value = !1;
|
|
686
686
|
}, 400);
|
|
687
687
|
}, 100)));
|
|
688
688
|
}, v = () => {
|
|
689
689
|
$.currentScreen.value.target.style.transition = "transform 0.35s ease", $.currentScreen.value.target.style.transform = "translateX(100vw) scale(1)", $.lastScreen.value.target.style.transition = "transform 0.35s ease", $.lastScreen.value.target.style.transform = "translateX(0px) scale(1) perspective(100vw) rotateY(0deg)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), l.value = !0, setTimeout(() => {
|
|
690
|
-
$.removeScreen(),
|
|
690
|
+
$.removeScreen(), i("change"), l.value = !1;
|
|
691
691
|
}, 400);
|
|
692
692
|
};
|
|
693
693
|
u(r.name), R(() => r.name, (s, f) => {
|
|
@@ -700,7 +700,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
700
700
|
l.value = !1;
|
|
701
701
|
}, 400);
|
|
702
702
|
};
|
|
703
|
-
return
|
|
703
|
+
return J(() => {
|
|
704
704
|
V(document, {
|
|
705
705
|
pointerId: null,
|
|
706
706
|
beforeEvent(s) {
|
|
@@ -727,15 +727,15 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
727
727
|
_();
|
|
728
728
|
}
|
|
729
729
|
});
|
|
730
|
-
}), (s, f) => (
|
|
731
|
-
(
|
|
730
|
+
}), (s, f) => (c(), m(A, null, [
|
|
731
|
+
(c(!0), m(A, null, H(D($).screens, (h, p) => (c(), E(se, {
|
|
732
732
|
ref_for: !0,
|
|
733
733
|
ref: (x) => d(p, x),
|
|
734
734
|
style: w({ zIndex: p + (p == D($).screens.length - 1 ? 2 : 1) }),
|
|
735
735
|
key: p
|
|
736
736
|
}, {
|
|
737
737
|
default: B(() => [
|
|
738
|
-
(
|
|
738
|
+
(c(), E(le(h.component.default)))
|
|
739
739
|
]),
|
|
740
740
|
_: 2
|
|
741
741
|
}, 1032, ["style"]))), 128)),
|
|
@@ -745,7 +745,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
745
745
|
}, null, 4)
|
|
746
746
|
], 64));
|
|
747
747
|
}
|
|
748
|
-
}),
|
|
748
|
+
}), Ge = /* @__PURE__ */ g(Fe, [["__scopeId", "data-v-a048cc07"]]), Ke = /* @__PURE__ */ T({
|
|
749
749
|
__name: "t-toolbar",
|
|
750
750
|
props: {
|
|
751
751
|
placement: { default: "bottom" },
|
|
@@ -753,7 +753,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
753
753
|
},
|
|
754
754
|
setup(t) {
|
|
755
755
|
const n = t;
|
|
756
|
-
return (o, e) => (
|
|
756
|
+
return (o, e) => (c(), m("div", {
|
|
757
757
|
class: I(["t-toolbar", { [n.placement]: !0 }]),
|
|
758
758
|
style: w({ "--t-size-toolbar": n.size })
|
|
759
759
|
}, [
|
|
@@ -762,7 +762,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
762
762
|
])
|
|
763
763
|
], 6));
|
|
764
764
|
}
|
|
765
|
-
}),
|
|
765
|
+
}), Me = /* @__PURE__ */ g(Ke, [["__scopeId", "data-v-3b3a7896"]]), Je = /* @__PURE__ */ T({
|
|
766
766
|
__name: "t-back-button",
|
|
767
767
|
props: {
|
|
768
768
|
to: {}
|
|
@@ -771,7 +771,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
771
771
|
const n = oe(), o = t, e = () => {
|
|
772
772
|
$.hasPrevious.value ? n?.back?.() : o.to && n?.push?.(o.to);
|
|
773
773
|
};
|
|
774
|
-
return (r, a) => r.to || D($).hasPrevious ? (
|
|
774
|
+
return (r, a) => r.to || D($).hasPrevious ? (c(), m("button", {
|
|
775
775
|
key: 0,
|
|
776
776
|
class: "t-back-button",
|
|
777
777
|
onClick: e
|
|
@@ -781,7 +781,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
781
781
|
], !0)
|
|
782
782
|
])) : z("", !0);
|
|
783
783
|
}
|
|
784
|
-
}),
|
|
784
|
+
}), Qe = /* @__PURE__ */ g(Je, [["__scopeId", "data-v-ed626a3d"]]), Ze = /* @__PURE__ */ T({
|
|
785
785
|
__name: "t-text",
|
|
786
786
|
props: {
|
|
787
787
|
color: { default: "var(--t-color-text)" },
|
|
@@ -795,24 +795,24 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
795
795
|
"--font-size": e
|
|
796
796
|
};
|
|
797
797
|
});
|
|
798
|
-
return (e, r) => (
|
|
798
|
+
return (e, r) => (c(), m("span", {
|
|
799
799
|
class: "t-text",
|
|
800
800
|
style: w(o.value)
|
|
801
801
|
}, [
|
|
802
802
|
b(e.$slots, "default", {}, void 0, !0)
|
|
803
803
|
], 4));
|
|
804
804
|
}
|
|
805
|
-
}),
|
|
805
|
+
}), K = /* @__PURE__ */ g(Ze, [["__scopeId", "data-v-f0f94f05"]]), et = /* @__PURE__ */ T({
|
|
806
806
|
__name: "t-pull-signal",
|
|
807
807
|
props: {
|
|
808
808
|
placement: { default: "bottom" }
|
|
809
809
|
},
|
|
810
810
|
setup(t) {
|
|
811
|
-
return (n, o) => (
|
|
811
|
+
return (n, o) => (c(), m("div", {
|
|
812
812
|
class: I(["t-pull-bar", { [n.placement]: !0 }])
|
|
813
813
|
}, null, 2));
|
|
814
814
|
}
|
|
815
|
-
}), ae = /* @__PURE__ */ g(
|
|
815
|
+
}), ae = /* @__PURE__ */ g(et, [["__scopeId", "data-v-daa38c85"]]), tt = /* @__PURE__ */ T({
|
|
816
816
|
__name: "t-sheet",
|
|
817
817
|
props: {
|
|
818
818
|
background: { default: "var(--t-color-surface)" },
|
|
@@ -829,7 +829,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
829
829
|
emits: ["dismiss"],
|
|
830
830
|
setup(t, { emit: n }) {
|
|
831
831
|
const o = t, e = n, r = y(), a = y(), l = y(!1);
|
|
832
|
-
let
|
|
832
|
+
let i = null;
|
|
833
833
|
const u = S(() => {
|
|
834
834
|
if (o.placement == "bottom") return "down";
|
|
835
835
|
if (o.placement == "top") return "up";
|
|
@@ -843,7 +843,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
843
843
|
}, 300);
|
|
844
844
|
};
|
|
845
845
|
return R(() => r.value, (_) => {
|
|
846
|
-
_ && (
|
|
846
|
+
_ && (i = V(r.value, {
|
|
847
847
|
options: {
|
|
848
848
|
minDist: 30
|
|
849
849
|
},
|
|
@@ -871,16 +871,16 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
871
871
|
a.value.open();
|
|
872
872
|
return;
|
|
873
873
|
}
|
|
874
|
-
let p, x,
|
|
875
|
-
o.placement == "bottom" || o.placement == "top" ? (p = r.value.offsetHeight,
|
|
874
|
+
let p, x, G;
|
|
875
|
+
o.placement == "bottom" || o.placement == "top" ? (p = r.value.offsetHeight, G = s) : (p = r.value.offsetWidth, G = f), x = G / p * 100, x > 50 ? e("dismiss", "gesture") : a.value.open();
|
|
876
876
|
},
|
|
877
877
|
cancel() {
|
|
878
878
|
v(), a.value.open();
|
|
879
879
|
}
|
|
880
880
|
}));
|
|
881
881
|
}), N(() => {
|
|
882
|
-
|
|
883
|
-
}), (_, s) => (
|
|
882
|
+
i && i.destroy();
|
|
883
|
+
}), (_, s) => (c(), E(L, {
|
|
884
884
|
ref_key: "present",
|
|
885
885
|
ref: a,
|
|
886
886
|
placement: o.placement,
|
|
@@ -890,11 +890,11 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
890
890
|
onDismiss: d
|
|
891
891
|
}, {
|
|
892
892
|
default: B(() => [
|
|
893
|
-
o.gesture && o.placement != "center" ? (
|
|
893
|
+
o.gesture && o.placement != "center" ? (c(), E(ae, {
|
|
894
894
|
key: 0,
|
|
895
895
|
placement: o.placement
|
|
896
896
|
}, null, 8, ["placement"])) : z("", !0),
|
|
897
|
-
o.closeButton && o.placement == "center" ? (
|
|
897
|
+
o.closeButton && o.placement == "center" ? (c(), m("button", {
|
|
898
898
|
key: 1,
|
|
899
899
|
class: "t-sheet-close",
|
|
900
900
|
onClick: s[0] || (s[0] = (f) => d("close-button"))
|
|
@@ -915,7 +915,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
915
915
|
_: 3
|
|
916
916
|
}, 8, ["placement", "backdrop", "visible", "keepalive"]));
|
|
917
917
|
}
|
|
918
|
-
}),
|
|
918
|
+
}), ot = /* @__PURE__ */ g(tt, [["__scopeId", "data-v-14b7fc93"]]), nt = { class: "t-input-label" }, rt = { class: "t-input-content" }, st = ["type", "placeholder", "value"], at = /* @__PURE__ */ T({
|
|
919
919
|
__name: "t-input",
|
|
920
920
|
props: {
|
|
921
921
|
size: { default: "standard" },
|
|
@@ -933,23 +933,23 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
933
933
|
const o = t, e = n, r = (a) => {
|
|
934
934
|
e("update:modelValue", a.target.value);
|
|
935
935
|
};
|
|
936
|
-
return (a, l) => (
|
|
936
|
+
return (a, l) => (c(), m("div", {
|
|
937
937
|
class: I(["t-input", { rounded: o.rounded, ["size-" + o.size]: !0, ["variant-" + o.variant]: !0 }])
|
|
938
938
|
}, [
|
|
939
939
|
k("label", null, [
|
|
940
|
-
k("span",
|
|
941
|
-
k("div",
|
|
940
|
+
k("span", nt, P(a.label), 1),
|
|
941
|
+
k("div", rt, [
|
|
942
942
|
b(a.$slots, "start", {}, void 0, !0),
|
|
943
943
|
k("input", {
|
|
944
944
|
type: a.type,
|
|
945
945
|
placeholder: a.placeholder,
|
|
946
946
|
value: a.modelValue,
|
|
947
947
|
onInput: r
|
|
948
|
-
}, null, 40,
|
|
948
|
+
}, null, 40, st),
|
|
949
949
|
b(a.$slots, "end", {}, void 0, !0)
|
|
950
950
|
])
|
|
951
951
|
]),
|
|
952
|
-
o.error ? (
|
|
952
|
+
o.error ? (c(), E(K, {
|
|
953
953
|
key: 0,
|
|
954
954
|
color: "danger"
|
|
955
955
|
}, {
|
|
@@ -957,7 +957,7 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
957
957
|
X(P(o.error), 1)
|
|
958
958
|
]),
|
|
959
959
|
_: 1
|
|
960
|
-
})) : o.help ? (
|
|
960
|
+
})) : o.help ? (c(), E(K, {
|
|
961
961
|
key: 1,
|
|
962
962
|
color: "secondary"
|
|
963
963
|
}, {
|
|
@@ -968,34 +968,34 @@ const se = /* @__PURE__ */ g(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
968
968
|
})) : z("", !0)
|
|
969
969
|
], 2));
|
|
970
970
|
}
|
|
971
|
-
}),
|
|
972
|
-
function
|
|
973
|
-
return
|
|
971
|
+
}), lt = /* @__PURE__ */ g(at, [["__scopeId", "data-v-1a9425cf"]]), ct = {};
|
|
972
|
+
function it(t, n) {
|
|
973
|
+
return c(), m("textarea");
|
|
974
974
|
}
|
|
975
|
-
const
|
|
976
|
-
function
|
|
977
|
-
return
|
|
975
|
+
const ut = /* @__PURE__ */ g(ct, [["render", it]]), dt = {};
|
|
976
|
+
function pt(t, n) {
|
|
977
|
+
return c(), m("div");
|
|
978
978
|
}
|
|
979
|
-
const
|
|
980
|
-
function
|
|
981
|
-
return
|
|
979
|
+
const ft = /* @__PURE__ */ g(dt, [["render", pt]]), mt = {}, vt = { class: "t-grid" };
|
|
980
|
+
function _t(t, n) {
|
|
981
|
+
return c(), m("div", vt);
|
|
982
982
|
}
|
|
983
|
-
const
|
|
984
|
-
function
|
|
985
|
-
return
|
|
983
|
+
const yt = /* @__PURE__ */ g(mt, [["render", _t]]), gt = {}, bt = { class: "t-grid-item" };
|
|
984
|
+
function ht(t, n) {
|
|
985
|
+
return c(), m("div", bt);
|
|
986
986
|
}
|
|
987
|
-
const
|
|
987
|
+
const kt = /* @__PURE__ */ g(gt, [["render", ht]]), $t = /* @__PURE__ */ T({
|
|
988
988
|
__name: "t-divider",
|
|
989
989
|
props: {
|
|
990
990
|
direction: { default: "horizontal" }
|
|
991
991
|
},
|
|
992
992
|
setup(t) {
|
|
993
993
|
const n = t;
|
|
994
|
-
return (o, e) => (
|
|
994
|
+
return (o, e) => (c(), m("div", {
|
|
995
995
|
class: I(["t-divider", { [n.direction]: !0 }])
|
|
996
996
|
}, null, 2));
|
|
997
997
|
}
|
|
998
|
-
}),
|
|
998
|
+
}), Tt = /* @__PURE__ */ g($t, [["__scopeId", "data-v-47ee8991"]]), wt = /* @__PURE__ */ T({
|
|
999
999
|
__name: "t-toggle-password",
|
|
1000
1000
|
props: {
|
|
1001
1001
|
color: { default: "warning" }
|
|
@@ -1007,16 +1007,16 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1007
1007
|
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(o.color) && (d = `var(--t-color-status-${o.color})`), {
|
|
1008
1008
|
"--color": d
|
|
1009
1009
|
};
|
|
1010
|
-
}),
|
|
1011
|
-
|
|
1012
|
-
let d =
|
|
1010
|
+
}), i = () => a.value?.parentElement?.querySelector?.("input");
|
|
1011
|
+
J(() => {
|
|
1012
|
+
let d = i();
|
|
1013
1013
|
d && (r.value = d.type != "password", e("change", r.value));
|
|
1014
1014
|
});
|
|
1015
1015
|
const u = () => {
|
|
1016
|
-
let d =
|
|
1016
|
+
let d = i();
|
|
1017
1017
|
d && (r.value = !r.value, r.value ? d.type = "text" : d.type = "password", e("change", r.value));
|
|
1018
1018
|
};
|
|
1019
|
-
return (d, v) => (
|
|
1019
|
+
return (d, v) => (c(), m("button", {
|
|
1020
1020
|
ref_key: "toggle",
|
|
1021
1021
|
ref: a,
|
|
1022
1022
|
class: "t-toggle-password",
|
|
@@ -1031,7 +1031,7 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1031
1031
|
], !0)
|
|
1032
1032
|
], 4));
|
|
1033
1033
|
}
|
|
1034
|
-
}),
|
|
1034
|
+
}), xt = /* @__PURE__ */ g(wt, [["__scopeId", "data-v-3268e9e3"]]), It = /* @__PURE__ */ T({
|
|
1035
1035
|
__name: "t-avatar",
|
|
1036
1036
|
props: {
|
|
1037
1037
|
square: { type: Boolean, default: !1 },
|
|
@@ -1039,52 +1039,52 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1039
1039
|
},
|
|
1040
1040
|
setup(t) {
|
|
1041
1041
|
const n = t, o = S(() => n.size == "small" ? "24px" : n.size == "standard" ? "40px" : n.size == "large" ? "60px" : n.size);
|
|
1042
|
-
return (e, r) => (
|
|
1042
|
+
return (e, r) => (c(), m("div", {
|
|
1043
1043
|
class: I(["t-avatar", { square: e.square }]),
|
|
1044
1044
|
style: w({ "--size": o.value })
|
|
1045
1045
|
}, [
|
|
1046
1046
|
b(e.$slots, "default", {}, void 0, !0)
|
|
1047
1047
|
], 6));
|
|
1048
1048
|
}
|
|
1049
|
-
}),
|
|
1049
|
+
}), St = /* @__PURE__ */ g(It, [["__scopeId", "data-v-24384c2f"]]), zt = { class: "t-collapse-title" }, Et = {
|
|
1050
1050
|
key: 0,
|
|
1051
1051
|
class: "icon"
|
|
1052
|
-
},
|
|
1052
|
+
}, Bt = {
|
|
1053
1053
|
key: 1,
|
|
1054
1054
|
class: "icon"
|
|
1055
|
-
},
|
|
1055
|
+
}, Ct = { class: "t-collapse-content" }, Pt = /* @__PURE__ */ T({
|
|
1056
1056
|
__name: "t-collapse",
|
|
1057
1057
|
props: {
|
|
1058
1058
|
title: {}
|
|
1059
1059
|
},
|
|
1060
1060
|
emits: ["change"],
|
|
1061
1061
|
setup(t, { emit: n }) {
|
|
1062
|
-
const o = t, e = n, r = y(!1), a = y(""), l = y(),
|
|
1062
|
+
const o = t, e = n, r = y(!1), a = y(""), l = y(), i = () => {
|
|
1063
1063
|
r.value = !r.value, a.value = `calc(${l.value.offsetHeight}px + 2rem)`, e("change", r.value);
|
|
1064
1064
|
};
|
|
1065
|
-
return e("change", r.value), (u, d) => (
|
|
1065
|
+
return e("change", r.value), (u, d) => (c(), m("div", {
|
|
1066
1066
|
class: I(["t-collapse", { open: r.value }]),
|
|
1067
1067
|
style: w({ "--height": a.value })
|
|
1068
1068
|
}, [
|
|
1069
1069
|
k("div", {
|
|
1070
1070
|
class: "t-collapse-header",
|
|
1071
|
-
onClick:
|
|
1071
|
+
onClick: i
|
|
1072
1072
|
}, [
|
|
1073
1073
|
b(u.$slots, "icon"),
|
|
1074
|
-
k("div",
|
|
1074
|
+
k("div", zt, [
|
|
1075
1075
|
b(u.$slots, "title", {}, () => [
|
|
1076
1076
|
X(P(o.title), 1)
|
|
1077
1077
|
])
|
|
1078
1078
|
]),
|
|
1079
1079
|
b(u.$slots, "toggle", {}, () => [
|
|
1080
|
-
r.value ? (
|
|
1080
|
+
r.value ? (c(), m("div", Et, [...d[0] || (d[0] = [
|
|
1081
1081
|
k("i", { class: "ri-arrow-up-s-line" }, null, -1)
|
|
1082
|
-
])])) : (
|
|
1082
|
+
])])) : (c(), m("div", Bt, [...d[1] || (d[1] = [
|
|
1083
1083
|
k("i", { class: "ri-arrow-down-s-line" }, null, -1)
|
|
1084
1084
|
])]))
|
|
1085
1085
|
])
|
|
1086
1086
|
]),
|
|
1087
|
-
k("div",
|
|
1087
|
+
k("div", Ct, [
|
|
1088
1088
|
k("div", {
|
|
1089
1089
|
ref_key: "content",
|
|
1090
1090
|
ref: l
|
|
@@ -1096,7 +1096,7 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1096
1096
|
])
|
|
1097
1097
|
], 6));
|
|
1098
1098
|
}
|
|
1099
|
-
}),
|
|
1099
|
+
}), Dt = /* @__PURE__ */ T({
|
|
1100
1100
|
__name: "t-switch",
|
|
1101
1101
|
props: {
|
|
1102
1102
|
modelValue: { type: Boolean },
|
|
@@ -1116,15 +1116,15 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1116
1116
|
"--color": `var(--t-color-status-${o.color}-text)`
|
|
1117
1117
|
}), l;
|
|
1118
1118
|
});
|
|
1119
|
-
return (l,
|
|
1119
|
+
return (l, i) => (c(), m("div", {
|
|
1120
1120
|
class: I(["t-switch", { on: o.modelValue }]),
|
|
1121
1121
|
style: w(a.value),
|
|
1122
1122
|
onClick: r
|
|
1123
|
-
}, [...
|
|
1123
|
+
}, [...i[0] || (i[0] = [
|
|
1124
1124
|
k("div", { class: "t-switch-icon" }, null, -1)
|
|
1125
1125
|
])], 6));
|
|
1126
1126
|
}
|
|
1127
|
-
}),
|
|
1127
|
+
}), Rt = /* @__PURE__ */ g(Dt, [["__scopeId", "data-v-3616970e"]]), Vt = /* @__PURE__ */ T({
|
|
1128
1128
|
__name: "t-tab",
|
|
1129
1129
|
props: {
|
|
1130
1130
|
value: {}
|
|
@@ -1133,25 +1133,22 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1133
1133
|
const n = t, o = ie("tabsState"), e = S(() => o.active.value === n.value), r = () => {
|
|
1134
1134
|
o.setActive(n.value);
|
|
1135
1135
|
};
|
|
1136
|
-
return (a, l) => {
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
}, 8, ["color"])
|
|
1151
|
-
], 2);
|
|
1152
|
-
};
|
|
1136
|
+
return (a, l) => (c(), m("li", {
|
|
1137
|
+
class: I(["t-tab", { active: e.value }])
|
|
1138
|
+
}, [
|
|
1139
|
+
M(F, {
|
|
1140
|
+
variant: "text",
|
|
1141
|
+
onClick: r,
|
|
1142
|
+
color: e.value && D(o).variant == "text" ? D(o).color : void 0
|
|
1143
|
+
}, {
|
|
1144
|
+
default: B(() => [
|
|
1145
|
+
b(a.$slots, "default", {}, void 0, !0)
|
|
1146
|
+
]),
|
|
1147
|
+
_: 3
|
|
1148
|
+
}, 8, ["color"])
|
|
1149
|
+
], 2));
|
|
1153
1150
|
}
|
|
1154
|
-
}),
|
|
1151
|
+
}), At = /* @__PURE__ */ g(Vt, [["__scopeId", "data-v-059bab6e"]]), Nt = /* @__PURE__ */ T({
|
|
1155
1152
|
__name: "t-tabs",
|
|
1156
1153
|
props: {
|
|
1157
1154
|
placement: { default: "top-start" },
|
|
@@ -1165,7 +1162,7 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1165
1162
|
const o = t, e = n, r = y("0px"), a = y(), l = S(() => {
|
|
1166
1163
|
let u = o.color;
|
|
1167
1164
|
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(u) && (u = `var(--t-color-status-${u})`), u;
|
|
1168
|
-
}),
|
|
1165
|
+
}), i = () => {
|
|
1169
1166
|
setTimeout(() => {
|
|
1170
1167
|
if (o.placement.startsWith("top-") || o.placement.startsWith("bottom-")) {
|
|
1171
1168
|
let u = a.value.querySelector(".active");
|
|
@@ -1182,16 +1179,16 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1182
1179
|
}
|
|
1183
1180
|
}, 50);
|
|
1184
1181
|
};
|
|
1185
|
-
return
|
|
1182
|
+
return ue("tabsState", {
|
|
1186
1183
|
active: S(() => o.modelValue),
|
|
1187
1184
|
color: l.value,
|
|
1188
1185
|
variant: o.variant,
|
|
1189
1186
|
setActive: (u) => {
|
|
1190
|
-
e("update:modelValue", u),
|
|
1187
|
+
e("update:modelValue", u), i();
|
|
1191
1188
|
}
|
|
1192
|
-
}),
|
|
1193
|
-
|
|
1194
|
-
}), (u, d) => (
|
|
1189
|
+
}), J(() => {
|
|
1190
|
+
i();
|
|
1191
|
+
}), (u, d) => (c(), m("ul", {
|
|
1195
1192
|
ref_key: "container",
|
|
1196
1193
|
ref: a,
|
|
1197
1194
|
class: I(["t-tabs", { [u.placement]: !0, [u.variant]: !0 }]),
|
|
@@ -1200,20 +1197,20 @@ const $t = /* @__PURE__ */ g(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1200
1197
|
b(u.$slots, "default", {}, void 0, !0)
|
|
1201
1198
|
], 6));
|
|
1202
1199
|
}
|
|
1203
|
-
}),
|
|
1200
|
+
}), Ot = /* @__PURE__ */ g(Nt, [["__scopeId", "data-v-2f040d31"]]), jt = () => ({
|
|
1204
1201
|
install: (t) => {
|
|
1205
|
-
|
|
1202
|
+
pe(), t.component("t-app", _e), t.component("t-screen", se), t.component("t-swipe-screen", Ge), t.component("t-cable", Ae), t.component("t-toolbar", Me), t.component("t-content", Le), t.component("t-card", Ne), t.component("t-refresher", Ye), t.component("t-button", F), t.component("t-back-button", Qe), t.component("t-present", L), t.component("t-text", K), t.component("t-sheet", ot), t.component("t-pull-signal", ae), t.component("t-input", lt), t.component("t-textarea", ut), t.component("t-rich-text", ft), t.component("t-grid", yt), t.component("t-grid-item", kt), t.component("t-divider", Tt), t.component("t-toggle-password", xt), t.component("t-loading-icon", Q), t.component("t-alert", ne), t.component("t-avatar", St), t.component("t-collapse", Pt), t.component("t-toast", re), t.component("t-switch", Rt), t.component("t-tab", At), t.component("t-tabs", Ot);
|
|
1206
1203
|
}
|
|
1207
1204
|
});
|
|
1208
1205
|
export {
|
|
1209
1206
|
q as blurCurrentActive,
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1207
|
+
Yt as createAction,
|
|
1208
|
+
Wt as createAlert,
|
|
1209
|
+
Ht as createLoading,
|
|
1210
|
+
Ut as createToast,
|
|
1211
|
+
jt as createToife,
|
|
1215
1212
|
O as isFormElement,
|
|
1216
|
-
|
|
1213
|
+
Ee as presentController,
|
|
1217
1214
|
$ as screenController,
|
|
1218
|
-
|
|
1215
|
+
Re as useKeyboard
|
|
1219
1216
|
};
|