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