@anzusystems/common-admin 1.47.0-beta.dev-1778753899 → 1.47.0-beta.dev-1778754000

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/labs.js CHANGED
@@ -1,6 +1,6 @@
1
- import { aG as La, aH as Ma, d as he, bT as za, bU as Na, bV as An, j as Ue, k as Oa, a1 as Ua, h as mt, i as Et, aj as Sn, ak as In, al as Pn, am as Dn, ag as Tt, a_ as En, aa as Tn, ab as $n, ac as Fn, ad as Bn, an as Kn, ao as Rn, ae as Vn, af as Ln, bW as Mn, bX as zn, be as Nn, bY as ja, as as On, bZ as Yt, ap as qa, aq as Ga, aV as Wa, b2 as Ha, ar as Ja, E as Xa, a8 as Ya, a2 as Qa, b_ as Za, q as _a, p as eo, x as to, a7 as no, aI as ao, m as Un, b$ as oo, l as lo, c0 as io, c1 as jn, c2 as qn, c3 as Gn, c4 as Wn, c5 as Hn, c6 as Jn, c7 as Xn, c8 as Yn, c9 as Qn, ca as Zn, g as be, cb as so, _ as _n, cc as ro, cd as co, ce as uo, cf as fo, cg as mo, aU as vo, ch as yo, ci as ho, cj as po, z as go } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CK0v0qy2.mjs";
2
- import { aE as Ui, ck as ji, cl as qi, aA as Gi, aB as Wi, aD as Hi, aF as Ji, aC as Xi, aS as Yi, aJ as Qi, bb as Zi, aO as _i, aX as es, ay as ts, az as ns, cm as as, cn as os, co as ls, cp as is, cq as ss, cr as rs, cs as ds, ai as cs, ah as us, ct as fs, cu as ms, cv as vs, cw as ys } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CK0v0qy2.mjs";
3
- import { defineComponent as je, inject as vt, provide as $t, ref as ce, openBlock as g, createBlock as G, withModifiers as te, withCtx as r, renderSlot as V, useModel as We, computed as C, watch as Pe, createElementBlock as B, createElementVNode as L, toDisplayString as $, unref as d, createVNode as s, createTextVNode as j, Fragment as ve, renderList as Qe, normalizeClass as Ce, mergeModels as Ve, createCommentVNode as q, onMounted as Zt, toRaw as pn, resolveComponent as gn, mergeProps as ie, withDirectives as bo, vShow as ko, useSlots as ea, useTemplateRef as Ft, isRef as ta, normalizeStyle as yt, normalizeProps as Re, guardReactiveProps as Ge, shallowRef as Qt, nextTick as Oe, onBeforeUnmount as _t, getCurrentInstance as en, reactive as wo } from "vue";
1
+ import { aG as La, aH as Ma, d as he, bT as za, bU as Na, bV as An, j as Ue, k as Oa, a1 as Ua, h as mt, i as Et, aj as Sn, ak as In, al as Pn, am as Dn, ag as Tt, a_ as En, aa as Tn, ab as $n, ac as Fn, ad as Bn, an as Kn, ao as Rn, ae as Vn, af as Ln, bW as Mn, bX as zn, be as Nn, bY as ja, as as On, bZ as Yt, ap as qa, aq as Ga, aV as Wa, b2 as Ha, ar as Ja, E as Xa, a8 as Ya, a2 as Qa, b_ as Za, q as _a, p as eo, x as to, a7 as no, aI as ao, m as Un, b$ as oo, l as lo, c0 as io, c1 as jn, c2 as qn, c3 as Gn, c4 as Wn, c5 as Hn, c6 as Jn, c7 as Xn, c8 as Yn, c9 as Qn, ca as Zn, g as be, cb as so, _ as _n, cc as ro, cd as co, ce as uo, cf as fo, cg as mo, aU as vo, ch as yo, ci as ho, cj as po, z as go } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-DxRqoX6k.mjs";
2
+ import { aE as Ui, ck as ji, cl as qi, aA as Gi, aB as Wi, aD as Hi, aF as Ji, aC as Xi, aS as Yi, aJ as Qi, bb as Zi, aO as _i, aX as es, ay as ts, az as ns, cm as as, cn as os, co as ls, cp as is, cq as ss, cr as rs, cs as ds, ai as cs, ah as us, ct as fs, cu as ms, cv as vs, cw as ys } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-DxRqoX6k.mjs";
3
+ import { defineComponent as je, inject as vt, provide as $t, ref as ce, openBlock as g, createBlock as G, withModifiers as te, withCtx as r, renderSlot as V, useModel as We, computed as C, watch as Pe, createElementBlock as B, createElementVNode as L, toDisplayString as F, unref as d, createVNode as s, createTextVNode as j, Fragment as ve, renderList as Qe, normalizeClass as Ce, mergeModels as Ve, createCommentVNode as q, onMounted as Zt, toRaw as pn, resolveComponent as gn, mergeProps as ie, withDirectives as bo, vShow as ko, useSlots as ea, useTemplateRef as Ft, isRef as ta, normalizeStyle as yt, normalizeProps as Re, guardReactiveProps as Ge, shallowRef as Qt, nextTick as Oe, onBeforeUnmount as _t, getCurrentInstance as en, reactive as wo } from "vue";
4
4
  import { VForm as Co } from "vuetify/components/VForm";
5
5
  import { useI18n as He } from "vue-i18n";
6
6
  import { VBtn as _ } from "vuetify/components/VBtn";
@@ -133,7 +133,7 @@ const Pi = /* @__PURE__ */ je({
133
133
  },
134
134
  { immediate: !0 }
135
135
  ), (b, M) => (g(), B("div", Eo, [
136
- L("div", To, $(d(p)("common.system.datatable.ordering.title")) + ": ", 1),
136
+ L("div", To, F(d(p)("common.system.datatable.ordering.title")) + ": ", 1),
137
137
  s(_, {
138
138
  variant: "text",
139
139
  rounded: "xl",
@@ -142,7 +142,7 @@ const Pi = /* @__PURE__ */ je({
142
142
  "append-icon": "mdi-chevron-down"
143
143
  }, {
144
144
  default: r(() => [
145
- j($(A.value) + " ", 1),
145
+ j(F(A.value) + " ", 1),
146
146
  s(Bt, {
147
147
  activator: "parent",
148
148
  location: "bottom",
@@ -163,7 +163,7 @@ const Pi = /* @__PURE__ */ je({
163
163
  class: Ce({ "font-weight-bold": W.id === u.value })
164
164
  }, {
165
165
  default: r(() => [
166
- j($(d(p)(W.titleT)), 1)
166
+ j(F(d(p)(W.titleT)), 1)
167
167
  ]),
168
168
  _: 2
169
169
  }, 1032, ["class"])
@@ -218,7 +218,7 @@ const Pi = /* @__PURE__ */ je({
218
218
  }, 300);
219
219
  return (y, Y) => (g(), B("div", $o, [
220
220
  e.hideRecordsPerPage ? q("", !0) : (g(), B("div", Fo, [
221
- j($(d(u)("common.system.datatable.itemsPerPage")) + ": ", 1),
221
+ j(F(d(u)("common.system.datatable.itemsPerPage")) + ": ", 1),
222
222
  s(Ao, {
223
223
  modelValue: d(n).rowsPerPage,
224
224
  "onUpdate:modelValue": Y[0] || (Y[0] = (ae) => d(n).rowsPerPage = ae),
@@ -237,7 +237,7 @@ const Pi = /* @__PURE__ */ je({
237
237
  variant: "text"
238
238
  }, {
239
239
  default: r(() => [
240
- j($(ae), 1)
240
+ j(F(ae), 1)
241
241
  ]),
242
242
  _: 2
243
243
  }, 1032, ["color", "value"]))), 128))
@@ -245,7 +245,7 @@ const Pi = /* @__PURE__ */ je({
245
245
  _: 1
246
246
  }, 8, ["modelValue"])
247
247
  ])),
248
- L("div", Bo, $(k.value) + " - " + $(w.value) + " " + $(d(u)("common.system.datatable.from")) + " " + $(z.value), 1),
248
+ L("div", Bo, F(k.value) + " - " + F(w.value) + " " + F(d(u)("common.system.datatable.from")) + " " + F(z.value), 1),
249
249
  L("div", Ko, [
250
250
  s(_, {
251
251
  disabled: i.value,
@@ -263,7 +263,7 @@ const Pi = /* @__PURE__ */ je({
263
263
  }, null, 8, ["disabled", "onClick"])
264
264
  ]),
265
265
  L("div", Ro, [
266
- L("span", null, $(d(n).page), 1)
266
+ L("span", null, F(d(n).page), 1)
267
267
  ]),
268
268
  L("div", Vo, [
269
269
  s(_, {
@@ -354,10 +354,10 @@ const Pi = /* @__PURE__ */ je({
354
354
  try {
355
355
  const I = z.general.elastic || ae ? "/search" : "", H = Et(M) ? M : h, K = Et(b) ? b : u;
356
356
  if (he(K)) throw new Error("Url template is undefined");
357
- const { pagination: P } = On(W, y ? Ue.Desc : Ue.Asc, {
357
+ const { pagination: D } = On(W, y ? Ue.Desc : Ue.Asc, {
358
358
  rowsPerPage: Y
359
359
  }), re = (he(H) ? K : Sn(K, H)) + I, J = [], de = await x().get(
360
- re + Yt(P, E, z),
360
+ re + Yt(D, E, z),
361
361
  {
362
362
  ...p,
363
363
  signal: w.signal
@@ -368,32 +368,32 @@ const Pi = /* @__PURE__ */ je({
368
368
  if (de.data) {
369
369
  const Z = de.data;
370
370
  if (J.push(...Z.data), qa(Z))
371
- for (P.value.hasNextPage = Z.hasNextPage; P.value.hasNextPage; ) {
372
- P.value.page++;
371
+ for (D.value.hasNextPage = Z.hasNextPage; D.value.hasNextPage; ) {
372
+ D.value.page++;
373
373
  const T = (await x().get(
374
- re + Yt(P, E, z),
374
+ re + Yt(D, E, z),
375
375
  {
376
376
  ...p,
377
377
  signal: w.signal
378
378
  }
379
379
  )).data;
380
- J.push(...T.data), P.value.hasNextPage = T.hasNextPage;
380
+ J.push(...T.data), D.value.hasNextPage = T.hasNextPage;
381
381
  }
382
382
  else if (Ga(Z)) {
383
- if (P.value.totalCount = Z.totalCount, P.value.totalCount <= P.value.rowsPerPage)
383
+ if (D.value.totalCount = Z.totalCount, D.value.totalCount <= D.value.rowsPerPage)
384
384
  return J;
385
- const oe = [], T = Math.ceil(P.value.totalCount / P.value.rowsPerPage);
386
- for (let m = 1; m < T; m++) {
387
- const D = { ...P.value, page: m + 1 }, F = ce(D);
385
+ const oe = [], T = Math.ceil(D.value.totalCount / D.value.rowsPerPage);
386
+ for (let v = 1; v < T; v++) {
387
+ const P = { ...D.value, page: v + 1 }, $ = ce(P);
388
388
  oe.push(
389
- x().get(re + Yt(F, E, z), {
389
+ x().get(re + Yt($, E, z), {
390
390
  ...p,
391
391
  signal: w.signal
392
392
  })
393
393
  );
394
394
  }
395
- (await Promise.all(oe)).forEach((m) => {
396
- J.push(...m.data.data);
395
+ (await Promise.all(oe)).forEach((v) => {
396
+ J.push(...v.data.data);
397
397
  });
398
398
  }
399
399
  return J;
@@ -480,7 +480,7 @@ function Fi(e, x, c, n, u, h, p, k = null, w = void 0, i = !1) {
480
480
  c,
481
481
  n,
482
482
  { storeColumnsLocalStorage: !1, disableActions: !i }
483
- ), P = () => {
483
+ ), D = () => {
484
484
  de(), oe();
485
485
  }, re = (f) => {
486
486
  M(f.sortBy), oe();
@@ -523,18 +523,18 @@ function Fi(e, x, c, n, u, h, p, k = null, w = void 0, i = !1) {
523
523
  filterTouched: A,
524
524
  loading: R,
525
525
  onRowClick: (f) => {
526
- const m = f.target;
527
- if (!m || m.tagName === "INPUT" && m.type === "checkbox")
526
+ const v = f.target;
527
+ if (!v || v.tagName === "INPUT" && v.type === "checkbox")
528
528
  return;
529
- const D = m.closest(".v-data-table__tr");
530
- if (!D || !D.classList.contains("v-data-table__tr")) return;
531
- const F = D.firstElementChild;
532
- if (!F || !F.classList.contains("v-data-table__td")) return;
533
- const O = F.querySelector("input");
529
+ const P = v.closest(".v-data-table__tr");
530
+ if (!P || !P.classList.contains("v-data-table__tr")) return;
531
+ const $ = P.firstElementChild;
532
+ if (!$ || !$.classList.contains("v-data-table__td")) return;
533
+ const O = $.querySelector("input");
534
534
  O && O.click();
535
535
  },
536
536
  onFetchNextPage: J,
537
- onOpen: P,
537
+ onOpen: D,
538
538
  sortByChange: re,
539
539
  getList: oe,
540
540
  resetFilter: () => y(b, oe),
@@ -563,13 +563,13 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
563
563
  get() {
564
564
  return he(n.modelValue) ? h.value : n.modelValue;
565
565
  },
566
- set(P) {
567
- h.value = P, u("update:modelValue", P);
566
+ set(D) {
567
+ h.value = D, u("update:modelValue", D);
568
568
  }
569
569
  }), k = C({
570
570
  get: () => n.pagination,
571
- set: (P) => {
572
- u("update:pagination", { ...pn(P) });
571
+ set: (D) => {
572
+ u("update:pagination", { ...pn(D) });
573
573
  }
574
574
  }), { mdAndDown: w } = aa(), i = ce(!w.value), A = () => {
575
575
  w.value && (i.value = !1);
@@ -584,27 +584,27 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
584
584
  }, y = () => {
585
585
  u(
586
586
  "onConfirm",
587
- n.selectedItems.map((P) => pn(P))
587
+ n.selectedItems.map((D) => pn(D))
588
588
  ), W();
589
589
  }, Y = () => {
590
590
  u("onFetchNextPage");
591
591
  }, ae = () => {
592
592
  u("onPageChange");
593
- }, I = C(() => Math.ceil(k.value.totalCount / k.value.rowsPerPage)), H = C(() => !(mt(k.value.hasNextPage) && k.value.page === I.value || k.value.hasNextPage === !1)), K = (P) => {
594
- P && H.value && !n.loading && Y();
593
+ }, I = C(() => Math.ceil(k.value.totalCount / k.value.rowsPerPage)), H = C(() => !(mt(k.value.hasNextPage) && k.value.page === I.value || k.value.hasNextPage === !1)), K = (D) => {
594
+ D && H.value && !n.loading && Y();
595
595
  };
596
596
  return Zt(() => {
597
597
  n.autoOpen && b();
598
598
  }), x({
599
599
  open: b,
600
600
  closeSidebarOnMobile: A
601
- }), (P, re) => {
601
+ }), (D, re) => {
602
602
  const J = gn("ABtnSecondary"), de = gn("ABtnPrimary");
603
603
  return g(), B(ve, null, [
604
- V(P.$slots, "activator", {
604
+ V(D.$slots, "activator", {
605
605
  props: { onClick: te(() => b(), ["stop"]) }
606
606
  }),
607
- s(nn, ie(P.$attrs, {
607
+ s(nn, ie(D.$attrs, {
608
608
  "model-value": p.value,
609
609
  fullscreen: "",
610
610
  class: "subject-select",
@@ -621,8 +621,8 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
621
621
  onOnCancel: W
622
622
  }, {
623
623
  default: r(() => [
624
- V(P.$slots, "title", {}, () => [
625
- j($(d(E)(e.dialogTitleT)), 1)
624
+ V(D.$slots, "title", {}, () => [
625
+ j(F(d(E)(e.dialogTitleT)), 1)
626
626
  ])
627
627
  ]),
628
628
  _: 3
@@ -635,7 +635,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
635
635
  class: "system-border-b subject-select__second-bar"
636
636
  }, {
637
637
  default: r(() => [
638
- V(P.$slots, "second-bar", {}, () => [
638
+ V(D.$slots, "second-bar", {}, () => [
639
639
  L("div", Uo, [
640
640
  L("div", jo, [
641
641
  L("div", qo, [
@@ -655,17 +655,17 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
655
655
  location: "bottom"
656
656
  }, {
657
657
  default: r(() => [
658
- j($(d(E)("common.subjectSelect.filter.toggle")), 1)
658
+ j(F(d(E)("common.subjectSelect.filter.toggle")), 1)
659
659
  ]),
660
660
  _: 1
661
661
  })
662
662
  ]),
663
663
  _: 1
664
664
  }),
665
- V(P.$slots, "second-bar-left")
665
+ V(D.$slots, "second-bar-left")
666
666
  ]),
667
667
  L("div", Go, [
668
- V(P.$slots, "second-bar-right")
668
+ V(D.$slots, "second-bar-right")
669
669
  ])
670
670
  ])
671
671
  ])
@@ -678,11 +678,11 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
678
678
  }, [
679
679
  L("div", Wo, [
680
680
  L("div", Ho, [
681
- V(P.$slots, "filter")
681
+ V(D.$slots, "filter")
682
682
  ])
683
683
  ]),
684
684
  L("div", Jo, [
685
- V(P.$slots, "content"),
685
+ V(D.$slots, "content"),
686
686
  e.paginationMode === "more" ? (g(), B("div", Xo, [
687
687
  bo((g(), G(J, {
688
688
  loading: e.loading,
@@ -690,8 +690,8 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
690
690
  onClick: Y
691
691
  }, {
692
692
  default: r(() => [
693
- V(P.$slots, "button-confirm-title", {}, () => [
694
- j($(d(E)("common.button.loadMore")), 1)
693
+ V(D.$slots, "button-confirm-title", {}, () => [
694
+ j(F(d(E)("common.button.loadMore")), 1)
695
695
  ])
696
696
  ]),
697
697
  _: 3
@@ -713,10 +713,10 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
713
713
  ])
714
714
  ], 2),
715
715
  L("div", Yo, [
716
- e.minCount === e.maxCount ? (g(), B("div", Qo, $(d(E)("common.subjectSelect.texts.pickExactCount", {
716
+ e.minCount === e.maxCount ? (g(), B("div", Qo, F(d(E)("common.subjectSelect.texts.pickExactCount", {
717
717
  count: e.minCount,
718
718
  selected: z.value
719
- })), 1)) : (g(), B("div", Zo, $(d(E)("common.subjectSelect.texts.pickRangeCount", {
719
+ })), 1)) : (g(), B("div", Zo, F(d(E)("common.subjectSelect.texts.pickRangeCount", {
720
720
  minCount: e.minCount,
721
721
  maxCount: e.maxCount,
722
722
  selected: z.value
@@ -727,8 +727,8 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
727
727
  onClick: te(y, ["stop"])
728
728
  }, {
729
729
  default: r(() => [
730
- V(P.$slots, "button-confirm-title", {}, () => [
731
- j($(d(E)("common.button.confirm")), 1)
730
+ V(D.$slots, "button-confirm-title", {}, () => [
731
+ j(F(d(E)("common.button.confirm")), 1)
732
732
  ])
733
733
  ]),
734
734
  _: 3
@@ -834,7 +834,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
834
834
  editingSnapshots: I,
835
835
  beginEdit: H,
836
836
  cancelEdit: K,
837
- commitEdit: P,
837
+ commitEdit: D,
838
838
  closeEdit: re,
839
839
  requestAutoOpen: J
840
840
  } = qn({
@@ -844,7 +844,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
844
844
  restoreSnapshot: (o, N) => E.updateItem(o, N),
845
845
  watchKeys: () => h.value.map((o) => o[n.keyField]),
846
846
  findEntry: (o) => {
847
- const N = h.value.find((v) => v[n.keyField] === o);
847
+ const N = h.value.find((m) => m[n.keyField] === o);
848
848
  return N ? { data: N } : null;
849
849
  },
850
850
  afterAutoOpen: (o) => {
@@ -856,33 +856,33 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
856
856
  () => n.deleteConfirmTitle ?? p("common.sortable.deleteConfirmTitle")
857
857
  ), T = C(
858
858
  () => n.deleteConfirmText ?? p("common.sortable.deleteConfirmText")
859
- ), f = C(() => !n.readonly && !n.disabled && !n.loading), m = C(() => f.value && n.showAddButton), D = C(() => !!(n.title || k.header)), F = C(() => !!n.onItemSave), O = C(() => {
859
+ ), f = C(() => !n.readonly && !n.disabled && !n.loading), v = C(() => f.value && n.showAddButton), P = C(() => !!(n.title || k.header)), $ = C(() => !!n.onItemSave), O = C(() => {
860
860
  const o = /* @__PURE__ */ new Set();
861
861
  for (const N of h.value) {
862
- const v = N[n.keyField];
863
- Y(v, N) && o.add(v);
862
+ const m = N[n.keyField];
863
+ Y(m, N) && o.add(m);
864
864
  }
865
865
  return o;
866
866
  }), U = /* @__PURE__ */ new Map(), le = C(() => {
867
867
  const o = [], N = /* @__PURE__ */ new Set();
868
- for (const v of E.viewItems.value) {
869
- N.add(v.key);
870
- const se = ae.value.has(v.key), kt = z.value.has(v.key), tt = n.loadingKeys?.has(v.key) ?? !1, nt = n.disableUnsaved ? !1 : O.value.has(v.key), $e = U.get(v.key);
871
- if ($e && $e.raw === v.raw && $e.index === v.index && $e.position === v.position && $e.editing === se && $e.expanded === kt && $e.loading === tt && $e.dirty === nt) {
868
+ for (const m of E.viewItems.value) {
869
+ N.add(m.key);
870
+ const se = ae.value.has(m.key), kt = z.value.has(m.key), tt = n.loadingKeys?.has(m.key) ?? !1, nt = n.disableUnsaved ? !1 : O.value.has(m.key), $e = U.get(m.key);
871
+ if ($e && $e.raw === m.raw && $e.index === m.index && $e.position === m.position && $e.editing === se && $e.expanded === kt && $e.loading === tt && $e.dirty === nt) {
872
872
  o.push($e);
873
873
  continue;
874
874
  }
875
875
  const ze = {
876
- ...v,
876
+ ...m,
877
877
  editing: se,
878
878
  expanded: kt,
879
879
  loading: tt,
880
880
  dirty: nt
881
881
  };
882
- U.set(v.key, ze), o.push(ze);
882
+ U.set(m.key, ze), o.push(ze);
883
883
  }
884
- for (const v of U.keys())
885
- N.has(v) || U.delete(v);
884
+ for (const m of U.keys())
885
+ N.has(m) || U.delete(m);
886
886
  return o;
887
887
  }), X = C(() => le.value.length === 0), ee = (o) => le.value.find((N) => N.key === o), fe = Gn({
888
888
  viewItems: C(() => le.value.map((o) => ({ key: o.key }))),
@@ -899,9 +899,9 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
899
899
  N && et(N);
900
900
  }
901
901
  }), ge = (o) => Zn(o, { compactField: n.compactField }), { resolveValidation: De } = Wn({
902
- getValidationState: (o, N, v) => n.getValidationState?.(o, N, v) ?? null
902
+ getValidationState: (o, N, m) => n.getValidationState?.(o, N, m) ?? null
903
903
  }), xe = () => {
904
- m.value && (J(), u("add", void 0));
904
+ v.value && (J(), u("add", void 0));
905
905
  }, Ee = (o) => {
906
906
  f.value && (J(), u("add", { afterId: o.key }));
907
907
  }, ye = (o) => {
@@ -914,14 +914,14 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
914
914
  }
915
915
  }, Ae = (o) => {
916
916
  if (n.disabled || n.loading) return;
917
- const N = o.key, v = z.value.has(N);
918
- if (v)
917
+ const N = o.key, m = z.value.has(N);
918
+ if (m)
919
919
  z.value.delete(N);
920
920
  else {
921
921
  for (const se of z.value) z.value.delete(se);
922
922
  z.value.add(N);
923
923
  }
924
- u("item-expand", o, !v);
924
+ u("item-expand", o, !m);
925
925
  }, Be = (o) => n.chips || n.disableRowClick || n.defaultExpanded || n.disabled || n.loading ? !1 : !!(o.editing || o.expanded || !n.readonly && n.showEditButton), Le = (o) => {
926
926
  if (Be(o)) {
927
927
  if (o.editing || o.expanded) {
@@ -947,7 +947,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
947
947
  }), we = async (o) => {
948
948
  f.value && await Je(o);
949
949
  }, it = async (o) => {
950
- n.onItemSave && await n.onItemSave(o.raw), P(o), u("item-saved", o);
950
+ n.onItemSave && await n.onItemSave(o.raw), D(o), u("item-saved", o);
951
951
  }, pt = (o) => {
952
952
  K(o);
953
953
  }, et = (o) => {
@@ -956,43 +956,43 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
956
956
  let N = Xe.get(o);
957
957
  return N || (N = {
958
958
  edit: () => {
959
- const v = ee(o);
960
- v && ye(v);
959
+ const m = ee(o);
960
+ m && ye(m);
961
961
  },
962
962
  save: () => {
963
- const v = ee(o);
964
- if (v) return it(v);
963
+ const m = ee(o);
964
+ if (m) return it(m);
965
965
  },
966
966
  cancel: () => {
967
- const v = ee(o);
968
- v && pt(v);
967
+ const m = ee(o);
968
+ m && pt(m);
969
969
  },
970
970
  close: () => {
971
- const v = ee(o);
972
- v && et(v);
971
+ const m = ee(o);
972
+ m && et(m);
973
973
  },
974
974
  delete: async () => {
975
- const v = ee(o);
976
- v && await we(v);
975
+ const m = ee(o);
976
+ m && await we(m);
977
977
  },
978
978
  addAfter: () => {
979
- const v = ee(o);
980
- v && Ee(v);
979
+ const m = ee(o);
980
+ m && Ee(m);
981
981
  },
982
982
  toggleExpand: () => {
983
- const v = ee(o);
984
- v && Ae(v);
983
+ const m = ee(o);
984
+ m && Ae(m);
985
985
  },
986
- update: (v) => E.updateItem(o, v)
986
+ update: (m) => E.updateItem(o, m)
987
987
  }, Xe.set(o, N)), N;
988
988
  };
989
989
  Pe(
990
990
  () => le.value,
991
991
  (o) => {
992
992
  if (Xe.size === 0) return;
993
- const N = new Set(o.map((v) => v.key));
994
- for (const v of Xe.keys())
995
- N.has(v) || Xe.delete(v);
993
+ const N = new Set(o.map((m) => m.key));
994
+ for (const m of Xe.keys())
995
+ N.has(m) || Xe.delete(m);
996
996
  }
997
997
  );
998
998
  const Te = (o) => ({
@@ -1048,9 +1048,9 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1048
1048
  ref: R,
1049
1049
  class: "a-le-card"
1050
1050
  }, [
1051
- D.value ? (g(), B("div", _o, [
1051
+ P.value ? (g(), B("div", _o, [
1052
1052
  V(o.$slots, "header", { title: e.title }, () => [
1053
- e.title ? (g(), B("h3", el, $(e.title), 1)) : q("", !0)
1053
+ e.title ? (g(), B("h3", el, F(e.title), 1)) : q("", !0)
1054
1054
  ])
1055
1055
  ])) : q("", !0),
1056
1056
  e.loading ? (g(), B("div", tl, [
@@ -1067,7 +1067,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1067
1067
  border: "start"
1068
1068
  }, {
1069
1069
  default: r(() => [
1070
- j($(e.error), 1)
1070
+ j(F(e.error), 1)
1071
1071
  ]),
1072
1072
  _: 1
1073
1073
  })
@@ -1080,46 +1080,46 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1080
1080
  s(Xn, {
1081
1081
  title: Z.value,
1082
1082
  "add-label": de.value,
1083
- "can-add": m.value,
1083
+ "can-add": v.value,
1084
1084
  onAdd: xe
1085
1085
  }, null, 8, ["title", "add-label", "can-add"])
1086
1086
  ])
1087
- ])) : (g(!0), B(ve, { key: 4 }, Qe(le.value, (v) => (g(), B("div", {
1088
- key: String(v.key),
1089
- "data-id": String(v.key),
1087
+ ])) : (g(!0), B(ve, { key: 4 }, Qe(le.value, (m) => (g(), B("div", {
1088
+ key: String(m.key),
1089
+ "data-id": String(m.key),
1090
1090
  role: "listitem",
1091
- tabindex: d(fe).rowTabindex(v.key),
1091
+ tabindex: d(fe).rowTabindex(m.key),
1092
1092
  class: Ce(["a-le-row", {
1093
1093
  "a-le-row--two-rows": e.twoRows === "always",
1094
- "a-le-row--editing": v.editing,
1095
- "a-le-row--expanded": v.expanded,
1096
- "a-le-row--unsaved": v.dirty,
1097
- "a-le-row--clickable": Be(v),
1098
- [`a-le-row--validation-${d(De)(v.raw, v.key, v.index)}`]: d(De)(v.raw, v.key, v.index) !== null
1094
+ "a-le-row--editing": m.editing,
1095
+ "a-le-row--expanded": m.expanded,
1096
+ "a-le-row--unsaved": m.dirty,
1097
+ "a-le-row--clickable": Be(m),
1098
+ [`a-le-row--validation-${d(De)(m.raw, m.key, m.index)}`]: d(De)(m.raw, m.key, m.index) !== null
1099
1099
  }]),
1100
- onKeydown: (se) => d(fe).handleKeydown(v.key, se)
1100
+ onKeydown: (se) => d(fe).handleKeydown(m.key, se)
1101
1101
  }, [
1102
- V(o.$slots, "before-item", ie({ ref_for: !0 }, Te(v))),
1102
+ V(o.$slots, "before-item", ie({ ref_for: !0 }, Te(m))),
1103
1103
  L("div", {
1104
1104
  class: "a-le-row-header",
1105
- onClick: (se) => Le(v)
1105
+ onClick: (se) => Le(m)
1106
1106
  }, [
1107
1107
  L("div", il, [
1108
- V(o.$slots, "item-compact", ie({ ref_for: !0 }, Te(v)), () => [
1109
- L("span", sl, $(ge(v.raw)), 1)
1108
+ V(o.$slots, "item-compact", ie({ ref_for: !0 }, Te(m)), () => [
1109
+ L("span", sl, F(ge(m.raw)), 1)
1110
1110
  ]),
1111
- v.dirty ? (g(), G(Yn, {
1111
+ m.dirty ? (g(), G(Yn, {
1112
1112
  key: 0,
1113
1113
  "dot-only": e.chips
1114
1114
  }, null, 8, ["dot-only"])) : q("", !0)
1115
1115
  ]),
1116
1116
  e.chips ? q("", !0) : (g(), B("div", rl, [
1117
- V(o.$slots, "item-status", ie({ ref_for: !0 }, Te(v)), () => [
1118
- e.statusField && v.raw[e.statusField] != null && v.raw[e.statusField] !== "" ? (g(), B("span", dl, $(v.raw[e.statusField]), 1)) : q("", !0)
1117
+ V(o.$slots, "item-status", ie({ ref_for: !0 }, Te(m)), () => [
1118
+ e.statusField && m.raw[e.statusField] != null && m.raw[e.statusField] !== "" ? (g(), B("span", dl, F(m.raw[e.statusField]), 1)) : q("", !0)
1119
1119
  ])
1120
1120
  ])),
1121
1121
  L("div", cl, [
1122
- V(o.$slots, "item-actions", ie({ ref_for: !0 }, Te(v)), () => [
1122
+ V(o.$slots, "item-actions", ie({ ref_for: !0 }, Te(m)), () => [
1123
1123
  e.chips && e.showDeleteButton && f.value ? (g(), G(_, {
1124
1124
  key: 0,
1125
1125
  icon: "",
@@ -1128,7 +1128,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1128
1128
  density: "compact",
1129
1129
  active: !1,
1130
1130
  class: "a-le-action a-le-action--chip-close",
1131
- onClick: te((se) => we(v), ["stop"])
1131
+ onClick: te((se) => we(m), ["stop"])
1132
1132
  }, {
1133
1133
  default: r(() => [
1134
1134
  s(ne, {
@@ -1146,7 +1146,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1146
1146
  color: "primary",
1147
1147
  density: "comfortable",
1148
1148
  class: "mx-1 a-le-action a-le-action--edit",
1149
- onClick: te((se) => ye(v), ["stop"])
1149
+ onClick: te((se) => ye(m), ["stop"])
1150
1150
  }, {
1151
1151
  default: r(() => [
1152
1152
  s(ne, {
@@ -1168,7 +1168,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1168
1168
  variant: "text",
1169
1169
  density: "comfortable",
1170
1170
  class: "mx-1 a-le-action a-le-action--delete",
1171
- onClick: te((se) => we(v), ["stop"])
1171
+ onClick: te((se) => we(m), ["stop"])
1172
1172
  }, {
1173
1173
  default: r(() => [
1174
1174
  s(ne, {
@@ -1207,7 +1207,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1207
1207
  s(ht, { density: "compact" }, {
1208
1208
  default: r(() => [
1209
1209
  s(Se, {
1210
- onClick: te((se) => Ee(v), ["stop"])
1210
+ onClick: te((se) => Ee(m), ["stop"])
1211
1211
  }, {
1212
1212
  prepend: r(() => [
1213
1213
  s(ne, { icon: "mdi-plus" })
@@ -1215,7 +1215,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1215
1215
  default: r(() => [
1216
1216
  s(Fe, null, {
1217
1217
  default: r(() => [
1218
- j($(d(p)("common.sortable.addAfter")), 1)
1218
+ j(F(d(p)("common.sortable.addAfter")), 1)
1219
1219
  ]),
1220
1220
  _: 1
1221
1221
  })
@@ -1235,22 +1235,22 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1235
1235
  ])
1236
1236
  ])
1237
1237
  ], 8, ll),
1238
- (v.editing || e.defaultExpanded) && o.$slots.item ? (g(), B(ve, { key: 0 }, [
1238
+ (m.editing || e.defaultExpanded) && o.$slots.item ? (g(), B(ve, { key: 0 }, [
1239
1239
  L("div", ul, [
1240
1240
  L("div", fl, [
1241
- V(o.$slots, "item", ie({ ref_for: !0 }, Te(v)))
1241
+ V(o.$slots, "item", ie({ ref_for: !0 }, Te(m)))
1242
1242
  ])
1243
1243
  ]),
1244
- V(o.$slots, "item-footer", ie({ ref_for: !0 }, Te(v)), () => [
1245
- F.value && !e.defaultExpanded ? (g(), B("div", ml, [
1244
+ V(o.$slots, "item-footer", ie({ ref_for: !0 }, Te(m)), () => [
1245
+ $.value && !e.defaultExpanded ? (g(), B("div", ml, [
1246
1246
  N[1] || (N[1] = L("div", { class: "a-le-row-footer-spacer" }, null, -1)),
1247
1247
  s(_, {
1248
1248
  variant: "text",
1249
- disabled: v.loading,
1250
- onClick: te((se) => pt(v), ["stop"])
1249
+ disabled: m.loading,
1250
+ onClick: te((se) => pt(m), ["stop"])
1251
1251
  }, {
1252
1252
  default: r(() => [
1253
- j($(d(p)("common.button.cancel")), 1)
1253
+ j(F(d(p)("common.button.cancel")), 1)
1254
1254
  ]),
1255
1255
  _: 1
1256
1256
  }, 8, ["disabled", "onClick"]),
@@ -1258,24 +1258,24 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1258
1258
  color: "primary",
1259
1259
  variant: "flat",
1260
1260
  "prepend-icon": "mdi-check",
1261
- disabled: v.loading,
1262
- onClick: te((se) => it(v), ["stop"])
1261
+ disabled: m.loading,
1262
+ onClick: te((se) => it(m), ["stop"])
1263
1263
  }, {
1264
1264
  default: r(() => [
1265
- j($(d(p)("common.button.save")), 1)
1265
+ j(F(d(p)("common.button.save")), 1)
1266
1266
  ]),
1267
1267
  _: 1
1268
1268
  }, 8, ["disabled", "onClick"])
1269
1269
  ])) : q("", !0)
1270
1270
  ])
1271
- ], 64)) : o.$slots["item-readonly"] && (e.readonly || v.expanded) ? (g(), B("div", vl, [
1271
+ ], 64)) : o.$slots["item-readonly"] && (e.readonly || m.expanded) ? (g(), B("div", vl, [
1272
1272
  L("div", yl, [
1273
- V(o.$slots, "item-readonly", ie({ ref_for: !0 }, Te(v)))
1273
+ V(o.$slots, "item-readonly", ie({ ref_for: !0 }, Te(m)))
1274
1274
  ])
1275
1275
  ])) : q("", !0),
1276
- V(o.$slots, "after-item", ie({ ref_for: !0 }, Te(v)))
1276
+ V(o.$slots, "after-item", ie({ ref_for: !0 }, Te(m)))
1277
1277
  ], 42, ol))), 128)),
1278
- m.value && !e.loading && !e.error && !X.value ? V(o.$slots, "add-button", {
1278
+ v.value && !e.loading && !e.error && !X.value ? V(o.$slots, "add-button", {
1279
1279
  key: 5,
1280
1280
  readonly: e.readonly,
1281
1281
  disabled: e.disabled,
@@ -1291,13 +1291,13 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1291
1291
  icon: "mdi-plus",
1292
1292
  size: "18"
1293
1293
  }),
1294
- L("span", null, $(de.value), 1)
1294
+ L("span", null, F(de.value), 1)
1295
1295
  ])
1296
1296
  ]) : q("", !0)
1297
1297
  ], 512),
1298
1298
  s(Qn, {
1299
1299
  modelValue: d(Ze),
1300
- "onUpdate:modelValue": N[0] || (N[0] = (v) => ta(Ze) ? Ze.value = v : null),
1300
+ "onUpdate:modelValue": N[0] || (N[0] = (m) => ta(Ze) ? Ze.value = m : null),
1301
1301
  title: oe.value,
1302
1302
  text: T.value,
1303
1303
  "confirm-label": d(p)("common.sortable.delete"),
@@ -1307,7 +1307,7 @@ const Uo = { class: "d-flex flex-column w-100 px-1 align-center" }, jo = { class
1307
1307
  onConfirm: d(ot),
1308
1308
  onCancel: d(lt)
1309
1309
  }, null, 8, ["modelValue", "title", "text", "confirm-label", "cancel-label", "error", "in-flight", "onConfirm", "onCancel"]),
1310
- L("div", hl, $(d(fe).grabbedKey.value !== null ? d(p)("common.sortable.keyboardGrab.status", {
1310
+ L("div", hl, F(d(fe).grabbedKey.value !== null ? d(p)("common.sortable.keyboardGrab.status", {
1311
1311
  n: d(fe).grabbedIndex.value + 1,
1312
1312
  total: d(fe).totalCount.value
1313
1313
  }) : ""), 1)
@@ -1318,42 +1318,42 @@ function kl(e, x) {
1318
1318
  const c = x.keyField ?? pl, n = x.positionField ?? gl, u = x.parentField ?? bl, h = x.positionMultiplier ?? 1, p = x.maxDepth, k = (T) => T[c], w = (T) => {
1319
1319
  if (!T.children || T.children.length === 0) return 1;
1320
1320
  let f = 0;
1321
- for (const m of T.children) {
1322
- const D = w(m);
1323
- D > f && (f = D);
1321
+ for (const v of T.children) {
1322
+ const P = w(v);
1323
+ P > f && (f = P);
1324
1324
  }
1325
1325
  return f + 1;
1326
- }, i = (T, f = e.value.children, m = null) => {
1327
- for (const D of f) {
1328
- if (k(D.data) === T) return { node: D, parent: m };
1329
- if (D.children && D.children.length > 0) {
1330
- const F = i(T, D.children, D);
1331
- if (F.node) return F;
1326
+ }, i = (T, f = e.value.children, v = null) => {
1327
+ for (const P of f) {
1328
+ if (k(P.data) === T) return { node: P, parent: v };
1329
+ if (P.children && P.children.length > 0) {
1330
+ const $ = i(T, P.children, P);
1331
+ if ($.node) return $;
1332
1332
  }
1333
1333
  }
1334
1334
  return { node: null, parent: null };
1335
1335
  }, A = (T) => {
1336
1336
  let f = 1 * h;
1337
- for (const m of T)
1338
- m.data[n] !== f && (m.data[n] = f, m.meta.dirty = !0), f += h;
1337
+ for (const v of T)
1338
+ v.data[n] !== f && (v.data[n] = f, v.meta.dirty = !0), f += h;
1339
1339
  }, E = (T) => {
1340
- const f = (m) => {
1341
- A(m);
1342
- for (const D of m) D.children && D.children.length && f(D.children);
1340
+ const f = (v) => {
1341
+ A(v);
1342
+ for (const P of v) P.children && P.children.length && f(P.children);
1343
1343
  };
1344
1344
  f(T.children);
1345
1345
  }, z = (T) => {
1346
1346
  const f = be(T);
1347
1347
  return E(f), f;
1348
1348
  }, R = (T) => {
1349
- const f = [], m = x.expandedKeys?.value;
1350
- let D = 0;
1351
- const F = (O, U, le) => {
1349
+ const f = [], v = x.expandedKeys?.value;
1350
+ let P = 0;
1351
+ const $ = (O, U, le) => {
1352
1352
  for (let X = 0; X < O.length; X++) {
1353
- const ee = O[X], fe = k(ee.data), ge = !he(ee.children), De = ge && (ee.children?.length ?? 0) > 0, xe = ee.children?.length ?? 0, Ee = m ? m.has(fe) : !0, ye = p - (U + 1), Ae = ge && ye > 0, Be = U > 0, Le = X > 0;
1353
+ const ee = O[X], fe = k(ee.data), ge = !he(ee.children), De = ge && (ee.children?.length ?? 0) > 0, xe = ee.children?.length ?? 0, Ee = v ? v.has(fe) : !0, ye = p - (U + 1), Ae = ge && ye > 0, Be = U > 0, Le = X > 0;
1354
1354
  f.push({
1355
1355
  key: fe,
1356
- index: D++,
1356
+ index: P++,
1357
1357
  raw: ee.data,
1358
1358
  position: ee.data[n],
1359
1359
  node: ee,
@@ -1370,97 +1370,97 @@ function kl(e, x) {
1370
1370
  canAddChild: Ae,
1371
1371
  canIndent: Le,
1372
1372
  canOutdent: Be
1373
- }), De && Ee && F(ee.children, U + 1, ee);
1373
+ }), De && Ee && $(ee.children, U + 1, ee);
1374
1374
  }
1375
1375
  };
1376
- return F(T.children, 0, null), f;
1377
- }, b = C(() => R(e.value)), M = (T, f, m) => {
1378
- T.splice(f + 1, 0, m);
1376
+ return $(T.children, 0, null), f;
1377
+ }, b = C(() => R(e.value)), M = (T, f, v) => {
1378
+ T.splice(f + 1, 0, v);
1379
1379
  }, W = (T, f) => {
1380
1380
  if (!f) return T.length;
1381
1381
  if (f.afterId !== void 0) {
1382
- const m = T.findIndex((D) => k(D.data) === f.afterId);
1383
- return m === -1 ? T.length : m + 1;
1382
+ const v = T.findIndex((P) => k(P.data) === f.afterId);
1383
+ return v === -1 ? T.length : v + 1;
1384
1384
  }
1385
1385
  return f.afterIndex !== void 0 ? f.afterIndex < 0 ? T.length : Math.min(f.afterIndex + 1, T.length) : f.index !== void 0 ? Math.max(0, Math.min(f.index, T.length)) : T.length;
1386
1386
  }, y = (T, f) => {
1387
- const m = be(e.value), D = f?.childrenAllowed ?? !0, F = {
1387
+ const v = be(e.value), P = f?.childrenAllowed ?? !0, $ = {
1388
1388
  data: be(T),
1389
- children: D ? [] : void 0,
1389
+ children: P ? [] : void 0,
1390
1390
  meta: { dirty: !1 }
1391
1391
  };
1392
- let O = m.children, U = null;
1392
+ let O = v.children, U = null;
1393
1393
  if (f?.parentId !== void 0 && f.parentId !== null) {
1394
- const { node: X } = i(f.parentId, m.children);
1394
+ const { node: X } = i(f.parentId, v.children);
1395
1395
  X && X.children && (O = X.children, U = X);
1396
1396
  }
1397
1397
  if (f?.afterId !== void 0) {
1398
- const { node: X, parent: ee } = i(f.afterId, m.children);
1398
+ const { node: X, parent: ee } = i(f.afterId, v.children);
1399
1399
  if (X) {
1400
- const fe = ee ? ee.children : m.children, ge = fe.indexOf(X);
1400
+ const fe = ee ? ee.children : v.children, ge = fe.indexOf(X);
1401
1401
  if (ge !== -1)
1402
- return M(fe, ge, F), F.data[u] = ee ? k(ee.data) : null, A(fe), e.value = m, m;
1402
+ return M(fe, ge, $), $.data[u] = ee ? k(ee.data) : null, A(fe), e.value = v, v;
1403
1403
  }
1404
1404
  }
1405
1405
  const le = f?.asFirstChild ? 0 : W(O, f);
1406
- return O.splice(le, 0, F), F.data[u] = U ? k(U.data) : null, A(O), e.value = m, m;
1406
+ return O.splice(le, 0, $), $.data[u] = U ? k(U.data) : null, A(O), e.value = v, v;
1407
1407
  }, Y = (T) => {
1408
- const f = be(e.value), { node: m, parent: D } = i(T, f.children);
1409
- if (!m) return f;
1410
- const F = D ? D.children : f.children, O = F.indexOf(m);
1411
- return O === -1 || (F.splice(O, 1), A(F), e.value = f), f;
1412
- }, ae = (T, f) => {
1413
- const m = be(e.value), { node: D } = i(T, m.children);
1414
- return D && (D.data = be(f), e.value = m), m;
1415
- }, I = (T, f, m) => {
1416
- const { node: D, parent: F } = i(f, T.children);
1417
- if (!D) return null;
1418
- const O = F ? F.children : T.children, U = O.indexOf(D);
1408
+ const f = be(e.value), { node: v, parent: P } = i(T, f.children);
1409
+ if (!v) return f;
1410
+ const $ = P ? P.children : f.children, O = $.indexOf(v);
1411
+ return O === -1 || ($.splice(O, 1), A($), e.value = f), f;
1412
+ }, ae = (T, f, v = !0) => {
1413
+ const P = be(e.value), { node: $ } = i(T, P.children);
1414
+ return $ && ($.data = be(f), v && ($.meta.dirty = !0), e.value = P), P;
1415
+ }, I = (T, f, v) => {
1416
+ const { node: P, parent: $ } = i(f, T.children);
1417
+ if (!P) return null;
1418
+ const O = $ ? $.children : T.children, U = O.indexOf(P);
1419
1419
  if (U === -1) return null;
1420
- const le = m(O, U);
1420
+ const le = v(O, U);
1421
1421
  if (le === null || le === U) return null;
1422
1422
  const [X] = O.splice(U, 1);
1423
1423
  return O.splice(le, 0, X), A(O), T;
1424
1424
  }, H = (T) => {
1425
- const f = be(e.value), m = I(f, T, (D, F) => F > 0 ? F - 1 : null);
1426
- return m && (e.value = m), m;
1425
+ const f = be(e.value), v = I(f, T, (P, $) => $ > 0 ? $ - 1 : null);
1426
+ return v && (e.value = v), v;
1427
1427
  }, K = (T) => {
1428
- const f = be(e.value), m = I(f, T, (D, F) => F < D.length - 1 ? F + 1 : null);
1429
- return m && (e.value = m), m;
1430
- }, P = (T) => {
1431
- const f = be(e.value), m = I(f, T, (D, F) => F > 0 ? 0 : null);
1432
- return m && (e.value = m), m;
1428
+ const f = be(e.value), v = I(f, T, (P, $) => $ < P.length - 1 ? $ + 1 : null);
1429
+ return v && (e.value = v), v;
1430
+ }, D = (T) => {
1431
+ const f = be(e.value), v = I(f, T, (P, $) => $ > 0 ? 0 : null);
1432
+ return v && (e.value = v), v;
1433
1433
  }, re = (T) => {
1434
- const f = be(e.value), m = I(f, T, (D, F) => F < D.length - 1 ? D.length - 1 : null);
1435
- return m && (e.value = m), m;
1434
+ const f = be(e.value), v = I(f, T, (P, $) => $ < P.length - 1 ? P.length - 1 : null);
1435
+ return v && (e.value = v), v;
1436
1436
  }, J = (T) => {
1437
- const f = be(e.value), { node: m, parent: D } = i(T, f.children);
1438
- if (!m) return null;
1439
- const F = D ? D.children : f.children, O = F.indexOf(m);
1437
+ const f = be(e.value), { node: v, parent: P } = i(T, f.children);
1438
+ if (!v) return null;
1439
+ const $ = P ? P.children : f.children, O = $.indexOf(v);
1440
1440
  if (O <= 0) return null;
1441
- const U = F[O - 1];
1441
+ const U = $[O - 1];
1442
1442
  if (he(U.children)) return null;
1443
- const le = w(m);
1444
- return Z(f, k(U.data)) + 1 + le > p ? null : (F.splice(O, 1), U.children.push(m), m.data[u] = k(U.data), A(F), A(U.children), e.value = f, f);
1443
+ const le = w(v);
1444
+ return Z(f, k(U.data)) + 1 + le > p ? null : ($.splice(O, 1), U.children.push(v), v.data[u] = k(U.data), A($), A(U.children), e.value = f, f);
1445
1445
  }, de = (T) => {
1446
- const f = be(e.value), { node: m, parent: D } = i(T, f.children);
1447
- if (!m || !D) return null;
1448
- const { parent: F } = i(k(D.data), f.children), O = F ? F.children : f.children, U = O.indexOf(D);
1446
+ const f = be(e.value), { node: v, parent: P } = i(T, f.children);
1447
+ if (!v || !P) return null;
1448
+ const { parent: $ } = i(k(P.data), f.children), O = $ ? $.children : f.children, U = O.indexOf(P);
1449
1449
  if (U === -1) return null;
1450
- const le = D.children, X = le.indexOf(m);
1451
- return X === -1 ? null : (le.splice(X, 1), O.splice(U + 1, 0, m), m.data[u] = F ? k(F.data) : null, A(le), A(O), e.value = f, f);
1450
+ const le = P.children, X = le.indexOf(v);
1451
+ return X === -1 ? null : (le.splice(X, 1), O.splice(U + 1, 0, v), v.data[u] = $ ? k($.data) : null, A(le), A(O), e.value = f, f);
1452
1452
  }, Z = (T, f) => {
1453
- const m = (D, F) => {
1454
- for (const O of D) {
1455
- if (k(O.data) === f) return F;
1453
+ const v = (P, $) => {
1454
+ for (const O of P) {
1455
+ if (k(O.data) === f) return $;
1456
1456
  if (O.children && O.children.length) {
1457
- const U = m(O.children, F + 1);
1457
+ const U = v(O.children, $ + 1);
1458
1458
  if (U !== null) return U;
1459
1459
  }
1460
1460
  }
1461
1461
  return null;
1462
1462
  };
1463
- return m(T.children, 0) ?? 0;
1463
+ return v(T.children, 0) ?? 0;
1464
1464
  };
1465
1465
  return {
1466
1466
  viewItems: b,
@@ -1470,13 +1470,13 @@ function kl(e, x) {
1470
1470
  updateItem: ae,
1471
1471
  moveUp: H,
1472
1472
  moveDown: K,
1473
- moveTop: P,
1473
+ moveTop: D,
1474
1474
  moveBottom: re,
1475
1475
  indent: J,
1476
1476
  outdent: de,
1477
- moveTo: (T, f, m) => {
1478
- const D = be(e.value), { node: F, parent: O } = i(T, D.children);
1479
- if (!F) return null;
1477
+ moveTo: (T, f, v) => {
1478
+ const P = be(e.value), { node: $, parent: O } = i(T, P.children);
1479
+ if (!$) return null;
1480
1480
  if (f !== null) {
1481
1481
  const ye = (Ae) => {
1482
1482
  if (!Ae.children) return !1;
@@ -1484,23 +1484,23 @@ function kl(e, x) {
1484
1484
  if (k(Be.data) === f || ye(Be)) return !0;
1485
1485
  return !1;
1486
1486
  };
1487
- if (k(F.data) === f || ye(F)) return null;
1487
+ if (k($.data) === f || ye($)) return null;
1488
1488
  }
1489
1489
  let U, le = null, X = 0;
1490
1490
  if (f === null)
1491
- U = D.children, X = 0;
1491
+ U = P.children, X = 0;
1492
1492
  else {
1493
- const { node: ye } = i(f, D.children);
1493
+ const { node: ye } = i(f, P.children);
1494
1494
  if (!ye || he(ye.children)) return null;
1495
- U = ye.children, le = ye, X = Z(D, f) + 1;
1495
+ U = ye.children, le = ye, X = Z(P, f) + 1;
1496
1496
  }
1497
- const ee = w(F);
1497
+ const ee = w($);
1498
1498
  if (X + ee > p) return null;
1499
- const fe = O ? O.children : D.children, ge = fe.indexOf(F);
1499
+ const fe = O ? O.children : P.children, ge = fe.indexOf($);
1500
1500
  if (ge === -1) return null;
1501
1501
  const De = fe === U, [xe] = fe.splice(ge, 1);
1502
- let Ee = m;
1503
- return De && ge < m && (Ee = m - 1), Ee = Math.max(0, Math.min(Ee, U.length)), U.splice(Ee, 0, xe), xe.data[u] = le ? k(le.data) : null, De || A(fe), A(U), e.value = D, D;
1502
+ let Ee = v;
1503
+ return De && ge < v && (Ee = v - 1), Ee = Math.max(0, Math.min(Ee, U.length)), U.splice(Ee, 0, xe), xe.data[u] = le ? k(le.data) : null, De || A(fe), A(U), e.value = P, P;
1504
1504
  },
1505
1505
  recalculatePositions: z,
1506
1506
  calculateSubtreeDepth: w
@@ -1539,7 +1539,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1539
1539
  containerPaddingLeft: i
1540
1540
  } = e;
1541
1541
  if (c.key === n || sa(h, n, c.key)) return null;
1542
- const A = x.y - c.rect.top, E = c.rect.height, z = A < E / 2, R = z ? "top" : "bottom", b = h.findIndex((P) => P.key === c.key), M = z ? Pt(h, b - 1, -1, n) : Pt(h, b, -1, n), W = z ? Pt(h, b, 1, n) : Pt(h, b + 1, 1, n), y = x.x - w - i, Y = Math.round(y / k), ae = M ? M.depth + 1 : 0, I = W ? W.depth : 0, H = Math.max(I, Math.min(Y, ae));
1542
+ const A = x.y - c.rect.top, E = c.rect.height, z = A < E / 2, R = z ? "top" : "bottom", b = h.findIndex((D) => D.key === c.key), M = z ? Pt(h, b - 1, -1, n) : Pt(h, b, -1, n), W = z ? Pt(h, b, 1, n) : Pt(h, b + 1, 1, n), y = x.x - w - i, Y = Math.round(y / k), ae = M ? M.depth + 1 : 0, I = W ? W.depth : 0, H = Math.max(I, Math.min(Y, ae));
1543
1543
  let K;
1544
1544
  if (!M)
1545
1545
  K = {
@@ -1575,16 +1575,16 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1575
1575
  levelRowKey: M.key
1576
1576
  };
1577
1577
  else {
1578
- const P = wl(h, M.key, H);
1579
- P ? K = {
1578
+ const D = wl(h, M.key, H);
1579
+ D ? K = {
1580
1580
  type: "insert",
1581
1581
  refKey: c.key,
1582
1582
  refEdge: R,
1583
- parentKey: P.parentKey,
1584
- index: P.siblingIndex + 1,
1583
+ parentKey: D.parentKey,
1584
+ index: D.siblingIndex + 1,
1585
1585
  depth: H,
1586
1586
  makeChild: !1,
1587
- levelRowKey: P.key
1587
+ levelRowKey: D.key
1588
1588
  } : K = {
1589
1589
  type: "insert",
1590
1590
  refKey: c.key,
@@ -1693,20 +1693,20 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1693
1693
  ])], 10, Sl)) : e.context.showExpandToggle ? (g(), B("span", Il)) : q("", !0),
1694
1694
  L("div", Pl, [
1695
1695
  V(w.$slots, "item-compact", Re(Ge(p())), () => [
1696
- L("span", Dl, $(e.context.resolveCompactText(e.vi.raw, e.vi.key)), 1)
1696
+ L("span", Dl, F(e.context.resolveCompactText(e.vi.raw, e.vi.key)), 1)
1697
1697
  ]),
1698
1698
  e.vi.hasChildren ? (g(), B("span", El, [
1699
1699
  s(ne, {
1700
1700
  icon: "mdi-file-tree",
1701
1701
  size: "14"
1702
1702
  }),
1703
- j(" +" + $(e.vi.childrenCount), 1)
1703
+ j(" +" + F(e.vi.childrenCount), 1)
1704
1704
  ])) : q("", !0),
1705
1705
  e.vi.unsaved ? (g(), G(Yn, { key: 1 })) : q("", !0)
1706
1706
  ]),
1707
1707
  e.context.reorderMode ? q("", !0) : (g(), B("div", Tl, [
1708
1708
  V(w.$slots, "item-status", Re(Ge(p())), () => [
1709
- e.context.statusField && e.vi.raw[e.context.statusField] != null && e.vi.raw[e.context.statusField] !== "" ? (g(), B("span", $l, $(e.vi.raw[e.context.statusField]), 1)) : q("", !0)
1709
+ e.context.statusField && e.vi.raw[e.context.statusField] != null && e.vi.raw[e.context.statusField] !== "" ? (g(), B("span", $l, F(e.vi.raw[e.context.statusField]), 1)) : q("", !0)
1710
1710
  ])
1711
1711
  ])),
1712
1712
  L("div", Fl, [
@@ -1788,7 +1788,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1788
1788
  default: r(() => [
1789
1789
  s(Fe, null, {
1790
1790
  default: r(() => [
1791
- j($(d(n)("common.sortable.moveToTop")), 1)
1791
+ j(F(d(n)("common.sortable.moveToTop")), 1)
1792
1792
  ]),
1793
1793
  _: 1
1794
1794
  })
@@ -1805,7 +1805,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1805
1805
  default: r(() => [
1806
1806
  s(Fe, null, {
1807
1807
  default: r(() => [
1808
- j($(d(n)("common.sortable.moveToBottom")), 1)
1808
+ j(F(d(n)("common.sortable.moveToBottom")), 1)
1809
1809
  ]),
1810
1810
  _: 1
1811
1811
  })
@@ -1822,7 +1822,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1822
1822
  default: r(() => [
1823
1823
  s(Fe, null, {
1824
1824
  default: r(() => [
1825
- j($(d(n)("common.sortable.moveToPosition.action")), 1)
1825
+ j(F(d(n)("common.sortable.moveToPosition.action")), 1)
1826
1826
  ]),
1827
1827
  _: 1
1828
1828
  })
@@ -1839,7 +1839,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1839
1839
  default: r(() => [
1840
1840
  s(Fe, null, {
1841
1841
  default: r(() => [
1842
- j($(d(n)("common.sortable.changeParent.action")), 1)
1842
+ j(F(d(n)("common.sortable.changeParent.action")), 1)
1843
1843
  ]),
1844
1844
  _: 1
1845
1845
  })
@@ -1856,7 +1856,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1856
1856
  default: r(() => [
1857
1857
  s(Fe, null, {
1858
1858
  default: r(() => [
1859
- j($(d(n)("common.sortable.indent")), 1)
1859
+ j(F(d(n)("common.sortable.indent")), 1)
1860
1860
  ]),
1861
1861
  _: 1
1862
1862
  })
@@ -1873,7 +1873,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1873
1873
  default: r(() => [
1874
1874
  s(Fe, null, {
1875
1875
  default: r(() => [
1876
- j($(d(n)("common.sortable.outdent")), 1)
1876
+ j(F(d(n)("common.sortable.outdent")), 1)
1877
1877
  ]),
1878
1878
  _: 1
1879
1879
  })
@@ -1893,7 +1893,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1893
1893
  default: r(() => [
1894
1894
  s(Fe, { class: "text-error" }, {
1895
1895
  default: r(() => [
1896
- j($(d(n)("common.sortable.delete")), 1)
1896
+ j(F(d(n)("common.sortable.delete")), 1)
1897
1897
  ]),
1898
1898
  _: 1
1899
1899
  })
@@ -1988,7 +1988,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
1988
1988
  default: r(() => [
1989
1989
  s(Fe, null, {
1990
1990
  default: r(() => [
1991
- j($(d(n)("common.sortable.addAfter")), 1)
1991
+ j(F(d(n)("common.sortable.addAfter")), 1)
1992
1992
  ]),
1993
1993
  _: 1
1994
1994
  })
@@ -2005,7 +2005,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2005
2005
  default: r(() => [
2006
2006
  s(Fe, null, {
2007
2007
  default: r(() => [
2008
- j($(d(n)("common.sortable.addChild")), 1)
2008
+ j(F(d(n)("common.sortable.addChild")), 1)
2009
2009
  ]),
2010
2010
  _: 1
2011
2011
  })
@@ -2040,7 +2040,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2040
2040
  onClick: i[15] || (i[15] = te((A) => e.callbacks.onCancelClick(e.vi), ["stop"]))
2041
2041
  }, {
2042
2042
  default: r(() => [
2043
- j($(d(n)("common.button.cancel")), 1)
2043
+ j(F(d(n)("common.button.cancel")), 1)
2044
2044
  ]),
2045
2045
  _: 1
2046
2046
  }, 8, ["disabled"]),
@@ -2052,7 +2052,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2052
2052
  onClick: i[16] || (i[16] = te((A) => e.callbacks.onSaveClick(e.vi), ["stop"]))
2053
2053
  }, {
2054
2054
  default: r(() => [
2055
- j($(d(n)("common.button.save")), 1)
2055
+ j(F(d(n)("common.button.save")), 1)
2056
2056
  ]),
2057
2057
  _: 1
2058
2058
  }, 8, ["disabled"])
@@ -2135,15 +2135,15 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2135
2135
  const I = /* @__PURE__ */ new Set();
2136
2136
  if (c.sourceKey === null) return I;
2137
2137
  const H = (K) => {
2138
- for (const P of K) {
2139
- if (P.data[c.keyField] === c.sourceKey) {
2138
+ for (const D of K) {
2139
+ if (D.data[c.keyField] === c.sourceKey) {
2140
2140
  const J = (de) => {
2141
2141
  for (const Z of de)
2142
2142
  I.add(Z.data[c.keyField]), Z.children?.length && J(Z.children);
2143
2143
  };
2144
- return P.children?.length && J(P.children), !0;
2144
+ return D.children?.length && J(D.children), !0;
2145
2145
  }
2146
- if (P.children?.length && H(P.children)) return !0;
2146
+ if (D.children?.length && H(D.children)) return !0;
2147
2147
  }
2148
2148
  return !1;
2149
2149
  };
@@ -2154,8 +2154,8 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2154
2154
  for (const K of H) {
2155
2155
  if (K.data[c.keyField] === c.sourceKey) return K;
2156
2156
  if (K.children?.length) {
2157
- const P = I(K.children);
2158
- if (P) return P;
2157
+ const D = I(K.children);
2158
+ if (D) return D;
2159
2159
  }
2160
2160
  }
2161
2161
  return null;
@@ -2164,10 +2164,10 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2164
2164
  }), A = C(() => {
2165
2165
  if (c.sourceKey === null) return;
2166
2166
  const I = (H, K) => {
2167
- for (const P of H) {
2168
- if (P.data[c.keyField] === c.sourceKey) return K;
2169
- if (P.children?.length) {
2170
- const re = I(P.children, P.data[c.keyField]);
2167
+ for (const D of H) {
2168
+ if (D.data[c.keyField] === c.sourceKey) return K;
2169
+ if (D.children?.length) {
2170
+ const re = I(D.children, D.data[c.keyField]);
2171
2171
  if (re !== void 0) return re;
2172
2172
  }
2173
2173
  }
@@ -2183,8 +2183,8 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2183
2183
  disallowed: A.value === null,
2184
2184
  reason: A.value === null ? "currentParent" : null
2185
2185
  });
2186
- const K = (P, re) => {
2187
- for (const J of P) {
2186
+ const K = (D, re) => {
2187
+ for (const J of D) {
2188
2188
  const de = J.data[c.keyField];
2189
2189
  let Z = !1, oe = null;
2190
2190
  de === c.sourceKey ? (Z = !0, oe = "self") : w.value.has(de) ? (Z = !0, oe = "descendant") : A.value !== void 0 && A.value === de ? (Z = !0, oe = "currentParent") : re + 1 + H > c.maxDepth && (Z = !0, oe = "maxDepth"), I.push({
@@ -2220,7 +2220,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2220
2220
  default: r(() => [
2221
2221
  s(oa, null, {
2222
2222
  default: r(() => [
2223
- j($(d(h)("common.sortable.changeParent.title")), 1)
2223
+ j(F(d(h)("common.sortable.changeParent.title")), 1)
2224
2224
  ]),
2225
2225
  _: 1
2226
2226
  }),
@@ -2235,8 +2235,8 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2235
2235
  density: "compact"
2236
2236
  }, {
2237
2237
  default: r(() => [
2238
- L("strong", null, $(d(h)("common.sortable.changeParent.noTargetsTitle")), 1),
2239
- L("div", null, $(d(h)("common.sortable.changeParent.noTargetsText")), 1)
2238
+ L("strong", null, F(d(h)("common.sortable.changeParent.noTargetsTitle")), 1),
2239
+ L("div", null, F(d(h)("common.sortable.changeParent.noTargetsText")), 1)
2240
2240
  ]),
2241
2241
  _: 1
2242
2242
  })
@@ -2259,7 +2259,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2259
2259
  style: yt({ paddingInlineStart: Y(K.depth) }),
2260
2260
  "data-disallowed": K.disallowed ? "true" : "false",
2261
2261
  "data-reason": K.reason ?? "",
2262
- onClick: (P) => M(K)
2262
+ onClick: (D) => M(K)
2263
2263
  }, {
2264
2264
  prepend: r(() => [
2265
2265
  K.key === null ? (g(), G(ne, {
@@ -2289,7 +2289,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2289
2289
  class: "pt-0"
2290
2290
  }, {
2291
2291
  default: r(() => [
2292
- L("div", Ol, $(d(h)("common.sortable.changeParent.placementHeading", {
2292
+ L("div", Ol, F(d(h)("common.sortable.changeParent.placementHeading", {
2293
2293
  label: R.value?.label ?? ""
2294
2294
  })), 1),
2295
2295
  s(Po, {
@@ -2322,7 +2322,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2322
2322
  onClick: y
2323
2323
  }, {
2324
2324
  default: r(() => [
2325
- j($(d(h)("common.sortable.reorderCancel")), 1)
2325
+ j(F(d(h)("common.sortable.reorderCancel")), 1)
2326
2326
  ]),
2327
2327
  _: 1
2328
2328
  }),
@@ -2333,7 +2333,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2333
2333
  onClick: W
2334
2334
  }, {
2335
2335
  default: r(() => [
2336
- j($(d(h)("common.sortable.changeParent.confirm")), 1)
2336
+ j(F(d(h)("common.sortable.changeParent.confirm")), 1)
2337
2337
  ]),
2338
2338
  _: 1
2339
2339
  }, 8, ["disabled"])
@@ -2445,16 +2445,16 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2445
2445
  },
2446
2446
  { excludeFields: [n.positionField, n.parentField], source: h }
2447
2447
  )
2448
- ), K = Qt(null), P = ce(/* @__PURE__ */ new Set()), re = () => {
2449
- Y(), P.value = /* @__PURE__ */ new Set();
2448
+ ), K = Qt(null), D = ce(/* @__PURE__ */ new Set()), re = () => {
2449
+ Y(), D.value = /* @__PURE__ */ new Set();
2450
2450
  }, J = (t) => {
2451
2451
  const { node: l } = y.findNode(t);
2452
2452
  if (!l) {
2453
- P.value.add(t);
2453
+ D.value.add(t);
2454
2454
  return;
2455
2455
  }
2456
2456
  const a = (S) => {
2457
- P.value.add(S.data[n.keyField]), S.children && S.children.forEach(a);
2457
+ D.value.add(S.data[n.keyField]), S.children && S.children.forEach(a);
2458
2458
  };
2459
2459
  a(l);
2460
2460
  }, de = C(() => {
@@ -2469,7 +2469,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2469
2469
  const t = [], l = /* @__PURE__ */ new Set();
2470
2470
  for (const a of y.viewItems.value) {
2471
2471
  l.add(a.key);
2472
- const S = X.value.has(a.key), Q = M.value.has(a.key), me = b.value.has(a.key), Ke = n.loadingKeys?.has(a.key) ?? !1, Ne = n.disableUnsaved ? !1 : P.value.has(a.key), ut = n.disableUnsaved ? !1 : de.value.has(a.key), ft = ut || Ne, ue = Z.get(a.key);
2472
+ const S = X.value.has(a.key), Q = M.value.has(a.key), me = b.value.has(a.key), Ke = n.loadingKeys?.has(a.key) ?? !1, Ne = n.disableUnsaved ? !1 : D.value.has(a.key), ut = n.disableUnsaved ? !1 : de.value.has(a.key), ft = ut || Ne, ue = Z.get(a.key);
2473
2473
  if (ue && ue.raw === a.raw && ue.index === a.index && ue.position === a.position && ue.depth === a.depth && ue.parentKey === a.parentKey && ue.childrenCount === a.childrenCount && ue.firstInParent === a.firstInParent && ue.lastInParent === a.lastInParent && ue.editing === S && ue.expanded === Q && ue.childrenExpanded === me && ue.loading === Ke && ue.dirty === ut && ue.moved === Ne && ue.unsaved === ft) {
2474
2474
  t.push(ue);
2475
2475
  continue;
@@ -2489,8 +2489,8 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2489
2489
  for (const a of Z.keys())
2490
2490
  l.has(a) || Z.delete(a);
2491
2491
  return t;
2492
- }), T = C(() => h.value.children.length === 0), f = C(() => y.viewItems.value.length), m = Ft("rowsContainer"), D = C(() => !n.readonly && !n.disabled && !n.loading), F = C(
2493
- () => D.value && !n.disableReorder && f.value > 1
2492
+ }), T = C(() => h.value.children.length === 0), f = C(() => y.viewItems.value.length), v = Ft("rowsContainer"), P = C(() => !n.readonly && !n.disabled && !n.loading), $ = C(
2493
+ () => P.value && !n.disableReorder && f.value > 1
2494
2494
  ), O = C(() => !!w.item), U = C(() => !!w["item-readonly"]), le = C(() => !!n.onItemSave), {
2495
2495
  editingKeys: X,
2496
2496
  editingSnapshots: ee,
@@ -2501,10 +2501,12 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2501
2501
  closeEdit: Ee,
2502
2502
  requestAutoOpen: ye
2503
2503
  } = qn({
2504
- rowsContainer: m,
2504
+ rowsContainer: v,
2505
2505
  rowSelector: ".a-le-row-wrapper",
2506
2506
  isInlineEdit: O,
2507
- restoreSnapshot: (t, l) => y.updateItem(t, l),
2507
+ // markDirty=false: restoring the pre-edit snapshot on cancel must not flag
2508
+ // the node dirty (it would otherwise be resent by partial-multi saves).
2509
+ restoreSnapshot: (t, l) => y.updateItem(t, l, !1),
2508
2510
  watchKeys: () => {
2509
2511
  const t = [], l = (a) => {
2510
2512
  for (const S of a)
@@ -2532,13 +2534,13 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2532
2534
  } = uo({
2533
2535
  mode: p,
2534
2536
  snapshot: K,
2535
- movedKeys: P,
2537
+ movedKeys: D,
2536
2538
  modelValue: h,
2537
2539
  cloneModel: (t) => be(t),
2538
2540
  applyModel: (t) => {
2539
2541
  H(), h.value = t;
2540
2542
  },
2541
- canEnterReorder: F,
2543
+ canEnterReorder: $,
2542
2544
  onEnter: () => {
2543
2545
  fe();
2544
2546
  for (const t of Me.value) b.value.add(t);
@@ -2550,10 +2552,10 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2550
2552
  fe();
2551
2553
  },
2552
2554
  onCancel: () => {
2553
- v();
2555
+ m();
2554
2556
  },
2555
2557
  onApplyEnd: () => {
2556
- v();
2558
+ m();
2557
2559
  },
2558
2560
  onReorderApply: (t) => n.onReorderApply?.(t),
2559
2561
  emit: {
@@ -2563,7 +2565,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2563
2565
  reorderApplyError: (t) => u("reorder-apply-error", t),
2564
2566
  reorderEnd: () => u("reorder-end")
2565
2567
  }
2566
- }), lt = C(() => D.value && n.showAddButton && !ke.value), we = C(() => ke.value && !z.value && !n.disableDrag), it = C(
2568
+ }), lt = C(() => P.value && n.showAddButton && !ke.value), we = C(() => ke.value && !z.value && !n.disableDrag), it = C(
2567
2569
  () => n.addLabel ? k(n.addLabel) : k("common.sortable.add")
2568
2570
  ), pt = C(() => n.emptyTitle ?? k("common.sortable.emptyTitle")), et = C(
2569
2571
  () => n.deleteConfirmTitle ?? k("common.sortable.deleteConfirmTitle")
@@ -2588,7 +2590,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2588
2590
  for (const t of Me.value) b.value.add(t);
2589
2591
  }, Rt = C(
2590
2592
  () => !!(n.title || w.header || w["reorder-toggle"] || gt.value || st.value || ke.value)
2591
- ), o = ce([]), N = ce(0), v = () => {
2593
+ ), o = ce([]), N = ce(0), m = () => {
2592
2594
  for (const t of o.value)
2593
2595
  try {
2594
2596
  t.stop();
@@ -2599,19 +2601,19 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2599
2601
  const a = document.elementFromPoint(t, l);
2600
2602
  if (!a) return null;
2601
2603
  const S = a.closest(".a-le-row-wrapper");
2602
- if (!S || !m.value || !m.value.contains(S)) return null;
2604
+ if (!S || !v.value || !v.value.contains(S)) return null;
2603
2605
  const Q = ln(S.getAttribute("data-id"));
2604
2606
  if (Q === null) return null;
2605
2607
  const me = oe.value.find((Ke) => Ke.key === Q);
2606
2608
  return me ? { el: S, viewItem: me } : null;
2607
2609
  }, tt = (t, l) => {
2608
- if (!se.value || !m.value) return;
2610
+ if (!se.value || !v.value) return;
2609
2611
  const a = kt(t, l);
2610
2612
  if (!a) {
2611
2613
  se.value.instruction = null;
2612
2614
  return;
2613
2615
  }
2614
- const S = m.value.getBoundingClientRect(), me = (a.el.querySelector(":scope > .a-le-row") ?? a.el).getBoundingClientRect();
2616
+ const S = v.value.getBoundingClientRect(), me = (a.el.querySelector(":scope > .a-le-row") ?? a.el).getBoundingClientRect();
2615
2617
  se.value.instruction = xl({
2616
2618
  pointer: { x: t, y: l },
2617
2619
  hoveredRow: {
@@ -2639,8 +2641,8 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2639
2641
  }
2640
2642
  J(l), t.makeChild && t.parentKey !== null && b.value.add(t.parentKey);
2641
2643
  }, ze = () => {
2642
- if (v(), !we.value || !m.value) return;
2643
- const t = Array.from(m.value.querySelectorAll("." + kn));
2644
+ if (m(), !we.value || !v.value) return;
2645
+ const t = Array.from(v.value.querySelectorAll("." + kn));
2644
2646
  for (const l of t) {
2645
2647
  const a = vo(l, [], {
2646
2648
  group: { name: "a-nested", pull: !0, put: !0 },
@@ -2692,7 +2694,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2692
2694
  Pe(
2693
2695
  () => we.value,
2694
2696
  () => {
2695
- we.value ? Oe(() => ze()) : v();
2697
+ we.value ? Oe(() => ze()) : m();
2696
2698
  }
2697
2699
  ), Pe(
2698
2700
  () => N.value,
@@ -2707,21 +2709,21 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2707
2709
  ), Zt(() => {
2708
2710
  we.value && ze();
2709
2711
  }), _t(() => {
2710
- v(), document.removeEventListener("pointermove", nt);
2712
+ m(), document.removeEventListener("pointermove", nt);
2711
2713
  });
2712
2714
  const qe = C(() => {
2713
2715
  const t = se.value;
2714
- if (!t || t.instruction === null || !m.value) return null;
2716
+ if (!t || t.instruction === null || !v.value) return null;
2715
2717
  const l = t.instruction;
2716
2718
  if (l.type === "blocked") return null;
2717
- const a = m.value.querySelector(
2719
+ const a = v.value.querySelector(
2718
2720
  `.a-le-row-wrapper[data-id="${CSS.escape(String(l.refKey))}"]`
2719
2721
  );
2720
2722
  if (!a) return null;
2721
- const S = a.querySelector(":scope > .a-le-row"), Q = m.value.getBoundingClientRect(), me = (S ?? a).getBoundingClientRect(), Ke = Cn + l.depth * wn, Ne = l.refEdge === "top" ? me.top - Q.top : me.bottom - Q.top, ut = { top: Ne, left: Ke, right: 16 };
2723
+ const S = a.querySelector(":scope > .a-le-row"), Q = v.value.getBoundingClientRect(), me = (S ?? a).getBoundingClientRect(), Ke = Cn + l.depth * wn, Ne = l.refEdge === "top" ? me.top - Q.top : me.bottom - Q.top, ut = { top: Ne, left: Ke, right: 16 };
2722
2724
  let ft = null;
2723
2725
  if (l.levelRowKey !== null) {
2724
- const ue = m.value.querySelector(
2726
+ const ue = v.value.querySelector(
2725
2727
  `.a-le-row-wrapper[data-id="${CSS.escape(String(l.levelRowKey))}"]`
2726
2728
  );
2727
2729
  if (ue) {
@@ -2737,11 +2739,11 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2737
2739
  }), rt = () => {
2738
2740
  lt.value && (ye(), u("add", void 0));
2739
2741
  }, sn = (t) => {
2740
- D.value && (ye(), u("add", { afterId: t.key, childrenAllowed: t.childrenAllowed }));
2742
+ P.value && (ye(), u("add", { afterId: t.key, childrenAllowed: t.childrenAllowed }));
2741
2743
  }, rn = (t) => {
2742
- D.value && t.canAddChild && (ye(), b.value.add(t.key), u("add-child", t), u("add", { parentId: t.key, childrenAllowed: !0 }));
2744
+ P.value && t.canAddChild && (ye(), b.value.add(t.key), u("add-child", t), u("add", { parentId: t.key, childrenAllowed: !0 }));
2743
2745
  }, wt = (t) => {
2744
- if (!(!D.value || ke.value)) {
2746
+ if (!(!P.value || ke.value)) {
2745
2747
  if (X.value.has(t.key)) {
2746
2748
  dt(t);
2747
2749
  return;
@@ -2779,7 +2781,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2779
2781
  },
2780
2782
  disableDeleteConfirm: () => n.disableDeleteConfirm
2781
2783
  }), un = async (t) => {
2782
- D.value && await ma(t);
2784
+ P.value && await ma(t);
2783
2785
  }, fn = async (t) => {
2784
2786
  n.onItemSave && await n.onItemSave(t.raw), xe(t), u("item-saved", t);
2785
2787
  }, mn = (t) => {
@@ -2907,7 +2909,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2907
2909
  }
2908
2910
  })), yn = C(() => ({
2909
2911
  mode: p.value,
2910
- disabled: !F.value,
2912
+ disabled: !$.value,
2911
2913
  hasPendingChanges: Le.value,
2912
2914
  actions: {
2913
2915
  enterReorderMode: _e,
@@ -2925,7 +2927,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2925
2927
  ),
2926
2928
  variant: "nested",
2927
2929
  isReorderMode: ke,
2928
- disabled: C(() => !D.value),
2930
+ disabled: C(() => !P.value),
2929
2931
  isEditing: (t) => X.value.has(t),
2930
2932
  onToggleEdit: (t) => {
2931
2933
  const l = pe(t);
@@ -2980,7 +2982,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
2980
2982
  }, Sa = C(() => ({
2981
2983
  reorderMode: ke.value,
2982
2984
  readonly: n.readonly,
2983
- canInteract: D.value,
2985
+ canInteract: P.value,
2984
2986
  dragEnabled: we.value,
2985
2987
  showExpandToggle: n.showExpandToggle,
2986
2988
  showEditButton: n.showEditButton,
@@ -3035,10 +3037,10 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3035
3037
  unsavedKeysModel: Fa,
3036
3038
  internalUnsavedKeys: Ba,
3037
3039
  onClearAll: () => {
3038
- Y(), P.value = /* @__PURE__ */ new Set();
3040
+ Y(), D.value = /* @__PURE__ */ new Set();
3039
3041
  },
3040
3042
  onClearKey: (t) => {
3041
- ae(t), P.value.delete(t);
3043
+ ae(t), D.value.delete(t);
3042
3044
  }
3043
3045
  });
3044
3046
  return x({
@@ -3090,7 +3092,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3090
3092
  L("div", ql, [
3091
3093
  Rt.value ? (g(), B("div", Gl, [
3092
3094
  V(t.$slots, "header", ie({ title: e.title }, yn.value), () => [
3093
- e.title ? (g(), B("h3", Wl, $(e.title), 1)) : q("", !0),
3095
+ e.title ? (g(), B("h3", Wl, F(e.title), 1)) : q("", !0),
3094
3096
  L("div", Hl, [
3095
3097
  d(ke) ? V(t.$slots, "reorder-toolbar", Re(ie({ key: 0 }, ga.value)), () => [
3096
3098
  s(fo, {
@@ -3106,7 +3108,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3106
3108
  onClick: d(Je)
3107
3109
  }, {
3108
3110
  default: r(() => [
3109
- j($(d(k)("common.sortable.reorderCancel")), 1)
3111
+ j(F(d(k)("common.sortable.reorderCancel")), 1)
3110
3112
  ]),
3111
3113
  _: 1
3112
3114
  }, 8, ["disabled", "onClick"]),
@@ -3120,7 +3122,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3120
3122
  onClick: d(ot)
3121
3123
  }, {
3122
3124
  default: r(() => [
3123
- j($(d(k)("common.sortable.reorderApply")), 1)
3125
+ j(F(d(k)("common.sortable.reorderApply")), 1)
3124
3126
  ]),
3125
3127
  _: 1
3126
3128
  }, 8, ["loading", "disabled", "onClick"])
@@ -3154,7 +3156,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3154
3156
  onClick: bt
3155
3157
  }, {
3156
3158
  default: r(() => [
3157
- j($(Ye.value ? d(k)("common.sortable.collapseAll") : d(k)("common.sortable.expandAll")), 1)
3159
+ j(F(Ye.value ? d(k)("common.sortable.collapseAll") : d(k)("common.sortable.expandAll")), 1)
3158
3160
  ]),
3159
3161
  _: 1
3160
3162
  }, 8, ["prepend-icon"])) : q("", !0),
@@ -3165,7 +3167,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3165
3167
  color: "primary",
3166
3168
  icon: "",
3167
3169
  size: "x-small",
3168
- disabled: !F.value,
3170
+ disabled: !$.value,
3169
3171
  onClick: d(_e)
3170
3172
  }, {
3171
3173
  default: r(() => [
@@ -3186,11 +3188,11 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3186
3188
  color: "primary",
3187
3189
  "prepend-icon": "mdi-sort",
3188
3190
  size: "small",
3189
- disabled: !F.value,
3191
+ disabled: !$.value,
3190
3192
  onClick: d(_e)
3191
3193
  }, {
3192
3194
  default: r(() => [
3193
- j($(d(k)("common.sortable.reorder")), 1)
3195
+ j(F(d(k)("common.sortable.reorder")), 1)
3194
3196
  ]),
3195
3197
  _: 1
3196
3198
  }, 8, ["disabled", "onClick"]))
@@ -3213,7 +3215,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3213
3215
  border: "start"
3214
3216
  }, {
3215
3217
  default: r(() => [
3216
- j($(e.error), 1)
3218
+ j(F(e.error), 1)
3217
3219
  ]),
3218
3220
  _: 1
3219
3221
  })
@@ -3233,7 +3235,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3233
3235
  ])) : (g(), B("div", {
3234
3236
  key: N.value,
3235
3237
  ref_key: "rowsContainer",
3236
- ref: m,
3238
+ ref: v,
3237
3239
  class: Ce(["a-nested-list-editor__rows", { "a-nested-list-editor__rows--dragging": se.value !== null }])
3238
3240
  }, [
3239
3241
  L("div", {
@@ -3313,7 +3315,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3313
3315
  icon: "mdi-plus",
3314
3316
  size: "18"
3315
3317
  }),
3316
- L("span", null, $(it.value), 1)
3318
+ L("span", null, F(it.value), 1)
3317
3319
  ])
3318
3320
  ]) : q("", !0)
3319
3321
  ]),
@@ -3348,7 +3350,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3348
3350
  onConfirm: d(va),
3349
3351
  onCancel: d(ya)
3350
3352
  }, null, 8, ["modelValue", "title", "text", "confirm-label", "cancel-label", "error", "in-flight", "onConfirm", "onCancel"]),
3351
- L("div", Ql, $(d(Ct).grabbedKey.value !== null ? d(k)("common.sortable.keyboardGrab.status", {
3353
+ L("div", Ql, F(d(Ct).grabbedKey.value !== null ? d(k)("common.sortable.keyboardGrab.status", {
3352
3354
  n: d(Ct).grabbedIndex.value + 1,
3353
3355
  total: d(Ct).totalCount.value
3354
3356
  }) : ""), 1)
@@ -3384,22 +3386,22 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3384
3386
  default: r(() => [
3385
3387
  s(oa, null, {
3386
3388
  default: r(() => [
3387
- j($(e.title ?? d(u)("common.sortable.unsavedChanges.title")), 1)
3389
+ j(F(e.title ?? d(u)("common.sortable.unsavedChanges.title")), 1)
3388
3390
  ]),
3389
3391
  _: 1
3390
3392
  }),
3391
3393
  s(Dt, null, {
3392
3394
  default: r(() => [
3393
3395
  e.body ? (g(), B(ve, { key: 0 }, [
3394
- j($(e.body), 1)
3396
+ j(F(e.body), 1)
3395
3397
  ], 64)) : e.dirtyLabels.length ? (g(), B(ve, { key: 1 }, [
3396
- j($(d(u)("common.sortable.unsavedChanges.sectionsIntro")) + " ", 1),
3398
+ j(F(d(u)("common.sortable.unsavedChanges.sectionsIntro")) + " ", 1),
3397
3399
  L("ul", _l, [
3398
- (g(!0), B(ve, null, Qe(e.dirtyLabels, (i, A) => (g(), B("li", { key: A }, $(i), 1))), 128))
3400
+ (g(!0), B(ve, null, Qe(e.dirtyLabels, (i, A) => (g(), B("li", { key: A }, F(i), 1))), 128))
3399
3401
  ]),
3400
- j(" " + $(d(u)("common.sortable.unsavedChanges.leaveQuestion")), 1)
3402
+ j(" " + F(d(u)("common.sortable.unsavedChanges.leaveQuestion")), 1)
3401
3403
  ], 64)) : (g(), B(ve, { key: 2 }, [
3402
- j($(d(u)("common.sortable.unsavedChanges.body")), 1)
3404
+ j(F(d(u)("common.sortable.unsavedChanges.body")), 1)
3403
3405
  ], 64))
3404
3406
  ]),
3405
3407
  _: 1
@@ -3412,7 +3414,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3412
3414
  onClick: h
3413
3415
  }, {
3414
3416
  default: r(() => [
3415
- j($(e.stayLabel ?? d(u)("common.sortable.unsavedChanges.stay")), 1)
3417
+ j(F(e.stayLabel ?? d(u)("common.sortable.unsavedChanges.stay")), 1)
3416
3418
  ]),
3417
3419
  _: 1
3418
3420
  }),
@@ -3422,7 +3424,7 @@ const Kt = (e, x) => e.find((c) => c.key === x) ?? null, sa = (e, x, c) => {
3422
3424
  onClick: p
3423
3425
  }, {
3424
3426
  default: r(() => [
3425
- j($(e.discardLabel ?? d(u)("common.sortable.unsavedChanges.discard")), 1)
3427
+ j(F(e.discardLabel ?? d(u)("common.sortable.unsavedChanges.discard")), 1)
3426
3428
  ]),
3427
3429
  _: 1
3428
3430
  })