@aeria-ui/ui 0.0.60 → 0.0.62
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/{activation-d4f4f8ae.js → activation-7645786e.js} +1 -1
- package/dist/{crud-view-c63e332c.js → crud-view-3df511a9.js} +1 -1
- package/dist/{index-a5e3cc58.js → index-13fe0da8.js} +372 -362
- package/dist/{password-change-f71d3af4.js → password-change-55124275.js} +1 -1
- package/dist/{profile-637f6183.js → profile-7847d400.js} +1 -1
- package/dist/{signin-19431012.js → signin-81d4ab57.js} +1 -1
- package/dist/{signup-245b6e05.js → signup-ab6052da.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/ui.js +1 -1
- package/package.json +2 -2
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { t as
|
|
3
|
-
import { useScrollObserver as We, useBreakpoints as je, useMask as Tt, PAGINATION_PER_PAGE_DEFAULTS as
|
|
1
|
+
import { defineComponent as U, ref as X, resolveDirective as ne, openBlock as o, createElementBlock as s, normalizeClass as G, Fragment as Z, renderList as E, withDirectives as N, toDisplayString as b, createCommentVNode as y, createTextVNode as Q, unref as e, renderSlot as C, inject as ve, computed as D, createElementVNode as g, mergeProps as H, createBlock as $, resolveDynamicComponent as he, withCtx as v, useCssVars as Vt, Teleport as Ge, onMounted as mt, watch as ue, createVNode as z, vModelDynamic as Ct, onBeforeMount as ft, normalizeStyle as $e, withModifiers as ze, pushScopeId as Fe, popScopeId as qe, provide as ye, normalizeProps as ce, guardReactiveProps as Ve, isRef as vt, createSlots as de, vModelCheckbox as It, onUnmounted as At, resolveComponent as Ot, Suspense as wt, useSlots as St, h as Bt } from "vue";
|
|
2
|
+
import { t as q, useI18n as jt } from "@aeria-ui/i18n";
|
|
3
|
+
import { useScrollObserver as We, useBreakpoints as je, useMask as Tt, PAGINATION_PER_PAGE_DEFAULTS as Rt, API_URL as yt, request as Lt, useDebounce as ht, isDocumentComplete as zt, getObjectKey as Mt, convertToSearchQuery as Ft, useAction as qt, convertFromSearchQuery as Ut, usePasswordPolicy as Et } from "@aeria-ui/core";
|
|
4
4
|
import { arraysIntersect as $t, getReferenceProperty as pe, convertConditionToQuery as Ht, deepClone as Be, freshItem as Dt, isRequired as Qt, evaluateCondition as Qe } from "@aeriajs/common";
|
|
5
|
-
import { useStore as
|
|
6
|
-
import { useRouter as
|
|
5
|
+
import { useStore as ie, getStoreId as Te, useParentStore as ge, STORE_ID as Ue, getGlobalStateManager as bt } from "@aeria-ui/state-management";
|
|
6
|
+
import { useRouter as Re } from "vue-router";
|
|
7
7
|
const Gt = ["onClick"], Wt = { key: 0 }, Kt = {
|
|
8
8
|
key: 0,
|
|
9
9
|
class: "accordion__content"
|
|
10
|
-
}, Xt = /* @__PURE__ */
|
|
10
|
+
}, Xt = /* @__PURE__ */ U({
|
|
11
11
|
__name: "aeria-accordion",
|
|
12
12
|
props: {
|
|
13
13
|
enumerate: { type: Boolean },
|
|
@@ -24,7 +24,7 @@ const Gt = ["onClick"], Wt = { key: 0 }, Kt = {
|
|
|
24
24
|
"accordion--padded": !a.noPadding
|
|
25
25
|
})
|
|
26
26
|
}, [
|
|
27
|
-
(o(!0), s(
|
|
27
|
+
(o(!0), s(Z, null, E(Object.keys(a.$slots).filter((u) => u !== "default"), (u, p) => (o(), s("div", {
|
|
28
28
|
key: u,
|
|
29
29
|
class: "accordion__slot"
|
|
30
30
|
}, [
|
|
@@ -33,7 +33,7 @@ const Gt = ["onClick"], Wt = { key: 0 }, Kt = {
|
|
|
33
33
|
onClick: (d) => i.value === u ? i.value = null : i.value = u
|
|
34
34
|
}, [
|
|
35
35
|
a.enumerate ? (o(), s("span", Wt, b(p + 1) + ". ", 1)) : y("", !0),
|
|
36
|
-
Q(" " + b(a.headers[u] ? t(a.headers[u]) : e(
|
|
36
|
+
Q(" " + b(a.headers[u] ? t(a.headers[u]) : e(q)(u)), 1)
|
|
37
37
|
], 8, Gt)), [
|
|
38
38
|
[r]
|
|
39
39
|
]),
|
|
@@ -50,7 +50,7 @@ const W = (c, i) => {
|
|
|
50
50
|
for (const [a, l] of i)
|
|
51
51
|
t[a] = l;
|
|
52
52
|
return t;
|
|
53
|
-
},
|
|
53
|
+
}, Rl = /* @__PURE__ */ W(Xt, [["__scopeId", "data-v-3ea933d4"]]), Yt = /* @__PURE__ */ U({
|
|
54
54
|
__name: "aeria-badge",
|
|
55
55
|
props: {
|
|
56
56
|
large: { type: Boolean },
|
|
@@ -68,7 +68,7 @@ const W = (c, i) => {
|
|
|
68
68
|
], 2));
|
|
69
69
|
}
|
|
70
70
|
});
|
|
71
|
-
const be = /* @__PURE__ */ W(Yt, [["__scopeId", "data-v-47f92648"]]), Jt = /* @__PURE__ */
|
|
71
|
+
const be = /* @__PURE__ */ W(Yt, [["__scopeId", "data-v-47f92648"]]), Jt = /* @__PURE__ */ U({
|
|
72
72
|
__name: "aeria-bare-button",
|
|
73
73
|
props: {
|
|
74
74
|
disabled: { type: Boolean }
|
|
@@ -92,7 +92,7 @@ const be = /* @__PURE__ */ W(Yt, [["__scopeId", "data-v-47f92648"]]), Jt = /* @_
|
|
|
92
92
|
const fe = /* @__PURE__ */ W(Jt, [["__scopeId", "data-v-35bc81ae"]]), Zt = ["href"], Pt = {
|
|
93
93
|
key: 0,
|
|
94
94
|
"data-component": "icon-label"
|
|
95
|
-
}, Nt = /* @__PURE__ */
|
|
95
|
+
}, Nt = /* @__PURE__ */ U({
|
|
96
96
|
__name: "aeria-icon",
|
|
97
97
|
props: {
|
|
98
98
|
icon: {},
|
|
@@ -143,7 +143,7 @@ const fe = /* @__PURE__ */ W(Jt, [["__scopeId", "data-v-35bc81ae"]]), Zt = ["hre
|
|
|
143
143
|
const P = /* @__PURE__ */ W(Nt, [["__scopeId", "data-v-4b763bd3"]]), xt = { class: "panel__header-left" }, en = { key: 1 }, tn = {
|
|
144
144
|
key: 2,
|
|
145
145
|
style: { "margin-left": "auto" }
|
|
146
|
-
}, nn = /* @__PURE__ */
|
|
146
|
+
}, nn = /* @__PURE__ */ U({
|
|
147
147
|
__name: "aeria-panel",
|
|
148
148
|
props: {
|
|
149
149
|
closeHint: { type: Boolean, default: !1 },
|
|
@@ -175,7 +175,7 @@ const P = /* @__PURE__ */ W(Nt, [["__scopeId", "data-v-4b763bd3"]]), xt = { clas
|
|
|
175
175
|
a("update:collapsed", n), r.value = n;
|
|
176
176
|
};
|
|
177
177
|
return (n, f) => {
|
|
178
|
-
const T = ne("clickable"), A = ne("loading"),
|
|
178
|
+
const T = ne("clickable"), A = ne("loading"), L = ne("overlay");
|
|
179
179
|
return n.modelValue ? N((o(), s("div", {
|
|
180
180
|
key: 0,
|
|
181
181
|
class: G(`
|
|
@@ -258,7 +258,7 @@ const P = /* @__PURE__ */ W(Nt, [["__scopeId", "data-v-4b763bd3"]]), xt = { clas
|
|
|
258
258
|
_: 3
|
|
259
259
|
}, 8, ["class"]))
|
|
260
260
|
], 2)), [
|
|
261
|
-
[
|
|
261
|
+
[L, {
|
|
262
262
|
condition: n.overlay || n.fixedRight || l.value,
|
|
263
263
|
invisible: n.invisibleOverlay,
|
|
264
264
|
click: h,
|
|
@@ -271,7 +271,7 @@ const P = /* @__PURE__ */ W(Nt, [["__scopeId", "data-v-4b763bd3"]]), xt = { clas
|
|
|
271
271
|
const Ae = /* @__PURE__ */ W(nn, [["__scopeId", "data-v-6fdc75a0"]]), on = { class: "button__content" }, an = {
|
|
272
272
|
key: 1,
|
|
273
273
|
class: "button__content"
|
|
274
|
-
}, ln = /* @__PURE__ */
|
|
274
|
+
}, ln = /* @__PURE__ */ U({
|
|
275
275
|
__name: "aeria-button",
|
|
276
276
|
props: {
|
|
277
277
|
size: {},
|
|
@@ -320,7 +320,7 @@ const Ae = /* @__PURE__ */ W(nn, [["__scopeId", "data-v-6fdc75a0"]]), on = { cla
|
|
|
320
320
|
}, 8, ["class", "disabled"]));
|
|
321
321
|
}
|
|
322
322
|
});
|
|
323
|
-
const
|
|
323
|
+
const re = /* @__PURE__ */ W(ln, [["__scopeId", "data-v-c328251b"]]), sn = { class: "card__picture" }, rn = { class: "card__footer" }, un = { class: "card__footer-upper" }, cn = { class: "card__badge" }, dn = /* @__PURE__ */ U({
|
|
324
324
|
__name: "aeria-card",
|
|
325
325
|
props: {
|
|
326
326
|
inactive: { type: Boolean },
|
|
@@ -354,7 +354,7 @@ const ie = /* @__PURE__ */ W(ln, [["__scopeId", "data-v-c328251b"]]), sn = { cla
|
|
|
354
354
|
const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { class: "content__body" }, mn = {
|
|
355
355
|
key: 0,
|
|
356
356
|
class: "content__section"
|
|
357
|
-
}, fn = { class: "content__item" }, vn = /* @__PURE__ */
|
|
357
|
+
}, fn = { class: "content__item" }, vn = /* @__PURE__ */ U({
|
|
358
358
|
__name: "aeria-context-menu",
|
|
359
359
|
props: {
|
|
360
360
|
actions: {},
|
|
@@ -364,12 +364,12 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
364
364
|
emits: ["actionClick"],
|
|
365
365
|
setup(c, { emit: i }) {
|
|
366
366
|
Vt((d) => ({
|
|
367
|
-
"
|
|
368
|
-
"
|
|
367
|
+
"50dae75f": p.value.x,
|
|
368
|
+
"50dae760": p.value.y
|
|
369
369
|
}));
|
|
370
370
|
const t = i, a = X(null), l = X(!1), r = (d) => d == null ? void 0 : d.filter((h) => {
|
|
371
371
|
if (h.roles) {
|
|
372
|
-
const _ =
|
|
372
|
+
const _ = ie("user");
|
|
373
373
|
return $t(h.roles, _.currentUser.roles);
|
|
374
374
|
}
|
|
375
375
|
return !0;
|
|
@@ -393,7 +393,7 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
393
393
|
});
|
|
394
394
|
return (d, h) => {
|
|
395
395
|
const _ = ne("overlay");
|
|
396
|
-
return o(), s(
|
|
396
|
+
return o(), s(Z, null, [
|
|
397
397
|
Object.keys(d.$slots).some((n) => n !== "default") || d.actions !== void 0 && d.actions.length > 0 ? (o(), s("div", {
|
|
398
398
|
key: 0,
|
|
399
399
|
ref_key: "contextmenu",
|
|
@@ -427,7 +427,7 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
427
427
|
class: "content__section",
|
|
428
428
|
onClick: h[1] || (h[1] = (n) => l.value = !1)
|
|
429
429
|
}, [
|
|
430
|
-
(o(!0), s(
|
|
430
|
+
(o(!0), s(Z, null, E(Object.keys(d.$slots).filter((n) => !["default", "extra", "header"].includes(n)), (n, f) => (o(), $(fe, {
|
|
431
431
|
key: `slot-${f}`,
|
|
432
432
|
class: "content__item content__item--reactive"
|
|
433
433
|
}, {
|
|
@@ -442,7 +442,7 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
442
442
|
class: "content__section",
|
|
443
443
|
onClick: h[2] || (h[2] = (n) => l.value = !1)
|
|
444
444
|
}, [
|
|
445
|
-
(o(!0), s(
|
|
445
|
+
(o(!0), s(Z, null, E(r(d.actions), (n, f) => (o(), $(fe, {
|
|
446
446
|
key: `action-${f}`,
|
|
447
447
|
class: "content__item content__item--reactive",
|
|
448
448
|
onClick: (T) => u(n, d.subject)
|
|
@@ -453,7 +453,7 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
453
453
|
icon: n.icon
|
|
454
454
|
}, {
|
|
455
455
|
default: v(() => [
|
|
456
|
-
Q(b(n.translate ? e(
|
|
456
|
+
Q(b(n.translate ? e(q)(n.label, { capitalize: !0 }) : n.label), 1)
|
|
457
457
|
]),
|
|
458
458
|
_: 2
|
|
459
459
|
}, 1032, ["icon"])) : y("", !0)
|
|
@@ -491,7 +491,7 @@ const pn = /* @__PURE__ */ W(dn, [["__scopeId", "data-v-c1a322df"]]), _n = { cla
|
|
|
491
491
|
};
|
|
492
492
|
}
|
|
493
493
|
});
|
|
494
|
-
const Ce = /* @__PURE__ */ W(vn, [["__scopeId", "data-v-
|
|
494
|
+
const Ce = /* @__PURE__ */ W(vn, [["__scopeId", "data-v-8fc3095d"]]), yn = { class: "info__content" }, hn = /* @__PURE__ */ U({
|
|
495
495
|
__name: "aeria-info",
|
|
496
496
|
props: {
|
|
497
497
|
where: {}
|
|
@@ -531,7 +531,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
531
531
|
}, Vn = ["placeholder", "readonly", "value"], Cn = ["value"], In = {
|
|
532
532
|
key: 1,
|
|
533
533
|
class: "input__clipboard"
|
|
534
|
-
}, An = /* @__PURE__ */
|
|
534
|
+
}, An = /* @__PURE__ */ U({
|
|
535
535
|
__name: "aeria-input",
|
|
536
536
|
props: {
|
|
537
537
|
modelValue: {},
|
|
@@ -579,7 +579,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
579
579
|
}, T = X([
|
|
580
580
|
"date",
|
|
581
581
|
"date-time"
|
|
582
|
-
].includes(n.type) ? f() : t.modelValue === null || t.modelValue === void 0 ? "" : t.modelValue), A = ((O = t.property) == null ? void 0 : O.type) === "string" && t.property.mask ? Tt(t.property.mask) : null,
|
|
582
|
+
].includes(n.type) ? f() : t.modelValue === null || t.modelValue === void 0 ? "" : t.modelValue), A = ((O = t.property) == null ? void 0 : O.type) === "string" && t.property.mask ? Tt(t.property.mask) : null, L = (M) => {
|
|
583
583
|
var K;
|
|
584
584
|
return typeof T.value == "string" && ((K = t.property) == null ? void 0 : K.type) === "string" && A !== null ? (T.value = A.enmask(T.value, void 0, {
|
|
585
585
|
defaultValue: !0
|
|
@@ -591,13 +591,13 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
591
591
|
if (n.type === "number" || n.type === "integer")
|
|
592
592
|
return Number(M);
|
|
593
593
|
if (!("type" in a && a.type === "string"))
|
|
594
|
-
return
|
|
594
|
+
return L(M);
|
|
595
595
|
switch (a.format) {
|
|
596
596
|
case "date":
|
|
597
597
|
case "date-time":
|
|
598
598
|
return new Date(M);
|
|
599
599
|
default:
|
|
600
|
-
return
|
|
600
|
+
return L(M);
|
|
601
601
|
}
|
|
602
602
|
})();
|
|
603
603
|
h("input", K), h("update:modelValue", K);
|
|
@@ -610,7 +610,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
610
610
|
defaultValue: !0
|
|
611
611
|
}) : String(M));
|
|
612
612
|
}), (M, K) => {
|
|
613
|
-
const
|
|
613
|
+
const S = ne("focus"), x = ne("clickable");
|
|
614
614
|
return o(), s("label", bn, [
|
|
615
615
|
e(u) ? y("", !0) : (o(), s("div", gn, [
|
|
616
616
|
M.$slots.default ? C(M.$slots, "default", { key: 0 }, void 0, !0) : C(M.$slots, "description", { key: 1 }, void 0, !0)
|
|
@@ -635,7 +635,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
635
635
|
`),
|
|
636
636
|
onInput: Y
|
|
637
637
|
}, null, 42, Vn), [
|
|
638
|
-
[
|
|
638
|
+
[S, e(a).focus]
|
|
639
639
|
])
|
|
640
640
|
], 2)) : (o(), s("div", {
|
|
641
641
|
key: 3,
|
|
@@ -656,7 +656,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
656
656
|
onInput: Y,
|
|
657
657
|
onChange: K[0] || (K[0] = (k) => h("change", k))
|
|
658
658
|
}), null, 16, Cn), [
|
|
659
|
-
[
|
|
659
|
+
[S, e(a).focus]
|
|
660
660
|
]),
|
|
661
661
|
e(l) ? (o(), $(P, {
|
|
662
662
|
key: 0,
|
|
@@ -690,7 +690,7 @@ const $n = /* @__PURE__ */ W(hn, [["__scopeId", "data-v-76defa0b"]]), bn = { cla
|
|
|
690
690
|
const Ie = /* @__PURE__ */ W(An, [["__scopeId", "data-v-7fdfb21c"]]), On = ["value"], wn = {
|
|
691
691
|
key: 1,
|
|
692
692
|
value: ""
|
|
693
|
-
}, Sn = ["value", "data-selected"], Bn = /* @__PURE__ */
|
|
693
|
+
}, Sn = ["value", "data-selected"], Bn = /* @__PURE__ */ U({
|
|
694
694
|
__name: "aeria-select",
|
|
695
695
|
props: {
|
|
696
696
|
modelValue: {},
|
|
@@ -747,18 +747,18 @@ const Ie = /* @__PURE__ */ W(An, [["__scopeId", "data-v-7fdfb21c"]]), On = ["val
|
|
|
747
747
|
key: 0,
|
|
748
748
|
icon: e(r).icon
|
|
749
749
|
}, null, 8, ["icon"])) : y("", !0),
|
|
750
|
-
t.multiple ? y("", !0) : (o(), s("option", wn, b(e(
|
|
751
|
-
(o(!0), s(
|
|
750
|
+
t.multiple ? y("", !0) : (o(), s("option", wn, b(e(q)("none")), 1)),
|
|
751
|
+
(o(!0), s(Z, null, E("enum" in e(r) ? e(r).enum : [], (f) => (o(), s("option", {
|
|
752
752
|
key: f,
|
|
753
753
|
value: f,
|
|
754
754
|
"data-selected": d(f)
|
|
755
|
-
}, b(e(r).translate ? e(
|
|
755
|
+
}, b(e(r).translate ? e(q)(f) : f), 9, Sn))), 128)),
|
|
756
756
|
C(_.$slots, "default", {}, void 0, !0)
|
|
757
757
|
], 16, On)
|
|
758
758
|
], 2));
|
|
759
759
|
}
|
|
760
760
|
});
|
|
761
|
-
const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { class: "pagination" }, Tn = ["value"],
|
|
761
|
+
const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { class: "pagination" }, Tn = ["value"], Rn = { class: "pagination__control" }, Ln = { class: "pagination__page-input" }, zn = /* @__PURE__ */ U({
|
|
762
762
|
__name: "aeria-pagination",
|
|
763
763
|
props: {
|
|
764
764
|
pagination: {}
|
|
@@ -797,14 +797,14 @@ const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { cla
|
|
|
797
797
|
class: "pagination__control"
|
|
798
798
|
}, {
|
|
799
799
|
default: v(() => [
|
|
800
|
-
(o(!0), s(
|
|
800
|
+
(o(!0), s(Z, null, E(e(Rt), (n) => (o(), s("option", {
|
|
801
801
|
key: `limit-${n}`,
|
|
802
802
|
value: n
|
|
803
803
|
}, b(n), 9, Tn))), 128))
|
|
804
804
|
]),
|
|
805
805
|
_: 1
|
|
806
806
|
}, 8, ["modelValue"]),
|
|
807
|
-
g("div",
|
|
807
|
+
g("div", Rn, [
|
|
808
808
|
z(fe, {
|
|
809
809
|
onClick: _[1] || (_[1] = (n) => l.value = 0)
|
|
810
810
|
}, {
|
|
@@ -828,7 +828,7 @@ const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { cla
|
|
|
828
828
|
]),
|
|
829
829
|
_: 1
|
|
830
830
|
}, 8, ["disabled"]),
|
|
831
|
-
g("div",
|
|
831
|
+
g("div", Ln, [
|
|
832
832
|
(o(), $(Ie, {
|
|
833
833
|
key: l.value,
|
|
834
834
|
modelValue: u.value,
|
|
@@ -841,7 +841,7 @@ const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { cla
|
|
|
841
841
|
l.value = u.value === 0 ? 0 : u.value - 1;
|
|
842
842
|
})
|
|
843
843
|
}, null, 8, ["modelValue"])),
|
|
844
|
-
g("span", null, b(e(
|
|
844
|
+
g("span", null, b(e(q)("of")) + " " + b(p.value), 1)
|
|
845
845
|
]),
|
|
846
846
|
z(fe, {
|
|
847
847
|
disabled: l.value === p.value - 1,
|
|
@@ -870,9 +870,9 @@ const Ee = /* @__PURE__ */ W(Bn, [["__scopeId", "data-v-7a33443b"]]), jn = { cla
|
|
|
870
870
|
]));
|
|
871
871
|
}
|
|
872
872
|
});
|
|
873
|
-
const Mn = /* @__PURE__ */ W(zn, [["__scopeId", "data-v-41aa1ffc"]]), Fn = { class: "checkbox__text" },
|
|
873
|
+
const Mn = /* @__PURE__ */ W(zn, [["__scopeId", "data-v-41aa1ffc"]]), Fn = { class: "checkbox__text" }, qn = ["innerHTML"], Un = { class: "checkbox__hint" }, En = ["innerHTML"], Hn = {
|
|
874
874
|
inheritAttrs: !1
|
|
875
|
-
}, Dn = /* @__PURE__ */
|
|
875
|
+
}, Dn = /* @__PURE__ */ U({
|
|
876
876
|
...Hn,
|
|
877
877
|
__name: "aeria-checkbox",
|
|
878
878
|
props: {
|
|
@@ -933,10 +933,10 @@ const Mn = /* @__PURE__ */ W(zn, [["__scopeId", "data-v-41aa1ffc"]]), Fn = { cla
|
|
|
933
933
|
g("div", null, [
|
|
934
934
|
d.$slots.description ? C(d.$slots, "description", { key: 0 }, void 0, !0) : e(u) ? (o(), s("div", {
|
|
935
935
|
key: 1,
|
|
936
|
-
innerHTML: e(a).translate ? e(
|
|
937
|
-
}, null, 8,
|
|
936
|
+
innerHTML: e(a).translate ? e(q)(e(u)) : e(u)
|
|
937
|
+
}, null, 8, qn)) : C(d.$slots, "default", { key: 2 }, void 0, !0)
|
|
938
938
|
]),
|
|
939
|
-
g("div",
|
|
939
|
+
g("div", Un, [
|
|
940
940
|
d.$slots.hint ? C(d.$slots, "hint", { key: 0 }, void 0, !0) : e(a).hint ? (o(), s("div", {
|
|
941
941
|
key: 1,
|
|
942
942
|
innerHTML: e(a).hint
|
|
@@ -951,7 +951,7 @@ const Mn = /* @__PURE__ */ W(zn, [["__scopeId", "data-v-41aa1ffc"]]), Fn = { cla
|
|
|
951
951
|
});
|
|
952
952
|
const Qn = /* @__PURE__ */ W(Dn, [["__scopeId", "data-v-256eb557"]]), Gn = {
|
|
953
953
|
inheritAttrs: !1
|
|
954
|
-
}, Wn = /* @__PURE__ */
|
|
954
|
+
}, Wn = /* @__PURE__ */ U({
|
|
955
955
|
...Gn,
|
|
956
956
|
__name: "aeria-options",
|
|
957
957
|
props: {
|
|
@@ -979,7 +979,7 @@ const Qn = /* @__PURE__ */ W(Dn, [["__scopeId", "data-v-256eb557"]]), Gn = {
|
|
|
979
979
|
grid-template-columns: repeat(var(--columns), 1fr);
|
|
980
980
|
`)
|
|
981
981
|
}, [
|
|
982
|
-
(o(!0), s(
|
|
982
|
+
(o(!0), s(Z, null, E(e(l), (d) => (o(), s("div", {
|
|
983
983
|
key: `option-${d}`,
|
|
984
984
|
class: "options__checkbox"
|
|
985
985
|
}, [
|
|
@@ -994,9 +994,9 @@ const Qn = /* @__PURE__ */ W(Dn, [["__scopeId", "data-v-256eb557"]]), Gn = {
|
|
|
994
994
|
], 4));
|
|
995
995
|
}
|
|
996
996
|
});
|
|
997
|
-
const Kn = /* @__PURE__ */ W(Wn, [["__scopeId", "data-v-43cda372"]]), Xn = (c) => (Fe("data-v-30f5a5ca"), c = c(),
|
|
997
|
+
const Kn = /* @__PURE__ */ W(Wn, [["__scopeId", "data-v-43cda372"]]), Xn = (c) => (Fe("data-v-30f5a5ca"), c = c(), qe(), c), Yn = { class: "switch-wrapper" }, Jn = /* @__PURE__ */ Xn(() => /* @__PURE__ */ g("div", { class: "switch__slider" }, null, -1)), Zn = { key: 1 }, Pn = {
|
|
998
998
|
inheritAttrs: !1
|
|
999
|
-
}, Nn = /* @__PURE__ */
|
|
999
|
+
}, Nn = /* @__PURE__ */ U({
|
|
1000
1000
|
...Pn,
|
|
1001
1001
|
__name: "aeria-switch",
|
|
1002
1002
|
props: {
|
|
@@ -1039,7 +1039,7 @@ const Kn = /* @__PURE__ */ W(Wn, [["__scopeId", "data-v-43cda372"]]), Xn = (c) =
|
|
|
1039
1039
|
};
|
|
1040
1040
|
}
|
|
1041
1041
|
});
|
|
1042
|
-
const xn = /* @__PURE__ */ W(Nn, [["__scopeId", "data-v-30f5a5ca"]]), gt = (c) => (Fe("data-v-153a2e0f"), c = c(),
|
|
1042
|
+
const xn = /* @__PURE__ */ W(Nn, [["__scopeId", "data-v-30f5a5ca"]]), gt = (c) => (Fe("data-v-153a2e0f"), c = c(), qe(), c), eo = { class: "picture" }, to = {
|
|
1043
1043
|
key: 0,
|
|
1044
1044
|
style: { position: "fixed", top: "50%", left: "50%", transform: "translate(-50%, -50%)" }
|
|
1045
1045
|
}, no = ["src", "alt"], oo = {
|
|
@@ -1062,7 +1062,7 @@ const xn = /* @__PURE__ */ W(Nn, [["__scopeId", "data-v-30f5a5ca"]]), gt = (c) =
|
|
|
1062
1062
|
}, null, -1)), io = [
|
|
1063
1063
|
lo,
|
|
1064
1064
|
so
|
|
1065
|
-
], ro = { key: 5 }, uo = /* @__PURE__ */
|
|
1065
|
+
], ro = { key: 5 }, uo = /* @__PURE__ */ U({
|
|
1066
1066
|
__name: "aeria-picture",
|
|
1067
1067
|
props: {
|
|
1068
1068
|
url: {},
|
|
@@ -1148,7 +1148,7 @@ const Me = /* @__PURE__ */ W(uo, [["__scopeId", "data-v-153a2e0f"]]), co = { cla
|
|
|
1148
1148
|
}, yo = {
|
|
1149
1149
|
key: 1,
|
|
1150
1150
|
class: "file__buttons"
|
|
1151
|
-
}, ho = /* @__PURE__ */
|
|
1151
|
+
}, ho = /* @__PURE__ */ U({
|
|
1152
1152
|
__name: "aeria-file",
|
|
1153
1153
|
props: {
|
|
1154
1154
|
modelValue: {},
|
|
@@ -1166,22 +1166,22 @@ const Me = /* @__PURE__ */ W(uo, [["__scopeId", "data-v-153a2e0f"]]), co = { cla
|
|
|
1166
1166
|
var A;
|
|
1167
1167
|
return u.value ? URL.createObjectURL(u.value) : (A = t.modelValue) == null ? void 0 : A.link;
|
|
1168
1168
|
}), d = D(() => {
|
|
1169
|
-
var A,
|
|
1170
|
-
return /^image\//.test((A = t.modelValue) == null ? void 0 : A.type) && !((
|
|
1171
|
-
}), h = (A) => new Promise((
|
|
1169
|
+
var A, L, F;
|
|
1170
|
+
return /^image\//.test((A = t.modelValue) == null ? void 0 : A.type) && !((L = u.value) != null && L.type) || /^image\//.test((F = u.value) == null ? void 0 : F.type);
|
|
1171
|
+
}), h = (A) => new Promise((L) => {
|
|
1172
1172
|
const F = new FileReader();
|
|
1173
|
-
F.onload = () =>
|
|
1173
|
+
F.onload = () => L(F.result), F.readAsArrayBuffer(A);
|
|
1174
1174
|
}), _ = () => {
|
|
1175
1175
|
t.modelValue.tempId && a("update:modelValue", null), u.value = null;
|
|
1176
1176
|
}, n = async (A) => {
|
|
1177
1177
|
u.value = A.target.files[0];
|
|
1178
|
-
const
|
|
1178
|
+
const L = u.value, F = await h(L);
|
|
1179
1179
|
if (r) {
|
|
1180
|
-
const { data: { error: Y, result: O } } = await
|
|
1180
|
+
const { data: { error: Y, result: O } } = await Lt(`${yt}/${r.$id}/upload?name=${L.name}`, F, {
|
|
1181
1181
|
params: {
|
|
1182
1182
|
method: "POST",
|
|
1183
1183
|
headers: {
|
|
1184
|
-
"content-type":
|
|
1184
|
+
"content-type": L.type || "application/octet-stream",
|
|
1185
1185
|
"x-stream-request": "1"
|
|
1186
1186
|
}
|
|
1187
1187
|
}
|
|
@@ -1190,22 +1190,22 @@ const Me = /* @__PURE__ */ W(uo, [["__scopeId", "data-v-153a2e0f"]]), co = { cla
|
|
|
1190
1190
|
return;
|
|
1191
1191
|
a("update:modelValue", {
|
|
1192
1192
|
tempId: O.tempId,
|
|
1193
|
-
file:
|
|
1193
|
+
file: L
|
|
1194
1194
|
});
|
|
1195
1195
|
} else
|
|
1196
|
-
a("update:modelValue",
|
|
1196
|
+
a("update:modelValue", L);
|
|
1197
1197
|
a("update:content", F), a("change", F);
|
|
1198
1198
|
}, f = async () => {
|
|
1199
1199
|
a("update:modelValue", null);
|
|
1200
1200
|
};
|
|
1201
|
-
return (A,
|
|
1202
|
-
var F, Y, O, M, K,
|
|
1201
|
+
return (A, L) => {
|
|
1202
|
+
var F, Y, O, M, K, S;
|
|
1203
1203
|
return o(), s("div", co, [
|
|
1204
1204
|
u.value || (F = A.modelValue) != null && F._id ? (o(), s("div", po, [
|
|
1205
1205
|
d.value ? (o(), $(Me, {
|
|
1206
1206
|
key: 0,
|
|
1207
1207
|
modelValue: p.value,
|
|
1208
|
-
"onUpdate:modelValue":
|
|
1208
|
+
"onUpdate:modelValue": L[0] || (L[0] = (x) => p.value = x),
|
|
1209
1209
|
alt: "Image preview",
|
|
1210
1210
|
class: G(`
|
|
1211
1211
|
file__image
|
|
@@ -1225,22 +1225,22 @@ const Me = /* @__PURE__ */ W(uo, [["__scopeId", "data-v-153a2e0f"]]), co = { cla
|
|
|
1225
1225
|
onChange: n
|
|
1226
1226
|
}, null, 40, fo),
|
|
1227
1227
|
u.value ? (o(), s("div", vo, [
|
|
1228
|
-
z(
|
|
1228
|
+
z(re, {
|
|
1229
1229
|
small: "",
|
|
1230
1230
|
onClick: ze(_, ["prevent"])
|
|
1231
1231
|
}, {
|
|
1232
1232
|
default: v(() => [
|
|
1233
|
-
Q(b(e(
|
|
1233
|
+
Q(b(e(q)("action.clear", { capitalize: !0 })), 1)
|
|
1234
1234
|
]),
|
|
1235
1235
|
_: 1
|
|
1236
1236
|
})
|
|
1237
|
-
])) : (
|
|
1238
|
-
z(
|
|
1237
|
+
])) : (S = A.modelValue) != null && S._id ? (o(), s("div", yo, [
|
|
1238
|
+
z(re, {
|
|
1239
1239
|
small: "",
|
|
1240
1240
|
onClick: ze(f, ["prevent"])
|
|
1241
1241
|
}, {
|
|
1242
1242
|
default: v(() => [
|
|
1243
|
-
Q(b(e(
|
|
1243
|
+
Q(b(e(q)("action.remove", { capitalize: !0 })), 1)
|
|
1244
1244
|
]),
|
|
1245
1245
|
_: 1
|
|
1246
1246
|
})
|
|
@@ -1253,7 +1253,7 @@ const Me = /* @__PURE__ */ W(uo, [["__scopeId", "data-v-153a2e0f"]]), co = { cla
|
|
|
1253
1253
|
const $o = /* @__PURE__ */ W(ho, [["__scopeId", "data-v-0e66cd51"]]), bo = { class: "container" }, go = {
|
|
1254
1254
|
key: 1,
|
|
1255
1255
|
class: "container__footer"
|
|
1256
|
-
}, ko = /* @__PURE__ */
|
|
1256
|
+
}, ko = /* @__PURE__ */ U({
|
|
1257
1257
|
__name: "aeria-search-container",
|
|
1258
1258
|
props: {
|
|
1259
1259
|
observeScroll: { type: Boolean }
|
|
@@ -1280,7 +1280,7 @@ const $o = /* @__PURE__ */ W(ho, [["__scopeId", "data-v-0e66cd51"]]), bo = { cla
|
|
|
1280
1280
|
]));
|
|
1281
1281
|
}
|
|
1282
1282
|
});
|
|
1283
|
-
const it = /* @__PURE__ */ W(ko, [["__scopeId", "data-v-c86e2d2a"]]), Vo = { class: "item__values" }, Co = /* @__PURE__ */
|
|
1283
|
+
const it = /* @__PURE__ */ W(ko, [["__scopeId", "data-v-c86e2d2a"]]), Vo = { class: "item__values" }, Co = /* @__PURE__ */ U({
|
|
1284
1284
|
__name: "aeria-search-item",
|
|
1285
1285
|
props: {
|
|
1286
1286
|
item: {},
|
|
@@ -1324,7 +1324,7 @@ const it = /* @__PURE__ */ W(ko, [["__scopeId", "data-v-c86e2d2a"]]), Vo = { cla
|
|
|
1324
1324
|
}, [
|
|
1325
1325
|
C(_.$slots, "default", {}, void 0, !0),
|
|
1326
1326
|
g("div", Vo, [
|
|
1327
|
-
(o(!0), s(
|
|
1327
|
+
(o(!0), s(Z, null, E(_.indexes, (T, A) => (o(), s("div", {
|
|
1328
1328
|
key: `index-${_.item._id}-${A}`,
|
|
1329
1329
|
class: "item__value"
|
|
1330
1330
|
}, b(_.item[T]), 1))), 128))
|
|
@@ -1335,10 +1335,10 @@ const it = /* @__PURE__ */ W(ko, [["__scopeId", "data-v-c86e2d2a"]]), Vo = { cla
|
|
|
1335
1335
|
};
|
|
1336
1336
|
}
|
|
1337
1337
|
});
|
|
1338
|
-
const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { class: "search__panel" }, Ao = { class: "search__input" }, Oo = ["value"], wo = { style: { flex: "1" } }, So = { key: 1 }, Bo = { key: 0 }, jo = { key: 1 }, To = { class: "search__summary" },
|
|
1338
|
+
const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { class: "search__panel" }, Ao = { class: "search__input" }, Oo = ["value"], wo = { style: { flex: "1" } }, So = { key: 1 }, Bo = { key: 0 }, jo = { key: 1 }, To = { class: "search__summary" }, Ro = {
|
|
1339
1339
|
key: 1,
|
|
1340
1340
|
class: "search"
|
|
1341
|
-
},
|
|
1341
|
+
}, Lo = { key: 0 }, Le = 10, zo = /* @__PURE__ */ U({
|
|
1342
1342
|
__name: "aeria-search",
|
|
1343
1343
|
props: {
|
|
1344
1344
|
modelValue: {},
|
|
@@ -1351,39 +1351,39 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1351
1351
|
},
|
|
1352
1352
|
emits: ["update:modelValue", "change", "update:panel"],
|
|
1353
1353
|
setup(c, { emit: i }) {
|
|
1354
|
-
const t = c, a = pe(t.property), l = t.panel !== void 0 ? D(() => t.panel) : X(!1), r = i, u =
|
|
1355
|
-
ye(
|
|
1354
|
+
const t = c, a = pe(t.property), l = t.panel !== void 0 ? D(() => t.panel) : X(!1), r = i, u = ie(pe(t.property).$ref), p = Te(), d = p ? ge() : null, h = a.indexes;
|
|
1355
|
+
ye(Ue, pe(t.property).$ref), ye("innerInputLabel", !0), ye("omitInputLabels", !0);
|
|
1356
1356
|
const _ = X(t.modelValue), n = X({
|
|
1357
1357
|
data: [],
|
|
1358
1358
|
pagination: {}
|
|
1359
|
-
}), f = D(() => n.value.data), T = D(() => n.value.pagination), A = X(0),
|
|
1359
|
+
}), f = D(() => n.value.data), T = D(() => n.value.pagination), A = X(0), L = X(h[0]), F = X(!1), Y = X({}), O = () => {
|
|
1360
1360
|
const I = {};
|
|
1361
1361
|
if (p) {
|
|
1362
|
-
const
|
|
1363
|
-
I[
|
|
1362
|
+
const w = e(p);
|
|
1363
|
+
I[w] = d;
|
|
1364
1364
|
}
|
|
1365
1365
|
return a.constraints ? Ht(a.constraints, I) : {};
|
|
1366
1366
|
}, M = () => {
|
|
1367
|
-
f.value.length < T.value.recordsTotal && (A.value += 1,
|
|
1367
|
+
f.value.length < T.value.recordsTotal && (A.value += 1, S());
|
|
1368
1368
|
}, K = async () => {
|
|
1369
|
-
if (Object.values(Y.value).every((
|
|
1369
|
+
if (Object.values(Y.value).every((w) => !(String(w).length > 0)))
|
|
1370
1370
|
return u.$actions.custom("getAll", {
|
|
1371
|
-
limit:
|
|
1372
|
-
offset: A.value *
|
|
1371
|
+
limit: Le,
|
|
1372
|
+
offset: A.value * Le,
|
|
1373
1373
|
filters: O()
|
|
1374
1374
|
});
|
|
1375
|
-
const I = h.filter((
|
|
1376
|
-
var
|
|
1377
|
-
return ((
|
|
1378
|
-
}).map((
|
|
1379
|
-
[
|
|
1380
|
-
$regex: Y.value[
|
|
1375
|
+
const I = h.filter((w) => {
|
|
1376
|
+
var J;
|
|
1377
|
+
return ((J = Y.value[w]) == null ? void 0 : J.length) > 0;
|
|
1378
|
+
}).map((w) => ({
|
|
1379
|
+
[w]: {
|
|
1380
|
+
$regex: Y.value[w].trim().replace("(", "\\(").replace(")", "\\)"),
|
|
1381
1381
|
$options: "i"
|
|
1382
1382
|
}
|
|
1383
1383
|
}));
|
|
1384
1384
|
return u.$actions.custom("getAll", {
|
|
1385
|
-
limit:
|
|
1386
|
-
offset: A.value *
|
|
1385
|
+
limit: Le,
|
|
1386
|
+
offset: A.value * Le,
|
|
1387
1387
|
filters: {
|
|
1388
1388
|
...O(),
|
|
1389
1389
|
...I.length > 0 && {
|
|
@@ -1391,34 +1391,41 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1391
1391
|
}
|
|
1392
1392
|
}
|
|
1393
1393
|
});
|
|
1394
|
-
},
|
|
1394
|
+
}, S = async () => {
|
|
1395
1395
|
if (u.loading.getAll)
|
|
1396
1396
|
return;
|
|
1397
|
-
const I = await K();
|
|
1398
|
-
|
|
1397
|
+
const { error: I, result: w } = await K();
|
|
1398
|
+
if (I) {
|
|
1399
|
+
ie("meta").$actions.spawnToast({
|
|
1400
|
+
text: "Request failed",
|
|
1401
|
+
icon: "warning"
|
|
1402
|
+
});
|
|
1403
|
+
return;
|
|
1404
|
+
}
|
|
1405
|
+
n.value.pagination = w.pagination, A.value === 0 && n.value.data.splice(0), n.value.data.push(...w.data);
|
|
1399
1406
|
}, [x] = ht({
|
|
1400
1407
|
delay: 800
|
|
1401
1408
|
})(() => {
|
|
1402
|
-
A.value = 0,
|
|
1409
|
+
A.value = 0, S(), F.value = !1;
|
|
1403
1410
|
}), k = () => {
|
|
1404
1411
|
F.value = !0, x();
|
|
1405
|
-
},
|
|
1406
|
-
"effect" in l ? r("update:panel", !0) : l.value = !0,
|
|
1412
|
+
}, R = () => {
|
|
1413
|
+
"effect" in l ? r("update:panel", !0) : l.value = !0, S();
|
|
1407
1414
|
}, te = () => {
|
|
1408
1415
|
A.value = 0, n.value.data.splice(0), "effect" in l ? r("update:panel", !1) : l.value = !1;
|
|
1409
|
-
},
|
|
1410
|
-
ue(
|
|
1411
|
-
I && !
|
|
1416
|
+
}, ae = D(() => !Object.values(Y.value).some((I) => !!I));
|
|
1417
|
+
ue(ae, (I, w) => {
|
|
1418
|
+
I && !w && S();
|
|
1412
1419
|
}), mt(() => {
|
|
1413
|
-
t.selectOnly &&
|
|
1420
|
+
t.selectOnly && S();
|
|
1414
1421
|
});
|
|
1415
|
-
const
|
|
1422
|
+
const oe = (I) => {
|
|
1416
1423
|
_.value = I, t.selectOnly || r("update:modelValue", I);
|
|
1417
1424
|
}, m = () => {
|
|
1418
1425
|
te(), r("update:modelValue", _.value);
|
|
1419
1426
|
};
|
|
1420
|
-
return (I,
|
|
1421
|
-
const
|
|
1427
|
+
return (I, w) => {
|
|
1428
|
+
const J = ne("clickable");
|
|
1422
1429
|
return o(), s("div", null, [
|
|
1423
1430
|
e(l) ? (o(), $(Ge, {
|
|
1424
1431
|
key: 0,
|
|
@@ -1427,7 +1434,7 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1427
1434
|
z(Ae, {
|
|
1428
1435
|
float: "",
|
|
1429
1436
|
"close-hint": "",
|
|
1430
|
-
title: `${e(
|
|
1437
|
+
title: `${e(q)("action.select", { capitalize: !0 })} ${e(q)(I.propertyName)}`,
|
|
1431
1438
|
"overlay-layer": 65,
|
|
1432
1439
|
"model-value": e(l),
|
|
1433
1440
|
style: { "--panel-max-width": "36rem" },
|
|
@@ -1435,12 +1442,12 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1435
1442
|
onOverlayClick: te
|
|
1436
1443
|
}, {
|
|
1437
1444
|
footer: v(() => [
|
|
1438
|
-
z(
|
|
1445
|
+
z(re, {
|
|
1439
1446
|
large: "",
|
|
1440
1447
|
onClick: m
|
|
1441
1448
|
}, {
|
|
1442
1449
|
default: v(() => [
|
|
1443
|
-
Q(b(e(
|
|
1450
|
+
Q(b(e(q)("action.save", { capitalize: !0 })), 1)
|
|
1444
1451
|
]),
|
|
1445
1452
|
_: 1
|
|
1446
1453
|
})
|
|
@@ -1452,25 +1459,25 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1452
1459
|
g("div", Ao, [
|
|
1453
1460
|
e(h).length > 1 ? (o(), $(Ee, {
|
|
1454
1461
|
key: 0,
|
|
1455
|
-
modelValue:
|
|
1456
|
-
"onUpdate:modelValue":
|
|
1457
|
-
onChange:
|
|
1462
|
+
modelValue: L.value,
|
|
1463
|
+
"onUpdate:modelValue": w[0] || (w[0] = (B) => L.value = B),
|
|
1464
|
+
onChange: w[1] || (w[1] = (B) => Y.value = {})
|
|
1458
1465
|
}, {
|
|
1459
1466
|
default: v(() => [
|
|
1460
|
-
(o(!0), s(
|
|
1467
|
+
(o(!0), s(Z, null, E(e(h), (B) => (o(), s("option", {
|
|
1461
1468
|
key: `searchfield-${B}`,
|
|
1462
1469
|
value: B
|
|
1463
|
-
}, b(e(
|
|
1470
|
+
}, b(e(q)(B)), 9, Oo))), 128))
|
|
1464
1471
|
]),
|
|
1465
1472
|
_: 1
|
|
1466
1473
|
}, 8, ["modelValue"])) : y("", !0),
|
|
1467
1474
|
g("div", wo, [
|
|
1468
1475
|
(o(), $(Ie, {
|
|
1469
|
-
key: `field-${
|
|
1470
|
-
modelValue: Y.value[
|
|
1471
|
-
"onUpdate:modelValue":
|
|
1476
|
+
key: `field-${L.value}`,
|
|
1477
|
+
modelValue: Y.value[L.value],
|
|
1478
|
+
"onUpdate:modelValue": w[2] || (w[2] = (B) => Y.value[L.value] = B),
|
|
1472
1479
|
property: {
|
|
1473
|
-
...e(u).properties[
|
|
1480
|
+
...e(u).properties[L.value],
|
|
1474
1481
|
inputType: "search"
|
|
1475
1482
|
},
|
|
1476
1483
|
onInput: k
|
|
@@ -1483,61 +1490,61 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1483
1490
|
onEndReached: M
|
|
1484
1491
|
}, {
|
|
1485
1492
|
default: v(() => [
|
|
1486
|
-
(o(!0), s(
|
|
1493
|
+
(o(!0), s(Z, null, E(f.value, (B) => (o(), $(De, H({ ref_for: !0 }, {
|
|
1487
1494
|
item: B,
|
|
1488
1495
|
indexes: e(h),
|
|
1489
1496
|
property: I.property
|
|
1490
1497
|
}, {
|
|
1491
1498
|
key: `matching-${B._id}`,
|
|
1492
1499
|
modelValue: _.value,
|
|
1493
|
-
"onUpdate:modelValue":
|
|
1500
|
+
"onUpdate:modelValue": w[3] || (w[3] = (le) => _.value = le)
|
|
1494
1501
|
}), null, 16, ["modelValue"]))), 128))
|
|
1495
1502
|
]),
|
|
1496
1503
|
_: 1
|
|
1497
1504
|
})) : (o(), s("div", So, [
|
|
1498
|
-
F.value ? (o(), s("div", Bo, b(e(
|
|
1505
|
+
F.value ? (o(), s("div", Bo, b(e(q)("searching", { capitalize: !0 })) + "... ", 1)) : !e(u).loading.getAll && Object.values(Y.value).filter((B) => !!B).length > 0 && !("items" in I.property && ((V = I.modelValue) != null && V.length) || !Array.isArray(I.modelValue) && ((j = I.modelValue) != null && j._id)) ? (o(), s("div", jo, b(e(q)("no_results", { capitalize: !0 })), 1)) : y("", !0)
|
|
1499
1506
|
]))
|
|
1500
1507
|
]),
|
|
1501
|
-
g("div", To, b(e(
|
|
1508
|
+
g("div", To, b(e(q)("showing", { capitalize: !0 })) + " " + b(f.value.length) + " " + b(e(q)("of")) + " " + b(T.value.recordsTotal), 1)
|
|
1502
1509
|
];
|
|
1503
1510
|
}),
|
|
1504
1511
|
_: 1
|
|
1505
1512
|
}, 8, ["title", "model-value"])
|
|
1506
1513
|
])) : y("", !0),
|
|
1507
|
-
I.selectOnly ? y("", !0) : (o(), s("div",
|
|
1514
|
+
I.selectOnly ? y("", !0) : (o(), s("div", Ro, [
|
|
1508
1515
|
z(it, null, {
|
|
1509
1516
|
footer: v(() => [
|
|
1510
1517
|
N((o(), $(P, {
|
|
1511
1518
|
icon: "plus",
|
|
1512
|
-
onClick:
|
|
1519
|
+
onClick: R
|
|
1513
1520
|
}, {
|
|
1514
1521
|
default: v(() => [
|
|
1515
|
-
Q(b(e(
|
|
1522
|
+
Q(b(e(q)("action.select", { capitalize: !0 })), 1)
|
|
1516
1523
|
]),
|
|
1517
1524
|
_: 1
|
|
1518
1525
|
})), [
|
|
1519
|
-
[
|
|
1526
|
+
[J]
|
|
1520
1527
|
])
|
|
1521
1528
|
]),
|
|
1522
1529
|
default: v(() => {
|
|
1523
1530
|
var V;
|
|
1524
1531
|
return [
|
|
1525
|
-
"items" in I.property ? (o(), s("div",
|
|
1526
|
-
(o(!0), s(
|
|
1532
|
+
"items" in I.property ? (o(), s("div", Lo, [
|
|
1533
|
+
(o(!0), s(Z, null, E(I.modelValue, (j) => (o(), $(De, H({ ref_for: !0 }, {
|
|
1527
1534
|
item: j,
|
|
1528
1535
|
indexes: e(h),
|
|
1529
1536
|
property: I.property,
|
|
1530
1537
|
modelValue: I.modelValue
|
|
1531
1538
|
}, {
|
|
1532
1539
|
key: `selected-${j._id}`,
|
|
1533
|
-
"onUpdate:modelValue":
|
|
1540
|
+
"onUpdate:modelValue": oe
|
|
1534
1541
|
}), null, 16))), 128))
|
|
1535
1542
|
])) : (V = I.modelValue) != null && V._id ? (o(), $(De, H({ key: 1 }, {
|
|
1536
1543
|
item: I.modelValue,
|
|
1537
1544
|
indexes: e(h),
|
|
1538
1545
|
property: e(a),
|
|
1539
1546
|
modelValue: I.modelValue
|
|
1540
|
-
}, { "onUpdate:modelValue":
|
|
1547
|
+
}, { "onUpdate:modelValue": oe }), null, 16)) : y("", !0)
|
|
1541
1548
|
];
|
|
1542
1549
|
}),
|
|
1543
1550
|
_: 1
|
|
@@ -1547,7 +1554,7 @@ const De = /* @__PURE__ */ W(Co, [["__scopeId", "data-v-fa7fea9f"]]), Io = { cla
|
|
|
1547
1554
|
};
|
|
1548
1555
|
}
|
|
1549
1556
|
});
|
|
1550
|
-
const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-
|
|
1557
|
+
const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-32560ddf"]]), rt = (c, i) => {
|
|
1551
1558
|
const t = "items" in c ? c.items : c, a = {
|
|
1552
1559
|
options: Kn,
|
|
1553
1560
|
select: Ee,
|
|
@@ -1577,13 +1584,13 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1577
1584
|
c ?? (c = []);
|
|
1578
1585
|
const a = "items" in i ? i.items : i;
|
|
1579
1586
|
if ("$ref" in a) {
|
|
1580
|
-
const l =
|
|
1587
|
+
const l = ie(a.$ref, t), r = Be(l.$freshItem);
|
|
1581
1588
|
return c.push(r);
|
|
1582
1589
|
}
|
|
1583
1590
|
return "properties" in a ? c.push(Dt(a)) : "type" in a && a.type === "boolean" ? c.push({}) : c.push(null);
|
|
1584
|
-
},
|
|
1591
|
+
}, qo = (c, i) => {
|
|
1585
1592
|
c.splice(i, 1);
|
|
1586
|
-
},
|
|
1593
|
+
}, Uo = {
|
|
1587
1594
|
key: 0,
|
|
1588
1595
|
class: "form__header"
|
|
1589
1596
|
}, Eo = {
|
|
@@ -1598,7 +1605,7 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1598
1605
|
}, Po = { key: 0 }, No = { key: 1 }, xo = {
|
|
1599
1606
|
key: 3,
|
|
1600
1607
|
class: "form__footer"
|
|
1601
|
-
}, ea = /* @__PURE__ */
|
|
1608
|
+
}, ea = /* @__PURE__ */ U({
|
|
1602
1609
|
__name: "aeria-form",
|
|
1603
1610
|
props: {
|
|
1604
1611
|
modelValue: {},
|
|
@@ -1628,73 +1635,73 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1628
1635
|
ft(() => {
|
|
1629
1636
|
a.modelValue || l("update:modelValue", a.property && "items" in a.property ? [] : {});
|
|
1630
1637
|
});
|
|
1631
|
-
const r = a.property && pe(a.property), u = r ? r.$ref : a.collection || Te(), p = u ?
|
|
1638
|
+
const r = a.property && pe(a.property), u = r ? r.$ref : a.collection || Te(), p = u ? ie(e(u)) : null;
|
|
1632
1639
|
!u && process.env.NODE_ENV !== "production" && console.warn(`aeria-form was used without providing storeId or specifying
|
|
1633
1640
|
collection prop, some features may not work as intended`);
|
|
1634
1641
|
const d = X(!1), h = D(() => !a.form && a.property ? "properties" in a.property ? a.property.properties : p == null ? void 0 : p.properties : a.form), _ = D(() => a.layout || (p == null ? void 0 : p.description.formLayout)), n = (m) => {
|
|
1635
1642
|
const I = ve(m, a[m]);
|
|
1636
1643
|
return a[m] && ye(m, a[m]), I;
|
|
1637
|
-
}, f = D(() => a.validationErrors !== null ? a.validationErrors : p == null ? void 0 : p.validationErrors), T = n("formComponents") || {}, A = n("propertyComponents") || {},
|
|
1638
|
-
u && ye(
|
|
1639
|
-
const O = (m) => h.value ? Object.entries(h.value).filter(([I,
|
|
1644
|
+
}, f = D(() => a.validationErrors !== null ? a.validationErrors : p == null ? void 0 : p.validationErrors), T = n("formComponents") || {}, A = n("propertyComponents") || {}, L = n("omitFormHeader"), F = n("omitInputLabels"), Y = n("innerInputLabel");
|
|
1645
|
+
u && ye(Ue, u), ye("searchOnly", a.searchOnly);
|
|
1646
|
+
const O = (m) => h.value ? Object.entries(h.value).filter(([I, w]) => !w.noForm && m([
|
|
1640
1647
|
I,
|
|
1641
|
-
|
|
1648
|
+
w
|
|
1642
1649
|
])) : null, M = (m) => {
|
|
1643
|
-
var
|
|
1650
|
+
var w;
|
|
1644
1651
|
if (a.searchOnly || !u)
|
|
1645
1652
|
return !0;
|
|
1646
|
-
const I = a.property && "properties" in a.property ? a.property.form : (
|
|
1653
|
+
const I = a.property && "properties" in a.property ? a.property.form : (w = p == null ? void 0 : p.description) == null ? void 0 : w.form;
|
|
1647
1654
|
return !I || I.includes(m);
|
|
1648
|
-
}, K = O(([m]) => M(m)),
|
|
1649
|
-
var j, B,
|
|
1650
|
-
const
|
|
1655
|
+
}, K = O(([m]) => M(m)), S = je(), x = {}, k = (m, I) => {
|
|
1656
|
+
var j, B, le, _e;
|
|
1657
|
+
const w = [], J = ((B = (j = _.value) == null ? void 0 : j.fields) == null ? void 0 : B[m]) || ((_e = (le = _.value) == null ? void 0 : le.fields) == null ? void 0 : _e.$default);
|
|
1651
1658
|
if (!I)
|
|
1652
1659
|
return;
|
|
1653
|
-
if (
|
|
1660
|
+
if (J != null && J.if && !a.searchOnly) {
|
|
1654
1661
|
const me = Qe(
|
|
1655
1662
|
a.modelValue,
|
|
1656
|
-
|
|
1663
|
+
J.if
|
|
1657
1664
|
);
|
|
1658
1665
|
me.satisfied || (x[m] && (p ? a.modelValue[m] = typeof p.$freshItem[m] == "object" ? Be(p.$freshItem[m]) : p.$freshItem[m] : a.modelValue[m] = [
|
|
1659
1666
|
void 0,
|
|
1660
1667
|
null
|
|
1661
|
-
].includes(a.modelValue[m]) ? null : a.modelValue[m].constructor()),
|
|
1668
|
+
].includes(a.modelValue[m]) ? null : a.modelValue[m].constructor()), w.push("display: none;")), x[m] = me.satisfied;
|
|
1662
1669
|
}
|
|
1663
|
-
const V =
|
|
1664
|
-
return
|
|
1670
|
+
const V = S.value.md && (J == null ? void 0 : J.span) || 6;
|
|
1671
|
+
return w.push(`
|
|
1665
1672
|
--field-span: ${V};
|
|
1666
1673
|
grid-column: span var(--field-span) / span var(--field-span);
|
|
1667
|
-
`),
|
|
1668
|
-
--vertical-spacing: ${
|
|
1674
|
+
`), J && (J.verticalSpacing && w.push(`
|
|
1675
|
+
--vertical-spacing: ${J.verticalSpacing};
|
|
1669
1676
|
padding: var(--vertical-spacing) 0;
|
|
1670
|
-
`),
|
|
1677
|
+
`), J.separator && w.push(`
|
|
1671
1678
|
border-top: 1px solid var(--theme-border-color);
|
|
1672
1679
|
border-width: 1px 0 1px 0;
|
|
1673
1680
|
padding: 1rem 0;
|
|
1674
1681
|
margin: 1rem 0;
|
|
1675
|
-
`)),
|
|
1676
|
-
},
|
|
1682
|
+
`)), w.join("");
|
|
1683
|
+
}, R = (m) => m === null || m instanceof Object && !Object.keys(m).length, te = D(() => a.required ? a.required : a.property && "required" in a.property ? a.property.required : p == null ? void 0 : p.description.required), ae = D(() => a.form ? zt(
|
|
1677
1684
|
a.modelValue,
|
|
1678
1685
|
a.form,
|
|
1679
1686
|
te.value,
|
|
1680
1687
|
p == null ? void 0 : p.description
|
|
1681
|
-
) : !0),
|
|
1682
|
-
var
|
|
1683
|
-
return (
|
|
1688
|
+
) : !0), oe = (m, I) => {
|
|
1689
|
+
var w;
|
|
1690
|
+
return (w = f.value) != null && w[m] && (typeof f.value[m].index != "number" || f.value[m].index === I) ? f.value[m].errors : null;
|
|
1684
1691
|
};
|
|
1685
1692
|
return (m, I) => {
|
|
1686
|
-
const
|
|
1693
|
+
const w = ne("clickable"), J = ne("focus");
|
|
1687
1694
|
return o(), s("form", {
|
|
1688
1695
|
class: "form",
|
|
1689
|
-
style: $e(`row-gap: ${e(
|
|
1696
|
+
style: $e(`row-gap: ${e(L) ? ".8rem" : "var(--form-internal-gap, 1.6rem);"};`)
|
|
1690
1697
|
}, [
|
|
1691
|
-
m.$slots.header && !e(
|
|
1698
|
+
m.$slots.header && !e(L) ? (o(), s("header", Uo, [
|
|
1692
1699
|
C(m.$slots, "header", {}, void 0, !0)
|
|
1693
1700
|
])) : y("", !0),
|
|
1694
1701
|
C(m.$slots, "default", {}, void 0, !0),
|
|
1695
1702
|
m.isReadOnly ? y("", !0) : (o(), s("fieldset", Eo, [
|
|
1696
|
-
(o(!0), s(
|
|
1697
|
-
var B,
|
|
1703
|
+
(o(!0), s(Z, null, E(e(K), ([V, j]) => {
|
|
1704
|
+
var B, le, _e, me, Ke, Xe, Ye, Je, Ze, Pe, Ne, xe, et;
|
|
1698
1705
|
return o(), s("div", {
|
|
1699
1706
|
key: `field-${V}`,
|
|
1700
1707
|
style: $e(k(V, j)),
|
|
@@ -1707,7 +1714,7 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1707
1714
|
"form__field-label--section": "items" in j ? "properties" in j.items : "properties" in j,
|
|
1708
1715
|
"form__field-required-hint": m.highlightRequired && !m.searchOnly && (!te.value || e(Qt)(V, te.value, m.modelValue))
|
|
1709
1716
|
})
|
|
1710
|
-
}, b(j.description || e(
|
|
1717
|
+
}, b(j.description || e(q)(V)), 3),
|
|
1711
1718
|
j.hint ? (o(), s("div", {
|
|
1712
1719
|
key: 0,
|
|
1713
1720
|
innerHTML: j.hint
|
|
@@ -1720,7 +1727,7 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1720
1727
|
propery: j,
|
|
1721
1728
|
properyName: V,
|
|
1722
1729
|
modelValue: m.modelValue
|
|
1723
|
-
}), void 0, !0) : (_e = (
|
|
1730
|
+
}), void 0, !0) : (_e = (le = (B = m.layout) == null ? void 0 : B.fields) == null ? void 0 : le[V]) != null && _e.component && e(A)[m.layout.fields[V].component.name] ? (o(), $(he(e(A)[m.layout.fields[V].component.name]), H({
|
|
1724
1731
|
key: 2,
|
|
1725
1732
|
modelValue: m.modelValue[V],
|
|
1726
1733
|
"onUpdate:modelValue": (ee) => m.modelValue[V] = ee,
|
|
@@ -1767,30 +1774,30 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1767
1774
|
}
|
|
1768
1775
|
}), {
|
|
1769
1776
|
default: v(() => [
|
|
1770
|
-
g("option", Wo, b(e(
|
|
1771
|
-
g("option", Ko, b(e(
|
|
1777
|
+
g("option", Wo, b(e(q)("yes")), 1),
|
|
1778
|
+
g("option", Ko, b(e(q)("no")), 1)
|
|
1772
1779
|
]),
|
|
1773
1780
|
_: 2
|
|
1774
1781
|
}, 1040, ["model-value", "onUpdate:modelValue"])
|
|
1775
1782
|
])) : m.modelValue && "items" in j && !j.uniqueItems && (!("$ref" in j.items) || j.items.inline || j.items.$ref === "file") ? (o(), s("div", Xo, [
|
|
1776
1783
|
g("div", null, [
|
|
1777
|
-
z(
|
|
1784
|
+
z(re, {
|
|
1778
1785
|
small: "",
|
|
1779
1786
|
variant: "alt",
|
|
1780
1787
|
icon: "plus",
|
|
1781
|
-
disabled: !("inline" in j.items && j.items.inline) && (((me = m.modelValue[V]) == null ? void 0 : me.length) >= j.maxItems ||
|
|
1788
|
+
disabled: !("inline" in j.items && j.items.inline) && (((me = m.modelValue[V]) == null ? void 0 : me.length) >= j.maxItems || R((Xe = m.modelValue[V]) == null ? void 0 : Xe[((Ke = m.modelValue[V]) == null ? void 0 : Ke.length) - 1])),
|
|
1782
1789
|
onClick: ze((ee) => {
|
|
1783
1790
|
m.modelValue[V] || (m.modelValue[V] = []), e(Fo)(m.modelValue[V], j, e(t));
|
|
1784
1791
|
}, ["prevent"])
|
|
1785
1792
|
}, {
|
|
1786
1793
|
default: v(() => [
|
|
1787
|
-
Q(b(e(
|
|
1794
|
+
Q(b(e(q)("action.add", { capitalize: !0 })), 1)
|
|
1788
1795
|
]),
|
|
1789
1796
|
_: 2
|
|
1790
1797
|
}, 1032, ["disabled", "onClick"])
|
|
1791
1798
|
]),
|
|
1792
1799
|
g("div", Yo, [
|
|
1793
|
-
(o(!0), s(
|
|
1800
|
+
(o(!0), s(Z, null, E(m.modelValue[V], (ee, Oe) => {
|
|
1794
1801
|
var tt, nt, ot, at, lt, st;
|
|
1795
1802
|
return o(), s("div", {
|
|
1796
1803
|
key: `rep-${V}-${e(Mt)(ee, Oe)}`,
|
|
@@ -1807,7 +1814,7 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1807
1814
|
parentCollection: e(u),
|
|
1808
1815
|
parentPropertyName: m.parentPropertyName,
|
|
1809
1816
|
columns: ((ot = (nt = (tt = m.layout) == null ? void 0 : tt.fields) == null ? void 0 : nt[V]) == null ? void 0 : ot.optionsColumns) || ((st = (lt = (at = m.layout) == null ? void 0 : at.fields) == null ? void 0 : lt.$default) == null ? void 0 : st.optionsColumns),
|
|
1810
|
-
validationErrors:
|
|
1817
|
+
validationErrors: oe(V, Oe),
|
|
1811
1818
|
...j.componentProps || {}
|
|
1812
1819
|
}, {
|
|
1813
1820
|
onInput: (we) => l("input", V),
|
|
@@ -1817,9 +1824,9 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1817
1824
|
N(z(P, {
|
|
1818
1825
|
reactive: "",
|
|
1819
1826
|
icon: "trash",
|
|
1820
|
-
onClick: (we) => e(
|
|
1827
|
+
onClick: (we) => e(qo)(m.modelValue[V], Oe)
|
|
1821
1828
|
}, null, 8, ["onClick"]), [
|
|
1822
|
-
[
|
|
1829
|
+
[w]
|
|
1823
1830
|
])
|
|
1824
1831
|
]);
|
|
1825
1832
|
}), 128))
|
|
@@ -1836,16 +1843,16 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1836
1843
|
parentCollection: e(u),
|
|
1837
1844
|
columns: ((Ze = (Je = (Ye = m.layout) == null ? void 0 : Ye.fields) == null ? void 0 : Je[V]) == null ? void 0 : Ze.optionsColumns) || ((xe = (Ne = (Pe = m.layout) == null ? void 0 : Pe.fields) == null ? void 0 : Ne.$default) == null ? void 0 : xe.optionsColumns),
|
|
1838
1845
|
...j.componentProps || {},
|
|
1839
|
-
validationErrors:
|
|
1846
|
+
validationErrors: oe(V)
|
|
1840
1847
|
}, {
|
|
1841
1848
|
onInput: (ee) => l("input", V),
|
|
1842
1849
|
onChange: I[4] || (I[4] = (ee) => l("change", ee))
|
|
1843
1850
|
}), null, 16, ["modelValue", "onUpdate:modelValue", "onInput"])), [
|
|
1844
|
-
[
|
|
1851
|
+
[J, !d.value && (d.value = !!m.focus)]
|
|
1845
1852
|
]) : y("", !0),
|
|
1846
1853
|
(et = f.value) != null && et[V] ? (o(), s("div", Zo, [
|
|
1847
|
-
f.value[V].type ? (o(), s("span", Po, b(e(
|
|
1848
|
-
f.value[V].detail ? (o(), s("span", No, b(e(
|
|
1854
|
+
f.value[V].type ? (o(), s("span", Po, b(e(q)(`validation_error.${f.value[V].type}`)), 1)) : y("", !0),
|
|
1855
|
+
f.value[V].detail ? (o(), s("span", No, b(e(q)(f.value[V].detail)), 1)) : y("", !0)
|
|
1849
1856
|
])) : y("", !0)
|
|
1850
1857
|
], 4);
|
|
1851
1858
|
}), 128))
|
|
@@ -1853,18 +1860,18 @@ const Mo = /* @__PURE__ */ W(zo, [["__scopeId", "data-v-d1967e9e"]]), rt = (c, i
|
|
|
1853
1860
|
m.$slots.after ? C(m.$slots, "after", { key: 2 }, void 0, !0) : y("", !0),
|
|
1854
1861
|
m.$slots.footer ? (o(), s("div", xo, [
|
|
1855
1862
|
C(m.$slots, "footer", ce(Ve({
|
|
1856
|
-
isInsertReady:
|
|
1863
|
+
isInsertReady: ae.value
|
|
1857
1864
|
})), void 0, !0)
|
|
1858
1865
|
])) : y("", !0)
|
|
1859
1866
|
], 4);
|
|
1860
1867
|
};
|
|
1861
1868
|
}
|
|
1862
1869
|
});
|
|
1863
|
-
const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @__PURE__ */
|
|
1870
|
+
const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @__PURE__ */ U({
|
|
1864
1871
|
__name: "aeria-filter-panel",
|
|
1865
1872
|
emits: ["update:modelValue"],
|
|
1866
1873
|
setup(c, { emit: i }) {
|
|
1867
|
-
const t = i, a = ge(), l =
|
|
1874
|
+
const t = i, a = ge(), l = Re(), r = () => {
|
|
1868
1875
|
a.pagination.offset = 0, a.$actions.filter(), t("update:modelValue", !1), l.push({
|
|
1869
1876
|
query: Ft(a)
|
|
1870
1877
|
});
|
|
@@ -1877,7 +1884,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
1877
1884
|
onOverlayClick: p[3] || (p[3] = (d) => t("update:modelValue", !1))
|
|
1878
1885
|
}, {
|
|
1879
1886
|
footer: v(() => [
|
|
1880
|
-
e(a).filtersCount > 0 ? (o(), $(
|
|
1887
|
+
e(a).filtersCount > 0 ? (o(), $(re, {
|
|
1881
1888
|
key: 0,
|
|
1882
1889
|
variant: "transparent",
|
|
1883
1890
|
onClick: p[1] || (p[1] = (d) => {
|
|
@@ -1895,7 +1902,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
1895
1902
|
]),
|
|
1896
1903
|
_: 1
|
|
1897
1904
|
})) : y("", !0),
|
|
1898
|
-
z(
|
|
1905
|
+
z(re, {
|
|
1899
1906
|
large: "",
|
|
1900
1907
|
icon: "funnel",
|
|
1901
1908
|
disabled: !e(a).hasActiveFilters,
|
|
@@ -1920,10 +1927,10 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
1920
1927
|
_: 1
|
|
1921
1928
|
}, 8, ["title"]));
|
|
1922
1929
|
}
|
|
1923
|
-
}), se = X(!1), ut = X(!1), ke = X(!1), Se = X((...c) => null), ct = X(), dt = !1, na = /* @__PURE__ */
|
|
1930
|
+
}), se = X(!1), ut = X(!1), ke = X(!1), Se = X((...c) => null), ct = X(), dt = !1, na = /* @__PURE__ */ U({
|
|
1924
1931
|
__name: "aeria-insert-panel",
|
|
1925
1932
|
setup(c) {
|
|
1926
|
-
const i =
|
|
1933
|
+
const i = ie("meta"), t = ie(i.view.collection), a = ve("individualActions", []), l = async () => {
|
|
1927
1934
|
const { error: p } = await t.$actions.deepInsert();
|
|
1928
1935
|
p || (se.value = !1);
|
|
1929
1936
|
}, { t: r } = jt(), u = () => {
|
|
@@ -1979,7 +1986,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
1979
1986
|
}, 16)
|
|
1980
1987
|
]),
|
|
1981
1988
|
footer: v(() => [
|
|
1982
|
-
z(
|
|
1989
|
+
z(re, {
|
|
1983
1990
|
variant: "transparent",
|
|
1984
1991
|
onClick: u
|
|
1985
1992
|
}, {
|
|
@@ -1988,7 +1995,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
1988
1995
|
]),
|
|
1989
1996
|
_: 1
|
|
1990
1997
|
}),
|
|
1991
|
-
z(
|
|
1998
|
+
z(re, {
|
|
1992
1999
|
large: "",
|
|
1993
2000
|
disabled: !e(t).isInsertReady || dt || e(t).loading.get,
|
|
1994
2001
|
loading: e(t).loading.insert,
|
|
@@ -2036,7 +2043,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2036
2043
|
}, oa = (c, i = {
|
|
2037
2044
|
persistInQuery: !0
|
|
2038
2045
|
}) => {
|
|
2039
|
-
const a =
|
|
2046
|
+
const a = Re().currentRoute;
|
|
2040
2047
|
return ue(() => a.value.query.section, (l) => {
|
|
2041
2048
|
if (c) {
|
|
2042
2049
|
if (c.description.filtersPresets) {
|
|
@@ -2054,7 +2061,7 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2054
2061
|
}, {
|
|
2055
2062
|
immediate: !0
|
|
2056
2063
|
});
|
|
2057
|
-
}, aa = (c) => (Fe("data-v-7f75c4c2"), c = c(),
|
|
2064
|
+
}, aa = (c) => (Fe("data-v-7f75c4c2"), c = c(), qe(), c), la = {
|
|
2058
2065
|
key: 0,
|
|
2059
2066
|
class: "table aeria-surface"
|
|
2060
2067
|
}, sa = { key: 0 }, ia = { key: 1 }, ra = { key: 0 }, ua = ["checked"], ca = {
|
|
@@ -2072,11 +2079,11 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2072
2079
|
}, Sa = { class: "table__cell-actions" }, Ba = {
|
|
2073
2080
|
key: 2,
|
|
2074
2081
|
class: "no-print table__mobile-actions"
|
|
2075
|
-
}, ja = ["id"], Ta = { key: 1 },
|
|
2082
|
+
}, ja = ["id"], Ta = { key: 1 }, Ra = /* @__PURE__ */ aa(() => /* @__PURE__ */ g("td", { colspan: 10 }, [
|
|
2076
2083
|
/* @__PURE__ */ g("div", { class: "table__empty" }, " Não foram encontrados resultados. ")
|
|
2077
|
-
], -1)),
|
|
2078
|
-
|
|
2079
|
-
], za = /* @__PURE__ */
|
|
2084
|
+
], -1)), La = [
|
|
2085
|
+
Ra
|
|
2086
|
+
], za = /* @__PURE__ */ U({
|
|
2080
2087
|
__name: "aeria-table",
|
|
2081
2088
|
props: {
|
|
2082
2089
|
columns: {},
|
|
@@ -2088,36 +2095,36 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2088
2095
|
},
|
|
2089
2096
|
emits: ["itemClick"],
|
|
2090
2097
|
setup(c, { emit: i }) {
|
|
2091
|
-
const t = c, a = i, l = je(), r = t.collection || Te(), u = r ?
|
|
2098
|
+
const t = c, a = i, l = je(), r = t.collection || Te(), u = r ? ie(typeof r == "string" ? r : r.value) : null, p = D({
|
|
2092
2099
|
get: () => u == null ? void 0 : u.selected,
|
|
2093
2100
|
set: (f) => u == null ? void 0 : u.$actions.selectManyItems(f, !0)
|
|
2094
2101
|
}), d = (f, T) => f != null && f.button ? typeof f.button == "object" ? Qe(T, f.button).satisfied : f.button : !1, h = (f) => {
|
|
2095
2102
|
var T;
|
|
2096
2103
|
return !l.value.xl || !((T = t.layout) != null && T.actions) || !t.actions ? [] : t.actions.filter((A) => {
|
|
2097
|
-
const
|
|
2098
|
-
return d(
|
|
2104
|
+
const L = t.layout.actions[A.action];
|
|
2105
|
+
return d(L, f);
|
|
2099
2106
|
});
|
|
2100
2107
|
}, _ = (f) => {
|
|
2101
2108
|
var T;
|
|
2102
2109
|
return t.actions ? !l.value.xl || !((T = t.layout) != null && T.actions) ? t.actions : t.actions.filter((A) => {
|
|
2103
|
-
const
|
|
2110
|
+
const L = t.layout.actions[A.action];
|
|
2104
2111
|
if (A.roles) {
|
|
2105
|
-
const F =
|
|
2112
|
+
const F = ie("user");
|
|
2106
2113
|
if (!$t(A.roles, F.currentUser.roles))
|
|
2107
2114
|
return !1;
|
|
2108
2115
|
}
|
|
2109
|
-
return !d(
|
|
2116
|
+
return !d(L, f);
|
|
2110
2117
|
}) : [];
|
|
2111
2118
|
}, n = (f, T) => {
|
|
2112
2119
|
var F, Y;
|
|
2113
|
-
const A = [],
|
|
2114
|
-
return
|
|
2120
|
+
const A = [], L = (Y = (F = t.layout) == null ? void 0 : F.actions) == null ? void 0 : Y[T.action];
|
|
2121
|
+
return L != null && L.if && (Qe(
|
|
2115
2122
|
f,
|
|
2116
|
-
|
|
2123
|
+
L.if
|
|
2117
2124
|
).satisfied || A.push("display: none;")), A.join("");
|
|
2118
2125
|
};
|
|
2119
2126
|
return (f, T) => {
|
|
2120
|
-
var
|
|
2127
|
+
var L, F, Y;
|
|
2121
2128
|
const A = ne("clickable");
|
|
2122
2129
|
return f.columns && Object.keys(f.columns).length > 0 || f.$slots.thead ? (o(), s("table", la, [
|
|
2123
2130
|
f.$slots.thead ? (o(), s("thead", sa, [
|
|
@@ -2131,54 +2138,54 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2131
2138
|
onChange: T[0] || (T[0] = (O) => e(u).$actions.selectAllItems(O.target.checked))
|
|
2132
2139
|
}, null, 40, ua)
|
|
2133
2140
|
])) : y("", !0),
|
|
2134
|
-
(o(!0), s(
|
|
2141
|
+
(o(!0), s(Z, null, E(Object.entries(f.columns), ([O, M], K) => (o(), s("th", {
|
|
2135
2142
|
key: `header-${K}`,
|
|
2136
2143
|
class: "table__header"
|
|
2137
|
-
}, b(M.description || e(
|
|
2138
|
-
(
|
|
2144
|
+
}, b(M.description || e(q)(O)), 1))), 128)),
|
|
2145
|
+
(L = f.actions) != null && L.length ? (o(), s("th", ca)) : y("", !0)
|
|
2139
2146
|
])
|
|
2140
2147
|
])),
|
|
2141
2148
|
f.$slots.tbody ? (o(), s("tbody", da, [
|
|
2142
2149
|
C(f.$slots, "tbody", {}, void 0, !0)
|
|
2143
2150
|
])) : (o(), s("tbody", pa, [
|
|
2144
|
-
(o(!0), s(
|
|
2151
|
+
(o(!0), s(Z, null, E(f.rows, (O) => {
|
|
2145
2152
|
var M, K;
|
|
2146
2153
|
return o(), s("tr", {
|
|
2147
2154
|
key: O._id,
|
|
2148
|
-
onClick: (
|
|
2155
|
+
onClick: (S) => a("itemClick", O)
|
|
2149
2156
|
}, [
|
|
2150
2157
|
e(u) && f.checkbox && e(l).md ? (o(), s("td", ma, [
|
|
2151
2158
|
N(g("input", {
|
|
2152
|
-
"onUpdate:modelValue": T[1] || (T[1] = (
|
|
2159
|
+
"onUpdate:modelValue": T[1] || (T[1] = (S) => p.value = S),
|
|
2153
2160
|
type: "checkbox",
|
|
2154
2161
|
value: O._id
|
|
2155
2162
|
}, null, 8, fa), [
|
|
2156
2163
|
[It, p.value]
|
|
2157
2164
|
])
|
|
2158
2165
|
])) : y("", !0),
|
|
2159
|
-
(o(!0), s(
|
|
2160
|
-
var
|
|
2166
|
+
(o(!0), s(Z, null, E(Object.entries(f.columns), ([S, x], k) => {
|
|
2167
|
+
var R, te, ae, oe, m, I;
|
|
2161
2168
|
return o(), s("td", {
|
|
2162
2169
|
key: `column-${O._id}-${k}`
|
|
2163
2170
|
}, [
|
|
2164
|
-
g("div", va, b(x.description || e(
|
|
2165
|
-
`row-${
|
|
2166
|
-
C(f.$slots, `row-${
|
|
2171
|
+
g("div", va, b(x.description || e(q)(S)), 1),
|
|
2172
|
+
`row-${S}` in f.$slots ? (o(), s("div", ya, [
|
|
2173
|
+
C(f.$slots, `row-${S}`, H({ ref_for: !0 }, {
|
|
2167
2174
|
store: e(u),
|
|
2168
|
-
column:
|
|
2175
|
+
column: S,
|
|
2169
2176
|
property: x,
|
|
2170
2177
|
row: O
|
|
2171
2178
|
}), void 0, !0)
|
|
2172
2179
|
])) : (o(), s("div", ha, [
|
|
2173
2180
|
g("div", $a, [
|
|
2174
2181
|
"type" in x && x.type === "boolean" ? (o(), s("div", ba, [
|
|
2175
|
-
O[
|
|
2182
|
+
O[S] ? (o(), $(P, {
|
|
2176
2183
|
key: 0,
|
|
2177
2184
|
icon: "check",
|
|
2178
2185
|
"icon-classes": "aeria-blueish"
|
|
2179
2186
|
}, {
|
|
2180
2187
|
default: v(() => [
|
|
2181
|
-
Q(b(e(
|
|
2188
|
+
Q(b(e(q)("yes")), 1)
|
|
2182
2189
|
]),
|
|
2183
2190
|
_: 1
|
|
2184
2191
|
})) : (o(), $(P, {
|
|
@@ -2187,47 +2194,47 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2187
2194
|
"icon-classes": "aeria-redish"
|
|
2188
2195
|
}, {
|
|
2189
2196
|
default: v(() => [
|
|
2190
|
-
Q(b(e(
|
|
2197
|
+
Q(b(e(q)("no")), 1)
|
|
2191
2198
|
]),
|
|
2192
2199
|
_: 1
|
|
2193
2200
|
}))
|
|
2194
|
-
])) : ((
|
|
2195
|
-
/^image/.test((te = O[
|
|
2201
|
+
])) : ((R = e(pe)(x)) == null ? void 0 : R.$ref) === "file" ? (o(), s("div", ga, [
|
|
2202
|
+
/^image/.test((te = O[S][0]) == null ? void 0 : te.type) && "items" in x ? (o(), $(Me, {
|
|
2196
2203
|
key: 0,
|
|
2197
|
-
modelValue: O[
|
|
2198
|
-
"onUpdate:modelValue": (
|
|
2204
|
+
modelValue: O[S][0].link,
|
|
2205
|
+
"onUpdate:modelValue": (w) => O[S][0].link = w,
|
|
2199
2206
|
expandable: "",
|
|
2200
|
-
meta: O[
|
|
2207
|
+
meta: O[S][0],
|
|
2201
2208
|
alt: "Row image",
|
|
2202
2209
|
class: "table__picture"
|
|
2203
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : /^image/.test((
|
|
2210
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : /^image/.test((ae = O[S]) == null ? void 0 : ae.type) ? (o(), $(Me, {
|
|
2204
2211
|
key: 1,
|
|
2205
|
-
modelValue: O[
|
|
2206
|
-
"onUpdate:modelValue": (
|
|
2212
|
+
modelValue: O[S].link,
|
|
2213
|
+
"onUpdate:modelValue": (w) => O[S].link = w,
|
|
2207
2214
|
expandable: "",
|
|
2208
|
-
meta: O[
|
|
2215
|
+
meta: O[S],
|
|
2209
2216
|
alt: "Row image",
|
|
2210
2217
|
class: "table__picture"
|
|
2211
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : (
|
|
2218
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : (oe = O[S]) != null && oe.link ? (o(), s("a", {
|
|
2212
2219
|
key: 2,
|
|
2213
|
-
href: O[
|
|
2220
|
+
href: O[S].link,
|
|
2214
2221
|
style: { "font-size": "10pt" }
|
|
2215
|
-
}, b(O[
|
|
2222
|
+
}, b(O[S].filename), 9, ka)) : (o(), s("div", Va, " - "))
|
|
2216
2223
|
])) : (o(), s("div", Ca, [
|
|
2217
2224
|
e(u) ? (o(), s("span", Ia, b(e(u).$actions.formatValue({
|
|
2218
|
-
value: O[
|
|
2219
|
-
key:
|
|
2225
|
+
value: O[S],
|
|
2226
|
+
key: S,
|
|
2220
2227
|
property: x
|
|
2221
|
-
})), 1)) : (o(), s("span", Aa, b(Array.isArray(O[
|
|
2228
|
+
})), 1)) : (o(), s("span", Aa, b(Array.isArray(O[S]) ? O[S].filter((w) => !!w).join(", ") : [void 0, null].includes(O[S]) ? "-" : O[S]), 1)),
|
|
2222
2229
|
((I = (m = e(pe)(x)) == null ? void 0 : m.indexes) == null ? void 0 : I.length) > 1 ? (o(), s("div", Oa, [
|
|
2223
|
-
(o(!0), s(
|
|
2224
|
-
key: `subvalue-${
|
|
2230
|
+
(o(!0), s(Z, null, E(e(pe)(x).indexes.slice(1, 2), (w, J) => (o(), s("div", {
|
|
2231
|
+
key: `subvalue-${J}`,
|
|
2225
2232
|
class: "table__cell-subvalue"
|
|
2226
2233
|
}, b(e(u).$actions.formatValue({
|
|
2227
|
-
value: O[
|
|
2228
|
-
key:
|
|
2234
|
+
value: O[S],
|
|
2235
|
+
key: S,
|
|
2229
2236
|
property: x,
|
|
2230
|
-
index:
|
|
2237
|
+
index: w
|
|
2231
2238
|
})), 1))), 128))
|
|
2232
2239
|
])) : y("", !0)
|
|
2233
2240
|
]))
|
|
@@ -2237,16 +2244,16 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2237
2244
|
}), 128)),
|
|
2238
2245
|
(M = f.actions) != null && M.length && e(l).md ? (o(), s("td", wa, [
|
|
2239
2246
|
g("div", Sa, [
|
|
2240
|
-
(o(!0), s(
|
|
2241
|
-
key: `action-${
|
|
2247
|
+
(o(!0), s(Z, null, E(h(O), (S) => (o(), $(re, {
|
|
2248
|
+
key: `action-${S.action}`,
|
|
2242
2249
|
small: "",
|
|
2243
2250
|
variant: "transparent",
|
|
2244
|
-
icon:
|
|
2245
|
-
style: $e(n(O,
|
|
2246
|
-
onClick: (x) =>
|
|
2251
|
+
icon: S.icon,
|
|
2252
|
+
style: $e(n(O, S)),
|
|
2253
|
+
onClick: (x) => S.click(O)
|
|
2247
2254
|
}, {
|
|
2248
2255
|
default: v(() => [
|
|
2249
|
-
Q(b(e(
|
|
2256
|
+
Q(b(e(q)(S.label)), 1)
|
|
2250
2257
|
]),
|
|
2251
2258
|
_: 2
|
|
2252
2259
|
}, 1032, ["icon", "style", "onClick"]))), 128)),
|
|
@@ -2273,17 +2280,17 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2273
2280
|
class: "table__mobile-actions-grid",
|
|
2274
2281
|
style: $e(`grid-template-columns: repeat(${h(O).length + (_(O).length ? 1 : 0)}, 1fr);`)
|
|
2275
2282
|
}, [
|
|
2276
|
-
(o(!0), s(
|
|
2277
|
-
key: `action-${
|
|
2283
|
+
(o(!0), s(Z, null, E(h(O), (S) => (o(), $(fe, {
|
|
2284
|
+
key: `action-${S.action}`,
|
|
2278
2285
|
class: "table__mobile-actions-button",
|
|
2279
|
-
onClick: (x) =>
|
|
2286
|
+
onClick: (x) => S.click(O)
|
|
2280
2287
|
}, {
|
|
2281
2288
|
default: v(() => [
|
|
2282
2289
|
z(P, {
|
|
2283
|
-
icon:
|
|
2290
|
+
icon: S.icon || "gear"
|
|
2284
2291
|
}, {
|
|
2285
2292
|
default: v(() => [
|
|
2286
|
-
Q(b(e(
|
|
2293
|
+
Q(b(e(q)(S.label)), 1)
|
|
2287
2294
|
]),
|
|
2288
2295
|
_: 2
|
|
2289
2296
|
}, 1032, ["icon"])
|
|
@@ -2314,13 +2321,13 @@ const He = /* @__PURE__ */ W(ea, [["__scopeId", "data-v-d0149f78"]]), ta = /* @_
|
|
|
2314
2321
|
}), 128))
|
|
2315
2322
|
])),
|
|
2316
2323
|
g("tfoot", null, [
|
|
2317
|
-
f.$slots.tfoot ? C(f.$slots, "tfoot", { key: 0 }, void 0, !0) : f.columns && !((F = f.rows) != null && F.length) && !((Y = e(u)) != null && Y.loading.getAll) ? (o(), s("tr", Ta,
|
|
2324
|
+
f.$slots.tfoot ? C(f.$slots, "tfoot", { key: 0 }, void 0, !0) : f.columns && !((F = f.rows) != null && F.length) && !((Y = e(u)) != null && Y.loading.getAll) ? (o(), s("tr", Ta, La)) : y("", !0)
|
|
2318
2325
|
])
|
|
2319
2326
|
])) : y("", !0);
|
|
2320
2327
|
};
|
|
2321
2328
|
}
|
|
2322
2329
|
});
|
|
2323
|
-
const Ma = /* @__PURE__ */ W(za, [["__scopeId", "data-v-7f75c4c2"]]), Fa = /* @__PURE__ */
|
|
2330
|
+
const Ma = /* @__PURE__ */ W(za, [["__scopeId", "data-v-7f75c4c2"]]), Fa = /* @__PURE__ */ U({
|
|
2324
2331
|
__name: "aeria-tabular",
|
|
2325
2332
|
props: {
|
|
2326
2333
|
individualActions: {},
|
|
@@ -2353,7 +2360,7 @@ const Ma = /* @__PURE__ */ W(za, [["__scopeId", "data-v-7f75c4c2"]]), Fa = /* @_
|
|
|
2353
2360
|
]), 1040)) : y("", !0)
|
|
2354
2361
|
]));
|
|
2355
2362
|
}
|
|
2356
|
-
}),
|
|
2363
|
+
}), qa = /* @__PURE__ */ U({
|
|
2357
2364
|
__name: "aeria-grid",
|
|
2358
2365
|
props: {
|
|
2359
2366
|
list: { type: Boolean }
|
|
@@ -2369,10 +2376,10 @@ const Ma = /* @__PURE__ */ W(za, [["__scopeId", "data-v-7f75c4c2"]]), Fa = /* @_
|
|
|
2369
2376
|
], 2));
|
|
2370
2377
|
}
|
|
2371
2378
|
});
|
|
2372
|
-
const
|
|
2379
|
+
const Ua = /* @__PURE__ */ W(qa, [["__scopeId", "data-v-438c4aed"]]), Ea = { key: 0 }, Ha = {
|
|
2373
2380
|
key: 1,
|
|
2374
2381
|
class: "card__information"
|
|
2375
|
-
}, Da = /* @__PURE__ */
|
|
2382
|
+
}, Da = /* @__PURE__ */ U({
|
|
2376
2383
|
__name: "aeria-grid",
|
|
2377
2384
|
props: {
|
|
2378
2385
|
individualActions: {},
|
|
@@ -2384,11 +2391,11 @@ const qa = /* @__PURE__ */ W(Ua, [["__scopeId", "data-v-438c4aed"]]), Ea = { key
|
|
|
2384
2391
|
const t = c.layoutOptions, a = ge(), l = (r) => Array.isArray(r) ? r[0] : r;
|
|
2385
2392
|
return (r, u) => {
|
|
2386
2393
|
const p = ne("clickable");
|
|
2387
|
-
return o(), $(
|
|
2394
|
+
return o(), $(Ua, {
|
|
2388
2395
|
list: r.componentName === "list"
|
|
2389
2396
|
}, {
|
|
2390
2397
|
default: v(() => [
|
|
2391
|
-
(o(!0), s(
|
|
2398
|
+
(o(!0), s(Z, null, E(e(a).items, (d) => (o(), $(pn, {
|
|
2392
2399
|
key: d,
|
|
2393
2400
|
inactive: !!(e(t).active && !d[e(t).active]),
|
|
2394
2401
|
horizontal: r.componentName === "list"
|
|
@@ -2432,12 +2439,12 @@ const qa = /* @__PURE__ */ W(Ua, [["__scopeId", "data-v-438c4aed"]]), Ea = { key
|
|
|
2432
2439
|
e(t).badge && Array.isArray(d[e(t).badge]) ? {
|
|
2433
2440
|
name: "badge",
|
|
2434
2441
|
fn: v(() => [
|
|
2435
|
-
(o(!0), s(
|
|
2442
|
+
(o(!0), s(Z, null, E(d[e(t).badge], (h) => (o(), $(be, {
|
|
2436
2443
|
key: `${d._id}-${h}`,
|
|
2437
2444
|
large: ""
|
|
2438
2445
|
}, {
|
|
2439
2446
|
default: v(() => [
|
|
2440
|
-
Q(b(e(t).translateBadge ? e(
|
|
2447
|
+
Q(b(e(t).translateBadge ? e(q)(h) : h), 1)
|
|
2441
2448
|
]),
|
|
2442
2449
|
_: 2
|
|
2443
2450
|
}, 1024))), 128))
|
|
@@ -2448,7 +2455,7 @@ const qa = /* @__PURE__ */ W(Ua, [["__scopeId", "data-v-438c4aed"]]), Ea = { key
|
|
|
2448
2455
|
fn: v(() => [
|
|
2449
2456
|
z(be, null, {
|
|
2450
2457
|
default: v(() => [
|
|
2451
|
-
Q(b(e(t).translateBadge ? e(
|
|
2458
|
+
Q(b(e(t).translateBadge ? e(q)(d[e(t).badge]) : d[e(t).badge]), 1)
|
|
2452
2459
|
]),
|
|
2453
2460
|
_: 2
|
|
2454
2461
|
}, 1024)
|
|
@@ -2466,7 +2473,7 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2466
2473
|
tabular: Fa,
|
|
2467
2474
|
grid: pt,
|
|
2468
2475
|
list: pt
|
|
2469
|
-
})[c], Ga = (c) => (Fe("data-v-
|
|
2476
|
+
})[c], Ga = (c) => (Fe("data-v-a1f52292"), c = c(), qe(), c), Wa = {
|
|
2470
2477
|
key: 2,
|
|
2471
2478
|
class: "crud__controls"
|
|
2472
2479
|
}, Ka = {
|
|
@@ -2475,7 +2482,7 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2475
2482
|
}, Xa = { class: "crud__actions" }, Ya = { class: "crud__context-badge" }, Ja = /* @__PURE__ */ Ga(() => /* @__PURE__ */ g("div", null, "Filtros", -1)), Za = { key: 0 }, Pa = {
|
|
2476
2483
|
key: 3,
|
|
2477
2484
|
class: "crud__pagination"
|
|
2478
|
-
}, _t = 30, Na = /* @__PURE__ */
|
|
2485
|
+
}, _t = 30, Na = /* @__PURE__ */ U({
|
|
2479
2486
|
__name: "aeria-crud",
|
|
2480
2487
|
props: {
|
|
2481
2488
|
collection: {},
|
|
@@ -2491,31 +2498,34 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2491
2498
|
},
|
|
2492
2499
|
emits: ["uiEvent"],
|
|
2493
2500
|
setup(c, { emit: i }) {
|
|
2494
|
-
const t = c, a = i, l =
|
|
2501
|
+
const t = c, a = i, l = Re(), r = ht({
|
|
2495
2502
|
delay: 600
|
|
2496
|
-
}), u =
|
|
2503
|
+
}), u = ie("meta"), p = je(), { reachedEnd: d, detach: h } = We(null, {
|
|
2497
2504
|
antecipate: 600
|
|
2498
2505
|
}), _ = !p.value.md || t.scrollPagination;
|
|
2499
2506
|
_ && ue(d, (k) => {
|
|
2500
2507
|
k && n.pagination.recordsTotal > n.items.length && A.value < _t && (A.value += 1, F());
|
|
2501
2508
|
});
|
|
2502
|
-
const n =
|
|
2509
|
+
const n = ie(t.collection);
|
|
2503
2510
|
oa(n, {
|
|
2504
2511
|
persistInQuery: !t.noQueryPersistence
|
|
2505
2512
|
});
|
|
2506
|
-
const f = bt(), T = t.action ? e(t.action) :
|
|
2513
|
+
const f = bt(), T = t.action ? e(t.action) : qt(n, l, f);
|
|
2507
2514
|
Se.value = T[0], ct.value = T[1];
|
|
2508
|
-
const A = X(0),
|
|
2515
|
+
const A = X(0), L = X(!1), F = async (k) => {
|
|
2509
2516
|
n.activeFilters = Object.assign({}, (k == null ? void 0 : k.filters) || n.$filters), Object.assign(n.activeFilters, n.filtersPreset);
|
|
2510
|
-
const
|
|
2517
|
+
const R = {
|
|
2511
2518
|
filters: n.activeFilters,
|
|
2512
2519
|
limit: n.pagination.limit,
|
|
2513
2520
|
offset: n.pagination.offset,
|
|
2514
2521
|
project: n.preferredTableProperties.length > 0 ? n.preferredTableProperties : n.description.table || Object.keys(n.properties)
|
|
2515
2522
|
};
|
|
2516
|
-
A.value > 0 && (
|
|
2517
|
-
const {
|
|
2518
|
-
|
|
2523
|
+
A.value > 0 && (R.limit = 15, R.offset = A.value * R.limit), n.description.tableMeta && (R.project = R.project.concat(n.description.tableMeta)), k && Object.assign(R, k), n.loading.getAll = !0;
|
|
2524
|
+
const { error: te, result: ae } = await n.$actions.retrieveItems(R);
|
|
2525
|
+
if (te)
|
|
2526
|
+
return;
|
|
2527
|
+
const { data: oe, pagination: m } = ae;
|
|
2528
|
+
n.pagination.recordsCount = m.recordsCount, n.pagination.recordsTotal = m.recordsTotal, A.value === 0 && n.items.splice(0), n.items.push(...oe), n.loading.getAll = !1, L.value = !0;
|
|
2519
2529
|
}, Y = async (k) => {
|
|
2520
2530
|
l.push({
|
|
2521
2531
|
query: {
|
|
@@ -2528,13 +2538,13 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2528
2538
|
ue(() => [
|
|
2529
2539
|
l.currentRoute.value.path,
|
|
2530
2540
|
l.currentRoute.value.query.section
|
|
2531
|
-
], async (k,
|
|
2532
|
-
if (
|
|
2541
|
+
], async (k, R) => {
|
|
2542
|
+
if (R && R[0] === k[0] && R[1] === k[1])
|
|
2533
2543
|
return;
|
|
2534
2544
|
const te = l.currentRoute.value;
|
|
2535
2545
|
if (u.view.title = t.collection, u.view.collection = t.collection, ut.value = !1, !t.noFetch && !te.query._popstate) {
|
|
2536
|
-
const
|
|
2537
|
-
Object.keys(
|
|
2546
|
+
const ae = Ut(n, te);
|
|
2547
|
+
Object.keys(ae).length > 0 && Object.assign(n.filters, ae), await F();
|
|
2538
2548
|
}
|
|
2539
2549
|
}, {
|
|
2540
2550
|
immediate: !0,
|
|
@@ -2561,88 +2571,88 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2561
2571
|
At(() => {
|
|
2562
2572
|
n.$actions.clearFilters(), n.textQuery = "", h();
|
|
2563
2573
|
}), ue(() => ct.value, async (k) => {
|
|
2564
|
-
var
|
|
2565
|
-
const
|
|
2574
|
+
var ae;
|
|
2575
|
+
const R = Be(k);
|
|
2566
2576
|
let te;
|
|
2567
|
-
if (
|
|
2577
|
+
if (R)
|
|
2568
2578
|
if ([
|
|
2569
2579
|
"spawnEdit",
|
|
2570
2580
|
"spawnView",
|
|
2571
2581
|
"duplicate"
|
|
2572
|
-
].includes(
|
|
2582
|
+
].includes(R.name) && (te = n.$actions.get({
|
|
2573
2583
|
filters: {
|
|
2574
|
-
_id:
|
|
2584
|
+
_id: R.params._id
|
|
2575
2585
|
}
|
|
2576
|
-
})),
|
|
2577
|
-
n.$actions.clearItem(), (
|
|
2578
|
-
delete n.referenceItem[
|
|
2586
|
+
})), R.name === "spawnAdd")
|
|
2587
|
+
n.$actions.clearItem(), (ae = R.params) != null && ae.item && (n.$actions.setItem(R.params.item), Object.keys(R.params.item).forEach((oe) => {
|
|
2588
|
+
delete n.referenceItem[oe];
|
|
2579
2589
|
})), se.value = "add";
|
|
2580
|
-
else if (
|
|
2581
|
-
n.$actions.setItem(
|
|
2582
|
-
else if (
|
|
2590
|
+
else if (R.name === "spawnEdit")
|
|
2591
|
+
n.$actions.setItem(R.params), se.value = "edit";
|
|
2592
|
+
else if (R.name === "spawnView")
|
|
2583
2593
|
ut.value = !0, se.value = "view";
|
|
2584
|
-
else if (
|
|
2594
|
+
else if (R.name === "duplicate") {
|
|
2585
2595
|
await te;
|
|
2586
|
-
const
|
|
2596
|
+
const oe = Object.entries(n.item).reduce((m, [I, w]) => {
|
|
2587
2597
|
if (!(I in n.properties))
|
|
2588
2598
|
return {
|
|
2589
2599
|
...m,
|
|
2590
|
-
[I]:
|
|
2600
|
+
[I]: w
|
|
2591
2601
|
};
|
|
2592
|
-
const
|
|
2593
|
-
if (
|
|
2602
|
+
const J = n.properties[I];
|
|
2603
|
+
if (J.readOnly)
|
|
2594
2604
|
return m;
|
|
2595
2605
|
const V = (j) => {
|
|
2596
|
-
const B = pe(
|
|
2606
|
+
const B = pe(J);
|
|
2597
2607
|
if (!B)
|
|
2598
2608
|
return j;
|
|
2599
2609
|
if (B.$ref === "file")
|
|
2600
2610
|
return {};
|
|
2601
2611
|
if (B.inline && j) {
|
|
2602
|
-
const { _id:
|
|
2612
|
+
const { _id: le, ..._e } = j;
|
|
2603
2613
|
return _e;
|
|
2604
2614
|
}
|
|
2605
2615
|
return j;
|
|
2606
2616
|
};
|
|
2607
|
-
return
|
|
2617
|
+
return w = Array.isArray(w) ? w.map(V) : V(w), {
|
|
2608
2618
|
...m,
|
|
2609
|
-
[I]:
|
|
2619
|
+
[I]: w
|
|
2610
2620
|
};
|
|
2611
2621
|
}, {});
|
|
2612
|
-
n.$actions.setItem(
|
|
2622
|
+
n.$actions.setItem(oe), delete n.item._id, n.referenceItem = {}, se.value = "duplicate";
|
|
2613
2623
|
} else
|
|
2614
|
-
a("uiEvent",
|
|
2624
|
+
a("uiEvent", R);
|
|
2615
2625
|
}, {
|
|
2616
2626
|
deep: !0
|
|
2617
2627
|
}), ue(() => se, (k) => {
|
|
2618
2628
|
k.value === !1 && (u.view.collection = t.collection, n.$actions.clearItem());
|
|
2619
2629
|
});
|
|
2620
|
-
const
|
|
2630
|
+
const S = D(() => n.individualActions.map((k) => ({
|
|
2621
2631
|
click: Se.value(k),
|
|
2622
2632
|
...k
|
|
2623
2633
|
}))), x = D(() => n.actions.filter((k) => !k.button));
|
|
2624
|
-
return ye(
|
|
2625
|
-
var
|
|
2626
|
-
const te = ne("clickable"),
|
|
2627
|
-
return o(), s(
|
|
2634
|
+
return ye(Ue, D(() => t.collection)), ye("individualActions", S), (k, R) => {
|
|
2635
|
+
var oe, m, I, w, J, V, j;
|
|
2636
|
+
const te = ne("clickable"), ae = ne("loading");
|
|
2637
|
+
return o(), s(Z, null, [
|
|
2628
2638
|
e(ke) ? (o(), $(ta, {
|
|
2629
2639
|
key: e(n).$id,
|
|
2630
2640
|
modelValue: e(ke),
|
|
2631
|
-
"onUpdate:modelValue":
|
|
2641
|
+
"onUpdate:modelValue": R[0] || (R[0] = (B) => vt(ke) ? ke.value = B : null)
|
|
2632
2642
|
}, null, 8, ["modelValue"])) : y("", !0),
|
|
2633
2643
|
e(se) ? (o(), $(na, { key: 1 }, de({ _: 2 }, [
|
|
2634
2644
|
E(Object.keys(k.$slots).filter((B) => B.startsWith("field-")), (B) => ({
|
|
2635
2645
|
name: B,
|
|
2636
|
-
fn: v((
|
|
2637
|
-
C(k.$slots, B, ce(Ve(
|
|
2646
|
+
fn: v((le) => [
|
|
2647
|
+
C(k.$slots, B, ce(Ve(le)), void 0, !0)
|
|
2638
2648
|
])
|
|
2639
2649
|
}))
|
|
2640
2650
|
]), 1024)) : y("", !0),
|
|
2641
|
-
!k.noActions && (e(n).description.search || Object.keys(e(n).availableFilters).length > 0 || ((
|
|
2651
|
+
!k.noActions && (e(n).description.search || Object.keys(e(n).availableFilters).length > 0 || ((oe = e(n)) == null ? void 0 : oe.actions.length) > 0 || k.$slots.actions || !k.noLayoutToggle && e(n).description.layout && ((m = e(n).description.layout) == null ? void 0 : m.name) !== "tabular") ? (o(), s("div", Wa, [
|
|
2642
2652
|
e(n).description.search ? (o(), s("div", Ka, [
|
|
2643
2653
|
z(Ie, H({
|
|
2644
2654
|
modelValue: e(n).textQuery,
|
|
2645
|
-
"onUpdate:modelValue":
|
|
2655
|
+
"onUpdate:modelValue": R[1] || (R[1] = (B) => e(n).textQuery = B)
|
|
2646
2656
|
}, {
|
|
2647
2657
|
property: {
|
|
2648
2658
|
type: "string",
|
|
@@ -2654,7 +2664,7 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2654
2664
|
g("div", Xa, [
|
|
2655
2665
|
x.value.length > 0 || !k.noLayoutToggle && e(n).description.layout && ((I = e(n).description.layout) == null ? void 0 : I.name) !== "tabular" ? (o(), $(Ce, { key: 0 }, de({
|
|
2656
2666
|
default: v(() => [
|
|
2657
|
-
z(
|
|
2667
|
+
z(re, {
|
|
2658
2668
|
variant: "alt",
|
|
2659
2669
|
icon: "sliders"
|
|
2660
2670
|
}, {
|
|
@@ -2676,10 +2686,10 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2676
2686
|
fn: v(() => [
|
|
2677
2687
|
N((o(), $(P, {
|
|
2678
2688
|
icon: "funnel",
|
|
2679
|
-
onClick:
|
|
2689
|
+
onClick: R[2] || (R[2] = (B) => ke.value = !0)
|
|
2680
2690
|
}, {
|
|
2681
2691
|
default: v(() => [
|
|
2682
|
-
Q(b(e(
|
|
2692
|
+
Q(b(e(q)("filters", { capitalize: !0 })), 1)
|
|
2683
2693
|
]),
|
|
2684
2694
|
_: 1
|
|
2685
2695
|
})), [
|
|
@@ -2696,15 +2706,15 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2696
2706
|
]),
|
|
2697
2707
|
key: "0"
|
|
2698
2708
|
} : void 0,
|
|
2699
|
-
!k.noLayoutToggle && e(n).description.layout && ((
|
|
2709
|
+
!k.noLayoutToggle && e(n).description.layout && ((w = e(n).description.layout) == null ? void 0 : w.name) !== "tabular" ? {
|
|
2700
2710
|
name: "layout-toggle",
|
|
2701
2711
|
fn: v(() => [
|
|
2702
2712
|
N((o(), $(P, {
|
|
2703
2713
|
icon: "table",
|
|
2704
|
-
onClick:
|
|
2714
|
+
onClick: R[3] || (R[3] = (B) => K(e(n)))
|
|
2705
2715
|
}, {
|
|
2706
2716
|
default: v(() => [
|
|
2707
|
-
Q(b(e(
|
|
2717
|
+
Q(b(e(q)("change_layout", { capitalize: !0 })), 1)
|
|
2708
2718
|
]),
|
|
2709
2719
|
_: 1
|
|
2710
2720
|
})), [
|
|
@@ -2713,8 +2723,8 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2713
2723
|
]),
|
|
2714
2724
|
key: "1"
|
|
2715
2725
|
} : void 0,
|
|
2716
|
-
E(x.value, (B,
|
|
2717
|
-
name: `action-${
|
|
2726
|
+
E(x.value, (B, le) => ({
|
|
2727
|
+
name: `action-${le}`,
|
|
2718
2728
|
fn: v(() => [
|
|
2719
2729
|
B ? (o(), $(P, {
|
|
2720
2730
|
key: 0,
|
|
@@ -2723,17 +2733,17 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2723
2733
|
onClick: (_e) => e(Se)(B)({ _id: e(n).selected.map((me) => me._id) })
|
|
2724
2734
|
}, {
|
|
2725
2735
|
default: v(() => [
|
|
2726
|
-
Q(b(e(
|
|
2736
|
+
Q(b(e(q)(B.label, { capitalize: !0 })), 1)
|
|
2727
2737
|
]),
|
|
2728
2738
|
_: 2
|
|
2729
2739
|
}, 1032, ["icon", "disabled", "onClick"])) : y("", !0)
|
|
2730
2740
|
])
|
|
2731
2741
|
}))
|
|
2732
|
-
]), 1024)) : Object.keys(e(n).availableFilters).length > 0 ? (o(), $(
|
|
2742
|
+
]), 1024)) : Object.keys(e(n).availableFilters).length > 0 ? (o(), $(re, {
|
|
2733
2743
|
key: 1,
|
|
2734
2744
|
variant: "alt",
|
|
2735
2745
|
icon: "funnel",
|
|
2736
|
-
onClick:
|
|
2746
|
+
onClick: R[4] || (R[4] = (B) => ke.value = !0)
|
|
2737
2747
|
}, {
|
|
2738
2748
|
default: v(() => [
|
|
2739
2749
|
Ja,
|
|
@@ -2746,14 +2756,14 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2746
2756
|
]),
|
|
2747
2757
|
_: 1
|
|
2748
2758
|
})) : y("", !0),
|
|
2749
|
-
(o(!0), s(
|
|
2750
|
-
key: `action-${
|
|
2759
|
+
(o(!0), s(Z, null, E(e(n).actions.filter((B) => B.button), (B, le) => (o(), $(re, {
|
|
2760
|
+
key: `action-${le}`,
|
|
2751
2761
|
icon: B.icon,
|
|
2752
2762
|
disabled: e(n).selected.length === 0 && B.selection,
|
|
2753
2763
|
onClick: (_e) => e(Se)(B)({ _id: e(n).selected.map((me) => me._id) })
|
|
2754
2764
|
}, {
|
|
2755
2765
|
default: v(() => [
|
|
2756
|
-
Q(b(e(
|
|
2766
|
+
Q(b(e(q)(B.label, { capitalize: !0 })), 1)
|
|
2757
2767
|
]),
|
|
2758
2768
|
_: 2
|
|
2759
2769
|
}, 1032, ["icon", "disabled", "onClick"]))), 128)),
|
|
@@ -2761,20 +2771,20 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2761
2771
|
])
|
|
2762
2772
|
])) : y("", !0),
|
|
2763
2773
|
N((o(), s("div", null, [
|
|
2764
|
-
e(n).itemsCount === 0 && !e(n).loading.getAll &&
|
|
2774
|
+
e(n).itemsCount === 0 && !e(n).loading.getAll && L.value && (e(O) || k.$slots.empty) ? (o(), s("div", Za, [
|
|
2765
2775
|
e(O) ? (o(), $(he(e(O)), ce(H({ key: 0 }, {
|
|
2766
2776
|
collection: e(n).$id
|
|
2767
2777
|
})), {
|
|
2768
2778
|
default: v(() => [
|
|
2769
|
-
e(n).filtersCount === 0 && e(n).description.actions && "ui:spawnAdd" in e(n).description.actions ? (o(), $(
|
|
2779
|
+
e(n).filtersCount === 0 && e(n).description.actions && "ui:spawnAdd" in e(n).description.actions ? (o(), $(re, {
|
|
2770
2780
|
key: 0,
|
|
2771
2781
|
icon: "plus",
|
|
2772
|
-
onClick:
|
|
2782
|
+
onClick: R[5] || (R[5] = (B) => e(Se)({
|
|
2773
2783
|
action: "ui:spawnAdd"
|
|
2774
2784
|
})())
|
|
2775
2785
|
}, {
|
|
2776
2786
|
default: v(() => [
|
|
2777
|
-
Q(b(e(
|
|
2787
|
+
Q(b(e(q)("add_first_item", { capitalize: !0 })), 1)
|
|
2778
2788
|
]),
|
|
2779
2789
|
_: 1
|
|
2780
2790
|
})) : y("", !0)
|
|
@@ -2785,8 +2795,8 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2785
2795
|
})), void 0, !0)
|
|
2786
2796
|
])) : k.$slots.component ? C(k.$slots, "component", ce(H({ key: 1 }, {
|
|
2787
2797
|
store: e(n)
|
|
2788
|
-
})), void 0, !0) : (o(), $(he(e(Qa)(((
|
|
2789
|
-
individualActions:
|
|
2798
|
+
})), void 0, !0) : (o(), $(he(e(Qa)(((J = k.layout) == null ? void 0 : J.name) || e(n).$currentLayout)), H({ key: 2 }, {
|
|
2799
|
+
individualActions: S.value,
|
|
2790
2800
|
layoutOptions: ((V = k.layout) == null ? void 0 : V.options) || e(n).layout.options,
|
|
2791
2801
|
componentProps: k.componentProps
|
|
2792
2802
|
}, {
|
|
@@ -2794,8 +2804,8 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2794
2804
|
}), de({ _: 2 }, [
|
|
2795
2805
|
E(Object.keys(k.$slots).filter((B) => B.startsWith("row-")), (B) => ({
|
|
2796
2806
|
name: B,
|
|
2797
|
-
fn: v((
|
|
2798
|
-
C(k.$slots, B, ce(Ve(
|
|
2807
|
+
fn: v((le) => [
|
|
2808
|
+
C(k.$slots, B, ce(Ve(le)), void 0, !0)
|
|
2799
2809
|
])
|
|
2800
2810
|
})),
|
|
2801
2811
|
k.$slots.tfoot ? {
|
|
@@ -2807,7 +2817,7 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2807
2817
|
} : void 0
|
|
2808
2818
|
]), 1040, ["component-name"]))
|
|
2809
2819
|
])), [
|
|
2810
|
-
[
|
|
2820
|
+
[ae, (!e(_) || A.value === _t) && e(n).loading.getAll]
|
|
2811
2821
|
]),
|
|
2812
2822
|
!e(n).loading.getAll && e(n).itemsCount > 0 ? (o(), s("div", Pa, [
|
|
2813
2823
|
z(Mn, {
|
|
@@ -2819,14 +2829,14 @@ const pt = /* @__PURE__ */ W(Da, [["__scopeId", "data-v-113dd7db"]]), Qa = (c) =
|
|
|
2819
2829
|
};
|
|
2820
2830
|
}
|
|
2821
2831
|
});
|
|
2822
|
-
const
|
|
2832
|
+
const Ll = /* @__PURE__ */ W(Na, [["__scopeId", "data-v-a1f52292"]]), xa = { class: "prompt" }, el = /* @__PURE__ */ U({
|
|
2823
2833
|
__name: "aeria-prompt",
|
|
2824
2834
|
props: {
|
|
2825
2835
|
title: {},
|
|
2826
2836
|
actions: {}
|
|
2827
2837
|
},
|
|
2828
2838
|
setup(c) {
|
|
2829
|
-
const i =
|
|
2839
|
+
const i = ie("meta"), t = (a) => {
|
|
2830
2840
|
i.$actions.fulfillPrompt(a);
|
|
2831
2841
|
};
|
|
2832
2842
|
return (a, l) => (o(), $(Ae, {
|
|
@@ -2840,7 +2850,7 @@ const Rl = /* @__PURE__ */ W(Na, [["__scopeId", "data-v-2cbb3e9f"]]), xa = { cla
|
|
|
2840
2850
|
class: "prompt__actions",
|
|
2841
2851
|
style: $e(`grid-template-columns: repeat(${a.actions.length}, 1fr)`)
|
|
2842
2852
|
}, [
|
|
2843
|
-
(o(!0), s(
|
|
2853
|
+
(o(!0), s(Z, null, E(a.actions, (r, u) => (o(), $(fe, {
|
|
2844
2854
|
key: `action-${u}`,
|
|
2845
2855
|
class: G(`
|
|
2846
2856
|
prompt__action
|
|
@@ -2872,7 +2882,7 @@ const Rl = /* @__PURE__ */ W(Na, [["__scopeId", "data-v-2cbb3e9f"]]), xa = { cla
|
|
|
2872
2882
|
]), 1024));
|
|
2873
2883
|
}
|
|
2874
2884
|
});
|
|
2875
|
-
const tl = /* @__PURE__ */ W(el, [["__scopeId", "data-v-5443f297"]]), nl = { class: "toast__content" }, ol = { class: "toast__time" }, al = /* @__PURE__ */
|
|
2885
|
+
const tl = /* @__PURE__ */ W(el, [["__scopeId", "data-v-5443f297"]]), nl = { class: "toast__content" }, ol = { class: "toast__time" }, al = /* @__PURE__ */ U({
|
|
2876
2886
|
__name: "aeria-toast",
|
|
2877
2887
|
props: {
|
|
2878
2888
|
idx: {},
|
|
@@ -2881,7 +2891,7 @@ const tl = /* @__PURE__ */ W(el, [["__scopeId", "data-v-5443f297"]]), nl = { cla
|
|
|
2881
2891
|
icon: {}
|
|
2882
2892
|
},
|
|
2883
2893
|
setup(c) {
|
|
2884
|
-
const i =
|
|
2894
|
+
const i = ie("meta");
|
|
2885
2895
|
return (t, a) => {
|
|
2886
2896
|
const l = ne("clickable");
|
|
2887
2897
|
return N((o(), s("div", {
|
|
@@ -2906,10 +2916,10 @@ const tl = /* @__PURE__ */ W(el, [["__scopeId", "data-v-5443f297"]]), nl = { cla
|
|
|
2906
2916
|
};
|
|
2907
2917
|
}
|
|
2908
2918
|
});
|
|
2909
|
-
const ll = /* @__PURE__ */ W(al, [["__scopeId", "data-v-21bbe178"]]), sl = ["innerHTML"], il = { class: "main__toasts" }, rl = ["innerHTML"], ul = /* @__PURE__ */
|
|
2919
|
+
const ll = /* @__PURE__ */ W(al, [["__scopeId", "data-v-21bbe178"]]), sl = ["innerHTML"], il = { class: "main__toasts" }, rl = ["innerHTML"], ul = /* @__PURE__ */ U({
|
|
2910
2920
|
__name: "aeria-main",
|
|
2911
2921
|
setup(c) {
|
|
2912
|
-
const i =
|
|
2922
|
+
const i = ie("meta"), t = D(() => i.themeOverride || i.theme);
|
|
2913
2923
|
return (a, l) => {
|
|
2914
2924
|
const r = Ot("router-view");
|
|
2915
2925
|
return o(), s("main", {
|
|
@@ -2965,12 +2975,12 @@ const ll = /* @__PURE__ */ W(al, [["__scopeId", "data-v-21bbe178"]]), sl = ["inn
|
|
|
2965
2975
|
_: 1
|
|
2966
2976
|
}, 16)) : y("", !0),
|
|
2967
2977
|
g("div", il, [
|
|
2968
|
-
(o(!0), s(
|
|
2978
|
+
(o(!0), s(Z, null, E(e(i).toasts, (u) => (o(), $(ll, H({ ref_for: !0 }, u, {
|
|
2969
2979
|
key: `toast-${u.itr}`
|
|
2970
2980
|
}), {
|
|
2971
2981
|
default: v(() => [
|
|
2972
2982
|
g("div", {
|
|
2973
|
-
innerHTML: e(
|
|
2983
|
+
innerHTML: e(q)(u.text)
|
|
2974
2984
|
}, null, 8, rl)
|
|
2975
2985
|
]),
|
|
2976
2986
|
_: 2
|
|
@@ -2984,7 +2994,7 @@ const zl = /* @__PURE__ */ W(ul, [["__scopeId", "data-v-1166be3d"]]);
|
|
|
2984
2994
|
const cl = {}, dl = { class: "menu" };
|
|
2985
2995
|
function pl(c, i) {
|
|
2986
2996
|
return o(), s("menu", dl, [
|
|
2987
|
-
(o(!0), s(
|
|
2997
|
+
(o(!0), s(Z, null, E(Object.keys(c.$slots), (t) => (o(), s("div", {
|
|
2988
2998
|
key: t,
|
|
2989
2999
|
class: "menu__entry"
|
|
2990
3000
|
}, [
|
|
@@ -3001,7 +3011,7 @@ const Ml = /* @__PURE__ */ W(cl, [["render", pl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3001
3011
|
}, vl = ["onClick"], yl = {
|
|
3002
3012
|
key: 1,
|
|
3003
3013
|
class: "tabs__context-menu"
|
|
3004
|
-
}, hl = ["onClick"], $l = /* @__PURE__ */
|
|
3014
|
+
}, hl = ["onClick"], $l = /* @__PURE__ */ U({
|
|
3005
3015
|
__name: "aeria-tabs",
|
|
3006
3016
|
props: {
|
|
3007
3017
|
query: {},
|
|
@@ -3009,7 +3019,7 @@ const Ml = /* @__PURE__ */ W(cl, [["render", pl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3009
3019
|
dropdown: { type: Boolean }
|
|
3010
3020
|
},
|
|
3011
3021
|
setup(c) {
|
|
3012
|
-
const i = c, t = St(), a =
|
|
3022
|
+
const i = c, t = St(), a = Re(), l = je(), r = "query" in i && i.query ? "query" : "params", u = D(() => {
|
|
3013
3023
|
const d = a.currentRoute.value[r][i.query || i.param];
|
|
3014
3024
|
return d || Object.keys(t)[0];
|
|
3015
3025
|
}), p = (d) => {
|
|
@@ -3035,7 +3045,7 @@ const Ml = /* @__PURE__ */ W(cl, [["render", pl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3035
3045
|
d.$slots.default ? (o(), s("div", fl, [
|
|
3036
3046
|
C(d.$slots, "default", {}, void 0, !0)
|
|
3037
3047
|
])) : y("", !0),
|
|
3038
|
-
(o(!0), s(
|
|
3048
|
+
(o(!0), s(Z, null, E(Object.keys(d.$slots).filter((n) => n !== "default"), (n, f) => (o(), s("div", {
|
|
3039
3049
|
key: n,
|
|
3040
3050
|
class: G({
|
|
3041
3051
|
tabs__tab: !0,
|
|
@@ -3080,7 +3090,7 @@ const Ml = /* @__PURE__ */ W(cl, [["render", pl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3080
3090
|
};
|
|
3081
3091
|
}
|
|
3082
3092
|
});
|
|
3083
|
-
const bl = /* @__PURE__ */ W($l, [["__scopeId", "data-v-4dd516ec"]]), gl =
|
|
3093
|
+
const bl = /* @__PURE__ */ W($l, [["__scopeId", "data-v-4dd516ec"]]), gl = U({
|
|
3084
3094
|
props: {
|
|
3085
3095
|
initialValue: String,
|
|
3086
3096
|
promise: Promise
|
|
@@ -3091,13 +3101,13 @@ const bl = /* @__PURE__ */ W($l, [["__scopeId", "data-v-4dd516ec"]]), gl = q({
|
|
|
3091
3101
|
i.value = t;
|
|
3092
3102
|
}), () => Bt("div", i.value);
|
|
3093
3103
|
}
|
|
3094
|
-
}), kl = ["onClick"], Vl = { key: 1 }, Cl = /* @__PURE__ */
|
|
3104
|
+
}), kl = ["onClick"], Vl = { key: 1 }, Cl = /* @__PURE__ */ U({
|
|
3095
3105
|
__name: "aeria-crud-topbar",
|
|
3096
3106
|
props: {
|
|
3097
3107
|
collection: {}
|
|
3098
3108
|
},
|
|
3099
3109
|
setup(c) {
|
|
3100
|
-
const i = c, a =
|
|
3110
|
+
const i = c, a = Re().currentRoute, l = D(() => {
|
|
3101
3111
|
try {
|
|
3102
3112
|
const r = i.collection ? i.collection : a.value.meta.collection || a.value.params.collection;
|
|
3103
3113
|
return ge(r);
|
|
@@ -3122,10 +3132,10 @@ const bl = /* @__PURE__ */ W($l, [["__scopeId", "data-v-4dd516ec"]]), gl = q({
|
|
|
3122
3132
|
icon: d.icon
|
|
3123
3133
|
}, {
|
|
3124
3134
|
default: v(() => [
|
|
3125
|
-
Q(b(d.label || e(
|
|
3135
|
+
Q(b(d.label || e(q)(p, { plural: !0 })), 1)
|
|
3126
3136
|
]),
|
|
3127
3137
|
_: 2
|
|
3128
|
-
}, 1032, ["icon"])) : (o(), s("div", Vl, b(d.label || e(
|
|
3138
|
+
}, 1032, ["icon"])) : (o(), s("div", Vl, b(d.label || e(q)(p, { plural: !0 })), 1)),
|
|
3129
3139
|
d.badgeFunction ? (o(), $(be, { key: 2 }, {
|
|
3130
3140
|
default: v(() => [
|
|
3131
3141
|
z(e(gl), {
|
|
@@ -3144,7 +3154,7 @@ const bl = /* @__PURE__ */ W($l, [["__scopeId", "data-v-4dd516ec"]]), gl = q({
|
|
|
3144
3154
|
const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3145
3155
|
__proto__: null,
|
|
3146
3156
|
default: Il
|
|
3147
|
-
}, Symbol.toStringTag, { value: "Module" })), Fl = /* @__PURE__ */
|
|
3157
|
+
}, Symbol.toStringTag, { value: "Module" })), Fl = /* @__PURE__ */ U({
|
|
3148
3158
|
__name: "aeria-password-form",
|
|
3149
3159
|
props: {
|
|
3150
3160
|
modelValue: {}
|
|
@@ -3152,7 +3162,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3152
3162
|
emits: ["update:modelValue"],
|
|
3153
3163
|
setup(c) {
|
|
3154
3164
|
const i = c;
|
|
3155
|
-
ye(
|
|
3165
|
+
ye(Ue, null);
|
|
3156
3166
|
const t = Et(), a = D(() => t(
|
|
3157
3167
|
i.modelValue.password,
|
|
3158
3168
|
i.modelValue.confirmation
|
|
@@ -3180,7 +3190,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3180
3190
|
_: 3
|
|
3181
3191
|
}, 8, ["model-value"]));
|
|
3182
3192
|
}
|
|
3183
|
-
}),
|
|
3193
|
+
}), ql = (c, i = []) => ({
|
|
3184
3194
|
path: "/user",
|
|
3185
3195
|
name: "/builtin:user",
|
|
3186
3196
|
component: c,
|
|
@@ -3198,7 +3208,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3198
3208
|
{
|
|
3199
3209
|
path: "signin",
|
|
3200
3210
|
name: "/user/signin",
|
|
3201
|
-
component: () => import("./signin-
|
|
3211
|
+
component: () => import("./signin-81d4ab57.js"),
|
|
3202
3212
|
meta: {
|
|
3203
3213
|
title: "Autenticação"
|
|
3204
3214
|
}
|
|
@@ -3206,7 +3216,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3206
3216
|
{
|
|
3207
3217
|
path: "signup",
|
|
3208
3218
|
name: "/user/signup",
|
|
3209
|
-
component: () => import("./signup-
|
|
3219
|
+
component: () => import("./signup-ab6052da.js"),
|
|
3210
3220
|
meta: {
|
|
3211
3221
|
title: "Registro"
|
|
3212
3222
|
}
|
|
@@ -3214,13 +3224,13 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3214
3224
|
{
|
|
3215
3225
|
path: "activation",
|
|
3216
3226
|
name: "/user/activation",
|
|
3217
|
-
component: () => import("./activation-
|
|
3227
|
+
component: () => import("./activation-7645786e.js"),
|
|
3218
3228
|
meta: {
|
|
3219
3229
|
title: "Ativação"
|
|
3220
3230
|
}
|
|
3221
3231
|
}
|
|
3222
3232
|
])
|
|
3223
|
-
}),
|
|
3233
|
+
}), Ul = (c, i = []) => ({
|
|
3224
3234
|
path: "/dashboard",
|
|
3225
3235
|
name: "/builtin:dashboard",
|
|
3226
3236
|
component: c,
|
|
@@ -3236,7 +3246,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3236
3246
|
name: "/dashboard/crud",
|
|
3237
3247
|
props: !0,
|
|
3238
3248
|
components: {
|
|
3239
|
-
default: () => import("./crud-view-
|
|
3249
|
+
default: () => import("./crud-view-3df511a9.js"),
|
|
3240
3250
|
topbar: () => Promise.resolve().then(() => Al)
|
|
3241
3251
|
},
|
|
3242
3252
|
meta: {
|
|
@@ -3255,7 +3265,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3255
3265
|
children: [
|
|
3256
3266
|
{
|
|
3257
3267
|
path: "profile",
|
|
3258
|
-
component: () => import("./profile-
|
|
3268
|
+
component: () => import("./profile-7847d400.js"),
|
|
3259
3269
|
meta: {
|
|
3260
3270
|
title: "Meu perfil",
|
|
3261
3271
|
icon: "user-square"
|
|
@@ -3264,7 +3274,7 @@ const Il = /* @__PURE__ */ W(Cl, [["__scopeId", "data-v-326eee9d"]]), Al = /* @_
|
|
|
3264
3274
|
{
|
|
3265
3275
|
path: "changepass",
|
|
3266
3276
|
name: "/dashboard/user/changepass",
|
|
3267
|
-
component: () => import("./password-change-
|
|
3277
|
+
component: () => import("./password-change-55124275.js"),
|
|
3268
3278
|
meta: {
|
|
3269
3279
|
title: "Mudar senha",
|
|
3270
3280
|
icon: "lock"
|
|
@@ -3279,23 +3289,23 @@ export {
|
|
|
3279
3289
|
tl as B,
|
|
3280
3290
|
ll as C,
|
|
3281
3291
|
Il as D,
|
|
3282
|
-
|
|
3283
|
-
|
|
3292
|
+
ql as E,
|
|
3293
|
+
Ul as F,
|
|
3284
3294
|
Fl as _,
|
|
3285
|
-
|
|
3295
|
+
re as a,
|
|
3286
3296
|
P as b,
|
|
3287
3297
|
Qn as c,
|
|
3288
|
-
|
|
3298
|
+
Ll as d,
|
|
3289
3299
|
Me as e,
|
|
3290
3300
|
Ml as f,
|
|
3291
3301
|
Ae as g,
|
|
3292
3302
|
W as h,
|
|
3293
|
-
|
|
3303
|
+
Rl as i,
|
|
3294
3304
|
be as j,
|
|
3295
3305
|
fe as k,
|
|
3296
3306
|
pn as l,
|
|
3297
3307
|
Ce as m,
|
|
3298
|
-
|
|
3308
|
+
Ua as n,
|
|
3299
3309
|
$n as o,
|
|
3300
3310
|
zl as p,
|
|
3301
3311
|
Mn as q,
|