@toife/vue 1.1.39 → 1.1.41
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/components/t-loading-app.vue.d.ts +2 -0
- package/dist/index.css +1 -1
- package/dist/index.es.js +195 -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 _, openBlock as
|
|
1
|
+
import { createElementBlock as _, openBlock as i, renderSlot as h, defineComponent as T, ref as y, computed as S, reactive as te, watch as A, Fragment as V, withDirectives as Y, createCommentVNode as C, normalizeStyle as w, normalizeClass as x, vShow as H, createElementVNode as $, createVNode as j, onUnmounted as L, createBlock as z, withCtx as E, toDisplayString as D, renderList as U, createTextVNode as O, createApp as F, h as G, unref as P, onMounted as Q, resolveDynamicComponent as ce, markRaw as ie, inject as ue, provide as de } from "vue";
|
|
2
2
|
import { gesture as N } from "@toife/gesture";
|
|
3
|
-
import { useRouter as oe, useRoute as
|
|
3
|
+
import { useRouter as oe, useRoute as pe } from "vue-router";
|
|
4
4
|
const q = (t) => t && (t.tagName == "INPUT" || t.tagName == "TEXTAREA" || t.isContentEditable), X = () => {
|
|
5
5
|
const t = document.activeElement;
|
|
6
6
|
t && (t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.isContentEditable) && t.blur();
|
|
7
|
-
},
|
|
7
|
+
}, fe = () => {
|
|
8
8
|
document.addEventListener("contextmenu", (t) => t.preventDefault()), document.addEventListener("selectstart", (t) => t.preventDefault()), document.addEventListener("pointerup", (t) => {
|
|
9
9
|
!q(t.target) && X();
|
|
10
10
|
});
|
|
@@ -13,13 +13,13 @@ const q = (t) => t && (t.tagName == "INPUT" || t.tagName == "TEXTAREA" || t.isCo
|
|
|
13
13
|
for (const [e, s] of n)
|
|
14
14
|
o[e] = s;
|
|
15
15
|
return o;
|
|
16
|
-
},
|
|
17
|
-
function
|
|
18
|
-
return
|
|
16
|
+
}, me = {}, ve = { class: "t-app" };
|
|
17
|
+
function _e(t, n) {
|
|
18
|
+
return i(), _("div", ve, [
|
|
19
19
|
h(t.$slots, "default")
|
|
20
20
|
]);
|
|
21
21
|
}
|
|
22
|
-
const
|
|
22
|
+
const ye = /* @__PURE__ */ b(me, [["render", _e]]), ge = /* @__PURE__ */ T({
|
|
23
23
|
__name: "t-present",
|
|
24
24
|
props: {
|
|
25
25
|
keepalive: { type: Boolean, default: !0 },
|
|
@@ -29,13 +29,13 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
29
29
|
},
|
|
30
30
|
emits: ["dismiss"],
|
|
31
31
|
setup(t, { expose: n, emit: o }) {
|
|
32
|
-
const e = y(0), s = y(!1), r = y(), c = y(),
|
|
32
|
+
const e = y(0), s = y(!1), r = y(), c = y(), u = t, d = o, p = S(() => s.value || u.keepalive), f = 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
|
}), v = (m) => {
|
|
38
|
-
|
|
38
|
+
u.backdrop ? m?.backdropOpacity && (f["--t-present-backdrop-opacity"] = m.backdropOpacity) : f["--t-present-backdrop-opacity"] = "0", m?.transition && (f["--t-present-transition"] = m.transition, f["--t-present-transition"] = m.transition), m?.contentTransform && (f["--t-present-content-transform"] = m.contentTransform), m?.contentOpacity && (f["--t-present-content-opacity"] = m.contentOpacity);
|
|
39
39
|
}, l = () => {
|
|
40
40
|
v({
|
|
41
41
|
contentTransform: "0px",
|
|
@@ -45,15 +45,15 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
45
45
|
});
|
|
46
46
|
}, a = () => {
|
|
47
47
|
let m = "0px", I = "1";
|
|
48
|
-
|
|
48
|
+
u.placement == "bottom" || u.placement == "right" ? m = "100%" : u.placement == "top" || u.placement == "left" ? m = "-100%" : u.placement == "center" && (m = "0px", I = "0"), v({
|
|
49
49
|
contentTransform: m,
|
|
50
50
|
transition: "0.2s",
|
|
51
51
|
contentOpacity: I,
|
|
52
52
|
backdropOpacity: "0"
|
|
53
53
|
});
|
|
54
54
|
};
|
|
55
|
-
A(() =>
|
|
56
|
-
|
|
55
|
+
A(() => u.visible, () => {
|
|
56
|
+
u.visible ? (s.value = !0, e.value = Ce.getNewIndex(), setTimeout(() => {
|
|
57
57
|
l();
|
|
58
58
|
}, 50)) : (a(), setTimeout(() => {
|
|
59
59
|
s.value = !1;
|
|
@@ -66,8 +66,8 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
66
66
|
const g = (m) => {
|
|
67
67
|
m.preventDefault(), d("dismiss", "backdrop");
|
|
68
68
|
};
|
|
69
|
-
return a(), (m, I) => (
|
|
70
|
-
p.value ? Y((
|
|
69
|
+
return a(), (m, I) => (i(), _(V, null, [
|
|
70
|
+
p.value ? Y((i(), _("div", {
|
|
71
71
|
key: 0,
|
|
72
72
|
class: x(["t-present", { [m.placement]: !0 }]),
|
|
73
73
|
ref_key: "present",
|
|
@@ -77,8 +77,8 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
77
77
|
h(m.$slots, "default", {}, void 0, !0)
|
|
78
78
|
], 6)), [
|
|
79
79
|
[H, s.value]
|
|
80
|
-
]) :
|
|
81
|
-
p.value ? Y((
|
|
80
|
+
]) : C("", !0),
|
|
81
|
+
p.value ? Y((i(), _("div", {
|
|
82
82
|
key: 1,
|
|
83
83
|
class: "t-present-backdrop",
|
|
84
84
|
onClick: g,
|
|
@@ -87,10 +87,10 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
87
87
|
style: w({ ...f, zIndex: e.value - 1 })
|
|
88
88
|
}, null, 4)), [
|
|
89
89
|
[H, s.value]
|
|
90
|
-
]) :
|
|
90
|
+
]) : C("", !0)
|
|
91
91
|
], 64));
|
|
92
92
|
}
|
|
93
|
-
}), W = /* @__PURE__ */ b(
|
|
93
|
+
}), W = /* @__PURE__ */ b(ge, [["__scopeId", "data-v-0ec92514"]]), be = /* @__PURE__ */ T({
|
|
94
94
|
__name: "t-loading-icon",
|
|
95
95
|
props: {
|
|
96
96
|
size: {
|
|
@@ -103,7 +103,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
103
103
|
}
|
|
104
104
|
},
|
|
105
105
|
setup(t) {
|
|
106
|
-
return (n, o) => (
|
|
106
|
+
return (n, o) => (i(), _("span", {
|
|
107
107
|
class: "t-loading-icon",
|
|
108
108
|
style: w({
|
|
109
109
|
width: t.size,
|
|
@@ -114,10 +114,10 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
114
114
|
"aria-label": "Loading..."
|
|
115
115
|
}, null, 4));
|
|
116
116
|
}
|
|
117
|
-
}),
|
|
117
|
+
}), K = /* @__PURE__ */ b(be, [["__scopeId", "data-v-7c463303"]]), he = {
|
|
118
118
|
key: 0,
|
|
119
119
|
class: "loader"
|
|
120
|
-
},
|
|
120
|
+
}, ke = /* @__PURE__ */ T({
|
|
121
121
|
__name: "t-button",
|
|
122
122
|
props: {
|
|
123
123
|
color: { default: null },
|
|
@@ -170,7 +170,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
170
170
|
"--background": "transparent"
|
|
171
171
|
}), e;
|
|
172
172
|
});
|
|
173
|
-
return (e, s) => (
|
|
173
|
+
return (e, s) => (i(), _("button", {
|
|
174
174
|
class: x(["t-button", { "active-background": n.activeBackground, rounded: n.rounded, block: n.block, ["size-" + n.size]: !0 }]),
|
|
175
175
|
style: w(o.value)
|
|
176
176
|
}, [
|
|
@@ -179,18 +179,18 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
179
179
|
], 512), [
|
|
180
180
|
[H, !n.loading]
|
|
181
181
|
]),
|
|
182
|
-
n.loading ? (
|
|
183
|
-
|
|
182
|
+
n.loading ? (i(), _("span", he, [
|
|
183
|
+
j(K, {
|
|
184
184
|
color: "var(--color)",
|
|
185
185
|
type: n.loadingType
|
|
186
186
|
}, null, 8, ["type"])
|
|
187
|
-
])) :
|
|
187
|
+
])) : C("", !0)
|
|
188
188
|
], 6));
|
|
189
189
|
}
|
|
190
|
-
}),
|
|
190
|
+
}), M = /* @__PURE__ */ b(ke, [["__scopeId", "data-v-74d8380d"]]), $e = {
|
|
191
191
|
key: 0,
|
|
192
192
|
class: "t-alert-header"
|
|
193
|
-
},
|
|
193
|
+
}, Te = { class: "t-alert-content" }, we = { class: "t-alert-footer" }, xe = /* @__PURE__ */ T({
|
|
194
194
|
__name: "t-alert",
|
|
195
195
|
props: {
|
|
196
196
|
title: {},
|
|
@@ -201,7 +201,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
201
201
|
emits: ["dismiss"],
|
|
202
202
|
setup(t, { expose: n, emit: o }) {
|
|
203
203
|
const e = t, s = y(!1), r = o, c = y();
|
|
204
|
-
let
|
|
204
|
+
let u;
|
|
205
205
|
const d = y(!1), p = () => {
|
|
206
206
|
s.value = !0;
|
|
207
207
|
}, f = (l) => {
|
|
@@ -214,40 +214,40 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
214
214
|
return n({
|
|
215
215
|
open: p
|
|
216
216
|
}), A(() => c.value, (l) => {
|
|
217
|
-
l && (
|
|
217
|
+
l && (u = N(c.value, {
|
|
218
218
|
beforeEvent(a) {
|
|
219
219
|
return a.stopPropagation(), q(a.target) || (a.preventDefault(), X()), !1;
|
|
220
220
|
}
|
|
221
221
|
}));
|
|
222
222
|
}), L(() => {
|
|
223
|
-
|
|
224
|
-
}), (l, a) => (
|
|
223
|
+
u && u.destroy();
|
|
224
|
+
}), (l, a) => (i(), z(W, {
|
|
225
225
|
placement: "center",
|
|
226
226
|
backdrop: !0,
|
|
227
227
|
keepalive: !1,
|
|
228
228
|
visible: s.value,
|
|
229
229
|
onDismiss: v
|
|
230
230
|
}, {
|
|
231
|
-
default:
|
|
231
|
+
default: E(() => [
|
|
232
232
|
$("div", {
|
|
233
233
|
class: x(["t-alert", { pop: d.value }]),
|
|
234
234
|
ref_key: "container",
|
|
235
235
|
ref: c
|
|
236
236
|
}, [
|
|
237
237
|
h(l.$slots, "header", {}, () => [
|
|
238
|
-
e.title ? (
|
|
238
|
+
e.title ? (i(), _("div", $e, D(e.title), 1)) : C("", !0)
|
|
239
239
|
], !0),
|
|
240
240
|
h(l.$slots, "content", {}, () => [
|
|
241
|
-
$("div",
|
|
241
|
+
$("div", Te, D(e.message), 1)
|
|
242
242
|
], !0),
|
|
243
243
|
h(l.$slots, "footer", {}, () => [
|
|
244
|
-
$("div",
|
|
245
|
-
(
|
|
244
|
+
$("div", we, [
|
|
245
|
+
(i(!0), _(V, null, U(e.actions, (g) => (i(), z(M, {
|
|
246
246
|
color: g.color,
|
|
247
247
|
variant: g.variant,
|
|
248
248
|
onClick: (m) => f(g)
|
|
249
249
|
}, {
|
|
250
|
-
default:
|
|
250
|
+
default: E(() => [
|
|
251
251
|
O(D(g.text), 1)
|
|
252
252
|
]),
|
|
253
253
|
_: 2
|
|
@@ -259,22 +259,22 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
259
259
|
_: 3
|
|
260
260
|
}, 8, ["visible"]));
|
|
261
261
|
}
|
|
262
|
-
}), ne = /* @__PURE__ */ b(
|
|
262
|
+
}), ne = /* @__PURE__ */ b(xe, [["__scopeId", "data-v-5cf415ec"]]), Ut = (t = {}) => ({
|
|
263
263
|
open() {
|
|
264
264
|
return new Promise((n) => {
|
|
265
265
|
let o = document.body.querySelector(".t-app");
|
|
266
266
|
if (!o) return;
|
|
267
267
|
const e = document.createElement("div"), s = y();
|
|
268
268
|
o.appendChild(e);
|
|
269
|
-
const r =
|
|
269
|
+
const r = F({
|
|
270
270
|
render() {
|
|
271
|
-
return
|
|
271
|
+
return G(ne, {
|
|
272
272
|
...t,
|
|
273
273
|
ref: s,
|
|
274
|
-
onDismiss: (c,
|
|
274
|
+
onDismiss: (c, u) => {
|
|
275
275
|
setTimeout(() => {
|
|
276
276
|
r.unmount(), e.remove();
|
|
277
|
-
}, 300), n(
|
|
277
|
+
}, 300), n(u);
|
|
278
278
|
}
|
|
279
279
|
});
|
|
280
280
|
}
|
|
@@ -284,7 +284,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
284
284
|
}, 50);
|
|
285
285
|
});
|
|
286
286
|
}
|
|
287
|
-
}),
|
|
287
|
+
}), Ie = /* @__PURE__ */ T({
|
|
288
288
|
__name: "t-action",
|
|
289
289
|
props: {
|
|
290
290
|
actions: {},
|
|
@@ -293,7 +293,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
293
293
|
emits: ["dismiss"],
|
|
294
294
|
setup(t, { expose: n, emit: o }) {
|
|
295
295
|
const e = t, s = y(!1), r = o, c = y();
|
|
296
|
-
let
|
|
296
|
+
let u;
|
|
297
297
|
const d = y(!1), p = () => {
|
|
298
298
|
s.value = !0;
|
|
299
299
|
}, f = (l) => {
|
|
@@ -306,35 +306,35 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
306
306
|
return n({
|
|
307
307
|
open: p
|
|
308
308
|
}), A(() => c.value, (l) => {
|
|
309
|
-
l && (
|
|
309
|
+
l && (u = N(c.value, {
|
|
310
310
|
beforeEvent(a) {
|
|
311
311
|
return a.stopPropagation(), q(a.target) || (a.preventDefault(), X()), !1;
|
|
312
312
|
}
|
|
313
313
|
}));
|
|
314
314
|
}), L(() => {
|
|
315
|
-
|
|
316
|
-
}), (l, a) => (
|
|
315
|
+
u && u.destroy();
|
|
316
|
+
}), (l, a) => (i(), z(W, {
|
|
317
317
|
placement: "bottom",
|
|
318
318
|
backdrop: !0,
|
|
319
319
|
keepalive: !1,
|
|
320
320
|
visible: s.value,
|
|
321
321
|
onDismiss: v
|
|
322
322
|
}, {
|
|
323
|
-
default:
|
|
323
|
+
default: E(() => [
|
|
324
324
|
$("div", {
|
|
325
325
|
class: x(["t-action", { pop: d.value }]),
|
|
326
326
|
ref_key: "container",
|
|
327
327
|
ref: c
|
|
328
328
|
}, [
|
|
329
|
-
(
|
|
330
|
-
(
|
|
329
|
+
(i(!0), _(V, null, U(e.actions, (g) => (i(), _("div", null, [
|
|
330
|
+
(i(!0), _(V, null, U(g, (m) => (i(), z(M, {
|
|
331
331
|
color: m.color,
|
|
332
332
|
size: m.size,
|
|
333
333
|
variant: m.variant,
|
|
334
334
|
onClick: (I) => f(m),
|
|
335
335
|
block: ""
|
|
336
336
|
}, {
|
|
337
|
-
default:
|
|
337
|
+
default: E(() => [
|
|
338
338
|
O(D(m.text), 1)
|
|
339
339
|
]),
|
|
340
340
|
_: 2
|
|
@@ -345,22 +345,22 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
345
345
|
_: 1
|
|
346
346
|
}, 8, ["visible"]));
|
|
347
347
|
}
|
|
348
|
-
}),
|
|
348
|
+
}), Se = /* @__PURE__ */ b(Ie, [["__scopeId", "data-v-73339adc"]]), jt = (t = {}) => ({
|
|
349
349
|
open() {
|
|
350
350
|
return new Promise((n) => {
|
|
351
351
|
let o = document.body.querySelector(".t-app");
|
|
352
352
|
if (!o) return;
|
|
353
353
|
const e = document.createElement("div"), s = y();
|
|
354
354
|
o.appendChild(e);
|
|
355
|
-
const r =
|
|
355
|
+
const r = F({
|
|
356
356
|
render() {
|
|
357
|
-
return
|
|
357
|
+
return G(Se, {
|
|
358
358
|
...t,
|
|
359
359
|
ref: s,
|
|
360
|
-
onDismiss: (c,
|
|
360
|
+
onDismiss: (c, u) => {
|
|
361
361
|
setTimeout(() => {
|
|
362
362
|
r.unmount(), e.remove();
|
|
363
|
-
}, 300), n(
|
|
363
|
+
}, 300), n(u);
|
|
364
364
|
}
|
|
365
365
|
});
|
|
366
366
|
}
|
|
@@ -370,7 +370,7 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
370
370
|
}, 50);
|
|
371
371
|
});
|
|
372
372
|
}
|
|
373
|
-
}),
|
|
373
|
+
}), ze = /* @__PURE__ */ T({
|
|
374
374
|
__name: "t-loading",
|
|
375
375
|
props: {
|
|
376
376
|
type: { default: "spinner" }
|
|
@@ -394,20 +394,20 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
394
394
|
}));
|
|
395
395
|
}), L(() => {
|
|
396
396
|
c && c.destroy();
|
|
397
|
-
}), (p, f) => (
|
|
397
|
+
}), (p, f) => (i(), z(W, {
|
|
398
398
|
placement: "center",
|
|
399
399
|
backdrop: !0,
|
|
400
400
|
keepalive: !1,
|
|
401
401
|
visible: s.value
|
|
402
402
|
}, {
|
|
403
|
-
default:
|
|
403
|
+
default: E(() => [
|
|
404
404
|
$("div", {
|
|
405
405
|
class: "t-loading",
|
|
406
406
|
ref_key: "container",
|
|
407
407
|
ref: r
|
|
408
408
|
}, [
|
|
409
409
|
h(p.$slots, "default", {}, () => [
|
|
410
|
-
|
|
410
|
+
j(K, {
|
|
411
411
|
type: e.type
|
|
412
412
|
}, null, 8, ["type"])
|
|
413
413
|
], !0)
|
|
@@ -416,15 +416,15 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
416
416
|
_: 3
|
|
417
417
|
}, 8, ["visible"]));
|
|
418
418
|
}
|
|
419
|
-
}),
|
|
419
|
+
}), Be = /* @__PURE__ */ b(ze, [["__scopeId", "data-v-d048a41d"]]), Ft = (t = {}) => {
|
|
420
420
|
const n = y(), o = document.body.querySelector(".t-app");
|
|
421
421
|
let e = null, s = null;
|
|
422
422
|
return {
|
|
423
423
|
open() {
|
|
424
424
|
return new Promise((r) => {
|
|
425
|
-
o && (s = document.createElement("div"), o.appendChild(s), e =
|
|
425
|
+
o && (s = document.createElement("div"), o.appendChild(s), e = F({
|
|
426
426
|
render() {
|
|
427
|
-
return
|
|
427
|
+
return G(Be, {
|
|
428
428
|
...t,
|
|
429
429
|
ref: n
|
|
430
430
|
});
|
|
@@ -442,28 +442,28 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
442
442
|
});
|
|
443
443
|
}
|
|
444
444
|
};
|
|
445
|
-
}, Z = y(1e3),
|
|
445
|
+
}, Z = y(1e3), Ce = {
|
|
446
446
|
getNewIndex() {
|
|
447
447
|
return Z.value += 2, Z.value;
|
|
448
448
|
}
|
|
449
|
-
},
|
|
450
|
-
|
|
451
|
-
},
|
|
452
|
-
t ||
|
|
453
|
-
},
|
|
454
|
-
|
|
449
|
+
}, B = te([]), Ee = (t) => {
|
|
450
|
+
B.push(t);
|
|
451
|
+
}, Pe = (t) => {
|
|
452
|
+
t || B.pop();
|
|
453
|
+
}, De = () => {
|
|
454
|
+
B.splice(0, B.length);
|
|
455
455
|
}, k = {
|
|
456
|
-
screens:
|
|
457
|
-
addScreen:
|
|
458
|
-
removeScreen:
|
|
459
|
-
removeAllScreen:
|
|
460
|
-
hasPrevious: S(() =>
|
|
461
|
-
currentScreen: S(() =>
|
|
456
|
+
screens: B,
|
|
457
|
+
addScreen: Ee,
|
|
458
|
+
removeScreen: Pe,
|
|
459
|
+
removeAllScreen: De,
|
|
460
|
+
hasPrevious: S(() => B.length > 1),
|
|
461
|
+
currentScreen: S(() => B[B.length - 1]),
|
|
462
462
|
lastScreen: S(() => {
|
|
463
|
-
if (!(
|
|
464
|
-
return
|
|
463
|
+
if (!(B.length < 2))
|
|
464
|
+
return B[B.length - 2];
|
|
465
465
|
})
|
|
466
|
-
},
|
|
466
|
+
}, Re = /* @__PURE__ */ T({
|
|
467
467
|
__name: "t-toast",
|
|
468
468
|
props: {
|
|
469
469
|
message: {},
|
|
@@ -475,14 +475,14 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
475
475
|
},
|
|
476
476
|
emits: ["dismiss"],
|
|
477
477
|
setup(t, { expose: n, emit: o }) {
|
|
478
|
-
const e = t, s = o, r = y(!1), c = y(!1),
|
|
479
|
-
c.value = !0,
|
|
478
|
+
const e = t, s = o, r = y(!1), c = y(!1), u = y(!1), d = () => {
|
|
479
|
+
c.value = !0, u.value = !1, setTimeout(() => {
|
|
480
480
|
r.value = !0;
|
|
481
481
|
}, 10), setTimeout(() => {
|
|
482
482
|
p();
|
|
483
483
|
}, e.duration + 10);
|
|
484
484
|
}, p = () => {
|
|
485
|
-
|
|
485
|
+
u.value = !0, setTimeout(() => {
|
|
486
486
|
c.value = !1, r.value = !1, s("dismiss");
|
|
487
487
|
}, 300);
|
|
488
488
|
}, f = S(() => {
|
|
@@ -527,21 +527,21 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
527
527
|
});
|
|
528
528
|
return n({
|
|
529
529
|
open: d
|
|
530
|
-
}), (v, l) => c.value ? (
|
|
530
|
+
}), (v, l) => c.value ? (i(), _("div", {
|
|
531
531
|
key: 0,
|
|
532
|
-
class: x(["t-toast", { [e.placement]: !0, open: r.value, closing:
|
|
532
|
+
class: x(["t-toast", { [e.placement]: !0, open: r.value, closing: u.value }]),
|
|
533
533
|
style: w({ "--space": e.space, ...f.value })
|
|
534
|
-
}, D(e.message), 7)) :
|
|
534
|
+
}, D(e.message), 7)) : C("", !0);
|
|
535
535
|
}
|
|
536
|
-
}), se = /* @__PURE__ */ b(
|
|
536
|
+
}), se = /* @__PURE__ */ b(Re, [["__scopeId", "data-v-98e8be37"]]), Gt = (t = {}) => ({
|
|
537
537
|
open() {
|
|
538
538
|
let n = document.body.querySelector(".t-app");
|
|
539
539
|
if (!n) return;
|
|
540
540
|
const o = document.createElement("div"), e = y();
|
|
541
541
|
n.appendChild(o);
|
|
542
|
-
const s =
|
|
542
|
+
const s = F({
|
|
543
543
|
render() {
|
|
544
|
-
return
|
|
544
|
+
return G(se, {
|
|
545
545
|
...t,
|
|
546
546
|
ref: e,
|
|
547
547
|
onDismiss: () => {
|
|
@@ -556,28 +556,28 @@ const _e = /* @__PURE__ */ b(fe, [["render", ve]]), ye = /* @__PURE__ */ T({
|
|
|
556
556
|
e.value?.open?.();
|
|
557
557
|
}, 50);
|
|
558
558
|
}
|
|
559
|
-
}),
|
|
560
|
-
function
|
|
559
|
+
}), Ae = y(0);
|
|
560
|
+
function Ve() {
|
|
561
561
|
return {
|
|
562
|
-
height:
|
|
562
|
+
height: Ae
|
|
563
563
|
};
|
|
564
564
|
}
|
|
565
|
-
const
|
|
565
|
+
const Le = /* @__PURE__ */ T({
|
|
566
566
|
__name: "t-cable",
|
|
567
567
|
props: {
|
|
568
568
|
keyboard: { type: Boolean, default: !0 },
|
|
569
569
|
placement: { default: "bottom" }
|
|
570
570
|
},
|
|
571
571
|
setup(t) {
|
|
572
|
-
const n = t, { height: o } =
|
|
573
|
-
return (e, s) => (
|
|
574
|
-
class: x(["t-cable", { keyboard: n.keyboard &&
|
|
575
|
-
style: w({ "--t-keyboard-height":
|
|
572
|
+
const n = t, { height: o } = Ve();
|
|
573
|
+
return (e, s) => (i(), _("div", {
|
|
574
|
+
class: x(["t-cable", { keyboard: n.keyboard && P(o) > 0, [n.placement]: !0 }]),
|
|
575
|
+
style: w({ "--t-keyboard-height": P(o) + "px", "--t-keyboard-transition": P(o) > 0 ? "0.3s" : "0.1s" })
|
|
576
576
|
}, [
|
|
577
577
|
h(e.$slots, "default", {}, void 0, !0)
|
|
578
578
|
], 6));
|
|
579
579
|
}
|
|
580
|
-
}),
|
|
580
|
+
}), Ne = /* @__PURE__ */ b(Le, [["__scopeId", "data-v-ecb72421"]]), Oe = /* @__PURE__ */ T({
|
|
581
581
|
__name: "t-card",
|
|
582
582
|
props: {
|
|
583
583
|
color: { default: null }
|
|
@@ -593,31 +593,31 @@ const Ve = /* @__PURE__ */ T({
|
|
|
593
593
|
"--background": "var(--t-color-surface)"
|
|
594
594
|
}, e;
|
|
595
595
|
});
|
|
596
|
-
return (e, s) => (
|
|
596
|
+
return (e, s) => (i(), _("div", {
|
|
597
597
|
class: "t-card",
|
|
598
598
|
style: w(o.value)
|
|
599
599
|
}, [
|
|
600
600
|
h(e.$slots, "default")
|
|
601
601
|
], 4));
|
|
602
602
|
}
|
|
603
|
-
}),
|
|
604
|
-
function
|
|
605
|
-
return
|
|
603
|
+
}), qe = {}, Xe = { class: "t-content" };
|
|
604
|
+
function We(t, n) {
|
|
605
|
+
return i(), _("div", Xe, [
|
|
606
606
|
h(t.$slots, "default", {}, void 0, !0)
|
|
607
607
|
]);
|
|
608
608
|
}
|
|
609
|
-
const
|
|
609
|
+
const re = /* @__PURE__ */ b(qe, [["render", We], ["__scopeId", "data-v-9a833657"]]), ee = 80, Ye = /* @__PURE__ */ T({
|
|
610
610
|
__name: "t-refresher",
|
|
611
611
|
emits: ["refresh"],
|
|
612
612
|
setup(t, { emit: n }) {
|
|
613
613
|
const o = n, e = y(0), s = y(!1), r = y();
|
|
614
|
-
let c,
|
|
614
|
+
let c, u = !1;
|
|
615
615
|
const d = () => {
|
|
616
616
|
s.value = !1, e.value = 0, c && c.cancel(), setTimeout(() => {
|
|
617
|
-
|
|
617
|
+
u = !1;
|
|
618
618
|
}, 2e3);
|
|
619
619
|
}, p = () => {
|
|
620
|
-
|
|
620
|
+
u = !0, s.value = !0, e.value = ee, o("refresh", d);
|
|
621
621
|
};
|
|
622
622
|
return A(() => r.value, () => {
|
|
623
623
|
c && c.destroy();
|
|
@@ -627,20 +627,20 @@ const We = /* @__PURE__ */ b(Oe, [["render", Xe], ["__scopeId", "data-v-9a833657
|
|
|
627
627
|
minDist: 60
|
|
628
628
|
},
|
|
629
629
|
move({ dy: v, e: l }) {
|
|
630
|
-
s.value ||
|
|
630
|
+
s.value || u || v < 0 || (v > 5 && f.scrollTop == 0 && (l.preventDefault(), f.classList.add("scroll-hidden")), v >= 120 ? p() : v > 10 && (e.value = v));
|
|
631
631
|
},
|
|
632
632
|
up({ dy: v, e: l }) {
|
|
633
|
-
f.classList.remove("scroll-hidden"), !(s.value ||
|
|
633
|
+
f.classList.remove("scroll-hidden"), !(s.value || u) && (v > ee ? p() : e.value = 0);
|
|
634
634
|
},
|
|
635
635
|
cancel() {
|
|
636
|
-
f.classList.remove("scroll-hidden"), !(s.value ||
|
|
636
|
+
f.classList.remove("scroll-hidden"), !(s.value || u) && (s.value = !1, e.value = 0);
|
|
637
637
|
}
|
|
638
638
|
}, {
|
|
639
639
|
passive: !1
|
|
640
640
|
}));
|
|
641
641
|
}), L(() => {
|
|
642
642
|
c && c.destroy();
|
|
643
|
-
}), (f, v) => Y((
|
|
643
|
+
}), (f, v) => Y((i(), _("div", {
|
|
644
644
|
class: "t-refresher",
|
|
645
645
|
ref_key: "container",
|
|
646
646
|
ref: r,
|
|
@@ -658,33 +658,33 @@ const We = /* @__PURE__ */ b(Oe, [["render", Xe], ["__scopeId", "data-v-9a833657
|
|
|
658
658
|
}
|
|
659
659
|
}), He = /* @__PURE__ */ b(Ye, [["__scopeId", "data-v-ac2b2370"]]), Ue = {}, je = { class: "t-screen" };
|
|
660
660
|
function Fe(t, n) {
|
|
661
|
-
return
|
|
661
|
+
return i(), _("div", je, [
|
|
662
662
|
h(t.$slots, "default", {}, void 0, !0)
|
|
663
663
|
]);
|
|
664
664
|
}
|
|
665
|
-
const
|
|
665
|
+
const ae = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649"]]), Ge = /* @__PURE__ */ T({
|
|
666
666
|
__name: "t-swipe-screen",
|
|
667
667
|
emits: ["change"],
|
|
668
668
|
setup(t, { emit: n }) {
|
|
669
669
|
let o = {};
|
|
670
|
-
const e = oe(), s =
|
|
670
|
+
const e = oe(), s = pe(), r = e.getRoutes(), c = y(!1), u = n;
|
|
671
671
|
for (let a of r)
|
|
672
672
|
o[a.name] = a.components;
|
|
673
673
|
const d = (a) => {
|
|
674
674
|
a && k.addScreen({
|
|
675
675
|
name: a,
|
|
676
676
|
target: null,
|
|
677
|
-
component:
|
|
677
|
+
component: ie(o[a] || null)
|
|
678
678
|
});
|
|
679
679
|
}, p = (a, g) => {
|
|
680
680
|
!g || k.screens[a].target || (k.screens[a].target = g.$el, a > 0 && (c.value = !0, g.$el.style.transform = "translateX(100vw)", g.$el.transitionOrigin = "center", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), setTimeout(() => {
|
|
681
681
|
g.$el.style.transition = "transform 0.35s ease", g.$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"), k.screens.length > 1 && (k.lastScreen.value.target.style.transitionOrigin = "left center", k.lastScreen.value.target.style.transition = "transform 0.35s ease", k.lastScreen.value.target.style.transform = "translateX(-30vw) scale(0.5) perspective(100vw) rotateY(30deg)"), setTimeout(() => {
|
|
682
|
-
|
|
682
|
+
u("change"), c.value = !1;
|
|
683
683
|
}, 400);
|
|
684
684
|
}, 100)));
|
|
685
685
|
}, f = () => {
|
|
686
686
|
k.currentScreen.value.target.style.transition = "transform 0.35s ease", k.currentScreen.value.target.style.transform = "translateX(100vw) scale(1)", k.lastScreen.value.target.style.transition = "transform 0.35s ease", k.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"), c.value = !0, setTimeout(() => {
|
|
687
|
-
k.removeScreen(),
|
|
687
|
+
k.removeScreen(), u("change"), c.value = !1;
|
|
688
688
|
}, 400);
|
|
689
689
|
};
|
|
690
690
|
d(s.name), A(() => s.name, (a, g) => {
|
|
@@ -698,7 +698,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
698
698
|
}, 400);
|
|
699
699
|
};
|
|
700
700
|
let l;
|
|
701
|
-
return
|
|
701
|
+
return Q(() => {
|
|
702
702
|
l = N(document, {
|
|
703
703
|
pointerId: null,
|
|
704
704
|
beforeEvent(a) {
|
|
@@ -727,21 +727,21 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
727
727
|
});
|
|
728
728
|
}), L(() => {
|
|
729
729
|
l && l.destroy(), k.removeAllScreen();
|
|
730
|
-
}), (a, g) => (
|
|
731
|
-
(
|
|
730
|
+
}), (a, g) => (i(), _(V, null, [
|
|
731
|
+
(i(!0), _(V, null, U(P(k).screens, (m, I) => (i(), z(ae, {
|
|
732
732
|
ref_for: !0,
|
|
733
733
|
ref: (R) => p(I, R),
|
|
734
|
-
style: w({ zIndex: I + (I ==
|
|
734
|
+
style: w({ zIndex: I + (I == P(k).screens.length - 1 ? 2 : 1) }),
|
|
735
735
|
key: I
|
|
736
736
|
}, {
|
|
737
|
-
default:
|
|
738
|
-
(
|
|
737
|
+
default: E(() => [
|
|
738
|
+
(i(), z(ce(m.component.default)))
|
|
739
739
|
]),
|
|
740
740
|
_: 2
|
|
741
741
|
}, 1032, ["style"]))), 128)),
|
|
742
742
|
$("div", {
|
|
743
743
|
class: "t-swipe-backdrop",
|
|
744
|
-
style: w({ zIndex:
|
|
744
|
+
style: w({ zIndex: P(k).screens.length })
|
|
745
745
|
}, null, 4)
|
|
746
746
|
], 64));
|
|
747
747
|
}
|
|
@@ -753,7 +753,7 @@ const re = /* @__PURE__ */ b(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) => (i(), _("div", {
|
|
757
757
|
class: x(["t-toolbar", { [n.placement]: !0 }]),
|
|
758
758
|
style: w({ "--t-size-toolbar": n.size })
|
|
759
759
|
}, [
|
|
@@ -771,7 +771,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
771
771
|
const n = oe(), o = t, e = () => {
|
|
772
772
|
k.hasPrevious.value ? n?.back?.() : o.to && n?.push?.(o.to);
|
|
773
773
|
};
|
|
774
|
-
return (s, r) => s.to ||
|
|
774
|
+
return (s, r) => s.to || P(k).hasPrevious ? (i(), _("button", {
|
|
775
775
|
key: 0,
|
|
776
776
|
class: "t-back-button",
|
|
777
777
|
onClick: e
|
|
@@ -779,7 +779,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
779
779
|
h(s.$slots, "default", {}, () => [
|
|
780
780
|
r[0] || (r[0] = $("i", { class: "ri-arrow-left-s-line" }, null, -1))
|
|
781
781
|
], !0)
|
|
782
|
-
])) :
|
|
782
|
+
])) : C("", !0);
|
|
783
783
|
}
|
|
784
784
|
}), Ze = /* @__PURE__ */ b(Qe, [["__scopeId", "data-v-ed626a3d"]]), et = /* @__PURE__ */ T({
|
|
785
785
|
__name: "t-text",
|
|
@@ -795,24 +795,24 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
795
795
|
"--font-size": e
|
|
796
796
|
};
|
|
797
797
|
});
|
|
798
|
-
return (e, s) => (
|
|
798
|
+
return (e, s) => (i(), _("span", {
|
|
799
799
|
class: "t-text",
|
|
800
800
|
style: w(o.value)
|
|
801
801
|
}, [
|
|
802
802
|
h(e.$slots, "default", {}, void 0, !0)
|
|
803
803
|
], 4));
|
|
804
804
|
}
|
|
805
|
-
}),
|
|
805
|
+
}), J = /* @__PURE__ */ b(et, [["__scopeId", "data-v-f0f94f05"]]), tt = /* @__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) => (i(), _("div", {
|
|
812
812
|
class: x(["t-pull-bar", { [n.placement]: !0 }])
|
|
813
813
|
}, null, 2));
|
|
814
814
|
}
|
|
815
|
-
}),
|
|
815
|
+
}), le = /* @__PURE__ */ b(tt, [["__scopeId", "data-v-daa38c85"]]), ot = /* @__PURE__ */ T({
|
|
816
816
|
__name: "t-sheet",
|
|
817
817
|
props: {
|
|
818
818
|
background: { default: "var(--t-color-surface)" },
|
|
@@ -829,7 +829,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
829
829
|
emits: ["dismiss"],
|
|
830
830
|
setup(t, { emit: n }) {
|
|
831
831
|
const o = t, e = n, s = y(), r = y(), c = y(!1);
|
|
832
|
-
let
|
|
832
|
+
let u = null;
|
|
833
833
|
const d = S(() => {
|
|
834
834
|
if (o.placement == "bottom") return "down";
|
|
835
835
|
if (o.placement == "top") return "up";
|
|
@@ -843,7 +843,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
843
843
|
}, 300);
|
|
844
844
|
};
|
|
845
845
|
return A(() => s.value, (v) => {
|
|
846
|
-
v && (
|
|
846
|
+
v && (u = N(s.value, {
|
|
847
847
|
options: {
|
|
848
848
|
minDist: 30
|
|
849
849
|
},
|
|
@@ -879,8 +879,8 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
879
879
|
}
|
|
880
880
|
}));
|
|
881
881
|
}), L(() => {
|
|
882
|
-
|
|
883
|
-
}), (v, l) => (
|
|
882
|
+
u && u.destroy();
|
|
883
|
+
}), (v, l) => (i(), z(W, {
|
|
884
884
|
ref_key: "present",
|
|
885
885
|
ref: r,
|
|
886
886
|
placement: o.placement,
|
|
@@ -889,12 +889,12 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
889
889
|
keepalive: o.keepalive,
|
|
890
890
|
onDismiss: p
|
|
891
891
|
}, {
|
|
892
|
-
default:
|
|
893
|
-
o.gesture && o.placement != "center" ? (
|
|
892
|
+
default: E(() => [
|
|
893
|
+
o.gesture && o.placement != "center" ? (i(), z(le, {
|
|
894
894
|
key: 0,
|
|
895
895
|
placement: o.placement
|
|
896
|
-
}, null, 8, ["placement"])) :
|
|
897
|
-
o.closeButton && o.placement == "center" ? (
|
|
896
|
+
}, null, 8, ["placement"])) : C("", !0),
|
|
897
|
+
o.closeButton && o.placement == "center" ? (i(), _("button", {
|
|
898
898
|
key: 1,
|
|
899
899
|
class: "t-sheet-close",
|
|
900
900
|
onClick: l[0] || (l[0] = (a) => p("close-button"))
|
|
@@ -902,7 +902,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
902
902
|
h(v.$slots, "close-icon", {}, () => [
|
|
903
903
|
l[1] || (l[1] = $("i", { class: "ri-close-large-line" }, null, -1))
|
|
904
904
|
], !0)
|
|
905
|
-
])) :
|
|
905
|
+
])) : C("", !0),
|
|
906
906
|
$("div", {
|
|
907
907
|
class: x(["t-sheet", { fullscreen: o.fullscreen, [o.placement]: !0, rounded: v.rounded, radius: o.radius }]),
|
|
908
908
|
style: w({ "--background": o.background }),
|
|
@@ -933,7 +933,7 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
933
933
|
const o = t, e = n, s = (r) => {
|
|
934
934
|
e("update:modelValue", r.target.value);
|
|
935
935
|
};
|
|
936
|
-
return (r, c) => (
|
|
936
|
+
return (r, c) => (i(), _("div", {
|
|
937
937
|
class: x(["t-input", { rounded: o.rounded, ["size-" + o.size]: !0, ["variant-" + o.variant]: !0 }])
|
|
938
938
|
}, [
|
|
939
939
|
$("label", null, [
|
|
@@ -949,40 +949,40 @@ const re = /* @__PURE__ */ b(Ue, [["render", Fe], ["__scopeId", "data-v-66ea8649
|
|
|
949
949
|
h(r.$slots, "end", {}, void 0, !0)
|
|
950
950
|
])
|
|
951
951
|
]),
|
|
952
|
-
o.error ? (
|
|
952
|
+
o.error ? (i(), z(J, {
|
|
953
953
|
key: 0,
|
|
954
954
|
color: "danger"
|
|
955
955
|
}, {
|
|
956
|
-
default:
|
|
956
|
+
default: E(() => [
|
|
957
957
|
O(D(o.error), 1)
|
|
958
958
|
]),
|
|
959
959
|
_: 1
|
|
960
|
-
})) : o.help ? (
|
|
960
|
+
})) : o.help ? (i(), z(J, {
|
|
961
961
|
key: 1,
|
|
962
962
|
color: "secondary"
|
|
963
963
|
}, {
|
|
964
|
-
default:
|
|
964
|
+
default: E(() => [
|
|
965
965
|
O(D(o.help), 1)
|
|
966
966
|
]),
|
|
967
967
|
_: 1
|
|
968
|
-
})) :
|
|
968
|
+
})) : C("", !0)
|
|
969
969
|
], 2));
|
|
970
970
|
}
|
|
971
971
|
}), ct = /* @__PURE__ */ b(lt, [["__scopeId", "data-v-1a9425cf"]]), it = {};
|
|
972
972
|
function ut(t, n) {
|
|
973
|
-
return
|
|
973
|
+
return i(), _("textarea");
|
|
974
974
|
}
|
|
975
975
|
const dt = /* @__PURE__ */ b(it, [["render", ut]]), pt = {};
|
|
976
976
|
function ft(t, n) {
|
|
977
|
-
return
|
|
977
|
+
return i(), _("div");
|
|
978
978
|
}
|
|
979
979
|
const mt = /* @__PURE__ */ b(pt, [["render", ft]]), vt = {}, _t = { class: "t-grid" };
|
|
980
980
|
function yt(t, n) {
|
|
981
|
-
return
|
|
981
|
+
return i(), _("div", _t);
|
|
982
982
|
}
|
|
983
983
|
const gt = /* @__PURE__ */ b(vt, [["render", yt]]), bt = {}, ht = { class: "t-grid-item" };
|
|
984
984
|
function kt(t, n) {
|
|
985
|
-
return
|
|
985
|
+
return i(), _("div", ht);
|
|
986
986
|
}
|
|
987
987
|
const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
988
988
|
__name: "t-divider",
|
|
@@ -991,7 +991,7 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
991
991
|
},
|
|
992
992
|
setup(t) {
|
|
993
993
|
const n = t;
|
|
994
|
-
return (o, e) => (
|
|
994
|
+
return (o, e) => (i(), _("div", {
|
|
995
995
|
class: x(["t-divider", { [n.direction]: !0 }])
|
|
996
996
|
}, null, 2));
|
|
997
997
|
}
|
|
@@ -1007,16 +1007,16 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1007
1007
|
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(o.color) && (p = `var(--t-color-status-${o.color})`), {
|
|
1008
1008
|
"--color": p
|
|
1009
1009
|
};
|
|
1010
|
-
}),
|
|
1011
|
-
|
|
1012
|
-
let p =
|
|
1010
|
+
}), u = () => r.value?.parentElement?.querySelector?.("input");
|
|
1011
|
+
Q(() => {
|
|
1012
|
+
let p = u();
|
|
1013
1013
|
p && (s.value = p.type != "password", e("change", s.value));
|
|
1014
1014
|
});
|
|
1015
1015
|
const d = () => {
|
|
1016
|
-
let p =
|
|
1016
|
+
let p = u();
|
|
1017
1017
|
p && (s.value = !s.value, s.value ? p.type = "text" : p.type = "password", e("change", s.value));
|
|
1018
1018
|
};
|
|
1019
|
-
return (p, f) => (
|
|
1019
|
+
return (p, f) => (i(), _("button", {
|
|
1020
1020
|
ref_key: "toggle",
|
|
1021
1021
|
ref: r,
|
|
1022
1022
|
class: "t-toggle-password",
|
|
@@ -1025,8 +1025,8 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1025
1025
|
}, [
|
|
1026
1026
|
s.value ? h(p.$slots, "on", { key: 0 }, () => [
|
|
1027
1027
|
f[0] || (f[0] = $("i", { class: "ri-eye-line" }, null, -1))
|
|
1028
|
-
], !0) :
|
|
1029
|
-
s.value ?
|
|
1028
|
+
], !0) : C("", !0),
|
|
1029
|
+
s.value ? C("", !0) : h(p.$slots, "off", { key: 1 }, () => [
|
|
1030
1030
|
f[1] || (f[1] = $("i", { class: "ri-eye-off-line" }, null, -1))
|
|
1031
1031
|
], !0)
|
|
1032
1032
|
], 4));
|
|
@@ -1039,7 +1039,7 @@ const $t = /* @__PURE__ */ b(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, s) => (
|
|
1042
|
+
return (e, s) => (i(), _("div", {
|
|
1043
1043
|
class: x(["t-avatar", { square: e.square }]),
|
|
1044
1044
|
style: w({ "--size": o.value })
|
|
1045
1045
|
}, [
|
|
@@ -1059,16 +1059,16 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1059
1059
|
},
|
|
1060
1060
|
emits: ["change"],
|
|
1061
1061
|
setup(t, { emit: n }) {
|
|
1062
|
-
const o = t, e = n, s = y(!1), r = y(""), c = y(),
|
|
1062
|
+
const o = t, e = n, s = y(!1), r = y(""), c = y(), u = () => {
|
|
1063
1063
|
s.value = !s.value, r.value = `calc(${c.value.offsetHeight}px + 2rem)`, e("change", s.value);
|
|
1064
1064
|
};
|
|
1065
|
-
return e("change", s.value), (d, p) => (
|
|
1065
|
+
return e("change", s.value), (d, p) => (i(), _("div", {
|
|
1066
1066
|
class: x(["t-collapse", { open: s.value }]),
|
|
1067
1067
|
style: w({ "--height": r.value })
|
|
1068
1068
|
}, [
|
|
1069
1069
|
$("div", {
|
|
1070
1070
|
class: "t-collapse-header",
|
|
1071
|
-
onClick:
|
|
1071
|
+
onClick: u
|
|
1072
1072
|
}, [
|
|
1073
1073
|
h(d.$slots, "icon"),
|
|
1074
1074
|
$("div", Bt, [
|
|
@@ -1077,9 +1077,9 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1077
1077
|
])
|
|
1078
1078
|
]),
|
|
1079
1079
|
h(d.$slots, "toggle", {}, () => [
|
|
1080
|
-
s.value ? (
|
|
1080
|
+
s.value ? (i(), _("div", Ct, [...p[0] || (p[0] = [
|
|
1081
1081
|
$("i", { class: "ri-arrow-up-s-line" }, null, -1)
|
|
1082
|
-
])])) : (
|
|
1082
|
+
])])) : (i(), _("div", Et, [...p[1] || (p[1] = [
|
|
1083
1083
|
$("i", { class: "ri-arrow-down-s-line" }, null, -1)
|
|
1084
1084
|
])]))
|
|
1085
1085
|
])
|
|
@@ -1116,11 +1116,11 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1116
1116
|
"--color": `var(--t-color-status-${o.color}-text)`
|
|
1117
1117
|
}), c;
|
|
1118
1118
|
});
|
|
1119
|
-
return (c,
|
|
1119
|
+
return (c, u) => (i(), _("div", {
|
|
1120
1120
|
class: x(["t-switch", { on: o.modelValue }]),
|
|
1121
1121
|
style: w(r.value),
|
|
1122
1122
|
onClick: s
|
|
1123
|
-
}, [...
|
|
1123
|
+
}, [...u[0] || (u[0] = [
|
|
1124
1124
|
$("div", { class: "t-switch-icon" }, null, -1)
|
|
1125
1125
|
])], 6));
|
|
1126
1126
|
}
|
|
@@ -1130,19 +1130,19 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1130
1130
|
value: {}
|
|
1131
1131
|
},
|
|
1132
1132
|
setup(t) {
|
|
1133
|
-
const n = t, o =
|
|
1133
|
+
const n = t, o = ue("tabsState"), e = S(() => o.active.value === n.value), s = () => {
|
|
1134
1134
|
o.setActive(n.value);
|
|
1135
1135
|
};
|
|
1136
|
-
return (r, c) => (
|
|
1136
|
+
return (r, c) => (i(), _("li", {
|
|
1137
1137
|
class: x(["t-tab", { active: e.value }])
|
|
1138
1138
|
}, [
|
|
1139
|
-
M
|
|
1139
|
+
j(M, {
|
|
1140
1140
|
variant: "text",
|
|
1141
1141
|
onClick: s,
|
|
1142
|
-
size:
|
|
1143
|
-
color: e.value &&
|
|
1142
|
+
size: P(o).size,
|
|
1143
|
+
color: e.value && P(o).variant == "text" ? P(o).color : void 0
|
|
1144
1144
|
}, {
|
|
1145
|
-
default:
|
|
1145
|
+
default: E(() => [
|
|
1146
1146
|
h(r.$slots, "default", {}, void 0, !0)
|
|
1147
1147
|
]),
|
|
1148
1148
|
_: 3
|
|
@@ -1164,7 +1164,7 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1164
1164
|
const o = t, e = n, s = y("0px"), r = y(), c = S(() => {
|
|
1165
1165
|
let d = o.color;
|
|
1166
1166
|
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(d) && (d = `var(--t-color-status-${d})`), d;
|
|
1167
|
-
}),
|
|
1167
|
+
}), u = () => {
|
|
1168
1168
|
setTimeout(() => {
|
|
1169
1169
|
if (o.placement.startsWith("top-") || o.placement.startsWith("bottom-")) {
|
|
1170
1170
|
let d = r.value.querySelector(".active");
|
|
@@ -1181,17 +1181,17 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1181
1181
|
}
|
|
1182
1182
|
}, 50);
|
|
1183
1183
|
};
|
|
1184
|
-
return
|
|
1184
|
+
return de("tabsState", {
|
|
1185
1185
|
active: S(() => o.modelValue),
|
|
1186
1186
|
color: c.value,
|
|
1187
1187
|
size: o.size,
|
|
1188
1188
|
variant: o.variant,
|
|
1189
1189
|
setActive: (d) => {
|
|
1190
|
-
e("update:modelValue", d),
|
|
1190
|
+
e("update:modelValue", d), u();
|
|
1191
1191
|
}
|
|
1192
|
-
}),
|
|
1193
|
-
|
|
1194
|
-
}), (d, p) => (
|
|
1192
|
+
}), Q(() => {
|
|
1193
|
+
u();
|
|
1194
|
+
}), (d, p) => (i(), _("ul", {
|
|
1195
1195
|
ref_key: "container",
|
|
1196
1196
|
ref: r,
|
|
1197
1197
|
class: x(["t-tabs", { [d.placement]: !0, [d.variant]: !0 }]),
|
|
@@ -1200,20 +1200,30 @@ const $t = /* @__PURE__ */ b(bt, [["render", kt]]), Tt = /* @__PURE__ */ T({
|
|
|
1200
1200
|
h(d.$slots, "default", {}, void 0, !0)
|
|
1201
1201
|
], 6));
|
|
1202
1202
|
}
|
|
1203
|
-
}), Ot = /* @__PURE__ */ b(Nt, [["__scopeId", "data-v-65a2c74c"]]),
|
|
1203
|
+
}), Ot = /* @__PURE__ */ b(Nt, [["__scopeId", "data-v-65a2c74c"]]), qt = /* @__PURE__ */ T({
|
|
1204
|
+
__name: "t-loading-app",
|
|
1205
|
+
setup(t) {
|
|
1206
|
+
return (n, o) => (i(), z(re, null, {
|
|
1207
|
+
default: E(() => [
|
|
1208
|
+
j(K, { type: "spinner" })
|
|
1209
|
+
]),
|
|
1210
|
+
_: 1
|
|
1211
|
+
}));
|
|
1212
|
+
}
|
|
1213
|
+
}), Xt = /* @__PURE__ */ b(qt, [["__scopeId", "data-v-fd0d53af"]]), Kt = () => ({
|
|
1204
1214
|
install: (t) => {
|
|
1205
|
-
|
|
1215
|
+
fe(), t.component("t-app", ye), t.component("t-screen", ae), t.component("t-swipe-screen", Ke), t.component("t-cable", Ne), t.component("t-toolbar", Je), t.component("t-content", re), t.component("t-card", Oe), t.component("t-refresher", He), t.component("t-button", M), t.component("t-back-button", Ze), t.component("t-present", W), t.component("t-text", J), t.component("t-sheet", nt), t.component("t-pull-signal", le), t.component("t-input", ct), t.component("t-textarea", dt), t.component("t-rich-text", mt), t.component("t-grid", gt), t.component("t-grid-item", $t), t.component("t-divider", wt), t.component("t-toggle-password", It), t.component("t-loading-icon", K), t.component("t-alert", ne), t.component("t-avatar", zt), t.component("t-collapse", Dt), t.component("t-toast", se), t.component("t-switch", At), t.component("t-tab", Lt), t.component("t-tabs", Ot), t.component("t-loading-app", Xt);
|
|
1206
1216
|
}
|
|
1207
1217
|
});
|
|
1208
1218
|
export {
|
|
1209
1219
|
X as blurCurrentActive,
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1220
|
+
jt as createAction,
|
|
1221
|
+
Ut as createAlert,
|
|
1222
|
+
Ft as createLoading,
|
|
1223
|
+
Gt as createToast,
|
|
1224
|
+
Kt as createToife,
|
|
1215
1225
|
q as isFormElement,
|
|
1216
|
-
|
|
1226
|
+
Ce as presentController,
|
|
1217
1227
|
k as screenController,
|
|
1218
|
-
|
|
1228
|
+
Ve as useKeyboard
|
|
1219
1229
|
};
|