vuesp-components 2.2.3 → 2.2.5

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.
@@ -0,0 +1,664 @@
1
+ import { openBlock as o, createElementBlock as c, createStaticVNode as ae, createElementVNode as r, defineComponent as E, computed as B, createBlock as O, resolveDynamicComponent as q, mergeProps as M, withCtx as $, normalizeClass as w, renderSlot as b, createCommentVNode as k, markRaw as H, shallowRef as R, Teleport as K, createVNode as S, Transition as A, unref as i, withModifiers as V, normalizeStyle as T, ref as G, withDirectives as ne, Fragment as J, renderList as Q, createTextVNode as N, toDisplayString as _, withKeys as se, createPropsRestProxy as re, normalizeProps as ie, guardReactiveProps as ce } from "vue";
2
+ import { u as U, a as de, b as X, c as Y } from "./useDialog-ALG4kFE7.js";
3
+ const W = (e, t) => {
4
+ const n = e.__vccOpts || e;
5
+ for (const [h, u] of t)
6
+ n[h] = u;
7
+ return n;
8
+ }, ue = {}, fe = {
9
+ viewBox: "0 0 179 40",
10
+ fill: "currentColor"
11
+ };
12
+ function me(e, t) {
13
+ return o(), c("svg", fe, [...t[0] || (t[0] = [
14
+ ae('<g transform="matrix(0.13287749,0,0,0.13643171,26.823508,13.407673)"><path d="m -19.25933,-16.057909 c 0,39.1906 -14.287,86.055995 -38.669,116.999999 -7.898,10.024 -30.4718,32.819 -43.7731,17.695 -9.4823,-10.781 -3.53183,-36.917714 -0.86893,-48.907714 9.1618,-41.251693 19.72123,-78.8733849 30.31103,-119.787285 -27.50968,14.537655 -68.26323,-24.154322 -70.36602,-2.214449 -12.32038,69.23655 -28.82323,204.245118 16.36602,215.925448 81.802,10.63 120.333,-82.698004 129.4249996,-148.710999 2.182,-15.84009991 4.123,-31.9832 2.401,-48 -2.342,-21.78506 -24.7959996,-32.68227 -43.7859996,-21.58643 -11.424,6.67523 -12.148,29.93713 -1.935,38.01393 5.462,4.3199 14.927,3.091 20.895,0.5725 z"></path><path d="m 104.76548,-63.374174 0.008,91.15236 -26.35225,25.003926 26.35676,25.415735 4.8e-4,91.161403 4.03033,0.0237 c 0,0 0.0729,-90.913243 -0.0476,-91.163063 l 26.24012,-24.776315 -26.23835,-25.66073 0.007,-91.147024 z"></path><path d="m 803.85444,82.816565 c -5.5092,-1.69169 -15.7197,-2.12913 -19.9329,1.03114 -5.56,4.548 -0.63,22.670005 -0.76,28.973005 0.3943,19.76599 20.7146,30.35978 36.02,33 0,0 45.06,4.77 68,-5.439 35.89996,-15.975 40.75996,-63.180005 13.91,-89.457 -15.2385,-18.333755 -72.7584,-32.66908 -78.91,-50.10399958 -6.54,-7.52040002 -2.52,-22.38120042 5.1,-27.89120042 10.47,-7.5605 25.91,-7.3647 37.9,-5.017 13.11,2.5659 14.15,13.6285 18,24.9082004 1.48,4.3522 2.88,12.3564 8.1,13.6674 2.25,0.5623 4.67,-0.1094 6.9,-0.3827 16.42996,-2.011 11.28456,-11.418391 12.09456,-24.2037914 0.38,-6.0219 2.2254,-16.238609 -1.1246,-21.752209 -5.98996,-9.87979 -17.48276,-9.960049 -30.96996,-15.3287 -11.9944,-2.919504 -32.57,-5.50288 -50,-1.25772 -13.92,3.39017 -28.5,10.49772 -37.24,22.25772 -16.31,21.9622 -9.6,57.1861 10.26,74.6998 22.17,19.5582 58.4,21.7732 76.41,46.304195 16.9,23.013005 -18.71,37.732005 -37.1,36.158005 -39.9169,-0.34531 -23.6297,-30.723925 -36.6571,-40.166145 z"></path><path d="m 321.18154,-32.17929 21,9 -46,120.999995 c -13.02939,-49.349215 -25.65589,-93.5184936 -37,-121.999995 5.741,-1.2008 17.946,-4.1139 20.397,-10.1049 2.328,-5.6934 -1.142,-13.0456 -1.397,-18.8951 -9.12189,0.745226 -79.43846,-2.275099 -82.411,2.3179 -1.02172,5.2378 -3.84926,12.95938 -1.985,17.2878 4.036,8.5605 18.82154,3.517306 23.75154,13.866906 25.90475,54.255645 38.51776,106.713979 60.87446,156.527394 37.33703,54.02331 63.06896,-92.52485 72.275,-119 4.089,-11.8192996 7.212,-30.0265 15.194,-39.7724 15.1599,-17.433642 28.97616,-5.381825 21.868,-28.07945 -5.23694,-5.944366 -63.1086,-2.739072 -64.389,-1.54476 -3.452,4.31661 -7.5289,7.804293 -2.178,19.39661 z"></path><path d="m 401.18154,-53.17929 c -0.998,4.83681 -4.908,16.1206 -1.357,20.3511 4.914,5.8555 20.341,3.7676 21.463,12.689 3.596,28.5694004 -0.4,58.2962 0.855,86.9599 0.882,20.149995 3.491,41.865 17.134,57.961 36.351,42.885 114.137,25.661 128.322,-27.961005 9.142,-34.561995 3.01191,-80.803507 3.08491,-116.292007 0.033,-15.7886 15.53509,-3.553988 22.46909,-13.356888 3.337,-4.7169 -1.212,-15.187 -1.971,-20.3511 -20.45735,-0.261837 -40.85188,-0.262234 -61.258,1.02779 l -3.742,11.97221 c 0.84877,13.898543 11.37685,10.038234 23.90801,11.758642 0.32053,9.189207 0.091,48.923358 0.092,71.241358 10e-4,19.4 0.471,40.338995 -8.89,58 -15.56,29.358 -61.659,29.409 -74.878,-2.000005 -10.636,-25.273 -6.147,-56.234995 -6.233,-82.999995 -0.035,-10.9870996 -2.501,-25.3419996 0.319,-35.9568 2.549,-9.5978 16.626,-6.4297 22.064,-12.6921 3.287,-3.7858 -0.52,-15.71299 -1.382,-20.3511 z"></path><path d="m 760.05964,143.05268 c -5.1123,-31.58627 4.9497,-52.437285 -1.4781,-59.628975 -3.17,-3.163 -17.48,-3.877 -20.39,-0.285 -7.636,9.412 -6.012,27.571005 -14.737,36.079005 -3.136,3.058 -10.272,1.461 -14.273,1.689 -13.102,0.746 -25.895,-0.086 -39,-0.086 l -1,-68 c 7.223,0.913 21.685,-1.996 27.722,1.269 6.665,3.604 3.577,17.035995 10.556,20.532995 5.15472,-0.0642 13.05488,0.47604 17.494,-1.405 5.21328,-7.758815 3.74312,-60.612259 -0.015,-62.640795 -5.5141,-0.237113 -13.29293,-2.8563906 -17.543,-1.1527996 -6.595,2.8734996 -5.002,15.2292996 -10.608,19.7931996 -5.233,4.2609 -21.417,2.0768 -27.606,0.6034 l 0.018,-19.9999996 0.982,-42.0000004 h 36 c 4.195,0 11.017,-1.271 14.725,1.0278 9.479,5.8759 5.235,25.2669004 13.705,30.94060042 4.66,3.12049998 14.21,-2.03520002 19.57,-1.96840002 -1.7258,-10.0332024 5.1749,-44.7657364 -0.6,-49.9722104 -8.573,-0.17431 -123.95249,0.09746 -142.26,0.5756 -2.813,3.26479 -4.226,15.59871 -1.533,19.00621 4.834,6.1168 16.163,4.3646 20.481,9.9544 4.51586,28.5714044 7.89004,96.377815 0.594,132.328 -2.185,7.787 -16.181,5.969 -20.654,11.832 -1.59611,5.22999 -0.7409,13.33851 1.536,18.048 5.16025,7.51372 110.02916,3.17366 148.3141,3.45997 z"></path><path d="m 964.1815,-23.17929 c 0,43.4127 3.83,88.767 -0.06,131.985 -0.8,8.923 -14.88,7.544 -20.62,12.09 -4.2,3.326 -1.95,14.442 -0.17,18.777 15.7137,4.67091 86.3037,9.27518 89.39,-4.852 0.57,-3.057 2.36,-9.582 0.42,-12.297 -5.77,-8.041 -28.93,-2.391 -30.81,-13.747 -0.063,-55.41713 -0.3488,-55.25935 -0.15,-140.956 16.19,0 34.24,-2.9842 46.98,9.0934 18.26,17.2977004 11.94,53.4098 -8.98,65.6236 -7.67,4.477 -18.44,3.283 -27,3.283 v 23 c 23.19,0 50.85,-0.216 69,-17.093 28.42,-26.4403 19.73,-83.9314 -16,-99.7334 -4.6952,-8.320027 -96.8662,-17.196078 -120.68,-4.43208 -2.7,1.3721 -3.6701,5.98455 -3.17,8.34798 -3.3313,17.201533 8.54,18.6194 21.85,20.9105 z"></path></g>', 1)
15
+ ])]);
16
+ }
17
+ const lt = /* @__PURE__ */ W(ue, [["render", me]]), he = {}, be = {
18
+ width: "40",
19
+ height: "40",
20
+ viewBox: "0 0 40 40",
21
+ fill: "currentColor"
22
+ };
23
+ function ve(e, t) {
24
+ return o(), c("svg", be, [...t[0] || (t[0] = [
25
+ r("g", { transform: "matrix(0.13287749,0,0,0.13643171,26.823508,13.407673)" }, [
26
+ r("path", { d: "m -19.25933,-16.057909 c 0,39.1906 -14.287,86.055995 -38.669,116.999999 -7.898,10.024 -30.4718,32.819 -43.7731,17.695 -9.4823,-10.781 -3.53183,-36.917714 -0.86893,-48.907714 9.1618,-41.251693 19.72123,-78.8733849 30.31103,-119.787285 -27.50968,14.537655 -68.26323,-24.154322 -70.36602,-2.214449 -12.32038,69.23655 -28.82323,204.245118 16.36602,215.925448 81.802,10.63 120.333,-82.698004 129.4249996,-148.710999 2.182,-15.84009991 4.123,-31.9832 2.401,-48 -2.342,-21.78506 -24.7959996,-32.68227 -43.7859996,-21.58643 -11.424,6.67523 -12.148,29.93713 -1.935,38.01393 5.462,4.3199 14.927,3.091 20.895,0.5725 z" })
27
+ ], -1)
28
+ ])]);
29
+ }
30
+ const ot = /* @__PURE__ */ W(he, [["render", ve]]), ge = {}, xe = {
31
+ class: "animate-spin h-6 w-6",
32
+ fill: "none",
33
+ viewBox: "0 0 24 24"
34
+ };
35
+ function pe(e, t) {
36
+ return o(), c("svg", xe, [...t[0] || (t[0] = [
37
+ r("circle", {
38
+ class: "opacity-25",
39
+ cx: "12",
40
+ cy: "12",
41
+ r: "10",
42
+ stroke: "currentColor",
43
+ "stroke-width": "2"
44
+ }, null, -1),
45
+ r("path", {
46
+ class: "opacity-75",
47
+ fill: "currentColor",
48
+ d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
49
+ }, null, -1)
50
+ ])]);
51
+ }
52
+ const ye = /* @__PURE__ */ W(ge, [["render", pe]]), we = "relative flex justify-center items-center transition not-disabled:cursor-pointer not-disabled:hover:opacity-90 disabled:opacity-40 rounded-md", Z = /* @__PURE__ */ E({
53
+ __name: "VButton",
54
+ props: {
55
+ outline: { type: Boolean, default: !1 },
56
+ color: { default: "transparent" },
57
+ size: { default: "md" },
58
+ type: { default: "button" },
59
+ href: { default: "" },
60
+ to: { default: "" },
61
+ loading: { type: Boolean, default: !1 }
62
+ },
63
+ emits: ["click"],
64
+ setup(e, { emit: t }) {
65
+ const n = t, h = (z) => n("click", z), u = e.outline ? "border border-green-500/30 text-green-600 dark:text-green-400" : "border border-green-500/20 bg-green-500/10 text-green-600 dark:text-green-400", l = e.outline ? "border border-red-500/30 text-red-600 dark:text-red-400" : "border border-red-500/20 bg-red-500/10 text-red-600 dark:text-red-400", s = e.outline ? "border border-gray-300/70 text-gray-700 dark:border-white/15 dark:text-white/70" : "border border-gray-200/70 bg-white/50 text-gray-700 dark:border-white/10 dark:bg-white/[0.05] dark:text-white/70", x = e.outline ? "border border-[var(--accent-blue)] text-[var(--accent-blue)]" : "bg-[var(--accent-blue)] text-white shadow-[0_8px_24px_-12px_rgba(37,99,235,0.9)] hover:brightness-110", v = e.outline ? "border border-[var(--accent-indigo)] text-[var(--accent-indigo)]" : "bg-[var(--accent-indigo)] text-white shadow-[0_8px_24px_-12px_rgba(99,102,241,0.9)] hover:brightness-110", f = e.outline ? "border border-[var(--accent-violet)] text-[var(--accent-violet)]" : "bg-[var(--accent-violet)] text-white shadow-[0_8px_24px_-12px_rgba(139,92,246,0.9)] hover:brightness-110", p = e.outline ? "border border-[var(--accent-emerald)] text-[var(--accent-emerald)]" : "bg-[var(--accent-emerald)] text-white shadow-[0_8px_24px_-12px_rgba(16,185,129,0.9)] hover:brightness-110", L = e.outline ? "border border-[var(--accent-amber)] text-[var(--accent-amber)]" : "bg-[var(--accent-amber)] text-[#231400] shadow-[0_8px_24px_-12px_rgba(245,158,11,0.9)] hover:brightness-110", C = e.outline ? "border border-[var(--accent-rose)] text-[var(--accent-rose)]" : "bg-[var(--accent-rose)] text-white shadow-[0_8px_24px_-12px_rgba(244,63,94,0.9)] hover:brightness-110", d = e.outline ? "border border-[var(--accent-slate)] text-[var(--accent-slate)]" : "bg-[var(--accent-slate)] text-white shadow-[0_8px_24px_-12px_rgba(71,85,105,0.9)] hover:brightness-110", m = (e.outline, ""), y = { green: u, red: l, gray: s, blue: x, indigo: v, violet: f, emerald: p, amber: L, rose: C, slate: d, transparent: m }, a = {
66
+ button: "px-3",
67
+ icon: "rounded-md border border-gray-200/70 dark:border-white/10"
68
+ }, g = {
69
+ button: { sm: "h-8", md: "h-10", lg: "h-12", xl: "h-14" },
70
+ icon: { sm: "size-8", md: "size-10", lg: "size-12", xl: "size-14" }
71
+ }, D = B(() => [we, oe(e.color), le(e.type), P(e.type, e.size)]), I = B(() => e.href || e.to ? "router-link" : "button"), P = (z, j) => {
72
+ var F;
73
+ return ((F = g[z]) == null ? void 0 : F[j]) || "";
74
+ }, le = (z) => (a == null ? void 0 : a[z]) || "", oe = (z) => y == null ? void 0 : y[z];
75
+ return (z, j) => (o(), O(q(I.value), M(z.$attrs, {
76
+ href: e.href,
77
+ to: e.to,
78
+ class: D.value,
79
+ onClick: h
80
+ }), {
81
+ default: $(() => [
82
+ r("span", {
83
+ class: w(e.loading ? "opacity-0" : "")
84
+ }, [
85
+ b(z.$slots, "default")
86
+ ], 2),
87
+ e.loading ? (o(), O(ye, {
88
+ key: 0,
89
+ class: "absolute left-1/2 -translate-x-1/2"
90
+ })) : k("", !0)
91
+ ]),
92
+ _: 3
93
+ }, 16, ["href", "to", "class"]));
94
+ }
95
+ }), ke = {
96
+ viewBox: "0 0 24 24",
97
+ width: "1.2em",
98
+ height: "1.2em"
99
+ };
100
+ function $e(e, t) {
101
+ return o(), c("svg", ke, [...t[0] || (t[0] = [
102
+ r("path", {
103
+ fill: "currentColor",
104
+ d: "m12 10.587l4.95-4.95l1.414 1.414l-4.95 4.95l4.95 4.95l-1.415 1.414l-4.95-4.95l-4.949 4.95l-1.414-1.415l4.95-4.95l-4.95-4.95L7.05 5.638z"
105
+ }, null, -1)
106
+ ])]);
107
+ }
108
+ const ee = H({ name: "ri-close-line", render: $e }), Ce = { class: "flex items-center absolute right-3 top-5 z-10" }, te = /* @__PURE__ */ E({
109
+ __name: "VPopup",
110
+ props: {
111
+ hiddenCloser: { type: Boolean },
112
+ size: { default: "auto" }
113
+ },
114
+ emits: ["close", "click", "open"],
115
+ setup(e, { emit: t }) {
116
+ const n = t, { show: h, overlay: u, onClose: l, onOpen: s } = U(n), x = R(null), v = R(null), { opacity: f, transform: p } = de(x, v, l), d = { click: (a) => {
117
+ n("click", a);
118
+ }, open: s, set: (a) => {
119
+ a ? s() : l(new Event("hide"));
120
+ } }, m = B(() => ({
121
+ auto: "max-h-[calc(100dvh-50px)]",
122
+ full: "h-[calc(100dvh-24px)] md:h-[calc(100dvh-100px)]",
123
+ screen: "h-dvh"
124
+ })), y = B(() => ({
125
+ auto: "max-h-[calc(100dvh-50px-16px)]",
126
+ full: "h-[calc(100dvh-24px-16px)] md:h-[calc(100dvh-100px-16px)]",
127
+ screen: "h-[calc(100dvh-16px)]"
128
+ }));
129
+ return (a, g) => {
130
+ const D = ee, I = Z;
131
+ return o(), O(K, { to: "body" }, [
132
+ S(A, {
133
+ "enter-active-class": "duration-300 ease-out",
134
+ "enter-from-class": "transform opacity-0 translate-y-full xl:-translate-y-2",
135
+ "enter-to-class": "opacity-100 translate-y-0",
136
+ "leave-active-class": "duration-200 ease-in",
137
+ "leave-from-class": "opacity-100 translate-y-0",
138
+ "leave-to-class": "transform opacity-0 translate-y-full xl:-translate-y-2"
139
+ }, {
140
+ default: $(() => [
141
+ i(h) ? (o(), c("div", {
142
+ key: 0,
143
+ ref_key: "container",
144
+ ref: v,
145
+ class: "fixed bottom-0 left-0 w-full z-15"
146
+ }, [
147
+ i(u) ? (o(), c("div", {
148
+ key: 0,
149
+ class: "fixed h-full w-full top-0 left-0 bg-black/40 bg-blur xl:hidden animate-opacity overscroll-contain",
150
+ style: T({ opacity: i(f) }),
151
+ onClick: g[0] || (g[0] = //@ts-ignore
152
+ (...P) => i(l) && i(l)(...P)),
153
+ onWheel: g[1] || (g[1] = V(() => {
154
+ }, ["prevent"])),
155
+ onTouchmove: g[2] || (g[2] = V(() => {
156
+ }, ["prevent"]))
157
+ }, null, 36)) : k("", !0),
158
+ r("div", {
159
+ class: w(["glass-popover relative w-full rounded-t-lg border-t shadow-nav", m.value[e.size]]),
160
+ style: T({ transform: i(p) })
161
+ }, [
162
+ r("div", {
163
+ ref_key: "target",
164
+ ref: x,
165
+ class: "flex justify-center py-3 md:pb-6",
166
+ onWheel: g[3] || (g[3] = V(() => {
167
+ }, ["prevent"])),
168
+ onTouchmove: g[4] || (g[4] = V(() => {
169
+ }, ["prevent"]))
170
+ }, [...g[5] || (g[5] = [
171
+ r("div", { class: "self-end h-1 w-12 bg-gray-400" }, null, -1)
172
+ ])], 544),
173
+ r("div", Ce, [
174
+ b(a.$slots, "button", { close: i(l) }),
175
+ S(I, {
176
+ class: "size-5 md:size-6",
177
+ color: "transparent",
178
+ size: "none",
179
+ icon: "",
180
+ "aria-label": "Close",
181
+ onClick: i(l)
182
+ }, {
183
+ default: $(() => [
184
+ S(D, { class: "size-5" })
185
+ ]),
186
+ _: 1
187
+ }, 8, ["onClick"])
188
+ ]),
189
+ r("div", {
190
+ class: w(["overflow-y-auto max-h-[calc(100dvh-24px-16px)] overscroll-contain scrollbar", y.value[e.size]])
191
+ }, [
192
+ b(a.$slots, "default", {
193
+ close: i(l),
194
+ on: d
195
+ })
196
+ ], 2)
197
+ ], 6)
198
+ ], 512)) : k("", !0)
199
+ ]),
200
+ _: 3
201
+ })
202
+ ]);
203
+ };
204
+ }
205
+ }), ze = {
206
+ mounted(e, t) {
207
+ e.clickOutsideEvent = function(n) {
208
+ e === n.target || e.contains(n.target) || t.value(n, e);
209
+ }, document.addEventListener("click", e.clickOutsideEvent);
210
+ },
211
+ unmounted(e) {
212
+ document.removeEventListener("click", e.clickOutsideEvent), delete e.clickOutsideEvent;
213
+ }
214
+ }, Be = { class: "relative" }, Ve = { class: "flex items-center cursor-pointer" }, Se = /* @__PURE__ */ E({
215
+ __name: "VDropdown",
216
+ props: {
217
+ title: { default: "" },
218
+ top: { default: "calc(100% + 8px)" },
219
+ left: { default: "" },
220
+ right: { default: "0" },
221
+ bottom: { default: "" },
222
+ height: { default: "200px" },
223
+ hideOnClick: { type: Boolean, default: !0 },
224
+ disabled: { type: Boolean, default: !1 },
225
+ isPopup: { type: Boolean }
226
+ },
227
+ emits: ["click", "show", "close"],
228
+ setup(e, { emit: t }) {
229
+ const n = t, u = X(Y).greaterOrEqual("lg"), l = G(!1), s = B(() => ({ top: e.top, left: e.left, right: e.right, bottom: e.bottom, "max-height": e.height })), x = (m) => {
230
+ u.value && l.value && p(m);
231
+ }, v = (m) => {
232
+ n("click", l.value), !e.disabled && (l.value ? e.hideOnClick && p(m) : f(m));
233
+ }, f = (m) => {
234
+ l.value = !0, n("show", m);
235
+ }, p = (m) => {
236
+ l.value = !1, n("close", m);
237
+ }, L = (m) => {
238
+ m ? f(new Event("show")) : p(new Event("hide"));
239
+ }, C = () => {
240
+ p(new Event("hide"));
241
+ }, d = { click: v, open: f, set: L };
242
+ return (m, y) => ne((o(), c("div", Be, [
243
+ r("div", Ve, [
244
+ b(m.$slots, "activator", {
245
+ on: d,
246
+ isShow: l.value
247
+ })
248
+ ]),
249
+ i(u) ? (o(), O(A, {
250
+ key: 0,
251
+ "enter-active-class": "duration-300 ease-out",
252
+ "enter-from-class": "transform opacity-0 -translate-y-2",
253
+ "enter-to-class": "opacity-100 translate-y-0",
254
+ "leave-active-class": "duration-200 ease-in",
255
+ "leave-from-class": "opacity-100 translate-y-0",
256
+ "leave-to-class": "transform opacity-0 -translate-y-2"
257
+ }, {
258
+ default: $(() => [
259
+ l.value ? (o(), c("div", {
260
+ key: 0,
261
+ class: "z-30 min-w-full absolute",
262
+ style: T(s.value)
263
+ }, [
264
+ b(m.$slots, "default", {
265
+ on: d,
266
+ show: f,
267
+ hide: p,
268
+ isShow: l.value
269
+ })
270
+ ], 4)) : k("", !0)
271
+ ]),
272
+ _: 3
273
+ })) : k("", !0),
274
+ !i(u) && l.value ? (o(), O(te, {
275
+ key: 1,
276
+ title: e.title,
277
+ onClose: C
278
+ }, {
279
+ default: $(({ on: a }) => [
280
+ b(m.$slots, "default", {
281
+ on: a,
282
+ show: f,
283
+ hide: p,
284
+ isShow: l.value
285
+ })
286
+ ]),
287
+ _: 3
288
+ }, 8, ["title"])) : k("", !0)
289
+ ])), [
290
+ [i(ze), x]
291
+ ]);
292
+ }
293
+ }), Oe = { class: "glass-popover rounded-md" }, _e = ["onClick"], Ee = /* @__PURE__ */ E({
294
+ __name: "VList",
295
+ props: {
296
+ items: {}
297
+ },
298
+ emits: ["click"],
299
+ setup(e, { emit: t }) {
300
+ const n = t, h = (u, l) => n("click", u, l);
301
+ return (u, l) => (o(), c("ul", Oe, [
302
+ (o(!0), c(J, null, Q(e.items, (s) => (o(), c("li", {
303
+ key: s.name,
304
+ class: "flex min-h-[40px] w-full cursor-pointer items-center whitespace-nowrap border-b border-gray-100 px-4 last:border-b-0 hover:bg-primary/10 dark:border-white/5 dark:hover:bg-white/[0.06]",
305
+ onClick: (x) => h(s, x)
306
+ }, [
307
+ b(u.$slots, "default", { item: s }, () => [
308
+ N(_(s.name), 1)
309
+ ])
310
+ ], 8, _e))), 128))
311
+ ]));
312
+ }
313
+ }), Le = { class: "relative flex items-end gap-0.5 w-10" }, Te = ["title"], De = { class: "absolute -top-1 -left-1 text-xs text-gray-600 dark:text-gray-300" }, at = /* @__PURE__ */ E({
314
+ __name: "VWifiIcon",
315
+ props: {
316
+ rssi: { default: 0 },
317
+ channel: { default: 0 }
318
+ },
319
+ setup(e) {
320
+ const t = 2 * (e.rssi + 100), n = (h) => h < t;
321
+ return (h, u) => (o(), c("div", Le, [
322
+ (o(), c(J, null, Q([10, 15, 25, 40, 70], (l, s) => r("div", {
323
+ key: l,
324
+ class: w(["w-1 h-5 rounded-lg", [n(l) ? "bg-gray-900 dark:bg-gray-100" : "bg-gray-300 dark:bg-gray-700"]]),
325
+ style: T(`height: ${(s + 1) * 5}px`),
326
+ title: `rssi: ${e.rssi} channel: ${e.channel}`
327
+ }, null, 14, Te)), 64)),
328
+ r("div", De, _(e.channel), 1)
329
+ ]));
330
+ }
331
+ }), Ie = {
332
+ viewBox: "0 0 24 24",
333
+ width: "1.2em",
334
+ height: "1.2em"
335
+ };
336
+ function Pe(e, t) {
337
+ return o(), c("svg", Ie, [...t[0] || (t[0] = [
338
+ r("path", {
339
+ fill: "currentColor",
340
+ d: "m12 10.828l-4.95 4.95l-1.414-1.414L12 8l6.364 6.364l-1.414 1.414z"
341
+ }, null, -1)
342
+ ])]);
343
+ }
344
+ const Me = H({ name: "ri-arrow-up-s-line", render: Pe }), Ae = { class: "w-full relative" }, Ne = ["disabled"], We = {
345
+ key: 0,
346
+ class: "text-red-400 h-[24px] px-2 text-xs"
347
+ }, je = "after:absolute after:h-1 after:w-full after:left-0 after:translate-y-[6px] after:-z-10 after:bg-white dark:after:bg-[#0b1538] after:transition-all", Fe = /* @__PURE__ */ E({
348
+ __name: "VTextField",
349
+ props: {
350
+ modelValue: { default: null },
351
+ label: { default: "" },
352
+ component: { default: "input" },
353
+ type: { default: "text" },
354
+ message: { default: "" },
355
+ readonly: { type: Boolean },
356
+ disabled: { type: [Boolean, Number], default: !1 },
357
+ active: { type: Boolean, default: !1 },
358
+ hideMessage: { type: Boolean, default: !1 }
359
+ },
360
+ emits: ["update:modelValue", "click", "on-icon", "enter", "blur", "focus"],
361
+ setup(e, { emit: t }) {
362
+ const n = t, h = {
363
+ input: "w-full h-full px-4 outline-none overflow-ellipsis flex-auto overflow-hidden w-[calc(100% - 20px)] bg-transparent",
364
+ textarea: "h-full w-full px-4 py-2 outline-none flex-auto bg-transparent"
365
+ }, u = G(!1), l = B(() => [
366
+ e.component === "input" ? "h-[40px]" : "min-h-[40px]",
367
+ e.message ? "!border-red-400/70 ring-1 ring-red-400/25 hover:!border-red-400" : "",
368
+ e.disabled ? "border-gray-300 opacity-40 dark:border-gray-700" : "border-gray-300/80 hover:border-gray-400/80 dark:border-white/10 dark:hover:border-white/20"
369
+ ]), s = B(() => h[e.component]), x = (a) => a || a === 0, v = B(() => [je, u.value || x(e.modelValue) || e.active ? "top-0 left-3 text-xs" : "top-1/2"]), f = B(() => e.component === "input"), p = (a) => {
370
+ u.value = !1, n("blur", a);
371
+ }, L = (a) => {
372
+ u.value = !0, n("focus", a);
373
+ }, C = ({ target: a }) => n("update:modelValue", a.value), d = (a) => n("enter", a), m = (a) => n("click", a), y = (a) => {
374
+ e.disabled || n("on-icon", a);
375
+ };
376
+ return (a, g) => (o(), c("div", Ae, [
377
+ r("label", {
378
+ class: w(["glass-inset relative flex w-full items-center rounded-md transition focus-within:border-primary/60 focus-within:ring-1 focus-within:ring-primary/20", l.value])
379
+ }, [
380
+ r("span", {
381
+ class: w(["absolute left-3.5 -translate-y-1/2 rounded bg-white/80 px-1 text-gray-500 transition-all dark:bg-[#0b1538]/80 dark:text-gray-400", v.value])
382
+ }, _(e.label), 3),
383
+ (o(), O(q(e.component), M(a.$attrs, {
384
+ value: e.modelValue,
385
+ disabled: !!e.disabled,
386
+ type: e.type,
387
+ readonly: e.readonly,
388
+ rows: f.value ? null : "2",
389
+ wrap: f.value ? null : "soft",
390
+ class: s.value,
391
+ onFocus: L,
392
+ onBlur: p,
393
+ onInput: C,
394
+ onClick: m,
395
+ onKeypress: se(d, ["enter"])
396
+ }), null, 16, ["value", "disabled", "type", "readonly", "rows", "wrap", "class"])),
397
+ a.$slots.icon ? (o(), c("button", {
398
+ key: 0,
399
+ disabled: !!e.disabled,
400
+ class: w([{ "cursor-pointer": !e.disabled }, "flex h-full flex-[0_0_50px] items-center justify-center border-l border-gray-200/70 text-gray-400 dark:border-white/10"]),
401
+ onClick: y
402
+ }, [
403
+ b(a.$slots, "icon")
404
+ ], 10, Ne)) : k("", !0)
405
+ ], 2),
406
+ e.hideMessage ? k("", !0) : (o(), c("div", We, [
407
+ b(a.$slots, "message", {}, () => [
408
+ N(_(e.message), 1)
409
+ ])
410
+ ]))
411
+ ]));
412
+ }
413
+ }), Re = { class: "glass-popover min-w-50 rounded-md pb-6 transition-all duration-300 lg:pb-0" }, qe = {
414
+ key: 0,
415
+ class: "lg:hidden text-title-md font-bold mb-4 uppercase px-4 sticky top-0"
416
+ }, He = { class: "h-full h-hull lg:max-h-44 lg:overflow-auto scrollbar lg:overscroll-contain" }, nt = /* @__PURE__ */ E({
417
+ inheritAttrs: !1,
418
+ __name: "VSelect",
419
+ props: {
420
+ modelValue: {},
421
+ label: {},
422
+ disabled: { type: Boolean },
423
+ items: {},
424
+ title: {},
425
+ top: {},
426
+ left: {},
427
+ right: {},
428
+ bottom: {},
429
+ height: {},
430
+ hideOnClick: { type: Boolean },
431
+ isPopup: { type: Boolean }
432
+ },
433
+ emits: ["change"],
434
+ setup(e, { emit: t }) {
435
+ const n = re(e, ["modelValue", "label", "items", "disabled"]), h = t;
436
+ function u(l, s) {
437
+ h("change", l), s == null || s.set(!1);
438
+ }
439
+ return (l, s) => {
440
+ const x = Me;
441
+ return o(), O(Se, M(n, {
442
+ "hide-on-click": !1,
443
+ class: "relative"
444
+ }), {
445
+ activator: $(({ on: v, isShow: f }) => [
446
+ b(l.$slots, "activator", ie(ce({ on: v, isShow: f })), () => [
447
+ S(Fe, {
448
+ "model-value": e.modelValue,
449
+ disabled: e.disabled,
450
+ label: e.label,
451
+ readonly: "",
452
+ hideMessage: "",
453
+ active: "",
454
+ onClick: v.click,
455
+ onOnIcon: v.click
456
+ }, {
457
+ icon: $(() => [
458
+ S(x, {
459
+ class: w(["transition duration-300", f ? "rotate-x-180" : ""])
460
+ }, null, 8, ["class"])
461
+ ]),
462
+ _: 2
463
+ }, 1032, ["model-value", "disabled", "label", "onClick", "onOnIcon"])
464
+ ])
465
+ ]),
466
+ default: $(({ on: v }) => [
467
+ r("div", Re, [
468
+ e.label ? (o(), c("h4", qe, _(e.label), 1)) : k("", !0),
469
+ r("div", He, [
470
+ S(Ee, {
471
+ items: e.items,
472
+ onClick: (f) => u(f, v)
473
+ }, {
474
+ default: $(({ item: f }) => [
475
+ b(l.$slots, "item", { item: f }, () => [
476
+ N(_(f.name), 1)
477
+ ])
478
+ ]),
479
+ _: 3
480
+ }, 8, ["items", "onClick"])
481
+ ])
482
+ ])
483
+ ]),
484
+ _: 3
485
+ }, 16);
486
+ };
487
+ }
488
+ }), Ke = {
489
+ key: 0,
490
+ class: "loader-line w-full absolute top-0 left-0 h-[3px] bg-gray-100 dark:bg-white/5 before:bg-primary before:h-1 rounded-xl z-20 before:absolute before:w-[40%] before:-left-1/2 before:content-[''] before:animate-[lineAnim_1s_linear_infinite]"
491
+ }, Ge = {
492
+ key: 1,
493
+ class: "absolute top-0 left-0 w-full h-full bg-gray-50 dark:bg-[#060b28]/75 z-10 opacity-50"
494
+ }, Je = {
495
+ key: 2,
496
+ class: "mb-4 flex items-center justify-between"
497
+ }, Qe = { class: "text-lg font-semibold text-gray-800 dark:text-white" }, Ue = ["inert", "aria-disabled"], st = /* @__PURE__ */ E({
498
+ __name: "CardMain",
499
+ props: {
500
+ title: {},
501
+ loading: { type: Boolean },
502
+ disabled: { type: Boolean }
503
+ },
504
+ setup(e) {
505
+ return (t, n) => (o(), c("div", {
506
+ class: w(["glass-panel relative p-5 transition-all duration-300 hover:border-primary/25 hover:shadow-[inset_0_1px_0_rgba(255,255,255,0.18),0_0_60px_-18px_rgba(40,183,240,0.25)] sm:p-6", { "overflow-hidden": e.loading }])
507
+ }, [
508
+ e.loading ? (o(), c("div", Ke)) : k("", !0),
509
+ e.loading ? (o(), c("div", Ge)) : k("", !0),
510
+ e.title ? (o(), c("div", Je, [
511
+ r("h3", Qe, _(e.title), 1),
512
+ r("div", null, [
513
+ b(t.$slots, "header")
514
+ ])
515
+ ])) : k("", !0),
516
+ r("div", {
517
+ class: "max-w-full",
518
+ inert: e.disabled,
519
+ "aria-disabled": e.disabled || void 0
520
+ }, [
521
+ b(t.$slots, "default")
522
+ ], 8, Ue)
523
+ ], 2));
524
+ }
525
+ }), Xe = { class: "text-title-md uppercase font-bold flex-auto" }, Ye = { class: "px-4 pb-4 md:px-6" }, Ze = {
526
+ key: 0,
527
+ class: "text-title-md uppercase font-bold"
528
+ }, rt = /* @__PURE__ */ E({
529
+ __name: "VDialog",
530
+ props: {
531
+ title: {},
532
+ size: { default: "md" },
533
+ popupSize: { default: "auto" },
534
+ color: { default: "white" },
535
+ type: {},
536
+ hiddenCloser: { type: Boolean },
537
+ isOnlyDialog: { type: Boolean },
538
+ timeout: {}
539
+ },
540
+ emits: ["close", "click", "open"],
541
+ setup(e, { expose: t, emit: n }) {
542
+ const h = n, u = X(Y), { show: l, onClose: s, onOpen: x } = U(h, e.timeout), v = {
543
+ sm: "max-w-full md:max-w-[330px] max-md:h-full",
544
+ md: "max-w-full md:max-w-[672px] max-md:h-full",
545
+ lg: "max-w-full md:max-w-[960px] max-md:h-full",
546
+ full: "relative max-w-full w-full h-3/4 "
547
+ }, f = {
548
+ none: "",
549
+ white: "glass-panel",
550
+ gray: ""
551
+ }, p = B(() => [v[e.size], f[e.color]]), L = u.greaterOrEqual("lg");
552
+ return t({
553
+ show: l,
554
+ onClose: s
555
+ }), (C, d) => {
556
+ const m = ee;
557
+ return e.isOnlyDialog || i(L) ? (o(), O(K, {
558
+ key: 0,
559
+ to: "body"
560
+ }, [
561
+ S(A, {
562
+ "enter-active-class": "duration-300 ease-out",
563
+ "enter-from-class": "transform opacity-0 -translate-y-2",
564
+ "enter-to-class": "opacity-100 translate-y-0",
565
+ "leave-active-class": "duration-200 ease-in",
566
+ "leave-from-class": "opacity-100 translate-y-0",
567
+ "leave-to-class": "transform opacity-0 -translate-y-2",
568
+ onAfterEnter: i(x)
569
+ }, {
570
+ default: $(() => [
571
+ i(l) ? (o(), c("div", {
572
+ key: 0,
573
+ class: "z-20 fixed top-0 h-dvh w-full left-0 flex flex-col",
574
+ onWheel: d[4] || (d[4] = V(() => {
575
+ }, ["stop"]))
576
+ }, [
577
+ r("div", {
578
+ class: "absolute h-full w-full top-0 left-0 bg-black/40 bg-blur",
579
+ onClick: d[0] || (d[0] = //@ts-ignore
580
+ (...y) => i(s) && i(s)(...y))
581
+ }),
582
+ r("div", {
583
+ class: w(["flex-auto flex align-center overflow-y-auto overscroll-contain", (e.size === "full", "")])
584
+ }, [
585
+ r("div", {
586
+ class: w(["m-auto z-20 flex w-full flex-col overflow-auto overscroll-contain scrollbar bg-transparent shadow-lg", p.value])
587
+ }, [
588
+ r("div", {
589
+ class: w(["flex items-center min-h-14 ps-6 pe-3", e.size === "full" ? "absolute top-0 right-4" : ""]),
590
+ onWheel: d[1] || (d[1] = V(() => {
591
+ }, ["prevent"])),
592
+ onTouchmove: d[2] || (d[2] = V(() => {
593
+ }, ["prevent"]))
594
+ }, [
595
+ r("h4", Xe, _(e.title), 1),
596
+ b(C.$slots, "header-btn", { close: i(s) }),
597
+ S(Z, {
598
+ color: "transparent",
599
+ size: "md",
600
+ onClick: i(s)
601
+ }, {
602
+ default: $(() => [
603
+ S(m)
604
+ ]),
605
+ _: 1
606
+ }, 8, ["onClick"])
607
+ ], 34),
608
+ r("div", {
609
+ class: w(["relative overflow-auto max-h-dvh scrollbar overflow-y-auto overscroll-contain min-h-0 max-md:flex-auto", e.size === "full" ? "flex-auto" : "md:max-h-147.5 px-6 pb-6"]),
610
+ onClose: d[3] || (d[3] = //@ts-ignore
611
+ (...y) => i(s) && i(s)(...y))
612
+ }, [
613
+ b(C.$slots, "default", { close: i(s) })
614
+ ], 34)
615
+ ], 2)
616
+ ], 2)
617
+ ], 32)) : k("", !0)
618
+ ]),
619
+ _: 3
620
+ }, 8, ["onAfterEnter"])
621
+ ])) : (o(), O(te, {
622
+ key: 1,
623
+ size: e.popupSize,
624
+ onClose: i(s)
625
+ }, {
626
+ button: $(() => [
627
+ b(C.$slots, "header-btn", { close: i(s) })
628
+ ]),
629
+ default: $(({ close: y }) => [
630
+ r("div", Ye, [
631
+ r("div", {
632
+ class: w(["flex items-center mb-4", e.size === "full" ? "absolute top-0 right-4" : ""]),
633
+ onWheel: d[5] || (d[5] = V(() => {
634
+ }, ["prevent"])),
635
+ onTouchmove: d[6] || (d[6] = V(() => {
636
+ }, ["prevent"]))
637
+ }, [
638
+ e.title ? (o(), c("h4", Ze, _(e.title), 1)) : k("", !0)
639
+ ], 34),
640
+ b(C.$slots, "default", { close: y })
641
+ ])
642
+ ]),
643
+ _: 3
644
+ }, 8, ["size", "onClose"]));
645
+ };
646
+ }
647
+ });
648
+ export {
649
+ lt as V,
650
+ rt as _,
651
+ ot as a,
652
+ st as b,
653
+ ze as c,
654
+ at as d,
655
+ nt as e,
656
+ Fe as f,
657
+ Ee as g,
658
+ Se as h,
659
+ ye as i,
660
+ Z as j,
661
+ ee as k,
662
+ W as l,
663
+ te as m
664
+ };
@@ -1 +1 @@
1
- {"version":3,"file":"AppHeader.vue.d.ts","sourceRoot":"","sources":["../../../src/components/app/AppHeader.vue"],"names":[],"mappings":"AAsDA;AA8FA,OAAO,KAAK,EAAE,eAAe,EAAmB,MAAM,wBAAwB,CAAC;;;;;;;;AAsU/E,wBAQG"}
1
+ {"version":3,"file":"AppHeader.vue.d.ts","sourceRoot":"","sources":["../../../src/components/app/AppHeader.vue"],"names":[],"mappings":"AAuDA;AA+FA,OAAO,KAAK,EAAE,eAAe,EAAmB,MAAM,wBAAwB,CAAC;;;;;;;;AAyU/E,wBAQG"}