@enos5/enos-vue 1.0.7 → 1.0.8
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/index.js +655 -656
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref as O, computed as g, watch as
|
|
1
|
+
import { ref as O, computed as g, watch as Z, openBlock as s, createElementBlock as r, createElementVNode as i, Fragment as q, renderList as X, normalizeClass as $, normalizeStyle as he, toDisplayString as A, createBlock as B, createCommentVNode as D, renderSlot as k, createVNode as H, Transition as oe, withCtx as F, mergeProps as R, useSlots as ge, unref as j, withDirectives as re, vShow as ce, watchEffect as Qe, onMounted as te, useAttrs as ne, vModelCheckbox as Ye, nextTick as fe, onBeforeUnmount as Je, Teleport as Te, withModifiers as ye, onUnmounted as Ae, createTextVNode as de, resolveDynamicComponent as Be, vModelText as Ze } from "vue";
|
|
2
2
|
import { usePage as et, Link as pe } from "@inertiajs/vue3";
|
|
3
3
|
import { useI18n as tt } from "vue-i18n";
|
|
4
4
|
import { CheckCircleIcon as lt, ExclamationTriangleIcon as Le, XMarkIcon as st, LockClosedIcon as at, ChevronDownIcon as xe, PhotoIcon as nt, ExclamationCircleIcon as ot, ChevronUpIcon as Ie, MagnifyingGlassIcon as rt, CheckIcon as it, PencilSquareIcon as dt } from "@heroicons/vue/24/outline";
|
|
@@ -20,7 +20,7 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
20
20
|
return Et;
|
|
21
21
|
},
|
|
22
22
|
get Badge() {
|
|
23
|
-
return
|
|
23
|
+
return Nt;
|
|
24
24
|
},
|
|
25
25
|
get Banner() {
|
|
26
26
|
return Gt;
|
|
@@ -50,7 +50,7 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
50
50
|
return Ee;
|
|
51
51
|
},
|
|
52
52
|
get DateInput() {
|
|
53
|
-
return
|
|
53
|
+
return Ne;
|
|
54
54
|
},
|
|
55
55
|
get DialogModal() {
|
|
56
56
|
return El;
|
|
@@ -59,7 +59,7 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
59
59
|
return we;
|
|
60
60
|
},
|
|
61
61
|
get Dropdown() {
|
|
62
|
-
return
|
|
62
|
+
return Nl;
|
|
63
63
|
},
|
|
64
64
|
get DropdownLink() {
|
|
65
65
|
return Kl;
|
|
@@ -71,7 +71,7 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
71
71
|
return Gl;
|
|
72
72
|
},
|
|
73
73
|
get ImageInput() {
|
|
74
|
-
return
|
|
74
|
+
return Re;
|
|
75
75
|
},
|
|
76
76
|
get InputError() {
|
|
77
77
|
return Ql;
|
|
@@ -152,60 +152,60 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
152
152
|
],
|
|
153
153
|
setup(e, { emit: a }) {
|
|
154
154
|
const t = e, l = a, n = O([]), d = g(() => t.tabs.map((w) => w.value)), u = g(() => d.value.includes(t.activeTab) ? t.activeTab : d.value[0] ?? "");
|
|
155
|
-
|
|
155
|
+
Z(u, (w) => {
|
|
156
156
|
w !== t.activeTab && l("update:activeTab", w);
|
|
157
157
|
}, { immediate: !0 });
|
|
158
|
-
const f = (w,
|
|
159
|
-
n.value[
|
|
160
|
-
},
|
|
158
|
+
const f = (w, h) => {
|
|
159
|
+
n.value[h] = w;
|
|
160
|
+
}, V = (w) => {
|
|
161
161
|
!w || w === t.activeTab || (l("update:activeTab", w), l("tab-click", w));
|
|
162
162
|
}, y = (w) => {
|
|
163
163
|
n.value[w]?.focus();
|
|
164
|
-
},
|
|
164
|
+
}, C = (w, h) => {
|
|
165
165
|
if (t.tabs.length === 0)
|
|
166
166
|
return;
|
|
167
|
-
let
|
|
167
|
+
let S = h;
|
|
168
168
|
switch (w.key) {
|
|
169
169
|
case "ArrowRight":
|
|
170
170
|
case "ArrowDown":
|
|
171
|
-
|
|
171
|
+
S = (h + 1) % t.tabs.length;
|
|
172
172
|
break;
|
|
173
173
|
case "ArrowLeft":
|
|
174
174
|
case "ArrowUp":
|
|
175
|
-
|
|
175
|
+
S = (h - 1 + t.tabs.length) % t.tabs.length;
|
|
176
176
|
break;
|
|
177
177
|
case "Home":
|
|
178
|
-
|
|
178
|
+
S = 0;
|
|
179
179
|
break;
|
|
180
180
|
case "End":
|
|
181
|
-
|
|
181
|
+
S = t.tabs.length - 1;
|
|
182
182
|
break;
|
|
183
183
|
default:
|
|
184
184
|
return;
|
|
185
185
|
}
|
|
186
|
-
w.preventDefault(),
|
|
186
|
+
w.preventDefault(), V(t.tabs[S].value), y(S);
|
|
187
187
|
};
|
|
188
|
-
return (w,
|
|
189
|
-
|
|
190
|
-
(s(!0),
|
|
191
|
-
key:
|
|
188
|
+
return (w, h) => (s(), r("div", ct, [
|
|
189
|
+
i("div", ft, [
|
|
190
|
+
(s(!0), r(q, null, X(e.tabs, (S, v) => (s(), r("button", {
|
|
191
|
+
key: S.value,
|
|
192
192
|
ref_for: !0,
|
|
193
|
-
ref: (
|
|
193
|
+
ref: (M) => f(M, v),
|
|
194
194
|
type: "button",
|
|
195
195
|
style: he({ width: `${100 / e.tabs.length}%` }),
|
|
196
196
|
role: "tab",
|
|
197
|
-
"aria-selected": u.value ===
|
|
198
|
-
tabindex: u.value ===
|
|
199
|
-
class:
|
|
197
|
+
"aria-selected": u.value === S.value,
|
|
198
|
+
tabindex: u.value === S.value ? 0 : -1,
|
|
199
|
+
class: $([
|
|
200
200
|
"px-4 py-3 text-center text-sm font-semibold tracking-wide transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-blue-500/40 focus-visible:ring-inset",
|
|
201
|
-
u.value ===
|
|
201
|
+
u.value === S.value ? "bg-blue-50 text-blue-700 shadow-[inset_0_-2px_0_0_rgb(37_99_235)]" : "text-gray-700 hover:bg-gray-50",
|
|
202
202
|
{
|
|
203
|
-
"border-r border-gray-200/80":
|
|
203
|
+
"border-r border-gray-200/80": v !== e.tabs.length - 1
|
|
204
204
|
}
|
|
205
205
|
]),
|
|
206
|
-
onClick: (
|
|
207
|
-
onKeydown: (
|
|
208
|
-
},
|
|
206
|
+
onClick: (M) => V(S.value),
|
|
207
|
+
onKeydown: (M) => C(M, v)
|
|
208
|
+
}, A(S.label), 47, gt))), 128))
|
|
209
209
|
])
|
|
210
210
|
]));
|
|
211
211
|
}
|
|
@@ -258,28 +258,28 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
258
258
|
],
|
|
259
259
|
setup(e) {
|
|
260
260
|
const a = e, t = O(""), l = O("right"), n = g(() => a.tabs.findIndex((d) => d.value === a.activeTab));
|
|
261
|
-
return g(() => a.tabs.findIndex((d) => d.value === t.value)),
|
|
261
|
+
return g(() => a.tabs.findIndex((d) => d.value === t.value)), Z(n, (d, u) => {
|
|
262
262
|
u !== void 0 && u !== -1 && d !== -1 && d !== u && (l.value = d > u ? "right" : "left", t.value = a.activeTab);
|
|
263
|
-
}), (d, u) => (s(),
|
|
264
|
-
class:
|
|
263
|
+
}), (d, u) => (s(), r("div", {
|
|
264
|
+
class: $(["bg-white/90 backdrop-blur-sm border border-slate-200/70 rounded-2xl shadow-[0_12px_30px_rgba(15,23,42,0.06)]", e.overflowClass, { "sticky top-6 self-start": e.sticky }, e.cardClass])
|
|
265
265
|
}, [
|
|
266
|
-
e.tabs.length > 0 ? (s(),
|
|
266
|
+
e.tabs.length > 0 ? (s(), B(Me, {
|
|
267
267
|
key: 0,
|
|
268
268
|
tabs: e.tabs,
|
|
269
269
|
"active-tab": e.activeTab,
|
|
270
270
|
"onUpdate:activeTab": u[0] || (u[0] = (f) => d.$emit("update:activeTab", f)),
|
|
271
271
|
onTabClick: u[1] || (u[1] = (f) => d.$emit("tab-click", f))
|
|
272
|
-
}, null, 8, ["tabs", "active-tab"])) :
|
|
273
|
-
|
|
274
|
-
class:
|
|
272
|
+
}, null, 8, ["tabs", "active-tab"])) : D("", !0),
|
|
273
|
+
i("div", {
|
|
274
|
+
class: $(e.paddingClass)
|
|
275
275
|
}, [
|
|
276
|
-
d.$slots.customTitle ? (s(),
|
|
277
|
-
|
|
278
|
-
])) : e.title ? (s(),
|
|
279
|
-
|
|
280
|
-
class:
|
|
276
|
+
d.$slots.customTitle ? (s(), r("div", pt, [
|
|
277
|
+
k(d.$slots, "customTitle")
|
|
278
|
+
])) : e.title ? (s(), r("h3", mt, A(e.title), 1)) : D("", !0),
|
|
279
|
+
i("div", {
|
|
280
|
+
class: $(["relative", e.tabs.length > 0 ? "overflow-hidden" : "overflow-visible"])
|
|
281
281
|
}, [
|
|
282
|
-
H(
|
|
282
|
+
H(oe, {
|
|
283
283
|
"enter-active-class": "transition-all duration-200 ease-in-out",
|
|
284
284
|
"enter-from-class": l.value === "right" ? "translate-x-full opacity-0" : "-translate-x-full opacity-0",
|
|
285
285
|
"enter-to-class": "translate-x-0 opacity-100",
|
|
@@ -289,11 +289,11 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
289
289
|
mode: "out-in"
|
|
290
290
|
}, {
|
|
291
291
|
default: F(() => [
|
|
292
|
-
(s(),
|
|
292
|
+
(s(), r("div", {
|
|
293
293
|
key: e.activeTab,
|
|
294
|
-
class:
|
|
294
|
+
class: $([e.tabs.length > 0 ? "p-2" : "", e.contentClass])
|
|
295
295
|
}, [
|
|
296
|
-
|
|
296
|
+
k(d.$slots, "default")
|
|
297
297
|
], 2))
|
|
298
298
|
]),
|
|
299
299
|
_: 3
|
|
@@ -307,8 +307,8 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
307
307
|
}, {
|
|
308
308
|
__name: "Divider",
|
|
309
309
|
setup(e) {
|
|
310
|
-
return (a, t) => (s(),
|
|
311
|
-
|
|
310
|
+
return (a, t) => (s(), r("div", R({ class: "border-t border-gray-200" }, a.$attrs), [
|
|
311
|
+
k(a.$slots, "default")
|
|
312
312
|
], 16));
|
|
313
313
|
}
|
|
314
314
|
}), bt = {
|
|
@@ -325,21 +325,21 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
325
325
|
},
|
|
326
326
|
setup(e) {
|
|
327
327
|
const a = ge();
|
|
328
|
-
return (t, l) => (s(),
|
|
328
|
+
return (t, l) => (s(), B(De, {
|
|
329
329
|
title: e.title,
|
|
330
330
|
"content-class": e.actionsClass
|
|
331
331
|
}, {
|
|
332
332
|
default: F(() => [
|
|
333
|
-
|
|
334
|
-
j(a).danger ? (s(),
|
|
333
|
+
k(t.$slots, "default"),
|
|
334
|
+
j(a).danger ? (s(), B(we, {
|
|
335
335
|
key: 0,
|
|
336
336
|
class: "mt-6 pt-4"
|
|
337
337
|
}, {
|
|
338
338
|
default: F(() => [
|
|
339
|
-
|
|
339
|
+
k(t.$slots, "danger")
|
|
340
340
|
]),
|
|
341
341
|
_: 3
|
|
342
|
-
})) :
|
|
342
|
+
})) : D("", !0)
|
|
343
343
|
]),
|
|
344
344
|
_: 3
|
|
345
345
|
}, 8, ["title", "content-class"]));
|
|
@@ -350,17 +350,17 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
350
350
|
on: Boolean
|
|
351
351
|
},
|
|
352
352
|
setup(e) {
|
|
353
|
-
return (a, t) => (s(),
|
|
354
|
-
H(
|
|
353
|
+
return (a, t) => (s(), r("div", null, [
|
|
354
|
+
H(oe, {
|
|
355
355
|
"leave-active-class": "transition ease-in duration-1000",
|
|
356
356
|
"leave-from-class": "opacity-100",
|
|
357
357
|
"leave-to-class": "opacity-0"
|
|
358
358
|
}, {
|
|
359
359
|
default: F(() => [
|
|
360
|
-
|
|
361
|
-
|
|
360
|
+
re(i("div", yt, [
|
|
361
|
+
k(a.$slots, "default")
|
|
362
362
|
], 512), [
|
|
363
|
-
[
|
|
363
|
+
[ce, e.on]
|
|
364
364
|
])
|
|
365
365
|
]),
|
|
366
366
|
_: 3
|
|
@@ -374,36 +374,36 @@ const ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
374
374
|
return t;
|
|
375
375
|
}, ht = {}, xt = { class: "md:col-span-1 flex justify-between" }, wt = { class: "px-4 sm:px-0" }, kt = { class: "text-xl font-semibold tracking-tight text-slate-900" }, St = { class: "mt-1 max-w-2xl text-sm text-slate-600" }, $t = { class: "px-4 sm:px-0" };
|
|
376
376
|
function Ct(e, a) {
|
|
377
|
-
return s(),
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
377
|
+
return s(), r("div", xt, [
|
|
378
|
+
i("div", wt, [
|
|
379
|
+
i("h3", kt, [
|
|
380
|
+
k(e.$slots, "title")
|
|
381
381
|
]),
|
|
382
|
-
|
|
383
|
-
|
|
382
|
+
i("p", St, [
|
|
383
|
+
k(e.$slots, "description")
|
|
384
384
|
])
|
|
385
385
|
]),
|
|
386
|
-
|
|
387
|
-
|
|
386
|
+
i("div", $t, [
|
|
387
|
+
k(e.$slots, "aside")
|
|
388
388
|
])
|
|
389
389
|
]);
|
|
390
390
|
}
|
|
391
391
|
const Se = /* @__PURE__ */ ke(ht, [["render", Ct]]), Vt = { class: "md:grid md:grid-cols-3 md:gap-6" }, _t = { class: "mt-5 md:mt-0 md:col-span-2" }, Tt = { class: "px-4 py-5 sm:p-6 bg-white shadow sm:rounded-lg" }, At = {
|
|
392
392
|
__name: "ActionSection",
|
|
393
393
|
setup(e) {
|
|
394
|
-
return (a, t) => (s(),
|
|
394
|
+
return (a, t) => (s(), r("div", Vt, [
|
|
395
395
|
H(Se, null, {
|
|
396
396
|
title: F(() => [
|
|
397
|
-
|
|
397
|
+
k(a.$slots, "title")
|
|
398
398
|
]),
|
|
399
399
|
description: F(() => [
|
|
400
|
-
|
|
400
|
+
k(a.$slots, "description")
|
|
401
401
|
]),
|
|
402
402
|
_: 3
|
|
403
403
|
}),
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
404
|
+
i("div", _t, [
|
|
405
|
+
i("div", Tt, [
|
|
406
|
+
k(a.$slots, "content")
|
|
407
407
|
])
|
|
408
408
|
])
|
|
409
409
|
]));
|
|
@@ -414,16 +414,16 @@ const Se = /* @__PURE__ */ ke(ht, [["render", Ct]]), Vt = { class: "md:grid md:g
|
|
|
414
414
|
xmlns: "http://www.w3.org/2000/svg"
|
|
415
415
|
};
|
|
416
416
|
function It(e, a) {
|
|
417
|
-
return s(),
|
|
418
|
-
|
|
417
|
+
return s(), r("svg", Lt, [...a[0] || (a[0] = [
|
|
418
|
+
i("path", {
|
|
419
419
|
d: "M74.09 30.04V13h-4.14v21H82.1v-3.96h-8.01zM95.379 19v1.77c-1.08-1.35-2.7-2.19-4.89-2.19-3.99 0-7.29 3.45-7.29 7.92s3.3 7.92 7.29 7.92c2.19 0 3.81-.84 4.89-2.19V34h3.87V19h-3.87zm-4.17 11.73c-2.37 0-4.14-1.71-4.14-4.23 0-2.52 1.77-4.23 4.14-4.23 2.4 0 4.17 1.71 4.17 4.23 0 2.52-1.77 4.23-4.17 4.23zM106.628 21.58V19h-3.87v15h3.87v-7.17c0-3.15 2.55-4.05 4.56-3.81V18.7c-1.89 0-3.78.84-4.56 2.88zM124.295 19v1.77c-1.08-1.35-2.7-2.19-4.89-2.19-3.99 0-7.29 3.45-7.29 7.92s3.3 7.92 7.29 7.92c2.19 0 3.81-.84 4.89-2.19V34h3.87V19h-3.87zm-4.17 11.73c-2.37 0-4.14-1.71-4.14-4.23 0-2.52 1.77-4.23 4.14-4.23 2.4 0 4.17 1.71 4.17 4.23 0 2.52-1.77 4.23-4.17 4.23zM141.544 19l-3.66 10.5-3.63-10.5h-4.26l5.7 15h4.41l5.7-15h-4.26zM150.354 28.09h11.31c.09-.51.15-1.02.15-1.59 0-4.41-3.15-7.92-7.59-7.92-4.71 0-7.92 3.45-7.92 7.92s3.18 7.92 8.22 7.92c2.88 0 5.13-1.17 6.54-3.21l-3.12-1.8c-.66.87-1.86 1.5-3.36 1.5-2.04 0-3.69-.84-4.23-2.82zm-.06-3c.45-1.92 1.86-3.03 3.93-3.03 1.62 0 3.24.87 3.72 3.03h-7.65zM164.516 34h3.87V12.1h-3.87V34zM185.248 34.36c3.69 0 6.9-2.01 6.9-6.3V13h-2.1v15.06c0 3.03-2.07 4.26-4.8 4.26-2.19 0-3.93-.78-4.62-2.61l-1.77 1.05c1.05 2.43 3.57 3.6 6.39 3.6zM203.124 18.64c-4.65 0-7.83 3.45-7.83 7.86 0 4.53 3.24 7.86 7.98 7.86 3.03 0 5.34-1.41 6.6-3.45l-1.74-1.02c-.81 1.44-2.46 2.55-4.83 2.55-3.18 0-5.55-1.89-5.97-4.95h13.17c.03-.3.06-.63.06-.93 0-4.11-2.85-7.92-7.44-7.92zm0 1.92c2.58 0 4.98 1.71 5.4 5.01h-11.19c.39-2.94 2.64-5.01 5.79-5.01zM221.224 20.92V19h-4.32v-4.2l-1.98.6V19h-3.15v1.92h3.15v9.09c0 3.6 2.25 4.59 6.3 3.99v-1.74c-2.91.12-4.32.33-4.32-2.25v-9.09h4.32zM225.176 22.93c0-1.62 1.59-2.37 3.15-2.37 1.44 0 2.97.57 3.6 2.1l1.65-.96c-.87-1.86-2.79-3.06-5.25-3.06-3 0-5.13 1.89-5.13 4.29 0 5.52 8.76 3.39 8.76 7.11 0 1.77-1.68 2.4-3.45 2.4-2.01 0-3.57-.99-4.11-2.52l-1.68.99c.75 1.92 2.79 3.45 5.79 3.45 3.21 0 5.43-1.77 5.43-4.32 0-5.52-8.76-3.39-8.76-7.11zM244.603 20.92V19h-4.32v-4.2l-1.98.6V19h-3.15v1.92h3.15v9.09c0 3.6 2.25 4.59 6.3 3.99v-1.74c-2.91.12-4.32.33-4.32-2.25v-9.09h4.32zM249.883 21.49V19h-1.98v15h1.98v-8.34c0-3.72 2.34-4.98 4.74-4.98v-1.92c-1.92 0-3.69.63-4.74 2.73zM263.358 18.64c-4.65 0-7.83 3.45-7.83 7.86 0 4.53 3.24 7.86 7.98 7.86 3.03 0 5.34-1.41 6.6-3.45l-1.74-1.02c-.81 1.44-2.46 2.55-4.83 2.55-3.18 0-5.55-1.89-5.97-4.95h13.17c.03-.3.06-.63.06-.93 0-4.11-2.85-7.92-7.44-7.92zm0 1.92c2.58 0 4.98 1.71 5.4 5.01h-11.19c.39-2.94 2.64-5.01 5.79-5.01zM286.848 19v2.94c-1.26-2.01-3.39-3.3-6.06-3.3-4.23 0-7.74 3.42-7.74 7.86s3.51 7.86 7.74 7.86c2.67 0 4.8-1.29 6.06-3.3V34h1.98V19h-1.98zm-5.91 13.44c-3.33 0-5.91-2.61-5.91-5.94 0-3.33 2.58-5.94 5.91-5.94s5.91 2.61 5.91 5.94c0 3.33-2.58 5.94-5.91 5.94zM309.01 18.64c-1.92 0-3.75.87-4.86 2.73-.84-1.74-2.46-2.73-4.56-2.73-1.8 0-3.42.72-4.59 2.55V19h-1.98v15H295v-8.31c0-3.72 2.16-5.13 4.32-5.13 2.13 0 3.51 1.41 3.51 4.08V34h1.98v-8.31c0-3.72 1.86-5.13 4.17-5.13 2.13 0 3.66 1.41 3.66 4.08V34h1.98v-9.36c0-3.75-2.31-6-5.61-6z",
|
|
420
420
|
class: "fill-black"
|
|
421
421
|
}, null, -1),
|
|
422
|
-
|
|
422
|
+
i("path", {
|
|
423
423
|
d: "M11.395 44.428C4.557 40.198 0 32.632 0 24 0 10.745 10.745 0 24 0a23.891 23.891 0 0113.997 4.502c-.2 17.907-11.097 33.245-26.602 39.926z",
|
|
424
424
|
fill: "#6875F5"
|
|
425
425
|
}, null, -1),
|
|
426
|
-
|
|
426
|
+
i("path", {
|
|
427
427
|
d: "M14.134 45.885A23.914 23.914 0 0024 48c13.255 0 24-10.745 24-24 0-3.516-.756-6.856-2.115-9.866-4.659 15.143-16.608 27.092-31.75 31.751z",
|
|
428
428
|
fill: "#6875F5"
|
|
429
429
|
}, null, -1)
|
|
@@ -431,16 +431,16 @@ function It(e, a) {
|
|
|
431
431
|
}
|
|
432
432
|
const Mt = /* @__PURE__ */ ke(Bt, [["render", It]]), Dt = {}, Ot = { class: "min-h-screen flex flex-col sm:justify-center items-center pt-6 sm:pt-0 bg-gray-100" }, jt = { class: "w-full sm:max-w-md mt-6 px-6 py-4 bg-white shadow-md overflow-hidden rounded-lg" };
|
|
433
433
|
function zt(e, a) {
|
|
434
|
-
return s(),
|
|
435
|
-
|
|
436
|
-
|
|
434
|
+
return s(), r("div", Ot, [
|
|
435
|
+
i("div", null, [
|
|
436
|
+
k(e.$slots, "logo")
|
|
437
437
|
]),
|
|
438
|
-
|
|
439
|
-
|
|
438
|
+
i("div", jt, [
|
|
439
|
+
k(e.$slots, "default")
|
|
440
440
|
])
|
|
441
441
|
]);
|
|
442
442
|
}
|
|
443
|
-
const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
443
|
+
const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" }, Nt = {
|
|
444
444
|
__name: "Badge",
|
|
445
445
|
props: {
|
|
446
446
|
type: {
|
|
@@ -495,29 +495,29 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
495
495
|
lg: "rounded-lg",
|
|
496
496
|
full: "rounded-full"
|
|
497
497
|
};
|
|
498
|
-
return (n, d) => e.type === "dot" ? (s(),
|
|
498
|
+
return (n, d) => e.type === "dot" ? (s(), r("span", {
|
|
499
499
|
key: 0,
|
|
500
|
-
class:
|
|
500
|
+
class: $(["inline-flex items-center justify-center w-6 h-6 rounded-full", a[e.color].bg])
|
|
501
501
|
}, [
|
|
502
|
-
|
|
503
|
-
class:
|
|
502
|
+
i("span", {
|
|
503
|
+
class: $(["w-2 h-2 rounded-full", a[e.color].dot])
|
|
504
504
|
}, null, 2),
|
|
505
|
-
|
|
506
|
-
|
|
505
|
+
i("span", Ft, [
|
|
506
|
+
k(n.$slots, "default")
|
|
507
507
|
])
|
|
508
|
-
], 2)) : (s(),
|
|
508
|
+
], 2)) : (s(), r("span", {
|
|
509
509
|
key: 1,
|
|
510
|
-
class:
|
|
510
|
+
class: $(["inline-flex items-center font-medium", [
|
|
511
511
|
a[e.color].bg,
|
|
512
512
|
a[e.color].text,
|
|
513
513
|
t[e.size],
|
|
514
514
|
l[e.rounded]
|
|
515
515
|
]])
|
|
516
516
|
}, [
|
|
517
|
-
|
|
517
|
+
k(n.$slots, "default")
|
|
518
518
|
], 2));
|
|
519
519
|
}
|
|
520
|
-
},
|
|
520
|
+
}, Rt = {
|
|
521
521
|
key: 0,
|
|
522
522
|
class: "fixed bottom-4 right-4 z-50"
|
|
523
523
|
}, Ut = { class: "flex items-center" }, Kt = { class: "flex-shrink-0" }, Ht = { class: "ml-3 w-0 flex-1" }, Wt = { class: "text-sm font-medium text-white" }, Pt = { class: "ml-4 flex-shrink-0 flex" }, qt = { class: "sr-only" }, Gt = {
|
|
@@ -525,7 +525,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
525
525
|
setup(e) {
|
|
526
526
|
const a = et(), { t } = tt(), l = O(!1), n = O("success"), d = O(""), u = O(!1);
|
|
527
527
|
let f = null;
|
|
528
|
-
const
|
|
528
|
+
const V = () => {
|
|
529
529
|
u.value = !1, setTimeout(() => {
|
|
530
530
|
l.value = !1;
|
|
531
531
|
}, 300);
|
|
@@ -533,58 +533,58 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
533
533
|
f && clearTimeout(f), l.value = !0, setTimeout(() => {
|
|
534
534
|
u.value = !0;
|
|
535
535
|
}, 50), f = setTimeout(() => {
|
|
536
|
-
|
|
536
|
+
V();
|
|
537
537
|
}, 5e3);
|
|
538
538
|
};
|
|
539
539
|
return Qe(async () => {
|
|
540
|
-
const
|
|
541
|
-
w && (n.value =
|
|
542
|
-
}),
|
|
540
|
+
const C = a.props.jetstream.flash?.bannerStyle || "success", w = a.props.jetstream.flash?.banner || "";
|
|
541
|
+
w && (n.value = C, d.value = w, y());
|
|
542
|
+
}), te(() => {
|
|
543
543
|
d.value && y();
|
|
544
|
-
}), (
|
|
545
|
-
|
|
546
|
-
class:
|
|
544
|
+
}), (C, w) => l.value ? (s(), r("div", Rt, [
|
|
545
|
+
i("div", {
|
|
546
|
+
class: $([
|
|
547
547
|
"transform transition-all duration-300 ease-out shadow-lg rounded-lg p-4 min-w-[300px] max-w-md",
|
|
548
548
|
u.value ? "translate-y-0 opacity-100" : "translate-y-full opacity-0",
|
|
549
549
|
n.value === "success" ? "bg-green-600" : "bg-red-600"
|
|
550
550
|
])
|
|
551
551
|
}, [
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
class:
|
|
552
|
+
i("div", Ut, [
|
|
553
|
+
i("div", Kt, [
|
|
554
|
+
i("div", {
|
|
555
|
+
class: $([
|
|
556
556
|
"flex p-2 rounded-full",
|
|
557
557
|
n.value === "success" ? "bg-green-700" : "bg-red-700"
|
|
558
558
|
])
|
|
559
559
|
}, [
|
|
560
|
-
n.value === "success" ? (s(),
|
|
560
|
+
n.value === "success" ? (s(), B(j(lt), {
|
|
561
561
|
key: 0,
|
|
562
562
|
class: "w-5 h-5 text-white"
|
|
563
|
-
})) :
|
|
564
|
-
n.value === "danger" ? (s(),
|
|
563
|
+
})) : D("", !0),
|
|
564
|
+
n.value === "danger" ? (s(), B(j(Le), {
|
|
565
565
|
key: 1,
|
|
566
566
|
class: "w-5 h-5 text-white"
|
|
567
|
-
})) :
|
|
567
|
+
})) : D("", !0)
|
|
568
568
|
], 2)
|
|
569
569
|
]),
|
|
570
|
-
|
|
571
|
-
|
|
570
|
+
i("div", Ht, [
|
|
571
|
+
i("p", Wt, A(d.value), 1)
|
|
572
572
|
]),
|
|
573
|
-
|
|
574
|
-
|
|
573
|
+
i("div", Pt, [
|
|
574
|
+
i("button", {
|
|
575
575
|
type: "button",
|
|
576
|
-
class:
|
|
576
|
+
class: $(["inline-flex text-white hover:bg-white/20 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-offset-green-600 focus:ring-white rounded-md p-1.5 transition-colors", [
|
|
577
577
|
n.value === "success" ? "hover:bg-green-700 focus:ring-offset-green-600" : "hover:bg-red-700 focus:ring-offset-red-600"
|
|
578
578
|
]]),
|
|
579
|
-
onClick:
|
|
579
|
+
onClick: V
|
|
580
580
|
}, [
|
|
581
|
-
|
|
581
|
+
i("span", qt, A(j(t)("Dismiss")), 1),
|
|
582
582
|
H(j(st), { class: "w-5 h-5" })
|
|
583
583
|
], 2)
|
|
584
584
|
])
|
|
585
585
|
])
|
|
586
586
|
], 2)
|
|
587
|
-
])) :
|
|
587
|
+
])) : D("", !0);
|
|
588
588
|
}
|
|
589
589
|
}, Xt = ["type", "disabled"], ve = /* @__PURE__ */ Object.assign({
|
|
590
590
|
inheritAttrs: !1
|
|
@@ -605,7 +605,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
605
605
|
}
|
|
606
606
|
},
|
|
607
607
|
setup(e) {
|
|
608
|
-
const a =
|
|
608
|
+
const a = ne(), t = e, l = {
|
|
609
609
|
primary: "bg-gradient-to-r from-blue-500 to-blue-600 text-white shadow-[0_6px_14px_rgba(37,99,235,0.14)] hover:from-blue-600 hover:to-blue-700 hover:shadow-[0_8px_18px_rgba(37,99,235,0.18)] focus:ring-blue-500 disabled:hover:from-blue-500 disabled:hover:to-blue-600",
|
|
610
610
|
success: "bg-gradient-to-r from-green-500 to-green-600 text-white shadow-[0_6px_14px_rgba(34,197,94,0.14)] hover:from-green-600 hover:to-green-700 hover:shadow-[0_8px_18px_rgba(34,197,94,0.18)] focus:ring-green-500 disabled:hover:from-green-500 disabled:hover:to-green-600",
|
|
611
611
|
secondary: "bg-gradient-to-r from-slate-700 to-slate-800 text-white shadow-[0_8px_18px_rgba(15,23,42,0.16)] hover:from-slate-800 hover:to-slate-900 hover:shadow-[0_10px_22px_rgba(15,23,42,0.22)] focus:ring-slate-500 disabled:hover:from-slate-700 disabled:hover:to-slate-800",
|
|
@@ -617,12 +617,12 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
617
617
|
l[n.value],
|
|
618
618
|
a.class
|
|
619
619
|
]);
|
|
620
|
-
return (u, f) => (s(),
|
|
620
|
+
return (u, f) => (s(), r("button", R(j(a), {
|
|
621
621
|
type: e.type,
|
|
622
622
|
disabled: e.disabled,
|
|
623
623
|
class: d.value
|
|
624
624
|
}), [
|
|
625
|
-
|
|
625
|
+
k(u.$slots, "default")
|
|
626
626
|
], 16, Xt));
|
|
627
627
|
}
|
|
628
628
|
}), Qt = ["value"], Yt = {
|
|
@@ -647,7 +647,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
647
647
|
t("update:checked", d);
|
|
648
648
|
}
|
|
649
649
|
});
|
|
650
|
-
return (d, u) =>
|
|
650
|
+
return (d, u) => re((s(), r("input", {
|
|
651
651
|
"onUpdate:modelValue": u[0] || (u[0] = (f) => n.value = f),
|
|
652
652
|
type: "checkbox",
|
|
653
653
|
value: e.value,
|
|
@@ -686,32 +686,32 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
686
686
|
d.value = !0;
|
|
687
687
|
}, f = () => {
|
|
688
688
|
d.value = !1;
|
|
689
|
-
},
|
|
689
|
+
}, V = (y) => {
|
|
690
690
|
t("update:modelValue", y.target.checked ? l.value : l.uncheckedValue);
|
|
691
691
|
};
|
|
692
|
-
return (y,
|
|
693
|
-
class:
|
|
692
|
+
return (y, C) => (s(), r("label", {
|
|
693
|
+
class: $(["inline-flex items-center gap-2 rounded-full border px-3 py-1 text-sm font-medium select-none transition-colors", [
|
|
694
694
|
n.value ? "bg-indigo-600 text-white border-indigo-600" : "text-gray-600 border-gray-200",
|
|
695
695
|
e.disabled ? "opacity-60 cursor-not-allowed" : "cursor-pointer",
|
|
696
696
|
d.value && !e.disabled ? "ring-2 ring-indigo-500/80 ring-offset-2 ring-offset-white" : ""
|
|
697
697
|
]])
|
|
698
698
|
}, [
|
|
699
|
-
|
|
699
|
+
i("input", {
|
|
700
700
|
type: "checkbox",
|
|
701
701
|
class: "sr-only",
|
|
702
702
|
checked: n.value,
|
|
703
703
|
disabled: e.disabled,
|
|
704
|
-
onChange:
|
|
704
|
+
onChange: V,
|
|
705
705
|
onFocus: u,
|
|
706
706
|
onBlur: f
|
|
707
707
|
}, null, 40, Jt),
|
|
708
|
-
|
|
709
|
-
class:
|
|
708
|
+
i("span", {
|
|
709
|
+
class: $(["inline-flex h-4 w-4 items-center justify-center border text-[10px] font-bold leading-none", [
|
|
710
710
|
n.value ? "border-current bg-white/15 text-current" : "border-current/70 text-transparent",
|
|
711
711
|
"rounded"
|
|
712
712
|
]])
|
|
713
713
|
}, " ✓ ", 2),
|
|
714
|
-
|
|
714
|
+
i("span", null, A(e.label), 1)
|
|
715
715
|
], 2));
|
|
716
716
|
}
|
|
717
717
|
}, Zt = { class: "relative flex items-center" }, el = {
|
|
@@ -747,69 +747,69 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
747
747
|
},
|
|
748
748
|
emits: ["update:modelValue", "blur"],
|
|
749
749
|
setup(e, { expose: a, emit: t }) {
|
|
750
|
-
const l = e, n = t, d =
|
|
751
|
-
const { class:
|
|
750
|
+
const l = e, n = t, d = ne(), u = O(null), f = O(!1), V = g(() => String(d.type ?? "text")), y = g(() => V.value === "password"), C = g(() => y.value && f.value ? "text" : V.value), w = g(() => l.modelValue ?? ""), h = g(() => {
|
|
751
|
+
const { class: m, type: L, ...z } = d;
|
|
752
752
|
return z.maxlength === void 0 && (z.maxlength = nl), z;
|
|
753
|
-
}),
|
|
753
|
+
}), S = g(() => [
|
|
754
754
|
"w-full min-w-0 max-w-full rounded-lg border border-slate-300 bg-white text-slate-900 shadow-sm focus:border-blue-500 focus:ring-2 focus:ring-blue-500/20 placeholder:text-slate-400",
|
|
755
755
|
d.class,
|
|
756
756
|
y.value ? "pr-10 pl-10" : ""
|
|
757
|
-
]),
|
|
757
|
+
]), v = () => {
|
|
758
758
|
f.value = !f.value;
|
|
759
|
-
},
|
|
760
|
-
if (
|
|
759
|
+
}, M = (m) => {
|
|
760
|
+
if (C.value !== "number")
|
|
761
761
|
return;
|
|
762
|
-
|
|
763
|
-
const
|
|
764
|
-
|
|
762
|
+
m.preventDefault();
|
|
763
|
+
const L = document.scrollingElement ?? document.documentElement ?? document.body;
|
|
764
|
+
L && (L.scrollTop += m.deltaY);
|
|
765
765
|
};
|
|
766
|
-
return
|
|
766
|
+
return te(() => {
|
|
767
767
|
u.value?.hasAttribute("autofocus") && u.value.focus();
|
|
768
|
-
}), a({ focus: () => u.value?.focus() }), (
|
|
769
|
-
y.value ? (s(),
|
|
768
|
+
}), a({ focus: () => u.value?.focus() }), (m, L) => (s(), r("div", Zt, [
|
|
769
|
+
y.value ? (s(), r("div", el, [
|
|
770
770
|
H(j(at), { class: "h-5 w-5 text-slate-400" })
|
|
771
|
-
])) :
|
|
772
|
-
|
|
771
|
+
])) : D("", !0),
|
|
772
|
+
i("input", R({
|
|
773
773
|
ref_key: "input",
|
|
774
774
|
ref: u
|
|
775
|
-
},
|
|
776
|
-
type:
|
|
777
|
-
class: [
|
|
775
|
+
}, h.value, {
|
|
776
|
+
type: C.value,
|
|
777
|
+
class: [S.value, l.disabled ? l.disabledClass : null],
|
|
778
778
|
value: w.value,
|
|
779
779
|
disabled: l.disabled,
|
|
780
|
-
onInput:
|
|
781
|
-
onBlur:
|
|
782
|
-
onWheel:
|
|
780
|
+
onInput: L[0] || (L[0] = (z) => n("update:modelValue", z.target.value)),
|
|
781
|
+
onBlur: L[1] || (L[1] = (z) => n("blur", z)),
|
|
782
|
+
onWheel: M
|
|
783
783
|
}), null, 16, tl),
|
|
784
|
-
y.value ? (s(),
|
|
784
|
+
y.value ? (s(), r("button", {
|
|
785
785
|
key: 1,
|
|
786
786
|
type: "button",
|
|
787
787
|
class: "absolute inset-y-0 right-0 flex items-center pr-3 text-slate-400 hover:text-slate-600 focus:outline-none",
|
|
788
788
|
"aria-label": f.value ? "Hide password" : "Show password",
|
|
789
|
-
onClick:
|
|
789
|
+
onClick: v
|
|
790
790
|
}, [
|
|
791
|
-
f.value ? (s(),
|
|
792
|
-
|
|
791
|
+
f.value ? (s(), r("svg", sl, [...L[2] || (L[2] = [
|
|
792
|
+
i("path", {
|
|
793
793
|
"stroke-linecap": "round",
|
|
794
794
|
"stroke-linejoin": "round",
|
|
795
795
|
"stroke-width": "2",
|
|
796
796
|
d: "M13.875 18.825A10.05 10.05 0 0112 19c-5 0-9.27-3.11-11-7 1.01-2.27 2.78-4.1 5-5.32m3.08-1.3A9.96 9.96 0 0112 5c5 0 9.27 3.11 11 7a11.03 11.03 0 01-4.16 4.91M15 12a3 3 0 00-3-3m0 0a3 3 0 00-2.94 3.59M3 3l18 18"
|
|
797
797
|
}, null, -1)
|
|
798
|
-
])])) : (s(),
|
|
799
|
-
|
|
798
|
+
])])) : (s(), r("svg", al, [...L[3] || (L[3] = [
|
|
799
|
+
i("path", {
|
|
800
800
|
"stroke-linecap": "round",
|
|
801
801
|
"stroke-linejoin": "round",
|
|
802
802
|
"stroke-width": "2",
|
|
803
803
|
d: "M15 12a3 3 0 11-6 0 3 3 0 016 0z"
|
|
804
804
|
}, null, -1),
|
|
805
|
-
|
|
805
|
+
i("path", {
|
|
806
806
|
"stroke-linecap": "round",
|
|
807
807
|
"stroke-linejoin": "round",
|
|
808
808
|
"stroke-width": "2",
|
|
809
809
|
d: "M2.458 12C3.732 7.943 7.523 5 12 5s8.268 2.943 9.542 7c-1.274 4.057-5.065 7-9.542 7S3.732 16.057 2.458 12z"
|
|
810
810
|
}, null, -1)
|
|
811
811
|
])]))
|
|
812
|
-
], 8, ll)) :
|
|
812
|
+
], 8, ll)) : D("", !0)
|
|
813
813
|
]));
|
|
814
814
|
}
|
|
815
815
|
}), ol = ["value", "disabled"], rl = 1e3, ze = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
@@ -831,35 +831,35 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
831
831
|
},
|
|
832
832
|
emits: ["update:modelValue"],
|
|
833
833
|
setup(e, { expose: a, emit: t }) {
|
|
834
|
-
const l = e, n = t, d =
|
|
835
|
-
const { class: w, ...
|
|
836
|
-
return
|
|
837
|
-
}),
|
|
834
|
+
const l = e, n = t, d = ne(), u = O(null), f = g(() => {
|
|
835
|
+
const { class: w, ...h } = d;
|
|
836
|
+
return h.maxlength === void 0 && (h.maxlength = rl), h;
|
|
837
|
+
}), V = g(() => [
|
|
838
838
|
"w-full min-w-0 max-w-full border-gray-300 focus:border-indigo-500 focus:ring-indigo-500 rounded-md shadow-sm",
|
|
839
839
|
l.autoResize ? "resize-none overflow-y-auto" : "resize-y",
|
|
840
840
|
d.class
|
|
841
841
|
]), y = () => {
|
|
842
842
|
!l.autoResize || !u.value || (u.value.style.height = "auto", u.value.style.height = `${u.value.scrollHeight}px`);
|
|
843
|
-
},
|
|
843
|
+
}, C = (w) => {
|
|
844
844
|
n("update:modelValue", w.target.value), y();
|
|
845
845
|
};
|
|
846
|
-
return
|
|
846
|
+
return te(() => {
|
|
847
847
|
u.value?.hasAttribute("autofocus") && u.value.focus(), fe(() => {
|
|
848
848
|
y();
|
|
849
849
|
});
|
|
850
|
-
}),
|
|
850
|
+
}), Z(() => l.modelValue, () => {
|
|
851
851
|
fe(() => {
|
|
852
852
|
y();
|
|
853
853
|
});
|
|
854
|
-
}), a({ focus: () => u.value?.focus() }), (w,
|
|
855
|
-
|
|
854
|
+
}), a({ focus: () => u.value?.focus() }), (w, h) => (s(), r("div", null, [
|
|
855
|
+
i("textarea", R({
|
|
856
856
|
ref_key: "textarea",
|
|
857
857
|
ref: u
|
|
858
858
|
}, f.value, {
|
|
859
|
-
class: [
|
|
859
|
+
class: [V.value, l.disabled ? l.disabledClass : ""],
|
|
860
860
|
value: l.modelValue,
|
|
861
861
|
disabled: l.disabled,
|
|
862
|
-
onInput:
|
|
862
|
+
onInput: C
|
|
863
863
|
}), null, 16, ol)
|
|
864
864
|
]));
|
|
865
865
|
}
|
|
@@ -949,67 +949,67 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
949
949
|
},
|
|
950
950
|
emits: ["update:modelValue"],
|
|
951
951
|
setup(e, { emit: a }) {
|
|
952
|
-
const t = e, l = a, n =
|
|
952
|
+
const t = e, l = a, n = ne(), d = O(!1), u = O(null), f = O(null), V = O(null), y = O({}), C = (b) => typeof b == "object" && b !== null, w = (b) => C(b) ? b[t.valueKey] : b, h = (b) => t.optionLabel ? t.optionLabel(b) : C(b) ? b[t.labelKey] ?? b[t.valueKey] ?? "" : b, S = (b) => !t.softDeleteAware || !C(b) ? !1 : !!b[t.deletedKey], v = g(() => String(t.modelValue ?? "")), M = g(() => !t.softDeleteAware || v.value === "" ? null : t.options.find((b) => S(b) && String(w(b) ?? "") === v.value) ?? null), m = g(() => t.softDeleteAware ? t.options.filter((b) => !S(b)) : t.options), L = g(() => {
|
|
953
953
|
if (t.modelValue === null || t.modelValue === void 0 || t.modelValue === "" && !t.options.some((E) => w(E) === ""))
|
|
954
954
|
return t.placeholder;
|
|
955
|
-
const
|
|
955
|
+
const b = t.options.find((E) => {
|
|
956
956
|
const N = w(E);
|
|
957
957
|
return N === t.modelValue || String(N) === String(t.modelValue);
|
|
958
958
|
});
|
|
959
|
-
return
|
|
960
|
-
}), z = (
|
|
959
|
+
return b ? h(b) : t.modelValue;
|
|
960
|
+
}), z = (b) => t.modelModifiers.number ? b === "" ? "" : Number(b) : b, Q = () => {
|
|
961
961
|
t.disabled || (d.value = !d.value);
|
|
962
|
-
},
|
|
963
|
-
const E = w(
|
|
962
|
+
}, ee = (b) => {
|
|
963
|
+
const E = w(b);
|
|
964
964
|
l("update:modelValue", z(E)), d.value = !1;
|
|
965
|
-
},
|
|
965
|
+
}, U = () => {
|
|
966
966
|
t.placeholderDisabled || (l("update:modelValue", z("")), d.value = !1);
|
|
967
|
-
},
|
|
967
|
+
}, P = () => {
|
|
968
968
|
if (!f.value)
|
|
969
969
|
return;
|
|
970
|
-
const
|
|
970
|
+
const b = f.value.getBoundingClientRect(), E = window.innerWidth, N = window.innerHeight, G = N - b.bottom - 8, J = b.top - 8, le = G < 240 && J > G, se = Math.min(b.width, Math.max(E - b.left - 16, 160)), ae = Math.max(Math.min(240, le ? J : G), 120);
|
|
971
971
|
y.value = {
|
|
972
972
|
position: "fixed",
|
|
973
|
-
left: `${Math.max(
|
|
973
|
+
left: `${Math.max(b.left, 8)}px`,
|
|
974
974
|
width: `${se}px`,
|
|
975
975
|
maxHeight: `${ae}px`,
|
|
976
976
|
zIndex: "9999",
|
|
977
|
-
...le ? { bottom: `${N -
|
|
977
|
+
...le ? { bottom: `${N - b.top + 1}px` } : { top: `${b.bottom - 1}px` }
|
|
978
978
|
};
|
|
979
|
-
},
|
|
980
|
-
const E = u.value?.contains(
|
|
979
|
+
}, Y = (b) => {
|
|
980
|
+
const E = u.value?.contains(b.target), N = V.value?.contains(b.target);
|
|
981
981
|
!E && !N && (d.value = !1);
|
|
982
982
|
};
|
|
983
|
-
return
|
|
984
|
-
document.addEventListener("click",
|
|
983
|
+
return te(() => {
|
|
984
|
+
document.addEventListener("click", Y), window.addEventListener("resize", P), window.addEventListener("scroll", P, !0);
|
|
985
985
|
}), Je(() => {
|
|
986
|
-
document.removeEventListener("click",
|
|
987
|
-
}),
|
|
988
|
-
|
|
989
|
-
}), (
|
|
986
|
+
document.removeEventListener("click", Y), window.removeEventListener("resize", P), window.removeEventListener("scroll", P, !0);
|
|
987
|
+
}), Z(d, async (b) => {
|
|
988
|
+
b && (await fe(), P());
|
|
989
|
+
}), (b, E) => (s(), r("div", {
|
|
990
990
|
ref_key: "rootRef",
|
|
991
991
|
ref: u,
|
|
992
992
|
class: "relative",
|
|
993
|
-
onClick:
|
|
993
|
+
onClick: Q
|
|
994
994
|
}, [
|
|
995
|
-
|
|
995
|
+
i("div", R({
|
|
996
996
|
ref_key: "triggerRef",
|
|
997
997
|
ref: f,
|
|
998
998
|
class: [
|
|
999
999
|
e.baseClass,
|
|
1000
|
-
|
|
1000
|
+
M.value ? e.deletedSelectedClass : e.normalTextClass,
|
|
1001
1001
|
"flex items-center justify-between cursor-pointer",
|
|
1002
1002
|
j(n).class
|
|
1003
1003
|
]
|
|
1004
1004
|
}, j(n), { tabindex: "0" }), [
|
|
1005
|
-
|
|
1006
|
-
class:
|
|
1007
|
-
},
|
|
1005
|
+
i("span", {
|
|
1006
|
+
class: $({ "text-gray-400": !e.modelValue && e.placeholder })
|
|
1007
|
+
}, A(L.value), 3),
|
|
1008
1008
|
H(j(xe), {
|
|
1009
|
-
class:
|
|
1009
|
+
class: $(["size-5 text-gray-400 transition-transform", { "rotate-180": d.value }])
|
|
1010
1010
|
}, null, 8, ["class"])
|
|
1011
1011
|
], 16),
|
|
1012
|
-
H(
|
|
1012
|
+
H(oe, {
|
|
1013
1013
|
"enter-active-class": "transition-all duration-200 ease-out",
|
|
1014
1014
|
"enter-from-class": "opacity-0 transform scale-95 -translate-y-2",
|
|
1015
1015
|
"enter-to-class": "opacity-100 transform scale-100 translate-y-0",
|
|
@@ -1018,45 +1018,45 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1018
1018
|
"leave-to-class": "opacity-0 transform scale-95 -translate-y-2"
|
|
1019
1019
|
}, {
|
|
1020
1020
|
default: F(() => [
|
|
1021
|
-
(s(),
|
|
1022
|
-
d.value ? (s(),
|
|
1021
|
+
(s(), B(Te, { to: "body" }, [
|
|
1022
|
+
d.value ? (s(), r("div", {
|
|
1023
1023
|
key: 0,
|
|
1024
1024
|
ref_key: "dropdownMenuRef",
|
|
1025
|
-
ref:
|
|
1026
|
-
class:
|
|
1025
|
+
ref: V,
|
|
1026
|
+
class: $(e.dropdownClass),
|
|
1027
1027
|
style: he(y.value)
|
|
1028
1028
|
}, [
|
|
1029
|
-
e.placeholder ? (s(),
|
|
1029
|
+
e.placeholder ? (s(), r("div", {
|
|
1030
1030
|
key: 0,
|
|
1031
|
-
class:
|
|
1031
|
+
class: $([
|
|
1032
1032
|
e.dropdownOptionClass,
|
|
1033
1033
|
e.placeholderClass,
|
|
1034
1034
|
{ "text-gray-400": !e.modelValue }
|
|
1035
1035
|
]),
|
|
1036
|
-
onClick: ye(
|
|
1037
|
-
},
|
|
1038
|
-
|
|
1036
|
+
onClick: ye(U, ["stop"])
|
|
1037
|
+
}, A(e.placeholder), 3)) : D("", !0),
|
|
1038
|
+
M.value ? (s(), r("div", {
|
|
1039
1039
|
key: 1,
|
|
1040
|
-
class:
|
|
1040
|
+
class: $([
|
|
1041
1041
|
e.dropdownOptionClass,
|
|
1042
1042
|
e.deletedOptionClass,
|
|
1043
1043
|
e.dropdownSelectedClass
|
|
1044
1044
|
])
|
|
1045
|
-
},
|
|
1046
|
-
(s(!0),
|
|
1045
|
+
}, A(h(M.value)), 3)) : D("", !0),
|
|
1046
|
+
(s(!0), r(q, null, X(m.value, (N) => (s(), r("div", {
|
|
1047
1047
|
key: String(w(N)),
|
|
1048
|
-
class:
|
|
1048
|
+
class: $([
|
|
1049
1049
|
e.dropdownOptionClass,
|
|
1050
1050
|
e.optionClass,
|
|
1051
1051
|
{
|
|
1052
1052
|
[e.dropdownSelectedClass]: w(N) === e.modelValue || String(w(N)) === String(e.modelValue),
|
|
1053
|
-
"rounded-b-lg": N ===
|
|
1054
|
-
"rounded-lg": !e.placeholder &&
|
|
1053
|
+
"rounded-b-lg": N === m.value[m.value.length - 1] && !e.placeholder,
|
|
1054
|
+
"rounded-lg": !e.placeholder && m.value.length === 1
|
|
1055
1055
|
}
|
|
1056
1056
|
]),
|
|
1057
|
-
onClick: ye((
|
|
1058
|
-
},
|
|
1059
|
-
], 6)) :
|
|
1057
|
+
onClick: ye((G) => ee(N), ["stop"])
|
|
1058
|
+
}, A(h(N)), 11, il))), 128))
|
|
1059
|
+
], 6)) : D("", !0)
|
|
1060
1060
|
]))
|
|
1061
1061
|
]),
|
|
1062
1062
|
_: 1
|
|
@@ -1150,7 +1150,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1150
1150
|
emits: ["update:modelValue"],
|
|
1151
1151
|
setup(e, { emit: a }) {
|
|
1152
1152
|
const t = a;
|
|
1153
|
-
return (l, n) => (s(),
|
|
1153
|
+
return (l, n) => (s(), B(Ee, R({
|
|
1154
1154
|
"model-value": e.modelValue,
|
|
1155
1155
|
"model-modifiers": e.modelModifiers,
|
|
1156
1156
|
options: e.options,
|
|
@@ -1174,7 +1174,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1174
1174
|
"onUpdate:modelValue": n[0] || (n[0] = (d) => t("update:modelValue", d))
|
|
1175
1175
|
}, l.$attrs), null, 16, ["model-value", "model-modifiers", "options", "placeholder", "placeholder-disabled", "disabled", "soft-delete-aware", "label-key", "value-key", "deleted-key", "option-label", "base-class", "normal-text-class", "deleted-selected-class", "option-class", "deleted-option-class", "placeholder-class", "dropdown-class", "dropdown-option-class", "dropdown-selected-class"]));
|
|
1176
1176
|
}
|
|
1177
|
-
}, dl = ["type", "max", "value", "disabled"],
|
|
1177
|
+
}, dl = ["type", "max", "value", "disabled"], Ne = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1178
1178
|
__name: "DateInput",
|
|
1179
1179
|
props: {
|
|
1180
1180
|
modelValue: {
|
|
@@ -1196,41 +1196,41 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1196
1196
|
},
|
|
1197
1197
|
emits: ["update:modelValue"],
|
|
1198
1198
|
setup(e, { expose: a, emit: t }) {
|
|
1199
|
-
const l = e, n = t, d =
|
|
1200
|
-
const
|
|
1201
|
-
return typeof
|
|
1202
|
-
}),
|
|
1203
|
-
const { class:
|
|
1204
|
-
return
|
|
1199
|
+
const l = e, n = t, d = ne(), u = O(null), f = g(() => l.withTimestamp ? "datetime-local" : "date"), V = g(() => l.modelValue ?? ""), y = g(() => {
|
|
1200
|
+
const v = l.withTimestamp ? "9999-12-31T23:59" : "9999-12-31", M = d.max;
|
|
1201
|
+
return typeof M != "string" || M === "" || M > v ? v : M;
|
|
1202
|
+
}), C = g(() => {
|
|
1203
|
+
const { class: v, type: M, ...m } = d;
|
|
1204
|
+
return m;
|
|
1205
1205
|
}), w = g(() => [
|
|
1206
1206
|
"w-full border-gray-300 focus:border-indigo-500 focus:ring-indigo-500 rounded-md shadow-sm",
|
|
1207
1207
|
d.class
|
|
1208
|
-
]),
|
|
1209
|
-
const
|
|
1210
|
-
if (!
|
|
1208
|
+
]), h = (v) => typeof v != "string" ? "" : v.replace(/^(\d{4})\d+/, "$1"), S = (v) => {
|
|
1209
|
+
const M = v.target;
|
|
1210
|
+
if (!M)
|
|
1211
1211
|
return;
|
|
1212
|
-
const
|
|
1213
|
-
|
|
1212
|
+
const m = String(M.value ?? ""), L = h(m);
|
|
1213
|
+
L !== m && (M.value = L), n("update:modelValue", L);
|
|
1214
1214
|
};
|
|
1215
|
-
return
|
|
1215
|
+
return te(() => {
|
|
1216
1216
|
u.value?.hasAttribute("autofocus") && u.value.focus();
|
|
1217
|
-
}), a({ focus: () => u.value?.focus() }), (
|
|
1217
|
+
}), a({ focus: () => u.value?.focus() }), (v, M) => (s(), r("input", R({
|
|
1218
1218
|
ref_key: "input",
|
|
1219
1219
|
ref: u
|
|
1220
|
-
},
|
|
1220
|
+
}, C.value, {
|
|
1221
1221
|
type: f.value,
|
|
1222
1222
|
max: y.value,
|
|
1223
1223
|
class: [w.value, l.disabled ? l.disabledClass : null],
|
|
1224
|
-
value:
|
|
1224
|
+
value: V.value,
|
|
1225
1225
|
disabled: l.disabled,
|
|
1226
|
-
onInput:
|
|
1227
|
-
onChange:
|
|
1226
|
+
onInput: S,
|
|
1227
|
+
onChange: S
|
|
1228
1228
|
}), null, 16, dl));
|
|
1229
1229
|
}
|
|
1230
1230
|
}), ul = { class: "relative" }, cl = { class: "absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none" }, fl = ["accept"], gl = {
|
|
1231
1231
|
key: 0,
|
|
1232
1232
|
class: "mt-4 p-4 bg-gray-50 rounded-lg border border-gray-200"
|
|
1233
|
-
}, pl = { class: "flex items-center space-x-4" }, ml = ["src"], bl = { class: "text-sm font-medium text-gray-900" }, yl = { class: "text-xs text-gray-500" },
|
|
1233
|
+
}, pl = { class: "flex items-center space-x-4" }, ml = ["src"], bl = { class: "text-sm font-medium text-gray-900" }, yl = { class: "text-xs text-gray-500" }, Re = {
|
|
1234
1234
|
__name: "ImageInput",
|
|
1235
1235
|
props: {
|
|
1236
1236
|
currentImageUrl: {
|
|
@@ -1260,31 +1260,31 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1260
1260
|
const u = d.target.files?.[0] ?? null;
|
|
1261
1261
|
t("update:modelValue", u);
|
|
1262
1262
|
};
|
|
1263
|
-
return (d, u) => (s(),
|
|
1264
|
-
|
|
1265
|
-
|
|
1263
|
+
return (d, u) => (s(), r("div", null, [
|
|
1264
|
+
i("div", ul, [
|
|
1265
|
+
i("div", cl, [
|
|
1266
1266
|
H(j(nt), { class: "size-5 text-gray-400" })
|
|
1267
1267
|
]),
|
|
1268
|
-
|
|
1268
|
+
i("input", R(e.attrs, {
|
|
1269
1269
|
type: "file",
|
|
1270
1270
|
accept: e.accept,
|
|
1271
1271
|
class: "block w-full pl-10 pr-4 py-3 border border-gray-300 rounded-lg bg-white text-sm file:mr-4 file:py-2 file:px-4 file:rounded-md file:border-0 file:text-sm file:font-medium file:bg-blue-50 file:text-blue-700 hover:file:bg-blue-100 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all duration-200 cursor-pointer",
|
|
1272
1272
|
onChange: n
|
|
1273
1273
|
}), null, 16, fl)
|
|
1274
1274
|
]),
|
|
1275
|
-
l.currentImageUrl ? (s(),
|
|
1276
|
-
|
|
1277
|
-
|
|
1275
|
+
l.currentImageUrl ? (s(), r("div", gl, [
|
|
1276
|
+
i("div", pl, [
|
|
1277
|
+
i("img", {
|
|
1278
1278
|
src: l.currentImageUrl,
|
|
1279
1279
|
alt: "Current logo",
|
|
1280
1280
|
class: "h-16 w-auto max-w-24 object-contain rounded-lg shadow-sm"
|
|
1281
1281
|
}, null, 8, ml),
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1282
|
+
i("div", null, [
|
|
1283
|
+
i("p", bl, A(l.currentLabel), 1),
|
|
1284
|
+
i("p", yl, A(l.currentSubtext), 1)
|
|
1285
1285
|
])
|
|
1286
1286
|
])
|
|
1287
|
-
])) :
|
|
1287
|
+
])) : D("", !0)
|
|
1288
1288
|
]));
|
|
1289
1289
|
}
|
|
1290
1290
|
}, vl = { class: "flex h-12 overflow-hidden rounded-lg border border-gray-300 text-sm" }, hl = ["disabled", "onClick"], Ue = {
|
|
@@ -1306,19 +1306,19 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1306
1306
|
emits: ["update:modelValue"],
|
|
1307
1307
|
setup(e, { emit: a }) {
|
|
1308
1308
|
const t = a, l = e, n = g(() => l.options.map((f) => f == null ? "" : String(f).trim()).filter((f) => f !== "")), d = (f) => String(f) === String(l.modelValue ?? ""), u = (f) => t("update:modelValue", f);
|
|
1309
|
-
return (f,
|
|
1310
|
-
(s(!0),
|
|
1311
|
-
key: `notation-${
|
|
1309
|
+
return (f, V) => (s(), r("div", vl, [
|
|
1310
|
+
(s(!0), r(q, null, X(n.value, (y, C) => (s(), r("button", {
|
|
1311
|
+
key: `notation-${C}-${y}`,
|
|
1312
1312
|
type: "button",
|
|
1313
|
-
class:
|
|
1314
|
-
|
|
1315
|
-
|
|
1313
|
+
class: $(["flex-1 border-l border-gray-300 px-2 text-center font-semibold transition-colors duration-150 first:border-l-0", [
|
|
1314
|
+
C === 0 ? "rounded-l-lg" : "",
|
|
1315
|
+
C === n.value.length - 1 ? "rounded-r-lg" : "",
|
|
1316
1316
|
d(y) ? "bg-indigo-600 text-white" : "bg-white text-gray-700 hover:bg-gray-50",
|
|
1317
1317
|
"focus-visible:ring-2 "
|
|
1318
1318
|
]]),
|
|
1319
1319
|
disabled: e.disabled,
|
|
1320
1320
|
onClick: (w) => u(y)
|
|
1321
|
-
},
|
|
1321
|
+
}, A(y), 11, hl))), 128))
|
|
1322
1322
|
]));
|
|
1323
1323
|
}
|
|
1324
1324
|
}, xl = ["name", "value", "checked", "disabled"], Ke = {
|
|
@@ -1351,26 +1351,26 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1351
1351
|
d.value = !0;
|
|
1352
1352
|
}, f = () => {
|
|
1353
1353
|
d.value = !1;
|
|
1354
|
-
},
|
|
1355
|
-
return (y,
|
|
1356
|
-
class:
|
|
1354
|
+
}, V = () => t("update:modelValue", l.value);
|
|
1355
|
+
return (y, C) => (s(), r("label", {
|
|
1356
|
+
class: $(["inline-flex items-center rounded-full border px-3 py-1 text-sm font-medium select-none transition-colors", [
|
|
1357
1357
|
n.value ? "bg-indigo-600 text-white border-indigo-600" : "text-gray-600 border-gray-200",
|
|
1358
1358
|
e.disabled ? "opacity-60 cursor-not-allowed" : "cursor-pointer",
|
|
1359
1359
|
d.value && !e.disabled ? "ring-2 ring-indigo-500/80 ring-offset-2 ring-offset-white" : ""
|
|
1360
1360
|
]])
|
|
1361
1361
|
}, [
|
|
1362
|
-
|
|
1362
|
+
i("input", {
|
|
1363
1363
|
type: "radio",
|
|
1364
1364
|
class: "sr-only",
|
|
1365
1365
|
name: e.name,
|
|
1366
1366
|
value: e.value,
|
|
1367
1367
|
checked: n.value,
|
|
1368
1368
|
disabled: e.disabled,
|
|
1369
|
-
onChange:
|
|
1369
|
+
onChange: V,
|
|
1370
1370
|
onFocus: u,
|
|
1371
1371
|
onBlur: f
|
|
1372
1372
|
}, null, 40, xl),
|
|
1373
|
-
|
|
1373
|
+
i("span", null, A(n.value ? "✓" : "○") + " " + A(e.label), 1)
|
|
1374
1374
|
], 2));
|
|
1375
1375
|
}
|
|
1376
1376
|
}, wl = { class: "flex flex-wrap gap-3" }, He = {
|
|
@@ -1396,14 +1396,14 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1396
1396
|
emits: ["update:modelValue"],
|
|
1397
1397
|
setup(e, { emit: a }) {
|
|
1398
1398
|
const t = a, l = e, n = g(() => l.options.map((u) => u == null ? "" : String(u).trim()).filter((u) => u !== "")), d = (u) => t("update:modelValue", u);
|
|
1399
|
-
return (u, f) => (s(),
|
|
1400
|
-
(s(!0),
|
|
1401
|
-
key: `radio-${e.name ?? "group"}-${
|
|
1399
|
+
return (u, f) => (s(), r("div", wl, [
|
|
1400
|
+
(s(!0), r(q, null, X(n.value, (V) => (s(), B(me, {
|
|
1401
|
+
key: `radio-${e.name ?? "group"}-${V}`,
|
|
1402
1402
|
type: "radio-input",
|
|
1403
1403
|
"model-value": l.modelValue,
|
|
1404
1404
|
name: e.name,
|
|
1405
|
-
value:
|
|
1406
|
-
label:
|
|
1405
|
+
value: V,
|
|
1406
|
+
label: V,
|
|
1407
1407
|
disabled: e.disabled,
|
|
1408
1408
|
"onUpdate:modelValue": d
|
|
1409
1409
|
}, null, 8, ["model-value", "name", "value", "label", "disabled"]))), 128))
|
|
@@ -1415,7 +1415,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1415
1415
|
}, $l = {
|
|
1416
1416
|
key: 14,
|
|
1417
1417
|
class: "flex items-center mt-2 text-sm text-red-600"
|
|
1418
|
-
},
|
|
1418
|
+
}, ue = "block w-full rounded-lg border border-slate-300 bg-white px-4 py-3 text-sm text-slate-900 placeholder:text-slate-400 shadow-sm transition-all duration-200 focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20", me = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
1419
1419
|
__name: "InputGroup",
|
|
1420
1420
|
props: {
|
|
1421
1421
|
type: {
|
|
@@ -1533,7 +1533,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1533
1533
|
},
|
|
1534
1534
|
emits: ["update:modelValue", "blur"],
|
|
1535
1535
|
setup(e, { emit: a }) {
|
|
1536
|
-
const t = e, l = a, n =
|
|
1536
|
+
const t = e, l = a, n = ne(), d = (K) => l("update:modelValue", K), u = g(() => !!t.errorMessage), f = g(() => S.value || v.value), V = g(() => {
|
|
1537
1537
|
const K = n.id;
|
|
1538
1538
|
return typeof K == "string" && K !== "" ? K : void 0;
|
|
1539
1539
|
}), y = [
|
|
@@ -1548,22 +1548,22 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1548
1548
|
"month",
|
|
1549
1549
|
"week",
|
|
1550
1550
|
"color"
|
|
1551
|
-
],
|
|
1551
|
+
], C = [], w = g(() => t.type === "image"), h = g(() => t.type === "notation"), S = g(() => t.type === "checkbox-input"), v = g(() => t.type === "radio-input"), M = g(() => t.type === "checkbox"), m = g(() => t.type === "radio"), L = g(() => t.type === "date" || t.type === "datetime-local"), z = g(() => t.type === "textarea"), Q = g(() => t.type === "select"), ee = g(() => y.includes(t.type)), U = g(() => C.includes(t.type)), P = g(() => ({
|
|
1552
1552
|
...n,
|
|
1553
|
-
class: [
|
|
1553
|
+
class: [ue, n.class],
|
|
1554
1554
|
type: t.type,
|
|
1555
1555
|
modelValue: t.modelValue,
|
|
1556
1556
|
disabled: t.disabled,
|
|
1557
1557
|
disabledClass: t.disabledClass
|
|
1558
|
-
})),
|
|
1558
|
+
})), Y = g(() => ({
|
|
1559
1559
|
...n,
|
|
1560
|
-
class: [
|
|
1560
|
+
class: [ue, n.class],
|
|
1561
1561
|
modelValue: t.modelValue,
|
|
1562
1562
|
disabled: t.disabled,
|
|
1563
1563
|
disabledClass: t.disabledClass
|
|
1564
|
-
})),
|
|
1564
|
+
})), b = g(() => ({
|
|
1565
1565
|
...n,
|
|
1566
|
-
class: [
|
|
1566
|
+
class: [ue, n.class],
|
|
1567
1567
|
modelValue: t.modelValue,
|
|
1568
1568
|
withTimestamp: t.type === "datetime-local" || t.withTimestamp,
|
|
1569
1569
|
disabled: t.disabled,
|
|
@@ -1571,7 +1571,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1571
1571
|
})), E = g(() => {
|
|
1572
1572
|
const K = {
|
|
1573
1573
|
...n,
|
|
1574
|
-
class: [
|
|
1574
|
+
class: [ue, n.class],
|
|
1575
1575
|
modelValue: t.modelValue,
|
|
1576
1576
|
modelModifiers: t.modelModifiers,
|
|
1577
1577
|
options: t.options,
|
|
@@ -1590,12 +1590,12 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1590
1590
|
modelValue: t.modelValue,
|
|
1591
1591
|
options: t.options,
|
|
1592
1592
|
disabled: t.disabled
|
|
1593
|
-
})),
|
|
1593
|
+
})), G = g(() => ({
|
|
1594
1594
|
...n,
|
|
1595
1595
|
modelValue: t.modelValue,
|
|
1596
1596
|
options: t.options,
|
|
1597
1597
|
disabled: t.disabled
|
|
1598
|
-
})),
|
|
1598
|
+
})), J = g(() => ({
|
|
1599
1599
|
...n,
|
|
1600
1600
|
modelValue: t.modelValue,
|
|
1601
1601
|
options: t.options,
|
|
@@ -1620,60 +1620,60 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1620
1620
|
currentLabel: t.currentLabel,
|
|
1621
1621
|
currentSubtext: t.currentSubtext
|
|
1622
1622
|
}));
|
|
1623
|
-
return (K,
|
|
1624
|
-
e.label && !f.value ? (s(),
|
|
1623
|
+
return (K, _) => (s(), r("div", null, [
|
|
1624
|
+
e.label && !f.value ? (s(), r("label", {
|
|
1625
1625
|
key: 0,
|
|
1626
|
-
for:
|
|
1626
|
+
for: V.value,
|
|
1627
1627
|
class: "text-base font-semibold text-gray-900 mb-1 block"
|
|
1628
|
-
},
|
|
1629
|
-
e.helperText && !f.value ? (s(),
|
|
1630
|
-
z.value ? (s(),
|
|
1631
|
-
"onUpdate:modelValue":
|
|
1632
|
-
onBlur:
|
|
1633
|
-
}), null, 16)) :
|
|
1634
|
-
"onUpdate:modelValue":
|
|
1635
|
-
onBlur:
|
|
1636
|
-
}), null, 16)) :
|
|
1637
|
-
"onUpdate:modelValue":
|
|
1638
|
-
onBlur:
|
|
1639
|
-
}), null, 16)) :
|
|
1640
|
-
"onUpdate:modelValue":
|
|
1641
|
-
onBlur:
|
|
1642
|
-
}), null, 16)) : w.value ? (s(),
|
|
1643
|
-
"onUpdate:modelValue":
|
|
1644
|
-
onBlur:
|
|
1645
|
-
}), null, 16)) :
|
|
1646
|
-
"onUpdate:modelValue":
|
|
1647
|
-
onBlur:
|
|
1648
|
-
}), null, 16)) :
|
|
1649
|
-
"onUpdate:modelValue":
|
|
1650
|
-
onBlur:
|
|
1651
|
-
}), null, 16)) :
|
|
1652
|
-
"onUpdate:modelValue":
|
|
1653
|
-
onBlur:
|
|
1654
|
-
}), null, 16)) :
|
|
1655
|
-
"onUpdate:modelValue":
|
|
1656
|
-
onBlur:
|
|
1657
|
-
}), null, 16)) :
|
|
1658
|
-
"onUpdate:modelValue":
|
|
1659
|
-
onBlur:
|
|
1660
|
-
}), null, 16)) :
|
|
1628
|
+
}, A(e.label), 9, kl)) : D("", !0),
|
|
1629
|
+
e.helperText && !f.value ? (s(), r("span", Sl, A(e.helperText), 1)) : D("", !0),
|
|
1630
|
+
z.value ? (s(), B(ze, R({ key: 2 }, Y.value, {
|
|
1631
|
+
"onUpdate:modelValue": _[0] || (_[0] = (T) => l("update:modelValue", T)),
|
|
1632
|
+
onBlur: _[1] || (_[1] = (T) => l("blur", T))
|
|
1633
|
+
}), null, 16)) : Q.value ? (s(), B(Fe, R({ key: 3 }, E.value, {
|
|
1634
|
+
"onUpdate:modelValue": _[2] || (_[2] = (T) => l("update:modelValue", T)),
|
|
1635
|
+
onBlur: _[3] || (_[3] = (T) => l("blur", T))
|
|
1636
|
+
}), null, 16)) : L.value ? (s(), B(Ne, R({ key: 4 }, b.value, {
|
|
1637
|
+
"onUpdate:modelValue": _[4] || (_[4] = (T) => l("update:modelValue", T)),
|
|
1638
|
+
onBlur: _[5] || (_[5] = (T) => l("blur", T))
|
|
1639
|
+
}), null, 16)) : ee.value ? (s(), B(je, R({ key: 5 }, P.value, {
|
|
1640
|
+
"onUpdate:modelValue": _[6] || (_[6] = (T) => l("update:modelValue", T)),
|
|
1641
|
+
onBlur: _[7] || (_[7] = (T) => l("blur", T))
|
|
1642
|
+
}), null, 16)) : w.value ? (s(), B(Re, R({ key: 6 }, ae.value, {
|
|
1643
|
+
"onUpdate:modelValue": _[8] || (_[8] = (T) => l("update:modelValue", T)),
|
|
1644
|
+
onBlur: _[9] || (_[9] = (T) => l("blur", T))
|
|
1645
|
+
}), null, 16)) : S.value ? (s(), B(Oe, R({ key: 7 }, le.value, {
|
|
1646
|
+
"onUpdate:modelValue": _[10] || (_[10] = (T) => l("update:modelValue", T)),
|
|
1647
|
+
onBlur: _[11] || (_[11] = (T) => l("blur", T))
|
|
1648
|
+
}), null, 16)) : v.value ? (s(), B(Ke, R({ key: 8 }, se.value, {
|
|
1649
|
+
"onUpdate:modelValue": _[12] || (_[12] = (T) => l("update:modelValue", T)),
|
|
1650
|
+
onBlur: _[13] || (_[13] = (T) => l("blur", T))
|
|
1651
|
+
}), null, 16)) : h.value ? (s(), B(Ue, R({ key: 9 }, N.value, {
|
|
1652
|
+
"onUpdate:modelValue": _[14] || (_[14] = (T) => l("update:modelValue", T)),
|
|
1653
|
+
onBlur: _[15] || (_[15] = (T) => l("blur", T))
|
|
1654
|
+
}), null, 16)) : M.value ? (s(), B(We, R({ key: 10 }, G.value, {
|
|
1655
|
+
"onUpdate:modelValue": _[16] || (_[16] = (T) => l("update:modelValue", T)),
|
|
1656
|
+
onBlur: _[17] || (_[17] = (T) => l("blur", T))
|
|
1657
|
+
}), null, 16)) : m.value ? (s(), B(He, R({ key: 11 }, J.value, {
|
|
1658
|
+
"onUpdate:modelValue": _[18] || (_[18] = (T) => l("update:modelValue", T)),
|
|
1659
|
+
onBlur: _[19] || (_[19] = (T) => l("blur", T))
|
|
1660
|
+
}), null, 16)) : U.value ? k(K.$slots, "unsupported-type", {
|
|
1661
1661
|
key: 12,
|
|
1662
1662
|
type: e.type,
|
|
1663
1663
|
modelValue: e.modelValue,
|
|
1664
1664
|
updateValue: d,
|
|
1665
1665
|
attrs: j(n)
|
|
1666
|
-
}) :
|
|
1666
|
+
}) : k(K.$slots, "unsupported-type", {
|
|
1667
1667
|
key: 13,
|
|
1668
1668
|
type: e.type,
|
|
1669
1669
|
modelValue: e.modelValue,
|
|
1670
1670
|
updateValue: d,
|
|
1671
1671
|
attrs: j(n)
|
|
1672
1672
|
}),
|
|
1673
|
-
u.value ? (s(),
|
|
1673
|
+
u.value ? (s(), r("div", $l, [
|
|
1674
1674
|
H(j(ot), { class: "mr-1 h-4 w-4 flex-shrink-0" }),
|
|
1675
|
-
|
|
1676
|
-
])) :
|
|
1675
|
+
i("span", null, A(e.errorMessage), 1)
|
|
1676
|
+
])) : D("", !0)
|
|
1677
1677
|
]));
|
|
1678
1678
|
}
|
|
1679
1679
|
}), Cl = { class: "flex flex-wrap gap-3" }, We = {
|
|
@@ -1694,12 +1694,12 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1694
1694
|
},
|
|
1695
1695
|
emits: ["update:modelValue"],
|
|
1696
1696
|
setup(e, { emit: a }) {
|
|
1697
|
-
const t = a, l = e, n = g(() => l.options.map((f) => f == null ? "" : String(f).trim()).filter((f) => f !== "")), d = (f) => Array.isArray(l.modelValue) && l.modelValue.includes(f), u = (f,
|
|
1698
|
-
const y = Array.isArray(l.modelValue) ? [...l.modelValue] : [],
|
|
1699
|
-
|
|
1697
|
+
const t = a, l = e, n = g(() => l.options.map((f) => f == null ? "" : String(f).trim()).filter((f) => f !== "")), d = (f) => Array.isArray(l.modelValue) && l.modelValue.includes(f), u = (f, V) => {
|
|
1698
|
+
const y = Array.isArray(l.modelValue) ? [...l.modelValue] : [], C = y.indexOf(f);
|
|
1699
|
+
V && C === -1 ? y.push(f) : !V && C !== -1 && y.splice(C, 1), t("update:modelValue", y);
|
|
1700
1700
|
};
|
|
1701
|
-
return (f,
|
|
1702
|
-
(s(!0),
|
|
1701
|
+
return (f, V) => (s(), r("div", Cl, [
|
|
1702
|
+
(s(!0), r(q, null, X(n.value, (y) => (s(), B(me, {
|
|
1703
1703
|
key: `checkbox-${y}`,
|
|
1704
1704
|
type: "checkbox-input",
|
|
1705
1705
|
"model-value": d(y),
|
|
@@ -1707,7 +1707,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1707
1707
|
"unchecked-value": !1,
|
|
1708
1708
|
label: y,
|
|
1709
1709
|
disabled: e.disabled,
|
|
1710
|
-
"onUpdate:modelValue": (
|
|
1710
|
+
"onUpdate:modelValue": (C) => u(y, C)
|
|
1711
1711
|
}, null, 8, ["model-value", "label", "disabled", "onUpdate:modelValue"]))), 128))
|
|
1712
1712
|
]));
|
|
1713
1713
|
}
|
|
@@ -1741,20 +1741,20 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1741
1741
|
n.value?.close(), d.value = !1;
|
|
1742
1742
|
}, 200);
|
|
1743
1743
|
};
|
|
1744
|
-
|
|
1744
|
+
Z(() => t.show, () => {
|
|
1745
1745
|
t.show ? u() : f();
|
|
1746
|
-
}),
|
|
1746
|
+
}), te(() => {
|
|
1747
1747
|
t.show && u();
|
|
1748
1748
|
});
|
|
1749
|
-
const
|
|
1749
|
+
const V = () => {
|
|
1750
1750
|
t.closeable && l("close");
|
|
1751
|
-
}, y = (
|
|
1752
|
-
|
|
1751
|
+
}, y = (h) => {
|
|
1752
|
+
h.key === "Escape" && (h.preventDefault(), t.show && V());
|
|
1753
1753
|
};
|
|
1754
|
-
|
|
1754
|
+
te(() => document.addEventListener("keydown", y)), Ae(() => {
|
|
1755
1755
|
document.removeEventListener("keydown", y), document.body.style.overflow = null;
|
|
1756
1756
|
});
|
|
1757
|
-
const
|
|
1757
|
+
const C = g(() => ({
|
|
1758
1758
|
sm: "sm:max-w-sm",
|
|
1759
1759
|
md: "sm:max-w-md",
|
|
1760
1760
|
lg: "sm:max-w-lg",
|
|
@@ -1770,15 +1770,15 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1770
1770
|
return "items-center justify-center";
|
|
1771
1771
|
}
|
|
1772
1772
|
});
|
|
1773
|
-
return (
|
|
1773
|
+
return (h, S) => (s(), r("dialog", {
|
|
1774
1774
|
class: "z-50 m-0 min-h-full min-w-full overflow-y-auto bg-transparent backdrop:bg-transparent",
|
|
1775
1775
|
ref_key: "dialog",
|
|
1776
1776
|
ref: n
|
|
1777
1777
|
}, [
|
|
1778
|
-
|
|
1779
|
-
class:
|
|
1778
|
+
i("div", {
|
|
1779
|
+
class: $(["fixed inset-0 overflow-y-auto px-4 py-6 sm:px-0 z-50 flex", w.value])
|
|
1780
1780
|
}, [
|
|
1781
|
-
H(
|
|
1781
|
+
H(oe, {
|
|
1782
1782
|
"enter-active-class": "ease-out duration-300",
|
|
1783
1783
|
"enter-from-class": "opacity-0",
|
|
1784
1784
|
"enter-to-class": "opacity-100",
|
|
@@ -1787,18 +1787,18 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1787
1787
|
"leave-to-class": "opacity-0"
|
|
1788
1788
|
}, {
|
|
1789
1789
|
default: F(() => [
|
|
1790
|
-
|
|
1790
|
+
re(i("div", {
|
|
1791
1791
|
class: "fixed inset-0 z-40 transform transition-all",
|
|
1792
|
-
onClick:
|
|
1793
|
-
}, [
|
|
1794
|
-
|
|
1792
|
+
onClick: V
|
|
1793
|
+
}, [...S[0] || (S[0] = [
|
|
1794
|
+
i("div", { class: "absolute inset-0 bg-gray-500 opacity-75" }, null, -1)
|
|
1795
1795
|
])], 512), [
|
|
1796
|
-
[
|
|
1796
|
+
[ce, e.show]
|
|
1797
1797
|
])
|
|
1798
1798
|
]),
|
|
1799
1799
|
_: 1
|
|
1800
1800
|
}),
|
|
1801
|
-
H(
|
|
1801
|
+
H(oe, {
|
|
1802
1802
|
"enter-active-class": "ease-out duration-300",
|
|
1803
1803
|
"enter-from-class": "opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",
|
|
1804
1804
|
"enter-to-class": "opacity-100 translate-y-0 sm:scale-100",
|
|
@@ -1807,12 +1807,12 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1807
1807
|
"leave-to-class": "opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
|
|
1808
1808
|
}, {
|
|
1809
1809
|
default: F(() => [
|
|
1810
|
-
|
|
1811
|
-
class:
|
|
1810
|
+
re(i("div", {
|
|
1811
|
+
class: $(["relative z-50 mb-6 bg-white rounded-lg overflow-hidden shadow-xl transform transition-all sm:w-full sm:mx-auto", C.value])
|
|
1812
1812
|
}, [
|
|
1813
|
-
d.value ?
|
|
1813
|
+
d.value ? k(h.$slots, "default", { key: 0 }) : D("", !0)
|
|
1814
1814
|
], 2), [
|
|
1815
|
-
[
|
|
1815
|
+
[ce, e.show]
|
|
1816
1816
|
])
|
|
1817
1817
|
]),
|
|
1818
1818
|
_: 3
|
|
@@ -1846,7 +1846,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1846
1846
|
const t = a, l = () => {
|
|
1847
1847
|
t("close");
|
|
1848
1848
|
};
|
|
1849
|
-
return (n, d) => (s(),
|
|
1849
|
+
return (n, d) => (s(), B($e, {
|
|
1850
1850
|
show: e.show,
|
|
1851
1851
|
"max-width": e.maxWidth,
|
|
1852
1852
|
closeable: e.closeable,
|
|
@@ -1854,23 +1854,23 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1854
1854
|
onClose: l
|
|
1855
1855
|
}, {
|
|
1856
1856
|
default: F(() => [
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1857
|
+
i("div", Vl, [
|
|
1858
|
+
i("div", _l, [
|
|
1859
|
+
i("div", Tl, [
|
|
1860
1860
|
H(j(Le), { class: "size-6 text-red-600" })
|
|
1861
1861
|
]),
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1862
|
+
i("div", Al, [
|
|
1863
|
+
i("h3", Bl, [
|
|
1864
|
+
k(n.$slots, "title")
|
|
1865
1865
|
]),
|
|
1866
|
-
|
|
1867
|
-
|
|
1866
|
+
i("div", Ll, [
|
|
1867
|
+
k(n.$slots, "content")
|
|
1868
1868
|
])
|
|
1869
1869
|
])
|
|
1870
1870
|
])
|
|
1871
1871
|
]),
|
|
1872
|
-
|
|
1873
|
-
|
|
1872
|
+
i("div", Il, [
|
|
1873
|
+
k(n.$slots, "footer")
|
|
1874
1874
|
])
|
|
1875
1875
|
]),
|
|
1876
1876
|
_: 3
|
|
@@ -1897,29 +1897,29 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1897
1897
|
const t = a, l = () => {
|
|
1898
1898
|
t("close");
|
|
1899
1899
|
};
|
|
1900
|
-
return (n, d) => (s(),
|
|
1900
|
+
return (n, d) => (s(), B($e, {
|
|
1901
1901
|
show: e.show,
|
|
1902
1902
|
"max-width": e.maxWidth,
|
|
1903
1903
|
closeable: e.closeable,
|
|
1904
1904
|
onClose: l
|
|
1905
1905
|
}, {
|
|
1906
1906
|
default: F(() => [
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1907
|
+
i("div", Dl, [
|
|
1908
|
+
i("div", Ol, [
|
|
1909
|
+
k(n.$slots, "title")
|
|
1910
1910
|
]),
|
|
1911
|
-
|
|
1912
|
-
|
|
1911
|
+
i("div", jl, [
|
|
1912
|
+
k(n.$slots, "content")
|
|
1913
1913
|
])
|
|
1914
1914
|
]),
|
|
1915
|
-
|
|
1916
|
-
|
|
1915
|
+
i("div", zl, [
|
|
1916
|
+
k(n.$slots, "footer")
|
|
1917
1917
|
])
|
|
1918
1918
|
]),
|
|
1919
1919
|
_: 3
|
|
1920
1920
|
}, 8, ["show", "max-width", "closeable"]));
|
|
1921
1921
|
}
|
|
1922
|
-
}, Fl = { class: "relative inline-block w-fit" },
|
|
1922
|
+
}, Fl = { class: "relative inline-block w-fit" }, Nl = {
|
|
1923
1923
|
__name: "Dropdown",
|
|
1924
1924
|
props: {
|
|
1925
1925
|
align: {
|
|
@@ -1943,64 +1943,63 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
1943
1943
|
visibility: "hidden"
|
|
1944
1944
|
}), u = O("ltr:origin-top-right rtl:origin-top-left");
|
|
1945
1945
|
let f = null;
|
|
1946
|
-
const
|
|
1947
|
-
t.value &&
|
|
1948
|
-
}, y = (
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1946
|
+
const V = (m) => {
|
|
1947
|
+
t.value && m.key === "Escape" && (t.value = !1);
|
|
1948
|
+
}, y = (m) => {
|
|
1949
|
+
if (!t.value)
|
|
1950
|
+
return;
|
|
1951
|
+
const L = m.target;
|
|
1952
|
+
L instanceof Node && (l.value?.contains(L) || n.value?.contains(L) || (t.value = !1));
|
|
1953
|
+
}, C = (m, L) => {
|
|
1954
|
+
const z = m ? "ltr:origin-top-right rtl:origin-top-left" : "ltr:origin-top-left rtl:origin-top-right";
|
|
1955
|
+
u.value = `${z} ${L ? "origin-bottom" : "origin-top"}`;
|
|
1956
|
+
}, w = g(() => ({
|
|
1952
1957
|
48: "w-48"
|
|
1953
|
-
})[a.width.toString()]),
|
|
1958
|
+
})[a.width.toString()]), h = g(() => u.value), S = () => {
|
|
1954
1959
|
if (!l.value || !n.value)
|
|
1955
1960
|
return;
|
|
1956
|
-
const
|
|
1957
|
-
let
|
|
1958
|
-
|
|
1959
|
-
let
|
|
1960
|
-
|
|
1961
|
-
const
|
|
1961
|
+
const m = l.value.getBoundingClientRect(), L = window.innerWidth, z = window.innerHeight, Q = n.value.offsetWidth, ee = n.value.offsetHeight, U = 8, P = m.left - U, Y = L - m.right - U;
|
|
1962
|
+
let b = a.align === "right";
|
|
1963
|
+
b && m.right + Q > L - U && P > Y ? b = !1 : !b && m.left + Q > L - U && Y > P && (b = !0);
|
|
1964
|
+
let E = b ? m.right - Q : m.left;
|
|
1965
|
+
E = Math.max(U, Math.min(E, L - Q - U));
|
|
1966
|
+
const N = z - m.bottom - U, G = m.top - U, J = N < ee && G > N;
|
|
1962
1967
|
d.value = {
|
|
1963
1968
|
position: "fixed",
|
|
1964
|
-
left: `${
|
|
1965
|
-
...
|
|
1969
|
+
left: `${E}px`,
|
|
1970
|
+
...J ? { bottom: `${z - m.top + U}px` } : { top: `${m.bottom + U}px` },
|
|
1966
1971
|
zIndex: "9999",
|
|
1967
|
-
maxHeight: `${Math.max(Math.min(
|
|
1968
|
-
},
|
|
1969
|
-
},
|
|
1972
|
+
maxHeight: `${Math.max(Math.min(J ? G : N, 320), 160)}px`
|
|
1973
|
+
}, C(b, J);
|
|
1974
|
+
}, v = async () => {
|
|
1970
1975
|
t.value && (f !== null && (cancelAnimationFrame(f), f = null), d.value = {
|
|
1971
1976
|
...d.value,
|
|
1972
1977
|
visibility: "hidden"
|
|
1973
|
-
}, await fe(),
|
|
1978
|
+
}, await fe(), S(), f = requestAnimationFrame(() => {
|
|
1974
1979
|
t.value && (d.value = {
|
|
1975
1980
|
...d.value,
|
|
1976
1981
|
visibility: "visible"
|
|
1977
1982
|
});
|
|
1978
1983
|
}));
|
|
1979
|
-
},
|
|
1980
|
-
t.value &&
|
|
1984
|
+
}, M = () => {
|
|
1985
|
+
t.value && S();
|
|
1981
1986
|
};
|
|
1982
|
-
return
|
|
1983
|
-
|
|
1984
|
-
}),
|
|
1985
|
-
document.addEventListener("keydown",
|
|
1987
|
+
return Z(t, (m) => {
|
|
1988
|
+
m && v();
|
|
1989
|
+
}), te(() => {
|
|
1990
|
+
document.addEventListener("keydown", V), document.addEventListener("pointerdown", y, !0), window.addEventListener("resize", M), window.addEventListener("scroll", M, !0);
|
|
1986
1991
|
}), Ae(() => {
|
|
1987
|
-
f !== null && cancelAnimationFrame(f), document.removeEventListener("keydown",
|
|
1988
|
-
}), (
|
|
1989
|
-
|
|
1992
|
+
f !== null && cancelAnimationFrame(f), document.removeEventListener("keydown", V), document.removeEventListener("pointerdown", y, !0), window.removeEventListener("resize", M), window.removeEventListener("scroll", M, !0);
|
|
1993
|
+
}), (m, L) => (s(), r("div", Fl, [
|
|
1994
|
+
i("div", {
|
|
1990
1995
|
ref_key: "triggerRef",
|
|
1991
1996
|
ref: l,
|
|
1992
|
-
onClick:
|
|
1997
|
+
onClick: L[0] || (L[0] = (z) => t.value = !t.value)
|
|
1993
1998
|
}, [
|
|
1994
|
-
|
|
1999
|
+
k(m.$slots, "trigger", { open: t.value })
|
|
1995
2000
|
], 512),
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
onClick: k[1] || (k[1] = (D) => t.value = !1)
|
|
1999
|
-
}, null, 512), [
|
|
2000
|
-
[de, t.value]
|
|
2001
|
-
]),
|
|
2002
|
-
(s(), L(Te, { to: "body" }, [
|
|
2003
|
-
H(re, {
|
|
2001
|
+
(s(), B(Te, { to: "body" }, [
|
|
2002
|
+
H(oe, {
|
|
2004
2003
|
"enter-active-class": "transition-opacity duration-150 ease-out",
|
|
2005
2004
|
"enter-from-class": "opacity-0",
|
|
2006
2005
|
"enter-to-class": "opacity-100",
|
|
@@ -2009,27 +2008,27 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2009
2008
|
"leave-to-class": "opacity-0"
|
|
2010
2009
|
}, {
|
|
2011
2010
|
default: F(() => [
|
|
2012
|
-
t.value ? (s(),
|
|
2011
|
+
t.value ? (s(), r("div", {
|
|
2013
2012
|
key: 0,
|
|
2014
2013
|
ref_key: "menuRef",
|
|
2015
2014
|
ref: n,
|
|
2016
|
-
class:
|
|
2015
|
+
class: $(["z-50 rounded-xl shadow-xl shadow-gray-900/10", [w.value, h.value]]),
|
|
2017
2016
|
style: he(d.value),
|
|
2018
|
-
onClick:
|
|
2017
|
+
onClick: L[1] || (L[1] = (z) => t.value = !1)
|
|
2019
2018
|
}, [
|
|
2020
|
-
|
|
2021
|
-
class:
|
|
2019
|
+
i("div", {
|
|
2020
|
+
class: $(["rounded-xl ring-1 ring-gray-200/60 backdrop-blur-sm bg-white/95", e.contentClasses])
|
|
2022
2021
|
}, [
|
|
2023
|
-
|
|
2022
|
+
k(m.$slots, "content")
|
|
2024
2023
|
], 2)
|
|
2025
|
-
], 6)) :
|
|
2024
|
+
], 6)) : D("", !0)
|
|
2026
2025
|
]),
|
|
2027
2026
|
_: 3
|
|
2028
2027
|
})
|
|
2029
2028
|
]))
|
|
2030
2029
|
]));
|
|
2031
2030
|
}
|
|
2032
|
-
},
|
|
2031
|
+
}, Rl = {
|
|
2033
2032
|
key: 0,
|
|
2034
2033
|
type: "submit",
|
|
2035
2034
|
class: "block w-full px-4 py-2 text-start text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition duration-150 ease-in-out"
|
|
@@ -2040,22 +2039,22 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2040
2039
|
as: String
|
|
2041
2040
|
},
|
|
2042
2041
|
setup(e) {
|
|
2043
|
-
return (a, t) => (s(),
|
|
2044
|
-
e.as == "button" ? (s(),
|
|
2045
|
-
|
|
2046
|
-
])) : e.as == "a" ? (s(),
|
|
2042
|
+
return (a, t) => (s(), r("div", null, [
|
|
2043
|
+
e.as == "button" ? (s(), r("button", Rl, [
|
|
2044
|
+
k(a.$slots, "default")
|
|
2045
|
+
])) : e.as == "a" ? (s(), r("a", {
|
|
2047
2046
|
key: 1,
|
|
2048
2047
|
href: e.href,
|
|
2049
2048
|
class: "block px-4 py-2 text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition duration-150 ease-in-out"
|
|
2050
2049
|
}, [
|
|
2051
|
-
|
|
2052
|
-
], 8, Ul)) : (s(),
|
|
2050
|
+
k(a.$slots, "default")
|
|
2051
|
+
], 8, Ul)) : (s(), B(j(pe), {
|
|
2053
2052
|
key: 2,
|
|
2054
2053
|
href: e.href,
|
|
2055
2054
|
class: "block px-4 py-2 text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition duration-150 ease-in-out"
|
|
2056
2055
|
}, {
|
|
2057
2056
|
default: F(() => [
|
|
2058
|
-
|
|
2057
|
+
k(a.$slots, "default")
|
|
2059
2058
|
]),
|
|
2060
2059
|
_: 3
|
|
2061
2060
|
}, 8, ["href"]))
|
|
@@ -2069,30 +2068,30 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2069
2068
|
emits: ["submitted"],
|
|
2070
2069
|
setup(e) {
|
|
2071
2070
|
const a = g(() => !!ge().actions);
|
|
2072
|
-
return (t, l) => (s(),
|
|
2071
|
+
return (t, l) => (s(), r("div", Hl, [
|
|
2073
2072
|
H(Se, null, {
|
|
2074
2073
|
title: F(() => [
|
|
2075
|
-
|
|
2074
|
+
k(t.$slots, "title")
|
|
2076
2075
|
]),
|
|
2077
2076
|
description: F(() => [
|
|
2078
|
-
|
|
2077
|
+
k(t.$slots, "description")
|
|
2079
2078
|
]),
|
|
2080
2079
|
_: 3
|
|
2081
2080
|
}),
|
|
2082
|
-
|
|
2083
|
-
|
|
2081
|
+
i("div", Wl, [
|
|
2082
|
+
i("form", {
|
|
2084
2083
|
onSubmit: l[0] || (l[0] = ye((n) => t.$emit("submitted"), ["prevent"]))
|
|
2085
2084
|
}, [
|
|
2086
|
-
|
|
2087
|
-
class:
|
|
2085
|
+
i("div", {
|
|
2086
|
+
class: $(["px-4 py-5 bg-white sm:p-6", a.value ? "sm:rounded-tl-md sm:rounded-tr-md" : "sm:rounded-md"])
|
|
2088
2087
|
}, [
|
|
2089
|
-
|
|
2090
|
-
|
|
2088
|
+
i("div", Pl, [
|
|
2089
|
+
k(t.$slots, "form")
|
|
2091
2090
|
])
|
|
2092
2091
|
], 2),
|
|
2093
|
-
a.value ? (s(),
|
|
2094
|
-
|
|
2095
|
-
])) :
|
|
2092
|
+
a.value ? (s(), r("div", ql, [
|
|
2093
|
+
k(t.$slots, "actions")
|
|
2094
|
+
])) : D("", !0)
|
|
2096
2095
|
], 32)
|
|
2097
2096
|
])
|
|
2098
2097
|
]));
|
|
@@ -2103,10 +2102,10 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2103
2102
|
message: String
|
|
2104
2103
|
},
|
|
2105
2104
|
setup(e) {
|
|
2106
|
-
return (a, t) =>
|
|
2107
|
-
|
|
2105
|
+
return (a, t) => re((s(), r("div", null, [
|
|
2106
|
+
i("p", Xl, A(e.message), 1)
|
|
2108
2107
|
], 512)), [
|
|
2109
|
-
[
|
|
2108
|
+
[ce, e.message]
|
|
2110
2109
|
]);
|
|
2111
2110
|
}
|
|
2112
2111
|
}, Yl = { class: "block font-medium text-sm text-gray-700" }, Jl = { key: 0 }, Zl = { key: 1 }, es = {
|
|
@@ -2115,9 +2114,9 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2115
2114
|
value: String
|
|
2116
2115
|
},
|
|
2117
2116
|
setup(e) {
|
|
2118
|
-
return (a, t) => (s(),
|
|
2119
|
-
e.value ? (s(),
|
|
2120
|
-
|
|
2117
|
+
return (a, t) => (s(), r("label", Yl, [
|
|
2118
|
+
e.value ? (s(), r("span", Jl, A(e.value), 1)) : (s(), r("span", Zl, [
|
|
2119
|
+
k(a.$slots, "default")
|
|
2121
2120
|
]))
|
|
2122
2121
|
]));
|
|
2123
2122
|
}
|
|
@@ -2152,7 +2151,7 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2152
2151
|
}
|
|
2153
2152
|
},
|
|
2154
2153
|
setup(e) {
|
|
2155
|
-
const a =
|
|
2154
|
+
const a = ne(), t = e, l = {
|
|
2156
2155
|
primary: "bg-gradient-to-r from-blue-500 to-blue-600 text-white shadow-[0_6px_14px_rgba(37,99,235,0.14)] hover:from-blue-600 hover:to-blue-700 hover:shadow-[0_8px_18px_rgba(37,99,235,0.18)] focus:ring-blue-500",
|
|
2157
2156
|
success: "bg-gradient-to-r from-green-500 to-green-600 text-white shadow-[0_6px_14px_rgba(34,197,94,0.14)] hover:from-green-600 hover:to-green-700 hover:shadow-[0_8px_18px_rgba(34,197,94,0.18)] focus:ring-green-500",
|
|
2158
2157
|
secondary: "bg-gradient-to-r from-slate-700 to-slate-800 text-white shadow-[0_8px_18px_rgba(15,23,42,0.16)] hover:from-slate-800 hover:to-slate-900 hover:shadow-[0_10px_22px_rgba(15,23,42,0.22)] focus:ring-slate-500",
|
|
@@ -2164,21 +2163,21 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2164
2163
|
l[n.value],
|
|
2165
2164
|
a.class
|
|
2166
2165
|
]);
|
|
2167
|
-
return (u, f) => e.external ? (s(),
|
|
2166
|
+
return (u, f) => e.external ? (s(), r("a", R({ key: 1 }, j(a), {
|
|
2168
2167
|
href: e.href,
|
|
2169
2168
|
title: e.title,
|
|
2170
2169
|
target: e.target,
|
|
2171
2170
|
rel: e.rel,
|
|
2172
2171
|
class: d.value
|
|
2173
2172
|
}), [
|
|
2174
|
-
|
|
2175
|
-
], 16, ts)) : (s(),
|
|
2173
|
+
k(u.$slots, "default")
|
|
2174
|
+
], 16, ts)) : (s(), B(j(pe), R({ key: 0 }, j(a), {
|
|
2176
2175
|
href: e.href,
|
|
2177
2176
|
title: e.title,
|
|
2178
2177
|
class: d.value
|
|
2179
2178
|
}), {
|
|
2180
2179
|
default: F(() => [
|
|
2181
|
-
|
|
2180
|
+
k(u.$slots, "default")
|
|
2182
2181
|
]),
|
|
2183
2182
|
_: 3
|
|
2184
2183
|
}, 16, ["href", "title", "class"]));
|
|
@@ -2191,12 +2190,12 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2191
2190
|
},
|
|
2192
2191
|
setup(e) {
|
|
2193
2192
|
const a = e, t = g(() => a.active ? "inline-flex items-center px-1 pt-1 border-b-2 border-indigo-500 text-sm font-semibold leading-5 text-gray-900 focus:outline-none focus:border-indigo-700 transition-all duration-300 ease-out relative group" : "inline-flex items-center px-1 pt-1 border-b-2 border-transparent text-sm font-medium leading-5 text-gray-600 hover:text-gray-900 hover:border-gray-400 focus:outline-none focus:text-gray-900 focus:border-gray-400 transition-all duration-300 ease-out relative group");
|
|
2194
|
-
return (l, n) => (s(),
|
|
2193
|
+
return (l, n) => (s(), B(j(pe), {
|
|
2195
2194
|
href: e.href,
|
|
2196
|
-
class:
|
|
2195
|
+
class: $(t.value)
|
|
2197
2196
|
}, {
|
|
2198
2197
|
default: F(() => [
|
|
2199
|
-
|
|
2198
|
+
k(l.$slots, "default")
|
|
2200
2199
|
]),
|
|
2201
2200
|
_: 3
|
|
2202
2201
|
}, 8, ["href", "class"]));
|
|
@@ -2210,25 +2209,25 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2210
2209
|
},
|
|
2211
2210
|
setup(e) {
|
|
2212
2211
|
const a = e, t = g(() => a.active ? "block w-full ps-3 pe-4 py-2 border-l-4 border-indigo-400 text-start text-base font-medium text-indigo-700 bg-indigo-50 focus:outline-none focus:text-indigo-800 focus:bg-indigo-100 focus:border-indigo-700 transition duration-150 ease-in-out" : "block w-full ps-3 pe-4 py-2 border-l-4 border-transparent text-start text-base font-medium text-gray-600 hover:text-gray-800 hover:bg-gray-50 hover:border-gray-300 focus:outline-none focus:text-gray-800 focus:bg-gray-50 focus:border-gray-300 transition duration-150 ease-in-out");
|
|
2213
|
-
return (l, n) => (s(),
|
|
2214
|
-
e.as == "button" ? (s(),
|
|
2212
|
+
return (l, n) => (s(), r("div", null, [
|
|
2213
|
+
e.as == "button" ? (s(), r("button", {
|
|
2215
2214
|
key: 0,
|
|
2216
|
-
class:
|
|
2215
|
+
class: $([t.value, "w-full text-start"])
|
|
2217
2216
|
}, [
|
|
2218
|
-
|
|
2219
|
-
], 2)) : e.as == "a" ? (s(),
|
|
2217
|
+
k(l.$slots, "default")
|
|
2218
|
+
], 2)) : e.as == "a" ? (s(), r("a", {
|
|
2220
2219
|
key: 1,
|
|
2221
|
-
class:
|
|
2220
|
+
class: $([t.value, "w-full text-start"]),
|
|
2222
2221
|
href: e.href
|
|
2223
2222
|
}, [
|
|
2224
|
-
|
|
2225
|
-
], 10, ss)) : (s(),
|
|
2223
|
+
k(l.$slots, "default")
|
|
2224
|
+
], 10, ss)) : (s(), B(j(pe), {
|
|
2226
2225
|
key: 2,
|
|
2227
2226
|
href: e.href,
|
|
2228
|
-
class:
|
|
2227
|
+
class: $(t.value)
|
|
2229
2228
|
}, {
|
|
2230
2229
|
default: F(() => [
|
|
2231
|
-
|
|
2230
|
+
k(l.$slots, "default")
|
|
2232
2231
|
]),
|
|
2233
2232
|
_: 3
|
|
2234
2233
|
}, 8, ["href", "class"]))
|
|
@@ -2237,8 +2236,8 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2237
2236
|
}, ns = { class: "hidden sm:block" }, os = { class: "py-8" }, rs = {
|
|
2238
2237
|
__name: "SectionBorder",
|
|
2239
2238
|
setup(e) {
|
|
2240
|
-
return (a, t) => (s(),
|
|
2241
|
-
|
|
2239
|
+
return (a, t) => (s(), r("div", ns, [
|
|
2240
|
+
i("div", os, [
|
|
2242
2241
|
H(we)
|
|
2243
2242
|
])
|
|
2244
2243
|
]));
|
|
@@ -2280,32 +2279,32 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2280
2279
|
const t = a, l = (n) => {
|
|
2281
2280
|
t("sort", n);
|
|
2282
2281
|
};
|
|
2283
|
-
return (n, d) => (s(),
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
(s(!0),
|
|
2282
|
+
return (n, d) => (s(), r("div", is, [
|
|
2283
|
+
i("div", ds, [
|
|
2284
|
+
i("div", us, [
|
|
2285
|
+
i("label", cs, A(e.sortByLabel) + ":", 1),
|
|
2286
|
+
i("div", fs, [
|
|
2287
|
+
(s(!0), r(q, null, X(e.fields, (u) => (s(), r("button", {
|
|
2289
2288
|
key: u.key,
|
|
2290
2289
|
onClick: (f) => l(u.key),
|
|
2291
|
-
class:
|
|
2290
|
+
class: $([
|
|
2292
2291
|
"px-3 py-1.5 text-sm font-medium rounded-lg transition-all duration-200",
|
|
2293
2292
|
e.currentSortField === u.key ? "bg-blue-500 text-white shadow-sm" : "bg-gray-100 text-gray-700 hover:bg-gray-200"
|
|
2294
2293
|
])
|
|
2295
2294
|
}, [
|
|
2296
|
-
|
|
2297
|
-
e.currentSortField === u.key && e.currentDirection === "asc" ? (s(),
|
|
2295
|
+
de(A(u.label) + " ", 1),
|
|
2296
|
+
e.currentSortField === u.key && e.currentDirection === "asc" ? (s(), B(j(Ie), {
|
|
2298
2297
|
key: 0,
|
|
2299
2298
|
class: "w-3 h-3 ml-1 inline"
|
|
2300
|
-
})) :
|
|
2301
|
-
e.currentSortField === u.key && e.currentDirection === "desc" ? (s(),
|
|
2299
|
+
})) : D("", !0),
|
|
2300
|
+
e.currentSortField === u.key && e.currentDirection === "desc" ? (s(), B(j(xe), {
|
|
2302
2301
|
key: 1,
|
|
2303
2302
|
class: "w-3 h-3 ml-1 inline"
|
|
2304
|
-
})) :
|
|
2303
|
+
})) : D("", !0)
|
|
2305
2304
|
], 10, gs))), 128))
|
|
2306
2305
|
])
|
|
2307
2306
|
]),
|
|
2308
|
-
|
|
2307
|
+
i("div", ps, A(e.count) + " " + A(e.countLabel), 1)
|
|
2309
2308
|
])
|
|
2310
2309
|
]));
|
|
2311
2310
|
}
|
|
@@ -2327,23 +2326,23 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2327
2326
|
},
|
|
2328
2327
|
setup(e) {
|
|
2329
2328
|
const a = e, t = g(() => a.field === a.currentSortField), l = g(() => t.value ? "text-blue-600" : "text-gray-400");
|
|
2330
|
-
return (n, d) => (s(),
|
|
2329
|
+
return (n, d) => (s(), r("th", {
|
|
2331
2330
|
class: "px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider cursor-pointer hover:bg-gray-100 transition-colors duration-150",
|
|
2332
2331
|
onClick: d[0] || (d[0] = (u) => n.$emit("sort", e.field))
|
|
2333
2332
|
}, [
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2333
|
+
i("div", bs, [
|
|
2334
|
+
i("span", null, [
|
|
2335
|
+
k(n.$slots, "default")
|
|
2337
2336
|
]),
|
|
2338
|
-
|
|
2339
|
-
t.value && e.currentDirection === "asc" ? (s(),
|
|
2337
|
+
i("div", ys, [
|
|
2338
|
+
t.value && e.currentDirection === "asc" ? (s(), B(j(Ie), {
|
|
2340
2339
|
key: 0,
|
|
2341
|
-
class:
|
|
2342
|
-
}, null, 8, ["class"])) :
|
|
2343
|
-
t.value && e.currentDirection === "desc" ? (s(),
|
|
2340
|
+
class: $([l.value, "w-3 h-3"])
|
|
2341
|
+
}, null, 8, ["class"])) : D("", !0),
|
|
2342
|
+
t.value && e.currentDirection === "desc" ? (s(), B(j(xe), {
|
|
2344
2343
|
key: 1,
|
|
2345
|
-
class:
|
|
2346
|
-
}, null, 8, ["class"])) :
|
|
2344
|
+
class: $([l.value, "w-3 h-3"])
|
|
2345
|
+
}, null, 8, ["class"])) : D("", !0)
|
|
2347
2346
|
])
|
|
2348
2347
|
])
|
|
2349
2348
|
]));
|
|
@@ -2420,116 +2419,116 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2420
2419
|
setup(e, { emit: a }) {
|
|
2421
2420
|
const t = ge(), l = e, n = a;
|
|
2422
2421
|
g(() => !!t.actions);
|
|
2423
|
-
const d = g(() => l.data && l.data.length > 0), u = (
|
|
2424
|
-
n("sort",
|
|
2425
|
-
}, f = (
|
|
2426
|
-
const
|
|
2427
|
-
return !Number.isFinite(
|
|
2428
|
-
},
|
|
2429
|
-
if (
|
|
2422
|
+
const d = g(() => l.data && l.data.length > 0), u = (h) => {
|
|
2423
|
+
n("sort", h);
|
|
2424
|
+
}, f = (h) => {
|
|
2425
|
+
const S = String(h ?? ""), v = Number(l.maxTextLength);
|
|
2426
|
+
return !Number.isFinite(v) || v <= 0 || S.length <= v ? S : `${S.slice(0, v)}...`;
|
|
2427
|
+
}, V = (h, S) => {
|
|
2428
|
+
if (S.slot)
|
|
2430
2429
|
return null;
|
|
2431
|
-
if (
|
|
2432
|
-
return
|
|
2433
|
-
const
|
|
2434
|
-
return
|
|
2435
|
-
}, y = (
|
|
2436
|
-
if (
|
|
2437
|
-
return
|
|
2438
|
-
let
|
|
2439
|
-
return
|
|
2440
|
-
}, w = (
|
|
2441
|
-
return (
|
|
2442
|
-
class:
|
|
2430
|
+
if (S.render)
|
|
2431
|
+
return S.render(h);
|
|
2432
|
+
const v = S.key.split(".").reduce((M, m) => M?.[m], h);
|
|
2433
|
+
return v == null || v === "" ? "-" : f(v);
|
|
2434
|
+
}, y = (h) => h.deleted_at || h.deleted, C = (h) => {
|
|
2435
|
+
if (h.class)
|
|
2436
|
+
return h.class;
|
|
2437
|
+
let S = "px-6 py-4 text-sm truncate";
|
|
2438
|
+
return h.isSecondary || (S += " font-medium"), h.isSecondary && (S += " text-slate-600"), S;
|
|
2439
|
+
}, w = (h) => h.sortable ? "" : "px-6 py-3 text-left text-[11px] font-semibold tracking-[0.12em] text-slate-600 uppercase";
|
|
2440
|
+
return (h, S) => (s(), r("div", {
|
|
2441
|
+
class: $(["bg-white/90 backdrop-blur-sm", e.isCard ? "border border-slate-200/70 rounded-2xl shadow-[0_12px_30px_rgba(15,23,42,0.06)] animate-fadeIn mx-4 md:mx-0" : ""])
|
|
2443
2442
|
}, [
|
|
2444
|
-
|
|
2445
|
-
class:
|
|
2443
|
+
i("div", {
|
|
2444
|
+
class: $(["overflow-x-auto", e.isCard ? "rounded-xl" : ""])
|
|
2446
2445
|
}, [
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
(s(!0),
|
|
2451
|
-
key:
|
|
2446
|
+
i("table", vs, [
|
|
2447
|
+
i("thead", hs, [
|
|
2448
|
+
i("tr", null, [
|
|
2449
|
+
(s(!0), r(q, null, X(e.columns, (v) => (s(), r(q, {
|
|
2450
|
+
key: v.key
|
|
2452
2451
|
}, [
|
|
2453
|
-
|
|
2452
|
+
v.sortable ? (s(), B(Ve, {
|
|
2454
2453
|
key: 0,
|
|
2455
|
-
field:
|
|
2454
|
+
field: v.key,
|
|
2456
2455
|
"current-sort-field": e.sortField,
|
|
2457
2456
|
"current-direction": e.sortDirection,
|
|
2458
2457
|
onSort: u
|
|
2459
2458
|
}, {
|
|
2460
2459
|
default: F(() => [
|
|
2461
|
-
|
|
2460
|
+
de(A(v.label), 1)
|
|
2462
2461
|
]),
|
|
2463
2462
|
_: 2
|
|
2464
|
-
}, 1032, ["field", "current-sort-field", "current-direction"])) : (s(),
|
|
2463
|
+
}, 1032, ["field", "current-sort-field", "current-direction"])) : (s(), r("th", {
|
|
2465
2464
|
key: 1,
|
|
2466
|
-
class:
|
|
2467
|
-
},
|
|
2465
|
+
class: $([w(v), { "text-right": v.align === "right" }])
|
|
2466
|
+
}, A(v.label), 3))
|
|
2468
2467
|
], 64))), 128)),
|
|
2469
|
-
|
|
2468
|
+
h.$slots.actions ? (s(), r("th", xs, A(e.actionsLabel), 1)) : D("", !0)
|
|
2470
2469
|
])
|
|
2471
2470
|
]),
|
|
2472
|
-
|
|
2473
|
-
(s(!0),
|
|
2474
|
-
key:
|
|
2475
|
-
class:
|
|
2471
|
+
i("tbody", ws, [
|
|
2472
|
+
(s(!0), r(q, null, X(e.data, (v, M) => (s(), r("tr", {
|
|
2473
|
+
key: v.id,
|
|
2474
|
+
class: $(e.rowClasses(v, M))
|
|
2476
2475
|
}, [
|
|
2477
|
-
(s(!0),
|
|
2478
|
-
key:
|
|
2479
|
-
class: C(
|
|
2476
|
+
(s(!0), r(q, null, X(e.columns, (m) => (s(), r("td", {
|
|
2477
|
+
key: m.key,
|
|
2478
|
+
class: $(C(m))
|
|
2480
2479
|
}, [
|
|
2481
|
-
|
|
2482
|
-
|
|
2480
|
+
m.key === "name" && !m.slot ? (s(), r("div", ks, [
|
|
2481
|
+
i("div", {
|
|
2483
2482
|
class: "text-sm font-medium text-slate-900 truncate",
|
|
2484
|
-
title:
|
|
2485
|
-
},
|
|
2486
|
-
y(
|
|
2487
|
-
])) :
|
|
2483
|
+
title: V(v, m)
|
|
2484
|
+
}, A(V(v, m)), 9, Ss),
|
|
2485
|
+
y(v) ? (s(), r("span", $s, A(e.deletedLabel), 1)) : D("", !0)
|
|
2486
|
+
])) : m.slot ? k(h.$slots, m.slot, {
|
|
2488
2487
|
key: 1,
|
|
2489
|
-
item:
|
|
2490
|
-
column:
|
|
2491
|
-
index:
|
|
2492
|
-
}) :
|
|
2488
|
+
item: v,
|
|
2489
|
+
column: m,
|
|
2490
|
+
index: M
|
|
2491
|
+
}) : m.render ? (s(), r("div", {
|
|
2493
2492
|
key: 2,
|
|
2494
|
-
innerHTML:
|
|
2495
|
-
}, null, 8, Cs)) : (s(),
|
|
2493
|
+
innerHTML: m.render(v)
|
|
2494
|
+
}, null, 8, Cs)) : (s(), r("div", Vs, A(V(v, m)), 1))
|
|
2496
2495
|
], 2))), 128)),
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
item:
|
|
2500
|
-
index:
|
|
2496
|
+
h.$slots.actions ? (s(), r("td", _s, [
|
|
2497
|
+
k(h.$slots, "actions", {
|
|
2498
|
+
item: v,
|
|
2499
|
+
index: M
|
|
2501
2500
|
})
|
|
2502
|
-
])) :
|
|
2501
|
+
])) : D("", !0)
|
|
2503
2502
|
], 2))), 128))
|
|
2504
2503
|
])
|
|
2505
2504
|
])
|
|
2506
2505
|
], 2),
|
|
2507
|
-
d.value ?
|
|
2508
|
-
|
|
2509
|
-
(s(),
|
|
2506
|
+
d.value ? D("", !0) : (s(), r("div", Ts, [
|
|
2507
|
+
i("div", As, [
|
|
2508
|
+
(s(), B(Be(e.emptyState.icon), { class: "w-8 h-8 text-slate-400" }))
|
|
2510
2509
|
]),
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
e.emptyState.actionText && e.emptyState.actionUrl ? (s(),
|
|
2510
|
+
i("h3", Bs, A(e.emptyState.title), 1),
|
|
2511
|
+
i("p", Ls, A(e.emptyState.description), 1),
|
|
2512
|
+
e.emptyState.actionText && e.emptyState.actionUrl ? (s(), B(Ce, {
|
|
2514
2513
|
key: 0,
|
|
2515
2514
|
href: e.emptyState.actionUrl,
|
|
2516
2515
|
variant: "primary"
|
|
2517
2516
|
}, {
|
|
2518
2517
|
default: F(() => [
|
|
2519
|
-
|
|
2518
|
+
de(A(e.emptyState.actionText), 1)
|
|
2520
2519
|
]),
|
|
2521
2520
|
_: 1
|
|
2522
|
-
}, 8, ["href"])) :
|
|
2521
|
+
}, 8, ["href"])) : D("", !0)
|
|
2523
2522
|
]))
|
|
2524
2523
|
], 2));
|
|
2525
2524
|
}
|
|
2526
2525
|
}, Ms = { class: "relative max-w-sm" }, Ds = { class: "absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none" }, Os = ["placeholder"], js = { class: "min-w-full divide-y divide-gray-200" }, zs = { class: "bg-gray-50" }, Es = {
|
|
2527
2526
|
key: 0,
|
|
2528
2527
|
class: "px-6 py-3 text-right text-xs font-medium text-gray-500 uppercase tracking-wider"
|
|
2529
|
-
}, Fs = { class: "bg-white divide-y divide-gray-200" },
|
|
2528
|
+
}, Fs = { class: "bg-white divide-y divide-gray-200" }, Ns = {
|
|
2530
2529
|
key: 2,
|
|
2531
2530
|
class: "flex items-center"
|
|
2532
|
-
},
|
|
2531
|
+
}, Rs = ["title"], Us = {
|
|
2533
2532
|
key: 0,
|
|
2534
2533
|
class: "ml-2 inline-flex items-center rounded-full bg-red-100 px-2 py-1 text-xs font-medium text-red-800"
|
|
2535
2534
|
}, Ks = ["innerHTML"], Hs = { key: 5 }, Ws = {
|
|
@@ -2637,28 +2636,28 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2637
2636
|
},
|
|
2638
2637
|
emits: ["sort", "update", "update:editingRowKey", "edit-start", "edit-cancel"],
|
|
2639
2638
|
setup(e, { emit: a }) {
|
|
2640
|
-
const t = ge(), l = e, n = a, d = O(l.sortField), u = O(l.sortDirection), f = O(""),
|
|
2641
|
-
|
|
2639
|
+
const t = ge(), l = e, n = a, d = O(l.sortField), u = O(l.sortDirection), f = O(""), V = O(null), y = O({}), C = g(() => l.editingRowKey !== void 0 ? l.editingRowKey : V.value);
|
|
2640
|
+
Z(() => l.sortField, (o) => {
|
|
2642
2641
|
d.value = o;
|
|
2643
|
-
}),
|
|
2642
|
+
}), Z(() => l.sortDirection, (o) => {
|
|
2644
2643
|
u.value = o;
|
|
2645
|
-
}),
|
|
2646
|
-
o ||
|
|
2647
|
-
}),
|
|
2644
|
+
}), Z(() => l.rowEditing, (o) => {
|
|
2645
|
+
o || G();
|
|
2646
|
+
}), Z(C, (o, p) => {
|
|
2648
2647
|
if (o === p)
|
|
2649
2648
|
return;
|
|
2650
2649
|
if (o == null || o === "") {
|
|
2651
2650
|
y.value = {};
|
|
2652
2651
|
return;
|
|
2653
2652
|
}
|
|
2654
|
-
const c = l.data.find((I,
|
|
2655
|
-
y.value = c ?
|
|
2656
|
-
}),
|
|
2653
|
+
const c = l.data.find((I, x) => U(I, x) === o);
|
|
2654
|
+
y.value = c ? m(c) : {};
|
|
2655
|
+
}), Z(
|
|
2657
2656
|
() => l.data,
|
|
2658
2657
|
() => {
|
|
2659
|
-
if (
|
|
2658
|
+
if (C.value === null || C.value === void 0)
|
|
2660
2659
|
return;
|
|
2661
|
-
l.data.find((p, c) =>
|
|
2660
|
+
l.data.find((p, c) => U(p, c) === C.value) || G();
|
|
2662
2661
|
},
|
|
2663
2662
|
{ deep: !0 }
|
|
2664
2663
|
);
|
|
@@ -2669,59 +2668,59 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2669
2668
|
o = l.data.filter((c) => l.columns.some((I) => {
|
|
2670
2669
|
if (!I.searchable)
|
|
2671
2670
|
return !1;
|
|
2672
|
-
const
|
|
2673
|
-
return
|
|
2671
|
+
const x = z(c, I.key);
|
|
2672
|
+
return x == null || x === "" ? !1 : String(x).toLowerCase().includes(p);
|
|
2674
2673
|
}));
|
|
2675
2674
|
}
|
|
2676
2675
|
return d.value ? [...o].sort((p, c) => {
|
|
2677
|
-
const I = z(p, d.value),
|
|
2676
|
+
const I = z(p, d.value), x = z(c, d.value);
|
|
2678
2677
|
if (I == null || I === "") return 1;
|
|
2679
|
-
if (
|
|
2678
|
+
if (x == null || x === "") return -1;
|
|
2680
2679
|
let W = 0;
|
|
2681
|
-
return I <
|
|
2680
|
+
return I < x && (W = -1), I > x && (W = 1), u.value === "desc" ? -W : W;
|
|
2682
2681
|
}) : o;
|
|
2683
|
-
}),
|
|
2682
|
+
}), h = g(() => !!t.actions), S = g(() => h.value || l.rowEditing), v = g(() => w.value && w.value.length > 0), M = (o) => {
|
|
2684
2683
|
d.value === o ? u.value = u.value === "asc" ? "desc" : "asc" : (d.value = o, u.value = "asc"), n("sort", { field: o, direction: u.value });
|
|
2685
|
-
},
|
|
2686
|
-
Object.entries(o).map(([p, c]) => [p,
|
|
2687
|
-
) : o,
|
|
2684
|
+
}, m = (o) => Array.isArray(o) ? o.map((p) => m(p)) : o && typeof o == "object" ? Object.fromEntries(
|
|
2685
|
+
Object.entries(o).map(([p, c]) => [p, m(c)])
|
|
2686
|
+
) : o, L = (o) => {
|
|
2688
2687
|
const p = String(o ?? ""), c = Number(l.maxTextLength);
|
|
2689
2688
|
return !Number.isFinite(c) || c <= 0 || p.length <= c ? p : `${p.slice(0, c)}...`;
|
|
2690
|
-
}, z = (o, p) => !p || typeof p != "string" ? o : p.split(".").reduce((c, I) => c?.[I], o),
|
|
2689
|
+
}, z = (o, p) => !p || typeof p != "string" ? o : p.split(".").reduce((c, I) => c?.[I], o), Q = (o, p, c) => {
|
|
2691
2690
|
if (!p || typeof p != "string" || o == null)
|
|
2692
2691
|
return;
|
|
2693
|
-
const I = p.split("."),
|
|
2692
|
+
const I = p.split("."), x = I.pop();
|
|
2694
2693
|
let W = o;
|
|
2695
2694
|
for (const ie of I)
|
|
2696
2695
|
(W[ie] === void 0 || W[ie] === null || typeof W[ie] != "object") && (W[ie] = {}), W = W[ie];
|
|
2697
|
-
|
|
2698
|
-
},
|
|
2699
|
-
l.editingRowKey === void 0 && (
|
|
2700
|
-
}, E = (o, p) => l.rowEditing &&
|
|
2701
|
-
|
|
2702
|
-
},
|
|
2696
|
+
x !== void 0 && (W[x] = c);
|
|
2697
|
+
}, ee = (o) => o?.id ? l.data.findIndex((p) => p?.id === o.id) : l.data.findIndex((p) => p === o), U = (o, p) => typeof l.rowKey == "function" ? l.rowKey(o, p) ?? `row-${p}` : z(o, l.rowKey) ?? `row-${p}`, P = (o) => `${o.slot}-edit`, Y = (o) => l.isDeletedFn(o), b = (o) => {
|
|
2698
|
+
l.editingRowKey === void 0 && (V.value = o), n("update:editingRowKey", o);
|
|
2699
|
+
}, E = (o, p) => l.rowEditing && C.value !== null && C.value === U(o, p), N = (o, p) => !l.rowEditing || !l.canEditRow(o, p) || Y(o) ? !0 : C.value !== null && !E(o, p), G = () => {
|
|
2700
|
+
b(null);
|
|
2701
|
+
}, J = (o, p) => {
|
|
2703
2702
|
if (N(o, p))
|
|
2704
2703
|
return;
|
|
2705
|
-
const c =
|
|
2706
|
-
|
|
2704
|
+
const c = U(o, p);
|
|
2705
|
+
b(c), n("edit-start", {
|
|
2707
2706
|
item: o,
|
|
2708
|
-
index:
|
|
2707
|
+
index: ee(o),
|
|
2709
2708
|
rowKey: c
|
|
2710
2709
|
});
|
|
2711
2710
|
}, le = (o, p) => {
|
|
2712
2711
|
n("edit-cancel", {
|
|
2713
2712
|
item: o,
|
|
2714
|
-
index:
|
|
2715
|
-
rowKey:
|
|
2716
|
-
}),
|
|
2713
|
+
index: ee(o),
|
|
2714
|
+
rowKey: U(o, p)
|
|
2715
|
+
}), G();
|
|
2717
2716
|
}, se = (o, p, c, I = void 0) => {
|
|
2718
|
-
|
|
2717
|
+
Q(y.value, o, p), l.mutateRows && Q(c, o, m(p)), n("update", {
|
|
2719
2718
|
item: c,
|
|
2720
2719
|
draft: y.value,
|
|
2721
2720
|
field: o,
|
|
2722
2721
|
value: p,
|
|
2723
|
-
index:
|
|
2724
|
-
rowKey:
|
|
2722
|
+
index: ee(c),
|
|
2723
|
+
rowKey: C.value,
|
|
2725
2724
|
event: I
|
|
2726
2725
|
});
|
|
2727
2726
|
}, ae = (o, p) => {
|
|
@@ -2730,17 +2729,17 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2730
2729
|
if (p.render)
|
|
2731
2730
|
return p.render(o);
|
|
2732
2731
|
const c = z(o, p.key);
|
|
2733
|
-
return c == null || c === "" ? "-" :
|
|
2732
|
+
return c == null || c === "" ? "-" : L(c);
|
|
2734
2733
|
}, K = (o, p, c) => {
|
|
2735
2734
|
if (o.class)
|
|
2736
2735
|
return o.class;
|
|
2737
|
-
let
|
|
2738
|
-
return o.isSecondary || (
|
|
2739
|
-
},
|
|
2736
|
+
let x = E(p, c) && (o.input || t[P(o)]) ? "px-6 py-3 text-sm align-top" : "px-6 py-4 text-sm truncate";
|
|
2737
|
+
return o.isSecondary || (x += " font-medium"), o.isSecondary && (x += " text-gray-600"), x;
|
|
2738
|
+
}, _ = (o) => o.sortable ? "" : "px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider", T = (o) => o.inputType || "text", Pe = (o) => {
|
|
2740
2739
|
let p = "block w-full min-w-[12rem] sm:min-w-[10rem] max-w-xs rounded-md border border-gray-200 bg-gray-50 px-3 py-2 text-sm text-gray-900 shadow-none placeholder-gray-400 transition-colors duration-200 focus:border-blue-500 focus:bg-white focus:outline-none focus:ring-2 focus:ring-blue-500/20";
|
|
2741
2740
|
return o.inputClass && (p += ` ${o.inputClass}`), o.isSecondary && (p += " text-gray-600"), p;
|
|
2742
2741
|
}, qe = (o) => o.placeholder || o.label || "", _e = (o, p, c) => E(o, c) ? z(y.value, p.key) ?? "" : z(o, p.key) ?? "", Ge = (o, p) => {
|
|
2743
|
-
const c =
|
|
2742
|
+
const c = ee(o);
|
|
2744
2743
|
return c === -1 ? null : l.getErrorMessage(c, p.key);
|
|
2745
2744
|
}, be = (o, p, c) => ({
|
|
2746
2745
|
item: o,
|
|
@@ -2748,26 +2747,26 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2748
2747
|
index: c,
|
|
2749
2748
|
isEditing: E(o, c),
|
|
2750
2749
|
draft: y.value,
|
|
2751
|
-
rowKey:
|
|
2752
|
-
updateDraft: (I,
|
|
2753
|
-
startEdit: () =>
|
|
2750
|
+
rowKey: U(o, c),
|
|
2751
|
+
updateDraft: (I, x) => se(I, x, o),
|
|
2752
|
+
startEdit: () => J(o, c),
|
|
2754
2753
|
cancelEdit: () => le(o, c)
|
|
2755
|
-
}), Xe = (o, p, c) => !!((typeof o.disabled == "function" ? o.disabled(p, c) : o.disabled) ||
|
|
2756
|
-
return (o, p) => (s(),
|
|
2757
|
-
class:
|
|
2754
|
+
}), Xe = (o, p, c) => !!((typeof o.disabled == "function" ? o.disabled(p, c) : o.disabled) || Y(p));
|
|
2755
|
+
return (o, p) => (s(), r("div", {
|
|
2756
|
+
class: $(["bg-white", e.isCard ? "mx-4 md:mx-0 border border-gray-200/60 rounded-xl shadow-[0_1px_3px_rgba(0,0,0,0.1)] animate-fadeIn" : ""])
|
|
2758
2757
|
}, [
|
|
2759
|
-
e.search ? (s(),
|
|
2758
|
+
e.search ? (s(), r("div", {
|
|
2760
2759
|
key: 0,
|
|
2761
|
-
class:
|
|
2760
|
+
class: $([
|
|
2762
2761
|
"px-6 py-4",
|
|
2763
2762
|
e.isCard ? "border-b border-gray-200 bg-gray-50/80 rounded-t-xl" : "mb-4 bg-white/80 backdrop-blur-sm"
|
|
2764
2763
|
])
|
|
2765
2764
|
}, [
|
|
2766
|
-
|
|
2767
|
-
|
|
2765
|
+
i("div", Ms, [
|
|
2766
|
+
i("div", Ds, [
|
|
2768
2767
|
H(j(rt), { class: "h-4 w-4 text-gray-400" })
|
|
2769
2768
|
]),
|
|
2770
|
-
|
|
2769
|
+
re(i("input", {
|
|
2771
2770
|
"onUpdate:modelValue": p[0] || (p[0] = (c) => f.value = c),
|
|
2772
2771
|
type: "text",
|
|
2773
2772
|
placeholder: e.searchPlaceholder,
|
|
@@ -2776,127 +2775,127 @@ const Et = /* @__PURE__ */ ke(Dt, [["render", zt]]), Ft = { class: "sr-only" },
|
|
|
2776
2775
|
[Ze, f.value]
|
|
2777
2776
|
])
|
|
2778
2777
|
])
|
|
2779
|
-
], 2)) :
|
|
2780
|
-
|
|
2778
|
+
], 2)) : D("", !0),
|
|
2779
|
+
v.value ? (s(), r("div", {
|
|
2781
2780
|
key: 1,
|
|
2782
|
-
class:
|
|
2781
|
+
class: $(["overflow-x-auto", e.isCard ? "rounded-xl" : ""])
|
|
2783
2782
|
}, [
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
(s(!0),
|
|
2783
|
+
i("table", js, [
|
|
2784
|
+
i("thead", zs, [
|
|
2785
|
+
i("tr", null, [
|
|
2786
|
+
(s(!0), r(q, null, X(e.columns, (c) => (s(), r(q, {
|
|
2788
2787
|
key: c.key
|
|
2789
2788
|
}, [
|
|
2790
|
-
c.sortable ? (s(),
|
|
2789
|
+
c.sortable ? (s(), B(Ve, {
|
|
2791
2790
|
key: 0,
|
|
2792
2791
|
field: c.key,
|
|
2793
2792
|
"current-sort-field": d.value,
|
|
2794
2793
|
"current-direction": u.value,
|
|
2795
|
-
onSort:
|
|
2794
|
+
onSort: M
|
|
2796
2795
|
}, {
|
|
2797
2796
|
default: F(() => [
|
|
2798
|
-
|
|
2797
|
+
de(A(c.label), 1)
|
|
2799
2798
|
]),
|
|
2800
2799
|
_: 2
|
|
2801
|
-
}, 1032, ["field", "current-sort-field", "current-direction"])) : (s(),
|
|
2800
|
+
}, 1032, ["field", "current-sort-field", "current-direction"])) : (s(), r("th", {
|
|
2802
2801
|
key: 1,
|
|
2803
|
-
class:
|
|
2804
|
-
},
|
|
2802
|
+
class: $([_(c), { "text-right": c.align === "right" }])
|
|
2803
|
+
}, A(c.label), 3))
|
|
2805
2804
|
], 64))), 128)),
|
|
2806
|
-
|
|
2805
|
+
S.value ? (s(), r("th", Es, A(e.actionsLabel), 1)) : D("", !0)
|
|
2807
2806
|
])
|
|
2808
2807
|
]),
|
|
2809
|
-
|
|
2810
|
-
(s(!0),
|
|
2811
|
-
key:
|
|
2812
|
-
class:
|
|
2808
|
+
i("tbody", Fs, [
|
|
2809
|
+
(s(!0), r(q, null, X(w.value, (c, I) => (s(), r("tr", {
|
|
2810
|
+
key: U(c, I),
|
|
2811
|
+
class: $(e.rowClasses(c, I))
|
|
2813
2812
|
}, [
|
|
2814
|
-
(s(!0),
|
|
2815
|
-
key:
|
|
2816
|
-
class:
|
|
2813
|
+
(s(!0), r(q, null, X(e.columns, (x) => (s(), r("td", {
|
|
2814
|
+
key: x.key,
|
|
2815
|
+
class: $([K(x, c, I), { "text-right": x.align === "right" }])
|
|
2817
2816
|
}, [
|
|
2818
|
-
E(c, I) &&
|
|
2817
|
+
E(c, I) && x.slot && j(t)[P(x)] ? k(o.$slots, P(x), R({
|
|
2819
2818
|
key: 0,
|
|
2820
2819
|
ref_for: !0
|
|
2821
|
-
}, be(c,
|
|
2820
|
+
}, be(c, x, I))) : E(c, I) && x.input ? (s(), B(me, {
|
|
2822
2821
|
key: 1,
|
|
2823
|
-
type:
|
|
2824
|
-
class:
|
|
2825
|
-
placeholder: qe(
|
|
2826
|
-
"model-value": _e(c,
|
|
2827
|
-
disabled: Xe(
|
|
2828
|
-
maxlength:
|
|
2829
|
-
"error-message": Ge(c,
|
|
2822
|
+
type: T(x),
|
|
2823
|
+
class: $(Pe(x)),
|
|
2824
|
+
placeholder: qe(x),
|
|
2825
|
+
"model-value": _e(c, x, I),
|
|
2826
|
+
disabled: Xe(x, c, I),
|
|
2827
|
+
maxlength: x.maxlength,
|
|
2828
|
+
"error-message": Ge(c, x),
|
|
2830
2829
|
"helper-text": "",
|
|
2831
|
-
"onUpdate:modelValue": (W) => se(
|
|
2832
|
-
onBlur: (W) => se(
|
|
2833
|
-
}, null, 8, ["type", "class", "placeholder", "model-value", "disabled", "maxlength", "error-message", "onUpdate:modelValue", "onBlur"])) :
|
|
2834
|
-
|
|
2830
|
+
"onUpdate:modelValue": (W) => se(x.key, W, c),
|
|
2831
|
+
onBlur: (W) => se(x.key, W?.target?.value ?? _e(c, x, I), c, "blur")
|
|
2832
|
+
}, null, 8, ["type", "class", "placeholder", "model-value", "disabled", "maxlength", "error-message", "onUpdate:modelValue", "onBlur"])) : x.key === "name" && !x.slot ? (s(), r("div", Ns, [
|
|
2833
|
+
i("div", {
|
|
2835
2834
|
class: "text-sm font-medium truncate",
|
|
2836
|
-
title: ae(c,
|
|
2837
|
-
},
|
|
2838
|
-
|
|
2839
|
-
])) :
|
|
2835
|
+
title: ae(c, x)
|
|
2836
|
+
}, A(ae(c, x)), 9, Rs),
|
|
2837
|
+
Y(c) ? (s(), r("span", Us, A(e.deletedLabel), 1)) : D("", !0)
|
|
2838
|
+
])) : x.slot ? k(o.$slots, x.slot, R({
|
|
2840
2839
|
key: 3,
|
|
2841
2840
|
ref_for: !0
|
|
2842
|
-
}, be(c,
|
|
2841
|
+
}, be(c, x, I))) : x.render ? (s(), r("div", {
|
|
2843
2842
|
key: 4,
|
|
2844
|
-
innerHTML:
|
|
2845
|
-
}, null, 8, Ks)) : (s(),
|
|
2843
|
+
innerHTML: x.render(c)
|
|
2844
|
+
}, null, 8, Ks)) : (s(), r("div", Hs, A(ae(c, x)), 1))
|
|
2846
2845
|
], 2))), 128)),
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2846
|
+
S.value ? (s(), r("td", Ws, [
|
|
2847
|
+
i("div", Ps, [
|
|
2848
|
+
h.value ? k(o.$slots, "actions", R({
|
|
2850
2849
|
key: 0,
|
|
2851
2850
|
ref_for: !0
|
|
2852
|
-
}, be(c, null, I))) :
|
|
2853
|
-
e.rowEditing && E(c, I) ? (s(),
|
|
2851
|
+
}, be(c, null, I))) : D("", !0),
|
|
2852
|
+
e.rowEditing && E(c, I) ? (s(), B(ve, {
|
|
2854
2853
|
key: 1,
|
|
2855
2854
|
type: "button",
|
|
2856
2855
|
variant: "tertiary",
|
|
2857
2856
|
title: e.cancelLabel,
|
|
2858
2857
|
"aria-label": e.cancelLabel,
|
|
2859
|
-
onClick: (
|
|
2858
|
+
onClick: (x) => le(c, I)
|
|
2860
2859
|
}, {
|
|
2861
2860
|
default: F(() => [
|
|
2862
2861
|
H(j(it), { class: "size-4" })
|
|
2863
2862
|
]),
|
|
2864
2863
|
_: 1
|
|
2865
|
-
}, 8, ["title", "aria-label", "onClick"])) : e.rowEditing ? (s(),
|
|
2864
|
+
}, 8, ["title", "aria-label", "onClick"])) : e.rowEditing ? (s(), B(ve, {
|
|
2866
2865
|
key: 2,
|
|
2867
2866
|
type: "button",
|
|
2868
2867
|
variant: "warning",
|
|
2869
2868
|
disabled: N(c, I),
|
|
2870
2869
|
title: e.editLabel,
|
|
2871
2870
|
"aria-label": e.editLabel,
|
|
2872
|
-
onClick: (
|
|
2871
|
+
onClick: (x) => J(c, I)
|
|
2873
2872
|
}, {
|
|
2874
2873
|
default: F(() => [
|
|
2875
2874
|
H(j(dt), { class: "size-4" })
|
|
2876
2875
|
]),
|
|
2877
2876
|
_: 1
|
|
2878
|
-
}, 8, ["disabled", "title", "aria-label", "onClick"])) :
|
|
2877
|
+
}, 8, ["disabled", "title", "aria-label", "onClick"])) : D("", !0)
|
|
2879
2878
|
])
|
|
2880
|
-
])) :
|
|
2879
|
+
])) : D("", !0)
|
|
2881
2880
|
], 2))), 128))
|
|
2882
2881
|
])
|
|
2883
2882
|
])
|
|
2884
|
-
], 2)) : (s(),
|
|
2885
|
-
|
|
2886
|
-
(s(),
|
|
2883
|
+
], 2)) : (s(), r("div", qs, [
|
|
2884
|
+
i("div", Gs, [
|
|
2885
|
+
(s(), B(Be(e.emptyState.icon), { class: "h-8 w-8 text-gray-400" }))
|
|
2887
2886
|
]),
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
e.emptyState.actionText && e.emptyState.actionUrl ? (s(),
|
|
2887
|
+
i("h3", Xs, A(e.emptyState.title), 1),
|
|
2888
|
+
i("p", Qs, A(e.emptyState.description), 1),
|
|
2889
|
+
e.emptyState.actionText && e.emptyState.actionUrl ? (s(), B(Ce, {
|
|
2891
2890
|
key: 0,
|
|
2892
2891
|
href: e.emptyState.actionUrl,
|
|
2893
2892
|
variant: "primary"
|
|
2894
2893
|
}, {
|
|
2895
2894
|
default: F(() => [
|
|
2896
|
-
|
|
2895
|
+
de(A(e.emptyState.actionText), 1)
|
|
2897
2896
|
]),
|
|
2898
2897
|
_: 1
|
|
2899
|
-
}, 8, ["href"])) :
|
|
2898
|
+
}, 8, ["href"])) : D("", !0)
|
|
2900
2899
|
]))
|
|
2901
2900
|
], 2));
|
|
2902
2901
|
}
|
|
@@ -2912,7 +2911,7 @@ export {
|
|
|
2912
2911
|
At as ActionSection,
|
|
2913
2912
|
Mt as ApplicationLogo,
|
|
2914
2913
|
Et as AuthenticationCard,
|
|
2915
|
-
|
|
2914
|
+
Nt as Badge,
|
|
2916
2915
|
Gt as Banner,
|
|
2917
2916
|
ve as Button,
|
|
2918
2917
|
De as Card,
|
|
@@ -2922,14 +2921,14 @@ export {
|
|
|
2922
2921
|
We as CheckboxMultipleInput,
|
|
2923
2922
|
Ml as ConfirmationModal,
|
|
2924
2923
|
Ee as CustomSelect,
|
|
2925
|
-
|
|
2924
|
+
Ne as DateInput,
|
|
2926
2925
|
El as DialogModal,
|
|
2927
2926
|
we as Divider,
|
|
2928
|
-
|
|
2927
|
+
Nl as Dropdown,
|
|
2929
2928
|
Kl as DropdownLink,
|
|
2930
2929
|
Js as EnosVue,
|
|
2931
2930
|
Gl as FormSection,
|
|
2932
|
-
|
|
2931
|
+
Re as ImageInput,
|
|
2933
2932
|
Ql as InputError,
|
|
2934
2933
|
me as InputGroup,
|
|
2935
2934
|
es as InputLabel,
|