manolis-ui 0.7.2 → 0.9.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/dist/manolis-ui.js +812 -791
- package/dist/manolis-ui.umd.cjs +13 -8
- package/dist/style.css +13 -0
- package/package.json +1 -1
package/dist/manolis-ui.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as L, computed as E, createElementBlock as a, openBlock as n, normalizeClass as
|
|
1
|
+
import { defineComponent as L, computed as E, createElementBlock as a, openBlock as n, normalizeClass as D, createCommentVNode as O, renderSlot as M, createTextVNode as ke, createElementVNode as s, Fragment as B, renderList as P, toDisplayString as C, ref as x, h as me, onMounted as ee, watch as H, withDirectives as q, createVNode as se, isRef as ze, vModelCheckbox as Ae, unref as R, provide as Pe, normalizeStyle as de, inject as Ee, useId as Le, defineAsyncComponent as ce, nextTick as pe, onBeforeUnmount as ge, withModifiers as Q, createBlock as ae, resolveDynamicComponent as ve, mergeProps as fe, withKeys as he, onUnmounted as $e, vModelSelect as Z, vModelText as oe, useSlots as Ue, Comment as Re, vShow as Ne } from "vue";
|
|
2
2
|
const je = ["disabled"], Fe = {
|
|
3
3
|
key: 0,
|
|
4
4
|
class: "loading loading-spinner"
|
|
5
|
-
},
|
|
5
|
+
}, mn = /* @__PURE__ */ L({
|
|
6
6
|
__name: "ButtonComponent",
|
|
7
7
|
props: {
|
|
8
8
|
outlined: { type: Boolean, default: !1 },
|
|
@@ -14,8 +14,8 @@ const je = ["disabled"], Fe = {
|
|
|
14
14
|
disabled: { type: Boolean, default: !1 }
|
|
15
15
|
},
|
|
16
16
|
setup(i) {
|
|
17
|
-
const
|
|
18
|
-
switch (
|
|
17
|
+
const v = i, e = E(() => {
|
|
18
|
+
switch (v.size) {
|
|
19
19
|
case "large":
|
|
20
20
|
return "btn-lg";
|
|
21
21
|
case "small":
|
|
@@ -30,7 +30,7 @@ const je = ["disabled"], Fe = {
|
|
|
30
30
|
return "";
|
|
31
31
|
}
|
|
32
32
|
}), t = E(() => {
|
|
33
|
-
switch (
|
|
33
|
+
switch (v.type) {
|
|
34
34
|
case "neutral":
|
|
35
35
|
return "btn-neutral";
|
|
36
36
|
case "primary":
|
|
@@ -55,7 +55,7 @@ const je = ["disabled"], Fe = {
|
|
|
55
55
|
return "btn-neutral";
|
|
56
56
|
}
|
|
57
57
|
}), o = E(() => {
|
|
58
|
-
switch (
|
|
58
|
+
switch (v.shape) {
|
|
59
59
|
case "square":
|
|
60
60
|
return "btn-square";
|
|
61
61
|
case "circle":
|
|
@@ -65,18 +65,18 @@ const je = ["disabled"], Fe = {
|
|
|
65
65
|
}
|
|
66
66
|
});
|
|
67
67
|
return (l, r) => (n(), a("button", {
|
|
68
|
-
class:
|
|
68
|
+
class: D([
|
|
69
69
|
"btn",
|
|
70
|
-
{ "btn-outline":
|
|
71
|
-
{ "btn-active":
|
|
70
|
+
{ "btn-outline": v.outlined },
|
|
71
|
+
{ "btn-active": v.active },
|
|
72
72
|
t.value,
|
|
73
73
|
e.value,
|
|
74
74
|
o.value
|
|
75
75
|
]),
|
|
76
|
-
disabled:
|
|
76
|
+
disabled: v.disabled
|
|
77
77
|
}, [
|
|
78
78
|
l.loading ? (n(), a("span", Fe)) : O("", !0),
|
|
79
|
-
|
|
79
|
+
M(l.$slots, "default", {}, () => [
|
|
80
80
|
r[0] || (r[0] = ke("Submit"))
|
|
81
81
|
])
|
|
82
82
|
], 10, je));
|
|
@@ -84,7 +84,7 @@ const je = ["disabled"], Fe = {
|
|
|
84
84
|
}), qe = {
|
|
85
85
|
tabindex: "0",
|
|
86
86
|
class: "z-1 bg-base-100 shadow-sm p-2 rounded-sm min-w-[inherit] md:min-w-full xl:min-w-52 dropdown-content menu"
|
|
87
|
-
}, He = ["href"],
|
|
87
|
+
}, He = ["href"], gn = /* @__PURE__ */ L({
|
|
88
88
|
__name: "dropdown",
|
|
89
89
|
props: {
|
|
90
90
|
items: {},
|
|
@@ -94,7 +94,7 @@ const je = ["disabled"], Fe = {
|
|
|
94
94
|
forceOpen: { type: Boolean, default: !1 }
|
|
95
95
|
},
|
|
96
96
|
setup(i) {
|
|
97
|
-
const
|
|
97
|
+
const v = {
|
|
98
98
|
left: "dropdown-left",
|
|
99
99
|
right: "dropdown-right",
|
|
100
100
|
bottom: "dropdown-bottom",
|
|
@@ -104,32 +104,32 @@ const je = ["disabled"], Fe = {
|
|
|
104
104
|
end: "dropdown-end"
|
|
105
105
|
}, t = i;
|
|
106
106
|
return (o, l) => (n(), a("div", {
|
|
107
|
-
class:
|
|
107
|
+
class: D(["dropdown", v[t.position], e[t.floatPosition], { "dropdown-open": t.forceOpen }, { "dropdown-hover": t.openOnHover }])
|
|
108
108
|
}, [
|
|
109
|
-
|
|
109
|
+
M(o.$slots, "default", {
|
|
110
110
|
tabindex: "0",
|
|
111
111
|
role: "button"
|
|
112
112
|
}, () => [
|
|
113
113
|
l[0] || (l[0] = s("div", { class: "m-1 btn" }, "Open dropdown", -1))
|
|
114
114
|
]),
|
|
115
115
|
s("ul", qe, [
|
|
116
|
-
(n(!0), a(B, null,
|
|
116
|
+
(n(!0), a(B, null, P(o.items, (r) => (n(), a("li", null, [
|
|
117
117
|
s("a", {
|
|
118
118
|
href: r.link
|
|
119
119
|
}, C(r.text), 9, He)
|
|
120
120
|
]))), 256)),
|
|
121
|
-
|
|
121
|
+
M(o.$slots, "additional")
|
|
122
122
|
])
|
|
123
123
|
], 2));
|
|
124
124
|
}
|
|
125
|
-
}), We = { class: "modal-box" }, Ke = { class: "modal-action" },
|
|
125
|
+
}), We = { class: "modal-box" }, Ke = { class: "modal-action" }, hn = /* @__PURE__ */ L({
|
|
126
126
|
__name: "modal",
|
|
127
127
|
props: {
|
|
128
128
|
position: { default: "center" },
|
|
129
129
|
withBackdrop: { type: Boolean, default: !1 }
|
|
130
130
|
},
|
|
131
131
|
setup(i) {
|
|
132
|
-
const
|
|
132
|
+
const v = i, e = {
|
|
133
133
|
top: "modal-top",
|
|
134
134
|
bottom: "modal-bottom",
|
|
135
135
|
center: "modal-middle"
|
|
@@ -140,31 +140,31 @@ const je = ["disabled"], Fe = {
|
|
|
140
140
|
var r;
|
|
141
141
|
(r = t.value) == null || r.close();
|
|
142
142
|
};
|
|
143
|
-
return (r,
|
|
143
|
+
return (r, b) => (n(), a(B, null, [
|
|
144
144
|
s("span", {
|
|
145
145
|
class: "w-fit cursor-pointer",
|
|
146
146
|
onClick: o
|
|
147
147
|
}, [
|
|
148
|
-
|
|
149
|
-
|
|
148
|
+
M(r.$slots, "trigger", { role: "button" }, () => [
|
|
149
|
+
b[0] || (b[0] = s("button", { class: "btn" }, "Open", -1))
|
|
150
150
|
])
|
|
151
151
|
]),
|
|
152
152
|
s("dialog", {
|
|
153
153
|
ref_key: "dialog",
|
|
154
154
|
ref: t,
|
|
155
|
-
class:
|
|
155
|
+
class: D(["modal", e[v.position]])
|
|
156
156
|
}, [
|
|
157
157
|
s("div", We, [
|
|
158
|
-
|
|
158
|
+
M(r.$slots, "default"),
|
|
159
159
|
s("div", Ke, [
|
|
160
|
-
|
|
160
|
+
M(r.$slots, "actions"),
|
|
161
161
|
s("form", {
|
|
162
162
|
method: "dialog",
|
|
163
163
|
onSubmit: l,
|
|
164
|
-
class:
|
|
164
|
+
class: D(r.withBackdrop ? "modal-backdrop" : "")
|
|
165
165
|
}, [
|
|
166
|
-
|
|
167
|
-
|
|
166
|
+
M(r.$slots, "close-button", {}, () => [
|
|
167
|
+
b[1] || (b[1] = s("button", { class: "btn" }, "Close", -1))
|
|
168
168
|
])
|
|
169
169
|
], 34)
|
|
170
170
|
])
|
|
@@ -172,22 +172,22 @@ const je = ["disabled"], Fe = {
|
|
|
172
172
|
], 2)
|
|
173
173
|
], 64));
|
|
174
174
|
}
|
|
175
|
-
}), Ye = { class: "flex justify-center items-center swap-on" }, Je = { class: "flex justify-center items-center swap-off" },
|
|
175
|
+
}), Ye = { class: "flex justify-center items-center swap-on" }, Je = { class: "flex justify-center items-center swap-off" }, bn = /* @__PURE__ */ L({
|
|
176
176
|
__name: "swap",
|
|
177
177
|
props: {
|
|
178
178
|
effect: {}
|
|
179
179
|
},
|
|
180
180
|
setup(i) {
|
|
181
|
-
const
|
|
181
|
+
const v = i;
|
|
182
182
|
return (e, t) => (n(), a("label", {
|
|
183
|
-
class:
|
|
183
|
+
class: D(["swap", v.effect ? `swap-${e.effect}` : ""])
|
|
184
184
|
}, [
|
|
185
185
|
t[0] || (t[0] = s("input", { type: "checkbox" }, null, -1)),
|
|
186
186
|
s("div", Ye, [
|
|
187
|
-
|
|
187
|
+
M(e.$slots, "on")
|
|
188
188
|
]),
|
|
189
189
|
s("div", Je, [
|
|
190
|
-
|
|
190
|
+
M(e.$slots, "off")
|
|
191
191
|
])
|
|
192
192
|
], 2));
|
|
193
193
|
}
|
|
@@ -198,14 +198,14 @@ const je = ["disabled"], Fe = {
|
|
|
198
198
|
* This source code is licensed under the ISC license.
|
|
199
199
|
* See the LICENSE file in the root directory of this source tree.
|
|
200
200
|
*/
|
|
201
|
-
const
|
|
201
|
+
const Xe = (i) => i.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
|
|
202
202
|
/**
|
|
203
203
|
* @license lucide-vue-next v0.468.0 - ISC
|
|
204
204
|
*
|
|
205
205
|
* This source code is licensed under the ISC license.
|
|
206
206
|
* See the LICENSE file in the root directory of this source tree.
|
|
207
207
|
*/
|
|
208
|
-
var
|
|
208
|
+
var ue = {
|
|
209
209
|
xmlns: "http://www.w3.org/2000/svg",
|
|
210
210
|
width: 24,
|
|
211
211
|
height: 24,
|
|
@@ -222,18 +222,18 @@ var ie = {
|
|
|
222
222
|
* This source code is licensed under the ISC license.
|
|
223
223
|
* See the LICENSE file in the root directory of this source tree.
|
|
224
224
|
*/
|
|
225
|
-
const
|
|
225
|
+
const Ge = ({ size: i, strokeWidth: v = 2, absoluteStrokeWidth: e, color: t, iconNode: o, name: l, class: r, ...b }, { slots: c }) => me(
|
|
226
226
|
"svg",
|
|
227
227
|
{
|
|
228
|
-
...
|
|
229
|
-
width: i ||
|
|
230
|
-
height: i ||
|
|
231
|
-
stroke: t ||
|
|
232
|
-
"stroke-width": e ? Number(
|
|
233
|
-
class: ["lucide", `lucide-${
|
|
234
|
-
...
|
|
228
|
+
...ue,
|
|
229
|
+
width: i || ue.width,
|
|
230
|
+
height: i || ue.height,
|
|
231
|
+
stroke: t || ue.stroke,
|
|
232
|
+
"stroke-width": e ? Number(v) * 24 / Number(i) : v,
|
|
233
|
+
class: ["lucide", `lucide-${Xe(l ?? "icon")}`],
|
|
234
|
+
...b
|
|
235
235
|
},
|
|
236
|
-
[...o.map((
|
|
236
|
+
[...o.map((m) => me(...m)), ...c.default ? [c.default()] : []]
|
|
237
237
|
);
|
|
238
238
|
/**
|
|
239
239
|
* @license lucide-vue-next v0.468.0 - ISC
|
|
@@ -241,11 +241,11 @@ const Xe = ({ size: i, strokeWidth: d = 2, absoluteStrokeWidth: e, color: t, ico
|
|
|
241
241
|
* This source code is licensed under the ISC license.
|
|
242
242
|
* See the LICENSE file in the root directory of this source tree.
|
|
243
243
|
*/
|
|
244
|
-
const
|
|
245
|
-
|
|
244
|
+
const te = (i, v) => (e, { slots: t }) => me(
|
|
245
|
+
Ge,
|
|
246
246
|
{
|
|
247
247
|
...e,
|
|
248
|
-
iconNode:
|
|
248
|
+
iconNode: v,
|
|
249
249
|
name: i
|
|
250
250
|
},
|
|
251
251
|
t
|
|
@@ -256,7 +256,7 @@ const oe = (i, d) => (e, { slots: t }) => me(
|
|
|
256
256
|
* This source code is licensed under the ISC license.
|
|
257
257
|
* See the LICENSE file in the root directory of this source tree.
|
|
258
258
|
*/
|
|
259
|
-
const Ze =
|
|
259
|
+
const Ze = te("CalendarIcon", [
|
|
260
260
|
["path", { d: "M8 2v4", key: "1cmpym" }],
|
|
261
261
|
["path", { d: "M16 2v4", key: "4m81vk" }],
|
|
262
262
|
["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
|
|
@@ -268,7 +268,7 @@ const Ze = oe("CalendarIcon", [
|
|
|
268
268
|
* This source code is licensed under the ISC license.
|
|
269
269
|
* See the LICENSE file in the root directory of this source tree.
|
|
270
270
|
*/
|
|
271
|
-
const Qe =
|
|
271
|
+
const Qe = te("CircleChevronDownIcon", [
|
|
272
272
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
273
273
|
["path", { d: "m16 10-4 4-4-4", key: "894hmk" }]
|
|
274
274
|
]);
|
|
@@ -278,7 +278,18 @@ const Qe = oe("CircleChevronDownIcon", [
|
|
|
278
278
|
* This source code is licensed under the ISC license.
|
|
279
279
|
* See the LICENSE file in the root directory of this source tree.
|
|
280
280
|
*/
|
|
281
|
-
const et =
|
|
281
|
+
const et = te("CircleXIcon", [
|
|
282
|
+
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
283
|
+
["path", { d: "m15 9-6 6", key: "1uzhvr" }],
|
|
284
|
+
["path", { d: "m9 9 6 6", key: "z0biqf" }]
|
|
285
|
+
]);
|
|
286
|
+
/**
|
|
287
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
288
|
+
*
|
|
289
|
+
* This source code is licensed under the ISC license.
|
|
290
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
291
|
+
*/
|
|
292
|
+
const tt = te("MoonIcon", [
|
|
282
293
|
["path", { d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z", key: "a7tn18" }]
|
|
283
294
|
]);
|
|
284
295
|
/**
|
|
@@ -287,7 +298,7 @@ const et = oe("MoonIcon", [
|
|
|
287
298
|
* This source code is licensed under the ISC license.
|
|
288
299
|
* See the LICENSE file in the root directory of this source tree.
|
|
289
300
|
*/
|
|
290
|
-
const we =
|
|
301
|
+
const we = te("SearchIcon", [
|
|
291
302
|
["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }],
|
|
292
303
|
["path", { d: "m21 21-4.3-4.3", key: "1qie3q" }]
|
|
293
304
|
]);
|
|
@@ -297,7 +308,7 @@ const we = oe("SearchIcon", [
|
|
|
297
308
|
* This source code is licensed under the ISC license.
|
|
298
309
|
* See the LICENSE file in the root directory of this source tree.
|
|
299
310
|
*/
|
|
300
|
-
const
|
|
311
|
+
const lt = te("SunIcon", [
|
|
301
312
|
["circle", { cx: "12", cy: "12", r: "4", key: "4exip2" }],
|
|
302
313
|
["path", { d: "M12 2v2", key: "tus03m" }],
|
|
303
314
|
["path", { d: "M12 20v2", key: "1lh1kg" }],
|
|
@@ -307,44 +318,44 @@ const tt = oe("SunIcon", [
|
|
|
307
318
|
["path", { d: "M20 12h2", key: "1q8mjw" }],
|
|
308
319
|
["path", { d: "m6.34 17.66-1.41 1.41", key: "1m8zz5" }],
|
|
309
320
|
["path", { d: "m19.07 4.93-1.41 1.41", key: "1shlcs" }]
|
|
310
|
-
]),
|
|
321
|
+
]), nt = (i, v) => {
|
|
311
322
|
const e = x(null);
|
|
312
|
-
return
|
|
323
|
+
return ee(() => {
|
|
313
324
|
if (typeof window < "u") {
|
|
314
325
|
const t = window.localStorage.getItem(i);
|
|
315
|
-
e.value = t ? JSON.parse(t) :
|
|
326
|
+
e.value = t ? JSON.parse(t) : v;
|
|
316
327
|
}
|
|
317
328
|
}), H(e, (t) => {
|
|
318
329
|
typeof window < "u" && window.localStorage.setItem(i, JSON.stringify(t));
|
|
319
330
|
}), e;
|
|
320
|
-
},
|
|
331
|
+
}, at = { class: "swap-rotate swap" }, ot = ["true-value", "false-value"], yn = /* @__PURE__ */ L({
|
|
321
332
|
__name: "theme-controller",
|
|
322
333
|
props: {
|
|
323
334
|
lightTheme: { default: "light" },
|
|
324
335
|
darkTheme: { default: "dark" }
|
|
325
336
|
},
|
|
326
337
|
setup(i) {
|
|
327
|
-
const
|
|
338
|
+
const v = i, e = nt("theme", v.lightTheme);
|
|
328
339
|
function t(o) {
|
|
329
340
|
typeof window < "u" && window.document && document.documentElement.setAttribute("data-theme", o);
|
|
330
341
|
}
|
|
331
|
-
return
|
|
342
|
+
return ee(() => t(e.value ? e.value : "")), H(e, (o) => {
|
|
332
343
|
t(o);
|
|
333
|
-
}), (o, l) => (n(), a("label",
|
|
344
|
+
}), (o, l) => (n(), a("label", at, [
|
|
334
345
|
q(s("input", {
|
|
335
346
|
type: "checkbox",
|
|
336
347
|
class: "theme-controller",
|
|
337
348
|
"onUpdate:modelValue": l[0] || (l[0] = (r) => ze(e) ? e.value = r : null),
|
|
338
|
-
"true-value":
|
|
339
|
-
"false-value":
|
|
340
|
-
}, null, 8,
|
|
341
|
-
[Ae,
|
|
349
|
+
"true-value": v.lightTheme,
|
|
350
|
+
"false-value": v.darkTheme
|
|
351
|
+
}, null, 8, ot), [
|
|
352
|
+
[Ae, R(e)]
|
|
342
353
|
]),
|
|
343
|
-
|
|
344
|
-
|
|
354
|
+
se(R(lt), { class: "swap-off fill-current" }),
|
|
355
|
+
se(R(tt), { class: "swap-on fill-current" })
|
|
345
356
|
]));
|
|
346
357
|
}
|
|
347
|
-
}),
|
|
358
|
+
}), st = ["name"], rt = { class: "collapse-title font-bold text-2xl lg:text-4xl" }, it = { class: "collapse-content" }, ut = ["innerHTML"], wn = /* @__PURE__ */ L({
|
|
348
359
|
__name: "accordion",
|
|
349
360
|
props: {
|
|
350
361
|
name: {},
|
|
@@ -353,25 +364,25 @@ const tt = oe("SunIcon", [
|
|
|
353
364
|
icon: {}
|
|
354
365
|
},
|
|
355
366
|
setup(i) {
|
|
356
|
-
const
|
|
357
|
-
return (e, t) => (n(!0), a(B, null,
|
|
358
|
-
class:
|
|
367
|
+
const v = i;
|
|
368
|
+
return (e, t) => (n(!0), a(B, null, P(v.items, (o, l) => (n(), a("div", {
|
|
369
|
+
class: D(["collapse border border-base-300", [e.icon ? `collapse-${e.icon}` : "", { "join-item": e.joinItems }]]),
|
|
359
370
|
key: l
|
|
360
371
|
}, [
|
|
361
372
|
s("input", {
|
|
362
373
|
type: "radio",
|
|
363
374
|
name: e.name,
|
|
364
375
|
value: "true"
|
|
365
|
-
}, null, 8,
|
|
366
|
-
s("div",
|
|
367
|
-
s("div",
|
|
376
|
+
}, null, 8, st),
|
|
377
|
+
s("div", rt, C(o.title), 1),
|
|
378
|
+
s("div", it, [
|
|
368
379
|
s("span", {
|
|
369
380
|
innerHTML: o.content
|
|
370
|
-
}, null, 8,
|
|
381
|
+
}, null, 8, ut)
|
|
371
382
|
])
|
|
372
383
|
], 2))), 128));
|
|
373
384
|
}
|
|
374
|
-
}),
|
|
385
|
+
}), dt = ["src"], ct = { class: "text-xl" }, kn = /* @__PURE__ */ L({
|
|
375
386
|
__name: "avatar",
|
|
376
387
|
props: {
|
|
377
388
|
image: {},
|
|
@@ -380,32 +391,32 @@ const tt = oe("SunIcon", [
|
|
|
380
391
|
fullyRounded: { type: Boolean, default: !1 }
|
|
381
392
|
},
|
|
382
393
|
setup(i) {
|
|
383
|
-
const
|
|
394
|
+
const v = i, e = x(v.onlineStatus);
|
|
384
395
|
return H(
|
|
385
|
-
() =>
|
|
396
|
+
() => v.onlineStatus,
|
|
386
397
|
(t) => {
|
|
387
398
|
t && (e.value = t);
|
|
388
399
|
}
|
|
389
400
|
), (t, o) => (n(), a("div", {
|
|
390
|
-
class:
|
|
401
|
+
class: D(["avatar", [{ "avatar-online": e.value === "online" }, { "avatar-offline": e.value === "offline" }]])
|
|
391
402
|
}, [
|
|
392
403
|
t.image ? (n(), a("div", {
|
|
393
404
|
key: 0,
|
|
394
|
-
class:
|
|
405
|
+
class: D(["rounded", [{ "rounded-full": t.fullyRounded }, { rounded: !t.fullyRounded }]])
|
|
395
406
|
}, [
|
|
396
407
|
s("img", {
|
|
397
408
|
src: t.image,
|
|
398
409
|
class: "w-full h-full"
|
|
399
|
-
}, null, 8,
|
|
410
|
+
}, null, 8, dt)
|
|
400
411
|
], 2)) : (n(), a("div", {
|
|
401
412
|
key: 1,
|
|
402
|
-
class:
|
|
413
|
+
class: D(["flex justify-center bg-neutral p-[25%] rounded w-16 text-neutral-content text-center", [{ "rounded-full": t.fullyRounded }, { rounded: !t.fullyRounded }]])
|
|
403
414
|
}, [
|
|
404
|
-
s("p",
|
|
415
|
+
s("p", ct, C(t.initials), 1)
|
|
405
416
|
], 2))
|
|
406
417
|
], 2));
|
|
407
418
|
}
|
|
408
|
-
}),
|
|
419
|
+
}), $n = /* @__PURE__ */ L({
|
|
409
420
|
__name: "badge",
|
|
410
421
|
props: {
|
|
411
422
|
color: { default: "neutral" },
|
|
@@ -413,7 +424,7 @@ const tt = oe("SunIcon", [
|
|
|
413
424
|
size: { default: "medium" }
|
|
414
425
|
},
|
|
415
426
|
setup(i) {
|
|
416
|
-
const
|
|
427
|
+
const v = i, e = {
|
|
417
428
|
"extra small": "badge-xs",
|
|
418
429
|
small: "badge-sm",
|
|
419
430
|
medium: "badge-md",
|
|
@@ -430,24 +441,24 @@ const tt = oe("SunIcon", [
|
|
|
430
441
|
error: "badge-error"
|
|
431
442
|
};
|
|
432
443
|
return (o, l) => (n(), a("span", {
|
|
433
|
-
class:
|
|
444
|
+
class: D(["badge", e[v.size], t[v.color], { "badge-outline": v.outline }])
|
|
434
445
|
}, [
|
|
435
|
-
|
|
446
|
+
M(o.$slots, "default")
|
|
436
447
|
], 2));
|
|
437
448
|
}
|
|
438
|
-
}),
|
|
449
|
+
}), pt = ["src", "alt"], vt = {
|
|
439
450
|
key: 0,
|
|
440
451
|
class: "card-body"
|
|
441
|
-
},
|
|
452
|
+
}, ft = {
|
|
442
453
|
key: 0,
|
|
443
454
|
class: "group-hover:text-primary text-lg text-left cursor-pointer card-title"
|
|
444
|
-
},
|
|
455
|
+
}, mt = {
|
|
445
456
|
key: 1,
|
|
446
457
|
class: "text-left"
|
|
447
|
-
},
|
|
458
|
+
}, gt = { class: "flex-col flex-nowrap mt-auto card-actions" }, ht = {
|
|
448
459
|
key: 1,
|
|
449
460
|
class: "card-body"
|
|
450
|
-
},
|
|
461
|
+
}, _n = /* @__PURE__ */ L({
|
|
451
462
|
__name: "card",
|
|
452
463
|
props: {
|
|
453
464
|
imgUrl: { default: "" },
|
|
@@ -462,41 +473,41 @@ const tt = oe("SunIcon", [
|
|
|
462
473
|
imgHeight: { default: "h-44" }
|
|
463
474
|
},
|
|
464
475
|
setup(i) {
|
|
465
|
-
const
|
|
476
|
+
const v = i, e = x(v.outlined);
|
|
466
477
|
return H(
|
|
467
|
-
() =>
|
|
478
|
+
() => v.outlined,
|
|
468
479
|
(t) => {
|
|
469
480
|
e.value = t;
|
|
470
481
|
}
|
|
471
482
|
), (t, o) => (n(), a("div", {
|
|
472
|
-
class:
|
|
483
|
+
class: D(["group bg-base-100 shadow-xl rounded-sm min-w-64 max-w-full h-full card card-compact", [{ "border-4 border-primary": e.value }, t.color ?? "", t.background]])
|
|
473
484
|
}, [
|
|
474
485
|
s("figure", null, [
|
|
475
486
|
t.imgUrl || t.imgUrl && !t.loading ? (n(), a("img", {
|
|
476
487
|
key: 0,
|
|
477
488
|
src: t.imgUrl,
|
|
478
489
|
alt: t.alt,
|
|
479
|
-
class:
|
|
490
|
+
class: D(["rounded-sm w-full object-cover", [
|
|
480
491
|
{
|
|
481
492
|
hidden: t.loading
|
|
482
493
|
},
|
|
483
494
|
t.imgHeight
|
|
484
495
|
]])
|
|
485
|
-
}, null, 10,
|
|
496
|
+
}, null, 10, pt)) : O("", !0),
|
|
486
497
|
t.loading && t.imgUrl ? (n(), a("div", {
|
|
487
498
|
key: 1,
|
|
488
|
-
class:
|
|
499
|
+
class: D(["w-full skeleton", t.imgHeight])
|
|
489
500
|
}, null, 2)) : O("", !0)
|
|
490
501
|
]),
|
|
491
|
-
t.loading ? O("", !0) : (n(), a("div",
|
|
492
|
-
t.title ? (n(), a("h2",
|
|
493
|
-
|
|
494
|
-
t.description ? (n(), a("p",
|
|
495
|
-
s("div",
|
|
496
|
-
|
|
502
|
+
t.loading ? O("", !0) : (n(), a("div", vt, [
|
|
503
|
+
t.title ? (n(), a("h2", ft, C(t.title), 1)) : O("", !0),
|
|
504
|
+
M(t.$slots, "details"),
|
|
505
|
+
t.description ? (n(), a("p", mt, C(t.description), 1)) : O("", !0),
|
|
506
|
+
s("div", gt, [
|
|
507
|
+
M(t.$slots, "actions")
|
|
497
508
|
])
|
|
498
509
|
])),
|
|
499
|
-
t.loading ? (n(), a("div",
|
|
510
|
+
t.loading ? (n(), a("div", ht, o[0] || (o[0] = [
|
|
500
511
|
s("div", { class: "flex flex-col gap-4 w-52" }, [
|
|
501
512
|
s("div", { class: "w-28 h-4 skeleton" }),
|
|
502
513
|
s("div", { class: "w-full h-4 skeleton" }),
|
|
@@ -505,13 +516,13 @@ const tt = oe("SunIcon", [
|
|
|
505
516
|
]))) : O("", !0)
|
|
506
517
|
], 2));
|
|
507
518
|
}
|
|
508
|
-
}), _e = Symbol("CarouselItemStyle"),
|
|
519
|
+
}), _e = Symbol("CarouselItemStyle"), bt = { class: "relative h-full" }, yt = {
|
|
509
520
|
key: 0,
|
|
510
521
|
class: "top-1/2 right-5 left-5 z-10 absolute flex justify-between -translate-y-1/2 transform"
|
|
511
|
-
},
|
|
522
|
+
}, wt = {
|
|
512
523
|
key: 1,
|
|
513
524
|
class: "bottom-5 z-10 absolute flex justify-center gap-2 py-2 w-full"
|
|
514
|
-
},
|
|
525
|
+
}, kt = ["onClick", "aria-label"], $t = /* @__PURE__ */ L({
|
|
515
526
|
__name: "carousel",
|
|
516
527
|
props: {
|
|
517
528
|
showIndicators: {
|
|
@@ -548,136 +559,136 @@ const tt = oe("SunIcon", [
|
|
|
548
559
|
validator: (i) => i >= 0
|
|
549
560
|
}
|
|
550
561
|
},
|
|
551
|
-
setup(i, { expose:
|
|
552
|
-
const e = i, t = x(e.initialSlide), o = x(null), l = x(!1), r = x(0),
|
|
562
|
+
setup(i, { expose: v }) {
|
|
563
|
+
const e = i, t = x(e.initialSlide), o = x(null), l = x(!1), r = x(0), b = E(() => ({
|
|
553
564
|
width: `calc((100% - ${e.slidesPerView > 1 ? (e.slidesPerView - 1) * e.gap : 0}px) / ${e.slidesPerView})`
|
|
554
565
|
}));
|
|
555
|
-
Pe(_e,
|
|
556
|
-
const
|
|
566
|
+
Pe(_e, b);
|
|
567
|
+
const c = () => {
|
|
557
568
|
o.value ? r.value = o.value.children.length : r.value = 0;
|
|
558
|
-
},
|
|
559
|
-
if (!o.value || e.slidesPerView <= 0 || l.value || (
|
|
560
|
-
const
|
|
569
|
+
}, m = async (w) => {
|
|
570
|
+
if (!o.value || e.slidesPerView <= 0 || l.value || (c(), r.value === 0)) return;
|
|
571
|
+
const $ = (w % r.value + r.value) % r.value, I = o.value, z = e.sliderOrientation === "vertical" ? (I.offsetHeight - (e.slidesPerView - 1) * e.gap) / e.slidesPerView : (I.offsetWidth - (e.slidesPerView - 1) * e.gap) / e.slidesPerView;
|
|
561
572
|
if (z <= 0) return;
|
|
562
|
-
const
|
|
563
|
-
l.value = !0,
|
|
564
|
-
const
|
|
573
|
+
const j = z + e.gap, W = $ * j, Y = e.sliderOrientation === "vertical" ? I.scrollHeight - I.offsetHeight : I.scrollWidth - I.offsetWidth, p = Math.max(0, Math.min(W, Y + 0.5));
|
|
574
|
+
l.value = !0, I.style.scrollBehavior = "auto";
|
|
575
|
+
const y = e.sliderOrientation === "vertical" ? I.scrollTop : I.scrollLeft, S = p - y;
|
|
565
576
|
if (Math.abs(S) < 1) {
|
|
566
|
-
l.value = !1, t.value =
|
|
577
|
+
l.value = !1, t.value = $;
|
|
567
578
|
return;
|
|
568
579
|
}
|
|
569
|
-
const
|
|
570
|
-
const
|
|
571
|
-
e.sliderOrientation === "vertical" ?
|
|
580
|
+
const T = performance.now(), u = (A) => {
|
|
581
|
+
const _ = A - T, V = Math.min(1, _ / e.slideDuration), K = V < 0.5 ? 4 * V * V * V : 1 - Math.pow(-2 * V + 2, 3) / 2, J = y + S * K;
|
|
582
|
+
e.sliderOrientation === "vertical" ? I.scrollTop = J : I.scrollLeft = J, V < 1 ? requestAnimationFrame(u) : (e.sliderOrientation === "vertical" ? I.scrollTop = p : I.scrollLeft = p, t.value = $, l.value = !1);
|
|
572
583
|
};
|
|
573
|
-
requestAnimationFrame(
|
|
574
|
-
},
|
|
575
|
-
|
|
584
|
+
requestAnimationFrame(u);
|
|
585
|
+
}, k = () => {
|
|
586
|
+
m(t.value + 1);
|
|
576
587
|
}, U = () => {
|
|
577
|
-
|
|
578
|
-
},
|
|
579
|
-
|
|
580
|
-
},
|
|
581
|
-
if (!o.value || e.slidesPerView <= 0 || (
|
|
582
|
-
const
|
|
588
|
+
m(t.value - 1);
|
|
589
|
+
}, N = (w) => {
|
|
590
|
+
m(w);
|
|
591
|
+
}, f = () => {
|
|
592
|
+
if (!o.value || e.slidesPerView <= 0 || (c(), r.value === 0)) return;
|
|
593
|
+
const w = o.value, $ = e.sliderOrientation === "vertical" ? w.offsetHeight : w.offsetWidth, I = e.slidesPerView > 1 ? (e.slidesPerView - 1) * e.gap : 0, z = ($ - I) / e.slidesPerView;
|
|
583
594
|
if (z <= 0) return;
|
|
584
|
-
const
|
|
585
|
-
e.sliderOrientation === "vertical" ?
|
|
595
|
+
const j = Math.max(0, r.value - e.slidesPerView), W = Math.min(Math.max(0, e.initialSlide), j), Y = W * (z + e.gap), p = e.sliderOrientation === "vertical" ? w.scrollHeight - w.offsetHeight : w.scrollWidth - w.offsetWidth, y = Math.max(0, Math.min(Y, p + 0.5));
|
|
596
|
+
e.sliderOrientation === "vertical" ? w.scrollTo({ top: y, behavior: "auto" }) : w.scrollTo({ left: y, behavior: "auto" }), t.value = W;
|
|
586
597
|
};
|
|
587
|
-
return
|
|
598
|
+
return ee(() => {
|
|
588
599
|
requestAnimationFrame(() => {
|
|
589
|
-
requestAnimationFrame(
|
|
590
|
-
}),
|
|
591
|
-
}), H(() => e.initialSlide, (
|
|
592
|
-
requestAnimationFrame(() =>
|
|
600
|
+
requestAnimationFrame(f);
|
|
601
|
+
}), c();
|
|
602
|
+
}), H(() => e.initialSlide, (w) => {
|
|
603
|
+
requestAnimationFrame(() => m(w));
|
|
593
604
|
}), H(() => [e.slidesPerView, e.gap], () => {
|
|
594
605
|
requestAnimationFrame(() => {
|
|
595
606
|
requestAnimationFrame(() => {
|
|
596
|
-
if (
|
|
597
|
-
const
|
|
598
|
-
e.slideDuration = 0,
|
|
607
|
+
if (c(), r.value === 0) return;
|
|
608
|
+
const w = Math.max(0, r.value - e.slidesPerView), $ = Math.min(t.value, w), I = e.slideDuration;
|
|
609
|
+
e.slideDuration = 0, m($), e.slideDuration = I;
|
|
599
610
|
});
|
|
600
611
|
});
|
|
601
|
-
}),
|
|
612
|
+
}), v({ scrollToSlide: m }), (w, $) => (n(), a("div", bt, [
|
|
602
613
|
s("div", {
|
|
603
614
|
ref_key: "carouselContainer",
|
|
604
615
|
ref: o,
|
|
605
|
-
class:
|
|
616
|
+
class: D(["rounded w-full h-full overflow-x-scroll scroll-smooth carousel", [{ "carousel-horizontal md:snap-none": i.sliderOrientation == "horizontal" }, { "carousel-vertical": i.sliderOrientation == "vertical" }]]),
|
|
606
617
|
style: de({ gap: `${i.gap}px` })
|
|
607
618
|
}, [
|
|
608
|
-
|
|
619
|
+
M(w.$slots, "default", {}, void 0, !0)
|
|
609
620
|
], 6),
|
|
610
|
-
i.showNavigationButtons ? (n(), a("div",
|
|
621
|
+
i.showNavigationButtons ? (n(), a("div", yt, [
|
|
611
622
|
s("div", {
|
|
612
623
|
onClick: U,
|
|
613
624
|
role: "button",
|
|
614
625
|
"aria-label": "Previous Slide"
|
|
615
626
|
}, [
|
|
616
|
-
|
|
617
|
-
|
|
627
|
+
M(w.$slots, "prevButton", {}, () => [
|
|
628
|
+
$[0] || ($[0] = s("button", {
|
|
618
629
|
class: "btn btn-circle",
|
|
619
630
|
tabindex: "-1"
|
|
620
631
|
}, "❮", -1))
|
|
621
632
|
], !0)
|
|
622
633
|
]),
|
|
623
634
|
s("div", {
|
|
624
|
-
onClick:
|
|
635
|
+
onClick: k,
|
|
625
636
|
role: "button",
|
|
626
637
|
"aria-label": "Next Slide"
|
|
627
638
|
}, [
|
|
628
|
-
|
|
629
|
-
|
|
639
|
+
M(w.$slots, "nextButton", {}, () => [
|
|
640
|
+
$[1] || ($[1] = s("button", {
|
|
630
641
|
class: "btn btn-circle",
|
|
631
642
|
tabindex: "-1"
|
|
632
643
|
}, "❯", -1))
|
|
633
644
|
], !0)
|
|
634
645
|
])
|
|
635
646
|
])) : O("", !0),
|
|
636
|
-
i.showIndicators ? (n(), a("div",
|
|
637
|
-
(n(!0), a(B, null,
|
|
647
|
+
i.showIndicators ? (n(), a("div", wt, [
|
|
648
|
+
(n(!0), a(B, null, P(r.value, (I, z) => (n(), a("button", {
|
|
638
649
|
key: `dot-${z}`,
|
|
639
|
-
onClick: (
|
|
640
|
-
class:
|
|
650
|
+
onClick: (j) => N(z),
|
|
651
|
+
class: D(["btn btn-circle btn-xs", { "btn-active": z === t.value }]),
|
|
641
652
|
"aria-label": `Go to slide ${z + 1}`
|
|
642
|
-
}, null, 10,
|
|
653
|
+
}, null, 10, kt))), 128))
|
|
643
654
|
])) : O("", !0)
|
|
644
655
|
]));
|
|
645
656
|
}
|
|
646
|
-
}),
|
|
657
|
+
}), le = (i, v) => {
|
|
647
658
|
const e = i.__vccOpts || i;
|
|
648
|
-
for (const [t, o] of
|
|
659
|
+
for (const [t, o] of v)
|
|
649
660
|
e[t] = o;
|
|
650
661
|
return e;
|
|
651
|
-
},
|
|
662
|
+
}, Sn = /* @__PURE__ */ le($t, [["__scopeId", "data-v-db55a6a5"]]), _t = /* @__PURE__ */ L({
|
|
652
663
|
__name: "carouselItem",
|
|
653
664
|
setup(i) {
|
|
654
|
-
const
|
|
665
|
+
const v = Ee(_e, x({}));
|
|
655
666
|
return (e, t) => (n(), a("div", {
|
|
656
667
|
class: "w-full h-full carousel-item",
|
|
657
|
-
style: de(
|
|
668
|
+
style: de(R(v))
|
|
658
669
|
}, [
|
|
659
|
-
|
|
670
|
+
M(e.$slots, "default", {}, void 0, !0)
|
|
660
671
|
], 4));
|
|
661
672
|
}
|
|
662
|
-
}),
|
|
673
|
+
}), xn = /* @__PURE__ */ le(_t, [["__scopeId", "data-v-507384bc"]]), St = { class: "flex gap-4 bg-base-100 w-full tabs tabs-boxed" }, xt = ["onClick"], Ct = {
|
|
663
674
|
key: 0,
|
|
664
675
|
class: "inline-component-wrapper flex flex-grow justify-center items-center w-full h-full"
|
|
665
|
-
},
|
|
676
|
+
}, It = {
|
|
666
677
|
key: 1,
|
|
667
678
|
class: "flex flex-col"
|
|
668
679
|
}, Mt = { class: "text-sm" }, Dt = {
|
|
669
680
|
key: 0,
|
|
670
681
|
class: "opacity-75 overflow-hidden text-xs truncate ..."
|
|
671
|
-
},
|
|
682
|
+
}, Tt = {
|
|
672
683
|
key: 1,
|
|
673
684
|
class: "hidden md:block opacity-35 overflow-hidden text-xs truncate ..."
|
|
674
|
-
},
|
|
685
|
+
}, Vt = { class: "hidden" }, Bt = ["id"], Ot = { class: "modal-box" }, zt = { class: "font-bold text-lg" }, At = ["name", "checked"], Pt = { class: "collapse-title flex justify-between items-center pr-4 w-full font-medium text-xl" }, Et = {
|
|
675
686
|
key: 0,
|
|
676
687
|
class: "opacity-75 overflow-hidden text-sm truncate ..."
|
|
677
|
-
},
|
|
688
|
+
}, Lt = {
|
|
678
689
|
key: 1,
|
|
679
690
|
class: "opacity-35 text-sm"
|
|
680
|
-
},
|
|
691
|
+
}, Ut = { class: "collapse-content flex place-content-center p-0" }, Rt = /* @__PURE__ */ L({
|
|
681
692
|
__name: "advancedSearch",
|
|
682
693
|
props: {
|
|
683
694
|
searchOptions: {},
|
|
@@ -686,121 +697,121 @@ const tt = oe("SunIcon", [
|
|
|
686
697
|
value: {}
|
|
687
698
|
},
|
|
688
699
|
emits: ["search", "update:search-data"],
|
|
689
|
-
setup(i, { emit:
|
|
690
|
-
const e = i, t =
|
|
691
|
-
datetime: ce(() => Promise.resolve().then(() =>
|
|
700
|
+
setup(i, { emit: v }) {
|
|
701
|
+
const e = i, t = v, o = e.id ?? `advancedSearch-${Le()}`, l = x(null), r = x(null), b = {
|
|
702
|
+
datetime: ce(() => Promise.resolve().then(() => pl)),
|
|
692
703
|
"standard-select": ce(() => import("./select-Cz4vf_YE.js")),
|
|
693
704
|
// Add other components here when you create them:
|
|
694
705
|
// 'custom-range': defineAsyncComponent(() => import('./CustomRange.vue')),
|
|
695
706
|
// 'custom-number': defineAsyncComponent(() => import('./CustomNumber.vue')),
|
|
696
707
|
"custom-text": ce(() => import("./inputField-BxT95oyM.js"))
|
|
697
708
|
// 'custom-select': defineAsyncComponent(() => import('./CustomSelect.vue')),
|
|
698
|
-
},
|
|
709
|
+
}, c = x({}), m = x({
|
|
699
710
|
left: "0px",
|
|
700
711
|
top: "0px",
|
|
701
712
|
transform: "translateX(0%)"
|
|
702
|
-
}),
|
|
703
|
-
var
|
|
704
|
-
if (
|
|
713
|
+
}), k = x(null), U = (p) => {
|
|
714
|
+
var y;
|
|
715
|
+
if (p.value === void 0 || p.value === null || p.value === "")
|
|
705
716
|
return "";
|
|
706
|
-
switch (
|
|
717
|
+
switch (p.type) {
|
|
707
718
|
case "datetime":
|
|
708
|
-
if (typeof
|
|
719
|
+
if (typeof p.value == "string")
|
|
709
720
|
try {
|
|
710
|
-
const S = new Date(
|
|
721
|
+
const S = new Date(p.value);
|
|
711
722
|
if (!isNaN(S.getTime()))
|
|
712
723
|
return S.toLocaleString();
|
|
713
724
|
} catch {
|
|
714
725
|
}
|
|
715
|
-
else if (
|
|
726
|
+
else if (p.range && typeof p.value == "object" && p.value !== null && "start" in p.value && "end" in p.value)
|
|
716
727
|
try {
|
|
717
|
-
const S = new Date(
|
|
718
|
-
if (!isNaN(S.getTime()) && !isNaN(
|
|
719
|
-
return `${S.toLocaleDateString()} - ${
|
|
728
|
+
const S = new Date(p.value.start), T = new Date(p.value.end);
|
|
729
|
+
if (!isNaN(S.getTime()) && !isNaN(T.getTime()))
|
|
730
|
+
return `${S.toLocaleDateString()} - ${T.toLocaleDateString()}`;
|
|
720
731
|
} catch {
|
|
721
732
|
}
|
|
722
733
|
break;
|
|
723
734
|
case "custom-range":
|
|
724
|
-
if (typeof
|
|
725
|
-
return `${
|
|
735
|
+
if (typeof p.value == "object" && p.value !== null && "start" in p.value && "end" in p.value)
|
|
736
|
+
return `${p.value.start} - ${p.value.end}`;
|
|
726
737
|
break;
|
|
727
738
|
case "custom-number":
|
|
728
|
-
if (typeof
|
|
729
|
-
return
|
|
739
|
+
if (typeof p.value == "number")
|
|
740
|
+
return p.value.toString();
|
|
730
741
|
break;
|
|
731
742
|
case "standard-select":
|
|
732
743
|
case "custom-select":
|
|
733
|
-
if ((
|
|
734
|
-
const S =
|
|
735
|
-
(
|
|
744
|
+
if ((y = p.props) != null && y.options && Array.isArray(p.props.options)) {
|
|
745
|
+
const S = p.props.options.find(
|
|
746
|
+
(T) => T.value === p.value
|
|
736
747
|
);
|
|
737
748
|
if (S)
|
|
738
749
|
return S.text;
|
|
739
750
|
}
|
|
740
|
-
return String(
|
|
751
|
+
return String(p.value);
|
|
741
752
|
case "custom-text":
|
|
742
|
-
if (typeof
|
|
743
|
-
return
|
|
753
|
+
if (typeof p.value == "string")
|
|
754
|
+
return p.value;
|
|
744
755
|
break;
|
|
745
756
|
}
|
|
746
|
-
return String(
|
|
757
|
+
return String(p.value);
|
|
747
758
|
};
|
|
748
|
-
function
|
|
749
|
-
var
|
|
750
|
-
const
|
|
751
|
-
if (!
|
|
759
|
+
function N(p) {
|
|
760
|
+
var u, A;
|
|
761
|
+
const y = (u = l.value) == null ? void 0 : u.name;
|
|
762
|
+
if (!y) {
|
|
752
763
|
console.warn("componentValueUpdated called but no active tab.");
|
|
753
764
|
return;
|
|
754
765
|
}
|
|
755
|
-
const S = (
|
|
756
|
-
(
|
|
757
|
-
)) == null ? void 0 :
|
|
758
|
-
(
|
|
766
|
+
const S = (A = e.searchOptions.find(
|
|
767
|
+
(_) => (_ == null ? void 0 : _.category) === e.currentCategory
|
|
768
|
+
)) == null ? void 0 : A.tabs, T = S == null ? void 0 : S.find(
|
|
769
|
+
(_) => _.name === y
|
|
759
770
|
);
|
|
760
|
-
|
|
761
|
-
tab:
|
|
762
|
-
data:
|
|
771
|
+
T ? (T.value = p, t("update:search-data", {
|
|
772
|
+
tab: T.name,
|
|
773
|
+
data: p
|
|
763
774
|
})) : console.error(
|
|
764
|
-
`Tab with name "${
|
|
775
|
+
`Tab with name "${y}" not found in current category.`
|
|
765
776
|
);
|
|
766
777
|
}
|
|
767
|
-
function
|
|
768
|
-
|
|
778
|
+
function f(p) {
|
|
779
|
+
N(p);
|
|
769
780
|
}
|
|
770
|
-
function
|
|
781
|
+
function w() {
|
|
771
782
|
t("search");
|
|
772
783
|
}
|
|
773
|
-
async function
|
|
774
|
-
var
|
|
775
|
-
const
|
|
776
|
-
((
|
|
784
|
+
async function $(p) {
|
|
785
|
+
var T;
|
|
786
|
+
const y = document.getElementById(`advancedSearchMobile-${o}`), S = y && y.contains(p.target);
|
|
787
|
+
((T = l.value) == null ? void 0 : T.displayMode) === "popup" && k.value && !k.value.contains(p.target) && !S && (await pe(), l.value = null);
|
|
777
788
|
}
|
|
778
|
-
async function
|
|
789
|
+
async function I() {
|
|
779
790
|
if (typeof window < "u" && window.innerWidth <= 768) {
|
|
780
|
-
const
|
|
791
|
+
const p = document.getElementById(
|
|
781
792
|
`advancedSearchMobile-${o}`
|
|
782
793
|
);
|
|
783
|
-
|
|
794
|
+
p ? (l.value = null, p.showModal()) : console.warn(
|
|
784
795
|
`Mobile modal element not found. Ensure it exists with id="advancedSearchMobile-${o}".`
|
|
785
796
|
);
|
|
786
797
|
}
|
|
787
798
|
}
|
|
788
|
-
async function z(
|
|
789
|
-
var S,
|
|
799
|
+
async function z(p) {
|
|
800
|
+
var S, T, u;
|
|
790
801
|
if (typeof window < "u" && window.innerWidth <= 768) {
|
|
791
|
-
|
|
802
|
+
I();
|
|
792
803
|
return;
|
|
793
804
|
}
|
|
794
|
-
const
|
|
795
|
-
if (((S = l.value) == null ? void 0 : S.name) ===
|
|
805
|
+
const y = p.displayMode ?? "popup";
|
|
806
|
+
if (((S = l.value) == null ? void 0 : S.name) === p.name && ((T = l.value) == null ? void 0 : T.displayMode) === y)
|
|
796
807
|
l.value = null;
|
|
797
|
-
else if (l.value = { ...
|
|
798
|
-
const
|
|
799
|
-
if (
|
|
800
|
-
const
|
|
801
|
-
|
|
808
|
+
else if (l.value = { ...p, displayMode: y }, await pe(), ((u = l.value) == null ? void 0 : u.displayMode) === "popup") {
|
|
809
|
+
const A = c.value[p.name];
|
|
810
|
+
if (A && k.value) {
|
|
811
|
+
const _ = A.getBoundingClientRect(), V = k.value.getBoundingClientRect(), K = _.bottom - V.top, J = _.left + _.width / 2 - V.left;
|
|
812
|
+
m.value = {
|
|
802
813
|
left: `${J}px`,
|
|
803
|
-
top: `${
|
|
814
|
+
top: `${K + 8}px`,
|
|
804
815
|
// Add a small gap
|
|
805
816
|
transform: "translateX(-50%)"
|
|
806
817
|
// Center horizontally
|
|
@@ -808,137 +819,137 @@ const tt = oe("SunIcon", [
|
|
|
808
819
|
} else
|
|
809
820
|
console.error(
|
|
810
821
|
"Tab element or search container not found for positioning:",
|
|
811
|
-
|
|
822
|
+
p.name
|
|
812
823
|
);
|
|
813
824
|
}
|
|
814
825
|
}
|
|
815
|
-
const
|
|
816
|
-
const
|
|
826
|
+
const j = (p) => {
|
|
827
|
+
const y = p.relatedTarget;
|
|
817
828
|
setTimeout(() => {
|
|
818
829
|
var S;
|
|
819
|
-
((S = l.value) == null ? void 0 : S.displayMode) === "inline" &&
|
|
830
|
+
((S = l.value) == null ? void 0 : S.displayMode) === "inline" && k.value && (!y || !k.value.contains(y)) ? (console.log("Blur detected outside container, closing inline view."), l.value = null) : console.log(
|
|
820
831
|
"Blur detected, but staying within container or not an inline tab."
|
|
821
832
|
);
|
|
822
833
|
}, 50);
|
|
823
|
-
},
|
|
834
|
+
}, W = () => {
|
|
824
835
|
console.log("Enter key pressed on inline component, closing inline view."), l.value = null;
|
|
825
836
|
};
|
|
826
|
-
H(r, (
|
|
827
|
-
var
|
|
837
|
+
H(r, (p) => {
|
|
838
|
+
var y;
|
|
828
839
|
console.log(
|
|
829
840
|
"advanced-search: inlineComponentRef changed. New Value:",
|
|
830
|
-
|
|
831
|
-
), console.log("advanced-search: activeTab.value:", l.value),
|
|
841
|
+
p
|
|
842
|
+
), console.log("advanced-search: activeTab.value:", l.value), p && ((y = l.value) == null ? void 0 : y.displayMode) === "inline" ? (console.log(
|
|
832
843
|
"advanced-search: Inline component ref is available and active tab is inline. Attempting to focus child input..."
|
|
833
844
|
), pe(() => {
|
|
834
845
|
console.log(
|
|
835
846
|
"advanced-search: Inside nextTick. Attempting to call child's focus method..."
|
|
836
|
-
), console.log("advanced-search: Type of newValue:", typeof
|
|
847
|
+
), console.log("advanced-search: Type of newValue:", typeof p), console.log(
|
|
837
848
|
"advanced-search: Does newValue have focusInput?",
|
|
838
|
-
typeof
|
|
839
|
-
),
|
|
849
|
+
typeof p.focusInput == "function"
|
|
850
|
+
), p && typeof p.focusInput == "function" ? (console.log(
|
|
840
851
|
"advanced-search: Calling exposed focusInput() method on child instance."
|
|
841
|
-
),
|
|
852
|
+
), p.focusInput()) : console.warn(
|
|
842
853
|
'advanced-search: Child inline component instance does not expose a "focusInput" method or is not ready.',
|
|
843
|
-
|
|
854
|
+
p
|
|
844
855
|
);
|
|
845
856
|
})) : console.log(
|
|
846
|
-
|
|
857
|
+
p ? "advanced-search: inlineComponentRef available, but active tab is not inline." : "advanced-search: inlineComponentRef is now null (component likely unmounted)."
|
|
847
858
|
);
|
|
848
|
-
}),
|
|
849
|
-
document.addEventListener("click",
|
|
859
|
+
}), ee(() => {
|
|
860
|
+
document.addEventListener("click", $), window.addEventListener("resize", Y);
|
|
850
861
|
}), ge(() => {
|
|
851
|
-
document.removeEventListener("click",
|
|
862
|
+
document.removeEventListener("click", $), window.removeEventListener("resize", Y);
|
|
852
863
|
});
|
|
853
|
-
const
|
|
854
|
-
var
|
|
864
|
+
const Y = () => {
|
|
865
|
+
var p, y;
|
|
855
866
|
if (typeof window < "u") {
|
|
856
|
-
const S = window.innerWidth <= 768,
|
|
857
|
-
!S && (((
|
|
867
|
+
const S = window.innerWidth <= 768, T = l.value !== null && (l.value.displayMode === "popup" || l.value.displayMode === "inline") && window.innerWidth > 768;
|
|
868
|
+
!S && (((p = l.value) == null ? void 0 : p.displayMode) === "popup" || ((y = l.value) == null ? void 0 : y.displayMode) === "inline") && window.innerWidth <= 768 && (console.log("Resizing to mobile, closing active tab."), l.value = null), S && !T && l.value !== null && (console.log(
|
|
858
869
|
"Resizing to desktop from potential mobile active state, closing active tab."
|
|
859
870
|
), l.value = null);
|
|
860
|
-
const
|
|
871
|
+
const u = document.getElementById(
|
|
861
872
|
`advancedSearchMobile-${o}`
|
|
862
873
|
);
|
|
863
|
-
|
|
874
|
+
u != null && u.open && !S && (console.log("Modal is open on desktop, closing modal and active tab."), u.close(), l.value = null);
|
|
864
875
|
}
|
|
865
876
|
};
|
|
866
|
-
return (
|
|
867
|
-
var S,
|
|
877
|
+
return (p, y) => {
|
|
878
|
+
var S, T;
|
|
868
879
|
return n(), a(B, null, [
|
|
869
880
|
s("div", {
|
|
870
881
|
ref_key: "searchContainer",
|
|
871
|
-
ref:
|
|
882
|
+
ref: k,
|
|
872
883
|
class: "w-full"
|
|
873
884
|
}, [
|
|
874
885
|
s("div", {
|
|
875
886
|
class: "group/search relative flex place-items-center shadow-md p-2 border-2 border-base-300/25 rounded-sm w-full transition-all cursor-pointer md:cursor-auto",
|
|
876
|
-
onClick:
|
|
887
|
+
onClick: I
|
|
877
888
|
}, [
|
|
878
|
-
s("div",
|
|
879
|
-
(n(!0), a(B, null,
|
|
880
|
-
(
|
|
881
|
-
)) == null ? void 0 : S.tabs) || [], (
|
|
882
|
-
var
|
|
889
|
+
s("div", St, [
|
|
890
|
+
(n(!0), a(B, null, P(((S = e.searchOptions.find(
|
|
891
|
+
(u) => u.category === e.currentCategory
|
|
892
|
+
)) == null ? void 0 : S.tabs) || [], (u, A) => {
|
|
893
|
+
var _, V, K, J, re;
|
|
883
894
|
return n(), a("button", {
|
|
884
|
-
key: `${
|
|
885
|
-
onClick:
|
|
886
|
-
class:
|
|
887
|
-
"tab-active": ((
|
|
888
|
-
"tab-active-inline": ((
|
|
895
|
+
key: `${u.name}-${A}`,
|
|
896
|
+
onClick: Q((X) => z(u), ["stop"]),
|
|
897
|
+
class: D([{
|
|
898
|
+
"tab-active": ((_ = l.value) == null ? void 0 : _.name) === u.name,
|
|
899
|
+
"tab-active-inline": ((V = l.value) == null ? void 0 : V.name) === u.name && ((K = l.value) == null ? void 0 : K.displayMode) === "inline"
|
|
889
900
|
// Add new class
|
|
890
901
|
}, "group/searchitem after:top-0 after:-right-2 after:absolute relative first-of-type:flex-auto last-of-type:flex-auto after:bg-base-200 hover:bg-base-200 p-1 rounded-sm w-auto after:w-[1px] after:h-10 overflow-x-hidden text-start md:after:content-[''] after:content-none last-of-type:after:content-none"]),
|
|
891
902
|
ref_for: !0,
|
|
892
|
-
ref: (
|
|
903
|
+
ref: (X) => c.value[u.name] = X
|
|
893
904
|
}, [
|
|
894
|
-
((J = l.value) == null ? void 0 : J.name) ===
|
|
895
|
-
(n(),
|
|
905
|
+
((J = l.value) == null ? void 0 : J.name) === u.name && ((re = l.value) == null ? void 0 : re.displayMode) === "inline" ? (n(), a("div", Ct, [
|
|
906
|
+
(n(), ae(ve(b[l.value.type]), fe({ ref_for: !0 }, l.value.props || {}, {
|
|
896
907
|
modelValue: l.value.value,
|
|
897
|
-
onUpdated:
|
|
898
|
-
"onUpdate:modelValue":
|
|
899
|
-
onBlur:
|
|
900
|
-
onKeydown: he(
|
|
908
|
+
onUpdated: y[0] || (y[0] = (X) => f(X)),
|
|
909
|
+
"onUpdate:modelValue": y[1] || (y[1] = (X) => f(X)),
|
|
910
|
+
onBlur: j,
|
|
911
|
+
onKeydown: he(Q(W, ["stop", "prevent"]), ["enter"]),
|
|
901
912
|
ref_for: !0,
|
|
902
913
|
ref_key: "inlineComponentRef",
|
|
903
914
|
ref: r
|
|
904
915
|
}), null, 16, ["modelValue", "onKeydown"]))
|
|
905
|
-
])) : (n(), a("div",
|
|
906
|
-
s("p", Mt, C(
|
|
907
|
-
|
|
916
|
+
])) : (n(), a("div", It, [
|
|
917
|
+
s("p", Mt, C(u.name), 1),
|
|
918
|
+
u.value !== void 0 && u.value !== null && u.value !== "" ? (n(), a("p", Dt, C(U(u)), 1)) : (n(), a("p", Tt, C(u.description), 1))
|
|
908
919
|
]))
|
|
909
|
-
], 10,
|
|
920
|
+
], 10, xt);
|
|
910
921
|
}), 128))
|
|
911
922
|
]),
|
|
912
923
|
l.value && l.value.displayMode === "popup" ? (n(), a("div", {
|
|
913
924
|
key: 0,
|
|
914
925
|
class: "absolute flex shadow-sm mt-4 w-fit max-w-full transition-all tab-content",
|
|
915
|
-
style: de(
|
|
926
|
+
style: de(m.value)
|
|
916
927
|
}, [
|
|
917
|
-
(n(),
|
|
928
|
+
(n(), ae(ve(b[l.value.type]), fe(l.value.props || {}, {
|
|
918
929
|
modelValue: l.value.value,
|
|
919
|
-
onUpdated:
|
|
920
|
-
"onUpdate:modelValue":
|
|
930
|
+
onUpdated: y[2] || (y[2] = (u) => N(u)),
|
|
931
|
+
"onUpdate:modelValue": y[3] || (y[3] = (u) => N(u))
|
|
921
932
|
}), null, 16, ["modelValue"]))
|
|
922
933
|
], 4)) : O("", !0),
|
|
923
934
|
s("button", {
|
|
924
935
|
title: "search",
|
|
925
936
|
type: "submit",
|
|
926
937
|
class: "ml-1 btn btn-primary btn-square",
|
|
927
|
-
onClick:
|
|
938
|
+
onClick: Q(w, ["stop"])
|
|
928
939
|
}, [
|
|
929
|
-
|
|
940
|
+
se(R(we), {
|
|
930
941
|
size: 24,
|
|
931
942
|
color: "white"
|
|
932
943
|
})
|
|
933
944
|
])
|
|
934
945
|
]),
|
|
935
|
-
s("div",
|
|
946
|
+
s("div", Vt, [
|
|
936
947
|
s("button", {
|
|
937
948
|
title: "search",
|
|
938
|
-
onClick:
|
|
949
|
+
onClick: y[4] || (y[4] = () => {
|
|
939
950
|
})
|
|
940
951
|
}, [
|
|
941
|
-
|
|
952
|
+
se(R(we), {
|
|
942
953
|
size: 24,
|
|
943
954
|
color: "white"
|
|
944
955
|
})
|
|
@@ -946,34 +957,34 @@ const tt = oe("SunIcon", [
|
|
|
946
957
|
])
|
|
947
958
|
], 512),
|
|
948
959
|
s("dialog", {
|
|
949
|
-
id: `advancedSearchMobile-${
|
|
960
|
+
id: `advancedSearchMobile-${R(o)}`,
|
|
950
961
|
class: "modal"
|
|
951
962
|
}, [
|
|
952
|
-
s("div",
|
|
953
|
-
|
|
954
|
-
s("h3",
|
|
963
|
+
s("div", Ot, [
|
|
964
|
+
M(p.$slots, "additionalForMobile", {}, () => [
|
|
965
|
+
s("h3", zt, C(p.currentCategory), 1)
|
|
955
966
|
], !0),
|
|
956
|
-
(n(!0), a(B, null,
|
|
957
|
-
(
|
|
958
|
-
)) == null ? void 0 :
|
|
967
|
+
(n(!0), a(B, null, P(((T = e.searchOptions.find(
|
|
968
|
+
(u) => u.category === e.currentCategory
|
|
969
|
+
)) == null ? void 0 : T.tabs) || [], (u, A) => (n(), a("div", {
|
|
959
970
|
class: "collapse bg-base-200 my-4",
|
|
960
|
-
key:
|
|
971
|
+
key: u.name
|
|
961
972
|
}, [
|
|
962
973
|
s("input", {
|
|
963
974
|
type: "radio",
|
|
964
|
-
name: `accordion-${
|
|
965
|
-
checked:
|
|
966
|
-
}, null, 8,
|
|
967
|
-
s("div",
|
|
968
|
-
s("div", null, C(
|
|
969
|
-
|
|
975
|
+
name: `accordion-${R(o)}`,
|
|
976
|
+
checked: A === 0
|
|
977
|
+
}, null, 8, At),
|
|
978
|
+
s("div", Pt, [
|
|
979
|
+
s("div", null, C(u.name), 1),
|
|
980
|
+
u.value !== void 0 && u.value !== null && u.value !== "" ? (n(), a("div", Et, C(U(u)), 1)) : (n(), a("div", Lt, C(u.description), 1))
|
|
970
981
|
]),
|
|
971
|
-
s("div",
|
|
972
|
-
|
|
973
|
-
(n(),
|
|
974
|
-
modelValue:
|
|
975
|
-
onUpdated:
|
|
976
|
-
"onUpdate:modelValue":
|
|
982
|
+
s("div", Ut, [
|
|
983
|
+
y[7] || (y[7] = s("br", null, null, -1)),
|
|
984
|
+
(n(), ae(ve(b[u.type]), fe({ ref_for: !0 }, u.props || {}, {
|
|
985
|
+
modelValue: u.value,
|
|
986
|
+
onUpdated: y[5] || (y[5] = (_) => N(_)),
|
|
987
|
+
"onUpdate:modelValue": y[6] || (y[6] = (_) => N(_))
|
|
977
988
|
}), null, 16, ["modelValue"]))
|
|
978
989
|
])
|
|
979
990
|
]))), 128)),
|
|
@@ -981,40 +992,40 @@ const tt = oe("SunIcon", [
|
|
|
981
992
|
s("form", { method: "dialog" }, [
|
|
982
993
|
s("button", {
|
|
983
994
|
class: "btn btn-primary",
|
|
984
|
-
onClick:
|
|
995
|
+
onClick: w
|
|
985
996
|
}, " Close and Search ")
|
|
986
997
|
])
|
|
987
998
|
])
|
|
988
999
|
])
|
|
989
|
-
], 8,
|
|
1000
|
+
], 8, Bt)
|
|
990
1001
|
], 64);
|
|
991
1002
|
};
|
|
992
1003
|
}
|
|
993
|
-
}),
|
|
1004
|
+
}), Cn = /* @__PURE__ */ le(Rt, [["__scopeId", "data-v-2a095d4c"]]), Nt = ["placeholder", "value", "id", "disabled"], jt = ["disabled"], Ft = ["id"], qt = {
|
|
994
1005
|
key: 0,
|
|
995
1006
|
class: "flex justify-between items-center place-content-center mb-4"
|
|
996
|
-
},
|
|
1007
|
+
}, Ht = ["disabled"], Wt = ["value"], Kt = ["value"], Yt = {
|
|
997
1008
|
key: 1,
|
|
998
1009
|
class: "gap-2 grid grid-cols-7"
|
|
999
|
-
},
|
|
1010
|
+
}, Jt = ["onClick"], Xt = {
|
|
1000
1011
|
key: 2,
|
|
1001
1012
|
class: "mt-4 lg:w-80"
|
|
1002
1013
|
}, Gt = {
|
|
1003
1014
|
key: 0,
|
|
1004
1015
|
class: "mb-2 font-bold text-lg"
|
|
1005
|
-
},
|
|
1016
|
+
}, Zt = { key: 1 }, Qt = {
|
|
1006
1017
|
key: 1,
|
|
1007
1018
|
class: "flex gap-4"
|
|
1008
|
-
},
|
|
1019
|
+
}, el = ["value"], tl = ["value"], ll = {
|
|
1009
1020
|
key: 2,
|
|
1010
1021
|
class: "flex flex-col gap-4"
|
|
1011
|
-
},
|
|
1022
|
+
}, nl = {
|
|
1012
1023
|
key: 1,
|
|
1013
1024
|
class: "flex gap-2"
|
|
1014
|
-
},
|
|
1025
|
+
}, al = ["value"], ol = ["value"], sl = {
|
|
1015
1026
|
key: 1,
|
|
1016
1027
|
class: "flex gap-2"
|
|
1017
|
-
},
|
|
1028
|
+
}, rl = ["value"], il = ["value"], ul = { class: "flex gap-2 mt-4" }, dl = {
|
|
1018
1029
|
__name: "datetimePicker",
|
|
1019
1030
|
props: {
|
|
1020
1031
|
mode: {
|
|
@@ -1049,39 +1060,39 @@ const tt = oe("SunIcon", [
|
|
|
1049
1060
|
}
|
|
1050
1061
|
},
|
|
1051
1062
|
emits: ["updated"],
|
|
1052
|
-
setup(i, { emit:
|
|
1063
|
+
setup(i, { emit: v }) {
|
|
1053
1064
|
const e = i;
|
|
1054
1065
|
H(
|
|
1055
1066
|
() => e.range,
|
|
1056
|
-
(
|
|
1057
|
-
|
|
1067
|
+
(g) => {
|
|
1068
|
+
g ? (l.value = { start: null, end: null }, r.value = { start: null, end: null }) : (l.value = null, r.value = null);
|
|
1058
1069
|
}
|
|
1059
1070
|
);
|
|
1060
|
-
const t =
|
|
1071
|
+
const t = v, o = x(!1), l = x(e.range ? { start: null, end: null } : null), r = x(e.range ? { start: null, end: null } : null), b = x(
|
|
1061
1072
|
(/* @__PURE__ */ new Date()).toLocaleString("default", { month: "long" })
|
|
1062
|
-
),
|
|
1073
|
+
), c = x((/* @__PURE__ */ new Date()).getFullYear()), m = x(e.range ? { start: 0, end: 0 } : 0), k = x(e.range ? { start: 0, end: 0 } : 0), U = x(null), N = E(() => `${e.id}-input`), f = E(() => `${e.id}-popup`), w = E(
|
|
1063
1074
|
() => e.mode === "date" || e.mode === "datetime"
|
|
1064
|
-
),
|
|
1075
|
+
), $ = E(
|
|
1065
1076
|
() => e.mode === "time" || e.mode === "datetime"
|
|
1066
1077
|
);
|
|
1067
1078
|
E(
|
|
1068
|
-
() => new Date(
|
|
1079
|
+
() => new Date(c.value, I.value)
|
|
1069
1080
|
);
|
|
1070
|
-
const
|
|
1071
|
-
() => new Date(
|
|
1072
|
-
),
|
|
1073
|
-
const
|
|
1081
|
+
const I = E(() => T.indexOf(b.value)), z = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], j = E(
|
|
1082
|
+
() => new Date(c.value, I.value).getDay()
|
|
1083
|
+
), W = E(() => {
|
|
1084
|
+
const g = new Date(c.value, I.value + 1, 0).getDate();
|
|
1074
1085
|
return Array.from(
|
|
1075
|
-
{ length:
|
|
1076
|
-
(h,
|
|
1086
|
+
{ length: g },
|
|
1087
|
+
(h, d) => new Date(c.value, I.value, d + 1)
|
|
1077
1088
|
);
|
|
1078
|
-
}),
|
|
1079
|
-
() => Array.from({ length:
|
|
1080
|
-
),
|
|
1089
|
+
}), Y = E(
|
|
1090
|
+
() => Array.from({ length: j.value }, (g, h) => h)
|
|
1091
|
+
), p = Array.from({ length: 24 }, (g, h) => h), y = Array.from({ length: 60 }, (g, h) => h), S = E(
|
|
1081
1092
|
() => typeof navigator < "u" && /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(
|
|
1082
1093
|
navigator.userAgent
|
|
1083
1094
|
)
|
|
1084
|
-
),
|
|
1095
|
+
), T = [
|
|
1085
1096
|
"January",
|
|
1086
1097
|
"February",
|
|
1087
1098
|
"March",
|
|
@@ -1094,110 +1105,110 @@ const tt = oe("SunIcon", [
|
|
|
1094
1105
|
"October",
|
|
1095
1106
|
"November",
|
|
1096
1107
|
"December"
|
|
1097
|
-
],
|
|
1098
|
-
const
|
|
1099
|
-
return Array.from({ length: 100 }, (h,
|
|
1100
|
-
}),
|
|
1101
|
-
if (!
|
|
1108
|
+
], u = E(() => {
|
|
1109
|
+
const g = (/* @__PURE__ */ new Date()).getFullYear();
|
|
1110
|
+
return Array.from({ length: 100 }, (h, d) => g - 50 + d);
|
|
1111
|
+
}), A = E(() => {
|
|
1112
|
+
if (!w.value || !l.value) return "";
|
|
1102
1113
|
if (e.range && l.value.start && l.value.end) {
|
|
1103
|
-
const
|
|
1104
|
-
return `${
|
|
1114
|
+
const g = l.value.start.toLocaleDateString("en-US"), h = l.value.end.toLocaleDateString("en-US");
|
|
1115
|
+
return `${g} - ${h}`;
|
|
1105
1116
|
}
|
|
1106
1117
|
return !e.range && l.value ? l.value.toLocaleDateString("en-US") : "";
|
|
1107
|
-
}),
|
|
1108
|
-
if (
|
|
1109
|
-
const
|
|
1110
|
-
var
|
|
1111
|
-
const
|
|
1112
|
-
return S.value ? ((ye = r.value) == null ? void 0 : ye[h]) ?? r.value : `${
|
|
1118
|
+
}), _ = (g) => g instanceof Date ? g : new Date(g), V = (g) => g instanceof Date && !isNaN(g), K = E(() => {
|
|
1119
|
+
if (!$.value) return "";
|
|
1120
|
+
const g = (h) => {
|
|
1121
|
+
var ie, ne, ye;
|
|
1122
|
+
const d = ((ie = m.value) == null ? void 0 : ie[h]) ?? m.value, G = ((ne = k.value) == null ? void 0 : ne[h]) ?? k.value;
|
|
1123
|
+
return S.value ? ((ye = r.value) == null ? void 0 : ye[h]) ?? r.value : `${d.toString().padStart(2, "0")}:${G.toString().padStart(2, "0")}`;
|
|
1113
1124
|
};
|
|
1114
|
-
return e.range ? `${
|
|
1125
|
+
return e.range ? `${g("start")} - ${g("end")}` : g();
|
|
1115
1126
|
}), J = E(() => {
|
|
1116
|
-
const
|
|
1117
|
-
return `${
|
|
1118
|
-
}),
|
|
1119
|
-
|
|
1127
|
+
const g = A.value, h = K.value;
|
|
1128
|
+
return `${g} ${h}`.trim();
|
|
1129
|
+
}), re = () => o.value = !o.value, X = () => {
|
|
1130
|
+
F(), Se();
|
|
1120
1131
|
}, Se = () => o.value = !1, xe = () => {
|
|
1121
|
-
l.value = e.range ? { start: null, end: null } : null, r.value = e.range ? { start: null, end: null } : null,
|
|
1122
|
-
}, Ce = (
|
|
1123
|
-
e.range ? l.value.start && l.value.end ? l.value = { start:
|
|
1124
|
-
},
|
|
1125
|
-
|
|
1132
|
+
l.value = e.range ? { start: null, end: null } : null, r.value = e.range ? { start: null, end: null } : null, F();
|
|
1133
|
+
}, Ce = (g) => {
|
|
1134
|
+
e.range ? l.value.start && l.value.end ? l.value = { start: g, end: null } : l.value.start ? l.value.end = g : l.value.start = g : l.value = g, F();
|
|
1135
|
+
}, Ie = (g) => (g = _(g), e.range ? l.value.start && V(l.value.start) && g.getTime() === l.value.start.getTime() || l.value.end && V(l.value.end) && g.getTime() === l.value.end.getTime() : V(l.value) && g.getTime() === l.value.getTime()), Me = (g) => {
|
|
1136
|
+
g = _(g);
|
|
1126
1137
|
const h = /* @__PURE__ */ new Date();
|
|
1127
|
-
return
|
|
1128
|
-
},
|
|
1129
|
-
if (
|
|
1130
|
-
const h = l.value.start.getTime(),
|
|
1131
|
-
return
|
|
1138
|
+
return g.getDate() === h.getDate() && g.getMonth() === h.getMonth() && g.getFullYear() === h.getFullYear();
|
|
1139
|
+
}, De = (g) => (g = _(g), e.range && V(l.value.start) && g.getTime() === l.value.start.getTime()), Te = (g) => (g = _(g), e.range && V(l.value.end) && g.getTime() === l.value.end.getTime()), Ve = (g) => {
|
|
1140
|
+
if (g = _(g), e.range && V(l.value.start) && V(l.value.end)) {
|
|
1141
|
+
const h = l.value.start.getTime(), d = l.value.end.getTime(), G = g.getTime();
|
|
1142
|
+
return G > h && G < d;
|
|
1132
1143
|
}
|
|
1133
1144
|
return !1;
|
|
1134
1145
|
}, Be = () => {
|
|
1135
|
-
let
|
|
1136
|
-
|
|
1146
|
+
let g = I.value - 1;
|
|
1147
|
+
g < 0 && (g = 11, c.value--), b.value = T[g], F();
|
|
1137
1148
|
}, Oe = () => {
|
|
1138
|
-
let
|
|
1139
|
-
|
|
1140
|
-
}, be = (
|
|
1141
|
-
U.value && !U.value.contains(
|
|
1142
|
-
},
|
|
1143
|
-
let
|
|
1144
|
-
const h = (
|
|
1145
|
-
|
|
1146
|
-
const
|
|
1147
|
-
return
|
|
1149
|
+
let g = I.value + 1;
|
|
1150
|
+
g > 11 && (g = 0, c.value++), b.value = T[g], F();
|
|
1151
|
+
}, be = (g) => {
|
|
1152
|
+
U.value && !U.value.contains(g.target) && o.value == !0 && X();
|
|
1153
|
+
}, F = () => {
|
|
1154
|
+
let g = {};
|
|
1155
|
+
const h = (d, G, ie) => {
|
|
1156
|
+
d instanceof Date && !isNaN(d) || (d = /* @__PURE__ */ new Date());
|
|
1157
|
+
const ne = new Date(d);
|
|
1158
|
+
return ne.setUTCHours(G, ie, 0, 0), ne.toISOString();
|
|
1148
1159
|
};
|
|
1149
|
-
e.range ? (
|
|
1160
|
+
e.range ? (g.from = h(
|
|
1150
1161
|
l.value.start,
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
),
|
|
1162
|
+
m.value.start,
|
|
1163
|
+
k.value.start
|
|
1164
|
+
), g.to = h(
|
|
1154
1165
|
l.value.end,
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
)) :
|
|
1166
|
+
m.value.end,
|
|
1167
|
+
k.value.end
|
|
1168
|
+
)) : g = h(
|
|
1158
1169
|
l.value,
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
), t("updated",
|
|
1170
|
+
m.value,
|
|
1171
|
+
k.value
|
|
1172
|
+
), t("updated", g);
|
|
1162
1173
|
};
|
|
1163
|
-
return
|
|
1174
|
+
return ee(() => {
|
|
1164
1175
|
e.initialDate && (e.range && e.initialDate.start && e.initialDate.end ? l.value = {
|
|
1165
1176
|
start: new Date(e.initialDate.start),
|
|
1166
1177
|
end: new Date(e.initialDate.end)
|
|
1167
|
-
} : e.initialDate.start && (l.value = { start: new Date(e.initialDate.start) })), e.range ? (
|
|
1168
|
-
}), e.popup &&
|
|
1178
|
+
} : e.initialDate.start && (l.value = { start: new Date(e.initialDate.start) })), e.range ? (m.value.start = m.value.start ?? (/* @__PURE__ */ new Date()).getHours(), m.value.end = m.value.end ?? (/* @__PURE__ */ new Date()).getHours(), k.value.start = k.value.start ?? (/* @__PURE__ */ new Date()).getMinutes(), k.value.end = k.value.end ?? (/* @__PURE__ */ new Date()).getMinutes()) : (m.value = m.value ?? (/* @__PURE__ */ new Date()).getHours(), k.value = k.value ?? (/* @__PURE__ */ new Date()).getMinutes());
|
|
1179
|
+
}), e.popup && ee(() => document.addEventListener("click", be)), $e(() => document.removeEventListener("click", be)), (g, h) => (n(), a("div", {
|
|
1169
1180
|
class: "inline-block relative w-full lg:w-[360px]",
|
|
1170
1181
|
ref_key: "pickerContainer",
|
|
1171
1182
|
ref: U
|
|
1172
1183
|
}, [
|
|
1173
1184
|
s("div", {
|
|
1174
1185
|
class: "flex items-center gap-2 cursor-pointer",
|
|
1175
|
-
onClick: h[0] || (h[0] = (
|
|
1186
|
+
onClick: h[0] || (h[0] = (d) => e.disabled ? null : re())
|
|
1176
1187
|
}, [
|
|
1177
|
-
i.popup ?
|
|
1188
|
+
i.popup ? M(g.$slots, "default", { key: 0 }, () => [
|
|
1178
1189
|
s("input", {
|
|
1179
1190
|
type: "text",
|
|
1180
1191
|
class: "input-bordered w-full cursor-pointer input",
|
|
1181
1192
|
placeholder: i.placeholder,
|
|
1182
1193
|
value: J.value,
|
|
1183
1194
|
readonly: "",
|
|
1184
|
-
id:
|
|
1195
|
+
id: N.value,
|
|
1185
1196
|
disabled: e.disabled
|
|
1186
|
-
}, null, 8,
|
|
1197
|
+
}, null, 8, Nt),
|
|
1187
1198
|
s("button", {
|
|
1188
1199
|
class: "btn btn-ghost",
|
|
1189
1200
|
disabled: e.disabled
|
|
1190
1201
|
}, [
|
|
1191
|
-
|
|
1192
|
-
], 8,
|
|
1202
|
+
se(R(Ze))
|
|
1203
|
+
], 8, jt)
|
|
1193
1204
|
], !0) : O("", !0)
|
|
1194
1205
|
]),
|
|
1195
1206
|
o.value || !i.popup ? (n(), a("div", {
|
|
1196
1207
|
key: 0,
|
|
1197
|
-
class:
|
|
1198
|
-
id:
|
|
1208
|
+
class: D(["z-50 bg-base-100 md:mt-2 md:p-4 px-4 rounded-md w-full", [{ absolute: i.popup }]]),
|
|
1209
|
+
id: f.value
|
|
1199
1210
|
}, [
|
|
1200
|
-
|
|
1211
|
+
w.value ? (n(), a("div", qt, [
|
|
1201
1212
|
s("button", {
|
|
1202
1213
|
class: "hidden md:block btn-outline btn btn-primary md:btn-sm",
|
|
1203
1214
|
onClick: Be,
|
|
@@ -1217,30 +1228,30 @@ const tt = oe("SunIcon", [
|
|
|
1217
1228
|
d: "M15 19l-7-7 7-7"
|
|
1218
1229
|
})
|
|
1219
1230
|
], -1)
|
|
1220
|
-
]), 8,
|
|
1231
|
+
]), 8, Ht),
|
|
1221
1232
|
q(s("select", {
|
|
1222
1233
|
class: "border-none w-fit select",
|
|
1223
|
-
"onUpdate:modelValue": h[1] || (h[1] = (
|
|
1224
|
-
onChange:
|
|
1234
|
+
"onUpdate:modelValue": h[1] || (h[1] = (d) => b.value = d),
|
|
1235
|
+
onChange: F
|
|
1225
1236
|
}, [
|
|
1226
|
-
(n(), a(B, null,
|
|
1227
|
-
key:
|
|
1228
|
-
value:
|
|
1229
|
-
}, C(
|
|
1237
|
+
(n(), a(B, null, P(T, (d, G) => s("option", {
|
|
1238
|
+
key: G,
|
|
1239
|
+
value: d
|
|
1240
|
+
}, C(d), 9, Wt)), 64))
|
|
1230
1241
|
], 544), [
|
|
1231
|
-
[Z,
|
|
1242
|
+
[Z, b.value]
|
|
1232
1243
|
]),
|
|
1233
1244
|
q(s("select", {
|
|
1234
1245
|
class: "border-none w-24 select",
|
|
1235
|
-
"onUpdate:modelValue": h[2] || (h[2] = (
|
|
1236
|
-
onChange:
|
|
1246
|
+
"onUpdate:modelValue": h[2] || (h[2] = (d) => c.value = d),
|
|
1247
|
+
onChange: F
|
|
1237
1248
|
}, [
|
|
1238
|
-
(n(!0), a(B, null,
|
|
1239
|
-
key:
|
|
1240
|
-
value:
|
|
1241
|
-
}, C(
|
|
1249
|
+
(n(!0), a(B, null, P(u.value, (d) => (n(), a("option", {
|
|
1250
|
+
key: d,
|
|
1251
|
+
value: d
|
|
1252
|
+
}, C(d), 9, Kt))), 128))
|
|
1242
1253
|
], 544), [
|
|
1243
|
-
[Z,
|
|
1254
|
+
[Z, c.value]
|
|
1244
1255
|
]),
|
|
1245
1256
|
s("button", {
|
|
1246
1257
|
class: "hidden md:block btn-outline btn btn-primary md:btn-sm",
|
|
@@ -1262,71 +1273,71 @@ const tt = oe("SunIcon", [
|
|
|
1262
1273
|
], -1)
|
|
1263
1274
|
]))
|
|
1264
1275
|
])) : O("", !0),
|
|
1265
|
-
|
|
1266
|
-
(n(), a(B, null,
|
|
1267
|
-
key:
|
|
1276
|
+
w.value ? (n(), a("div", Yt, [
|
|
1277
|
+
(n(), a(B, null, P(z, (d) => s("div", {
|
|
1278
|
+
key: d,
|
|
1268
1279
|
class: "text-center"
|
|
1269
|
-
}, C(
|
|
1270
|
-
(n(!0), a(B, null,
|
|
1271
|
-
key:
|
|
1280
|
+
}, C(d), 1)), 64)),
|
|
1281
|
+
(n(!0), a(B, null, P(Y.value, (d) => (n(), a("div", {
|
|
1282
|
+
key: d,
|
|
1272
1283
|
class: "text-center"
|
|
1273
1284
|
}))), 128)),
|
|
1274
|
-
(n(!0), a(B, null,
|
|
1275
|
-
key:
|
|
1276
|
-
class:
|
|
1277
|
-
"bg-primary text-primary-content":
|
|
1278
|
-
today:
|
|
1279
|
-
"range-start bg-primary text-primary-content":
|
|
1280
|
-
"range-end bg-primary text-primary-content": Te(
|
|
1281
|
-
"in-range bg-primary/20 hover:bg-primary/10": Ve(
|
|
1285
|
+
(n(!0), a(B, null, P(W.value, (d) => (n(), a("div", {
|
|
1286
|
+
key: d,
|
|
1287
|
+
class: D(["hover:bg-primary-10 py-1 rounded-full text-center cursor-pointer", {
|
|
1288
|
+
"bg-primary text-primary-content": Ie(d),
|
|
1289
|
+
today: Me(d),
|
|
1290
|
+
"range-start bg-primary text-primary-content": De(d),
|
|
1291
|
+
"range-end bg-primary text-primary-content": Te(d),
|
|
1292
|
+
"in-range bg-primary/20 hover:bg-primary/10": Ve(d)
|
|
1282
1293
|
}]),
|
|
1283
|
-
onClick: (
|
|
1284
|
-
}, C(
|
|
1294
|
+
onClick: (G) => Ce(d)
|
|
1295
|
+
}, C(d.getDate()), 11, Jt))), 128))
|
|
1285
1296
|
])) : O("", !0),
|
|
1286
|
-
|
|
1297
|
+
$.value ? (n(), a("div", Xt, [
|
|
1287
1298
|
e.range ? O("", !0) : (n(), a("h3", Gt, "Select Time")),
|
|
1288
|
-
e.range ? (n(), a("div",
|
|
1299
|
+
e.range ? (n(), a("div", ll, [
|
|
1289
1300
|
s("div", null, [
|
|
1290
1301
|
h[14] || (h[14] = s("p", { class: "font-bold" }, "Start Time", -1)),
|
|
1291
1302
|
S.value ? q((n(), a("input", {
|
|
1292
1303
|
key: 0,
|
|
1293
1304
|
type: "time",
|
|
1294
1305
|
class: "input-bordered w-full input",
|
|
1295
|
-
"onUpdate:modelValue": h[6] || (h[6] = (
|
|
1296
|
-
onChange:
|
|
1306
|
+
"onUpdate:modelValue": h[6] || (h[6] = (d) => r.value.start = d),
|
|
1307
|
+
onChange: F
|
|
1297
1308
|
}, null, 544)), [
|
|
1298
|
-
[
|
|
1299
|
-
]) : (n(), a("div",
|
|
1309
|
+
[oe, r.value.start]
|
|
1310
|
+
]) : (n(), a("div", nl, [
|
|
1300
1311
|
q(s("select", {
|
|
1301
1312
|
class: "w-full select-bordered select",
|
|
1302
|
-
"onUpdate:modelValue": h[7] || (h[7] = (
|
|
1303
|
-
onChange:
|
|
1313
|
+
"onUpdate:modelValue": h[7] || (h[7] = (d) => m.value.start = d),
|
|
1314
|
+
onChange: F
|
|
1304
1315
|
}, [
|
|
1305
|
-
(n(!0), a(B, null,
|
|
1306
|
-
key:
|
|
1307
|
-
value:
|
|
1308
|
-
}, C(
|
|
1316
|
+
(n(!0), a(B, null, P(R(p), (d) => (n(), a("option", {
|
|
1317
|
+
key: d,
|
|
1318
|
+
value: d
|
|
1319
|
+
}, C(d.toString().padStart(2, "0")), 9, al))), 128))
|
|
1309
1320
|
], 544), [
|
|
1310
1321
|
[
|
|
1311
1322
|
Z,
|
|
1312
|
-
|
|
1323
|
+
m.value.start,
|
|
1313
1324
|
void 0,
|
|
1314
1325
|
{ number: !0 }
|
|
1315
1326
|
]
|
|
1316
1327
|
]),
|
|
1317
1328
|
q(s("select", {
|
|
1318
1329
|
class: "w-full select-bordered select",
|
|
1319
|
-
"onUpdate:modelValue": h[8] || (h[8] = (
|
|
1320
|
-
onChange:
|
|
1330
|
+
"onUpdate:modelValue": h[8] || (h[8] = (d) => k.value.start = d),
|
|
1331
|
+
onChange: F
|
|
1321
1332
|
}, [
|
|
1322
|
-
(n(!0), a(B, null,
|
|
1323
|
-
key:
|
|
1324
|
-
value:
|
|
1325
|
-
}, C(
|
|
1333
|
+
(n(!0), a(B, null, P(R(y), (d) => (n(), a("option", {
|
|
1334
|
+
key: d,
|
|
1335
|
+
value: d
|
|
1336
|
+
}, C(d.toString().padStart(2, "0")), 9, ol))), 128))
|
|
1326
1337
|
], 544), [
|
|
1327
1338
|
[
|
|
1328
1339
|
Z,
|
|
1329
|
-
|
|
1340
|
+
k.value.start,
|
|
1330
1341
|
void 0,
|
|
1331
1342
|
{ number: !0 }
|
|
1332
1343
|
]
|
|
@@ -1339,87 +1350,87 @@ const tt = oe("SunIcon", [
|
|
|
1339
1350
|
key: 0,
|
|
1340
1351
|
type: "time",
|
|
1341
1352
|
class: "input-bordered w-full input",
|
|
1342
|
-
"onUpdate:modelValue": h[9] || (h[9] = (
|
|
1343
|
-
onChange:
|
|
1353
|
+
"onUpdate:modelValue": h[9] || (h[9] = (d) => r.value.end = d),
|
|
1354
|
+
onChange: F
|
|
1344
1355
|
}, null, 544)), [
|
|
1345
|
-
[
|
|
1346
|
-
]) : (n(), a("div",
|
|
1356
|
+
[oe, r.value.end]
|
|
1357
|
+
]) : (n(), a("div", sl, [
|
|
1347
1358
|
q(s("select", {
|
|
1348
1359
|
class: "w-full select-bordered select",
|
|
1349
|
-
"onUpdate:modelValue": h[10] || (h[10] = (
|
|
1350
|
-
onChange:
|
|
1360
|
+
"onUpdate:modelValue": h[10] || (h[10] = (d) => m.value.end = d),
|
|
1361
|
+
onChange: F
|
|
1351
1362
|
}, [
|
|
1352
|
-
(n(!0), a(B, null,
|
|
1353
|
-
key:
|
|
1354
|
-
value:
|
|
1355
|
-
}, C(
|
|
1363
|
+
(n(!0), a(B, null, P(R(p), (d) => (n(), a("option", {
|
|
1364
|
+
key: d,
|
|
1365
|
+
value: d
|
|
1366
|
+
}, C(d.toString().padStart(2, "0")), 9, rl))), 128))
|
|
1356
1367
|
], 544), [
|
|
1357
1368
|
[
|
|
1358
1369
|
Z,
|
|
1359
|
-
|
|
1370
|
+
m.value.end,
|
|
1360
1371
|
void 0,
|
|
1361
1372
|
{ number: !0 }
|
|
1362
1373
|
]
|
|
1363
1374
|
]),
|
|
1364
1375
|
q(s("select", {
|
|
1365
1376
|
class: "w-full select-bordered select",
|
|
1366
|
-
"onUpdate:modelValue": h[11] || (h[11] = (
|
|
1367
|
-
onChange:
|
|
1377
|
+
"onUpdate:modelValue": h[11] || (h[11] = (d) => k.value.end = d),
|
|
1378
|
+
onChange: F
|
|
1368
1379
|
}, [
|
|
1369
|
-
(n(!0), a(B, null,
|
|
1370
|
-
key:
|
|
1371
|
-
value:
|
|
1372
|
-
}, C(
|
|
1380
|
+
(n(!0), a(B, null, P(R(y), (d) => (n(), a("option", {
|
|
1381
|
+
key: d,
|
|
1382
|
+
value: d
|
|
1383
|
+
}, C(d.toString().padStart(2, "0")), 9, il))), 128))
|
|
1373
1384
|
], 544), [
|
|
1374
1385
|
[
|
|
1375
1386
|
Z,
|
|
1376
|
-
|
|
1387
|
+
k.value.end,
|
|
1377
1388
|
void 0,
|
|
1378
1389
|
{ number: !0 }
|
|
1379
1390
|
]
|
|
1380
1391
|
])
|
|
1381
1392
|
]))
|
|
1382
1393
|
])
|
|
1383
|
-
])) : (n(), a("div",
|
|
1394
|
+
])) : (n(), a("div", Zt, [
|
|
1384
1395
|
S.value ? q((n(), a("input", {
|
|
1385
1396
|
key: 0,
|
|
1386
1397
|
type: "time",
|
|
1387
1398
|
class: "input-bordered w-full input",
|
|
1388
|
-
"onUpdate:modelValue": h[3] || (h[3] = (
|
|
1389
|
-
onChange:
|
|
1399
|
+
"onUpdate:modelValue": h[3] || (h[3] = (d) => r.value = d),
|
|
1400
|
+
onChange: F
|
|
1390
1401
|
}, null, 544)), [
|
|
1391
|
-
[
|
|
1392
|
-
]) : (n(), a("div",
|
|
1402
|
+
[oe, r.value]
|
|
1403
|
+
]) : (n(), a("div", Qt, [
|
|
1393
1404
|
q(s("select", {
|
|
1394
1405
|
class: "w-full select-bordered select",
|
|
1395
|
-
"onUpdate:modelValue": h[4] || (h[4] = (
|
|
1396
|
-
onChange:
|
|
1406
|
+
"onUpdate:modelValue": h[4] || (h[4] = (d) => m.value = d),
|
|
1407
|
+
onChange: F
|
|
1397
1408
|
}, [
|
|
1398
|
-
(n(!0), a(B, null,
|
|
1399
|
-
key:
|
|
1400
|
-
value:
|
|
1401
|
-
}, C(
|
|
1409
|
+
(n(!0), a(B, null, P(R(p), (d) => (n(), a("option", {
|
|
1410
|
+
key: d,
|
|
1411
|
+
value: d
|
|
1412
|
+
}, C(d.toString().padStart(2, "0")), 9, el))), 128))
|
|
1402
1413
|
], 544), [
|
|
1403
1414
|
[
|
|
1404
1415
|
Z,
|
|
1405
|
-
|
|
1416
|
+
m.value,
|
|
1406
1417
|
void 0,
|
|
1407
1418
|
{ number: !0 }
|
|
1408
1419
|
]
|
|
1409
1420
|
]),
|
|
1410
1421
|
q(s("select", {
|
|
1411
1422
|
class: "w-full select-bordered select",
|
|
1412
|
-
"onUpdate:modelValue": h[5] || (h[5] = (
|
|
1413
|
-
onChange:
|
|
1423
|
+
"onUpdate:modelValue": h[5] || (h[5] = (d) => k.value = d),
|
|
1424
|
+
onChange: F
|
|
1414
1425
|
}, [
|
|
1415
|
-
(n(!0), a(B, null,
|
|
1416
|
-
key:
|
|
1417
|
-
value:
|
|
1418
|
-
}, C(
|
|
1426
|
+
(n(!0), a(B, null, P(R(y), (d) => (n(), a("option", {
|
|
1427
|
+
key: d,
|
|
1428
|
+
value: d
|
|
1429
|
+
}, C(d.toString().padStart(2, "0")), 9, tl))), 128))
|
|
1419
1430
|
], 544), [
|
|
1420
1431
|
[
|
|
1421
1432
|
Z,
|
|
1422
|
-
|
|
1433
|
+
k.value,
|
|
1423
1434
|
void 0,
|
|
1424
1435
|
{ number: !0 }
|
|
1425
1436
|
]
|
|
@@ -1427,24 +1438,24 @@ const tt = oe("SunIcon", [
|
|
|
1427
1438
|
]))
|
|
1428
1439
|
]))
|
|
1429
1440
|
])) : O("", !0),
|
|
1430
|
-
s("div",
|
|
1441
|
+
s("div", ul, [
|
|
1431
1442
|
s("button", {
|
|
1432
|
-
class:
|
|
1443
|
+
class: D(["btn btn-secondary", i.popup ? "w-fit" : "w-full"]),
|
|
1433
1444
|
onClick: xe
|
|
1434
1445
|
}, " Clear ", 2),
|
|
1435
1446
|
i.popup ? (n(), a("button", {
|
|
1436
1447
|
key: 0,
|
|
1437
1448
|
class: "btn btn-primary btn-wide",
|
|
1438
|
-
onClick:
|
|
1449
|
+
onClick: X
|
|
1439
1450
|
}, " Close ")) : O("", !0)
|
|
1440
1451
|
])
|
|
1441
|
-
], 10,
|
|
1452
|
+
], 10, Ft)) : O("", !0)
|
|
1442
1453
|
], 512));
|
|
1443
1454
|
}
|
|
1444
|
-
},
|
|
1455
|
+
}, cl = /* @__PURE__ */ le(dl, [["__scopeId", "data-v-bab9b3c1"]]), pl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1445
1456
|
__proto__: null,
|
|
1446
|
-
default:
|
|
1447
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1457
|
+
default: cl
|
|
1458
|
+
}, Symbol.toStringTag, { value: "Module" })), vl = ["value", "checked", "onChange", "disabled"], In = /* @__PURE__ */ L({
|
|
1448
1459
|
__name: "rating",
|
|
1449
1460
|
props: {
|
|
1450
1461
|
initialRating: { default: 0 },
|
|
@@ -1457,9 +1468,9 @@ const tt = oe("SunIcon", [
|
|
|
1457
1468
|
gap: { default: 0 }
|
|
1458
1469
|
},
|
|
1459
1470
|
setup(i) {
|
|
1460
|
-
const
|
|
1471
|
+
const v = i, e = x(v.initialRating);
|
|
1461
1472
|
H(
|
|
1462
|
-
() =>
|
|
1473
|
+
() => v.initialRating,
|
|
1463
1474
|
(o) => {
|
|
1464
1475
|
e.value = o;
|
|
1465
1476
|
}
|
|
@@ -1468,19 +1479,19 @@ const tt = oe("SunIcon", [
|
|
|
1468
1479
|
e.value = o;
|
|
1469
1480
|
};
|
|
1470
1481
|
return (o, l) => (n(), a("div", {
|
|
1471
|
-
class:
|
|
1472
|
-
`rating-${
|
|
1482
|
+
class: D(["rating", [
|
|
1483
|
+
`rating-${v.size}`,
|
|
1473
1484
|
{ "rating-half": o.halfStars },
|
|
1474
1485
|
{ "pointer-events-none": !o.isInteractive }
|
|
1475
1486
|
]])
|
|
1476
1487
|
}, [
|
|
1477
|
-
(n(!0), a(B, null,
|
|
1488
|
+
(n(!0), a(B, null, P(o.numberOfStars * (o.halfStars ? 2 : 1), (r) => (n(), a("input", {
|
|
1478
1489
|
key: r,
|
|
1479
1490
|
type: "radio",
|
|
1480
1491
|
value: o.halfStars ? r * 0.5 : r,
|
|
1481
1492
|
checked: e.value === (o.halfStars ? r * 0.5 : r),
|
|
1482
|
-
onChange: (
|
|
1483
|
-
class:
|
|
1493
|
+
onChange: (b) => o.isInteractive ? t(o.halfStars ? r * 0.5 : r) : null,
|
|
1494
|
+
class: D(["mask", [
|
|
1484
1495
|
{
|
|
1485
1496
|
// 'bg-yellow-400': rating >= (halfStars ? i * 0.5 : i),
|
|
1486
1497
|
"mask-half-1": o.halfStars && r % 2 !== 0,
|
|
@@ -1501,16 +1512,16 @@ const tt = oe("SunIcon", [
|
|
|
1501
1512
|
"mask-triangle-3": o.shape === "triangle-left",
|
|
1502
1513
|
"mask-triangle-4": o.shape === "triangle-right"
|
|
1503
1514
|
},
|
|
1504
|
-
e.value >= (o.halfStars ? r * 0.5 : r) ?
|
|
1515
|
+
e.value >= (o.halfStars ? r * 0.5 : r) ? v.color : ""
|
|
1505
1516
|
]]),
|
|
1506
1517
|
style: de({
|
|
1507
|
-
marginRight: o.halfStars && r % 2 === 0 ? `${
|
|
1518
|
+
marginRight: o.halfStars && r % 2 === 0 ? `${v.gap}px` : o.halfStars ? "0" : `${v.gap}px`
|
|
1508
1519
|
}),
|
|
1509
1520
|
disabled: !o.isInteractive
|
|
1510
|
-
}, null, 46,
|
|
1521
|
+
}, null, 46, vl))), 128))
|
|
1511
1522
|
], 2));
|
|
1512
1523
|
}
|
|
1513
|
-
}),
|
|
1524
|
+
}), fl = { class: "badge" }, ml = ["onClick"], gl = { class: "opacity-75" }, hl = ["placeholder"], Mn = /* @__PURE__ */ L({
|
|
1514
1525
|
__name: "taginput",
|
|
1515
1526
|
props: {
|
|
1516
1527
|
modelValue: {},
|
|
@@ -1519,61 +1530,61 @@ const tt = oe("SunIcon", [
|
|
|
1519
1530
|
class: {}
|
|
1520
1531
|
},
|
|
1521
1532
|
emits: ["update:modelValue"],
|
|
1522
|
-
setup(i, { emit:
|
|
1523
|
-
const e = i, t =
|
|
1524
|
-
const
|
|
1525
|
-
|
|
1526
|
-
},
|
|
1527
|
-
o.value = o.value.filter((
|
|
1533
|
+
setup(i, { emit: v }) {
|
|
1534
|
+
const e = i, t = v, o = x([...e.modelValue]), l = e.maxTagAmount === void 0 ? -1 : e.maxTagAmount, r = x(null), b = x(""), c = E(() => l < 0 || o.value.length < l), m = () => {
|
|
1535
|
+
const f = b.value.trim();
|
|
1536
|
+
f && !o.value.includes(f) && (o.value.push(f), t("update:modelValue", o.value), b.value = "");
|
|
1537
|
+
}, k = (f) => {
|
|
1538
|
+
o.value = o.value.filter((w) => w !== f), t("update:modelValue", o.value);
|
|
1528
1539
|
}, U = () => {
|
|
1529
|
-
|
|
1530
|
-
},
|
|
1531
|
-
|
|
1540
|
+
b.value === "" && (o.value.pop(), t("update:modelValue", o.value));
|
|
1541
|
+
}, N = (f) => {
|
|
1542
|
+
f.key === "Enter" ? m() : f.key === "Backspace" && b.value === "" && U();
|
|
1532
1543
|
};
|
|
1533
|
-
return H(() => e.modelValue, (
|
|
1534
|
-
o.value = [...
|
|
1535
|
-
}), (
|
|
1536
|
-
class:
|
|
1544
|
+
return H(() => e.modelValue, (f) => {
|
|
1545
|
+
o.value = [...f];
|
|
1546
|
+
}), (f, w) => (n(), a("div", {
|
|
1547
|
+
class: D(["flex flex-wrap gap-2 bg-base-100 shadow px-4 py-6 border border-base-content/20 rounded", f.$props.class])
|
|
1537
1548
|
}, [
|
|
1538
|
-
(n(!0), a(B, null,
|
|
1539
|
-
key:
|
|
1540
|
-
tag:
|
|
1549
|
+
(n(!0), a(B, null, P(o.value, ($) => M(f.$slots, "tag", {
|
|
1550
|
+
key: $,
|
|
1551
|
+
tag: $
|
|
1541
1552
|
}, () => [
|
|
1542
|
-
s("div",
|
|
1553
|
+
s("div", fl, [
|
|
1543
1554
|
s("button", {
|
|
1544
1555
|
class: "!px-1 !py-0 h-fit font-bold cursor-pointer",
|
|
1545
|
-
onClick: (
|
|
1556
|
+
onClick: (I) => k($),
|
|
1546
1557
|
"aria-label": "Remove tag"
|
|
1547
|
-
}, "X", 8,
|
|
1548
|
-
s("span",
|
|
1558
|
+
}, "X", 8, ml),
|
|
1559
|
+
s("span", gl, C($), 1)
|
|
1549
1560
|
])
|
|
1550
1561
|
])), 128)),
|
|
1551
|
-
|
|
1552
|
-
|
|
1562
|
+
M(f.$slots, "input", { showInput: c.value }, () => [
|
|
1563
|
+
c.value ? q((n(), a("input", {
|
|
1553
1564
|
key: 0,
|
|
1554
1565
|
ref_key: "inputRef",
|
|
1555
1566
|
ref: r,
|
|
1556
|
-
"onUpdate:modelValue":
|
|
1567
|
+
"onUpdate:modelValue": w[0] || (w[0] = ($) => b.value = $),
|
|
1557
1568
|
type: "text",
|
|
1558
|
-
placeholder:
|
|
1569
|
+
placeholder: f.placeholder || "Type here",
|
|
1559
1570
|
class: "h-full input input-ghost",
|
|
1560
|
-
onKeydown:
|
|
1571
|
+
onKeydown: N,
|
|
1561
1572
|
"aria-label": "Add tags"
|
|
1562
|
-
}, null, 40,
|
|
1563
|
-
[
|
|
1573
|
+
}, null, 40, hl)), [
|
|
1574
|
+
[oe, b.value]
|
|
1564
1575
|
]) : O("", !0)
|
|
1565
1576
|
])
|
|
1566
1577
|
], 2));
|
|
1567
1578
|
}
|
|
1568
|
-
}),
|
|
1579
|
+
}), bl = { class: "w-full max-w-xs form-control" }, yl = {
|
|
1569
1580
|
key: 0,
|
|
1570
1581
|
class: "label"
|
|
1571
|
-
},
|
|
1582
|
+
}, wl = { class: "label-text" }, kl = ["value"], $l = {
|
|
1572
1583
|
key: 0,
|
|
1573
1584
|
value: "",
|
|
1574
1585
|
disabled: "",
|
|
1575
1586
|
selected: ""
|
|
1576
|
-
},
|
|
1587
|
+
}, _l = ["value"], Dn = /* @__PURE__ */ L({
|
|
1577
1588
|
__name: "select",
|
|
1578
1589
|
props: {
|
|
1579
1590
|
options: {},
|
|
@@ -1582,45 +1593,45 @@ const tt = oe("SunIcon", [
|
|
|
1582
1593
|
modelValue: {}
|
|
1583
1594
|
},
|
|
1584
1595
|
emits: ["update:modelValue"],
|
|
1585
|
-
setup(i, { expose:
|
|
1596
|
+
setup(i, { expose: v, emit: e }) {
|
|
1586
1597
|
console.log(i.placeholder);
|
|
1587
|
-
const o = e, l = x(null), r = (
|
|
1588
|
-
const
|
|
1589
|
-
o("update:modelValue",
|
|
1598
|
+
const o = e, l = x(null), r = (c) => {
|
|
1599
|
+
const m = c.target;
|
|
1600
|
+
o("update:modelValue", m.value);
|
|
1590
1601
|
};
|
|
1591
|
-
return
|
|
1602
|
+
return v({
|
|
1592
1603
|
focusInput: () => {
|
|
1593
|
-
var
|
|
1594
|
-
console.log("select.vue: focusInput method called."), (
|
|
1604
|
+
var c;
|
|
1605
|
+
console.log("select.vue: focusInput method called."), (c = l.value) == null || c.focus();
|
|
1595
1606
|
}
|
|
1596
1607
|
// You can expose other properties or methods here if needed by the parent
|
|
1597
1608
|
// e.g., the current value: modelValue
|
|
1598
|
-
}), (
|
|
1599
|
-
|
|
1600
|
-
s("span",
|
|
1609
|
+
}), (c, m) => (n(), a("div", bl, [
|
|
1610
|
+
c.label ? (n(), a("label", yl, [
|
|
1611
|
+
s("span", wl, C(c.label), 1)
|
|
1601
1612
|
])) : O("", !0),
|
|
1602
1613
|
s("select", {
|
|
1603
1614
|
ref_key: "selectElement",
|
|
1604
1615
|
ref: l,
|
|
1605
1616
|
class: "rounded-md w-full select-bordered select",
|
|
1606
|
-
value:
|
|
1617
|
+
value: c.modelValue,
|
|
1607
1618
|
onChange: r
|
|
1608
1619
|
}, [
|
|
1609
|
-
|
|
1610
|
-
(n(!0), a(B, null,
|
|
1611
|
-
key:
|
|
1612
|
-
value:
|
|
1613
|
-
}, C(
|
|
1614
|
-
], 40,
|
|
1620
|
+
c.placeholder ? (n(), a("option", $l, C(c.placeholder), 1)) : O("", !0),
|
|
1621
|
+
(n(!0), a(B, null, P(c.options, (k) => (n(), a("option", {
|
|
1622
|
+
key: k.value,
|
|
1623
|
+
value: k.value
|
|
1624
|
+
}, C(k.text), 9, _l))), 128))
|
|
1625
|
+
], 40, kl)
|
|
1615
1626
|
]));
|
|
1616
1627
|
}
|
|
1617
|
-
}),
|
|
1628
|
+
}), Sl = {
|
|
1618
1629
|
key: 0,
|
|
1619
1630
|
class: "label"
|
|
1620
|
-
},
|
|
1631
|
+
}, xl = { class: "label-text" }, Cl = ["onKeydown", "aria-expanded", "aria-activedescendant"], Il = ["placeholder", "disabled"], Ml = {
|
|
1621
1632
|
class: "top-full z-10 absolute bg-base-100 shadow-lg mt-1 rounded-md w-full dropdown-content",
|
|
1622
1633
|
role: "listbox"
|
|
1623
|
-
}, Dl = { class: "flex-nowrap p-0 w-[inherit] max-h-60 overflow-y-auto menu" },
|
|
1634
|
+
}, Dl = { class: "flex-nowrap p-0 w-[inherit] max-h-60 overflow-y-auto menu" }, Tl = ["onMousedown", "id", "aria-selected"], Tn = {
|
|
1624
1635
|
__name: "filterableSelect",
|
|
1625
1636
|
props: {
|
|
1626
1637
|
// Array of options: [{ value: any, text: string }, ...]
|
|
@@ -1649,183 +1660,193 @@ const tt = oe("SunIcon", [
|
|
|
1649
1660
|
default: !1
|
|
1650
1661
|
}
|
|
1651
1662
|
},
|
|
1652
|
-
emits: ["update:modelValue", "select"],
|
|
1653
|
-
setup(i, { expose:
|
|
1663
|
+
emits: ["update:modelValue", "select", "clear"],
|
|
1664
|
+
setup(i, { expose: v, emit: e }) {
|
|
1654
1665
|
const t = i, o = e, l = Ue(), r = E(() => {
|
|
1655
|
-
const
|
|
1656
|
-
return console.log("hasDefaultSlotContent computed:",
|
|
1657
|
-
}),
|
|
1658
|
-
|
|
1659
|
-
},
|
|
1660
|
-
|
|
1661
|
-
},
|
|
1662
|
-
|
|
1666
|
+
const A = (l.default ? l.default() : []).filter((_) => _.type !== Re);
|
|
1667
|
+
return console.log("hasDefaultSlotContent computed:", A.length > 0), A.length > 0;
|
|
1668
|
+
}), b = x(""), c = x(null), m = x(!1), k = x(null), U = x(null), N = x(null), f = x(null), w = () => {
|
|
1669
|
+
m.value = !t.disabled;
|
|
1670
|
+
}, $ = () => {
|
|
1671
|
+
m.value = !1, f.value = null, r.value || (c.value && b.value !== c.value.text ? b.value = c.value.text : c.value || (b.value = ""));
|
|
1672
|
+
}, I = () => {
|
|
1673
|
+
m.value ? $() : w();
|
|
1663
1674
|
}, z = E(() => {
|
|
1664
|
-
const
|
|
1665
|
-
return
|
|
1666
|
-
(
|
|
1675
|
+
const u = b.value.toLowerCase();
|
|
1676
|
+
return u === "" && !m.value ? [] : t.options.filter(
|
|
1677
|
+
(_) => _.text.toLowerCase().includes(u)
|
|
1667
1678
|
);
|
|
1668
1679
|
});
|
|
1669
1680
|
H(
|
|
1670
1681
|
() => t.modelValue,
|
|
1671
|
-
(
|
|
1672
|
-
if (
|
|
1673
|
-
|
|
1682
|
+
(u, A) => {
|
|
1683
|
+
if (u !== A && $(), u == null)
|
|
1684
|
+
c.value = null, !m.value && !r.value && (b.value = "");
|
|
1674
1685
|
else {
|
|
1675
|
-
const
|
|
1676
|
-
|
|
1686
|
+
const _ = t.options.find((V) => V.value === u);
|
|
1687
|
+
_ ? (c.value = _, !m.value && !r.value && (b.value = _.text)) : (c.value = null, !m.value && !r.value && (b.value = ""));
|
|
1677
1688
|
}
|
|
1678
1689
|
},
|
|
1679
1690
|
{ immediate: !0 }
|
|
1680
1691
|
// Run immediately on component mount
|
|
1681
1692
|
);
|
|
1682
|
-
const
|
|
1683
|
-
U.value && !U.value.contains(
|
|
1684
|
-
},
|
|
1693
|
+
const j = (u) => {
|
|
1694
|
+
U.value && !U.value.contains(u.target) && $();
|
|
1695
|
+
}, W = () => {
|
|
1685
1696
|
setTimeout(() => {
|
|
1686
|
-
U.value && !U.value.contains(document.activeElement) &&
|
|
1697
|
+
U.value && !U.value.contains(document.activeElement) && $();
|
|
1687
1698
|
}, 100);
|
|
1688
1699
|
};
|
|
1689
|
-
H(
|
|
1690
|
-
|
|
1691
|
-
document.addEventListener("click",
|
|
1692
|
-
}, 0) : document.removeEventListener("click",
|
|
1700
|
+
H(m, (u) => {
|
|
1701
|
+
u ? setTimeout(() => {
|
|
1702
|
+
document.addEventListener("click", j);
|
|
1703
|
+
}, 0) : document.removeEventListener("click", j);
|
|
1693
1704
|
}), ge(() => {
|
|
1694
|
-
document.removeEventListener("click",
|
|
1705
|
+
document.removeEventListener("click", j), window.removeEventListener("keydown", T);
|
|
1695
1706
|
});
|
|
1696
|
-
const
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
},
|
|
1701
|
-
|
|
1702
|
-
},
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1707
|
+
const Y = () => {
|
|
1708
|
+
if (t.disabled) return;
|
|
1709
|
+
const u = c.value;
|
|
1710
|
+
o("update:modelValue", null), u && o("clear", u);
|
|
1711
|
+
}, p = (u) => {
|
|
1712
|
+
c.value = u, r.value || (b.value = u.text), o("update:modelValue", u.value), o("select", u), $();
|
|
1713
|
+
}, y = () => {
|
|
1714
|
+
z.value.length > 0 && p(z.value[0]);
|
|
1715
|
+
}, S = () => {
|
|
1716
|
+
m.value || w();
|
|
1717
|
+
}, T = (u) => {
|
|
1718
|
+
if (!m.value || z.value.length === 0) return;
|
|
1719
|
+
const A = z.value.findIndex(
|
|
1720
|
+
(V, K) => "option-" + K === f.value
|
|
1706
1721
|
);
|
|
1707
|
-
let
|
|
1708
|
-
if (
|
|
1709
|
-
|
|
1710
|
-
else if (
|
|
1711
|
-
|
|
1712
|
-
else if (
|
|
1713
|
-
|
|
1714
|
-
const
|
|
1715
|
-
(
|
|
1722
|
+
let _ = -1;
|
|
1723
|
+
if (u.key === "ArrowDown")
|
|
1724
|
+
u.preventDefault(), _ = (A + 1) % z.value.length;
|
|
1725
|
+
else if (u.key === "ArrowUp")
|
|
1726
|
+
u.preventDefault(), _ = (A - 1 + z.value.length) % z.value.length;
|
|
1727
|
+
else if (u.key === "Enter" && f.value) {
|
|
1728
|
+
u.preventDefault();
|
|
1729
|
+
const V = z.value.find(
|
|
1730
|
+
(K, J) => "option-" + J === f.value
|
|
1716
1731
|
);
|
|
1717
|
-
|
|
1732
|
+
V && p(V);
|
|
1718
1733
|
return;
|
|
1719
|
-
} else if (
|
|
1720
|
-
|
|
1734
|
+
} else if (u.key === "Escape") {
|
|
1735
|
+
u.preventDefault(), $(), N.value && N.value.focus();
|
|
1721
1736
|
return;
|
|
1722
1737
|
} else if (r.value)
|
|
1723
1738
|
return;
|
|
1724
|
-
if (
|
|
1725
|
-
|
|
1726
|
-
const
|
|
1727
|
-
|
|
1728
|
-
|
|
1739
|
+
if (_ !== -1) {
|
|
1740
|
+
f.value = "option-" + _;
|
|
1741
|
+
const V = document.getElementById(f.value);
|
|
1742
|
+
V && requestAnimationFrame(() => {
|
|
1743
|
+
V.scrollIntoView({ block: "nearest", behavior: "smooth" });
|
|
1729
1744
|
});
|
|
1730
1745
|
}
|
|
1731
1746
|
};
|
|
1732
|
-
return H(
|
|
1733
|
-
|
|
1747
|
+
return H(m, (u) => {
|
|
1748
|
+
u ? (window.addEventListener("keydown", T), !r.value && !b.value && c.value && (b.value = c.value.text)) : window.removeEventListener("keydown", T);
|
|
1734
1749
|
}), ge(() => {
|
|
1735
|
-
document.removeEventListener("click",
|
|
1736
|
-
}),
|
|
1737
|
-
isDropdownOpen:
|
|
1750
|
+
document.removeEventListener("click", j), window.removeEventListener("keydown", T);
|
|
1751
|
+
}), v({
|
|
1752
|
+
isDropdownOpen: m,
|
|
1738
1753
|
// Expose state
|
|
1739
|
-
selectedItem:
|
|
1754
|
+
selectedItem: c,
|
|
1740
1755
|
// Expose selected item
|
|
1741
|
-
openDropdown:
|
|
1756
|
+
openDropdown: w,
|
|
1742
1757
|
// Expose method to open
|
|
1743
|
-
closeDropdown:
|
|
1758
|
+
closeDropdown: $,
|
|
1744
1759
|
// Expose method to close
|
|
1745
|
-
toggleDropdown:
|
|
1760
|
+
toggleDropdown: I,
|
|
1746
1761
|
// Expose method to toggle
|
|
1747
|
-
selectItem:
|
|
1762
|
+
selectItem: p,
|
|
1748
1763
|
// Expose method to select an item programmatically
|
|
1749
|
-
filterText:
|
|
1764
|
+
filterText: b,
|
|
1750
1765
|
// Expose filter text (useful if parent controls filtering)
|
|
1751
1766
|
hasDefaultSlotContent: r
|
|
1752
1767
|
// Expose to know if the default slot is used
|
|
1753
|
-
}), (
|
|
1768
|
+
}), (u, A) => (n(), a("div", {
|
|
1754
1769
|
class: "relative w-full max-w-xs form-control",
|
|
1755
1770
|
ref_key: "componentRoot",
|
|
1756
1771
|
ref: U
|
|
1757
1772
|
}, [
|
|
1758
|
-
i.label ? (n(), a("label",
|
|
1759
|
-
s("span",
|
|
1773
|
+
i.label ? (n(), a("label", Sl, [
|
|
1774
|
+
s("span", xl, C(i.label), 1)
|
|
1760
1775
|
])) : O("", !0),
|
|
1761
1776
|
s("div", {
|
|
1762
|
-
class:
|
|
1777
|
+
class: D(["flex items-center input-bordered rounded-md w-fit cursor-pointer", { input: !r.value, select: !r.value }]),
|
|
1763
1778
|
tabindex: "0",
|
|
1764
|
-
onClick:
|
|
1779
|
+
onClick: A[1] || (A[1] = (_) => r.value ? I() : w()),
|
|
1765
1780
|
onKeydown: [
|
|
1766
|
-
he(
|
|
1767
|
-
he(
|
|
1781
|
+
he(Q(y, ["prevent"]), ["enter"]),
|
|
1782
|
+
he(Q(y, ["prevent"]), ["space"])
|
|
1768
1783
|
],
|
|
1769
|
-
onBlur:
|
|
1784
|
+
onBlur: W,
|
|
1770
1785
|
role: "combobox",
|
|
1771
1786
|
"aria-haspopup": "listbox",
|
|
1772
|
-
"aria-expanded":
|
|
1773
|
-
"aria-activedescendant":
|
|
1787
|
+
"aria-expanded": m.value,
|
|
1788
|
+
"aria-activedescendant": f.value,
|
|
1774
1789
|
"aria-autocomplete": "list",
|
|
1775
1790
|
ref_key: "activatorWrapper",
|
|
1776
|
-
ref:
|
|
1791
|
+
ref: N
|
|
1777
1792
|
}, [
|
|
1778
|
-
|
|
1793
|
+
M(u.$slots, "default", {}, () => [
|
|
1779
1794
|
r.value ? O("", !0) : q((n(), a("input", {
|
|
1780
1795
|
key: 0,
|
|
1781
1796
|
type: "text",
|
|
1782
1797
|
placeholder: i.placeholder,
|
|
1783
1798
|
class: "bg-transparent border-none focus:outline-none w-full",
|
|
1784
|
-
"onUpdate:modelValue":
|
|
1799
|
+
"onUpdate:modelValue": A[0] || (A[0] = (_) => b.value = _),
|
|
1785
1800
|
ref_key: "filterInput",
|
|
1786
|
-
ref:
|
|
1787
|
-
onFocus:
|
|
1788
|
-
onInput:
|
|
1801
|
+
ref: k,
|
|
1802
|
+
onFocus: w,
|
|
1803
|
+
onInput: S,
|
|
1789
1804
|
tabindex: "-1",
|
|
1790
1805
|
disabled: t.disabled
|
|
1791
|
-
}, null, 40,
|
|
1792
|
-
[
|
|
1806
|
+
}, null, 40, Il)), [
|
|
1807
|
+
[oe, b.value]
|
|
1793
1808
|
])
|
|
1794
1809
|
]),
|
|
1795
|
-
|
|
1810
|
+
c.value && !i.disabled ? (n(), ae(R(et), {
|
|
1796
1811
|
key: 0,
|
|
1797
|
-
|
|
1812
|
+
size: 20,
|
|
1813
|
+
class: "mx-2 text-base-content/50 hover:text-base-content/80 cursor-pointer",
|
|
1814
|
+
onClick: Q(Y, ["stop"])
|
|
1815
|
+
})) : O("", !0),
|
|
1816
|
+
r.value && !c.value ? (n(), ae(R(Qe), {
|
|
1817
|
+
key: 1,
|
|
1818
|
+
class: D([{ "rotate-180": m.value }, "mx-2"]),
|
|
1798
1819
|
size: 20
|
|
1799
1820
|
}, null, 8, ["class"])) : O("", !0)
|
|
1800
|
-
], 42,
|
|
1821
|
+
], 42, Cl),
|
|
1801
1822
|
q(s("div", Ml, [
|
|
1802
1823
|
s("ul", Dl, [
|
|
1803
|
-
(n(!0), a(B, null,
|
|
1804
|
-
key:
|
|
1805
|
-
onMousedown:
|
|
1824
|
+
(n(!0), a(B, null, P(z.value, (_, V) => (n(), a("li", {
|
|
1825
|
+
key: _.value,
|
|
1826
|
+
onMousedown: Q((K) => p(_), ["prevent"]),
|
|
1806
1827
|
class: "hover:bg-base-200 rounded-md w-full cursor-pointer",
|
|
1807
|
-
id: "option-" +
|
|
1828
|
+
id: "option-" + V,
|
|
1808
1829
|
role: "option",
|
|
1809
|
-
"aria-selected":
|
|
1830
|
+
"aria-selected": c.value && c.value.value === _.value
|
|
1810
1831
|
}, [
|
|
1811
|
-
s("a", null, C(
|
|
1812
|
-
], 40,
|
|
1832
|
+
s("a", null, C(_.text), 1)
|
|
1833
|
+
], 40, Tl))), 128))
|
|
1813
1834
|
])
|
|
1814
1835
|
], 512), [
|
|
1815
|
-
[Ne,
|
|
1836
|
+
[Ne, m.value && z.value.length > 0]
|
|
1816
1837
|
])
|
|
1817
1838
|
], 512));
|
|
1818
1839
|
}
|
|
1819
|
-
},
|
|
1840
|
+
}, Vl = { class: "w-full max-w-xs form-control" }, Bl = {
|
|
1820
1841
|
key: 0,
|
|
1821
1842
|
class: "label"
|
|
1822
|
-
},
|
|
1843
|
+
}, Ol = { class: "label-text" }, zl = ["type", "placeholder", "disabled", "value"], Al = {
|
|
1823
1844
|
key: 1,
|
|
1824
1845
|
class: "label"
|
|
1825
|
-
},
|
|
1846
|
+
}, Pl = { class: "label-text-alt text-error validator-hint" }, El = {
|
|
1826
1847
|
key: 2,
|
|
1827
1848
|
class: "label"
|
|
1828
|
-
},
|
|
1849
|
+
}, Ll = { class: "label-text-alt text-success validator-hint" }, Vn = /* @__PURE__ */ L({
|
|
1829
1850
|
__name: "inputField",
|
|
1830
1851
|
props: {
|
|
1831
1852
|
modelValue: { default: "" },
|
|
@@ -1841,81 +1862,81 @@ const tt = oe("SunIcon", [
|
|
|
1841
1862
|
disabled: { type: Boolean, default: !1 }
|
|
1842
1863
|
},
|
|
1843
1864
|
emits: ["update:modelValue", "validate"],
|
|
1844
|
-
setup(i, { expose:
|
|
1845
|
-
const t = i, o = e, l = x(null), r = x(!1),
|
|
1846
|
-
var
|
|
1847
|
-
let
|
|
1848
|
-
const
|
|
1849
|
-
return (
|
|
1850
|
-
}),
|
|
1851
|
-
const
|
|
1852
|
-
o("update:modelValue",
|
|
1865
|
+
setup(i, { expose: v, emit: e }) {
|
|
1866
|
+
const t = i, o = e, l = x(null), r = x(!1), b = x(""), c = E(() => {
|
|
1867
|
+
var I, z, j, W;
|
|
1868
|
+
let f = !0, w = "";
|
|
1869
|
+
const $ = t.modelValue;
|
|
1870
|
+
return (I = t.rules) != null && I.required && ($ == null || $ === "") && (f = !1, w = "This field is required."), f && ((z = t.rules) == null ? void 0 : z.minLength) !== void 0 && typeof $ == "string" && $.length < t.rules.minLength && (f = !1, w = `Must be at least ${t.rules.minLength} characters.`), f && ((j = t.rules) == null ? void 0 : j.maxLength) !== void 0 && typeof $ == "string" && $.length > t.rules.maxLength && (f = !1, w = `Cannot exceed ${t.rules.maxLength} characters.`), f && ((W = t.rules) != null && W.email) && typeof $ == "string" && $ && (/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test($) || (f = !1, w = "Please enter a valid email address.")), b.value = w, o("validate", f), f;
|
|
1871
|
+
}), m = E(() => r.value && !c.value), k = (f) => {
|
|
1872
|
+
const w = f.target;
|
|
1873
|
+
o("update:modelValue", w.value), r.value && c.value;
|
|
1853
1874
|
}, U = () => {
|
|
1854
|
-
r.value = !0,
|
|
1875
|
+
r.value = !0, c.value;
|
|
1855
1876
|
};
|
|
1856
1877
|
return H(
|
|
1857
1878
|
() => t.modelValue,
|
|
1858
1879
|
() => {
|
|
1859
|
-
r.value &&
|
|
1880
|
+
r.value && c.value;
|
|
1860
1881
|
}
|
|
1861
|
-
),
|
|
1882
|
+
), v({
|
|
1862
1883
|
focusInput: () => {
|
|
1863
|
-
var
|
|
1864
|
-
console.log("inputField.vue: focusInput method called."), (
|
|
1884
|
+
var f;
|
|
1885
|
+
console.log("inputField.vue: focusInput method called."), (f = l.value) == null || f.focus();
|
|
1865
1886
|
},
|
|
1866
|
-
isValid:
|
|
1887
|
+
isValid: c,
|
|
1867
1888
|
isTouched: r,
|
|
1868
|
-
errorMessage:
|
|
1869
|
-
}), (
|
|
1870
|
-
|
|
1871
|
-
s("span",
|
|
1889
|
+
errorMessage: b
|
|
1890
|
+
}), (f, w) => (n(), a("div", Vl, [
|
|
1891
|
+
f.label ? (n(), a("label", Bl, [
|
|
1892
|
+
s("span", Ol, C(f.label), 1)
|
|
1872
1893
|
])) : O("", !0),
|
|
1873
|
-
|
|
1894
|
+
M(f.$slots, "default"),
|
|
1874
1895
|
s("input", {
|
|
1875
1896
|
ref_key: "inputElement",
|
|
1876
1897
|
ref: l,
|
|
1877
|
-
type:
|
|
1878
|
-
placeholder:
|
|
1898
|
+
type: f.type,
|
|
1899
|
+
placeholder: f.placeholder,
|
|
1879
1900
|
disabled: t.disabled,
|
|
1880
|
-
class:
|
|
1901
|
+
class: D(["input-bordered rounded-md w-full input validator", [
|
|
1881
1902
|
{
|
|
1882
1903
|
// Size classes - Apply based on size prop
|
|
1883
|
-
"input-xs":
|
|
1884
|
-
"input-sm":
|
|
1885
|
-
"input-md":
|
|
1886
|
-
"input-lg":
|
|
1887
|
-
"input-xl":
|
|
1904
|
+
"input-xs": f.size === "xs",
|
|
1905
|
+
"input-sm": f.size === "sm",
|
|
1906
|
+
"input-md": f.size === "md",
|
|
1907
|
+
"input-lg": f.size === "lg",
|
|
1908
|
+
"input-xl": f.size === "xl",
|
|
1888
1909
|
// Style classes - Apply based on style prop
|
|
1889
|
-
"input-ghost":
|
|
1910
|
+
"input-ghost": f.style === "ghost",
|
|
1890
1911
|
// Color classes - Apply only if NOT in an error state AND NOT in a validation success state.
|
|
1891
1912
|
// This ensures validation feedback overrides base colors.
|
|
1892
|
-
"input-neutral":
|
|
1893
|
-
"input-primary":
|
|
1894
|
-
"input-secondary":
|
|
1895
|
-
"input-accent":
|
|
1896
|
-
"input-info":
|
|
1897
|
-
"input-success":
|
|
1913
|
+
"input-neutral": f.color === "neutral" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1914
|
+
"input-primary": f.color === "primary" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1915
|
+
"input-secondary": f.color === "secondary" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1916
|
+
"input-accent": f.color === "accent" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1917
|
+
"input-info": f.color === "info" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1918
|
+
"input-success": f.color === "success" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1898
1919
|
// Color success applies only if not in error or validation success state
|
|
1899
|
-
"input-warning":
|
|
1920
|
+
"input-warning": f.color === "warning" && !m.value && !(c.value && r.value && f.needsValidation),
|
|
1900
1921
|
// Validation state classes - These take precedence visually via conditions or CSS specificity.
|
|
1901
|
-
"input-error":
|
|
1922
|
+
"input-error": m.value,
|
|
1902
1923
|
// Apply error style if validation fails
|
|
1903
|
-
"input-success-validation":
|
|
1924
|
+
"input-success-validation": c.value && r.value && !m.value && f.needsValidation
|
|
1904
1925
|
// Apply validation success style if valid, touched, not error, AND validation is needed. Using a distinct name 'input-success-validation' is recommended to avoid CSS conflicts with the 'input-success' color class.
|
|
1905
1926
|
}
|
|
1906
1927
|
]]),
|
|
1907
|
-
value:
|
|
1908
|
-
onInput:
|
|
1928
|
+
value: f.modelValue,
|
|
1929
|
+
onInput: k,
|
|
1909
1930
|
onBlur: U
|
|
1910
|
-
}, null, 42,
|
|
1911
|
-
|
|
1912
|
-
s("span",
|
|
1913
|
-
])) :
|
|
1914
|
-
s("span",
|
|
1931
|
+
}, null, 42, zl),
|
|
1932
|
+
m.value ? (n(), a("div", Al, [
|
|
1933
|
+
s("span", Pl, C(b.value), 1)
|
|
1934
|
+
])) : c.value && r.value && f.successMessage ? (n(), a("div", El, [
|
|
1935
|
+
s("span", Ll, C(f.successMessage), 1)
|
|
1915
1936
|
])) : O("", !0)
|
|
1916
1937
|
]));
|
|
1917
1938
|
}
|
|
1918
|
-
}),
|
|
1939
|
+
}), Bn = /* @__PURE__ */ L({
|
|
1919
1940
|
__name: "loader",
|
|
1920
1941
|
props: {
|
|
1921
1942
|
loading: { type: Boolean, default: !0 },
|
|
@@ -1924,15 +1945,15 @@ const tt = oe("SunIcon", [
|
|
|
1924
1945
|
color: { default: "primary" }
|
|
1925
1946
|
},
|
|
1926
1947
|
setup(i) {
|
|
1927
|
-
const
|
|
1948
|
+
const v = i, e = x(v.loading);
|
|
1928
1949
|
return H(
|
|
1929
|
-
() =>
|
|
1950
|
+
() => v.loading,
|
|
1930
1951
|
(t) => {
|
|
1931
1952
|
e.value = t;
|
|
1932
1953
|
}
|
|
1933
1954
|
), (t, o) => e.value ? (n(), a("span", {
|
|
1934
1955
|
key: 0,
|
|
1935
|
-
class:
|
|
1956
|
+
class: D(["loading", [
|
|
1936
1957
|
{ "loading-xs": t.size === "xs" },
|
|
1937
1958
|
{ "loading-sm": t.size === "sm" },
|
|
1938
1959
|
{ "loading-md": t.size === "md" },
|
|
@@ -1957,13 +1978,13 @@ const tt = oe("SunIcon", [
|
|
|
1957
1978
|
]])
|
|
1958
1979
|
}, null, 2)) : O("", !0);
|
|
1959
1980
|
}
|
|
1960
|
-
}),
|
|
1981
|
+
}), Ul = { class: "footer sm:footer-horizontal container" }, Rl = { class: "footer-title" }, Nl = ["href"], jl = {
|
|
1961
1982
|
key: 0,
|
|
1962
1983
|
class: "sm:hidden w-full"
|
|
1963
|
-
},
|
|
1984
|
+
}, Fl = { class: "border-b-2 border-base-100 last:border-b-0 w-full" }, ql = {
|
|
1964
1985
|
tabindex: "0",
|
|
1965
1986
|
class: "collapse collapse-plus w-full"
|
|
1966
|
-
},
|
|
1987
|
+
}, Hl = { class: "collapse-title font-bold text-lg collapsible-footer-title" }, Wl = { class: "collapse-content flex w-full text-sm" }, Kl = { class: "flex flex-col gap-2.5" }, Yl = { class: "w-full" }, Jl = ["href"], Xl = { class: "w-full" }, On = /* @__PURE__ */ L({
|
|
1967
1988
|
__name: "footer",
|
|
1968
1989
|
props: {
|
|
1969
1990
|
items: {},
|
|
@@ -1972,118 +1993,118 @@ const tt = oe("SunIcon", [
|
|
|
1972
1993
|
collapseOnMobile: { type: Boolean, default: !1 }
|
|
1973
1994
|
},
|
|
1974
1995
|
setup(i) {
|
|
1975
|
-
const
|
|
1996
|
+
const v = i;
|
|
1976
1997
|
return (e, t) => (n(), a("div", {
|
|
1977
|
-
class:
|
|
1998
|
+
class: D(["mx-auto md:px-10 py-10 text-base-content", [e.background ?? "bg-base-200", e.color ?? "text-base-content"]])
|
|
1978
1999
|
}, [
|
|
1979
|
-
s("footer",
|
|
1980
|
-
(n(!0), a(B, null,
|
|
1981
|
-
class:
|
|
2000
|
+
s("footer", Ul, [
|
|
2001
|
+
(n(!0), a(B, null, P(v.items, (o) => (n(), a("nav", {
|
|
2002
|
+
class: D([{ "hidden sm:grid": e.collapseOnMobile }])
|
|
1982
2003
|
}, [
|
|
1983
|
-
s("h6",
|
|
1984
|
-
(n(!0), a(B, null,
|
|
2004
|
+
s("h6", Rl, C(o.title), 1),
|
|
2005
|
+
(n(!0), a(B, null, P(o.items, (l) => (n(), a("a", {
|
|
1985
2006
|
class: "link link-hover",
|
|
1986
2007
|
href: l.link
|
|
1987
|
-
}, C(l.text), 9,
|
|
2008
|
+
}, C(l.text), 9, Nl))), 256))
|
|
1988
2009
|
], 2))), 256)),
|
|
1989
|
-
e.collapseOnMobile ? (n(), a("nav",
|
|
1990
|
-
(n(!0), a(B, null,
|
|
1991
|
-
s("div",
|
|
1992
|
-
s("div",
|
|
1993
|
-
s("div",
|
|
1994
|
-
s("ul",
|
|
1995
|
-
(n(!0), a(B, null,
|
|
2010
|
+
e.collapseOnMobile ? (n(), a("nav", jl, [
|
|
2011
|
+
(n(!0), a(B, null, P(v.items, (o) => (n(), a("ul", Fl, [
|
|
2012
|
+
s("div", ql, [
|
|
2013
|
+
s("div", Hl, C(o.title), 1),
|
|
2014
|
+
s("div", Wl, [
|
|
2015
|
+
s("ul", Kl, [
|
|
2016
|
+
(n(!0), a(B, null, P(o.items, (l) => (n(), a("li", Yl, [
|
|
1996
2017
|
s("a", {
|
|
1997
2018
|
class: "w-full font-medium link link-hover",
|
|
1998
2019
|
href: l.link
|
|
1999
|
-
}, C(l.text), 9,
|
|
2020
|
+
}, C(l.text), 9, Jl)
|
|
2000
2021
|
]))), 256))
|
|
2001
2022
|
])
|
|
2002
2023
|
])
|
|
2003
2024
|
])
|
|
2004
2025
|
]))), 256))
|
|
2005
2026
|
])) : O("", !0),
|
|
2006
|
-
s("aside",
|
|
2007
|
-
|
|
2027
|
+
s("aside", Xl, [
|
|
2028
|
+
M(e.$slots, "default")
|
|
2008
2029
|
])
|
|
2009
2030
|
])
|
|
2010
2031
|
], 2));
|
|
2011
2032
|
}
|
|
2012
|
-
}), Gl = {},
|
|
2013
|
-
function
|
|
2014
|
-
return n(), a("div",
|
|
2015
|
-
s("div",
|
|
2033
|
+
}), Gl = {}, Zl = { class: "min-h-40 container hero" }, Ql = { class: "px-0! text-center hero-content" }, en = { class: "mt-9 text-4xl" };
|
|
2034
|
+
function tn(i, v) {
|
|
2035
|
+
return n(), a("div", Zl, [
|
|
2036
|
+
s("div", Ql, [
|
|
2016
2037
|
s("div", null, [
|
|
2017
|
-
s("h1",
|
|
2018
|
-
|
|
2019
|
-
|
|
2038
|
+
s("h1", en, [
|
|
2039
|
+
M(i.$slots, "title", {}, () => [
|
|
2040
|
+
v[0] || (v[0] = ke("hero title"))
|
|
2020
2041
|
])
|
|
2021
2042
|
]),
|
|
2022
2043
|
s("p", null, [
|
|
2023
|
-
|
|
2044
|
+
M(i.$slots, "description", { class: "py-9" })
|
|
2024
2045
|
]),
|
|
2025
|
-
|
|
2026
|
-
|
|
2046
|
+
M(i.$slots, "call-to-action-block", { class: "max-w-full" }, () => [
|
|
2047
|
+
v[1] || (v[1] = s("button", { class: "btn btn-primary" }, "Call to action", -1))
|
|
2027
2048
|
])
|
|
2028
2049
|
])
|
|
2029
2050
|
])
|
|
2030
2051
|
]);
|
|
2031
2052
|
}
|
|
2032
|
-
const
|
|
2053
|
+
const zn = /* @__PURE__ */ le(Gl, [["render", tn]]), ln = { class: "flex flex-row place-content-center gap-4 categories" }, nn = ["onClick"], An = /* @__PURE__ */ L({
|
|
2033
2054
|
__name: "categoryNavigation",
|
|
2034
2055
|
props: {
|
|
2035
2056
|
searchOptions: {},
|
|
2036
2057
|
currentCategory: {}
|
|
2037
2058
|
},
|
|
2038
2059
|
emits: ["update:currentCategory"],
|
|
2039
|
-
setup(i, { emit:
|
|
2040
|
-
const e = i, t =
|
|
2060
|
+
setup(i, { emit: v }) {
|
|
2061
|
+
const e = i, t = v;
|
|
2041
2062
|
function o(l) {
|
|
2042
2063
|
t("update:currentCategory", l);
|
|
2043
2064
|
}
|
|
2044
|
-
return (l, r) => (n(), a("div",
|
|
2045
|
-
(n(!0), a(B, null,
|
|
2046
|
-
key:
|
|
2065
|
+
return (l, r) => (n(), a("div", ln, [
|
|
2066
|
+
(n(!0), a(B, null, P(e.searchOptions, (b) => (n(), a("div", {
|
|
2067
|
+
key: b.category
|
|
2047
2068
|
}, [
|
|
2048
2069
|
s("button", {
|
|
2049
|
-
onClick: (
|
|
2050
|
-
class:
|
|
2051
|
-
}, C(
|
|
2070
|
+
onClick: (c) => o(b.category),
|
|
2071
|
+
class: D(["truncate btn btn-ghost", { "font-semibold": e.currentCategory === b.category }])
|
|
2072
|
+
}, C(b.category), 11, nn)
|
|
2052
2073
|
]))), 128))
|
|
2053
2074
|
]));
|
|
2054
2075
|
}
|
|
2055
|
-
}),
|
|
2076
|
+
}), an = { class: "md:flex hidden navbar-start" }, on = { class: "md:flex justify-center items-center hidden navbar-center" }, sn = { class: "md:flex hidden navbar-end" }, rn = { class: "navbar-bottom md:flex hidden" }, un = /* @__PURE__ */ L({
|
|
2056
2077
|
__name: "navigationBar",
|
|
2057
2078
|
props: {
|
|
2058
2079
|
isCollapsed: { type: Boolean, default: !0 }
|
|
2059
2080
|
},
|
|
2060
2081
|
setup(i) {
|
|
2061
|
-
const
|
|
2082
|
+
const v = i;
|
|
2062
2083
|
return (e, t) => (n(), a("nav", {
|
|
2063
|
-
class:
|
|
2084
|
+
class: D(["place-items-start border-primary bg-base-100 px-5 py-5 border-b-4 transition-all navbar navigationbar", v.isCollapsed ? "collapsed" : ""])
|
|
2064
2085
|
}, [
|
|
2065
|
-
s("div", nn, [
|
|
2066
|
-
T(e.$slots, "start", {}, void 0, !0)
|
|
2067
|
-
]),
|
|
2068
2086
|
s("div", an, [
|
|
2069
|
-
|
|
2087
|
+
M(e.$slots, "start", {}, void 0, !0)
|
|
2070
2088
|
]),
|
|
2071
2089
|
s("div", on, [
|
|
2072
|
-
|
|
2090
|
+
M(e.$slots, "center", {}, void 0, !0)
|
|
2073
2091
|
]),
|
|
2074
2092
|
s("div", sn, [
|
|
2075
|
-
|
|
2093
|
+
M(e.$slots, "end", {}, void 0, !0)
|
|
2094
|
+
]),
|
|
2095
|
+
s("div", rn, [
|
|
2096
|
+
M(e.$slots, "bottom", {}, void 0, !0)
|
|
2076
2097
|
])
|
|
2077
2098
|
], 2));
|
|
2078
2099
|
}
|
|
2079
|
-
}),
|
|
2100
|
+
}), Pn = /* @__PURE__ */ le(un, [["__scopeId", "data-v-8ddb2b45"]]), dn = {
|
|
2080
2101
|
key: 0,
|
|
2081
2102
|
class: "hidden top-4 right-0 absolute md:flex gap-4"
|
|
2082
|
-
},
|
|
2103
|
+
}, cn = ["onClick", "aria-selected"], pn = {
|
|
2083
2104
|
key: 0,
|
|
2084
2105
|
role: "tabpanel",
|
|
2085
2106
|
class: "p-6 border-x-0 border-t-2 border-b-0 border-base-300 max-w-full overflow-x-auto tab-content"
|
|
2086
|
-
},
|
|
2107
|
+
}, vn = { class: "p-6 border-x-0 border-t-2 border-b-0 border-base-300 max-w-full" }, En = /* @__PURE__ */ L({
|
|
2087
2108
|
__name: "tab",
|
|
2088
2109
|
props: {
|
|
2089
2110
|
items: {},
|
|
@@ -2092,82 +2113,82 @@ const On = /* @__PURE__ */ te(Gl, [["render", en]]), tn = { class: "flex flex-ro
|
|
|
2092
2113
|
buttonOnlyMode: { type: Boolean, default: !1 }
|
|
2093
2114
|
},
|
|
2094
2115
|
emits: ["tab-changed"],
|
|
2095
|
-
setup(i, { emit:
|
|
2096
|
-
const e = i, t = x(e.items[0]), o =
|
|
2097
|
-
function l(
|
|
2098
|
-
t.value =
|
|
2116
|
+
setup(i, { emit: v }) {
|
|
2117
|
+
const e = i, t = x(e.items[0]), o = v;
|
|
2118
|
+
function l(c) {
|
|
2119
|
+
t.value = c, o("tab-changed", c);
|
|
2099
2120
|
}
|
|
2100
2121
|
function r() {
|
|
2101
|
-
const
|
|
2102
|
-
l(e.items[
|
|
2122
|
+
const m = (e.items.indexOf(t.value) + 1) % e.items.length;
|
|
2123
|
+
l(e.items[m]);
|
|
2103
2124
|
}
|
|
2104
|
-
function
|
|
2105
|
-
const
|
|
2106
|
-
l(e.items[
|
|
2125
|
+
function b() {
|
|
2126
|
+
const m = (e.items.indexOf(t.value) - 1 + e.items.length) % e.items.length;
|
|
2127
|
+
l(e.items[m]);
|
|
2107
2128
|
}
|
|
2108
|
-
return
|
|
2129
|
+
return ee(() => {
|
|
2109
2130
|
e.items && l(e.items[0]);
|
|
2110
2131
|
}), $e(() => {
|
|
2111
2132
|
e.rotateTabsAfter && e.rotateTabsAfter > 0 && setInterval(() => {
|
|
2112
2133
|
r();
|
|
2113
2134
|
}, e.rotateTabsAfter * 1e3);
|
|
2114
|
-
}), (
|
|
2135
|
+
}), (c, m) => (n(), a(B, null, [
|
|
2115
2136
|
s("div", {
|
|
2116
2137
|
role: "tablist",
|
|
2117
|
-
class:
|
|
2138
|
+
class: D(["relative tabs-bordered w-full tabs tabs-lg", { "flex-nowrap overflow-x-auto": c.buttonOnlyMode }])
|
|
2118
2139
|
}, [
|
|
2119
|
-
|
|
2140
|
+
c.withControlls ? (n(), a("div", dn, [
|
|
2120
2141
|
s("button", {
|
|
2121
|
-
onClick:
|
|
2142
|
+
onClick: m[0] || (m[0] = (k) => b()),
|
|
2122
2143
|
class: "cursor-pointer"
|
|
2123
2144
|
}, "Previous"),
|
|
2124
2145
|
s("button", {
|
|
2125
|
-
onClick:
|
|
2146
|
+
onClick: m[1] || (m[1] = (k) => r()),
|
|
2126
2147
|
class: "text-primary cursor-pointer"
|
|
2127
2148
|
}, "Next")
|
|
2128
2149
|
])) : O("", !0),
|
|
2129
|
-
(n(!0), a(B, null,
|
|
2150
|
+
(n(!0), a(B, null, P(c.items, (k) => (n(), a(B, null, [
|
|
2130
2151
|
s("a", {
|
|
2131
2152
|
type: "button",
|
|
2132
2153
|
role: "tab",
|
|
2133
|
-
class:
|
|
2134
|
-
onClick: (U) => l(
|
|
2135
|
-
"aria-selected": t.value ==
|
|
2136
|
-
}, C(
|
|
2137
|
-
|
|
2138
|
-
|
|
2154
|
+
class: D(["min-w-max tab", k === t.value ? "bg-primary text-base-100" : ""]),
|
|
2155
|
+
onClick: (U) => l(k),
|
|
2156
|
+
"aria-selected": t.value == k
|
|
2157
|
+
}, C(k), 11, cn),
|
|
2158
|
+
c.buttonOnlyMode ? O("", !0) : (n(), a("div", pn, [
|
|
2159
|
+
M(c.$slots, `${k}-tab`)
|
|
2139
2160
|
]))
|
|
2140
2161
|
], 64))), 256))
|
|
2141
2162
|
], 2),
|
|
2142
|
-
s("div",
|
|
2143
|
-
|
|
2163
|
+
s("div", vn, [
|
|
2164
|
+
M(c.$slots, "default")
|
|
2144
2165
|
])
|
|
2145
2166
|
], 64));
|
|
2146
2167
|
}
|
|
2147
2168
|
});
|
|
2148
2169
|
export {
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2170
|
+
wn as Accordion,
|
|
2171
|
+
Cn as AdvancedSearch,
|
|
2172
|
+
kn as Avatar,
|
|
2173
|
+
$n as Badge,
|
|
2174
|
+
mn as ButtonComponent,
|
|
2175
|
+
_n as Card,
|
|
2176
|
+
Sn as Carousel,
|
|
2177
|
+
xn as CarouselItem,
|
|
2178
|
+
An as CategoryNavigation,
|
|
2179
|
+
cl as DatetimePicker,
|
|
2180
|
+
gn as Dropdown,
|
|
2181
|
+
Tn as FilterableSelect,
|
|
2182
|
+
On as Footer,
|
|
2183
|
+
zn as Hero,
|
|
2184
|
+
Vn as InputField,
|
|
2185
|
+
Bn as Loader,
|
|
2186
|
+
hn as Modal,
|
|
2187
|
+
Pn as NavigationBar,
|
|
2188
|
+
In as Rating,
|
|
2168
2189
|
Dn as Selector,
|
|
2169
|
-
|
|
2170
|
-
|
|
2190
|
+
bn as Swap,
|
|
2191
|
+
En as Tab,
|
|
2171
2192
|
Mn as TagInput,
|
|
2172
|
-
|
|
2193
|
+
yn as ThemeController
|
|
2173
2194
|
};
|