@toife/vue 1.2.44 → 1.2.46
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-action.vue.d.ts +5 -1
- package/dist/components/t-swipe-screen.vue.d.ts +8 -3
- package/dist/components/t-toast.vue.d.ts +19 -3
- package/dist/controllers/screen.d.ts +8 -1
- package/dist/index.css +1 -1
- package/dist/index.es.js +756 -678
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { createElementBlock as
|
|
2
|
-
import { gesture as
|
|
3
|
-
import { useRouter as
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
},
|
|
8
|
-
document.addEventListener("contextmenu", (
|
|
9
|
-
!
|
|
1
|
+
import { createElementBlock as d, openBlock as c, renderSlot as g, defineComponent as b, ref as m, computed as w, reactive as ce, watch as O, Fragment as X, withDirectives as W, createCommentVNode as E, normalizeStyle as k, normalizeClass as T, vShow as H, createElementVNode as h, createVNode as U, createBlock as C, withCtx as P, toDisplayString as R, renderList as G, createTextVNode as N, createApp as j, h as F, provide as ie, unref as V, onUnmounted as se, onMounted as oe, resolveDynamicComponent as be, markRaw as he, inject as ue, useAttrs as ke } from "vue";
|
|
2
|
+
import { gesture as ne } from "@toife/gesture";
|
|
3
|
+
import { useRouter as de, useRoute as $e } from "vue-router";
|
|
4
|
+
const we = (e) => e && (e.tagName == "INPUT" || e.tagName == "TEXTAREA" || e.isContentEditable), xe = () => {
|
|
5
|
+
const e = document.activeElement;
|
|
6
|
+
e && (e.tagName === "INPUT" || e.tagName === "TEXTAREA" || e.isContentEditable) && e.blur();
|
|
7
|
+
}, Te = () => {
|
|
8
|
+
document.addEventListener("contextmenu", (e) => e.preventDefault()), document.addEventListener("selectstart", (e) => e.preventDefault()), document.addEventListener("pointerup", (e) => {
|
|
9
|
+
!we(e.target) && xe();
|
|
10
10
|
});
|
|
11
|
-
},
|
|
12
|
-
const
|
|
13
|
-
for (const [
|
|
14
|
-
|
|
15
|
-
return
|
|
16
|
-
},
|
|
17
|
-
function
|
|
18
|
-
return c(),
|
|
19
|
-
|
|
11
|
+
}, v = (e, t) => {
|
|
12
|
+
const s = e.__vccOpts || e;
|
|
13
|
+
for (const [o, n] of t)
|
|
14
|
+
s[o] = n;
|
|
15
|
+
return s;
|
|
16
|
+
}, Se = {}, ze = { class: "t-app" };
|
|
17
|
+
function Ie(e, t) {
|
|
18
|
+
return c(), d("div", ze, [
|
|
19
|
+
g(e.$slots, "default")
|
|
20
20
|
]);
|
|
21
21
|
}
|
|
22
|
-
const
|
|
22
|
+
const Ee = /* @__PURE__ */ v(Se, [["render", Ie]]), Be = /* @__PURE__ */ b({
|
|
23
23
|
__name: "t-present",
|
|
24
24
|
props: {
|
|
25
25
|
keepalive: { type: Boolean, default: !0 },
|
|
@@ -30,69 +30,69 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
30
30
|
class: {}
|
|
31
31
|
},
|
|
32
32
|
emits: ["dismiss"],
|
|
33
|
-
setup(
|
|
34
|
-
const
|
|
33
|
+
setup(e, { expose: t, emit: s }) {
|
|
34
|
+
const o = m(0), n = m(!1), l = m(), u = m(), a = e, i = s, p = w(() => n.value || a.keepalive), _ = ce({
|
|
35
35
|
"--t-present-backdrop-opacity": "0.4",
|
|
36
36
|
"--t-present-transition": "0.2s",
|
|
37
37
|
"--t-present-content-transform": "0px",
|
|
38
38
|
"--t-present-content-opacity": "1"
|
|
39
|
-
}),
|
|
40
|
-
a.backdrop ? f?.backdropOpacity && (
|
|
41
|
-
},
|
|
42
|
-
|
|
39
|
+
}), r = (f) => {
|
|
40
|
+
a.backdrop ? f?.backdropOpacity && (_["--t-present-backdrop-opacity"] = f.backdropOpacity) : _["--t-present-backdrop-opacity"] = "0", f?.transition && (_["--t-present-transition"] = f.transition, _["--t-present-transition"] = f.transition), f?.contentTransform && (_["--t-present-content-transform"] = f.contentTransform), f?.contentOpacity && (_["--t-present-content-opacity"] = f.contentOpacity);
|
|
41
|
+
}, y = () => {
|
|
42
|
+
r({
|
|
43
43
|
contentTransform: "0px",
|
|
44
44
|
transition: "0.2s",
|
|
45
45
|
backdropOpacity: "0.4",
|
|
46
46
|
contentOpacity: "1"
|
|
47
47
|
});
|
|
48
|
-
},
|
|
49
|
-
let f = "0px",
|
|
50
|
-
a.placement == "bottom" || a.placement == "right" ? f = "100%" : a.placement == "top" || a.placement == "left" ? f = "-100%" : a.placement == "center" && (f = "0px",
|
|
48
|
+
}, $ = () => {
|
|
49
|
+
let f = "0px", D = "1";
|
|
50
|
+
a.placement == "bottom" || a.placement == "right" ? f = "100%" : a.placement == "top" || a.placement == "left" ? f = "-100%" : a.placement == "center" && (f = "0px", D = "0"), r({
|
|
51
51
|
contentTransform: f,
|
|
52
52
|
transition: "0.2s",
|
|
53
|
-
contentOpacity:
|
|
53
|
+
contentOpacity: D,
|
|
54
54
|
backdropOpacity: "0"
|
|
55
55
|
});
|
|
56
56
|
};
|
|
57
|
-
|
|
58
|
-
a.visible ? (n.value = !0,
|
|
59
|
-
|
|
60
|
-
}, 50)) : (
|
|
57
|
+
O(() => a.visible, () => {
|
|
58
|
+
a.visible ? (n.value = !0, o.value = He.getNewIndex(), setTimeout(() => {
|
|
59
|
+
y();
|
|
60
|
+
}, 50)) : ($(), setTimeout(() => {
|
|
61
61
|
n.value = !1;
|
|
62
62
|
}, 200));
|
|
63
|
-
}),
|
|
64
|
-
render:
|
|
65
|
-
open:
|
|
66
|
-
close:
|
|
63
|
+
}), t({
|
|
64
|
+
render: r,
|
|
65
|
+
open: y,
|
|
66
|
+
close: $
|
|
67
67
|
});
|
|
68
|
-
const
|
|
69
|
-
f.preventDefault(),
|
|
68
|
+
const S = (f) => {
|
|
69
|
+
f.preventDefault(), i("dismiss", "backdrop");
|
|
70
70
|
};
|
|
71
|
-
return
|
|
72
|
-
|
|
71
|
+
return $(), (f, D) => (c(), d(X, null, [
|
|
72
|
+
p.value ? W((c(), d("div", {
|
|
73
73
|
key: 0,
|
|
74
|
-
class:
|
|
74
|
+
class: T(["t-present", [{ [f.placement]: !0 }, a.class]]),
|
|
75
75
|
ref_key: "present",
|
|
76
|
-
ref:
|
|
77
|
-
style:
|
|
76
|
+
ref: u,
|
|
77
|
+
style: k([_, { zIndex: o.value }, a.style])
|
|
78
78
|
}, [
|
|
79
|
-
|
|
79
|
+
g(f.$slots, "default", {}, void 0, !0)
|
|
80
80
|
], 6)), [
|
|
81
|
-
[
|
|
82
|
-
]) :
|
|
83
|
-
|
|
81
|
+
[H, n.value]
|
|
82
|
+
]) : E("", !0),
|
|
83
|
+
p.value ? W((c(), d("div", {
|
|
84
84
|
key: 1,
|
|
85
85
|
class: "t-present-backdrop",
|
|
86
|
-
onClick:
|
|
86
|
+
onClick: S,
|
|
87
87
|
ref_key: "backdrop",
|
|
88
|
-
ref:
|
|
89
|
-
style:
|
|
88
|
+
ref: l,
|
|
89
|
+
style: k([_, { zIndex: o.value - 1 }, a.style])
|
|
90
90
|
}, null, 4)), [
|
|
91
|
-
[
|
|
92
|
-
]) :
|
|
91
|
+
[H, n.value]
|
|
92
|
+
]) : E("", !0)
|
|
93
93
|
], 64));
|
|
94
94
|
}
|
|
95
|
-
}),
|
|
95
|
+
}), L = /* @__PURE__ */ v(Be, [["__scopeId", "data-v-8eb6e6e4"]]), Ce = /* @__PURE__ */ b({
|
|
96
96
|
__name: "t-loading-icon",
|
|
97
97
|
props: {
|
|
98
98
|
size: {
|
|
@@ -104,22 +104,22 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
104
104
|
default: "var(--t-color-text)"
|
|
105
105
|
}
|
|
106
106
|
},
|
|
107
|
-
setup(
|
|
108
|
-
return (
|
|
107
|
+
setup(e) {
|
|
108
|
+
return (t, s) => (c(), d("span", {
|
|
109
109
|
class: "t-loading-icon",
|
|
110
|
-
style:
|
|
111
|
-
width:
|
|
112
|
-
height:
|
|
113
|
-
borderTopColor:
|
|
110
|
+
style: k({
|
|
111
|
+
width: e.size,
|
|
112
|
+
height: e.size,
|
|
113
|
+
borderTopColor: e.color
|
|
114
114
|
}),
|
|
115
115
|
role: "status",
|
|
116
116
|
"aria-label": "Loading..."
|
|
117
117
|
}, null, 4));
|
|
118
118
|
}
|
|
119
|
-
}),
|
|
119
|
+
}), K = /* @__PURE__ */ v(Ce, [["__scopeId", "data-v-7c463303"]]), Ve = { class: "t-button-content" }, Pe = {
|
|
120
120
|
key: 0,
|
|
121
121
|
class: "loader"
|
|
122
|
-
},
|
|
122
|
+
}, Ae = /* @__PURE__ */ b({
|
|
123
123
|
__name: "t-button",
|
|
124
124
|
props: {
|
|
125
125
|
color: { default: null },
|
|
@@ -131,68 +131,68 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
131
131
|
variant: { default: "default" },
|
|
132
132
|
activeBackground: { type: Boolean, default: !1 }
|
|
133
133
|
},
|
|
134
|
-
setup(
|
|
135
|
-
const
|
|
136
|
-
let
|
|
137
|
-
return
|
|
134
|
+
setup(e) {
|
|
135
|
+
const t = e, s = w(() => {
|
|
136
|
+
let o;
|
|
137
|
+
return t.variant == "default" && (t.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) ? o = {
|
|
138
138
|
"--border": "none",
|
|
139
|
-
"--color": "var(--t-color-status-" +
|
|
140
|
-
"--background": "var(--t-color-status-" +
|
|
141
|
-
} :
|
|
139
|
+
"--color": "var(--t-color-status-" + t.color + "-text)",
|
|
140
|
+
"--background": "var(--t-color-status-" + t.color + ")"
|
|
141
|
+
} : o = {
|
|
142
142
|
"--border": "none",
|
|
143
143
|
"--color": "var(--t-color-text)",
|
|
144
|
-
"--background":
|
|
145
|
-
} :
|
|
144
|
+
"--background": t.color
|
|
145
|
+
} : o = {
|
|
146
146
|
"--border": "none",
|
|
147
147
|
"--color": "var(--t-color-text)",
|
|
148
148
|
"--background": "var(--t-color-surface)"
|
|
149
|
-
}),
|
|
149
|
+
}), t.variant == "text" && (t.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) ? o = {
|
|
150
150
|
"--border": "none",
|
|
151
|
-
"--color": "var(--t-color-status-" +
|
|
151
|
+
"--color": "var(--t-color-status-" + t.color + ")",
|
|
152
152
|
"--background": "transparent"
|
|
153
|
-
} :
|
|
153
|
+
} : o = {
|
|
154
154
|
"--border": "none",
|
|
155
|
-
"--color":
|
|
155
|
+
"--color": t.color,
|
|
156
156
|
"--background": "transparent"
|
|
157
|
-
} :
|
|
157
|
+
} : o = {
|
|
158
158
|
"--border": "none",
|
|
159
159
|
"--color": "var(--t-color-text)",
|
|
160
160
|
"--background": "transparent"
|
|
161
|
-
}),
|
|
162
|
-
"--border": "0.55px solid var(--t-color-status-" +
|
|
163
|
-
"--color": "var(--t-color-status-" +
|
|
161
|
+
}), t.variant == "outline" && (t.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) ? o = {
|
|
162
|
+
"--border": "0.55px solid var(--t-color-status-" + t.color + ")",
|
|
163
|
+
"--color": "var(--t-color-status-" + t.color + ")",
|
|
164
164
|
"--background": "transparent"
|
|
165
|
-
} :
|
|
166
|
-
"--border": "0.55px solid " +
|
|
167
|
-
"--color":
|
|
165
|
+
} : o = {
|
|
166
|
+
"--border": "0.55px solid " + t.color,
|
|
167
|
+
"--color": t.color,
|
|
168
168
|
"--background": "transparent"
|
|
169
|
-
} :
|
|
169
|
+
} : o = {
|
|
170
170
|
"--border": "0.55px solid var(--t-color-text)",
|
|
171
171
|
"--color": "var(--t-color-text)",
|
|
172
172
|
"--background": "transparent"
|
|
173
|
-
}),
|
|
173
|
+
}), o;
|
|
174
174
|
});
|
|
175
|
-
return (
|
|
176
|
-
class:
|
|
177
|
-
style:
|
|
175
|
+
return (o, n) => (c(), d("button", {
|
|
176
|
+
class: T(["t-button", { "active-background": t.activeBackground, rounded: t.rounded, block: t.block, ["size-" + t.size]: !0 }]),
|
|
177
|
+
style: k(s.value)
|
|
178
178
|
}, [
|
|
179
|
-
|
|
180
|
-
|
|
179
|
+
W(h("span", Ve, [
|
|
180
|
+
g(o.$slots, "default", {}, void 0, !0)
|
|
181
181
|
], 512), [
|
|
182
|
-
[
|
|
182
|
+
[H, !t.loading]
|
|
183
183
|
]),
|
|
184
|
-
|
|
185
|
-
|
|
184
|
+
t.loading ? (c(), d("span", Pe, [
|
|
185
|
+
U(K, {
|
|
186
186
|
color: "var(--color)",
|
|
187
|
-
type:
|
|
187
|
+
type: t.loadingType
|
|
188
188
|
}, null, 8, ["type"])
|
|
189
|
-
])) :
|
|
189
|
+
])) : E("", !0)
|
|
190
190
|
], 6));
|
|
191
191
|
}
|
|
192
|
-
}),
|
|
192
|
+
}), J = /* @__PURE__ */ v(Ae, [["__scopeId", "data-v-185a9e49"]]), Re = {
|
|
193
193
|
key: 0,
|
|
194
194
|
class: "t-alert-header"
|
|
195
|
-
},
|
|
195
|
+
}, Me = { class: "t-alert-content" }, De = { class: "t-alert-footer" }, Xe = /* @__PURE__ */ b({
|
|
196
196
|
__name: "t-alert",
|
|
197
197
|
props: {
|
|
198
198
|
title: {},
|
|
@@ -201,46 +201,46 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
201
201
|
dismiss: {}
|
|
202
202
|
},
|
|
203
203
|
emits: ["dismiss"],
|
|
204
|
-
setup(
|
|
205
|
-
const
|
|
204
|
+
setup(e, { expose: t, emit: s }) {
|
|
205
|
+
const o = e, n = m(!1), l = s, u = m(), a = m(!1), i = () => {
|
|
206
206
|
n.value = !0;
|
|
207
|
-
},
|
|
208
|
-
n.value = !1,
|
|
209
|
-
},
|
|
210
|
-
|
|
207
|
+
}, p = (r) => {
|
|
208
|
+
n.value = !1, r.handler && r.handler(), l("dismiss", "choose", r?.data);
|
|
209
|
+
}, _ = (r) => {
|
|
210
|
+
o.dismiss && o.dismiss.includes(r) ? (n.value = !1, l("dismiss", r)) : r == "backdrop" && (a.value = !0, setTimeout(() => {
|
|
211
211
|
a.value = !1;
|
|
212
212
|
}, 300));
|
|
213
213
|
};
|
|
214
|
-
return
|
|
215
|
-
open:
|
|
216
|
-
}), (
|
|
214
|
+
return t({
|
|
215
|
+
open: i
|
|
216
|
+
}), (r, y) => (c(), C(L, {
|
|
217
217
|
placement: "center",
|
|
218
218
|
backdrop: !0,
|
|
219
219
|
keepalive: !1,
|
|
220
220
|
visible: n.value,
|
|
221
|
-
onDismiss:
|
|
221
|
+
onDismiss: _
|
|
222
222
|
}, {
|
|
223
|
-
default:
|
|
224
|
-
|
|
225
|
-
class:
|
|
223
|
+
default: P(() => [
|
|
224
|
+
h("div", {
|
|
225
|
+
class: T(["t-alert", { pop: a.value }]),
|
|
226
226
|
ref_key: "container",
|
|
227
|
-
ref:
|
|
227
|
+
ref: u
|
|
228
228
|
}, [
|
|
229
|
-
|
|
230
|
-
|
|
229
|
+
g(r.$slots, "header", {}, () => [
|
|
230
|
+
o.title ? (c(), d("div", Re, R(o.title), 1)) : E("", !0)
|
|
231
231
|
], !0),
|
|
232
|
-
|
|
233
|
-
|
|
232
|
+
g(r.$slots, "content", {}, () => [
|
|
233
|
+
h("div", Me, R(o.message), 1)
|
|
234
234
|
], !0),
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
(c(!0),
|
|
238
|
-
color:
|
|
239
|
-
variant:
|
|
240
|
-
onClick: (
|
|
235
|
+
g(r.$slots, "footer", {}, () => [
|
|
236
|
+
h("div", De, [
|
|
237
|
+
(c(!0), d(X, null, G(o.actions, ($) => (c(), C(J, {
|
|
238
|
+
color: $.color,
|
|
239
|
+
variant: $.variant,
|
|
240
|
+
onClick: (S) => p($)
|
|
241
241
|
}, {
|
|
242
|
-
default:
|
|
243
|
-
R(
|
|
242
|
+
default: P(() => [
|
|
243
|
+
N(R($.text), 1)
|
|
244
244
|
]),
|
|
245
245
|
_: 2
|
|
246
246
|
}, 1032, ["color", "variant", "onClick"]))), 256))
|
|
@@ -251,73 +251,77 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
251
251
|
_: 3
|
|
252
252
|
}, 8, ["visible"]));
|
|
253
253
|
}
|
|
254
|
-
}),
|
|
254
|
+
}), pe = /* @__PURE__ */ v(Xe, [["__scopeId", "data-v-05d0c578"]]), ks = (e = {}) => ({
|
|
255
255
|
open() {
|
|
256
|
-
return new Promise((
|
|
257
|
-
let
|
|
258
|
-
if (!
|
|
259
|
-
const
|
|
260
|
-
|
|
261
|
-
const
|
|
256
|
+
return new Promise((t) => {
|
|
257
|
+
let s = document.body.querySelector(".t-app");
|
|
258
|
+
if (!s) return;
|
|
259
|
+
const o = document.createElement("div"), n = m();
|
|
260
|
+
s.appendChild(o);
|
|
261
|
+
const l = j({
|
|
262
262
|
render() {
|
|
263
|
-
return
|
|
264
|
-
...
|
|
263
|
+
return F(pe, {
|
|
264
|
+
...e,
|
|
265
265
|
ref: n,
|
|
266
|
-
onDismiss: (
|
|
266
|
+
onDismiss: (u, a) => {
|
|
267
267
|
setTimeout(() => {
|
|
268
|
-
|
|
269
|
-
}, 300),
|
|
268
|
+
l.unmount(), o.remove();
|
|
269
|
+
}, 300), t({ type: u, data: a });
|
|
270
270
|
}
|
|
271
271
|
});
|
|
272
272
|
}
|
|
273
273
|
});
|
|
274
|
-
|
|
274
|
+
l.mount(o), setTimeout(() => {
|
|
275
275
|
n.value?.open?.();
|
|
276
276
|
}, 50);
|
|
277
277
|
});
|
|
278
278
|
}
|
|
279
|
-
}),
|
|
279
|
+
}), Oe = /* @__PURE__ */ b({
|
|
280
280
|
__name: "t-action",
|
|
281
281
|
props: {
|
|
282
282
|
actions: {},
|
|
283
|
+
visible: { type: Boolean, default: !1 },
|
|
283
284
|
dismiss: {}
|
|
284
285
|
},
|
|
285
286
|
emits: ["dismiss"],
|
|
286
|
-
setup(
|
|
287
|
-
const
|
|
287
|
+
setup(e, { expose: t, emit: s }) {
|
|
288
|
+
const o = e, n = m(!1), l = s, u = m(), a = m(!1), i = () => {
|
|
288
289
|
n.value = !0;
|
|
289
|
-
},
|
|
290
|
-
n.value = !1,
|
|
291
|
-
},
|
|
292
|
-
|
|
290
|
+
}, p = (r) => {
|
|
291
|
+
n.value = !1, r.handler && r.handler(), l("dismiss", "choose", r?.data);
|
|
292
|
+
}, _ = (r) => {
|
|
293
|
+
o.dismiss && o.dismiss.includes(r) ? (n.value = !1, l("dismiss", r)) : r == "backdrop" && (a.value = !0, setTimeout(() => {
|
|
293
294
|
a.value = !1;
|
|
294
295
|
}, 300));
|
|
295
296
|
};
|
|
296
|
-
return
|
|
297
|
-
|
|
298
|
-
}), (
|
|
297
|
+
return O(() => o.visible, (r) => {
|
|
298
|
+
r ? i() : close();
|
|
299
|
+
}), t({
|
|
300
|
+
open: i,
|
|
301
|
+
close
|
|
302
|
+
}), (r, y) => (c(), C(L, {
|
|
299
303
|
placement: "bottom",
|
|
300
304
|
backdrop: !0,
|
|
301
305
|
keepalive: !1,
|
|
302
306
|
visible: n.value,
|
|
303
|
-
onDismiss:
|
|
307
|
+
onDismiss: _
|
|
304
308
|
}, {
|
|
305
|
-
default:
|
|
306
|
-
|
|
307
|
-
class:
|
|
309
|
+
default: P(() => [
|
|
310
|
+
h("div", {
|
|
311
|
+
class: T(["t-action", { pop: a.value }]),
|
|
308
312
|
ref_key: "container",
|
|
309
|
-
ref:
|
|
313
|
+
ref: u
|
|
310
314
|
}, [
|
|
311
|
-
(c(!0),
|
|
312
|
-
(c(!0),
|
|
313
|
-
color:
|
|
314
|
-
size:
|
|
315
|
-
variant:
|
|
316
|
-
onClick: (f) =>
|
|
315
|
+
(c(!0), d(X, null, G(o.actions, ($) => (c(), d("div", null, [
|
|
316
|
+
(c(!0), d(X, null, G($, (S) => (c(), C(J, {
|
|
317
|
+
color: S.color,
|
|
318
|
+
size: S.size,
|
|
319
|
+
variant: S.variant,
|
|
320
|
+
onClick: (f) => p(S),
|
|
317
321
|
block: ""
|
|
318
322
|
}, {
|
|
319
|
-
default:
|
|
320
|
-
R(
|
|
323
|
+
default: P(() => [
|
|
324
|
+
N(R(S.text), 1)
|
|
321
325
|
]),
|
|
322
326
|
_: 2
|
|
323
327
|
}, 1032, ["color", "size", "variant", "onClick"]))), 256))
|
|
@@ -327,57 +331,57 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
327
331
|
_: 1
|
|
328
332
|
}, 8, ["visible"]));
|
|
329
333
|
}
|
|
330
|
-
}),
|
|
334
|
+
}), Ne = /* @__PURE__ */ v(Oe, [["__scopeId", "data-v-e693a02a"]]), $s = (e = {}) => ({
|
|
331
335
|
open() {
|
|
332
|
-
return new Promise((
|
|
333
|
-
let
|
|
334
|
-
if (!
|
|
335
|
-
const
|
|
336
|
-
|
|
337
|
-
const
|
|
336
|
+
return new Promise((t) => {
|
|
337
|
+
let s = document.body.querySelector(".t-app");
|
|
338
|
+
if (!s) return;
|
|
339
|
+
const o = document.createElement("div"), n = m();
|
|
340
|
+
s.appendChild(o);
|
|
341
|
+
const l = j({
|
|
338
342
|
render() {
|
|
339
|
-
return
|
|
340
|
-
...
|
|
343
|
+
return F(Ne, {
|
|
344
|
+
...e,
|
|
341
345
|
ref: n,
|
|
342
|
-
onDismiss: (
|
|
346
|
+
onDismiss: (u, a) => {
|
|
343
347
|
setTimeout(() => {
|
|
344
|
-
|
|
345
|
-
}, 300),
|
|
348
|
+
l.unmount(), o.remove();
|
|
349
|
+
}, 300), t({ type: u, data: a });
|
|
346
350
|
}
|
|
347
351
|
});
|
|
348
352
|
}
|
|
349
353
|
});
|
|
350
|
-
|
|
354
|
+
l.mount(o), setTimeout(() => {
|
|
351
355
|
n.value?.open?.();
|
|
352
356
|
}, 50);
|
|
353
357
|
});
|
|
354
358
|
}
|
|
355
|
-
}),
|
|
359
|
+
}), qe = { class: "t-loading" }, Le = /* @__PURE__ */ b({
|
|
356
360
|
__name: "t-loading",
|
|
357
361
|
props: {
|
|
358
362
|
type: { default: "spinner" }
|
|
359
363
|
},
|
|
360
364
|
emits: ["dismiss"],
|
|
361
|
-
setup(
|
|
362
|
-
const
|
|
363
|
-
return
|
|
365
|
+
setup(e, { expose: t, emit: s }) {
|
|
366
|
+
const o = e, n = m(!1);
|
|
367
|
+
return t({
|
|
364
368
|
open: () => {
|
|
365
369
|
n.value = !0;
|
|
366
370
|
},
|
|
367
371
|
close: () => {
|
|
368
372
|
n.value = !1;
|
|
369
373
|
}
|
|
370
|
-
}), (a,
|
|
374
|
+
}), (a, i) => (c(), C(L, {
|
|
371
375
|
placement: "center",
|
|
372
376
|
backdrop: !0,
|
|
373
377
|
keepalive: !1,
|
|
374
378
|
visible: n.value
|
|
375
379
|
}, {
|
|
376
|
-
default:
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
type:
|
|
380
|
+
default: P(() => [
|
|
381
|
+
h("div", qe, [
|
|
382
|
+
g(a.$slots, "default", {}, () => [
|
|
383
|
+
U(K, {
|
|
384
|
+
type: o.type
|
|
381
385
|
}, null, 8, ["type"])
|
|
382
386
|
], !0)
|
|
383
387
|
])
|
|
@@ -385,222 +389,308 @@ const ke = /* @__PURE__ */ _(ge, [["render", be]]), $e = /* @__PURE__ */ g({
|
|
|
385
389
|
_: 3
|
|
386
390
|
}, 8, ["visible"]));
|
|
387
391
|
}
|
|
388
|
-
}),
|
|
389
|
-
const
|
|
390
|
-
let
|
|
392
|
+
}), We = /* @__PURE__ */ v(Le, [["__scopeId", "data-v-8f84c14e"]]), ws = (e = {}) => {
|
|
393
|
+
const t = m(), s = document.body.querySelector(".t-app");
|
|
394
|
+
let o = null, n = null;
|
|
391
395
|
return {
|
|
392
396
|
open() {
|
|
393
|
-
return new Promise((
|
|
394
|
-
|
|
397
|
+
return new Promise((l) => {
|
|
398
|
+
s && (n = document.createElement("div"), s.appendChild(n), o = j({
|
|
395
399
|
render() {
|
|
396
|
-
return
|
|
397
|
-
...
|
|
398
|
-
ref:
|
|
400
|
+
return F(We, {
|
|
401
|
+
...e,
|
|
402
|
+
ref: t
|
|
399
403
|
});
|
|
400
404
|
}
|
|
401
|
-
}),
|
|
402
|
-
|
|
405
|
+
}), o.mount(n), setTimeout(() => {
|
|
406
|
+
t.value?.open?.(), l(!0);
|
|
403
407
|
}, 50));
|
|
404
408
|
});
|
|
405
409
|
},
|
|
406
410
|
close() {
|
|
407
|
-
return new Promise((
|
|
408
|
-
|
|
409
|
-
|
|
411
|
+
return new Promise((l) => {
|
|
412
|
+
t.value?.close?.(), setTimeout(() => {
|
|
413
|
+
o?.unmount?.(), n?.remove?.(), l(!0);
|
|
410
414
|
}, 300);
|
|
411
415
|
});
|
|
412
416
|
}
|
|
413
417
|
};
|
|
414
|
-
},
|
|
418
|
+
}, ae = m(1e3), He = {
|
|
415
419
|
getNewIndex() {
|
|
416
|
-
return
|
|
420
|
+
return ae.value += 2, ae.value;
|
|
417
421
|
}
|
|
418
|
-
},
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
},
|
|
422
|
+
}, M = ce([]), Q = m(!0), I = m(!1), A = m(-1), z = w(() => M[A.value]), q = w(() => M[A.value + 1] || void 0), B = w(() => M[M.length - 2]), fe = w(() => !I.value && Q.value && B.value), Z = {
|
|
423
|
+
reset() {
|
|
424
|
+
I.value = !0;
|
|
425
|
+
const e = z.value.target, t = B.value.target;
|
|
426
|
+
e.style.transition = "transform 0.35s ease", e.style.transform = "translateX(0px)", t.style.transition = "transform 0.35s ease", t.style.transform = "translateX(calc(var(--t-app-width) / 100 * 30 * -1)) scale(0.5) perspective(var(--t-app-width)) rotateY(30deg)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), setTimeout(() => {
|
|
427
|
+
I.value = !1;
|
|
428
|
+
}, 400);
|
|
429
|
+
},
|
|
430
|
+
move(e) {
|
|
431
|
+
if (!fe.value) return;
|
|
432
|
+
const t = window.innerWidth, s = e / t * 100, o = z.value.target, n = B.value.target;
|
|
433
|
+
e > 15 && e <= t && (e = e > 0 ? e : 0, o.style.transition = "transform 0s ease", o.style.transform = `translateX(${e}px)`, n.style.transition = "transform 0s ease", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0s"), n.style.transform = `translateX(calc((var(--t-app-width) / 100 * 30 * -1) + ((var(--t-app-width) / 100 * 30) / 100 * ${s}))) scale(${0.5 + 0.5 / 100 * s}) perspective(var(--t-app-width)) rotateY(${30 - 30 / 100 * s}deg)`, document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", `${0.5 - 0.5 / 100 * s}`));
|
|
434
|
+
},
|
|
435
|
+
back(e) {
|
|
436
|
+
B.value && (z.value.target.style.transition = "transform 0.35s ease", z.value.target.style.transform = "translateX(var(--t-app-width)) scale(1)", B.value.target.style.transition = "transform 0.35s ease", B.value.target.style.transform = "translateX(0px) scale(1) perspective(var(--t-app-width)) rotateY(0deg)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), I.value = !0, setTimeout(() => {
|
|
437
|
+
re(), I.value = !1, A.value -= 1, e && e();
|
|
438
|
+
}, 400));
|
|
439
|
+
},
|
|
440
|
+
next(e) {
|
|
441
|
+
if (!q.value) return;
|
|
442
|
+
if (A.value == -1) {
|
|
443
|
+
A.value += 1, e && e();
|
|
444
|
+
return;
|
|
445
|
+
}
|
|
446
|
+
I.value = !0;
|
|
447
|
+
let t = q.value.target;
|
|
448
|
+
t.style.transform = "translateX(var(--t-app-width))", t.transitionOrigin = "center", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), setTimeout(() => {
|
|
449
|
+
t.style.transition = "transform 0.35s ease", t.style.transform = "translateX(0px)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), z.value && (z.value.target.style.transitionOrigin = "left center", z.value.target.style.transition = "transform 0.35s ease", z.value.target.style.transform = "translateX(calc(var(--t-app-width) / 100 * 30 * -1)) scale(0.5) perspective(var(--t-app-width)) rotateY(30deg)"), setTimeout(() => {
|
|
450
|
+
I.value = !1, A.value += 1, e && e();
|
|
451
|
+
}, 400);
|
|
452
|
+
}, 100);
|
|
453
|
+
}
|
|
454
|
+
}, Y = {
|
|
455
|
+
reset() {
|
|
456
|
+
I.value = !0;
|
|
457
|
+
const e = z.value.target, t = B.value.target;
|
|
458
|
+
e.style.transition = "transform 0.35s ease", e.style.transform = "translateX(0px)", t.style.transition = "transform 0.35s ease", t.style.transform = "translateX(calc(var(--t-app-width) / 100 * 30 * -1))", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), setTimeout(() => {
|
|
459
|
+
I.value = !1;
|
|
460
|
+
}, 400);
|
|
461
|
+
},
|
|
462
|
+
move(e) {
|
|
463
|
+
const t = window.innerWidth, s = e / t * 100, o = z.value.target, n = B.value.target;
|
|
464
|
+
e > 15 && e <= t && (e = e > 0 ? e : 0, o.style.transition = "transform 0s ease", o.style.transform = `translateX(${e}px)`, n.style.transition = "transform 0s ease", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0s"), n.style.transform = `translateX(calc((var(--t-app-width) / 100 * 30 * -1) + ((var(--t-app-width) / 100 * 30) / 100 * ${s})))`, document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", `${0.5 - 0.5 / 100 * s}`));
|
|
465
|
+
},
|
|
466
|
+
back(e) {
|
|
467
|
+
B.value && (z.value.target.style.transition = "transform 0.35s ease", z.value.target.style.transform = "translateX(var(--t-app-width)) scale(1)", B.value.target.style.transition = "transform 0.35s ease", B.value.target.style.transform = "translateX(0px)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), I.value = !0, setTimeout(() => {
|
|
468
|
+
re(), I.value = !1, A.value -= 1, e && e();
|
|
469
|
+
}, 400));
|
|
470
|
+
},
|
|
471
|
+
next(e) {
|
|
472
|
+
if (!q.value) return;
|
|
473
|
+
if (A.value == -1) {
|
|
474
|
+
A.value += 1, e && e();
|
|
475
|
+
return;
|
|
476
|
+
}
|
|
477
|
+
I.value = !0;
|
|
478
|
+
let t = q.value.target;
|
|
479
|
+
t.style.transform = "translateX(var(--t-app-width))", t.transitionOrigin = "center", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), setTimeout(() => {
|
|
480
|
+
t.style.transition = "transform 0.35s ease", t.style.transform = "translateX(0px)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), z.value && (z.value.target.style.transitionOrigin = "left center", z.value.target.style.transition = "transform 0.35s ease", z.value.target.style.transform = "translateX(calc(var(--t-app-width) / 100 * 30 * -1))"), setTimeout(() => {
|
|
481
|
+
I.value = !1, A.value += 1, e && e();
|
|
482
|
+
}, 400);
|
|
483
|
+
}, 100);
|
|
484
|
+
}
|
|
485
|
+
}, Ge = (e) => {
|
|
486
|
+
M.push(e);
|
|
487
|
+
}, Ue = (e, t) => {
|
|
488
|
+
M[e].target = t;
|
|
489
|
+
}, re = (e) => {
|
|
490
|
+
e || M.pop();
|
|
491
|
+
}, je = () => {
|
|
492
|
+
M.splice(0, M.length);
|
|
493
|
+
}, Fe = () => {
|
|
425
494
|
Q.value = !1;
|
|
426
|
-
},
|
|
495
|
+
}, Ke = () => {
|
|
427
496
|
Q.value = !0;
|
|
428
|
-
},
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
497
|
+
}, Je = (e, t) => {
|
|
498
|
+
e == "scale" && Z.next(t), e == "transform" && Y.next(t);
|
|
499
|
+
}, Qe = (e, t) => {
|
|
500
|
+
e == "scale" && Z.back(t), e == "transform" && Y.back(t);
|
|
501
|
+
}, Ze = (e, t) => {
|
|
502
|
+
e == "scale" && Z.move(t), e == "transform" && Y.move(t);
|
|
503
|
+
}, Ye = (e) => {
|
|
504
|
+
e == "scale" && Z.reset(), e == "transform" && Y.reset();
|
|
505
|
+
}, x = {
|
|
506
|
+
isBusy: I,
|
|
507
|
+
isSwipeable: fe,
|
|
508
|
+
reset: Ye,
|
|
509
|
+
next: Je,
|
|
510
|
+
back: Qe,
|
|
511
|
+
move: Ze,
|
|
512
|
+
screens: M,
|
|
513
|
+
addScreen: Ge,
|
|
514
|
+
addScreenEl: Ue,
|
|
515
|
+
removeScreen: re,
|
|
516
|
+
removeAllScreen: je,
|
|
517
|
+
lockSwipe: Fe,
|
|
518
|
+
unlockSwipe: Ke,
|
|
435
519
|
swipeable: Q,
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
return C[C.length - 2];
|
|
441
|
-
})
|
|
442
|
-
}, We = /* @__PURE__ */ g({
|
|
520
|
+
currentScreen: z,
|
|
521
|
+
lastScreen: B,
|
|
522
|
+
nextScreen: q
|
|
523
|
+
}, et = { class: "t-toast-content" }, tt = /* @__PURE__ */ b({
|
|
443
524
|
__name: "t-toast",
|
|
444
525
|
props: {
|
|
445
526
|
message: {},
|
|
446
527
|
space: { default: "0px" },
|
|
447
528
|
placement: { default: "bottom" },
|
|
448
|
-
duration: { default: 2e3 },
|
|
449
529
|
color: { default: null },
|
|
450
|
-
variant: { default: "default" }
|
|
530
|
+
variant: { default: "default" },
|
|
531
|
+
visible: { type: Boolean, default: !1 }
|
|
451
532
|
},
|
|
452
533
|
emits: ["dismiss"],
|
|
453
|
-
setup(
|
|
454
|
-
const
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
}, 10)
|
|
458
|
-
|
|
459
|
-
}, t.duration + 10);
|
|
460
|
-
}, m = () => {
|
|
534
|
+
setup(e, { expose: t, emit: s }) {
|
|
535
|
+
const o = e, n = s, l = m(!1), u = m(!1), a = m(!1), i = () => {
|
|
536
|
+
u.value = !0, a.value = !1, setTimeout(() => {
|
|
537
|
+
l.value = !0;
|
|
538
|
+
}, 10);
|
|
539
|
+
}, p = () => {
|
|
461
540
|
a.value = !0, setTimeout(() => {
|
|
462
|
-
|
|
541
|
+
u.value = !1, l.value = !1, n("dismiss");
|
|
463
542
|
}, 300);
|
|
464
|
-
}
|
|
465
|
-
|
|
466
|
-
|
|
543
|
+
};
|
|
544
|
+
O(() => o.visible, (r) => {
|
|
545
|
+
r ? i() : p();
|
|
546
|
+
});
|
|
547
|
+
const _ = w(() => {
|
|
548
|
+
let r;
|
|
549
|
+
return o.variant == "default" && (o.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(o.color) ? r = {
|
|
467
550
|
"--border": "none",
|
|
468
|
-
"--color": "var(--t-color-status-" +
|
|
469
|
-
"--background": "rgba(var(--t-color-status-" +
|
|
470
|
-
} :
|
|
551
|
+
"--color": "var(--t-color-status-" + o.color + "-text)",
|
|
552
|
+
"--background": "rgba(var(--t-color-status-" + o.color + "-rgb), 1)"
|
|
553
|
+
} : r = {
|
|
471
554
|
"--border": "none",
|
|
472
555
|
"--color": "var(--t-color-text)",
|
|
473
|
-
"--background":
|
|
474
|
-
} :
|
|
556
|
+
"--background": o.color
|
|
557
|
+
} : r = {
|
|
475
558
|
"--border": "none",
|
|
476
559
|
"--color": "var(--t-color-text)",
|
|
477
560
|
"--background": "rgba(var(--t-color-surface-rgb), 1)"
|
|
478
|
-
}),
|
|
561
|
+
}), o.variant == "text" && (o.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(o.color) ? r = {
|
|
479
562
|
"--border": "none",
|
|
480
|
-
"--color": "var(--t-color-status-" +
|
|
563
|
+
"--color": "var(--t-color-status-" + o.color + ")",
|
|
481
564
|
"--background": "transparent"
|
|
482
|
-
} :
|
|
565
|
+
} : r = {
|
|
483
566
|
"--border": "none",
|
|
484
|
-
"--color":
|
|
567
|
+
"--color": o.color,
|
|
485
568
|
"--background": "transparent"
|
|
486
|
-
} :
|
|
569
|
+
} : r = {
|
|
487
570
|
"--border": "none",
|
|
488
571
|
"--color": "var(--t-color-text)",
|
|
489
572
|
"--background": "transparent"
|
|
490
|
-
}),
|
|
491
|
-
"--border": "0.55px solid var(--t-color-status-" +
|
|
492
|
-
"--color": "var(--t-color-status-" +
|
|
573
|
+
}), o.variant == "outline" && (o.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(o.color) ? r = {
|
|
574
|
+
"--border": "0.55px solid var(--t-color-status-" + o.color + ")",
|
|
575
|
+
"--color": "var(--t-color-status-" + o.color + ")",
|
|
493
576
|
"--background": "transparent"
|
|
494
|
-
} :
|
|
495
|
-
"--border": "0.55px solid " +
|
|
496
|
-
"--color":
|
|
577
|
+
} : r = {
|
|
578
|
+
"--border": "0.55px solid " + o.color,
|
|
579
|
+
"--color": o.color,
|
|
497
580
|
"--background": "transparent"
|
|
498
|
-
} :
|
|
581
|
+
} : r = {
|
|
499
582
|
"--border": "0.55px solid var(--t-color-text)",
|
|
500
583
|
"--color": "var(--t-color-text)",
|
|
501
584
|
"--background": "transparent"
|
|
502
|
-
}),
|
|
585
|
+
}), r;
|
|
503
586
|
});
|
|
504
|
-
return
|
|
505
|
-
open:
|
|
506
|
-
|
|
587
|
+
return t({
|
|
588
|
+
open: i,
|
|
589
|
+
close: p
|
|
590
|
+
}), (r, y) => u.value ? (c(), d("div", {
|
|
507
591
|
key: 0,
|
|
508
|
-
class:
|
|
509
|
-
style:
|
|
510
|
-
},
|
|
592
|
+
class: T(["t-toast", { [o.placement]: !0, open: l.value, closing: a.value }]),
|
|
593
|
+
style: k({ "--space": o.space, ..._.value })
|
|
594
|
+
}, [
|
|
595
|
+
g(r.$slots, "content", {}, () => [
|
|
596
|
+
h("div", et, R(o.message), 1)
|
|
597
|
+
], !0)
|
|
598
|
+
], 6)) : E("", !0);
|
|
511
599
|
}
|
|
512
|
-
}),
|
|
600
|
+
}), me = /* @__PURE__ */ v(tt, [["__scopeId", "data-v-7011351e"]]), xs = (e = {}) => ({
|
|
513
601
|
open() {
|
|
514
|
-
let
|
|
515
|
-
if (!
|
|
516
|
-
const
|
|
517
|
-
|
|
518
|
-
const n =
|
|
602
|
+
let t = document.body.querySelector(".t-app");
|
|
603
|
+
if (!t) return;
|
|
604
|
+
const s = document.createElement("div"), o = m();
|
|
605
|
+
t.appendChild(s);
|
|
606
|
+
const n = j({
|
|
519
607
|
render() {
|
|
520
|
-
return
|
|
521
|
-
...
|
|
522
|
-
ref:
|
|
608
|
+
return F(me, {
|
|
609
|
+
...e,
|
|
610
|
+
ref: o,
|
|
523
611
|
onDismiss: () => {
|
|
524
612
|
setTimeout(() => {
|
|
525
|
-
n.unmount(),
|
|
613
|
+
n.unmount(), s.remove();
|
|
526
614
|
}, 300);
|
|
527
615
|
}
|
|
528
616
|
});
|
|
529
617
|
}
|
|
530
618
|
});
|
|
531
|
-
n.mount(
|
|
532
|
-
|
|
619
|
+
n.mount(s), setTimeout(() => {
|
|
620
|
+
o.value?.open?.(), setTimeout(() => {
|
|
621
|
+
o.value?.close?.();
|
|
622
|
+
}, e.duration + 10);
|
|
533
623
|
}, 50);
|
|
534
624
|
}
|
|
535
|
-
}),
|
|
536
|
-
function
|
|
625
|
+
}), st = m(0);
|
|
626
|
+
function ve() {
|
|
537
627
|
return {
|
|
538
|
-
height:
|
|
628
|
+
height: st
|
|
539
629
|
};
|
|
540
630
|
}
|
|
541
|
-
const
|
|
631
|
+
const ot = /* @__PURE__ */ b({
|
|
542
632
|
__name: "t-cable",
|
|
543
633
|
props: {
|
|
544
634
|
keyboard: { type: Boolean, default: !0 },
|
|
545
635
|
placement: { default: "bottom" }
|
|
546
636
|
},
|
|
547
|
-
setup(
|
|
548
|
-
const
|
|
549
|
-
return
|
|
550
|
-
placement:
|
|
551
|
-
}), (
|
|
552
|
-
class:
|
|
553
|
-
style:
|
|
637
|
+
setup(e) {
|
|
638
|
+
const t = e, { height: s } = ve();
|
|
639
|
+
return ie("cableState", {
|
|
640
|
+
placement: t.placement
|
|
641
|
+
}), (o, n) => (c(), d("div", {
|
|
642
|
+
class: T(["t-cable", { keyboard: t.keyboard && V(s) > 0, [t.placement]: !0 }]),
|
|
643
|
+
style: k({ "--t-keyboard-height": V(s) + "px", "--t-keyboard-transition": V(s) > 0 ? "0.3s" : "0.1s" })
|
|
554
644
|
}, [
|
|
555
|
-
|
|
645
|
+
g(o.$slots, "default", {}, void 0, !0)
|
|
556
646
|
], 6));
|
|
557
647
|
}
|
|
558
|
-
}),
|
|
648
|
+
}), nt = /* @__PURE__ */ v(ot, [["__scopeId", "data-v-5234450f"]]), rt = /* @__PURE__ */ b({
|
|
559
649
|
__name: "t-card",
|
|
560
650
|
props: {
|
|
561
651
|
color: { default: null }
|
|
562
652
|
},
|
|
563
|
-
setup(
|
|
564
|
-
const
|
|
565
|
-
let
|
|
566
|
-
return
|
|
567
|
-
"--background": "var(--t-color-status-" +
|
|
568
|
-
} :
|
|
569
|
-
"--background":
|
|
570
|
-
} :
|
|
653
|
+
setup(e) {
|
|
654
|
+
const t = e, s = w(() => {
|
|
655
|
+
let o;
|
|
656
|
+
return t.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) ? o = {
|
|
657
|
+
"--background": "var(--t-color-status-" + t.color + ")"
|
|
658
|
+
} : o = {
|
|
659
|
+
"--background": t.color
|
|
660
|
+
} : o = {
|
|
571
661
|
"--background": "var(--t-color-surface)"
|
|
572
|
-
},
|
|
662
|
+
}, o;
|
|
573
663
|
});
|
|
574
|
-
return (
|
|
664
|
+
return (o, n) => (c(), d("div", {
|
|
575
665
|
class: "t-card",
|
|
576
|
-
style:
|
|
666
|
+
style: k(s.value)
|
|
577
667
|
}, [
|
|
578
|
-
|
|
668
|
+
g(o.$slots, "default")
|
|
579
669
|
], 4));
|
|
580
670
|
}
|
|
581
|
-
}),
|
|
582
|
-
function
|
|
583
|
-
return c(),
|
|
584
|
-
|
|
671
|
+
}), at = {}, lt = { class: "t-content" };
|
|
672
|
+
function ct(e, t) {
|
|
673
|
+
return c(), d("div", lt, [
|
|
674
|
+
g(e.$slots, "default", {}, void 0, !0)
|
|
585
675
|
]);
|
|
586
676
|
}
|
|
587
|
-
const
|
|
677
|
+
const _e = /* @__PURE__ */ v(at, [["render", ct], ["__scopeId", "data-v-af750e89"]]), le = 80, it = /* @__PURE__ */ b({
|
|
588
678
|
__name: "t-refresher",
|
|
589
679
|
emits: ["refresh"],
|
|
590
|
-
setup(
|
|
591
|
-
const
|
|
592
|
-
let
|
|
593
|
-
const
|
|
594
|
-
n.value = !1,
|
|
680
|
+
setup(e, { emit: t }) {
|
|
681
|
+
const s = t, o = m(0), n = m(!1), l = m();
|
|
682
|
+
let u, a = !1;
|
|
683
|
+
const i = () => {
|
|
684
|
+
n.value = !1, o.value = 0, u && u.cancel(), setTimeout(() => {
|
|
595
685
|
a = !1;
|
|
596
686
|
}, 2e3);
|
|
597
|
-
},
|
|
598
|
-
a = !0, n.value = !0,
|
|
687
|
+
}, p = () => {
|
|
688
|
+
a = !0, n.value = !0, o.value = le, s("refresh", i);
|
|
599
689
|
};
|
|
600
|
-
return
|
|
601
|
-
|
|
602
|
-
let
|
|
603
|
-
|
|
690
|
+
return O(() => l.value, () => {
|
|
691
|
+
u && u.destroy();
|
|
692
|
+
let _ = l.value.closest(".t-content");
|
|
693
|
+
_ && (u = ne(_, {
|
|
604
694
|
isMoving: !1,
|
|
605
695
|
options: {
|
|
606
696
|
minDist: 60
|
|
@@ -608,197 +698,185 @@ const ce = /* @__PURE__ */ _(Fe, [["render", Xe], ["__scopeId", "data-v-af750e89
|
|
|
608
698
|
down() {
|
|
609
699
|
this.isMoving = !1;
|
|
610
700
|
},
|
|
611
|
-
move({ deltaY:
|
|
612
|
-
n.value || a ||
|
|
701
|
+
move({ deltaY: r, initialDirection: y }) {
|
|
702
|
+
n.value || a || y != "down" || (r >= 120 ? (this.isMoving = !1, p()) : (r > 10 || this.isMoving) && (this.isMoving = !0, o.value = r > 0 ? r : 0));
|
|
613
703
|
},
|
|
614
|
-
up({ deltaY:
|
|
615
|
-
this.isMoving = !1, !(n.value || a) && (
|
|
704
|
+
up({ deltaY: r, initialDirection: y }) {
|
|
705
|
+
this.isMoving = !1, !(n.value || a) && (r > le && y == "down" ? p() : o.value = 0);
|
|
616
706
|
},
|
|
617
707
|
cancel() {
|
|
618
|
-
this.isMoving = !1, !(n.value || a) && (n.value = !1,
|
|
708
|
+
this.isMoving = !1, !(n.value || a) && (n.value = !1, o.value = 0);
|
|
619
709
|
}
|
|
620
710
|
}, {
|
|
621
711
|
passive: !1
|
|
622
712
|
}));
|
|
623
|
-
}),
|
|
624
|
-
|
|
625
|
-
}), (
|
|
713
|
+
}), se(() => {
|
|
714
|
+
u && u.destroy();
|
|
715
|
+
}), (_, r) => W((c(), d("div", {
|
|
626
716
|
class: "t-refresher",
|
|
627
717
|
ref_key: "container",
|
|
628
|
-
ref:
|
|
629
|
-
style:
|
|
718
|
+
ref: l,
|
|
719
|
+
style: k({ height: `${o.value}px` })
|
|
630
720
|
}, [
|
|
631
|
-
|
|
632
|
-
class:
|
|
721
|
+
h("img", {
|
|
722
|
+
class: T({ spiner: n.value }),
|
|
633
723
|
src: "https://static.toikit.com/toikit/home_2.png?v=3",
|
|
634
724
|
alt: "Loading...",
|
|
635
725
|
style: { width: "22px", height: "22px" }
|
|
636
726
|
}, null, 2)
|
|
637
727
|
], 4)), [
|
|
638
|
-
[
|
|
728
|
+
[H, o.value > 0]
|
|
639
729
|
]);
|
|
640
730
|
}
|
|
641
|
-
}),
|
|
642
|
-
function
|
|
643
|
-
return c(),
|
|
644
|
-
|
|
731
|
+
}), ut = /* @__PURE__ */ v(it, [["__scopeId", "data-v-c6364c14"]]), dt = {}, pt = { class: "t-screen" };
|
|
732
|
+
function ft(e, t) {
|
|
733
|
+
return c(), d("div", pt, [
|
|
734
|
+
g(e.$slots, "default", {}, void 0, !0)
|
|
645
735
|
]);
|
|
646
736
|
}
|
|
647
|
-
const
|
|
737
|
+
const ye = /* @__PURE__ */ v(dt, [["render", ft], ["__scopeId", "data-v-c2a3436c"]]), mt = /* @__PURE__ */ b({
|
|
648
738
|
__name: "t-swipe-screen",
|
|
739
|
+
props: {
|
|
740
|
+
variant: { default: "scale" }
|
|
741
|
+
},
|
|
649
742
|
emits: ["change"],
|
|
650
|
-
setup(
|
|
651
|
-
let
|
|
652
|
-
const
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
743
|
+
setup(e, { emit: t }) {
|
|
744
|
+
let s = {};
|
|
745
|
+
const o = de(), n = $e(), l = o.getRoutes(), u = t, a = e;
|
|
746
|
+
let i;
|
|
747
|
+
for (let r of l)
|
|
748
|
+
s[r.name] = r.components;
|
|
749
|
+
const p = (r) => {
|
|
750
|
+
r && x.addScreen({
|
|
751
|
+
name: r,
|
|
658
752
|
target: null,
|
|
659
|
-
component:
|
|
753
|
+
component: he(s[r] || null)
|
|
660
754
|
});
|
|
661
|
-
},
|
|
662
|
-
!
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
}, 400);
|
|
666
|
-
}, 100)));
|
|
667
|
-
}, y = () => {
|
|
668
|
-
k.currentScreen.value.target.style.transition = "transform 0.35s ease", k.currentScreen.value.target.style.transform = "translateX(var(--t-app-width)) scale(1)", k.lastScreen.value.target.style.transition = "transform 0.35s ease", k.lastScreen.value.target.style.transform = "translateX(0px) scale(1) perspective(var(--t-app-width)) rotateY(0deg)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0"), i.value = !0, setTimeout(() => {
|
|
669
|
-
k.removeScreen(), a("change"), i.value = !1;
|
|
670
|
-
}, 400);
|
|
671
|
-
};
|
|
672
|
-
d(n.name), L(() => n.name, (u, h) => {
|
|
673
|
-
u != k.currentScreen.value.name && (k.lastScreen.value?.name == u ? y() : d(u));
|
|
674
|
-
});
|
|
675
|
-
const l = () => {
|
|
676
|
-
i.value = !0;
|
|
677
|
-
const u = k.currentScreen.value.target, h = k.lastScreen.value.target;
|
|
678
|
-
u.style.transition = "transform 0.35s ease", u.style.transform = "translateX(0px)", h.style.transition = "transform 0.35s ease", h.style.transform = "translateX(calc(var(--t-app-width) / 100 * 30 * -1)) scale(0.5) perspective(var(--t-app-width)) rotateY(30deg)", document.documentElement.style.setProperty("--t-screen-backdrop-duration", "0.35s"), document.documentElement.style.setProperty("--t-swipe-backdrop-opacity", "0.5"), setTimeout(() => {
|
|
679
|
-
i.value = !1;
|
|
680
|
-
}, 400);
|
|
755
|
+
}, _ = (r, y) => {
|
|
756
|
+
!y || x.screens[r].target || (x.addScreenEl(r, y.$el), x.nextScreen && x.next(a.variant, () => {
|
|
757
|
+
u("change");
|
|
758
|
+
}));
|
|
681
759
|
};
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
760
|
+
return O(() => n.name, (r, y) => {
|
|
761
|
+
r != x.currentScreen.value.name && (x.lastScreen.value?.name == r ? x.back(a.variant, () => {
|
|
762
|
+
u("change");
|
|
763
|
+
}) : p(n.name));
|
|
764
|
+
}), oe(() => {
|
|
765
|
+
i = ne(document.body, {
|
|
766
|
+
beforeEvent(r) {
|
|
767
|
+
return !!x.isSwipeable.value;
|
|
688
768
|
},
|
|
689
|
-
fast({ initialDirection:
|
|
690
|
-
|
|
769
|
+
fast({ initialDirection: r }) {
|
|
770
|
+
x.lastScreen.value && r == "right" && o.back();
|
|
691
771
|
},
|
|
692
|
-
|
|
693
|
-
|
|
772
|
+
move({ deltaX: r, initialDirection: y }) {
|
|
773
|
+
y == "right" && x.move(a.variant, r);
|
|
694
774
|
},
|
|
695
|
-
|
|
696
|
-
if (
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
const f = window.innerWidth;
|
|
703
|
-
u / f * 100 >= 50 ? t.back() : l();
|
|
775
|
+
up({ deltaX: r, initialDirection: y }) {
|
|
776
|
+
if (y != "right") {
|
|
777
|
+
x.reset(a.variant);
|
|
778
|
+
return;
|
|
779
|
+
}
|
|
780
|
+
const $ = window.innerWidth;
|
|
781
|
+
r / $ * 100 >= 50 ? o.back() : x.reset(a.variant);
|
|
704
782
|
},
|
|
705
783
|
cancel() {
|
|
706
|
-
|
|
784
|
+
x.reset(a.variant);
|
|
707
785
|
}
|
|
708
786
|
});
|
|
709
|
-
}),
|
|
710
|
-
|
|
711
|
-
}), (
|
|
712
|
-
(c(!0),
|
|
787
|
+
}), se(() => {
|
|
788
|
+
i && i.destroy(), x.removeAllScreen();
|
|
789
|
+
}), p(n.name), (r, y) => (c(), d(X, null, [
|
|
790
|
+
(c(!0), d(X, null, G(V(x).screens, ($, S) => (c(), C(ye, {
|
|
713
791
|
ref_for: !0,
|
|
714
|
-
ref: (
|
|
715
|
-
style:
|
|
716
|
-
key:
|
|
792
|
+
ref: (f) => _(S, f),
|
|
793
|
+
style: k({ zIndex: S + (S == V(x).screens.length - 1 ? 2 : 1) }),
|
|
794
|
+
key: S
|
|
717
795
|
}, {
|
|
718
|
-
default:
|
|
719
|
-
(c(),
|
|
796
|
+
default: P(() => [
|
|
797
|
+
(c(), C(be($.component.default)))
|
|
720
798
|
]),
|
|
721
799
|
_: 2
|
|
722
800
|
}, 1032, ["style"]))), 128)),
|
|
723
|
-
|
|
801
|
+
h("div", {
|
|
724
802
|
class: "t-swipe-backdrop",
|
|
725
|
-
style:
|
|
803
|
+
style: k({ zIndex: V(x).screens.length })
|
|
726
804
|
}, null, 4)
|
|
727
805
|
], 64));
|
|
728
806
|
}
|
|
729
|
-
}),
|
|
807
|
+
}), vt = /* @__PURE__ */ v(mt, [["__scopeId", "data-v-b6917f76"]]), _t = /* @__PURE__ */ b({
|
|
730
808
|
__name: "t-toolbar",
|
|
731
809
|
props: {
|
|
732
810
|
placement: { default: null },
|
|
733
811
|
safe: { type: Boolean, default: !0 },
|
|
734
812
|
size: { default: "50px" }
|
|
735
813
|
},
|
|
736
|
-
setup(
|
|
737
|
-
const
|
|
738
|
-
return (n,
|
|
739
|
-
class:
|
|
740
|
-
style:
|
|
814
|
+
setup(e) {
|
|
815
|
+
const t = e, s = ue("cableState"), o = w(() => t?.placement || s?.placement);
|
|
816
|
+
return (n, l) => (c(), d("div", {
|
|
817
|
+
class: T(["t-toolbar", { [o.value]: !0, safe: t.safe }]),
|
|
818
|
+
style: k({ "--t-size-toolbar": t.size })
|
|
741
819
|
}, [
|
|
742
|
-
|
|
743
|
-
|
|
820
|
+
h("div", null, [
|
|
821
|
+
g(n.$slots, "default", {}, void 0, !0)
|
|
744
822
|
])
|
|
745
823
|
], 6));
|
|
746
824
|
}
|
|
747
|
-
}),
|
|
825
|
+
}), yt = /* @__PURE__ */ v(_t, [["__scopeId", "data-v-1ee9866d"]]), gt = /* @__PURE__ */ b({
|
|
748
826
|
__name: "t-back-button",
|
|
749
827
|
props: {
|
|
750
828
|
to: {}
|
|
751
829
|
},
|
|
752
|
-
setup(
|
|
753
|
-
const
|
|
754
|
-
if (
|
|
755
|
-
|
|
830
|
+
setup(e) {
|
|
831
|
+
const t = de(), s = e, o = ke(), n = (l) => {
|
|
832
|
+
if (o.onBack) {
|
|
833
|
+
o.onBack(l);
|
|
756
834
|
return;
|
|
757
835
|
}
|
|
758
|
-
|
|
836
|
+
x.lastScreen.value ? t?.back?.() : s.to && t?.push?.(s.to);
|
|
759
837
|
};
|
|
760
|
-
return (
|
|
838
|
+
return (l, u) => l.to || V(x).lastScreen ? (c(), d("button", {
|
|
761
839
|
key: 0,
|
|
762
840
|
class: "t-back-button",
|
|
763
841
|
onClick: n
|
|
764
842
|
}, [
|
|
765
|
-
|
|
766
|
-
|
|
843
|
+
g(l.$slots, "default", {}, () => [
|
|
844
|
+
u[0] || (u[0] = h("i", { class: "ri-arrow-left-s-line" }, null, -1))
|
|
767
845
|
], !0)
|
|
768
|
-
])) :
|
|
846
|
+
])) : E("", !0);
|
|
769
847
|
}
|
|
770
|
-
}),
|
|
848
|
+
}), bt = /* @__PURE__ */ v(gt, [["__scopeId", "data-v-25ab48bb"]]), ht = /* @__PURE__ */ b({
|
|
771
849
|
__name: "t-text",
|
|
772
850
|
props: {
|
|
773
851
|
color: { default: "var(--t-color-text)" },
|
|
774
852
|
size: { default: "standard" }
|
|
775
853
|
},
|
|
776
|
-
setup(
|
|
777
|
-
const
|
|
778
|
-
let
|
|
779
|
-
return
|
|
854
|
+
setup(e) {
|
|
855
|
+
const t = e, s = w(() => {
|
|
856
|
+
let o, n = t.color;
|
|
857
|
+
return t.size == "standard" ? o = "var(--t-fs-10)" : t.size == "small" ? o = "var(--t-fs-08)" : t.size == "large" ? o = "var(--t-fs-12)" : o = t.size, ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) && (n = `var(--t-color-status-${t.color})`), {
|
|
780
858
|
"--color": n,
|
|
781
|
-
"--font-size":
|
|
859
|
+
"--font-size": o
|
|
782
860
|
};
|
|
783
861
|
});
|
|
784
|
-
return (
|
|
862
|
+
return (o, n) => (c(), d("span", {
|
|
785
863
|
class: "t-text",
|
|
786
|
-
style:
|
|
864
|
+
style: k(s.value)
|
|
787
865
|
}, [
|
|
788
|
-
|
|
866
|
+
g(o.$slots, "default", {}, void 0, !0)
|
|
789
867
|
], 4));
|
|
790
868
|
}
|
|
791
|
-
}),
|
|
869
|
+
}), te = /* @__PURE__ */ v(ht, [["__scopeId", "data-v-f0f94f05"]]), kt = /* @__PURE__ */ b({
|
|
792
870
|
__name: "t-gesture-indicator",
|
|
793
871
|
props: {
|
|
794
872
|
placement: { default: "bottom" }
|
|
795
873
|
},
|
|
796
|
-
setup(
|
|
797
|
-
return (
|
|
798
|
-
class:
|
|
874
|
+
setup(e) {
|
|
875
|
+
return (t, s) => (c(), d("div", {
|
|
876
|
+
class: T(["t-gesture-indicator", { [t.placement]: !0 }])
|
|
799
877
|
}, null, 2));
|
|
800
878
|
}
|
|
801
|
-
}),
|
|
879
|
+
}), ge = /* @__PURE__ */ v(kt, [["__scopeId", "data-v-ed8f7308"]]), $t = /* @__PURE__ */ b({
|
|
802
880
|
__name: "t-sheet",
|
|
803
881
|
props: {
|
|
804
882
|
background: { default: "var(--t-color-surface)" },
|
|
@@ -815,87 +893,87 @@ const ie = /* @__PURE__ */ _(Ze, [["render", et], ["__scopeId", "data-v-c2a3436c
|
|
|
815
893
|
style: {}
|
|
816
894
|
},
|
|
817
895
|
emits: ["dismiss"],
|
|
818
|
-
setup(
|
|
819
|
-
const
|
|
896
|
+
setup(e, { emit: t }) {
|
|
897
|
+
const s = e, o = t, n = m(), l = m(), u = m(!1);
|
|
820
898
|
let a = null;
|
|
821
|
-
const
|
|
822
|
-
if (
|
|
823
|
-
if (
|
|
824
|
-
if (
|
|
825
|
-
if (
|
|
826
|
-
}),
|
|
827
|
-
|
|
828
|
-
},
|
|
829
|
-
|
|
830
|
-
|
|
899
|
+
const i = w(() => {
|
|
900
|
+
if (s.placement == "bottom") return "down";
|
|
901
|
+
if (s.placement == "top") return "up";
|
|
902
|
+
if (s.placement == "left") return "left";
|
|
903
|
+
if (s.placement == "right") return "right";
|
|
904
|
+
}), p = (r) => {
|
|
905
|
+
o("dismiss", r);
|
|
906
|
+
}, _ = () => {
|
|
907
|
+
u.value = !0, setTimeout(() => {
|
|
908
|
+
u.value = !1;
|
|
831
909
|
}, 300);
|
|
832
910
|
};
|
|
833
|
-
return
|
|
834
|
-
|
|
911
|
+
return O(() => n.value, (r) => {
|
|
912
|
+
r && (a = ne(n.value, {
|
|
835
913
|
isMoving: !1,
|
|
836
914
|
options: {
|
|
837
915
|
minDist: 30
|
|
838
916
|
},
|
|
839
|
-
beforeEvent(
|
|
840
|
-
return !(
|
|
917
|
+
beforeEvent(y) {
|
|
918
|
+
return !(u.value || !s.gesture || s.placement == "center");
|
|
841
919
|
},
|
|
842
920
|
down() {
|
|
843
921
|
this.isMoving = !1;
|
|
844
922
|
},
|
|
845
|
-
fast({ initialDirection:
|
|
846
|
-
|
|
923
|
+
fast({ initialDirection: y }) {
|
|
924
|
+
_(), y == i.value ? o("dismiss", "gesture") : l.value.open();
|
|
847
925
|
},
|
|
848
|
-
move({ deltaY:
|
|
849
|
-
if (
|
|
926
|
+
move({ deltaY: y, deltaX: $, initialDirection: S }) {
|
|
927
|
+
if (S != i.value) return;
|
|
850
928
|
let f = 0;
|
|
851
|
-
|
|
929
|
+
s.placement == "bottom" || s.placement == "top" ? f = y : f = $, s.placement == "bottom" && (f = y > 0 ? y : 0), s.placement == "top" && (f = y < 0 ? y : 0), s.placement == "left" && (f = $ < 0 ? $ : 0), s.placement == "right" && (f = $ > 0 ? $ : 0), (s.placement == "bottom" && (f >= 10 || this.isMoving) || s.placement == "top" && (f <= -10 || this.isMoving) || s.placement == "left" && (f <= -10 || this.isMoving) || s.placement == "right" && (f >= 10 || this.isMoving)) && (this.isMoving = !0, l.value.render({
|
|
852
930
|
contentTransform: f + "px",
|
|
853
931
|
transition: "0s"
|
|
854
932
|
}));
|
|
855
933
|
},
|
|
856
|
-
up({ deltaY:
|
|
857
|
-
if (this.isMoving = !1,
|
|
858
|
-
|
|
934
|
+
up({ deltaY: y, deltaX: $, initialDirection: S }) {
|
|
935
|
+
if (this.isMoving = !1, _(), S != i.value) {
|
|
936
|
+
l.value.open();
|
|
859
937
|
return;
|
|
860
938
|
}
|
|
861
|
-
let f,
|
|
862
|
-
|
|
939
|
+
let f, D, ee;
|
|
940
|
+
s.placement == "bottom" || s.placement == "top" ? (f = n.value.offsetHeight, ee = y) : (f = n.value.offsetWidth, ee = $), D = ee / f * 100, D > 50 ? o("dismiss", "gesture") : l.value.open();
|
|
863
941
|
},
|
|
864
942
|
cancel() {
|
|
865
|
-
this.isMoving = !1,
|
|
943
|
+
this.isMoving = !1, _(), l.value.open();
|
|
866
944
|
}
|
|
867
945
|
}));
|
|
868
|
-
}),
|
|
946
|
+
}), se(() => {
|
|
869
947
|
a && a.destroy();
|
|
870
|
-
}), (
|
|
948
|
+
}), (r, y) => (c(), C(L, {
|
|
871
949
|
ref_key: "present",
|
|
872
|
-
ref:
|
|
873
|
-
class:
|
|
874
|
-
placement:
|
|
875
|
-
backdrop:
|
|
876
|
-
visible:
|
|
877
|
-
keepalive:
|
|
878
|
-
onDismiss:
|
|
879
|
-
style:
|
|
950
|
+
ref: l,
|
|
951
|
+
class: T(s.class),
|
|
952
|
+
placement: s.placement,
|
|
953
|
+
backdrop: r.backdrop,
|
|
954
|
+
visible: s.visible,
|
|
955
|
+
keepalive: s.keepalive,
|
|
956
|
+
onDismiss: p,
|
|
957
|
+
style: k(s.style)
|
|
880
958
|
}, {
|
|
881
|
-
default:
|
|
882
|
-
|
|
959
|
+
default: P(() => [
|
|
960
|
+
s.gesture && s.indicator && s.placement != "center" ? (c(), C(ge, {
|
|
883
961
|
key: 0,
|
|
884
|
-
placement:
|
|
885
|
-
}, null, 8, ["placement"])) :
|
|
886
|
-
|
|
887
|
-
class:
|
|
888
|
-
style:
|
|
962
|
+
placement: s.placement
|
|
963
|
+
}, null, 8, ["placement"])) : E("", !0),
|
|
964
|
+
h("div", {
|
|
965
|
+
class: T(["t-sheet", { fullscreen: s.fullscreen, [s.placement]: !0, rounded: r.rounded, radius: s.radius }]),
|
|
966
|
+
style: k({ "--background": s.background }),
|
|
889
967
|
ref_key: "sheet",
|
|
890
968
|
ref: n
|
|
891
969
|
}, [
|
|
892
|
-
|
|
970
|
+
g(r.$slots, "default", {}, void 0, !0)
|
|
893
971
|
], 6)
|
|
894
972
|
]),
|
|
895
973
|
_: 3
|
|
896
974
|
}, 8, ["class", "placement", "backdrop", "visible", "keepalive", "style"]));
|
|
897
975
|
}
|
|
898
|
-
}),
|
|
976
|
+
}), wt = /* @__PURE__ */ v($t, [["__scopeId", "data-v-71a5b877"]]), xt = { class: "t-input-label" }, Tt = { class: "t-input-content" }, St = ["type", "placeholder", "value"], zt = /* @__PURE__ */ b({
|
|
899
977
|
__name: "t-input",
|
|
900
978
|
props: {
|
|
901
979
|
size: { default: "standard" },
|
|
@@ -909,227 +987,227 @@ const ie = /* @__PURE__ */ _(Ze, [["render", et], ["__scopeId", "data-v-c2a3436c
|
|
|
909
987
|
variant: { default: "default" }
|
|
910
988
|
},
|
|
911
989
|
emits: ["update:modelValue"],
|
|
912
|
-
setup(
|
|
913
|
-
const
|
|
914
|
-
|
|
990
|
+
setup(e, { emit: t }) {
|
|
991
|
+
const s = e, o = t, n = (l) => {
|
|
992
|
+
o("update:modelValue", l.target.value);
|
|
915
993
|
};
|
|
916
|
-
return (
|
|
917
|
-
class:
|
|
994
|
+
return (l, u) => (c(), d("div", {
|
|
995
|
+
class: T(["t-input", { rounded: s.rounded, ["size-" + s.size]: !0, ["variant-" + s.variant]: !0 }])
|
|
918
996
|
}, [
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
type:
|
|
925
|
-
placeholder:
|
|
926
|
-
value:
|
|
997
|
+
h("label", null, [
|
|
998
|
+
h("span", xt, R(l.label), 1),
|
|
999
|
+
h("div", Tt, [
|
|
1000
|
+
g(l.$slots, "start", {}, void 0, !0),
|
|
1001
|
+
h("input", {
|
|
1002
|
+
type: l.type,
|
|
1003
|
+
placeholder: l.placeholder,
|
|
1004
|
+
value: l.modelValue,
|
|
927
1005
|
onInput: n
|
|
928
|
-
}, null, 40,
|
|
929
|
-
|
|
1006
|
+
}, null, 40, St),
|
|
1007
|
+
g(l.$slots, "end", {}, void 0, !0)
|
|
930
1008
|
])
|
|
931
1009
|
]),
|
|
932
|
-
|
|
1010
|
+
s.error ? (c(), C(te, {
|
|
933
1011
|
key: 0,
|
|
934
1012
|
color: "danger"
|
|
935
1013
|
}, {
|
|
936
|
-
default:
|
|
937
|
-
R(
|
|
1014
|
+
default: P(() => [
|
|
1015
|
+
N(R(s.error), 1)
|
|
938
1016
|
]),
|
|
939
1017
|
_: 1
|
|
940
|
-
})) :
|
|
1018
|
+
})) : s.help ? (c(), C(te, {
|
|
941
1019
|
key: 1,
|
|
942
1020
|
color: "secondary"
|
|
943
1021
|
}, {
|
|
944
|
-
default:
|
|
945
|
-
R(
|
|
1022
|
+
default: P(() => [
|
|
1023
|
+
N(R(s.help), 1)
|
|
946
1024
|
]),
|
|
947
1025
|
_: 1
|
|
948
|
-
})) :
|
|
1026
|
+
})) : E("", !0)
|
|
949
1027
|
], 2));
|
|
950
1028
|
}
|
|
951
|
-
}),
|
|
952
|
-
function
|
|
953
|
-
return c(),
|
|
1029
|
+
}), It = /* @__PURE__ */ v(zt, [["__scopeId", "data-v-1a9425cf"]]), Et = {};
|
|
1030
|
+
function Bt(e, t) {
|
|
1031
|
+
return c(), d("textarea");
|
|
954
1032
|
}
|
|
955
|
-
const
|
|
956
|
-
function
|
|
957
|
-
return c(),
|
|
1033
|
+
const Ct = /* @__PURE__ */ v(Et, [["render", Bt]]), Vt = {};
|
|
1034
|
+
function Pt(e, t) {
|
|
1035
|
+
return c(), d("div");
|
|
958
1036
|
}
|
|
959
|
-
const
|
|
960
|
-
function
|
|
961
|
-
return c(),
|
|
1037
|
+
const At = /* @__PURE__ */ v(Vt, [["render", Pt]]), Rt = {}, Mt = { class: "t-grid" };
|
|
1038
|
+
function Dt(e, t) {
|
|
1039
|
+
return c(), d("div", Mt);
|
|
962
1040
|
}
|
|
963
|
-
const
|
|
964
|
-
function
|
|
965
|
-
return c(),
|
|
1041
|
+
const Xt = /* @__PURE__ */ v(Rt, [["render", Dt]]), Ot = {}, Nt = { class: "t-grid-item" };
|
|
1042
|
+
function qt(e, t) {
|
|
1043
|
+
return c(), d("div", Nt);
|
|
966
1044
|
}
|
|
967
|
-
const
|
|
1045
|
+
const Lt = /* @__PURE__ */ v(Ot, [["render", qt]]), Wt = /* @__PURE__ */ b({
|
|
968
1046
|
__name: "t-divider",
|
|
969
1047
|
props: {
|
|
970
1048
|
direction: { default: "horizontal" }
|
|
971
1049
|
},
|
|
972
|
-
setup(
|
|
973
|
-
const
|
|
974
|
-
return (
|
|
975
|
-
class:
|
|
1050
|
+
setup(e) {
|
|
1051
|
+
const t = e;
|
|
1052
|
+
return (s, o) => (c(), d("div", {
|
|
1053
|
+
class: T(["t-divider", { [t.direction]: !0 }])
|
|
976
1054
|
}, null, 2));
|
|
977
1055
|
}
|
|
978
|
-
}),
|
|
1056
|
+
}), Ht = /* @__PURE__ */ v(Wt, [["__scopeId", "data-v-47ee8991"]]), Gt = /* @__PURE__ */ b({
|
|
979
1057
|
__name: "t-toggle-password",
|
|
980
1058
|
props: {
|
|
981
1059
|
color: { default: "warning" }
|
|
982
1060
|
},
|
|
983
1061
|
emits: ["change"],
|
|
984
|
-
setup(
|
|
985
|
-
const
|
|
986
|
-
let
|
|
987
|
-
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(
|
|
988
|
-
"--color":
|
|
1062
|
+
setup(e, { emit: t }) {
|
|
1063
|
+
const s = e, o = t, n = m(!1), l = m(), u = w(() => {
|
|
1064
|
+
let p = s.color;
|
|
1065
|
+
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(s.color) && (p = `var(--t-color-status-${s.color})`), {
|
|
1066
|
+
"--color": p
|
|
989
1067
|
};
|
|
990
|
-
}), a = () =>
|
|
991
|
-
|
|
992
|
-
let
|
|
993
|
-
|
|
1068
|
+
}), a = () => l.value?.parentElement?.querySelector?.("input");
|
|
1069
|
+
oe(() => {
|
|
1070
|
+
let p = a();
|
|
1071
|
+
p && (n.value = p.type != "password", o("change", n.value));
|
|
994
1072
|
});
|
|
995
|
-
const
|
|
996
|
-
let
|
|
997
|
-
|
|
1073
|
+
const i = () => {
|
|
1074
|
+
let p = a();
|
|
1075
|
+
p && (n.value = !n.value, n.value ? p.type = "text" : p.type = "password", o("change", n.value));
|
|
998
1076
|
};
|
|
999
|
-
return (
|
|
1077
|
+
return (p, _) => (c(), d("button", {
|
|
1000
1078
|
ref_key: "toggle",
|
|
1001
|
-
ref:
|
|
1079
|
+
ref: l,
|
|
1002
1080
|
class: "t-toggle-password",
|
|
1003
|
-
style:
|
|
1004
|
-
onClick:
|
|
1081
|
+
style: k(u.value),
|
|
1082
|
+
onClick: i
|
|
1005
1083
|
}, [
|
|
1006
|
-
n.value ?
|
|
1007
|
-
|
|
1008
|
-
], !0) :
|
|
1009
|
-
n.value ?
|
|
1010
|
-
|
|
1084
|
+
n.value ? g(p.$slots, "on", { key: 0 }, () => [
|
|
1085
|
+
_[0] || (_[0] = h("i", { class: "ri-eye-line" }, null, -1))
|
|
1086
|
+
], !0) : E("", !0),
|
|
1087
|
+
n.value ? E("", !0) : g(p.$slots, "off", { key: 1 }, () => [
|
|
1088
|
+
_[1] || (_[1] = h("i", { class: "ri-eye-off-line" }, null, -1))
|
|
1011
1089
|
], !0)
|
|
1012
1090
|
], 4));
|
|
1013
1091
|
}
|
|
1014
|
-
}),
|
|
1092
|
+
}), Ut = /* @__PURE__ */ v(Gt, [["__scopeId", "data-v-3268e9e3"]]), jt = /* @__PURE__ */ b({
|
|
1015
1093
|
__name: "t-avatar",
|
|
1016
1094
|
props: {
|
|
1017
1095
|
square: { type: Boolean, default: !1 },
|
|
1018
1096
|
size: { default: "standard" }
|
|
1019
1097
|
},
|
|
1020
|
-
setup(
|
|
1021
|
-
const
|
|
1022
|
-
return (
|
|
1023
|
-
class:
|
|
1024
|
-
style:
|
|
1098
|
+
setup(e) {
|
|
1099
|
+
const t = e, s = w(() => t.size == "small" ? "24px" : t.size == "standard" ? "40px" : t.size == "large" ? "60px" : t.size);
|
|
1100
|
+
return (o, n) => (c(), d("div", {
|
|
1101
|
+
class: T(["t-avatar", { square: o.square }]),
|
|
1102
|
+
style: k({ "--size": s.value })
|
|
1025
1103
|
}, [
|
|
1026
|
-
|
|
1104
|
+
g(o.$slots, "default", {}, void 0, !0)
|
|
1027
1105
|
], 6));
|
|
1028
1106
|
}
|
|
1029
|
-
}),
|
|
1107
|
+
}), Ft = /* @__PURE__ */ v(jt, [["__scopeId", "data-v-24384c2f"]]), Kt = { class: "t-collapse-title" }, Jt = {
|
|
1030
1108
|
key: 0,
|
|
1031
1109
|
class: "icon"
|
|
1032
|
-
},
|
|
1110
|
+
}, Qt = {
|
|
1033
1111
|
key: 1,
|
|
1034
1112
|
class: "icon"
|
|
1035
|
-
},
|
|
1113
|
+
}, Zt = { class: "t-collapse-content" }, Yt = /* @__PURE__ */ b({
|
|
1036
1114
|
__name: "t-collapse",
|
|
1037
1115
|
props: {
|
|
1038
1116
|
title: {}
|
|
1039
1117
|
},
|
|
1040
1118
|
emits: ["change"],
|
|
1041
|
-
setup(
|
|
1042
|
-
const
|
|
1043
|
-
n.value = !n.value,
|
|
1119
|
+
setup(e, { emit: t }) {
|
|
1120
|
+
const s = e, o = t, n = m(!1), l = m(""), u = m(), a = () => {
|
|
1121
|
+
n.value = !n.value, l.value = `calc(${u.value.offsetHeight}px + 2rem)`, o("change", n.value);
|
|
1044
1122
|
};
|
|
1045
|
-
return
|
|
1046
|
-
class:
|
|
1047
|
-
style:
|
|
1123
|
+
return o("change", n.value), (i, p) => (c(), d("div", {
|
|
1124
|
+
class: T(["t-collapse", { open: n.value }]),
|
|
1125
|
+
style: k({ "--height": l.value })
|
|
1048
1126
|
}, [
|
|
1049
|
-
|
|
1127
|
+
h("div", {
|
|
1050
1128
|
class: "t-collapse-header",
|
|
1051
1129
|
onClick: a
|
|
1052
1130
|
}, [
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
R(
|
|
1131
|
+
g(i.$slots, "icon"),
|
|
1132
|
+
h("div", Kt, [
|
|
1133
|
+
g(i.$slots, "title", {}, () => [
|
|
1134
|
+
N(R(s.title), 1)
|
|
1057
1135
|
])
|
|
1058
1136
|
]),
|
|
1059
|
-
|
|
1060
|
-
n.value ? (c(),
|
|
1061
|
-
|
|
1062
|
-
])])) : (c(),
|
|
1063
|
-
|
|
1137
|
+
g(i.$slots, "toggle", {}, () => [
|
|
1138
|
+
n.value ? (c(), d("div", Jt, [...p[0] || (p[0] = [
|
|
1139
|
+
h("i", { class: "ri-arrow-up-s-line" }, null, -1)
|
|
1140
|
+
])])) : (c(), d("div", Qt, [...p[1] || (p[1] = [
|
|
1141
|
+
h("i", { class: "ri-arrow-down-s-line" }, null, -1)
|
|
1064
1142
|
])]))
|
|
1065
1143
|
])
|
|
1066
1144
|
]),
|
|
1067
|
-
|
|
1068
|
-
|
|
1145
|
+
h("div", Zt, [
|
|
1146
|
+
h("div", {
|
|
1069
1147
|
ref_key: "content",
|
|
1070
|
-
ref:
|
|
1148
|
+
ref: u
|
|
1071
1149
|
}, [
|
|
1072
|
-
|
|
1073
|
-
|
|
1150
|
+
g(i.$slots, "content", {}, () => [
|
|
1151
|
+
g(i.$slots, "default")
|
|
1074
1152
|
])
|
|
1075
1153
|
], 512)
|
|
1076
1154
|
])
|
|
1077
1155
|
], 6));
|
|
1078
1156
|
}
|
|
1079
|
-
}),
|
|
1157
|
+
}), es = /* @__PURE__ */ b({
|
|
1080
1158
|
__name: "t-switch",
|
|
1081
1159
|
props: {
|
|
1082
1160
|
modelValue: { type: Boolean },
|
|
1083
1161
|
color: { default: "primary" }
|
|
1084
1162
|
},
|
|
1085
1163
|
emits: ["update:modelValue"],
|
|
1086
|
-
setup(
|
|
1087
|
-
const
|
|
1088
|
-
|
|
1089
|
-
},
|
|
1090
|
-
let
|
|
1091
|
-
"--background":
|
|
1164
|
+
setup(e, { emit: t }) {
|
|
1165
|
+
const s = e, o = t, n = () => {
|
|
1166
|
+
o("update:modelValue", !s.modelValue);
|
|
1167
|
+
}, l = w(() => {
|
|
1168
|
+
let u = {
|
|
1169
|
+
"--background": s.color,
|
|
1092
1170
|
"--color": "#ffffff"
|
|
1093
1171
|
};
|
|
1094
|
-
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(
|
|
1095
|
-
"--background": `var(--t-color-status-${
|
|
1096
|
-
"--color": `var(--t-color-status-${
|
|
1097
|
-
}),
|
|
1172
|
+
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(s.color) && (u = {
|
|
1173
|
+
"--background": `var(--t-color-status-${s.color})`,
|
|
1174
|
+
"--color": `var(--t-color-status-${s.color}-text)`
|
|
1175
|
+
}), u;
|
|
1098
1176
|
});
|
|
1099
|
-
return (
|
|
1100
|
-
class:
|
|
1101
|
-
style:
|
|
1177
|
+
return (u, a) => (c(), d("div", {
|
|
1178
|
+
class: T(["t-switch", { on: s.modelValue }]),
|
|
1179
|
+
style: k(l.value),
|
|
1102
1180
|
onClick: n
|
|
1103
1181
|
}, [...a[0] || (a[0] = [
|
|
1104
|
-
|
|
1182
|
+
h("div", { class: "t-switch-icon" }, null, -1)
|
|
1105
1183
|
])], 6));
|
|
1106
1184
|
}
|
|
1107
|
-
}),
|
|
1185
|
+
}), ts = /* @__PURE__ */ v(es, [["__scopeId", "data-v-3616970e"]]), ss = /* @__PURE__ */ b({
|
|
1108
1186
|
__name: "t-tab",
|
|
1109
1187
|
props: {
|
|
1110
1188
|
value: {}
|
|
1111
1189
|
},
|
|
1112
|
-
setup(
|
|
1113
|
-
const
|
|
1114
|
-
|
|
1190
|
+
setup(e) {
|
|
1191
|
+
const t = e, s = ue("tabsState"), o = w(() => s.active.value === t.value), n = () => {
|
|
1192
|
+
s.setActive(t.value);
|
|
1115
1193
|
};
|
|
1116
|
-
return (
|
|
1117
|
-
class:
|
|
1194
|
+
return (l, u) => (c(), d("li", {
|
|
1195
|
+
class: T(["t-tab", { active: o.value }])
|
|
1118
1196
|
}, [
|
|
1119
|
-
|
|
1197
|
+
U(J, {
|
|
1120
1198
|
variant: "text",
|
|
1121
1199
|
onClick: n,
|
|
1122
|
-
size:
|
|
1123
|
-
color:
|
|
1200
|
+
size: V(s).size,
|
|
1201
|
+
color: o.value && V(s).variant == "text" ? V(s).color : void 0
|
|
1124
1202
|
}, {
|
|
1125
|
-
default:
|
|
1126
|
-
|
|
1203
|
+
default: P(() => [
|
|
1204
|
+
g(l.$slots, "default", {}, void 0, !0)
|
|
1127
1205
|
]),
|
|
1128
1206
|
_: 3
|
|
1129
1207
|
}, 8, ["size", "color"])
|
|
1130
1208
|
], 2));
|
|
1131
1209
|
}
|
|
1132
|
-
}),
|
|
1210
|
+
}), os = /* @__PURE__ */ v(ss, [["__scopeId", "data-v-36c12a50"]]), ns = /* @__PURE__ */ b({
|
|
1133
1211
|
__name: "t-tabs",
|
|
1134
1212
|
props: {
|
|
1135
1213
|
placement: { default: "top-start" },
|
|
@@ -1140,60 +1218,60 @@ const Bt = /* @__PURE__ */ _(St, [["render", It]]), Ct = /* @__PURE__ */ g({
|
|
|
1140
1218
|
size: { default: "standard" }
|
|
1141
1219
|
},
|
|
1142
1220
|
emits: ["update:modelValue"],
|
|
1143
|
-
setup(
|
|
1144
|
-
const
|
|
1145
|
-
let
|
|
1146
|
-
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(
|
|
1221
|
+
setup(e, { emit: t }) {
|
|
1222
|
+
const s = e, o = t, n = m("0px"), l = m(), u = w(() => {
|
|
1223
|
+
let i = s.color;
|
|
1224
|
+
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(i) && (i = `var(--t-color-status-${i})`), i;
|
|
1147
1225
|
}), a = () => {
|
|
1148
1226
|
setTimeout(() => {
|
|
1149
|
-
if (
|
|
1150
|
-
let
|
|
1151
|
-
if (
|
|
1152
|
-
let
|
|
1153
|
-
n.value =
|
|
1227
|
+
if (s.placement.startsWith("top-") || s.placement.startsWith("bottom-")) {
|
|
1228
|
+
let i = l.value.querySelector(".active");
|
|
1229
|
+
if (i) {
|
|
1230
|
+
let p = i.getBoundingClientRect().left - l.value.getBoundingClientRect().left + l.value.scrollLeft, _ = i.offsetWidth / 2;
|
|
1231
|
+
n.value = p + _ - s.border / 2 + "px";
|
|
1154
1232
|
}
|
|
1155
|
-
} else if (
|
|
1156
|
-
let
|
|
1157
|
-
if (
|
|
1158
|
-
let
|
|
1159
|
-
n.value =
|
|
1233
|
+
} else if (s.placement.startsWith("left-") || s.placement.startsWith("right-")) {
|
|
1234
|
+
let i = l.value.querySelector(".active");
|
|
1235
|
+
if (i) {
|
|
1236
|
+
let p = i.getBoundingClientRect().top - l.value.getBoundingClientRect().top + l.value.scrollTop, _ = i.offsetHeight / 2;
|
|
1237
|
+
n.value = p + _ - s.border / 2 + "px";
|
|
1160
1238
|
}
|
|
1161
1239
|
}
|
|
1162
1240
|
}, 50);
|
|
1163
1241
|
};
|
|
1164
|
-
return
|
|
1165
|
-
active:
|
|
1166
|
-
color:
|
|
1167
|
-
size:
|
|
1168
|
-
variant:
|
|
1169
|
-
setActive: (
|
|
1170
|
-
|
|
1242
|
+
return ie("tabsState", {
|
|
1243
|
+
active: w(() => s.modelValue),
|
|
1244
|
+
color: u.value,
|
|
1245
|
+
size: s.size,
|
|
1246
|
+
variant: s.variant,
|
|
1247
|
+
setActive: (i) => {
|
|
1248
|
+
o("update:modelValue", i), a();
|
|
1171
1249
|
}
|
|
1172
|
-
}),
|
|
1250
|
+
}), oe(() => {
|
|
1173
1251
|
a();
|
|
1174
|
-
}), (
|
|
1252
|
+
}), (i, p) => (c(), d("ul", {
|
|
1175
1253
|
ref_key: "container",
|
|
1176
|
-
ref:
|
|
1177
|
-
class:
|
|
1178
|
-
style:
|
|
1254
|
+
ref: l,
|
|
1255
|
+
class: T(["t-tabs", { [i.placement]: !0, [i.variant]: !0 }]),
|
|
1256
|
+
style: k({ "--color": u.value, "--transform": n.value, "--border": i.border + "px" })
|
|
1179
1257
|
}, [
|
|
1180
|
-
|
|
1258
|
+
g(i.$slots, "default", {}, void 0, !0)
|
|
1181
1259
|
], 6));
|
|
1182
1260
|
}
|
|
1183
|
-
}),
|
|
1261
|
+
}), rs = /* @__PURE__ */ v(ns, [["__scopeId", "data-v-65a2c74c"]]), as = /* @__PURE__ */ b({
|
|
1184
1262
|
__name: "t-loading-app",
|
|
1185
|
-
setup(
|
|
1186
|
-
return (
|
|
1187
|
-
default:
|
|
1188
|
-
|
|
1263
|
+
setup(e) {
|
|
1264
|
+
return (t, s) => (c(), C(_e, null, {
|
|
1265
|
+
default: P(() => [
|
|
1266
|
+
U(K, { type: "spinner" })
|
|
1189
1267
|
]),
|
|
1190
1268
|
_: 1
|
|
1191
1269
|
}));
|
|
1192
1270
|
}
|
|
1193
|
-
}),
|
|
1271
|
+
}), ls = /* @__PURE__ */ v(as, [["__scopeId", "data-v-1436aa9f"]]), cs = { key: 0 }, is = {
|
|
1194
1272
|
key: 0,
|
|
1195
1273
|
class: "t-checkbox-label"
|
|
1196
|
-
},
|
|
1274
|
+
}, us = /* @__PURE__ */ b({
|
|
1197
1275
|
__name: "t-checkbox",
|
|
1198
1276
|
props: {
|
|
1199
1277
|
label: { default: "" },
|
|
@@ -1205,48 +1283,48 @@ const Bt = /* @__PURE__ */ _(St, [["render", It]]), Ct = /* @__PURE__ */ g({
|
|
|
1205
1283
|
color: { default: "primary" }
|
|
1206
1284
|
},
|
|
1207
1285
|
emits: ["update:modelValue"],
|
|
1208
|
-
setup(
|
|
1209
|
-
const
|
|
1286
|
+
setup(e, { emit: t }) {
|
|
1287
|
+
const s = e, o = t, n = w(() => {
|
|
1210
1288
|
let a = {
|
|
1211
|
-
"--background":
|
|
1289
|
+
"--background": s.color,
|
|
1212
1290
|
"--color": "#ffffff"
|
|
1213
1291
|
};
|
|
1214
|
-
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(
|
|
1215
|
-
"--background": `var(--t-color-status-${
|
|
1216
|
-
"--color": `var(--t-color-status-${
|
|
1292
|
+
return ["warning", "info", "danger", "primary", "secondary", "success"].includes(s.color) && (a = {
|
|
1293
|
+
"--background": `var(--t-color-status-${s.color})`,
|
|
1294
|
+
"--color": `var(--t-color-status-${s.color}-text)`
|
|
1217
1295
|
}), a;
|
|
1218
|
-
}),
|
|
1219
|
-
if (
|
|
1220
|
-
let a =
|
|
1221
|
-
|
|
1222
|
-
} else
|
|
1296
|
+
}), l = w(() => s.multiple ? s.modelValue.includes(s.value) : s.value === void 0 ? s.modelValue : s.modelValue == s.value), u = () => {
|
|
1297
|
+
if (s.multiple) {
|
|
1298
|
+
let a = s.modelValue;
|
|
1299
|
+
s.modelValue.includes(s.value) ? a.splice(a.indexOf(s.value), 1) : a.push(s.value), o("update:modelValue", a);
|
|
1300
|
+
} else s.value === void 0 ? o("update:modelValue", !s.modelValue) : o("update:modelValue", s.value);
|
|
1223
1301
|
};
|
|
1224
|
-
return (a,
|
|
1225
|
-
class:
|
|
1226
|
-
style:
|
|
1227
|
-
onClick:
|
|
1302
|
+
return (a, i) => (c(), d("div", {
|
|
1303
|
+
class: T(["t-checkbox", { active: l.value }]),
|
|
1304
|
+
style: k(n.value),
|
|
1305
|
+
onClick: u
|
|
1228
1306
|
}, [
|
|
1229
|
-
|
|
1230
|
-
class:
|
|
1307
|
+
h("div", {
|
|
1308
|
+
class: T(`t-checkbox-${a.type}`)
|
|
1231
1309
|
}, [
|
|
1232
|
-
a.type == "radio" ? (c(),
|
|
1233
|
-
a.type == "check" ?
|
|
1234
|
-
|
|
1235
|
-
], !0) :
|
|
1310
|
+
a.type == "radio" ? (c(), d("div", cs)) : E("", !0),
|
|
1311
|
+
a.type == "check" ? g(a.$slots, "icon", { key: 1 }, () => [
|
|
1312
|
+
i[0] || (i[0] = h("i", { class: "ri-check-line" }, null, -1))
|
|
1313
|
+
], !0) : E("", !0)
|
|
1236
1314
|
], 2),
|
|
1237
|
-
a.label ? (c(),
|
|
1315
|
+
a.label ? (c(), d("span", is, R(s.label), 1)) : E("", !0)
|
|
1238
1316
|
], 6));
|
|
1239
1317
|
}
|
|
1240
|
-
}),
|
|
1318
|
+
}), ds = /* @__PURE__ */ v(us, [["__scopeId", "data-v-d558d0b0"]]), ps = /* @__PURE__ */ b({
|
|
1241
1319
|
__name: "t-keyboard",
|
|
1242
|
-
setup(
|
|
1243
|
-
const { height:
|
|
1244
|
-
return (
|
|
1320
|
+
setup(e) {
|
|
1321
|
+
const { height: t } = ve();
|
|
1322
|
+
return (s, o) => (c(), d("div", {
|
|
1245
1323
|
class: "t-keyboard",
|
|
1246
|
-
style:
|
|
1324
|
+
style: k({ "--height": V(t) + "px" })
|
|
1247
1325
|
}, null, 4));
|
|
1248
1326
|
}
|
|
1249
|
-
}),
|
|
1327
|
+
}), fs = /* @__PURE__ */ v(ps, [["__scopeId", "data-v-5d3fa1da"]]), ms = /* @__PURE__ */ b({
|
|
1250
1328
|
__name: "t-skeleton",
|
|
1251
1329
|
props: {
|
|
1252
1330
|
width: { default: "100%" },
|
|
@@ -1254,52 +1332,52 @@ const Bt = /* @__PURE__ */ _(St, [["render", It]]), Ct = /* @__PURE__ */ g({
|
|
|
1254
1332
|
radius: { default: "8px" },
|
|
1255
1333
|
color: { default: null }
|
|
1256
1334
|
},
|
|
1257
|
-
setup(
|
|
1258
|
-
const
|
|
1259
|
-
"--width":
|
|
1260
|
-
"--height":
|
|
1261
|
-
"--radius":
|
|
1335
|
+
setup(e) {
|
|
1336
|
+
const t = e, s = w(() => ({
|
|
1337
|
+
"--width": t.width,
|
|
1338
|
+
"--height": t.height,
|
|
1339
|
+
"--radius": t.radius
|
|
1262
1340
|
}));
|
|
1263
|
-
return (
|
|
1341
|
+
return (o, n) => (c(), d("div", {
|
|
1264
1342
|
class: "t-skeleton",
|
|
1265
|
-
style:
|
|
1343
|
+
style: k(s.value)
|
|
1266
1344
|
}, null, 4));
|
|
1267
1345
|
}
|
|
1268
|
-
}),
|
|
1346
|
+
}), vs = /* @__PURE__ */ v(ms, [["__scopeId", "data-v-877bbdb5"]]), _s = /* @__PURE__ */ b({
|
|
1269
1347
|
__name: "t-ripple",
|
|
1270
1348
|
props: {
|
|
1271
1349
|
color: { default: "primary" }
|
|
1272
1350
|
},
|
|
1273
|
-
setup(
|
|
1274
|
-
const
|
|
1275
|
-
let
|
|
1276
|
-
return
|
|
1277
|
-
"--color": "var(--t-color-status-" +
|
|
1278
|
-
} :
|
|
1279
|
-
"--color":
|
|
1280
|
-
} :
|
|
1351
|
+
setup(e) {
|
|
1352
|
+
const t = e, s = w(() => {
|
|
1353
|
+
let o = {};
|
|
1354
|
+
return t.color ? ["warning", "info", "danger", "primary", "secondary", "success"].includes(t.color) ? o = {
|
|
1355
|
+
"--color": "var(--t-color-status-" + t.color + ")"
|
|
1356
|
+
} : o = {
|
|
1357
|
+
"--color": t.color
|
|
1358
|
+
} : o = {
|
|
1281
1359
|
"--color": "var(--t-color-surface)"
|
|
1282
|
-
},
|
|
1360
|
+
}, o;
|
|
1283
1361
|
});
|
|
1284
|
-
return (
|
|
1362
|
+
return (o, n) => (c(), d("div", {
|
|
1285
1363
|
class: "t-ripple",
|
|
1286
|
-
style:
|
|
1364
|
+
style: k(s.value)
|
|
1287
1365
|
}, null, 4));
|
|
1288
1366
|
}
|
|
1289
|
-
}),
|
|
1290
|
-
install: (
|
|
1291
|
-
|
|
1367
|
+
}), ys = /* @__PURE__ */ v(_s, [["__scopeId", "data-v-42cb3d71"]]), Ts = () => ({
|
|
1368
|
+
install: (e) => {
|
|
1369
|
+
Te(), e.component("t-app", Ee), e.component("t-screen", ye), e.component("t-swipe-screen", vt), e.component("t-cable", nt), e.component("t-toolbar", yt), e.component("t-content", _e), e.component("t-card", rt), e.component("t-refresher", ut), e.component("t-button", J), e.component("t-back-button", bt), e.component("t-present", L), e.component("t-text", te), e.component("t-sheet", wt), e.component("t-gesture-indicator", ge), e.component("t-input", It), e.component("t-textarea", Ct), e.component("t-rich-text", At), e.component("t-grid", Xt), e.component("t-grid-item", Lt), e.component("t-divider", Ht), e.component("t-toggle-password", Ut), e.component("t-loading-icon", K), e.component("t-alert", pe), e.component("t-avatar", Ft), e.component("t-collapse", Yt), e.component("t-toast", me), e.component("t-switch", ts), e.component("t-tab", os), e.component("t-tabs", rs), e.component("t-loading-app", ls), e.component("t-checkbox", ds), e.component("t-keyboard", fs), e.component("t-skeleton", vs), e.component("t-ripple", ys);
|
|
1292
1370
|
}
|
|
1293
1371
|
});
|
|
1294
1372
|
export {
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1373
|
+
xe as blurCurrentActive,
|
|
1374
|
+
$s as createAction,
|
|
1375
|
+
ks as createAlert,
|
|
1376
|
+
ws as createLoading,
|
|
1377
|
+
xs as createToast,
|
|
1378
|
+
Ts as createToife,
|
|
1379
|
+
we as isFormElement,
|
|
1380
|
+
He as presentController,
|
|
1381
|
+
x as screenController,
|
|
1382
|
+
ve as useKeyboard
|
|
1305
1383
|
};
|