ss-component-new 1.1.20 → 1.1.21

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.
@@ -0,0 +1,3341 @@
1
+ import { ref as U, onMounted as Ln, watch as pe, createElementBlock as Y, openBlock as K, createElementVNode as L, createBlock as Be, createVNode as ee, Fragment as je, renderList as $e, normalizeStyle as Lt, toDisplayString as Z, createSlots as qn, withCtx as ce, createCommentVNode as en, resolveComponent as Ge, createTextVNode as Ue, unref as tn, resolveDynamicComponent as Et } from "vue";
2
+ import { g as Jn, a as Mn, d as nn, c as v, _ as Re, s as Ee, E as zn, u as Hn } from "./menu-V9qTN_Cu.js";
3
+ import { u as Ye } from "./modelComp-5PDCbl8W.js";
4
+ import { s as Te, a as In, b as et, E as Ne } from "./index-fopmc0W_.js";
5
+ const qt = (e, t) => {
6
+ const n = e.storage || sessionStorage, r = e.key || t.$id;
7
+ if (e.paths) {
8
+ const o = e.paths.reduce((s, a) => (s[a] = t.$state[a], s), {});
9
+ n.setItem(r, JSON.stringify(o));
10
+ } else
11
+ n.setItem(r, JSON.stringify(t.$state));
12
+ };
13
+ var Vn = ({ options: e, store: t }) => {
14
+ var n, r, o, s;
15
+ if ((n = e.persist) != null && n.enabled) {
16
+ const a = [{
17
+ key: t.$id,
18
+ storage: sessionStorage
19
+ }], l = (o = (r = e.persist) == null ? void 0 : r.strategies) != null && o.length ? (s = e.persist) == null ? void 0 : s.strategies : a;
20
+ l.forEach((p) => {
21
+ const d = p.storage || sessionStorage, b = p.key || t.$id, i = d.getItem(b);
22
+ i && (t.$patch(JSON.parse(i)), qt(p, t));
23
+ }), t.$subscribe(() => {
24
+ l.forEach((p) => {
25
+ qt(p, t);
26
+ });
27
+ });
28
+ }
29
+ };
30
+ const he = Jn() || Mn();
31
+ he.use(Vn);
32
+ const rn = nn("formToTableComp", {
33
+ state: () => ({
34
+ selectArray: [],
35
+ selectString: ""
36
+ }),
37
+ actions: {
38
+ setSelectArray(e) {
39
+ this.selectArray = e;
40
+ },
41
+ setSelectString(e) {
42
+ this.selectString = e;
43
+ }
44
+ }
45
+ }), Wn = nn("unit", {
46
+ state: () => ({
47
+ selectIndex: "",
48
+ selectMenu: "",
49
+ selectTitle: []
50
+ }),
51
+ actions: {
52
+ setSelectIndex(e) {
53
+ this.selectIndex = e;
54
+ },
55
+ setSelectMenu(e) {
56
+ this.selectMenu = e;
57
+ },
58
+ setSelectTitle(e) {
59
+ this.selectTitle = e;
60
+ }
61
+ }
62
+ }), Kn = (e, t) => {
63
+ const n = t == null ? void 0 : t.split("-");
64
+ return on(e, n);
65
+ }, on = (e, t) => {
66
+ var o;
67
+ let n = e, r = t;
68
+ return Array.isArray(n) ? n = n == null ? void 0 : n[parseInt(v(r == null ? void 0 : r[0]))] : Array.isArray(n == null ? void 0 : n.children) && (n = (o = n == null ? void 0 : n.children) == null ? void 0 : o[parseInt(v(r == null ? void 0 : r[0]))]), r == null || r.shift(), (r == null ? void 0 : r.length) > 0 && (n = on(n, r)), n;
69
+ }, sn = (e, t) => {
70
+ let n = e, r = t == null ? void 0 : t.filter((o) => (o == null ? void 0 : o.prop) !== "index");
71
+ return Array.isArray(n) && (n = n == null ? void 0 : n.map((o, s) => {
72
+ if (Array.isArray(o)) {
73
+ let a = {};
74
+ return o = o == null ? void 0 : o.forEach((l, p) => {
75
+ var d;
76
+ (d = r == null ? void 0 : r[p]) != null && d.prop ? a[r[p].prop] = l : Array.isArray(l) && (a.children = sn(l, r));
77
+ }), Object.assign(a, { id: s });
78
+ } else
79
+ return o;
80
+ })), n;
81
+ }, Gn = (e, t, n) => {
82
+ if (t === "")
83
+ return e == null ? void 0 : e.filter((r) => (r == null ? void 0 : r.id) === n);
84
+ {
85
+ const r = t.split("-");
86
+ return Xn(e, r, n);
87
+ }
88
+ }, Xn = (e, t, n) => {
89
+ let r = e, o = t;
90
+ return (o == null ? void 0 : o.length) === 0 ? r = r == null ? void 0 : r.filter((s) => s.id !== n) : r = r == null ? void 0 : r.map((s) => (s.id.toString() === (o == null ? void 0 : o[0]) && (o == null || o.shift(), s = an(s, o, n)), s)), r;
91
+ }, an = (e, t, n) => {
92
+ var s, a;
93
+ let r = e, o = t;
94
+ return (o == null ? void 0 : o.length) === 0 ? r.children = (s = r.children) == null ? void 0 : s.filter((l) => l.id !== n) : r.children = (a = r.children) == null ? void 0 : a.map((l) => (l.id.toString() === (o == null ? void 0 : o[0]) && (o == null || o.shift(), l = an(l, o, n)), l)), r;
95
+ }, Zn = (e, t, n) => {
96
+ if (t === "")
97
+ return n;
98
+ {
99
+ const r = t.split("-");
100
+ return Qn(e, r, n);
101
+ }
102
+ }, Qn = (e, t, n) => {
103
+ let r = e, o = t;
104
+ return (o == null ? void 0 : o.length) === 0 ? r = n : r = r == null ? void 0 : r.map((s) => (s.id.toString() === (o == null ? void 0 : o[0]) && (o == null || o.shift(), s = ln(s, o, n)), s)), r;
105
+ }, ln = (e, t, n) => {
106
+ var s;
107
+ let r = e, o = t;
108
+ return (o == null ? void 0 : o.length) === 0 ? r.children = n : r.children = (s = r.children) == null ? void 0 : s.map((a) => (a.id.toString() === (o == null ? void 0 : o[0]) && (o == null || o.shift(), a = ln(a, o, n)), a)), r;
109
+ }, Yn = { class: "table-content" }, er = { class: "extra-header" }, tr = ["onClick"], nr = ["onClick"], rr = {
110
+ key: 0,
111
+ class: "dialog-footer"
112
+ }, or = {
113
+ __name: "index",
114
+ props: {
115
+ itemData: {
116
+ type: Array,
117
+ default: () => []
118
+ },
119
+ childItemData: {
120
+ type: Array,
121
+ default: () => []
122
+ },
123
+ index: Number
124
+ },
125
+ emits: ["change", "contentChange"],
126
+ setup(e, { emit: t }) {
127
+ const n = e, r = t, o = U([]), s = U([]), a = U(""), l = U(), p = U(!0), d = U(0), b = U(!1), i = U(""), T = U(!1), w = U([]), g = U(!1), _ = U([]), f = U([]), h = U(), c = U(), R = rn(he), y = U(), m = Wn(he), { selectIndex: E, selectMenu: S, selectTitle: D } = Ee(m), { selectString: N } = Ee(R), O = U(720), G = () => {
128
+ T.value = !1;
129
+ }, F = (A) => {
130
+ var q, $, x, j, V;
131
+ if (M(A), A != null && A.children && Array.isArray(A == null ? void 0 : A.children)) {
132
+ const J = D.value;
133
+ J.push({ key: S.value === "" ? (q = A == null ? void 0 : A.id) == null ? void 0 : q.toString() : S.value + "-" + (($ = A == null ? void 0 : A.id) == null ? void 0 : $.toString()), value: A[(x = Object.keys(A)) == null ? void 0 : x.filter((W) => W !== "index" && W !== "id")[0]] }), m.setSelectMenu(S.value === "" ? (j = A == null ? void 0 : A.id) == null ? void 0 : j.toString() : S.value + "-" + ((V = A == null ? void 0 : A.id) == null ? void 0 : V.toString())), m.setSelectTitle(J), m.setSelectIndex(n != null && n.index ? n == null ? void 0 : n.index.toString() : "");
134
+ }
135
+ }, M = (A) => {
136
+ var q, $, x;
137
+ if (A != null && A.children && Array.isArray(A == null ? void 0 : A.children)) {
138
+ let j = [];
139
+ const V = (q = v(h.value)) == null ? void 0 : q.filter((J) => (J == null ? void 0 : J.prop) !== "index");
140
+ ($ = A == null ? void 0 : A.children) == null || $.forEach((J, W) => {
141
+ if (!Array.isArray(J))
142
+ j.push(J);
143
+ else {
144
+ let ae = {};
145
+ J == null || J.forEach((le, Ce) => {
146
+ var xe;
147
+ (xe = V == null ? void 0 : V[Ce]) != null && xe.prop ? ae[V[Ce].prop] = le : Array.isArray(le) && (ae.children = le);
148
+ }), j.push(Object.assign(ae, { id: W }));
149
+ }
150
+ }), o.value = (x = v(o.value)) == null ? void 0 : x.filter((J) => (J == null ? void 0 : J.prop) !== "index"), s.value = j;
151
+ }
152
+ }, z = (A, q) => {
153
+ var $;
154
+ if (a.value = "", g.value = !0, p.value = !0, A === "删除") {
155
+ s.value = ($ = v(s.value)) == null ? void 0 : $.filter((j) => (j == null ? void 0 : j.id) !== (q == null ? void 0 : q.id));
156
+ const x = Gn(y.value, S.value, q == null ? void 0 : q.id);
157
+ k(x), r("change", {
158
+ content: x,
159
+ index: n == null ? void 0 : n.index,
160
+ buttonName: A
161
+ });
162
+ } else A === "新增" ? (i.value = "新增", H(""), T.value = !0) : A === "编辑" ? (i.value = "编辑", H(q), T.value = !0) : A === "详情" && (i.value = "详情", H(q), g.value = !1, p.value = !1, T.value = !0);
163
+ }, H = (A) => {
164
+ var $;
165
+ const q = [];
166
+ ($ = v(o.value)) == null || $.forEach((x, j) => {
167
+ x.label !== "" && (x == null ? void 0 : x.label) !== "操作" && q.push({
168
+ label: (x == null ? void 0 : x.label) ?? "",
169
+ name: (x == null ? void 0 : x.prop) ?? "t" + j,
170
+ type: !(x != null && x.type) || (x == null ? void 0 : x.type) === "" ? "Input" : x == null ? void 0 : x.type,
171
+ value: (A == null ? void 0 : A[x == null ? void 0 : x.prop]) ?? "",
172
+ id: (x == null ? void 0 : x.id) ?? j,
173
+ contents: (x == null ? void 0 : x.options) ?? [],
174
+ width: 1
175
+ });
176
+ }), A === "" || !A || (a.value = A == null ? void 0 : A.id), f.value = q;
177
+ };
178
+ Ln(() => {
179
+ });
180
+ const I = () => {
181
+ let A = v(s.value);
182
+ a.value === "" ? (d.value++, A.push(Object.assign(c.value, { id: d.value }))) : A = A == null ? void 0 : A.map(($) => (($ == null ? void 0 : $.id) === a.value && ($ = Object.assign($, c.value)), $)), s.value = A;
183
+ const q = Zn(y.value, S.value, A);
184
+ k(q), T.value = !1, r("change", {
185
+ content: q,
186
+ index: n == null ? void 0 : n.index,
187
+ buttonName: i.value
188
+ });
189
+ }, k = (A) => {
190
+ var $;
191
+ const q = ($ = v(n.itemData)) == null ? void 0 : $.map((x) => ((x == null ? void 0 : x.key) === "tableContents" && (x.contents = A), x));
192
+ r("contentChange", {
193
+ contents: q,
194
+ index: n.index
195
+ });
196
+ }, Q = (A) => {
197
+ c.value = A;
198
+ };
199
+ return pe(
200
+ () => [n.itemData, N.value, E.value, S.value],
201
+ () => {
202
+ var ae, le, Ce, xe, Ot, Tt, At, _t, Ct, xt, Dt, Nt, Ft, Pt, Ut, Bt, jt, $t;
203
+ const A = (ae = v(n.itemData)) == null ? void 0 : ae.filter((P) => (P == null ? void 0 : P.key) === "header"), q = (le = v(n.itemData)) == null ? void 0 : le.find((P) => (P == null ? void 0 : P.key) === "page"), $ = (Ce = v(n.itemData)) == null ? void 0 : Ce.find((P) => (P == null ? void 0 : P.key) === "rowButton"), x = (xe = v(n.itemData)) == null ? void 0 : xe.find((P) => (P == null ? void 0 : P.key) === "extraButton"), j = (Ot = v(n.itemData)) == null ? void 0 : Ot.filter((P) => (P == null ? void 0 : P.key) === "tableContents"), V = (Tt = v(n.itemData)) == null ? void 0 : Tt.filter((P) => (P == null ? void 0 : P.key) === "tableIndex");
204
+ b.value = (q == null ? void 0 : q.contents) ?? !0;
205
+ let J = [];
206
+ N.value === "" ? J = A == null ? void 0 : A[0] : J = (A == null ? void 0 : A.find((P) => (P == null ? void 0 : P.selectLabel) === "(" + N.value + ")")) ?? (A == null ? void 0 : A.find((P) => !(P != null && P.selectLabel)));
207
+ let W = [];
208
+ if (N.value === "" ? W = V == null ? void 0 : V[0] : W = (V == null ? void 0 : V.find((P) => (P == null ? void 0 : P.selectLabel) === "(" + N.value + ")")) ?? (V == null ? void 0 : V.find((P) => !(P != null && P.selectLabel))), ((At = J == null ? void 0 : J.contents) == null ? void 0 : At.length) > 0) {
209
+ const P = [];
210
+ W != null && W.contents && ((_t = W == null ? void 0 : W.contents) == null ? void 0 : _t.length) !== 0 && P.push({
211
+ label: "",
212
+ prop: "index",
213
+ sortable: !1
214
+ }), (Ct = J == null ? void 0 : J.contents) == null || Ct.forEach((C, fe) => {
215
+ (C == null ? void 0 : C.label) !== "" && P.push({
216
+ label: (C == null ? void 0 : C.label) ?? "",
217
+ prop: (C == null ? void 0 : C.label) === "操作" ? "operate" : (C == null ? void 0 : C.prop) ?? "a" + fe,
218
+ width: C != null && C.width ? parseInt(C.width) : "",
219
+ fixed: (C == null ? void 0 : C.fixed) ?? void 0,
220
+ sortable: (C == null ? void 0 : C.sortable) ?? !1,
221
+ align: (C == null ? void 0 : C.align) ?? "center",
222
+ showOverflowTooltip: (C == null ? void 0 : C.showOverflowTooltip) ?? !0,
223
+ isNotDrag: (C == null ? void 0 : C.isNotDrag) ?? !1,
224
+ isEditCol: (C == null ? void 0 : C.isEditCol) ?? !1,
225
+ isOperate: (C == null ? void 0 : C.isOperate) ?? !1,
226
+ id: (C == null ? void 0 : C.id) ?? fe,
227
+ type: (C == null ? void 0 : C.label) === "操作" ? "operate" : void 0
228
+ });
229
+ }), o.value = P;
230
+ let ye = (Dt = (xt = v(o.value)) == null ? void 0 : xt.filter((C) => (C == null ? void 0 : C.type) !== "operate")) == null ? void 0 : Dt.map((C, fe) => ({
231
+ prop: (C == null ? void 0 : C.prop) ?? "a" + fe
232
+ }));
233
+ h.value = ye;
234
+ let me = [];
235
+ if (N.value === "" ? me = j == null ? void 0 : j[0] : me = (j == null ? void 0 : j.find((C) => (C == null ? void 0 : C.selectLabel) === "(" + N.value + ")")) ?? (j == null ? void 0 : j.find((C) => !(C != null && C.selectLabel))), ((Nt = me == null ? void 0 : me.contents) == null ? void 0 : Nt.length) !== 0) {
236
+ let C = v(me == null ? void 0 : me.contents);
237
+ W != null && W.contents && ((Ft = W == null ? void 0 : W.contents) == null ? void 0 : Ft.length) !== 0 && (C = (Pt = v(C)) == null ? void 0 : Pt.map((ie, it) => {
238
+ var we, Oe;
239
+ if (!Array.isArray(ie)) {
240
+ let De = {};
241
+ for (let be in ie)
242
+ be !== "id" && be !== "index" && (De[be] = ie[be]);
243
+ ie = Object.values(De);
244
+ }
245
+ return ie.unshift(((Oe = (we = W == null ? void 0 : W.contents) == null ? void 0 : we[it]) == null ? void 0 : Oe.label) ?? ""), ie;
246
+ }));
247
+ const fe = [];
248
+ C == null || C.forEach((ie, it) => {
249
+ let we = {};
250
+ ie == null || ie.forEach((Oe, De) => {
251
+ var be;
252
+ (be = ye == null ? void 0 : ye[De]) != null && be.prop ? we[ye[De].prop] = Oe : Array.isArray(Oe) && (we.children = sn(Oe, ye));
253
+ }), fe.push(Object.assign(we, { id: it }));
254
+ }), s.value = fe;
255
+ } else {
256
+ let C = (Ut = v(ye)) == null ? void 0 : Ut.reduce((fe, ie) => (fe[ie.prop] = "测试数据", fe), {});
257
+ l.value = C, s.value = [Object.assign({}, l.value, { id: d.value })];
258
+ }
259
+ } else
260
+ o.value = [], s.value = [];
261
+ if (((Bt = $ == null ? void 0 : $.contents) == null ? void 0 : Bt.length) > 0 ? w.value = $ == null ? void 0 : $.contents : w.value = [], ((jt = x == null ? void 0 : x.contents) == null ? void 0 : jt.length) > 0 ? _.value = x == null ? void 0 : x.contents : _.value = [], d.value = (($t = s == null ? void 0 : s.value) == null ? void 0 : $t.length) ?? 0, E.value !== "") {
262
+ const P = Kn(v(s.value), S.value);
263
+ y.value = s.value, M(P);
264
+ }
265
+ },
266
+ { deep: !0, immediate: !0 }
267
+ ), (A, q) => {
268
+ var $;
269
+ return K(), Y("div", Yn, [
270
+ L("div", er, [
271
+ (K(!0), Y(je, null, $e(_.value, (x, j) => (K(), Y("div", {
272
+ class: "extra-contents",
273
+ key: j
274
+ }, [
275
+ L("div", {
276
+ class: "extra-content",
277
+ style: Lt({ background: x == null ? void 0 : x.background }),
278
+ onClick: (V) => z(x == null ? void 0 : x.label, "")
279
+ }, Z(x == null ? void 0 : x.label), 13, tr)
280
+ ]))), 128))
281
+ ]),
282
+ (K(), Be(Te, {
283
+ columns: o.value,
284
+ key: o.value,
285
+ tableData: s.value,
286
+ isShowPagination: b.value,
287
+ isShowEdit: !1,
288
+ isShowDelete: !1,
289
+ onDbClickRow: F
290
+ }, qn({ _: 2 }, [
291
+ (($ = w.value) == null ? void 0 : $.length) > 0 ? {
292
+ name: "actions",
293
+ fn: ce(({ item: x }) => [
294
+ (K(!0), Y(je, null, $e(w.value, (j, V) => (K(), Y("div", { key: V }, [
295
+ L("div", {
296
+ style: Lt({ color: j == null ? void 0 : j.textColor }),
297
+ class: "extra-button-label",
298
+ onClick: (J) => z(j == null ? void 0 : j.label, x)
299
+ }, Z(j == null ? void 0 : j.label), 13, nr)
300
+ ]))), 128))
301
+ ]),
302
+ key: "0"
303
+ } : void 0
304
+ ]), 1032, ["columns", "tableData", "isShowPagination"])),
305
+ ee(In, {
306
+ title: i.value,
307
+ visible: T.value,
308
+ width: O.value,
309
+ onBeforeDestroy: G
310
+ }, {
311
+ default: ce(() => [
312
+ ee(et, {
313
+ rowContents: f.value,
314
+ isEnableWrap: !1,
315
+ onChange: Q,
316
+ isEdit: p.value
317
+ }, null, 8, ["rowContents", "isEdit"])
318
+ ]),
319
+ footer: ce(() => [
320
+ g.value ? (K(), Y("div", rr, [
321
+ L("div", {
322
+ onClick: q[0] || (q[0] = (x) => T.value = !1),
323
+ class: "cancel-button"
324
+ }, Z("取消")),
325
+ L("div", {
326
+ class: "ok-button",
327
+ onClick: I
328
+ }, Z("确认"))
329
+ ])) : en("", !0)
330
+ ]),
331
+ _: 1
332
+ }, 8, ["title", "visible", "width"])
333
+ ]);
334
+ };
335
+ }
336
+ }, sr = /* @__PURE__ */ Re(or, [["__scopeId", "data-v-3405e36c"]]), Me = [
337
+ {
338
+ key: "单选",
339
+ value: "Select"
340
+ },
341
+ {
342
+ key: "日期",
343
+ value: "Date"
344
+ },
345
+ {
346
+ key: "长文本",
347
+ value: "TextArea"
348
+ },
349
+ {
350
+ key: "上传",
351
+ value: "Upload"
352
+ }
353
+ ], ar = (e) => e.match(/\((.*)\)/)[1], lr = { class: "form-content" }, ir = {
354
+ __name: "index",
355
+ props: {
356
+ itemData: {
357
+ type: Array,
358
+ default: () => []
359
+ },
360
+ childItemData: {
361
+ type: Array,
362
+ default: () => []
363
+ },
364
+ index: Number
365
+ },
366
+ emits: ["change", "contentChange"],
367
+ setup(e, { emit: t }) {
368
+ const n = e, r = t, o = U([]), s = U(!1), a = U([]), l = rn(he), p = U(), d = (i) => {
369
+ var f, h, c, R;
370
+ const T = (h = (f = v(n.itemData)) == null ? void 0 : f.find((y) => (y == null ? void 0 : y.key) === "formContent")) == null ? void 0 : h.contents, w = v(i.content);
371
+ let g = {};
372
+ w && ((c = Object.values(w)) == null ? void 0 : c.length) > 0 && ((R = Object.values(w)) == null || R.forEach((y, m) => {
373
+ g[T[m].key] = y;
374
+ }));
375
+ const _ = {
376
+ content: g,
377
+ index: n == null ? void 0 : n.index,
378
+ buttonName: i == null ? void 0 : i.buttonName
379
+ };
380
+ r("change", _);
381
+ }, b = (i) => {
382
+ var g, _;
383
+ if (!i) return;
384
+ if (((g = Object.values(v(i))) == null ? void 0 : g.length) > 0) {
385
+ const f = (_ = Object.values(v(i))) == null ? void 0 : _.map((c) => c);
386
+ let h = "";
387
+ f == null || f.forEach((c) => {
388
+ c !== "" && c !== void 0 && (h = h === "" ? c : h + "/" + c);
389
+ }), l.setSelectArray(f), l.setSelectString(h);
390
+ }
391
+ const T = v(n.itemData), w = T == null ? void 0 : T.map((f) => {
392
+ var h;
393
+ return (f == null ? void 0 : f.key) === "formContent" && ((h = f.contents) == null || h.map((c, R) => {
394
+ var y, m, E, S, D, N, O, G, F, M, z, H, I, k;
395
+ return c.type = c != null && c.type ? c.type : (E = (m = (y = c == null ? void 0 : c.key.split("$")) == null ? void 0 : y[1]) == null ? void 0 : m.split("(")) != null && E[0] ? (S = Me == null ? void 0 : Me.find((Q) => {
396
+ var A, q, $;
397
+ return (Q == null ? void 0 : Q.key) === (($ = (q = (A = c == null ? void 0 : c.key.split("$")) == null ? void 0 : A[1]) == null ? void 0 : q.split("(")) == null ? void 0 : $[0]);
398
+ })) == null ? void 0 : S.value : "Input", c.options = c != null && c.options ? c.options : ((N = (D = c == null ? void 0 : c.key.split("$")) == null ? void 0 : D[1]) == null ? void 0 : N.length) > 0 ? (F = (G = ar((O = c == null ? void 0 : c.key.split("$")) == null ? void 0 : O[1])) == null ? void 0 : G.split(",")) == null ? void 0 : F.map((Q) => ({
399
+ label: Q,
400
+ value: Q
401
+ })) : [], c != null && c.key.includes("$") && (c.key = (M = c == null ? void 0 : c.key.split("$")) == null ? void 0 : M[0]), c.value = c != null && c.value ? c.value : Array.isArray((z = Object.values(i)) == null ? void 0 : z[R]) ? (I = (H = Object.values(i)) == null ? void 0 : H[R]) == null ? void 0 : I[0] : (k = Object.values(i)) == null ? void 0 : k[R], c;
402
+ })), f;
403
+ });
404
+ r("contentChange", {
405
+ contents: w,
406
+ index: n.index
407
+ });
408
+ };
409
+ return pe(
410
+ () => n.itemData,
411
+ () => {
412
+ var _, f, h, c, R, y, m, E, S, D;
413
+ const i = (_ = v(n.itemData)) == null ? void 0 : _.find((N) => (N == null ? void 0 : N.key) === "formContent"), T = (f = v(n.itemData)) == null ? void 0 : f.find((N) => (N == null ? void 0 : N.key) === "formButton"), w = (h = v(n.itemData)) == null ? void 0 : h.find((N) => (N == null ? void 0 : N.key) === "formFlex"), g = (c = v(n.itemData)) == null ? void 0 : c.find((N) => (N == null ? void 0 : N.key) === "formWrap");
414
+ if ((g == null ? void 0 : g.contents) === "纵向" ? s.value = !1 : s.value = !0, p.value = typeof (w == null ? void 0 : w.contents) != "boolean" ? !(!(w != null && w.contents) === "" || ((R = w == null ? void 0 : w.contents) == null ? void 0 : R.toUpperCase()) === "VERTICAL") : w == null ? void 0 : w.contents, ((y = i == null ? void 0 : i.contents) == null ? void 0 : y.length) > 0) {
415
+ const N = [];
416
+ (m = i == null ? void 0 : i.contents) == null || m.forEach((F, M) => {
417
+ var z, H, I, k, Q, A, q, $, x;
418
+ if ((F == null ? void 0 : F.label) !== "") {
419
+ let j = (F == null ? void 0 : F.key) ?? "", V = (F == null ? void 0 : F.type) ?? "", J = (F == null ? void 0 : F.options) ?? [];
420
+ if (F != null && F.key.includes("$") && (j = (z = v(F == null ? void 0 : F.key).split("$")) == null ? void 0 : z[0], ((I = (H = v(F == null ? void 0 : F.key).split("$")) == null ? void 0 : H[1]) == null ? void 0 : I.length) > 0)) {
421
+ const [W, ae] = (Q = (k = v(F == null ? void 0 : F.key).split("$")) == null ? void 0 : k[1]) == null ? void 0 : Q.split(/[()]/);
422
+ V = ((A = Me.find((le) => (le == null ? void 0 : le.key) === W)) == null ? void 0 : A.value) ?? "", ((q = ae == null ? void 0 : ae.split(",")) == null ? void 0 : q.length) > 0 && (J = ($ = ae == null ? void 0 : ae.split(",")) == null ? void 0 : $.map((le) => ({
423
+ label: le,
424
+ value: le
425
+ })));
426
+ }
427
+ N.push({
428
+ label: j ?? "",
429
+ name: "t" + M,
430
+ type: V === "" ? "Input" : V,
431
+ value: (J == null ? void 0 : J.length) > 0 ? (x = J == null ? void 0 : J[0]) == null ? void 0 : x.value : (F == null ? void 0 : F.value) ?? "",
432
+ id: (F == null ? void 0 : F.id) ?? M,
433
+ contents: J ?? [],
434
+ width: (F == null ? void 0 : F.width) ?? 1
435
+ });
436
+ }
437
+ });
438
+ const O = (E = v(N)) == null ? void 0 : E.map((F) => F.value);
439
+ let G = "";
440
+ O == null || O.forEach((F) => {
441
+ F !== "" && F !== void 0 && (G = G === "" ? F : G + "/" + F);
442
+ }), l.setSelectArray(O), l.setSelectString(G), o.value = N;
443
+ } else
444
+ o.value = [];
445
+ if (((S = T == null ? void 0 : T.contents) == null ? void 0 : S.length) > 0) {
446
+ const N = [];
447
+ (D = T == null ? void 0 : T.contents) == null || D.forEach((O, G) => {
448
+ (O == null ? void 0 : O.label) !== "" && N.push({
449
+ label: (O == null ? void 0 : O.label) ?? "",
450
+ id: (O == null ? void 0 : O.id) ?? G,
451
+ type: (O == null ? void 0 : O.type) ?? "",
452
+ background: O == null ? void 0 : O.background
453
+ });
454
+ }), a.value = N;
455
+ } else
456
+ a.value = [];
457
+ },
458
+ { deep: !0, immediate: !0 }
459
+ ), (i, T) => (K(), Y("div", lr, [
460
+ ee(et, {
461
+ rowContents: o.value,
462
+ buttonValue: a.value,
463
+ isRowFlex: p.value,
464
+ isEnableWrap: !1,
465
+ onOnButtonClick: d,
466
+ onChange: b,
467
+ isButtonRow: s.value
468
+ }, null, 8, ["rowContents", "buttonValue", "isRowFlex", "isButtonRow"])
469
+ ]));
470
+ }
471
+ }, cr = /* @__PURE__ */ Re(ir, [["__scopeId", "data-v-56c22bdb"]]), ur = { class: "table-operate-content" }, fr = { class: "table-operate-item" }, dr = { class: "operate-title" }, pr = { class: "operate-content" }, hr = { class: "operate-title" }, mr = { class: "operate-content" }, yr = { class: "operate-title" }, br = { class: "operate-content" }, gr = { class: "operate-content" }, vr = {
472
+ __name: "operate",
473
+ props: {
474
+ itemContents: {
475
+ type: Array,
476
+ default: () => []
477
+ },
478
+ originalItemContents: {
479
+ type: Array,
480
+ default: () => []
481
+ }
482
+ },
483
+ emits: ["change"],
484
+ setup(e, { emit: t }) {
485
+ const n = e, r = t, o = U([]), s = U([]), a = U([]), l = U([{
486
+ label: "按钮名称",
487
+ prop: "label",
488
+ type: "edit"
489
+ }, {
490
+ label: "按钮类型",
491
+ prop: "type",
492
+ type: "edit"
493
+ }, {
494
+ label: "按钮背景颜色",
495
+ prop: "background",
496
+ type: "edit",
497
+ columnType: "Color"
498
+ }, {
499
+ label: "操作",
500
+ prop: "operate",
501
+ type: "operate",
502
+ sortable: !1
503
+ }]), p = U([{
504
+ label: "标签名称",
505
+ prop: "label",
506
+ type: "edit"
507
+ }, {
508
+ label: "标签类型",
509
+ prop: "type",
510
+ type: "edit"
511
+ }, {
512
+ label: "按钮文字颜色",
513
+ prop: "textColor",
514
+ type: "edit",
515
+ columnType: "Color"
516
+ }, {
517
+ label: "操作",
518
+ prop: "operate",
519
+ type: "operate",
520
+ sortable: !1
521
+ }]), d = U([]), b = U(0), i = U([{
522
+ name: "isPagination",
523
+ label: "是否显示分页",
524
+ type: "Switch",
525
+ value: !0
526
+ }]), T = [{
527
+ label: "标签名",
528
+ prop: "label",
529
+ type: "edit"
530
+ }, {
531
+ label: "属性名",
532
+ prop: "prop",
533
+ type: "edit"
534
+ }, {
535
+ label: "宽度",
536
+ prop: "width",
537
+ type: "edit",
538
+ columnType: "Number"
539
+ }, {
540
+ label: "是否固定列",
541
+ prop: "fixed",
542
+ type: "edit",
543
+ columnType: "Radio",
544
+ contents: [{
545
+ label: "left",
546
+ value: "左"
547
+ }, {
548
+ label: "right",
549
+ value: "右"
550
+ }]
551
+ }, {
552
+ label: "是否支持排序",
553
+ prop: "sortable",
554
+ type: "edit",
555
+ columnType: "Switch"
556
+ }, {
557
+ label: "文本所在位置",
558
+ prop: "align",
559
+ type: "edit",
560
+ columnType: "Radio",
561
+ contents: [{
562
+ label: "left",
563
+ value: "左"
564
+ }, {
565
+ label: "center",
566
+ value: "中"
567
+ }, {
568
+ label: "right",
569
+ value: "右"
570
+ }]
571
+ }, {
572
+ label: "溢出悬浮文字",
573
+ prop: "showOverflowTooltip",
574
+ type: "edit",
575
+ columnType: "Switch"
576
+ }, {
577
+ label: "是否不可拖动",
578
+ prop: "isNotDrag",
579
+ type: "edit",
580
+ columnType: "Switch"
581
+ }, {
582
+ label: "是否可编辑列名",
583
+ //暂不支持
584
+ prop: "isEditCol",
585
+ type: "edit",
586
+ columnType: "Switch"
587
+ }, {
588
+ label: "是否出现在附属界面",
589
+ //暂不支持
590
+ prop: "isOperate",
591
+ type: "edit",
592
+ columnType: "Switch"
593
+ }, {
594
+ label: "操作",
595
+ prop: "operate",
596
+ type: "operate",
597
+ sortable: !1
598
+ }], w = (y) => {
599
+ let m = v(o.value);
600
+ const E = m == null ? void 0 : m.find((S) => S.key === "page");
601
+ (E == null ? void 0 : E.contents) !== void 0 ? m = m == null ? void 0 : m.map((S) => ((S == null ? void 0 : S.key) === "page" && (S.contents = y == null ? void 0 : y.isPagination), S)) : m.push({
602
+ key: "page",
603
+ contents: y == null ? void 0 : y.isPagination
604
+ }), o.value = m;
605
+ };
606
+ pe(
607
+ () => n.originalItemContents,
608
+ () => {
609
+ var y, m, E, S, D, N, O, G, F, M, z, H, I;
610
+ !n.originalItemContents || n.originalItemContents.length === 0 || (o.value = v(n.originalItemContents), s.value = (m = (y = o.value) == null ? void 0 : y.find((k) => (k == null ? void 0 : k.key) === "header")) == null ? void 0 : m.contents, a.value = (S = (E = o.value) == null ? void 0 : E.find((k) => (k == null ? void 0 : k.key) === "rowButton")) == null ? void 0 : S.contents, l.value = (N = (D = o.value) == null ? void 0 : D.find((k) => (k == null ? void 0 : k.key) === "extraButton")) == null ? void 0 : N.contents, i.value = (G = (O = o.value) == null ? void 0 : O.find((k) => (k == null ? void 0 : k.key) === "page")) != null && G.contents ? [{
611
+ name: "isPagination",
612
+ label: "是否显示分页",
613
+ type: "Switch",
614
+ value: (M = (F = o.value) == null ? void 0 : F.find((k) => (k == null ? void 0 : k.key) === "page")) == null ? void 0 : M.contents
615
+ }] : [{
616
+ name: "isPagination",
617
+ label: "是否显示分页",
618
+ type: "Switch",
619
+ value: !0
620
+ }], s.value = (z = s.value) == null ? void 0 : z.map((k, Q) => k = {
621
+ label: (k == null ? void 0 : k.label) ?? "",
622
+ prop: (k == null ? void 0 : k.label) === "操作" ? "operate" : k == null ? void 0 : k.prop,
623
+ width: k != null && k.width ? parseInt(k.width) : "",
624
+ fixed: (k == null ? void 0 : k.fixed) ?? void 0,
625
+ sortable: (k == null ? void 0 : k.sortable) ?? !1,
626
+ align: (k == null ? void 0 : k.align) ?? "center",
627
+ showOverflowTooltip: (k == null ? void 0 : k.showOverflowTooltip) ?? !0,
628
+ isNotDrag: (k == null ? void 0 : k.isNotDrag) ?? !1,
629
+ isEditCol: (k == null ? void 0 : k.isEditCol) ?? !1,
630
+ isOperate: (k == null ? void 0 : k.isOperate) ?? !1,
631
+ id: (k == null ? void 0 : k.id) ?? Q
632
+ }), a.value = (H = a.value) == null ? void 0 : H.map((k, Q) => k = {
633
+ label: (k == null ? void 0 : k.label) ?? "",
634
+ type: (k == null ? void 0 : k.type) ?? "",
635
+ textColor: (k == null ? void 0 : k.textColor) ?? "#000000",
636
+ id: (k == null ? void 0 : k.id) ?? Q
637
+ }), l.value = (I = l.value) == null ? void 0 : I.map((k, Q) => k = {
638
+ label: (k == null ? void 0 : k.label) ?? "",
639
+ type: (k == null ? void 0 : k.type) ?? "",
640
+ background: (k == null ? void 0 : k.textColor) ?? "#FFFFFF",
641
+ id: (k == null ? void 0 : k.id) ?? Q
642
+ }));
643
+ },
644
+ { deep: !0, immediate: !0 }
645
+ ), pe(
646
+ () => i.value,
647
+ () => {
648
+ var E;
649
+ let y = v(o.value);
650
+ const m = y == null ? void 0 : y.find((S) => S.key === "page");
651
+ m != null && m.contents ? y = y == null ? void 0 : y.map((S) => {
652
+ var D;
653
+ return (S == null ? void 0 : S.key) === "page" && (S.contents = (D = i.value) == null ? void 0 : D[0].value), S;
654
+ }) : y.push({
655
+ key: "page",
656
+ contents: (E = i.value) == null ? void 0 : E[0].value
657
+ }), o.value = y;
658
+ },
659
+ { immediate: !0, deep: !0 }
660
+ );
661
+ const g = () => {
662
+ const y = v(s.value);
663
+ let m = v(o.value);
664
+ y.push({
665
+ label: "",
666
+ prop: "",
667
+ width: "",
668
+ fixed: void 0,
669
+ sortable: !1,
670
+ align: "center",
671
+ showOverflowTooltip: !0,
672
+ isNotDrag: !1,
673
+ isEditCol: !1,
674
+ isOperate: !1,
675
+ id: b.value
676
+ }), s.value = y, b.value++;
677
+ const E = m == null ? void 0 : m.find((S) => (S == null ? void 0 : S.key) === "header");
678
+ E != null && E.contents ? (E.contents = y, m = m == null ? void 0 : m.map((S) => ((S == null ? void 0 : S.key) === "header" && (S.contents = y), S))) : m.push({
679
+ key: "header",
680
+ contents: y
681
+ }), o.value = m;
682
+ }, _ = () => {
683
+ const y = v(a.value);
684
+ let m = v(o.value);
685
+ y.push({
686
+ label: "",
687
+ type: "",
688
+ textColor: "#000000",
689
+ id: b.value
690
+ }), a.value = y, b.value++;
691
+ const E = m == null ? void 0 : m.find((S) => (S == null ? void 0 : S.key) === "rowButton");
692
+ E != null && E.contents ? (E.contents = y, m = m == null ? void 0 : m.map((S) => ((S == null ? void 0 : S.key) === "rowButton" && (S.contents = y), S))) : m.push({
693
+ key: "rowButton",
694
+ contents: y
695
+ }), o.value = m;
696
+ }, f = () => {
697
+ const y = v(d.value);
698
+ let m = v(o.value);
699
+ y.push({
700
+ label: "",
701
+ type: "",
702
+ background: "#FFFFFF",
703
+ id: b.value
704
+ }), d.value = y, b.value++;
705
+ const E = m == null ? void 0 : m.find((S) => (S == null ? void 0 : S.key) === "extraButton");
706
+ E != null && E.contents ? (E.contents = y, m = m == null ? void 0 : m.map((S) => ((S == null ? void 0 : S.key) === "extraButton" && (S.contents = y), S))) : m.push({
707
+ key: "extraButton",
708
+ contents: y
709
+ }), o.value = m;
710
+ }, h = (y) => {
711
+ const m = v(a.value);
712
+ let E = v(o.value);
713
+ a.value = m.filter((D) => D.id !== y.id);
714
+ const S = E == null ? void 0 : E.find((D) => D.key === "rowButton");
715
+ S != null && S.contents && (E = E == null ? void 0 : E.map((D) => ((D == null ? void 0 : D.key) === "rowButton" && (D.contents = m.filter((N) => N.id !== y.id)), D))), o.value = E;
716
+ }, c = (y) => {
717
+ const m = v(d.value);
718
+ let E = v(o.value);
719
+ d.value = m.filter((D) => D.id !== y.id);
720
+ const S = E == null ? void 0 : E.find((D) => D.key === "extraButton");
721
+ S != null && S.contents && (E = E == null ? void 0 : E.map((D) => ((D == null ? void 0 : D.key) === "extraButton" && (D.contents = m.filter((N) => N.id !== y.id)), D))), o.value = E;
722
+ }, R = (y) => {
723
+ const m = v(s.value);
724
+ let E = v(o.value);
725
+ s.value = m.filter((D) => D.id !== y.id);
726
+ const S = E == null ? void 0 : E.find((D) => D.key === "header");
727
+ S != null && S.contents && (E = E == null ? void 0 : E.map((D) => ((D == null ? void 0 : D.key) === "header" && (D.contents = m.filter((N) => N.id !== y.id)), D))), o.value = E;
728
+ };
729
+ return pe(
730
+ () => [o.value, s.value],
731
+ () => {
732
+ let y = v(o.value);
733
+ const m = y == null ? void 0 : y.find((E) => (E == null ? void 0 : E.key) === "header");
734
+ m != null && m.contents ? (m.contents = s.value, y = y == null ? void 0 : y.map((E) => ((E == null ? void 0 : E.key) === "header" && (E.contents = s.value), E))) : y.push({
735
+ key: "header",
736
+ contents: s.value
737
+ }), r("change", y);
738
+ },
739
+ { deep: !0, immediate: !0 }
740
+ ), (y, m) => {
741
+ const E = Ge("el-button");
742
+ return K(), Y("div", ur, [
743
+ L("div", fr, [
744
+ L("div", dr, [
745
+ m[1] || (m[1] = L("div", null, Z("表头"), -1)),
746
+ ee(E, {
747
+ class: "blue-operate-button",
748
+ icon: "ele-Plus",
749
+ onClick: g
750
+ }, {
751
+ default: ce(() => m[0] || (m[0] = [
752
+ Ue(Z("新建"))
753
+ ])),
754
+ _: 1
755
+ })
756
+ ]),
757
+ L("div", pr, [
758
+ ee(Te, {
759
+ columns: T,
760
+ isShowPagination: !1,
761
+ isShowEdit: !1,
762
+ isMoveColumn: !1,
763
+ tableData: s.value,
764
+ onDeleteRow: R
765
+ }, null, 8, ["tableData"])
766
+ ]),
767
+ L("div", hr, [
768
+ m[3] || (m[3] = L("div", null, Z("行内按钮"), -1)),
769
+ ee(E, {
770
+ class: "blue-operate-button",
771
+ icon: "ele-Plus",
772
+ onClick: _
773
+ }, {
774
+ default: ce(() => m[2] || (m[2] = [
775
+ Ue(Z("新建"))
776
+ ])),
777
+ _: 1
778
+ })
779
+ ]),
780
+ L("div", mr, [
781
+ ee(Te, {
782
+ columns: p.value,
783
+ isShowPagination: !1,
784
+ isShowEdit: !1,
785
+ isMoveColumn: !1,
786
+ tableData: a.value,
787
+ onDeleteRow: h
788
+ }, null, 8, ["columns", "tableData"])
789
+ ]),
790
+ L("div", yr, [
791
+ m[5] || (m[5] = L("div", null, Z("表格外部按钮"), -1)),
792
+ ee(E, {
793
+ class: "blue-operate-button",
794
+ icon: "ele-Plus",
795
+ onClick: f
796
+ }, {
797
+ default: ce(() => m[4] || (m[4] = [
798
+ Ue(Z("新建"))
799
+ ])),
800
+ _: 1
801
+ })
802
+ ]),
803
+ L("div", br, [
804
+ ee(Te, {
805
+ columns: l.value,
806
+ isShowPagination: !1,
807
+ isShowEdit: !1,
808
+ isMoveColumn: !1,
809
+ tableData: d.value,
810
+ onDeleteRow: c
811
+ }, null, 8, ["columns", "tableData"])
812
+ ]),
813
+ m[6] || (m[6] = L("div", { class: "operate-title" }, [
814
+ L("div", null, Z("分页"))
815
+ ], -1)),
816
+ L("div", gr, [
817
+ ee(et, {
818
+ rowContents: i.value,
819
+ onChange: w
820
+ }, null, 8, ["rowContents"])
821
+ ])
822
+ ])
823
+ ]);
824
+ };
825
+ }
826
+ }, kr = /* @__PURE__ */ Re(vr, [["__scopeId", "data-v-877911eb"]]), Er = { class: "form-operate-content" }, Sr = { class: "form-operate-item" }, Rr = { class: "operate-title" }, wr = { class: "operate-content" }, Or = { class: "operate-title" }, Tr = { class: "operate-content" }, Ar = { class: "operate-content" }, _r = {
827
+ __name: "operate",
828
+ props: {
829
+ itemContents: {
830
+ type: Array,
831
+ default: () => []
832
+ },
833
+ originalItemContents: {
834
+ type: Array,
835
+ default: () => []
836
+ }
837
+ },
838
+ emits: ["change"],
839
+ setup(e, { emit: t }) {
840
+ const n = e, r = t, o = U([{
841
+ name: "isRowFlex",
842
+ label: "是否横向布局",
843
+ type: "Switch",
844
+ value: !0
845
+ }]), s = U([{
846
+ label: "字段名称",
847
+ prop: "label",
848
+ type: "edit"
849
+ }, {
850
+ label: "字段类型",
851
+ prop: "type",
852
+ type: "edit"
853
+ }, {
854
+ label: "字段值",
855
+ prop: "key",
856
+ type: "edit"
857
+ }, {
858
+ label: "字段选项值",
859
+ prop: "options",
860
+ type: "edit"
861
+ }, {
862
+ label: "操作",
863
+ prop: "operate",
864
+ type: "operate",
865
+ sortable: !1
866
+ }]), a = U([{
867
+ label: "字段名称",
868
+ prop: "label",
869
+ type: "edit"
870
+ }, {
871
+ label: "字段类型",
872
+ prop: "type",
873
+ type: "edit"
874
+ }, {
875
+ label: "按钮背景颜色",
876
+ prop: "background",
877
+ type: "edit",
878
+ columnType: "Color"
879
+ }, {
880
+ label: "操作",
881
+ prop: "operate",
882
+ type: "operate",
883
+ sortable: !1
884
+ }]), l = U([]), p = U([]), d = U([]), b = U(0);
885
+ pe(
886
+ () => n.originalItemContents,
887
+ () => {
888
+ var f, h, c, R, y, m, E, S, D, N;
889
+ !n.originalItemContents || n.originalItemContents.length === 0 || (p.value = v(n.originalItemContents), d.value = (h = (f = p.value) == null ? void 0 : f.find((O) => (O == null ? void 0 : O.key) === "formContent")) == null ? void 0 : h.contents, l.value = (R = (c = p.value) == null ? void 0 : c.find((O) => (O == null ? void 0 : O.key) === "formButton")) == null ? void 0 : R.contents, d.value = (y = d.value) == null ? void 0 : y.map((O, G) => O = {
890
+ label: (O == null ? void 0 : O.label) ?? "",
891
+ type: (O == null ? void 0 : O.type) ?? "",
892
+ key: (O == null ? void 0 : O.key) ?? "",
893
+ options: (O == null ? void 0 : O.options) ?? "",
894
+ id: (O == null ? void 0 : O.id) ?? G
895
+ }), l.value = (m = l.value) == null ? void 0 : m.map((O, G) => O = {
896
+ label: (O == null ? void 0 : O.label) ?? "",
897
+ type: (O == null ? void 0 : O.type) ?? "",
898
+ background: (O == null ? void 0 : O.background) ?? "#000000",
899
+ id: (O == null ? void 0 : O.id) ?? G
900
+ }), o.value = (S = (E = p.value) == null ? void 0 : E.find((O) => (O == null ? void 0 : O.key) === "formFlex")) != null && S.contents ? [{
901
+ name: "isRowFlex",
902
+ label: "是否横向布局",
903
+ type: "Switch",
904
+ value: (N = (D = p.value) == null ? void 0 : D.find((O) => (O == null ? void 0 : O.key) === "formFlex")) == null ? void 0 : N.contents
905
+ }] : [{
906
+ name: "isRowFlex",
907
+ label: "是否横向布局",
908
+ type: "Switch",
909
+ value: !0
910
+ }]);
911
+ },
912
+ { deep: !0, immediate: !0 }
913
+ );
914
+ const i = () => {
915
+ const f = v(l.value);
916
+ let h = v(p.value);
917
+ f.push({
918
+ label: "",
919
+ type: "",
920
+ background: "#000000",
921
+ id: b.value
922
+ }), l.value = f, b.value++;
923
+ const c = h == null ? void 0 : h.find((R) => (R == null ? void 0 : R.key) === "formButton");
924
+ c != null && c.contents ? (c.contents = f, h = h == null ? void 0 : h.map((R) => ((R == null ? void 0 : R.key) === "formButton" && (R.contents = f), R))) : h.push({
925
+ key: "formButton",
926
+ contents: f
927
+ }), p.value = h;
928
+ }, T = () => {
929
+ const f = v(d.value);
930
+ let h = v(p.value);
931
+ f.push({
932
+ label: "",
933
+ type: "",
934
+ key: "",
935
+ options: "",
936
+ id: b.value
937
+ }), d.value = f, b.value++;
938
+ const c = h == null ? void 0 : h.find((R) => (R == null ? void 0 : R.key) === "formContent");
939
+ c != null && c.contents ? (c.contents = f, h = h == null ? void 0 : h.map((R) => ((R == null ? void 0 : R.key) === "formContent" && (R.contents = f), R))) : h.push({
940
+ key: "formContent",
941
+ contents: f
942
+ }), p.value = h;
943
+ }, w = (f) => {
944
+ const h = v(l.value);
945
+ let c = v(p.value);
946
+ l.value = h.filter((y) => y.id !== f.id);
947
+ const R = c == null ? void 0 : c.find((y) => y.key === "formButton");
948
+ R != null && R.contents && (c = c == null ? void 0 : c.map((y) => ((y == null ? void 0 : y.key) === "formButton" && (y.contents = h.filter((m) => m.id !== f.id)), y))), p.value = c;
949
+ }, g = (f) => {
950
+ const h = v(d.value);
951
+ let c = v(p.value);
952
+ d.value = h.filter((y) => y.id !== f.id);
953
+ const R = c == null ? void 0 : c.find((y) => y.key === "formContent");
954
+ R != null && R.contents && (c = c == null ? void 0 : c.map((y) => ((y == null ? void 0 : y.key) === "formContent" && (y.contents = h.filter((m) => m.id !== f.id)), y))), p.value = c;
955
+ }, _ = (f) => {
956
+ let h = v(p.value);
957
+ const c = h == null ? void 0 : h.find((R) => R.key === "formFlex");
958
+ (c == null ? void 0 : c.contents) !== void 0 ? h = h == null ? void 0 : h.map((R) => ((R == null ? void 0 : R.key) === "formFlex" && (R.contents = f == null ? void 0 : f.isRowFlex), R)) : h.push({
959
+ key: "formFlex",
960
+ contents: f == null ? void 0 : f.isRowFlex
961
+ }), p.value = h;
962
+ };
963
+ return pe(
964
+ () => [p.value, d.value],
965
+ () => {
966
+ let f = v(p.value);
967
+ const h = f == null ? void 0 : f.find((c) => (c == null ? void 0 : c.key) === "formContent");
968
+ h != null && h.contents ? (h.contents = d.value, f = f == null ? void 0 : f.map((c) => ((c == null ? void 0 : c.key) === "formContent" && (c.contents = d.value), c))) : f.push({
969
+ key: "formContent",
970
+ contents: d.value
971
+ }), r("change", f);
972
+ },
973
+ { deep: !0, immediate: !0 }
974
+ ), (f, h) => {
975
+ const c = Ge("el-button");
976
+ return K(), Y("div", Er, [
977
+ L("div", Sr, [
978
+ L("div", Rr, [
979
+ h[1] || (h[1] = L("div", null, Z("表单信息"), -1)),
980
+ ee(c, {
981
+ class: "blue-operate-button",
982
+ icon: "ele-Plus",
983
+ onClick: T
984
+ }, {
985
+ default: ce(() => h[0] || (h[0] = [
986
+ Ue(Z("新建"))
987
+ ])),
988
+ _: 1
989
+ })
990
+ ]),
991
+ L("div", wr, [
992
+ ee(Te, {
993
+ columns: s.value,
994
+ isShowPagination: !1,
995
+ isShowEdit: !1,
996
+ isMoveColumn: !1,
997
+ tableData: d.value,
998
+ onDeleteRow: g
999
+ }, null, 8, ["columns", "tableData"])
1000
+ ]),
1001
+ L("div", Or, [
1002
+ h[3] || (h[3] = L("div", null, Z("表单按钮"), -1)),
1003
+ ee(c, {
1004
+ class: "blue-operate-button",
1005
+ icon: "ele-Plus",
1006
+ onClick: i
1007
+ }, {
1008
+ default: ce(() => h[2] || (h[2] = [
1009
+ Ue(Z("新建"))
1010
+ ])),
1011
+ _: 1
1012
+ })
1013
+ ]),
1014
+ L("div", Tr, [
1015
+ ee(Te, {
1016
+ columns: a.value,
1017
+ isShowPagination: !1,
1018
+ isShowEdit: !1,
1019
+ isMoveColumn: !1,
1020
+ tableData: l.value,
1021
+ onDeleteRow: w
1022
+ }, null, 8, ["columns", "tableData"])
1023
+ ]),
1024
+ h[4] || (h[4] = L("div", { class: "operate-title" }, [
1025
+ L("div", null, Z("表单布局"))
1026
+ ], -1)),
1027
+ L("div", Ar, [
1028
+ ee(et, {
1029
+ rowContents: o.value,
1030
+ onChange: _
1031
+ }, null, 8, ["rowContents"])
1032
+ ])
1033
+ ])
1034
+ ]);
1035
+ };
1036
+ }
1037
+ }, Cr = /* @__PURE__ */ Re(_r, [["__scopeId", "data-v-a36b8468"]]), xr = U([
1038
+ {
1039
+ name: "表格",
1040
+ type: "table",
1041
+ comp: "Table",
1042
+ icon: "Grid"
1043
+ },
1044
+ {
1045
+ name: "表单",
1046
+ type: "form",
1047
+ comp: "Form",
1048
+ icon: "Film"
1049
+ }
1050
+ ]), Dr = {
1051
+ Table: sr,
1052
+ Form: cr,
1053
+ TableOperate: kr,
1054
+ FormOperate: Cr
1055
+ // 添加其他组件...
1056
+ };
1057
+ function cn(e) {
1058
+ return Dr[e] || null;
1059
+ }
1060
+ const Nr = { class: "type-select" }, Fr = ["onClick"], Pr = { class: "list-icon" }, Ur = {
1061
+ __name: "index",
1062
+ setup(e) {
1063
+ const t = Ye(he), { itemData: n } = Ee(t), r = (s) => zn[s], o = (s) => {
1064
+ const a = v(n.value);
1065
+ a.push({
1066
+ comp: s.comp,
1067
+ name: s.name,
1068
+ compData: []
1069
+ }), t.setItemData(a);
1070
+ };
1071
+ return (s, a) => (K(), Y("div", Nr, [
1072
+ (K(!0), Y(je, null, $e(tn(xr), (l, p) => (K(), Y("div", {
1073
+ class: "type-list",
1074
+ key: p
1075
+ }, [
1076
+ L("div", {
1077
+ class: "list-content",
1078
+ onClick: (d) => o(l)
1079
+ }, [
1080
+ L("div", Pr, [
1081
+ (K(), Be(Et(r(l.icon))))
1082
+ ]),
1083
+ L("div", null, Z(l.name), 1)
1084
+ ], 8, Fr)
1085
+ ]))), 128))
1086
+ ]));
1087
+ }
1088
+ }, Bs = /* @__PURE__ */ Re(Ur, [["__scopeId", "data-v-fe4aecc8"]]), Br = { class: "fill-content" }, jr = { class: "operate-content" }, $r = { class: "collapse-title" }, Lr = { class: "comp-child" }, qr = {
1089
+ __name: "index",
1090
+ setup(e) {
1091
+ const t = Ye(he), { itemData: n, originalData: r } = Ee(t), o = U([]), s = U([]);
1092
+ pe(
1093
+ () => n.value,
1094
+ () => {
1095
+ var p;
1096
+ !n.value || ((p = n.value) == null ? void 0 : p.length) === 0 || (o.value = v(n.value));
1097
+ },
1098
+ { deep: !0, immediate: !0 }
1099
+ );
1100
+ const a = (p) => cn(p), l = (p, d, b) => {
1101
+ if (!p || p.length === 0) return;
1102
+ let i = v(n.value);
1103
+ const T = v(d);
1104
+ T.compData = p, i = i == null ? void 0 : i.map((w, g) => (g === b && (w = T), w)), t.setItemData(i);
1105
+ };
1106
+ return (p, d) => {
1107
+ const b = Ge("el-collapse-item"), i = Ge("el-collapse");
1108
+ return K(), Y("div", Br, [
1109
+ d[1] || (d[1] = L("div", { class: "fill-operate" }, Z("操作栏"), -1)),
1110
+ L("div", jr, [
1111
+ ee(i, {
1112
+ modelValue: s.value,
1113
+ "onUpdate:modelValue": d[0] || (d[0] = (T) => s.value = T),
1114
+ class: "collapse-content"
1115
+ }, {
1116
+ default: ce(() => [
1117
+ (K(!0), Y(je, null, $e(o.value, (T, w) => (K(), Be(b, {
1118
+ key: w,
1119
+ name: w
1120
+ }, {
1121
+ title: ce(() => [
1122
+ L("div", $r, Z(T.name), 1)
1123
+ ]),
1124
+ default: ce(() => {
1125
+ var g, _;
1126
+ return [
1127
+ L("div", Lr, [
1128
+ (K(), Be(Et(a(T.comp + "Operate")), {
1129
+ itemContents: T == null ? void 0 : T.compData,
1130
+ originalItemContents: (_ = (g = tn(r)) == null ? void 0 : g.find((f, h) => h === w)) == null ? void 0 : _.compData,
1131
+ onChange: (f) => l(f, T, w)
1132
+ }, null, 40, ["itemContents", "originalItemContents", "onChange"]))
1133
+ ])
1134
+ ];
1135
+ }),
1136
+ _: 2
1137
+ }, 1032, ["name"]))), 128))
1138
+ ]),
1139
+ _: 1
1140
+ }, 8, ["modelValue"])
1141
+ ])
1142
+ ]);
1143
+ };
1144
+ }
1145
+ }, js = /* @__PURE__ */ Re(qr, [["__scopeId", "data-v-a216b035"]]), Jr = {
1146
+ key: 0,
1147
+ class: "show-content"
1148
+ }, Mr = {
1149
+ __name: "index",
1150
+ setup(e) {
1151
+ const t = Ye(he), { itemData: n } = Ee(t), r = U([]);
1152
+ pe(
1153
+ () => n.value,
1154
+ () => {
1155
+ var s;
1156
+ !n.value || ((s = n.value) == null ? void 0 : s.length) === 0 || (r.value = v(n.value));
1157
+ },
1158
+ { deep: !0, immediate: !0 }
1159
+ );
1160
+ const o = (s) => cn(s);
1161
+ return (s, a) => {
1162
+ var l;
1163
+ return ((l = r.value) == null ? void 0 : l.length) > 0 ? (K(), Y("div", Jr, [
1164
+ (K(!0), Y(je, null, $e(r.value, (p, d) => (K(), Y("div", {
1165
+ class: "item-content",
1166
+ key: d
1167
+ }, [
1168
+ L("div", null, Z(p.name), 1),
1169
+ (K(), Be(Et(o(p.comp)), {
1170
+ itemData: p == null ? void 0 : p.compData,
1171
+ childItemData: p == null ? void 0 : p.itemChildData,
1172
+ key: d
1173
+ }, null, 8, ["itemData", "childItemData"]))
1174
+ ]))), 128))
1175
+ ])) : en("", !0);
1176
+ };
1177
+ }
1178
+ }, $s = /* @__PURE__ */ Re(Mr, [["__scopeId", "data-v-79320497"]]), re = [
1179
+ {
1180
+ key: "FormName",
1181
+ value: "Form"
1182
+ },
1183
+ {
1184
+ key: "TableName",
1185
+ value: "Table"
1186
+ },
1187
+ {
1188
+ key: "MenuName",
1189
+ value: "Menu"
1190
+ },
1191
+ {
1192
+ key: "GroupName",
1193
+ value: "Group"
1194
+ },
1195
+ {
1196
+ key: "SystemKey",
1197
+ value: "System"
1198
+ }
1199
+ ], ne = [
1200
+ {
1201
+ key: "FormDirect",
1202
+ value: "formFlex"
1203
+ },
1204
+ {
1205
+ key: "Form",
1206
+ value: "formContent"
1207
+ },
1208
+ {
1209
+ key: "FormButton",
1210
+ value: "formButton"
1211
+ },
1212
+ {
1213
+ key: "FormFlex",
1214
+ value: "formWrap"
1215
+ },
1216
+ {
1217
+ key: "TableColumns",
1218
+ value: "header"
1219
+ },
1220
+ {
1221
+ key: "TableButton",
1222
+ value: "extraButton"
1223
+ },
1224
+ {
1225
+ key: "LineButton",
1226
+ value: "rowButton"
1227
+ },
1228
+ {
1229
+ key: "Table",
1230
+ value: "tableContents"
1231
+ },
1232
+ {
1233
+ key: "TableIndex",
1234
+ value: "tableIndex"
1235
+ },
1236
+ {
1237
+ key: "Menus",
1238
+ value: "menuContents"
1239
+ },
1240
+ {
1241
+ key: "GroupContents",
1242
+ value: "groupContents"
1243
+ }
1244
+ ], ze = U(0), ct = U(0), zr = (e) => {
1245
+ let t;
1246
+ e.includes(`\r
1247
+ `) ? t = e.split(`\r
1248
+ `).filter((o) => o.trim() !== "") : t = e.split(`
1249
+ `).filter((o) => o.trim() !== "");
1250
+ const n = [];
1251
+ let r = "";
1252
+ for (const o of t)
1253
+ o.includes("{") || r.includes("{") || o.includes("[") || r.includes("[") || o.includes("【") || r.includes("【") || o.includes("(") || r.includes("(") || o.includes("(") || r.includes("(") ? (r += o.trim(), v(r).split("{").length - 1 === v(r).split("}").length - 1 && v(r).split("【").length - 1 === v(r).split("】").length - 1 && v(r).split("[").length - 1 === v(r).split("]").length - 1 && v(r).split("(").length - 1 === v(r).split(")").length - 1 && v(r).split("(").length - 1 === v(r).split(")").length - 1 && (n.push(r), r = "")) : n.push(o.trim());
1254
+ return n;
1255
+ }, Hr = (e) => {
1256
+ const t = e.trim().replace(/^'|'$/g, ""), n = /((?:\$?[a-zA-Z_][a-zA-Z0-9_]*\$?\([^)]*\))|[a-zA-Z_][a-zA-Z0-9_]*)\s*=\s*(.*?)(?=\s*(?:(?:\$?[a-zA-Z_][a-zA-Z0-9_]*\$?\([^)]*\))|[a-zA-Z_][a-zA-Z0-9_]*)\s*=|$)/g, r = {};
1257
+ let o;
1258
+ for (; (o = n.exec(t)) !== null; ) {
1259
+ const s = o[1];
1260
+ let a = o[2].trim();
1261
+ (a.match(/\[/g) || []).length !== (a.match(/\]/g) || []).length && (a = a == null ? void 0 : a.replace(/]$/, "")), r[s] ? (r[s + ct.value] && ct.value++, r[s + ct.value] = s + "=" + a) : r[s] = s + "=" + a;
1262
+ }
1263
+ return r;
1264
+ }, un = (e) => {
1265
+ const [t, n] = e.split("=").map((s) => s.trim()), r = t.replace(/['"]/g, ""), o = n.replace(/^['"]|['"]$/g, "");
1266
+ return { key: r, value: o };
1267
+ }, Ir = (e) => {
1268
+ var a;
1269
+ let t = [];
1270
+ const [n, r] = e.split(/=(.+)/), o = n.replace(/['"]/g, "").trim(), s = r.replace(/^['"]|['"]$/g, "");
1271
+ return (a = Object.values(Hr(s))) == null || a.forEach((l) => {
1272
+ t.push(un(l));
1273
+ }), { key: o, value: t };
1274
+ }, Ie = (e) => {
1275
+ try {
1276
+ return JSON.parse(e), !0;
1277
+ } catch {
1278
+ return !1;
1279
+ }
1280
+ }, fn = (e) => {
1281
+ try {
1282
+ const t = e.replace(/[’]|[‘]|[']/g, '"').replace(/,/g, ",").replace(/:/g, ":").replace(/:\s*(?=,|}|$)/g, ': ""');
1283
+ if (v(t).split("{").length - 1 > 1) {
1284
+ let n = v(t).replace(/^\{(.*)\}$/, "[$1]");
1285
+ if (Ie(n) && !n.includes("$") || (n = n.replace(/"([^"]+)"\$([\w\u4e00-\u9fa5]+\([^)]*\))/g, '"$1$$$2"')), Ie(n)) {
1286
+ const r = JSON.parse(n);
1287
+ let o = [];
1288
+ return r == null || r.forEach((s) => {
1289
+ var a;
1290
+ (a = Object.entries(v(s))) == null || a.forEach((l) => {
1291
+ ze.value++, o.push({
1292
+ id: ze.value,
1293
+ key: (l == null ? void 0 : l[0]) ?? "",
1294
+ value: (l == null ? void 0 : l[1]) === "" ? "" : l == null ? void 0 : l[1],
1295
+ // 如果值为空,则key设为空字符串,否则保留原值
1296
+ width: Object.keys(v(s)).length
1297
+ });
1298
+ });
1299
+ }), o;
1300
+ } else
1301
+ return console.error("转换类型不正确:"), [];
1302
+ } else if (Ie(t)) {
1303
+ const n = JSON.parse(t);
1304
+ return Object.entries(n).map(([r, o]) => (ze.value++, {
1305
+ id: ze.value,
1306
+ key: r,
1307
+ value: o === "" ? "" : o,
1308
+ // 如果值为空,则key设为空字符串,否则保留原值
1309
+ width: 1
1310
+ }));
1311
+ } else
1312
+ return t;
1313
+ } catch (t) {
1314
+ return console.error("转换失败:", t), [];
1315
+ }
1316
+ }, Vr = (e, t) => {
1317
+ try {
1318
+ if (re != null && re.find((n) => (n == null ? void 0 : n.key) === t))
1319
+ return JSON.parse(e.replace(/[’]|[‘]|[']/g, '"'));
1320
+ if (v(e).split("[").length - 1 > 1) {
1321
+ const n = v(e).replace(/[’]|[‘]|[']/g, '"').replaceAll(/,/g, ",").replaceAll("(", "[").replaceAll(")", "]").replaceAll("],]", "]]");
1322
+ return JSON.parse(n);
1323
+ } else {
1324
+ const n = v(e).replace(/[’]|[‘]|[']/g, '"').replace(/,/g, ",");
1325
+ if (Ie(n)) {
1326
+ const r = JSON.parse(n);
1327
+ return Array.isArray(r) ? r.map((o) => ({ label: o })) : r;
1328
+ } else
1329
+ return fn(v(e));
1330
+ }
1331
+ } catch (n) {
1332
+ return console.error("解析失败:", n), e;
1333
+ }
1334
+ }, Wr = (e) => ({ [e == null ? void 0 : e.key]: Vr(e == null ? void 0 : e.value, e == null ? void 0 : e.key) }), Kr = (e) => {
1335
+ try {
1336
+ if (v(e).split("[").length - 1 > 1) {
1337
+ const t = v(e).replace(/[’]|[‘]|[']/g, '"').replaceAll(/,/g, ",").replaceAll("(", "[").replaceAll(")", "]").replaceAll("],]", "]]");
1338
+ return JSON.parse(t);
1339
+ } else
1340
+ return JSON.parse(v(e).replace(/[’]|[‘]|[']/g, '"').replace(/,/g, ",")).map((n) => ({ label: n }));
1341
+ } catch (t) {
1342
+ return console.error("解析失败:", t), e;
1343
+ }
1344
+ }, Ls = (e) => {
1345
+ var s, a, l, p, d, b;
1346
+ const t = zr((a = (s = v(e)) == null ? void 0 : s.replace("(", "(")) == null ? void 0 : a.replace(")", ")")), n = (l = v(t)) == null ? void 0 : l.map((i) => {
1347
+ var w, g;
1348
+ let T = (g = (w = v(i)) == null ? void 0 : w.split("=")) == null ? void 0 : g[0];
1349
+ return T != null && T.includes("GroupContents") ? Ir(i) : un(i);
1350
+ }), r = [];
1351
+ (p = v(n)) == null || p.forEach((i) => {
1352
+ var T, w, g, _, f;
1353
+ re != null && re.find((h) => {
1354
+ var c, R;
1355
+ return ((c = h == null ? void 0 : h.key) == null ? void 0 : c.toUpperCase()) === ((R = i == null ? void 0 : i.key) == null ? void 0 : R.toUpperCase());
1356
+ }) ? r.push({
1357
+ comp: ((T = re == null ? void 0 : re.find((h) => {
1358
+ var c, R;
1359
+ return ((c = h == null ? void 0 : h.key) == null ? void 0 : c.toUpperCase()) === ((R = i == null ? void 0 : i.key) == null ? void 0 : R.toUpperCase());
1360
+ })) == null ? void 0 : T.value) ?? "",
1361
+ name: (w = i == null ? void 0 : i.value) == null ? void 0 : w.replace(/[’]|[‘]|[']/g, ""),
1362
+ compData: []
1363
+ }) : ne != null && ne.find((h) => {
1364
+ var c, R;
1365
+ return ((c = h == null ? void 0 : h.key) == null ? void 0 : c.toUpperCase()) === ((R = i == null ? void 0 : i.key) == null ? void 0 : R.toUpperCase());
1366
+ }) && ((r == null ? void 0 : r.length) === 0 && (g = i.key) != null && g.includes("Menus") && r.push({
1367
+ comp: "Menu",
1368
+ name: "",
1369
+ compData: []
1370
+ }), (_ = r == null ? void 0 : r[(r == null ? void 0 : r.length) - 1]) != null && _.compData && r[(r == null ? void 0 : r.length) - 1].compData.push({
1371
+ key: (f = ne == null ? void 0 : ne.find((h) => {
1372
+ var c, R;
1373
+ return ((c = h == null ? void 0 : h.key) == null ? void 0 : c.toUpperCase()) === ((R = i == null ? void 0 : i.key) == null ? void 0 : R.toUpperCase());
1374
+ })) == null ? void 0 : f.value,
1375
+ contents: i == null ? void 0 : i.value
1376
+ }));
1377
+ });
1378
+ let o = (d = v(r)) == null ? void 0 : d.map((i) => {
1379
+ var T;
1380
+ return i != null && i.compData && (i.compData = (T = i == null ? void 0 : i.compData) == null ? void 0 : T.map((w) => {
1381
+ var g, _, f, h, c, R, y, m, E, S, D;
1382
+ if ((w == null ? void 0 : w.key) === "formFlex")
1383
+ w.contents = ((_ = (g = w.contents) == null ? void 0 : g.replace(/[’]|[‘]|[']/g, "")) == null ? void 0 : _.toUpperCase()) !== "Vertical".toUpperCase();
1384
+ else if ((w == null ? void 0 : w.key) === "groupContents")
1385
+ w.contents = (f = v(w.contents)) == null ? void 0 : f.map((N) => Wr(v(N)));
1386
+ else if (((c = (h = w.contents) == null ? void 0 : h.trim()) != null && c.startsWith("[") || (y = (R = w.contents) == null ? void 0 : R.trim()) != null && y.startsWith("【")) && ((E = (m = w.contents) == null ? void 0 : m.trim()) != null && E.endsWith("]") || (D = (S = w.contents) == null ? void 0 : S.trim()) != null && D.endsWith("】")))
1387
+ w.contents = Kr(v(w.contents));
1388
+ else {
1389
+ if (!w.contents) return;
1390
+ w.contents = fn(v(w.contents));
1391
+ }
1392
+ return w;
1393
+ })), i;
1394
+ });
1395
+ return o = (b = v(o)) == null ? void 0 : b.map((i) => {
1396
+ var T;
1397
+ return (i == null ? void 0 : i.comp) === "Group" && (i.compData = (T = i.compData) == null ? void 0 : T.map((w) => {
1398
+ var _;
1399
+ let g = [];
1400
+ return (_ = w.contents) == null || _.forEach((f) => {
1401
+ var h, c, R, y, m, E, S, D, N, O, G, F;
1402
+ if (re != null && re.find((M) => {
1403
+ var z, H, I;
1404
+ return ((z = M == null ? void 0 : M.key) == null ? void 0 : z.toUpperCase()) === ((I = (H = Object.keys(f)) == null ? void 0 : H[0]) == null ? void 0 : I.toUpperCase());
1405
+ }))
1406
+ g.push({
1407
+ comp: (h = re == null ? void 0 : re.find((M) => {
1408
+ var z, H, I;
1409
+ return ((z = M == null ? void 0 : M.key) == null ? void 0 : z.toUpperCase()) === ((I = (H = Object.keys(f)) == null ? void 0 : H[0]) == null ? void 0 : I.toUpperCase());
1410
+ })) == null ? void 0 : h.value,
1411
+ name: (R = (c = Object.values(f)) == null ? void 0 : c[0]) == null ? void 0 : R.replace(/[’]|[‘]|[']/g, ""),
1412
+ compData: []
1413
+ });
1414
+ else if (ne != null && ne.find((M) => {
1415
+ var z, H, I;
1416
+ return ((z = M == null ? void 0 : M.key) == null ? void 0 : z.toUpperCase()) === ((I = (H = Object.keys(f)) == null ? void 0 : H[0]) == null ? void 0 : I.toUpperCase());
1417
+ })) {
1418
+ if ((g == null ? void 0 : g.length) === 0) return;
1419
+ (y = g == null ? void 0 : g[(g == null ? void 0 : g.length) - 1]) != null && y.compData && g[(g == null ? void 0 : g.length) - 1].compData.push({
1420
+ key: (m = ne == null ? void 0 : ne.find((M) => {
1421
+ var z, H, I;
1422
+ return ((z = M == null ? void 0 : M.key) == null ? void 0 : z.toUpperCase()) === ((I = (H = Object.keys(f)) == null ? void 0 : H[0]) == null ? void 0 : I.toUpperCase());
1423
+ })) == null ? void 0 : m.value,
1424
+ contents: (E = Object.values(f)) == null ? void 0 : E[0]
1425
+ });
1426
+ } else if ((D = (S = Object.keys(f)) == null ? void 0 : S[0]) != null && D.includes("$")) {
1427
+ const M = (O = (N = Object.keys(v(f))) == null ? void 0 : N[0]) == null ? void 0 : O.split("$");
1428
+ g[(g == null ? void 0 : g.length) - 1].compData.push({
1429
+ key: (G = ne == null ? void 0 : ne.find((z) => {
1430
+ var H, I;
1431
+ return ((H = z == null ? void 0 : z.key) == null ? void 0 : H.toUpperCase()) === ((I = M == null ? void 0 : M[0]) == null ? void 0 : I.toUpperCase());
1432
+ })) == null ? void 0 : G.value,
1433
+ contents: (F = Object.values(f)) == null ? void 0 : F[0],
1434
+ selectLabel: M == null ? void 0 : M[1]
1435
+ });
1436
+ }
1437
+ return f;
1438
+ }), w.contents = g, w;
1439
+ })), i;
1440
+ }), o;
1441
+ };
1442
+ function dn(e, t) {
1443
+ return function() {
1444
+ return e.apply(t, arguments);
1445
+ };
1446
+ }
1447
+ const { toString: Gr } = Object.prototype, { getPrototypeOf: St } = Object, { iterator: tt, toStringTag: pn } = Symbol, nt = /* @__PURE__ */ ((e) => (t) => {
1448
+ const n = Gr.call(t);
1449
+ return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
1450
+ })(/* @__PURE__ */ Object.create(null)), ue = (e) => (e = e.toLowerCase(), (t) => nt(t) === e), rt = (e) => (t) => typeof t === e, { isArray: Ae } = Array, Le = rt("undefined");
1451
+ function Xr(e) {
1452
+ return e !== null && !Le(e) && e.constructor !== null && !Le(e.constructor) && oe(e.constructor.isBuffer) && e.constructor.isBuffer(e);
1453
+ }
1454
+ const hn = ue("ArrayBuffer");
1455
+ function Zr(e) {
1456
+ let t;
1457
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && hn(e.buffer), t;
1458
+ }
1459
+ const Qr = rt("string"), oe = rt("function"), mn = rt("number"), ot = (e) => e !== null && typeof e == "object", Yr = (e) => e === !0 || e === !1, Ve = (e) => {
1460
+ if (nt(e) !== "object")
1461
+ return !1;
1462
+ const t = St(e);
1463
+ return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(pn in e) && !(tt in e);
1464
+ }, eo = ue("Date"), to = ue("File"), no = ue("Blob"), ro = ue("FileList"), oo = (e) => ot(e) && oe(e.pipe), so = (e) => {
1465
+ let t;
1466
+ return e && (typeof FormData == "function" && e instanceof FormData || oe(e.append) && ((t = nt(e)) === "formdata" || // detect form-data instance
1467
+ t === "object" && oe(e.toString) && e.toString() === "[object FormData]"));
1468
+ }, ao = ue("URLSearchParams"), [lo, io, co, uo] = ["ReadableStream", "Request", "Response", "Headers"].map(ue), fo = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
1469
+ function qe(e, t, { allOwnKeys: n = !1 } = {}) {
1470
+ if (e === null || typeof e > "u")
1471
+ return;
1472
+ let r, o;
1473
+ if (typeof e != "object" && (e = [e]), Ae(e))
1474
+ for (r = 0, o = e.length; r < o; r++)
1475
+ t.call(null, e[r], r, e);
1476
+ else {
1477
+ const s = n ? Object.getOwnPropertyNames(e) : Object.keys(e), a = s.length;
1478
+ let l;
1479
+ for (r = 0; r < a; r++)
1480
+ l = s[r], t.call(null, e[l], l, e);
1481
+ }
1482
+ }
1483
+ function yn(e, t) {
1484
+ t = t.toLowerCase();
1485
+ const n = Object.keys(e);
1486
+ let r = n.length, o;
1487
+ for (; r-- > 0; )
1488
+ if (o = n[r], t === o.toLowerCase())
1489
+ return o;
1490
+ return null;
1491
+ }
1492
+ const ge = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, bn = (e) => !Le(e) && e !== ge;
1493
+ function pt() {
1494
+ const { caseless: e } = bn(this) && this || {}, t = {}, n = (r, o) => {
1495
+ const s = e && yn(t, o) || o;
1496
+ Ve(t[s]) && Ve(r) ? t[s] = pt(t[s], r) : Ve(r) ? t[s] = pt({}, r) : Ae(r) ? t[s] = r.slice() : t[s] = r;
1497
+ };
1498
+ for (let r = 0, o = arguments.length; r < o; r++)
1499
+ arguments[r] && qe(arguments[r], n);
1500
+ return t;
1501
+ }
1502
+ const po = (e, t, n, { allOwnKeys: r } = {}) => (qe(t, (o, s) => {
1503
+ n && oe(o) ? e[s] = dn(o, n) : e[s] = o;
1504
+ }, { allOwnKeys: r }), e), ho = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), mo = (e, t, n, r) => {
1505
+ e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
1506
+ value: t.prototype
1507
+ }), n && Object.assign(e.prototype, n);
1508
+ }, yo = (e, t, n, r) => {
1509
+ let o, s, a;
1510
+ const l = {};
1511
+ if (t = t || {}, e == null) return t;
1512
+ do {
1513
+ for (o = Object.getOwnPropertyNames(e), s = o.length; s-- > 0; )
1514
+ a = o[s], (!r || r(a, e, t)) && !l[a] && (t[a] = e[a], l[a] = !0);
1515
+ e = n !== !1 && St(e);
1516
+ } while (e && (!n || n(e, t)) && e !== Object.prototype);
1517
+ return t;
1518
+ }, bo = (e, t, n) => {
1519
+ e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
1520
+ const r = e.indexOf(t, n);
1521
+ return r !== -1 && r === n;
1522
+ }, go = (e) => {
1523
+ if (!e) return null;
1524
+ if (Ae(e)) return e;
1525
+ let t = e.length;
1526
+ if (!mn(t)) return null;
1527
+ const n = new Array(t);
1528
+ for (; t-- > 0; )
1529
+ n[t] = e[t];
1530
+ return n;
1531
+ }, vo = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && St(Uint8Array)), ko = (e, t) => {
1532
+ const r = (e && e[tt]).call(e);
1533
+ let o;
1534
+ for (; (o = r.next()) && !o.done; ) {
1535
+ const s = o.value;
1536
+ t.call(e, s[0], s[1]);
1537
+ }
1538
+ }, Eo = (e, t) => {
1539
+ let n;
1540
+ const r = [];
1541
+ for (; (n = e.exec(t)) !== null; )
1542
+ r.push(n);
1543
+ return r;
1544
+ }, So = ue("HTMLFormElement"), Ro = (e) => e.toLowerCase().replace(
1545
+ /[-_\s]([a-z\d])(\w*)/g,
1546
+ function(n, r, o) {
1547
+ return r.toUpperCase() + o;
1548
+ }
1549
+ ), Jt = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), wo = ue("RegExp"), gn = (e, t) => {
1550
+ const n = Object.getOwnPropertyDescriptors(e), r = {};
1551
+ qe(n, (o, s) => {
1552
+ let a;
1553
+ (a = t(o, s, e)) !== !1 && (r[s] = a || o);
1554
+ }), Object.defineProperties(e, r);
1555
+ }, Oo = (e) => {
1556
+ gn(e, (t, n) => {
1557
+ if (oe(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
1558
+ return !1;
1559
+ const r = e[n];
1560
+ if (oe(r)) {
1561
+ if (t.enumerable = !1, "writable" in t) {
1562
+ t.writable = !1;
1563
+ return;
1564
+ }
1565
+ t.set || (t.set = () => {
1566
+ throw Error("Can not rewrite read-only method '" + n + "'");
1567
+ });
1568
+ }
1569
+ });
1570
+ }, To = (e, t) => {
1571
+ const n = {}, r = (o) => {
1572
+ o.forEach((s) => {
1573
+ n[s] = !0;
1574
+ });
1575
+ };
1576
+ return Ae(e) ? r(e) : r(String(e).split(t)), n;
1577
+ }, Ao = () => {
1578
+ }, _o = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
1579
+ function Co(e) {
1580
+ return !!(e && oe(e.append) && e[pn] === "FormData" && e[tt]);
1581
+ }
1582
+ const xo = (e) => {
1583
+ const t = new Array(10), n = (r, o) => {
1584
+ if (ot(r)) {
1585
+ if (t.indexOf(r) >= 0)
1586
+ return;
1587
+ if (!("toJSON" in r)) {
1588
+ t[o] = r;
1589
+ const s = Ae(r) ? [] : {};
1590
+ return qe(r, (a, l) => {
1591
+ const p = n(a, o + 1);
1592
+ !Le(p) && (s[l] = p);
1593
+ }), t[o] = void 0, s;
1594
+ }
1595
+ }
1596
+ return r;
1597
+ };
1598
+ return n(e, 0);
1599
+ }, Do = ue("AsyncFunction"), No = (e) => e && (ot(e) || oe(e)) && oe(e.then) && oe(e.catch), vn = ((e, t) => e ? setImmediate : t ? ((n, r) => (ge.addEventListener("message", ({ source: o, data: s }) => {
1600
+ o === ge && s === n && r.length && r.shift()();
1601
+ }, !1), (o) => {
1602
+ r.push(o), ge.postMessage(n, "*");
1603
+ }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
1604
+ typeof setImmediate == "function",
1605
+ oe(ge.postMessage)
1606
+ ), Fo = typeof queueMicrotask < "u" ? queueMicrotask.bind(ge) : typeof process < "u" && process.nextTick || vn, Po = (e) => e != null && oe(e[tt]), u = {
1607
+ isArray: Ae,
1608
+ isArrayBuffer: hn,
1609
+ isBuffer: Xr,
1610
+ isFormData: so,
1611
+ isArrayBufferView: Zr,
1612
+ isString: Qr,
1613
+ isNumber: mn,
1614
+ isBoolean: Yr,
1615
+ isObject: ot,
1616
+ isPlainObject: Ve,
1617
+ isReadableStream: lo,
1618
+ isRequest: io,
1619
+ isResponse: co,
1620
+ isHeaders: uo,
1621
+ isUndefined: Le,
1622
+ isDate: eo,
1623
+ isFile: to,
1624
+ isBlob: no,
1625
+ isRegExp: wo,
1626
+ isFunction: oe,
1627
+ isStream: oo,
1628
+ isURLSearchParams: ao,
1629
+ isTypedArray: vo,
1630
+ isFileList: ro,
1631
+ forEach: qe,
1632
+ merge: pt,
1633
+ extend: po,
1634
+ trim: fo,
1635
+ stripBOM: ho,
1636
+ inherits: mo,
1637
+ toFlatObject: yo,
1638
+ kindOf: nt,
1639
+ kindOfTest: ue,
1640
+ endsWith: bo,
1641
+ toArray: go,
1642
+ forEachEntry: ko,
1643
+ matchAll: Eo,
1644
+ isHTMLForm: So,
1645
+ hasOwnProperty: Jt,
1646
+ hasOwnProp: Jt,
1647
+ // an alias to avoid ESLint no-prototype-builtins detection
1648
+ reduceDescriptors: gn,
1649
+ freezeMethods: Oo,
1650
+ toObjectSet: To,
1651
+ toCamelCase: Ro,
1652
+ noop: Ao,
1653
+ toFiniteNumber: _o,
1654
+ findKey: yn,
1655
+ global: ge,
1656
+ isContextDefined: bn,
1657
+ isSpecCompliantForm: Co,
1658
+ toJSONObject: xo,
1659
+ isAsyncFn: Do,
1660
+ isThenable: No,
1661
+ setImmediate: vn,
1662
+ asap: Fo,
1663
+ isIterable: Po
1664
+ };
1665
+ function B(e, t, n, r, o) {
1666
+ Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), o && (this.response = o, this.status = o.status ? o.status : null);
1667
+ }
1668
+ u.inherits(B, Error, {
1669
+ toJSON: function() {
1670
+ return {
1671
+ // Standard
1672
+ message: this.message,
1673
+ name: this.name,
1674
+ // Microsoft
1675
+ description: this.description,
1676
+ number: this.number,
1677
+ // Mozilla
1678
+ fileName: this.fileName,
1679
+ lineNumber: this.lineNumber,
1680
+ columnNumber: this.columnNumber,
1681
+ stack: this.stack,
1682
+ // Axios
1683
+ config: u.toJSONObject(this.config),
1684
+ code: this.code,
1685
+ status: this.status
1686
+ };
1687
+ }
1688
+ });
1689
+ const kn = B.prototype, En = {};
1690
+ [
1691
+ "ERR_BAD_OPTION_VALUE",
1692
+ "ERR_BAD_OPTION",
1693
+ "ECONNABORTED",
1694
+ "ETIMEDOUT",
1695
+ "ERR_NETWORK",
1696
+ "ERR_FR_TOO_MANY_REDIRECTS",
1697
+ "ERR_DEPRECATED",
1698
+ "ERR_BAD_RESPONSE",
1699
+ "ERR_BAD_REQUEST",
1700
+ "ERR_CANCELED",
1701
+ "ERR_NOT_SUPPORT",
1702
+ "ERR_INVALID_URL"
1703
+ // eslint-disable-next-line func-names
1704
+ ].forEach((e) => {
1705
+ En[e] = { value: e };
1706
+ });
1707
+ Object.defineProperties(B, En);
1708
+ Object.defineProperty(kn, "isAxiosError", { value: !0 });
1709
+ B.from = (e, t, n, r, o, s) => {
1710
+ const a = Object.create(kn);
1711
+ return u.toFlatObject(e, a, function(p) {
1712
+ return p !== Error.prototype;
1713
+ }, (l) => l !== "isAxiosError"), B.call(a, e.message, t, n, r, o), a.cause = e, a.name = e.name, s && Object.assign(a, s), a;
1714
+ };
1715
+ const Uo = null;
1716
+ function ht(e) {
1717
+ return u.isPlainObject(e) || u.isArray(e);
1718
+ }
1719
+ function Sn(e) {
1720
+ return u.endsWith(e, "[]") ? e.slice(0, -2) : e;
1721
+ }
1722
+ function Mt(e, t, n) {
1723
+ return e ? e.concat(t).map(function(o, s) {
1724
+ return o = Sn(o), !n && s ? "[" + o + "]" : o;
1725
+ }).join(n ? "." : "") : t;
1726
+ }
1727
+ function Bo(e) {
1728
+ return u.isArray(e) && !e.some(ht);
1729
+ }
1730
+ const jo = u.toFlatObject(u, {}, null, function(t) {
1731
+ return /^is[A-Z]/.test(t);
1732
+ });
1733
+ function st(e, t, n) {
1734
+ if (!u.isObject(e))
1735
+ throw new TypeError("target must be an object");
1736
+ t = t || new FormData(), n = u.toFlatObject(n, {
1737
+ metaTokens: !0,
1738
+ dots: !1,
1739
+ indexes: !1
1740
+ }, !1, function(_, f) {
1741
+ return !u.isUndefined(f[_]);
1742
+ });
1743
+ const r = n.metaTokens, o = n.visitor || b, s = n.dots, a = n.indexes, p = (n.Blob || typeof Blob < "u" && Blob) && u.isSpecCompliantForm(t);
1744
+ if (!u.isFunction(o))
1745
+ throw new TypeError("visitor must be a function");
1746
+ function d(g) {
1747
+ if (g === null) return "";
1748
+ if (u.isDate(g))
1749
+ return g.toISOString();
1750
+ if (!p && u.isBlob(g))
1751
+ throw new B("Blob is not supported. Use a Buffer instead.");
1752
+ return u.isArrayBuffer(g) || u.isTypedArray(g) ? p && typeof Blob == "function" ? new Blob([g]) : Buffer.from(g) : g;
1753
+ }
1754
+ function b(g, _, f) {
1755
+ let h = g;
1756
+ if (g && !f && typeof g == "object") {
1757
+ if (u.endsWith(_, "{}"))
1758
+ _ = r ? _ : _.slice(0, -2), g = JSON.stringify(g);
1759
+ else if (u.isArray(g) && Bo(g) || (u.isFileList(g) || u.endsWith(_, "[]")) && (h = u.toArray(g)))
1760
+ return _ = Sn(_), h.forEach(function(R, y) {
1761
+ !(u.isUndefined(R) || R === null) && t.append(
1762
+ // eslint-disable-next-line no-nested-ternary
1763
+ a === !0 ? Mt([_], y, s) : a === null ? _ : _ + "[]",
1764
+ d(R)
1765
+ );
1766
+ }), !1;
1767
+ }
1768
+ return ht(g) ? !0 : (t.append(Mt(f, _, s), d(g)), !1);
1769
+ }
1770
+ const i = [], T = Object.assign(jo, {
1771
+ defaultVisitor: b,
1772
+ convertValue: d,
1773
+ isVisitable: ht
1774
+ });
1775
+ function w(g, _) {
1776
+ if (!u.isUndefined(g)) {
1777
+ if (i.indexOf(g) !== -1)
1778
+ throw Error("Circular reference detected in " + _.join("."));
1779
+ i.push(g), u.forEach(g, function(h, c) {
1780
+ (!(u.isUndefined(h) || h === null) && o.call(
1781
+ t,
1782
+ h,
1783
+ u.isString(c) ? c.trim() : c,
1784
+ _,
1785
+ T
1786
+ )) === !0 && w(h, _ ? _.concat(c) : [c]);
1787
+ }), i.pop();
1788
+ }
1789
+ }
1790
+ if (!u.isObject(e))
1791
+ throw new TypeError("data must be an object");
1792
+ return w(e), t;
1793
+ }
1794
+ function zt(e) {
1795
+ const t = {
1796
+ "!": "%21",
1797
+ "'": "%27",
1798
+ "(": "%28",
1799
+ ")": "%29",
1800
+ "~": "%7E",
1801
+ "%20": "+",
1802
+ "%00": "\0"
1803
+ };
1804
+ return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(r) {
1805
+ return t[r];
1806
+ });
1807
+ }
1808
+ function Rt(e, t) {
1809
+ this._pairs = [], e && st(e, this, t);
1810
+ }
1811
+ const Rn = Rt.prototype;
1812
+ Rn.append = function(t, n) {
1813
+ this._pairs.push([t, n]);
1814
+ };
1815
+ Rn.toString = function(t) {
1816
+ const n = t ? function(r) {
1817
+ return t.call(this, r, zt);
1818
+ } : zt;
1819
+ return this._pairs.map(function(o) {
1820
+ return n(o[0]) + "=" + n(o[1]);
1821
+ }, "").join("&");
1822
+ };
1823
+ function $o(e) {
1824
+ return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
1825
+ }
1826
+ function wn(e, t, n) {
1827
+ if (!t)
1828
+ return e;
1829
+ const r = n && n.encode || $o;
1830
+ u.isFunction(n) && (n = {
1831
+ serialize: n
1832
+ });
1833
+ const o = n && n.serialize;
1834
+ let s;
1835
+ if (o ? s = o(t, n) : s = u.isURLSearchParams(t) ? t.toString() : new Rt(t, n).toString(r), s) {
1836
+ const a = e.indexOf("#");
1837
+ a !== -1 && (e = e.slice(0, a)), e += (e.indexOf("?") === -1 ? "?" : "&") + s;
1838
+ }
1839
+ return e;
1840
+ }
1841
+ class Ht {
1842
+ constructor() {
1843
+ this.handlers = [];
1844
+ }
1845
+ /**
1846
+ * Add a new interceptor to the stack
1847
+ *
1848
+ * @param {Function} fulfilled The function to handle `then` for a `Promise`
1849
+ * @param {Function} rejected The function to handle `reject` for a `Promise`
1850
+ *
1851
+ * @return {Number} An ID used to remove interceptor later
1852
+ */
1853
+ use(t, n, r) {
1854
+ return this.handlers.push({
1855
+ fulfilled: t,
1856
+ rejected: n,
1857
+ synchronous: r ? r.synchronous : !1,
1858
+ runWhen: r ? r.runWhen : null
1859
+ }), this.handlers.length - 1;
1860
+ }
1861
+ /**
1862
+ * Remove an interceptor from the stack
1863
+ *
1864
+ * @param {Number} id The ID that was returned by `use`
1865
+ *
1866
+ * @returns {Boolean} `true` if the interceptor was removed, `false` otherwise
1867
+ */
1868
+ eject(t) {
1869
+ this.handlers[t] && (this.handlers[t] = null);
1870
+ }
1871
+ /**
1872
+ * Clear all interceptors from the stack
1873
+ *
1874
+ * @returns {void}
1875
+ */
1876
+ clear() {
1877
+ this.handlers && (this.handlers = []);
1878
+ }
1879
+ /**
1880
+ * Iterate over all the registered interceptors
1881
+ *
1882
+ * This method is particularly useful for skipping over any
1883
+ * interceptors that may have become `null` calling `eject`.
1884
+ *
1885
+ * @param {Function} fn The function to call for each interceptor
1886
+ *
1887
+ * @returns {void}
1888
+ */
1889
+ forEach(t) {
1890
+ u.forEach(this.handlers, function(r) {
1891
+ r !== null && t(r);
1892
+ });
1893
+ }
1894
+ }
1895
+ const On = {
1896
+ silentJSONParsing: !0,
1897
+ forcedJSONParsing: !0,
1898
+ clarifyTimeoutError: !1
1899
+ }, Lo = typeof URLSearchParams < "u" ? URLSearchParams : Rt, qo = typeof FormData < "u" ? FormData : null, Jo = typeof Blob < "u" ? Blob : null, Mo = {
1900
+ isBrowser: !0,
1901
+ classes: {
1902
+ URLSearchParams: Lo,
1903
+ FormData: qo,
1904
+ Blob: Jo
1905
+ },
1906
+ protocols: ["http", "https", "file", "blob", "url", "data"]
1907
+ }, wt = typeof window < "u" && typeof document < "u", mt = typeof navigator == "object" && navigator || void 0, zo = wt && (!mt || ["ReactNative", "NativeScript", "NS"].indexOf(mt.product) < 0), Ho = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1908
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Io = wt && window.location.href || "http://localhost", Vo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1909
+ __proto__: null,
1910
+ hasBrowserEnv: wt,
1911
+ hasStandardBrowserEnv: zo,
1912
+ hasStandardBrowserWebWorkerEnv: Ho,
1913
+ navigator: mt,
1914
+ origin: Io
1915
+ }, Symbol.toStringTag, { value: "Module" })), te = {
1916
+ ...Vo,
1917
+ ...Mo
1918
+ };
1919
+ function Wo(e, t) {
1920
+ return st(e, new te.classes.URLSearchParams(), Object.assign({
1921
+ visitor: function(n, r, o, s) {
1922
+ return te.isNode && u.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : s.defaultVisitor.apply(this, arguments);
1923
+ }
1924
+ }, t));
1925
+ }
1926
+ function Ko(e) {
1927
+ return u.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
1928
+ }
1929
+ function Go(e) {
1930
+ const t = {}, n = Object.keys(e);
1931
+ let r;
1932
+ const o = n.length;
1933
+ let s;
1934
+ for (r = 0; r < o; r++)
1935
+ s = n[r], t[s] = e[s];
1936
+ return t;
1937
+ }
1938
+ function Tn(e) {
1939
+ function t(n, r, o, s) {
1940
+ let a = n[s++];
1941
+ if (a === "__proto__") return !0;
1942
+ const l = Number.isFinite(+a), p = s >= n.length;
1943
+ return a = !a && u.isArray(o) ? o.length : a, p ? (u.hasOwnProp(o, a) ? o[a] = [o[a], r] : o[a] = r, !l) : ((!o[a] || !u.isObject(o[a])) && (o[a] = []), t(n, r, o[a], s) && u.isArray(o[a]) && (o[a] = Go(o[a])), !l);
1944
+ }
1945
+ if (u.isFormData(e) && u.isFunction(e.entries)) {
1946
+ const n = {};
1947
+ return u.forEachEntry(e, (r, o) => {
1948
+ t(Ko(r), o, n, 0);
1949
+ }), n;
1950
+ }
1951
+ return null;
1952
+ }
1953
+ function Xo(e, t, n) {
1954
+ if (u.isString(e))
1955
+ try {
1956
+ return (t || JSON.parse)(e), u.trim(e);
1957
+ } catch (r) {
1958
+ if (r.name !== "SyntaxError")
1959
+ throw r;
1960
+ }
1961
+ return (n || JSON.stringify)(e);
1962
+ }
1963
+ const Je = {
1964
+ transitional: On,
1965
+ adapter: ["xhr", "http", "fetch"],
1966
+ transformRequest: [function(t, n) {
1967
+ const r = n.getContentType() || "", o = r.indexOf("application/json") > -1, s = u.isObject(t);
1968
+ if (s && u.isHTMLForm(t) && (t = new FormData(t)), u.isFormData(t))
1969
+ return o ? JSON.stringify(Tn(t)) : t;
1970
+ if (u.isArrayBuffer(t) || u.isBuffer(t) || u.isStream(t) || u.isFile(t) || u.isBlob(t) || u.isReadableStream(t))
1971
+ return t;
1972
+ if (u.isArrayBufferView(t))
1973
+ return t.buffer;
1974
+ if (u.isURLSearchParams(t))
1975
+ return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
1976
+ let l;
1977
+ if (s) {
1978
+ if (r.indexOf("application/x-www-form-urlencoded") > -1)
1979
+ return Wo(t, this.formSerializer).toString();
1980
+ if ((l = u.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
1981
+ const p = this.env && this.env.FormData;
1982
+ return st(
1983
+ l ? { "files[]": t } : t,
1984
+ p && new p(),
1985
+ this.formSerializer
1986
+ );
1987
+ }
1988
+ }
1989
+ return s || o ? (n.setContentType("application/json", !1), Xo(t)) : t;
1990
+ }],
1991
+ transformResponse: [function(t) {
1992
+ const n = this.transitional || Je.transitional, r = n && n.forcedJSONParsing, o = this.responseType === "json";
1993
+ if (u.isResponse(t) || u.isReadableStream(t))
1994
+ return t;
1995
+ if (t && u.isString(t) && (r && !this.responseType || o)) {
1996
+ const a = !(n && n.silentJSONParsing) && o;
1997
+ try {
1998
+ return JSON.parse(t);
1999
+ } catch (l) {
2000
+ if (a)
2001
+ throw l.name === "SyntaxError" ? B.from(l, B.ERR_BAD_RESPONSE, this, null, this.response) : l;
2002
+ }
2003
+ }
2004
+ return t;
2005
+ }],
2006
+ /**
2007
+ * A timeout in milliseconds to abort a request. If set to 0 (default) a
2008
+ * timeout is not created.
2009
+ */
2010
+ timeout: 0,
2011
+ xsrfCookieName: "XSRF-TOKEN",
2012
+ xsrfHeaderName: "X-XSRF-TOKEN",
2013
+ maxContentLength: -1,
2014
+ maxBodyLength: -1,
2015
+ env: {
2016
+ FormData: te.classes.FormData,
2017
+ Blob: te.classes.Blob
2018
+ },
2019
+ validateStatus: function(t) {
2020
+ return t >= 200 && t < 300;
2021
+ },
2022
+ headers: {
2023
+ common: {
2024
+ Accept: "application/json, text/plain, */*",
2025
+ "Content-Type": void 0
2026
+ }
2027
+ }
2028
+ };
2029
+ u.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
2030
+ Je.headers[e] = {};
2031
+ });
2032
+ const Zo = u.toObjectSet([
2033
+ "age",
2034
+ "authorization",
2035
+ "content-length",
2036
+ "content-type",
2037
+ "etag",
2038
+ "expires",
2039
+ "from",
2040
+ "host",
2041
+ "if-modified-since",
2042
+ "if-unmodified-since",
2043
+ "last-modified",
2044
+ "location",
2045
+ "max-forwards",
2046
+ "proxy-authorization",
2047
+ "referer",
2048
+ "retry-after",
2049
+ "user-agent"
2050
+ ]), Qo = (e) => {
2051
+ const t = {};
2052
+ let n, r, o;
2053
+ return e && e.split(`
2054
+ `).forEach(function(a) {
2055
+ o = a.indexOf(":"), n = a.substring(0, o).trim().toLowerCase(), r = a.substring(o + 1).trim(), !(!n || t[n] && Zo[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
2056
+ }), t;
2057
+ }, It = Symbol("internals");
2058
+ function Fe(e) {
2059
+ return e && String(e).trim().toLowerCase();
2060
+ }
2061
+ function We(e) {
2062
+ return e === !1 || e == null ? e : u.isArray(e) ? e.map(We) : String(e);
2063
+ }
2064
+ function Yo(e) {
2065
+ const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
2066
+ let r;
2067
+ for (; r = n.exec(e); )
2068
+ t[r[1]] = r[2];
2069
+ return t;
2070
+ }
2071
+ const es = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
2072
+ function ut(e, t, n, r, o) {
2073
+ if (u.isFunction(r))
2074
+ return r.call(this, t, n);
2075
+ if (o && (t = n), !!u.isString(t)) {
2076
+ if (u.isString(r))
2077
+ return t.indexOf(r) !== -1;
2078
+ if (u.isRegExp(r))
2079
+ return r.test(t);
2080
+ }
2081
+ }
2082
+ function ts(e) {
2083
+ return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
2084
+ }
2085
+ function ns(e, t) {
2086
+ const n = u.toCamelCase(" " + t);
2087
+ ["get", "set", "has"].forEach((r) => {
2088
+ Object.defineProperty(e, r + n, {
2089
+ value: function(o, s, a) {
2090
+ return this[r].call(this, t, o, s, a);
2091
+ },
2092
+ configurable: !0
2093
+ });
2094
+ });
2095
+ }
2096
+ let se = class {
2097
+ constructor(t) {
2098
+ t && this.set(t);
2099
+ }
2100
+ set(t, n, r) {
2101
+ const o = this;
2102
+ function s(l, p, d) {
2103
+ const b = Fe(p);
2104
+ if (!b)
2105
+ throw new Error("header name must be a non-empty string");
2106
+ const i = u.findKey(o, b);
2107
+ (!i || o[i] === void 0 || d === !0 || d === void 0 && o[i] !== !1) && (o[i || p] = We(l));
2108
+ }
2109
+ const a = (l, p) => u.forEach(l, (d, b) => s(d, b, p));
2110
+ if (u.isPlainObject(t) || t instanceof this.constructor)
2111
+ a(t, n);
2112
+ else if (u.isString(t) && (t = t.trim()) && !es(t))
2113
+ a(Qo(t), n);
2114
+ else if (u.isObject(t) && u.isIterable(t)) {
2115
+ let l = {}, p, d;
2116
+ for (const b of t) {
2117
+ if (!u.isArray(b))
2118
+ throw TypeError("Object iterator must return a key-value pair");
2119
+ l[d = b[0]] = (p = l[d]) ? u.isArray(p) ? [...p, b[1]] : [p, b[1]] : b[1];
2120
+ }
2121
+ a(l, n);
2122
+ } else
2123
+ t != null && s(n, t, r);
2124
+ return this;
2125
+ }
2126
+ get(t, n) {
2127
+ if (t = Fe(t), t) {
2128
+ const r = u.findKey(this, t);
2129
+ if (r) {
2130
+ const o = this[r];
2131
+ if (!n)
2132
+ return o;
2133
+ if (n === !0)
2134
+ return Yo(o);
2135
+ if (u.isFunction(n))
2136
+ return n.call(this, o, r);
2137
+ if (u.isRegExp(n))
2138
+ return n.exec(o);
2139
+ throw new TypeError("parser must be boolean|regexp|function");
2140
+ }
2141
+ }
2142
+ }
2143
+ has(t, n) {
2144
+ if (t = Fe(t), t) {
2145
+ const r = u.findKey(this, t);
2146
+ return !!(r && this[r] !== void 0 && (!n || ut(this, this[r], r, n)));
2147
+ }
2148
+ return !1;
2149
+ }
2150
+ delete(t, n) {
2151
+ const r = this;
2152
+ let o = !1;
2153
+ function s(a) {
2154
+ if (a = Fe(a), a) {
2155
+ const l = u.findKey(r, a);
2156
+ l && (!n || ut(r, r[l], l, n)) && (delete r[l], o = !0);
2157
+ }
2158
+ }
2159
+ return u.isArray(t) ? t.forEach(s) : s(t), o;
2160
+ }
2161
+ clear(t) {
2162
+ const n = Object.keys(this);
2163
+ let r = n.length, o = !1;
2164
+ for (; r--; ) {
2165
+ const s = n[r];
2166
+ (!t || ut(this, this[s], s, t, !0)) && (delete this[s], o = !0);
2167
+ }
2168
+ return o;
2169
+ }
2170
+ normalize(t) {
2171
+ const n = this, r = {};
2172
+ return u.forEach(this, (o, s) => {
2173
+ const a = u.findKey(r, s);
2174
+ if (a) {
2175
+ n[a] = We(o), delete n[s];
2176
+ return;
2177
+ }
2178
+ const l = t ? ts(s) : String(s).trim();
2179
+ l !== s && delete n[s], n[l] = We(o), r[l] = !0;
2180
+ }), this;
2181
+ }
2182
+ concat(...t) {
2183
+ return this.constructor.concat(this, ...t);
2184
+ }
2185
+ toJSON(t) {
2186
+ const n = /* @__PURE__ */ Object.create(null);
2187
+ return u.forEach(this, (r, o) => {
2188
+ r != null && r !== !1 && (n[o] = t && u.isArray(r) ? r.join(", ") : r);
2189
+ }), n;
2190
+ }
2191
+ [Symbol.iterator]() {
2192
+ return Object.entries(this.toJSON())[Symbol.iterator]();
2193
+ }
2194
+ toString() {
2195
+ return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(`
2196
+ `);
2197
+ }
2198
+ getSetCookie() {
2199
+ return this.get("set-cookie") || [];
2200
+ }
2201
+ get [Symbol.toStringTag]() {
2202
+ return "AxiosHeaders";
2203
+ }
2204
+ static from(t) {
2205
+ return t instanceof this ? t : new this(t);
2206
+ }
2207
+ static concat(t, ...n) {
2208
+ const r = new this(t);
2209
+ return n.forEach((o) => r.set(o)), r;
2210
+ }
2211
+ static accessor(t) {
2212
+ const r = (this[It] = this[It] = {
2213
+ accessors: {}
2214
+ }).accessors, o = this.prototype;
2215
+ function s(a) {
2216
+ const l = Fe(a);
2217
+ r[l] || (ns(o, a), r[l] = !0);
2218
+ }
2219
+ return u.isArray(t) ? t.forEach(s) : s(t), this;
2220
+ }
2221
+ };
2222
+ se.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
2223
+ u.reduceDescriptors(se.prototype, ({ value: e }, t) => {
2224
+ let n = t[0].toUpperCase() + t.slice(1);
2225
+ return {
2226
+ get: () => e,
2227
+ set(r) {
2228
+ this[n] = r;
2229
+ }
2230
+ };
2231
+ });
2232
+ u.freezeMethods(se);
2233
+ function ft(e, t) {
2234
+ const n = this || Je, r = t || n, o = se.from(r.headers);
2235
+ let s = r.data;
2236
+ return u.forEach(e, function(l) {
2237
+ s = l.call(n, s, o.normalize(), t ? t.status : void 0);
2238
+ }), o.normalize(), s;
2239
+ }
2240
+ function An(e) {
2241
+ return !!(e && e.__CANCEL__);
2242
+ }
2243
+ function _e(e, t, n) {
2244
+ B.call(this, e ?? "canceled", B.ERR_CANCELED, t, n), this.name = "CanceledError";
2245
+ }
2246
+ u.inherits(_e, B, {
2247
+ __CANCEL__: !0
2248
+ });
2249
+ function _n(e, t, n) {
2250
+ const r = n.config.validateStatus;
2251
+ !n.status || !r || r(n.status) ? e(n) : t(new B(
2252
+ "Request failed with status code " + n.status,
2253
+ [B.ERR_BAD_REQUEST, B.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
2254
+ n.config,
2255
+ n.request,
2256
+ n
2257
+ ));
2258
+ }
2259
+ function rs(e) {
2260
+ const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
2261
+ return t && t[1] || "";
2262
+ }
2263
+ function os(e, t) {
2264
+ e = e || 10;
2265
+ const n = new Array(e), r = new Array(e);
2266
+ let o = 0, s = 0, a;
2267
+ return t = t !== void 0 ? t : 1e3, function(p) {
2268
+ const d = Date.now(), b = r[s];
2269
+ a || (a = d), n[o] = p, r[o] = d;
2270
+ let i = s, T = 0;
2271
+ for (; i !== o; )
2272
+ T += n[i++], i = i % e;
2273
+ if (o = (o + 1) % e, o === s && (s = (s + 1) % e), d - a < t)
2274
+ return;
2275
+ const w = b && d - b;
2276
+ return w ? Math.round(T * 1e3 / w) : void 0;
2277
+ };
2278
+ }
2279
+ function ss(e, t) {
2280
+ let n = 0, r = 1e3 / t, o, s;
2281
+ const a = (d, b = Date.now()) => {
2282
+ n = b, o = null, s && (clearTimeout(s), s = null), e.apply(null, d);
2283
+ };
2284
+ return [(...d) => {
2285
+ const b = Date.now(), i = b - n;
2286
+ i >= r ? a(d, b) : (o = d, s || (s = setTimeout(() => {
2287
+ s = null, a(o);
2288
+ }, r - i)));
2289
+ }, () => o && a(o)];
2290
+ }
2291
+ const Xe = (e, t, n = 3) => {
2292
+ let r = 0;
2293
+ const o = os(50, 250);
2294
+ return ss((s) => {
2295
+ const a = s.loaded, l = s.lengthComputable ? s.total : void 0, p = a - r, d = o(p), b = a <= l;
2296
+ r = a;
2297
+ const i = {
2298
+ loaded: a,
2299
+ total: l,
2300
+ progress: l ? a / l : void 0,
2301
+ bytes: p,
2302
+ rate: d || void 0,
2303
+ estimated: d && l && b ? (l - a) / d : void 0,
2304
+ event: s,
2305
+ lengthComputable: l != null,
2306
+ [t ? "download" : "upload"]: !0
2307
+ };
2308
+ e(i);
2309
+ }, n);
2310
+ }, Vt = (e, t) => {
2311
+ const n = e != null;
2312
+ return [(r) => t[0]({
2313
+ lengthComputable: n,
2314
+ total: e,
2315
+ loaded: r
2316
+ }), t[1]];
2317
+ }, Wt = (e) => (...t) => u.asap(() => e(...t)), as = te.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (n) => (n = new URL(n, te.origin), e.protocol === n.protocol && e.host === n.host && (t || e.port === n.port)))(
2318
+ new URL(te.origin),
2319
+ te.navigator && /(msie|trident)/i.test(te.navigator.userAgent)
2320
+ ) : () => !0, ls = te.hasStandardBrowserEnv ? (
2321
+ // Standard browser envs support document.cookie
2322
+ {
2323
+ write(e, t, n, r, o, s) {
2324
+ const a = [e + "=" + encodeURIComponent(t)];
2325
+ u.isNumber(n) && a.push("expires=" + new Date(n).toGMTString()), u.isString(r) && a.push("path=" + r), u.isString(o) && a.push("domain=" + o), s === !0 && a.push("secure"), document.cookie = a.join("; ");
2326
+ },
2327
+ read(e) {
2328
+ const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
2329
+ return t ? decodeURIComponent(t[3]) : null;
2330
+ },
2331
+ remove(e) {
2332
+ this.write(e, "", Date.now() - 864e5);
2333
+ }
2334
+ }
2335
+ ) : (
2336
+ // Non-standard browser env (web workers, react-native) lack needed support.
2337
+ {
2338
+ write() {
2339
+ },
2340
+ read() {
2341
+ return null;
2342
+ },
2343
+ remove() {
2344
+ }
2345
+ }
2346
+ );
2347
+ function is(e) {
2348
+ return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
2349
+ }
2350
+ function cs(e, t) {
2351
+ return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
2352
+ }
2353
+ function Cn(e, t, n) {
2354
+ let r = !is(t);
2355
+ return e && (r || n == !1) ? cs(e, t) : t;
2356
+ }
2357
+ const Kt = (e) => e instanceof se ? { ...e } : e;
2358
+ function Se(e, t) {
2359
+ t = t || {};
2360
+ const n = {};
2361
+ function r(d, b, i, T) {
2362
+ return u.isPlainObject(d) && u.isPlainObject(b) ? u.merge.call({ caseless: T }, d, b) : u.isPlainObject(b) ? u.merge({}, b) : u.isArray(b) ? b.slice() : b;
2363
+ }
2364
+ function o(d, b, i, T) {
2365
+ if (u.isUndefined(b)) {
2366
+ if (!u.isUndefined(d))
2367
+ return r(void 0, d, i, T);
2368
+ } else return r(d, b, i, T);
2369
+ }
2370
+ function s(d, b) {
2371
+ if (!u.isUndefined(b))
2372
+ return r(void 0, b);
2373
+ }
2374
+ function a(d, b) {
2375
+ if (u.isUndefined(b)) {
2376
+ if (!u.isUndefined(d))
2377
+ return r(void 0, d);
2378
+ } else return r(void 0, b);
2379
+ }
2380
+ function l(d, b, i) {
2381
+ if (i in t)
2382
+ return r(d, b);
2383
+ if (i in e)
2384
+ return r(void 0, d);
2385
+ }
2386
+ const p = {
2387
+ url: s,
2388
+ method: s,
2389
+ data: s,
2390
+ baseURL: a,
2391
+ transformRequest: a,
2392
+ transformResponse: a,
2393
+ paramsSerializer: a,
2394
+ timeout: a,
2395
+ timeoutMessage: a,
2396
+ withCredentials: a,
2397
+ withXSRFToken: a,
2398
+ adapter: a,
2399
+ responseType: a,
2400
+ xsrfCookieName: a,
2401
+ xsrfHeaderName: a,
2402
+ onUploadProgress: a,
2403
+ onDownloadProgress: a,
2404
+ decompress: a,
2405
+ maxContentLength: a,
2406
+ maxBodyLength: a,
2407
+ beforeRedirect: a,
2408
+ transport: a,
2409
+ httpAgent: a,
2410
+ httpsAgent: a,
2411
+ cancelToken: a,
2412
+ socketPath: a,
2413
+ responseEncoding: a,
2414
+ validateStatus: l,
2415
+ headers: (d, b, i) => o(Kt(d), Kt(b), i, !0)
2416
+ };
2417
+ return u.forEach(Object.keys(Object.assign({}, e, t)), function(b) {
2418
+ const i = p[b] || o, T = i(e[b], t[b], b);
2419
+ u.isUndefined(T) && i !== l || (n[b] = T);
2420
+ }), n;
2421
+ }
2422
+ const xn = (e) => {
2423
+ const t = Se({}, e);
2424
+ let { data: n, withXSRFToken: r, xsrfHeaderName: o, xsrfCookieName: s, headers: a, auth: l } = t;
2425
+ t.headers = a = se.from(a), t.url = wn(Cn(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), l && a.set(
2426
+ "Authorization",
2427
+ "Basic " + btoa((l.username || "") + ":" + (l.password ? unescape(encodeURIComponent(l.password)) : ""))
2428
+ );
2429
+ let p;
2430
+ if (u.isFormData(n)) {
2431
+ if (te.hasStandardBrowserEnv || te.hasStandardBrowserWebWorkerEnv)
2432
+ a.setContentType(void 0);
2433
+ else if ((p = a.getContentType()) !== !1) {
2434
+ const [d, ...b] = p ? p.split(";").map((i) => i.trim()).filter(Boolean) : [];
2435
+ a.setContentType([d || "multipart/form-data", ...b].join("; "));
2436
+ }
2437
+ }
2438
+ if (te.hasStandardBrowserEnv && (r && u.isFunction(r) && (r = r(t)), r || r !== !1 && as(t.url))) {
2439
+ const d = o && s && ls.read(s);
2440
+ d && a.set(o, d);
2441
+ }
2442
+ return t;
2443
+ }, us = typeof XMLHttpRequest < "u", fs = us && function(e) {
2444
+ return new Promise(function(n, r) {
2445
+ const o = xn(e);
2446
+ let s = o.data;
2447
+ const a = se.from(o.headers).normalize();
2448
+ let { responseType: l, onUploadProgress: p, onDownloadProgress: d } = o, b, i, T, w, g;
2449
+ function _() {
2450
+ w && w(), g && g(), o.cancelToken && o.cancelToken.unsubscribe(b), o.signal && o.signal.removeEventListener("abort", b);
2451
+ }
2452
+ let f = new XMLHttpRequest();
2453
+ f.open(o.method.toUpperCase(), o.url, !0), f.timeout = o.timeout;
2454
+ function h() {
2455
+ if (!f)
2456
+ return;
2457
+ const R = se.from(
2458
+ "getAllResponseHeaders" in f && f.getAllResponseHeaders()
2459
+ ), m = {
2460
+ data: !l || l === "text" || l === "json" ? f.responseText : f.response,
2461
+ status: f.status,
2462
+ statusText: f.statusText,
2463
+ headers: R,
2464
+ config: e,
2465
+ request: f
2466
+ };
2467
+ _n(function(S) {
2468
+ n(S), _();
2469
+ }, function(S) {
2470
+ r(S), _();
2471
+ }, m), f = null;
2472
+ }
2473
+ "onloadend" in f ? f.onloadend = h : f.onreadystatechange = function() {
2474
+ !f || f.readyState !== 4 || f.status === 0 && !(f.responseURL && f.responseURL.indexOf("file:") === 0) || setTimeout(h);
2475
+ }, f.onabort = function() {
2476
+ f && (r(new B("Request aborted", B.ECONNABORTED, e, f)), f = null);
2477
+ }, f.onerror = function() {
2478
+ r(new B("Network Error", B.ERR_NETWORK, e, f)), f = null;
2479
+ }, f.ontimeout = function() {
2480
+ let y = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
2481
+ const m = o.transitional || On;
2482
+ o.timeoutErrorMessage && (y = o.timeoutErrorMessage), r(new B(
2483
+ y,
2484
+ m.clarifyTimeoutError ? B.ETIMEDOUT : B.ECONNABORTED,
2485
+ e,
2486
+ f
2487
+ )), f = null;
2488
+ }, s === void 0 && a.setContentType(null), "setRequestHeader" in f && u.forEach(a.toJSON(), function(y, m) {
2489
+ f.setRequestHeader(m, y);
2490
+ }), u.isUndefined(o.withCredentials) || (f.withCredentials = !!o.withCredentials), l && l !== "json" && (f.responseType = o.responseType), d && ([T, g] = Xe(d, !0), f.addEventListener("progress", T)), p && f.upload && ([i, w] = Xe(p), f.upload.addEventListener("progress", i), f.upload.addEventListener("loadend", w)), (o.cancelToken || o.signal) && (b = (R) => {
2491
+ f && (r(!R || R.type ? new _e(null, e, f) : R), f.abort(), f = null);
2492
+ }, o.cancelToken && o.cancelToken.subscribe(b), o.signal && (o.signal.aborted ? b() : o.signal.addEventListener("abort", b)));
2493
+ const c = rs(o.url);
2494
+ if (c && te.protocols.indexOf(c) === -1) {
2495
+ r(new B("Unsupported protocol " + c + ":", B.ERR_BAD_REQUEST, e));
2496
+ return;
2497
+ }
2498
+ f.send(s || null);
2499
+ });
2500
+ }, ds = (e, t) => {
2501
+ const { length: n } = e = e ? e.filter(Boolean) : [];
2502
+ if (t || n) {
2503
+ let r = new AbortController(), o;
2504
+ const s = function(d) {
2505
+ if (!o) {
2506
+ o = !0, l();
2507
+ const b = d instanceof Error ? d : this.reason;
2508
+ r.abort(b instanceof B ? b : new _e(b instanceof Error ? b.message : b));
2509
+ }
2510
+ };
2511
+ let a = t && setTimeout(() => {
2512
+ a = null, s(new B(`timeout ${t} of ms exceeded`, B.ETIMEDOUT));
2513
+ }, t);
2514
+ const l = () => {
2515
+ e && (a && clearTimeout(a), a = null, e.forEach((d) => {
2516
+ d.unsubscribe ? d.unsubscribe(s) : d.removeEventListener("abort", s);
2517
+ }), e = null);
2518
+ };
2519
+ e.forEach((d) => d.addEventListener("abort", s));
2520
+ const { signal: p } = r;
2521
+ return p.unsubscribe = () => u.asap(l), p;
2522
+ }
2523
+ }, ps = function* (e, t) {
2524
+ let n = e.byteLength;
2525
+ if (n < t) {
2526
+ yield e;
2527
+ return;
2528
+ }
2529
+ let r = 0, o;
2530
+ for (; r < n; )
2531
+ o = r + t, yield e.slice(r, o), r = o;
2532
+ }, hs = async function* (e, t) {
2533
+ for await (const n of ms(e))
2534
+ yield* ps(n, t);
2535
+ }, ms = async function* (e) {
2536
+ if (e[Symbol.asyncIterator]) {
2537
+ yield* e;
2538
+ return;
2539
+ }
2540
+ const t = e.getReader();
2541
+ try {
2542
+ for (; ; ) {
2543
+ const { done: n, value: r } = await t.read();
2544
+ if (n)
2545
+ break;
2546
+ yield r;
2547
+ }
2548
+ } finally {
2549
+ await t.cancel();
2550
+ }
2551
+ }, Gt = (e, t, n, r) => {
2552
+ const o = hs(e, t);
2553
+ let s = 0, a, l = (p) => {
2554
+ a || (a = !0, r && r(p));
2555
+ };
2556
+ return new ReadableStream({
2557
+ async pull(p) {
2558
+ try {
2559
+ const { done: d, value: b } = await o.next();
2560
+ if (d) {
2561
+ l(), p.close();
2562
+ return;
2563
+ }
2564
+ let i = b.byteLength;
2565
+ if (n) {
2566
+ let T = s += i;
2567
+ n(T);
2568
+ }
2569
+ p.enqueue(new Uint8Array(b));
2570
+ } catch (d) {
2571
+ throw l(d), d;
2572
+ }
2573
+ },
2574
+ cancel(p) {
2575
+ return l(p), o.return();
2576
+ }
2577
+ }, {
2578
+ highWaterMark: 2
2579
+ });
2580
+ }, at = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", Dn = at && typeof ReadableStream == "function", ys = at && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), Nn = (e, ...t) => {
2581
+ try {
2582
+ return !!e(...t);
2583
+ } catch {
2584
+ return !1;
2585
+ }
2586
+ }, bs = Dn && Nn(() => {
2587
+ let e = !1;
2588
+ const t = new Request(te.origin, {
2589
+ body: new ReadableStream(),
2590
+ method: "POST",
2591
+ get duplex() {
2592
+ return e = !0, "half";
2593
+ }
2594
+ }).headers.has("Content-Type");
2595
+ return e && !t;
2596
+ }), Xt = 64 * 1024, yt = Dn && Nn(() => u.isReadableStream(new Response("").body)), Ze = {
2597
+ stream: yt && ((e) => e.body)
2598
+ };
2599
+ at && ((e) => {
2600
+ ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((t) => {
2601
+ !Ze[t] && (Ze[t] = u.isFunction(e[t]) ? (n) => n[t]() : (n, r) => {
2602
+ throw new B(`Response type '${t}' is not supported`, B.ERR_NOT_SUPPORT, r);
2603
+ });
2604
+ });
2605
+ })(new Response());
2606
+ const gs = async (e) => {
2607
+ if (e == null)
2608
+ return 0;
2609
+ if (u.isBlob(e))
2610
+ return e.size;
2611
+ if (u.isSpecCompliantForm(e))
2612
+ return (await new Request(te.origin, {
2613
+ method: "POST",
2614
+ body: e
2615
+ }).arrayBuffer()).byteLength;
2616
+ if (u.isArrayBufferView(e) || u.isArrayBuffer(e))
2617
+ return e.byteLength;
2618
+ if (u.isURLSearchParams(e) && (e = e + ""), u.isString(e))
2619
+ return (await ys(e)).byteLength;
2620
+ }, vs = async (e, t) => {
2621
+ const n = u.toFiniteNumber(e.getContentLength());
2622
+ return n ?? gs(t);
2623
+ }, ks = at && (async (e) => {
2624
+ let {
2625
+ url: t,
2626
+ method: n,
2627
+ data: r,
2628
+ signal: o,
2629
+ cancelToken: s,
2630
+ timeout: a,
2631
+ onDownloadProgress: l,
2632
+ onUploadProgress: p,
2633
+ responseType: d,
2634
+ headers: b,
2635
+ withCredentials: i = "same-origin",
2636
+ fetchOptions: T
2637
+ } = xn(e);
2638
+ d = d ? (d + "").toLowerCase() : "text";
2639
+ let w = ds([o, s && s.toAbortSignal()], a), g;
2640
+ const _ = w && w.unsubscribe && (() => {
2641
+ w.unsubscribe();
2642
+ });
2643
+ let f;
2644
+ try {
2645
+ if (p && bs && n !== "get" && n !== "head" && (f = await vs(b, r)) !== 0) {
2646
+ let m = new Request(t, {
2647
+ method: "POST",
2648
+ body: r,
2649
+ duplex: "half"
2650
+ }), E;
2651
+ if (u.isFormData(r) && (E = m.headers.get("content-type")) && b.setContentType(E), m.body) {
2652
+ const [S, D] = Vt(
2653
+ f,
2654
+ Xe(Wt(p))
2655
+ );
2656
+ r = Gt(m.body, Xt, S, D);
2657
+ }
2658
+ }
2659
+ u.isString(i) || (i = i ? "include" : "omit");
2660
+ const h = "credentials" in Request.prototype;
2661
+ g = new Request(t, {
2662
+ ...T,
2663
+ signal: w,
2664
+ method: n.toUpperCase(),
2665
+ headers: b.normalize().toJSON(),
2666
+ body: r,
2667
+ duplex: "half",
2668
+ credentials: h ? i : void 0
2669
+ });
2670
+ let c = await fetch(g);
2671
+ const R = yt && (d === "stream" || d === "response");
2672
+ if (yt && (l || R && _)) {
2673
+ const m = {};
2674
+ ["status", "statusText", "headers"].forEach((N) => {
2675
+ m[N] = c[N];
2676
+ });
2677
+ const E = u.toFiniteNumber(c.headers.get("content-length")), [S, D] = l && Vt(
2678
+ E,
2679
+ Xe(Wt(l), !0)
2680
+ ) || [];
2681
+ c = new Response(
2682
+ Gt(c.body, Xt, S, () => {
2683
+ D && D(), _ && _();
2684
+ }),
2685
+ m
2686
+ );
2687
+ }
2688
+ d = d || "text";
2689
+ let y = await Ze[u.findKey(Ze, d) || "text"](c, e);
2690
+ return !R && _ && _(), await new Promise((m, E) => {
2691
+ _n(m, E, {
2692
+ data: y,
2693
+ headers: se.from(c.headers),
2694
+ status: c.status,
2695
+ statusText: c.statusText,
2696
+ config: e,
2697
+ request: g
2698
+ });
2699
+ });
2700
+ } catch (h) {
2701
+ throw _ && _(), h && h.name === "TypeError" && /Load failed|fetch/i.test(h.message) ? Object.assign(
2702
+ new B("Network Error", B.ERR_NETWORK, e, g),
2703
+ {
2704
+ cause: h.cause || h
2705
+ }
2706
+ ) : B.from(h, h && h.code, e, g);
2707
+ }
2708
+ }), bt = {
2709
+ http: Uo,
2710
+ xhr: fs,
2711
+ fetch: ks
2712
+ };
2713
+ u.forEach(bt, (e, t) => {
2714
+ if (e) {
2715
+ try {
2716
+ Object.defineProperty(e, "name", { value: t });
2717
+ } catch {
2718
+ }
2719
+ Object.defineProperty(e, "adapterName", { value: t });
2720
+ }
2721
+ });
2722
+ const Zt = (e) => `- ${e}`, Es = (e) => u.isFunction(e) || e === null || e === !1, Fn = {
2723
+ getAdapter: (e) => {
2724
+ e = u.isArray(e) ? e : [e];
2725
+ const { length: t } = e;
2726
+ let n, r;
2727
+ const o = {};
2728
+ for (let s = 0; s < t; s++) {
2729
+ n = e[s];
2730
+ let a;
2731
+ if (r = n, !Es(n) && (r = bt[(a = String(n)).toLowerCase()], r === void 0))
2732
+ throw new B(`Unknown adapter '${a}'`);
2733
+ if (r)
2734
+ break;
2735
+ o[a || "#" + s] = r;
2736
+ }
2737
+ if (!r) {
2738
+ const s = Object.entries(o).map(
2739
+ ([l, p]) => `adapter ${l} ` + (p === !1 ? "is not supported by the environment" : "is not available in the build")
2740
+ );
2741
+ let a = t ? s.length > 1 ? `since :
2742
+ ` + s.map(Zt).join(`
2743
+ `) : " " + Zt(s[0]) : "as no adapter specified";
2744
+ throw new B(
2745
+ "There is no suitable adapter to dispatch the request " + a,
2746
+ "ERR_NOT_SUPPORT"
2747
+ );
2748
+ }
2749
+ return r;
2750
+ },
2751
+ adapters: bt
2752
+ };
2753
+ function dt(e) {
2754
+ if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
2755
+ throw new _e(null, e);
2756
+ }
2757
+ function Qt(e) {
2758
+ return dt(e), e.headers = se.from(e.headers), e.data = ft.call(
2759
+ e,
2760
+ e.transformRequest
2761
+ ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Fn.getAdapter(e.adapter || Je.adapter)(e).then(function(r) {
2762
+ return dt(e), r.data = ft.call(
2763
+ e,
2764
+ e.transformResponse,
2765
+ r
2766
+ ), r.headers = se.from(r.headers), r;
2767
+ }, function(r) {
2768
+ return An(r) || (dt(e), r && r.response && (r.response.data = ft.call(
2769
+ e,
2770
+ e.transformResponse,
2771
+ r.response
2772
+ ), r.response.headers = se.from(r.response.headers))), Promise.reject(r);
2773
+ });
2774
+ }
2775
+ const Pn = "1.9.0", lt = {};
2776
+ ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
2777
+ lt[e] = function(r) {
2778
+ return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
2779
+ };
2780
+ });
2781
+ const Yt = {};
2782
+ lt.transitional = function(t, n, r) {
2783
+ function o(s, a) {
2784
+ return "[Axios v" + Pn + "] Transitional option '" + s + "'" + a + (r ? ". " + r : "");
2785
+ }
2786
+ return (s, a, l) => {
2787
+ if (t === !1)
2788
+ throw new B(
2789
+ o(a, " has been removed" + (n ? " in " + n : "")),
2790
+ B.ERR_DEPRECATED
2791
+ );
2792
+ return n && !Yt[a] && (Yt[a] = !0, console.warn(
2793
+ o(
2794
+ a,
2795
+ " has been deprecated since v" + n + " and will be removed in the near future"
2796
+ )
2797
+ )), t ? t(s, a, l) : !0;
2798
+ };
2799
+ };
2800
+ lt.spelling = function(t) {
2801
+ return (n, r) => (console.warn(`${r} is likely a misspelling of ${t}`), !0);
2802
+ };
2803
+ function Ss(e, t, n) {
2804
+ if (typeof e != "object")
2805
+ throw new B("options must be an object", B.ERR_BAD_OPTION_VALUE);
2806
+ const r = Object.keys(e);
2807
+ let o = r.length;
2808
+ for (; o-- > 0; ) {
2809
+ const s = r[o], a = t[s];
2810
+ if (a) {
2811
+ const l = e[s], p = l === void 0 || a(l, s, e);
2812
+ if (p !== !0)
2813
+ throw new B("option " + s + " must be " + p, B.ERR_BAD_OPTION_VALUE);
2814
+ continue;
2815
+ }
2816
+ if (n !== !0)
2817
+ throw new B("Unknown option " + s, B.ERR_BAD_OPTION);
2818
+ }
2819
+ }
2820
+ const Ke = {
2821
+ assertOptions: Ss,
2822
+ validators: lt
2823
+ }, de = Ke.validators;
2824
+ let ve = class {
2825
+ constructor(t) {
2826
+ this.defaults = t || {}, this.interceptors = {
2827
+ request: new Ht(),
2828
+ response: new Ht()
2829
+ };
2830
+ }
2831
+ /**
2832
+ * Dispatch a request
2833
+ *
2834
+ * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
2835
+ * @param {?Object} config
2836
+ *
2837
+ * @returns {Promise} The Promise to be fulfilled
2838
+ */
2839
+ async request(t, n) {
2840
+ try {
2841
+ return await this._request(t, n);
2842
+ } catch (r) {
2843
+ if (r instanceof Error) {
2844
+ let o = {};
2845
+ Error.captureStackTrace ? Error.captureStackTrace(o) : o = new Error();
2846
+ const s = o.stack ? o.stack.replace(/^.+\n/, "") : "";
2847
+ try {
2848
+ r.stack ? s && !String(r.stack).endsWith(s.replace(/^.+\n.+\n/, "")) && (r.stack += `
2849
+ ` + s) : r.stack = s;
2850
+ } catch {
2851
+ }
2852
+ }
2853
+ throw r;
2854
+ }
2855
+ }
2856
+ _request(t, n) {
2857
+ typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = Se(this.defaults, n);
2858
+ const { transitional: r, paramsSerializer: o, headers: s } = n;
2859
+ r !== void 0 && Ke.assertOptions(r, {
2860
+ silentJSONParsing: de.transitional(de.boolean),
2861
+ forcedJSONParsing: de.transitional(de.boolean),
2862
+ clarifyTimeoutError: de.transitional(de.boolean)
2863
+ }, !1), o != null && (u.isFunction(o) ? n.paramsSerializer = {
2864
+ serialize: o
2865
+ } : Ke.assertOptions(o, {
2866
+ encode: de.function,
2867
+ serialize: de.function
2868
+ }, !0)), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), Ke.assertOptions(n, {
2869
+ baseUrl: de.spelling("baseURL"),
2870
+ withXsrfToken: de.spelling("withXSRFToken")
2871
+ }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
2872
+ let a = s && u.merge(
2873
+ s.common,
2874
+ s[n.method]
2875
+ );
2876
+ s && u.forEach(
2877
+ ["delete", "get", "head", "post", "put", "patch", "common"],
2878
+ (g) => {
2879
+ delete s[g];
2880
+ }
2881
+ ), n.headers = se.concat(a, s);
2882
+ const l = [];
2883
+ let p = !0;
2884
+ this.interceptors.request.forEach(function(_) {
2885
+ typeof _.runWhen == "function" && _.runWhen(n) === !1 || (p = p && _.synchronous, l.unshift(_.fulfilled, _.rejected));
2886
+ });
2887
+ const d = [];
2888
+ this.interceptors.response.forEach(function(_) {
2889
+ d.push(_.fulfilled, _.rejected);
2890
+ });
2891
+ let b, i = 0, T;
2892
+ if (!p) {
2893
+ const g = [Qt.bind(this), void 0];
2894
+ for (g.unshift.apply(g, l), g.push.apply(g, d), T = g.length, b = Promise.resolve(n); i < T; )
2895
+ b = b.then(g[i++], g[i++]);
2896
+ return b;
2897
+ }
2898
+ T = l.length;
2899
+ let w = n;
2900
+ for (i = 0; i < T; ) {
2901
+ const g = l[i++], _ = l[i++];
2902
+ try {
2903
+ w = g(w);
2904
+ } catch (f) {
2905
+ _.call(this, f);
2906
+ break;
2907
+ }
2908
+ }
2909
+ try {
2910
+ b = Qt.call(this, w);
2911
+ } catch (g) {
2912
+ return Promise.reject(g);
2913
+ }
2914
+ for (i = 0, T = d.length; i < T; )
2915
+ b = b.then(d[i++], d[i++]);
2916
+ return b;
2917
+ }
2918
+ getUri(t) {
2919
+ t = Se(this.defaults, t);
2920
+ const n = Cn(t.baseURL, t.url, t.allowAbsoluteUrls);
2921
+ return wn(n, t.params, t.paramsSerializer);
2922
+ }
2923
+ };
2924
+ u.forEach(["delete", "get", "head", "options"], function(t) {
2925
+ ve.prototype[t] = function(n, r) {
2926
+ return this.request(Se(r || {}, {
2927
+ method: t,
2928
+ url: n,
2929
+ data: (r || {}).data
2930
+ }));
2931
+ };
2932
+ });
2933
+ u.forEach(["post", "put", "patch"], function(t) {
2934
+ function n(r) {
2935
+ return function(s, a, l) {
2936
+ return this.request(Se(l || {}, {
2937
+ method: t,
2938
+ headers: r ? {
2939
+ "Content-Type": "multipart/form-data"
2940
+ } : {},
2941
+ url: s,
2942
+ data: a
2943
+ }));
2944
+ };
2945
+ }
2946
+ ve.prototype[t] = n(), ve.prototype[t + "Form"] = n(!0);
2947
+ });
2948
+ let Rs = class Un {
2949
+ constructor(t) {
2950
+ if (typeof t != "function")
2951
+ throw new TypeError("executor must be a function.");
2952
+ let n;
2953
+ this.promise = new Promise(function(s) {
2954
+ n = s;
2955
+ });
2956
+ const r = this;
2957
+ this.promise.then((o) => {
2958
+ if (!r._listeners) return;
2959
+ let s = r._listeners.length;
2960
+ for (; s-- > 0; )
2961
+ r._listeners[s](o);
2962
+ r._listeners = null;
2963
+ }), this.promise.then = (o) => {
2964
+ let s;
2965
+ const a = new Promise((l) => {
2966
+ r.subscribe(l), s = l;
2967
+ }).then(o);
2968
+ return a.cancel = function() {
2969
+ r.unsubscribe(s);
2970
+ }, a;
2971
+ }, t(function(s, a, l) {
2972
+ r.reason || (r.reason = new _e(s, a, l), n(r.reason));
2973
+ });
2974
+ }
2975
+ /**
2976
+ * Throws a `CanceledError` if cancellation has been requested.
2977
+ */
2978
+ throwIfRequested() {
2979
+ if (this.reason)
2980
+ throw this.reason;
2981
+ }
2982
+ /**
2983
+ * Subscribe to the cancel signal
2984
+ */
2985
+ subscribe(t) {
2986
+ if (this.reason) {
2987
+ t(this.reason);
2988
+ return;
2989
+ }
2990
+ this._listeners ? this._listeners.push(t) : this._listeners = [t];
2991
+ }
2992
+ /**
2993
+ * Unsubscribe from the cancel signal
2994
+ */
2995
+ unsubscribe(t) {
2996
+ if (!this._listeners)
2997
+ return;
2998
+ const n = this._listeners.indexOf(t);
2999
+ n !== -1 && this._listeners.splice(n, 1);
3000
+ }
3001
+ toAbortSignal() {
3002
+ const t = new AbortController(), n = (r) => {
3003
+ t.abort(r);
3004
+ };
3005
+ return this.subscribe(n), t.signal.unsubscribe = () => this.unsubscribe(n), t.signal;
3006
+ }
3007
+ /**
3008
+ * Returns an object that contains a new `CancelToken` and a function that, when called,
3009
+ * cancels the `CancelToken`.
3010
+ */
3011
+ static source() {
3012
+ let t;
3013
+ return {
3014
+ token: new Un(function(o) {
3015
+ t = o;
3016
+ }),
3017
+ cancel: t
3018
+ };
3019
+ }
3020
+ };
3021
+ function ws(e) {
3022
+ return function(n) {
3023
+ return e.apply(null, n);
3024
+ };
3025
+ }
3026
+ function Os(e) {
3027
+ return u.isObject(e) && e.isAxiosError === !0;
3028
+ }
3029
+ const gt = {
3030
+ Continue: 100,
3031
+ SwitchingProtocols: 101,
3032
+ Processing: 102,
3033
+ EarlyHints: 103,
3034
+ Ok: 200,
3035
+ Created: 201,
3036
+ Accepted: 202,
3037
+ NonAuthoritativeInformation: 203,
3038
+ NoContent: 204,
3039
+ ResetContent: 205,
3040
+ PartialContent: 206,
3041
+ MultiStatus: 207,
3042
+ AlreadyReported: 208,
3043
+ ImUsed: 226,
3044
+ MultipleChoices: 300,
3045
+ MovedPermanently: 301,
3046
+ Found: 302,
3047
+ SeeOther: 303,
3048
+ NotModified: 304,
3049
+ UseProxy: 305,
3050
+ Unused: 306,
3051
+ TemporaryRedirect: 307,
3052
+ PermanentRedirect: 308,
3053
+ BadRequest: 400,
3054
+ Unauthorized: 401,
3055
+ PaymentRequired: 402,
3056
+ Forbidden: 403,
3057
+ NotFound: 404,
3058
+ MethodNotAllowed: 405,
3059
+ NotAcceptable: 406,
3060
+ ProxyAuthenticationRequired: 407,
3061
+ RequestTimeout: 408,
3062
+ Conflict: 409,
3063
+ Gone: 410,
3064
+ LengthRequired: 411,
3065
+ PreconditionFailed: 412,
3066
+ PayloadTooLarge: 413,
3067
+ UriTooLong: 414,
3068
+ UnsupportedMediaType: 415,
3069
+ RangeNotSatisfiable: 416,
3070
+ ExpectationFailed: 417,
3071
+ ImATeapot: 418,
3072
+ MisdirectedRequest: 421,
3073
+ UnprocessableEntity: 422,
3074
+ Locked: 423,
3075
+ FailedDependency: 424,
3076
+ TooEarly: 425,
3077
+ UpgradeRequired: 426,
3078
+ PreconditionRequired: 428,
3079
+ TooManyRequests: 429,
3080
+ RequestHeaderFieldsTooLarge: 431,
3081
+ UnavailableForLegalReasons: 451,
3082
+ InternalServerError: 500,
3083
+ NotImplemented: 501,
3084
+ BadGateway: 502,
3085
+ ServiceUnavailable: 503,
3086
+ GatewayTimeout: 504,
3087
+ HttpVersionNotSupported: 505,
3088
+ VariantAlsoNegotiates: 506,
3089
+ InsufficientStorage: 507,
3090
+ LoopDetected: 508,
3091
+ NotExtended: 510,
3092
+ NetworkAuthenticationRequired: 511
3093
+ };
3094
+ Object.entries(gt).forEach(([e, t]) => {
3095
+ gt[t] = e;
3096
+ });
3097
+ function Bn(e) {
3098
+ const t = new ve(e), n = dn(ve.prototype.request, t);
3099
+ return u.extend(n, ve.prototype, t, { allOwnKeys: !0 }), u.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(o) {
3100
+ return Bn(Se(e, o));
3101
+ }, n;
3102
+ }
3103
+ const X = Bn(Je);
3104
+ X.Axios = ve;
3105
+ X.CanceledError = _e;
3106
+ X.CancelToken = Rs;
3107
+ X.isCancel = An;
3108
+ X.VERSION = Pn;
3109
+ X.toFormData = st;
3110
+ X.AxiosError = B;
3111
+ X.Cancel = X.CanceledError;
3112
+ X.all = function(t) {
3113
+ return Promise.all(t);
3114
+ };
3115
+ X.spread = ws;
3116
+ X.isAxiosError = Os;
3117
+ X.mergeConfig = Se;
3118
+ X.AxiosHeaders = se;
3119
+ X.formToJSON = (e) => Tn(u.isHTMLForm(e) ? new FormData(e) : e);
3120
+ X.getAdapter = Fn.getAdapter;
3121
+ X.HttpStatusCode = gt;
3122
+ X.default = X;
3123
+ const {
3124
+ Axios: Ms,
3125
+ AxiosError: zs,
3126
+ CanceledError: Hs,
3127
+ isCancel: Is,
3128
+ CancelToken: Vs,
3129
+ VERSION: Ws,
3130
+ all: Ks,
3131
+ Cancel: Gs,
3132
+ isAxiosError: Xs,
3133
+ spread: Zs,
3134
+ toFormData: Qs,
3135
+ AxiosHeaders: Ys,
3136
+ HttpStatusCode: ea,
3137
+ formToJSON: ta,
3138
+ getAdapter: na,
3139
+ mergeConfig: ra
3140
+ } = X;
3141
+ /*! js-cookie v3.0.5 | MIT */
3142
+ function He(e) {
3143
+ for (var t = 1; t < arguments.length; t++) {
3144
+ var n = arguments[t];
3145
+ for (var r in n)
3146
+ e[r] = n[r];
3147
+ }
3148
+ return e;
3149
+ }
3150
+ var Ts = {
3151
+ read: function(e) {
3152
+ return e[0] === '"' && (e = e.slice(1, -1)), e.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
3153
+ },
3154
+ write: function(e) {
3155
+ return encodeURIComponent(e).replace(
3156
+ /%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,
3157
+ decodeURIComponent
3158
+ );
3159
+ }
3160
+ };
3161
+ function vt(e, t) {
3162
+ function n(o, s, a) {
3163
+ if (!(typeof document > "u")) {
3164
+ a = He({}, t, a), typeof a.expires == "number" && (a.expires = new Date(Date.now() + a.expires * 864e5)), a.expires && (a.expires = a.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
3165
+ var l = "";
3166
+ for (var p in a)
3167
+ a[p] && (l += "; " + p, a[p] !== !0 && (l += "=" + a[p].split(";")[0]));
3168
+ return document.cookie = o + "=" + e.write(s, o) + l;
3169
+ }
3170
+ }
3171
+ function r(o) {
3172
+ if (!(typeof document > "u" || arguments.length && !o)) {
3173
+ for (var s = document.cookie ? document.cookie.split("; ") : [], a = {}, l = 0; l < s.length; l++) {
3174
+ var p = s[l].split("="), d = p.slice(1).join("=");
3175
+ try {
3176
+ var b = decodeURIComponent(p[0]);
3177
+ if (a[b] = e.read(d, b), o === b)
3178
+ break;
3179
+ } catch {
3180
+ }
3181
+ }
3182
+ return o ? a[o] : a;
3183
+ }
3184
+ }
3185
+ return Object.create(
3186
+ {
3187
+ set: n,
3188
+ get: r,
3189
+ remove: function(o, s) {
3190
+ n(
3191
+ o,
3192
+ "",
3193
+ He({}, s, {
3194
+ expires: -1
3195
+ })
3196
+ );
3197
+ },
3198
+ withAttributes: function(o) {
3199
+ return vt(this.converter, He({}, this.attributes, o));
3200
+ },
3201
+ withConverter: function(o) {
3202
+ return vt(He({}, this.converter, o), this.attributes);
3203
+ }
3204
+ },
3205
+ {
3206
+ attributes: { value: Object.freeze(t) },
3207
+ converter: { value: Object.freeze(e) }
3208
+ }
3209
+ );
3210
+ }
3211
+ vt(Ts, { path: "/" });
3212
+ const ke = {
3213
+ // 查看 v2.4.3版本更新日志
3214
+ setKey(e) {
3215
+ return `ss-component-new:${e}`;
3216
+ },
3217
+ // 设置永久缓存
3218
+ set(e, t) {
3219
+ window.localStorage.setItem(ke.setKey(e), JSON.stringify(t));
3220
+ },
3221
+ // 获取永久缓存
3222
+ get(e) {
3223
+ let t = window.localStorage.getItem(ke.setKey(e));
3224
+ return JSON.parse(t);
3225
+ },
3226
+ // 移除永久缓存
3227
+ remove(e) {
3228
+ window.localStorage.removeItem(ke.setKey(e));
3229
+ },
3230
+ // 移除全部永久缓存
3231
+ clear() {
3232
+ window.localStorage.clear();
3233
+ }
3234
+ }, jn = /* @__PURE__ */ new Map();
3235
+ console.log("import.meta.env.VITE_API_URL", "http://139.196.154.85:20013");
3236
+ const $n = X.create({
3237
+ baseURL: "http://139.196.154.85:20013",
3238
+ timeout: 5e4
3239
+ //headers: { 'Content-Type': 'application/json' }, 这个会导致生成代码的上传文件 file为空
3240
+ }), Qe = "access-token", kt = `x-${Qe}`;
3241
+ $n.interceptors.request.use(
3242
+ (e) => {
3243
+ var o;
3244
+ const t = new AbortController();
3245
+ e.signal = t.signal;
3246
+ const n = e.url || "";
3247
+ jn.set(n, t);
3248
+ const r = ke.get(Qe);
3249
+ if (r) {
3250
+ e.headers.Authorization = `Bearer ${r}`;
3251
+ const s = _s(r), a = Cs(s.exp);
3252
+ if (/* @__PURE__ */ new Date() >= a) {
3253
+ const l = ke.get(kt);
3254
+ l && (e.headers["X-Authorization"] = `Bearer ${l}`);
3255
+ }
3256
+ if (((o = e.method) == null ? void 0 : o.toLowerCase()) === "get" && e.data) {
3257
+ let l = e.url + "?" + As(e.data);
3258
+ l = l.slice(0, -1), e.data = {}, e.url = l;
3259
+ }
3260
+ }
3261
+ return e;
3262
+ },
3263
+ (e) => Promise.reject(e)
3264
+ );
3265
+ $n.interceptors.response.use(
3266
+ (e) => {
3267
+ const t = e.config.url || "";
3268
+ jn.delete(t);
3269
+ var n = e.status, r = e.data;
3270
+ if (n === 401)
3271
+ throw new Error(e.statusText || "Request Error.");
3272
+ if (n >= 400)
3273
+ throw new Error(e.statusText || "Request Error.");
3274
+ if (r && r.hasOwnProperty("errors") && r.errors)
3275
+ throw new Error(JSON.stringify(r.errors || "Request Error."));
3276
+ var o = e.headers[Qe], s = e.headers[kt];
3277
+ if (o === "invalid_token")
3278
+ throw new Error(e.statusText || "Request Error.");
3279
+ if (s && o && (ke.set(Qe, o), ke.set(kt, s)), r.code === 401)
3280
+ throw new Error(e.statusText || "Request Error.");
3281
+ if (r.code === void 0)
3282
+ return Promise.resolve(e);
3283
+ if (r.code !== 200) {
3284
+ var a;
3285
+ throw r.message && typeof r.message == "object" ? a = JSON.stringify(r.message) : a = r.message, Ne({
3286
+ dangerouslyUseHTMLString: !0,
3287
+ message: a,
3288
+ type: "error"
3289
+ }), new Error(a);
3290
+ }
3291
+ return e;
3292
+ },
3293
+ (e) => {
3294
+ var t, n;
3295
+ if (e.response && e.response.status === 401)
3296
+ throw new Error(res.statusText || "Request Error.");
3297
+ return e.message.indexOf("timeout") != -1 ? Ne.error("网络超时") : e.message == "Network Error" ? Ne.error("网络连接错误") : (t = e.response) != null && t.data ? Ne.error((n = e.response) == null ? void 0 : n.statusText) : Ne.error("接口路径找不到"), Promise.reject(e);
3298
+ }
3299
+ );
3300
+ function As(e) {
3301
+ let t = "";
3302
+ for (const o of Object.keys(e)) {
3303
+ const s = e[o];
3304
+ var n = encodeURIComponent(o) + "=";
3305
+ if (s !== null && s !== "" && typeof s < "u")
3306
+ if (typeof s == "object") {
3307
+ for (const a of Object.keys(s))
3308
+ if (s[a] !== null && s[a] !== "" && typeof s[a] < "u") {
3309
+ let l = o + "[" + a + "]";
3310
+ var r = encodeURIComponent(l) + "=";
3311
+ t += r + encodeURIComponent(s[a]) + "&";
3312
+ }
3313
+ } else
3314
+ t += n + encodeURIComponent(s) + "&";
3315
+ }
3316
+ return t;
3317
+ }
3318
+ function _s(e) {
3319
+ e = e.replace(/_/g, "/").replace(/-/g, "+");
3320
+ var t = decodeURIComponent(escape(window.atob(e.split(".")[1])));
3321
+ return JSON.parse(t);
3322
+ }
3323
+ function Cs(e) {
3324
+ return new Date(e * 1e3);
3325
+ }
3326
+ const xs = Ye(he), { itemData: oa } = Ee(xs), Ds = Hn(he), { systemKey: sa, activeMenuPath: aa } = Ee(Ds), Pe = U(0), la = (e) => e.reduce((n, r) => {
3327
+ var s, a;
3328
+ const o = Object.values(n);
3329
+ return (((s = Object.keys(n)) == null ? void 0 : s.length) === 0 || o[o.length - 1].length >= (r == null ? void 0 : r.width)) && (n[Pe.value] = [], Pe.value++), n[Pe.value - 1].push(r), ((a = Object.keys(n)) == null ? void 0 : a.length) === (r == null ? void 0 : r.width) && (n[Pe.value] = [], Pe.value++), n;
3330
+ }, {});
3331
+ export {
3332
+ $s as a,
3333
+ js as b,
3334
+ la as c,
3335
+ Wn as d,
3336
+ Ls as e,
3337
+ cn as g,
3338
+ Bs as m,
3339
+ he as p,
3340
+ rn as u
3341
+ };