@aeria-ui/ui 0.0.79 → 0.0.80
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/{_id_-6411f44c.js → _id_-5a99fcd7.js} +1 -1
- package/dist/{activation-38221cce.js → activation-c75876f9.js} +1 -1
- package/dist/{index-6dd891f3.js → index-5ead2930.js} +1 -1
- package/dist/{index-bddeb3df.js → index-99ed76d0.js} +1 -1
- package/dist/{index-478f3f8b.js → index-b1767513.js} +1 -1
- package/dist/{index-6f63fb5e.js → index-e378d757.js} +185 -184
- package/dist/less/theme.less +1 -1
- package/dist/{signin-e4cc7e0d.js → signin-ebb7e29e.js} +1 -1
- package/dist/{signup-ba8245b7.js → signup-02b1329c.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/ui.js +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as E, ref as J, resolveDirective as oe, openBlock as t, createElementBlock as s, normalizeClass as X, Fragment as N, renderList as D, withDirectives as x, toDisplayString as k, createCommentVNode as y, createTextVNode as Q, unref as e, renderSlot as C, inject as _e, computed as W, createElementVNode as I, mergeProps as G, createBlock as $, resolveDynamicComponent as
|
|
1
|
+
import { defineComponent as E, ref as J, resolveDirective as oe, openBlock as t, createElementBlock as s, normalizeClass as X, Fragment as N, renderList as D, withDirectives as x, toDisplayString as k, createCommentVNode as y, createTextVNode as Q, unref as e, renderSlot as C, inject as _e, computed as W, createElementVNode as I, mergeProps as G, createBlock as $, resolveDynamicComponent as be, withCtx as v, useCssVars as It, normalizeProps as de, guardReactiveProps as ge, Teleport as Je, onMounted as ht, watch as ue, createVNode as F, withModifiers as ze, vModelDynamic as At, onBeforeMount as $t, normalizeStyle as he, pushScopeId as De, popScopeId as Qe, provide as ye, createSlots as ce, vModelCheckbox as Bt, onUnmounted as wt, isRef as _t, resolveComponent as St, Suspense as Tt, useSlots as jt, h as Rt } from "vue";
|
|
2
2
|
import { t as L, useI18n as Lt } from "@aeria-ui/i18n";
|
|
3
3
|
import { useScrollObserver as Ze, useBreakpoints as qe, useMask as zt, PAGINATION_PER_PAGE_DEFAULTS as Mt, API_URL as gt, request as qt, useDebounce as kt, isDocumentComplete as Ft, getObjectKey as Ut, convertToSearchQuery as Et, useAction as Ht, convertFromSearchQuery as Dt, useParentCollectionStore as Ke, usePasswordPolicy as Qt } from "@aeria-ui/core";
|
|
4
4
|
import { arraysIntersect as Vt, deepClone as Ce, getReferenceProperty as me, convertConditionToQuery as Gt, freshItem as Wt, isRequired as Kt, evaluateCondition as Ye, deepMerge as Me } from "@aeriajs/common";
|
|
@@ -171,13 +171,13 @@ const Z = /* @__PURE__ */ K(tn, [["__scopeId", "data-v-0826507c"]]), nn = { clas
|
|
|
171
171
|
setup(u, { emit: r }) {
|
|
172
172
|
const l = u, n = r, a = W(() => l.floating || l.float), i = J(l.collapsed), c = J(null), { reachedEnd: _ } = Ze(c), d = () => {
|
|
173
173
|
n("update:modelValue", !1), n("close");
|
|
174
|
-
},
|
|
174
|
+
}, b = () => {
|
|
175
175
|
n("overlayClick");
|
|
176
176
|
}, p = (o) => {
|
|
177
177
|
n("update:collapsed", o), i.value = o;
|
|
178
178
|
};
|
|
179
179
|
return (o, m) => {
|
|
180
|
-
const A = oe("clickable"),
|
|
180
|
+
const A = oe("clickable"), h = oe("loading"), S = oe("overlay");
|
|
181
181
|
return o.modelValue ? x((t(), s("div", {
|
|
182
182
|
key: 0,
|
|
183
183
|
class: X(`
|
|
@@ -185,7 +185,7 @@ const Z = /* @__PURE__ */ K(tn, [["__scopeId", "data-v-0826507c"]]), nn = { clas
|
|
|
185
185
|
${o.fixedRight && "panel--fixed"}
|
|
186
186
|
`)
|
|
187
187
|
}, [
|
|
188
|
-
(t(), $(
|
|
188
|
+
(t(), $(be(
|
|
189
189
|
a.value ? "dialog" : "div"
|
|
190
190
|
), {
|
|
191
191
|
"data-component": "panel",
|
|
@@ -250,7 +250,7 @@ const Z = /* @__PURE__ */ K(tn, [["__scopeId", "data-v-0826507c"]]), nn = { clas
|
|
|
250
250
|
}, [
|
|
251
251
|
C(o.$slots, "default", {}, void 0, !0)
|
|
252
252
|
], 2)), [
|
|
253
|
-
[
|
|
253
|
+
[h, o.loading]
|
|
254
254
|
]),
|
|
255
255
|
o.$slots.footer ? (t(), s("div", {
|
|
256
256
|
key: 2,
|
|
@@ -269,7 +269,7 @@ const Z = /* @__PURE__ */ K(tn, [["__scopeId", "data-v-0826507c"]]), nn = { clas
|
|
|
269
269
|
[S, {
|
|
270
270
|
condition: o.overlay || o.fixedRight || a.value,
|
|
271
271
|
invisible: o.invisibleOverlay,
|
|
272
|
-
click:
|
|
272
|
+
click: b,
|
|
273
273
|
layer: o.overlayLayer || (a.value ? 60 : o.fixedRight ? 50 : 0)
|
|
274
274
|
}]
|
|
275
275
|
]) : y("", !0);
|
|
@@ -362,7 +362,7 @@ const re = /* @__PURE__ */ K(un, [["__scopeId", "data-v-c328251b"]]), cn = { cla
|
|
|
362
362
|
const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { class: "content__body" }, yn = {
|
|
363
363
|
key: 0,
|
|
364
364
|
class: "content__section"
|
|
365
|
-
},
|
|
365
|
+
}, bn = { class: "content__item" }, hn = /* @__PURE__ */ E({
|
|
366
366
|
__name: "aeria-context-menu",
|
|
367
367
|
props: {
|
|
368
368
|
actions: {},
|
|
@@ -375,14 +375,14 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
375
375
|
"036683e2": _.value.x,
|
|
376
376
|
"036683e0": _.value.y
|
|
377
377
|
}));
|
|
378
|
-
const l = r, n = J(null), a = J(!1), i = (d) => d == null ? void 0 : d.filter((
|
|
379
|
-
if (
|
|
378
|
+
const l = r, n = J(null), a = J(!1), i = (d) => d == null ? void 0 : d.filter((b) => {
|
|
379
|
+
if (b.roles) {
|
|
380
380
|
const p = ie("user");
|
|
381
|
-
return Vt(
|
|
381
|
+
return Vt(b.roles, p.currentUser.roles);
|
|
382
382
|
}
|
|
383
383
|
return !0;
|
|
384
|
-
}), c = (d,
|
|
385
|
-
const p =
|
|
384
|
+
}), c = (d, b) => {
|
|
385
|
+
const p = b && Ce(b);
|
|
386
386
|
d.click && d.click(p), l("actionClick", {
|
|
387
387
|
action: d,
|
|
388
388
|
subject: p
|
|
@@ -393,14 +393,14 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
393
393
|
x: 0,
|
|
394
394
|
y: 0
|
|
395
395
|
};
|
|
396
|
-
const d = n.value.getBoundingClientRect().top,
|
|
396
|
+
const d = n.value.getBoundingClientRect().top, b = n.value.getBoundingClientRect().left, p = n.value.offsetHeight;
|
|
397
397
|
return {
|
|
398
398
|
_: a.value,
|
|
399
|
-
x: Math.floor(
|
|
399
|
+
x: Math.floor(b) + "px",
|
|
400
400
|
y: Math.floor(d + p) + "px"
|
|
401
401
|
};
|
|
402
402
|
});
|
|
403
|
-
return (d,
|
|
403
|
+
return (d, b) => {
|
|
404
404
|
const p = oe("overlay");
|
|
405
405
|
return t(), s(N, null, [
|
|
406
406
|
Object.keys(d.$slots).some((o) => o !== "default") || d.actions !== void 0 && d.actions.length > 0 ? (t(), s("div", {
|
|
@@ -411,7 +411,7 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
411
411
|
}, [
|
|
412
412
|
I("a", {
|
|
413
413
|
class: "contextmenu__trigger",
|
|
414
|
-
onClick:
|
|
414
|
+
onClick: b[0] || (b[0] = (o) => a.value = !0)
|
|
415
415
|
}, [
|
|
416
416
|
C(d.$slots, "default", de(ge({
|
|
417
417
|
visible: a.value
|
|
@@ -424,7 +424,7 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
424
424
|
}, [
|
|
425
425
|
x((t(), $(Be, {
|
|
426
426
|
modelValue: a.value,
|
|
427
|
-
"onUpdate:modelValue":
|
|
427
|
+
"onUpdate:modelValue": b[4] || (b[4] = (o) => a.value = o),
|
|
428
428
|
fill: "",
|
|
429
429
|
bordered: "",
|
|
430
430
|
class: "content",
|
|
@@ -438,7 +438,7 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
438
438
|
Object.keys(d.$slots).filter((o) => !["default", "extra", "header"].includes(o)).length > 0 ? (t(), s("div", {
|
|
439
439
|
key: 1,
|
|
440
440
|
class: "content__section",
|
|
441
|
-
onClick:
|
|
441
|
+
onClick: b[1] || (b[1] = (o) => a.value = !1)
|
|
442
442
|
}, [
|
|
443
443
|
(t(!0), s(N, null, D(Object.keys(d.$slots).filter((o) => !["default", "extra", "header"].includes(o)), (o, m) => (t(), $(ve, {
|
|
444
444
|
key: `slot-${m}`,
|
|
@@ -453,7 +453,7 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
453
453
|
d.actions !== void 0 && d.actions.length > 0 ? (t(), s("div", {
|
|
454
454
|
key: 2,
|
|
455
455
|
class: "content__section",
|
|
456
|
-
onClick:
|
|
456
|
+
onClick: b[2] || (b[2] = (o) => a.value = !1)
|
|
457
457
|
}, [
|
|
458
458
|
(t(!0), s(N, null, D(i(d.actions), (o, m) => (t(), $(ve, {
|
|
459
459
|
key: `action-${m}`,
|
|
@@ -477,9 +477,9 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
477
477
|
d.$slots.extra ? (t(), s("div", {
|
|
478
478
|
key: 3,
|
|
479
479
|
class: "content__section",
|
|
480
|
-
onClick:
|
|
480
|
+
onClick: b[3] || (b[3] = (o) => a.value = !1)
|
|
481
481
|
}, [
|
|
482
|
-
I("div",
|
|
482
|
+
I("div", bn, [
|
|
483
483
|
d.$slots.extra ? C(d.$slots, "extra", { key: 0 }, void 0, !0) : y("", !0)
|
|
484
484
|
])
|
|
485
485
|
])) : y("", !0)
|
|
@@ -504,7 +504,7 @@ const fn = /* @__PURE__ */ K(mn, [["__scopeId", "data-v-c1a322df"]]), vn = { cla
|
|
|
504
504
|
};
|
|
505
505
|
}
|
|
506
506
|
});
|
|
507
|
-
const Oe = /* @__PURE__ */ K(
|
|
507
|
+
const Oe = /* @__PURE__ */ K(hn, [["__scopeId", "data-v-a03802b2"]]), $n = { class: "info__content" }, gn = /* @__PURE__ */ E({
|
|
508
508
|
__name: "aeria-info",
|
|
509
509
|
props: {
|
|
510
510
|
where: { default: "top" }
|
|
@@ -558,7 +558,7 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
558
558
|
emits: ["update:modelValue", "input", "change", "clipboardCopy"],
|
|
559
559
|
setup(u, { emit: r }) {
|
|
560
560
|
var B;
|
|
561
|
-
const l = u, n = r, a = l.property || {}, i = "icon" in a || "inputType" in a && a.inputType === "search", c = _e("searchOnly", !1), _ = _e("innerInputLabel", !1), d = !c && (l.readOnly || a.readOnly),
|
|
561
|
+
const l = u, n = r, a = l.property || {}, i = "icon" in a || "inputType" in a && a.inputType === "search", c = _e("searchOnly", !1), _ = _e("innerInputLabel", !1), d = !c && (l.readOnly || a.readOnly), b = (R) => (n("clipboardCopy", R), navigator.clipboard.writeText(R)), p = _e("inputVariant", l.variant) || "normal", o = Object.assign(Object.assign({}, l), {
|
|
562
562
|
name: l.propertyName,
|
|
563
563
|
readonly: d,
|
|
564
564
|
type: (() => {
|
|
@@ -581,7 +581,7 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
581
581
|
})(),
|
|
582
582
|
placeholder: _ ? a.description || l.propertyName : a.placeholder
|
|
583
583
|
});
|
|
584
|
-
"type" in a && ((a.type === "number" || a.type === "integer") && (a.minimum && (o.min = a.minimum), a.exclusiveMinimum && (o.min = a.exclusiveMinimum + 1), a.maximum && (o.max = a.maximum), a.exclusiveMaximum && (o.max = a.exclusiveMaximum - 1)), a.type === "string" && ((a.format === "date" || a.format === "date-time") && (o.type = !c && a.format === "date-time" ? "datetime-local" : "date"), o.minlength = a.minLength, o.maxlength = a.maxLength)), o.type === "text" && c && (o.type = "search"),
|
|
584
|
+
"type" in a && ((a.type === "number" || a.type === "integer") && (a.minimum && (o.min = a.minimum), a.exclusiveMinimum && (o.min = a.exclusiveMinimum + 1), a.maximum && (o.max = a.maximum), a.exclusiveMaximum && (o.max = a.exclusiveMaximum - 1)), a.type === "string" && ((a.format === "date" || a.format === "date-time") && (o.type = !c && a.format === "date-time" ? "datetime-local" : "date"), o.minlength = a.minLength, o.maxlength = a.maxLength)), o.type === "text" && c && (o.type = "search"), ht(() => {
|
|
585
585
|
l.modelValue !== null && j(l.modelValue);
|
|
586
586
|
});
|
|
587
587
|
const m = (R) => {
|
|
@@ -590,11 +590,11 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
590
590
|
} catch {
|
|
591
591
|
return "";
|
|
592
592
|
}
|
|
593
|
-
}, A = J(""),
|
|
593
|
+
}, A = J(""), h = ((B = l.property) == null ? void 0 : B.type) === "string" && l.property.mask ? zt(l.property.mask) : null;
|
|
594
594
|
ue(() => l.modelValue, (R) => {
|
|
595
595
|
A.value = (() => {
|
|
596
|
-
if (
|
|
597
|
-
return R ?
|
|
596
|
+
if (h)
|
|
597
|
+
return R ? h.enmask(String(R), void 0, {
|
|
598
598
|
defaultValue: !0
|
|
599
599
|
}) : "";
|
|
600
600
|
switch (o.type) {
|
|
@@ -615,9 +615,9 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
615
615
|
});
|
|
616
616
|
const S = (R) => {
|
|
617
617
|
var Y;
|
|
618
|
-
return typeof A.value == "string" && ((Y = l.property) == null ? void 0 : Y.type) === "string" &&
|
|
618
|
+
return typeof A.value == "string" && ((Y = l.property) == null ? void 0 : Y.type) === "string" && h !== null ? (A.value = h.enmask(A.value, void 0, {
|
|
619
619
|
defaultValue: !0
|
|
620
|
-
}), l.property.maskedValue === !0 ? A.value :
|
|
620
|
+
}), l.property.maskedValue === !0 ? A.value : h.unmask(A.value)) : R;
|
|
621
621
|
}, j = (R) => {
|
|
622
622
|
const Y = (() => {
|
|
623
623
|
if (!R || typeof R != "string")
|
|
@@ -652,6 +652,7 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
652
652
|
key: 2,
|
|
653
653
|
class: X(`
|
|
654
654
|
input__container
|
|
655
|
+
input__container--textarea
|
|
655
656
|
input__container--${e(p)}
|
|
656
657
|
`)
|
|
657
658
|
}, [
|
|
@@ -705,7 +706,7 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
705
706
|
x(F(Z, {
|
|
706
707
|
reactive: "",
|
|
707
708
|
icon: "clipboard",
|
|
708
|
-
onClick: Y[1] || (Y[1] = ze((V) =>
|
|
709
|
+
onClick: Y[1] || (Y[1] = ze((V) => b(String(R.modelValue || "")), ["prevent"]))
|
|
709
710
|
}, null, 512), [
|
|
710
711
|
[te]
|
|
711
712
|
])
|
|
@@ -718,7 +719,7 @@ const kn = /* @__PURE__ */ K(gn, [["__scopeId", "data-v-7e2a5440"]]), Vn = { cla
|
|
|
718
719
|
};
|
|
719
720
|
}
|
|
720
721
|
});
|
|
721
|
-
const ke = /* @__PURE__ */ K(wn, [["__scopeId", "data-v-
|
|
722
|
+
const ke = /* @__PURE__ */ K(wn, [["__scopeId", "data-v-bfceb841"]]), Sn = {
|
|
722
723
|
key: 1,
|
|
723
724
|
value: ""
|
|
724
725
|
}, Tn = ["value", "data-selected"], jn = /* @__PURE__ */ E({
|
|
@@ -758,7 +759,7 @@ const ke = /* @__PURE__ */ K(wn, [["__scopeId", "data-v-865a7acf"]]), Sn = {
|
|
|
758
759
|
})() : W({
|
|
759
760
|
get: () => l.modelValue,
|
|
760
761
|
set: c
|
|
761
|
-
}), d = (p) => Array.isArray(l.modelValue) ? l.modelValue.includes(p) : l.modelValue === p,
|
|
762
|
+
}), d = (p) => Array.isArray(l.modelValue) ? l.modelValue.includes(p) : l.modelValue === p, b = W(() => l.multiple ? typeof l.multiple == "number" ? l.multiple : 5 : 1);
|
|
762
763
|
return l.multiple && ue(() => l.modelValue, (p) => {
|
|
763
764
|
var m;
|
|
764
765
|
if (!a.value)
|
|
@@ -770,14 +771,14 @@ const ke = /* @__PURE__ */ K(wn, [["__scopeId", "data-v-865a7acf"]]), Sn = {
|
|
|
770
771
|
"read-only": "",
|
|
771
772
|
"model-value": e(_)
|
|
772
773
|
}, null, 8, ["model-value"])) : (t(), s("select", G({ key: 0 }, {
|
|
773
|
-
size:
|
|
774
|
+
size: b.value,
|
|
774
775
|
value: e(_)
|
|
775
776
|
}, {
|
|
776
777
|
ref_key: "select",
|
|
777
778
|
ref: a,
|
|
778
779
|
class: {
|
|
779
780
|
select: !0,
|
|
780
|
-
"select--multiple": !!
|
|
781
|
+
"select--multiple": !!b.value,
|
|
781
782
|
"select--outline": !p.noOutline
|
|
782
783
|
},
|
|
783
784
|
onChange: o[0] || (o[0] = (m) => c(m.target.value))
|
|
@@ -812,26 +813,26 @@ const Ge = /* @__PURE__ */ K(jn, [["__scopeId", "data-v-1c0432ab"]]), Rn = { cla
|
|
|
812
813
|
setup(u, { emit: r }) {
|
|
813
814
|
const l = u, n = r, a = W({
|
|
814
815
|
get: () => Math.floor(l.pagination.offset / l.pagination.limit),
|
|
815
|
-
set: (
|
|
816
|
-
l.pagination.offset =
|
|
816
|
+
set: (b) => {
|
|
817
|
+
l.pagination.offset = b * l.pagination.limit;
|
|
817
818
|
}
|
|
818
819
|
}), i = W({
|
|
819
820
|
get: () => l.pagination.limit,
|
|
820
|
-
set: (
|
|
821
|
-
l.pagination.limit = Number(
|
|
821
|
+
set: (b) => {
|
|
822
|
+
l.pagination.limit = Number(b);
|
|
822
823
|
}
|
|
823
|
-
}), c = J(a.value ? a.value + 1 : 1), _ = W(() => Math.ceil(l.pagination.recordsTotal / l.pagination.limit)), d = (
|
|
824
|
-
a.value =
|
|
824
|
+
}), c = J(a.value ? a.value + 1 : 1), _ = W(() => Math.ceil(l.pagination.recordsTotal / l.pagination.limit)), d = (b) => {
|
|
825
|
+
a.value = b === "previous" ? a.value - 1 : a.value + 1;
|
|
825
826
|
};
|
|
826
827
|
return ue([
|
|
827
828
|
a,
|
|
828
829
|
i
|
|
829
|
-
], ([
|
|
830
|
-
c.value =
|
|
830
|
+
], ([b]) => {
|
|
831
|
+
c.value = b + 1, n("paginate", {
|
|
831
832
|
offset: a.value * i.value,
|
|
832
833
|
limit: i.value
|
|
833
834
|
});
|
|
834
|
-
}), (
|
|
835
|
+
}), (b, p) => (t(), s("div", Rn, [
|
|
835
836
|
I("div", Ln, [
|
|
836
837
|
F(ve, {
|
|
837
838
|
disabled: a.value === 0,
|
|
@@ -887,7 +888,7 @@ const Ge = /* @__PURE__ */ K(jn, [["__scopeId", "data-v-1c0432ab"]]), Rn = { cla
|
|
|
887
888
|
_: 1
|
|
888
889
|
}, 8, ["modelValue"])
|
|
889
890
|
]),
|
|
890
|
-
|
|
891
|
+
b.noSummary ? y("", !0) : (t(), s("div", Mn, [
|
|
891
892
|
Q(k(e(L)("Page")) + " ", 1),
|
|
892
893
|
(t(), $(ke, {
|
|
893
894
|
key: a.value,
|
|
@@ -963,11 +964,11 @@ const Fn = /* @__PURE__ */ K(qn, [["__scopeId", "data-v-ae7235de"]]), Un = { cla
|
|
|
963
964
|
c("update:modelValue", l.value);
|
|
964
965
|
}
|
|
965
966
|
}
|
|
966
|
-
}),
|
|
967
|
+
}), b = (p) => {
|
|
967
968
|
a && p.preventDefault();
|
|
968
969
|
};
|
|
969
970
|
return (p, o) => {
|
|
970
|
-
var A,
|
|
971
|
+
var A, h;
|
|
971
972
|
const m = oe("clickable");
|
|
972
973
|
return x((t(), s("label", {
|
|
973
974
|
class: X(`
|
|
@@ -983,7 +984,7 @@ const Fn = /* @__PURE__ */ K(qn, [["__scopeId", "data-v-ae7235de"]]), Un = { cla
|
|
|
983
984
|
checked: d.value
|
|
984
985
|
}, {
|
|
985
986
|
class: "checkbox__input",
|
|
986
|
-
onClick:
|
|
987
|
+
onClick: b
|
|
987
988
|
}), null, 16), [
|
|
988
989
|
[At, d.value]
|
|
989
990
|
]),
|
|
@@ -995,7 +996,7 @@ const Fn = /* @__PURE__ */ K(qn, [["__scopeId", "data-v-ae7235de"]]), Un = { cla
|
|
|
995
996
|
}, null, 8, En)) : C(p.$slots, "default", { key: 2 }, void 0, !0)
|
|
996
997
|
]),
|
|
997
998
|
I("div", Hn, [
|
|
998
|
-
p.$slots.hint ? C(p.$slots, "hint", { key: 0 }, void 0, !0) : (
|
|
999
|
+
p.$slots.hint ? C(p.$slots, "hint", { key: 0 }, void 0, !0) : (h = e(n)) != null && h.hint ? (t(), s("div", {
|
|
999
1000
|
key: 1,
|
|
1000
1001
|
innerHTML: e(n).hint
|
|
1001
1002
|
}, null, 8, Dn)) : y("", !0)
|
|
@@ -1033,17 +1034,17 @@ const Wn = /* @__PURE__ */ K(Gn, [["__scopeId", "data-v-b9da4354"]]), Kn = {
|
|
|
1033
1034
|
);
|
|
1034
1035
|
}), (_, d) => (t(), s("div", {
|
|
1035
1036
|
class: "options",
|
|
1036
|
-
style:
|
|
1037
|
+
style: he(`
|
|
1037
1038
|
--columns: ${_.columns};
|
|
1038
1039
|
grid-template-columns: repeat(var(--columns), 1fr);
|
|
1039
1040
|
`)
|
|
1040
1041
|
}, [
|
|
1041
|
-
(t(!0), s(N, null, D(e(i), (
|
|
1042
|
-
key: `option-${
|
|
1042
|
+
(t(!0), s(N, null, D(e(i), (b) => (t(), s("div", {
|
|
1043
|
+
key: `option-${b}`,
|
|
1043
1044
|
class: "options__checkbox"
|
|
1044
1045
|
}, [
|
|
1045
1046
|
F(Wn, G({ ref_for: !0 }, {
|
|
1046
|
-
value:
|
|
1047
|
+
value: b,
|
|
1047
1048
|
readOnly: e(a),
|
|
1048
1049
|
property: _.property
|
|
1049
1050
|
}, {
|
|
@@ -1074,7 +1075,7 @@ const Yn = /* @__PURE__ */ K(Xn, [["__scopeId", "data-v-4aed0c5c"]]), Jn = (u) =
|
|
|
1074
1075
|
};
|
|
1075
1076
|
return (_, d) => {
|
|
1076
1077
|
var p;
|
|
1077
|
-
const
|
|
1078
|
+
const b = oe("clickable");
|
|
1078
1079
|
return t(), s("div", Zn, [
|
|
1079
1080
|
x((t(), s("a", {
|
|
1080
1081
|
class: X(`
|
|
@@ -1092,7 +1093,7 @@ const Yn = /* @__PURE__ */ K(Xn, [["__scopeId", "data-v-4aed0c5c"]]), Jn = (u) =
|
|
|
1092
1093
|
`)
|
|
1093
1094
|
}, null, 2)
|
|
1094
1095
|
], 2)), [
|
|
1095
|
-
[
|
|
1096
|
+
[b, {
|
|
1096
1097
|
blocked: e(i)
|
|
1097
1098
|
}]
|
|
1098
1099
|
]),
|
|
@@ -1175,7 +1176,7 @@ const to = /* @__PURE__ */ K(eo, [["__scopeId", "data-v-0e3564b6"]]), Ct = (u) =
|
|
|
1175
1176
|
${a.bordered && "picture__image--bordered"}
|
|
1176
1177
|
${a.expandable && "picture__image--expandable"}
|
|
1177
1178
|
`),
|
|
1178
|
-
style:
|
|
1179
|
+
style: he(`
|
|
1179
1180
|
object-fit: ${a.objectFit || "cover"};
|
|
1180
1181
|
width: ${a.width || "100%"};
|
|
1181
1182
|
height: ${a.height || "100%"};
|
|
@@ -1191,7 +1192,7 @@ const to = /* @__PURE__ */ K(eo, [["__scopeId", "data-v-0e3564b6"]]), Ct = (u) =
|
|
|
1191
1192
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1192
1193
|
viewBox: "0 0 200 200",
|
|
1193
1194
|
preserveAspectRatio: "none",
|
|
1194
|
-
style:
|
|
1195
|
+
style: he(`
|
|
1195
1196
|
object-fit: ${a.objectFit || "cover"};
|
|
1196
1197
|
width: ${a.width || "100%"};
|
|
1197
1198
|
height: ${a.height || "100%"};
|
|
@@ -1207,10 +1208,10 @@ const to = /* @__PURE__ */ K(eo, [["__scopeId", "data-v-0e3564b6"]]), Ct = (u) =
|
|
|
1207
1208
|
const He = /* @__PURE__ */ K(po, [["__scopeId", "data-v-153a2e0f"]]), _o = { class: "file" }, mo = { key: 0 }, fo = ["href"], vo = {
|
|
1208
1209
|
key: 1,
|
|
1209
1210
|
class: "file__actions"
|
|
1210
|
-
}, yo = ["accept"],
|
|
1211
|
+
}, yo = ["accept"], bo = {
|
|
1211
1212
|
key: 0,
|
|
1212
1213
|
class: "file__buttons"
|
|
1213
|
-
},
|
|
1214
|
+
}, ho = {
|
|
1214
1215
|
key: 1,
|
|
1215
1216
|
class: "file__buttons"
|
|
1216
1217
|
}, $o = /* @__PURE__ */ E({
|
|
@@ -1229,19 +1230,19 @@ const He = /* @__PURE__ */ K(po, [["__scopeId", "data-v-153a2e0f"]]), _o = { cla
|
|
|
1229
1230
|
setup(u, { emit: r }) {
|
|
1230
1231
|
var A;
|
|
1231
1232
|
const l = u, n = r, i = Fe() ? Ie() : null, c = J(((A = l.modelValue) == null ? void 0 : A.file) || null), _ = W(() => {
|
|
1232
|
-
var
|
|
1233
|
-
return c.value ? URL.createObjectURL(c.value) : (
|
|
1233
|
+
var h;
|
|
1234
|
+
return c.value ? URL.createObjectURL(c.value) : (h = l.modelValue) == null ? void 0 : h.link;
|
|
1234
1235
|
}), d = W(() => {
|
|
1235
|
-
var
|
|
1236
|
-
return /^image\//.test((
|
|
1237
|
-
}),
|
|
1236
|
+
var h, S, j;
|
|
1237
|
+
return /^image\//.test((h = l.modelValue) == null ? void 0 : h.type) && !((S = c.value) != null && S.type) || /^image\//.test((j = c.value) == null ? void 0 : j.type);
|
|
1238
|
+
}), b = (h) => new Promise((S) => {
|
|
1238
1239
|
const j = new FileReader();
|
|
1239
|
-
j.onload = () => S(j.result), j.readAsArrayBuffer(
|
|
1240
|
+
j.onload = () => S(j.result), j.readAsArrayBuffer(h);
|
|
1240
1241
|
}), p = () => {
|
|
1241
1242
|
l.modelValue.tempId && n("update:modelValue", null), c.value = null;
|
|
1242
|
-
}, o = async (
|
|
1243
|
-
c.value =
|
|
1244
|
-
const S = c.value, j = await
|
|
1243
|
+
}, o = async (h) => {
|
|
1244
|
+
c.value = h.target.files[0];
|
|
1245
|
+
const S = c.value, j = await b(S);
|
|
1245
1246
|
if (i) {
|
|
1246
1247
|
const { data: { error: P, result: B } } = await qt(`${gt}/${i.$id}/upload?name=${S.name}`, j, {
|
|
1247
1248
|
params: {
|
|
@@ -1264,34 +1265,34 @@ const He = /* @__PURE__ */ K(po, [["__scopeId", "data-v-153a2e0f"]]), _o = { cla
|
|
|
1264
1265
|
}, m = async () => {
|
|
1265
1266
|
n("update:modelValue", null);
|
|
1266
1267
|
};
|
|
1267
|
-
return (
|
|
1268
|
+
return (h, S) => {
|
|
1268
1269
|
var j, P, B, R, Y, w;
|
|
1269
1270
|
return t(), s("div", _o, [
|
|
1270
|
-
c.value || (j =
|
|
1271
|
+
c.value || (j = h.modelValue) != null && j._id ? (t(), s("div", mo, [
|
|
1271
1272
|
d.value ? (t(), $(He, {
|
|
1272
1273
|
key: 0,
|
|
1273
1274
|
modelValue: _.value,
|
|
1274
1275
|
"onUpdate:modelValue": S[0] || (S[0] = (te) => _.value = te),
|
|
1275
1276
|
alt: "Image preview",
|
|
1276
|
-
expandable:
|
|
1277
|
+
expandable: h.readOnly,
|
|
1277
1278
|
class: X(`
|
|
1278
1279
|
file__image
|
|
1279
|
-
${!e(i) || ((P =
|
|
1280
|
+
${!e(i) || ((P = h.modelValue) == null ? void 0 : P._id) || "file__image--unsent"}
|
|
1280
1281
|
`)
|
|
1281
1282
|
}, null, 8, ["modelValue", "expandable", "class"])) : y("", !0),
|
|
1282
|
-
(B =
|
|
1283
|
+
(B = h.modelValue) != null && B._id ? (t(), s("a", {
|
|
1283
1284
|
key: 1,
|
|
1284
|
-
href:
|
|
1285
|
-
}, k(
|
|
1285
|
+
href: h.modelValue.download_link
|
|
1286
|
+
}, k(h.modelValue.name), 9, fo)) : y("", !0)
|
|
1286
1287
|
])) : y("", !0),
|
|
1287
|
-
|
|
1288
|
+
h.readOnly ? y("", !0) : (t(), s("div", vo, [
|
|
1288
1289
|
I("input", {
|
|
1289
1290
|
ref: "file",
|
|
1290
1291
|
type: "file",
|
|
1291
|
-
accept: (Y = (R =
|
|
1292
|
+
accept: (Y = (R = h.property) == null ? void 0 : R.accept) == null ? void 0 : Y.join(","),
|
|
1292
1293
|
onChange: o
|
|
1293
1294
|
}, null, 40, yo),
|
|
1294
|
-
c.value ? (t(), s("div",
|
|
1295
|
+
c.value ? (t(), s("div", bo, [
|
|
1295
1296
|
F(re, {
|
|
1296
1297
|
small: "",
|
|
1297
1298
|
onClick: ze(p, ["prevent"])
|
|
@@ -1301,7 +1302,7 @@ const He = /* @__PURE__ */ K(po, [["__scopeId", "data-v-153a2e0f"]]), _o = { cla
|
|
|
1301
1302
|
]),
|
|
1302
1303
|
_: 1
|
|
1303
1304
|
})
|
|
1304
|
-
])) : (w =
|
|
1305
|
+
])) : (w = h.modelValue) != null && w._id ? (t(), s("div", ho, [
|
|
1305
1306
|
F(re, {
|
|
1306
1307
|
small: "",
|
|
1307
1308
|
onClick: ze(m, ["prevent"])
|
|
@@ -1358,23 +1359,23 @@ const mt = /* @__PURE__ */ K(Co, [["__scopeId", "data-v-c86e2d2a"]]), Oo = { cla
|
|
|
1358
1359
|
},
|
|
1359
1360
|
emits: ["update:modelValue", "change"],
|
|
1360
1361
|
setup(u, { emit: r }) {
|
|
1361
|
-
const l = Ae(), n = u, a = r, i = n.property, c = me(i), _ = Ie(), d = W(() => Array.isArray(n.modelValue) ? Array.isArray(n.modelValue) && Object.values(n.modelValue).some(({ _id: m }) => n.item._id === m) : n.modelValue && n.modelValue._id === n.item._id),
|
|
1362
|
+
const l = Ae(), n = u, a = r, i = n.property, c = me(i), _ = Ie(), d = W(() => Array.isArray(n.modelValue) ? Array.isArray(n.modelValue) && Object.values(n.modelValue).some(({ _id: m }) => n.item._id === m) : n.modelValue && n.modelValue._id === n.item._id), b = () => {
|
|
1362
1363
|
if (d.value)
|
|
1363
1364
|
return;
|
|
1364
|
-
const m = (
|
|
1365
|
+
const m = (h) => h.filter((S) => !!(S != null && S._id)), A = "items" in i ? m(Array.isArray(n.modelValue) ? n.modelValue : [n.modelValue]) : n.modelValue;
|
|
1365
1366
|
Array.isArray(A) ? a("update:modelValue", A.concat([n.item])) : a("update:modelValue", n.item), a("change", n.item);
|
|
1366
1367
|
}, p = async (m) => {
|
|
1367
1368
|
if (c.purge && (m != null && m.purge)) {
|
|
1368
|
-
const { _id:
|
|
1369
|
+
const { _id: h } = n.item;
|
|
1369
1370
|
await _.$actions.remove({
|
|
1370
1371
|
filters: {
|
|
1371
|
-
_id:
|
|
1372
|
+
_id: h
|
|
1372
1373
|
}
|
|
1373
1374
|
});
|
|
1374
1375
|
}
|
|
1375
1376
|
const A = () => {
|
|
1376
|
-
const
|
|
1377
|
-
return
|
|
1377
|
+
const h = [...n.modelValue], S = h.findIndex((j) => j._id === n.item._id);
|
|
1378
|
+
return h.splice(S, 1), h;
|
|
1378
1379
|
};
|
|
1379
1380
|
a("update:modelValue", "items" in i ? A() : null);
|
|
1380
1381
|
}, o = () => {
|
|
@@ -1384,10 +1385,10 @@ const mt = /* @__PURE__ */ K(Co, [["__scopeId", "data-v-c86e2d2a"]]), Oo = { cla
|
|
|
1384
1385
|
});
|
|
1385
1386
|
return;
|
|
1386
1387
|
}
|
|
1387
|
-
return d.value ? p() :
|
|
1388
|
+
return d.value ? p() : b();
|
|
1388
1389
|
};
|
|
1389
1390
|
return (m, A) => {
|
|
1390
|
-
const
|
|
1391
|
+
const h = oe("clickable");
|
|
1391
1392
|
return x((t(), s("div", {
|
|
1392
1393
|
class: X({
|
|
1393
1394
|
item: !0,
|
|
@@ -1408,7 +1409,7 @@ const mt = /* @__PURE__ */ K(Co, [["__scopeId", "data-v-c86e2d2a"]]), Oo = { cla
|
|
|
1408
1409
|
style: { "--icon-color": "var(--theme-brand-color-contrast)" }
|
|
1409
1410
|
})) : y("", !0)
|
|
1410
1411
|
], 2)), [
|
|
1411
|
-
[
|
|
1412
|
+
[h]
|
|
1412
1413
|
]);
|
|
1413
1414
|
};
|
|
1414
1415
|
}
|
|
@@ -1430,12 +1431,12 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1430
1431
|
},
|
|
1431
1432
|
emits: ["update:modelValue", "change", "update:panel"],
|
|
1432
1433
|
setup(u, { emit: r }) {
|
|
1433
|
-
const l = u, n = me(l.property), a = l.panel !== void 0 ? W(() => l.panel) : J(!1), i = r, c = ie(me(l.property).$ref), _ = Fe(), d = _ ? Ie() : null,
|
|
1434
|
+
const l = u, n = me(l.property), a = l.panel !== void 0 ? W(() => l.panel) : J(!1), i = r, c = ie(me(l.property).$ref), _ = Fe(), d = _ ? Ie() : null, b = n.indexes;
|
|
1434
1435
|
ye(Ue, me(l.property).$ref), ye("innerInputLabel", !0), ye("omitInputLabels", !0);
|
|
1435
1436
|
const p = J(l.modelValue), o = J({
|
|
1436
1437
|
data: [],
|
|
1437
1438
|
pagination: {}
|
|
1438
|
-
}), m = W(() => o.value.data), A = W(() => o.value.pagination),
|
|
1439
|
+
}), m = W(() => o.value.data), A = W(() => o.value.pagination), h = J(0), S = J(b[0]), j = J(!1), P = J({}), B = () => {
|
|
1439
1440
|
const z = {};
|
|
1440
1441
|
if (_) {
|
|
1441
1442
|
const U = e(_);
|
|
@@ -1443,15 +1444,15 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1443
1444
|
}
|
|
1444
1445
|
return n.constraints ? Gt(n.constraints, z) : {};
|
|
1445
1446
|
}, R = () => {
|
|
1446
|
-
m.value.length < A.value.recordsTotal && (
|
|
1447
|
+
m.value.length < A.value.recordsTotal && (h.value += 1, w());
|
|
1447
1448
|
}, Y = async () => {
|
|
1448
1449
|
if (Object.values(P.value).every((U) => !(String(U).length > 0)))
|
|
1449
1450
|
return c.$actions.custom("getAll", {
|
|
1450
1451
|
limit: Ee,
|
|
1451
|
-
offset:
|
|
1452
|
+
offset: h.value * Ee,
|
|
1452
1453
|
filters: B()
|
|
1453
1454
|
});
|
|
1454
|
-
const z =
|
|
1455
|
+
const z = b.filter((U) => {
|
|
1455
1456
|
var f;
|
|
1456
1457
|
return ((f = P.value[U]) == null ? void 0 : f.length) > 0;
|
|
1457
1458
|
}).map((U) => ({
|
|
@@ -1462,7 +1463,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1462
1463
|
}));
|
|
1463
1464
|
return c.$actions.custom("getAll", {
|
|
1464
1465
|
limit: Ee,
|
|
1465
|
-
offset:
|
|
1466
|
+
offset: h.value * Ee,
|
|
1466
1467
|
filters: {
|
|
1467
1468
|
...B(),
|
|
1468
1469
|
...z.length > 0 && {
|
|
@@ -1481,21 +1482,21 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1481
1482
|
});
|
|
1482
1483
|
return;
|
|
1483
1484
|
}
|
|
1484
|
-
o.value.pagination = U.pagination,
|
|
1485
|
+
o.value.pagination = U.pagination, h.value === 0 && o.value.data.splice(0), o.value.data.push(...U.data);
|
|
1485
1486
|
}, [te] = kt({
|
|
1486
1487
|
delay: 800
|
|
1487
1488
|
})(() => {
|
|
1488
|
-
|
|
1489
|
+
h.value = 0, w(), j.value = !1;
|
|
1489
1490
|
}), V = () => {
|
|
1490
1491
|
j.value = !0, te();
|
|
1491
1492
|
}, T = () => {
|
|
1492
1493
|
"effect" in a ? i("update:panel", !0) : a.value = !0, w();
|
|
1493
1494
|
}, ae = () => {
|
|
1494
|
-
|
|
1495
|
+
h.value = 0, o.value.data.splice(0), "effect" in a ? i("update:panel", !1) : a.value = !1;
|
|
1495
1496
|
}, le = W(() => !Object.values(P.value).some((z) => !!z));
|
|
1496
1497
|
ue(le, (z, U) => {
|
|
1497
1498
|
z && !U && w();
|
|
1498
|
-
}),
|
|
1499
|
+
}), ht(() => {
|
|
1499
1500
|
l.selectOnly && w();
|
|
1500
1501
|
});
|
|
1501
1502
|
const ne = (z) => {
|
|
@@ -1536,7 +1537,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1536
1537
|
return [
|
|
1537
1538
|
I("div", Ao, [
|
|
1538
1539
|
I("div", Bo, [
|
|
1539
|
-
e(
|
|
1540
|
+
e(b).length > 1 ? (t(), $(Ge, {
|
|
1540
1541
|
key: 0,
|
|
1541
1542
|
modelValue: S.value,
|
|
1542
1543
|
"onUpdate:modelValue": U[0] || (U[0] = (g) => S.value = g),
|
|
@@ -1544,7 +1545,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1544
1545
|
onChange: U[1] || (U[1] = (g) => P.value = {})
|
|
1545
1546
|
}, {
|
|
1546
1547
|
default: v(() => [
|
|
1547
|
-
(t(!0), s(N, null, D(e(
|
|
1548
|
+
(t(!0), s(N, null, D(e(b), (g) => (t(), s("option", {
|
|
1548
1549
|
key: `searchfield-${g}`,
|
|
1549
1550
|
value: g
|
|
1550
1551
|
}, k(e(L)(g)), 9, wo))), 128))
|
|
@@ -1572,7 +1573,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1572
1573
|
default: v(() => [
|
|
1573
1574
|
(t(!0), s(N, null, D(m.value, (g) => (t(), $(Xe, G({ ref_for: !0 }, {
|
|
1574
1575
|
item: g,
|
|
1575
|
-
indexes: e(
|
|
1576
|
+
indexes: e(b),
|
|
1576
1577
|
property: z.property
|
|
1577
1578
|
}, {
|
|
1578
1579
|
key: `matching-${g._id}`,
|
|
@@ -1599,7 +1600,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1599
1600
|
"items" in z.property ? (t(), s("div", Mo, [
|
|
1600
1601
|
(t(!0), s(N, null, D(z.modelValue, (H) => (t(), $(Xe, G({ ref_for: !0 }, {
|
|
1601
1602
|
item: H,
|
|
1602
|
-
indexes: e(
|
|
1603
|
+
indexes: e(b),
|
|
1603
1604
|
property: z.property,
|
|
1604
1605
|
readOnly: z.readOnly,
|
|
1605
1606
|
modelValue: z.modelValue
|
|
@@ -1609,7 +1610,7 @@ const Xe = /* @__PURE__ */ K(Io, [["__scopeId", "data-v-e8413b98"]]), Ao = { cla
|
|
|
1609
1610
|
}), null, 16))), 128))
|
|
1610
1611
|
])) : (M = z.modelValue) != null && M._id ? (t(), $(Xe, G({ key: 1 }, {
|
|
1611
1612
|
item: z.modelValue,
|
|
1612
|
-
indexes: e(
|
|
1613
|
+
indexes: e(b),
|
|
1613
1614
|
property: e(n),
|
|
1614
1615
|
readOnly: z.readOnly,
|
|
1615
1616
|
modelValue: z.modelValue
|
|
@@ -1725,7 +1726,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1725
1726
|
const i = n.property && me(n.property), c = i ? i.$ref : n.collection || Fe(), _ = n.readOnly || ((U = n.property) == null ? void 0 : U.readOnly), d = c ? ie(e(c)) : null;
|
|
1726
1727
|
!c && process.env.NODE_ENV !== "production" && console.warn(`aeria-form was used without providing storeId or specifying
|
|
1727
1728
|
collection prop, some features may not work as intended`);
|
|
1728
|
-
const
|
|
1729
|
+
const b = J(!1), p = W(() => {
|
|
1729
1730
|
const f = (() => !n.form && n.property ? "type" in n.property && n.property.type === "object" ? "properties" in n.property ? n.property.properties : void 0 : d == null ? void 0 : d.properties : n.form)();
|
|
1730
1731
|
if (!f)
|
|
1731
1732
|
return;
|
|
@@ -1746,7 +1747,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1746
1747
|
}), o = W(() => n.layout || (d == null ? void 0 : d.description.formLayout)), m = (f) => {
|
|
1747
1748
|
const M = _e(f, n[f]);
|
|
1748
1749
|
return n[f] && ye(f, n[f]), M;
|
|
1749
|
-
}, A = W(() => n.validationErrors !== null ? n.validationErrors : d == null ? void 0 : d.validationErrors),
|
|
1750
|
+
}, A = W(() => n.validationErrors !== null ? n.validationErrors : d == null ? void 0 : d.validationErrors), h = m("formComponents") || {}, S = m("propertyComponents") || {}, j = m("omitFormHeader"), P = m("omitInputLabels"), B = m("innerInputLabel");
|
|
1750
1751
|
c && ye(Ue, c), ye("searchOnly", n.searchOnly);
|
|
1751
1752
|
const R = (f) => p.value ? Object.entries(p.value).filter(([M, H]) => !H.noForm && f([
|
|
1752
1753
|
M,
|
|
@@ -1794,14 +1795,14 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1794
1795
|
var H;
|
|
1795
1796
|
return (H = A.value) != null && H[f] && (typeof A.value[f].index != "number" || A.value[f].index === M) ? A.value[f].errors : null;
|
|
1796
1797
|
}, z = (f) => {
|
|
1797
|
-
if (!(_ || f.readOnly) && !n.parentPropertyName && !n.parentCollection && !
|
|
1798
|
-
return
|
|
1798
|
+
if (!(_ || f.readOnly) && !n.parentPropertyName && !n.parentCollection && !b.value)
|
|
1799
|
+
return b.value = !0, !0;
|
|
1799
1800
|
};
|
|
1800
1801
|
return (f, M) => {
|
|
1801
1802
|
const H = oe("clickable"), g = oe("focus");
|
|
1802
1803
|
return t(), s("form", {
|
|
1803
1804
|
class: "form",
|
|
1804
|
-
style:
|
|
1805
|
+
style: he(`row-gap: ${e(j) ? ".8rem" : "var(--form-internal-gap, 1.6rem);"};`)
|
|
1805
1806
|
}, [
|
|
1806
1807
|
f.$slots.header && !e(j) ? (t(), s("header", Ho, [
|
|
1807
1808
|
C(f.$slots, "header", {}, void 0, !0)
|
|
@@ -1812,7 +1813,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1812
1813
|
var fe, we, Se, Te, Ne, xe, et, tt, nt, ot, at, lt, st;
|
|
1813
1814
|
return t(), s("div", {
|
|
1814
1815
|
key: `field-${O}`,
|
|
1815
|
-
style:
|
|
1816
|
+
style: he(T(O, q)),
|
|
1816
1817
|
class: "form__field"
|
|
1817
1818
|
}, [
|
|
1818
1819
|
(!("type" in q) || q.type !== "boolean" || f.searchOnly) && !q.noLabel && !e(P) && !e(B) ? (t(), s("label", Qo, [
|
|
@@ -1836,7 +1837,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1836
1837
|
property: q,
|
|
1837
1838
|
propertyName: O,
|
|
1838
1839
|
modelValue: f.modelValue
|
|
1839
|
-
}), void 0, !0) : (Se = (we = (fe = f.layout) == null ? void 0 : fe.fields) == null ? void 0 : we[O]) != null && Se.component && e(S)[f.layout.fields[O].component.name] ? (t(), $(
|
|
1840
|
+
}), void 0, !0) : (Se = (we = (fe = f.layout) == null ? void 0 : fe.fields) == null ? void 0 : we[O]) != null && Se.component && e(S)[f.layout.fields[O].component.name] ? (t(), $(be(e(S)[f.layout.fields[O].component.name]), G({
|
|
1840
1841
|
key: 2,
|
|
1841
1842
|
modelValue: f.modelValue[O],
|
|
1842
1843
|
"onUpdate:modelValue": (ee) => f.modelValue[O] = ee,
|
|
@@ -1914,7 +1915,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1914
1915
|
class: "form__array-item"
|
|
1915
1916
|
}, [
|
|
1916
1917
|
I("div", No, [
|
|
1917
|
-
(t(), $(
|
|
1918
|
+
(t(), $(be(e(ft)(q, e(h))), G({
|
|
1918
1919
|
modelValue: f.modelValue[O][je],
|
|
1919
1920
|
"onUpdate:modelValue": (Re) => f.modelValue[O][je] = Re,
|
|
1920
1921
|
ref_for: !0
|
|
@@ -1943,7 +1944,7 @@ const Fo = /* @__PURE__ */ K(qo, [["__scopeId", "data-v-15bbe202"]]), ft = (u, r
|
|
|
1943
1944
|
]);
|
|
1944
1945
|
}), 128))
|
|
1945
1946
|
])
|
|
1946
|
-
])) : f.modelValue ? x((t(), $(
|
|
1947
|
+
])) : f.modelValue ? x((t(), $(be(e(ft)(q, e(h))), G({
|
|
1947
1948
|
key: 6,
|
|
1948
1949
|
modelValue: f.modelValue[O],
|
|
1949
1950
|
"onUpdate:modelValue": (ee) => f.modelValue[O] = ee,
|
|
@@ -2000,14 +2001,14 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2000
2001
|
"close-hint": "",
|
|
2001
2002
|
"fixed-right": "",
|
|
2002
2003
|
title: _.t("filter_by", { capitalize: !0 }),
|
|
2003
|
-
onClose: d[2] || (d[2] = (
|
|
2004
|
-
onOverlayClick: d[3] || (d[3] = (
|
|
2004
|
+
onClose: d[2] || (d[2] = (b) => l("update:modelValue", !1)),
|
|
2005
|
+
onOverlayClick: d[3] || (d[3] = (b) => l("update:modelValue", !1))
|
|
2005
2006
|
}, {
|
|
2006
2007
|
footer: v(() => [
|
|
2007
2008
|
e(n).filtersCount > 0 ? (t(), $(re, {
|
|
2008
2009
|
key: 0,
|
|
2009
2010
|
variant: "transparent",
|
|
2010
|
-
onClick: d[1] || (d[1] = (
|
|
2011
|
+
onClick: d[1] || (d[1] = (b) => {
|
|
2011
2012
|
e(n).$actions.clearFilters(), c(), l("update:modelValue", !1);
|
|
2012
2013
|
})
|
|
2013
2014
|
}, {
|
|
@@ -2037,7 +2038,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2037
2038
|
default: v(() => [
|
|
2038
2039
|
F(We, G({
|
|
2039
2040
|
modelValue: e(n).filters,
|
|
2040
|
-
"onUpdate:modelValue": d[0] || (d[0] = (
|
|
2041
|
+
"onUpdate:modelValue": d[0] || (d[0] = (b) => e(n).filters = b)
|
|
2041
2042
|
}, {
|
|
2042
2043
|
searchOnly: !0,
|
|
2043
2044
|
form: e(n).availableFilters,
|
|
@@ -2061,7 +2062,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2061
2062
|
const l = u, n = r, a = ie("meta"), i = ie(l.collection || a.view.collection), c = _e("individualActions", []), _ = async () => {
|
|
2062
2063
|
const { error: o } = await i.$actions.deepInsert();
|
|
2063
2064
|
o || n("update:modelValue", !1);
|
|
2064
|
-
}, { t: d } = Lt(),
|
|
2065
|
+
}, { t: d } = Lt(), b = () => {
|
|
2065
2066
|
a.$actions.ask({
|
|
2066
2067
|
action: () => {
|
|
2067
2068
|
i.$actions.clearItem(), i.validationErrors = {}, n("cancel");
|
|
@@ -2078,23 +2079,23 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2078
2079
|
const A = oe("clickable");
|
|
2079
2080
|
return t(), $(Be, {
|
|
2080
2081
|
loading: e(i).loading.get,
|
|
2081
|
-
onOverlayClick:
|
|
2082
|
+
onOverlayClick: b
|
|
2082
2083
|
}, ce({
|
|
2083
2084
|
extra: v(() => [
|
|
2084
2085
|
F(Oe, G({
|
|
2085
2086
|
subject: e(i).item,
|
|
2086
|
-
actions: e(c).filter(({ action:
|
|
2087
|
+
actions: e(c).filter(({ action: h }) => h !== "ui:spawnEdit"),
|
|
2087
2088
|
overlayLayer: 60
|
|
2088
2089
|
}, {
|
|
2089
|
-
onActionClick: m[2] || (m[2] = (
|
|
2090
|
+
onActionClick: m[2] || (m[2] = (h) => n("update:modelValue", !1))
|
|
2090
2091
|
}), {
|
|
2091
2092
|
default: v(({
|
|
2092
|
-
visible:
|
|
2093
|
+
visible: h
|
|
2093
2094
|
}) => [
|
|
2094
2095
|
e(i).item._id ? x((t(), $(Z, {
|
|
2095
2096
|
key: 0,
|
|
2096
2097
|
reactive: "",
|
|
2097
|
-
active:
|
|
2098
|
+
active: h,
|
|
2098
2099
|
icon: "dots-three"
|
|
2099
2100
|
}, null, 8, ["active"])), [
|
|
2100
2101
|
[A]
|
|
@@ -2106,7 +2107,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2106
2107
|
default: v(() => [
|
|
2107
2108
|
F(We, G({
|
|
2108
2109
|
modelValue: e(i).item,
|
|
2109
|
-
"onUpdate:modelValue": m[0] || (m[0] = (
|
|
2110
|
+
"onUpdate:modelValue": m[0] || (m[0] = (h) => e(i).item = h)
|
|
2110
2111
|
}, {
|
|
2111
2112
|
readOnly: o.readOnly,
|
|
2112
2113
|
includeId: o.includeId,
|
|
@@ -2117,12 +2118,12 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2117
2118
|
}, {
|
|
2118
2119
|
focus: "",
|
|
2119
2120
|
onClipboardCopy: p,
|
|
2120
|
-
onAdd: m[1] || (m[1] = (
|
|
2121
|
+
onAdd: m[1] || (m[1] = (h) => h.preventDefault())
|
|
2121
2122
|
}), ce({ _: 2 }, [
|
|
2122
|
-
D(Object.keys(o.$slots).filter((
|
|
2123
|
-
name:
|
|
2123
|
+
D(Object.keys(o.$slots).filter((h) => h.startsWith("field-")), (h) => ({
|
|
2124
|
+
name: h,
|
|
2124
2125
|
fn: v((S) => [
|
|
2125
|
-
C(o.$slots,
|
|
2126
|
+
C(o.$slots, h, de(ge(S)))
|
|
2126
2127
|
])
|
|
2127
2128
|
}))
|
|
2128
2129
|
]), 1040, ["modelValue"])
|
|
@@ -2141,7 +2142,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2141
2142
|
fn: v(() => [
|
|
2142
2143
|
F(re, {
|
|
2143
2144
|
variant: "transparent",
|
|
2144
|
-
onClick:
|
|
2145
|
+
onClick: b
|
|
2145
2146
|
}, {
|
|
2146
2147
|
default: v(() => [
|
|
2147
2148
|
Q(k(e(d)("action.cancel", { capitalize: !0 })), 1)
|
|
@@ -2200,7 +2201,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2200
2201
|
}, ua = { key: 0 }, ca = { key: 1 }, da = { key: 0 }, pa = ["checked"], _a = {
|
|
2201
2202
|
key: 1,
|
|
2202
2203
|
style: { "text-align": "right" }
|
|
2203
|
-
}, ma = { key: 2 }, fa = { key: 3 }, va = ["onClick"], ya = { key: 0 },
|
|
2204
|
+
}, ma = { key: 2 }, fa = { key: 3 }, va = ["onClick"], ya = { key: 0 }, ba = ["value"], ha = { class: "table__cell-mobile-label" }, $a = {
|
|
2204
2205
|
key: 0,
|
|
2205
2206
|
class: "table__cell-container"
|
|
2206
2207
|
}, ga = {
|
|
@@ -2231,34 +2232,34 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2231
2232
|
const l = u, n = r, a = qe(), i = l.collection || Fe(), c = i ? ie(typeof i == "string" ? i : i.value) : null, _ = W({
|
|
2232
2233
|
get: () => c == null ? void 0 : c.selected,
|
|
2233
2234
|
set: (m) => c == null ? void 0 : c.$actions.selectManyItems(m, !0)
|
|
2234
|
-
}), d = (m, A) => m != null && m.button ? typeof m.button == "object" ? Ye(A, m.button).satisfied : m.button : !1,
|
|
2235
|
+
}), d = (m, A) => m != null && m.button ? typeof m.button == "object" ? Ye(A, m.button).satisfied : m.button : !1, b = (m) => {
|
|
2235
2236
|
var A;
|
|
2236
|
-
return !a.value.xl || !((A = l.layout) != null && A.actions) || !l.actions ? [] : l.actions.filter((
|
|
2237
|
-
const S = l.layout.actions[
|
|
2237
|
+
return !a.value.xl || !((A = l.layout) != null && A.actions) || !l.actions ? [] : l.actions.filter((h) => {
|
|
2238
|
+
const S = l.layout.actions[h.action];
|
|
2238
2239
|
return d(S, m);
|
|
2239
2240
|
});
|
|
2240
2241
|
}, p = (m) => {
|
|
2241
2242
|
var A;
|
|
2242
|
-
return l.actions ? !a.value.xl || !((A = l.layout) != null && A.actions) ? l.actions : l.actions.filter((
|
|
2243
|
-
const S = l.layout.actions[
|
|
2244
|
-
if (
|
|
2243
|
+
return l.actions ? !a.value.xl || !((A = l.layout) != null && A.actions) ? l.actions : l.actions.filter((h) => {
|
|
2244
|
+
const S = l.layout.actions[h.action];
|
|
2245
|
+
if (h.roles) {
|
|
2245
2246
|
const j = ie("user");
|
|
2246
|
-
if (!Vt(
|
|
2247
|
+
if (!Vt(h.roles, j.currentUser.roles))
|
|
2247
2248
|
return !1;
|
|
2248
2249
|
}
|
|
2249
2250
|
return !d(S, m);
|
|
2250
2251
|
}) : [];
|
|
2251
2252
|
}, o = (m, A) => {
|
|
2252
2253
|
var j, P;
|
|
2253
|
-
const
|
|
2254
|
+
const h = [], S = (P = (j = l.layout) == null ? void 0 : j.actions) == null ? void 0 : P[A.action];
|
|
2254
2255
|
return S != null && S.if && (Ye(
|
|
2255
2256
|
m,
|
|
2256
2257
|
S.if
|
|
2257
|
-
).satisfied ||
|
|
2258
|
+
).satisfied || h.push("display: none;")), h.join("");
|
|
2258
2259
|
};
|
|
2259
2260
|
return (m, A) => {
|
|
2260
2261
|
var S, j, P;
|
|
2261
|
-
const
|
|
2262
|
+
const h = oe("clickable");
|
|
2262
2263
|
return m.columns && Object.keys(m.columns).length > 0 || m.$slots.thead ? (t(), s("table", ra, [
|
|
2263
2264
|
m.$slots.thead ? (t(), s("thead", ua, [
|
|
2264
2265
|
C(m.$slots, "thead", {}, void 0, !0)
|
|
@@ -2292,7 +2293,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2292
2293
|
"onUpdate:modelValue": A[1] || (A[1] = (w) => _.value = w),
|
|
2293
2294
|
type: "checkbox",
|
|
2294
2295
|
value: B._id
|
|
2295
|
-
}, null, 8,
|
|
2296
|
+
}, null, 8, ba), [
|
|
2296
2297
|
[Bt, _.value]
|
|
2297
2298
|
])
|
|
2298
2299
|
])) : y("", !0),
|
|
@@ -2301,7 +2302,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2301
2302
|
return t(), s("td", {
|
|
2302
2303
|
key: `column-${B._id}-${V}`
|
|
2303
2304
|
}, [
|
|
2304
|
-
I("div",
|
|
2305
|
+
I("div", ha, k(te.description || e(L)(w)), 1),
|
|
2305
2306
|
`row-${w}` in m.$slots ? (t(), s("div", $a, [
|
|
2306
2307
|
C(m.$slots, `row-${w}`, G({ ref_for: !0 }, {
|
|
2307
2308
|
store: e(c),
|
|
@@ -2379,12 +2380,12 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2379
2380
|
}), 128)),
|
|
2380
2381
|
(R = m.actions) != null && R.length && e(a).md ? (t(), s("td", Ra, [
|
|
2381
2382
|
I("div", La, [
|
|
2382
|
-
(t(!0), s(N, null, D(
|
|
2383
|
+
(t(!0), s(N, null, D(b(B), (w) => (t(), $(re, {
|
|
2383
2384
|
key: `action-${w.action}`,
|
|
2384
2385
|
small: "",
|
|
2385
2386
|
variant: "transparent",
|
|
2386
2387
|
icon: w.icon,
|
|
2387
|
-
style:
|
|
2388
|
+
style: he(o(B, w)),
|
|
2388
2389
|
onClick: (te) => w.click(B)
|
|
2389
2390
|
}, {
|
|
2390
2391
|
default: v(() => [
|
|
@@ -2407,7 +2408,7 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2407
2408
|
active: w,
|
|
2408
2409
|
icon: "dots-three"
|
|
2409
2410
|
}, null, 8, ["active"]), [
|
|
2410
|
-
[
|
|
2411
|
+
[h]
|
|
2411
2412
|
])
|
|
2412
2413
|
]),
|
|
2413
2414
|
_: 2
|
|
@@ -2416,9 +2417,9 @@ const We = /* @__PURE__ */ K(oa, [["__scopeId", "data-v-e02fe7fe"]]), aa = /* @_
|
|
|
2416
2417
|
])) : (Y = m.actions) != null && Y.length ? (t(), s("td", za, [
|
|
2417
2418
|
I("div", {
|
|
2418
2419
|
class: "table__mobile-actions-grid",
|
|
2419
|
-
style:
|
|
2420
|
+
style: he(`grid-template-columns: repeat(${b(B).length + (p(B).length ? 1 : 0)}, 1fr);`)
|
|
2420
2421
|
}, [
|
|
2421
|
-
(t(!0), s(N, null, D(
|
|
2422
|
+
(t(!0), s(N, null, D(b(B), (w) => (t(), $(ve, {
|
|
2422
2423
|
key: `action-${w.action}`,
|
|
2423
2424
|
class: "table__mobile-actions-button",
|
|
2424
2425
|
onClick: (te) => w.click(B)
|
|
@@ -2551,11 +2552,11 @@ const Ga = /* @__PURE__ */ K(Qa, [["__scopeId", "data-v-438c4aed"]]), Wa = { key
|
|
|
2551
2552
|
actions: i.individualActions
|
|
2552
2553
|
}), {
|
|
2553
2554
|
default: v(({
|
|
2554
|
-
visible:
|
|
2555
|
+
visible: b
|
|
2555
2556
|
}) => [
|
|
2556
2557
|
x(F(Z, {
|
|
2557
2558
|
reactive: "",
|
|
2558
|
-
active:
|
|
2559
|
+
active: b,
|
|
2559
2560
|
icon: "dots-three-vertical"
|
|
2560
2561
|
}, null, 8, ["active"]), [
|
|
2561
2562
|
[_]
|
|
@@ -2565,12 +2566,12 @@ const Ga = /* @__PURE__ */ K(Qa, [["__scopeId", "data-v-438c4aed"]]), Wa = { key
|
|
|
2565
2566
|
}, 1040)) : y("", !0)
|
|
2566
2567
|
]),
|
|
2567
2568
|
default: v(() => {
|
|
2568
|
-
var
|
|
2569
|
+
var b;
|
|
2569
2570
|
return [
|
|
2570
2571
|
F(He, {
|
|
2571
2572
|
alt: "Item picture",
|
|
2572
2573
|
expandable: "",
|
|
2573
|
-
url: (
|
|
2574
|
+
url: (b = a(d[e(l).picture])) == null ? void 0 : b.link,
|
|
2574
2575
|
meta: a(d[e(l).picture])
|
|
2575
2576
|
}, null, 8, ["url", "meta"])
|
|
2576
2577
|
];
|
|
@@ -2580,12 +2581,12 @@ const Ga = /* @__PURE__ */ K(Qa, [["__scopeId", "data-v-438c4aed"]]), Wa = { key
|
|
|
2580
2581
|
e(l).badge && Array.isArray(d[e(l).badge]) ? {
|
|
2581
2582
|
name: "badge",
|
|
2582
2583
|
fn: v(() => [
|
|
2583
|
-
(t(!0), s(N, null, D(d[e(l).badge], (
|
|
2584
|
-
key: `${d._id}-${
|
|
2584
|
+
(t(!0), s(N, null, D(d[e(l).badge], (b) => (t(), $($e, {
|
|
2585
|
+
key: `${d._id}-${b}`,
|
|
2585
2586
|
large: ""
|
|
2586
2587
|
}, {
|
|
2587
2588
|
default: v(() => [
|
|
2588
|
-
Q(k(e(l).translateBadge ? e(L)(
|
|
2589
|
+
Q(k(e(l).translateBadge ? e(L)(b) : b), 1)
|
|
2589
2590
|
]),
|
|
2590
2591
|
_: 2
|
|
2591
2592
|
}, 1024))), 128))
|
|
@@ -2625,7 +2626,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2625
2626
|
}, Na = { class: "crud__actions" }, xa = { class: "crud__context-badge" }, el = /* @__PURE__ */ Ja(() => /* @__PURE__ */ I("div", null, "Filtros", -1)), tl = { key: 0 }, nl = {
|
|
2626
2627
|
key: 3,
|
|
2627
2628
|
class: "crud__pagination"
|
|
2628
|
-
},
|
|
2629
|
+
}, bt = 30, ol = /* @__PURE__ */ E({
|
|
2629
2630
|
__name: "aeria-crud",
|
|
2630
2631
|
props: {
|
|
2631
2632
|
collection: {},
|
|
@@ -2643,11 +2644,11 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2643
2644
|
setup(u, { emit: r }) {
|
|
2644
2645
|
const l = u, n = r, a = Ae(), i = kt({
|
|
2645
2646
|
delay: 600
|
|
2646
|
-
}), c = ie("meta"), _ = qe(), { reachedEnd: d, detach:
|
|
2647
|
+
}), c = ie("meta"), _ = qe(), { reachedEnd: d, detach: b } = Ze(null, {
|
|
2647
2648
|
antecipate: 600
|
|
2648
2649
|
}), p = !_.value.md || l.scrollPagination;
|
|
2649
2650
|
p && ue(d, (V) => {
|
|
2650
|
-
V && o.pagination.recordsTotal > o.items.length &&
|
|
2651
|
+
V && o.pagination.recordsTotal > o.items.length && h.value < bt && (h.value += 1, j());
|
|
2651
2652
|
});
|
|
2652
2653
|
const o = ie(l.collection);
|
|
2653
2654
|
sa(o, {
|
|
@@ -2655,7 +2656,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2655
2656
|
});
|
|
2656
2657
|
const m = Pe(), A = l.action ? e(l.action) : Ht(o, a, m);
|
|
2657
2658
|
Le.value = A[0], yt.value = A[1];
|
|
2658
|
-
const
|
|
2659
|
+
const h = J(0), S = J(!1), j = async (V) => {
|
|
2659
2660
|
o.activeFilters = Object.assign({}, (V == null ? void 0 : V.filters) || o.$filters), Object.assign(o.activeFilters, o.filtersPreset);
|
|
2660
2661
|
const T = {
|
|
2661
2662
|
filters: o.activeFilters,
|
|
@@ -2663,12 +2664,12 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2663
2664
|
offset: o.pagination.offset,
|
|
2664
2665
|
project: o.preferredTableProperties.length > 0 ? o.preferredTableProperties : o.description.table || Object.keys(o.properties)
|
|
2665
2666
|
};
|
|
2666
|
-
|
|
2667
|
+
h.value > 0 && (T.limit = 15, T.offset = h.value * T.limit), o.description.tableMeta && (T.project = T.project.concat(o.description.tableMeta)), V && Object.assign(T, V), o.loading.getAll = !0;
|
|
2667
2668
|
const { error: ae, result: le } = await o.$actions.retrieveItems(T);
|
|
2668
2669
|
if (ae)
|
|
2669
2670
|
return;
|
|
2670
2671
|
const { data: ne, pagination: se } = le;
|
|
2671
|
-
o.pagination.recordsCount = se.recordsCount, o.pagination.recordsTotal = se.recordsTotal,
|
|
2672
|
+
o.pagination.recordsCount = se.recordsCount, o.pagination.recordsTotal = se.recordsTotal, h.value === 0 && o.items.splice(0), o.items.push(...ne), o.loading.getAll = !1, S.value = !0;
|
|
2672
2673
|
}, P = async (V) => {
|
|
2673
2674
|
a.push(Me(a.currentRoute.value, {
|
|
2674
2675
|
query: {
|
|
@@ -2703,7 +2704,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2703
2704
|
}
|
|
2704
2705
|
}), j({
|
|
2705
2706
|
offset: 0
|
|
2706
|
-
})) : (o.filters = Ce(o.freshFilters),
|
|
2707
|
+
})) : (o.filters = Ce(o.freshFilters), h.value = 0, j())));
|
|
2707
2708
|
ue(() => o.textQuery, (V) => {
|
|
2708
2709
|
R(V);
|
|
2709
2710
|
});
|
|
@@ -2711,7 +2712,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2711
2712
|
V.currentLayout = V.currentLayout === "tabular" ? V.description.layout.name : "tabular";
|
|
2712
2713
|
};
|
|
2713
2714
|
wt(() => {
|
|
2714
|
-
o.$actions.clearFilters(), o.textQuery = "",
|
|
2715
|
+
o.$actions.clearFilters(), o.textQuery = "", b();
|
|
2715
2716
|
}), ue(() => yt.value, async (V) => {
|
|
2716
2717
|
var le;
|
|
2717
2718
|
const T = Ce(V);
|
|
@@ -2930,7 +2931,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2930
2931
|
])) : y("", !0),
|
|
2931
2932
|
x((t(), s("div", null, [
|
|
2932
2933
|
e(o).itemsCount === 0 && !e(o).loading.getAll && S.value && (e(B) || V.$slots.empty) ? (t(), s("div", tl, [
|
|
2933
|
-
e(B) ? (t(), $(
|
|
2934
|
+
e(B) ? (t(), $(be(e(B)), de(G({ key: 0 }, {
|
|
2934
2935
|
collection: e(o).$id
|
|
2935
2936
|
})), {
|
|
2936
2937
|
default: v(() => [
|
|
@@ -2953,7 +2954,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2953
2954
|
})), void 0, !0)
|
|
2954
2955
|
])) : V.$slots.component ? C(V.$slots, "component", de(G({ key: 1 }, {
|
|
2955
2956
|
store: e(o)
|
|
2956
|
-
})), void 0, !0) : (t(), $(
|
|
2957
|
+
})), void 0, !0) : (t(), $(be(e(Ya)(((f = V.layout) == null ? void 0 : f.name) || e(o).$currentLayout)), G({ key: 2 }, {
|
|
2957
2958
|
individualActions: w.value,
|
|
2958
2959
|
layoutOptions: ((M = V.layout) == null ? void 0 : M.options) || e(o).layout.options,
|
|
2959
2960
|
componentProps: V.componentProps
|
|
@@ -2975,7 +2976,7 @@ const Ve = J(!1), Le = J((...u) => null), yt = J(), Ja = (u) => (De("data-v-21ee
|
|
|
2975
2976
|
} : void 0
|
|
2976
2977
|
]), 1040, ["component-name"]))
|
|
2977
2978
|
])), [
|
|
2978
|
-
[le, (!e(p) ||
|
|
2979
|
+
[le, (!e(p) || h.value === bt) && e(o).loading.getAll]
|
|
2979
2980
|
]),
|
|
2980
2981
|
!e(o).loading.getAll && e(o).itemsCount > 0 ? (t(), s("div", nl, [
|
|
2981
2982
|
F(Fn, {
|
|
@@ -3006,7 +3007,7 @@ const Ul = /* @__PURE__ */ K(ol, [["__scopeId", "data-v-21eeb8fd"]]), al = { cla
|
|
|
3006
3007
|
footer: v(() => [
|
|
3007
3008
|
I("div", {
|
|
3008
3009
|
class: "prompt__actions",
|
|
3009
|
-
style:
|
|
3010
|
+
style: he(`grid-template-columns: repeat(${n.actions.length}, 1fr)`)
|
|
3010
3011
|
}, [
|
|
3011
3012
|
(t(!0), s(N, null, D(n.actions, (i, c) => (t(), $(ve, {
|
|
3012
3013
|
key: `action-${c}`,
|
|
@@ -3092,7 +3093,7 @@ const cl = /* @__PURE__ */ K(ul, [["__scopeId", "data-v-21bbe178"]]), dl = ["inn
|
|
|
3092
3093
|
default: v(() => [
|
|
3093
3094
|
F(i, null, {
|
|
3094
3095
|
default: v(({ Component: c }) => [
|
|
3095
|
-
(t(), $(
|
|
3096
|
+
(t(), $(be(c), null, ce({ _: 2 }, [
|
|
3096
3097
|
D(Object.keys(n.$slots), (_) => ({
|
|
3097
3098
|
name: _,
|
|
3098
3099
|
fn: v(() => [
|
|
@@ -3122,7 +3123,7 @@ const cl = /* @__PURE__ */ K(ul, [["__scopeId", "data-v-21bbe178"]]), dl = ["inn
|
|
|
3122
3123
|
style: { "white-space": "pre-wrap" },
|
|
3123
3124
|
innerHTML: e(r).modal.body
|
|
3124
3125
|
}, null, 8, dl)) : y("", !0),
|
|
3125
|
-
e(r).modal.component ? (t(), $(
|
|
3126
|
+
e(r).modal.component ? (t(), $(be(e(r).modal.component), { key: 1 })) : y("", !0)
|
|
3126
3127
|
]),
|
|
3127
3128
|
_: 1
|
|
3128
3129
|
}, 16, ["modelValue"]),
|
|
@@ -3160,7 +3161,7 @@ function yl(u, r) {
|
|
|
3160
3161
|
]))), 128))
|
|
3161
3162
|
]);
|
|
3162
3163
|
}
|
|
3163
|
-
const Hl = /* @__PURE__ */ K(fl, [["render", yl], ["__scopeId", "data-v-3cfef7fb"]]),
|
|
3164
|
+
const Hl = /* @__PURE__ */ K(fl, [["render", yl], ["__scopeId", "data-v-3cfef7fb"]]), bl = { class: "tabs" }, hl = {
|
|
3164
3165
|
key: 0,
|
|
3165
3166
|
class: "tabs__horizontal"
|
|
3166
3167
|
}, $l = {
|
|
@@ -3200,9 +3201,9 @@ const Hl = /* @__PURE__ */ K(fl, [["render", yl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3200
3201
|
}));
|
|
3201
3202
|
};
|
|
3202
3203
|
return (_, d) => {
|
|
3203
|
-
const
|
|
3204
|
-
return t(), s("div",
|
|
3205
|
-
e(a).md && !_.dropdown ? (t(), s("div",
|
|
3204
|
+
const b = oe("clickable");
|
|
3205
|
+
return t(), s("div", bl, [
|
|
3206
|
+
e(a).md && !_.dropdown ? (t(), s("div", hl, [
|
|
3206
3207
|
_.$slots.default ? (t(), s("div", $l, [
|
|
3207
3208
|
C(_.$slots, "default", {}, void 0, !0)
|
|
3208
3209
|
])) : y("", !0),
|
|
@@ -3231,7 +3232,7 @@ const Hl = /* @__PURE__ */ K(fl, [["render", yl], ["__scopeId", "data-v-3cfef7fb
|
|
|
3231
3232
|
]),
|
|
3232
3233
|
_: 2
|
|
3233
3234
|
}, 1032, ["active"])), [
|
|
3234
|
-
[
|
|
3235
|
+
[b]
|
|
3235
3236
|
])
|
|
3236
3237
|
]),
|
|
3237
3238
|
_: 2
|
|
@@ -3270,18 +3271,18 @@ const Ol = /* @__PURE__ */ K(Cl, [["__scopeId", "data-v-a20914ab"]]), Il = E({
|
|
|
3270
3271
|
},
|
|
3271
3272
|
setup(u) {
|
|
3272
3273
|
const r = u, n = Ae().currentRoute, a = Pe(), i = W(() => r.collection ? Ke(r.collection, a) : typeof n.value.meta.collection == "string" ? Ke(n.value.meta.collection, a) : typeof n.value.params.collection == "string" ? Ke(n.value.params.collection, a) : null), c = async (_, d) => {
|
|
3273
|
-
const { error:
|
|
3274
|
+
const { error: b, result: p } = await d.$functions[_.badgeFunction]({
|
|
3274
3275
|
filters: _.filters
|
|
3275
3276
|
});
|
|
3276
|
-
return
|
|
3277
|
+
return b ? 0 : p;
|
|
3277
3278
|
};
|
|
3278
3279
|
return (_, d) => i.value && i.value.description.filtersPresets ? (t(), $(Ol, {
|
|
3279
3280
|
key: 0,
|
|
3280
3281
|
dropdown: "",
|
|
3281
3282
|
query: "section"
|
|
3282
3283
|
}, ce({ _: 2 }, [
|
|
3283
|
-
D(Object.entries(i.value.description.filtersPresets), ([
|
|
3284
|
-
name:
|
|
3284
|
+
D(Object.entries(i.value.description.filtersPresets), ([b, p]) => ({
|
|
3285
|
+
name: b,
|
|
3285
3286
|
fn: v(() => [
|
|
3286
3287
|
I("div", {
|
|
3287
3288
|
class: "topbar__preset",
|
|
@@ -3292,10 +3293,10 @@ const Ol = /* @__PURE__ */ K(Cl, [["__scopeId", "data-v-a20914ab"]]), Il = E({
|
|
|
3292
3293
|
icon: p.icon
|
|
3293
3294
|
}, {
|
|
3294
3295
|
default: v(() => [
|
|
3295
|
-
Q(k(p.label || e(L)(
|
|
3296
|
+
Q(k(p.label || e(L)(b, { plural: !0 })), 1)
|
|
3296
3297
|
]),
|
|
3297
3298
|
_: 2
|
|
3298
|
-
}, 1032, ["icon"])) : (t(), s("div", Bl, k(p.label || e(L)(
|
|
3299
|
+
}, 1032, ["icon"])) : (t(), s("div", Bl, k(p.label || e(L)(b, { plural: !0 })), 1)),
|
|
3299
3300
|
p.badgeFunction ? (t(), $($e, { key: 2 }, {
|
|
3300
3301
|
default: v(() => [
|
|
3301
3302
|
F(e(Il), {
|
|
@@ -3368,7 +3369,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3368
3369
|
{
|
|
3369
3370
|
path: "signin",
|
|
3370
3371
|
name: "/user/signin",
|
|
3371
|
-
component: () => import("./signin-
|
|
3372
|
+
component: () => import("./signin-ebb7e29e.js"),
|
|
3372
3373
|
meta: {
|
|
3373
3374
|
title: "Autenticação"
|
|
3374
3375
|
}
|
|
@@ -3376,7 +3377,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3376
3377
|
{
|
|
3377
3378
|
path: "signup",
|
|
3378
3379
|
name: "/user/signup",
|
|
3379
|
-
component: () => import("./signup-
|
|
3380
|
+
component: () => import("./signup-02b1329c.js"),
|
|
3380
3381
|
meta: {
|
|
3381
3382
|
title: "Registro"
|
|
3382
3383
|
}
|
|
@@ -3384,7 +3385,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3384
3385
|
{
|
|
3385
3386
|
path: "activation",
|
|
3386
3387
|
name: "/user/activation",
|
|
3387
|
-
component: () => import("./activation-
|
|
3388
|
+
component: () => import("./activation-c75876f9.js"),
|
|
3388
3389
|
meta: {
|
|
3389
3390
|
title: "Ativação"
|
|
3390
3391
|
}
|
|
@@ -3406,7 +3407,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3406
3407
|
name: "/dashboard/:collection",
|
|
3407
3408
|
props: !0,
|
|
3408
3409
|
components: {
|
|
3409
|
-
default: () => import("./index-
|
|
3410
|
+
default: () => import("./index-99ed76d0.js"),
|
|
3410
3411
|
topbar: () => Promise.resolve().then(() => Tl)
|
|
3411
3412
|
},
|
|
3412
3413
|
meta: {
|
|
@@ -3418,7 +3419,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3418
3419
|
name: "/dashboard/:collection/:id",
|
|
3419
3420
|
props: !0,
|
|
3420
3421
|
components: {
|
|
3421
|
-
default: () => import("./_id_-
|
|
3422
|
+
default: () => import("./_id_-5a99fcd7.js")
|
|
3422
3423
|
},
|
|
3423
3424
|
meta: {
|
|
3424
3425
|
title: "%viewTitle%"
|
|
@@ -3436,7 +3437,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3436
3437
|
children: [
|
|
3437
3438
|
{
|
|
3438
3439
|
path: "profile",
|
|
3439
|
-
component: () => import("./index-
|
|
3440
|
+
component: () => import("./index-5ead2930.js"),
|
|
3440
3441
|
meta: {
|
|
3441
3442
|
title: "Meu perfil",
|
|
3442
3443
|
icon: "user-square"
|
|
@@ -3445,7 +3446,7 @@ const Sl = /* @__PURE__ */ K(wl, [["__scopeId", "data-v-85c3b087"]]), Tl = /* @_
|
|
|
3445
3446
|
{
|
|
3446
3447
|
path: "changepass",
|
|
3447
3448
|
name: "/dashboard/user/changepass",
|
|
3448
|
-
component: () => import("./index-
|
|
3449
|
+
component: () => import("./index-b1767513.js"),
|
|
3449
3450
|
meta: {
|
|
3450
3451
|
title: "Mudar senha",
|
|
3451
3452
|
icon: "lock"
|