@aeria-ui/ui 0.0.174 → 0.0.176

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.
@@ -1,62 +1,62 @@
1
- import { defineComponent as z, ref as J, resolveDirective as P, createElementBlock as l, openBlock as t, normalizeClass as Q, Fragment as Y, renderList as E, withDirectives as K, createCommentVNode as b, createTextVNode as D, toDisplayString as A, unref as e, renderSlot as I, withModifiers as Ie, inject as ue, computed as W, createElementVNode as S, mergeProps as M, createBlock as V, withCtx as h, resolveDynamicComponent as me, useCssVars as et, normalizeProps as le, guardReactiveProps as _e, Teleport as Ee, createVNode as L, onMounted as Ue, watch as ne, vModelDynamic as tt, onBeforeMount as Je, normalizeStyle as ve, provide as fe, createSlots as ie, vModelCheckbox as ot, onUnmounted as nt, resolveComponent as at, Suspense as lt, useSlots as st, h as it } from "vue";
2
- import { t as j, useI18n as rt } from "@aeria-ui/i18n";
3
- import { INSTANCE_VARS_SYMBOL as ut, useScrollObserver as He, useBreakpoints as Se, useMask as dt, PAGINATION_PER_PAGE_DEFAULTS as ct, API_URL as Ze, request as pt, useDebounce as Pe, convertToSearchQuery as mt, useParentCollectionStore as Ae, useCollectionStore as ft, useAction as vt, convertFromSearchQuery as yt, usePasswordPolicy as _t } from "@aeria-ui/core";
4
- import { arraysIntersect as Fe, deepClone as ge, getReferenceProperty as re, convertConditionToQuery as ht, freshItem as bt, isRequired as Ge, evaluateCondition as Re, deepMerge as Be } from "@aeriajs/common";
5
- import { useStore as te, getStoreId as we, useParentStore as qe, STORE_ID as Te, getGlobalStateManager as De } from "@aeria-ui/state-management";
6
- import { useRouter as Ve } from "vue-router";
7
- import { isDocumentComplete as $t, getObjectKey as gt } from "@aeria-ui/utils";
8
- const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1
+ import { defineComponent as F, ref as Z, resolveDirective as N, createElementBlock as l, openBlock as t, normalizeClass as Q, Fragment as X, renderList as E, withDirectives as J, createCommentVNode as b, createTextVNode as D, toDisplayString as C, unref as e, renderSlot as A, withModifiers as Ie, inject as ue, computed as Y, createElementVNode as I, mergeProps as z, createBlock as k, withCtx as h, resolveDynamicComponent as pe, useCssVars as xe, normalizeProps as ne, guardReactiveProps as _e, Teleport as Ue, createVNode as M, onMounted as He, watch as oe, vModelDynamic as et, onBeforeMount as Ze, normalizeStyle as fe, provide as me, createSlots as le, vModelCheckbox as tt, onUnmounted as ot, resolveComponent as nt, Suspense as at, useSlots as lt, h as st } from "vue";
2
+ import { t as j, useI18n as it } from "@aeria-ui/i18n";
3
+ import { INSTANCE_VARS_SYMBOL as rt, useScrollObserver as De, useBreakpoints as Se, useMask as ut, PAGINATION_PER_PAGE_DEFAULTS as dt, API_URL as Pe, request as ct, useDebounce as Fe, convertToSearchQuery as pt, useParentCollectionStore as Ae, useCollectionStore as mt, useAction as ft, convertFromSearchQuery as vt, usePasswordPolicy as yt } from "@aeria-ui/core";
4
+ import { arraysIntersect as Ee, deepClone as ke, getReferenceProperty as se, convertConditionToQuery as _t, freshItem as ht, isRequired as We, evaluateCondition as Re, deepMerge as Be } from "@aeriajs/common";
5
+ import { useStore as te, getStoreId as we, useParentStore as qe, STORE_ID as Te, getGlobalStateManager as Qe } from "@aeria-ui/state-management";
6
+ import { useRouter as Ce } from "vue-router";
7
+ import { isDocumentComplete as bt, getObjectKey as $t } from "@aeria-ui/utils";
8
+ const gt = ["onClick"], kt = { key: 0 }, Vt = {
9
9
  key: 0,
10
10
  class: "accordion__content"
11
- }, Ot = /* @__PURE__ */ z({
11
+ }, Ct = /* @__PURE__ */ F({
12
12
  __name: "aeria-accordion",
13
13
  props: {
14
14
  enumerate: { type: Boolean },
15
15
  noPadding: { type: Boolean },
16
16
  headers: {}
17
17
  },
18
- setup(p) {
19
- const i = J(null), o = (n) => typeof n == "string" ? n : n.title;
18
+ setup(m) {
19
+ const i = Z(null), o = (n) => typeof n == "string" ? n : n.title;
20
20
  return (n, a) => {
21
- const d = P("clickable");
21
+ const d = N("clickable");
22
22
  return t(), l("div", {
23
23
  class: Q({
24
24
  accordion: !0,
25
25
  "accordion--padded": !n.noPadding
26
26
  })
27
27
  }, [
28
- (t(!0), l(Y, null, E(Object.keys(n.$slots).filter((u) => u !== "default"), (u, m) => (t(), l("div", {
28
+ (t(!0), l(X, null, E(Object.keys(n.$slots).filter((u) => u !== "default"), (u, f) => (t(), l("div", {
29
29
  key: u,
30
30
  class: "accordion__slot"
31
31
  }, [
32
- K((t(), l("div", {
32
+ J((t(), l("div", {
33
33
  class: "accordion__header",
34
- onClick: (c) => i.value === u ? i.value = null : i.value = u
34
+ onClick: (p) => i.value === u ? i.value = null : i.value = u
35
35
  }, [
36
- n.enumerate ? (t(), l("span", Vt, A(m + 1) + ". ", 1)) : b("", !0),
37
- D(" " + A(n.headers[u] ? o(n.headers[u]) : e(j)(u)), 1)
38
- ], 8, kt)), [
36
+ n.enumerate ? (t(), l("span", kt, C(f + 1) + ". ", 1)) : b("", !0),
37
+ D(" " + C(n.headers[u] ? o(n.headers[u]) : e(j)(u)), 1)
38
+ ], 8, gt)), [
39
39
  [d]
40
40
  ]),
41
- i.value === u ? (t(), l("div", Ct, [
42
- I(n.$slots, u, {}, void 0, !0)
41
+ i.value === u ? (t(), l("div", Vt, [
42
+ A(n.$slots, u, {}, void 0, !0)
43
43
  ])) : b("", !0)
44
44
  ]))), 128))
45
45
  ], 2);
46
46
  };
47
47
  }
48
- }), U = (p, i) => {
49
- const o = p.__vccOpts || p;
48
+ }), U = (m, i) => {
49
+ const o = m.__vccOpts || m;
50
50
  for (const [n, a] of i)
51
51
  o[n] = a;
52
52
  return o;
53
- }, rl = /* @__PURE__ */ U(Ot, [["__scopeId", "data-v-3ea933d4"]]), At = /* @__PURE__ */ z({
53
+ }, il = /* @__PURE__ */ U(Ct, [["__scopeId", "data-v-3ea933d4"]]), Ot = /* @__PURE__ */ F({
54
54
  __name: "aeria-badge",
55
55
  props: {
56
56
  large: { type: Boolean },
57
57
  alt: { type: Boolean }
58
58
  },
59
- setup(p) {
59
+ setup(m) {
60
60
  return (i, o) => (t(), l("div", {
61
61
  class: Q([
62
62
  "badge",
@@ -64,17 +64,17 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
64
64
  { "badge--alt": i.alt }
65
65
  ])
66
66
  }, [
67
- I(i.$slots, "default", {}, void 0, !0)
67
+ A(i.$slots, "default", {}, void 0, !0)
68
68
  ], 2));
69
69
  }
70
- }), ye = /* @__PURE__ */ U(At, [["__scopeId", "data-v-4cbce7ef"]]), It = /* @__PURE__ */ z({
70
+ }), ye = /* @__PURE__ */ U(Ot, [["__scopeId", "data-v-4cbce7ef"]]), At = /* @__PURE__ */ F({
71
71
  __name: "aeria-bare-button",
72
72
  props: {
73
73
  disabled: { type: Boolean }
74
74
  },
75
75
  emits: ["click"],
76
- setup(p, { emit: i }) {
77
- const o = p, n = i, a = (d) => {
76
+ setup(m, { emit: i }) {
77
+ const o = m, n = i, a = (d) => {
78
78
  o.disabled || n("click", d);
79
79
  };
80
80
  return (d, u) => (t(), l("button", {
@@ -84,13 +84,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
84
84
  ]),
85
85
  onClick: Ie(a, ["prevent"])
86
86
  }, [
87
- I(d.$slots, "default", {}, void 0, !0)
87
+ A(d.$slots, "default", {}, void 0, !0)
88
88
  ], 2));
89
89
  }
90
- }), ce = /* @__PURE__ */ U(It, [["__scopeId", "data-v-1883f6a0"]]), Bt = ["href"], St = {
90
+ }), de = /* @__PURE__ */ U(At, [["__scopeId", "data-v-1883f6a0"]]), It = ["href"], Bt = {
91
91
  key: 0,
92
92
  "data-component": "icon-label"
93
- }, wt = /* @__PURE__ */ z({
93
+ }, St = /* @__PURE__ */ F({
94
94
  __name: "aeria-icon",
95
95
  props: {
96
96
  icon: {},
@@ -100,8 +100,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
100
100
  iconRight: { type: Boolean },
101
101
  active: { type: Boolean }
102
102
  },
103
- setup(p) {
104
- const i = p, o = ue(ut, {}), n = typeof i.reactive == "boolean" ? i.reactive : ue("iconReactive", !1), a = W(() => i.icon?.includes(":") ? i.icon : `regular:${i.icon}`);
103
+ setup(m) {
104
+ const i = m, o = ue(rt, {}), n = typeof i.reactive == "boolean" ? i.reactive : ue("iconReactive", !1), a = Y(() => i.icon?.includes(":") ? i.icon : `regular:${i.icon}`);
105
105
  return (d, u) => (t(), l("a", {
106
106
  class: Q([
107
107
  "icon",
@@ -110,13 +110,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
110
110
  d.$slots.default ? "icon--centered" : "icon--standalone"
111
111
  ])
112
112
  }, [
113
- S("div", {
113
+ I("div", {
114
114
  class: Q([
115
115
  "icon__icon",
116
116
  { "icon__icon--right": d.iconRight }
117
117
  ])
118
118
  }, [
119
- (t(), l("svg", M({
119
+ (t(), l("svg", z({
120
120
  width: "24",
121
121
  height: "24",
122
122
  viewBox: "0 0 256 256",
@@ -124,20 +124,20 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
124
124
  }, {
125
125
  ...d.fill ? { fill: d.fill } : {}
126
126
  }), [
127
- S("use", {
127
+ I("use", {
128
128
  href: `${e(o).base || "/"}assets/icons.svg#${a.value}`
129
- }, null, 8, Bt)
129
+ }, null, 8, It)
130
130
  ], 16))
131
131
  ], 2),
132
- d.$slots.default ? (t(), l("div", St, [
133
- I(d.$slots, "default", {}, void 0, !0)
132
+ d.$slots.default ? (t(), l("div", Bt, [
133
+ A(d.$slots, "default", {}, void 0, !0)
134
134
  ])) : b("", !0)
135
135
  ], 2));
136
136
  }
137
- }), G = /* @__PURE__ */ U(wt, [["__scopeId", "data-v-263a2782"]]), Tt = { class: "button__content" }, jt = {
137
+ }), G = /* @__PURE__ */ U(St, [["__scopeId", "data-v-263a2782"]]), wt = { class: "button__content" }, Tt = {
138
138
  key: 1,
139
139
  class: "button__content"
140
- }, Rt = /* @__PURE__ */ z({
140
+ }, jt = /* @__PURE__ */ F({
141
141
  __name: "aeria-button",
142
142
  props: {
143
143
  size: {},
@@ -148,8 +148,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
148
148
  disabled: { type: Boolean },
149
149
  loading: { type: Boolean }
150
150
  },
151
- setup(p) {
152
- const i = p, o = ue("buttonVariant", i.variant) || "primary", n = (() => {
151
+ setup(m) {
152
+ const i = m, o = ue("buttonVariant", i.variant) || "primary", n = (() => {
153
153
  switch (!0) {
154
154
  case i.small:
155
155
  return "small";
@@ -158,7 +158,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
158
158
  }
159
159
  return ue("buttonSize", i.size) || "medium";
160
160
  })();
161
- return (a, d) => (t(), V(ce, {
161
+ return (a, d) => (t(), k(de, {
162
162
  class: Q([
163
163
  "button",
164
164
  `button--${e(o)}`,
@@ -168,30 +168,30 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
168
168
  disabled: a.disabled || a.loading
169
169
  }, {
170
170
  default: h(() => [
171
- a.icon ? (t(), V(G, {
171
+ a.icon ? (t(), k(G, {
172
172
  key: 0,
173
173
  icon: a.icon
174
174
  }, {
175
175
  default: h(() => [
176
- S("div", Tt, [
177
- I(a.$slots, "default", {}, void 0, !0)
176
+ I("div", wt, [
177
+ A(a.$slots, "default", {}, void 0, !0)
178
178
  ])
179
179
  ]),
180
180
  _: 3
181
- }, 8, ["icon"])) : (t(), l("div", jt, [
182
- I(a.$slots, "default", {}, void 0, !0)
181
+ }, 8, ["icon"])) : (t(), l("div", Tt, [
182
+ A(a.$slots, "default", {}, void 0, !0)
183
183
  ]))
184
184
  ]),
185
185
  _: 3
186
186
  }, 8, ["class", "disabled"]));
187
187
  }
188
- }), se = /* @__PURE__ */ U(Rt, [["__scopeId", "data-v-e9f582db"]]), Lt = { class: "card__picture" }, qt = { class: "card__footer" }, Mt = { class: "card__footer-upper" }, zt = { class: "card__actions" }, Ft = { class: "card__badge" }, Et = /* @__PURE__ */ z({
188
+ }), ae = /* @__PURE__ */ U(jt, [["__scopeId", "data-v-e9f582db"]]), Rt = { class: "card__picture" }, Lt = { class: "card__footer" }, qt = { class: "card__footer-upper" }, Mt = { class: "card__actions" }, zt = { class: "card__badge" }, Ft = /* @__PURE__ */ F({
189
189
  __name: "aeria-card",
190
190
  props: {
191
191
  inactive: { type: Boolean },
192
192
  horizontal: { type: Boolean }
193
193
  },
194
- setup(p) {
194
+ setup(m) {
195
195
  return (i, o) => (t(), l("div", {
196
196
  class: Q([
197
197
  "card",
@@ -199,31 +199,31 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
199
199
  { "card--horizontal": i.horizontal }
200
200
  ])
201
201
  }, [
202
- S("div", Lt, [
203
- I(i.$slots, "default", {}, void 0, !0)
202
+ I("div", Rt, [
203
+ A(i.$slots, "default", {}, void 0, !0)
204
204
  ]),
205
- S("div", qt, [
206
- S("div", Mt, [
207
- S("div", null, [
208
- I(i.$slots, "footer", {}, void 0, !0)
205
+ I("div", Lt, [
206
+ I("div", qt, [
207
+ I("div", null, [
208
+ A(i.$slots, "footer", {}, void 0, !0)
209
209
  ]),
210
- S("div", zt, [
211
- i.$slots.actions ? I(i.$slots, "actions", { key: 0 }, void 0, !0) : b("", !0)
210
+ I("div", Mt, [
211
+ i.$slots.actions ? A(i.$slots, "actions", { key: 0 }, void 0, !0) : b("", !0)
212
212
  ])
213
213
  ]),
214
- S("div", Ft, [
215
- I(i.$slots, "badge", {}, void 0, !0)
214
+ I("div", zt, [
215
+ A(i.$slots, "badge", {}, void 0, !0)
216
216
  ])
217
217
  ])
218
218
  ], 2));
219
219
  }
220
- }), Ut = /* @__PURE__ */ U(Et, [["__scopeId", "data-v-e7d2c665"]]), Ht = { class: "panel__header-left" }, Dt = {
220
+ }), Et = /* @__PURE__ */ U(Ft, [["__scopeId", "data-v-e7d2c665"]]), Ut = { class: "panel__header-left" }, Ht = {
221
221
  key: 1,
222
222
  class: "panel__header-title"
223
- }, Qt = {
223
+ }, Dt = {
224
224
  key: 2,
225
225
  style: { "margin-left": "auto" }
226
- }, Gt = /* @__PURE__ */ z({
226
+ }, Qt = /* @__PURE__ */ F({
227
227
  __name: "aeria-panel",
228
228
  props: {
229
229
  closeHint: { type: Boolean, default: !1 },
@@ -245,24 +245,24 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
245
245
  overlayLayer: {}
246
246
  },
247
247
  emits: ["update:modelValue", "update:collapsed", "update:closeHint", "overlayClick", "close"],
248
- setup(p, { emit: i }) {
249
- const o = p, n = i, a = J(o.collapsed), d = J(null), { reachedEnd: u } = He(d), m = () => {
248
+ setup(m, { emit: i }) {
249
+ const o = m, n = i, a = Z(o.collapsed), d = Z(null), { reachedEnd: u } = De(d), f = () => {
250
250
  n("update:modelValue", !1), n("close");
251
- }, c = () => {
251
+ }, p = () => {
252
252
  n("overlayClick");
253
253
  }, v = (r) => {
254
254
  n("update:collapsed", r), a.value = r;
255
255
  };
256
256
  return (r, $) => {
257
- const k = P("clickable"), _ = P("loading"), T = P("overlay");
258
- return r.modelValue ? K((t(), l("div", {
257
+ const g = N("clickable"), y = N("loading"), s = N("overlay");
258
+ return r.modelValue ? J((t(), l("div", {
259
259
  key: 0,
260
260
  class: Q([
261
261
  "panel",
262
262
  { "panel--fixed": r.fixedRight }
263
263
  ])
264
264
  }, [
265
- (t(), V(me(
265
+ (t(), k(pe(
266
266
  r.float || r.fixedRight ? "dialog" : "div"
267
267
  ), {
268
268
  "data-component": "panel",
@@ -276,7 +276,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
276
276
  { "panel__content--transparent-mobile": r.transparentMobile },
277
277
  { "panel__content--outer-header": r.outerHeader }
278
278
  ]),
279
- onClick: $[2] || ($[2] = (s) => s.stopPropagation())
279
+ onClick: $[2] || ($[2] = (B) => B.stopPropagation())
280
280
  }, {
281
281
  default: h(() => [
282
282
  r.$slots.header || r.title ? (t(), l("div", {
@@ -287,36 +287,36 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
287
287
  { "panel__header--outer": r.outerHeader }
288
288
  ])
289
289
  }, [
290
- S("div", Ht, [
291
- r.$slots.header ? I(r.$slots, "header", { key: 0 }, void 0, !0) : r.title ? (t(), l("div", Dt, A(r.title), 1)) : b("", !0),
292
- r.$slots.extra ? (t(), l("div", Qt, [
293
- I(r.$slots, "extra", {}, void 0, !0)
290
+ I("div", Ut, [
291
+ r.$slots.header ? A(r.$slots, "header", { key: 0 }, void 0, !0) : r.title ? (t(), l("div", Ht, C(r.title), 1)) : b("", !0),
292
+ r.$slots.extra ? (t(), l("div", Dt, [
293
+ A(r.$slots, "extra", {}, void 0, !0)
294
294
  ])) : b("", !0)
295
295
  ]),
296
- r.collapsible && a.value ? K((t(), V(G, {
296
+ r.collapsible && a.value ? J((t(), k(G, {
297
297
  key: 0,
298
298
  reactive: "",
299
299
  icon: "plus",
300
- onClick: $[0] || ($[0] = (s) => v(!a.value))
300
+ onClick: $[0] || ($[0] = (B) => v(!a.value))
301
301
  }, null, 512)), [
302
- [k]
303
- ]) : r.collapsible && !a.value ? K((t(), V(G, {
302
+ [g]
303
+ ]) : r.collapsible && !a.value ? J((t(), k(G, {
304
304
  key: 1,
305
305
  reactive: "",
306
306
  icon: "minus",
307
- onClick: $[1] || ($[1] = (s) => v(!a.value))
307
+ onClick: $[1] || ($[1] = (B) => v(!a.value))
308
308
  }, null, 512)), [
309
- [k]
310
- ]) : r.closeHint ? K((t(), V(G, {
309
+ [g]
310
+ ]) : r.closeHint ? J((t(), k(G, {
311
311
  key: 2,
312
312
  reactive: "",
313
313
  icon: "x",
314
- onClick: m
314
+ onClick: f
315
315
  }, null, 512)), [
316
- [k]
316
+ [g]
317
317
  ]) : b("", !0)
318
318
  ], 2)) : b("", !0),
319
- a.value ? b("", !0) : K((t(), l("div", {
319
+ a.value ? b("", !0) : J((t(), l("div", {
320
320
  key: 1,
321
321
  ref_key: "body",
322
322
  ref: d,
@@ -326,9 +326,9 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
326
326
  { "panel__body--padded": !r.fill }
327
327
  ])
328
328
  }, [
329
- I(r.$slots, "default", {}, void 0, !0)
329
+ A(r.$slots, "default", {}, void 0, !0)
330
330
  ], 2)), [
331
- [_, r.loading]
331
+ [y, r.loading]
332
332
  ]),
333
333
  r.$slots.footer ? (t(), l("div", {
334
334
  key: 2,
@@ -338,25 +338,25 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
338
338
  { "panel__footer--shadowed": !e(u) }
339
339
  ])
340
340
  }, [
341
- I(r.$slots, "footer", {}, void 0, !0)
341
+ A(r.$slots, "footer", {}, void 0, !0)
342
342
  ], 2)) : b("", !0)
343
343
  ]),
344
344
  _: 3
345
345
  }, 8, ["class"]))
346
346
  ], 2)), [
347
- [T, {
347
+ [s, {
348
348
  condition: r.overlay || r.fixedRight || r.float,
349
349
  invisible: r.invisibleOverlay,
350
- click: c,
350
+ click: p,
351
351
  layer: r.overlayLayer || (r.float ? 60 : r.fixedRight ? 50 : 0)
352
352
  }]
353
353
  ]) : b("", !0);
354
354
  };
355
355
  }
356
- }), Ce = /* @__PURE__ */ U(Gt, [["__scopeId", "data-v-8463f8df"]]), Wt = { class: "content__body" }, Yt = {
356
+ }), Oe = /* @__PURE__ */ U(Qt, [["__scopeId", "data-v-8463f8df"]]), Gt = { class: "content__body" }, Wt = {
357
357
  key: 0,
358
358
  class: "content__section"
359
- }, Kt = { class: "content__item" }, Xt = /* @__PURE__ */ z({
359
+ }, Yt = { class: "content__item" }, Kt = /* @__PURE__ */ F({
360
360
  __name: "aeria-context-menu",
361
361
  props: {
362
362
  actions: {},
@@ -364,59 +364,59 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
364
364
  overlayLayer: {}
365
365
  },
366
366
  emits: ["actionClick"],
367
- setup(p, { emit: i }) {
368
- et((c) => ({
369
- "4078ef85": m.value.x,
370
- "4078ef86": m.value.y
367
+ setup(m, { emit: i }) {
368
+ xe((p) => ({
369
+ "4078ef85": f.value.x,
370
+ "4078ef86": f.value.y
371
371
  }));
372
- const o = i, n = J(null), a = J(!1), d = (c) => c?.filter((v) => {
372
+ const o = i, n = Z(null), a = Z(!1), d = (p) => p?.filter((v) => {
373
373
  if (v.roles) {
374
374
  const r = te("user");
375
- return Fe(v.roles, r.currentUser.roles);
375
+ return Ee(v.roles, r.currentUser.roles);
376
376
  }
377
377
  return !0;
378
- }), u = (c, v) => {
379
- const r = v && ge(v);
380
- c.click && c.click(r), o("actionClick", {
381
- action: c,
378
+ }), u = (p, v) => {
379
+ const r = v && ke(v);
380
+ p.click && p.click(r), o("actionClick", {
381
+ action: p,
382
382
  subject: r
383
383
  }), a.value = !1;
384
- }, m = W(() => {
384
+ }, f = Y(() => {
385
385
  if (!n.value)
386
386
  return {
387
387
  x: 0,
388
388
  y: 0
389
389
  };
390
- const c = n.value.getBoundingClientRect().top, v = n.value.getBoundingClientRect().left, r = n.value.offsetHeight;
390
+ const p = n.value.getBoundingClientRect().top, v = n.value.getBoundingClientRect().left, r = n.value.offsetHeight;
391
391
  return {
392
392
  _: a.value,
393
393
  x: Math.floor(v) + "px",
394
- y: Math.floor(c + r) + "px"
394
+ y: Math.floor(p + r) + "px"
395
395
  };
396
396
  });
397
- return (c, v) => {
398
- const r = P("overlay");
399
- return t(), l(Y, null, [
400
- Object.keys(c.$slots).some(($) => $ !== "default") || c.actions !== void 0 && c.actions.length > 0 ? (t(), l("div", {
397
+ return (p, v) => {
398
+ const r = N("overlay");
399
+ return t(), l(X, null, [
400
+ Object.keys(p.$slots).some(($) => $ !== "default") || p.actions !== void 0 && p.actions.length > 0 ? (t(), l("div", {
401
401
  key: 0,
402
402
  ref_key: "contextmenu",
403
403
  ref: n,
404
404
  class: "contextmenu"
405
405
  }, [
406
- S("a", {
406
+ I("a", {
407
407
  class: "contextmenu__trigger",
408
408
  onClick: v[0] || (v[0] = ($) => a.value = !0)
409
409
  }, [
410
- I(c.$slots, "default", le(_e({
410
+ A(p.$slots, "default", ne(_e({
411
411
  visible: a.value
412
412
  })), void 0, !0)
413
413
  ])
414
414
  ], 512)) : b("", !0),
415
- a.value ? (t(), V(Ee, {
415
+ a.value ? (t(), k(Ue, {
416
416
  key: 1,
417
417
  to: "main"
418
418
  }, [
419
- K((t(), V(Ce, {
419
+ J((t(), k(Oe, {
420
420
  modelValue: a.value,
421
421
  "onUpdate:modelValue": v[4] || (v[4] = ($) => a.value = $),
422
422
  fill: "",
@@ -425,41 +425,41 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
425
425
  style: { "--panel-min-width": "0" }
426
426
  }, {
427
427
  default: h(() => [
428
- S("div", Wt, [
429
- c.$slots.header ? (t(), l("div", Yt, [
430
- I(c.$slots, "header", {}, void 0, !0)
428
+ I("div", Gt, [
429
+ p.$slots.header ? (t(), l("div", Wt, [
430
+ A(p.$slots, "header", {}, void 0, !0)
431
431
  ])) : b("", !0),
432
- Object.keys(c.$slots).filter(($) => !["default", "extra", "header"].includes($)).length > 0 ? (t(), l("div", {
432
+ Object.keys(p.$slots).filter(($) => !["default", "extra", "header"].includes($)).length > 0 ? (t(), l("div", {
433
433
  key: 1,
434
434
  class: "content__section",
435
435
  onClick: v[1] || (v[1] = ($) => a.value = !1)
436
436
  }, [
437
- (t(!0), l(Y, null, E(Object.keys(c.$slots).filter(($) => !["default", "extra", "header"].includes($)), ($, k) => (t(), V(ce, {
438
- key: `slot-${k}`,
437
+ (t(!0), l(X, null, E(Object.keys(p.$slots).filter(($) => !["default", "extra", "header"].includes($)), ($, g) => (t(), k(de, {
438
+ key: `slot-${g}`,
439
439
  class: "content__item content__item--reactive"
440
440
  }, {
441
441
  default: h(() => [
442
- I(c.$slots, $, {}, void 0, !0)
442
+ A(p.$slots, $, {}, void 0, !0)
443
443
  ]),
444
444
  _: 2
445
445
  }, 1024))), 128))
446
446
  ])) : b("", !0),
447
- c.actions !== void 0 && c.actions.length > 0 ? (t(), l("div", {
447
+ p.actions !== void 0 && p.actions.length > 0 ? (t(), l("div", {
448
448
  key: 2,
449
449
  class: "content__section",
450
450
  onClick: v[2] || (v[2] = ($) => a.value = !1)
451
451
  }, [
452
- (t(!0), l(Y, null, E(d(c.actions), ($, k) => (t(), V(ce, {
453
- key: `action-${k}`,
452
+ (t(!0), l(X, null, E(d(p.actions), ($, g) => (t(), k(de, {
453
+ key: `action-${g}`,
454
454
  class: "content__item content__item--reactive",
455
- onClick: (_) => u($, c.subject)
455
+ onClick: (y) => u($, p.subject)
456
456
  }, {
457
457
  default: h(() => [
458
- L(G, {
458
+ M(G, {
459
459
  icon: $.icon || "gear"
460
460
  }, {
461
461
  default: h(() => [
462
- D(A($.translate ? e(j)($.label, { capitalize: !0 }) : $.label), 1)
462
+ D(C($.translate ? e(j)($.label, { capitalize: !0 }) : $.label), 1)
463
463
  ]),
464
464
  _: 2
465
465
  }, 1032, ["icon"])
@@ -467,13 +467,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
467
467
  _: 2
468
468
  }, 1032, ["onClick"]))), 128))
469
469
  ])) : b("", !0),
470
- c.$slots.extra ? (t(), l("div", {
470
+ p.$slots.extra ? (t(), l("div", {
471
471
  key: 3,
472
472
  class: "content__section",
473
473
  onClick: v[3] || (v[3] = ($) => a.value = !1)
474
474
  }, [
475
- S("div", Kt, [
476
- c.$slots.extra ? I(c.$slots, "extra", { key: 0 }, void 0, !0) : b("", !0)
475
+ I("div", Yt, [
476
+ p.$slots.extra ? A(p.$slots, "extra", { key: 0 }, void 0, !0) : b("", !0)
477
477
  ])
478
478
  ])) : b("", !0)
479
479
  ])
@@ -483,7 +483,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
483
483
  [
484
484
  r,
485
485
  {
486
- layer: c.overlayLayer,
486
+ layer: p.overlayLayer,
487
487
  click: () => {
488
488
  a.value = !1;
489
489
  }
@@ -496,13 +496,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
496
496
  ], 64);
497
497
  };
498
498
  }
499
- }), ke = /* @__PURE__ */ U(Xt, [["__scopeId", "data-v-ee3ea72f"]]), Jt = { class: "info__content" }, Zt = /* @__PURE__ */ z({
499
+ }), Ve = /* @__PURE__ */ U(Kt, [["__scopeId", "data-v-ee3ea72f"]]), Xt = { class: "info__content" }, Jt = /* @__PURE__ */ F({
500
500
  __name: "aeria-info",
501
501
  props: {
502
502
  where: { default: "top" }
503
503
  },
504
- setup(p) {
505
- const i = Se(), o = J(!1);
504
+ setup(m) {
505
+ const i = Se(), o = Z(!1);
506
506
  return (n, a) => e(i).md ? (t(), l("div", {
507
507
  key: 0,
508
508
  class: "info",
@@ -515,27 +515,27 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
515
515
  `info__bubble--${n.where}`
516
516
  ])
517
517
  }, [
518
- S("div", Jt, [
519
- I(n.$slots, "text", {}, void 0, !0)
518
+ I("div", Xt, [
519
+ A(n.$slots, "text", {}, void 0, !0)
520
520
  ])
521
521
  ], 2)) : b("", !0),
522
- S("div", {
522
+ I("div", {
523
523
  onMouseover: a[0] || (a[0] = (d) => o.value = !0)
524
524
  }, [
525
- I(n.$slots, "default", {}, void 0, !0)
525
+ A(n.$slots, "default", {}, void 0, !0)
526
526
  ], 32)
527
- ], 32)) : I(n.$slots, "default", { key: 1 }, void 0, !0);
527
+ ], 32)) : A(n.$slots, "default", { key: 1 }, void 0, !0);
528
528
  }
529
- }), Pt = /* @__PURE__ */ U(Zt, [["__scopeId", "data-v-15a38847"]]), Nt = { class: "input" }, xt = {
529
+ }), Zt = /* @__PURE__ */ U(Jt, [["__scopeId", "data-v-15a38847"]]), Pt = { class: "input" }, Nt = {
530
530
  key: 0,
531
531
  class: "input__label"
532
- }, eo = {
532
+ }, xt = {
533
533
  key: 1,
534
534
  class: "input__hint"
535
- }, to = ["placeholder", "readonly", "value"], oo = ["value"], no = {
535
+ }, eo = ["placeholder", "readonly", "value"], to = ["value"], oo = {
536
536
  key: 1,
537
537
  class: "input__clipboard"
538
- }, ao = /* @__PURE__ */ z({
538
+ }, no = /* @__PURE__ */ F({
539
539
  __name: "aeria-input",
540
540
  props: {
541
541
  modelValue: {},
@@ -548,10 +548,10 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
548
548
  variant: {}
549
549
  },
550
550
  emits: ["update:modelValue", "input", "change", "clipboardCopy"],
551
- setup(p, { emit: i }) {
552
- const o = p, n = i, a = o.property || {}, d = "icon" in a || "inputType" in a && a.inputType === "search", u = ue("searchOnly", !1), m = ue("innerInputLabel", !1), c = !u && (o.readOnly || a.readOnly), v = (y) => (n("clipboardCopy", y), navigator.clipboard.writeText(y)), r = ue("inputVariant", o.variant) || "normal", $ = Object.assign(Object.assign({}, o), {
551
+ setup(m, { emit: i }) {
552
+ const o = m, n = i, a = o.property || {}, d = "icon" in a || "inputType" in a && a.inputType === "search", u = ue("searchOnly", !1), f = ue("innerInputLabel", !1), p = !u && (o.readOnly || a.readOnly), v = (_) => (n("clipboardCopy", _), navigator.clipboard.writeText(_)), r = ue("inputVariant", o.variant) || "normal", $ = Object.assign(Object.assign({}, o), {
553
553
  name: o.propertyName,
554
- readonly: c,
554
+ readonly: p,
555
555
  type: (() => {
556
556
  if ("type" in a)
557
557
  switch (a.type) {
@@ -570,17 +570,17 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
570
570
  return "text";
571
571
  }
572
572
  })(),
573
- placeholder: m ? a.description || o.propertyName : a.placeholder
573
+ placeholder: f ? a.description || o.propertyName : a.placeholder
574
574
  });
575
- "type" in a && ((a.type === "number" || a.type === "integer") && (a.minimum && ($.min = a.minimum), a.exclusiveMinimum && ($.min = a.exclusiveMinimum + 1), a.maximum && ($.max = a.maximum), a.exclusiveMaximum && ($.max = a.exclusiveMaximum - 1)), a.type === "string" && ((a.format === "date" || a.format === "date-time") && ($.type = !u && a.format === "date-time" ? "datetime-local" : "date"), $.minlength = a.minLength, $.maxlength = a.maxLength)), $.type === "text" && u && ($.type = "search"), Ue(() => {
576
- o.modelValue !== null && O(o.modelValue);
575
+ "type" in a && ((a.type === "number" || a.type === "integer") && (a.minimum && ($.min = a.minimum), a.exclusiveMinimum && ($.min = a.exclusiveMinimum + 1), a.maximum && ($.max = a.maximum), a.exclusiveMaximum && ($.max = a.exclusiveMaximum - 1)), a.type === "string" && ((a.format === "date" || a.format === "date-time") && ($.type = !u && a.format === "date-time" ? "datetime-local" : "date"), $.minlength = a.minLength, $.maxlength = a.maxLength)), $.type === "text" && u && ($.type = "search"), He(() => {
576
+ o.modelValue !== null && V(o.modelValue);
577
577
  });
578
- const k = (y) => {
578
+ const g = (_) => {
579
579
  let q;
580
- if (typeof y == "string")
581
- q = y;
582
- else if (y instanceof Date)
583
- q = y.toISOString();
580
+ if (typeof _ == "string")
581
+ q = _;
582
+ else if (_ instanceof Date)
583
+ q = _.toISOString();
584
584
  else
585
585
  return "";
586
586
  switch ($.type) {
@@ -591,59 +591,59 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
591
591
  default:
592
592
  throw new Error();
593
593
  }
594
- }, _ = J(""), T = o.property?.type === "string" && o.property.mask ? dt(o.property.mask) : null;
595
- ne(() => o.modelValue, (y) => {
596
- _.value = (() => {
597
- if (T)
598
- return y ? T.enmask(String(y), void 0, {
594
+ }, y = Z(""), s = o.property?.type === "string" && o.property.mask ? ut(o.property.mask) : null;
595
+ oe(() => o.modelValue, (_) => {
596
+ y.value = (() => {
597
+ if (s)
598
+ return _ ? s.enmask(String(_), void 0, {
599
599
  defaultValue: !0
600
600
  }) : "";
601
601
  switch ($.type) {
602
602
  case "date":
603
603
  case "datetime-local":
604
- return k(y);
604
+ return g(_);
605
605
  }
606
- switch (y) {
606
+ switch (_) {
607
607
  case null:
608
608
  case void 0:
609
609
  return "";
610
610
  default:
611
- return y;
611
+ return _;
612
612
  }
613
613
  })();
614
614
  }, {
615
615
  immediate: !0
616
616
  });
617
- const s = (y) => typeof _.value == "string" && o.property?.type === "string" && T !== null ? (_.value = T.enmask(_.value, void 0, {
617
+ const B = (_) => typeof y.value == "string" && o.property?.type === "string" && s !== null ? (y.value = s.enmask(y.value, void 0, {
618
618
  defaultValue: !0
619
- }), o.property.maskedValue === !0 ? _.value : T.unmask(_.value)) : y, O = (y) => {
619
+ }), o.property.maskedValue === !0 ? y.value : s.unmask(y.value)) : _, V = (_) => {
620
620
  const q = (() => {
621
- if (typeof y != "string")
622
- return y;
621
+ if (typeof _ != "string")
622
+ return _;
623
623
  switch ($.type) {
624
624
  case "number":
625
625
  case "integer":
626
- return y === "" ? null : Number(y);
626
+ return _ === "" ? null : Number(_);
627
627
  case "date":
628
628
  case "date-time":
629
- return y === "" ? null : typeof y == "string" ? new Date(y) : y;
629
+ return _ === "" ? null : typeof _ == "string" ? new Date(_) : _;
630
630
  default:
631
- return s(y);
631
+ return B(_);
632
632
  }
633
633
  })();
634
634
  n("input", q), n("update:modelValue", q);
635
- }, X = (y) => {
636
- const q = y.target.value;
637
- _.value = q, O(q);
635
+ }, H = (_) => {
636
+ const q = _.target.value;
637
+ y.value = q, V(q);
638
638
  };
639
- return (y, q) => {
640
- const ee = P("focus"), N = P("clickable");
641
- return t(), l("label", Nt, [
642
- e(m) ? b("", !0) : (t(), l("div", xt, [
643
- y.$slots.default ? I(y.$slots, "default", { key: 0 }, void 0, !0) : I(y.$slots, "description", { key: 1 }, void 0, !0)
639
+ return (_, q) => {
640
+ const ie = N("focus"), x = N("clickable");
641
+ return t(), l("label", Pt, [
642
+ e(f) ? b("", !0) : (t(), l("div", Nt, [
643
+ _.$slots.default ? A(_.$slots, "default", { key: 0 }, void 0, !0) : A(_.$slots, "description", { key: 1 }, void 0, !0)
644
644
  ])),
645
- y.$slots.hint ? (t(), l("div", eo, [
646
- I(y.$slots, "hint", {}, void 0, !0)
645
+ _.$slots.hint ? (t(), l("div", xt, [
646
+ A(_.$slots, "hint", {}, void 0, !0)
647
647
  ])) : b("", !0),
648
648
  "element" in e(a) && e(a).element === "textarea" ? (t(), l("div", {
649
649
  key: 2,
@@ -653,17 +653,17 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
653
653
  `input__container--${e(r)}`
654
654
  ])
655
655
  }, [
656
- K(S("textarea", {
656
+ J(I("textarea", {
657
657
  placeholder: e($).placeholder,
658
658
  readonly: e($).readonly,
659
- value: y.modelValue,
659
+ value: _.modelValue,
660
660
  class: Q([
661
661
  "input__textarea",
662
662
  `input__input--${e(r)}`
663
663
  ]),
664
- onInput: X
665
- }, null, 42, to), [
666
- [ee, e(a).focus]
664
+ onInput: H
665
+ }, null, 42, eo), [
666
+ [ie, e(a).focus]
667
667
  ])
668
668
  ], 2)) : (t(), l("div", {
669
669
  key: 3,
@@ -672,21 +672,21 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
672
672
  `input__container--${e(r)}`
673
673
  ])
674
674
  }, [
675
- K(S("input", M(e($), {
676
- value: _.value,
675
+ J(I("input", z(e($), {
676
+ value: y.value,
677
677
  "data-component": "input",
678
678
  class: [
679
679
  "input__input",
680
680
  `input__input--${e(r)}`,
681
681
  { "input__input--icon": e(d) },
682
- { "input__input--readOnly": e(c) }
682
+ { "input__input--readOnly": e(p) }
683
683
  ],
684
- onInput: X,
685
- onChange: q[0] || (q[0] = (oe) => n("change", oe))
686
- }), null, 16, oo), [
687
- [ee, e(a).focus]
684
+ onInput: H,
685
+ onChange: q[0] || (q[0] = (re) => n("change", re))
686
+ }), null, 16, to), [
687
+ [ie, e(a).focus]
688
688
  ]),
689
- e(d) ? (t(), V(G, {
689
+ e(d) ? (t(), k(G, {
690
690
  key: 0,
691
691
  icon: e(a).icon || "magnifying-glass",
692
692
  class: Q([
@@ -694,18 +694,18 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
694
694
  `input__icon--${e(r)}`
695
695
  ])
696
696
  }, null, 8, ["icon", "class"])) : b("", !0),
697
- e(c) ? (t(), l("div", no, [
698
- L(Pt, null, {
697
+ e(p) ? (t(), l("div", oo, [
698
+ M(Zt, null, {
699
699
  text: h(() => q[2] || (q[2] = [
700
700
  D("Copiar")
701
701
  ])),
702
702
  default: h(() => [
703
- K(L(G, {
703
+ J(M(G, {
704
704
  reactive: "",
705
705
  icon: "clipboard",
706
- onClick: q[1] || (q[1] = Ie((oe) => v(String(y.modelValue || "")), ["prevent"]))
706
+ onClick: q[1] || (q[1] = Ie((re) => v(String(_.modelValue || "")), ["prevent"]))
707
707
  }, null, 512), [
708
- [N]
708
+ [x]
709
709
  ])
710
710
  ]),
711
711
  _: 1
@@ -715,10 +715,10 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
715
715
  ]);
716
716
  };
717
717
  }
718
- }), he = /* @__PURE__ */ U(ao, [["__scopeId", "data-v-36753c7c"]]), lo = {
718
+ }), he = /* @__PURE__ */ U(no, [["__scopeId", "data-v-36753c7c"]]), ao = {
719
719
  key: 1,
720
720
  value: ""
721
- }, so = ["value", "data-selected"], io = /* @__PURE__ */ z({
721
+ }, lo = ["value", "data-selected"], so = /* @__PURE__ */ F({
722
722
  __name: "aeria-select",
723
723
  props: {
724
724
  modelValue: {},
@@ -733,22 +733,22 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
733
733
  noOutline: { type: Boolean }
734
734
  },
735
735
  emits: ["update:modelValue", "change"],
736
- setup(p, { emit: i }) {
737
- const o = p, n = i, a = J(null), d = o.property, u = (r) => {
736
+ setup(m, { emit: i }) {
737
+ const o = m, n = i, a = Z(null), d = o.property, u = (r) => {
738
738
  n("update:modelValue", r), n("change", r);
739
- }, m = (r) => {
739
+ }, f = (r) => {
740
740
  r === "" || r === null ? u(null) : o.booleanRef ? u(r === "true") : u(r);
741
- }, c = (r) => Array.isArray(o.modelValue) ? o.modelValue.includes(r) : o.modelValue === r, v = W(() => o.multiple ? typeof o.multiple == "number" ? o.multiple : 5 : 1);
742
- return o.multiple && ne(() => o.modelValue, (r) => {
741
+ }, p = (r) => Array.isArray(o.modelValue) ? o.modelValue.includes(r) : o.modelValue === r, v = Y(() => o.multiple ? typeof o.multiple == "number" ? o.multiple : 5 : 1);
742
+ return o.multiple && oe(() => o.modelValue, (r) => {
743
743
  if (!a.value)
744
744
  return;
745
745
  const $ = a.value.querySelector('option[data-selected="true"]');
746
746
  $ && $.removeAttribute("data-selected"), a.value.querySelector(`option[value="${r}"]`)?.setAttribute("data-selected", "true");
747
- }), (r, $) => r.readOnly ? (t(), V(he, {
747
+ }), (r, $) => r.readOnly ? (t(), k(he, {
748
748
  key: 1,
749
749
  "read-only": "",
750
750
  "model-value": r.modelValue
751
- }, null, 8, ["model-value"])) : (t(), l("select", M({ key: 0 }, {
751
+ }, null, 8, ["model-value"])) : (t(), l("select", z({ key: 0 }, {
752
752
  size: v.value,
753
753
  value: r.modelValue
754
754
  }, {
@@ -759,90 +759,90 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
759
759
  "select--multiple": !!v.value,
760
760
  "select--outline": !r.noOutline
761
761
  },
762
- onChange: $[0] || ($[0] = (k) => m(k.target.value))
762
+ onChange: $[0] || ($[0] = (g) => f(g.target.value))
763
763
  }), [
764
- e(d) && e(d).icon ? (t(), V(G, {
764
+ e(d) && e(d).icon ? (t(), k(G, {
765
765
  key: 0,
766
766
  icon: e(d).icon
767
767
  }, null, 8, ["icon"])) : b("", !0),
768
- !o.multiple && !r.required ? (t(), l("option", lo, A(e(j)("none")), 1)) : b("", !0),
769
- (t(!0), l(Y, null, E(e(d) && "enum" in e(d) ? e(d).enum : [], (k) => (t(), l("option", {
770
- key: String(k),
771
- value: k,
772
- "data-selected": c(k)
773
- }, A(e(d)?.translate ? e(j)(k) : k), 9, so))), 128)),
774
- I(r.$slots, "default", {}, void 0, !0)
768
+ !o.multiple && !r.required ? (t(), l("option", ao, C(e(j)("none")), 1)) : b("", !0),
769
+ (t(!0), l(X, null, E(e(d) && "enum" in e(d) ? e(d).enum : [], (g) => (t(), l("option", {
770
+ key: String(g),
771
+ value: g,
772
+ "data-selected": p(g)
773
+ }, C(e(d)?.translate ? e(j)(g) : g), 9, lo))), 128)),
774
+ A(r.$slots, "default", {}, void 0, !0)
775
775
  ], 16));
776
776
  }
777
- }), Qe = /* @__PURE__ */ U(io, [["__scopeId", "data-v-82e255a8"]]), ro = { class: "pagination" }, uo = { class: "pagination__arrows" }, co = ["value"], po = {
777
+ }), Ge = /* @__PURE__ */ U(so, [["__scopeId", "data-v-82e255a8"]]), io = { class: "pagination" }, ro = { class: "pagination__arrows" }, uo = ["value"], co = {
778
778
  key: 0,
779
779
  class: "pagination__summary"
780
- }, mo = /* @__PURE__ */ z({
780
+ }, po = /* @__PURE__ */ F({
781
781
  __name: "aeria-pagination",
782
782
  props: {
783
783
  pagination: {},
784
784
  noSummary: { type: Boolean }
785
785
  },
786
786
  emits: ["paginate"],
787
- setup(p, { emit: i }) {
788
- const o = p, n = i, a = W({
787
+ setup(m, { emit: i }) {
788
+ const o = m, n = i, a = Y({
789
789
  get: () => Math.floor(o.pagination.offset / o.pagination.limit),
790
- set: (c) => {
791
- o.pagination.offset = c * o.pagination.limit;
790
+ set: (p) => {
791
+ o.pagination.offset = p * o.pagination.limit;
792
792
  }
793
- }), d = W({
793
+ }), d = Y({
794
794
  get: () => o.pagination.limit,
795
- set: (c) => {
796
- o.pagination.limit = Number(c);
795
+ set: (p) => {
796
+ o.pagination.limit = Number(p);
797
797
  }
798
- }), u = J(a.value ? a.value + 1 : 1), m = W(() => Math.ceil(o.pagination.recordsTotal / o.pagination.limit));
799
- return ne([
798
+ }), u = Z(a.value ? a.value + 1 : 1), f = Y(() => Math.ceil(o.pagination.recordsTotal / o.pagination.limit));
799
+ return oe([
800
800
  a,
801
801
  d
802
- ], ([c]) => {
803
- u.value = c + 1, n("paginate", {
802
+ ], ([p]) => {
803
+ u.value = p + 1, n("paginate", {
804
804
  offset: a.value * d.value,
805
805
  limit: d.value
806
806
  });
807
- }), (c, v) => (t(), l("div", ro, [
808
- S("div", uo, [
809
- L(ce, {
807
+ }), (p, v) => (t(), l("div", io, [
808
+ I("div", ro, [
809
+ M(de, {
810
810
  disabled: a.value === 0,
811
811
  onClick: v[0] || (v[0] = (r) => a.value = 0)
812
812
  }, {
813
813
  default: h(() => [
814
- L(G, { icon: "caret-double-left" })
814
+ M(G, { icon: "caret-double-left" })
815
815
  ]),
816
816
  _: 1
817
817
  }, 8, ["disabled"]),
818
- L(ce, {
818
+ M(de, {
819
819
  disabled: a.value === 0,
820
820
  onClick: v[1] || (v[1] = (r) => a.value -= 1)
821
821
  }, {
822
822
  default: h(() => [
823
- L(G, { icon: "caret-left" })
823
+ M(G, { icon: "caret-left" })
824
824
  ]),
825
825
  _: 1
826
826
  }, 8, ["disabled"]),
827
- L(ce, {
828
- disabled: a.value === m.value - 1,
827
+ M(de, {
828
+ disabled: a.value === f.value - 1,
829
829
  onClick: v[2] || (v[2] = (r) => a.value += 1)
830
830
  }, {
831
831
  default: h(() => [
832
- L(G, { icon: "caret-right" })
832
+ M(G, { icon: "caret-right" })
833
833
  ]),
834
834
  _: 1
835
835
  }, 8, ["disabled"]),
836
- L(ce, {
837
- disabled: a.value === m.value - 1,
838
- onClick: v[3] || (v[3] = (r) => a.value = m.value - 1)
836
+ M(de, {
837
+ disabled: a.value === f.value - 1,
838
+ onClick: v[3] || (v[3] = (r) => a.value = f.value - 1)
839
839
  }, {
840
840
  default: h(() => [
841
- L(G, { icon: "caret-double-right" })
841
+ M(G, { icon: "caret-double-right" })
842
842
  ]),
843
843
  _: 1
844
844
  }, 8, ["disabled"]),
845
- L(Qe, {
845
+ M(Ge, {
846
846
  modelValue: d.value,
847
847
  "onUpdate:modelValue": v[4] || (v[4] = (r) => d.value = r),
848
848
  property: {
@@ -852,17 +852,17 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
852
852
  class: "pagination__control"
853
853
  }, {
854
854
  default: h(() => [
855
- (t(!0), l(Y, null, E(e(ct), (r) => (t(), l("option", {
855
+ (t(!0), l(X, null, E(e(dt), (r) => (t(), l("option", {
856
856
  key: `limit-${r}`,
857
857
  value: r
858
- }, A(r), 9, co))), 128))
858
+ }, C(r), 9, uo))), 128))
859
859
  ]),
860
860
  _: 1
861
861
  }, 8, ["modelValue"])
862
862
  ]),
863
- c.noSummary ? b("", !0) : (t(), l("div", po, [
864
- D(A(e(j)("Page")) + " ", 1),
865
- (t(), V(he, {
863
+ p.noSummary ? b("", !0) : (t(), l("div", co, [
864
+ D(C(e(j)("Page")) + " ", 1),
865
+ (t(), k(he, {
866
866
  key: a.value,
867
867
  modelValue: u.value,
868
868
  "onUpdate:modelValue": v[5] || (v[5] = (r) => u.value = r),
@@ -875,14 +875,14 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
875
875
  a.value = u.value === 0 ? 0 : u.value - 1;
876
876
  })
877
877
  }, null, 8, ["modelValue"])),
878
- S("span", null, A(e(j)("of")) + " " + A(m.value), 1)
878
+ I("span", null, C(e(j)("of")) + " " + C(f.value), 1)
879
879
  ]))
880
880
  ]));
881
881
  }
882
- }), fo = /* @__PURE__ */ U(mo, [["__scopeId", "data-v-8cd299be"]]), vo = { class: "checkbox__text" }, yo = ["innerHTML"], _o = { class: "checkbox__hint" }, ho = ["innerHTML"], bo = {
882
+ }), mo = /* @__PURE__ */ U(po, [["__scopeId", "data-v-8cd299be"]]), fo = { class: "checkbox__text" }, vo = ["innerHTML"], yo = { class: "checkbox__hint" }, _o = ["innerHTML"], ho = {
883
883
  inheritAttrs: !1
884
- }, $o = /* @__PURE__ */ z({
885
- ...bo,
884
+ }, bo = /* @__PURE__ */ F({
885
+ ...ho,
886
886
  __name: "aeria-checkbox",
887
887
  props: {
888
888
  modelValue: {},
@@ -896,8 +896,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
896
896
  variant: {}
897
897
  },
898
898
  emits: ["update:modelValue", "change"],
899
- setup(p, { emit: i }) {
900
- const o = p, n = o.property, a = o.readOnly || n?.readOnly, d = (() => {
899
+ setup(m, { emit: i }) {
900
+ const o = m, n = o.property, a = o.readOnly || n?.readOnly, d = (() => {
901
901
  if (n && "type" in n)
902
902
  switch (n.type) {
903
903
  case "array":
@@ -905,7 +905,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
905
905
  return "checkbox";
906
906
  }
907
907
  return "radio";
908
- })(), u = i, m = o.value || !1, c = W({
908
+ })(), u = i, f = o.value || !1, p = Y({
909
909
  get: () => {
910
910
  if (n) {
911
911
  if ("type" in n && n.type === "boolean")
@@ -923,11 +923,11 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
923
923
  return;
924
924
  }
925
925
  if ("items" in n) {
926
- if (o.modelValue?.includes(m)) {
927
- u("update:modelValue", o.modelValue.filter((r) => r !== m));
926
+ if (o.modelValue?.includes(f)) {
927
+ u("update:modelValue", o.modelValue.filter((r) => r !== f));
928
928
  return;
929
929
  }
930
- u("update:modelValue", [m].concat(o.modelValue || []));
930
+ u("update:modelValue", [f].concat(o.modelValue || []));
931
931
  return;
932
932
  }
933
933
  }
@@ -938,48 +938,48 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
938
938
  a && r.preventDefault();
939
939
  };
940
940
  return (r, $) => {
941
- const k = P("clickable");
942
- return K((t(), l("label", {
941
+ const g = N("clickable");
942
+ return J((t(), l("label", {
943
943
  class: Q([
944
944
  "checkbox",
945
945
  { "checkbox--readOnly": e(a) }
946
946
  ])
947
947
  }, [
948
- K(S("input", M({
949
- "onUpdate:modelValue": $[0] || ($[0] = (_) => c.value = _)
948
+ J(I("input", z({
949
+ "onUpdate:modelValue": $[0] || ($[0] = (y) => p.value = y)
950
950
  }, {
951
951
  type: e(d),
952
952
  readOnly: e(a),
953
- checked: c.value
953
+ checked: p.value
954
954
  }, {
955
955
  class: "checkbox__input",
956
956
  onClick: v
957
957
  }), null, 16), [
958
- [tt, c.value]
958
+ [et, p.value]
959
959
  ]),
960
- S("div", vo, [
961
- S("div", null, [
962
- r.$slots.description ? I(r.$slots, "description", { key: 0 }, void 0, !0) : e(m) ? (t(), l("div", {
960
+ I("div", fo, [
961
+ I("div", null, [
962
+ r.$slots.description ? A(r.$slots, "description", { key: 0 }, void 0, !0) : e(f) ? (t(), l("div", {
963
963
  key: 1,
964
- innerHTML: e(n)?.translate ? e(j)(e(m)) : e(m)
965
- }, null, 8, yo)) : I(r.$slots, "default", { key: 2 }, void 0, !0)
964
+ innerHTML: e(n)?.translate ? e(j)(e(f)) : e(f)
965
+ }, null, 8, vo)) : A(r.$slots, "default", { key: 2 }, void 0, !0)
966
966
  ]),
967
- S("div", _o, [
968
- r.$slots.hint ? I(r.$slots, "hint", { key: 0 }, void 0, !0) : e(n)?.hint ? (t(), l("div", {
967
+ I("div", yo, [
968
+ r.$slots.hint ? A(r.$slots, "hint", { key: 0 }, void 0, !0) : e(n)?.hint ? (t(), l("div", {
969
969
  key: 1,
970
970
  innerHTML: e(n).hint
971
- }, null, 8, ho)) : b("", !0)
971
+ }, null, 8, _o)) : b("", !0)
972
972
  ])
973
973
  ])
974
974
  ], 2)), [
975
- [k]
975
+ [g]
976
976
  ]);
977
977
  };
978
978
  }
979
- }), go = /* @__PURE__ */ U($o, [["__scopeId", "data-v-7e6efc77"]]), ko = {
979
+ }), $o = /* @__PURE__ */ U(bo, [["__scopeId", "data-v-7e6efc77"]]), go = {
980
980
  inheritAttrs: !1
981
- }, Vo = /* @__PURE__ */ z({
982
- ...ko,
981
+ }, ko = /* @__PURE__ */ F({
982
+ ...go,
983
983
  __name: "aeria-options",
984
984
  props: {
985
985
  modelValue: {},
@@ -992,41 +992,41 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
992
992
  columns: { default: 1 }
993
993
  },
994
994
  emits: ["update:modelValue"],
995
- setup(p, { emit: i }) {
996
- const o = p, n = i, a = o.readOnly || o.property.readOnly, d = "items" in o.property ? o.property.items.enum : o.property.enum, u = (m) => {
997
- n("update:modelValue", m);
995
+ setup(m, { emit: i }) {
996
+ const o = m, n = i, a = o.readOnly || o.property.readOnly, d = "items" in o.property ? o.property.items.enum : o.property.enum, u = (f) => {
997
+ n("update:modelValue", f);
998
998
  };
999
- return Je(() => {
999
+ return Ze(() => {
1000
1000
  o.modelValue || n(
1001
1001
  "update:modelValue",
1002
1002
  "items" in o.property ? [] : ""
1003
1003
  );
1004
- }), (m, c) => (t(), l("div", {
1004
+ }), (f, p) => (t(), l("div", {
1005
1005
  class: "options",
1006
- style: ve(`
1007
- --columns: ${m.columns};
1006
+ style: fe(`
1007
+ --columns: ${f.columns};
1008
1008
  grid-template-columns: repeat(var(--columns), 1fr);
1009
1009
  `)
1010
1010
  }, [
1011
- (t(!0), l(Y, null, E(e(d), (v) => (t(), l("div", {
1011
+ (t(!0), l(X, null, E(e(d), (v) => (t(), l("div", {
1012
1012
  key: `option-${v}`,
1013
1013
  class: "options__checkbox"
1014
1014
  }, [
1015
- L(go, M({ ref_for: !0 }, {
1015
+ M($o, z({ ref_for: !0 }, {
1016
1016
  value: v,
1017
1017
  readOnly: e(a),
1018
- property: m.property
1018
+ property: f.property
1019
1019
  }, {
1020
- "model-value": m.modelValue,
1020
+ "model-value": f.modelValue,
1021
1021
  "onUpdate:modelValue": u
1022
1022
  }), null, 16, ["model-value"])
1023
1023
  ]))), 128))
1024
1024
  ], 4));
1025
1025
  }
1026
- }), Co = /* @__PURE__ */ U(Vo, [["__scopeId", "data-v-bcfc697e"]]), Oo = { class: "switch-wrapper" }, Ao = { key: 1 }, Io = {
1026
+ }), Vo = /* @__PURE__ */ U(ko, [["__scopeId", "data-v-bcfc697e"]]), Co = { class: "switch-wrapper" }, Oo = { key: 1 }, Ao = {
1027
1027
  inheritAttrs: !1
1028
- }, Bo = /* @__PURE__ */ z({
1029
- ...Io,
1028
+ }, Io = /* @__PURE__ */ F({
1029
+ ...Ao,
1030
1030
  __name: "aeria-switch",
1031
1031
  props: {
1032
1032
  modelValue: {},
@@ -1038,26 +1038,26 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1038
1038
  required: { type: Boolean }
1039
1039
  },
1040
1040
  emits: ["update:modelValue", "change"],
1041
- setup(p, { emit: i }) {
1042
- const o = p, n = i, a = o.property, d = o.readOnly || a?.readOnly, u = () => {
1041
+ setup(m, { emit: i }) {
1042
+ const o = m, n = i, a = o.property, d = o.readOnly || a?.readOnly, u = () => {
1043
1043
  d || (n("change", !o.modelValue), n("update:modelValue", !o.modelValue));
1044
1044
  };
1045
- return (m, c) => {
1046
- const v = P("clickable");
1047
- return t(), l("div", Oo, [
1048
- K((t(), l("a", {
1045
+ return (f, p) => {
1046
+ const v = N("clickable");
1047
+ return t(), l("div", Co, [
1048
+ J((t(), l("a", {
1049
1049
  class: Q([
1050
1050
  "switch",
1051
- { "switch--active": m.modelValue },
1051
+ { "switch--active": f.modelValue },
1052
1052
  { "switch--readOnly": e(d) }
1053
1053
  ]),
1054
1054
  onClick: Ie(u, ["stop"])
1055
1055
  }, [
1056
- c[0] || (c[0] = S("div", { class: "switch__slider" }, null, -1)),
1057
- S("div", {
1056
+ p[0] || (p[0] = I("div", { class: "switch__slider" }, null, -1)),
1057
+ I("div", {
1058
1058
  class: Q([
1059
1059
  "switch__dummy",
1060
- { "switch__dummy--flex": !m.modelValue }
1060
+ { "switch__dummy--flex": !f.modelValue }
1061
1061
  ])
1062
1062
  }, null, 2)
1063
1063
  ], 2)), [
@@ -1065,14 +1065,14 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1065
1065
  blocked: e(d)
1066
1066
  }]
1067
1067
  ]),
1068
- m.$slots.default ? I(m.$slots, "default", { key: 0 }, void 0, !0) : (t(), l("div", Ao, A(e(a)?.description || m.propertyName), 1))
1068
+ f.$slots.default ? A(f.$slots, "default", { key: 0 }, void 0, !0) : (t(), l("div", Oo, C(e(a)?.description || f.propertyName), 1))
1069
1069
  ]);
1070
1070
  };
1071
1071
  }
1072
- }), So = /* @__PURE__ */ U(Bo, [["__scopeId", "data-v-ae45597d"]]), wo = { class: "picture" }, To = { style: { position: "fixed", top: "50%", left: "50%", transform: "translate(-50%, -50%)" } }, jo = ["src", "alt"], Ro = {
1072
+ }), Bo = /* @__PURE__ */ U(Io, [["__scopeId", "data-v-ae45597d"]]), So = { class: "picture" }, wo = { style: { position: "fixed", top: "50%", left: "50%", transform: "translate(-50%, -50%)" } }, To = ["src", "alt"], jo = {
1073
1073
  key: 0,
1074
1074
  class: "picture__meta"
1075
- }, Lo = ["src"], qo = { key: 5 }, Mo = /* @__PURE__ */ z({
1075
+ }, Ro = ["src"], Lo = { key: 5 }, qo = /* @__PURE__ */ F({
1076
1076
  __name: "aeria-picture",
1077
1077
  props: {
1078
1078
  url: {},
@@ -1086,26 +1086,26 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1086
1086
  width: { default: "100%" },
1087
1087
  height: { default: "100%" }
1088
1088
  },
1089
- setup(p) {
1090
- const i = p, o = W(() => i.fileId ? `${Ze}/file/${i.fileId}/picture` : i.url || i.modelValue), n = J(!1);
1089
+ setup(m) {
1090
+ const i = m, o = Y(() => i.fileId ? `${Pe}/file/${i.fileId}/picture` : i.url || i.modelValue), n = Z(!1);
1091
1091
  return (a, d) => {
1092
- const u = P("overlay");
1093
- return t(), l("figure", wo, [
1094
- o.value && n.value ? (t(), V(Ee, {
1092
+ const u = N("overlay");
1093
+ return t(), l("figure", So, [
1094
+ o.value && n.value ? (t(), k(Ue, {
1095
1095
  key: 0,
1096
1096
  to: "main"
1097
1097
  }, [
1098
- K((t(), l("div", To, [
1099
- S("img", {
1098
+ J((t(), l("div", wo, [
1099
+ I("img", {
1100
1100
  src: o.value,
1101
1101
  alt: a.alt,
1102
1102
  style: {
1103
1103
  maxHeight: "60vh",
1104
1104
  objectFit: "contain"
1105
1105
  },
1106
- onClick: d[0] || (d[0] = (m) => n.value = !0)
1107
- }, null, 8, jo),
1108
- a.meta?.owner ? (t(), l("div", Ro, A(a.t("created_by")) + " " + A(a.meta.owner.name) + " em " + A(a.formatDateTime(a.meta.created_at, { hours: !0 })), 1)) : b("", !0)
1106
+ onClick: d[0] || (d[0] = (f) => n.value = !0)
1107
+ }, null, 8, To),
1108
+ a.meta?.owner ? (t(), l("div", jo, C(a.t("created_by")) + " " + C(a.meta.owner.name) + " em " + C(a.formatDateTime(a.meta.created_at, { hours: !0 })), 1)) : b("", !0)
1109
1109
  ])), [
1110
1110
  [u, {
1111
1111
  layer: 60,
@@ -1123,7 +1123,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1123
1123
  { "picture__image--bordered": a.bordered },
1124
1124
  { "picture__image--expandable": a.expandable }
1125
1125
  ]),
1126
- style: ve({
1126
+ style: fe({
1127
1127
  objectFit: a.objectFit,
1128
1128
  width: a.width,
1129
1129
  height: a.height
@@ -1131,7 +1131,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1131
1131
  onClick: d[1] || (d[1] = () => {
1132
1132
  a.expandable && (n.value = !0);
1133
1133
  })
1134
- }, null, 14, Lo)) : a.$slots.fallback ? I(a.$slots, "fallback", { key: 2 }, void 0, !0) : a.$slots.default ? I(a.$slots, "default", { key: 3 }, void 0, !0) : (t(), l("svg", {
1134
+ }, null, 14, Ro)) : a.$slots.fallback ? A(a.$slots, "fallback", { key: 2 }, void 0, !0) : a.$slots.default ? A(a.$slots, "default", { key: 3 }, void 0, !0) : (t(), l("svg", {
1135
1135
  key: 4,
1136
1136
  class: Q(["picture__background", [
1137
1137
  { "picture__image--bordered": a.bordered }
@@ -1139,13 +1139,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1139
1139
  xmlns: "http://www.w3.org/2000/svg",
1140
1140
  viewBox: "0 0 200 200",
1141
1141
  preserveAspectRatio: "none",
1142
- style: ve({
1142
+ style: fe({
1143
1143
  objectFit: a.objectFit,
1144
1144
  width: a.width,
1145
1145
  height: a.height
1146
1146
  })
1147
1147
  }, d[2] || (d[2] = [
1148
- S("line", {
1148
+ I("line", {
1149
1149
  x1: "0",
1150
1150
  y1: "0",
1151
1151
  x2: "200",
@@ -1153,7 +1153,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1153
1153
  stroke: "#000",
1154
1154
  "vector-effect": "non-scaling-stroke"
1155
1155
  }, null, -1),
1156
- S("line", {
1156
+ I("line", {
1157
1157
  x1: "200",
1158
1158
  y1: "0",
1159
1159
  x2: "0",
@@ -1162,22 +1162,22 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1162
1162
  "vector-effect": "non-scaling-stroke"
1163
1163
  }, null, -1)
1164
1164
  ]), 6)),
1165
- a.$slots.caption ? (t(), l("figcaption", qo, [
1166
- I(a.$slots, "caption", {}, void 0, !0)
1165
+ a.$slots.caption ? (t(), l("figcaption", Lo, [
1166
+ A(a.$slots, "caption", {}, void 0, !0)
1167
1167
  ])) : b("", !0)
1168
1168
  ]);
1169
1169
  };
1170
1170
  }
1171
- }), Le = /* @__PURE__ */ U(Mo, [["__scopeId", "data-v-6705b19f"]]), zo = { class: "item" }, Fo = { class: "item__presentation" }, Eo = {
1171
+ }), Le = /* @__PURE__ */ U(qo, [["__scopeId", "data-v-6705b19f"]]), Mo = { class: "item" }, zo = { class: "item__presentation" }, Fo = {
1172
1172
  key: 1,
1173
1173
  class: "item__name"
1174
- }, Uo = { class: "item__size" }, Ho = /* @__PURE__ */ z({
1174
+ }, Eo = { class: "item__size" }, Uo = /* @__PURE__ */ F({
1175
1175
  __name: "aeria-file-item",
1176
1176
  props: {
1177
1177
  modelValue: {}
1178
1178
  },
1179
- setup(p) {
1180
- const i = p, o = "_id" in i.modelValue ? i.modelValue : i.modelValue.file, n = (a) => {
1179
+ setup(m) {
1180
+ const i = m, o = "_id" in i.modelValue ? i.modelValue : i.modelValue.file, n = (a) => {
1181
1181
  const d = a === 0 ? 0 : Math.floor(Math.log(a) / Math.log(1024));
1182
1182
  return `${(a / Math.pow(1024, d)).toFixed(2)} ${[
1183
1183
  "B",
@@ -1187,8 +1187,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1187
1187
  "TB"
1188
1188
  ][d]}`;
1189
1189
  };
1190
- return (a, d) => (t(), l("div", zo, [
1191
- "_id" in e(o) && e(o).type.startsWith("image/") ? (t(), V(Le, {
1190
+ return (a, d) => (t(), l("div", Mo, [
1191
+ "_id" in e(o) && e(o).type.startsWith("image/") ? (t(), k(Le, {
1192
1192
  key: 0,
1193
1193
  bordered: "",
1194
1194
  expandable: "",
@@ -1196,8 +1196,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1196
1196
  url: e(o).link,
1197
1197
  class: "item__picture"
1198
1198
  }, null, 8, ["alt", "url"])) : b("", !0),
1199
- S("div", Fo, [
1200
- "_id" in e(o) ? (t(), V(G, {
1199
+ I("div", zo, [
1200
+ "_id" in e(o) ? (t(), k(G, {
1201
1201
  key: 0,
1202
1202
  icon: "arrow-square-out",
1203
1203
  href: e(o).link,
@@ -1205,21 +1205,21 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1205
1205
  class: "item__name item__name--link"
1206
1206
  }, {
1207
1207
  default: h(() => [
1208
- D(A(e(o).name), 1)
1208
+ D(C(e(o).name), 1)
1209
1209
  ]),
1210
1210
  _: 1
1211
- }, 8, ["href"])) : (t(), l("div", Eo, A(e(o).name), 1)),
1212
- S("div", Uo, A(n(e(o).size)), 1)
1211
+ }, 8, ["href"])) : (t(), l("div", Fo, C(e(o).name), 1)),
1212
+ I("div", Eo, C(n(e(o).size)), 1)
1213
1213
  ]),
1214
- S("div", null, [
1215
- I(a.$slots, "default", {}, void 0, !0)
1214
+ I("div", null, [
1215
+ A(a.$slots, "default", {}, void 0, !0)
1216
1216
  ])
1217
1217
  ]));
1218
1218
  }
1219
- }), Do = /* @__PURE__ */ U(Ho, [["__scopeId", "data-v-85a82246"]]), Qo = { class: "file" }, Go = ["accept", "multiple"], Wo = {
1219
+ }), Ho = /* @__PURE__ */ U(Uo, [["__scopeId", "data-v-85a82246"]]), Do = { class: "file" }, Qo = ["accept", "multiple"], Go = {
1220
1220
  key: 1,
1221
1221
  class: "file__list"
1222
- }, Yo = /* @__PURE__ */ z({
1222
+ }, Wo = /* @__PURE__ */ F({
1223
1223
  __name: "aeria-file",
1224
1224
  props: {
1225
1225
  modelValue: {},
@@ -1234,72 +1234,72 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1234
1234
  multiple: { type: Boolean }
1235
1235
  },
1236
1236
  emits: ["update:content", "change", "update:modelValue"],
1237
- setup(p, { emit: i }) {
1238
- const o = p, n = o.property && re(o.property), a = i, u = we() ? qe() : null, m = o.multiple || o.property && "type" in o.property && o.property.type === "array", c = W(() => {
1237
+ setup(m, { emit: i }) {
1238
+ const o = m, n = o.property && se(o.property), a = i, u = we() ? qe() : null, f = o.multiple || o.property && "type" in o.property && o.property.type === "array", p = Y(() => {
1239
1239
  if (o.modelValue)
1240
1240
  return Array.isArray(o.modelValue) ? o.modelValue : [o.modelValue];
1241
- }), v = (k) => new Promise((_) => {
1242
- const T = new FileReader();
1243
- T.onload = () => _(T.result), T.readAsArrayBuffer(k);
1244
- }), r = async (k) => {
1245
- const _ = k.target.files;
1246
- if (!_)
1241
+ }), v = (g) => new Promise((y) => {
1242
+ const s = new FileReader();
1243
+ s.onload = () => y(s.result), s.readAsArrayBuffer(g);
1244
+ }), r = async (g) => {
1245
+ const y = g.target.files;
1246
+ if (!y)
1247
1247
  return;
1248
- const T = [];
1249
- for (const s of _) {
1250
- const O = await v(s);
1248
+ const s = [];
1249
+ for (const B of y) {
1250
+ const V = await v(B);
1251
1251
  if (u) {
1252
- const { data: { error: X, result: y } } = await pt(`${Ze}/${u.$id}/upload?name=${s.name}`, O, {
1252
+ const { data: { error: H, result: _ } } = await ct(`${Pe}/${u.$id}/upload?name=${B.name}`, V, {
1253
1253
  params: {
1254
1254
  method: "POST",
1255
1255
  headers: {
1256
- "content-type": s.type || "application/octet-stream",
1256
+ "content-type": B.type || "application/octet-stream",
1257
1257
  "x-stream-request": "1"
1258
1258
  }
1259
1259
  }
1260
1260
  });
1261
- if (X)
1261
+ if (H)
1262
1262
  return;
1263
- T.unshift({
1264
- tempId: y.tempId,
1265
- file: s
1263
+ s.unshift({
1264
+ tempId: _.tempId,
1265
+ file: B
1266
1266
  });
1267
1267
  } else
1268
- T.unshift({
1269
- file: s
1268
+ s.unshift({
1269
+ file: B
1270
1270
  });
1271
1271
  }
1272
- m ? a("update:modelValue", Array.isArray(o.modelValue) ? T.concat(o.modelValue) : T) : a("update:modelValue", T[0]), a("update:content", T), a("change", T);
1273
- }, $ = async (k) => {
1272
+ f ? a("update:modelValue", Array.isArray(o.modelValue) ? s.concat(o.modelValue) : s) : a("update:modelValue", s[0]), a("update:content", s), a("change", s);
1273
+ }, $ = async (g) => {
1274
1274
  if (!o.modelValue)
1275
1275
  throw new Error();
1276
- const _ = Array.isArray(o.modelValue) ? o.modelValue.filter((T, s) => s !== k) : [];
1277
- m ? a("update:modelValue", _) : a("update:modelValue", null), a("update:content", _), a("change", _);
1276
+ const y = Array.isArray(o.modelValue) ? o.modelValue.filter((s, B) => B !== g) : [];
1277
+ f ? a("update:modelValue", y) : a("update:modelValue", null), a("update:content", y), a("change", y);
1278
1278
  };
1279
- return (k, _) => {
1280
- const T = P("clickable");
1281
- return t(), l("div", Qo, [
1282
- k.readOnly ? b("", !0) : (t(), l("input", {
1279
+ return (g, y) => {
1280
+ const s = N("clickable");
1281
+ return t(), l("div", Do, [
1282
+ g.readOnly ? b("", !0) : (t(), l("input", {
1283
1283
  key: 0,
1284
1284
  ref: "file",
1285
1285
  type: "file",
1286
1286
  accept: e(n)?.accept?.join(","),
1287
- multiple: e(m),
1287
+ multiple: e(f),
1288
1288
  onChange: r
1289
- }, null, 40, Go)),
1290
- c.value && c.value.length > 0 ? (t(), l("div", Wo, [
1291
- (t(!0), l(Y, null, E(c.value, (s, O) => (t(), V(Do, {
1292
- key: "_id" in s ? String(s._id) : s.file.name,
1293
- "model-value": s
1289
+ }, null, 40, Qo)),
1290
+ p.value && p.value.length > 0 ? (t(), l("div", Go, [
1291
+ (t(!0), l(X, null, E(p.value, (B, V) => (t(), k(Ho, {
1292
+ key: "_id" in B ? String(B._id) : B.file.name,
1293
+ "model-value": B
1294
1294
  }, {
1295
1295
  default: h(() => [
1296
- k.readOnly ? b("", !0) : K((t(), V(G, {
1296
+ g.readOnly ? b("", !0) : J((t(), k(G, {
1297
1297
  key: 0,
1298
1298
  reactive: "",
1299
1299
  icon: "trash",
1300
- onClick: (X) => $(O)
1300
+ onClick: (H) => $(V)
1301
1301
  }, null, 8, ["onClick"])), [
1302
- [T]
1302
+ [s]
1303
1303
  ])
1304
1304
  ]),
1305
1305
  _: 2
@@ -1308,36 +1308,36 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1308
1308
  ]);
1309
1309
  };
1310
1310
  }
1311
- }), Ko = /* @__PURE__ */ U(Yo, [["__scopeId", "data-v-9950a715"]]), Xo = { class: "container" }, Jo = {
1311
+ }), Yo = /* @__PURE__ */ U(Wo, [["__scopeId", "data-v-9950a715"]]), Ko = { class: "container" }, Xo = {
1312
1312
  key: 1,
1313
1313
  class: "container__footer"
1314
- }, Zo = /* @__PURE__ */ z({
1314
+ }, Jo = /* @__PURE__ */ F({
1315
1315
  __name: "aeria-search-container",
1316
1316
  props: {
1317
1317
  observeScroll: { type: Boolean }
1318
1318
  },
1319
1319
  emits: ["endReached"],
1320
- setup(p, { emit: i }) {
1321
- const o = p, n = i, a = J(null), d = o.observeScroll ? He(a, {
1320
+ setup(m, { emit: i }) {
1321
+ const o = m, n = i, a = Z(null), d = o.observeScroll ? De(a, {
1322
1322
  antecipate: 100
1323
1323
  }).reachedEnd : null;
1324
- return d !== null && ne(d, (u) => {
1324
+ return d !== null && oe(d, (u) => {
1325
1325
  u && n("endReached", u);
1326
- }), (u, m) => (t(), l("div", Xo, [
1326
+ }), (u, f) => (t(), l("div", Ko, [
1327
1327
  u.$slots.default ? (t(), l("div", {
1328
1328
  key: 0,
1329
1329
  ref_key: "containerEl",
1330
1330
  ref: a,
1331
1331
  class: "container__content"
1332
1332
  }, [
1333
- I(u.$slots, "default", {}, void 0, !0)
1333
+ A(u.$slots, "default", {}, void 0, !0)
1334
1334
  ], 512)) : b("", !0),
1335
- u.$slots.footer ? (t(), l("div", Jo, [
1336
- I(u.$slots, "footer", {}, void 0, !0)
1335
+ u.$slots.footer ? (t(), l("div", Xo, [
1336
+ A(u.$slots, "footer", {}, void 0, !0)
1337
1337
  ])) : b("", !0)
1338
1338
  ]));
1339
1339
  }
1340
- }), We = /* @__PURE__ */ U(Zo, [["__scopeId", "data-v-c86e2d2a"]]), Po = { class: "item__values" }, No = /* @__PURE__ */ z({
1340
+ }), Ye = /* @__PURE__ */ U(Jo, [["__scopeId", "data-v-c86e2d2a"]]), Zo = { class: "item__values" }, Po = /* @__PURE__ */ F({
1341
1341
  __name: "aeria-search-item",
1342
1342
  props: {
1343
1343
  item: {},
@@ -1347,22 +1347,22 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1347
1347
  readOnly: { type: Boolean }
1348
1348
  },
1349
1349
  emits: ["update:modelValue", "change"],
1350
- setup(p, { emit: i }) {
1351
- const o = Ve(), n = p, a = i, d = n.property, u = re(d);
1350
+ setup(m, { emit: i }) {
1351
+ const o = Ce(), n = m, a = i, d = n.property, u = se(d);
1352
1352
  qe();
1353
- const m = W(() => n.modelValue ? Array.isArray(n.modelValue) ? Array.isArray(n.modelValue) && Object.values(n.modelValue).some(({ _id: $ }) => n.item._id === $) : n.modelValue._id === n.item._id : !1), c = () => {
1354
- if (m.value)
1353
+ const f = Y(() => n.modelValue ? Array.isArray(n.modelValue) ? Array.isArray(n.modelValue) && Object.values(n.modelValue).some(({ _id: $ }) => n.item._id === $) : n.modelValue._id === n.item._id : !1), p = () => {
1354
+ if (f.value)
1355
1355
  return;
1356
- const $ = (_) => _.filter((T) => !!T._id);
1357
- let k;
1358
- "items" in d ? n.modelValue ? k = $(Array.isArray(n.modelValue) ? n.modelValue : [n.modelValue]) : k = [] : k = n.modelValue, Array.isArray(k) ? a("update:modelValue", k.concat([n.item])) : a("update:modelValue", n.item), a("change", n.item);
1356
+ const $ = (y) => y.filter((s) => !!s._id);
1357
+ let g;
1358
+ "items" in d ? n.modelValue ? g = $(Array.isArray(n.modelValue) ? n.modelValue : [n.modelValue]) : g = [] : g = n.modelValue, Array.isArray(g) ? a("update:modelValue", g.concat([n.item])) : a("update:modelValue", n.item), a("change", n.item);
1359
1359
  }, v = async ($) => {
1360
1360
  u.purge && $?.purge;
1361
- const k = () => {
1362
- const _ = Array.isArray(n.modelValue) ? Array.from(n.modelValue) : [], T = _.findIndex((s) => s._id === n.item._id);
1363
- return _.splice(T, 1), _;
1361
+ const g = () => {
1362
+ const y = Array.isArray(n.modelValue) ? Array.from(n.modelValue) : [], s = y.findIndex((B) => B._id === n.item._id);
1363
+ return y.splice(s, 1), y;
1364
1364
  };
1365
- a("update:modelValue", "items" in d ? k() : null);
1365
+ a("update:modelValue", "items" in d ? g() : null);
1366
1366
  }, r = () => {
1367
1367
  if (n.readOnly) {
1368
1368
  o.push({
@@ -1370,38 +1370,38 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1370
1370
  });
1371
1371
  return;
1372
1372
  }
1373
- return m.value ? v() : c();
1373
+ return f.value ? v() : p();
1374
1374
  };
1375
- return ($, k) => {
1376
- const _ = P("clickable");
1377
- return K((t(), l("div", {
1375
+ return ($, g) => {
1376
+ const y = N("clickable");
1377
+ return J((t(), l("div", {
1378
1378
  class: Q({
1379
1379
  item: !0,
1380
- "item--selected": m.value
1380
+ "item--selected": f.value
1381
1381
  }),
1382
1382
  onClick: r
1383
1383
  }, [
1384
- I($.$slots, "default", {}, void 0, !0),
1385
- S("div", Po, [
1386
- (t(!0), l(Y, null, E($.indexes, (T, s) => (t(), l("div", {
1387
- key: `index-${$.item._id}-${s}`,
1384
+ A($.$slots, "default", {}, void 0, !0),
1385
+ I("div", Zo, [
1386
+ (t(!0), l(X, null, E($.indexes, (s, B) => (t(), l("div", {
1387
+ key: `index-${$.item._id}-${B}`,
1388
1388
  class: "item__value"
1389
- }, A($.item[T]), 1))), 128))
1389
+ }, C($.item[s]), 1))), 128))
1390
1390
  ]),
1391
- $.readOnly ? (t(), V(G, {
1391
+ $.readOnly ? (t(), k(G, {
1392
1392
  key: 0,
1393
1393
  icon: "arrow-square-out",
1394
1394
  style: { "--icon-color": "var(--theme-brand-color-contrast)" }
1395
1395
  })) : b("", !0)
1396
1396
  ], 2)), [
1397
- [_]
1397
+ [y]
1398
1398
  ]);
1399
1399
  };
1400
1400
  }
1401
- }), ze = /* @__PURE__ */ U(No, [["__scopeId", "data-v-63761718"]]), xo = { class: "search__panel" }, en = { key: 1 }, tn = { key: 0 }, on = { key: 1 }, nn = { class: "search__summary" }, an = {
1401
+ }), ze = /* @__PURE__ */ U(Po, [["__scopeId", "data-v-63761718"]]), No = { class: "search__panel" }, xo = { key: 1 }, en = { key: 0 }, tn = { key: 1 }, on = { class: "search__summary" }, nn = {
1402
1402
  key: 1,
1403
1403
  class: "search"
1404
- }, ln = { key: 0 }, je = 10, sn = /* @__PURE__ */ z({
1404
+ }, an = { key: 0 }, je = 10, ln = /* @__PURE__ */ F({
1405
1405
  __name: "aeria-search",
1406
1406
  props: {
1407
1407
  modelValue: {},
@@ -1415,101 +1415,101 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1415
1415
  panel: { default: void 0 }
1416
1416
  },
1417
1417
  emits: ["update:modelValue", "change", "update:panel"],
1418
- setup(p, { emit: i }) {
1419
- const o = p, n = te("meta"), a = re(o.property), d = o.panel !== void 0 ? W(() => o.panel) : J(!1), u = i, m = te(re(o.property).$ref), c = we(), v = c ? qe() : null, r = a.indexes;
1420
- fe(Te, re(o.property).$ref), fe("innerInputLabel", !0), fe("omitInputLabels", !0);
1421
- const $ = J(o.modelValue), k = J({
1418
+ setup(m, { emit: i }) {
1419
+ const o = m, n = te("meta"), a = se(o.property), d = o.panel !== void 0 ? Y(() => o.panel) : Z(!1), u = i, f = te(se(o.property).$ref), p = we(), v = p ? qe() : null, r = a.indexes;
1420
+ me(Te, se(o.property).$ref), me("innerInputLabel", !0), me("omitInputLabels", !0);
1421
+ const $ = Z(o.modelValue), g = Z({
1422
1422
  data: [],
1423
1423
  pagination: {}
1424
- }), _ = W(() => k.value.data), T = W(() => k.value.pagination), s = J(0), O = J(!1), X = J(""), y = () => {
1425
- const C = {};
1426
- if (c) {
1427
- const Z = e(c);
1428
- C[Z] = v;
1424
+ }), y = Y(() => g.value.data), s = Y(() => g.value.pagination), B = Z(0), V = Z(!1), H = Z(""), _ = () => {
1425
+ const L = {};
1426
+ if (p) {
1427
+ const P = e(p);
1428
+ L[P] = v;
1429
1429
  }
1430
- return a.constraints ? ht(a.constraints, C) : {};
1430
+ return a.constraints ? _t(a.constraints, L) : {};
1431
1431
  }, q = () => {
1432
- _.value.length < T.value.recordsTotal && (s.value += 1, N());
1433
- }, ee = async () => X.value.length === 0 ? m.$actions.custom("getAll", {
1432
+ y.value.length < s.value.recordsTotal && (B.value += 1, x());
1433
+ }, ie = async () => H.value.length === 0 ? f.$actions.custom("getAll", {
1434
1434
  limit: je,
1435
- offset: s.value * je,
1436
- filters: y()
1437
- }) : m.$actions.custom("getAll", {
1435
+ offset: B.value * je,
1436
+ filters: _()
1437
+ }) : f.$actions.custom("getAll", {
1438
1438
  limit: je,
1439
- offset: s.value * je,
1439
+ offset: B.value * je,
1440
1440
  filters: {
1441
1441
  $text: {
1442
- $search: `"${X.value}"`,
1442
+ $search: `"${H.value}"`,
1443
1443
  $caseSensitive: !1
1444
1444
  },
1445
- ...y()
1445
+ ..._()
1446
1446
  }
1447
- }), N = async () => {
1448
- if (m.loading.getAll)
1447
+ }), x = async () => {
1448
+ if (f.loading.getAll)
1449
1449
  return;
1450
- const { error: C, result: Z } = await ee();
1451
- if (C) {
1450
+ const { error: L, result: P } = await ie();
1451
+ if (L) {
1452
1452
  n.$actions.spawnToast({
1453
1453
  text: "Request failed",
1454
1454
  icon: "warning"
1455
1455
  });
1456
1456
  return;
1457
1457
  }
1458
- k.value.pagination = Z.pagination, s.value === 0 && k.value.data.splice(0), k.value.data.push(...Z.data);
1459
- }, [oe] = Pe({
1458
+ g.value.pagination = P.pagination, B.value === 0 && g.value.data.splice(0), g.value.data.push(...P.data);
1459
+ }, [re] = Fe({
1460
1460
  delay: 800
1461
1461
  })(() => {
1462
- s.value = 0, N(), O.value = !1;
1462
+ B.value = 0, x(), V.value = !1;
1463
1463
  }), be = () => {
1464
- O.value = !0, oe();
1465
- }, Oe = () => {
1466
- "effect" in d ? u("update:panel", !0) : d.value = !0, N();
1467
- }, pe = () => {
1468
- s.value = 0, k.value.data.splice(0), "effect" in d ? u("update:panel", !1) : d.value = !1;
1464
+ V.value = !0, re();
1465
+ }, $e = () => {
1466
+ "effect" in d ? u("update:panel", !0) : d.value = !0, x();
1467
+ }, ce = () => {
1468
+ B.value = 0, g.value.data.splice(0), "effect" in d ? u("update:panel", !1) : d.value = !1;
1469
1469
  };
1470
- ne(() => X.value.length, (C, Z) => {
1471
- C && !Z && N();
1472
- }), Ue(() => {
1473
- o.selectOnly && N();
1470
+ oe(() => H.value.length, (L, P) => {
1471
+ L && !P && x();
1472
+ }), He(() => {
1473
+ o.selectOnly && x();
1474
1474
  });
1475
- const ae = (C) => {
1476
- $.value = C, o.selectOnly || u("update:modelValue", C);
1477
- }, w = () => {
1478
- pe(), u("update:modelValue", $.value);
1475
+ const O = (L) => {
1476
+ $.value = L, o.selectOnly || u("update:modelValue", L);
1477
+ }, T = () => {
1478
+ ce(), u("update:modelValue", $.value);
1479
1479
  };
1480
- return (C, Z) => {
1481
- const f = P("clickable");
1480
+ return (L, P) => {
1481
+ const c = N("clickable");
1482
1482
  return t(), l("div", null, [
1483
- e(d) ? (t(), V(Ee, {
1483
+ e(d) ? (t(), k(Ue, {
1484
1484
  key: 0,
1485
1485
  to: "main"
1486
1486
  }, [
1487
- L(Ce, {
1487
+ M(Oe, {
1488
1488
  float: "",
1489
1489
  "close-hint": "",
1490
- title: `${e(j)("action.select", { capitalize: !0 })} ${e(j)(C.propertyName)}`,
1490
+ title: `${e(j)("action.select", { capitalize: !0 })} ${e(j)(L.propertyName)}`,
1491
1491
  "overlay-layer": 65,
1492
1492
  "model-value": e(d),
1493
1493
  style: { "--panel-max-width": "36rem" },
1494
- onClose: pe,
1495
- onOverlayClick: pe
1494
+ onClose: ce,
1495
+ onOverlayClick: ce
1496
1496
  }, {
1497
1497
  footer: h(() => [
1498
- L(se, {
1498
+ M(ae, {
1499
1499
  large: "",
1500
- onClick: w
1500
+ onClick: T
1501
1501
  }, {
1502
1502
  default: h(() => [
1503
- D(A(e(j)("action.save", { capitalize: !0 })), 1)
1503
+ D(C(e(j)("action.save", { capitalize: !0 })), 1)
1504
1504
  ]),
1505
1505
  _: 1
1506
1506
  })
1507
1507
  ]),
1508
1508
  default: h(() => [
1509
- S("div", xo, [
1510
- L(he, M({
1511
- modelValue: X.value,
1512
- "onUpdate:modelValue": Z[0] || (Z[0] = (g) => X.value = g)
1509
+ I("div", No, [
1510
+ M(he, z({
1511
+ modelValue: H.value,
1512
+ "onUpdate:modelValue": P[0] || (P[0] = (w) => H.value = w)
1513
1513
  }, {
1514
1514
  property: {
1515
1515
  type: "string",
@@ -1517,69 +1517,69 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1517
1517
  inputType: "search"
1518
1518
  }
1519
1519
  }, { onInput: be }), null, 16, ["modelValue"]),
1520
- _.value.length ? (t(), V(We, {
1520
+ y.value.length ? (t(), k(Ye, {
1521
1521
  key: 0,
1522
1522
  "observe-scroll": "",
1523
1523
  onEndReached: q
1524
1524
  }, {
1525
1525
  default: h(() => [
1526
- (t(!0), l(Y, null, E(_.value, (g) => (t(), V(ze, M({ ref_for: !0 }, {
1527
- item: g,
1526
+ (t(!0), l(X, null, E(y.value, (w) => (t(), k(ze, z({ ref_for: !0 }, {
1527
+ item: w,
1528
1528
  indexes: e(r),
1529
- property: C.property
1529
+ property: L.property
1530
1530
  }, {
1531
- key: `matching-${g._id}`,
1531
+ key: `matching-${w._id}`,
1532
1532
  modelValue: $.value,
1533
- "onUpdate:modelValue": Z[1] || (Z[1] = (F) => $.value = F)
1533
+ "onUpdate:modelValue": P[1] || (P[1] = (K) => $.value = K)
1534
1534
  }), null, 16, ["modelValue"]))), 128))
1535
1535
  ]),
1536
1536
  _: 1
1537
- })) : (t(), l("div", en, [
1538
- O.value ? (t(), l("div", tn, A(e(j)("searching", { capitalize: !0 })) + "... ", 1)) : !e(m).loading.getAll && Object.values(X.value).filter((g) => !!g).length > 0 && !("items" in C.property && C.modelValue?.length || !Array.isArray(C.modelValue) && C.modelValue?._id) ? (t(), l("div", on, A(e(j)("no_results", { capitalize: !0 })), 1)) : b("", !0)
1537
+ })) : (t(), l("div", xo, [
1538
+ V.value ? (t(), l("div", en, C(e(j)("searching", { capitalize: !0 })) + "... ", 1)) : !e(f).loading.getAll && Object.values(H.value).filter((w) => !!w).length > 0 && !("items" in L.property && L.modelValue?.length || !Array.isArray(L.modelValue) && L.modelValue?._id) ? (t(), l("div", tn, C(e(j)("no_results", { capitalize: !0 })), 1)) : b("", !0)
1539
1539
  ]))
1540
1540
  ]),
1541
- S("div", nn, A(e(j)("showing", { capitalize: !0 })) + " " + A(_.value.length) + " " + A(e(j)("of")) + " " + A(T.value.recordsTotal), 1)
1541
+ I("div", on, C(e(j)("showing", { capitalize: !0 })) + " " + C(y.value.length) + " " + C(e(j)("of")) + " " + C(s.value.recordsTotal), 1)
1542
1542
  ]),
1543
1543
  _: 1
1544
1544
  }, 8, ["title", "model-value"])
1545
1545
  ])) : b("", !0),
1546
- C.selectOnly ? b("", !0) : (t(), l("div", an, [
1547
- L(We, null, ie({
1546
+ L.selectOnly ? b("", !0) : (t(), l("div", nn, [
1547
+ M(Ye, null, le({
1548
1548
  default: h(() => [
1549
- "items" in C.property ? (t(), l("div", ln, [
1550
- (t(!0), l(Y, null, E(C.modelValue, (g) => (t(), V(ze, M({ ref_for: !0 }, {
1551
- item: g,
1549
+ "items" in L.property ? (t(), l("div", an, [
1550
+ (t(!0), l(X, null, E(L.modelValue, (w) => (t(), k(ze, z({ ref_for: !0 }, {
1551
+ item: w,
1552
1552
  indexes: e(r),
1553
- property: C.property,
1554
- readOnly: C.readOnly,
1555
- modelValue: C.modelValue
1553
+ property: L.property,
1554
+ readOnly: L.readOnly,
1555
+ modelValue: L.modelValue
1556
1556
  }, {
1557
- key: `selected-${g._id}`,
1558
- "onUpdate:modelValue": ae
1557
+ key: `selected-${w._id}`,
1558
+ "onUpdate:modelValue": O
1559
1559
  }), null, 16))), 128))
1560
- ])) : C.modelValue?._id ? (t(), V(ze, M({ key: 1 }, {
1561
- item: C.modelValue,
1560
+ ])) : L.modelValue?._id ? (t(), k(ze, z({ key: 1 }, {
1561
+ item: L.modelValue,
1562
1562
  indexes: e(r),
1563
1563
  property: e(a),
1564
- readOnly: C.readOnly,
1565
- modelValue: C.modelValue
1566
- }, { "onUpdate:modelValue": ae }), null, 16)) : b("", !0)
1564
+ readOnly: L.readOnly,
1565
+ modelValue: L.modelValue
1566
+ }, { "onUpdate:modelValue": O }), null, 16)) : b("", !0)
1567
1567
  ]),
1568
1568
  _: 2
1569
1569
  }, [
1570
- C.readOnly ? void 0 : {
1570
+ L.readOnly ? void 0 : {
1571
1571
  name: "footer",
1572
1572
  fn: h(() => [
1573
- K((t(), V(G, {
1573
+ J((t(), k(G, {
1574
1574
  icon: "plus",
1575
- onClick: Oe
1575
+ onClick: $e
1576
1576
  }, {
1577
1577
  default: h(() => [
1578
- D(A(e(j)("action.select", { capitalize: !0 })), 1)
1578
+ D(C(e(j)("action.select", { capitalize: !0 })), 1)
1579
1579
  ]),
1580
1580
  _: 1
1581
1581
  })), [
1582
- [f]
1582
+ [c]
1583
1583
  ])
1584
1584
  ]),
1585
1585
  key: "0"
@@ -1589,13 +1589,13 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1589
1589
  ]);
1590
1590
  };
1591
1591
  }
1592
- }), rn = /* @__PURE__ */ U(sn, [["__scopeId", "data-v-7a35daa0"]]), Ye = (p, i) => {
1593
- const o = "items" in p ? p.items : p, n = {
1594
- options: Co,
1595
- select: Qe,
1596
- switch: So,
1597
- file: Ko,
1598
- search: rn,
1592
+ }), sn = /* @__PURE__ */ U(ln, [["__scopeId", "data-v-7a35daa0"]]), Ke = (m, i) => {
1593
+ const o = "items" in m ? m.items : m, n = {
1594
+ options: Vo,
1595
+ select: Ge,
1596
+ switch: Bo,
1597
+ file: Yo,
1598
+ search: sn,
1599
1599
  input: he,
1600
1600
  form: Me
1601
1601
  }, a = (() => {
@@ -1605,42 +1605,42 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1605
1605
  if (o.type === "boolean")
1606
1606
  return "switch";
1607
1607
  }
1608
- if ("element" in p) {
1609
- if (p.element === "checkbox" || p.element === "radio")
1608
+ if ("element" in m) {
1609
+ if (m.element === "checkbox" || m.element === "radio")
1610
1610
  return "options";
1611
- if (p.element === "select")
1611
+ if (m.element === "select")
1612
1612
  return "select";
1613
1613
  }
1614
- const d = re(p);
1615
- return d ? d.inline ? "form" : d.$ref === "file" ? "file" : "search" : "items" in p && p.uniqueItems ? "options" : "enum" in o ? "select" : "input";
1614
+ const d = se(m);
1615
+ return d ? d.inline ? "form" : d.$ref === "file" ? "file" : "search" : "items" in m && m.uniqueItems ? "options" : "enum" in o ? "select" : "input";
1616
1616
  })();
1617
1617
  return i[a] ? i[a] : n[a];
1618
- }, un = (p, i, o) => {
1619
- p ??= [];
1618
+ }, rn = (m, i, o) => {
1619
+ m ??= [];
1620
1620
  const n = "items" in i ? i.items : i;
1621
1621
  if ("$ref" in n) {
1622
- const a = te(n.$ref, o), d = ge(a.$freshItem);
1623
- return p.push(d);
1622
+ const a = te(n.$ref, o), d = ke(a.$freshItem);
1623
+ return m.push(d);
1624
1624
  }
1625
- return "properties" in n ? p.push(bt(n)) : "type" in n && n.type === "boolean" ? p.push({}) : p.push(null);
1626
- }, dn = (p, i) => {
1627
- p.splice(i, 1);
1628
- }, cn = {
1625
+ return "properties" in n ? m.push(ht(n)) : "type" in n && n.type === "boolean" ? m.push({}) : m.push(null);
1626
+ }, un = (m, i) => {
1627
+ m.splice(i, 1);
1628
+ }, dn = {
1629
1629
  key: 0,
1630
1630
  class: "form__header"
1631
- }, pn = { class: "form__fieldset" }, mn = { key: 0 }, fn = ["innerHTML"], vn = ["onInput"], yn = { key: 4 }, _n = { value: "true" }, hn = { value: "false" }, bn = {
1631
+ }, cn = { class: "form__fieldset" }, pn = { key: 0 }, mn = ["innerHTML"], fn = ["onInput"], vn = { key: 4 }, yn = { value: "true" }, _n = { value: "false" }, hn = {
1632
1632
  key: 5,
1633
1633
  style: { display: "grid", "row-gap": ".4rem" }
1634
- }, $n = { key: 0 }, gn = {
1634
+ }, bn = { key: 0 }, $n = {
1635
1635
  key: 1,
1636
1636
  class: "form__array"
1637
- }, kn = {
1637
+ }, gn = {
1638
1638
  key: 7,
1639
1639
  class: "form__validation-error"
1640
- }, Vn = { key: 0 }, Cn = { key: 1 }, On = {
1640
+ }, kn = { key: 0 }, Vn = { key: 1 }, Cn = {
1641
1641
  key: 2,
1642
1642
  class: "form__footer"
1643
- }, An = /* @__PURE__ */ z({
1643
+ }, On = /* @__PURE__ */ F({
1644
1644
  __name: "aeria-form",
1645
1645
  props: {
1646
1646
  modelValue: {},
@@ -1667,313 +1667,313 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1667
1667
  includeTimestamps: { type: Boolean }
1668
1668
  },
1669
1669
  emits: ["update:modelValue", "input", "change", "clipboardCopy"],
1670
- setup(p, { emit: i }) {
1671
- const o = De(), n = p, a = i;
1672
- Je(() => {
1670
+ setup(m, { emit: i }) {
1671
+ const o = Qe(), n = m, a = i;
1672
+ Ze(() => {
1673
1673
  n.modelValue || a("update:modelValue", n.property && "items" in n.property ? [] : {});
1674
1674
  });
1675
- const d = n.property && re(n.property), u = d ? d.$ref : n.collection || we(), m = n.readOnly || n.property?.readOnly, c = u ? te(e(u)) : null;
1675
+ const d = n.property && se(n.property), u = d ? d.$ref : n.collection || we(), f = n.readOnly || n.property?.readOnly, p = u ? te(e(u)) : null;
1676
1676
  !u && process.env.NODE_ENV !== "production" && console.warn("aeria-form was used without providing storeId or specifying collection prop, some features may not work as intended");
1677
- const v = J(!1), r = W(() => {
1678
- const f = !n.form && n.property ? "type" in n.property && n.property.type === "object" ? "properties" in n.property ? n.property.properties : void 0 : c?.properties : n.form;
1679
- if (!f)
1677
+ const v = Z(!1), r = Y(() => {
1678
+ const c = !n.form && n.property ? "type" in n.property && n.property.type === "object" ? "properties" in n.property ? n.property.properties : void 0 : p?.properties : n.form;
1679
+ if (!c)
1680
1680
  return;
1681
- const g = {};
1682
- if (n.includeId && (g._id = {
1681
+ const w = {};
1682
+ if (n.includeId && (w._id = {
1683
1683
  type: "string",
1684
1684
  readOnly: !0
1685
1685
  }), n.includeTimestamps) {
1686
- const F = {
1686
+ const K = {
1687
1687
  type: "string",
1688
1688
  format: "date-time",
1689
1689
  readOnly: !0,
1690
1690
  isTimestamp: !0
1691
1691
  };
1692
- f.created_at || (g.created_at = F), f.created_at || (g.updated_at = F);
1692
+ c.created_at || (w.created_at = K), c.created_at || (w.updated_at = K);
1693
1693
  }
1694
- return Object.assign(g, f), g;
1695
- }), $ = W(() => n.layout || c?.description.formLayout), k = (f) => {
1696
- const g = ue(f, n[f]);
1697
- return n[f] && fe(f, n[f]), g;
1698
- }, _ = W(() => n.validationErrors !== null ? n.validationErrors : c?.validationErrors), T = k("formComponents") || {}, s = k("propertyComponents") || {}, O = k("omitFormHeader"), X = k("omitInputLabels"), y = k("innerInputLabel");
1699
- u && fe(Te, u), fe("searchOnly", n.searchOnly);
1700
- const q = (f) => r.value ? Object.entries(r.value).filter(([g, F]) => !F.noForm && f([
1701
- g,
1702
- F
1703
- ])) : null, ee = (f, g) => {
1704
- if (n.searchOnly || !u || n.includeId && f === "_id" || n.includeTimestamps && g.isTimestamp)
1694
+ return Object.assign(w, c), w;
1695
+ }), $ = Y(() => n.layout || p?.description.formLayout), g = (c) => {
1696
+ const w = ue(c, n[c]);
1697
+ return n[c] && me(c, n[c]), w;
1698
+ }, y = Y(() => n.validationErrors !== null ? n.validationErrors : p?.validationErrors), s = g("formComponents") || {}, B = g("propertyComponents") || {}, V = g("omitFormHeader"), H = g("omitInputLabels"), _ = g("innerInputLabel");
1699
+ u && me(Te, u), me("searchOnly", n.searchOnly);
1700
+ const q = (c) => r.value ? Object.entries(r.value).filter(([w, K]) => !K.noForm && c([
1701
+ w,
1702
+ K
1703
+ ])) : null, ie = (c, w) => {
1704
+ if (n.searchOnly || !u || n.includeId && c === "_id" || n.includeTimestamps && w.isTimestamp)
1705
1705
  return !0;
1706
- const F = n.property && "properties" in n.property ? n.property.form : c?.description?.form;
1707
- return !F || F.includes(f);
1708
- }, N = q(([f, g]) => ee(f, g)), oe = Se(), be = {}, Oe = (f, g) => {
1709
- const F = [], x = $.value?.fields?.[f] || $.value?.fields?.$default;
1710
- if (!g)
1706
+ const K = n.property && "properties" in n.property ? n.property.form : p?.description?.form;
1707
+ return !K || K.includes(c);
1708
+ }, x = q(([c, w]) => ie(c, w)), re = Se(), be = {}, $e = (c, w) => {
1709
+ const K = [], ee = $.value?.fields?.[c] || $.value?.fields?.$default;
1710
+ if (!w)
1711
1711
  return;
1712
- if (x?.if && !n.searchOnly) {
1712
+ if (ee?.if && !n.searchOnly) {
1713
1713
  const R = Re(
1714
1714
  n.modelValue,
1715
- x.if
1715
+ ee.if
1716
1716
  );
1717
- R.satisfied || (be[f] && (c ? n.modelValue[f] = typeof c.$freshItem[f] == "object" ? ge(c.$freshItem[f]) : c.$freshItem[f] : n.modelValue[f] = [
1717
+ R.satisfied || (be[c] && (p ? n.modelValue[c] = typeof p.$freshItem[c] == "object" ? ke(p.$freshItem[c]) : p.$freshItem[c] : n.modelValue[c] = [
1718
1718
  void 0,
1719
1719
  null
1720
- ].includes(n.modelValue[f]) ? null : n.modelValue[f].constructor()), F.push("display: none")), be[f] = R.satisfied;
1720
+ ].includes(n.modelValue[c]) ? null : n.modelValue[c].constructor()), K.push("display: none")), be[c] = R.satisfied;
1721
1721
  }
1722
- const B = oe.value.md && x?.span || 6;
1723
- return F.push(`--field-span: ${B}`, "grid-column: span var(--field-span) / span var(--field-span)"), x && (x.verticalSpacing && F.push([
1724
- `--vertical-spacing: ${x.verticalSpacing}`,
1722
+ const S = re.value.md && ee?.span || 6;
1723
+ return K.push(`--field-span: ${S}`, "grid-column: span var(--field-span) / span var(--field-span)"), ee && (ee.verticalSpacing && K.push([
1724
+ `--vertical-spacing: ${ee.verticalSpacing}`,
1725
1725
  "padding: var(--vertical-spacing) 0"
1726
- ]), x.separator && F.push([
1726
+ ]), ee.separator && K.push([
1727
1727
  "border-top: 1px solid var(--theme-border-color)",
1728
1728
  "border-width: 1px 0 1px 0",
1729
1729
  "padding: 1rem 0",
1730
1730
  "margin: 1rem 0"
1731
- ])), F.join(";");
1732
- }, pe = (f) => f === null || f instanceof Object && !Object.keys(f).length, ae = W(() => n.required ? n.required : n.property && "required" in n.property ? n.property.required : c?.description.required), w = W(() => n.form ? $t(
1731
+ ])), K.join(";");
1732
+ }, ce = (c) => c === null || c instanceof Object && !Object.keys(c).length, O = Y(() => n.required ? n.required : n.property && "required" in n.property ? n.property.required : p?.description.required), T = Y(() => n.form ? bt(
1733
1733
  n.modelValue,
1734
1734
  n.form,
1735
- ae.value,
1736
- c?.description
1737
- ) : !0), C = (f, g) => _.value?.[f] && (typeof _.value[f].index != "number" || _.value[f].index === g) ? _.value[f].errors : null, Z = (f) => {
1738
- if (!(m || f.readOnly) && !n.parentPropertyName && !n.parentCollection && !v.value)
1735
+ O.value,
1736
+ p?.description
1737
+ ) : !0), L = (c, w) => y.value?.[c] && (typeof y.value[c].index != "number" || y.value[c].index === w) ? y.value[c].errors : null, P = (c) => {
1738
+ if (!(f || c.readOnly) && !n.parentPropertyName && !n.parentCollection && !v.value)
1739
1739
  return v.value = !0, !0;
1740
1740
  };
1741
- return (f, g) => {
1742
- const F = P("clickable"), x = P("focus");
1741
+ return (c, w) => {
1742
+ const K = N("clickable"), ee = N("focus");
1743
1743
  return t(), l("form", {
1744
1744
  class: "form",
1745
- style: ve(`row-gap: ${e(O) ? ".8rem" : "var(--form-internal-gap, 1.6rem);"};`)
1745
+ style: fe(`row-gap: ${e(V) ? ".8rem" : "var(--form-internal-gap, 1.6rem);"};`)
1746
1746
  }, [
1747
- f.$slots.header && !e(O) ? (t(), l("header", cn, [
1748
- I(f.$slots, "header", {}, void 0, !0)
1747
+ c.$slots.header && !e(V) ? (t(), l("header", dn, [
1748
+ A(c.$slots, "header", {}, void 0, !0)
1749
1749
  ])) : b("", !0),
1750
- I(f.$slots, "default", {}, void 0, !0),
1751
- S("fieldset", pn, [
1752
- (t(!0), l(Y, null, E(e(N), ([B, R]) => (t(), l("div", {
1753
- key: `field-${B}`,
1754
- style: ve(Oe(B, R)),
1750
+ A(c.$slots, "default", {}, void 0, !0),
1751
+ I("fieldset", cn, [
1752
+ (t(!0), l(X, null, E(e(x), ([S, R]) => (t(), l("div", {
1753
+ key: `field-${S}`,
1754
+ style: fe($e(S, R)),
1755
1755
  class: Q({
1756
1756
  form__field: !0,
1757
1757
  "form__field--form": "properties" in R
1758
1758
  })
1759
1759
  }, [
1760
- (!("type" in R) || R.type !== "boolean" || f.searchOnly) && !R.noLabel && !e(X) && !e(y) ? (t(), l("label", mn, [
1761
- S("div", {
1760
+ (!("type" in R) || R.type !== "boolean" || c.searchOnly) && !R.noLabel && !e(H) && !e(_) ? (t(), l("label", pn, [
1761
+ I("div", {
1762
1762
  class: Q({
1763
1763
  "form__field-label": !0,
1764
1764
  "form__field-label--section": "items" in R ? "properties" in R.items : "properties" in R,
1765
- "form__field-required-hint": f.highlightRequired && !e(m) && !f.searchOnly && (!ae.value || e(Ge)(B, ae.value, f.modelValue))
1765
+ "form__field-required-hint": c.highlightRequired && !e(f) && !c.searchOnly && (!O.value || e(We)(S, O.value, c.modelValue))
1766
1766
  })
1767
- }, A(R.description || e(j)(B)), 3),
1767
+ }, C(R.description || e(j)(S)), 3),
1768
1768
  R.hint ? (t(), l("div", {
1769
1769
  key: 0,
1770
1770
  innerHTML: R.hint
1771
- }, null, 8, fn)) : b("", !0)
1771
+ }, null, 8, mn)) : b("", !0)
1772
1772
  ])) : b("", !0),
1773
- f.$slots[`field-${B}`] ? I(f.$slots, `field-${B}`, M({
1773
+ c.$slots[`field-${S}`] ? A(c.$slots, `field-${S}`, z({
1774
1774
  key: 1,
1775
1775
  ref_for: !0
1776
1776
  }, {
1777
- readOnly: e(m),
1777
+ readOnly: e(f),
1778
1778
  property: R,
1779
- propertyName: B,
1780
- modelValue: f.modelValue
1781
- }), void 0, !0) : f.layout?.fields?.[B]?.component && e(s)[f.layout.fields[B].component.name] ? (t(), V(me(e(s)[f.layout.fields[B].component.name]), M({
1779
+ propertyName: S,
1780
+ modelValue: c.modelValue
1781
+ }), void 0, !0) : c.layout?.fields?.[S]?.component && e(B)[c.layout.fields[S].component.name] ? (t(), k(pe(e(B)[c.layout.fields[S].component.name]), z({
1782
1782
  key: 2,
1783
- modelValue: f.modelValue[B],
1784
- "onUpdate:modelValue": (H) => f.modelValue[B] = H
1783
+ modelValue: c.modelValue[S],
1784
+ "onUpdate:modelValue": (W) => c.modelValue[S] = W
1785
1785
  }, { ref_for: !0 }, {
1786
- readOnly: e(m),
1786
+ readOnly: e(f),
1787
1787
  property: R,
1788
- propertyName: B,
1789
- required: !f.searchOnly && (!ae.value || e(Ge)(B, ae.value, f.modelValue)),
1790
- ...f.layout.fields[B].component.props || {}
1788
+ propertyName: S,
1789
+ required: !c.searchOnly && (!O.value || e(We)(S, O.value, c.modelValue)),
1790
+ ...c.layout.fields[S].component.props || {}
1791
1791
  }, {
1792
- onInput: (H) => a("input", B),
1793
- onChange: g[0] || (g[0] = (H) => a("change", H))
1794
- }), null, 16, ["modelValue", "onUpdate:modelValue", "onInput"])) : "format" in R && ["date", "date-time"].includes(R.format) && f.searchOnly ? (t(), l("div", {
1792
+ onInput: (W) => a("input", S),
1793
+ onChange: w[0] || (w[0] = (W) => a("change", W))
1794
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "onInput"])) : "format" in R && ["date", "date-time"].includes(R.format) && c.searchOnly ? (t(), l("div", {
1795
1795
  key: 3,
1796
1796
  style: { display: "grid", "grid-template-columns": "repeat(2, 1fr)", "column-gap": "1rem" },
1797
- onInput: (H) => a("input", B),
1798
- onChange: g[1] || (g[1] = (H) => a("change", H))
1797
+ onInput: (W) => a("input", S),
1798
+ onChange: w[1] || (w[1] = (W) => a("change", W))
1799
1799
  }, [
1800
- L(he, M({
1801
- modelValue: f.modelValue[B].$gte,
1802
- "onUpdate:modelValue": (H) => f.modelValue[B].$gte = H
1800
+ M(he, z({
1801
+ modelValue: c.modelValue[S].$gte,
1802
+ "onUpdate:modelValue": (W) => c.modelValue[S].$gte = W
1803
1803
  }, { ref_for: !0 }, {
1804
1804
  property: R,
1805
- propertyName: B
1805
+ propertyName: S
1806
1806
  }), null, 16, ["modelValue", "onUpdate:modelValue"]),
1807
- L(he, M({
1808
- modelValue: f.modelValue[B].$lte,
1809
- "onUpdate:modelValue": (H) => f.modelValue[B].$lte = H
1807
+ M(he, z({
1808
+ modelValue: c.modelValue[S].$lte,
1809
+ "onUpdate:modelValue": (W) => c.modelValue[S].$lte = W
1810
1810
  }, { ref_for: !0 }, {
1811
1811
  property: R,
1812
- propertyName: B
1812
+ propertyName: S
1813
1813
  }), null, 16, ["modelValue", "onUpdate:modelValue"])
1814
- ], 40, vn)) : "type" in R && R.type === "boolean" && f.searchOnly ? (t(), l("div", yn, [
1815
- L(Qe, M({ ref_for: !0 }, {
1814
+ ], 40, fn)) : "type" in R && R.type === "boolean" && c.searchOnly ? (t(), l("div", vn, [
1815
+ M(Ge, z({ ref_for: !0 }, {
1816
1816
  property: R,
1817
- propertyName: B
1817
+ propertyName: S
1818
1818
  }, {
1819
1819
  "boolean-ref": "",
1820
- "model-value": f.modelValue[B],
1821
- onChange: g[2] || (g[2] = (H) => a("change", H)),
1822
- "onUpdate:modelValue": (H) => {
1823
- f.modelValue[B] = H;
1820
+ "model-value": c.modelValue[S],
1821
+ onChange: w[2] || (w[2] = (W) => a("change", W)),
1822
+ "onUpdate:modelValue": (W) => {
1823
+ c.modelValue[S] = W;
1824
1824
  }
1825
1825
  }), {
1826
1826
  default: h(() => [
1827
- S("option", _n, A(e(j)("yes")), 1),
1828
- S("option", hn, A(e(j)("no")), 1)
1827
+ I("option", yn, C(e(j)("yes")), 1),
1828
+ I("option", _n, C(e(j)("no")), 1)
1829
1829
  ]),
1830
1830
  _: 2
1831
1831
  }, 1040, ["model-value", "onUpdate:modelValue"])
1832
- ])) : f.modelValue && "items" in R && !R.uniqueItems && (!("$ref" in R.items) || R.items.inline) ? (t(), l("div", bn, [
1833
- e(m) ? b("", !0) : (t(), l("div", $n, [
1834
- L(se, {
1832
+ ])) : c.modelValue && "items" in R && !R.uniqueItems && (!("$ref" in R.items) || R.items.inline) ? (t(), l("div", hn, [
1833
+ e(f) ? b("", !0) : (t(), l("div", bn, [
1834
+ M(ae, {
1835
1835
  small: "",
1836
1836
  variant: "alt",
1837
1837
  icon: "plus",
1838
- disabled: !("inline" in R.items && R.items.inline) && (f.modelValue[B]?.length >= R.maxItems || pe(f.modelValue[B]?.[f.modelValue[B]?.length - 1])),
1839
- onClick: Ie((H) => {
1840
- f.modelValue[B] || (f.modelValue[B] = []), e(un)(f.modelValue[B], R, e(o));
1838
+ disabled: !("inline" in R.items && R.items.inline) && (c.modelValue[S]?.length >= R.maxItems || ce(c.modelValue[S]?.[c.modelValue[S]?.length - 1])),
1839
+ onClick: Ie((W) => {
1840
+ c.modelValue[S] || (c.modelValue[S] = []), e(rn)(c.modelValue[S], R, e(o));
1841
1841
  }, ["prevent"])
1842
1842
  }, {
1843
1843
  default: h(() => [
1844
- D(A(e(j)("action.add", { capitalize: !0 })), 1)
1844
+ D(C(e(j)("action.add", { capitalize: !0 })), 1)
1845
1845
  ]),
1846
1846
  _: 2
1847
1847
  }, 1032, ["disabled", "onClick"])
1848
1848
  ])),
1849
- f.modelValue[B]?.length > 0 ? (t(), l("div", gn, [
1850
- (t(!0), l(Y, null, E(f.modelValue[B], (H, de) => (t(), l("div", {
1851
- key: `rep-${B}-${e(gt)(H, de)}`,
1849
+ c.modelValue[S]?.length > 0 ? (t(), l("div", $n, [
1850
+ (t(!0), l(X, null, E(c.modelValue[S], (W, ge) => (t(), l("div", {
1851
+ key: `rep-${S}-${e($t)(W, ge)}`,
1852
1852
  class: "form__array-item"
1853
1853
  }, [
1854
- e(m) ? b("", !0) : K((t(), V(G, {
1854
+ e(f) ? b("", !0) : J((t(), k(G, {
1855
1855
  key: 0,
1856
1856
  icon: "trash",
1857
1857
  class: "form__array-remove",
1858
- onClick: Ie(($e) => e(dn)(f.modelValue[B], de), ["prevent"])
1858
+ onClick: Ie((ve) => e(un)(c.modelValue[S], ge), ["prevent"])
1859
1859
  }, {
1860
1860
  default: h(() => [
1861
- D(A(e(j)("action.remove", { capitalize: !0 })), 1)
1861
+ D(C(e(j)("action.remove", { capitalize: !0 })), 1)
1862
1862
  ]),
1863
1863
  _: 2
1864
1864
  }, 1032, ["onClick"])), [
1865
- [F]
1865
+ [K]
1866
1866
  ]),
1867
- (t(), V(me(e(Ye)(R, e(T))), M({
1868
- modelValue: f.modelValue[B][de],
1869
- "onUpdate:modelValue": ($e) => f.modelValue[B][de] = $e
1867
+ (t(), k(pe(e(Ke)(R, e(s))), z({
1868
+ modelValue: c.modelValue[S][ge],
1869
+ "onUpdate:modelValue": (ve) => c.modelValue[S][ge] = ve
1870
1870
  }, { ref_for: !0 }, {
1871
- readOnly: e(m),
1871
+ readOnly: e(f),
1872
1872
  property: R.items,
1873
- propertyName: B,
1873
+ propertyName: S,
1874
1874
  parentCollection: e(u),
1875
- parentPropertyName: f.parentPropertyName,
1876
- columns: f.layout?.fields?.[B]?.optionsColumns || f.layout?.fields?.$default?.optionsColumns,
1877
- validationErrors: C(B, de),
1875
+ parentPropertyName: c.parentPropertyName,
1876
+ columns: c.layout?.fields?.[S]?.optionsColumns || c.layout?.fields?.$default?.optionsColumns,
1877
+ validationErrors: L(S, ge),
1878
1878
  ...R.componentProps || {}
1879
1879
  }, {
1880
- onInput: ($e) => a("input", B),
1881
- onChange: g[3] || (g[3] = ($e) => a("change", $e))
1880
+ onInput: (ve) => a("input", S),
1881
+ onChange: w[3] || (w[3] = (ve) => a("change", ve))
1882
1882
  }), null, 16, ["modelValue", "onUpdate:modelValue", "onInput"]))
1883
1883
  ]))), 128))
1884
1884
  ])) : b("", !0)
1885
- ])) : f.modelValue ? K((t(), V(me(e(Ye)(R, e(T))), M({
1885
+ ])) : c.modelValue ? J((t(), k(pe(e(Ke)(R, e(s))), z({
1886
1886
  key: 6,
1887
- modelValue: f.modelValue[B],
1888
- "onUpdate:modelValue": (H) => f.modelValue[B] = H
1887
+ modelValue: c.modelValue[S],
1888
+ "onUpdate:modelValue": (W) => c.modelValue[S] = W
1889
1889
  }, { ref_for: !0 }, {
1890
- readOnly: e(m),
1890
+ readOnly: e(f),
1891
1891
  property: R,
1892
- propertyName: B,
1893
- parentPropertyName: f.parentPropertyName,
1892
+ propertyName: S,
1893
+ parentPropertyName: c.parentPropertyName,
1894
1894
  parentCollection: e(u),
1895
- columns: f.layout?.fields?.[B]?.optionsColumns || f.layout?.fields?.$default?.optionsColumns,
1895
+ columns: c.layout?.fields?.[S]?.optionsColumns || c.layout?.fields?.$default?.optionsColumns,
1896
1896
  ...R.componentProps || {},
1897
- validationErrors: C(B)
1897
+ validationErrors: L(S)
1898
1898
  }, {
1899
- onInput: (H) => a("input", B),
1900
- onChange: g[4] || (g[4] = (H) => a("change", H)),
1901
- onClipboardCopy: g[5] || (g[5] = (H) => a("clipboardCopy", H))
1899
+ onInput: (W) => a("input", S),
1900
+ onChange: w[4] || (w[4] = (W) => a("change", W)),
1901
+ onClipboardCopy: w[5] || (w[5] = (W) => a("clipboardCopy", W))
1902
1902
  }), null, 16, ["modelValue", "onUpdate:modelValue", "onInput"])), [
1903
- [x, Z(R)]
1903
+ [ee, P(R)]
1904
1904
  ]) : b("", !0),
1905
- _.value?.[B] ? (t(), l("div", kn, [
1906
- _.value[B].type ? (t(), l("span", Vn, A(e(j)(`validation_error.${_.value[B].type}`)), 1)) : b("", !0),
1907
- _.value[B].detail ? (t(), l("span", Cn, A(e(j)(_.value[B].detail)), 1)) : b("", !0)
1905
+ y.value?.[S] ? (t(), l("div", gn, [
1906
+ y.value[S].type ? (t(), l("span", kn, C(e(j)(`validation_error.${y.value[S].type}`)), 1)) : b("", !0),
1907
+ y.value[S].detail ? (t(), l("span", Vn, C(e(j)(y.value[S].detail)), 1)) : b("", !0)
1908
1908
  ])) : b("", !0)
1909
1909
  ], 6))), 128))
1910
1910
  ]),
1911
- f.$slots.after ? I(f.$slots, "after", { key: 1 }, void 0, !0) : b("", !0),
1912
- f.$slots.footer ? (t(), l("div", On, [
1913
- I(f.$slots, "footer", le(_e({
1914
- isInsertReady: w.value
1911
+ c.$slots.after ? A(c.$slots, "after", { key: 1 }, void 0, !0) : b("", !0),
1912
+ c.$slots.footer ? (t(), l("div", Cn, [
1913
+ A(c.$slots, "footer", ne(_e({
1914
+ isInsertReady: T.value
1915
1915
  })), void 0, !0)
1916
1916
  ])) : b("", !0)
1917
1917
  ], 4);
1918
1918
  };
1919
1919
  }
1920
- }), Me = /* @__PURE__ */ U(An, [["__scopeId", "data-v-f9013657"]]), In = /* @__PURE__ */ z({
1920
+ }), Me = /* @__PURE__ */ U(On, [["__scopeId", "data-v-f9013657"]]), An = /* @__PURE__ */ F({
1921
1921
  __name: "aeria-filter-panel",
1922
1922
  emits: ["update:modelValue"],
1923
- setup(p, { emit: i }) {
1924
- const o = i, n = qe(), a = Ve(), d = e(ue(Te)), u = () => {
1923
+ setup(m, { emit: i }) {
1924
+ const o = i, n = qe(), a = Ce(), d = e(ue(Te)), u = () => {
1925
1925
  if (n.pagination.offset = 0, n.$actions.filter(), o("update:modelValue", !1), "query" in a.currentRoute && a.currentRoute.query && typeof a.currentRoute.query == "object") {
1926
1926
  const v = a.currentRoute.query;
1927
1927
  for (const r of Object.keys(v))
1928
1928
  r.startsWith(`${d}.`) && delete v[r];
1929
1929
  }
1930
- const { query: m, ...c } = a.currentRoute.value;
1931
- a.push(Be(c, {
1932
- query: mt(n)
1930
+ const { query: f, ...p } = a.currentRoute.value;
1931
+ a.push(Be(p, {
1932
+ query: pt(n)
1933
1933
  }));
1934
1934
  };
1935
- return (m, c) => (t(), V(Ce, {
1935
+ return (f, p) => (t(), k(Oe, {
1936
1936
  "close-hint": "",
1937
1937
  "fixed-right": "",
1938
- title: m.t("filter_by", { capitalize: !0 }),
1939
- onClose: c[2] || (c[2] = (v) => o("update:modelValue", !1)),
1940
- onOverlayClick: c[3] || (c[3] = (v) => o("update:modelValue", !1))
1938
+ title: f.t("filter_by", { capitalize: !0 }),
1939
+ onClose: p[2] || (p[2] = (v) => o("update:modelValue", !1)),
1940
+ onOverlayClick: p[3] || (p[3] = (v) => o("update:modelValue", !1))
1941
1941
  }, {
1942
1942
  footer: h(() => [
1943
- e(n).filtersCount > 0 ? (t(), V(se, {
1943
+ e(n).filtersCount > 0 ? (t(), k(ae, {
1944
1944
  key: 0,
1945
1945
  variant: "transparent",
1946
- onClick: c[1] || (c[1] = (v) => {
1946
+ onClick: p[1] || (p[1] = (v) => {
1947
1947
  e(n).$actions.clearFilters(), u(), o("update:modelValue", !1);
1948
1948
  })
1949
1949
  }, {
1950
1950
  default: h(() => [
1951
- D(A(m.t("action.clear", { capitalize: !0 })) + " ", 1),
1952
- L(ye, null, {
1951
+ D(C(f.t("action.clear", { capitalize: !0 })) + " ", 1),
1952
+ M(ye, null, {
1953
1953
  default: h(() => [
1954
- D(A(e(n).filtersCount), 1)
1954
+ D(C(e(n).filtersCount), 1)
1955
1955
  ]),
1956
1956
  _: 1
1957
1957
  })
1958
1958
  ]),
1959
1959
  _: 1
1960
1960
  })) : b("", !0),
1961
- L(se, {
1961
+ M(ae, {
1962
1962
  large: "",
1963
1963
  icon: "funnel",
1964
1964
  disabled: !e(n).hasActiveFilters,
1965
1965
  onClick: u
1966
1966
  }, {
1967
1967
  default: h(() => [
1968
- D(A(m.t("action.filter", { capitalize: !0 })), 1)
1968
+ D(C(f.t("action.filter", { capitalize: !0 })), 1)
1969
1969
  ]),
1970
1970
  _: 1
1971
1971
  }, 8, ["disabled"])
1972
1972
  ]),
1973
1973
  default: h(() => [
1974
- L(Me, M({
1974
+ M(Me, z({
1975
1975
  modelValue: e(n).filters,
1976
- "onUpdate:modelValue": c[0] || (c[0] = (v) => e(n).filters = v)
1976
+ "onUpdate:modelValue": p[0] || (p[0] = (v) => e(n).filters = v)
1977
1977
  }, {
1978
1978
  searchOnly: !0,
1979
1979
  form: e(n).availableFilters,
@@ -1983,7 +1983,7 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1983
1983
  _: 1
1984
1984
  }, 8, ["title"]));
1985
1985
  }
1986
- }), Bn = /* @__PURE__ */ z({
1986
+ }), In = /* @__PURE__ */ F({
1987
1987
  __name: "aeria-insert-panel",
1988
1988
  props: {
1989
1989
  individualActions: {},
@@ -1998,33 +1998,33 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
1998
1998
  includeTimestamps: { type: Boolean }
1999
1999
  },
2000
2000
  emits: ["update:visible", "update:modelValue", "insert", "cancel"],
2001
- setup(p, { emit: i }) {
2002
- const o = p, n = i, a = te("meta"), d = o.collection, u = te(d);
2003
- Ue(() => {
2001
+ setup(m, { emit: i }) {
2002
+ const o = m, n = i, a = te("meta"), d = o.collection, u = te(d);
2003
+ He(() => {
2004
2004
  o.modelValue && u.$actions.setItem(o.modelValue);
2005
2005
  });
2006
- const m = W(() => o.form ? u.$actions.useProperties(o.form) : u.description.form ? u.$actions.useProperties(u.description.form) : u.properties), c = async () => {
2007
- const { error: k, result: _ } = await u.$actions.deepInsert();
2008
- if (k) {
2009
- if ("code" in k)
2010
- switch (k.code) {
2006
+ const f = Y(() => o.form ? u.$actions.useProperties(o.form) : u.description.form ? u.$actions.useProperties(u.description.form) : u.properties), p = async () => {
2007
+ const { error: g, result: y } = await u.$actions.deepInsert();
2008
+ if (g) {
2009
+ if ("code" in g)
2010
+ switch (g.code) {
2011
2011
  case "INVALID_PROPERTIES":
2012
2012
  case "MISSING_PROPERTIES":
2013
2013
  return;
2014
2014
  default: {
2015
- let T = v("error", {
2015
+ let s = v("error", {
2016
2016
  capitalize: !0
2017
2017
  });
2018
- k.message && (T += `: ${v(k.message)}`), T += ` (${v(k.code)})`, a.$actions.spawnToast({
2019
- text: T,
2018
+ g.message && (s += `: ${v(g.message)}`), s += ` (${v(g.code)})`, a.$actions.spawnToast({
2019
+ text: s,
2020
2020
  icon: "warning"
2021
2021
  });
2022
2022
  }
2023
2023
  }
2024
2024
  return;
2025
2025
  }
2026
- n("update:visible", !1), n("update:modelValue", _), n("insert", _), u.$actions.clearItem();
2027
- }, { t: v } = rt(), r = () => {
2026
+ n("update:visible", !1), n("update:modelValue", y), n("insert", y), u.$actions.clearItem();
2027
+ }, { t: v } = it(), r = () => {
2028
2028
  a.$actions.ask({
2029
2029
  action: () => {
2030
2030
  u.$actions.clearItem(), u.validationErrors = {}, n("cancel");
@@ -2035,93 +2035,93 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2035
2035
  icon: "info",
2036
2036
  text: v("copied_to_clipboard")
2037
2037
  });
2038
- return ne(() => u.item._id, (k) => {
2039
- k === null && n("update:visible", !1);
2040
- }), (k, _) => {
2041
- const T = P("clickable");
2042
- return t(), V(Ce, M({
2043
- modelValue: k.visible,
2038
+ return oe(() => u.item._id, (g) => {
2039
+ g === null && n("update:visible", !1);
2040
+ }), (g, y) => {
2041
+ const s = N("clickable");
2042
+ return t(), k(Oe, z({
2043
+ modelValue: g.visible,
2044
2044
  loading: e(u).loading.get,
2045
- float: k.float,
2046
- fixedRight: k.fixedRight
2047
- }, { onOverlayClick: r }), ie({
2045
+ float: g.float,
2046
+ fixedRight: g.fixedRight
2047
+ }, { onOverlayClick: r }), le({
2048
2048
  extra: h(() => [
2049
- k.individualActions ? (t(), V(ke, M({ key: 0 }, {
2049
+ g.individualActions ? (t(), k(Ve, z({ key: 0 }, {
2050
2050
  subject: e(u).item,
2051
- actions: k.individualActions.filter(({ action: s }) => s !== "spawnEdit"),
2051
+ actions: g.individualActions.filter(({ action: B }) => B !== "spawnEdit"),
2052
2052
  overlayLayer: 60
2053
2053
  }, {
2054
- onActionClick: _[2] || (_[2] = (s) => n("update:visible", !1))
2054
+ onActionClick: y[2] || (y[2] = (B) => n("update:visible", !1))
2055
2055
  }), {
2056
2056
  default: h(({
2057
- visible: s
2057
+ visible: B
2058
2058
  }) => [
2059
- e(u).item._id ? K((t(), V(G, {
2059
+ e(u).item._id ? J((t(), k(G, {
2060
2060
  key: 0,
2061
2061
  reactive: "",
2062
- active: s,
2062
+ active: B,
2063
2063
  icon: "dots-three"
2064
2064
  }, null, 8, ["active"])), [
2065
- [T]
2065
+ [s]
2066
2066
  ]) : b("", !0)
2067
2067
  ]),
2068
2068
  _: 1
2069
2069
  }, 16)) : b("", !0)
2070
2070
  ]),
2071
2071
  default: h(() => [
2072
- L(Me, M({
2072
+ M(Me, z({
2073
2073
  modelValue: e(u).item,
2074
- "onUpdate:modelValue": _[0] || (_[0] = (s) => e(u).item = s)
2074
+ "onUpdate:modelValue": y[0] || (y[0] = (B) => e(u).item = B)
2075
2075
  }, {
2076
2076
  collection: e(d),
2077
- readOnly: k.readOnly,
2078
- includeId: k.includeId,
2079
- includeTimestamps: k.includeTimestamps,
2080
- form: m.value,
2077
+ readOnly: g.readOnly,
2078
+ includeId: g.includeId,
2079
+ includeTimestamps: g.includeTimestamps,
2080
+ form: f.value,
2081
2081
  layout: e(u).description.formLayout || {}
2082
2082
  }, {
2083
2083
  focus: "",
2084
2084
  onClipboardCopy: $,
2085
- onAdd: _[1] || (_[1] = (s) => s.preventDefault())
2086
- }), ie({ _: 2 }, [
2087
- E(Object.keys(k.$slots).filter((s) => s.startsWith("field-")), (s) => ({
2088
- name: s,
2089
- fn: h((O) => [
2090
- I(k.$slots, s, le(_e(O)))
2085
+ onAdd: y[1] || (y[1] = (B) => B.preventDefault())
2086
+ }), le({ _: 2 }, [
2087
+ E(Object.keys(g.$slots).filter((B) => B.startsWith("field-")), (B) => ({
2088
+ name: B,
2089
+ fn: h((V) => [
2090
+ A(g.$slots, B, ne(_e(V)))
2091
2091
  ])
2092
2092
  }))
2093
2093
  ]), 1040, ["modelValue"])
2094
2094
  ]),
2095
2095
  _: 2
2096
2096
  }, [
2097
- k.$slots.header ? {
2097
+ g.$slots.header ? {
2098
2098
  name: "header",
2099
2099
  fn: h(() => [
2100
- I(k.$slots, "header")
2100
+ A(g.$slots, "header")
2101
2101
  ]),
2102
2102
  key: "0"
2103
2103
  } : void 0,
2104
- k.readOnly ? void 0 : {
2104
+ g.readOnly ? void 0 : {
2105
2105
  name: "footer",
2106
2106
  fn: h(() => [
2107
- k.float || k.fixedRight ? (t(), V(se, {
2107
+ g.float || g.fixedRight ? (t(), k(ae, {
2108
2108
  key: 0,
2109
2109
  variant: "transparent",
2110
2110
  onClick: r
2111
2111
  }, {
2112
2112
  default: h(() => [
2113
- D(A(e(v)("action.cancel", { capitalize: !0 })), 1)
2113
+ D(C(e(v)("action.cancel", { capitalize: !0 })), 1)
2114
2114
  ]),
2115
2115
  _: 1
2116
2116
  })) : b("", !0),
2117
- L(se, {
2117
+ M(ae, {
2118
2118
  large: "",
2119
2119
  disabled: !e(u).isInsertReady || e(u).loading.get,
2120
2120
  loading: e(u).loading.insert,
2121
- onClick: c
2121
+ onClick: p
2122
2122
  }, {
2123
2123
  default: h(() => [
2124
- D(A(e(v)("action.insert", { capitalize: !0 })), 1)
2124
+ D(C(e(v)("action.insert", { capitalize: !0 })), 1)
2125
2125
  ]),
2126
2126
  _: 1
2127
2127
  }, 8, ["disabled", "loading"])
@@ -2131,27 +2131,27 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2131
2131
  ]), 1040);
2132
2132
  };
2133
2133
  }
2134
- }), Ne = (p, i) => {
2134
+ }), Ne = (m, i) => {
2135
2135
  if (i) {
2136
- if (!p) {
2136
+ if (!m) {
2137
2137
  i.filtersPreset = {}, i.preferredTableProperties = [], i.pagination.offset = 0;
2138
2138
  return;
2139
2139
  }
2140
- i.filtersPreset = p.filters || {}, i.preferredTableProperties = p.table ? Array.from(p.table) : [], i.pagination.offset = 0;
2140
+ i.filtersPreset = m.filters || {}, i.preferredTableProperties = m.table ? Array.from(m.table) : [], i.pagination.offset = 0;
2141
2141
  }
2142
- }, Sn = (p, i = {
2142
+ }, Bn = (m, i = {
2143
2143
  persistInQuery: !0
2144
2144
  }) => {
2145
- const n = Ve().currentRoute;
2146
- return ne(() => n.value.query.section, (a) => {
2147
- if (p) {
2148
- if (p.description.filtersPresets) {
2149
- const d = a || Object.keys(p.description.filtersPresets)[0];
2150
- Ne(p.description.filtersPresets[d], p);
2145
+ const n = Ce().currentRoute;
2146
+ return oe(() => n.value.query.section, (a) => {
2147
+ if (m) {
2148
+ if (m.description.filtersPresets) {
2149
+ const d = a || Object.keys(m.description.filtersPresets)[0];
2150
+ Ne(m.description.filtersPresets[d], m);
2151
2151
  }
2152
2152
  if (i.persistInQuery) {
2153
2153
  const d = n.value.query;
2154
- d.offset && (p.pagination.offset = +d.offset), d.limit && (p.pagination.limit = +d.limit), d.search && (p.textQuery = d.search, p.filters.$text = {
2154
+ d.offset && (m.pagination.offset = +d.offset), d.limit && (m.pagination.limit = +d.limit), d.search && (m.textQuery = d.search, m.filters.$text = {
2155
2155
  $search: `"${d.search}"`,
2156
2156
  $caseSensitive: !1
2157
2157
  });
@@ -2160,25 +2160,25 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2160
2160
  }, {
2161
2161
  immediate: !0
2162
2162
  });
2163
- }, wn = {
2163
+ }, Sn = {
2164
2164
  key: 0,
2165
2165
  class: "table aeria-surface"
2166
- }, Tn = { key: 0 }, jn = { key: 1 }, Rn = { key: 0 }, Ln = ["checked"], qn = {
2166
+ }, wn = { key: 0 }, Tn = { key: 1 }, jn = { key: 0 }, Rn = ["checked"], Ln = {
2167
2167
  key: 1,
2168
2168
  style: { "text-align": "right" }
2169
- }, Mn = { key: 2 }, zn = { key: 3 }, Fn = ["onClick"], En = { key: 0 }, Un = ["value"], Hn = { class: "table__cell-mobile-label" }, Dn = {
2169
+ }, qn = { key: 2 }, Mn = { key: 3 }, zn = ["onClick"], Fn = { key: 0 }, En = ["value"], Un = { class: "table__cell-mobile-label" }, Hn = {
2170
2170
  key: 0,
2171
2171
  class: "table__cell-container"
2172
- }, Qn = {
2172
+ }, Dn = {
2173
2173
  key: 1,
2174
2174
  class: "table__cell-container"
2175
- }, Gn = { class: "table__cell-grid" }, Wn = { key: 0 }, Yn = { key: 1 }, Kn = { key: 0 }, Xn = ["href"], Jn = { key: 3 }, Zn = { key: 1 }, Pn = { key: 2 }, Nn = { key: 0 }, xn = { key: 1 }, ea = { key: 2 }, ta = {
2175
+ }, Qn = { class: "table__cell-grid" }, Gn = { key: 0 }, Wn = { key: 1 }, Yn = { key: 0 }, Kn = ["href"], Xn = { key: 3 }, Jn = { key: 1 }, Zn = { key: 2 }, Pn = { key: 0 }, Nn = { key: 1 }, xn = { key: 2 }, ea = {
2176
2176
  key: 1,
2177
2177
  class: "no-print"
2178
- }, oa = { class: "table__cell-actions" }, na = {
2178
+ }, ta = { class: "table__cell-actions" }, oa = {
2179
2179
  key: 2,
2180
2180
  class: "no-print table__mobile-actions"
2181
- }, aa = ["id"], la = { key: 1 }, sa = ["colspan"], ia = { class: "table__empty" }, ra = /* @__PURE__ */ z({
2181
+ }, na = ["id"], aa = { key: 1 }, la = ["colspan"], sa = { class: "table__empty" }, ia = /* @__PURE__ */ F({
2182
2182
  __name: "aeria-table",
2183
2183
  props: {
2184
2184
  columns: {},
@@ -2189,227 +2189,227 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2189
2189
  layout: {}
2190
2190
  },
2191
2191
  emits: ["itemClick"],
2192
- setup(p, { emit: i }) {
2193
- const o = p, n = i, a = Se(), d = o.collection || we(), u = d ? te(typeof d == "string" ? d : d.value) : null, m = W({
2192
+ setup(m, { emit: i }) {
2193
+ const o = m, n = i, a = Se(), d = o.collection || we(), u = d ? te(typeof d == "string" ? d : d.value) : null, f = Y({
2194
2194
  get: () => u?.selected,
2195
- set: (_) => u?.$actions.selectManyItems(_, !0)
2196
- }), c = W(() => o.columns ? Object.keys(o.columns).length + Number(o.checkbox) : 0), v = (_, T) => _.button ? typeof _.button == "object" ? Re(T, _.button).satisfied : _.button : !1, r = (_) => {
2197
- const T = o.layout?.actions;
2198
- return !a.value.xl || !T || !o.actions ? [] : o.actions.filter((s) => {
2199
- if (s.roles) {
2200
- const X = te("user");
2201
- if (!Fe(s.roles, X.currentUser.roles))
2195
+ set: (y) => u?.$actions.selectManyItems(y, !0)
2196
+ }), p = Y(() => o.columns ? Object.keys(o.columns).length + Number(o.checkbox) : 0), v = (y, s) => y.button ? typeof y.button == "object" ? Re(s, y.button).satisfied : y.button : !1, r = (y) => {
2197
+ const s = o.layout?.actions;
2198
+ return !a.value.xl || !s || !o.actions ? [] : o.actions.filter((B) => {
2199
+ if (B.roles) {
2200
+ const H = te("user");
2201
+ if (!Ee(B.roles, H.currentUser.roles))
2202
2202
  return !1;
2203
2203
  }
2204
- const O = T[s.action];
2205
- return O && v(O, _);
2204
+ const V = s[B.action];
2205
+ return V && v(V, y);
2206
2206
  });
2207
- }, $ = (_) => {
2207
+ }, $ = (y) => {
2208
2208
  if (!o.actions)
2209
2209
  return [];
2210
- const T = o.layout?.actions;
2211
- return !a.value.xl || !T ? o.actions : o.actions.filter((s) => {
2212
- const O = T[s.action];
2213
- if (s.roles) {
2214
- const X = te("user");
2215
- if (!Fe(s.roles, X.currentUser.roles))
2210
+ const s = o.layout?.actions;
2211
+ return !a.value.xl || !s ? o.actions : o.actions.filter((B) => {
2212
+ const V = s[B.action];
2213
+ if (B.roles) {
2214
+ const H = te("user");
2215
+ if (!Ee(B.roles, H.currentUser.roles))
2216
2216
  return !1;
2217
2217
  }
2218
- return O ? O.if ? Re(
2219
- _,
2220
- O.if
2221
- ).satisfied : !v(O, _) : !0;
2218
+ return V ? V.if ? Re(
2219
+ y,
2220
+ V.if
2221
+ ).satisfied : !v(V, y) : !0;
2222
2222
  });
2223
- }, k = (_, T) => {
2224
- const s = [], O = o.layout?.actions?.[T.action];
2225
- return O?.if && (Re(
2226
- _,
2227
- O.if
2228
- ).satisfied || s.push("display: none;")), s.join("");
2223
+ }, g = (y, s) => {
2224
+ const B = [], V = o.layout?.actions?.[s.action];
2225
+ return V?.if && (Re(
2226
+ y,
2227
+ V.if
2228
+ ).satisfied || B.push("display: none;")), B.join("");
2229
2229
  };
2230
- return (_, T) => {
2231
- const s = P("clickable");
2232
- return c.value > 0 || _.$slots.thead ? (t(), l("table", wn, [
2233
- _.$slots.thead ? (t(), l("thead", Tn, [
2234
- I(_.$slots, "thead", {}, void 0, !0)
2235
- ])) : (t(), l("thead", jn, [
2236
- S("tr", null, [
2237
- _.checkbox && e(u) && e(a).md ? (t(), l("th", Rn, [
2238
- S("input", {
2230
+ return (y, s) => {
2231
+ const B = N("clickable");
2232
+ return p.value > 0 || y.$slots.thead ? (t(), l("table", Sn, [
2233
+ y.$slots.thead ? (t(), l("thead", wn, [
2234
+ A(y.$slots, "thead", {}, void 0, !0)
2235
+ ])) : (t(), l("thead", Tn, [
2236
+ I("tr", null, [
2237
+ y.checkbox && e(u) && e(a).md ? (t(), l("th", jn, [
2238
+ I("input", {
2239
2239
  type: "checkbox",
2240
2240
  checked: e(u).selected.length > 0 && e(u).selected.length === e(u).itemsCount,
2241
- onChange: T[0] || (T[0] = (O) => e(u).$actions.selectAllItems(O.target.checked))
2242
- }, null, 40, Ln)
2241
+ onChange: s[0] || (s[0] = (V) => e(u).$actions.selectAllItems(V.target.checked))
2242
+ }, null, 40, Rn)
2243
2243
  ])) : b("", !0),
2244
- (t(!0), l(Y, null, E(Object.entries(_.columns), ([O, X], y) => (t(), l("th", {
2245
- key: `header-${y}`,
2244
+ (t(!0), l(X, null, E(Object.entries(y.columns), ([V, H], _) => (t(), l("th", {
2245
+ key: `header-${_}`,
2246
2246
  class: "table__header"
2247
- }, A(X.description || e(j)(O)), 1))), 128)),
2248
- _.actions?.length ? (t(), l("th", qn)) : b("", !0)
2247
+ }, C(H.description || e(j)(V)), 1))), 128)),
2248
+ y.actions?.length ? (t(), l("th", Ln)) : b("", !0)
2249
2249
  ])
2250
2250
  ])),
2251
- _.$slots.tbody ? (t(), l("tbody", Mn, [
2252
- I(_.$slots, "tbody", {}, void 0, !0)
2253
- ])) : (t(), l("tbody", zn, [
2254
- (t(!0), l(Y, null, E(_.rows, (O, X) => (t(), l("tr", {
2255
- key: O._id,
2256
- onClick: (y) => n("itemClick", O)
2251
+ y.$slots.tbody ? (t(), l("tbody", qn, [
2252
+ A(y.$slots, "tbody", {}, void 0, !0)
2253
+ ])) : (t(), l("tbody", Mn, [
2254
+ (t(!0), l(X, null, E(y.rows, (V, H) => (t(), l("tr", {
2255
+ key: V._id,
2256
+ onClick: (_) => n("itemClick", V)
2257
2257
  }, [
2258
- e(u) && _.checkbox && e(a).md ? (t(), l("td", En, [
2259
- K(S("input", {
2260
- "onUpdate:modelValue": T[1] || (T[1] = (y) => m.value = y),
2258
+ e(u) && y.checkbox && e(a).md ? (t(), l("td", Fn, [
2259
+ J(I("input", {
2260
+ "onUpdate:modelValue": s[1] || (s[1] = (_) => f.value = _),
2261
2261
  type: "checkbox",
2262
- value: O._id
2263
- }, null, 8, Un), [
2264
- [ot, m.value]
2262
+ value: V._id
2263
+ }, null, 8, En), [
2264
+ [tt, f.value]
2265
2265
  ])
2266
2266
  ])) : b("", !0),
2267
- (t(!0), l(Y, null, E(Object.entries(_.columns), ([y, q], ee) => (t(), l("td", {
2268
- key: `column-${O._id}-${ee}`
2267
+ (t(!0), l(X, null, E(Object.entries(y.columns), ([_, q], ie) => (t(), l("td", {
2268
+ key: `column-${V._id}-${ie}`
2269
2269
  }, [
2270
- S("div", Hn, A(q.description || e(j)(y)), 1),
2271
- `row-${y}` in _.$slots ? (t(), l("div", Dn, [
2272
- I(_.$slots, `row-${y}`, M({ ref_for: !0 }, {
2270
+ I("div", Un, C(q.description || e(j)(_)), 1),
2271
+ `row-${_}` in y.$slots ? (t(), l("div", Hn, [
2272
+ A(y.$slots, `row-${_}`, z({ ref_for: !0 }, {
2273
2273
  store: e(u),
2274
- column: y,
2274
+ column: _,
2275
2275
  property: q,
2276
- row: O,
2277
- rowIndex: X
2276
+ row: V,
2277
+ rowIndex: H
2278
2278
  }), void 0, !0)
2279
- ])) : (t(), l("div", Qn, [
2280
- S("div", Gn, [
2281
- "type" in q && q.type === "boolean" ? (t(), l("div", Wn, [
2282
- O[y] ? (t(), V(G, {
2279
+ ])) : (t(), l("div", Dn, [
2280
+ I("div", Qn, [
2281
+ "type" in q && q.type === "boolean" ? (t(), l("div", Gn, [
2282
+ V[_] ? (t(), k(G, {
2283
2283
  key: 0,
2284
2284
  icon: "check",
2285
2285
  "icon-classes": "aeria-blueish"
2286
2286
  }, {
2287
2287
  default: h(() => [
2288
- D(A(e(j)("yes")), 1)
2288
+ D(C(e(j)("yes")), 1)
2289
2289
  ]),
2290
2290
  _: 1
2291
- })) : (t(), V(G, {
2291
+ })) : (t(), k(G, {
2292
2292
  key: 1,
2293
2293
  icon: "x",
2294
2294
  "icon-classes": "aeria-redish"
2295
2295
  }, {
2296
2296
  default: h(() => [
2297
- D(A(e(j)("no")), 1)
2297
+ D(C(e(j)("no")), 1)
2298
2298
  ]),
2299
2299
  _: 1
2300
2300
  }))
2301
- ])) : e(re)(q)?.$ref === "file" ? (t(), l("div", Yn, [
2302
- O[y] ? (t(), l("div", Kn, [
2303
- "items" in q && O[y][0] && /^image/.test(O[y][0].type) ? (t(), V(Le, {
2301
+ ])) : e(se)(q)?.$ref === "file" ? (t(), l("div", Wn, [
2302
+ V[_] ? (t(), l("div", Yn, [
2303
+ "items" in q && V[_][0] && /^image/.test(V[_][0].type) ? (t(), k(Le, {
2304
2304
  key: 0,
2305
- modelValue: O[y][0].link,
2306
- "onUpdate:modelValue": (N) => O[y][0].link = N,
2305
+ modelValue: V[_][0].link,
2306
+ "onUpdate:modelValue": (x) => V[_][0].link = x,
2307
2307
  expandable: "",
2308
- meta: O[y][0],
2308
+ meta: V[_][0],
2309
2309
  alt: "Row image",
2310
2310
  class: "table__picture"
2311
- }, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : /^image/.test(O[y].type) ? (t(), V(Le, {
2311
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : /^image/.test(V[_].type) ? (t(), k(Le, {
2312
2312
  key: 1,
2313
- modelValue: O[y].link,
2314
- "onUpdate:modelValue": (N) => O[y].link = N,
2313
+ modelValue: V[_].link,
2314
+ "onUpdate:modelValue": (x) => V[_].link = x,
2315
2315
  expandable: "",
2316
- meta: O[y],
2316
+ meta: V[_],
2317
2317
  alt: "Row image",
2318
2318
  class: "table__picture"
2319
- }, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : O[y].link ? (t(), l("a", {
2319
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "meta"])) : V[_].link ? (t(), l("a", {
2320
2320
  key: 2,
2321
- href: O[y].link,
2321
+ href: V[_].link,
2322
2322
  style: { "font-size": "10pt" }
2323
- }, A(O[y].filename), 9, Xn)) : (t(), l("div", Jn, " - "))
2324
- ])) : (t(), l("div", Zn, " - "))
2325
- ])) : (t(), l("div", Pn, [
2326
- e(u) ? (t(), l("span", Nn, A(e(u).$actions.formatValue({
2327
- value: O[y],
2328
- key: y,
2323
+ }, C(V[_].filename), 9, Kn)) : (t(), l("div", Xn, " - "))
2324
+ ])) : (t(), l("div", Jn, " - "))
2325
+ ])) : (t(), l("div", Zn, [
2326
+ e(u) ? (t(), l("span", Pn, C(e(u).$actions.formatValue({
2327
+ value: V[_],
2328
+ key: _,
2329
2329
  property: q
2330
- })), 1)) : (t(), l("span", xn, A(Array.isArray(O[y]) ? O[y].filter((N) => !!N).join(", ") : [void 0, null].includes(O[y]) ? "-" : O[y]), 1)),
2331
- e(re)(q)?.indexes?.length > 1 ? (t(), l("div", ea, [
2332
- (t(!0), l(Y, null, E(e(re)(q).indexes.slice(1, 2), (N, oe) => (t(), l("div", {
2333
- key: `subvalue-${oe}`,
2330
+ })), 1)) : (t(), l("span", Nn, C(Array.isArray(V[_]) ? V[_].filter((x) => !!x).join(", ") : [void 0, null].includes(V[_]) ? "-" : V[_]), 1)),
2331
+ e(se)(q)?.indexes?.length > 1 ? (t(), l("div", xn, [
2332
+ (t(!0), l(X, null, E(e(se)(q).indexes.slice(1, 2), (x, re) => (t(), l("div", {
2333
+ key: `subvalue-${re}`,
2334
2334
  class: "table__cell-subvalue"
2335
- }, A(e(u).$actions.formatValue({
2336
- value: O[y],
2337
- key: y,
2335
+ }, C(e(u).$actions.formatValue({
2336
+ value: V[_],
2337
+ key: _,
2338
2338
  property: q,
2339
- index: N
2339
+ index: x
2340
2340
  })), 1))), 128))
2341
2341
  ])) : b("", !0)
2342
2342
  ]))
2343
2343
  ])
2344
2344
  ]))
2345
2345
  ]))), 128)),
2346
- _.actions?.length && e(a).md ? (t(), l("td", ta, [
2347
- S("div", oa, [
2348
- (t(!0), l(Y, null, E(r(O), (y) => (t(), V(se, {
2349
- key: `action-${y.action}`,
2346
+ y.actions?.length && e(a).md ? (t(), l("td", ea, [
2347
+ I("div", ta, [
2348
+ (t(!0), l(X, null, E(r(V), (_) => (t(), k(ae, {
2349
+ key: `action-${_.action}`,
2350
2350
  small: "",
2351
2351
  variant: "alt",
2352
- icon: y.icon,
2353
- style: ve(k(O, y)),
2354
- onClick: (q) => y.click(O)
2352
+ icon: _.icon,
2353
+ style: fe(g(V, _)),
2354
+ onClick: (q) => _.click(V)
2355
2355
  }, {
2356
2356
  default: h(() => [
2357
- D(A(e(j)(y.label)), 1)
2357
+ D(C(e(j)(_.label)), 1)
2358
2358
  ]),
2359
2359
  _: 2
2360
2360
  }, 1032, ["icon", "style", "onClick"]))), 128)),
2361
- $(O).length > 0 ? (t(), V(ke, M({
2361
+ $(V).length > 0 ? (t(), k(Ve, z({
2362
2362
  key: 0,
2363
2363
  ref_for: !0
2364
2364
  }, {
2365
- subject: O,
2366
- actions: $(O)
2365
+ subject: V,
2366
+ actions: $(V)
2367
2367
  }), {
2368
2368
  default: h(({
2369
- visible: y
2369
+ visible: _
2370
2370
  }) => [
2371
- K(L(G, {
2371
+ J(M(G, {
2372
2372
  reactive: "",
2373
- active: y,
2373
+ active: _,
2374
2374
  icon: "dots-three"
2375
2375
  }, null, 8, ["active"]), [
2376
- [s]
2376
+ [B]
2377
2377
  ])
2378
2378
  ]),
2379
2379
  _: 2
2380
2380
  }, 1040)) : b("", !0)
2381
2381
  ])
2382
- ])) : _.actions?.length ? (t(), l("td", na, [
2383
- S("div", {
2382
+ ])) : y.actions?.length ? (t(), l("td", oa, [
2383
+ I("div", {
2384
2384
  class: "table__mobile-actions-grid",
2385
- style: ve(`grid-template-columns: repeat(${r(O).length + ($(O).length ? 1 : 0)}, 1fr);`)
2385
+ style: fe(`grid-template-columns: repeat(${r(V).length + ($(V).length ? 1 : 0)}, 1fr);`)
2386
2386
  }, [
2387
- (t(!0), l(Y, null, E(r(O), (y) => (t(), V(ce, {
2388
- key: `action-${y.action}`,
2387
+ (t(!0), l(X, null, E(r(V), (_) => (t(), k(de, {
2388
+ key: `action-${_.action}`,
2389
2389
  class: "table__mobile-actions-button",
2390
- onClick: (q) => y.click(O)
2390
+ onClick: (q) => _.click(V)
2391
2391
  }, {
2392
2392
  default: h(() => [
2393
- L(G, {
2394
- icon: y.icon || "gear"
2393
+ M(G, {
2394
+ icon: _.icon || "gear"
2395
2395
  }, {
2396
2396
  default: h(() => [
2397
- D(A(e(j)(y.label)), 1)
2397
+ D(C(e(j)(_.label)), 1)
2398
2398
  ]),
2399
2399
  _: 2
2400
2400
  }, 1032, ["icon"])
2401
2401
  ]),
2402
2402
  _: 2
2403
2403
  }, 1032, ["onClick"]))), 128)),
2404
- $(O).length > 0 ? (t(), V(ke, M({
2404
+ $(V).length > 0 ? (t(), k(Ve, z({
2405
2405
  key: 0,
2406
2406
  ref_for: !0
2407
2407
  }, {
2408
- subject: O,
2409
- actions: $(O)
2408
+ subject: V,
2409
+ actions: $(V)
2410
2410
  }), {
2411
2411
  default: h(() => [
2412
- L(G, {
2412
+ M(G, {
2413
2413
  icon: "dots-three",
2414
2414
  class: "table__mobile-actions-button"
2415
2415
  })
@@ -2417,33 +2417,33 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2417
2417
  _: 2
2418
2418
  }, 1040)) : b("", !0)
2419
2419
  ], 4),
2420
- S("div", {
2421
- id: `dropdown-${O._id}`
2422
- }, null, 8, aa)
2420
+ I("div", {
2421
+ id: `dropdown-${V._id}`
2422
+ }, null, 8, na)
2423
2423
  ])) : b("", !0)
2424
- ], 8, Fn))), 128))
2424
+ ], 8, zn))), 128))
2425
2425
  ])),
2426
- S("tfoot", null, [
2427
- _.$slots.tfoot ? I(_.$slots, "tfoot", { key: 0 }, void 0, !0) : _.columns && !_.rows?.length && !e(u)?.loading.getAll ? (t(), l("tr", la, [
2428
- S("td", {
2429
- colspan: c.value + 1
2426
+ I("tfoot", null, [
2427
+ y.$slots.tfoot ? A(y.$slots, "tfoot", { key: 0 }, void 0, !0) : y.columns && !y.rows?.length && !e(u)?.loading.getAll ? (t(), l("tr", aa, [
2428
+ I("td", {
2429
+ colspan: p.value + 1
2430
2430
  }, [
2431
- S("div", ia, A(e(j)("no_results", { capitalize: !0 })) + ". ", 1)
2432
- ], 8, sa)
2431
+ I("div", sa, C(e(j)("no_results", { capitalize: !0 })) + ". ", 1)
2432
+ ], 8, la)
2433
2433
  ])) : b("", !0)
2434
2434
  ])
2435
2435
  ])) : b("", !0);
2436
2436
  };
2437
2437
  }
2438
- }), ua = /* @__PURE__ */ U(ra, [["__scopeId", "data-v-e01a149a"]]), da = /* @__PURE__ */ z({
2438
+ }), ra = /* @__PURE__ */ U(ia, [["__scopeId", "data-v-e01a149a"]]), ua = /* @__PURE__ */ F({
2439
2439
  __name: "aeria-tabular",
2440
2440
  props: {
2441
2441
  individualActions: {},
2442
2442
  layoutOptions: {},
2443
2443
  componentProps: {}
2444
2444
  },
2445
- setup(p) {
2446
- const i = p, o = Ae(), n = we(), a = W(() => {
2445
+ setup(m) {
2446
+ const i = m, o = Ae(), n = we(), a = Y(() => {
2447
2447
  const d = {
2448
2448
  collection: n,
2449
2449
  checkbox: o.hasSelectionActions,
@@ -2455,41 +2455,41 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2455
2455
  return Object.assign(d, i.componentProps);
2456
2456
  });
2457
2457
  return (d, u) => (t(), l("div", null, [
2458
- d.$slots.inner ? I(d.$slots, "inner", { key: 0 }) : b("", !0),
2459
- e(o).properties ? (t(), V(ua, M({ key: 1 }, a.value, {
2458
+ d.$slots.inner ? A(d.$slots, "inner", { key: 0 }) : b("", !0),
2459
+ e(o).properties ? (t(), k(ra, z({ key: 1 }, a.value, {
2460
2460
  key: e(o).$id
2461
- }), ie({ _: 2 }, [
2462
- E(Object.keys(d.$slots).filter((m) => !["inner"].includes(m)), (m) => ({
2463
- name: m,
2464
- fn: h((c) => [
2465
- I(d.$slots, m, le(_e(c)))
2461
+ }), le({ _: 2 }, [
2462
+ E(Object.keys(d.$slots).filter((f) => !["inner"].includes(f)), (f) => ({
2463
+ name: f,
2464
+ fn: h((p) => [
2465
+ A(d.$slots, f, ne(_e(p)))
2466
2466
  ])
2467
2467
  }))
2468
2468
  ]), 1040)) : b("", !0)
2469
2469
  ]));
2470
2470
  }
2471
- }), ca = /* @__PURE__ */ z({
2471
+ }), da = /* @__PURE__ */ F({
2472
2472
  __name: "aeria-grid",
2473
2473
  props: {
2474
2474
  list: { type: Boolean }
2475
2475
  },
2476
- setup(p) {
2476
+ setup(m) {
2477
2477
  return (i, o) => (t(), l("div", {
2478
2478
  class: Q([
2479
2479
  "grid",
2480
2480
  { "grid--list": i.list }
2481
2481
  ])
2482
2482
  }, [
2483
- I(i.$slots, "default", {}, void 0, !0)
2483
+ A(i.$slots, "default", {}, void 0, !0)
2484
2484
  ], 2));
2485
2485
  }
2486
- }), pa = /* @__PURE__ */ U(ca, [["__scopeId", "data-v-4839c834"]]), ma = { key: 0 }, fa = {
2486
+ }), ca = /* @__PURE__ */ U(da, [["__scopeId", "data-v-4839c834"]]), pa = { key: 0 }, ma = {
2487
2487
  key: 1,
2488
2488
  class: "card__information"
2489
- }, va = {
2489
+ }, fa = {
2490
2490
  key: 2,
2491
2491
  class: "card__information"
2492
- }, ya = /* @__PURE__ */ z({
2492
+ }, va = /* @__PURE__ */ F({
2493
2493
  __name: "aeria-grid",
2494
2494
  props: {
2495
2495
  individualActions: {},
@@ -2497,68 +2497,68 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2497
2497
  layoutOptions: {},
2498
2498
  componentName: {}
2499
2499
  },
2500
- setup(p) {
2501
- const o = p.layoutOptions, n = Ae(), a = (d) => Array.isArray(d) ? d[0] : d;
2500
+ setup(m) {
2501
+ const o = m.layoutOptions, n = Ae(), a = (d) => Array.isArray(d) ? d[0] : d;
2502
2502
  return (d, u) => {
2503
- const m = P("clickable");
2504
- return t(), V(pa, {
2503
+ const f = N("clickable");
2504
+ return t(), k(ca, {
2505
2505
  list: d.componentName === "list"
2506
2506
  }, {
2507
2507
  default: h(() => [
2508
- (t(!0), l(Y, null, E(e(n).items, (c) => (t(), V(Ut, {
2509
- key: c._id,
2510
- inactive: !!(e(o).active && !c[e(o).active]),
2508
+ (t(!0), l(X, null, E(e(n).items, (p) => (t(), k(Et, {
2509
+ key: p._id,
2510
+ inactive: !!(e(o).active && !p[e(o).active]),
2511
2511
  horizontal: d.componentName === "list"
2512
- }, ie({
2512
+ }, le({
2513
2513
  footer: h(() => [
2514
- e(o).title ? (t(), l("div", ma, A(c[e(o).title]), 1)) : b("", !0),
2515
- Array.isArray(e(o).information) ? (t(), l("div", fa, [
2516
- (t(!0), l(Y, null, E(e(o).information, (v) => (t(), l("div", {
2514
+ e(o).title ? (t(), l("div", pa, C(p[e(o).title]), 1)) : b("", !0),
2515
+ Array.isArray(e(o).information) ? (t(), l("div", ma, [
2516
+ (t(!0), l(X, null, E(e(o).information, (v) => (t(), l("div", {
2517
2517
  key: `info-${v}`
2518
- }, A(c[v]), 1))), 128))
2519
- ])) : e(o).information ? (t(), l("div", va, A(c[e(o).information]), 1)) : b("", !0)
2518
+ }, C(p[v]), 1))), 128))
2519
+ ])) : e(o).information ? (t(), l("div", fa, C(p[e(o).information]), 1)) : b("", !0)
2520
2520
  ]),
2521
2521
  actions: h(() => [
2522
- d.individualActions?.length ? (t(), V(ke, M({
2522
+ d.individualActions?.length ? (t(), k(Ve, z({
2523
2523
  key: 0,
2524
2524
  ref_for: !0
2525
2525
  }, {
2526
- subject: c,
2526
+ subject: p,
2527
2527
  actions: d.individualActions
2528
2528
  }), {
2529
2529
  default: h(({
2530
2530
  visible: v
2531
2531
  }) => [
2532
- K(L(G, {
2532
+ J(M(G, {
2533
2533
  reactive: "",
2534
2534
  active: v,
2535
2535
  icon: "dots-three-vertical"
2536
2536
  }, null, 8, ["active"]), [
2537
- [m]
2537
+ [f]
2538
2538
  ])
2539
2539
  ]),
2540
2540
  _: 2
2541
2541
  }, 1040)) : b("", !0)
2542
2542
  ]),
2543
2543
  default: h(() => [
2544
- L(Le, M({ expandable: "" }, { ref_for: !0 }, {
2545
- url: a(c[e(o).picture])?.link,
2546
- meta: a(c[e(o).picture]),
2544
+ M(Le, z({ expandable: "" }, { ref_for: !0 }, {
2545
+ url: a(p[e(o).picture])?.link,
2546
+ meta: a(p[e(o).picture]),
2547
2547
  height: "16rem",
2548
- alt: e(o).title ? a(c[e(o).title])?.link : "Item picture"
2548
+ alt: e(o).title ? a(p[e(o).title])?.link : "Item picture"
2549
2549
  }), null, 16)
2550
2550
  ]),
2551
2551
  _: 2
2552
2552
  }, [
2553
- e(o).badge && Array.isArray(c[e(o).badge]) ? {
2553
+ e(o).badge && Array.isArray(p[e(o).badge]) ? {
2554
2554
  name: "badge",
2555
2555
  fn: h(() => [
2556
- (t(!0), l(Y, null, E(c[e(o).badge], (v) => (t(), V(ye, {
2557
- key: `${c._id}-${v}`,
2556
+ (t(!0), l(X, null, E(p[e(o).badge], (v) => (t(), k(ye, {
2557
+ key: `${p._id}-${v}`,
2558
2558
  large: ""
2559
2559
  }, {
2560
2560
  default: h(() => [
2561
- D(A(e(o).translateBadge ? e(j)(v) : v), 1)
2561
+ D(C(e(o).translateBadge ? e(j)(v) : v), 1)
2562
2562
  ]),
2563
2563
  _: 2
2564
2564
  }, 1024))), 128))
@@ -2567,9 +2567,9 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2567
2567
  } : e(o).badge ? {
2568
2568
  name: "badge",
2569
2569
  fn: h(() => [
2570
- L(ye, null, {
2570
+ M(ye, null, {
2571
2571
  default: h(() => [
2572
- D(A(e(o).translateBadge ? e(j)(c[e(o).badge]) : c[e(o).badge]), 1)
2572
+ D(C(e(o).translateBadge ? e(j)(p[e(o).badge]) : p[e(o).badge]), 1)
2573
2573
  ]),
2574
2574
  _: 2
2575
2575
  }, 1024)
@@ -2582,20 +2582,20 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2582
2582
  }, 8, ["list"]);
2583
2583
  };
2584
2584
  }
2585
- }), Ke = /* @__PURE__ */ U(ya, [["__scopeId", "data-v-b4b8f1e7"]]), _a = (p) => ({
2586
- tabular: da,
2587
- grid: Ke,
2588
- list: Ke
2589
- })[p], ha = {
2585
+ }), Xe = /* @__PURE__ */ U(va, [["__scopeId", "data-v-b4b8f1e7"]]), ya = (m) => ({
2586
+ tabular: ua,
2587
+ grid: Xe,
2588
+ list: Xe
2589
+ })[m], _a = {
2590
2590
  key: 2,
2591
2591
  class: "crud__controls"
2592
- }, ba = {
2592
+ }, ha = {
2593
2593
  key: 0,
2594
2594
  class: "crud__search"
2595
- }, $a = { class: "crud__actions" }, ga = { class: "crud__context-badge" }, ka = { class: "crud__data" }, Va = { key: 0 }, Ca = {
2595
+ }, ba = { class: "crud__actions" }, $a = { class: "crud__context-badge" }, ga = { class: "crud__data" }, ka = { key: 0 }, Va = {
2596
2596
  key: 3,
2597
2597
  class: "crud__pagination"
2598
- }, Xe = 30, Oa = /* @__PURE__ */ z({
2598
+ }, Je = 30, Ca = /* @__PURE__ */ F({
2599
2599
  __name: "aeria-crud",
2600
2600
  props: {
2601
2601
  collection: {},
@@ -2610,163 +2610,166 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2610
2610
  noQueryPersistence: { type: Boolean }
2611
2611
  },
2612
2612
  emits: ["uiEvent"],
2613
- setup(p, { emit: i }) {
2614
- const o = J(!1), n = J(!1), a = J((...w) => null), d = J(), u = p, m = i, c = Ve(), v = Pe({
2615
- delay: 600
2616
- }), r = te("meta"), $ = Se(), { reachedEnd: k, detach: _ } = He(null, {
2613
+ setup(m, { emit: i }) {
2614
+ const o = Z(!1), n = Z(!1), a = Z((...O) => null), d = Z(), u = m, f = i, p = Ce(), v = te("meta"), r = Se(), { reachedEnd: $, detach: g } = De(null, {
2617
2615
  antecipate: 600
2618
- }), T = !$.value.md || u.scrollPagination;
2619
- T && ne(k, (w) => {
2620
- w && s.pagination.recordsTotal > s.items.length && y.value < Xe && (y.value += 1, ee());
2616
+ }), y = !r.value.md || u.scrollPagination;
2617
+ y && oe($, (O) => {
2618
+ O && s.pagination.recordsTotal > s.items.length && H.value < Je && (H.value += 1, q());
2621
2619
  });
2622
- const s = ft(u.collection);
2623
- Sn(s, {
2620
+ const s = mt(u.collection);
2621
+ Bn(s, {
2624
2622
  persistInQuery: !u.noQueryPersistence
2625
2623
  });
2626
- const O = De(), X = u.action ? e(u.action) : vt(s, c, O);
2627
- a.value = X[0], d.value = X[1];
2628
- const y = J(0), q = J(!1), ee = async (w) => {
2629
- s.activeFilters = Object.assign({}, w?.filters || s.$filters), Object.assign(s.activeFilters, s.filtersPreset);
2630
- const C = {
2624
+ const B = Qe(), V = u.action ? e(u.action) : ft(s, p, B);
2625
+ a.value = V[0], d.value = V[1];
2626
+ const H = Z(0), _ = Z(!1), q = async (O) => {
2627
+ s.activeFilters = Object.assign({}, O?.filters || s.$filters), Object.assign(s.activeFilters, s.filtersPreset);
2628
+ const T = {
2631
2629
  filters: s.activeFilters,
2632
2630
  limit: s.pagination.limit,
2633
2631
  offset: s.pagination.offset,
2634
2632
  project: s.preferredTableProperties.length > 0 ? s.preferredTableProperties : s.description.table || Object.keys(s.properties)
2635
2633
  };
2636
- y.value > 0 && (C.limit = 15, C.offset = y.value * C.limit), s.description.tableMeta && (C.project = C.project.concat(s.description.tableMeta)), w && Object.assign(C, w), s.loading.getAll = !0;
2637
- const { error: Z, result: f } = await s.$actions.retrieveItems(C);
2638
- if (Z)
2634
+ H.value > 0 && (T.limit = 15, T.offset = H.value * T.limit), s.description.tableMeta && (T.project = T.project.concat(s.description.tableMeta)), O && Object.assign(T, O), s.loading.getAll = !0;
2635
+ const { error: L, result: P } = await s.$actions.retrieveItems(T);
2636
+ if (L)
2639
2637
  return;
2640
- const { data: g, pagination: F } = f;
2641
- s.pagination.recordsCount = F.recordsCount, s.pagination.recordsTotal = F.recordsTotal, y.value === 0 && s.items.splice(0), s.items.push(...g), s.loading.getAll = !1, q.value = !0;
2642
- }, N = async (w) => {
2643
- c.push(Be(c.currentRoute.value, {
2638
+ const { data: c, pagination: w } = P;
2639
+ s.pagination.recordsCount = w.recordsCount, s.pagination.recordsTotal = w.recordsTotal, H.value === 0 && s.items.splice(0), s.items.push(...c), s.loading.getAll = !1, _.value = !0;
2640
+ }, ie = async (O) => {
2641
+ p.push(Be(p.currentRoute.value, {
2644
2642
  query: {
2645
- offset: w.offset,
2646
- limit: w.limit
2643
+ offset: O.offset,
2644
+ limit: O.limit
2647
2645
  }
2648
- })), s.pagination.offset = w.offset, s.pagination.limit = w.limit, ee();
2649
- }, oe = ue("noResultsComponent", null);
2650
- ne(() => [
2651
- c.currentRoute.value.path,
2652
- c.currentRoute.value.query.section
2653
- ], async (w, C) => {
2654
- if (C && C[0] === w[0] && C[1] === w[1])
2646
+ })), s.pagination.offset = O.offset, s.pagination.limit = O.limit, q();
2647
+ }, x = ue("noResultsComponent", null);
2648
+ oe(() => [
2649
+ p.currentRoute.value.path,
2650
+ p.currentRoute.value.query.section
2651
+ ], async (O, T) => {
2652
+ if (T && T[0] === O[0] && T[1] === O[1])
2655
2653
  return;
2656
- const Z = c.currentRoute.value;
2657
- if (r.view.title = u.collection, !u.noFetch && (!Z.query._popstate || s.itemsCount === 0)) {
2658
- const f = yt(s, Z.query);
2659
- Object.keys(f).length > 0 && Object.assign(s.filters, f), await ee();
2654
+ const L = p.currentRoute.value;
2655
+ if (v.view.title = u.collection, !u.noFetch && (!L.query._popstate || s.itemsCount === 0)) {
2656
+ const P = vt(s, L.query);
2657
+ Object.keys(P).length > 0 && Object.assign(s.filters, P), await q();
2660
2658
  }
2661
2659
  }, {
2662
2660
  immediate: !0,
2663
2661
  flush: "post"
2664
2662
  });
2665
- const [be] = v((w) => (c.push(Be(c.currentRoute.value, {
2663
+ const [re] = Fe({
2664
+ delay: 600
2665
+ })((O) => (p.push(Be(p.currentRoute.value, {
2666
2666
  query: {
2667
- search: w || void 0
2667
+ search: O || void 0
2668
2668
  }
2669
- })), w ? (s.filters = Object.assign(ge(s.freshFilters), {
2669
+ })), O ? (s.filters = Object.assign(ke(s.freshFilters), {
2670
2670
  $text: {
2671
- $search: `"${w}"`,
2671
+ $search: `"${O}"`,
2672
2672
  $caseSensitive: !1
2673
2673
  }
2674
- }), ee({
2674
+ }), q({
2675
2675
  offset: 0
2676
- })) : (s.filters = ge(s.freshFilters), y.value = 0, ee())));
2677
- ne(() => s.textQuery, (w) => {
2678
- be(w);
2676
+ })) : (s.filters = ke(s.freshFilters), H.value = 0, q())));
2677
+ oe(() => s.textQuery, (O) => {
2678
+ re(O);
2679
2679
  });
2680
- const Oe = (w) => {
2681
- w.currentLayout = w.currentLayout === "tabular" ? w.description.layout.name : "tabular";
2680
+ const be = (O) => {
2681
+ O.currentLayout = O.currentLayout === "tabular" ? O.description.layout.name : "tabular";
2682
2682
  };
2683
- nt(() => {
2684
- s.$actions.clearFilters(), s.textQuery = "", _();
2685
- }), ne(() => d.value, async (w) => {
2686
- const C = ge(w);
2687
- let Z;
2688
- if (C)
2689
- if ((C.name === "spawnEdit" || C.name === "duplicate") && (Z = s.$actions.get({
2683
+ ot(() => {
2684
+ s.$actions.clearFilters(), s.textQuery = "", g();
2685
+ }), oe(() => d.value, async (O) => {
2686
+ const T = ke(O);
2687
+ let L;
2688
+ if (T)
2689
+ if ((T.name === "spawnEdit" || T.name === "duplicate") && (L = s.$actions.get({
2690
2690
  filters: {
2691
- _id: C.params._id
2691
+ _id: T.params._id
2692
2692
  }
2693
- })), C.name === "spawnAdd")
2694
- s.$actions.clearItem(), C.params?.item && (s.$actions.setItem(C.params.item), Object.keys(C.params.item).forEach((f) => {
2695
- delete s.referenceItem[f];
2693
+ })), T.name === "spawnAdd")
2694
+ s.$actions.clearItem(), T.params?.item && (s.$actions.setItem(T.params.item), Object.keys(T.params.item).forEach((P) => {
2695
+ delete s.referenceItem[P];
2696
2696
  })), o.value = "add";
2697
- else if (C.name === "spawnEdit")
2698
- s.$actions.setItem(C.params), o.value = "edit";
2699
- else if (C.name === "duplicate") {
2700
- await Z;
2701
- const f = Object.entries(s.item).reduce((g, [F, x]) => {
2702
- if (!(F in s.properties))
2697
+ else if (T.name === "spawnEdit")
2698
+ s.$actions.setItem(T.params), o.value = "edit";
2699
+ else if (T.name === "duplicate") {
2700
+ await L;
2701
+ const P = Object.entries(s.item).reduce((c, [w, K]) => {
2702
+ if (!(w in s.properties))
2703
2703
  return {
2704
- ...g,
2705
- [F]: x
2704
+ ...c,
2705
+ [w]: K
2706
2706
  };
2707
- const B = s.properties[F];
2708
- if (B.readOnly)
2709
- return g;
2710
- const R = (H) => {
2711
- const de = re(B);
2712
- if (!de)
2713
- return H;
2714
- if (de.$ref === "file")
2707
+ const ee = s.properties[w];
2708
+ if (ee.readOnly)
2709
+ return c;
2710
+ const S = (R) => {
2711
+ const W = se(ee);
2712
+ if (!W)
2713
+ return R;
2714
+ if (W.$ref === "file")
2715
2715
  return {};
2716
- if (de.inline && H) {
2717
- const { _id: $e, ...xe } = H;
2718
- return xe;
2716
+ if (W.inline && R) {
2717
+ const { _id: ge, ...ve } = R;
2718
+ return ve;
2719
2719
  }
2720
- return H;
2720
+ return R;
2721
2721
  };
2722
- return x = Array.isArray(x) ? x.map(R) : R(x), {
2723
- ...g,
2724
- [F]: x
2722
+ return K = Array.isArray(K) ? K.map(S) : S(K), {
2723
+ ...c,
2724
+ [w]: K
2725
2725
  };
2726
2726
  }, {
2727
2727
  _id: void 0
2728
2728
  });
2729
- s.$actions.setItem(f), delete s.item._id, s.referenceItem = {
2729
+ s.$actions.setItem(P), delete s.item._id, s.referenceItem = {
2730
2730
  _id: void 0
2731
2731
  }, o.value = "duplicate";
2732
2732
  } else
2733
- m("uiEvent", C);
2733
+ f("uiEvent", T);
2734
2734
  }, {
2735
2735
  deep: !0
2736
- }), ne(() => o, ({ value: w }) => {
2737
- w === !1 && s.$actions.clearItem();
2736
+ }), oe(() => o, ({ value: O }) => {
2737
+ O === !1 && s.$actions.clearItem();
2738
2738
  });
2739
- const pe = W(() => {
2739
+ const $e = Y(() => {
2740
2740
  if (!u.noActions)
2741
- return s.individualActions.map((w) => {
2742
- const [C] = v(a.value(w));
2741
+ return s.individualActions.map((O) => {
2742
+ const [T] = Fe({
2743
+ delay: 100,
2744
+ immediate: !0
2745
+ })(a.value(O));
2743
2746
  return {
2744
- click: C,
2745
- ...w
2747
+ click: T,
2748
+ ...O
2746
2749
  };
2747
2750
  });
2748
- }), ae = W(() => s.actions.filter((w) => !w.button));
2749
- return fe(Te, W(() => u.collection)), (w, C) => {
2750
- const Z = P("clickable"), f = P("loading");
2751
- return t(), l(Y, null, [
2752
- n.value ? (t(), V(In, {
2751
+ }), ce = Y(() => s.actions.filter((O) => !O.button));
2752
+ return me(Te, Y(() => u.collection)), (O, T) => {
2753
+ const L = N("clickable"), P = N("loading");
2754
+ return t(), l(X, null, [
2755
+ n.value ? (t(), k(An, {
2753
2756
  key: e(s).$id,
2754
2757
  modelValue: n.value,
2755
- "onUpdate:modelValue": C[0] || (C[0] = (g) => n.value = g)
2758
+ "onUpdate:modelValue": T[0] || (T[0] = (c) => n.value = c)
2756
2759
  }, null, 8, ["modelValue"])) : b("", !0),
2757
- o.value ? (t(), V(Bn, M({
2760
+ o.value ? (t(), k(In, z({
2758
2761
  key: 1,
2759
2762
  visible: o.value,
2760
- "onUpdate:visible": C[1] || (C[1] = (g) => o.value = g),
2763
+ "onUpdate:visible": T[1] || (T[1] = (c) => o.value = c),
2761
2764
  "fixed-right": ""
2762
2765
  }, {
2763
- collection: w.collection,
2764
- individualActions: pe.value
2766
+ collection: O.collection,
2767
+ individualActions: $e.value
2765
2768
  }, {
2766
- onCancel: C[2] || (C[2] = (g) => o.value = !1)
2767
- }), ie({
2769
+ onCancel: T[2] || (T[2] = (c) => o.value = !1)
2770
+ }), le({
2768
2771
  header: h(() => [
2769
- S("span", null, A((() => {
2772
+ I("span", null, C((() => {
2770
2773
  switch (o.value) {
2771
2774
  case "add":
2772
2775
  return e(j)("action.add", { capitalize: !0 });
@@ -2777,22 +2780,22 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2777
2780
  return e(j)("action.edit", { capitalize: !0 });
2778
2781
  }
2779
2782
  })()), 1),
2780
- S("span", null, " " + A(e(j)(w.collection)), 1)
2783
+ I("span", null, " " + C(e(j)(O.collection)), 1)
2781
2784
  ]),
2782
2785
  _: 2
2783
2786
  }, [
2784
- E(Object.keys(w.$slots).filter((g) => g.startsWith("field-")), (g) => ({
2785
- name: g,
2786
- fn: h((F) => [
2787
- I(w.$slots, g, le(_e(F)), void 0, !0)
2787
+ E(Object.keys(O.$slots).filter((c) => c.startsWith("field-")), (c) => ({
2788
+ name: c,
2789
+ fn: h((w) => [
2790
+ A(O.$slots, c, ne(_e(w)), void 0, !0)
2788
2791
  ])
2789
2792
  }))
2790
2793
  ]), 1040, ["visible"])) : b("", !0),
2791
- !w.noActions && (e(s).description.search || Object.keys(e(s).availableFilters).length > 0 || e(s)?.actions.length > 0 || w.$slots.actions || !w.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular") ? (t(), l("div", ha, [
2792
- e(s).description.search ? (t(), l("div", ba, [
2793
- L(he, M({
2794
+ !O.noActions && (e(s).description.search || Object.keys(e(s).availableFilters).length > 0 || e(s)?.actions.length > 0 || O.$slots.actions || !O.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular") ? (t(), l("div", _a, [
2795
+ e(s).description.search ? (t(), l("div", ha, [
2796
+ M(he, z({
2794
2797
  modelValue: e(s).textQuery,
2795
- "onUpdate:modelValue": C[3] || (C[3] = (g) => e(s).textQuery = g)
2798
+ "onUpdate:modelValue": T[3] || (T[3] = (c) => e(s).textQuery = c)
2796
2799
  }, {
2797
2800
  property: {
2798
2801
  type: "string",
@@ -2801,17 +2804,17 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2801
2804
  }
2802
2805
  }), null, 16, ["modelValue"])
2803
2806
  ])) : b("", !0),
2804
- S("div", $a, [
2805
- ae.value.length > 0 || !w.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular" ? (t(), V(ke, { key: 0 }, ie({
2807
+ I("div", ba, [
2808
+ ce.value.length > 0 || !O.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular" ? (t(), k(Ve, { key: 0 }, le({
2806
2809
  default: h(() => [
2807
- L(se, {
2810
+ M(ae, {
2808
2811
  variant: "alt",
2809
2812
  icon: "sliders"
2810
2813
  }, {
2811
2814
  default: h(() => [
2812
- e(s).filtersCount ? (t(), V(ye, { key: 0 }, {
2815
+ e(s).filtersCount ? (t(), k(ye, { key: 0 }, {
2813
2816
  default: h(() => [
2814
- D(A(e(s).filtersCount), 1)
2817
+ D(C(e(s).filtersCount), 1)
2815
2818
  ]),
2816
2819
  _: 1
2817
2820
  })) : b("", !0)
@@ -2824,21 +2827,21 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2824
2827
  Object.keys(e(s).availableFilters).length > 0 ? {
2825
2828
  name: "filter",
2826
2829
  fn: h(() => [
2827
- K((t(), V(G, {
2830
+ J((t(), k(G, {
2828
2831
  icon: "funnel",
2829
- onClick: C[4] || (C[4] = (g) => n.value = !0)
2832
+ onClick: T[4] || (T[4] = (c) => n.value = !0)
2830
2833
  }, {
2831
2834
  default: h(() => [
2832
- D(A(e(j)("filters", { capitalize: !0 })), 1)
2835
+ D(C(e(j)("filters", { capitalize: !0 })), 1)
2833
2836
  ]),
2834
2837
  _: 1
2835
2838
  })), [
2836
- [Z]
2839
+ [L]
2837
2840
  ]),
2838
- S("div", ga, [
2839
- e(s).filtersCount ? (t(), V(ye, { key: 0 }, {
2841
+ I("div", $a, [
2842
+ e(s).filtersCount ? (t(), k(ye, { key: 0 }, {
2840
2843
  default: h(() => [
2841
- D(A(e(s).filtersCount), 1)
2844
+ D(C(e(s).filtersCount), 1)
2842
2845
  ]),
2843
2846
  _: 1
2844
2847
  })) : b("", !0)
@@ -2846,140 +2849,140 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2846
2849
  ]),
2847
2850
  key: "0"
2848
2851
  } : void 0,
2849
- !w.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular" ? {
2852
+ !O.noLayoutToggle && e(s).description.layout && e(s).description.layout?.name !== "tabular" ? {
2850
2853
  name: "layout-toggle",
2851
2854
  fn: h(() => [
2852
- K((t(), V(G, {
2855
+ J((t(), k(G, {
2853
2856
  icon: "table",
2854
- onClick: C[5] || (C[5] = (g) => Oe(e(s)))
2857
+ onClick: T[5] || (T[5] = (c) => be(e(s)))
2855
2858
  }, {
2856
2859
  default: h(() => [
2857
- D(A(e(j)("change_layout", { capitalize: !0 })), 1)
2860
+ D(C(e(j)("change_layout", { capitalize: !0 })), 1)
2858
2861
  ]),
2859
2862
  _: 1
2860
2863
  })), [
2861
- [Z]
2864
+ [L]
2862
2865
  ])
2863
2866
  ]),
2864
2867
  key: "1"
2865
2868
  } : void 0,
2866
- E(ae.value, (g, F) => ({
2867
- name: `action-${F}`,
2869
+ E(ce.value, (c, w) => ({
2870
+ name: `action-${w}`,
2868
2871
  fn: h(() => [
2869
- g ? (t(), V(G, {
2872
+ c ? (t(), k(G, {
2870
2873
  key: 0,
2871
- icon: g.icon || "gear",
2872
- disabled: e(s).selected.length === 0 && "selection" in g && g.selection,
2873
- onClick: (x) => a.value(g)({ _id: e(s).selected.map((B) => typeof B == "string" || B._id) })
2874
+ icon: c.icon || "gear",
2875
+ disabled: e(s).selected.length === 0 && "selection" in c && c.selection,
2876
+ onClick: (K) => a.value(c)({ _id: e(s).selected.map((ee) => typeof ee == "string" || ee._id) })
2874
2877
  }, {
2875
2878
  default: h(() => [
2876
- D(A(e(j)(g.label, { capitalize: !0 })), 1)
2879
+ D(C(e(j)(c.label, { capitalize: !0 })), 1)
2877
2880
  ]),
2878
2881
  _: 2
2879
2882
  }, 1032, ["icon", "disabled", "onClick"])) : b("", !0)
2880
2883
  ])
2881
2884
  }))
2882
- ]), 1024)) : Object.keys(e(s).availableFilters).length > 0 ? (t(), V(se, {
2885
+ ]), 1024)) : Object.keys(e(s).availableFilters).length > 0 ? (t(), k(ae, {
2883
2886
  key: 1,
2884
2887
  variant: "alt",
2885
2888
  icon: "funnel",
2886
- onClick: C[6] || (C[6] = (g) => n.value = !0)
2889
+ onClick: T[6] || (T[6] = (c) => n.value = !0)
2887
2890
  }, {
2888
2891
  default: h(() => [
2889
- S("div", null, A(e(j)("Filters")), 1),
2890
- e(s).filtersCount ? (t(), V(ye, { key: 0 }, {
2892
+ I("div", null, C(e(j)("Filters")), 1),
2893
+ e(s).filtersCount ? (t(), k(ye, { key: 0 }, {
2891
2894
  default: h(() => [
2892
- D(A(e(s).filtersCount), 1)
2895
+ D(C(e(s).filtersCount), 1)
2893
2896
  ]),
2894
2897
  _: 1
2895
2898
  })) : b("", !0)
2896
2899
  ]),
2897
2900
  _: 1
2898
2901
  })) : b("", !0),
2899
- (t(!0), l(Y, null, E(e(s).actions.filter((g) => g.button), (g, F) => (t(), V(se, {
2900
- key: `action-${F}`,
2901
- icon: g.icon,
2902
- disabled: e(s).selected.length === 0 && "selection" in g && g.selection,
2903
- onClick: (x) => a.value(g)({ _id: e(s).selected.map((B) => typeof B == "string" || B._id) })
2902
+ (t(!0), l(X, null, E(e(s).actions.filter((c) => c.button), (c, w) => (t(), k(ae, {
2903
+ key: `action-${w}`,
2904
+ icon: c.icon,
2905
+ disabled: e(s).selected.length === 0 && "selection" in c && c.selection,
2906
+ onClick: (K) => a.value(c)({ _id: e(s).selected.map((ee) => typeof ee == "string" || ee._id) })
2904
2907
  }, {
2905
2908
  default: h(() => [
2906
- D(A(e(j)(g.label, { capitalize: !0 })), 1)
2909
+ D(C(e(j)(c.label, { capitalize: !0 })), 1)
2907
2910
  ]),
2908
2911
  _: 2
2909
2912
  }, 1032, ["icon", "disabled", "onClick"]))), 128)),
2910
- w.$slots.actions ? I(w.$slots, "actions", { key: 2 }, void 0, !0) : b("", !0)
2913
+ O.$slots.actions ? A(O.$slots, "actions", { key: 2 }, void 0, !0) : b("", !0)
2911
2914
  ])
2912
2915
  ])) : b("", !0),
2913
- K((t(), l("div", ka, [
2914
- e(s).itemsCount === 0 && !e(s).loading.getAll && q.value && (e(oe) || w.$slots.empty) ? (t(), l("div", Va, [
2915
- e(oe) ? (t(), V(me(e(oe)), le(M({ key: 0 }, {
2916
+ J((t(), l("div", ga, [
2917
+ e(s).itemsCount === 0 && !e(s).loading.getAll && _.value && (e(x) || O.$slots.empty) ? (t(), l("div", ka, [
2918
+ e(x) ? (t(), k(pe(e(x)), ne(z({ key: 0 }, {
2916
2919
  collection: e(s).$id
2917
2920
  })), {
2918
2921
  default: h(() => [
2919
- e(s).filtersCount === 0 && e(s).description.actions && "spawnAdd" in e(s).description.actions ? (t(), V(se, {
2922
+ e(s).filtersCount === 0 && e(s).description.actions && "spawnAdd" in e(s).description.actions ? (t(), k(ae, {
2920
2923
  key: 0,
2921
2924
  icon: "plus",
2922
- onClick: C[7] || (C[7] = (g) => a.value({
2925
+ onClick: T[7] || (T[7] = (c) => a.value({
2923
2926
  action: "spawnAdd",
2924
2927
  event: "spawnAdd"
2925
2928
  })())
2926
2929
  }, {
2927
2930
  default: h(() => [
2928
- D(A(e(j)("add_first_item", { capitalize: !0 })), 1)
2931
+ D(C(e(j)("add_first_item", { capitalize: !0 })), 1)
2929
2932
  ]),
2930
2933
  _: 1
2931
2934
  })) : b("", !0)
2932
2935
  ]),
2933
2936
  _: 1
2934
- }, 16)) : I(w.$slots, "empty", le(M({ key: 1 }, {
2937
+ }, 16)) : A(O.$slots, "empty", ne(z({ key: 1 }, {
2935
2938
  collection: e(s).$id
2936
2939
  })), void 0, !0)
2937
- ])) : w.$slots.component ? I(w.$slots, "component", le(M({ key: 1 }, {
2940
+ ])) : O.$slots.component ? A(O.$slots, "component", ne(z({ key: 1 }, {
2938
2941
  store: e(s)
2939
- })), void 0, !0) : (t(), V(me(e(_a)(w.layout?.name || e(s).$currentLayout)), M({ key: 2 }, {
2940
- individualActions: pe.value,
2941
- layoutOptions: w.layout?.options || e(s).layout.options,
2942
- componentProps: w.componentProps
2942
+ })), void 0, !0) : (t(), k(pe(e(ya)(O.layout?.name || e(s).$currentLayout)), z({ key: 2 }, {
2943
+ individualActions: $e.value,
2944
+ layoutOptions: O.layout?.options || e(s).layout.options,
2945
+ componentProps: O.componentProps
2943
2946
  }, {
2944
- "component-name": w.layout?.name || e(s).$currentLayout
2945
- }), ie({ _: 2 }, [
2946
- E(Object.keys(w.$slots).filter((g) => g.startsWith("row-")), (g) => ({
2947
- name: g,
2948
- fn: h((F) => [
2949
- I(w.$slots, g, le(_e(F)), void 0, !0)
2947
+ "component-name": O.layout?.name || e(s).$currentLayout
2948
+ }), le({ _: 2 }, [
2949
+ E(Object.keys(O.$slots).filter((c) => c.startsWith("row-")), (c) => ({
2950
+ name: c,
2951
+ fn: h((w) => [
2952
+ A(O.$slots, c, ne(_e(w)), void 0, !0)
2950
2953
  ])
2951
2954
  })),
2952
- w.$slots.tfoot ? {
2955
+ O.$slots.tfoot ? {
2953
2956
  name: "tfoot",
2954
2957
  fn: h(() => [
2955
- I(w.$slots, "tfoot", {}, void 0, !0)
2958
+ A(O.$slots, "tfoot", {}, void 0, !0)
2956
2959
  ]),
2957
2960
  key: "0"
2958
2961
  } : void 0
2959
2962
  ]), 1040, ["component-name"]))
2960
2963
  ])), [
2961
- [f, (!e(T) || y.value === Xe) && e(s).loading.getAll]
2964
+ [P, (!e(y) || H.value === Je) && e(s).loading.getAll]
2962
2965
  ]),
2963
- !e(T) && !w.noControls && !e(s).loading.getAll && e(s).itemsCount > 0 ? (t(), l("div", Ca, [
2964
- L(fo, {
2966
+ !e(y) && !O.noControls && !e(s).loading.getAll && e(s).itemsCount > 0 ? (t(), l("div", Va, [
2967
+ M(mo, {
2965
2968
  pagination: e(s).pagination,
2966
- onPaginate: N
2969
+ onPaginate: ie
2967
2970
  }, null, 8, ["pagination"])
2968
2971
  ])) : b("", !0)
2969
2972
  ], 64);
2970
2973
  };
2971
2974
  }
2972
- }), ul = /* @__PURE__ */ U(Oa, [["__scopeId", "data-v-018dcf56"]]), Aa = { class: "prompt" }, Ia = /* @__PURE__ */ z({
2975
+ }), rl = /* @__PURE__ */ U(Ca, [["__scopeId", "data-v-5848bd1f"]]), Oa = { class: "prompt" }, Aa = /* @__PURE__ */ F({
2973
2976
  __name: "aeria-prompt",
2974
2977
  props: {
2975
2978
  title: {},
2976
2979
  options: {}
2977
2980
  },
2978
- setup(p) {
2981
+ setup(m) {
2979
2982
  const i = te("meta"), o = (n, a) => {
2980
2983
  i.$actions.fulfillPrompt(n, a);
2981
2984
  };
2982
- return (n, a) => (t(), V(Ce, {
2985
+ return (n, a) => (t(), k(Oe, {
2983
2986
  float: "",
2984
2987
  "fill-footer": "",
2985
2988
  "close-hint": !1,
@@ -2987,34 +2990,34 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
2987
2990
  style: { "--panel-min-width": "32rem" }
2988
2991
  }, {
2989
2992
  footer: h(() => [
2990
- S("div", {
2993
+ I("div", {
2991
2994
  class: "prompt__options",
2992
- style: ve(`grid-template-columns: repeat(${Object.keys(n.options).length}, 1fr)`)
2995
+ style: fe(`grid-template-columns: repeat(${Object.keys(n.options).length}, 1fr)`)
2993
2996
  }, [
2994
- (t(!0), l(Y, null, E(Object.entries(n.options), ([d, u], m) => (t(), V(ce, {
2995
- key: `option-${m}`,
2997
+ (t(!0), l(X, null, E(Object.entries(n.options), ([d, u], f) => (t(), k(de, {
2998
+ key: `option-${f}`,
2996
2999
  class: Q([
2997
3000
  "prompt__option",
2998
3001
  `prompt__option--${u.variant || "primary"}`
2999
3002
  ]),
3000
- onClick: (c) => u.click ? u.click(d, u) : o(d, u)
3003
+ onClick: (p) => u.click ? u.click(d, u) : o(d, u)
3001
3004
  }, {
3002
3005
  default: h(() => [
3003
- D(A(u.title), 1)
3006
+ D(C(u.title), 1)
3004
3007
  ]),
3005
3008
  _: 2
3006
3009
  }, 1032, ["class", "onClick"]))), 128))
3007
3010
  ], 4)
3008
3011
  ]),
3009
3012
  default: h(() => [
3010
- S("div", Aa, [
3011
- I(n.$slots, "default", {}, void 0, !0)
3013
+ I("div", Oa, [
3014
+ A(n.$slots, "default", {}, void 0, !0)
3012
3015
  ])
3013
3016
  ]),
3014
3017
  _: 3
3015
3018
  }, 8, ["title"]));
3016
3019
  }
3017
- }), Ba = /* @__PURE__ */ U(Ia, [["__scopeId", "data-v-4cbfd28f"]]), Sa = { class: "toast__content" }, wa = { class: "toast__time" }, Ta = /* @__PURE__ */ z({
3020
+ }), Ia = /* @__PURE__ */ U(Aa, [["__scopeId", "data-v-4cbfd28f"]]), Ba = { class: "toast__content" }, Sa = { class: "toast__time" }, wa = /* @__PURE__ */ F({
3018
3021
  __name: "aeria-toast",
3019
3022
  props: {
3020
3023
  idx: {},
@@ -3022,11 +3025,11 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3022
3025
  date: {},
3023
3026
  icon: {}
3024
3027
  },
3025
- setup(p) {
3028
+ setup(m) {
3026
3029
  const i = te("meta");
3027
3030
  return (o, n) => {
3028
- const a = P("clickable");
3029
- return K((t(), l("div", {
3031
+ const a = N("clickable");
3032
+ return J((t(), l("div", {
3030
3033
  class: Q({
3031
3034
  toast: !0,
3032
3035
  "toast--animate": e(i).toasts[0].itr === o.itr
@@ -3034,25 +3037,25 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3034
3037
  onAnimationend: n[0] || (n[0] = (d) => e(i).$actions.popToast()),
3035
3038
  onClick: n[1] || (n[1] = (d) => e(i).$actions.popToast(o.itr))
3036
3039
  }, [
3037
- L(G, M(
3040
+ M(G, z(
3038
3041
  o.icon ? { icon: o.icon } : { icon: "warning-circle" },
3039
3042
  { style: { "--icon-size": "4rem", "--icon-color": "var(--theme-brand-color-shade-3)" } }
3040
3043
  ), null, 16),
3041
- S("div", Sa, [
3042
- I(o.$slots, "default", {}, void 0, !0),
3043
- S("div", wa, A(o.formatDateTime(o.date, { hoursOnly: !0 })), 1)
3044
+ I("div", Ba, [
3045
+ A(o.$slots, "default", {}, void 0, !0),
3046
+ I("div", Sa, C(o.formatDateTime(o.date, { hoursOnly: !0 })), 1)
3044
3047
  ])
3045
3048
  ], 34)), [
3046
3049
  [a]
3047
3050
  ]);
3048
3051
  };
3049
3052
  }
3050
- }), ja = /* @__PURE__ */ U(Ta, [["__scopeId", "data-v-606d47bf"]]), Ra = ["innerHTML"], La = ["innerHTML"], qa = { class: "main__toasts" }, Ma = ["innerHTML"], za = /* @__PURE__ */ z({
3053
+ }), Ta = /* @__PURE__ */ U(wa, [["__scopeId", "data-v-606d47bf"]]), ja = ["innerHTML"], Ra = ["innerHTML"], La = { class: "main__toasts" }, qa = ["innerHTML"], Ma = /* @__PURE__ */ F({
3051
3054
  __name: "aeria-main",
3052
- setup(p) {
3053
- const i = te("meta"), o = W(() => i.themeOverride || i.theme);
3055
+ setup(m) {
3056
+ const i = te("meta"), o = Y(() => i.themeOverride || i.theme);
3054
3057
  return (n, a) => {
3055
- const d = at("router-view");
3058
+ const d = nt("router-view");
3056
3059
  return t(), l("main", {
3057
3060
  id: "main",
3058
3061
  class: Q([
@@ -3061,15 +3064,15 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3061
3064
  { dark: o.value === "dark" }
3062
3065
  ])
3063
3066
  }, [
3064
- (t(), V(lt, null, {
3067
+ (t(), k(at, null, {
3065
3068
  default: h(() => [
3066
- L(d, null, {
3069
+ M(d, null, {
3067
3070
  default: h(({ Component: u }) => [
3068
- (t(), V(me(u), null, ie({ _: 2 }, [
3069
- E(Object.keys(n.$slots), (m) => ({
3070
- name: m,
3071
+ (t(), k(pe(u), null, le({ _: 2 }, [
3072
+ E(Object.keys(n.$slots), (f) => ({
3073
+ name: f,
3071
3074
  fn: h(() => [
3072
- I(n.$slots, m, {}, void 0, !0)
3075
+ A(n.$slots, f, {}, void 0, !0)
3073
3076
  ])
3074
3077
  }))
3075
3078
  ]), 1024))
@@ -3079,8 +3082,8 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3079
3082
  ]),
3080
3083
  _: 3
3081
3084
  })),
3082
- I(n.$slots, "default", {}, void 0, !0),
3083
- L(Ce, M({
3085
+ A(n.$slots, "default", {}, void 0, !0),
3086
+ M(Oe, z({
3084
3087
  modelValue: e(i).modal.visible,
3085
3088
  "onUpdate:modelValue": a[0] || (a[0] = (u) => e(i).modal.visible = u),
3086
3089
  float: "",
@@ -3094,27 +3097,27 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3094
3097
  key: 0,
3095
3098
  style: { "white-space": "pre-wrap" },
3096
3099
  innerHTML: e(i).modal.body
3097
- }, null, 8, Ra)) : b("", !0),
3098
- e(i).modal.component ? (t(), V(me(e(i).modal.component), { key: 1 })) : b("", !0)
3100
+ }, null, 8, ja)) : b("", !0),
3101
+ e(i).modal.component ? (t(), k(pe(e(i).modal.component), { key: 1 })) : b("", !0)
3099
3102
  ]),
3100
3103
  _: 1
3101
3104
  }, 16, ["modelValue"]),
3102
- e(i).prompt.visible ? (t(), V(Ba, le(M({ key: 0 }, e(i).prompt)), {
3105
+ e(i).prompt.visible ? (t(), k(Ia, ne(z({ key: 0 }, e(i).prompt)), {
3103
3106
  default: h(() => [
3104
- S("div", {
3107
+ I("div", {
3105
3108
  innerHTML: e(i).prompt.body
3106
- }, null, 8, La)
3109
+ }, null, 8, Ra)
3107
3110
  ]),
3108
3111
  _: 1
3109
3112
  }, 16)) : b("", !0),
3110
- S("div", qa, [
3111
- (t(!0), l(Y, null, E(e(i).toasts, (u) => (t(), V(ja, M({ ref_for: !0 }, u, {
3113
+ I("div", La, [
3114
+ (t(!0), l(X, null, E(e(i).toasts, (u) => (t(), k(Ta, z({ ref_for: !0 }, u, {
3112
3115
  key: `toast-${u.itr}`
3113
3116
  }), {
3114
3117
  default: h(() => [
3115
- S("div", {
3118
+ I("div", {
3116
3119
  innerHTML: e(j)(u.text)
3117
- }, null, 8, Ma)
3120
+ }, null, 8, qa)
3118
3121
  ]),
3119
3122
  _: 2
3120
3123
  }, 1040))), 128))
@@ -3122,77 +3125,77 @@ const kt = ["onClick"], Vt = { key: 0 }, Ct = {
3122
3125
  ], 2);
3123
3126
  };
3124
3127
  }
3125
- }), dl = /* @__PURE__ */ U(za, [["__scopeId", "data-v-8de8a4eb"]]), Fa = {}, Ea = { class: "menu" };
3126
- function Ua(p, i) {
3127
- return t(), l("menu", Ea, [
3128
- (t(!0), l(Y, null, E(Object.keys(p.$slots), (o) => (t(), l("div", {
3128
+ }), ul = /* @__PURE__ */ U(Ma, [["__scopeId", "data-v-8de8a4eb"]]), za = {}, Fa = { class: "menu" };
3129
+ function Ea(m, i) {
3130
+ return t(), l("menu", Fa, [
3131
+ (t(!0), l(X, null, E(Object.keys(m.$slots), (o) => (t(), l("div", {
3129
3132
  key: o,
3130
3133
  class: "menu__entry"
3131
3134
  }, [
3132
- I(p.$slots, o, {}, void 0, !0)
3135
+ A(m.$slots, o, {}, void 0, !0)
3133
3136
  ]))), 128))
3134
3137
  ]);
3135
3138
  }
3136
- const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb"]]), Ha = { class: "tabs" }, Da = {
3139
+ const dl = /* @__PURE__ */ U(za, [["render", Ea], ["__scopeId", "data-v-3cfef7fb"]]), Ua = { class: "tabs" }, Ha = {
3137
3140
  key: 0,
3138
3141
  class: "tabs__horizontal"
3139
- }, Qa = {
3142
+ }, Da = {
3140
3143
  key: 0,
3141
3144
  class: "tabs__tab tabs__tab--info"
3142
- }, Ga = ["onClick"], Wa = {
3145
+ }, Qa = ["onClick"], Ga = {
3143
3146
  key: 1,
3144
3147
  class: "tabs__context-menu"
3145
- }, Ya = ["onClick"], Ka = /* @__PURE__ */ z({
3148
+ }, Wa = ["onClick"], Ya = /* @__PURE__ */ F({
3146
3149
  __name: "aeria-tabs",
3147
3150
  props: {
3148
3151
  query: {},
3149
3152
  param: {},
3150
3153
  dropdown: { type: Boolean }
3151
3154
  },
3152
- setup(p) {
3153
- const i = p, o = st(), n = Ve(), a = Se(), d = W(() => {
3155
+ setup(m) {
3156
+ const i = m, o = lt(), n = Ce(), a = Se(), d = Y(() => {
3154
3157
  if (i.query) {
3155
- const m = n.currentRoute.value.query[i.query];
3156
- if (m)
3157
- return m;
3158
+ const f = n.currentRoute.value.query[i.query];
3159
+ if (f)
3160
+ return f;
3158
3161
  } else if (i.param) {
3159
- const m = n.currentRoute.value.params[i.param];
3160
- if (m)
3161
- return m;
3162
+ const f = n.currentRoute.value.params[i.param];
3163
+ if (f)
3164
+ return f;
3162
3165
  }
3163
3166
  return Object.keys(o)[0];
3164
- }), u = (m) => {
3167
+ }), u = (f) => {
3165
3168
  i.query && n.push(Be(n.currentRoute.value, {
3166
3169
  query: {
3167
- [i.query]: m
3170
+ [i.query]: f
3168
3171
  }
3169
3172
  })), i.param && n.push(Be(n.currentRoute.value, {
3170
3173
  params: {
3171
- [i.param]: m
3174
+ [i.param]: f
3172
3175
  }
3173
3176
  }));
3174
3177
  };
3175
- return (m, c) => {
3176
- const v = P("clickable");
3177
- return t(), l("div", Ha, [
3178
- e(a).md && !m.dropdown ? (t(), l("div", Da, [
3179
- m.$slots.default ? (t(), l("div", Qa, [
3180
- I(m.$slots, "default", {}, void 0, !0)
3178
+ return (f, p) => {
3179
+ const v = N("clickable");
3180
+ return t(), l("div", Ua, [
3181
+ e(a).md && !f.dropdown ? (t(), l("div", Ha, [
3182
+ f.$slots.default ? (t(), l("div", Da, [
3183
+ A(f.$slots, "default", {}, void 0, !0)
3181
3184
  ])) : b("", !0),
3182
- (t(!0), l(Y, null, E(Object.keys(m.$slots).filter((r) => r !== "default"), (r, $) => (t(), l("div", {
3185
+ (t(!0), l(X, null, E(Object.keys(f.$slots).filter((r) => r !== "default"), (r, $) => (t(), l("div", {
3183
3186
  key: r,
3184
3187
  class: Q({
3185
3188
  tabs__tab: !0,
3186
3189
  "tabs__tab--current": r === d.value || !d.value && $ === 0
3187
3190
  }),
3188
- onClick: (k) => u(r)
3191
+ onClick: (g) => u(r)
3189
3192
  }, [
3190
- I(m.$slots, r, {}, void 0, !0)
3191
- ], 10, Ga))), 128))
3192
- ])) : (t(), l("div", Wa, [
3193
- L(ke, null, ie({
3193
+ A(f.$slots, r, {}, void 0, !0)
3194
+ ], 10, Qa))), 128))
3195
+ ])) : (t(), l("div", Ga, [
3196
+ M(Ve, null, le({
3194
3197
  default: h(({ visible: r }) => [
3195
- K((t(), V(G, {
3198
+ J((t(), k(G, {
3196
3199
  "icon-right": "",
3197
3200
  active: r,
3198
3201
  icon: "caret-down",
@@ -3200,7 +3203,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3200
3203
  class: "tabs__context-menu-icon"
3201
3204
  }, {
3202
3205
  default: h(() => [
3203
- I(m.$slots, d.value, {}, void 0, !0)
3206
+ A(f.$slots, d.value, {}, void 0, !0)
3204
3207
  ]),
3205
3208
  _: 2
3206
3209
  }, 1032, ["active"])), [
@@ -3209,14 +3212,14 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3209
3212
  ]),
3210
3213
  _: 2
3211
3214
  }, [
3212
- E(Object.keys(m.$slots).filter((r) => r !== "default"), (r) => ({
3215
+ E(Object.keys(f.$slots).filter((r) => r !== "default"), (r) => ({
3213
3216
  name: r,
3214
3217
  fn: h(() => [
3215
- S("div", {
3218
+ I("div", {
3216
3219
  onClick: ($) => u(r)
3217
3220
  }, [
3218
- I(m.$slots, r, {}, void 0, !0)
3219
- ], 8, Ya)
3221
+ A(f.$slots, r, {}, void 0, !0)
3222
+ ], 8, Wa)
3220
3223
  ])
3221
3224
  }))
3222
3225
  ]), 1024)
@@ -3224,81 +3227,81 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3224
3227
  ]);
3225
3228
  };
3226
3229
  }
3227
- }), Xa = /* @__PURE__ */ U(Ka, [["__scopeId", "data-v-a20914ab"]]), Ja = z({
3230
+ }), Ka = /* @__PURE__ */ U(Ya, [["__scopeId", "data-v-a20914ab"]]), Xa = F({
3228
3231
  props: {
3229
3232
  initialValue: String,
3230
3233
  promise: Promise
3231
3234
  },
3232
- setup(p) {
3233
- const i = J(p.initialValue);
3234
- return p.promise instanceof Promise && p.promise.then((o) => {
3235
+ setup(m) {
3236
+ const i = Z(m.initialValue);
3237
+ return m.promise instanceof Promise && m.promise.then((o) => {
3235
3238
  i.value = o;
3236
- }), () => it("div", String(i.value));
3239
+ }), () => st("div", String(i.value));
3237
3240
  }
3238
- }), Za = ["onClick"], Pa = { key: 1 }, Na = /* @__PURE__ */ z({
3241
+ }), Ja = ["onClick"], Za = { key: 1 }, Pa = /* @__PURE__ */ F({
3239
3242
  __name: "aeria-crud-topbar",
3240
3243
  props: {
3241
3244
  collection: {}
3242
3245
  },
3243
- setup(p) {
3244
- const i = p, n = Ve().currentRoute, a = De(), d = W(() => i.collection ? Ae(i.collection, a) : typeof n.value.meta.collection == "string" ? Ae(n.value.meta.collection, a) : typeof n.value.params.collection == "string" ? Ae(n.value.params.collection, a) : null), u = async (m, c) => {
3245
- const { error: v, result: r } = await c.$functions[m.badgeFunction]({
3246
- filters: m.filters
3246
+ setup(m) {
3247
+ const i = m, n = Ce().currentRoute, a = Qe(), d = Y(() => i.collection ? Ae(i.collection, a) : typeof n.value.meta.collection == "string" ? Ae(n.value.meta.collection, a) : typeof n.value.params.collection == "string" ? Ae(n.value.params.collection, a) : null), u = async (f, p) => {
3248
+ const { error: v, result: r } = await p.$functions[f.badgeFunction]({
3249
+ filters: f.filters
3247
3250
  });
3248
3251
  return v ? 0 : r;
3249
3252
  };
3250
- return (m, c) => d.value && d.value.description.filtersPresets ? (t(), V(Xa, {
3253
+ return (f, p) => d.value && d.value.description.filtersPresets ? (t(), k(Ka, {
3251
3254
  key: 0,
3252
3255
  dropdown: "",
3253
3256
  query: "section"
3254
- }, ie({ _: 2 }, [
3257
+ }, le({ _: 2 }, [
3255
3258
  E(Object.entries(d.value.description.filtersPresets), ([v, r]) => ({
3256
3259
  name: v,
3257
3260
  fn: h(() => [
3258
- S("div", {
3261
+ I("div", {
3259
3262
  class: "topbar__preset",
3260
3263
  onClick: ($) => e(Ne)(r, d.value)
3261
3264
  }, [
3262
- r.icon ? (t(), V(G, {
3265
+ r.icon ? (t(), k(G, {
3263
3266
  key: 0,
3264
3267
  icon: r.icon
3265
3268
  }, {
3266
3269
  default: h(() => [
3267
- D(A(r.label || e(j)(v, { plural: !0 })), 1)
3270
+ D(C(r.label || e(j)(v, { plural: !0 })), 1)
3268
3271
  ]),
3269
3272
  _: 2
3270
- }, 1032, ["icon"])) : (t(), l("div", Pa, A(r.label || e(j)(v, { plural: !0 })), 1)),
3271
- r.badgeFunction ? (t(), V(ye, { key: 2 }, {
3273
+ }, 1032, ["icon"])) : (t(), l("div", Za, C(r.label || e(j)(v, { plural: !0 })), 1)),
3274
+ r.badgeFunction ? (t(), k(ye, { key: 2 }, {
3272
3275
  default: h(() => [
3273
- L(e(Ja), {
3276
+ M(e(Xa), {
3274
3277
  "initial-value": "0",
3275
3278
  promise: u(r, d.value)
3276
3279
  }, null, 8, ["promise"])
3277
3280
  ]),
3278
3281
  _: 2
3279
3282
  }, 1024)) : b("", !0)
3280
- ], 8, Za)
3283
+ ], 8, Ja)
3281
3284
  ])
3282
3285
  }))
3283
3286
  ]), 1024)) : b("", !0);
3284
3287
  }
3285
- }), xa = /* @__PURE__ */ U(Na, [["__scopeId", "data-v-f0a45677"]]), el = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3288
+ }), Na = /* @__PURE__ */ U(Pa, [["__scopeId", "data-v-f0a45677"]]), xa = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3286
3289
  __proto__: null,
3287
- default: xa
3288
- }, Symbol.toStringTag, { value: "Module" })), pl = /* @__PURE__ */ z({
3290
+ default: Na
3291
+ }, Symbol.toStringTag, { value: "Module" })), cl = /* @__PURE__ */ F({
3289
3292
  __name: "aeria-password-form",
3290
3293
  props: {
3291
3294
  modelValue: {}
3292
3295
  },
3293
3296
  emits: ["update:modelValue"],
3294
- setup(p) {
3295
- const i = p;
3296
- fe(Te, null);
3297
- const o = _t(), n = W(() => o(
3297
+ setup(m) {
3298
+ const i = m;
3299
+ me(Te, null);
3300
+ const o = yt(), n = Y(() => o(
3298
3301
  i.modelValue.password,
3299
3302
  i.modelValue.confirmation
3300
3303
  ));
3301
- return (a, d) => (t(), V(Me, {
3304
+ return (a, d) => (t(), k(Me, {
3302
3305
  form: {
3303
3306
  password: {
3304
3307
  type: "string",
@@ -3315,16 +3318,16 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3315
3318
  "onUpdate:modelValue": d[0] || (d[0] = (u) => a.$emit("update:modelValue", u))
3316
3319
  }, {
3317
3320
  after: h(() => [
3318
- S("div", null, A(n.value || "Senhas conferem"), 1),
3319
- I(a.$slots, "default", le(_e({ passwordError: n.value })))
3321
+ I("div", null, C(n.value || "Senhas conferem"), 1),
3322
+ A(a.$slots, "default", ne(_e({ passwordError: n.value })))
3320
3323
  ]),
3321
3324
  _: 3
3322
3325
  }, 8, ["model-value"]));
3323
3326
  }
3324
- }), ml = (p, i = []) => ({
3327
+ }), pl = (m, i = []) => ({
3325
3328
  path: "/user",
3326
3329
  name: "/builtin:user",
3327
- component: p,
3330
+ component: m,
3328
3331
  children: i.concat([
3329
3332
  {
3330
3333
  path: "invite/:id",
@@ -3339,7 +3342,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3339
3342
  {
3340
3343
  path: "signin",
3341
3344
  name: "/user/signin",
3342
- component: () => import("./signin-cVrDDO_m.js"),
3345
+ component: () => import("./signin-BZFKbwTv.js"),
3343
3346
  meta: {
3344
3347
  title: "Sign in"
3345
3348
  }
@@ -3347,7 +3350,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3347
3350
  {
3348
3351
  path: "signup",
3349
3352
  name: "/user/signup",
3350
- component: () => import("./signup-DQuIkgfu.js"),
3353
+ component: () => import("./signup-ZmbJgJUx.js"),
3351
3354
  meta: {
3352
3355
  title: "Sign up"
3353
3356
  }
@@ -3355,7 +3358,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3355
3358
  {
3356
3359
  path: "redefine-password",
3357
3360
  name: "/user/redefine-password",
3358
- component: () => import("./redefine-password-DlV5qOxs.js"),
3361
+ component: () => import("./redefine-password-Bz2MeqPp.js"),
3359
3362
  meta: {
3360
3363
  title: "Redefine password"
3361
3364
  }
@@ -3363,16 +3366,16 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3363
3366
  {
3364
3367
  path: "activation",
3365
3368
  name: "/user/activation",
3366
- component: () => import("./activation-B07anxba.js"),
3369
+ component: () => import("./activation-CcLZrr2U.js"),
3367
3370
  meta: {
3368
3371
  title: "Activate user"
3369
3372
  }
3370
3373
  }
3371
3374
  ])
3372
- }), fl = (p, i = []) => ({
3375
+ }), ml = (m, i = []) => ({
3373
3376
  path: "/dashboard",
3374
3377
  name: "/builtin:dashboard",
3375
- component: p,
3378
+ component: m,
3376
3379
  redirect: {
3377
3380
  name: "/dashboard/"
3378
3381
  },
@@ -3385,8 +3388,8 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3385
3388
  name: "/dashboard/:collection",
3386
3389
  props: !0,
3387
3390
  components: {
3388
- default: () => import("./index-Db2uR1by.js"),
3389
- topbar: () => Promise.resolve().then(() => el)
3391
+ default: () => import("./index-C904aSbj.js"),
3392
+ topbar: () => Promise.resolve().then(() => xa)
3390
3393
  },
3391
3394
  meta: {
3392
3395
  title: ({ collectionName: o, t: n }) => n(o, {
@@ -3399,7 +3402,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3399
3402
  name: "/dashboard/:collection/:id",
3400
3403
  props: !0,
3401
3404
  components: {
3402
- default: () => import("./_id_-CcKdtx34.js")
3405
+ default: () => import("./_id_-5pLsKnBu.js")
3403
3406
  },
3404
3407
  meta: {
3405
3408
  title: ({ collectionName: o, t: n }) => n(o, {
@@ -3419,7 +3422,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3419
3422
  children: [
3420
3423
  {
3421
3424
  path: "profile",
3422
- component: () => import("./index-C5UDw5o-.js"),
3425
+ component: () => import("./index-y9W1IkHg.js"),
3423
3426
  meta: {
3424
3427
  title: "User profile",
3425
3428
  icon: "user-square"
@@ -3428,7 +3431,7 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3428
3431
  {
3429
3432
  path: "changepass",
3430
3433
  name: "/dashboard/user/changepass",
3431
- component: () => import("./index-Dz3vo8bz.js"),
3434
+ component: () => import("./index-B0YMsxPx.js"),
3432
3435
  meta: {
3433
3436
  title: "Change password",
3434
3437
  icon: "lock"
@@ -3440,38 +3443,38 @@ const cl = /* @__PURE__ */ U(Fa, [["render", Ua], ["__scopeId", "data-v-3cfef7fb
3440
3443
  });
3441
3444
  export {
3442
3445
  Me as A,
3443
- So as B,
3444
- Ja as C,
3445
- Ba as D,
3446
- ja as E,
3447
- xa as F,
3448
- ml as G,
3449
- fl as H,
3446
+ Bo as B,
3447
+ Xa as C,
3448
+ Ia as D,
3449
+ Ta as E,
3450
+ Na as F,
3451
+ pl as G,
3452
+ ml as H,
3450
3453
  U as _,
3451
- se as a,
3454
+ ae as a,
3452
3455
  G as b,
3453
- pl as c,
3454
- go as d,
3455
- ul as e,
3456
- Bn as f,
3456
+ cl as c,
3457
+ $o as d,
3458
+ rl as e,
3459
+ In as f,
3457
3460
  Le as g,
3458
- cl as h,
3459
- Ce as i,
3460
- rl as j,
3461
+ dl as h,
3462
+ Oe as i,
3463
+ il as j,
3461
3464
  ye as k,
3462
- ce as l,
3463
- Ut as m,
3464
- ke as n,
3465
- pa as o,
3466
- In as p,
3467
- Pt as q,
3468
- dl as r,
3469
- fo as s,
3470
- ua as t,
3471
- Xa as u,
3472
- Ko as v,
3465
+ de as l,
3466
+ Et as m,
3467
+ Ve as n,
3468
+ ca as o,
3469
+ An as p,
3470
+ Zt as q,
3471
+ ul as r,
3472
+ mo as s,
3473
+ ra as t,
3474
+ Ka as u,
3475
+ Yo as v,
3473
3476
  he as w,
3474
- Co as x,
3475
- rn as y,
3476
- Qe as z
3477
+ Vo as x,
3478
+ sn as y,
3479
+ Ge as z
3477
3480
  };