@anzusystems/common-admin 1.47.0-beta.dev-1778753790 → 1.47.0-beta.dev-1778753795
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/{AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-DDq97ou0.mjs → AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CcJ9O4Nl.mjs} +1729 -1691
- package/dist/{AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-DDq97ou0.mjs.map → AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CcJ9O4Nl.mjs.map} +1 -1
- package/dist/common-admin.css +1 -1
- package/dist/common-admin.js +3 -3
- package/dist/common-admin.js.map +1 -1
- package/dist/labs.d.ts +13 -3
- package/dist/labs.js +1530 -1534
- package/dist/labs.js.map +1 -1
- package/dist/{webfontloader-GR-npb3W.mjs → webfontloader-B5y4KLvE.mjs} +2 -2
- package/dist/{webfontloader-GR-npb3W.mjs.map → webfontloader-B5y4KLvE.mjs.map} +1 -1
- package/package.json +3 -3
package/dist/labs.js
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import { bS as
|
|
2
|
-
import { aE as
|
|
3
|
-
import { defineComponent as
|
|
4
|
-
import { useI18n as
|
|
1
|
+
import { bS as Sn, d as pe, j as Ue, k as Ma, a1 as za, h as mt, i as Et, aj as Pn, ak as In, al as Dn, am as En, ag as Tt, aZ as Tn, aa as $n, ab as Fn, ac as Bn, ad as Rn, an as Kn, ao as Vn, ae as Ln, af as Mn, bT as zn, bU as Nn, bd as On, bV as Na, as as Un, bW as Yt, ap as Oa, aq as Ua, aU as ja, b1 as qa, ar as Ga, E as Ha, a8 as Ja, a2 as Wa, bX as Ya, q as Xa, p as Qa, x as Za, a7 as _a, aI as eo, m as jn, bY as to, l as no, bZ as ao, b_ as qn, b$ as Gn, c0 as Hn, c1 as Jn, c2 as Wn, c3 as Yn, c4 as Xn, c5 as Qn, c6 as Zn, c7 as _n, g as ke, c8 as oo, _ as ea, c9 as lo, ca as io, cb as so, cc as ro, aT as co, cd as uo, ce as fo, cf as mo, z as vo } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CcJ9O4Nl.mjs";
|
|
2
|
+
import { aE as Ki, cg as Vi, ch as Li, aA as Mi, aB as zi, aD as Ni, aF as Oi, aC as Ui, aR as ji, aJ as qi, ba as Gi, aW as Hi, aG as Ji, aH as Wi, ay as Yi, az as Xi, ci as Qi, cj as Zi, ck as _i, cl as es, cm as ts, cn as ns, co as as, ai as os, ah as ls, cp as is, cq as ss, cr as rs, cs as ds } from "./AFormRemoteAutocomplete.vue_vue_type_script_setup_true_lang-CcJ9O4Nl.mjs";
|
|
3
|
+
import { defineComponent as He, useModel as Ge, inject as Qt, computed as g, watch as Ee, openBlock as y, createElementBlock as K, createElementVNode as M, toDisplayString as B, unref as d, createVNode as i, withCtx as r, createTextVNode as G, Fragment as ve, renderList as Ze, createBlock as W, normalizeClass as xe, mergeModels as Le, createCommentVNode as H, withModifiers as le, ref as ce, onMounted as Zt, toRaw as gn, provide as ta, resolveComponent as bn, renderSlot as z, mergeProps as ie, withDirectives as yo, vShow as ho, useSlots as na, useTemplateRef as $t, isRef as aa, normalizeStyle as vt, normalizeProps as Ve, guardReactiveProps as qe, shallowRef as Xt, nextTick as Oe, onBeforeUnmount as _t, getCurrentInstance as en, reactive as po } from "vue";
|
|
4
|
+
import { useI18n as Je } from "vue-i18n";
|
|
5
5
|
import { VBtn as _ } from "vuetify/components/VBtn";
|
|
6
|
-
import { VList as
|
|
7
|
-
import { VMenu as
|
|
8
|
-
import { useThrottleFn as
|
|
9
|
-
import { VBtnToggle as
|
|
10
|
-
import
|
|
11
|
-
import { useDisplay as
|
|
12
|
-
import { VCard as
|
|
13
|
-
import { VDialog as
|
|
14
|
-
import { VSpacer as
|
|
15
|
-
import { VIcon as
|
|
16
|
-
import { VToolbar as
|
|
17
|
-
import { VTooltip as
|
|
18
|
-
import { Intersect as
|
|
19
|
-
import { VAlert as
|
|
20
|
-
import { VProgressCircular as
|
|
21
|
-
import { VRadio as
|
|
22
|
-
import { VRadioGroup as
|
|
23
|
-
import { onBeforeRouteLeave as
|
|
24
|
-
const
|
|
6
|
+
import { VList as yt, VListItem as Ie, VListItemTitle as Re } from "vuetify/components/VList";
|
|
7
|
+
import { VMenu as Ft } from "vuetify/components/VMenu";
|
|
8
|
+
import { useThrottleFn as At, useDebounceFn as go } from "@vueuse/core";
|
|
9
|
+
import { VBtnToggle as bo } from "vuetify/components/VBtnToggle";
|
|
10
|
+
import oa from "axios";
|
|
11
|
+
import { useDisplay as tn } from "vuetify";
|
|
12
|
+
import { VCard as nn, VCardTitle as la, VCardText as Dt, VCardActions as ia } from "vuetify/components/VCard";
|
|
13
|
+
import { VDialog as an } from "vuetify/components/VDialog";
|
|
14
|
+
import { VSpacer as on } from "vuetify/components/VGrid";
|
|
15
|
+
import { VIcon as ne } from "vuetify/components/VIcon";
|
|
16
|
+
import { VToolbar as ko } from "vuetify/components/VToolbar";
|
|
17
|
+
import { VTooltip as De } from "vuetify/components/VTooltip";
|
|
18
|
+
import { Intersect as wo } from "vuetify/directives";
|
|
19
|
+
import { VAlert as ln } from "vuetify/components/VAlert";
|
|
20
|
+
import { VProgressCircular as sa } from "vuetify/components/VProgressCircular";
|
|
21
|
+
import { VRadio as kn } from "vuetify/components/VRadio";
|
|
22
|
+
import { VRadioGroup as Co } from "vuetify/components/VRadioGroup";
|
|
23
|
+
import { onBeforeRouteLeave as xo } from "vue-router";
|
|
24
|
+
const Ao = { class: "d-flex align-center justify-center" }, So = { class: "text-body-small mr-1" }, wi = /* @__PURE__ */ He({
|
|
25
25
|
__name: "ADatatableOrdering",
|
|
26
|
-
props: /* @__PURE__ */
|
|
26
|
+
props: /* @__PURE__ */ Le({
|
|
27
27
|
variant: { default: "id" },
|
|
28
28
|
customOptions: { default: void 0 },
|
|
29
29
|
paginationUpdateCustomCb: { type: Function, default: void 0 }
|
|
@@ -34,81 +34,81 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
34
34
|
},
|
|
35
35
|
modelModifiers: {}
|
|
36
36
|
}),
|
|
37
|
-
emits: /* @__PURE__ */
|
|
37
|
+
emits: /* @__PURE__ */ Le(["sortByChange"], ["update:modelValue"]),
|
|
38
38
|
setup(e, { emit: w }) {
|
|
39
|
-
const
|
|
40
|
-
if (pe(
|
|
39
|
+
const u = e, n = w, f = Ge(e, "modelValue"), h = Qt(Sn);
|
|
40
|
+
if (pe(h))
|
|
41
41
|
throw new Error("Incorrect provide/inject config.");
|
|
42
|
-
const { t:
|
|
42
|
+
const { t: p } = Je(), b = [
|
|
43
43
|
{
|
|
44
44
|
id: 1,
|
|
45
45
|
titleT: "common.system.datatable.ordering.mostRecent",
|
|
46
|
-
sortBy: { key: "createdAt", order:
|
|
46
|
+
sortBy: { key: "createdAt", order: Ue.Desc }
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
49
|
id: 2,
|
|
50
50
|
titleT: "common.system.datatable.ordering.oldest",
|
|
51
|
-
sortBy: { key: "createdAt", order:
|
|
51
|
+
sortBy: { key: "createdAt", order: Ue.Asc }
|
|
52
52
|
}
|
|
53
53
|
], k = [
|
|
54
54
|
{
|
|
55
55
|
id: 1,
|
|
56
56
|
titleT: "common.system.datatable.ordering.mostRecent",
|
|
57
|
-
sortBy: { key: "id", order:
|
|
57
|
+
sortBy: { key: "id", order: Ue.Desc }
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
id: 2,
|
|
61
61
|
titleT: "common.system.datatable.ordering.oldest",
|
|
62
|
-
sortBy: { key: "id", order:
|
|
62
|
+
sortBy: { key: "id", order: Ue.Asc }
|
|
63
63
|
}
|
|
64
64
|
], s = [
|
|
65
65
|
{
|
|
66
66
|
id: 3,
|
|
67
67
|
titleT: "common.system.datatable.ordering.mostRelevant",
|
|
68
|
-
sortBy: { key:
|
|
68
|
+
sortBy: { key: Ma, order: Ue.Desc }
|
|
69
69
|
},
|
|
70
70
|
{
|
|
71
71
|
id: 1,
|
|
72
72
|
titleT: "common.system.datatable.ordering.mostRecent",
|
|
73
|
-
sortBy: { key: "createdAt", order:
|
|
73
|
+
sortBy: { key: "createdAt", order: Ue.Desc }
|
|
74
74
|
},
|
|
75
75
|
{
|
|
76
76
|
id: 2,
|
|
77
77
|
titleT: "common.system.datatable.ordering.oldest",
|
|
78
|
-
sortBy: { key: "createdAt", order:
|
|
78
|
+
sortBy: { key: "createdAt", order: Ue.Asc }
|
|
79
79
|
}
|
|
80
80
|
], C = g(() => {
|
|
81
|
-
const I = D.value.find((
|
|
82
|
-
return I ?
|
|
83
|
-
}), D = g(() =>
|
|
84
|
-
|
|
81
|
+
const I = D.value.find((T) => T.id === f.value);
|
|
82
|
+
return I ? p(I.titleT) : "";
|
|
83
|
+
}), D = g(() => u.customOptions ? u.customOptions : u.variant === "most-relevant" ? s : u.variant === "id" ? k : b), N = (I) => {
|
|
84
|
+
f.value = I.id;
|
|
85
85
|
}, V = (I) => {
|
|
86
|
-
I.sortBy || (
|
|
87
|
-
...
|
|
86
|
+
I.sortBy || (h.value = {
|
|
87
|
+
...h.value,
|
|
88
88
|
sortBy: null
|
|
89
|
-
}, n("sortByChange", I)),
|
|
89
|
+
}, n("sortByChange", I)), h.value.sortBy = I.sortBy, n("sortByChange", I);
|
|
90
90
|
};
|
|
91
|
-
return Ee(
|
|
92
|
-
if (I ===
|
|
91
|
+
return Ee(f, (I, T) => {
|
|
92
|
+
if (I === T) return;
|
|
93
93
|
const j = D.value.find((R) => R.id === I);
|
|
94
94
|
if (!pe(j)) {
|
|
95
|
-
if (pe(
|
|
95
|
+
if (pe(u.paginationUpdateCustomCb)) {
|
|
96
96
|
V(j);
|
|
97
97
|
return;
|
|
98
98
|
}
|
|
99
|
-
|
|
99
|
+
u.paginationUpdateCustomCb(j, h);
|
|
100
100
|
}
|
|
101
101
|
}), Ee(
|
|
102
|
-
|
|
103
|
-
(I,
|
|
104
|
-
if (I.sortBy?.key ===
|
|
102
|
+
h,
|
|
103
|
+
(I, T) => {
|
|
104
|
+
if (I.sortBy?.key === T?.sortBy?.key && I.sortBy?.order === T?.sortBy?.order)
|
|
105
105
|
return;
|
|
106
106
|
const j = D.value.find((R) => I.sortBy?.key === R.sortBy?.key && I.sortBy?.order === R.sortBy?.order);
|
|
107
|
-
pe(j) || (
|
|
107
|
+
pe(j) || (f.value = j.id);
|
|
108
108
|
},
|
|
109
109
|
{ immediate: !0 }
|
|
110
|
-
), (I,
|
|
111
|
-
M("div",
|
|
110
|
+
), (I, T) => (y(), K("div", Ao, [
|
|
111
|
+
M("div", So, B(d(p)("common.system.datatable.ordering.title")) + ": ", 1),
|
|
112
112
|
i(_, {
|
|
113
113
|
variant: "text",
|
|
114
114
|
rounded: "xl",
|
|
@@ -117,28 +117,28 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
117
117
|
"append-icon": "mdi-chevron-down"
|
|
118
118
|
}, {
|
|
119
119
|
default: r(() => [
|
|
120
|
-
|
|
121
|
-
i(
|
|
120
|
+
G(B(C.value) + " ", 1),
|
|
121
|
+
i(Ft, {
|
|
122
122
|
activator: "parent",
|
|
123
123
|
location: "bottom",
|
|
124
124
|
"close-on-content-click": ""
|
|
125
125
|
}, {
|
|
126
126
|
default: r(() => [
|
|
127
|
-
i(
|
|
127
|
+
i(yt, {
|
|
128
128
|
density: "compact",
|
|
129
129
|
class: "pa-0"
|
|
130
130
|
}, {
|
|
131
131
|
default: r(() => [
|
|
132
|
-
(
|
|
132
|
+
(y(!0), K(ve, null, Ze(D.value, (j) => (y(), W(Ie, {
|
|
133
133
|
key: j.id,
|
|
134
134
|
onClick: (R) => N(j)
|
|
135
135
|
}, {
|
|
136
136
|
default: r(() => [
|
|
137
|
-
i(
|
|
138
|
-
class:
|
|
137
|
+
i(Re, {
|
|
138
|
+
class: xe({ "font-weight-bold": j.id === f.value })
|
|
139
139
|
}, {
|
|
140
140
|
default: r(() => [
|
|
141
|
-
|
|
141
|
+
G(B(d(p)(j.titleT)), 1)
|
|
142
142
|
]),
|
|
143
143
|
_: 2
|
|
144
144
|
}, 1032, ["class"])
|
|
@@ -156,10 +156,10 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
156
156
|
})
|
|
157
157
|
]));
|
|
158
158
|
}
|
|
159
|
-
}),
|
|
159
|
+
}), Po = { class: "anzu-data-footer" }, Io = {
|
|
160
160
|
key: 0,
|
|
161
161
|
class: "anzu-data-footer__page-limit"
|
|
162
|
-
},
|
|
162
|
+
}, Do = { class: "anzu-data-footer__pagination" }, Eo = { class: "anzu-data-footer__icons-before" }, To = { class: "current-page" }, $o = { class: "anzu-data-footer__icons-after" }, Fo = /* @__PURE__ */ He({
|
|
163
163
|
__name: "ADatatablePagination",
|
|
164
164
|
props: {
|
|
165
165
|
itemsPerPageOptions: { default: () => [10, 25, 50] },
|
|
@@ -167,52 +167,52 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
167
167
|
},
|
|
168
168
|
emits: ["change"],
|
|
169
169
|
setup(e, { emit: w }) {
|
|
170
|
-
const
|
|
170
|
+
const u = w, n = Qt(Sn);
|
|
171
171
|
if (pe(n))
|
|
172
172
|
throw new Error("Incorrect provide/inject config.");
|
|
173
|
-
const { t:
|
|
173
|
+
const { t: f } = Je(), { setStoredPage: h } = za(), p = g(() => Math.ceil(n.value.totalCount / n.value.rowsPerPage)), b = g(() => n.value.page * n.value.rowsPerPage - n.value.rowsPerPage + 1), k = g(() => n.value.page * n.value.rowsPerPage - n.value.rowsPerPage + n.value.currentViewCount), s = g(() => n.value.page === 1), C = g(() => !mt(n.value.hasNextPage) || n.value.page === p.value), D = g(() => mt(n.value.hasNextPage) && n.value.page === p.value || n.value.hasNextPage === !1), N = g(() => mt(n.value.hasNextPage) ? n.value.totalCount : n.value.hasNextPage ? k.value + 1 + "+" : k.value);
|
|
174
174
|
Ee(
|
|
175
175
|
() => n.value.rowsPerPage,
|
|
176
176
|
(R, $) => {
|
|
177
|
-
R !== $ && (n.value.page = 1,
|
|
177
|
+
R !== $ && (n.value.page = 1, u("change"));
|
|
178
178
|
}
|
|
179
179
|
), Ee(
|
|
180
180
|
() => n.value.page,
|
|
181
181
|
(R, $) => {
|
|
182
|
-
R !== $ && (
|
|
182
|
+
R !== $ && (h(R), u("change"));
|
|
183
183
|
}
|
|
184
184
|
);
|
|
185
|
-
const V =
|
|
185
|
+
const V = At(() => {
|
|
186
186
|
n.value.page = 1;
|
|
187
|
-
}, 300), I =
|
|
188
|
-
n.value.page =
|
|
189
|
-
}, 300),
|
|
187
|
+
}, 300), I = At(() => {
|
|
188
|
+
n.value.page = p.value;
|
|
189
|
+
}, 300), T = At(() => {
|
|
190
190
|
n.value.page = n.value.page - 1;
|
|
191
|
-
}, 300), j =
|
|
191
|
+
}, 300), j = At(() => {
|
|
192
192
|
n.value.page = n.value.page + 1;
|
|
193
193
|
}, 300);
|
|
194
|
-
return (R, $) => (
|
|
195
|
-
e.hideRecordsPerPage ?
|
|
196
|
-
|
|
197
|
-
i(
|
|
194
|
+
return (R, $) => (y(), K("div", Po, [
|
|
195
|
+
e.hideRecordsPerPage ? H("", !0) : (y(), K("div", Io, [
|
|
196
|
+
G(B(d(f)("common.system.datatable.itemsPerPage")) + ": ", 1),
|
|
197
|
+
i(bo, {
|
|
198
198
|
modelValue: d(n).rowsPerPage,
|
|
199
|
-
"onUpdate:modelValue": $[0] || ($[0] = (
|
|
199
|
+
"onUpdate:modelValue": $[0] || ($[0] = (Y) => d(n).rowsPerPage = Y),
|
|
200
200
|
class: "ml-2",
|
|
201
201
|
density: "compact",
|
|
202
202
|
mandatory: "",
|
|
203
203
|
"data-cy": "table-size"
|
|
204
204
|
}, {
|
|
205
205
|
default: r(() => [
|
|
206
|
-
(
|
|
207
|
-
key:
|
|
208
|
-
color:
|
|
209
|
-
value:
|
|
206
|
+
(y(!0), K(ve, null, Ze(e.itemsPerPageOptions, (Y) => (y(), W(_, {
|
|
207
|
+
key: Y,
|
|
208
|
+
color: Y === d(n).rowsPerPage ? "secondary" : "",
|
|
209
|
+
value: Y,
|
|
210
210
|
density: "compact",
|
|
211
211
|
size: "small",
|
|
212
212
|
variant: "text"
|
|
213
213
|
}, {
|
|
214
214
|
default: r(() => [
|
|
215
|
-
|
|
215
|
+
G(B(Y), 1)
|
|
216
216
|
]),
|
|
217
217
|
_: 2
|
|
218
218
|
}, 1032, ["color", "value"]))), 128))
|
|
@@ -220,55 +220,55 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
220
220
|
_: 1
|
|
221
221
|
}, 8, ["modelValue"])
|
|
222
222
|
])),
|
|
223
|
-
M("div",
|
|
223
|
+
M("div", Do, B(b.value) + " - " + B(k.value) + " " + B(d(f)("common.system.datatable.from")) + " " + B(N.value), 1),
|
|
224
224
|
M("div", Eo, [
|
|
225
225
|
i(_, {
|
|
226
226
|
disabled: s.value,
|
|
227
227
|
icon: "mdi-page-first",
|
|
228
228
|
size: "small",
|
|
229
229
|
variant: "text",
|
|
230
|
-
onClick:
|
|
230
|
+
onClick: le(d(V), ["stop"])
|
|
231
231
|
}, null, 8, ["disabled", "onClick"]),
|
|
232
232
|
i(_, {
|
|
233
233
|
disabled: s.value,
|
|
234
234
|
icon: "mdi-chevron-left",
|
|
235
235
|
size: "small",
|
|
236
236
|
variant: "text",
|
|
237
|
-
onClick:
|
|
237
|
+
onClick: le(d(T), ["stop"])
|
|
238
238
|
}, null, 8, ["disabled", "onClick"])
|
|
239
239
|
]),
|
|
240
|
-
M("div",
|
|
240
|
+
M("div", To, [
|
|
241
241
|
M("span", null, B(d(n).page), 1)
|
|
242
242
|
]),
|
|
243
|
-
M("div",
|
|
243
|
+
M("div", $o, [
|
|
244
244
|
i(_, {
|
|
245
245
|
disabled: D.value,
|
|
246
246
|
icon: "mdi-chevron-right",
|
|
247
247
|
size: "small",
|
|
248
248
|
variant: "text",
|
|
249
|
-
onClick:
|
|
249
|
+
onClick: le(d(j), ["stop"])
|
|
250
250
|
}, null, 8, ["disabled", "onClick"]),
|
|
251
251
|
i(_, {
|
|
252
252
|
disabled: C.value,
|
|
253
253
|
icon: "mdi-page-last",
|
|
254
254
|
size: "small",
|
|
255
255
|
variant: "text",
|
|
256
|
-
onClick:
|
|
256
|
+
onClick: le(d(I), ["stop"])
|
|
257
257
|
}, null, 8, ["disabled", "onClick"])
|
|
258
258
|
])
|
|
259
259
|
]));
|
|
260
260
|
}
|
|
261
|
-
}),
|
|
262
|
-
const { querySetLimit: n, querySetOffset:
|
|
263
|
-
return n(s),
|
|
264
|
-
},
|
|
261
|
+
}), Bo = (e, w, u = "id") => {
|
|
262
|
+
const { querySetLimit: n, querySetOffset: f, querySetOrder: h, queryBuild: p, queryAddFilter: b, queryAdd: k } = Na(), s = e.length;
|
|
263
|
+
return n(s), f(1, s), h(u, !1), w ? k(u, e.join(",")) : b("in", u, e.join(",")), p();
|
|
264
|
+
}, Ci = (e) => {
|
|
265
265
|
const {
|
|
266
266
|
client: w,
|
|
267
|
-
system:
|
|
267
|
+
system: u,
|
|
268
268
|
entity: n,
|
|
269
|
-
urlTemplate:
|
|
270
|
-
urlParams:
|
|
271
|
-
options:
|
|
269
|
+
urlTemplate: f,
|
|
270
|
+
urlParams: h,
|
|
271
|
+
options: p = {},
|
|
272
272
|
isSearchApi: b = !1,
|
|
273
273
|
field: k = "id",
|
|
274
274
|
silentConsoleError: s = !1
|
|
@@ -277,25 +277,25 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
277
277
|
return {
|
|
278
278
|
executeFetch: async (V, I = {}) => {
|
|
279
279
|
C = new AbortController();
|
|
280
|
-
const { urlTemplate:
|
|
280
|
+
const { urlTemplate: T, urlParams: j } = I;
|
|
281
281
|
try {
|
|
282
|
-
const R = Et(j) ? j :
|
|
282
|
+
const R = Et(j) ? j : h, $ = Et(T) ? T : f;
|
|
283
283
|
if (pe($)) throw new Error("Url template is undefined");
|
|
284
|
-
const
|
|
285
|
-
...
|
|
284
|
+
const Y = (pe(R) ? $ : Pn($, R)) + Bo(V, b, k), A = await w().get(Y, {
|
|
285
|
+
...p,
|
|
286
286
|
signal: C.signal
|
|
287
287
|
});
|
|
288
|
-
if (!
|
|
289
|
-
throw new
|
|
290
|
-
if (
|
|
291
|
-
return
|
|
292
|
-
if (
|
|
288
|
+
if (!In(A.status))
|
|
289
|
+
throw new Dn(A.status);
|
|
290
|
+
if (A.data?.data)
|
|
291
|
+
return A.data.data;
|
|
292
|
+
if (A.status === En)
|
|
293
293
|
return [];
|
|
294
|
-
throw new
|
|
294
|
+
throw new Tt();
|
|
295
295
|
} catch (R) {
|
|
296
296
|
if (R instanceof DOMException && R.name === "AbortError")
|
|
297
297
|
return [];
|
|
298
|
-
throw
|
|
298
|
+
throw Tn(R) ? R : $n(R) ? new Fn(R, R.config?.url) : Bn(R) ? new Rn(R, u, n, R) : Kn(R) ? new Vn(R, u, n, R) : Ln(R) ? new Mn(R, R) : zn(R) ? new Nn(R) : oa.isAxiosError(R) ? (s || console.error("Axios error: " + f, ...R.cause ? [R.cause] : []), new On(R)) : (s || console.error("AnzuFatalError: ", R), new Tt(R));
|
|
299
299
|
} finally {
|
|
300
300
|
C = null;
|
|
301
301
|
}
|
|
@@ -304,14 +304,14 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
304
304
|
C && C.abort();
|
|
305
305
|
}
|
|
306
306
|
};
|
|
307
|
-
},
|
|
307
|
+
}, xi = (e) => {
|
|
308
308
|
const {
|
|
309
309
|
client: w,
|
|
310
|
-
system:
|
|
310
|
+
system: u,
|
|
311
311
|
entity: n,
|
|
312
|
-
urlTemplate:
|
|
313
|
-
urlParams:
|
|
314
|
-
options:
|
|
312
|
+
urlTemplate: f,
|
|
313
|
+
urlParams: h,
|
|
314
|
+
options: p = {},
|
|
315
315
|
silentConsoleError: b = !1
|
|
316
316
|
} = e;
|
|
317
317
|
let k = null;
|
|
@@ -320,66 +320,66 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
320
320
|
k = new AbortController();
|
|
321
321
|
const {
|
|
322
322
|
urlTemplate: I,
|
|
323
|
-
urlParams:
|
|
323
|
+
urlParams: T,
|
|
324
324
|
sortBy: j = "id",
|
|
325
325
|
sortDesc: R = !0,
|
|
326
326
|
batchSize: $ = 100,
|
|
327
|
-
forceElastic:
|
|
327
|
+
forceElastic: Y = !1
|
|
328
328
|
} = V;
|
|
329
329
|
try {
|
|
330
|
-
const
|
|
330
|
+
const A = N.general.elastic || Y ? "/search" : "", J = Et(T) ? T : h, L = Et(I) ? I : f;
|
|
331
331
|
if (pe(L)) throw new Error("Url template is undefined");
|
|
332
|
-
const { pagination:
|
|
332
|
+
const { pagination: E } = Un(j, R ? Ue.Desc : Ue.Asc, {
|
|
333
333
|
rowsPerPage: $
|
|
334
|
-
}), ee = (pe(J) ? L :
|
|
335
|
-
ee +
|
|
334
|
+
}), ee = (pe(J) ? L : Pn(L, J)) + A, se = [], X = await w().get(
|
|
335
|
+
ee + Yt(E, D, N),
|
|
336
336
|
{
|
|
337
|
-
...
|
|
337
|
+
...p,
|
|
338
338
|
signal: k.signal
|
|
339
339
|
}
|
|
340
340
|
);
|
|
341
|
-
if (!
|
|
342
|
-
throw new
|
|
343
|
-
if (
|
|
344
|
-
const
|
|
345
|
-
if (
|
|
346
|
-
for (
|
|
347
|
-
|
|
341
|
+
if (!In(X.status))
|
|
342
|
+
throw new Dn(X.status);
|
|
343
|
+
if (X.data) {
|
|
344
|
+
const ae = X.data;
|
|
345
|
+
if (se.push(...ae.data), Oa(ae))
|
|
346
|
+
for (E.value.hasNextPage = ae.hasNextPage; E.value.hasNextPage; ) {
|
|
347
|
+
E.value.page++;
|
|
348
348
|
const P = (await w().get(
|
|
349
|
-
ee +
|
|
349
|
+
ee + Yt(E, D, N),
|
|
350
350
|
{
|
|
351
|
-
...
|
|
351
|
+
...p,
|
|
352
352
|
signal: k.signal
|
|
353
353
|
}
|
|
354
354
|
)).data;
|
|
355
|
-
|
|
355
|
+
se.push(...P.data), E.value.hasNextPage = P.hasNextPage;
|
|
356
356
|
}
|
|
357
|
-
else if (
|
|
358
|
-
if (
|
|
359
|
-
return
|
|
360
|
-
const
|
|
357
|
+
else if (Ua(ae)) {
|
|
358
|
+
if (E.value.totalCount = ae.totalCount, E.value.totalCount <= E.value.rowsPerPage)
|
|
359
|
+
return se;
|
|
360
|
+
const re = [], P = Math.ceil(E.value.totalCount / E.value.rowsPerPage);
|
|
361
361
|
for (let v = 1; v < P; v++) {
|
|
362
|
-
const
|
|
363
|
-
|
|
364
|
-
w().get(ee +
|
|
365
|
-
...
|
|
362
|
+
const S = { ...E.value, page: v + 1 }, F = ce(S);
|
|
363
|
+
re.push(
|
|
364
|
+
w().get(ee + Yt(F, D, N), {
|
|
365
|
+
...p,
|
|
366
366
|
signal: k.signal
|
|
367
367
|
})
|
|
368
368
|
);
|
|
369
369
|
}
|
|
370
|
-
(await Promise.all(
|
|
371
|
-
|
|
370
|
+
(await Promise.all(re)).forEach((v) => {
|
|
371
|
+
se.push(...v.data.data);
|
|
372
372
|
});
|
|
373
373
|
}
|
|
374
|
-
return
|
|
374
|
+
return se;
|
|
375
375
|
}
|
|
376
|
-
if (
|
|
376
|
+
if (X.status === En)
|
|
377
377
|
return [];
|
|
378
|
-
throw new
|
|
379
|
-
} catch (
|
|
380
|
-
if (
|
|
378
|
+
throw new Tt();
|
|
379
|
+
} catch (A) {
|
|
380
|
+
if (A instanceof DOMException && A.name === "AbortError")
|
|
381
381
|
return [];
|
|
382
|
-
throw
|
|
382
|
+
throw Tn(A) ? A : $n(A) ? new Fn(A, A.config?.url) : Bn(A) ? new Rn(A, u, n, A) : Kn(A) ? new Vn(A, u, n, A) : Ln(A) ? new Mn(A, A) : zn(A) ? new Nn(A) : oa.isAxiosError(A) ? (b || console.error("Axios error: " + f, ...A.cause ? [A.cause] : []), new On(A)) : (b || console.error("AnzuFatalError: ", A), new Tt(A));
|
|
383
383
|
} finally {
|
|
384
384
|
k = null;
|
|
385
385
|
}
|
|
@@ -388,51 +388,51 @@ const So = { class: "d-flex align-center justify-center" }, Po = { class: "text-
|
|
|
388
388
|
k && k.abort();
|
|
389
389
|
}
|
|
390
390
|
};
|
|
391
|
-
},
|
|
392
|
-
function
|
|
391
|
+
}, St = "/adm/v1/job", Pt = "job";
|
|
392
|
+
function Ai(e, w) {
|
|
393
393
|
return {
|
|
394
|
-
useFetchJobList: () =>
|
|
395
|
-
fetchJob: (
|
|
396
|
-
createJob: (
|
|
397
|
-
const b =
|
|
398
|
-
return
|
|
394
|
+
useFetchJobList: () => Ja({ client: e, system: w, entity: Pt, urlTemplate: St }),
|
|
395
|
+
fetchJob: (p) => Ha(e, St + "/:id", { id: p }, w, Pt),
|
|
396
|
+
createJob: (p) => {
|
|
397
|
+
const b = qa(p._resourceName).slice(4).replace("-kind-", "-kind/");
|
|
398
|
+
return Ga(e, p, St + "/:type", { type: b }, w, Pt);
|
|
399
399
|
},
|
|
400
|
-
deleteJob: (
|
|
400
|
+
deleteJob: (p) => ja(e, St + "/:id", { id: p }, w, Pt)
|
|
401
401
|
};
|
|
402
402
|
}
|
|
403
|
-
const
|
|
403
|
+
const Ro = {
|
|
404
404
|
key: "",
|
|
405
405
|
title: void 0,
|
|
406
406
|
sortable: !1,
|
|
407
407
|
fixed: !1
|
|
408
|
-
},
|
|
408
|
+
}, Ko = {
|
|
409
409
|
storeColumnsLocalStorage: !0,
|
|
410
410
|
disableActions: !1,
|
|
411
411
|
customI18n: void 0,
|
|
412
412
|
showExpand: !1
|
|
413
413
|
};
|
|
414
|
-
function
|
|
415
|
-
const
|
|
414
|
+
function Vo(e, w, u, n, f = {}) {
|
|
415
|
+
const h = { ...Ko, ...f }, p = h.customI18n ?? Wa, { t: b } = p.global || p;
|
|
416
416
|
let k;
|
|
417
|
-
|
|
417
|
+
Za(h.storeColumnsLocalStorage) ? k = h.storeColumnsLocalStorage : _a(h.storeColumnsLocalStorage) && h.storeColumnsLocalStorage === !0 && (k = "table_" + u + "_" + n);
|
|
418
418
|
const s = e.map((V) => {
|
|
419
|
-
const I = { ...
|
|
420
|
-
return pe(I.title) && (pe(I.title) &&
|
|
419
|
+
const I = { ...Ro, ...V };
|
|
420
|
+
return pe(I.title) && (pe(I.title) && Ya.includes(I.key) ? I.title = b("common.model.tracking." + I.key) : pe(I.title) && u && n ? I.title = b(u + "." + n + ".model." + I.key) : I.title = ""), I;
|
|
421
421
|
}), C = g(() => {
|
|
422
422
|
const V = [];
|
|
423
|
-
return
|
|
423
|
+
return h.showExpand && V.push({ key: "data-table-expand", sortable: !1 }), s.forEach((I) => {
|
|
424
424
|
w.value.includes(I.key) || V.push(I);
|
|
425
|
-
}),
|
|
425
|
+
}), h.disableActions || V.push({ key: "actions", sortable: !1, fixed: "end" }), V;
|
|
426
426
|
}), D = () => {
|
|
427
427
|
if (!k || !localStorage) return;
|
|
428
428
|
const V = localStorage.getItem(k);
|
|
429
429
|
if (!V) return;
|
|
430
430
|
const I = JSON.parse(V);
|
|
431
|
-
|
|
431
|
+
Xa(I) && Qa(I.hidden) && (w.value = I.hidden);
|
|
432
432
|
}, N = (V) => {
|
|
433
433
|
!k || !localStorage || localStorage.setItem(k, JSON.stringify({ hidden: V }));
|
|
434
434
|
};
|
|
435
|
-
return
|
|
435
|
+
return Zt(() => {
|
|
436
436
|
D();
|
|
437
437
|
}), Ee(w, (V) => {
|
|
438
438
|
N(V);
|
|
@@ -442,84 +442,84 @@ function Lo(e, w, c, n, u = {}) {
|
|
|
442
442
|
columnsHidden: w
|
|
443
443
|
};
|
|
444
444
|
}
|
|
445
|
-
function
|
|
446
|
-
const C =
|
|
447
|
-
|
|
445
|
+
function Si(e, w, u, n, f, h, p, b = null, k = void 0, s = !1) {
|
|
446
|
+
const C = ce(!1), D = ce([]), N = ce([]), V = ce(!1), { pagination: I, setSortBy: T, incrementPage: j } = Un(
|
|
447
|
+
mt(b) ? null : b.key,
|
|
448
448
|
b?.order
|
|
449
|
-
), { resetFilter: R, submitFilter: $ } =
|
|
449
|
+
), { resetFilter: R, submitFilter: $ } = eo(h, p, {
|
|
450
450
|
storeFiltersLocalStorage: !1,
|
|
451
451
|
populateUrlParams: !1
|
|
452
|
-
}), { showErrorsDefault:
|
|
452
|
+
}), { showErrorsDefault: Y } = jn(), { columnsVisible: A, columnsAll: J, columnsHidden: L } = Vo(
|
|
453
453
|
e,
|
|
454
454
|
w,
|
|
455
|
-
|
|
455
|
+
u,
|
|
456
456
|
n,
|
|
457
457
|
{ storeColumnsLocalStorage: !1, disableActions: !s }
|
|
458
|
-
),
|
|
459
|
-
|
|
460
|
-
}, ee = (
|
|
461
|
-
|
|
462
|
-
},
|
|
458
|
+
), E = () => {
|
|
459
|
+
X(), re();
|
|
460
|
+
}, ee = (c) => {
|
|
461
|
+
T(c.sortBy), re();
|
|
462
|
+
}, se = async () => {
|
|
463
463
|
V.value = !0, j();
|
|
464
464
|
try {
|
|
465
|
-
const
|
|
466
|
-
D.value.push(...
|
|
467
|
-
} catch (
|
|
468
|
-
|
|
465
|
+
const c = await f(I, h, p, k);
|
|
466
|
+
D.value.push(...c);
|
|
467
|
+
} catch (c) {
|
|
468
|
+
Y(c);
|
|
469
469
|
} finally {
|
|
470
470
|
V.value = !1;
|
|
471
471
|
}
|
|
472
|
-
},
|
|
472
|
+
}, X = () => {
|
|
473
473
|
D.value = [], N.value = [];
|
|
474
|
-
},
|
|
474
|
+
}, ae = async () => {
|
|
475
475
|
V.value = !0;
|
|
476
476
|
try {
|
|
477
|
-
D.value = await
|
|
477
|
+
D.value = await f(
|
|
478
478
|
I,
|
|
479
|
+
h,
|
|
479
480
|
p,
|
|
480
|
-
y,
|
|
481
481
|
k
|
|
482
482
|
);
|
|
483
|
-
} catch (
|
|
484
|
-
|
|
483
|
+
} catch (c) {
|
|
484
|
+
Y(c);
|
|
485
485
|
} finally {
|
|
486
486
|
V.value = !1;
|
|
487
487
|
}
|
|
488
|
-
},
|
|
489
|
-
await
|
|
488
|
+
}, re = go(async () => {
|
|
489
|
+
await ae();
|
|
490
490
|
});
|
|
491
491
|
return {
|
|
492
492
|
items: D,
|
|
493
493
|
selected: N,
|
|
494
494
|
pagination: I,
|
|
495
|
-
columnsVisible:
|
|
495
|
+
columnsVisible: A,
|
|
496
496
|
columnsHidden: L,
|
|
497
497
|
columnsAll: J,
|
|
498
498
|
filterTouched: C,
|
|
499
499
|
loading: V,
|
|
500
|
-
onRowClick: (
|
|
501
|
-
const v =
|
|
500
|
+
onRowClick: (c) => {
|
|
501
|
+
const v = c.target;
|
|
502
502
|
if (!v || v.tagName === "INPUT" && v.type === "checkbox")
|
|
503
503
|
return;
|
|
504
|
-
const
|
|
505
|
-
if (!
|
|
506
|
-
const F =
|
|
504
|
+
const S = v.closest(".v-data-table__tr");
|
|
505
|
+
if (!S || !S.classList.contains("v-data-table__tr")) return;
|
|
506
|
+
const F = S.firstElementChild;
|
|
507
507
|
if (!F || !F.classList.contains("v-data-table__td")) return;
|
|
508
|
-
const
|
|
509
|
-
|
|
508
|
+
const O = F.querySelector("input");
|
|
509
|
+
O && O.click();
|
|
510
510
|
},
|
|
511
|
-
onFetchNextPage:
|
|
512
|
-
onOpen:
|
|
511
|
+
onFetchNextPage: se,
|
|
512
|
+
onOpen: E,
|
|
513
513
|
sortByChange: ee,
|
|
514
|
-
getList:
|
|
515
|
-
resetFilter: () => R(I,
|
|
516
|
-
submitFilter: () => $(I,
|
|
514
|
+
getList: re,
|
|
515
|
+
resetFilter: () => R(I, re),
|
|
516
|
+
submitFilter: () => $(I, re)
|
|
517
517
|
};
|
|
518
518
|
}
|
|
519
|
-
const
|
|
519
|
+
const Lo = { class: "d-flex flex-column w-100 px-1 align-center" }, Mo = { class: "d-flex justify-space-between w-100 align-center" }, zo = { class: "d-flex align-center" }, No = { class: "d-flex align-center" }, Oo = { class: "subject-select__sidebar system-border-r" }, Uo = { class: "subject-select-filter" }, jo = { class: "subject-select__content" }, qo = {
|
|
520
520
|
key: 0,
|
|
521
521
|
class: "d-flex w-100 align-center justify-center pa-4"
|
|
522
|
-
},
|
|
522
|
+
}, Go = { class: "subject-select__actions system-border-t" }, Ho = { key: 0 }, Jo = { key: 1 }, Pi = /* @__PURE__ */ He({
|
|
523
523
|
__name: "ASubjectSelect",
|
|
524
524
|
props: {
|
|
525
525
|
selectedItems: {},
|
|
@@ -533,76 +533,76 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
533
533
|
autoOpen: { type: Boolean, default: !1 }
|
|
534
534
|
},
|
|
535
535
|
emits: ["update:modelValue", "update:pagination", "onOpen", "onPageChange", "onConfirm", "onFetchNextPage"],
|
|
536
|
-
setup(e, { expose: w, emit:
|
|
537
|
-
const n = e,
|
|
536
|
+
setup(e, { expose: w, emit: u }) {
|
|
537
|
+
const n = e, f = u, h = ce(!1), p = g({
|
|
538
538
|
get() {
|
|
539
|
-
return pe(n.modelValue) ?
|
|
539
|
+
return pe(n.modelValue) ? h.value : n.modelValue;
|
|
540
540
|
},
|
|
541
|
-
set(
|
|
542
|
-
|
|
541
|
+
set(E) {
|
|
542
|
+
h.value = E, f("update:modelValue", E);
|
|
543
543
|
}
|
|
544
544
|
}), b = g({
|
|
545
545
|
get: () => n.pagination,
|
|
546
|
-
set: (
|
|
547
|
-
|
|
546
|
+
set: (E) => {
|
|
547
|
+
f("update:pagination", { ...gn(E) });
|
|
548
548
|
}
|
|
549
|
-
}), { mdAndDown: k } =
|
|
549
|
+
}), { mdAndDown: k } = tn(), s = ce(!k.value), C = () => {
|
|
550
550
|
k.value && (s.value = !1);
|
|
551
551
|
};
|
|
552
|
-
|
|
553
|
-
const { t: D } =
|
|
554
|
-
|
|
555
|
-
},
|
|
552
|
+
ta(to, C);
|
|
553
|
+
const { t: D } = Je(), N = g(() => n.selectedItems.length), V = g(() => N.value < n.minCount || N.value > n.maxCount), I = () => {
|
|
554
|
+
f("onOpen"), s.value = !k.value, p.value = !0;
|
|
555
|
+
}, T = () => {
|
|
556
556
|
s.value = !s.value;
|
|
557
557
|
}, j = () => {
|
|
558
|
-
|
|
558
|
+
p.value = !1;
|
|
559
559
|
}, R = () => {
|
|
560
|
-
|
|
560
|
+
f(
|
|
561
561
|
"onConfirm",
|
|
562
|
-
n.selectedItems.map((
|
|
562
|
+
n.selectedItems.map((E) => gn(E))
|
|
563
563
|
), j();
|
|
564
564
|
}, $ = () => {
|
|
565
|
-
|
|
566
|
-
},
|
|
567
|
-
|
|
568
|
-
},
|
|
569
|
-
|
|
565
|
+
f("onFetchNextPage");
|
|
566
|
+
}, Y = () => {
|
|
567
|
+
f("onPageChange");
|
|
568
|
+
}, A = g(() => Math.ceil(b.value.totalCount / b.value.rowsPerPage)), J = g(() => !(mt(b.value.hasNextPage) && b.value.page === A.value || b.value.hasNextPage === !1)), L = (E) => {
|
|
569
|
+
E && J.value && !n.loading && $();
|
|
570
570
|
};
|
|
571
|
-
return
|
|
571
|
+
return Zt(() => {
|
|
572
572
|
n.autoOpen && I();
|
|
573
573
|
}), w({
|
|
574
574
|
open: I,
|
|
575
575
|
closeSidebarOnMobile: C
|
|
576
|
-
}), (
|
|
577
|
-
const
|
|
578
|
-
return
|
|
579
|
-
z(
|
|
580
|
-
props: { onClick:
|
|
576
|
+
}), (E, ee) => {
|
|
577
|
+
const se = bn("ABtnSecondary"), X = bn("ABtnPrimary");
|
|
578
|
+
return y(), K(ve, null, [
|
|
579
|
+
z(E.$slots, "activator", {
|
|
580
|
+
props: { onClick: le(() => I(), ["stop"]) }
|
|
581
581
|
}),
|
|
582
|
-
i(
|
|
583
|
-
"model-value":
|
|
582
|
+
i(an, ie(E.$attrs, {
|
|
583
|
+
"model-value": p.value,
|
|
584
584
|
fullscreen: "",
|
|
585
585
|
class: "subject-select",
|
|
586
|
-
"onUpdate:modelValue": ee[1] || (ee[1] = (
|
|
586
|
+
"onUpdate:modelValue": ee[1] || (ee[1] = (ae) => f("update:modelValue", ae))
|
|
587
587
|
}), {
|
|
588
588
|
default: r(() => [
|
|
589
|
-
|
|
589
|
+
p.value ? (y(), W(nn, {
|
|
590
590
|
key: 0,
|
|
591
591
|
class: "subject-select__card"
|
|
592
592
|
}, {
|
|
593
593
|
default: r(() => [
|
|
594
|
-
i(
|
|
594
|
+
i(no, {
|
|
595
595
|
class: "subject-select__toolbar system-border-b",
|
|
596
596
|
onOnCancel: j
|
|
597
597
|
}, {
|
|
598
598
|
default: r(() => [
|
|
599
|
-
z(
|
|
600
|
-
|
|
599
|
+
z(E.$slots, "title", {}, () => [
|
|
600
|
+
G(B(d(D)(e.dialogTitleT)), 1)
|
|
601
601
|
])
|
|
602
602
|
]),
|
|
603
603
|
_: 3
|
|
604
604
|
}),
|
|
605
|
-
i(
|
|
605
|
+
i(ko, {
|
|
606
606
|
density: "compact",
|
|
607
607
|
color: "transparent",
|
|
608
608
|
height: 46,
|
|
@@ -610,37 +610,37 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
610
610
|
class: "system-border-b subject-select__second-bar"
|
|
611
611
|
}, {
|
|
612
612
|
default: r(() => [
|
|
613
|
-
z(
|
|
614
|
-
M("div",
|
|
615
|
-
M("div",
|
|
616
|
-
M("div",
|
|
613
|
+
z(E.$slots, "second-bar", {}, () => [
|
|
614
|
+
M("div", Lo, [
|
|
615
|
+
M("div", Mo, [
|
|
616
|
+
M("div", zo, [
|
|
617
617
|
i(_, {
|
|
618
618
|
icon: "",
|
|
619
619
|
width: 30,
|
|
620
620
|
height: 30,
|
|
621
|
-
onClick:
|
|
621
|
+
onClick: T
|
|
622
622
|
}, {
|
|
623
623
|
default: r(() => [
|
|
624
|
-
i(
|
|
624
|
+
i(ne, {
|
|
625
625
|
icon: "mdi-tune",
|
|
626
626
|
size: 16
|
|
627
627
|
}),
|
|
628
|
-
i(
|
|
628
|
+
i(De, {
|
|
629
629
|
activator: "parent",
|
|
630
630
|
location: "bottom"
|
|
631
631
|
}, {
|
|
632
632
|
default: r(() => [
|
|
633
|
-
|
|
633
|
+
G(B(d(D)("common.subjectSelect.filter.toggle")), 1)
|
|
634
634
|
]),
|
|
635
635
|
_: 1
|
|
636
636
|
})
|
|
637
637
|
]),
|
|
638
638
|
_: 1
|
|
639
639
|
}),
|
|
640
|
-
z(
|
|
640
|
+
z(E.$slots, "second-bar-left")
|
|
641
641
|
]),
|
|
642
|
-
M("div",
|
|
643
|
-
z(
|
|
642
|
+
M("div", No, [
|
|
643
|
+
z(E.$slots, "second-bar-right")
|
|
644
644
|
])
|
|
645
645
|
])
|
|
646
646
|
])
|
|
@@ -649,61 +649,61 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
649
649
|
_: 3
|
|
650
650
|
}),
|
|
651
651
|
M("div", {
|
|
652
|
-
class:
|
|
652
|
+
class: xe(["subject-select__main", { "subject-select__main--sidebar-active": s.value }])
|
|
653
653
|
}, [
|
|
654
|
-
M("div",
|
|
655
|
-
M("div",
|
|
656
|
-
z(
|
|
654
|
+
M("div", Oo, [
|
|
655
|
+
M("div", Uo, [
|
|
656
|
+
z(E.$slots, "filter")
|
|
657
657
|
])
|
|
658
658
|
]),
|
|
659
|
-
M("div",
|
|
660
|
-
z(
|
|
661
|
-
e.paginationMode === "more" ? (
|
|
662
|
-
|
|
659
|
+
M("div", jo, [
|
|
660
|
+
z(E.$slots, "content"),
|
|
661
|
+
e.paginationMode === "more" ? (y(), K("div", qo, [
|
|
662
|
+
yo((y(), W(se, {
|
|
663
663
|
loading: e.loading,
|
|
664
664
|
size: "small",
|
|
665
665
|
onClick: $
|
|
666
666
|
}, {
|
|
667
667
|
default: r(() => [
|
|
668
|
-
z(
|
|
669
|
-
|
|
668
|
+
z(E.$slots, "button-confirm-title", {}, () => [
|
|
669
|
+
G(B(d(D)("common.button.loadMore")), 1)
|
|
670
670
|
])
|
|
671
671
|
]),
|
|
672
672
|
_: 3
|
|
673
673
|
}, 8, ["loading"])), [
|
|
674
|
-
[
|
|
674
|
+
[ho, J.value || e.loading],
|
|
675
675
|
[
|
|
676
|
-
|
|
676
|
+
wo,
|
|
677
677
|
L,
|
|
678
678
|
void 0,
|
|
679
679
|
{ quiet: !0 }
|
|
680
680
|
]
|
|
681
681
|
])
|
|
682
|
-
])) : (
|
|
682
|
+
])) : (y(), W(Fo, {
|
|
683
683
|
key: 1,
|
|
684
684
|
modelValue: b.value,
|
|
685
|
-
"onUpdate:modelValue": ee[0] || (ee[0] = (
|
|
686
|
-
onChange:
|
|
685
|
+
"onUpdate:modelValue": ee[0] || (ee[0] = (ae) => b.value = ae),
|
|
686
|
+
onChange: Y
|
|
687
687
|
}, null, 8, ["modelValue"]))
|
|
688
688
|
])
|
|
689
689
|
], 2),
|
|
690
|
-
M("div",
|
|
691
|
-
e.minCount === e.maxCount ? (
|
|
690
|
+
M("div", Go, [
|
|
691
|
+
e.minCount === e.maxCount ? (y(), K("div", Ho, B(d(D)("common.subjectSelect.texts.pickExactCount", {
|
|
692
692
|
count: e.minCount,
|
|
693
693
|
selected: N.value
|
|
694
|
-
})), 1)) : (
|
|
694
|
+
})), 1)) : (y(), K("div", Jo, B(d(D)("common.subjectSelect.texts.pickRangeCount", {
|
|
695
695
|
minCount: e.minCount,
|
|
696
696
|
maxCount: e.maxCount,
|
|
697
697
|
selected: N.value
|
|
698
698
|
})), 1)),
|
|
699
|
-
i(
|
|
700
|
-
i(
|
|
699
|
+
i(on),
|
|
700
|
+
i(X, {
|
|
701
701
|
disabled: V.value,
|
|
702
|
-
onClick:
|
|
702
|
+
onClick: le(R, ["stop"])
|
|
703
703
|
}, {
|
|
704
704
|
default: r(() => [
|
|
705
|
-
z(
|
|
706
|
-
|
|
705
|
+
z(E.$slots, "button-confirm-title", {}, () => [
|
|
706
|
+
G(B(d(D)("common.button.confirm")), 1)
|
|
707
707
|
])
|
|
708
708
|
]),
|
|
709
709
|
_: 3
|
|
@@ -711,47 +711,47 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
711
711
|
])
|
|
712
712
|
]),
|
|
713
713
|
_: 3
|
|
714
|
-
})) :
|
|
714
|
+
})) : H("", !0)
|
|
715
715
|
]),
|
|
716
716
|
_: 3
|
|
717
717
|
}, 16, ["model-value"])
|
|
718
718
|
], 64);
|
|
719
719
|
};
|
|
720
720
|
}
|
|
721
|
-
}),
|
|
721
|
+
}), Wo = {
|
|
722
722
|
key: 0,
|
|
723
723
|
class: "a-le-header"
|
|
724
|
-
},
|
|
724
|
+
}, Yo = {
|
|
725
725
|
key: 0,
|
|
726
726
|
class: "a-le-title-heading"
|
|
727
|
-
},
|
|
727
|
+
}, Xo = {
|
|
728
728
|
key: 1,
|
|
729
729
|
class: "a-le-state a-le-state--loading"
|
|
730
|
-
},
|
|
730
|
+
}, Qo = {
|
|
731
731
|
key: 2,
|
|
732
732
|
class: "a-le-state a-le-state--error"
|
|
733
|
-
},
|
|
733
|
+
}, Zo = {
|
|
734
734
|
key: 3,
|
|
735
735
|
class: "a-le-state a-le-state--empty"
|
|
736
|
-
},
|
|
736
|
+
}, _o = ["data-id", "tabindex", "onKeydown"], el = ["onClick"], tl = { class: "a-le-row-main" }, nl = { class: "a-le-title" }, al = {
|
|
737
737
|
key: 0,
|
|
738
738
|
class: "a-le-status"
|
|
739
|
-
},
|
|
739
|
+
}, ol = {
|
|
740
740
|
key: 0,
|
|
741
741
|
class: "a-le-status-badge"
|
|
742
|
-
},
|
|
742
|
+
}, ll = { class: "a-le-actions" }, il = { class: "a-le-row-body" }, sl = { class: "a-le-form" }, rl = {
|
|
743
743
|
key: 0,
|
|
744
744
|
class: "a-le-row-footer"
|
|
745
|
-
},
|
|
745
|
+
}, dl = {
|
|
746
746
|
key: 1,
|
|
747
747
|
class: "a-le-row-body"
|
|
748
|
-
},
|
|
748
|
+
}, cl = { class: "a-le-form" }, ul = {
|
|
749
749
|
class: "a-le-sr-only",
|
|
750
750
|
"aria-live": "polite",
|
|
751
751
|
role: "status"
|
|
752
|
-
},
|
|
752
|
+
}, Ii = /* @__PURE__ */ He({
|
|
753
753
|
__name: "AListEditor",
|
|
754
|
-
props: /* @__PURE__ */
|
|
754
|
+
props: /* @__PURE__ */ Le({
|
|
755
755
|
keyField: { default: "id" },
|
|
756
756
|
positionField: { default: "position" },
|
|
757
757
|
positionMultiplier: { default: 1 },
|
|
@@ -771,12 +771,13 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
771
771
|
showAddAfterAction: { type: Boolean, default: !1 },
|
|
772
772
|
addLabel: { default: null },
|
|
773
773
|
emptyTitle: { default: null },
|
|
774
|
-
emptyText: { default: null },
|
|
775
774
|
disableRowClick: { type: Boolean, default: !1 },
|
|
776
775
|
disableDeleteConfirm: { type: Boolean, default: !1 },
|
|
776
|
+
disableUnsaved: { type: Boolean, default: !1 },
|
|
777
777
|
deleteConfirmTitle: { default: null },
|
|
778
778
|
deleteConfirmText: { default: null },
|
|
779
779
|
closeVariant: { default: "auto" },
|
|
780
|
+
defaultExpanded: { type: Boolean, default: !1 },
|
|
780
781
|
loadingKeys: { default: null },
|
|
781
782
|
getValidationState: { type: Function, default: void 0 },
|
|
782
783
|
onDeleteConfirm: { type: Function, default: void 0 },
|
|
@@ -790,209 +791,206 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
790
791
|
},
|
|
791
792
|
unsavedKeysModifiers: {}
|
|
792
793
|
}),
|
|
793
|
-
emits: /* @__PURE__ */
|
|
794
|
-
setup(e, { expose: w, emit:
|
|
795
|
-
const n = e,
|
|
794
|
+
emits: /* @__PURE__ */ Le(["add", "edit", "deleted", "close", "item-saved", "item-expand"], ["update:modelValue", "update:unsavedKeys"]),
|
|
795
|
+
setup(e, { expose: w, emit: u }) {
|
|
796
|
+
const n = e, f = u, h = Ge(e, "modelValue"), { t: p } = Je(), b = na(), k = tn(), s = $t("rootEl"), C = g(() => k.platform.value.touch), D = ao(h, {
|
|
796
797
|
keyField: n.keyField,
|
|
797
798
|
positionField: n.positionField,
|
|
798
799
|
positionMultiplier: n.positionMultiplier,
|
|
799
800
|
updatePosition: n.updatePosition
|
|
800
|
-
}), N =
|
|
801
|
-
() =>
|
|
801
|
+
}), N = ce(/* @__PURE__ */ new Set()), V = $t("rowsContainer"), I = g(() => !n.chips && !!b.item), T = g(() => !n.chips && !!b["item-readonly"]), { captureDirtyBaseline: j, rebaselineKey: R, isItemDirty: $ } = qn(
|
|
802
|
+
() => h.value.map((o) => ({
|
|
802
803
|
key: o[n.keyField],
|
|
803
804
|
data: o
|
|
804
805
|
})),
|
|
805
|
-
{ source:
|
|
806
|
+
{ source: h }
|
|
806
807
|
), {
|
|
807
|
-
editingKeys:
|
|
808
|
-
editingSnapshots:
|
|
808
|
+
editingKeys: Y,
|
|
809
|
+
editingSnapshots: A,
|
|
809
810
|
beginEdit: J,
|
|
810
811
|
cancelEdit: L,
|
|
811
|
-
commitEdit:
|
|
812
|
+
commitEdit: E,
|
|
812
813
|
closeEdit: ee,
|
|
813
|
-
requestAutoOpen:
|
|
814
|
-
} =
|
|
814
|
+
requestAutoOpen: se
|
|
815
|
+
} = Gn({
|
|
815
816
|
rowsContainer: V,
|
|
816
817
|
rowSelector: ".a-le-row",
|
|
817
818
|
isInlineEdit: I,
|
|
818
|
-
restoreSnapshot: (o,
|
|
819
|
-
watchKeys: () =>
|
|
819
|
+
restoreSnapshot: (o, U) => D.updateItem(o, U),
|
|
820
|
+
watchKeys: () => h.value.map((o) => o[n.keyField]),
|
|
820
821
|
findEntry: (o) => {
|
|
821
|
-
const
|
|
822
|
-
return
|
|
822
|
+
const U = h.value.find((m) => m[n.keyField] === o);
|
|
823
|
+
return U ? { data: U } : null;
|
|
823
824
|
},
|
|
824
825
|
afterAutoOpen: (o) => {
|
|
825
826
|
N.value.delete(o);
|
|
826
827
|
}
|
|
827
|
-
}),
|
|
828
|
-
() => n.addLabel ?
|
|
829
|
-
),
|
|
830
|
-
() => n.deleteConfirmTitle ??
|
|
831
|
-
),
|
|
832
|
-
() => n.deleteConfirmText ??
|
|
833
|
-
),
|
|
828
|
+
}), X = g(
|
|
829
|
+
() => n.addLabel ? p(n.addLabel) : p("common.sortable.add")
|
|
830
|
+
), ae = g(() => n.emptyTitle ?? p("common.sortable.emptyTitle")), re = g(
|
|
831
|
+
() => n.deleteConfirmTitle ?? p("common.sortable.deleteConfirmTitle")
|
|
832
|
+
), P = g(
|
|
833
|
+
() => n.deleteConfirmText ?? p("common.sortable.deleteConfirmText")
|
|
834
|
+
), c = g(() => !n.readonly && !n.disabled && !n.loading), v = g(() => c.value && n.showAddButton), S = g(() => !!(n.title || b.header)), F = g(() => !!n.onItemSave), O = g(() => {
|
|
834
835
|
const o = /* @__PURE__ */ new Set();
|
|
835
|
-
for (const
|
|
836
|
-
const
|
|
837
|
-
$(
|
|
836
|
+
for (const U of h.value) {
|
|
837
|
+
const m = U[n.keyField];
|
|
838
|
+
$(m, U) && o.add(m);
|
|
838
839
|
}
|
|
839
840
|
return o;
|
|
840
|
-
}),
|
|
841
|
-
const o = [],
|
|
842
|
-
for (const
|
|
843
|
-
|
|
844
|
-
const
|
|
845
|
-
if (
|
|
846
|
-
o.push(
|
|
841
|
+
}), q = /* @__PURE__ */ new Map(), oe = g(() => {
|
|
842
|
+
const o = [], U = /* @__PURE__ */ new Set();
|
|
843
|
+
for (const m of D.viewItems.value) {
|
|
844
|
+
U.add(m.key);
|
|
845
|
+
const fe = Y.value.has(m.key), be = N.value.has(m.key), bt = n.loadingKeys?.has(m.key) ?? !1, nt = n.disableUnsaved ? !1 : O.value.has(m.key), Ce = q.get(m.key);
|
|
846
|
+
if (Ce && Ce.raw === m.raw && Ce.index === m.index && Ce.position === m.position && Ce.editing === fe && Ce.expanded === be && Ce.loading === bt && Ce.dirty === nt) {
|
|
847
|
+
o.push(Ce);
|
|
847
848
|
continue;
|
|
848
849
|
}
|
|
849
|
-
const
|
|
850
|
-
...
|
|
851
|
-
editing:
|
|
852
|
-
expanded:
|
|
853
|
-
loading:
|
|
854
|
-
dirty:
|
|
850
|
+
const kt = {
|
|
851
|
+
...m,
|
|
852
|
+
editing: fe,
|
|
853
|
+
expanded: be,
|
|
854
|
+
loading: bt,
|
|
855
|
+
dirty: nt
|
|
855
856
|
};
|
|
856
|
-
|
|
857
|
+
q.set(m.key, kt), o.push(kt);
|
|
857
858
|
}
|
|
858
|
-
for (const
|
|
859
|
-
|
|
859
|
+
for (const m of q.keys())
|
|
860
|
+
U.has(m) || q.delete(m);
|
|
860
861
|
return o;
|
|
861
|
-
}),
|
|
862
|
-
viewItems: g(() =>
|
|
862
|
+
}), te = g(() => oe.value.length === 0), Q = (o) => oe.value.find((U) => U.key === o), ue = Hn({
|
|
863
|
+
viewItems: g(() => oe.value.map((o) => ({ key: o.key }))),
|
|
863
864
|
variant: "flat",
|
|
864
|
-
isReorderMode:
|
|
865
|
-
disabled: g(() => !
|
|
866
|
-
isEditing: (o) =>
|
|
865
|
+
isReorderMode: ce(!1),
|
|
866
|
+
disabled: g(() => !c.value),
|
|
867
|
+
isEditing: (o) => Y.value.has(o),
|
|
867
868
|
onToggleEdit: (o) => {
|
|
868
|
-
const
|
|
869
|
-
|
|
869
|
+
const U = Q(o);
|
|
870
|
+
U && ye(U);
|
|
870
871
|
},
|
|
871
872
|
onCancelEdit: (o) => {
|
|
872
|
-
const
|
|
873
|
-
|
|
873
|
+
const U = Q(o);
|
|
874
|
+
U && tt(U);
|
|
874
875
|
}
|
|
875
|
-
}),
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
if (v.value) {
|
|
886
|
-
if (X.value.has(o.key)) {
|
|
887
|
-
nt(o);
|
|
876
|
+
}), ge = (o) => _n(o, { compactField: n.compactField }), { resolveValidation: Te } = Jn({
|
|
877
|
+
getValidationState: (o, U, m) => n.getValidationState?.(o, U, m) ?? null
|
|
878
|
+
}), Ae = () => {
|
|
879
|
+
v.value && (se(), f("add", void 0));
|
|
880
|
+
}, $e = (o) => {
|
|
881
|
+
c.value && (se(), f("add", { afterId: o.key }));
|
|
882
|
+
}, ye = (o) => {
|
|
883
|
+
if (c.value) {
|
|
884
|
+
if (Y.value.has(o.key)) {
|
|
885
|
+
tt(o);
|
|
888
886
|
return;
|
|
889
887
|
}
|
|
890
|
-
I.value && (J(o), N.value.delete(o.key)),
|
|
888
|
+
I.value && (J(o), N.value.delete(o.key)), f("edit", o);
|
|
891
889
|
}
|
|
892
|
-
},
|
|
890
|
+
}, Fe = (o) => {
|
|
893
891
|
if (n.disabled || n.loading) return;
|
|
894
|
-
const
|
|
895
|
-
if (
|
|
896
|
-
N.value.delete(
|
|
892
|
+
const U = o.key, m = N.value.has(U);
|
|
893
|
+
if (m)
|
|
894
|
+
N.value.delete(U);
|
|
897
895
|
else {
|
|
898
|
-
for (const
|
|
899
|
-
N.value.add(
|
|
896
|
+
for (const fe of N.value) N.value.delete(fe);
|
|
897
|
+
N.value.add(U);
|
|
900
898
|
}
|
|
901
|
-
|
|
902
|
-
},
|
|
903
|
-
if (
|
|
899
|
+
f("item-expand", o, !m);
|
|
900
|
+
}, Se = (o) => n.chips || n.disableRowClick || n.defaultExpanded || n.disabled || n.loading ? !1 : !!(o.editing || o.expanded || !n.readonly && n.showEditButton), _e = (o) => {
|
|
901
|
+
if (Se(o)) {
|
|
904
902
|
if (o.editing || o.expanded) {
|
|
905
|
-
|
|
903
|
+
tt(o);
|
|
906
904
|
return;
|
|
907
905
|
}
|
|
908
|
-
n.readonly &&
|
|
906
|
+
n.readonly && T.value ? Fe(o) : ye(o);
|
|
909
907
|
}
|
|
910
908
|
}, {
|
|
911
|
-
deleteDialog:
|
|
912
|
-
deleteInFlight:
|
|
913
|
-
deleteError:
|
|
914
|
-
onDeleteClick:
|
|
915
|
-
onDeleteDialogConfirm:
|
|
916
|
-
onDeleteDialogCancel:
|
|
917
|
-
} =
|
|
909
|
+
deleteDialog: Me,
|
|
910
|
+
deleteInFlight: ht,
|
|
911
|
+
deleteError: we,
|
|
912
|
+
onDeleteClick: et,
|
|
913
|
+
onDeleteDialogConfirm: We,
|
|
914
|
+
onDeleteDialogCancel: lt
|
|
915
|
+
} = Wn({
|
|
918
916
|
onDeleteConfirm: (o) => n.onDeleteConfirm ? n.onDeleteConfirm(o) : !0,
|
|
919
917
|
onDelete: (o) => n.onDelete?.(o),
|
|
920
918
|
onDeleted: (o) => {
|
|
921
|
-
|
|
919
|
+
Y.value.delete(o.key), A.value.delete(o.key), N.value.delete(o.key), f("deleted", o);
|
|
922
920
|
},
|
|
923
921
|
disableDeleteConfirm: () => n.disableDeleteConfirm || n.chips
|
|
924
|
-
}),
|
|
925
|
-
|
|
926
|
-
},
|
|
927
|
-
n.onItemSave && await n.onItemSave(o.raw),
|
|
928
|
-
},
|
|
922
|
+
}), Ye = async (o) => {
|
|
923
|
+
c.value && await et(o);
|
|
924
|
+
}, Pe = async (o) => {
|
|
925
|
+
n.onItemSave && await n.onItemSave(o.raw), E(o), f("item-saved", o);
|
|
926
|
+
}, it = (o) => {
|
|
929
927
|
L(o);
|
|
930
|
-
},
|
|
931
|
-
ee(o), N.value.delete(o.key),
|
|
932
|
-
}, Xe = /* @__PURE__ */ new Map(),
|
|
933
|
-
let
|
|
934
|
-
return
|
|
928
|
+
}, tt = (o) => {
|
|
929
|
+
ee(o), N.value.delete(o.key), f("close", o);
|
|
930
|
+
}, Xe = /* @__PURE__ */ new Map(), Rt = (o) => {
|
|
931
|
+
let U = Xe.get(o);
|
|
932
|
+
return U || (U = {
|
|
935
933
|
edit: () => {
|
|
936
|
-
const
|
|
937
|
-
|
|
934
|
+
const m = Q(o);
|
|
935
|
+
m && ye(m);
|
|
938
936
|
},
|
|
939
937
|
save: () => {
|
|
940
|
-
const
|
|
941
|
-
if (
|
|
938
|
+
const m = Q(o);
|
|
939
|
+
if (m) return Pe(m);
|
|
942
940
|
},
|
|
943
941
|
cancel: () => {
|
|
944
|
-
const
|
|
945
|
-
|
|
942
|
+
const m = Q(o);
|
|
943
|
+
m && it(m);
|
|
946
944
|
},
|
|
947
945
|
close: () => {
|
|
948
|
-
const
|
|
949
|
-
|
|
946
|
+
const m = Q(o);
|
|
947
|
+
m && tt(m);
|
|
950
948
|
},
|
|
951
949
|
delete: async () => {
|
|
952
|
-
const
|
|
953
|
-
|
|
950
|
+
const m = Q(o);
|
|
951
|
+
m && await Ye(m);
|
|
954
952
|
},
|
|
955
953
|
addAfter: () => {
|
|
956
|
-
const
|
|
957
|
-
|
|
954
|
+
const m = Q(o);
|
|
955
|
+
m && $e(m);
|
|
958
956
|
},
|
|
959
957
|
toggleExpand: () => {
|
|
960
|
-
const
|
|
961
|
-
|
|
958
|
+
const m = Q(o);
|
|
959
|
+
m && Fe(m);
|
|
962
960
|
},
|
|
963
|
-
update: (
|
|
964
|
-
}, Xe.set(o,
|
|
961
|
+
update: (m) => D.updateItem(o, m)
|
|
962
|
+
}, Xe.set(o, U)), U;
|
|
965
963
|
};
|
|
966
964
|
Ee(
|
|
967
|
-
() =>
|
|
965
|
+
() => oe.value,
|
|
968
966
|
(o) => {
|
|
969
967
|
if (Xe.size === 0) return;
|
|
970
|
-
const
|
|
971
|
-
for (const
|
|
972
|
-
|
|
968
|
+
const U = new Set(o.map((m) => m.key));
|
|
969
|
+
for (const m of Xe.keys())
|
|
970
|
+
U.has(m) || Xe.delete(m);
|
|
973
971
|
}
|
|
974
972
|
);
|
|
975
|
-
const
|
|
976
|
-
item: { ...o, validationState:
|
|
973
|
+
const Be = (o) => ({
|
|
974
|
+
item: { ...o, validationState: Te(o.raw, o.key, o.index) },
|
|
977
975
|
raw: o.raw,
|
|
978
976
|
index: o.index,
|
|
979
977
|
key: o.key,
|
|
980
978
|
readonly: n.readonly,
|
|
981
979
|
disabled: n.disabled,
|
|
982
980
|
expanded: o.expanded,
|
|
983
|
-
editing: o.editing,
|
|
981
|
+
editing: o.editing || n.defaultExpanded,
|
|
984
982
|
dirty: o.dirty,
|
|
985
983
|
unsaved: o.dirty,
|
|
986
984
|
touch: C.value,
|
|
987
|
-
actions:
|
|
988
|
-
}),
|
|
985
|
+
actions: Rt(o.key)
|
|
986
|
+
}), pt = Ge(e, "unsavedKeys"), ze = g(() => {
|
|
989
987
|
const o = /* @__PURE__ */ new Set();
|
|
990
|
-
for (const
|
|
991
|
-
|
|
988
|
+
for (const U of oe.value)
|
|
989
|
+
U.dirty && o.add(U.key);
|
|
992
990
|
return o;
|
|
993
|
-
}), { hasUnsavedChanges: Qe, unsavedCount:
|
|
994
|
-
unsavedKeysModel:
|
|
995
|
-
internalUnsavedKeys:
|
|
991
|
+
}), { hasUnsavedChanges: Qe, unsavedCount: st, clearUnsavedState: gt } = Yn({
|
|
992
|
+
unsavedKeysModel: pt,
|
|
993
|
+
internalUnsavedKeys: ze,
|
|
996
994
|
onClearAll: () => j(),
|
|
997
995
|
onClearKey: (o) => R(o)
|
|
998
996
|
});
|
|
@@ -1005,12 +1003,12 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1005
1003
|
viewItems: D.viewItems,
|
|
1006
1004
|
resetDirtyBaseline: j,
|
|
1007
1005
|
hasUnsavedChanges: Qe,
|
|
1008
|
-
unsavedCount:
|
|
1009
|
-
clearUnsavedState:
|
|
1010
|
-
}), (o,
|
|
1006
|
+
unsavedCount: st,
|
|
1007
|
+
clearUnsavedState: gt
|
|
1008
|
+
}), (o, U) => (y(), K("div", {
|
|
1011
1009
|
ref_key: "rootEl",
|
|
1012
1010
|
ref: s,
|
|
1013
|
-
class:
|
|
1011
|
+
class: xe(["a-list-editor", [
|
|
1014
1012
|
`a-list-editor--two-rows-${e.twoRows}`,
|
|
1015
1013
|
{
|
|
1016
1014
|
"a-list-editor--readonly": e.readonly,
|
|
@@ -1025,77 +1023,79 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1025
1023
|
ref: V,
|
|
1026
1024
|
class: "a-le-card"
|
|
1027
1025
|
}, [
|
|
1028
|
-
|
|
1026
|
+
S.value ? (y(), K("div", Wo, [
|
|
1029
1027
|
z(o.$slots, "header", { title: e.title }, () => [
|
|
1030
|
-
e.title ? (
|
|
1028
|
+
e.title ? (y(), K("h3", Yo, B(e.title), 1)) : H("", !0)
|
|
1031
1029
|
])
|
|
1032
|
-
])) :
|
|
1033
|
-
e.loading ? (
|
|
1034
|
-
i(
|
|
1030
|
+
])) : H("", !0),
|
|
1031
|
+
e.loading ? (y(), K("div", Xo, [
|
|
1032
|
+
i(sa, {
|
|
1035
1033
|
indeterminate: "",
|
|
1036
1034
|
color: "primary",
|
|
1037
1035
|
size: "32"
|
|
1038
1036
|
})
|
|
1039
|
-
])) : e.error ? (
|
|
1040
|
-
i(
|
|
1037
|
+
])) : e.error ? (y(), K("div", Qo, [
|
|
1038
|
+
i(ln, {
|
|
1041
1039
|
type: "error",
|
|
1042
1040
|
variant: "tonal",
|
|
1043
1041
|
density: "compact",
|
|
1044
1042
|
border: "start"
|
|
1045
1043
|
}, {
|
|
1046
1044
|
default: r(() => [
|
|
1047
|
-
|
|
1045
|
+
G(B(e.error), 1)
|
|
1048
1046
|
]),
|
|
1049
1047
|
_: 1
|
|
1050
1048
|
})
|
|
1051
|
-
])) :
|
|
1049
|
+
])) : te.value ? (y(), K("div", Zo, [
|
|
1052
1050
|
z(o.$slots, "empty", {
|
|
1053
1051
|
readonly: e.readonly,
|
|
1054
1052
|
disabled: e.disabled,
|
|
1055
|
-
actions: { add:
|
|
1053
|
+
actions: { add: Ae }
|
|
1056
1054
|
}, () => [
|
|
1057
|
-
i(
|
|
1058
|
-
title:
|
|
1059
|
-
|
|
1060
|
-
"add
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
}, null, 8, ["title", "text", "add-label", "can-add"])
|
|
1055
|
+
i(Xn, {
|
|
1056
|
+
title: ae.value,
|
|
1057
|
+
"add-label": X.value,
|
|
1058
|
+
"can-add": v.value,
|
|
1059
|
+
onAdd: Ae
|
|
1060
|
+
}, null, 8, ["title", "add-label", "can-add"])
|
|
1064
1061
|
])
|
|
1065
|
-
])) : (
|
|
1066
|
-
key: String(
|
|
1067
|
-
"data-id": String(
|
|
1062
|
+
])) : (y(!0), K(ve, { key: 4 }, Ze(oe.value, (m) => (y(), K("div", {
|
|
1063
|
+
key: String(m.key),
|
|
1064
|
+
"data-id": String(m.key),
|
|
1068
1065
|
role: "listitem",
|
|
1069
|
-
tabindex: d(
|
|
1070
|
-
class:
|
|
1066
|
+
tabindex: d(ue).rowTabindex(m.key),
|
|
1067
|
+
class: xe(["a-le-row", {
|
|
1071
1068
|
"a-le-row--two-rows": e.twoRows === "always",
|
|
1072
|
-
"a-le-row--editing":
|
|
1073
|
-
"a-le-row--expanded":
|
|
1074
|
-
"a-le-row--unsaved":
|
|
1075
|
-
"a-le-row--clickable":
|
|
1076
|
-
[`a-le-row--validation-${d(
|
|
1069
|
+
"a-le-row--editing": m.editing,
|
|
1070
|
+
"a-le-row--expanded": m.expanded,
|
|
1071
|
+
"a-le-row--unsaved": m.dirty,
|
|
1072
|
+
"a-le-row--clickable": Se(m),
|
|
1073
|
+
[`a-le-row--validation-${d(Te)(m.raw, m.key, m.index)}`]: d(Te)(m.raw, m.key, m.index) !== null
|
|
1077
1074
|
}]),
|
|
1078
|
-
onKeydown: (
|
|
1075
|
+
onKeydown: (fe) => d(ue).handleKeydown(m.key, fe)
|
|
1079
1076
|
}, [
|
|
1080
|
-
z(o.$slots, "before-item",
|
|
1077
|
+
z(o.$slots, "before-item", ie({ ref_for: !0 }, Be(m))),
|
|
1081
1078
|
M("div", {
|
|
1082
1079
|
class: "a-le-row-header",
|
|
1083
|
-
onClick: (
|
|
1080
|
+
onClick: (fe) => _e(m)
|
|
1084
1081
|
}, [
|
|
1085
|
-
M("div",
|
|
1086
|
-
z(o.$slots, "item-compact",
|
|
1087
|
-
M("span",
|
|
1082
|
+
M("div", tl, [
|
|
1083
|
+
z(o.$slots, "item-compact", ie({ ref_for: !0 }, Be(m)), () => [
|
|
1084
|
+
M("span", nl, B(ge(m.raw)), 1)
|
|
1088
1085
|
]),
|
|
1089
|
-
|
|
1086
|
+
m.dirty ? (y(), W(Qn, {
|
|
1087
|
+
key: 0,
|
|
1088
|
+
"dot-only": e.chips
|
|
1089
|
+
}, null, 8, ["dot-only"])) : H("", !0)
|
|
1090
1090
|
]),
|
|
1091
|
-
e.chips ?
|
|
1092
|
-
z(o.$slots, "item-status",
|
|
1093
|
-
e.statusField &&
|
|
1091
|
+
e.chips ? H("", !0) : (y(), K("div", al, [
|
|
1092
|
+
z(o.$slots, "item-status", ie({ ref_for: !0 }, Be(m)), () => [
|
|
1093
|
+
e.statusField && m.raw[e.statusField] != null && m.raw[e.statusField] !== "" ? (y(), K("span", ol, B(m.raw[e.statusField]), 1)) : H("", !0)
|
|
1094
1094
|
])
|
|
1095
1095
|
])),
|
|
1096
|
-
M("div",
|
|
1097
|
-
z(o.$slots, "item-actions",
|
|
1098
|
-
e.chips && e.showDeleteButton &&
|
|
1096
|
+
M("div", ll, [
|
|
1097
|
+
z(o.$slots, "item-actions", ie({ ref_for: !0 }, Be(m)), () => [
|
|
1098
|
+
e.chips && e.showDeleteButton && c.value ? (y(), W(_, {
|
|
1099
1099
|
key: 0,
|
|
1100
1100
|
icon: "",
|
|
1101
1101
|
size: "x-small",
|
|
@@ -1103,17 +1103,17 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1103
1103
|
density: "compact",
|
|
1104
1104
|
active: !1,
|
|
1105
1105
|
class: "a-le-action a-le-action--chip-close",
|
|
1106
|
-
onClick:
|
|
1106
|
+
onClick: le((fe) => Ye(m), ["stop"])
|
|
1107
1107
|
}, {
|
|
1108
1108
|
default: r(() => [
|
|
1109
|
-
i(
|
|
1109
|
+
i(ne, {
|
|
1110
1110
|
icon: "mdi-close",
|
|
1111
1111
|
size: "14"
|
|
1112
1112
|
})
|
|
1113
1113
|
]),
|
|
1114
1114
|
_: 1
|
|
1115
|
-
}, 8, ["onClick"])) : (
|
|
1116
|
-
e.showEditButton &&
|
|
1115
|
+
}, 8, ["onClick"])) : (y(), K(ve, { key: 1 }, [
|
|
1116
|
+
e.showEditButton && c.value && !e.defaultExpanded ? (y(), W(_, {
|
|
1117
1117
|
key: 0,
|
|
1118
1118
|
icon: "",
|
|
1119
1119
|
size: "small",
|
|
@@ -1121,44 +1121,44 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1121
1121
|
color: "primary",
|
|
1122
1122
|
density: "comfortable",
|
|
1123
1123
|
class: "mx-1 a-le-action a-le-action--edit",
|
|
1124
|
-
onClick:
|
|
1124
|
+
onClick: le((fe) => ye(m), ["stop"])
|
|
1125
1125
|
}, {
|
|
1126
1126
|
default: r(() => [
|
|
1127
|
-
i(
|
|
1127
|
+
i(ne, {
|
|
1128
1128
|
icon: "mdi-pencil-outline",
|
|
1129
1129
|
size: "18"
|
|
1130
1130
|
}),
|
|
1131
|
-
i(
|
|
1131
|
+
i(De, {
|
|
1132
1132
|
activator: "parent",
|
|
1133
1133
|
location: "bottom",
|
|
1134
|
-
text: d(
|
|
1134
|
+
text: d(p)("common.sortable.edit")
|
|
1135
1135
|
}, null, 8, ["text"])
|
|
1136
1136
|
]),
|
|
1137
1137
|
_: 1
|
|
1138
|
-
}, 8, ["onClick"])) :
|
|
1139
|
-
e.showDeleteButton &&
|
|
1138
|
+
}, 8, ["onClick"])) : H("", !0),
|
|
1139
|
+
e.showDeleteButton && c.value ? (y(), W(_, {
|
|
1140
1140
|
key: 1,
|
|
1141
1141
|
icon: "",
|
|
1142
1142
|
size: "small",
|
|
1143
1143
|
variant: "text",
|
|
1144
1144
|
density: "comfortable",
|
|
1145
1145
|
class: "mx-1 a-le-action a-le-action--delete",
|
|
1146
|
-
onClick:
|
|
1146
|
+
onClick: le((fe) => Ye(m), ["stop"])
|
|
1147
1147
|
}, {
|
|
1148
1148
|
default: r(() => [
|
|
1149
|
-
i(
|
|
1149
|
+
i(ne, {
|
|
1150
1150
|
icon: "mdi-trash-can-outline",
|
|
1151
1151
|
size: "18"
|
|
1152
1152
|
}),
|
|
1153
|
-
i(
|
|
1153
|
+
i(De, {
|
|
1154
1154
|
activator: "parent",
|
|
1155
1155
|
location: "bottom",
|
|
1156
|
-
text: d(
|
|
1156
|
+
text: d(p)("common.sortable.delete")
|
|
1157
1157
|
}, null, 8, ["text"])
|
|
1158
1158
|
]),
|
|
1159
1159
|
_: 1
|
|
1160
|
-
}, 8, ["onClick"])) :
|
|
1161
|
-
e.showAddAfterAction &&
|
|
1160
|
+
}, 8, ["onClick"])) : H("", !0),
|
|
1161
|
+
e.showAddAfterAction && c.value ? (y(), W(_, {
|
|
1162
1162
|
key: 2,
|
|
1163
1163
|
icon: "",
|
|
1164
1164
|
size: "small",
|
|
@@ -1168,29 +1168,29 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1168
1168
|
class: "mx-1 a-le-action a-le-action--menu"
|
|
1169
1169
|
}, {
|
|
1170
1170
|
default: r(() => [
|
|
1171
|
-
i(
|
|
1171
|
+
i(ne, {
|
|
1172
1172
|
icon: "mdi-dots-vertical",
|
|
1173
1173
|
size: "18"
|
|
1174
1174
|
}),
|
|
1175
|
-
i(
|
|
1175
|
+
i(De, {
|
|
1176
1176
|
activator: "parent",
|
|
1177
1177
|
location: "bottom",
|
|
1178
|
-
text: d(
|
|
1178
|
+
text: d(p)("common.sortable.more")
|
|
1179
1179
|
}, null, 8, ["text"]),
|
|
1180
|
-
i(
|
|
1180
|
+
i(Ft, { activator: "parent" }, {
|
|
1181
1181
|
default: r(() => [
|
|
1182
|
-
i(
|
|
1182
|
+
i(yt, { density: "compact" }, {
|
|
1183
1183
|
default: r(() => [
|
|
1184
|
-
i(
|
|
1185
|
-
onClick:
|
|
1184
|
+
i(Ie, {
|
|
1185
|
+
onClick: le((fe) => $e(m), ["stop"])
|
|
1186
1186
|
}, {
|
|
1187
1187
|
prepend: r(() => [
|
|
1188
|
-
i(
|
|
1188
|
+
i(ne, { icon: "mdi-plus" })
|
|
1189
1189
|
]),
|
|
1190
1190
|
default: r(() => [
|
|
1191
|
-
i(
|
|
1191
|
+
i(Re, null, {
|
|
1192
1192
|
default: r(() => [
|
|
1193
|
-
|
|
1193
|
+
G(B(d(p)("common.sortable.addAfter")), 1)
|
|
1194
1194
|
]),
|
|
1195
1195
|
_: 1
|
|
1196
1196
|
})
|
|
@@ -1205,27 +1205,27 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1205
1205
|
}, 1024)
|
|
1206
1206
|
]),
|
|
1207
1207
|
_: 2
|
|
1208
|
-
}, 1024)) :
|
|
1208
|
+
}, 1024)) : H("", !0)
|
|
1209
1209
|
], 64))
|
|
1210
1210
|
])
|
|
1211
1211
|
])
|
|
1212
|
-
], 8,
|
|
1213
|
-
|
|
1214
|
-
M("div",
|
|
1215
|
-
M("div",
|
|
1216
|
-
z(o.$slots, "item",
|
|
1212
|
+
], 8, el),
|
|
1213
|
+
(m.editing || e.defaultExpanded) && o.$slots.item ? (y(), K(ve, { key: 0 }, [
|
|
1214
|
+
M("div", il, [
|
|
1215
|
+
M("div", sl, [
|
|
1216
|
+
z(o.$slots, "item", ie({ ref_for: !0 }, Be(m)))
|
|
1217
1217
|
])
|
|
1218
1218
|
]),
|
|
1219
|
-
z(o.$slots, "item-footer",
|
|
1220
|
-
|
|
1221
|
-
|
|
1219
|
+
z(o.$slots, "item-footer", ie({ ref_for: !0 }, Be(m)), () => [
|
|
1220
|
+
F.value && !e.defaultExpanded ? (y(), K("div", rl, [
|
|
1221
|
+
U[1] || (U[1] = M("div", { class: "a-le-row-footer-spacer" }, null, -1)),
|
|
1222
1222
|
i(_, {
|
|
1223
1223
|
variant: "text",
|
|
1224
|
-
disabled:
|
|
1225
|
-
onClick:
|
|
1224
|
+
disabled: m.loading,
|
|
1225
|
+
onClick: le((fe) => it(m), ["stop"])
|
|
1226
1226
|
}, {
|
|
1227
1227
|
default: r(() => [
|
|
1228
|
-
|
|
1228
|
+
G(B(d(p)("common.button.cancel")), 1)
|
|
1229
1229
|
]),
|
|
1230
1230
|
_: 1
|
|
1231
1231
|
}, 8, ["disabled", "onClick"]),
|
|
@@ -1233,204 +1233,204 @@ const Mo = { class: "d-flex flex-column w-100 px-1 align-center" }, zo = { class
|
|
|
1233
1233
|
color: "primary",
|
|
1234
1234
|
variant: "flat",
|
|
1235
1235
|
"prepend-icon": "mdi-check",
|
|
1236
|
-
disabled:
|
|
1237
|
-
onClick:
|
|
1236
|
+
disabled: m.loading,
|
|
1237
|
+
onClick: le((fe) => Pe(m), ["stop"])
|
|
1238
1238
|
}, {
|
|
1239
1239
|
default: r(() => [
|
|
1240
|
-
|
|
1240
|
+
G(B(d(p)("common.button.save")), 1)
|
|
1241
1241
|
]),
|
|
1242
1242
|
_: 1
|
|
1243
1243
|
}, 8, ["disabled", "onClick"])
|
|
1244
|
-
])) :
|
|
1244
|
+
])) : H("", !0)
|
|
1245
1245
|
])
|
|
1246
|
-
], 64)) : o.$slots["item-readonly"] && (e.readonly ||
|
|
1247
|
-
M("div",
|
|
1248
|
-
z(o.$slots, "item-readonly",
|
|
1246
|
+
], 64)) : o.$slots["item-readonly"] && (e.readonly || m.expanded) ? (y(), K("div", dl, [
|
|
1247
|
+
M("div", cl, [
|
|
1248
|
+
z(o.$slots, "item-readonly", ie({ ref_for: !0 }, Be(m)))
|
|
1249
1249
|
])
|
|
1250
|
-
])) :
|
|
1251
|
-
z(o.$slots, "after-item",
|
|
1252
|
-
], 42,
|
|
1253
|
-
|
|
1250
|
+
])) : H("", !0),
|
|
1251
|
+
z(o.$slots, "after-item", ie({ ref_for: !0 }, Be(m)))
|
|
1252
|
+
], 42, _o))), 128)),
|
|
1253
|
+
v.value && !e.loading && !e.error && !te.value ? z(o.$slots, "add-button", {
|
|
1254
1254
|
key: 5,
|
|
1255
1255
|
readonly: e.readonly,
|
|
1256
1256
|
disabled: e.disabled,
|
|
1257
|
-
props: { onClick:
|
|
1258
|
-
actions: { add:
|
|
1257
|
+
props: { onClick: Ae },
|
|
1258
|
+
actions: { add: Ae }
|
|
1259
1259
|
}, () => [
|
|
1260
1260
|
M("button", {
|
|
1261
1261
|
type: "button",
|
|
1262
1262
|
class: "a-le-row-add",
|
|
1263
|
-
onClick:
|
|
1263
|
+
onClick: Ae
|
|
1264
1264
|
}, [
|
|
1265
|
-
i(
|
|
1265
|
+
i(ne, {
|
|
1266
1266
|
icon: "mdi-plus",
|
|
1267
1267
|
size: "18"
|
|
1268
1268
|
}),
|
|
1269
|
-
M("span", null, B(
|
|
1269
|
+
M("span", null, B(X.value), 1)
|
|
1270
1270
|
])
|
|
1271
|
-
]) :
|
|
1271
|
+
]) : H("", !0)
|
|
1272
1272
|
], 512),
|
|
1273
|
-
i(
|
|
1274
|
-
modelValue: d(
|
|
1275
|
-
"onUpdate:modelValue":
|
|
1276
|
-
title:
|
|
1277
|
-
text:
|
|
1278
|
-
"confirm-label": d(
|
|
1279
|
-
"cancel-label": d(
|
|
1280
|
-
error: d(
|
|
1281
|
-
"in-flight": d(
|
|
1282
|
-
onConfirm: d(
|
|
1283
|
-
onCancel: d(
|
|
1273
|
+
i(Zn, {
|
|
1274
|
+
modelValue: d(Me),
|
|
1275
|
+
"onUpdate:modelValue": U[0] || (U[0] = (m) => aa(Me) ? Me.value = m : null),
|
|
1276
|
+
title: re.value,
|
|
1277
|
+
text: P.value,
|
|
1278
|
+
"confirm-label": d(p)("common.sortable.delete"),
|
|
1279
|
+
"cancel-label": d(p)("common.button.cancel"),
|
|
1280
|
+
error: d(we),
|
|
1281
|
+
"in-flight": d(ht),
|
|
1282
|
+
onConfirm: d(We),
|
|
1283
|
+
onCancel: d(lt)
|
|
1284
1284
|
}, null, 8, ["modelValue", "title", "text", "confirm-label", "cancel-label", "error", "in-flight", "onConfirm", "onCancel"]),
|
|
1285
|
-
M("div",
|
|
1286
|
-
n: d(
|
|
1287
|
-
total: d(
|
|
1285
|
+
M("div", ul, B(d(ue).grabbedKey.value !== null ? d(p)("common.sortable.keyboardGrab.status", {
|
|
1286
|
+
n: d(ue).grabbedIndex.value + 1,
|
|
1287
|
+
total: d(ue).totalCount.value
|
|
1288
1288
|
}) : ""), 1)
|
|
1289
1289
|
], 2));
|
|
1290
1290
|
}
|
|
1291
|
-
}),
|
|
1292
|
-
function
|
|
1293
|
-
const
|
|
1291
|
+
}), fl = "id", ml = "position", vl = "parent";
|
|
1292
|
+
function yl(e, w) {
|
|
1293
|
+
const u = w.keyField ?? fl, n = w.positionField ?? ml, f = w.parentField ?? vl, h = w.positionMultiplier ?? 1, p = w.maxDepth, b = (P) => P[u], k = (P) => {
|
|
1294
1294
|
if (!P.children || P.children.length === 0) return 1;
|
|
1295
|
-
let
|
|
1295
|
+
let c = 0;
|
|
1296
1296
|
for (const v of P.children) {
|
|
1297
|
-
const
|
|
1298
|
-
|
|
1297
|
+
const S = k(v);
|
|
1298
|
+
S > c && (c = S);
|
|
1299
1299
|
}
|
|
1300
|
-
return
|
|
1301
|
-
}, s = (P,
|
|
1302
|
-
for (const
|
|
1303
|
-
if (b(
|
|
1304
|
-
if (
|
|
1305
|
-
const F = s(P,
|
|
1300
|
+
return c + 1;
|
|
1301
|
+
}, s = (P, c = e.value.children, v = null) => {
|
|
1302
|
+
for (const S of c) {
|
|
1303
|
+
if (b(S.data) === P) return { node: S, parent: v };
|
|
1304
|
+
if (S.children && S.children.length > 0) {
|
|
1305
|
+
const F = s(P, S.children, S);
|
|
1306
1306
|
if (F.node) return F;
|
|
1307
1307
|
}
|
|
1308
1308
|
}
|
|
1309
1309
|
return { node: null, parent: null };
|
|
1310
1310
|
}, C = (P) => {
|
|
1311
|
-
let
|
|
1311
|
+
let c = 1 * h;
|
|
1312
1312
|
for (const v of P)
|
|
1313
|
-
v.data[n] !==
|
|
1313
|
+
v.data[n] !== c && (v.data[n] = c), c += h;
|
|
1314
1314
|
}, D = (P) => {
|
|
1315
|
-
const
|
|
1315
|
+
const c = (v) => {
|
|
1316
1316
|
C(v);
|
|
1317
|
-
for (const
|
|
1317
|
+
for (const S of v) S.children && S.children.length && c(S.children);
|
|
1318
1318
|
};
|
|
1319
|
-
|
|
1319
|
+
c(P.children);
|
|
1320
1320
|
}, N = (P) => {
|
|
1321
|
-
const
|
|
1322
|
-
return D(
|
|
1321
|
+
const c = ke(P);
|
|
1322
|
+
return D(c), c;
|
|
1323
1323
|
}, V = (P) => {
|
|
1324
|
-
const
|
|
1325
|
-
let
|
|
1326
|
-
const F = (
|
|
1327
|
-
for (let
|
|
1328
|
-
const
|
|
1329
|
-
|
|
1330
|
-
key:
|
|
1331
|
-
index:
|
|
1332
|
-
raw:
|
|
1333
|
-
position:
|
|
1334
|
-
node:
|
|
1335
|
-
depth:
|
|
1336
|
-
parent:
|
|
1337
|
-
parentKey:
|
|
1338
|
-
childrenCount:
|
|
1339
|
-
hasChildren:
|
|
1340
|
-
childrenAllowed:
|
|
1341
|
-
siblingIndex:
|
|
1342
|
-
siblingCount:
|
|
1343
|
-
firstInParent:
|
|
1344
|
-
lastInParent:
|
|
1345
|
-
canAddChild:
|
|
1346
|
-
canIndent:
|
|
1347
|
-
canOutdent:
|
|
1348
|
-
}),
|
|
1324
|
+
const c = [], v = w.expandedKeys?.value;
|
|
1325
|
+
let S = 0;
|
|
1326
|
+
const F = (O, q, oe) => {
|
|
1327
|
+
for (let te = 0; te < O.length; te++) {
|
|
1328
|
+
const Q = O[te], ue = b(Q.data), ge = !pe(Q.children), Te = ge && (Q.children?.length ?? 0) > 0, Ae = Q.children?.length ?? 0, $e = v ? v.has(ue) : !0, ye = p - (q + 1), Fe = ge && ye > 0, Se = q > 0, _e = te > 0;
|
|
1329
|
+
c.push({
|
|
1330
|
+
key: ue,
|
|
1331
|
+
index: S++,
|
|
1332
|
+
raw: Q.data,
|
|
1333
|
+
position: Q.data[n],
|
|
1334
|
+
node: Q,
|
|
1335
|
+
depth: q,
|
|
1336
|
+
parent: oe?.data ?? null,
|
|
1337
|
+
parentKey: oe ? b(oe.data) : null,
|
|
1338
|
+
childrenCount: Ae,
|
|
1339
|
+
hasChildren: Te,
|
|
1340
|
+
childrenAllowed: ge,
|
|
1341
|
+
siblingIndex: te,
|
|
1342
|
+
siblingCount: O.length,
|
|
1343
|
+
firstInParent: te === 0,
|
|
1344
|
+
lastInParent: te === O.length - 1,
|
|
1345
|
+
canAddChild: Fe,
|
|
1346
|
+
canIndent: _e,
|
|
1347
|
+
canOutdent: Se
|
|
1348
|
+
}), Te && $e && F(Q.children, q + 1, Q);
|
|
1349
1349
|
}
|
|
1350
1350
|
};
|
|
1351
|
-
return F(P.children, 0, null),
|
|
1352
|
-
}, I = g(() => V(e.value)),
|
|
1353
|
-
P.splice(
|
|
1354
|
-
}, j = (P,
|
|
1355
|
-
if (!
|
|
1356
|
-
if (
|
|
1357
|
-
const v = P.findIndex((
|
|
1351
|
+
return F(P.children, 0, null), c;
|
|
1352
|
+
}, I = g(() => V(e.value)), T = (P, c, v) => {
|
|
1353
|
+
P.splice(c + 1, 0, v);
|
|
1354
|
+
}, j = (P, c) => {
|
|
1355
|
+
if (!c) return P.length;
|
|
1356
|
+
if (c.afterId !== void 0) {
|
|
1357
|
+
const v = P.findIndex((S) => b(S.data) === c.afterId);
|
|
1358
1358
|
return v === -1 ? P.length : v + 1;
|
|
1359
1359
|
}
|
|
1360
|
-
return
|
|
1361
|
-
}, R = (P,
|
|
1362
|
-
const v =
|
|
1363
|
-
data:
|
|
1364
|
-
children:
|
|
1360
|
+
return c.afterIndex !== void 0 ? c.afterIndex < 0 ? P.length : Math.min(c.afterIndex + 1, P.length) : c.index !== void 0 ? Math.max(0, Math.min(c.index, P.length)) : P.length;
|
|
1361
|
+
}, R = (P, c) => {
|
|
1362
|
+
const v = ke(e.value), S = c?.childrenAllowed ?? !0, F = {
|
|
1363
|
+
data: ke(P),
|
|
1364
|
+
children: S ? [] : void 0,
|
|
1365
1365
|
meta: { dirty: !1 }
|
|
1366
1366
|
};
|
|
1367
|
-
let
|
|
1368
|
-
if (
|
|
1369
|
-
const { node:
|
|
1370
|
-
|
|
1367
|
+
let O = v.children, q = null;
|
|
1368
|
+
if (c?.parentId !== void 0 && c.parentId !== null) {
|
|
1369
|
+
const { node: te } = s(c.parentId, v.children);
|
|
1370
|
+
te && te.children && (O = te.children, q = te);
|
|
1371
1371
|
}
|
|
1372
|
-
if (
|
|
1373
|
-
const { node:
|
|
1374
|
-
if (
|
|
1375
|
-
const
|
|
1376
|
-
if (
|
|
1377
|
-
return
|
|
1372
|
+
if (c?.afterId !== void 0) {
|
|
1373
|
+
const { node: te, parent: Q } = s(c.afterId, v.children);
|
|
1374
|
+
if (te) {
|
|
1375
|
+
const ue = Q ? Q.children : v.children, ge = ue.indexOf(te);
|
|
1376
|
+
if (ge !== -1)
|
|
1377
|
+
return T(ue, ge, F), F.data[f] = Q ? b(Q.data) : null, C(ue), e.value = v, v;
|
|
1378
1378
|
}
|
|
1379
1379
|
}
|
|
1380
|
-
const
|
|
1381
|
-
return
|
|
1380
|
+
const oe = c?.asFirstChild ? 0 : j(O, c);
|
|
1381
|
+
return O.splice(oe, 0, F), F.data[f] = q ? b(q.data) : null, C(O), e.value = v, v;
|
|
1382
1382
|
}, $ = (P) => {
|
|
1383
|
-
const
|
|
1384
|
-
if (!v) return
|
|
1385
|
-
const F =
|
|
1386
|
-
return
|
|
1387
|
-
},
|
|
1388
|
-
const v =
|
|
1389
|
-
return
|
|
1390
|
-
},
|
|
1391
|
-
const { node:
|
|
1392
|
-
if (!
|
|
1393
|
-
const
|
|
1394
|
-
if (
|
|
1395
|
-
const
|
|
1396
|
-
if (
|
|
1397
|
-
const [
|
|
1398
|
-
return
|
|
1383
|
+
const c = ke(e.value), { node: v, parent: S } = s(P, c.children);
|
|
1384
|
+
if (!v) return c;
|
|
1385
|
+
const F = S ? S.children : c.children, O = F.indexOf(v);
|
|
1386
|
+
return O === -1 || (F.splice(O, 1), C(F), e.value = c), c;
|
|
1387
|
+
}, Y = (P, c) => {
|
|
1388
|
+
const v = ke(e.value), { node: S } = s(P, v.children);
|
|
1389
|
+
return S && (S.data = ke(c), e.value = v), v;
|
|
1390
|
+
}, A = (P, c, v) => {
|
|
1391
|
+
const { node: S, parent: F } = s(c, P.children);
|
|
1392
|
+
if (!S) return null;
|
|
1393
|
+
const O = F ? F.children : P.children, q = O.indexOf(S);
|
|
1394
|
+
if (q === -1) return null;
|
|
1395
|
+
const oe = v(O, q);
|
|
1396
|
+
if (oe === null || oe === q) return null;
|
|
1397
|
+
const [te] = O.splice(q, 1);
|
|
1398
|
+
return O.splice(oe, 0, te), C(O), P;
|
|
1399
1399
|
}, J = (P) => {
|
|
1400
|
-
const
|
|
1400
|
+
const c = ke(e.value), v = A(c, P, (S, F) => F > 0 ? F - 1 : null);
|
|
1401
1401
|
return v && (e.value = v), v;
|
|
1402
1402
|
}, L = (P) => {
|
|
1403
|
-
const
|
|
1403
|
+
const c = ke(e.value), v = A(c, P, (S, F) => F < S.length - 1 ? F + 1 : null);
|
|
1404
1404
|
return v && (e.value = v), v;
|
|
1405
|
-
},
|
|
1406
|
-
const
|
|
1405
|
+
}, E = (P) => {
|
|
1406
|
+
const c = ke(e.value), v = A(c, P, (S, F) => F > 0 ? 0 : null);
|
|
1407
1407
|
return v && (e.value = v), v;
|
|
1408
1408
|
}, ee = (P) => {
|
|
1409
|
-
const
|
|
1409
|
+
const c = ke(e.value), v = A(c, P, (S, F) => F < S.length - 1 ? S.length - 1 : null);
|
|
1410
1410
|
return v && (e.value = v), v;
|
|
1411
|
-
},
|
|
1412
|
-
const
|
|
1411
|
+
}, se = (P) => {
|
|
1412
|
+
const c = ke(e.value), { node: v, parent: S } = s(P, c.children);
|
|
1413
1413
|
if (!v) return null;
|
|
1414
|
-
const F =
|
|
1415
|
-
if (
|
|
1416
|
-
const
|
|
1417
|
-
if (pe(
|
|
1418
|
-
const
|
|
1419
|
-
return
|
|
1420
|
-
},
|
|
1421
|
-
const
|
|
1422
|
-
if (!v || !
|
|
1423
|
-
const { parent: F } = s(b(
|
|
1424
|
-
if (
|
|
1425
|
-
const
|
|
1426
|
-
return
|
|
1427
|
-
},
|
|
1428
|
-
const v = (
|
|
1429
|
-
for (const
|
|
1430
|
-
if (b(
|
|
1431
|
-
if (
|
|
1432
|
-
const
|
|
1433
|
-
if (
|
|
1414
|
+
const F = S ? S.children : c.children, O = F.indexOf(v);
|
|
1415
|
+
if (O <= 0) return null;
|
|
1416
|
+
const q = F[O - 1];
|
|
1417
|
+
if (pe(q.children)) return null;
|
|
1418
|
+
const oe = k(v);
|
|
1419
|
+
return ae(c, b(q.data)) + 1 + oe > p ? null : (F.splice(O, 1), q.children.push(v), v.data[f] = b(q.data), C(F), C(q.children), e.value = c, c);
|
|
1420
|
+
}, X = (P) => {
|
|
1421
|
+
const c = ke(e.value), { node: v, parent: S } = s(P, c.children);
|
|
1422
|
+
if (!v || !S) return null;
|
|
1423
|
+
const { parent: F } = s(b(S.data), c.children), O = F ? F.children : c.children, q = O.indexOf(S);
|
|
1424
|
+
if (q === -1) return null;
|
|
1425
|
+
const oe = S.children, te = oe.indexOf(v);
|
|
1426
|
+
return te === -1 ? null : (oe.splice(te, 1), O.splice(q + 1, 0, v), v.data[f] = F ? b(F.data) : null, C(oe), C(O), e.value = c, c);
|
|
1427
|
+
}, ae = (P, c) => {
|
|
1428
|
+
const v = (S, F) => {
|
|
1429
|
+
for (const O of S) {
|
|
1430
|
+
if (b(O.data) === c) return F;
|
|
1431
|
+
if (O.children && O.children.length) {
|
|
1432
|
+
const q = v(O.children, F + 1);
|
|
1433
|
+
if (q !== null) return q;
|
|
1434
1434
|
}
|
|
1435
1435
|
}
|
|
1436
1436
|
return null;
|
|
@@ -1442,84 +1442,84 @@ function hl(e, w) {
|
|
|
1442
1442
|
findNode: s,
|
|
1443
1443
|
addItem: R,
|
|
1444
1444
|
deleteItem: $,
|
|
1445
|
-
updateItem:
|
|
1445
|
+
updateItem: Y,
|
|
1446
1446
|
moveUp: J,
|
|
1447
1447
|
moveDown: L,
|
|
1448
|
-
moveTop:
|
|
1448
|
+
moveTop: E,
|
|
1449
1449
|
moveBottom: ee,
|
|
1450
|
-
indent:
|
|
1451
|
-
outdent:
|
|
1452
|
-
moveTo: (P,
|
|
1453
|
-
const
|
|
1450
|
+
indent: se,
|
|
1451
|
+
outdent: X,
|
|
1452
|
+
moveTo: (P, c, v) => {
|
|
1453
|
+
const S = ke(e.value), { node: F, parent: O } = s(P, S.children);
|
|
1454
1454
|
if (!F) return null;
|
|
1455
|
-
if (
|
|
1456
|
-
const
|
|
1457
|
-
if (!
|
|
1458
|
-
for (const
|
|
1459
|
-
if (b(
|
|
1455
|
+
if (c !== null) {
|
|
1456
|
+
const ye = (Fe) => {
|
|
1457
|
+
if (!Fe.children) return !1;
|
|
1458
|
+
for (const Se of Fe.children)
|
|
1459
|
+
if (b(Se.data) === c || ye(Se)) return !0;
|
|
1460
1460
|
return !1;
|
|
1461
1461
|
};
|
|
1462
|
-
if (b(F.data) ===
|
|
1462
|
+
if (b(F.data) === c || ye(F)) return null;
|
|
1463
1463
|
}
|
|
1464
|
-
let
|
|
1465
|
-
if (
|
|
1466
|
-
|
|
1464
|
+
let q, oe = null, te = 0;
|
|
1465
|
+
if (c === null)
|
|
1466
|
+
q = S.children, te = 0;
|
|
1467
1467
|
else {
|
|
1468
|
-
const { node:
|
|
1469
|
-
if (!
|
|
1470
|
-
|
|
1468
|
+
const { node: ye } = s(c, S.children);
|
|
1469
|
+
if (!ye || pe(ye.children)) return null;
|
|
1470
|
+
q = ye.children, oe = ye, te = ae(S, c) + 1;
|
|
1471
1471
|
}
|
|
1472
|
-
const
|
|
1473
|
-
if (
|
|
1474
|
-
const
|
|
1475
|
-
if (
|
|
1476
|
-
const
|
|
1477
|
-
let
|
|
1478
|
-
return
|
|
1472
|
+
const Q = k(F);
|
|
1473
|
+
if (te + Q > p) return null;
|
|
1474
|
+
const ue = O ? O.children : S.children, ge = ue.indexOf(F);
|
|
1475
|
+
if (ge === -1) return null;
|
|
1476
|
+
const Te = ue === q, [Ae] = ue.splice(ge, 1);
|
|
1477
|
+
let $e = v;
|
|
1478
|
+
return Te && ge < v && ($e = v - 1), $e = Math.max(0, Math.min($e, q.length)), q.splice($e, 0, Ae), Ae.data[f] = oe ? b(oe.data) : null, Te || C(ue), C(q), e.value = S, S;
|
|
1479
1479
|
},
|
|
1480
1480
|
recalculatePositions: N,
|
|
1481
1481
|
calculateSubtreeDepth: k
|
|
1482
1482
|
};
|
|
1483
1483
|
}
|
|
1484
|
-
const
|
|
1485
|
-
let n =
|
|
1484
|
+
const Bt = (e, w) => e.find((u) => u.key === w) ?? null, ra = (e, w, u) => {
|
|
1485
|
+
let n = Bt(e, u);
|
|
1486
1486
|
for (; n && n.parentKey !== null; ) {
|
|
1487
1487
|
if (n.parentKey === w) return !0;
|
|
1488
|
-
n =
|
|
1488
|
+
n = Bt(e, n.parentKey);
|
|
1489
1489
|
}
|
|
1490
1490
|
return !1;
|
|
1491
|
-
},
|
|
1492
|
-
let n =
|
|
1493
|
-
for (; n && n.depth >
|
|
1491
|
+
}, hl = (e, w, u) => {
|
|
1492
|
+
let n = Bt(e, w);
|
|
1493
|
+
for (; n && n.depth > u; ) {
|
|
1494
1494
|
if (n.parentKey === null) return null;
|
|
1495
|
-
n =
|
|
1495
|
+
n = Bt(e, n.parentKey);
|
|
1496
1496
|
}
|
|
1497
|
-
return n && n.depth ===
|
|
1498
|
-
},
|
|
1499
|
-
for (let
|
|
1500
|
-
const
|
|
1501
|
-
if (!
|
|
1497
|
+
return n && n.depth === u ? n : null;
|
|
1498
|
+
}, pl = (e, w, u) => u === w || ra(e, w, u), It = (e, w, u, n) => {
|
|
1499
|
+
for (let f = w; f >= 0 && f < e.length; f += u) {
|
|
1500
|
+
const h = e[f];
|
|
1501
|
+
if (!pl(e, n, h.key)) return h;
|
|
1502
1502
|
}
|
|
1503
1503
|
return null;
|
|
1504
|
-
},
|
|
1504
|
+
}, gl = (e) => {
|
|
1505
1505
|
const {
|
|
1506
1506
|
pointer: w,
|
|
1507
|
-
hoveredRow:
|
|
1507
|
+
hoveredRow: u,
|
|
1508
1508
|
sourceKey: n,
|
|
1509
|
-
sourceSubtreeDepth:
|
|
1510
|
-
viewItems:
|
|
1511
|
-
maxDepth:
|
|
1509
|
+
sourceSubtreeDepth: f,
|
|
1510
|
+
viewItems: h,
|
|
1511
|
+
maxDepth: p,
|
|
1512
1512
|
indentPx: b,
|
|
1513
1513
|
containerLeft: k,
|
|
1514
1514
|
containerPaddingLeft: s
|
|
1515
1515
|
} = e;
|
|
1516
|
-
if (
|
|
1517
|
-
const C = w.y -
|
|
1516
|
+
if (u.key === n || ra(h, n, u.key)) return null;
|
|
1517
|
+
const C = w.y - u.rect.top, D = u.rect.height, N = C < D / 2, V = N ? "top" : "bottom", I = h.findIndex((E) => E.key === u.key), T = N ? It(h, I - 1, -1, n) : It(h, I, -1, n), j = N ? It(h, I, 1, n) : It(h, I + 1, 1, n), R = w.x - k - s, $ = Math.round(R / b), Y = T ? T.depth + 1 : 0, A = j ? j.depth : 0, J = Math.max(A, Math.min($, Y));
|
|
1518
1518
|
let L;
|
|
1519
|
-
if (!
|
|
1519
|
+
if (!T)
|
|
1520
1520
|
L = {
|
|
1521
1521
|
type: "insert",
|
|
1522
|
-
refKey:
|
|
1522
|
+
refKey: u.key,
|
|
1523
1523
|
refEdge: "top",
|
|
1524
1524
|
parentKey: null,
|
|
1525
1525
|
index: 0,
|
|
@@ -1527,72 +1527,72 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1527
1527
|
makeChild: !1,
|
|
1528
1528
|
levelRowKey: null
|
|
1529
1529
|
};
|
|
1530
|
-
else if (J ===
|
|
1530
|
+
else if (J === T.depth + 1)
|
|
1531
1531
|
L = {
|
|
1532
1532
|
type: "insert",
|
|
1533
|
-
refKey:
|
|
1533
|
+
refKey: u.key,
|
|
1534
1534
|
refEdge: V,
|
|
1535
|
-
parentKey:
|
|
1535
|
+
parentKey: T.key,
|
|
1536
1536
|
index: 0,
|
|
1537
1537
|
depth: J,
|
|
1538
1538
|
makeChild: !0,
|
|
1539
1539
|
levelRowKey: null
|
|
1540
1540
|
};
|
|
1541
|
-
else if (J ===
|
|
1541
|
+
else if (J === T.depth)
|
|
1542
1542
|
L = {
|
|
1543
1543
|
type: "insert",
|
|
1544
|
-
refKey:
|
|
1544
|
+
refKey: u.key,
|
|
1545
1545
|
refEdge: V,
|
|
1546
|
-
parentKey:
|
|
1547
|
-
index:
|
|
1546
|
+
parentKey: T.parentKey,
|
|
1547
|
+
index: T.siblingIndex + 1,
|
|
1548
1548
|
depth: J,
|
|
1549
1549
|
makeChild: !1,
|
|
1550
|
-
levelRowKey:
|
|
1550
|
+
levelRowKey: T.key
|
|
1551
1551
|
};
|
|
1552
1552
|
else {
|
|
1553
|
-
const
|
|
1554
|
-
|
|
1553
|
+
const E = hl(h, T.key, J);
|
|
1554
|
+
E ? L = {
|
|
1555
1555
|
type: "insert",
|
|
1556
|
-
refKey:
|
|
1556
|
+
refKey: u.key,
|
|
1557
1557
|
refEdge: V,
|
|
1558
|
-
parentKey:
|
|
1559
|
-
index:
|
|
1558
|
+
parentKey: E.parentKey,
|
|
1559
|
+
index: E.siblingIndex + 1,
|
|
1560
1560
|
depth: J,
|
|
1561
1561
|
makeChild: !1,
|
|
1562
|
-
levelRowKey:
|
|
1562
|
+
levelRowKey: E.key
|
|
1563
1563
|
} : L = {
|
|
1564
1564
|
type: "insert",
|
|
1565
|
-
refKey:
|
|
1565
|
+
refKey: u.key,
|
|
1566
1566
|
refEdge: V,
|
|
1567
|
-
parentKey:
|
|
1568
|
-
index:
|
|
1569
|
-
depth:
|
|
1567
|
+
parentKey: T.parentKey,
|
|
1568
|
+
index: T.siblingIndex + 1,
|
|
1569
|
+
depth: T.depth,
|
|
1570
1570
|
makeChild: !1,
|
|
1571
|
-
levelRowKey:
|
|
1571
|
+
levelRowKey: T.key
|
|
1572
1572
|
};
|
|
1573
1573
|
}
|
|
1574
|
-
return L.depth +
|
|
1575
|
-
},
|
|
1574
|
+
return L.depth + f - 1 >= p ? { type: "blocked", desired: L, reason: "maxDepth" } : L;
|
|
1575
|
+
}, bl = ["data-id", "aria-level", "tabindex"], kl = ["aria-label"], wl = {
|
|
1576
1576
|
key: 2,
|
|
1577
1577
|
class: "a-nested-list-editor__tree-toggle a-nested-list-editor__tree-toggle--spacer",
|
|
1578
1578
|
"aria-hidden": "true"
|
|
1579
|
-
},
|
|
1579
|
+
}, Cl = { class: "a-le-row-main" }, xl = { class: "a-le-title" }, Al = {
|
|
1580
1580
|
key: 0,
|
|
1581
1581
|
class: "a-nested-list-editor__drag-count",
|
|
1582
1582
|
"aria-hidden": "true"
|
|
1583
|
-
},
|
|
1583
|
+
}, Sl = {
|
|
1584
1584
|
key: 3,
|
|
1585
1585
|
class: "a-le-status"
|
|
1586
|
-
},
|
|
1586
|
+
}, Pl = {
|
|
1587
1587
|
key: 0,
|
|
1588
1588
|
class: "a-le-status-badge"
|
|
1589
|
-
},
|
|
1589
|
+
}, Il = { class: "a-le-actions" }, Dl = { class: "a-le-row-body" }, El = { class: "a-le-form" }, Tl = {
|
|
1590
1590
|
key: 0,
|
|
1591
1591
|
class: "a-le-row-footer"
|
|
1592
|
-
},
|
|
1592
|
+
}, $l = {
|
|
1593
1593
|
key: 1,
|
|
1594
1594
|
class: "a-le-row-body"
|
|
1595
|
-
},
|
|
1595
|
+
}, Fl = { class: "a-le-form" }, Bl = ["data-parent-id"], Rl = "a-nested-list-editor__group", Kl = "a-le-drag-handle", da = /* @__PURE__ */ He({
|
|
1596
1596
|
__name: "LeNestedRow",
|
|
1597
1597
|
props: {
|
|
1598
1598
|
vi: {},
|
|
@@ -1602,14 +1602,14 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1602
1602
|
callbacks: {}
|
|
1603
1603
|
},
|
|
1604
1604
|
setup(e) {
|
|
1605
|
-
const w = e,
|
|
1605
|
+
const w = e, u = da, { t: n } = Je(), f = (k) => `--row-${String(k).replace(/\W/g, "_")}`, h = (k) => {
|
|
1606
1606
|
if (typeof w.context.resolveValidation == "function")
|
|
1607
1607
|
return w.context.resolveValidation(k, w.vi.key, w.vi.index);
|
|
1608
1608
|
const s = k.validationState;
|
|
1609
1609
|
return s === "valid" || s === "invalid" || s === "warning" ? s : null;
|
|
1610
|
-
},
|
|
1611
|
-
return (k, s) => (
|
|
1612
|
-
class:
|
|
1610
|
+
}, p = () => w.context.buildSlotProps(w.vi), b = () => w.viewItems.filter((k) => k.parentKey === w.vi.key);
|
|
1611
|
+
return (k, s) => (y(), K("div", {
|
|
1612
|
+
class: xe([
|
|
1613
1613
|
"a-le-row-wrapper",
|
|
1614
1614
|
{
|
|
1615
1615
|
"a-le-row-wrapper--drop-disabled": e.dragState !== null && e.dragState.sourceKey === e.vi.key
|
|
@@ -1622,7 +1622,7 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1622
1622
|
onKeydown: s[17] || (s[17] = (C) => e.context.keyboardNav ? e.context.keyboardNav.handleKeydown(e.vi.key, C) : void 0)
|
|
1623
1623
|
}, [
|
|
1624
1624
|
M("div", {
|
|
1625
|
-
class:
|
|
1625
|
+
class: xe([
|
|
1626
1626
|
"a-le-row",
|
|
1627
1627
|
e.vi.depth > 0 ? "a-le-row--child" : null,
|
|
1628
1628
|
{
|
|
@@ -1633,28 +1633,28 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1633
1633
|
"a-le-row--grabbed": e.context.keyboardNav && e.context.keyboardNav.isGrabbed(e.vi.key),
|
|
1634
1634
|
"a-le-row--clickable": e.context.isRowClickable(e.vi),
|
|
1635
1635
|
"a-le-row--drop-source": e.dragState !== null && e.dragState.sourceKey === e.vi.key,
|
|
1636
|
-
[`a-le-row--validation-${
|
|
1636
|
+
[`a-le-row--validation-${h(e.vi.raw)}`]: h(e.vi.raw) !== null
|
|
1637
1637
|
}
|
|
1638
1638
|
]),
|
|
1639
|
-
style:
|
|
1639
|
+
style: vt({
|
|
1640
1640
|
"--nested-depth": e.vi.depth,
|
|
1641
|
-
"anchor-name":
|
|
1642
|
-
"--parent-anchor": e.vi.parentKey !== null ?
|
|
1641
|
+
"anchor-name": f(e.vi.key),
|
|
1642
|
+
"--parent-anchor": e.vi.parentKey !== null ? f(e.vi.parentKey) : "none"
|
|
1643
1643
|
})
|
|
1644
1644
|
}, [
|
|
1645
|
-
z(k.$slots, "before-item",
|
|
1645
|
+
z(k.$slots, "before-item", Ve(qe(p()))),
|
|
1646
1646
|
M("div", {
|
|
1647
1647
|
class: "a-le-row-header",
|
|
1648
1648
|
onClick: s[14] || (s[14] = (C) => e.callbacks.onRowClick(e.vi))
|
|
1649
1649
|
}, [
|
|
1650
|
-
e.context.dragEnabled ? (
|
|
1650
|
+
e.context.dragEnabled ? (y(), W(oo, {
|
|
1651
1651
|
key: 0,
|
|
1652
|
-
class:
|
|
1653
|
-
})) :
|
|
1654
|
-
e.context.showExpandToggle && e.vi.childrenAllowed ? (
|
|
1652
|
+
class: xe(Kl)
|
|
1653
|
+
})) : H("", !0),
|
|
1654
|
+
e.context.showExpandToggle && e.vi.childrenAllowed ? (y(), K("button", {
|
|
1655
1655
|
key: 1,
|
|
1656
1656
|
type: "button",
|
|
1657
|
-
class:
|
|
1657
|
+
class: xe([
|
|
1658
1658
|
"a-nested-list-editor__tree-toggle",
|
|
1659
1659
|
{
|
|
1660
1660
|
"a-nested-list-editor__tree-toggle--empty": !e.vi.hasChildren,
|
|
@@ -1662,31 +1662,31 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1662
1662
|
}
|
|
1663
1663
|
]),
|
|
1664
1664
|
"aria-label": e.vi.childrenExpanded ? d(n)("common.sortable.close") : d(n)("common.sortable.edit"),
|
|
1665
|
-
onClick: s[0] || (s[0] =
|
|
1665
|
+
onClick: s[0] || (s[0] = le((C) => e.vi.hasChildren && e.callbacks.onChevronClick(e.vi), ["stop"]))
|
|
1666
1666
|
}, [...s[18] || (s[18] = [
|
|
1667
1667
|
M("span", { class: "a-nested-list-editor__tree-toggle-caret" }, null, -1)
|
|
1668
|
-
])], 10,
|
|
1669
|
-
M("div",
|
|
1670
|
-
z(k.$slots, "item-compact",
|
|
1671
|
-
M("span",
|
|
1668
|
+
])], 10, kl)) : e.context.showExpandToggle ? (y(), K("span", wl)) : H("", !0),
|
|
1669
|
+
M("div", Cl, [
|
|
1670
|
+
z(k.$slots, "item-compact", Ve(qe(p())), () => [
|
|
1671
|
+
M("span", xl, B(e.context.resolveCompactText(e.vi.raw, e.vi.key)), 1)
|
|
1672
1672
|
]),
|
|
1673
|
-
e.vi.hasChildren ? (
|
|
1674
|
-
i(
|
|
1673
|
+
e.vi.hasChildren ? (y(), K("span", Al, [
|
|
1674
|
+
i(ne, {
|
|
1675
1675
|
icon: "mdi-file-tree",
|
|
1676
1676
|
size: "14"
|
|
1677
1677
|
}),
|
|
1678
|
-
|
|
1679
|
-
])) :
|
|
1680
|
-
e.vi.unsaved ? (
|
|
1678
|
+
G(" +" + B(e.vi.childrenCount), 1)
|
|
1679
|
+
])) : H("", !0),
|
|
1680
|
+
e.vi.unsaved ? (y(), W(Qn, { key: 1 })) : H("", !0)
|
|
1681
1681
|
]),
|
|
1682
|
-
e.context.reorderMode ?
|
|
1683
|
-
z(k.$slots, "item-status",
|
|
1684
|
-
e.context.statusField && e.vi.raw[e.context.statusField] != null && e.vi.raw[e.context.statusField] !== "" ? (
|
|
1682
|
+
e.context.reorderMode ? H("", !0) : (y(), K("div", Sl, [
|
|
1683
|
+
z(k.$slots, "item-status", Ve(qe(p())), () => [
|
|
1684
|
+
e.context.statusField && e.vi.raw[e.context.statusField] != null && e.vi.raw[e.context.statusField] !== "" ? (y(), K("span", Pl, B(e.vi.raw[e.context.statusField]), 1)) : H("", !0)
|
|
1685
1685
|
])
|
|
1686
1686
|
])),
|
|
1687
|
-
M("div",
|
|
1688
|
-
z(k.$slots, "item-actions",
|
|
1689
|
-
e.context.reorderMode ? (
|
|
1687
|
+
M("div", Il, [
|
|
1688
|
+
z(k.$slots, "item-actions", Ve(qe(p())), () => [
|
|
1689
|
+
e.context.reorderMode ? (y(), K(ve, { key: 0 }, [
|
|
1690
1690
|
i(_, {
|
|
1691
1691
|
icon: "",
|
|
1692
1692
|
size: "small",
|
|
@@ -1694,14 +1694,14 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1694
1694
|
density: "comfortable",
|
|
1695
1695
|
disabled: e.vi.firstInParent,
|
|
1696
1696
|
class: "mx-1 a-le-action a-le-action--up",
|
|
1697
|
-
onClick: s[1] || (s[1] =
|
|
1697
|
+
onClick: s[1] || (s[1] = le((C) => e.callbacks.moveUp(e.vi.key), ["stop"]))
|
|
1698
1698
|
}, {
|
|
1699
1699
|
default: r(() => [
|
|
1700
|
-
i(
|
|
1700
|
+
i(ne, {
|
|
1701
1701
|
icon: "mdi-arrow-up",
|
|
1702
1702
|
size: "18"
|
|
1703
1703
|
}),
|
|
1704
|
-
i(
|
|
1704
|
+
i(De, {
|
|
1705
1705
|
activator: "parent",
|
|
1706
1706
|
location: "bottom",
|
|
1707
1707
|
text: d(n)("common.sortable.moveUp")
|
|
@@ -1716,14 +1716,14 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1716
1716
|
density: "comfortable",
|
|
1717
1717
|
disabled: e.vi.lastInParent,
|
|
1718
1718
|
class: "mx-1 a-le-action a-le-action--down",
|
|
1719
|
-
onClick: s[2] || (s[2] =
|
|
1719
|
+
onClick: s[2] || (s[2] = le((C) => e.callbacks.moveDown(e.vi.key), ["stop"]))
|
|
1720
1720
|
}, {
|
|
1721
1721
|
default: r(() => [
|
|
1722
|
-
i(
|
|
1722
|
+
i(ne, {
|
|
1723
1723
|
icon: "mdi-arrow-down",
|
|
1724
1724
|
size: "18"
|
|
1725
1725
|
}),
|
|
1726
|
-
i(
|
|
1726
|
+
i(De, {
|
|
1727
1727
|
activator: "parent",
|
|
1728
1728
|
location: "bottom",
|
|
1729
1729
|
text: d(n)("common.sortable.moveDown")
|
|
@@ -1740,141 +1740,141 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1740
1740
|
class: "mx-1 a-le-action a-le-action--menu"
|
|
1741
1741
|
}, {
|
|
1742
1742
|
default: r(() => [
|
|
1743
|
-
i(
|
|
1743
|
+
i(ne, {
|
|
1744
1744
|
icon: "mdi-dots-vertical",
|
|
1745
1745
|
size: "18"
|
|
1746
1746
|
}),
|
|
1747
|
-
i(
|
|
1747
|
+
i(De, {
|
|
1748
1748
|
activator: "parent",
|
|
1749
1749
|
location: "bottom",
|
|
1750
1750
|
text: d(n)("common.sortable.more")
|
|
1751
1751
|
}, null, 8, ["text"]),
|
|
1752
|
-
i(
|
|
1752
|
+
i(Ft, { activator: "parent" }, {
|
|
1753
1753
|
default: r(() => [
|
|
1754
|
-
i(
|
|
1754
|
+
i(yt, { density: "compact" }, {
|
|
1755
1755
|
default: r(() => [
|
|
1756
|
-
i(
|
|
1756
|
+
i(Ie, {
|
|
1757
1757
|
disabled: e.vi.firstInParent,
|
|
1758
|
-
onClick: s[3] || (s[3] =
|
|
1758
|
+
onClick: s[3] || (s[3] = le((C) => e.callbacks.moveTop(e.vi.key), ["stop"]))
|
|
1759
1759
|
}, {
|
|
1760
1760
|
prepend: r(() => [
|
|
1761
|
-
i(
|
|
1761
|
+
i(ne, { icon: "mdi-arrow-collapse-up" })
|
|
1762
1762
|
]),
|
|
1763
1763
|
default: r(() => [
|
|
1764
|
-
i(
|
|
1764
|
+
i(Re, null, {
|
|
1765
1765
|
default: r(() => [
|
|
1766
|
-
|
|
1766
|
+
G(B(d(n)("common.sortable.moveToTop")), 1)
|
|
1767
1767
|
]),
|
|
1768
1768
|
_: 1
|
|
1769
1769
|
})
|
|
1770
1770
|
]),
|
|
1771
1771
|
_: 1
|
|
1772
1772
|
}, 8, ["disabled"]),
|
|
1773
|
-
i(
|
|
1773
|
+
i(Ie, {
|
|
1774
1774
|
disabled: e.vi.lastInParent,
|
|
1775
|
-
onClick: s[4] || (s[4] =
|
|
1775
|
+
onClick: s[4] || (s[4] = le((C) => e.callbacks.moveBottom(e.vi.key), ["stop"]))
|
|
1776
1776
|
}, {
|
|
1777
1777
|
prepend: r(() => [
|
|
1778
|
-
i(
|
|
1778
|
+
i(ne, { icon: "mdi-arrow-collapse-down" })
|
|
1779
1779
|
]),
|
|
1780
1780
|
default: r(() => [
|
|
1781
|
-
i(
|
|
1781
|
+
i(Re, null, {
|
|
1782
1782
|
default: r(() => [
|
|
1783
|
-
|
|
1783
|
+
G(B(d(n)("common.sortable.moveToBottom")), 1)
|
|
1784
1784
|
]),
|
|
1785
1785
|
_: 1
|
|
1786
1786
|
})
|
|
1787
1787
|
]),
|
|
1788
1788
|
_: 1
|
|
1789
1789
|
}, 8, ["disabled"]),
|
|
1790
|
-
e.context.showMoveToPosition && (!e.vi.firstInParent || !e.vi.lastInParent) ? (
|
|
1790
|
+
e.context.showMoveToPosition && (!e.vi.firstInParent || !e.vi.lastInParent) ? (y(), W(Ie, {
|
|
1791
1791
|
key: 0,
|
|
1792
|
-
onClick: s[5] || (s[5] =
|
|
1792
|
+
onClick: s[5] || (s[5] = le((C) => e.callbacks.openMoveToPosition(e.vi), ["stop"]))
|
|
1793
1793
|
}, {
|
|
1794
1794
|
prepend: r(() => [
|
|
1795
|
-
i(
|
|
1795
|
+
i(ne, { icon: "mdi-target" })
|
|
1796
1796
|
]),
|
|
1797
1797
|
default: r(() => [
|
|
1798
|
-
i(
|
|
1798
|
+
i(Re, null, {
|
|
1799
1799
|
default: r(() => [
|
|
1800
|
-
|
|
1800
|
+
G(B(d(n)("common.sortable.moveToPosition.action")), 1)
|
|
1801
1801
|
]),
|
|
1802
1802
|
_: 1
|
|
1803
1803
|
})
|
|
1804
1804
|
]),
|
|
1805
1805
|
_: 1
|
|
1806
|
-
})) :
|
|
1807
|
-
e.context.showChangeParent ? (
|
|
1806
|
+
})) : H("", !0),
|
|
1807
|
+
e.context.showChangeParent ? (y(), W(Ie, {
|
|
1808
1808
|
key: 1,
|
|
1809
|
-
onClick: s[6] || (s[6] =
|
|
1809
|
+
onClick: s[6] || (s[6] = le((C) => e.callbacks.openChangeParent(e.vi), ["stop"]))
|
|
1810
1810
|
}, {
|
|
1811
1811
|
prepend: r(() => [
|
|
1812
|
-
i(
|
|
1812
|
+
i(ne, { icon: "mdi-folder-move-outline" })
|
|
1813
1813
|
]),
|
|
1814
1814
|
default: r(() => [
|
|
1815
|
-
i(
|
|
1815
|
+
i(Re, null, {
|
|
1816
1816
|
default: r(() => [
|
|
1817
|
-
|
|
1817
|
+
G(B(d(n)("common.sortable.changeParent.action")), 1)
|
|
1818
1818
|
]),
|
|
1819
1819
|
_: 1
|
|
1820
1820
|
})
|
|
1821
1821
|
]),
|
|
1822
1822
|
_: 1
|
|
1823
|
-
})) :
|
|
1824
|
-
i(
|
|
1823
|
+
})) : H("", !0),
|
|
1824
|
+
i(Ie, {
|
|
1825
1825
|
disabled: !e.vi.canIndent,
|
|
1826
|
-
onClick: s[7] || (s[7] =
|
|
1826
|
+
onClick: s[7] || (s[7] = le((C) => e.callbacks.indent(e.vi), ["stop"]))
|
|
1827
1827
|
}, {
|
|
1828
1828
|
prepend: r(() => [
|
|
1829
|
-
i(
|
|
1829
|
+
i(ne, { icon: "mdi-format-indent-increase" })
|
|
1830
1830
|
]),
|
|
1831
1831
|
default: r(() => [
|
|
1832
|
-
i(
|
|
1832
|
+
i(Re, null, {
|
|
1833
1833
|
default: r(() => [
|
|
1834
|
-
|
|
1834
|
+
G(B(d(n)("common.sortable.indent")), 1)
|
|
1835
1835
|
]),
|
|
1836
1836
|
_: 1
|
|
1837
1837
|
})
|
|
1838
1838
|
]),
|
|
1839
1839
|
_: 1
|
|
1840
1840
|
}, 8, ["disabled"]),
|
|
1841
|
-
i(
|
|
1841
|
+
i(Ie, {
|
|
1842
1842
|
disabled: !e.vi.canOutdent,
|
|
1843
|
-
onClick: s[8] || (s[8] =
|
|
1843
|
+
onClick: s[8] || (s[8] = le((C) => e.callbacks.outdent(e.vi), ["stop"]))
|
|
1844
1844
|
}, {
|
|
1845
1845
|
prepend: r(() => [
|
|
1846
|
-
i(
|
|
1846
|
+
i(ne, { icon: "mdi-format-indent-decrease" })
|
|
1847
1847
|
]),
|
|
1848
1848
|
default: r(() => [
|
|
1849
|
-
i(
|
|
1849
|
+
i(Re, null, {
|
|
1850
1850
|
default: r(() => [
|
|
1851
|
-
|
|
1851
|
+
G(B(d(n)("common.sortable.outdent")), 1)
|
|
1852
1852
|
]),
|
|
1853
1853
|
_: 1
|
|
1854
1854
|
})
|
|
1855
1855
|
]),
|
|
1856
1856
|
_: 1
|
|
1857
1857
|
}, 8, ["disabled"]),
|
|
1858
|
-
e.context.showDeleteButton && e.context.canInteract ? (
|
|
1858
|
+
e.context.showDeleteButton && e.context.canInteract ? (y(), W(Ie, {
|
|
1859
1859
|
key: 2,
|
|
1860
|
-
onClick: s[9] || (s[9] =
|
|
1860
|
+
onClick: s[9] || (s[9] = le((C) => e.callbacks.onDeleteClick(e.vi), ["stop"]))
|
|
1861
1861
|
}, {
|
|
1862
1862
|
prepend: r(() => [
|
|
1863
|
-
i(
|
|
1863
|
+
i(ne, {
|
|
1864
1864
|
icon: "mdi-trash-can-outline",
|
|
1865
1865
|
color: "error"
|
|
1866
1866
|
})
|
|
1867
1867
|
]),
|
|
1868
1868
|
default: r(() => [
|
|
1869
|
-
i(
|
|
1869
|
+
i(Re, { class: "text-error" }, {
|
|
1870
1870
|
default: r(() => [
|
|
1871
|
-
|
|
1871
|
+
G(B(d(n)("common.sortable.delete")), 1)
|
|
1872
1872
|
]),
|
|
1873
1873
|
_: 1
|
|
1874
1874
|
})
|
|
1875
1875
|
]),
|
|
1876
1876
|
_: 1
|
|
1877
|
-
})) :
|
|
1877
|
+
})) : H("", !0)
|
|
1878
1878
|
]),
|
|
1879
1879
|
_: 1
|
|
1880
1880
|
})
|
|
@@ -1884,8 +1884,8 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1884
1884
|
]),
|
|
1885
1885
|
_: 1
|
|
1886
1886
|
})
|
|
1887
|
-
], 64)) : (
|
|
1888
|
-
e.context.showEditButton && e.context.canInteract ? (
|
|
1887
|
+
], 64)) : (y(), K(ve, { key: 1 }, [
|
|
1888
|
+
e.context.showEditButton && e.context.canInteract ? (y(), W(_, {
|
|
1889
1889
|
key: 0,
|
|
1890
1890
|
icon: "",
|
|
1891
1891
|
size: "small",
|
|
@@ -1893,44 +1893,44 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1893
1893
|
color: "primary",
|
|
1894
1894
|
density: "comfortable",
|
|
1895
1895
|
class: "mx-1 a-le-action a-le-action--edit",
|
|
1896
|
-
onClick: s[10] || (s[10] =
|
|
1896
|
+
onClick: s[10] || (s[10] = le((C) => e.callbacks.onEditClick(e.vi), ["stop"]))
|
|
1897
1897
|
}, {
|
|
1898
1898
|
default: r(() => [
|
|
1899
|
-
i(
|
|
1899
|
+
i(ne, {
|
|
1900
1900
|
icon: "mdi-pencil-outline",
|
|
1901
1901
|
size: "18"
|
|
1902
1902
|
}),
|
|
1903
|
-
i(
|
|
1903
|
+
i(De, {
|
|
1904
1904
|
activator: "parent",
|
|
1905
1905
|
location: "bottom",
|
|
1906
1906
|
text: d(n)("common.sortable.edit")
|
|
1907
1907
|
}, null, 8, ["text"])
|
|
1908
1908
|
]),
|
|
1909
1909
|
_: 1
|
|
1910
|
-
})) :
|
|
1911
|
-
e.context.showDeleteButton && e.context.canInteract ? (
|
|
1910
|
+
})) : H("", !0),
|
|
1911
|
+
e.context.showDeleteButton && e.context.canInteract ? (y(), W(_, {
|
|
1912
1912
|
key: 1,
|
|
1913
1913
|
icon: "",
|
|
1914
1914
|
size: "small",
|
|
1915
1915
|
variant: "text",
|
|
1916
1916
|
density: "comfortable",
|
|
1917
1917
|
class: "mx-1 a-le-action a-le-action--delete",
|
|
1918
|
-
onClick: s[11] || (s[11] =
|
|
1918
|
+
onClick: s[11] || (s[11] = le((C) => e.callbacks.onDeleteClick(e.vi), ["stop"]))
|
|
1919
1919
|
}, {
|
|
1920
1920
|
default: r(() => [
|
|
1921
|
-
i(
|
|
1921
|
+
i(ne, {
|
|
1922
1922
|
icon: "mdi-trash-can-outline",
|
|
1923
1923
|
size: "18"
|
|
1924
1924
|
}),
|
|
1925
|
-
i(
|
|
1925
|
+
i(De, {
|
|
1926
1926
|
activator: "parent",
|
|
1927
1927
|
location: "bottom",
|
|
1928
1928
|
text: d(n)("common.sortable.delete")
|
|
1929
1929
|
}, null, 8, ["text"])
|
|
1930
1930
|
]),
|
|
1931
1931
|
_: 1
|
|
1932
|
-
})) :
|
|
1933
|
-
e.context.canInteract && (e.context.showAddChildButton && e.vi.canAddChild || e.context.showAddAfterAction) ? (
|
|
1932
|
+
})) : H("", !0),
|
|
1933
|
+
e.context.canInteract && (e.context.showAddChildButton && e.vi.canAddChild || e.context.showAddAfterAction) ? (y(), W(_, {
|
|
1934
1934
|
key: 2,
|
|
1935
1935
|
icon: "",
|
|
1936
1936
|
size: "small",
|
|
@@ -1940,53 +1940,53 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1940
1940
|
class: "mx-1 a-le-action a-le-action--menu"
|
|
1941
1941
|
}, {
|
|
1942
1942
|
default: r(() => [
|
|
1943
|
-
i(
|
|
1943
|
+
i(ne, {
|
|
1944
1944
|
icon: "mdi-dots-vertical",
|
|
1945
1945
|
size: "18"
|
|
1946
1946
|
}),
|
|
1947
|
-
i(
|
|
1947
|
+
i(De, {
|
|
1948
1948
|
activator: "parent",
|
|
1949
1949
|
location: "bottom",
|
|
1950
1950
|
text: d(n)("common.sortable.more")
|
|
1951
1951
|
}, null, 8, ["text"]),
|
|
1952
|
-
i(
|
|
1952
|
+
i(Ft, { activator: "parent" }, {
|
|
1953
1953
|
default: r(() => [
|
|
1954
|
-
i(
|
|
1954
|
+
i(yt, { density: "compact" }, {
|
|
1955
1955
|
default: r(() => [
|
|
1956
|
-
e.context.showAddAfterAction ? (
|
|
1956
|
+
e.context.showAddAfterAction ? (y(), W(Ie, {
|
|
1957
1957
|
key: 0,
|
|
1958
|
-
onClick: s[12] || (s[12] =
|
|
1958
|
+
onClick: s[12] || (s[12] = le((C) => e.callbacks.onAddAfterClick(e.vi), ["stop"]))
|
|
1959
1959
|
}, {
|
|
1960
1960
|
prepend: r(() => [
|
|
1961
|
-
i(
|
|
1961
|
+
i(ne, { icon: "mdi-playlist-plus" })
|
|
1962
1962
|
]),
|
|
1963
1963
|
default: r(() => [
|
|
1964
|
-
i(
|
|
1964
|
+
i(Re, null, {
|
|
1965
1965
|
default: r(() => [
|
|
1966
|
-
|
|
1966
|
+
G(B(d(n)("common.sortable.addAfter")), 1)
|
|
1967
1967
|
]),
|
|
1968
1968
|
_: 1
|
|
1969
1969
|
})
|
|
1970
1970
|
]),
|
|
1971
1971
|
_: 1
|
|
1972
|
-
})) :
|
|
1973
|
-
e.context.showAddChildButton && e.vi.canAddChild ? (
|
|
1972
|
+
})) : H("", !0),
|
|
1973
|
+
e.context.showAddChildButton && e.vi.canAddChild ? (y(), W(Ie, {
|
|
1974
1974
|
key: 1,
|
|
1975
|
-
onClick: s[13] || (s[13] =
|
|
1975
|
+
onClick: s[13] || (s[13] = le((C) => e.callbacks.onAddChildClick(e.vi), ["stop"]))
|
|
1976
1976
|
}, {
|
|
1977
1977
|
prepend: r(() => [
|
|
1978
|
-
i(
|
|
1978
|
+
i(ne, { icon: "mdi-subdirectory-arrow-right" })
|
|
1979
1979
|
]),
|
|
1980
1980
|
default: r(() => [
|
|
1981
|
-
i(
|
|
1981
|
+
i(Re, null, {
|
|
1982
1982
|
default: r(() => [
|
|
1983
|
-
|
|
1983
|
+
G(B(d(n)("common.sortable.addChild")), 1)
|
|
1984
1984
|
]),
|
|
1985
1985
|
_: 1
|
|
1986
1986
|
})
|
|
1987
1987
|
]),
|
|
1988
1988
|
_: 1
|
|
1989
|
-
})) :
|
|
1989
|
+
})) : H("", !0)
|
|
1990
1990
|
]),
|
|
1991
1991
|
_: 1
|
|
1992
1992
|
})
|
|
@@ -1995,27 +1995,27 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
1995
1995
|
})
|
|
1996
1996
|
]),
|
|
1997
1997
|
_: 1
|
|
1998
|
-
})) :
|
|
1998
|
+
})) : H("", !0)
|
|
1999
1999
|
], 64))
|
|
2000
2000
|
])
|
|
2001
2001
|
])
|
|
2002
2002
|
]),
|
|
2003
|
-
e.vi.editing && !e.context.reorderMode && k.$slots.item ? (
|
|
2004
|
-
M("div",
|
|
2003
|
+
e.vi.editing && !e.context.reorderMode && k.$slots.item ? (y(), K(ve, { key: 0 }, [
|
|
2004
|
+
M("div", Dl, [
|
|
2005
2005
|
M("div", El, [
|
|
2006
|
-
z(k.$slots, "item",
|
|
2006
|
+
z(k.$slots, "item", Ve(qe(p())))
|
|
2007
2007
|
])
|
|
2008
2008
|
]),
|
|
2009
|
-
z(k.$slots, "item-footer",
|
|
2010
|
-
e.context.showInlineSaveFooter ? (
|
|
2009
|
+
z(k.$slots, "item-footer", Ve(qe(p())), () => [
|
|
2010
|
+
e.context.showInlineSaveFooter ? (y(), K("div", Tl, [
|
|
2011
2011
|
s[19] || (s[19] = M("div", { class: "a-le-row-footer-spacer" }, null, -1)),
|
|
2012
2012
|
i(_, {
|
|
2013
2013
|
variant: "text",
|
|
2014
2014
|
disabled: e.vi.loading,
|
|
2015
|
-
onClick: s[15] || (s[15] =
|
|
2015
|
+
onClick: s[15] || (s[15] = le((C) => e.callbacks.onCancelClick(e.vi), ["stop"]))
|
|
2016
2016
|
}, {
|
|
2017
2017
|
default: r(() => [
|
|
2018
|
-
|
|
2018
|
+
G(B(d(n)("common.button.cancel")), 1)
|
|
2019
2019
|
]),
|
|
2020
2020
|
_: 1
|
|
2021
2021
|
}, 8, ["disabled"]),
|
|
@@ -2024,32 +2024,32 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2024
2024
|
variant: "flat",
|
|
2025
2025
|
"prepend-icon": "mdi-check",
|
|
2026
2026
|
disabled: e.vi.loading,
|
|
2027
|
-
onClick: s[16] || (s[16] =
|
|
2027
|
+
onClick: s[16] || (s[16] = le((C) => e.callbacks.onSaveClick(e.vi), ["stop"]))
|
|
2028
2028
|
}, {
|
|
2029
2029
|
default: r(() => [
|
|
2030
|
-
|
|
2030
|
+
G(B(d(n)("common.button.save")), 1)
|
|
2031
2031
|
]),
|
|
2032
2032
|
_: 1
|
|
2033
2033
|
}, 8, ["disabled"])
|
|
2034
|
-
])) :
|
|
2034
|
+
])) : H("", !0)
|
|
2035
2035
|
])
|
|
2036
|
-
], 64)) : k.$slots["item-readonly"] && (e.context.readonly || e.vi.expanded) && !e.context.reorderMode ? (
|
|
2037
|
-
M("div",
|
|
2038
|
-
z(k.$slots, "item-readonly",
|
|
2036
|
+
], 64)) : k.$slots["item-readonly"] && (e.context.readonly || e.vi.expanded) && !e.context.reorderMode ? (y(), K("div", $l, [
|
|
2037
|
+
M("div", Fl, [
|
|
2038
|
+
z(k.$slots, "item-readonly", Ve(qe(p())))
|
|
2039
2039
|
])
|
|
2040
|
-
])) :
|
|
2041
|
-
z(k.$slots, "after-item",
|
|
2040
|
+
])) : H("", !0),
|
|
2041
|
+
z(k.$slots, "after-item", Ve(qe(p())))
|
|
2042
2042
|
], 6),
|
|
2043
|
-
e.vi.hasChildren && e.vi.childrenExpanded ? (
|
|
2043
|
+
e.vi.hasChildren && e.vi.childrenExpanded ? (y(), K("div", {
|
|
2044
2044
|
key: 0,
|
|
2045
2045
|
class: "a-nested-list-editor__children",
|
|
2046
|
-
style:
|
|
2046
|
+
style: vt({ "--parent-depth": e.vi.depth })
|
|
2047
2047
|
}, [
|
|
2048
2048
|
M("div", {
|
|
2049
|
-
class:
|
|
2049
|
+
class: xe([Rl]),
|
|
2050
2050
|
"data-parent-id": String(e.vi.key)
|
|
2051
2051
|
}, [
|
|
2052
|
-
(
|
|
2052
|
+
(y(!0), K(ve, null, Ze(b(), (C) => (y(), W(d(u), {
|
|
2053
2053
|
key: String(C.key),
|
|
2054
2054
|
vi: C,
|
|
2055
2055
|
"view-items": e.viewItems,
|
|
@@ -2058,38 +2058,38 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2058
2058
|
callbacks: e.callbacks
|
|
2059
2059
|
}, {
|
|
2060
2060
|
item: r((D) => [
|
|
2061
|
-
z(k.$slots, "item",
|
|
2061
|
+
z(k.$slots, "item", ie({ ref_for: !0 }, D))
|
|
2062
2062
|
]),
|
|
2063
2063
|
"item-compact": r((D) => [
|
|
2064
|
-
z(k.$slots, "item-compact",
|
|
2064
|
+
z(k.$slots, "item-compact", ie({ ref_for: !0 }, D))
|
|
2065
2065
|
]),
|
|
2066
2066
|
"item-readonly": r((D) => [
|
|
2067
|
-
z(k.$slots, "item-readonly",
|
|
2067
|
+
z(k.$slots, "item-readonly", ie({ ref_for: !0 }, D))
|
|
2068
2068
|
]),
|
|
2069
2069
|
"item-status": r((D) => [
|
|
2070
|
-
z(k.$slots, "item-status",
|
|
2070
|
+
z(k.$slots, "item-status", ie({ ref_for: !0 }, D))
|
|
2071
2071
|
]),
|
|
2072
2072
|
"item-footer": r((D) => [
|
|
2073
|
-
z(k.$slots, "item-footer",
|
|
2073
|
+
z(k.$slots, "item-footer", ie({ ref_for: !0 }, D))
|
|
2074
2074
|
]),
|
|
2075
2075
|
"item-actions": r((D) => [
|
|
2076
|
-
z(k.$slots, "item-actions",
|
|
2076
|
+
z(k.$slots, "item-actions", ie({ ref_for: !0 }, D))
|
|
2077
2077
|
]),
|
|
2078
2078
|
"before-item": r((D) => [
|
|
2079
|
-
z(k.$slots, "before-item",
|
|
2079
|
+
z(k.$slots, "before-item", ie({ ref_for: !0 }, D))
|
|
2080
2080
|
]),
|
|
2081
2081
|
"after-item": r((D) => [
|
|
2082
|
-
z(k.$slots, "after-item",
|
|
2082
|
+
z(k.$slots, "after-item", ie({ ref_for: !0 }, D))
|
|
2083
2083
|
]),
|
|
2084
2084
|
_: 3
|
|
2085
2085
|
}, 8, ["vi", "view-items", "drag-state", "context", "callbacks"]))), 128))
|
|
2086
|
-
], 10,
|
|
2087
|
-
], 4)) :
|
|
2088
|
-
], 42,
|
|
2086
|
+
], 10, Bl)
|
|
2087
|
+
], 4)) : H("", !0)
|
|
2088
|
+
], 42, bl));
|
|
2089
2089
|
}
|
|
2090
|
-
}),
|
|
2090
|
+
}), Vl = { class: "text-body-medium mb-2" }, Ll = /* @__PURE__ */ He({
|
|
2091
2091
|
__name: "LeChangeParentDialog",
|
|
2092
|
-
props: /* @__PURE__ */
|
|
2092
|
+
props: /* @__PURE__ */ Le({
|
|
2093
2093
|
tree: {},
|
|
2094
2094
|
sourceKey: {},
|
|
2095
2095
|
keyField: {},
|
|
@@ -2100,152 +2100,152 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2100
2100
|
modelValue: { type: Boolean, required: !0 },
|
|
2101
2101
|
modelModifiers: {}
|
|
2102
2102
|
}),
|
|
2103
|
-
emits: /* @__PURE__ */
|
|
2103
|
+
emits: /* @__PURE__ */ Le(["confirm"], ["update:modelValue"]),
|
|
2104
2104
|
setup(e, { emit: w }) {
|
|
2105
|
-
const
|
|
2106
|
-
Ee(
|
|
2107
|
-
|
|
2105
|
+
const u = e, n = w, f = Ge(e, "modelValue"), { t: h } = Je(), p = ce(void 0), b = ce("last");
|
|
2106
|
+
Ee(f, (A) => {
|
|
2107
|
+
A && (p.value = void 0, b.value = "last");
|
|
2108
2108
|
});
|
|
2109
2109
|
const k = g(() => {
|
|
2110
|
-
const
|
|
2111
|
-
if (
|
|
2110
|
+
const A = /* @__PURE__ */ new Set();
|
|
2111
|
+
if (u.sourceKey === null) return A;
|
|
2112
2112
|
const J = (L) => {
|
|
2113
|
-
for (const
|
|
2114
|
-
if (
|
|
2115
|
-
const
|
|
2116
|
-
for (const
|
|
2117
|
-
|
|
2113
|
+
for (const E of L) {
|
|
2114
|
+
if (E.data[u.keyField] === u.sourceKey) {
|
|
2115
|
+
const se = (X) => {
|
|
2116
|
+
for (const ae of X)
|
|
2117
|
+
A.add(ae.data[u.keyField]), ae.children?.length && se(ae.children);
|
|
2118
2118
|
};
|
|
2119
|
-
return
|
|
2119
|
+
return E.children?.length && se(E.children), !0;
|
|
2120
2120
|
}
|
|
2121
|
-
if (
|
|
2121
|
+
if (E.children?.length && J(E.children)) return !0;
|
|
2122
2122
|
}
|
|
2123
2123
|
return !1;
|
|
2124
2124
|
};
|
|
2125
|
-
return J(
|
|
2125
|
+
return J(u.tree.children), A;
|
|
2126
2126
|
}), s = g(() => {
|
|
2127
|
-
if (
|
|
2128
|
-
const
|
|
2127
|
+
if (u.sourceKey === null) return null;
|
|
2128
|
+
const A = (J) => {
|
|
2129
2129
|
for (const L of J) {
|
|
2130
|
-
if (L.data[
|
|
2130
|
+
if (L.data[u.keyField] === u.sourceKey) return L;
|
|
2131
2131
|
if (L.children?.length) {
|
|
2132
|
-
const
|
|
2133
|
-
if (
|
|
2132
|
+
const E = A(L.children);
|
|
2133
|
+
if (E) return E;
|
|
2134
2134
|
}
|
|
2135
2135
|
}
|
|
2136
2136
|
return null;
|
|
2137
2137
|
};
|
|
2138
|
-
return
|
|
2138
|
+
return A(u.tree.children);
|
|
2139
2139
|
}), C = g(() => {
|
|
2140
|
-
if (
|
|
2141
|
-
const
|
|
2142
|
-
for (const
|
|
2143
|
-
if (
|
|
2144
|
-
if (
|
|
2145
|
-
const ee =
|
|
2140
|
+
if (u.sourceKey === null) return;
|
|
2141
|
+
const A = (J, L) => {
|
|
2142
|
+
for (const E of J) {
|
|
2143
|
+
if (E.data[u.keyField] === u.sourceKey) return L;
|
|
2144
|
+
if (E.children?.length) {
|
|
2145
|
+
const ee = A(E.children, E.data[u.keyField]);
|
|
2146
2146
|
if (ee !== void 0) return ee;
|
|
2147
2147
|
}
|
|
2148
2148
|
}
|
|
2149
2149
|
};
|
|
2150
|
-
return
|
|
2150
|
+
return A(u.tree.children, null);
|
|
2151
2151
|
}), D = g(() => {
|
|
2152
|
-
const
|
|
2153
|
-
|
|
2152
|
+
const A = [], J = s.value ? u.calculateSubtreeDepth(s.value) : 1;
|
|
2153
|
+
A.push({
|
|
2154
2154
|
key: null,
|
|
2155
2155
|
depth: 0,
|
|
2156
|
-
label:
|
|
2157
|
-
hasChildren:
|
|
2156
|
+
label: h("common.sortable.changeParent.rootLabel"),
|
|
2157
|
+
hasChildren: u.tree.children.length > 0,
|
|
2158
2158
|
disallowed: C.value === null,
|
|
2159
2159
|
reason: C.value === null ? "currentParent" : null
|
|
2160
2160
|
});
|
|
2161
|
-
const L = (
|
|
2162
|
-
for (const
|
|
2163
|
-
const
|
|
2164
|
-
let
|
|
2165
|
-
|
|
2166
|
-
key:
|
|
2161
|
+
const L = (E, ee) => {
|
|
2162
|
+
for (const se of E) {
|
|
2163
|
+
const X = se.data[u.keyField];
|
|
2164
|
+
let ae = !1, re = null;
|
|
2165
|
+
X === u.sourceKey ? (ae = !0, re = "self") : k.value.has(X) ? (ae = !0, re = "descendant") : C.value !== void 0 && C.value === X ? (ae = !0, re = "currentParent") : ee + 1 + J > u.maxDepth && (ae = !0, re = "maxDepth"), A.push({
|
|
2166
|
+
key: X,
|
|
2167
2167
|
depth: ee + 1,
|
|
2168
|
-
label:
|
|
2169
|
-
hasChildren: !!(
|
|
2170
|
-
disallowed:
|
|
2171
|
-
reason:
|
|
2172
|
-
}),
|
|
2168
|
+
label: u.resolveLabel(se.data, X),
|
|
2169
|
+
hasChildren: !!(se.children && se.children.length > 0),
|
|
2170
|
+
disallowed: ae,
|
|
2171
|
+
reason: re
|
|
2172
|
+
}), se.children?.length && L(se.children, ee + 1);
|
|
2173
2173
|
}
|
|
2174
2174
|
};
|
|
2175
|
-
return L(
|
|
2176
|
-
}), N = g(() => D.value.filter((
|
|
2177
|
-
() =>
|
|
2175
|
+
return L(u.tree.children, 0), A;
|
|
2176
|
+
}), N = g(() => D.value.filter((A) => !A.disallowed)), V = g(
|
|
2177
|
+
() => p.value === void 0 ? null : D.value.find((A) => A.key === p.value) ?? null
|
|
2178
2178
|
), I = g(
|
|
2179
2179
|
() => !!V.value && V.value.hasChildren
|
|
2180
|
-
),
|
|
2181
|
-
|
|
2180
|
+
), T = (A) => {
|
|
2181
|
+
A.disallowed || (p.value = A.key);
|
|
2182
2182
|
}, j = () => {
|
|
2183
|
-
V.value && (n("confirm", V.value.key, b.value),
|
|
2183
|
+
V.value && (n("confirm", V.value.key, b.value), f.value = !1);
|
|
2184
2184
|
}, R = () => {
|
|
2185
|
-
|
|
2186
|
-
}, $ = (
|
|
2187
|
-
return (
|
|
2188
|
-
modelValue:
|
|
2189
|
-
"onUpdate:modelValue": J[1] || (J[1] = (L) =>
|
|
2185
|
+
f.value = !1;
|
|
2186
|
+
}, $ = (A) => `${A * 16}px`, Y = (A) => A === "maxDepth" ? h("common.sortable.changeParent.errorMaxDepth") : "";
|
|
2187
|
+
return (A, J) => (y(), W(an, {
|
|
2188
|
+
modelValue: f.value,
|
|
2189
|
+
"onUpdate:modelValue": J[1] || (J[1] = (L) => f.value = L),
|
|
2190
2190
|
"max-width": "540",
|
|
2191
2191
|
persistent: ""
|
|
2192
2192
|
}, {
|
|
2193
2193
|
default: r(() => [
|
|
2194
|
-
i(
|
|
2194
|
+
i(nn, null, {
|
|
2195
2195
|
default: r(() => [
|
|
2196
|
-
i(
|
|
2196
|
+
i(la, null, {
|
|
2197
2197
|
default: r(() => [
|
|
2198
|
-
|
|
2198
|
+
G(B(d(h)("common.sortable.changeParent.title")), 1)
|
|
2199
2199
|
]),
|
|
2200
2200
|
_: 1
|
|
2201
2201
|
}),
|
|
2202
|
-
N.value.length === 0 ? (
|
|
2202
|
+
N.value.length === 0 ? (y(), W(Dt, {
|
|
2203
2203
|
key: 0,
|
|
2204
2204
|
class: "text-body-medium"
|
|
2205
2205
|
}, {
|
|
2206
2206
|
default: r(() => [
|
|
2207
|
-
i(
|
|
2207
|
+
i(ln, {
|
|
2208
2208
|
type: "info",
|
|
2209
2209
|
variant: "tonal",
|
|
2210
2210
|
density: "compact"
|
|
2211
2211
|
}, {
|
|
2212
2212
|
default: r(() => [
|
|
2213
|
-
M("strong", null, B(d(
|
|
2214
|
-
M("div", null, B(d(
|
|
2213
|
+
M("strong", null, B(d(h)("common.sortable.changeParent.noTargetsTitle")), 1),
|
|
2214
|
+
M("div", null, B(d(h)("common.sortable.changeParent.noTargetsText")), 1)
|
|
2215
2215
|
]),
|
|
2216
2216
|
_: 1
|
|
2217
2217
|
})
|
|
2218
2218
|
]),
|
|
2219
2219
|
_: 1
|
|
2220
|
-
})) : (
|
|
2221
|
-
i(
|
|
2220
|
+
})) : (y(), K(ve, { key: 1 }, [
|
|
2221
|
+
i(Dt, { class: "pb-1" }, {
|
|
2222
2222
|
default: r(() => [
|
|
2223
|
-
i(
|
|
2223
|
+
i(yt, {
|
|
2224
2224
|
density: "compact",
|
|
2225
2225
|
class: "le-change-parent__list"
|
|
2226
2226
|
}, {
|
|
2227
2227
|
default: r(() => [
|
|
2228
|
-
(
|
|
2228
|
+
(y(!0), K(ve, null, Ze(D.value, (L) => (y(), W(Ie, {
|
|
2229
2229
|
key: L.key === null ? "__root__" : String(L.key),
|
|
2230
2230
|
disabled: L.disallowed,
|
|
2231
|
-
active:
|
|
2231
|
+
active: p.value === L.key,
|
|
2232
2232
|
title: L.label,
|
|
2233
|
-
subtitle:
|
|
2234
|
-
style:
|
|
2233
|
+
subtitle: Y(L.reason),
|
|
2234
|
+
style: vt({ paddingInlineStart: $(L.depth) }),
|
|
2235
2235
|
"data-disallowed": L.disallowed ? "true" : "false",
|
|
2236
2236
|
"data-reason": L.reason ?? "",
|
|
2237
|
-
onClick: (
|
|
2237
|
+
onClick: (E) => T(L)
|
|
2238
2238
|
}, {
|
|
2239
2239
|
prepend: r(() => [
|
|
2240
|
-
L.key === null ? (
|
|
2240
|
+
L.key === null ? (y(), W(ne, {
|
|
2241
2241
|
key: 0,
|
|
2242
2242
|
icon: "mdi-folder-home-outline",
|
|
2243
2243
|
size: "18"
|
|
2244
|
-
})) : L.hasChildren ? (
|
|
2244
|
+
})) : L.hasChildren ? (y(), W(ne, {
|
|
2245
2245
|
key: 1,
|
|
2246
2246
|
icon: "mdi-folder-outline",
|
|
2247
2247
|
size: "18"
|
|
2248
|
-
})) : (
|
|
2248
|
+
})) : (y(), W(ne, {
|
|
2249
2249
|
key: 2,
|
|
2250
2250
|
icon: "mdi-file-outline",
|
|
2251
2251
|
size: "18"
|
|
@@ -2259,45 +2259,45 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2259
2259
|
]),
|
|
2260
2260
|
_: 1
|
|
2261
2261
|
}),
|
|
2262
|
-
I.value ? (
|
|
2262
|
+
I.value ? (y(), W(Dt, {
|
|
2263
2263
|
key: 0,
|
|
2264
2264
|
class: "pt-0"
|
|
2265
2265
|
}, {
|
|
2266
2266
|
default: r(() => [
|
|
2267
|
-
M("div",
|
|
2267
|
+
M("div", Vl, B(d(h)("common.sortable.changeParent.placementHeading", {
|
|
2268
2268
|
label: V.value?.label ?? ""
|
|
2269
2269
|
})), 1),
|
|
2270
|
-
i(
|
|
2270
|
+
i(Co, {
|
|
2271
2271
|
modelValue: b.value,
|
|
2272
2272
|
"onUpdate:modelValue": J[0] || (J[0] = (L) => b.value = L),
|
|
2273
2273
|
density: "compact",
|
|
2274
2274
|
"hide-details": ""
|
|
2275
2275
|
}, {
|
|
2276
2276
|
default: r(() => [
|
|
2277
|
-
i(
|
|
2277
|
+
i(kn, {
|
|
2278
2278
|
value: "first",
|
|
2279
|
-
label: d(
|
|
2279
|
+
label: d(h)("common.sortable.changeParent.placeFirst")
|
|
2280
2280
|
}, null, 8, ["label"]),
|
|
2281
|
-
i(
|
|
2281
|
+
i(kn, {
|
|
2282
2282
|
value: "last",
|
|
2283
|
-
label: d(
|
|
2283
|
+
label: d(h)("common.sortable.changeParent.placeLast")
|
|
2284
2284
|
}, null, 8, ["label"])
|
|
2285
2285
|
]),
|
|
2286
2286
|
_: 1
|
|
2287
2287
|
}, 8, ["modelValue"])
|
|
2288
2288
|
]),
|
|
2289
2289
|
_: 1
|
|
2290
|
-
})) :
|
|
2290
|
+
})) : H("", !0)
|
|
2291
2291
|
], 64)),
|
|
2292
|
-
i(
|
|
2292
|
+
i(ia, null, {
|
|
2293
2293
|
default: r(() => [
|
|
2294
|
-
i(
|
|
2294
|
+
i(on),
|
|
2295
2295
|
i(_, {
|
|
2296
2296
|
variant: "text",
|
|
2297
2297
|
onClick: R
|
|
2298
2298
|
}, {
|
|
2299
2299
|
default: r(() => [
|
|
2300
|
-
|
|
2300
|
+
G(B(d(h)("common.sortable.reorderCancel")), 1)
|
|
2301
2301
|
]),
|
|
2302
2302
|
_: 1
|
|
2303
2303
|
}),
|
|
@@ -2308,7 +2308,7 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2308
2308
|
onClick: j
|
|
2309
2309
|
}, {
|
|
2310
2310
|
default: r(() => [
|
|
2311
|
-
|
|
2311
|
+
G(B(d(h)("common.sortable.changeParent.confirm")), 1)
|
|
2312
2312
|
]),
|
|
2313
2313
|
_: 1
|
|
2314
2314
|
}, 8, ["disabled"])
|
|
@@ -2322,28 +2322,28 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2322
2322
|
_: 1
|
|
2323
2323
|
}, 8, ["modelValue"]));
|
|
2324
2324
|
}
|
|
2325
|
-
}),
|
|
2325
|
+
}), Ml = /* @__PURE__ */ ea(Ll, [["__scopeId", "data-v-0058f5cc"]]), zl = { class: "a-le-card" }, Nl = {
|
|
2326
2326
|
key: 0,
|
|
2327
2327
|
class: "a-le-header"
|
|
2328
|
-
},
|
|
2328
|
+
}, Ol = {
|
|
2329
2329
|
key: 0,
|
|
2330
2330
|
class: "a-le-title-heading"
|
|
2331
|
-
},
|
|
2331
|
+
}, Ul = { class: "a-le-header-actions" }, jl = {
|
|
2332
2332
|
key: 1,
|
|
2333
2333
|
class: "a-le-state a-le-state--loading"
|
|
2334
|
-
},
|
|
2334
|
+
}, ql = {
|
|
2335
2335
|
key: 2,
|
|
2336
2336
|
class: "a-le-state a-le-state--error"
|
|
2337
|
-
},
|
|
2337
|
+
}, Gl = {
|
|
2338
2338
|
key: 3,
|
|
2339
2339
|
class: "a-le-state a-le-state--empty"
|
|
2340
|
-
},
|
|
2340
|
+
}, Hl = {
|
|
2341
2341
|
class: "a-le-sr-only",
|
|
2342
2342
|
"aria-live": "polite",
|
|
2343
2343
|
role: "status"
|
|
2344
|
-
},
|
|
2344
|
+
}, wn = "a-nested-list-editor__group", Jl = "a-le-drag-handle", Cn = 24, xn = 22, Di = /* @__PURE__ */ He({
|
|
2345
2345
|
__name: "ANestedSortableListEditor",
|
|
2346
|
-
props: /* @__PURE__ */
|
|
2346
|
+
props: /* @__PURE__ */ Le({
|
|
2347
2347
|
maxDepth: {},
|
|
2348
2348
|
keyField: { default: "id" },
|
|
2349
2349
|
positionField: { default: "position" },
|
|
@@ -2367,7 +2367,6 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2367
2367
|
getValidationState: { type: Function, default: void 0 },
|
|
2368
2368
|
addLabel: { default: null },
|
|
2369
2369
|
emptyTitle: { default: null },
|
|
2370
|
-
emptyText: { default: null },
|
|
2371
2370
|
disableRowClick: { type: Boolean, default: !1 },
|
|
2372
2371
|
disableDeleteConfirm: { type: Boolean, default: !1 },
|
|
2373
2372
|
deleteConfirmTitle: { default: null },
|
|
@@ -2377,6 +2376,7 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2377
2376
|
showReorderToggle: { type: Boolean, default: !0 },
|
|
2378
2377
|
disableReorder: { type: Boolean, default: !1 },
|
|
2379
2378
|
disableDrag: { type: Boolean, default: !1 },
|
|
2379
|
+
disableUnsaved: { type: Boolean, default: !1 },
|
|
2380
2380
|
onDeleteConfirm: { type: Function, default: void 0 },
|
|
2381
2381
|
onDelete: { type: Function, default: void 0 },
|
|
2382
2382
|
onItemSave: { type: Function, default: void 0 },
|
|
@@ -2391,101 +2391,101 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2391
2391
|
},
|
|
2392
2392
|
unsavedKeysModifiers: {}
|
|
2393
2393
|
}),
|
|
2394
|
-
emits: /* @__PURE__ */
|
|
2395
|
-
setup(e, { expose: w, emit:
|
|
2396
|
-
const n = e,
|
|
2394
|
+
emits: /* @__PURE__ */ Le(["add", "add-child", "edit", "deleted", "close", "item-saved", "item-expand", "reorder-start", "reorder-cancel", "reorder-applied", "reorder-apply-error", "reorder-end", "indent", "outdent"], ["update:modelValue", "update:mode", "update:unsavedKeys"]),
|
|
2395
|
+
setup(e, { expose: w, emit: u }) {
|
|
2396
|
+
const n = e, f = u, h = Ge(e, "modelValue"), p = Ge(e, "mode"), { t: b } = Je(), k = na(), s = tn(), { showWarningT: C } = jn(), D = $t("rootEl"), { isNarrow: N } = lo(D), V = g(() => s.platform.value.touch), I = g(() => n.closeVariant === "icon" ? "icon" : n.closeVariant === "labeled" ? "labeled" : N.value ? "icon" : "labeled"), T = ce(/* @__PURE__ */ new Set()), j = ce(/* @__PURE__ */ new Set());
|
|
2397
2397
|
((t) => {
|
|
2398
2398
|
const l = (a) => {
|
|
2399
|
-
for (const
|
|
2400
|
-
|
|
2399
|
+
for (const x of a)
|
|
2400
|
+
x.children && x.children.length > 0 && (T.value.add(x.data[n.keyField]), l(x.children));
|
|
2401
2401
|
};
|
|
2402
2402
|
l(t.children);
|
|
2403
|
-
})(
|
|
2404
|
-
const $ =
|
|
2403
|
+
})(h.value);
|
|
2404
|
+
const $ = yl(h, {
|
|
2405
2405
|
keyField: n.keyField,
|
|
2406
2406
|
positionField: n.positionField,
|
|
2407
2407
|
parentField: n.parentField,
|
|
2408
2408
|
positionMultiplier: n.positionMultiplier,
|
|
2409
2409
|
maxDepth: n.maxDepth,
|
|
2410
|
-
expandedKeys:
|
|
2411
|
-
}), { captureDirtyBaseline:
|
|
2410
|
+
expandedKeys: T
|
|
2411
|
+
}), { captureDirtyBaseline: Y, rebaselineKey: A, isItemDirty: J, ignoreNextSourceChange: L } = (
|
|
2412
2412
|
// eslint-disable-next-line vue/no-setup-props-reactivity-loss
|
|
2413
|
-
|
|
2413
|
+
qn(
|
|
2414
2414
|
() => {
|
|
2415
2415
|
const t = [], l = (a) => {
|
|
2416
|
-
for (const
|
|
2417
|
-
t.push({ key:
|
|
2416
|
+
for (const x of a)
|
|
2417
|
+
t.push({ key: x.data[n.keyField], data: x.data }), x.children && x.children.length && l(x.children);
|
|
2418
2418
|
};
|
|
2419
|
-
return l(
|
|
2419
|
+
return l(h.value.children), t;
|
|
2420
2420
|
},
|
|
2421
|
-
{ excludeFields: [n.positionField, n.parentField], source:
|
|
2421
|
+
{ excludeFields: [n.positionField, n.parentField], source: h }
|
|
2422
2422
|
)
|
|
2423
|
-
),
|
|
2424
|
-
|
|
2425
|
-
},
|
|
2423
|
+
), E = Xt(null), ee = ce(/* @__PURE__ */ new Set()), se = () => {
|
|
2424
|
+
Y(), ee.value = /* @__PURE__ */ new Set();
|
|
2425
|
+
}, X = (t) => {
|
|
2426
2426
|
const { node: l } = $.findNode(t);
|
|
2427
2427
|
if (!l) {
|
|
2428
2428
|
ee.value.add(t);
|
|
2429
2429
|
return;
|
|
2430
2430
|
}
|
|
2431
|
-
const a = (
|
|
2432
|
-
ee.value.add(
|
|
2431
|
+
const a = (x) => {
|
|
2432
|
+
ee.value.add(x.data[n.keyField]), x.children && x.children.forEach(a);
|
|
2433
2433
|
};
|
|
2434
2434
|
a(l);
|
|
2435
|
-
},
|
|
2435
|
+
}, ae = g(() => {
|
|
2436
2436
|
const t = /* @__PURE__ */ new Set(), l = (a) => {
|
|
2437
|
-
for (const
|
|
2438
|
-
const Z =
|
|
2439
|
-
J(Z,
|
|
2437
|
+
for (const x of a) {
|
|
2438
|
+
const Z = x.data[n.keyField];
|
|
2439
|
+
J(Z, x.data) && t.add(Z), x.children?.length && l(x.children);
|
|
2440
2440
|
}
|
|
2441
2441
|
};
|
|
2442
|
-
return l(
|
|
2443
|
-
}),
|
|
2442
|
+
return l(h.value.children), t;
|
|
2443
|
+
}), re = /* @__PURE__ */ new Map(), P = g(() => {
|
|
2444
2444
|
const t = [], l = /* @__PURE__ */ new Set();
|
|
2445
2445
|
for (const a of $.viewItems.value) {
|
|
2446
2446
|
l.add(a.key);
|
|
2447
|
-
const
|
|
2448
|
-
if (
|
|
2449
|
-
t.push(
|
|
2447
|
+
const x = Q.value.has(a.key), Z = j.value.has(a.key), me = T.value.has(a.key), Ke = n.loadingKeys?.has(a.key) ?? !1, Ne = n.disableUnsaved ? !1 : ee.value.has(a.key), ut = n.disableUnsaved ? !1 : ae.value.has(a.key), ft = ut || Ne, de = re.get(a.key);
|
|
2448
|
+
if (de && de.raw === a.raw && de.index === a.index && de.position === a.position && de.depth === a.depth && de.parentKey === a.parentKey && de.childrenCount === a.childrenCount && de.firstInParent === a.firstInParent && de.lastInParent === a.lastInParent && de.editing === x && de.expanded === Z && de.childrenExpanded === me && de.loading === Ke && de.dirty === ut && de.moved === Ne && de.unsaved === ft) {
|
|
2449
|
+
t.push(de);
|
|
2450
2450
|
continue;
|
|
2451
2451
|
}
|
|
2452
|
-
const
|
|
2452
|
+
const Jt = {
|
|
2453
2453
|
...a,
|
|
2454
|
-
editing:
|
|
2454
|
+
editing: x,
|
|
2455
2455
|
expanded: Z,
|
|
2456
|
-
childrenExpanded:
|
|
2457
|
-
loading:
|
|
2458
|
-
dirty:
|
|
2459
|
-
moved:
|
|
2460
|
-
unsaved:
|
|
2456
|
+
childrenExpanded: me,
|
|
2457
|
+
loading: Ke,
|
|
2458
|
+
dirty: ut,
|
|
2459
|
+
moved: Ne,
|
|
2460
|
+
unsaved: ft
|
|
2461
2461
|
};
|
|
2462
|
-
|
|
2462
|
+
re.set(a.key, Jt), t.push(Jt);
|
|
2463
2463
|
}
|
|
2464
|
-
for (const a of
|
|
2465
|
-
l.has(a) ||
|
|
2464
|
+
for (const a of re.keys())
|
|
2465
|
+
l.has(a) || re.delete(a);
|
|
2466
2466
|
return t;
|
|
2467
|
-
}),
|
|
2467
|
+
}), c = g(() => h.value.children.length === 0), v = g(() => $.viewItems.value.length), S = $t("rowsContainer"), F = g(() => !n.readonly && !n.disabled && !n.loading), O = g(
|
|
2468
2468
|
() => F.value && !n.disableReorder && v.value > 1
|
|
2469
|
-
),
|
|
2470
|
-
editingKeys:
|
|
2471
|
-
editingSnapshots:
|
|
2472
|
-
clearEditing:
|
|
2473
|
-
beginEdit:
|
|
2474
|
-
cancelEdit:
|
|
2475
|
-
commitEdit:
|
|
2476
|
-
closeEdit:
|
|
2477
|
-
requestAutoOpen:
|
|
2478
|
-
} =
|
|
2479
|
-
rowsContainer:
|
|
2469
|
+
), q = g(() => !!k.item), oe = g(() => !!k["item-readonly"]), te = g(() => !!n.onItemSave), {
|
|
2470
|
+
editingKeys: Q,
|
|
2471
|
+
editingSnapshots: ue,
|
|
2472
|
+
clearEditing: ge,
|
|
2473
|
+
beginEdit: Te,
|
|
2474
|
+
cancelEdit: Ae,
|
|
2475
|
+
commitEdit: $e,
|
|
2476
|
+
closeEdit: ye,
|
|
2477
|
+
requestAutoOpen: Fe
|
|
2478
|
+
} = Gn({
|
|
2479
|
+
rowsContainer: S,
|
|
2480
2480
|
rowSelector: ".a-le-row-wrapper",
|
|
2481
|
-
isInlineEdit:
|
|
2481
|
+
isInlineEdit: q,
|
|
2482
2482
|
restoreSnapshot: (t, l) => $.updateItem(t, l),
|
|
2483
2483
|
watchKeys: () => {
|
|
2484
2484
|
const t = [], l = (a) => {
|
|
2485
|
-
for (const
|
|
2486
|
-
t.push(
|
|
2485
|
+
for (const x of a)
|
|
2486
|
+
t.push(x.data[n.keyField]), x.children && x.children.length && l(x.children);
|
|
2487
2487
|
};
|
|
2488
|
-
return l(
|
|
2488
|
+
return l(h.value.children), t;
|
|
2489
2489
|
},
|
|
2490
2490
|
findEntry: (t) => {
|
|
2491
2491
|
const { node: l } = $.findNode(t);
|
|
@@ -2493,360 +2493,357 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2493
2493
|
},
|
|
2494
2494
|
afterAutoOpen: (t) => {
|
|
2495
2495
|
const { parent: l } = $.findNode(t);
|
|
2496
|
-
l &&
|
|
2496
|
+
l && T.value.add(l.data[n.keyField]);
|
|
2497
2497
|
}
|
|
2498
2498
|
}), {
|
|
2499
|
-
applying:
|
|
2500
|
-
applyError:
|
|
2501
|
-
hasPendingChanges:
|
|
2502
|
-
movedCount:
|
|
2503
|
-
reorderMode:
|
|
2504
|
-
enterReorderMode:
|
|
2505
|
-
cancelReorderMode:
|
|
2499
|
+
applying: Se,
|
|
2500
|
+
applyError: _e,
|
|
2501
|
+
hasPendingChanges: Me,
|
|
2502
|
+
movedCount: ht,
|
|
2503
|
+
reorderMode: we,
|
|
2504
|
+
enterReorderMode: et,
|
|
2505
|
+
cancelReorderMode: We,
|
|
2506
2506
|
applyReorder: lt
|
|
2507
|
-
} =
|
|
2508
|
-
mode:
|
|
2509
|
-
snapshot:
|
|
2507
|
+
} = io({
|
|
2508
|
+
mode: p,
|
|
2509
|
+
snapshot: E,
|
|
2510
2510
|
movedKeys: ee,
|
|
2511
|
-
modelValue:
|
|
2512
|
-
cloneModel: (t) =>
|
|
2511
|
+
modelValue: h,
|
|
2512
|
+
cloneModel: (t) => ke(t),
|
|
2513
2513
|
applyModel: (t) => {
|
|
2514
|
-
L(),
|
|
2514
|
+
L(), h.value = t;
|
|
2515
2515
|
},
|
|
2516
|
-
canEnterReorder:
|
|
2516
|
+
canEnterReorder: O,
|
|
2517
2517
|
onEnter: () => {
|
|
2518
|
-
|
|
2519
|
-
for (const t of
|
|
2520
|
-
|
|
2521
|
-
|
|
2518
|
+
ge();
|
|
2519
|
+
for (const t of ze.value) T.value.add(t);
|
|
2520
|
+
Oe(() => {
|
|
2521
|
+
Pe.value && at();
|
|
2522
2522
|
});
|
|
2523
2523
|
},
|
|
2524
2524
|
onExternalEnter: () => {
|
|
2525
|
-
|
|
2525
|
+
ge();
|
|
2526
2526
|
},
|
|
2527
2527
|
onCancel: () => {
|
|
2528
|
-
|
|
2528
|
+
fe();
|
|
2529
2529
|
},
|
|
2530
2530
|
onApplyEnd: () => {
|
|
2531
|
-
|
|
2531
|
+
fe();
|
|
2532
2532
|
},
|
|
2533
2533
|
onReorderApply: (t) => n.onReorderApply?.(t),
|
|
2534
2534
|
emit: {
|
|
2535
|
-
reorderStart: () =>
|
|
2536
|
-
reorderCancel: () =>
|
|
2537
|
-
reorderApplied: (t) =>
|
|
2538
|
-
reorderApplyError: (t) =>
|
|
2539
|
-
reorderEnd: () =>
|
|
2535
|
+
reorderStart: () => f("reorder-start"),
|
|
2536
|
+
reorderCancel: () => f("reorder-cancel"),
|
|
2537
|
+
reorderApplied: (t) => f("reorder-applied", t),
|
|
2538
|
+
reorderApplyError: (t) => f("reorder-apply-error", t),
|
|
2539
|
+
reorderEnd: () => f("reorder-end")
|
|
2540
2540
|
}
|
|
2541
|
-
}),
|
|
2541
|
+
}), Ye = g(() => F.value && n.showAddButton && !we.value), Pe = g(() => we.value && !V.value && !n.disableDrag), it = g(
|
|
2542
2542
|
() => n.addLabel ? b(n.addLabel) : b("common.sortable.add")
|
|
2543
|
-
),
|
|
2543
|
+
), tt = g(() => n.emptyTitle ?? b("common.sortable.emptyTitle")), Xe = g(
|
|
2544
2544
|
() => n.deleteConfirmTitle ?? b("common.sortable.deleteConfirmTitle")
|
|
2545
|
-
),
|
|
2545
|
+
), Rt = g(
|
|
2546
2546
|
() => n.deleteConfirmText ?? b("common.sortable.deleteConfirmText")
|
|
2547
|
-
),
|
|
2548
|
-
() => !n.readonly && n.showReorderToggle && !
|
|
2549
|
-
),
|
|
2547
|
+
), Be = g(
|
|
2548
|
+
() => !n.readonly && n.showReorderToggle && !we.value && v.value > 0
|
|
2549
|
+
), pt = g(() => !!n.title && N.value), ze = g(() => {
|
|
2550
2550
|
const t = [], l = (a) => {
|
|
2551
|
-
for (const
|
|
2552
|
-
|
|
2551
|
+
for (const x of a)
|
|
2552
|
+
x.children && x.children.length > 0 && (t.push(x.data[n.keyField]), l(x.children));
|
|
2553
2553
|
};
|
|
2554
|
-
return l(
|
|
2554
|
+
return l(h.value.children), t;
|
|
2555
2555
|
}), Qe = g(
|
|
2556
|
-
() =>
|
|
2557
|
-
),
|
|
2558
|
-
() => !
|
|
2559
|
-
),
|
|
2556
|
+
() => ze.value.length > 0 && ze.value.every((t) => T.value.has(t))
|
|
2557
|
+
), st = g(
|
|
2558
|
+
() => !we.value && ze.value.length > 0
|
|
2559
|
+
), gt = () => {
|
|
2560
2560
|
if (Qe.value)
|
|
2561
|
-
for (const t of
|
|
2561
|
+
for (const t of ze.value) T.value.delete(t);
|
|
2562
2562
|
else
|
|
2563
|
-
for (const t of
|
|
2563
|
+
for (const t of ze.value) T.value.add(t);
|
|
2564
2564
|
}, o = g(
|
|
2565
|
-
() => !!(n.title || k.header || k["reorder-toggle"] ||
|
|
2566
|
-
),
|
|
2567
|
-
for (const t of
|
|
2565
|
+
() => !!(n.title || k.header || k["reorder-toggle"] || Be.value || st.value || we.value)
|
|
2566
|
+
), U = ce([]), m = ce(0), fe = () => {
|
|
2567
|
+
for (const t of U.value)
|
|
2568
2568
|
try {
|
|
2569
2569
|
t.stop();
|
|
2570
2570
|
} catch {
|
|
2571
2571
|
}
|
|
2572
|
-
|
|
2573
|
-
},
|
|
2572
|
+
U.value = [];
|
|
2573
|
+
}, be = ce(null), bt = (t, l) => {
|
|
2574
2574
|
const a = document.elementFromPoint(t, l);
|
|
2575
2575
|
if (!a) return null;
|
|
2576
|
-
const
|
|
2577
|
-
if (!
|
|
2578
|
-
const Z =
|
|
2576
|
+
const x = a.closest(".a-le-row-wrapper");
|
|
2577
|
+
if (!x || !S.value || !S.value.contains(x)) return null;
|
|
2578
|
+
const Z = sn(x.getAttribute("data-id"));
|
|
2579
2579
|
if (Z === null) return null;
|
|
2580
|
-
const
|
|
2581
|
-
return
|
|
2582
|
-
},
|
|
2583
|
-
if (!
|
|
2584
|
-
const a =
|
|
2580
|
+
const me = P.value.find((Ke) => Ke.key === Z);
|
|
2581
|
+
return me ? { el: x, viewItem: me } : null;
|
|
2582
|
+
}, nt = (t, l) => {
|
|
2583
|
+
if (!be.value || !S.value) return;
|
|
2584
|
+
const a = bt(t, l);
|
|
2585
2585
|
if (!a) {
|
|
2586
|
-
|
|
2586
|
+
be.value.instruction = null;
|
|
2587
2587
|
return;
|
|
2588
2588
|
}
|
|
2589
|
-
const
|
|
2590
|
-
|
|
2589
|
+
const x = S.value.getBoundingClientRect(), me = (a.el.querySelector(":scope > .a-le-row") ?? a.el).getBoundingClientRect();
|
|
2590
|
+
be.value.instruction = gl({
|
|
2591
2591
|
pointer: { x: t, y: l },
|
|
2592
2592
|
hoveredRow: {
|
|
2593
2593
|
key: a.viewItem.key,
|
|
2594
|
-
rect:
|
|
2594
|
+
rect: me,
|
|
2595
2595
|
depth: a.viewItem.depth,
|
|
2596
2596
|
parentKey: a.viewItem.parentKey,
|
|
2597
2597
|
siblingIndex: a.viewItem.siblingIndex,
|
|
2598
2598
|
siblingCount: a.viewItem.siblingCount
|
|
2599
2599
|
},
|
|
2600
|
-
sourceKey:
|
|
2601
|
-
sourceSubtreeDepth:
|
|
2600
|
+
sourceKey: be.value.sourceKey,
|
|
2601
|
+
sourceSubtreeDepth: be.value.sourceSubtreeDepth,
|
|
2602
2602
|
viewItems: P.value,
|
|
2603
2603
|
maxDepth: n.maxDepth,
|
|
2604
|
-
indentPx:
|
|
2605
|
-
containerLeft:
|
|
2606
|
-
containerPaddingLeft:
|
|
2604
|
+
indentPx: Cn,
|
|
2605
|
+
containerLeft: x.left,
|
|
2606
|
+
containerPaddingLeft: xn
|
|
2607
2607
|
});
|
|
2608
|
-
},
|
|
2609
|
-
|
|
2610
|
-
},
|
|
2608
|
+
}, Ce = (t) => {
|
|
2609
|
+
nt(t.clientX, t.clientY);
|
|
2610
|
+
}, kt = (t, l) => {
|
|
2611
2611
|
if ($.moveTo(l, t.parentKey, t.index) === null) {
|
|
2612
|
-
C("common.sortable.error.maxDeepExceed"),
|
|
2612
|
+
C("common.sortable.error.maxDeepExceed"), m.value++, Oe(() => at());
|
|
2613
2613
|
return;
|
|
2614
2614
|
}
|
|
2615
|
-
|
|
2616
|
-
},
|
|
2617
|
-
if (
|
|
2618
|
-
const t = Array.from(
|
|
2615
|
+
X(l), t.makeChild && t.parentKey !== null && T.value.add(t.parentKey);
|
|
2616
|
+
}, at = () => {
|
|
2617
|
+
if (fe(), !Pe.value || !S.value) return;
|
|
2618
|
+
const t = Array.from(S.value.querySelectorAll("." + wn));
|
|
2619
2619
|
for (const l of t) {
|
|
2620
|
-
const a =
|
|
2620
|
+
const a = co(l, [], {
|
|
2621
2621
|
group: { name: "a-nested", pull: !0, put: !0 },
|
|
2622
|
-
handle: "." +
|
|
2622
|
+
handle: "." + Jl,
|
|
2623
2623
|
animation: 0,
|
|
2624
|
-
ghostClass:
|
|
2625
|
-
chosenClass:
|
|
2626
|
-
dragClass:
|
|
2624
|
+
ghostClass: mo,
|
|
2625
|
+
chosenClass: fo,
|
|
2626
|
+
dragClass: uo,
|
|
2627
2627
|
fallbackOnBody: !0,
|
|
2628
2628
|
forceFallback: !0,
|
|
2629
2629
|
fallbackTolerance: 3,
|
|
2630
|
-
onStart: (
|
|
2631
|
-
const Z =
|
|
2632
|
-
if (
|
|
2633
|
-
const
|
|
2634
|
-
|
|
2635
|
-
sourceKey:
|
|
2636
|
-
sourceSubtreeDepth:
|
|
2630
|
+
onStart: (x) => {
|
|
2631
|
+
const Z = x.item, me = sn(Z.getAttribute("data-id"));
|
|
2632
|
+
if (me === null) return;
|
|
2633
|
+
const Ke = $.findNode(me).node, Ne = Ke ? $.calculateSubtreeDepth(Ke) : 1;
|
|
2634
|
+
be.value = {
|
|
2635
|
+
sourceKey: me,
|
|
2636
|
+
sourceSubtreeDepth: Ne,
|
|
2637
2637
|
instruction: null
|
|
2638
|
-
}, document.addEventListener("pointermove",
|
|
2638
|
+
}, document.addEventListener("pointermove", Ce, { passive: !0 });
|
|
2639
2639
|
},
|
|
2640
|
-
onMove: (
|
|
2641
|
-
const Z =
|
|
2640
|
+
onMove: (x) => {
|
|
2641
|
+
const Z = x.originalEvent;
|
|
2642
2642
|
if (Z) {
|
|
2643
2643
|
if ("clientX" in Z && "clientY" in Z)
|
|
2644
|
-
|
|
2644
|
+
nt(Z.clientX, Z.clientY);
|
|
2645
2645
|
else if ("touches" in Z) {
|
|
2646
|
-
const
|
|
2647
|
-
|
|
2646
|
+
const me = Z;
|
|
2647
|
+
me.touches.length > 0 && nt(me.touches[0].clientX, me.touches[0].clientY);
|
|
2648
2648
|
}
|
|
2649
2649
|
}
|
|
2650
2650
|
return !1;
|
|
2651
2651
|
},
|
|
2652
2652
|
onEnd: () => {
|
|
2653
|
-
document.removeEventListener("pointermove",
|
|
2654
|
-
const
|
|
2655
|
-
if (
|
|
2656
|
-
const Z =
|
|
2657
|
-
Z !== null && Z.type !== "blocked" &&
|
|
2653
|
+
document.removeEventListener("pointermove", Ce);
|
|
2654
|
+
const x = be.value;
|
|
2655
|
+
if (be.value = null, !x) return;
|
|
2656
|
+
const Z = x.instruction;
|
|
2657
|
+
Z !== null && Z.type !== "blocked" && kt(Z, x.sourceKey);
|
|
2658
2658
|
}
|
|
2659
2659
|
});
|
|
2660
|
-
|
|
2660
|
+
U.value.push(a);
|
|
2661
2661
|
}
|
|
2662
|
-
},
|
|
2662
|
+
}, sn = (t) => {
|
|
2663
2663
|
if (t === null || t === "") return null;
|
|
2664
|
-
const l =
|
|
2664
|
+
const l = vo(t);
|
|
2665
2665
|
return l > 0 ? l : t;
|
|
2666
2666
|
};
|
|
2667
2667
|
Ee(
|
|
2668
|
-
() =>
|
|
2668
|
+
() => Pe.value,
|
|
2669
2669
|
() => {
|
|
2670
|
-
|
|
2670
|
+
Pe.value ? Oe(() => at()) : fe();
|
|
2671
2671
|
}
|
|
2672
2672
|
), Ee(
|
|
2673
|
-
() =>
|
|
2673
|
+
() => m.value,
|
|
2674
2674
|
() => {
|
|
2675
|
-
|
|
2675
|
+
Pe.value && Oe(() => at());
|
|
2676
2676
|
}
|
|
2677
2677
|
), Ee(
|
|
2678
2678
|
() => P.value.map((t) => t.key).join("|"),
|
|
2679
2679
|
() => {
|
|
2680
|
-
|
|
2680
|
+
Pe.value && Oe(() => at());
|
|
2681
2681
|
}
|
|
2682
|
-
),
|
|
2683
|
-
|
|
2684
|
-
}),
|
|
2685
|
-
|
|
2682
|
+
), Zt(() => {
|
|
2683
|
+
Pe.value && at();
|
|
2684
|
+
}), _t(() => {
|
|
2685
|
+
fe(), document.removeEventListener("pointermove", Ce);
|
|
2686
2686
|
});
|
|
2687
|
-
const
|
|
2688
|
-
const t =
|
|
2689
|
-
if (!t || t.instruction === null || !
|
|
2687
|
+
const je = g(() => {
|
|
2688
|
+
const t = be.value;
|
|
2689
|
+
if (!t || t.instruction === null || !S.value) return null;
|
|
2690
2690
|
const l = t.instruction;
|
|
2691
2691
|
if (l.type === "blocked") return null;
|
|
2692
|
-
const a =
|
|
2692
|
+
const a = S.value.querySelector(
|
|
2693
2693
|
`.a-le-row-wrapper[data-id="${CSS.escape(String(l.refKey))}"]`
|
|
2694
2694
|
);
|
|
2695
2695
|
if (!a) return null;
|
|
2696
|
-
const
|
|
2697
|
-
let
|
|
2696
|
+
const x = a.querySelector(":scope > .a-le-row"), Z = S.value.getBoundingClientRect(), me = (x ?? a).getBoundingClientRect(), Ke = xn + l.depth * Cn, Ne = l.refEdge === "top" ? me.top - Z.top : me.bottom - Z.top, ut = { top: Ne, left: Ke, right: 16 };
|
|
2697
|
+
let ft = null;
|
|
2698
2698
|
if (l.levelRowKey !== null) {
|
|
2699
|
-
const
|
|
2699
|
+
const de = S.value.querySelector(
|
|
2700
2700
|
`.a-le-row-wrapper[data-id="${CSS.escape(String(l.levelRowKey))}"]`
|
|
2701
2701
|
);
|
|
2702
|
-
if (
|
|
2703
|
-
const
|
|
2704
|
-
|
|
2705
|
-
top:
|
|
2706
|
-
height:
|
|
2707
|
-
left:
|
|
2702
|
+
if (de) {
|
|
2703
|
+
const pn = (de.querySelector(":scope > .a-le-row") ?? de).getBoundingClientRect(), Wt = pn.top - Z.top + pn.height / 2;
|
|
2704
|
+
Wt < Ne && (ft = {
|
|
2705
|
+
top: Wt,
|
|
2706
|
+
height: Ne - Wt,
|
|
2707
|
+
left: Ke
|
|
2708
2708
|
});
|
|
2709
2709
|
}
|
|
2710
2710
|
}
|
|
2711
|
-
return { line:
|
|
2712
|
-
}),
|
|
2713
|
-
|
|
2711
|
+
return { line: ut, connector: ft };
|
|
2712
|
+
}), rt = () => {
|
|
2713
|
+
Ye.value && (Fe(), f("add", void 0));
|
|
2714
|
+
}, rn = (t) => {
|
|
2715
|
+
F.value && (Fe(), f("add", { afterId: t.key, childrenAllowed: t.childrenAllowed }));
|
|
2714
2716
|
}, dn = (t) => {
|
|
2715
|
-
F.value && (
|
|
2716
|
-
},
|
|
2717
|
-
F.value
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
if (se.value.has(t.key)) {
|
|
2721
|
-
ct(t);
|
|
2717
|
+
F.value && t.canAddChild && (Fe(), T.value.add(t.key), f("add-child", t), f("add", { parentId: t.key, childrenAllowed: !0 }));
|
|
2718
|
+
}, wt = (t) => {
|
|
2719
|
+
if (!(!F.value || we.value)) {
|
|
2720
|
+
if (Q.value.has(t.key)) {
|
|
2721
|
+
dt(t);
|
|
2722
2722
|
return;
|
|
2723
2723
|
}
|
|
2724
|
-
|
|
2724
|
+
q.value && Te(t), f("edit", t);
|
|
2725
2725
|
}
|
|
2726
|
-
},
|
|
2726
|
+
}, Kt = (t) => {
|
|
2727
2727
|
if (n.disabled || n.loading) return;
|
|
2728
|
-
const l = t.key, a =
|
|
2729
|
-
a ?
|
|
2730
|
-
},
|
|
2728
|
+
const l = t.key, a = T.value.has(l);
|
|
2729
|
+
a ? T.value.delete(l) : T.value.add(l), f("item-expand", t, !a);
|
|
2730
|
+
}, cn = (t) => {
|
|
2731
2731
|
if (n.disabled || n.loading) return;
|
|
2732
2732
|
const l = t.key, a = j.value.has(l);
|
|
2733
|
-
a ? j.value.delete(l) : j.value.add(l),
|
|
2734
|
-
},
|
|
2735
|
-
if (
|
|
2733
|
+
a ? j.value.delete(l) : j.value.add(l), f("item-expand", t, !a);
|
|
2734
|
+
}, un = (t) => n.disableRowClick || n.disabled || n.loading || we.value ? !1 : !!(t.editing || t.expanded || !n.readonly && n.showEditButton), ua = (t) => {
|
|
2735
|
+
if (un(t)) {
|
|
2736
2736
|
if (t.editing || t.expanded) {
|
|
2737
|
-
|
|
2737
|
+
dt(t);
|
|
2738
2738
|
return;
|
|
2739
2739
|
}
|
|
2740
|
-
n.readonly &&
|
|
2740
|
+
n.readonly && oe.value ? cn(t) : wt(t);
|
|
2741
2741
|
}
|
|
2742
2742
|
}, {
|
|
2743
|
-
deleteDialog:
|
|
2744
|
-
deleteInFlight:
|
|
2745
|
-
deleteError:
|
|
2746
|
-
onDeleteClick:
|
|
2747
|
-
onDeleteDialogConfirm:
|
|
2748
|
-
onDeleteDialogCancel:
|
|
2749
|
-
} =
|
|
2743
|
+
deleteDialog: Vt,
|
|
2744
|
+
deleteInFlight: fa,
|
|
2745
|
+
deleteError: ma,
|
|
2746
|
+
onDeleteClick: va,
|
|
2747
|
+
onDeleteDialogConfirm: ya,
|
|
2748
|
+
onDeleteDialogCancel: ha
|
|
2749
|
+
} = Wn({
|
|
2750
2750
|
onDeleteConfirm: (t) => n.onDeleteConfirm ? n.onDeleteConfirm(t) : !0,
|
|
2751
2751
|
onDelete: (t) => n.onDelete?.(t),
|
|
2752
2752
|
onDeleted: (t) => {
|
|
2753
|
-
|
|
2753
|
+
Q.value.delete(t.key), ue.value.delete(t.key), j.value.delete(t.key), T.value.delete(t.key), f("deleted", t);
|
|
2754
2754
|
},
|
|
2755
2755
|
disableDeleteConfirm: () => n.disableDeleteConfirm
|
|
2756
|
-
}),
|
|
2757
|
-
F.value && await
|
|
2758
|
-
},
|
|
2759
|
-
n.onItemSave && await n.onItemSave(t.raw),
|
|
2760
|
-
},
|
|
2761
|
-
|
|
2762
|
-
},
|
|
2763
|
-
|
|
2756
|
+
}), fn = async (t) => {
|
|
2757
|
+
F.value && await va(t);
|
|
2758
|
+
}, mn = async (t) => {
|
|
2759
|
+
n.onItemSave && await n.onItemSave(t.raw), $e(t), f("item-saved", t);
|
|
2760
|
+
}, vn = (t) => {
|
|
2761
|
+
Ae(t);
|
|
2762
|
+
}, dt = (t) => {
|
|
2763
|
+
ye(t), f("close", t);
|
|
2764
|
+
}, Lt = (t) => {
|
|
2765
|
+
$.moveUp(t) && X(t);
|
|
2764
2766
|
}, Mt = (t) => {
|
|
2765
|
-
$.
|
|
2767
|
+
$.moveDown(t) && X(t);
|
|
2766
2768
|
}, zt = (t) => {
|
|
2767
|
-
$.
|
|
2769
|
+
$.moveTop(t) && X(t);
|
|
2768
2770
|
}, Nt = (t) => {
|
|
2769
|
-
$.
|
|
2771
|
+
$.moveBottom(t) && X(t);
|
|
2770
2772
|
}, Ot = (t) => {
|
|
2771
|
-
$.moveBottom(t) && Q(t);
|
|
2772
|
-
}, Ut = (t) => {
|
|
2773
2773
|
if ($.indent(t.key) === null) {
|
|
2774
2774
|
C("common.sortable.error.maxDeepExceed");
|
|
2775
2775
|
return;
|
|
2776
2776
|
}
|
|
2777
|
-
|
|
2778
|
-
},
|
|
2779
|
-
$.outdent(t.key) !== null && (
|
|
2780
|
-
},
|
|
2781
|
-
compactField: n.compactField,
|
|
2782
|
-
fallback: b("common.sortable.itemFallback")
|
|
2783
|
-
}), { resolveValidation: hn } = Wn({
|
|
2777
|
+
X(t.key), f("indent", t);
|
|
2778
|
+
}, Ut = (t) => {
|
|
2779
|
+
$.outdent(t.key) !== null && (X(t.key), f("outdent", t));
|
|
2780
|
+
}, jt = (t) => _n(t, { compactField: n.compactField }), { resolveValidation: yn } = Jn({
|
|
2784
2781
|
getValidationState: (t, l, a) => n.getValidationState?.(t, l, a) ?? null
|
|
2785
|
-
}),
|
|
2786
|
-
let l =
|
|
2782
|
+
}), ct = /* @__PURE__ */ new Map(), pa = (t) => {
|
|
2783
|
+
let l = ct.get(t);
|
|
2787
2784
|
return l || (l = {
|
|
2788
2785
|
edit: () => {
|
|
2789
2786
|
const a = he(t);
|
|
2790
|
-
a &&
|
|
2787
|
+
a && wt(a);
|
|
2791
2788
|
},
|
|
2792
2789
|
save: () => {
|
|
2793
2790
|
const a = he(t);
|
|
2794
|
-
if (a) return
|
|
2791
|
+
if (a) return mn(a);
|
|
2795
2792
|
},
|
|
2796
2793
|
cancel: () => {
|
|
2797
2794
|
const a = he(t);
|
|
2798
|
-
a &&
|
|
2795
|
+
a && vn(a);
|
|
2799
2796
|
},
|
|
2800
2797
|
close: () => {
|
|
2801
2798
|
const a = he(t);
|
|
2802
|
-
a &&
|
|
2799
|
+
a && dt(a);
|
|
2803
2800
|
},
|
|
2804
2801
|
delete: async () => {
|
|
2805
2802
|
const a = he(t);
|
|
2806
|
-
a && await
|
|
2803
|
+
a && await fn(a);
|
|
2807
2804
|
},
|
|
2808
2805
|
addAfter: () => {
|
|
2809
2806
|
const a = he(t);
|
|
2810
|
-
a &&
|
|
2807
|
+
a && rn(a);
|
|
2811
2808
|
},
|
|
2812
2809
|
addChild: () => {
|
|
2813
2810
|
const a = he(t);
|
|
2814
|
-
a &&
|
|
2811
|
+
a && dn(a);
|
|
2815
2812
|
},
|
|
2816
2813
|
toggleExpand: () => {
|
|
2817
2814
|
const a = he(t);
|
|
2818
|
-
a &&
|
|
2815
|
+
a && Kt(a);
|
|
2819
2816
|
},
|
|
2820
2817
|
toggleDetail: () => {
|
|
2821
2818
|
const a = he(t);
|
|
2822
|
-
a &&
|
|
2819
|
+
a && cn(a);
|
|
2823
2820
|
},
|
|
2824
|
-
moveUp: () =>
|
|
2825
|
-
moveDown: () =>
|
|
2826
|
-
moveTop: () =>
|
|
2827
|
-
moveBottom: () =>
|
|
2821
|
+
moveUp: () => Lt(t),
|
|
2822
|
+
moveDown: () => Mt(t),
|
|
2823
|
+
moveTop: () => zt(t),
|
|
2824
|
+
moveBottom: () => Nt(t),
|
|
2828
2825
|
indent: () => {
|
|
2829
2826
|
const a = he(t);
|
|
2830
|
-
a &&
|
|
2827
|
+
a && Ot(a);
|
|
2831
2828
|
},
|
|
2832
2829
|
outdent: () => {
|
|
2833
2830
|
const a = he(t);
|
|
2834
|
-
a &&
|
|
2831
|
+
a && Ut(a);
|
|
2835
2832
|
},
|
|
2836
2833
|
update: (a) => $.updateItem(t, a)
|
|
2837
|
-
},
|
|
2834
|
+
}, ct.set(t, l)), l;
|
|
2838
2835
|
};
|
|
2839
2836
|
Ee(
|
|
2840
2837
|
() => P.value,
|
|
2841
2838
|
(t) => {
|
|
2842
|
-
if (
|
|
2839
|
+
if (ct.size === 0) return;
|
|
2843
2840
|
const l = new Set(t.map((a) => a.key));
|
|
2844
|
-
for (const a of
|
|
2845
|
-
l.has(a) ||
|
|
2841
|
+
for (const a of ct.keys())
|
|
2842
|
+
l.has(a) || ct.delete(a);
|
|
2846
2843
|
}
|
|
2847
2844
|
);
|
|
2848
|
-
const
|
|
2849
|
-
item: { ...t, validationState:
|
|
2845
|
+
const ga = (t) => ({
|
|
2846
|
+
item: { ...t, validationState: yn(t.raw, t.key, t.index) },
|
|
2850
2847
|
raw: t.raw,
|
|
2851
2848
|
index: t.index,
|
|
2852
2849
|
key: t.key,
|
|
@@ -2866,100 +2863,100 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2866
2863
|
dirty: t.dirty,
|
|
2867
2864
|
unsaved: t.unsaved,
|
|
2868
2865
|
moved: t.moved,
|
|
2869
|
-
reorderMode:
|
|
2866
|
+
reorderMode: we.value,
|
|
2870
2867
|
canMoveUp: !t.firstInParent,
|
|
2871
2868
|
canMoveDown: !t.lastInParent,
|
|
2872
2869
|
canIndent: t.canIndent,
|
|
2873
2870
|
canOutdent: t.canOutdent,
|
|
2874
2871
|
canAddChild: t.canAddChild,
|
|
2875
2872
|
touch: V.value,
|
|
2876
|
-
actions:
|
|
2877
|
-
}),
|
|
2878
|
-
applying:
|
|
2879
|
-
hasPendingChanges:
|
|
2880
|
-
movedCount:
|
|
2881
|
-
error:
|
|
2873
|
+
actions: pa(t.key)
|
|
2874
|
+
}), ba = g(() => ({
|
|
2875
|
+
applying: Se.value,
|
|
2876
|
+
hasPendingChanges: Me.value,
|
|
2877
|
+
movedCount: ht.value,
|
|
2878
|
+
error: _e.value,
|
|
2882
2879
|
actions: {
|
|
2883
2880
|
apply: lt,
|
|
2884
|
-
cancel:
|
|
2881
|
+
cancel: We
|
|
2885
2882
|
}
|
|
2886
|
-
})),
|
|
2887
|
-
mode:
|
|
2888
|
-
disabled: !
|
|
2889
|
-
hasPendingChanges:
|
|
2883
|
+
})), hn = g(() => ({
|
|
2884
|
+
mode: p.value,
|
|
2885
|
+
disabled: !O.value,
|
|
2886
|
+
hasPendingChanges: Me.value,
|
|
2890
2887
|
actions: {
|
|
2891
|
-
enterReorderMode:
|
|
2892
|
-
exitReorderMode:
|
|
2888
|
+
enterReorderMode: et,
|
|
2889
|
+
exitReorderMode: We
|
|
2893
2890
|
}
|
|
2894
|
-
})),
|
|
2891
|
+
})), ka = g(() => new Set(ze.value)), he = (t) => P.value.find((l) => l.key === t), Ct = Hn({
|
|
2895
2892
|
viewItems: g(
|
|
2896
2893
|
() => P.value.map((t) => ({
|
|
2897
2894
|
key: t.key,
|
|
2898
2895
|
expanded: t.childrenExpanded,
|
|
2899
|
-
canExpand:
|
|
2896
|
+
canExpand: ka.value.has(t.key),
|
|
2900
2897
|
canIndent: !0,
|
|
2901
2898
|
canOutdent: !0
|
|
2902
2899
|
}))
|
|
2903
2900
|
),
|
|
2904
2901
|
variant: "nested",
|
|
2905
|
-
isReorderMode:
|
|
2902
|
+
isReorderMode: we,
|
|
2906
2903
|
disabled: g(() => !F.value),
|
|
2907
|
-
isEditing: (t) =>
|
|
2904
|
+
isEditing: (t) => Q.value.has(t),
|
|
2908
2905
|
onToggleEdit: (t) => {
|
|
2909
2906
|
const l = he(t);
|
|
2910
|
-
l &&
|
|
2907
|
+
l && wt(l);
|
|
2911
2908
|
},
|
|
2912
2909
|
onCancelEdit: (t) => {
|
|
2913
2910
|
const l = he(t);
|
|
2914
|
-
l &&
|
|
2911
|
+
l && dt(l);
|
|
2915
2912
|
},
|
|
2916
|
-
onMoveUp: (t) =>
|
|
2917
|
-
onMoveDown: (t) =>
|
|
2918
|
-
onMoveTop: (t) =>
|
|
2919
|
-
onMoveBottom: (t) =>
|
|
2913
|
+
onMoveUp: (t) => Lt(t),
|
|
2914
|
+
onMoveDown: (t) => Mt(t),
|
|
2915
|
+
onMoveTop: (t) => zt(t),
|
|
2916
|
+
onMoveBottom: (t) => Nt(t),
|
|
2920
2917
|
onIndent: (t) => {
|
|
2921
2918
|
const l = he(t);
|
|
2922
|
-
l &&
|
|
2919
|
+
l && Ot(l);
|
|
2923
2920
|
},
|
|
2924
2921
|
onOutdent: (t) => {
|
|
2925
2922
|
const l = he(t);
|
|
2926
|
-
l &&
|
|
2923
|
+
l && Ut(l);
|
|
2927
2924
|
},
|
|
2928
2925
|
onToggleChildren: (t) => {
|
|
2929
2926
|
const l = he(t);
|
|
2930
|
-
l &&
|
|
2927
|
+
l && Kt(l);
|
|
2931
2928
|
},
|
|
2932
|
-
onCancelReorder: () =>
|
|
2933
|
-
}),
|
|
2934
|
-
const t =
|
|
2929
|
+
onCancelReorder: () => We()
|
|
2930
|
+
}), qt = ce(!1), ot = Xt(null), Gt = g(() => {
|
|
2931
|
+
const t = ot.value;
|
|
2935
2932
|
if (!t) return null;
|
|
2936
|
-
const l = $.findNode(t.key), a = l.parent?.children ??
|
|
2933
|
+
const l = $.findNode(t.key), a = l.parent?.children ?? h.value.children, x = a.findIndex((Z) => Z.data[n.keyField] === t.key);
|
|
2937
2934
|
return {
|
|
2938
2935
|
parentId: l.parent ? l.parent.data[n.keyField] : null,
|
|
2939
2936
|
total: a.length,
|
|
2940
|
-
currentIndex:
|
|
2937
|
+
currentIndex: x
|
|
2941
2938
|
};
|
|
2942
|
-
}),
|
|
2943
|
-
() =>
|
|
2944
|
-
),
|
|
2945
|
-
n.showMoveToPosition && (
|
|
2946
|
-
},
|
|
2947
|
-
const l =
|
|
2948
|
-
|
|
2949
|
-
},
|
|
2950
|
-
n.showChangeParent && (
|
|
2951
|
-
},
|
|
2952
|
-
const a =
|
|
2953
|
-
if (
|
|
2954
|
-
let
|
|
2955
|
-
t === null ?
|
|
2956
|
-
const Z = l === "first" ? 0 :
|
|
2957
|
-
$.moveTo(a.key, t, Z) && (
|
|
2958
|
-
},
|
|
2959
|
-
reorderMode:
|
|
2939
|
+
}), wa = g(
|
|
2940
|
+
() => ot.value ? jt(ot.value.raw) : ""
|
|
2941
|
+
), Ca = (t) => {
|
|
2942
|
+
n.showMoveToPosition && (ot.value = t, qt.value = !0);
|
|
2943
|
+
}, xa = (t) => {
|
|
2944
|
+
const l = Gt.value, a = ot.value;
|
|
2945
|
+
ot.value = null, !(!l || !a) && t !== l.currentIndex && $.moveTo(a.key, l.parentId, t) && X(a.key);
|
|
2946
|
+
}, Ht = ce(!1), xt = Xt(null), Aa = (t) => {
|
|
2947
|
+
n.showChangeParent && (xt.value = t, Ht.value = !0);
|
|
2948
|
+
}, Sa = (t, l) => {
|
|
2949
|
+
const a = xt.value;
|
|
2950
|
+
if (xt.value = null, !a) return;
|
|
2951
|
+
let x = 0;
|
|
2952
|
+
t === null ? x = h.value.children.length : x = $.findNode(t).node?.children?.length ?? 0;
|
|
2953
|
+
const Z = l === "first" ? 0 : x;
|
|
2954
|
+
$.moveTo(a.key, t, Z) && (X(a.key), t !== null && T.value.add(t));
|
|
2955
|
+
}, Pa = g(() => ({
|
|
2956
|
+
reorderMode: we.value,
|
|
2960
2957
|
readonly: n.readonly,
|
|
2961
2958
|
canInteract: F.value,
|
|
2962
|
-
dragEnabled:
|
|
2959
|
+
dragEnabled: Pe.value,
|
|
2963
2960
|
showExpandToggle: n.showExpandToggle,
|
|
2964
2961
|
showEditButton: n.showEditButton,
|
|
2965
2962
|
showDeleteButton: n.showDeleteButton,
|
|
@@ -2967,64 +2964,64 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
2967
2964
|
showAddAfterAction: n.showAddAfterAction,
|
|
2968
2965
|
showMoveToPosition: n.showMoveToPosition,
|
|
2969
2966
|
showChangeParent: n.showChangeParent,
|
|
2970
|
-
showInlineSaveFooter:
|
|
2967
|
+
showInlineSaveFooter: te.value,
|
|
2971
2968
|
statusField: n.statusField,
|
|
2972
2969
|
effectiveCloseVariant: I.value,
|
|
2973
|
-
keyboardNav:
|
|
2974
|
-
isRowClickable:
|
|
2975
|
-
resolveCompactText:
|
|
2976
|
-
resolveValidation: (t, l, a) =>
|
|
2977
|
-
buildSlotProps:
|
|
2978
|
-
})),
|
|
2979
|
-
onRowClick:
|
|
2980
|
-
onChevronClick:
|
|
2981
|
-
onEditClick:
|
|
2982
|
-
onDeleteClick:
|
|
2983
|
-
onCloseClick:
|
|
2984
|
-
onSaveClick:
|
|
2985
|
-
onCancelClick:
|
|
2986
|
-
onAddAfterClick:
|
|
2987
|
-
onAddChildClick:
|
|
2988
|
-
moveUp: (t) =>
|
|
2989
|
-
moveDown: (t) =>
|
|
2990
|
-
moveTop: (t) =>
|
|
2991
|
-
moveBottom: (t) =>
|
|
2992
|
-
indent:
|
|
2993
|
-
outdent:
|
|
2994
|
-
openMoveToPosition:
|
|
2995
|
-
openChangeParent:
|
|
2996
|
-
},
|
|
2997
|
-
const
|
|
2998
|
-
return
|
|
2999
|
-
},
|
|
3000
|
-
|
|
3001
|
-
const
|
|
3002
|
-
return
|
|
3003
|
-
},
|
|
3004
|
-
$.deleteItem(t),
|
|
3005
|
-
},
|
|
3006
|
-
$.updateItem(t, l),
|
|
3007
|
-
},
|
|
2970
|
+
keyboardNav: Ct,
|
|
2971
|
+
isRowClickable: un,
|
|
2972
|
+
resolveCompactText: jt,
|
|
2973
|
+
resolveValidation: (t, l, a) => yn(t, l, a),
|
|
2974
|
+
buildSlotProps: ga
|
|
2975
|
+
})), Ia = {
|
|
2976
|
+
onRowClick: ua,
|
|
2977
|
+
onChevronClick: Kt,
|
|
2978
|
+
onEditClick: wt,
|
|
2979
|
+
onDeleteClick: fn,
|
|
2980
|
+
onCloseClick: dt,
|
|
2981
|
+
onSaveClick: mn,
|
|
2982
|
+
onCancelClick: vn,
|
|
2983
|
+
onAddAfterClick: rn,
|
|
2984
|
+
onAddChildClick: dn,
|
|
2985
|
+
moveUp: (t) => Lt(t),
|
|
2986
|
+
moveDown: (t) => Mt(t),
|
|
2987
|
+
moveTop: (t) => zt(t),
|
|
2988
|
+
moveBottom: (t) => Nt(t),
|
|
2989
|
+
indent: Ot,
|
|
2990
|
+
outdent: Ut,
|
|
2991
|
+
openMoveToPosition: Ca,
|
|
2992
|
+
openChangeParent: Aa
|
|
2993
|
+
}, Da = g(() => P.value.filter((t) => t.parentKey === null)), Ea = (t, l, a) => {
|
|
2994
|
+
const x = $.addItem(l, { afterId: t ?? void 0, childrenAllowed: a });
|
|
2995
|
+
return Oe(() => Y()), x;
|
|
2996
|
+
}, Ta = (t, l, a) => {
|
|
2997
|
+
T.value.add(t);
|
|
2998
|
+
const x = $.addItem(l, { parentId: t, asFirstChild: !0, childrenAllowed: a });
|
|
2999
|
+
return Oe(() => Y()), x;
|
|
3000
|
+
}, $a = (t) => {
|
|
3001
|
+
$.deleteItem(t), Q.value.delete(t), ue.value.delete(t), j.value.delete(t), T.value.delete(t), Oe(() => Y());
|
|
3002
|
+
}, Fa = (t, l, a = null, x = null, Z = null) => {
|
|
3003
|
+
$.updateItem(t, l), Oe(() => Y());
|
|
3004
|
+
}, Ba = Ge(e, "unsavedKeys"), Ra = g(() => {
|
|
3008
3005
|
const t = /* @__PURE__ */ new Set();
|
|
3009
3006
|
for (const l of P.value)
|
|
3010
3007
|
l.unsaved && t.add(l.key);
|
|
3011
3008
|
return t;
|
|
3012
|
-
}), { hasUnsavedChanges:
|
|
3013
|
-
unsavedKeysModel:
|
|
3014
|
-
internalUnsavedKeys:
|
|
3009
|
+
}), { hasUnsavedChanges: Ka, unsavedCount: Va, clearUnsavedState: La } = Yn({
|
|
3010
|
+
unsavedKeysModel: Ba,
|
|
3011
|
+
internalUnsavedKeys: Ra,
|
|
3015
3012
|
onClearAll: () => {
|
|
3016
|
-
|
|
3013
|
+
Y(), ee.value = /* @__PURE__ */ new Set();
|
|
3017
3014
|
},
|
|
3018
3015
|
onClearKey: (t) => {
|
|
3019
|
-
|
|
3016
|
+
A(t), ee.value.delete(t);
|
|
3020
3017
|
}
|
|
3021
3018
|
});
|
|
3022
3019
|
return w({
|
|
3023
3020
|
addItem: $.addItem,
|
|
3024
3021
|
addAfterId: Ea,
|
|
3025
|
-
addChildToId:
|
|
3026
|
-
removeById:
|
|
3027
|
-
updateData:
|
|
3022
|
+
addChildToId: Ta,
|
|
3023
|
+
removeById: $a,
|
|
3024
|
+
updateData: Fa,
|
|
3028
3025
|
updateItem: $.updateItem,
|
|
3029
3026
|
deleteItem: $.deleteItem,
|
|
3030
3027
|
moveUp: $.moveUp,
|
|
@@ -3036,55 +3033,55 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
3036
3033
|
moveTo: $.moveTo,
|
|
3037
3034
|
recalculatePositions: $.recalculatePositions,
|
|
3038
3035
|
viewItems: $.viewItems,
|
|
3039
|
-
resetDirtyBaseline:
|
|
3040
|
-
hasUnsavedChanges:
|
|
3041
|
-
unsavedCount:
|
|
3042
|
-
clearUnsavedState:
|
|
3043
|
-
enterReorderMode:
|
|
3044
|
-
cancelReorderMode:
|
|
3036
|
+
resetDirtyBaseline: se,
|
|
3037
|
+
hasUnsavedChanges: Ka,
|
|
3038
|
+
unsavedCount: Va,
|
|
3039
|
+
clearUnsavedState: La,
|
|
3040
|
+
enterReorderMode: et,
|
|
3041
|
+
cancelReorderMode: We,
|
|
3045
3042
|
applyReorder: lt,
|
|
3046
3043
|
// Tree children visibility (expand/collapse a branch)
|
|
3047
|
-
expand: (t) =>
|
|
3048
|
-
collapse: (t) =>
|
|
3044
|
+
expand: (t) => T.value.add(t),
|
|
3045
|
+
collapse: (t) => T.value.delete(t),
|
|
3049
3046
|
toggleExpand: (t) => {
|
|
3050
|
-
|
|
3047
|
+
T.value.has(t) ? T.value.delete(t) : T.value.add(t);
|
|
3051
3048
|
},
|
|
3052
3049
|
// Row readonly-detail body visibility
|
|
3053
3050
|
expandDetail: (t) => j.value.add(t),
|
|
3054
3051
|
collapseDetail: (t) => j.value.delete(t)
|
|
3055
|
-
}), (t, l) => (
|
|
3052
|
+
}), (t, l) => (y(), K("div", {
|
|
3056
3053
|
ref_key: "rootEl",
|
|
3057
3054
|
ref: D,
|
|
3058
|
-
class:
|
|
3059
|
-
`a-nested-list-editor--mode-${
|
|
3055
|
+
class: xe(["a-nested-list-editor", [
|
|
3056
|
+
`a-nested-list-editor--mode-${p.value}`,
|
|
3060
3057
|
{
|
|
3061
3058
|
"a-nested-list-editor--readonly": e.readonly,
|
|
3062
3059
|
"a-nested-list-editor--disabled": e.disabled,
|
|
3063
3060
|
"a-nested-list-editor--touch": V.value,
|
|
3064
|
-
"a-nested-list-editor--drag-enabled":
|
|
3061
|
+
"a-nested-list-editor--drag-enabled": Pe.value
|
|
3065
3062
|
}
|
|
3066
3063
|
]])
|
|
3067
3064
|
}, [
|
|
3068
|
-
M("div",
|
|
3069
|
-
o.value ? (
|
|
3070
|
-
z(t.$slots, "header",
|
|
3071
|
-
e.title ? (
|
|
3072
|
-
M("div",
|
|
3073
|
-
d(
|
|
3074
|
-
i(
|
|
3075
|
-
class:
|
|
3076
|
-
"has-pending-changes": d(
|
|
3077
|
-
"pending-count": d(
|
|
3078
|
-
error: d(
|
|
3065
|
+
M("div", zl, [
|
|
3066
|
+
o.value ? (y(), K("div", Nl, [
|
|
3067
|
+
z(t.$slots, "header", ie({ title: e.title }, hn.value), () => [
|
|
3068
|
+
e.title ? (y(), K("h3", Ol, B(e.title), 1)) : H("", !0),
|
|
3069
|
+
M("div", Ul, [
|
|
3070
|
+
d(we) ? z(t.$slots, "reorder-toolbar", Ve(ie({ key: 0 }, ba.value)), () => [
|
|
3071
|
+
i(so, {
|
|
3072
|
+
class: xe({ "a-le-toolbar-status--pending": d(Me) }),
|
|
3073
|
+
"has-pending-changes": d(Me),
|
|
3074
|
+
"pending-count": d(ht),
|
|
3075
|
+
error: d(_e)
|
|
3079
3076
|
}, null, 8, ["class", "has-pending-changes", "pending-count", "error"]),
|
|
3080
3077
|
i(_, {
|
|
3081
3078
|
variant: "text",
|
|
3082
3079
|
size: "small",
|
|
3083
|
-
disabled: d(
|
|
3084
|
-
onClick: d(
|
|
3080
|
+
disabled: d(Se),
|
|
3081
|
+
onClick: d(We)
|
|
3085
3082
|
}, {
|
|
3086
3083
|
default: r(() => [
|
|
3087
|
-
|
|
3084
|
+
G(B(d(b)("common.sortable.reorderCancel")), 1)
|
|
3088
3085
|
]),
|
|
3089
3086
|
_: 1
|
|
3090
3087
|
}, 8, ["disabled", "onClick"]),
|
|
@@ -3093,249 +3090,248 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
3093
3090
|
variant: "flat",
|
|
3094
3091
|
size: "small",
|
|
3095
3092
|
"prepend-icon": "mdi-check",
|
|
3096
|
-
loading: d(
|
|
3097
|
-
disabled: d(
|
|
3093
|
+
loading: d(Se),
|
|
3094
|
+
disabled: d(Se) || !d(Me),
|
|
3098
3095
|
onClick: d(lt)
|
|
3099
3096
|
}, {
|
|
3100
3097
|
default: r(() => [
|
|
3101
|
-
|
|
3098
|
+
G(B(d(b)("common.sortable.reorderApply")), 1)
|
|
3102
3099
|
]),
|
|
3103
3100
|
_: 1
|
|
3104
3101
|
}, 8, ["loading", "disabled", "onClick"])
|
|
3105
|
-
]) : (
|
|
3106
|
-
|
|
3102
|
+
]) : (y(), K(ve, { key: 1 }, [
|
|
3103
|
+
st.value && pt.value ? (y(), W(_, {
|
|
3107
3104
|
key: 0,
|
|
3108
3105
|
variant: "tonal",
|
|
3109
3106
|
color: "primary",
|
|
3110
3107
|
icon: "",
|
|
3111
3108
|
size: "x-small",
|
|
3112
|
-
onClick:
|
|
3109
|
+
onClick: gt
|
|
3113
3110
|
}, {
|
|
3114
3111
|
default: r(() => [
|
|
3115
|
-
i(
|
|
3112
|
+
i(ne, {
|
|
3116
3113
|
icon: Qe.value ? "mdi-unfold-less-horizontal" : "mdi-unfold-more-horizontal",
|
|
3117
3114
|
size: "18"
|
|
3118
3115
|
}, null, 8, ["icon"]),
|
|
3119
|
-
i(
|
|
3116
|
+
i(De, {
|
|
3120
3117
|
activator: "parent",
|
|
3121
3118
|
location: "bottom",
|
|
3122
3119
|
text: Qe.value ? d(b)("common.sortable.collapseAll") : d(b)("common.sortable.expandAll")
|
|
3123
3120
|
}, null, 8, ["text"])
|
|
3124
3121
|
]),
|
|
3125
3122
|
_: 1
|
|
3126
|
-
})) :
|
|
3123
|
+
})) : st.value ? (y(), W(_, {
|
|
3127
3124
|
key: 1,
|
|
3128
3125
|
variant: "tonal",
|
|
3129
3126
|
color: "primary",
|
|
3130
3127
|
size: "small",
|
|
3131
3128
|
"prepend-icon": Qe.value ? "mdi-unfold-less-horizontal" : "mdi-unfold-more-horizontal",
|
|
3132
|
-
onClick:
|
|
3129
|
+
onClick: gt
|
|
3133
3130
|
}, {
|
|
3134
3131
|
default: r(() => [
|
|
3135
|
-
|
|
3132
|
+
G(B(Qe.value ? d(b)("common.sortable.collapseAll") : d(b)("common.sortable.expandAll")), 1)
|
|
3136
3133
|
]),
|
|
3137
3134
|
_: 1
|
|
3138
|
-
}, 8, ["prepend-icon"])) :
|
|
3139
|
-
|
|
3140
|
-
|
|
3135
|
+
}, 8, ["prepend-icon"])) : H("", !0),
|
|
3136
|
+
Be.value ? z(t.$slots, "reorder-toggle", Ve(ie({ key: 2 }, hn.value)), () => [
|
|
3137
|
+
pt.value ? (y(), W(_, {
|
|
3141
3138
|
key: 0,
|
|
3142
3139
|
variant: "tonal",
|
|
3143
3140
|
color: "primary",
|
|
3144
3141
|
icon: "",
|
|
3145
3142
|
size: "x-small",
|
|
3146
|
-
disabled: !
|
|
3147
|
-
onClick: d(
|
|
3143
|
+
disabled: !O.value,
|
|
3144
|
+
onClick: d(et)
|
|
3148
3145
|
}, {
|
|
3149
3146
|
default: r(() => [
|
|
3150
|
-
i(
|
|
3147
|
+
i(ne, {
|
|
3151
3148
|
icon: "mdi-sort",
|
|
3152
3149
|
size: "18"
|
|
3153
3150
|
}),
|
|
3154
|
-
i(
|
|
3151
|
+
i(De, {
|
|
3155
3152
|
activator: "parent",
|
|
3156
3153
|
location: "bottom",
|
|
3157
3154
|
text: d(b)("common.sortable.reorder")
|
|
3158
3155
|
}, null, 8, ["text"])
|
|
3159
3156
|
]),
|
|
3160
3157
|
_: 1
|
|
3161
|
-
}, 8, ["disabled", "onClick"])) : (
|
|
3158
|
+
}, 8, ["disabled", "onClick"])) : (y(), W(_, {
|
|
3162
3159
|
key: 1,
|
|
3163
3160
|
variant: "tonal",
|
|
3164
3161
|
color: "primary",
|
|
3165
3162
|
"prepend-icon": "mdi-sort",
|
|
3166
3163
|
size: "small",
|
|
3167
|
-
disabled: !
|
|
3168
|
-
onClick: d(
|
|
3164
|
+
disabled: !O.value,
|
|
3165
|
+
onClick: d(et)
|
|
3169
3166
|
}, {
|
|
3170
3167
|
default: r(() => [
|
|
3171
|
-
|
|
3168
|
+
G(B(d(b)("common.sortable.reorder")), 1)
|
|
3172
3169
|
]),
|
|
3173
3170
|
_: 1
|
|
3174
3171
|
}, 8, ["disabled", "onClick"]))
|
|
3175
|
-
]) :
|
|
3172
|
+
]) : H("", !0)
|
|
3176
3173
|
], 64))
|
|
3177
3174
|
])
|
|
3178
3175
|
])
|
|
3179
|
-
])) :
|
|
3180
|
-
e.loading ? (
|
|
3181
|
-
i(
|
|
3176
|
+
])) : H("", !0),
|
|
3177
|
+
e.loading ? (y(), K("div", jl, [
|
|
3178
|
+
i(sa, {
|
|
3182
3179
|
indeterminate: "",
|
|
3183
3180
|
color: "primary",
|
|
3184
3181
|
size: "32"
|
|
3185
3182
|
})
|
|
3186
|
-
])) : e.error ? (
|
|
3187
|
-
i(
|
|
3183
|
+
])) : e.error ? (y(), K("div", ql, [
|
|
3184
|
+
i(ln, {
|
|
3188
3185
|
type: "error",
|
|
3189
3186
|
variant: "tonal",
|
|
3190
3187
|
density: "compact",
|
|
3191
3188
|
border: "start"
|
|
3192
3189
|
}, {
|
|
3193
3190
|
default: r(() => [
|
|
3194
|
-
|
|
3191
|
+
G(B(e.error), 1)
|
|
3195
3192
|
]),
|
|
3196
3193
|
_: 1
|
|
3197
3194
|
})
|
|
3198
|
-
])) :
|
|
3195
|
+
])) : c.value ? (y(), K("div", Gl, [
|
|
3199
3196
|
z(t.$slots, "empty", {
|
|
3200
3197
|
readonly: e.readonly,
|
|
3201
3198
|
disabled: e.disabled,
|
|
3202
|
-
actions: { add:
|
|
3199
|
+
actions: { add: rt }
|
|
3203
3200
|
}, () => [
|
|
3204
|
-
i(
|
|
3205
|
-
title:
|
|
3206
|
-
|
|
3207
|
-
"add
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
}, null, 8, ["title", "text", "add-label", "can-add"])
|
|
3201
|
+
i(Xn, {
|
|
3202
|
+
title: tt.value,
|
|
3203
|
+
"add-label": it.value,
|
|
3204
|
+
"can-add": Ye.value,
|
|
3205
|
+
onAdd: rt
|
|
3206
|
+
}, null, 8, ["title", "add-label", "can-add"])
|
|
3211
3207
|
])
|
|
3212
|
-
])) : (
|
|
3213
|
-
key:
|
|
3208
|
+
])) : (y(), K("div", {
|
|
3209
|
+
key: m.value,
|
|
3214
3210
|
ref_key: "rowsContainer",
|
|
3215
|
-
ref:
|
|
3216
|
-
class:
|
|
3211
|
+
ref: S,
|
|
3212
|
+
class: xe(["a-nested-list-editor__rows", { "a-nested-list-editor__rows--dragging": be.value !== null }])
|
|
3217
3213
|
}, [
|
|
3218
3214
|
M("div", {
|
|
3219
|
-
class:
|
|
3215
|
+
class: xe([wn, "a-nested-list-editor__group--root"]),
|
|
3220
3216
|
"data-parent-id": ""
|
|
3221
3217
|
}, [
|
|
3222
|
-
(
|
|
3218
|
+
(y(!0), K(ve, null, Ze(Da.value, (a) => (y(), W(da, {
|
|
3223
3219
|
key: String(a.key),
|
|
3224
3220
|
vi: a,
|
|
3225
3221
|
"view-items": P.value,
|
|
3226
|
-
"drag-state":
|
|
3227
|
-
context:
|
|
3228
|
-
callbacks:
|
|
3222
|
+
"drag-state": be.value,
|
|
3223
|
+
context: Pa.value,
|
|
3224
|
+
callbacks: Ia
|
|
3229
3225
|
}, {
|
|
3230
|
-
item: r((
|
|
3231
|
-
z(t.$slots, "item",
|
|
3226
|
+
item: r((x) => [
|
|
3227
|
+
z(t.$slots, "item", ie({ ref_for: !0 }, x))
|
|
3232
3228
|
]),
|
|
3233
|
-
"item-compact": r((
|
|
3234
|
-
z(t.$slots, "item-compact",
|
|
3229
|
+
"item-compact": r((x) => [
|
|
3230
|
+
z(t.$slots, "item-compact", ie({ ref_for: !0 }, x))
|
|
3235
3231
|
]),
|
|
3236
|
-
"item-readonly": r((
|
|
3237
|
-
z(t.$slots, "item-readonly",
|
|
3232
|
+
"item-readonly": r((x) => [
|
|
3233
|
+
z(t.$slots, "item-readonly", ie({ ref_for: !0 }, x))
|
|
3238
3234
|
]),
|
|
3239
|
-
"item-status": r((
|
|
3240
|
-
z(t.$slots, "item-status",
|
|
3235
|
+
"item-status": r((x) => [
|
|
3236
|
+
z(t.$slots, "item-status", ie({ ref_for: !0 }, x))
|
|
3241
3237
|
]),
|
|
3242
|
-
"item-footer": r((
|
|
3243
|
-
z(t.$slots, "item-footer",
|
|
3238
|
+
"item-footer": r((x) => [
|
|
3239
|
+
z(t.$slots, "item-footer", ie({ ref_for: !0 }, x))
|
|
3244
3240
|
]),
|
|
3245
|
-
"item-actions": r((
|
|
3246
|
-
z(t.$slots, "item-actions",
|
|
3241
|
+
"item-actions": r((x) => [
|
|
3242
|
+
z(t.$slots, "item-actions", ie({ ref_for: !0 }, x))
|
|
3247
3243
|
]),
|
|
3248
|
-
"before-item": r((
|
|
3249
|
-
z(t.$slots, "before-item",
|
|
3244
|
+
"before-item": r((x) => [
|
|
3245
|
+
z(t.$slots, "before-item", ie({ ref_for: !0 }, x))
|
|
3250
3246
|
]),
|
|
3251
|
-
"after-item": r((
|
|
3252
|
-
z(t.$slots, "after-item",
|
|
3247
|
+
"after-item": r((x) => [
|
|
3248
|
+
z(t.$slots, "after-item", ie({ ref_for: !0 }, x))
|
|
3253
3249
|
]),
|
|
3254
3250
|
_: 3
|
|
3255
3251
|
}, 8, ["vi", "view-items", "drag-state", "context"]))), 128))
|
|
3256
3252
|
], 2),
|
|
3257
|
-
|
|
3258
|
-
|
|
3253
|
+
je.value !== null ? (y(), K(ve, { key: 0 }, [
|
|
3254
|
+
je.value.connector !== null ? (y(), K("div", {
|
|
3259
3255
|
key: 0,
|
|
3260
3256
|
class: "a-nested-list-editor__drop-connector",
|
|
3261
|
-
style:
|
|
3262
|
-
left: `${
|
|
3263
|
-
top: `${
|
|
3264
|
-
height: `${
|
|
3257
|
+
style: vt({
|
|
3258
|
+
left: `${je.value.connector.left}px`,
|
|
3259
|
+
top: `${je.value.connector.top}px`,
|
|
3260
|
+
height: `${je.value.connector.height}px`
|
|
3265
3261
|
})
|
|
3266
|
-
}, null, 4)) :
|
|
3262
|
+
}, null, 4)) : H("", !0),
|
|
3267
3263
|
M("div", {
|
|
3268
3264
|
class: "a-nested-list-editor__drop-line",
|
|
3269
|
-
style:
|
|
3270
|
-
top: `${
|
|
3271
|
-
left: `${
|
|
3272
|
-
right: `${
|
|
3265
|
+
style: vt({
|
|
3266
|
+
top: `${je.value.line.top}px`,
|
|
3267
|
+
left: `${je.value.line.left}px`,
|
|
3268
|
+
right: `${je.value.line.right}px`
|
|
3273
3269
|
})
|
|
3274
3270
|
}, [...l[3] || (l[3] = [
|
|
3275
3271
|
M("span", { class: "a-nested-list-editor__drop-line-dot" }, null, -1)
|
|
3276
3272
|
])], 4)
|
|
3277
|
-
], 64)) :
|
|
3273
|
+
], 64)) : H("", !0)
|
|
3278
3274
|
], 2)),
|
|
3279
|
-
|
|
3275
|
+
Ye.value && !e.loading && !e.error && !c.value ? z(t.$slots, "add-button", {
|
|
3280
3276
|
key: 5,
|
|
3281
3277
|
readonly: e.readonly,
|
|
3282
3278
|
disabled: e.disabled,
|
|
3283
|
-
props: { onClick:
|
|
3284
|
-
actions: { add:
|
|
3279
|
+
props: { onClick: rt },
|
|
3280
|
+
actions: { add: rt }
|
|
3285
3281
|
}, () => [
|
|
3286
3282
|
M("button", {
|
|
3287
3283
|
type: "button",
|
|
3288
3284
|
class: "a-le-row-add",
|
|
3289
|
-
onClick:
|
|
3285
|
+
onClick: rt
|
|
3290
3286
|
}, [
|
|
3291
|
-
i(
|
|
3287
|
+
i(ne, {
|
|
3292
3288
|
icon: "mdi-plus",
|
|
3293
3289
|
size: "18"
|
|
3294
3290
|
}),
|
|
3295
|
-
M("span", null, B(
|
|
3291
|
+
M("span", null, B(it.value), 1)
|
|
3296
3292
|
])
|
|
3297
|
-
]) :
|
|
3293
|
+
]) : H("", !0)
|
|
3298
3294
|
]),
|
|
3299
|
-
i(
|
|
3300
|
-
modelValue:
|
|
3301
|
-
"onUpdate:modelValue": l[0] || (l[0] = (a) =>
|
|
3302
|
-
total:
|
|
3303
|
-
"current-index":
|
|
3304
|
-
"item-label":
|
|
3305
|
-
onConfirm:
|
|
3295
|
+
i(ro, {
|
|
3296
|
+
modelValue: qt.value,
|
|
3297
|
+
"onUpdate:modelValue": l[0] || (l[0] = (a) => qt.value = a),
|
|
3298
|
+
total: Gt.value?.total ?? 0,
|
|
3299
|
+
"current-index": Gt.value?.currentIndex ?? 0,
|
|
3300
|
+
"item-label": wa.value,
|
|
3301
|
+
onConfirm: xa
|
|
3306
3302
|
}, null, 8, ["modelValue", "total", "current-index", "item-label"]),
|
|
3307
|
-
i(
|
|
3308
|
-
modelValue:
|
|
3309
|
-
"onUpdate:modelValue": l[1] || (l[1] = (a) =>
|
|
3310
|
-
tree:
|
|
3311
|
-
"source-key":
|
|
3303
|
+
i(Ml, {
|
|
3304
|
+
modelValue: Ht.value,
|
|
3305
|
+
"onUpdate:modelValue": l[1] || (l[1] = (a) => Ht.value = a),
|
|
3306
|
+
tree: h.value,
|
|
3307
|
+
"source-key": xt.value?.key ?? null,
|
|
3312
3308
|
"key-field": e.keyField,
|
|
3313
3309
|
"max-depth": e.maxDepth,
|
|
3314
|
-
"resolve-label":
|
|
3310
|
+
"resolve-label": jt,
|
|
3315
3311
|
"calculate-subtree-depth": d($).calculateSubtreeDepth,
|
|
3316
|
-
onConfirm:
|
|
3312
|
+
onConfirm: Sa
|
|
3317
3313
|
}, null, 8, ["modelValue", "tree", "source-key", "key-field", "max-depth", "calculate-subtree-depth"]),
|
|
3318
|
-
i(
|
|
3319
|
-
modelValue: d(
|
|
3320
|
-
"onUpdate:modelValue": l[2] || (l[2] = (a) =>
|
|
3314
|
+
i(Zn, {
|
|
3315
|
+
modelValue: d(Vt),
|
|
3316
|
+
"onUpdate:modelValue": l[2] || (l[2] = (a) => aa(Vt) ? Vt.value = a : null),
|
|
3321
3317
|
title: Xe.value,
|
|
3322
|
-
text:
|
|
3318
|
+
text: Rt.value,
|
|
3323
3319
|
"confirm-label": d(b)("common.sortable.delete"),
|
|
3324
3320
|
"cancel-label": d(b)("common.button.cancel"),
|
|
3325
|
-
error: d(
|
|
3326
|
-
"in-flight": d(
|
|
3327
|
-
onConfirm: d(
|
|
3328
|
-
onCancel: d(
|
|
3321
|
+
error: d(ma),
|
|
3322
|
+
"in-flight": d(fa),
|
|
3323
|
+
onConfirm: d(ya),
|
|
3324
|
+
onCancel: d(ha)
|
|
3329
3325
|
}, null, 8, ["modelValue", "title", "text", "confirm-label", "cancel-label", "error", "in-flight", "onConfirm", "onCancel"]),
|
|
3330
|
-
M("div",
|
|
3331
|
-
n: d(
|
|
3332
|
-
total: d(
|
|
3326
|
+
M("div", Hl, B(d(Ct).grabbedKey.value !== null ? d(b)("common.sortable.keyboardGrab.status", {
|
|
3327
|
+
n: d(Ct).grabbedIndex.value + 1,
|
|
3328
|
+
total: d(Ct).totalCount.value
|
|
3333
3329
|
}) : ""), 1)
|
|
3334
3330
|
], 2));
|
|
3335
3331
|
}
|
|
3336
|
-
}),
|
|
3332
|
+
}), Wl = { class: "a-unsaved-sections" }, Yl = /* @__PURE__ */ He({
|
|
3337
3333
|
__name: "AUnsavedConfirmDialog",
|
|
3338
|
-
props: /* @__PURE__ */
|
|
3334
|
+
props: /* @__PURE__ */ Le({
|
|
3339
3335
|
title: { default: void 0 },
|
|
3340
3336
|
body: { default: void 0 },
|
|
3341
3337
|
stayLabel: { default: void 0 },
|
|
@@ -3345,63 +3341,63 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
3345
3341
|
modelValue: { type: Boolean, required: !0 },
|
|
3346
3342
|
modelModifiers: {}
|
|
3347
3343
|
}),
|
|
3348
|
-
emits: /* @__PURE__ */
|
|
3344
|
+
emits: /* @__PURE__ */ Le(["resolve"], ["update:modelValue"]),
|
|
3349
3345
|
setup(e, { emit: w }) {
|
|
3350
|
-
const
|
|
3351
|
-
|
|
3352
|
-
},
|
|
3353
|
-
|
|
3346
|
+
const u = w, n = Ge(e, "modelValue"), { t: f } = Je(), h = () => {
|
|
3347
|
+
u("resolve", !1);
|
|
3348
|
+
}, p = () => {
|
|
3349
|
+
u("resolve", !0);
|
|
3354
3350
|
};
|
|
3355
|
-
return (b, k) => (
|
|
3351
|
+
return (b, k) => (y(), W(an, {
|
|
3356
3352
|
modelValue: n.value,
|
|
3357
3353
|
"onUpdate:modelValue": k[0] || (k[0] = (s) => n.value = s),
|
|
3358
3354
|
"max-width": "480",
|
|
3359
3355
|
persistent: ""
|
|
3360
3356
|
}, {
|
|
3361
3357
|
default: r(() => [
|
|
3362
|
-
i(
|
|
3358
|
+
i(nn, null, {
|
|
3363
3359
|
default: r(() => [
|
|
3364
|
-
i(
|
|
3360
|
+
i(la, null, {
|
|
3365
3361
|
default: r(() => [
|
|
3366
|
-
|
|
3362
|
+
G(B(e.title ?? d(f)("common.sortable.unsavedChanges.title")), 1)
|
|
3367
3363
|
]),
|
|
3368
3364
|
_: 1
|
|
3369
3365
|
}),
|
|
3370
|
-
i(
|
|
3366
|
+
i(Dt, null, {
|
|
3371
3367
|
default: r(() => [
|
|
3372
|
-
e.body ? (
|
|
3373
|
-
|
|
3374
|
-
], 64)) : e.dirtyLabels.length ? (
|
|
3375
|
-
|
|
3376
|
-
M("ul",
|
|
3377
|
-
(
|
|
3368
|
+
e.body ? (y(), K(ve, { key: 0 }, [
|
|
3369
|
+
G(B(e.body), 1)
|
|
3370
|
+
], 64)) : e.dirtyLabels.length ? (y(), K(ve, { key: 1 }, [
|
|
3371
|
+
G(B(d(f)("common.sortable.unsavedChanges.sectionsIntro")) + " ", 1),
|
|
3372
|
+
M("ul", Wl, [
|
|
3373
|
+
(y(!0), K(ve, null, Ze(e.dirtyLabels, (s, C) => (y(), K("li", { key: C }, B(s), 1))), 128))
|
|
3378
3374
|
]),
|
|
3379
|
-
|
|
3380
|
-
], 64)) : (
|
|
3381
|
-
|
|
3375
|
+
G(" " + B(d(f)("common.sortable.unsavedChanges.leaveQuestion")), 1)
|
|
3376
|
+
], 64)) : (y(), K(ve, { key: 2 }, [
|
|
3377
|
+
G(B(d(f)("common.sortable.unsavedChanges.body")), 1)
|
|
3382
3378
|
], 64))
|
|
3383
3379
|
]),
|
|
3384
3380
|
_: 1
|
|
3385
3381
|
}),
|
|
3386
|
-
i(
|
|
3382
|
+
i(ia, null, {
|
|
3387
3383
|
default: r(() => [
|
|
3388
|
-
i(
|
|
3384
|
+
i(on),
|
|
3389
3385
|
i(_, {
|
|
3390
3386
|
variant: "text",
|
|
3391
|
-
onClick:
|
|
3387
|
+
onClick: h
|
|
3392
3388
|
}, {
|
|
3393
3389
|
default: r(() => [
|
|
3394
|
-
|
|
3390
|
+
G(B(e.stayLabel ?? d(f)("common.sortable.unsavedChanges.stay")), 1)
|
|
3395
3391
|
]),
|
|
3396
3392
|
_: 1
|
|
3397
3393
|
}),
|
|
3398
3394
|
i(_, {
|
|
3399
3395
|
color: "warning",
|
|
3400
3396
|
variant: "flat",
|
|
3401
|
-
onClick:
|
|
3397
|
+
onClick: p
|
|
3402
3398
|
}, {
|
|
3403
3399
|
default: r(() => [
|
|
3404
|
-
|
|
3400
|
+
G(B(e.discardLabel ?? d(f)("common.sortable.unsavedChanges.discard")), 1)
|
|
3405
3401
|
]),
|
|
3406
3402
|
_: 1
|
|
3407
3403
|
})
|
|
@@ -3415,41 +3411,41 @@ const Rt = (e, w) => e.find((c) => c.key === w) ?? null, da = (e, w, c) => {
|
|
|
3415
3411
|
_: 1
|
|
3416
3412
|
}, 8, ["modelValue"]));
|
|
3417
3413
|
}
|
|
3418
|
-
}), Ei = /* @__PURE__ */
|
|
3419
|
-
function
|
|
3420
|
-
const e =
|
|
3421
|
-
const
|
|
3414
|
+
}), Ei = /* @__PURE__ */ ea(Yl, [["__scopeId", "data-v-8342a164"]]), ca = /* @__PURE__ */ Symbol("unsaved.sections");
|
|
3415
|
+
function Xl() {
|
|
3416
|
+
const e = po(/* @__PURE__ */ new Map()), w = g(() => {
|
|
3417
|
+
const u = [];
|
|
3422
3418
|
for (const n of e.values())
|
|
3423
|
-
for (const
|
|
3424
|
-
|
|
3425
|
-
return
|
|
3419
|
+
for (const f of n.value)
|
|
3420
|
+
f.dirty && u.push(f.label);
|
|
3421
|
+
return u;
|
|
3426
3422
|
});
|
|
3427
3423
|
return {
|
|
3428
|
-
register(
|
|
3429
|
-
e.set(
|
|
3424
|
+
register(u, n) {
|
|
3425
|
+
e.set(u, n);
|
|
3430
3426
|
},
|
|
3431
|
-
unregister(
|
|
3432
|
-
e.delete(
|
|
3427
|
+
unregister(u) {
|
|
3428
|
+
e.delete(u);
|
|
3433
3429
|
},
|
|
3434
3430
|
dirtyLabels: w
|
|
3435
3431
|
};
|
|
3436
3432
|
}
|
|
3437
|
-
function
|
|
3438
|
-
const e =
|
|
3439
|
-
return
|
|
3433
|
+
function Ql() {
|
|
3434
|
+
const e = Xl();
|
|
3435
|
+
return en() && ta(ca, e), e;
|
|
3440
3436
|
}
|
|
3441
|
-
function
|
|
3442
|
-
const w =
|
|
3443
|
-
if (!w || !
|
|
3444
|
-
const
|
|
3445
|
-
const
|
|
3446
|
-
return Array.isArray(
|
|
3437
|
+
function Ti(e) {
|
|
3438
|
+
const w = Qt(ca, null);
|
|
3439
|
+
if (!w || !en()) return;
|
|
3440
|
+
const u = /* @__PURE__ */ Symbol("unsaved.section"), n = g(() => {
|
|
3441
|
+
const f = e();
|
|
3442
|
+
return Array.isArray(f) ? f : [f];
|
|
3447
3443
|
});
|
|
3448
|
-
w.register(
|
|
3444
|
+
w.register(u, n), _t(() => w.unregister(u));
|
|
3449
3445
|
}
|
|
3450
|
-
const
|
|
3451
|
-
function
|
|
3452
|
-
const w =
|
|
3446
|
+
const Zl = (e) => e == null ? !1 : typeof e == "boolean" ? e : e instanceof Set ? e.size > 0 : Array.isArray(e) ? e.length > 0 : !!e, An = (e, w) => e === void 0 ? w : typeof e == "boolean" ? e : e.value;
|
|
3447
|
+
function $i(e) {
|
|
3448
|
+
const w = Ql();
|
|
3453
3449
|
if (e.ownSections) {
|
|
3454
3450
|
const s = e.ownSections, C = /* @__PURE__ */ Symbol("unsaved.section.own"), D = g(() => {
|
|
3455
3451
|
const N = s();
|
|
@@ -3457,27 +3453,27 @@ function Fi(e) {
|
|
|
3457
3453
|
});
|
|
3458
3454
|
w.register(C, D);
|
|
3459
3455
|
}
|
|
3460
|
-
const
|
|
3461
|
-
() => e.sources.some((s) =>
|
|
3462
|
-
), n =
|
|
3463
|
-
let
|
|
3464
|
-
const
|
|
3465
|
-
|
|
3456
|
+
const u = g(
|
|
3457
|
+
() => e.sources.some((s) => Zl(s.value)) || w.dirtyLabels.value.length > 0
|
|
3458
|
+
), n = ce(!1);
|
|
3459
|
+
let f = null, h = !1;
|
|
3460
|
+
const p = () => h ? (h = !1, Promise.resolve(!0)) : new Promise((s) => {
|
|
3461
|
+
f = s, n.value = !0;
|
|
3466
3462
|
}), b = (s) => {
|
|
3467
|
-
n.value = !1,
|
|
3463
|
+
n.value = !1, f && (f(s), f = null);
|
|
3468
3464
|
}, k = () => {
|
|
3469
|
-
|
|
3465
|
+
h = !0;
|
|
3470
3466
|
};
|
|
3471
|
-
if (
|
|
3467
|
+
if (An(e.guardRoute, !0) && en())
|
|
3472
3468
|
try {
|
|
3473
|
-
|
|
3469
|
+
xo(async () => u.value ? await p() : !0);
|
|
3474
3470
|
} catch {
|
|
3475
3471
|
}
|
|
3476
|
-
if (
|
|
3472
|
+
if (An(e.guardWindowUnload, !0)) {
|
|
3477
3473
|
const s = (C) => {
|
|
3478
|
-
|
|
3474
|
+
u.value && (C.preventDefault(), C.returnValue = "");
|
|
3479
3475
|
};
|
|
3480
|
-
typeof window < "u" && (window.addEventListener("beforeunload", s),
|
|
3476
|
+
typeof window < "u" && (window.addEventListener("beforeunload", s), _t(() => {
|
|
3481
3477
|
window.removeEventListener("beforeunload", s);
|
|
3482
3478
|
}));
|
|
3483
3479
|
}
|
|
@@ -3489,80 +3485,80 @@ function Fi(e) {
|
|
|
3489
3485
|
C = !1;
|
|
3490
3486
|
return;
|
|
3491
3487
|
}
|
|
3492
|
-
N === !0 && D === !1 &&
|
|
3488
|
+
N === !0 && D === !1 && u.value && (C = !0, s.value = !0, await p() && (C = !0, s.value = !1));
|
|
3493
3489
|
});
|
|
3494
3490
|
}
|
|
3495
3491
|
return {
|
|
3496
|
-
hasUnsavedChanges:
|
|
3492
|
+
hasUnsavedChanges: u,
|
|
3497
3493
|
dirtyLabels: w.dirtyLabels,
|
|
3498
3494
|
promptOpen: n,
|
|
3499
3495
|
resolvePrompt: b,
|
|
3500
3496
|
acknowledge: k
|
|
3501
3497
|
};
|
|
3502
3498
|
}
|
|
3503
|
-
function
|
|
3504
|
-
const e =
|
|
3505
|
-
b.size === 0 ? e.value.delete(
|
|
3506
|
-
},
|
|
3507
|
-
const
|
|
3499
|
+
function Fi() {
|
|
3500
|
+
const e = ce(/* @__PURE__ */ new Map()), w = /* @__PURE__ */ new Set(), u = (p) => e.value.get(p) ?? w, n = (p, b) => {
|
|
3501
|
+
b.size === 0 ? e.value.delete(p) : e.value.set(p, b), e.value = new Map(e.value);
|
|
3502
|
+
}, f = g(() => {
|
|
3503
|
+
const p = /* @__PURE__ */ new Set();
|
|
3508
3504
|
for (const [b, k] of e.value.entries())
|
|
3509
3505
|
for (const s of k)
|
|
3510
|
-
|
|
3511
|
-
return
|
|
3512
|
-
}),
|
|
3513
|
-
return { getForParent:
|
|
3506
|
+
p.add(`${String(b)}:${String(s)}`);
|
|
3507
|
+
return p;
|
|
3508
|
+
}), h = g(() => f.value.size);
|
|
3509
|
+
return { getForParent: u, setForParent: n, merged: f, count: h };
|
|
3514
3510
|
}
|
|
3515
3511
|
export {
|
|
3516
|
-
|
|
3517
|
-
|
|
3518
|
-
|
|
3519
|
-
|
|
3520
|
-
|
|
3521
|
-
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3512
|
+
wi as ADatatableOrdering,
|
|
3513
|
+
Fo as ADatatablePagination,
|
|
3514
|
+
Ki as AFilterBooleanSelect,
|
|
3515
|
+
Vi as AFilterDatetimePicker,
|
|
3516
|
+
Li as AFilterInteger,
|
|
3517
|
+
Mi as AFilterRemoteAutocomplete,
|
|
3518
|
+
zi as AFilterRemoteAutocompleteWithMinimal,
|
|
3519
|
+
Ni as AFilterString,
|
|
3520
|
+
Oi as AFilterTimeInterval,
|
|
3521
|
+
Ui as AFilterValueObjectOptionsSelect,
|
|
3522
|
+
ji as AFilterWrapper,
|
|
3523
|
+
qi as AFilterWrapperSubjectSelect,
|
|
3524
|
+
Gi as AFormRemoteAutocomplete,
|
|
3525
|
+
Ii as AListEditor,
|
|
3526
|
+
Di as ANestedSortableListEditor,
|
|
3527
|
+
Hi as ASortableListEditor,
|
|
3528
|
+
Pi as ASubjectSelect,
|
|
3533
3529
|
Ei as AUnsavedConfirmDialog,
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3530
|
+
Sn as DatatablePaginationKey,
|
|
3531
|
+
Ji as FilterConfigKey,
|
|
3532
|
+
Wi as FilterDataKey,
|
|
3533
|
+
Yi as FilterInnerConfigKey,
|
|
3534
|
+
Xi as FilterInnerDataKey,
|
|
3535
|
+
Qi as ListEditorValidationKey,
|
|
3536
|
+
Zi as SharedReorderRegistryKey,
|
|
3537
|
+
_i as TimeIntervalSpecialOptions,
|
|
3538
|
+
es as UserAdminConfigLayoutType,
|
|
3539
|
+
ts as UserAdminConfigLayoutTypeDefault,
|
|
3540
|
+
ns as UserAdminConfigType,
|
|
3541
|
+
as as UserAdminConfigTypeDefault,
|
|
3542
|
+
Vo as createDatatableColumnsConfig,
|
|
3543
|
+
os as createFilter,
|
|
3544
|
+
ls as createFilterStore,
|
|
3545
|
+
Yt as generateListQuery,
|
|
3546
|
+
Ci as useApiFetchByIds,
|
|
3547
|
+
Ja as useApiFetchList,
|
|
3548
|
+
xi as useApiFetchListBatch,
|
|
3549
|
+
Na as useApiQueryBuilder,
|
|
3550
|
+
is as useApiRequest,
|
|
3551
|
+
eo as useFilterHelpers,
|
|
3552
|
+
Ai as useJobApi,
|
|
3553
|
+
ao as useListEditor,
|
|
3554
|
+
ss as useListEditorItemValidation,
|
|
3555
|
+
yl as useNestedListEditor,
|
|
3556
|
+
Fi as useNestedUnsavedKeys,
|
|
3557
|
+
Un as usePagination,
|
|
3558
|
+
Si as useSubjectSelect,
|
|
3559
|
+
$i as useUnsavedChangesGuard,
|
|
3560
|
+
Ti as useUnsavedSection,
|
|
3561
|
+
rs as useUserAdminConfigApi,
|
|
3562
|
+
ds as useUserAdminConfigFactory
|
|
3567
3563
|
};
|
|
3568
3564
|
//# sourceMappingURL=labs.js.map
|