xph-crud 0.2.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +87 -87
- package/dist/index.umd.cjs +8 -8
- package/dist/types/common/src/componnets/actions/hooks/useActionsProps.d.ts +1 -1
- package/dist/types/common/src/componnets/actions/hooks/useExtendActions.d.ts +1 -1
- package/dist/types/common/src/componnets/auth/hooks/useExtendAuth.d.ts +1 -1
- package/dist/types/common/src/hooks/useExtendCompProps.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import Se, { useCallback as ve, createElement as Kn, createContext as Jn, useContext as Zn, useState as X, useRef as D, useEffect as q, Fragment as Vr, forwardRef as fe, useImperativeHandle as Pe, useMemo as
|
|
2
|
-
import { Button as ae, Dropdown as qr, theme as
|
|
1
|
+
import Se, { useCallback as ve, createElement as Kn, createContext as Jn, useContext as Zn, useState as X, useRef as D, useEffect as q, Fragment as Vr, forwardRef as fe, useImperativeHandle as Pe, useMemo as lt, memo as Ur } from "react";
|
|
2
|
+
import { Button as ae, Dropdown as qr, theme as qe, Space as Qn, Spin as Yr, Form as tt, Select as Gr, TreeSelect as Xr, Transfer as Kr, AutoComplete as Jr, Upload as $t, message as Ft, Input as Ut, InputNumber as eo, Switch as to, Radio as Zr, Checkbox as Qr, Cascader as ro, TimePicker as no, DatePicker as ut, Col as oo, Row as so, Table as io, Pagination as ao } from "antd";
|
|
3
3
|
import { CaretDownOutlined as en, ShrinkOutlined as co, FullscreenOutlined as lo, FullscreenExitOutlined as uo, CloseOutlined as fo, DownOutlined as po, UpOutlined as go, SearchOutlined as ho, ReloadOutlined as mo } from "@ant-design/icons";
|
|
4
4
|
import bo from "react-dom";
|
|
5
|
-
import
|
|
5
|
+
import rt from "dayjs";
|
|
6
6
|
const Mt = [];
|
|
7
7
|
for (let e = 0; e <= 15; e++)
|
|
8
8
|
Mt[e] = e.toString(16);
|
|
@@ -234,7 +234,7 @@ function _o() {
|
|
|
234
234
|
var bt = typeof WeakMap == "function" ? WeakMap : Map;
|
|
235
235
|
Re = new bt();
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function Xe(c, m) {
|
|
238
238
|
if (!c || De)
|
|
239
239
|
return "";
|
|
240
240
|
{
|
|
@@ -305,8 +305,8 @@ function _o() {
|
|
|
305
305
|
var Me = c ? c.displayName || c.name : "", je = Me ? he(Me) : "";
|
|
306
306
|
return typeof c == "function" && Re.set(c, je), je;
|
|
307
307
|
}
|
|
308
|
-
function
|
|
309
|
-
return
|
|
308
|
+
function Ke(c, m, y) {
|
|
309
|
+
return Xe(c, !1);
|
|
310
310
|
}
|
|
311
311
|
function vt(c) {
|
|
312
312
|
var m = c.prototype;
|
|
@@ -316,7 +316,7 @@ function _o() {
|
|
|
316
316
|
if (c == null)
|
|
317
317
|
return "";
|
|
318
318
|
if (typeof c == "function")
|
|
319
|
-
return
|
|
319
|
+
return Xe(c, vt(c));
|
|
320
320
|
if (typeof c == "string")
|
|
321
321
|
return he(c);
|
|
322
322
|
switch (c) {
|
|
@@ -328,7 +328,7 @@ function _o() {
|
|
|
328
328
|
if (typeof c == "object")
|
|
329
329
|
switch (c.$$typeof) {
|
|
330
330
|
case l:
|
|
331
|
-
return
|
|
331
|
+
return Ke(c.render);
|
|
332
332
|
case g:
|
|
333
333
|
return Oe(c.type, m, y);
|
|
334
334
|
case f: {
|
|
@@ -341,7 +341,7 @@ function _o() {
|
|
|
341
341
|
}
|
|
342
342
|
return "";
|
|
343
343
|
}
|
|
344
|
-
var me = Object.prototype.hasOwnProperty,
|
|
344
|
+
var me = Object.prototype.hasOwnProperty, Je = {}, yt = R.ReactDebugCurrentFrame;
|
|
345
345
|
function xe(c) {
|
|
346
346
|
if (c) {
|
|
347
347
|
var m = c._owner, y = Oe(c.type, c._source, m ? m.type : null);
|
|
@@ -364,7 +364,7 @@ function _o() {
|
|
|
364
364
|
} catch (K) {
|
|
365
365
|
O = K;
|
|
366
366
|
}
|
|
367
|
-
O && !(O instanceof Error) && (xe(z), T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", P || "React class", y, M, typeof O), xe(null)), O instanceof Error && !(O.message in
|
|
367
|
+
O && !(O instanceof Error) && (xe(z), T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", P || "React class", y, M, typeof O), xe(null)), O instanceof Error && !(O.message in Je) && (Je[O.message] = !0, xe(z), T("Failed %s type: %s", y, O.message), xe(null));
|
|
368
368
|
}
|
|
369
369
|
}
|
|
370
370
|
}
|
|
@@ -380,17 +380,17 @@ function _o() {
|
|
|
380
380
|
}
|
|
381
381
|
function Ct(c) {
|
|
382
382
|
try {
|
|
383
|
-
return
|
|
383
|
+
return Ze(c), !1;
|
|
384
384
|
} catch {
|
|
385
385
|
return !0;
|
|
386
386
|
}
|
|
387
387
|
}
|
|
388
|
-
function
|
|
388
|
+
function Ze(c) {
|
|
389
389
|
return "" + c;
|
|
390
390
|
}
|
|
391
391
|
function tr(c) {
|
|
392
392
|
if (Ct(c))
|
|
393
|
-
return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", xt(c)),
|
|
393
|
+
return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", xt(c)), Ze(c);
|
|
394
394
|
}
|
|
395
395
|
var Le = R.ReactCurrentOwner, Dn = {
|
|
396
396
|
key: !0,
|
|
@@ -799,14 +799,14 @@ function rs(e) {
|
|
|
799
799
|
return e;
|
|
800
800
|
};
|
|
801
801
|
}
|
|
802
|
-
var
|
|
802
|
+
var nt = function() {
|
|
803
803
|
try {
|
|
804
804
|
var e = Ae(Object, "defineProperty");
|
|
805
805
|
return e({}, "", {}), e;
|
|
806
806
|
} catch {
|
|
807
807
|
}
|
|
808
|
-
}(), ns =
|
|
809
|
-
return
|
|
808
|
+
}(), ns = nt ? function(e, t) {
|
|
809
|
+
return nt(e, "toString", {
|
|
810
810
|
configurable: !0,
|
|
811
811
|
enumerable: !1,
|
|
812
812
|
value: rs(t),
|
|
@@ -818,20 +818,20 @@ function Yt(e, t) {
|
|
|
818
818
|
return t = t ?? ss, !!t && (r == "number" || r != "symbol" && is.test(e)) && e > -1 && e % 1 == 0 && e < t;
|
|
819
819
|
}
|
|
820
820
|
function Gt(e, t, r) {
|
|
821
|
-
t == "__proto__" &&
|
|
821
|
+
t == "__proto__" && nt ? nt(e, t, {
|
|
822
822
|
configurable: !0,
|
|
823
823
|
enumerable: !0,
|
|
824
824
|
value: r,
|
|
825
825
|
writable: !0
|
|
826
826
|
}) : e[t] = r;
|
|
827
827
|
}
|
|
828
|
-
function
|
|
828
|
+
function Ye(e, t) {
|
|
829
829
|
return e === t || e !== e && t !== t;
|
|
830
830
|
}
|
|
831
831
|
var as = Object.prototype, cs = as.hasOwnProperty;
|
|
832
832
|
function sn(e, t, r) {
|
|
833
833
|
var n = e[t];
|
|
834
|
-
(!(cs.call(e, t) &&
|
|
834
|
+
(!(cs.call(e, t) && Ye(n, r)) || r === void 0 && !(t in e)) && Gt(e, t, r);
|
|
835
835
|
}
|
|
836
836
|
function ls(e, t, r, n) {
|
|
837
837
|
var o = !r;
|
|
@@ -867,7 +867,7 @@ function ps(e, t, r) {
|
|
|
867
867
|
if (!ce(r))
|
|
868
868
|
return !1;
|
|
869
869
|
var n = typeof t;
|
|
870
|
-
return (n == "number" ? dt(r) && Yt(t, r.length) : n == "string" && t in r) ?
|
|
870
|
+
return (n == "number" ? dt(r) && Yt(t, r.length) : n == "string" && t in r) ? Ye(r[t], e) : !1;
|
|
871
871
|
}
|
|
872
872
|
function gs(e) {
|
|
873
873
|
return ds(function(t, r) {
|
|
@@ -901,7 +901,7 @@ var cn = Object.prototype, vs = cn.hasOwnProperty, ys = cn.propertyIsEnumerable,
|
|
|
901
901
|
function _s() {
|
|
902
902
|
return !1;
|
|
903
903
|
}
|
|
904
|
-
var ln = typeof exports == "object" && exports && !exports.nodeType && exports, xr = ln && typeof module == "object" && module && !module.nodeType && module, ws = xr && xr.exports === ln, Cr = ws ? pe.Buffer : void 0, xs = Cr ? Cr.isBuffer : void 0,
|
|
904
|
+
var ln = typeof exports == "object" && exports && !exports.nodeType && exports, xr = ln && typeof module == "object" && module && !module.nodeType && module, ws = xr && xr.exports === ln, Cr = ws ? pe.Buffer : void 0, xs = Cr ? Cr.isBuffer : void 0, ot = xs || _s, Cs = "[object Arguments]", Ts = "[object Array]", Ss = "[object Boolean]", Ps = "[object Date]", Rs = "[object Error]", js = "[object Function]", Fs = "[object Map]", Es = "[object Number]", As = "[object Object]", Ds = "[object RegExp]", Os = "[object Set]", $s = "[object String]", Ms = "[object WeakMap]", ks = "[object ArrayBuffer]", zs = "[object DataView]", Is = "[object Float32Array]", Ls = "[object Float64Array]", Ns = "[object Int8Array]", Ws = "[object Int16Array]", Bs = "[object Int32Array]", Hs = "[object Uint8Array]", Vs = "[object Uint8ClampedArray]", Us = "[object Uint16Array]", qs = "[object Uint32Array]", U = {};
|
|
905
905
|
U[Is] = U[Ls] = U[Ns] = U[Ws] = U[Bs] = U[Hs] = U[Vs] = U[Us] = U[qs] = !0;
|
|
906
906
|
U[Cs] = U[Ts] = U[ks] = U[Ss] = U[zs] = U[Ps] = U[Rs] = U[js] = U[Fs] = U[Es] = U[As] = U[Ds] = U[Os] = U[$s] = U[Ms] = !1;
|
|
907
907
|
function Ys(e) {
|
|
@@ -920,7 +920,7 @@ var un = typeof exports == "object" && exports && !exports.nodeType && exports,
|
|
|
920
920
|
}
|
|
921
921
|
}(), Sr = Tr && Tr.isTypedArray, Kt = Sr ? Gs(Sr) : Ys, Ks = Object.prototype, Js = Ks.hasOwnProperty;
|
|
922
922
|
function dn(e, t) {
|
|
923
|
-
var r = oe(e), n = !r && It(e), o = !r && !n &&
|
|
923
|
+
var r = oe(e), n = !r && It(e), o = !r && !n && ot(e), s = !r && !n && !o && Kt(e), i = r || n || o || s, a = i ? ms(e.length, String) : [], l = a.length;
|
|
924
924
|
for (var u in e)
|
|
925
925
|
(t || Js.call(e, u)) && !(i && // Safari 9 has enumerable `arguments.length` in strict mode.
|
|
926
926
|
(u == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
|
@@ -1016,7 +1016,7 @@ function wi() {
|
|
|
1016
1016
|
}
|
|
1017
1017
|
function ft(e, t) {
|
|
1018
1018
|
for (var r = e.length; r--; )
|
|
1019
|
-
if (
|
|
1019
|
+
if (Ye(e[r][0], t))
|
|
1020
1020
|
return r;
|
|
1021
1021
|
return -1;
|
|
1022
1022
|
}
|
|
@@ -1226,10 +1226,10 @@ var Lt = Ae(pe, "DataView"), Nt = Ae(pe, "Promise"), Wt = Ae(pe, "Set"), Er = "[
|
|
|
1226
1226
|
}
|
|
1227
1227
|
return t;
|
|
1228
1228
|
});
|
|
1229
|
-
var
|
|
1229
|
+
var st = pe.Uint8Array;
|
|
1230
1230
|
function ba(e) {
|
|
1231
1231
|
var t = new e.constructor(e.byteLength);
|
|
1232
|
-
return new
|
|
1232
|
+
return new st(t).set(new st(e)), t;
|
|
1233
1233
|
}
|
|
1234
1234
|
function va(e, t) {
|
|
1235
1235
|
var r = ba(e.buffer);
|
|
@@ -1245,13 +1245,13 @@ function wa(e) {
|
|
|
1245
1245
|
function xa(e) {
|
|
1246
1246
|
return this.__data__.has(e);
|
|
1247
1247
|
}
|
|
1248
|
-
function
|
|
1248
|
+
function it(e) {
|
|
1249
1249
|
var t = -1, r = e == null ? 0 : e.length;
|
|
1250
1250
|
for (this.__data__ = new we(); ++t < r; )
|
|
1251
1251
|
this.add(e[t]);
|
|
1252
1252
|
}
|
|
1253
|
-
|
|
1254
|
-
|
|
1253
|
+
it.prototype.add = it.prototype.push = wa;
|
|
1254
|
+
it.prototype.has = xa;
|
|
1255
1255
|
function Ca(e, t) {
|
|
1256
1256
|
for (var r = -1, n = e == null ? 0 : e.length; ++r < n; )
|
|
1257
1257
|
if (t(e[r], r, e))
|
|
@@ -1269,7 +1269,7 @@ function bn(e, t, r, n, o, s) {
|
|
|
1269
1269
|
var u = s.get(e), d = s.get(t);
|
|
1270
1270
|
if (u && d)
|
|
1271
1271
|
return u == t && d == e;
|
|
1272
|
-
var g = -1, f = !0, b = r & Pa ? new
|
|
1272
|
+
var g = -1, f = !0, b = r & Pa ? new it() : void 0;
|
|
1273
1273
|
for (s.set(e, t), s.set(t, e); ++g < a; ) {
|
|
1274
1274
|
var p = e[g], v = t[g];
|
|
1275
1275
|
if (n)
|
|
@@ -1315,11 +1315,11 @@ function Ba(e, t, r, n, o, s, i) {
|
|
|
1315
1315
|
return !1;
|
|
1316
1316
|
e = e.buffer, t = t.buffer;
|
|
1317
1317
|
case Na:
|
|
1318
|
-
return !(e.byteLength != t.byteLength || !s(new
|
|
1318
|
+
return !(e.byteLength != t.byteLength || !s(new st(e), new st(t)));
|
|
1319
1319
|
case Aa:
|
|
1320
1320
|
case Da:
|
|
1321
1321
|
case Ma:
|
|
1322
|
-
return
|
|
1322
|
+
return Ye(+e, +t);
|
|
1323
1323
|
case Oa:
|
|
1324
1324
|
return e.name == t.name && e.message == t.message;
|
|
1325
1325
|
case ka:
|
|
@@ -1375,13 +1375,13 @@ function qa(e, t, r, n, o, s) {
|
|
|
1375
1375
|
}
|
|
1376
1376
|
return s.delete(e), s.delete(t), v;
|
|
1377
1377
|
}
|
|
1378
|
-
var Ya = 1, kr = "[object Arguments]", zr = "[object Array]",
|
|
1378
|
+
var Ya = 1, kr = "[object Arguments]", zr = "[object Array]", Qe = "[object Object]", Ga = Object.prototype, Ir = Ga.hasOwnProperty;
|
|
1379
1379
|
function Xa(e, t, r, n, o, s) {
|
|
1380
1380
|
var i = oe(e), a = oe(t), l = i ? zr : Ce(e), u = a ? zr : Ce(t);
|
|
1381
|
-
l = l == kr ?
|
|
1382
|
-
var d = l ==
|
|
1383
|
-
if (f &&
|
|
1384
|
-
if (!
|
|
1381
|
+
l = l == kr ? Qe : l, u = u == kr ? Qe : u;
|
|
1382
|
+
var d = l == Qe, g = u == Qe, f = l == u;
|
|
1383
|
+
if (f && ot(e)) {
|
|
1384
|
+
if (!ot(t))
|
|
1385
1385
|
return !1;
|
|
1386
1386
|
i = !0, d = !1;
|
|
1387
1387
|
}
|
|
@@ -1411,7 +1411,7 @@ function Ka(e) {
|
|
|
1411
1411
|
}
|
|
1412
1412
|
var Ja = Ka();
|
|
1413
1413
|
function Bt(e, t, r) {
|
|
1414
|
-
(r !== void 0 && !
|
|
1414
|
+
(r !== void 0 && !Ye(e[t], r) || r === void 0 && !(t in e)) && Gt(e, t, r);
|
|
1415
1415
|
}
|
|
1416
1416
|
function Za(e) {
|
|
1417
1417
|
return de(e) && dt(e);
|
|
@@ -1431,7 +1431,7 @@ function ec(e, t, r, n, o, s, i) {
|
|
|
1431
1431
|
}
|
|
1432
1432
|
var d = s ? s(a, l, r + "", e, t, i) : void 0, g = d === void 0;
|
|
1433
1433
|
if (g) {
|
|
1434
|
-
var f = oe(l), b = !f &&
|
|
1434
|
+
var f = oe(l), b = !f && ot(l), p = !f && !b && Kt(l);
|
|
1435
1435
|
d = l, f || b || p ? oe(a) ? d = a : Za(a) ? d = Jo(a) : b ? (g = !1, d = oa(l)) : p ? (g = !1, d = va(l)) : d = [] : Ki(l) || It(l) ? (d = a, It(a) ? d = Qa(a) : (!ce(a) || Z(a)) && (d = ya(l))) : g = !1;
|
|
1436
1436
|
}
|
|
1437
1437
|
g && (i.set(l, d), o(d, l, n, s, i), i.delete(l)), Bt(e, r, d);
|
|
@@ -1454,7 +1454,7 @@ var rc = "[object Boolean]";
|
|
|
1454
1454
|
function Vt(e) {
|
|
1455
1455
|
return e === !0 || e === !1 || de(e) && ge(e) == rc;
|
|
1456
1456
|
}
|
|
1457
|
-
function
|
|
1457
|
+
function at(e, t) {
|
|
1458
1458
|
return vn(e, t);
|
|
1459
1459
|
}
|
|
1460
1460
|
var nc = "[object Number]";
|
|
@@ -1591,17 +1591,17 @@ const uc = (e) => {
|
|
|
1591
1591
|
}
|
|
1592
1592
|
)
|
|
1593
1593
|
);
|
|
1594
|
-
},
|
|
1595
|
-
|
|
1596
|
-
|
|
1594
|
+
}, ct = /* @__PURE__ */ new Map();
|
|
1595
|
+
ct.set("Button", uc);
|
|
1596
|
+
ct.set("Dropdown", dc);
|
|
1597
1597
|
function Cn() {
|
|
1598
1598
|
const { setExtendActionsComp: e } = Sn();
|
|
1599
|
-
return e(
|
|
1599
|
+
return e(ct), {
|
|
1600
1600
|
renderContent: ve(
|
|
1601
1601
|
(r, n) => {
|
|
1602
1602
|
const o = xn(r), s = cc(r);
|
|
1603
1603
|
if (o) {
|
|
1604
|
-
const i =
|
|
1604
|
+
const i = ct.get(r.component);
|
|
1605
1605
|
return /* @__PURE__ */ Kn(i, { ...r, key: n });
|
|
1606
1606
|
}
|
|
1607
1607
|
return s ? /* @__PURE__ */ h.jsx("div", { children: r.render }, n) : null;
|
|
@@ -1622,7 +1622,7 @@ const Tn = Jn({}), iu = (e) => {
|
|
|
1622
1622
|
children: e.children
|
|
1623
1623
|
}
|
|
1624
1624
|
);
|
|
1625
|
-
},
|
|
1625
|
+
}, Ge = () => Zn(Tn), fc = (e) => {
|
|
1626
1626
|
const [t, r] = X(e), n = D(null);
|
|
1627
1627
|
return q(() => {
|
|
1628
1628
|
n.current && (n.current(), n.current = null);
|
|
@@ -1633,7 +1633,7 @@ const Tn = Jn({}), iu = (e) => {
|
|
|
1633
1633
|
});
|
|
1634
1634
|
})];
|
|
1635
1635
|
}, Sn = () => {
|
|
1636
|
-
const { extendProps: e, extendComp: t } =
|
|
1636
|
+
const { extendProps: e, extendComp: t } = Ge(), r = (n) => {
|
|
1637
1637
|
const o = t == null ? void 0 : t.actions;
|
|
1638
1638
|
o && Object.keys(o).forEach((s) => {
|
|
1639
1639
|
n.set(s, o[s]);
|
|
@@ -1644,7 +1644,7 @@ const Tn = Jn({}), iu = (e) => {
|
|
|
1644
1644
|
extendActionsProps: e == null ? void 0 : e.actions,
|
|
1645
1645
|
setExtendActionsComp: r
|
|
1646
1646
|
};
|
|
1647
|
-
}, { useToken: pc } =
|
|
1647
|
+
}, { useToken: pc } = qe, gc = ({
|
|
1648
1648
|
items: e,
|
|
1649
1649
|
actionsProps: t
|
|
1650
1650
|
}) => {
|
|
@@ -1729,7 +1729,7 @@ const mc = (e) => {
|
|
|
1729
1729
|
baseDialogProps: r
|
|
1730
1730
|
};
|
|
1731
1731
|
}, bc = () => {
|
|
1732
|
-
const { extendProps: e } =
|
|
1732
|
+
const { extendProps: e } = Ge();
|
|
1733
1733
|
return {
|
|
1734
1734
|
extendDialogProps: e == null ? void 0 : e.dialog
|
|
1735
1735
|
};
|
|
@@ -2222,7 +2222,7 @@ const mc = (e) => {
|
|
|
2222
2222
|
}
|
|
2223
2223
|
)
|
|
2224
2224
|
}
|
|
2225
|
-
), { useToken: Oc } =
|
|
2225
|
+
), { useToken: Oc } = qe, $c = fe(
|
|
2226
2226
|
({
|
|
2227
2227
|
title: e,
|
|
2228
2228
|
left: t,
|
|
@@ -2269,7 +2269,7 @@ const mc = (e) => {
|
|
|
2269
2269
|
"dialog__resize-rt": "_dialog__resize-rt_128q2_125",
|
|
2270
2270
|
"dialog__resize-rb": "_dialog__resize-rb_128q2_137",
|
|
2271
2271
|
"dialog__resize-lb": "_dialog__resize-lb_128q2_149"
|
|
2272
|
-
}, { useToken: Lc } =
|
|
2272
|
+
}, { useToken: Lc } = qe, Nc = fe((e, t) => {
|
|
2273
2273
|
console.log("render Dialog==============================================");
|
|
2274
2274
|
const { token: r } = Lc(), n = {
|
|
2275
2275
|
borderRadius: r.borderRadiusLG
|
|
@@ -2322,8 +2322,8 @@ const mc = (e) => {
|
|
|
2322
2322
|
), { minimizeLeft: ke, minimizeTop: ze, minimizeRef: he, setMinimizePosition: De } = Cc(), {
|
|
2323
2323
|
minimizeVisible: Re,
|
|
2324
2324
|
maximizeVisible: bt,
|
|
2325
|
-
setMaximizeVisible:
|
|
2326
|
-
onMaximize:
|
|
2325
|
+
setMaximizeVisible: Xe,
|
|
2326
|
+
onMaximize: Ke,
|
|
2327
2327
|
onMinimize: vt,
|
|
2328
2328
|
onRecovery: Oe,
|
|
2329
2329
|
onClose: me
|
|
@@ -2333,11 +2333,11 @@ const mc = (e) => {
|
|
|
2333
2333
|
close: R,
|
|
2334
2334
|
setDialogSize: se,
|
|
2335
2335
|
setDialogPosition: V
|
|
2336
|
-
}),
|
|
2337
|
-
console.log("触发了initDialog"), se({ width: S.current, height: E.current }), V({ left: x.current, top: _.current }), De({ left: 160, top: 60 }),
|
|
2336
|
+
}), Je = () => {
|
|
2337
|
+
console.log("触发了initDialog"), se({ width: S.current, height: E.current }), V({ left: x.current, top: _.current }), De({ left: 160, top: 60 }), Xe(!1);
|
|
2338
2338
|
};
|
|
2339
2339
|
q(() => {
|
|
2340
|
-
|
|
2340
|
+
Je();
|
|
2341
2341
|
}, [C]), Sc({
|
|
2342
2342
|
initWidth: S,
|
|
2343
2343
|
initHeight: E,
|
|
@@ -2369,7 +2369,7 @@ const mc = (e) => {
|
|
|
2369
2369
|
onMousedownResizeLt: Ie,
|
|
2370
2370
|
onMousedownResizeRt: xt,
|
|
2371
2371
|
onMousedownResizeRb: Ct,
|
|
2372
|
-
onMousedownResizeLb:
|
|
2372
|
+
onMousedownResizeLb: Ze
|
|
2373
2373
|
} = Rc({
|
|
2374
2374
|
containerSizeTarget: $,
|
|
2375
2375
|
dialogRef: j,
|
|
@@ -2394,7 +2394,7 @@ const mc = (e) => {
|
|
|
2394
2394
|
left: ke,
|
|
2395
2395
|
top: ze,
|
|
2396
2396
|
title: a,
|
|
2397
|
-
onMaximize: () =>
|
|
2397
|
+
onMaximize: () => Ke("minimize"),
|
|
2398
2398
|
onClosesquare: me
|
|
2399
2399
|
}
|
|
2400
2400
|
),
|
|
@@ -2419,7 +2419,7 @@ const mc = (e) => {
|
|
|
2419
2419
|
/* @__PURE__ */ h.jsx("div", { children: u ? u() : a }),
|
|
2420
2420
|
/* @__PURE__ */ h.jsxs("div", { className: ne["dialog__header-btns"], children: [
|
|
2421
2421
|
/* @__PURE__ */ h.jsx(Ac, { onClick: vt }),
|
|
2422
|
-
bt ? /* @__PURE__ */ h.jsx(Dc, { onClick: Oe }) : /* @__PURE__ */ h.jsx(Pn, { onClick: () =>
|
|
2422
|
+
bt ? /* @__PURE__ */ h.jsx(Dc, { onClick: Oe }) : /* @__PURE__ */ h.jsx(Pn, { onClick: () => Ke("maximize") }),
|
|
2423
2423
|
/* @__PURE__ */ h.jsx(Rn, { onClick: me, disabled: p })
|
|
2424
2424
|
] })
|
|
2425
2425
|
] }),
|
|
@@ -2460,7 +2460,7 @@ const mc = (e) => {
|
|
|
2460
2460
|
"div",
|
|
2461
2461
|
{
|
|
2462
2462
|
className: `${ne.dialog__resize} ${ne["dialog__resize-lb"]}`,
|
|
2463
|
-
onMouseDown:
|
|
2463
|
+
onMouseDown: Ze
|
|
2464
2464
|
}
|
|
2465
2465
|
)
|
|
2466
2466
|
]
|
|
@@ -2492,16 +2492,16 @@ function Vc(e) {
|
|
|
2492
2492
|
};
|
|
2493
2493
|
}
|
|
2494
2494
|
const Uc = () => {
|
|
2495
|
-
const { extendProps: e } =
|
|
2495
|
+
const { extendProps: e } = Ge();
|
|
2496
2496
|
return {
|
|
2497
2497
|
extendAuthProps: e == null ? void 0 : e.auth
|
|
2498
2498
|
};
|
|
2499
2499
|
}, au = (e) => {
|
|
2500
2500
|
const { children: t, ...r } = e, { authProps: n } = Vc(r), { auth: o, authCode: s } = n;
|
|
2501
|
-
return
|
|
2501
|
+
return (() => {
|
|
2502
2502
|
let a = !1;
|
|
2503
2503
|
return s && o && (oe(s) ? a = s.every((l) => o(l)) : a = o(s)), a;
|
|
2504
|
-
}
|
|
2504
|
+
})() ? t : null;
|
|
2505
2505
|
};
|
|
2506
2506
|
function Qt(e) {
|
|
2507
2507
|
return "component" in e;
|
|
@@ -2539,14 +2539,14 @@ const Gc = [
|
|
|
2539
2539
|
l = i({ model: t });
|
|
2540
2540
|
const d = Lr(n.current) ? l : n.current;
|
|
2541
2541
|
q(() => {
|
|
2542
|
-
|
|
2542
|
+
at(l, d) || s && s();
|
|
2543
2543
|
}, [t]);
|
|
2544
2544
|
}
|
|
2545
2545
|
if (Z(a)) {
|
|
2546
2546
|
u = a({ model: t });
|
|
2547
2547
|
const d = Lr(o.current) ? u : o.current;
|
|
2548
2548
|
q(() => {
|
|
2549
|
-
|
|
2549
|
+
at(u, d) || s && s();
|
|
2550
2550
|
}, [t]);
|
|
2551
2551
|
}
|
|
2552
2552
|
return n.current = l, o.current = u, { isShow: l, isIfShow: u };
|
|
@@ -2625,9 +2625,9 @@ const Gc = [
|
|
|
2625
2625
|
e.items.forEach((a) => {
|
|
2626
2626
|
n[a.name] = a.initialValue;
|
|
2627
2627
|
});
|
|
2628
|
-
const o = Xc(t), s = o ?
|
|
2628
|
+
const o = Xc(t), s = o ? tt.useWatch((a) => r(a)) : null;
|
|
2629
2629
|
return {
|
|
2630
|
-
rewritingModel:
|
|
2630
|
+
rewritingModel: lt(() => s || r(n), [s]),
|
|
2631
2631
|
isusewatch: o
|
|
2632
2632
|
};
|
|
2633
2633
|
}, cu = () => {
|
|
@@ -2716,7 +2716,7 @@ function al(e, t) {
|
|
|
2716
2716
|
continue;
|
|
2717
2717
|
}
|
|
2718
2718
|
const [a, l] = e[n], [u, d] = Array.isArray(i) ? i : [i, i];
|
|
2719
|
-
e[o] =
|
|
2719
|
+
e[o] = rt(a).format(u), e[s] = rt(l).format(d), Reflect.deleteProperty(e, n);
|
|
2720
2720
|
}
|
|
2721
2721
|
return e;
|
|
2722
2722
|
}
|
|
@@ -2734,10 +2734,10 @@ const cl = (e, t, r) => {
|
|
|
2734
2734
|
if (oe(f)) {
|
|
2735
2735
|
const b = [];
|
|
2736
2736
|
for (const p of f)
|
|
2737
|
-
b.push(p ?
|
|
2737
|
+
b.push(p ? rt(p) : null);
|
|
2738
2738
|
a[u.name] = b;
|
|
2739
2739
|
} else
|
|
2740
|
-
a[u.name] = f ?
|
|
2740
|
+
a[u.name] = f ? rt(f) : null;
|
|
2741
2741
|
l.push(u.name);
|
|
2742
2742
|
} else
|
|
2743
2743
|
a[u.name] = f, l.push(u.name);
|
|
@@ -2803,7 +2803,7 @@ const cl = (e, t, r) => {
|
|
|
2803
2803
|
n && Z(n) && (r ? n(r).then(o) : n().then(o), a.current = r);
|
|
2804
2804
|
};
|
|
2805
2805
|
return q(() => {
|
|
2806
|
-
i.current && (t && l(), i.current = !1), !i.current && s && (
|
|
2806
|
+
i.current && (t && l(), i.current = !1), !i.current && s && (at(r, a.current) || t && l());
|
|
2807
2807
|
}, [r]), {
|
|
2808
2808
|
getApiData: l
|
|
2809
2809
|
};
|
|
@@ -2833,7 +2833,7 @@ const cl = (e, t, r) => {
|
|
|
2833
2833
|
}
|
|
2834
2834
|
};
|
|
2835
2835
|
}, jn = () => {
|
|
2836
|
-
const { extendProps: e, extendComp: t } =
|
|
2836
|
+
const { extendProps: e, extendComp: t } = Ge(), r = (n) => {
|
|
2837
2837
|
const o = t == null ? void 0 : t.form;
|
|
2838
2838
|
o && Object.keys(o).forEach((s) => {
|
|
2839
2839
|
n.set(s, o[s]);
|
|
@@ -3030,7 +3030,7 @@ const cl = (e, t, r) => {
|
|
|
3030
3030
|
};
|
|
3031
3031
|
return q(() => {
|
|
3032
3032
|
const C = $();
|
|
3033
|
-
if (
|
|
3033
|
+
if (at(C, u)) return;
|
|
3034
3034
|
let x = [];
|
|
3035
3035
|
switch (l) {
|
|
3036
3036
|
case be.String: {
|
|
@@ -3179,7 +3179,7 @@ const Wr = {
|
|
|
3179
3179
|
{
|
|
3180
3180
|
...d,
|
|
3181
3181
|
className: u && !p ? void 0 : Wr["form-item-hidden"],
|
|
3182
|
-
children: /* @__PURE__ */ h.jsx(
|
|
3182
|
+
children: /* @__PURE__ */ h.jsx(tt.Item, { ...$(), children: S() })
|
|
3183
3183
|
}
|
|
3184
3184
|
) : null
|
|
3185
3185
|
] });
|
|
@@ -3192,7 +3192,7 @@ const Wr = {
|
|
|
3192
3192
|
onClickExpand: t,
|
|
3193
3193
|
onClickFold: r
|
|
3194
3194
|
}, n) => {
|
|
3195
|
-
const [o, s] = X(e), i =
|
|
3195
|
+
const [o, s] = X(e), i = lt(() => o, [o]), a = () => {
|
|
3196
3196
|
r(), s(!0);
|
|
3197
3197
|
}, l = () => {
|
|
3198
3198
|
t(), s(!1);
|
|
@@ -3226,7 +3226,7 @@ const Wr = {
|
|
|
3226
3226
|
"xph-form-action": "_xph-form-action_8ws73_1"
|
|
3227
3227
|
}, Cl = (e, t) => {
|
|
3228
3228
|
console.log("render Form");
|
|
3229
|
-
const [r] =
|
|
3229
|
+
const [r] = tt.useForm(), { formProps: n } = ul(e), { formItems: o } = nl({ formProps: n }), s = D(/* @__PURE__ */ new Map()), {
|
|
3230
3230
|
collapsible: i,
|
|
3231
3231
|
collapseNum: a,
|
|
3232
3232
|
collapseRef: l,
|
|
@@ -3280,7 +3280,7 @@ const Wr = {
|
|
|
3280
3280
|
...j
|
|
3281
3281
|
})), q(() => (console.log("Form is mounted======================="), n.register && n.register(j), () => {
|
|
3282
3282
|
console.log("Form is unmounted========================="), s.current.clear();
|
|
3283
|
-
}), []), /* @__PURE__ */ h.jsxs(
|
|
3283
|
+
}), []), /* @__PURE__ */ h.jsxs(tt, { form: r, ...T(), children: [
|
|
3284
3284
|
/* @__PURE__ */ h.jsx(so, { children: o.map((k, I) => (s.current.has(k.name) || s.current.set(k.name, Se.createRef()), /* @__PURE__ */ h.jsx(
|
|
3285
3285
|
bl,
|
|
3286
3286
|
{
|
|
@@ -3431,7 +3431,7 @@ function El(e) {
|
|
|
3431
3431
|
function Al(e) {
|
|
3432
3432
|
return "children" in e;
|
|
3433
3433
|
}
|
|
3434
|
-
const { useToken: Dl } =
|
|
3434
|
+
const { useToken: Dl } = qe, Ol = (e, t, r) => {
|
|
3435
3435
|
const { curComponentProps: n, cellFuncProps: o } = t, { url: s, onClick: i } = n, { token: a } = Dl(), l = {
|
|
3436
3436
|
color: a.colorLink,
|
|
3437
3437
|
cursor: "pointer"
|
|
@@ -3458,7 +3458,7 @@ const { useToken: Dl } = Ye, Ol = (e, t, r) => {
|
|
|
3458
3458
|
}, Ml = (e, t, r) => {
|
|
3459
3459
|
const { curComponentProps: n, cellFuncProps: o } = t;
|
|
3460
3460
|
return /* @__PURE__ */ h.jsx("div", { className: $l["cellfunc-actions"], children: /* @__PURE__ */ h.jsx(Zt, { ...n }) });
|
|
3461
|
-
}, { useToken: kl } =
|
|
3461
|
+
}, { useToken: kl } = qe, zl = {
|
|
3462
3462
|
0: {
|
|
3463
3463
|
color: "orange",
|
|
3464
3464
|
backgroundColor: "unset",
|
|
@@ -3707,7 +3707,7 @@ function Vl(e) {
|
|
|
3707
3707
|
t
|
|
3708
3708
|
), s = D(
|
|
3709
3709
|
t
|
|
3710
|
-
), i =
|
|
3710
|
+
), i = lt(() => n && (r === !0 || r === void 0) || !1, [n]);
|
|
3711
3711
|
return {
|
|
3712
3712
|
pagination: {
|
|
3713
3713
|
model: n,
|
|
@@ -3941,7 +3941,7 @@ function Yl(e, t) {
|
|
|
3941
3941
|
q(() => (u(), window.addEventListener("resize", u), () => {
|
|
3942
3942
|
window.removeEventListener("resize", u);
|
|
3943
3943
|
}), []);
|
|
3944
|
-
const d =
|
|
3944
|
+
const d = lt(() => t ? n ? { x: s, y: a - 70, ...r } : { x: "max-content", y: a - 70, ...r } : {
|
|
3945
3945
|
x: "max-content",
|
|
3946
3946
|
...r
|
|
3947
3947
|
}, [a]);
|
|
@@ -3974,7 +3974,7 @@ function Gl(e, t) {
|
|
|
3974
3974
|
};
|
|
3975
3975
|
}
|
|
3976
3976
|
const An = () => {
|
|
3977
|
-
const { extendProps: e, extendComp: t } =
|
|
3977
|
+
const { extendProps: e, extendComp: t } = Ge(), r = (n) => {
|
|
3978
3978
|
const o = t == null ? void 0 : t.tableCellFunc;
|
|
3979
3979
|
o && Object.keys(o).forEach((s) => {
|
|
3980
3980
|
const i = o[s];
|
|
@@ -3990,7 +3990,7 @@ const An = () => {
|
|
|
3990
3990
|
}, Xl = ({ crudFormDialog: e }) => ({
|
|
3991
3991
|
crudFormDialogRef: D(null),
|
|
3992
3992
|
crudFormProps: e
|
|
3993
|
-
}), Kl = "_container__toolbar_1yx5k_13", Jl = "_container__table_1yx5k_27", Zl = "_container__pagination_1yx5k_35",
|
|
3993
|
+
}), Kl = "_container__toolbar_1yx5k_13", Jl = "_container__table_1yx5k_27", Zl = "_container__pagination_1yx5k_35", et = {
|
|
3994
3994
|
"main-container": "_main-container_1yx5k_1",
|
|
3995
3995
|
container__toolbar: Kl,
|
|
3996
3996
|
container__table: Jl,
|
|
@@ -4026,13 +4026,13 @@ const An = () => {
|
|
|
4026
4026
|
reloadData: b,
|
|
4027
4027
|
/** 合并一下antd中table实例的方法 */
|
|
4028
4028
|
...s.current
|
|
4029
|
-
})), console.log("render Table"), /* @__PURE__ */ h.jsxs("div", { className: r ?
|
|
4030
|
-
/* @__PURE__ */ h.jsx("div", { className:
|
|
4029
|
+
})), console.log("render Table"), /* @__PURE__ */ h.jsxs("div", { className: r ? et["main-container"] : void 0, children: [
|
|
4030
|
+
/* @__PURE__ */ h.jsx("div", { className: et.container__toolbar, children: /* @__PURE__ */ h.jsx(Zt, { ...R() }) }),
|
|
4031
4031
|
/* @__PURE__ */ h.jsx(
|
|
4032
4032
|
"div",
|
|
4033
4033
|
{
|
|
4034
4034
|
ref: v,
|
|
4035
|
-
className: r ?
|
|
4035
|
+
className: r ? et.container__table : void 0,
|
|
4036
4036
|
children: /* @__PURE__ */ h.jsx(
|
|
4037
4037
|
io,
|
|
4038
4038
|
{
|
|
@@ -4049,7 +4049,7 @@ const An = () => {
|
|
|
4049
4049
|
)
|
|
4050
4050
|
}
|
|
4051
4051
|
),
|
|
4052
|
-
a.show ? /* @__PURE__ */ h.jsx("div", { className:
|
|
4052
|
+
a.show ? /* @__PURE__ */ h.jsx("div", { className: et.container__pagination, children: /* @__PURE__ */ h.jsx(
|
|
4053
4053
|
ao,
|
|
4054
4054
|
{
|
|
4055
4055
|
disabled: i.model.loading,
|
|
@@ -4102,6 +4102,6 @@ export {
|
|
|
4102
4102
|
vo as getValueByPath,
|
|
4103
4103
|
fr as getValuesByPathObj,
|
|
4104
4104
|
fc as useAsyncState,
|
|
4105
|
-
|
|
4105
|
+
Ge as useXphExtendCompProps,
|
|
4106
4106
|
cu as useXphForm
|
|
4107
4107
|
};
|
package/dist/index.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(R,p){typeof exports=="object"&&typeof module<"u"?p(exports,require("react"),require("antd"),require("@ant-design/icons"),require("react-dom"),require("dayjs")):typeof define=="function"&&define.amd?define(["exports","react","antd","@ant-design/icons","react-dom","dayjs"],p):(R=typeof globalThis<"u"?globalThis:R||self,p(R["xph-crud"]={},R.React,R.Antd,R.AntDesignIcons,R.ReactDOM,R.Dayjs))})(this,function(R,p,T,fe,hn,Ve){"use strict";const lt=[];for(let e=0;e<=15;e++)lt[e]=e.toString(16);function ct(){let e="";for(let t=1;t<=36;t++)t===9||t===14||t===19||t===24?e+="-":t===15?e+=4:t===20?e+=lt[Math.random()*4|8]:e+=lt[Math.random()*16|0];return e.replace(/-/g,"")}const Yt=(e,t)=>{const r=t.split(".").filter(Boolean);let n=e;for(const o of r)if(n[o]!==void 0)n=n[o];else return;return r.length?n:void 0},ut=(e,t)=>{const r={};for(const[n,o]of Object.entries(e))r[n]=Yt(t,o);return r};var ft={exports:{}},$e={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var Gt;function mn(){if(Gt)return $e;Gt=1;var e=p,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function i(a,c,u){var f,h={},d=null,v=null;u!==void 0&&(d=""+u),c.key!==void 0&&(d=""+c.key),c.ref!==void 0&&(v=c.ref);for(f in c)n.call(c,f)&&!s.hasOwnProperty(f)&&(h[f]=c[f]);if(a&&a.defaultProps)for(f in c=a.defaultProps,c)h[f]===void 0&&(h[f]=c[f]);return{$$typeof:t,type:a,key:d,ref:v,props:h,_owner:o.current}}return $e.Fragment=r,$e.jsx=i,$e.jsxs=i,$e}var
|
|
9
|
+
*/var Gt;function mn(){if(Gt)return $e;Gt=1;var e=p,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function i(a,c,u){var f,h={},d=null,v=null;u!==void 0&&(d=""+u),c.key!==void 0&&(d=""+c.key),c.ref!==void 0&&(v=c.ref);for(f in c)n.call(c,f)&&!s.hasOwnProperty(f)&&(h[f]=c[f]);if(a&&a.defaultProps)for(f in c=a.defaultProps,c)h[f]===void 0&&(h[f]=c[f]);return{$$typeof:t,type:a,key:d,ref:v,props:h,_owner:o.current}}return $e.Fragment=r,$e.jsx=i,$e.jsxs=i,$e}var Re={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,17 +14,17 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var Xt;function bn(){return Xt||(Xt=1,process.env.NODE_ENV!=="production"&&function(){var e=p,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),g=Symbol.iterator,y="@@iterator";function C(l){if(l===null||typeof l!="object")return null;var b=g&&l[g]||l[y];return typeof b=="function"?b:null}var j=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function P(l){{for(var b=arguments.length,_=new Array(b>1?b-1:0),F=1;F<b;F++)_[F-1]=arguments[F];D("error",l,_)}}function D(l,b,_){{var F=j.ReactDebugCurrentFrame,L=F.getStackAddendum();L!==""&&(b+="%s",_=_.concat([L]));var U=_.map(function(I){return String(I)});U.unshift("Warning: "+b),Function.prototype.apply.call(console[l],console,U)}}var z=!1,W=!1,G=!1,k=!1,S=!1,x;x=Symbol.for("react.module.reference");function w(l){return!!(typeof l=="string"||typeof l=="function"||l===n||l===s||S||l===o||l===u||l===f||k||l===v||z||W||G||typeof l=="object"&&l!==null&&(l.$$typeof===d||l.$$typeof===h||l.$$typeof===i||l.$$typeof===a||l.$$typeof===c||l.$$typeof===x||l.getModuleId!==void 0))}function E(l,b,_){var F=l.displayName;if(F)return F;var L=b.displayName||b.name||"";return L!==""?_+"("+L+")":_}function O(l){return l.displayName||"Context"}function A(l){if(l==null)return null;if(typeof l.tag=="number"&&P("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof l=="function")return l.displayName||l.name||null;if(typeof l=="string")return l;switch(l){case n:return"Fragment";case r:return"Portal";case s:return"Profiler";case o:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if(typeof l=="object")switch(l.$$typeof){case a:var b=l;return O(b)+".Consumer";case i:var _=l;return O(_._context)+".Provider";case c:return E(l,l.render,"ForwardRef");case h:var F=l.displayName||null;return F!==null?F:A(l.type)||"Memo";case d:{var L=l,U=L._payload,I=L._init;try{return A(I(U))}catch{return null}}}return null}var $=Object.assign,B=0,Q,ne,ue,ie,H,V,q;function X(){}X.__reactDisabledLog=!0;function $t(){{if(B===0){Q=console.log,ne=console.info,ue=console.warn,ie=console.error,H=console.group,V=console.groupCollapsed,q=console.groupEnd;var l={configurable:!0,enumerable:!0,value:X,writable:!0};Object.defineProperties(console,{info:l,log:l,warn:l,error:l,group:l,groupCollapsed:l,groupEnd:l})}B++}}function
|
|
18
|
-
`+We+l}}var je=!1,Pe;{var
|
|
17
|
+
*/var Xt;function bn(){return Xt||(Xt=1,process.env.NODE_ENV!=="production"&&function(){var e=p,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),g=Symbol.iterator,y="@@iterator";function C(l){if(l===null||typeof l!="object")return null;var b=g&&l[g]||l[y];return typeof b=="function"?b:null}var j=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function P(l){{for(var b=arguments.length,_=new Array(b>1?b-1:0),F=1;F<b;F++)_[F-1]=arguments[F];D("error",l,_)}}function D(l,b,_){{var F=j.ReactDebugCurrentFrame,L=F.getStackAddendum();L!==""&&(b+="%s",_=_.concat([L]));var U=_.map(function(I){return String(I)});U.unshift("Warning: "+b),Function.prototype.apply.call(console[l],console,U)}}var z=!1,W=!1,G=!1,k=!1,S=!1,x;x=Symbol.for("react.module.reference");function w(l){return!!(typeof l=="string"||typeof l=="function"||l===n||l===s||S||l===o||l===u||l===f||k||l===v||z||W||G||typeof l=="object"&&l!==null&&(l.$$typeof===d||l.$$typeof===h||l.$$typeof===i||l.$$typeof===a||l.$$typeof===c||l.$$typeof===x||l.getModuleId!==void 0))}function E(l,b,_){var F=l.displayName;if(F)return F;var L=b.displayName||b.name||"";return L!==""?_+"("+L+")":_}function O(l){return l.displayName||"Context"}function A(l){if(l==null)return null;if(typeof l.tag=="number"&&P("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof l=="function")return l.displayName||l.name||null;if(typeof l=="string")return l;switch(l){case n:return"Fragment";case r:return"Portal";case s:return"Profiler";case o:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if(typeof l=="object")switch(l.$$typeof){case a:var b=l;return O(b)+".Consumer";case i:var _=l;return O(_._context)+".Provider";case c:return E(l,l.render,"ForwardRef");case h:var F=l.displayName||null;return F!==null?F:A(l.type)||"Memo";case d:{var L=l,U=L._payload,I=L._init;try{return A(I(U))}catch{return null}}}return null}var $=Object.assign,B=0,Q,ne,ue,ie,H,V,q;function X(){}X.__reactDisabledLog=!0;function $t(){{if(B===0){Q=console.log,ne=console.info,ue=console.warn,ie=console.error,H=console.group,V=console.groupCollapsed,q=console.groupEnd;var l={configurable:!0,enumerable:!0,value:X,writable:!0};Object.defineProperties(console,{info:l,log:l,warn:l,error:l,group:l,groupCollapsed:l,groupEnd:l})}B++}}function Rt(){{if(B--,B===0){var l={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:$({},l,{value:Q}),info:$({},l,{value:ne}),warn:$({},l,{value:ue}),error:$({},l,{value:ie}),group:$({},l,{value:H}),groupCollapsed:$({},l,{value:V}),groupEnd:$({},l,{value:q})})}B<0&&P("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Ne=j.ReactCurrentDispatcher,We;function ve(l,b,_){{if(We===void 0)try{throw Error()}catch(L){var F=L.stack.trim().match(/\n( *(at )?)/);We=F&&F[1]||""}return`
|
|
18
|
+
`+We+l}}var je=!1,Pe;{var Mt=typeof WeakMap=="function"?WeakMap:Map;Pe=new Mt}function ot(l,b){if(!l||je)return"";{var _=Pe.get(l);if(_!==void 0)return _}var F;je=!0;var L=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var U;U=Ne.current,Ne.current=null,$t();try{if(b){var I=function(){throw Error()};if(Object.defineProperty(I.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(I,[])}catch(oe){F=oe}Reflect.construct(l,[],I)}else{try{I.call()}catch(oe){F=oe}l.call(I.prototype)}}else{try{throw Error()}catch(oe){F=oe}l()}}catch(oe){if(oe&&F&&typeof oe.stack=="string"){for(var M=oe.stack.split(`
|
|
19
19
|
`),ee=F.stack.split(`
|
|
20
|
-
`),K=
|
|
21
|
-
`+
|
|
20
|
+
`),K=M.length-1,J=ee.length-1;K>=1&&J>=0&&M[K]!==ee[J];)J--;for(;K>=1&&J>=0;K--,J--)if(M[K]!==ee[J]){if(K!==1||J!==1)do if(K--,J--,J<0||M[K]!==ee[J]){var ae=`
|
|
21
|
+
`+M[K].replace(" at new "," at ");return l.displayName&&ae.includes("<anonymous>")&&(ae=ae.replace("<anonymous>",l.displayName)),typeof l=="function"&&Pe.set(l,ae),ae}while(K>=1&&J>=0);break}}}finally{je=!1,Ne.current=U,Rt(),Error.prepareStackTrace=L}var Oe=l?l.displayName||l.name:"",Ee=Oe?ve(Oe):"";return typeof l=="function"&&Pe.set(l,Ee),Ee}function st(l,b,_){return ot(l,!1)}function kt(l){var b=l.prototype;return!!(b&&b.isReactComponent)}function De(l,b,_){if(l==null)return"";if(typeof l=="function")return ot(l,kt(l));if(typeof l=="string")return ve(l);switch(l){case u:return ve("Suspense");case f:return ve("SuspenseList")}if(typeof l=="object")switch(l.$$typeof){case c:return st(l.render);case h:return De(l.type,b,_);case d:{var F=l,L=F._payload,U=F._init;try{return De(U(L),b,_)}catch{}}}return""}var ye=Object.prototype.hasOwnProperty,it={},It=j.ReactDebugCurrentFrame;function Ce(l){if(l){var b=l._owner,_=De(l.type,l._source,b?b.type:null);It.setExtraStackFrame(_)}else It.setExtraStackFrame(null)}function zt(l,b,_,F,L){{var U=Function.call.bind(ye);for(var I in l)if(U(l,I)){var M=void 0;try{if(typeof l[I]!="function"){var ee=Error((F||"React class")+": "+_+" type `"+I+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof l[I]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw ee.name="Invariant Violation",ee}M=l[I](b,I,F,_,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(K){M=K}M&&!(M instanceof Error)&&(Ce(L),P("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",F||"React class",_,I,typeof M),Ce(null)),M instanceof Error&&!(M.message in it)&&(it[M.message]=!0,Ce(L),P("Failed %s type: %s",_,M.message),Ce(null))}}}var Lt=Array.isArray;function Be(l){return Lt(l)}function Nt(l){{var b=typeof Symbol=="function"&&Symbol.toStringTag,_=b&&l[Symbol.toStringTag]||l.constructor.name||"Object";return _}}function Wt(l){try{return at(l),!1}catch{return!0}}function at(l){return""+l}function on(l){if(Wt(l))return P("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Nt(l)),at(l)}var He=j.ReactCurrentOwner,Ul={key:!0,ref:!0,__self:!0,__source:!0},sn,an,Bt;Bt={};function ql(l){if(ye.call(l,"ref")){var b=Object.getOwnPropertyDescriptor(l,"ref").get;if(b&&b.isReactWarning)return!1}return l.ref!==void 0}function Yl(l){if(ye.call(l,"key")){var b=Object.getOwnPropertyDescriptor(l,"key").get;if(b&&b.isReactWarning)return!1}return l.key!==void 0}function Gl(l,b){if(typeof l.ref=="string"&&He.current&&b&&He.current.stateNode!==b){var _=A(He.current.type);Bt[_]||(P('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',A(He.current.type),l.ref),Bt[_]=!0)}}function Xl(l,b){{var _=function(){sn||(sn=!0,P("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",b))};_.isReactWarning=!0,Object.defineProperty(l,"key",{get:_,configurable:!0})}}function Kl(l,b){{var _=function(){an||(an=!0,P("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",b))};_.isReactWarning=!0,Object.defineProperty(l,"ref",{get:_,configurable:!0})}}var Jl=function(l,b,_,F,L,U,I){var M={$$typeof:t,type:l,key:b,ref:_,props:I,_owner:U};return M._store={},Object.defineProperty(M._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(M,"_self",{configurable:!1,enumerable:!1,writable:!1,value:F}),Object.defineProperty(M,"_source",{configurable:!1,enumerable:!1,writable:!1,value:L}),Object.freeze&&(Object.freeze(M.props),Object.freeze(M)),M};function Zl(l,b,_,F,L){{var U,I={},M=null,ee=null;_!==void 0&&(on(_),M=""+_),Yl(b)&&(on(b.key),M=""+b.key),ql(b)&&(ee=b.ref,Gl(b,L));for(U in b)ye.call(b,U)&&!Ul.hasOwnProperty(U)&&(I[U]=b[U]);if(l&&l.defaultProps){var K=l.defaultProps;for(U in K)I[U]===void 0&&(I[U]=K[U])}if(M||ee){var J=typeof l=="function"?l.displayName||l.name||"Unknown":l;M&&Xl(I,J),ee&&Kl(I,J)}return Jl(l,M,ee,L,F,He.current,I)}}var Ht=j.ReactCurrentOwner,ln=j.ReactDebugCurrentFrame;function Ae(l){if(l){var b=l._owner,_=De(l.type,l._source,b?b.type:null);ln.setExtraStackFrame(_)}else ln.setExtraStackFrame(null)}var Vt;Vt=!1;function Ut(l){return typeof l=="object"&&l!==null&&l.$$typeof===t}function cn(){{if(Ht.current){var l=A(Ht.current.type);if(l)return`
|
|
22
22
|
|
|
23
23
|
Check the render method of \``+l+"`."}return""}}function Ql(l){return""}var un={};function ec(l){{var b=cn();if(!b){var _=typeof l=="string"?l:l.displayName||l.name;_&&(b=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+_+">.")}return b}}function fn(l,b){{if(!l._store||l._store.validated||l.key!=null)return;l._store.validated=!0;var _=ec(b);if(un[_])return;un[_]=!0;var F="";l&&l._owner&&l._owner!==Ht.current&&(F=" It was passed a child from "+A(l._owner.type)+"."),Ae(l),P('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',_,F),Ae(null)}}function dn(l,b){{if(typeof l!="object")return;if(Be(l))for(var _=0;_<l.length;_++){var F=l[_];Ut(F)&&fn(F,b)}else if(Ut(l))l._store&&(l._store.validated=!0);else if(l){var L=C(l);if(typeof L=="function"&&L!==l.entries)for(var U=L.call(l),I;!(I=U.next()).done;)Ut(I.value)&&fn(I.value,b)}}}function tc(l){{var b=l.type;if(b==null||typeof b=="string")return;var _;if(typeof b=="function")_=b.propTypes;else if(typeof b=="object"&&(b.$$typeof===c||b.$$typeof===h))_=b.propTypes;else return;if(_){var F=A(b);zt(_,l.props,"prop",F,l)}else if(b.PropTypes!==void 0&&!Vt){Vt=!0;var L=A(b);P("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",L||"Unknown")}typeof b.getDefaultProps=="function"&&!b.getDefaultProps.isReactClassApproved&&P("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function rc(l){{for(var b=Object.keys(l.props),_=0;_<b.length;_++){var F=b[_];if(F!=="children"&&F!=="key"){Ae(l),P("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",F),Ae(null);break}}l.ref!==null&&(Ae(l),P("Invalid attribute `ref` supplied to `React.Fragment`."),Ae(null))}}var pn={};function gn(l,b,_,F,L,U){{var I=w(l);if(!I){var
|
|
25
|
+
Check the top-level render call using <`+_+">.")}return b}}function fn(l,b){{if(!l._store||l._store.validated||l.key!=null)return;l._store.validated=!0;var _=ec(b);if(un[_])return;un[_]=!0;var F="";l&&l._owner&&l._owner!==Ht.current&&(F=" It was passed a child from "+A(l._owner.type)+"."),Ae(l),P('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',_,F),Ae(null)}}function dn(l,b){{if(typeof l!="object")return;if(Be(l))for(var _=0;_<l.length;_++){var F=l[_];Ut(F)&&fn(F,b)}else if(Ut(l))l._store&&(l._store.validated=!0);else if(l){var L=C(l);if(typeof L=="function"&&L!==l.entries)for(var U=L.call(l),I;!(I=U.next()).done;)Ut(I.value)&&fn(I.value,b)}}}function tc(l){{var b=l.type;if(b==null||typeof b=="string")return;var _;if(typeof b=="function")_=b.propTypes;else if(typeof b=="object"&&(b.$$typeof===c||b.$$typeof===h))_=b.propTypes;else return;if(_){var F=A(b);zt(_,l.props,"prop",F,l)}else if(b.PropTypes!==void 0&&!Vt){Vt=!0;var L=A(b);P("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",L||"Unknown")}typeof b.getDefaultProps=="function"&&!b.getDefaultProps.isReactClassApproved&&P("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function rc(l){{for(var b=Object.keys(l.props),_=0;_<b.length;_++){var F=b[_];if(F!=="children"&&F!=="key"){Ae(l),P("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",F),Ae(null);break}}l.ref!==null&&(Ae(l),P("Invalid attribute `ref` supplied to `React.Fragment`."),Ae(null))}}var pn={};function gn(l,b,_,F,L,U){{var I=w(l);if(!I){var M="";(l===void 0||typeof l=="object"&&l!==null&&Object.keys(l).length===0)&&(M+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var ee=Ql();ee?M+=ee:M+=cn();var K;l===null?K="null":Be(l)?K="array":l!==void 0&&l.$$typeof===t?(K="<"+(A(l.type)||"Unknown")+" />",M=" Did you accidentally export a JSX literal instead of a component?"):K=typeof l,P("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",K,M)}var J=Zl(l,b,_,L,U);if(J==null)return J;if(I){var ae=b.children;if(ae!==void 0)if(F)if(Be(ae)){for(var Oe=0;Oe<ae.length;Oe++)dn(ae[Oe],l);Object.freeze&&Object.freeze(ae)}else P("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else dn(ae,l)}if(ye.call(b,"key")){var Ee=A(l),oe=Object.keys(b).filter(function(lc){return lc!=="key"}),qt=oe.length>0?"{key: someKey, "+oe.join(": ..., ")+": ...}":"{key: someKey}";if(!pn[Ee+qt]){var ac=oe.length>0?"{"+oe.join(": ..., ")+": ...}":"{}";P(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,qt,Ee,ac,Ee),pn[Ee+qt]=!0}}return l===n?rc(J):tc(J),J}}function nc(l,b,_){return gn(l,b,_,!0)}function oc(l,b,_){return gn(l,b,_,!1)}var sc=oc,ic=nc;Me.Fragment=n,Me.jsx=sc,Me.jsxs=ic}()),Me}process.env.NODE_ENV==="production"?ft.exports=mn():ft.exports=bn();var m=ft.exports,Kt=typeof global=="object"&&global&&global.Object===Object&&global,vn=typeof self=="object"&&self&&self.Object===Object&&self,de=Kt||vn||Function("return this")(),_e=de.Symbol,Jt=Object.prototype,yn=Jt.hasOwnProperty,_n=Jt.toString,Re=_e?_e.toStringTag:void 0;function wn(e){var t=yn.call(e,Re),r=e[Re];try{e[Re]=void 0;var n=!0}catch{}var o=_n.call(e);return n&&(t?e[Re]=r:delete e[Re]),o}var Cn=Object.prototype,xn=Cn.toString;function Tn(e){return xn.call(e)}var Sn="[object Null]",Pn="[object Undefined]",Zt=_e?_e.toStringTag:void 0;function pe(e){return e==null?e===void 0?Pn:Sn:Zt&&Zt in Object(e)?wn(e):Tn(e)}function le(e){return e!=null&&typeof e=="object"}var En="[object Symbol]";function dt(e){return typeof e=="symbol"||le(e)&&pe(e)==En}function Fn(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var te=Array.isArray,jn=1/0,Qt=_e?_e.prototype:void 0,er=Qt?Qt.toString:void 0;function tr(e){if(typeof e=="string")return e;if(te(e))return Fn(e,tr)+"";if(dt(e))return er?er.call(e):"";var t=e+"";return t=="0"&&1/e==-jn?"-0":t}function se(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function rr(e){return e}var Dn="[object AsyncFunction]",An="[object Function]",On="[object GeneratorFunction]",$n="[object Proxy]";function Z(e){if(!se(e))return!1;var t=pe(e);return t==An||t==On||t==Dn||t==$n}var pt=de["__core-js_shared__"],nr=function(){var e=/[^.]+$/.exec(pt&&pt.keys&&pt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Mn(e){return!!nr&&nr in e}var Rn=Function.prototype,kn=Rn.toString;function xe(e){if(e!=null){try{return kn.call(e)}catch{}try{return e+""}catch{}}return""}var In=/[\\^$.*+?()[\]{}|]/g,zn=/^\[object .+?Constructor\]$/,Ln=Function.prototype,Nn=Object.prototype,Wn=Ln.toString,Bn=Nn.hasOwnProperty,Hn=RegExp("^"+Wn.call(Bn).replace(In,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Vn(e){if(!se(e)||Mn(e))return!1;var t=Z(e)?Hn:zn;return t.test(xe(e))}function Un(e,t){return e==null?void 0:e[t]}function Te(e,t){var r=Un(e,t);return Vn(r)?r:void 0}var gt=Te(de,"WeakMap"),or=Object.create,qn=function(){function e(){}return function(t){if(!se(t))return{};if(or)return or(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function Yn(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Gn(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Xn=800,Kn=16,Jn=Date.now;function Zn(e){var t=0,r=0;return function(){var n=Jn(),o=Kn-(n-r);if(r=n,o>0){if(++t>=Xn)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Qn(e){return function(){return e}}var Ue=function(){try{var e=Te(Object,"defineProperty");return e({},"",{}),e}catch{}}(),eo=Ue?function(e,t){return Ue(e,"toString",{configurable:!0,enumerable:!1,value:Qn(t),writable:!0})}:rr,to=Zn(eo),ro=9007199254740991,no=/^(?:0|[1-9]\d*)$/;function ht(e,t){var r=typeof e;return t=t??ro,!!t&&(r=="number"||r!="symbol"&&no.test(e))&&e>-1&&e%1==0&&e<t}function mt(e,t,r){t=="__proto__"&&Ue?Ue(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function ke(e,t){return e===t||e!==e&&t!==t}var oo=Object.prototype,so=oo.hasOwnProperty;function sr(e,t,r){var n=e[t];(!(so.call(e,t)&&ke(n,r))||r===void 0&&!(t in e))&&mt(e,t,r)}function io(e,t,r,n){var o=!r;r||(r={});for(var s=-1,i=t.length;++s<i;){var a=t[s],c=void 0;c===void 0&&(c=e[a]),o?mt(r,a,c):sr(r,a,c)}return r}var ir=Math.max;function ao(e,t,r){return t=ir(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,s=ir(n.length-t,0),i=Array(s);++o<s;)i[o]=n[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=n[o];return a[t]=r(i),Yn(e,this,a)}}function lo(e,t){return to(ao(e,t,rr),e+"")}var co=9007199254740991;function ar(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=co}function qe(e){return e!=null&&ar(e.length)&&!Z(e)}function uo(e,t,r){if(!se(r))return!1;var n=typeof t;return(n=="number"?qe(r)&&ht(t,r.length):n=="string"&&t in r)?ke(r[t],e):!1}function fo(e){return lo(function(t,r){var n=-1,o=r.length,s=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(o--,s):void 0,i&&uo(r[0],r[1],i)&&(s=o<3?void 0:s,o=1),t=Object(t);++n<o;){var a=r[n];a&&e(t,a,n,s)}return t})}var po=Object.prototype;function bt(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||po;return e===r}function go(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var ho="[object Arguments]";function lr(e){return le(e)&&pe(e)==ho}var cr=Object.prototype,mo=cr.hasOwnProperty,bo=cr.propertyIsEnumerable,vt=lr(function(){return arguments}())?lr:function(e){return le(e)&&mo.call(e,"callee")&&!bo.call(e,"callee")};function vo(){return!1}var ur=typeof M=="object"&&M&&!M.nodeType&&M,fr=ur&&typeof module=="object"&&module&&!module.nodeType&&module,yo=fr&&fr.exports===ur,dr=yo?de.Buffer:void 0,_o=dr?dr.isBuffer:void 0,Ye=_o||vo,wo="[object Arguments]",Co="[object Array]",xo="[object Boolean]",To="[object Date]",So="[object Error]",Po="[object Function]",Eo="[object Map]",Fo="[object Number]",jo="[object Object]",Do="[object RegExp]",Ao="[object Set]",Oo="[object String]",$o="[object WeakMap]",Mo="[object ArrayBuffer]",Ro="[object DataView]",ko="[object Float32Array]",Io="[object Float64Array]",zo="[object Int8Array]",Lo="[object Int16Array]",No="[object Int32Array]",Wo="[object Uint8Array]",Bo="[object Uint8ClampedArray]",Ho="[object Uint16Array]",Vo="[object Uint32Array]",Y={};Y[ko]=Y[Io]=Y[zo]=Y[Lo]=Y[No]=Y[Wo]=Y[Bo]=Y[Ho]=Y[Vo]=!0,Y[wo]=Y[Co]=Y[Mo]=Y[xo]=Y[Ro]=Y[To]=Y[So]=Y[Po]=Y[Eo]=Y[Fo]=Y[jo]=Y[Do]=Y[Ao]=Y[Oo]=Y[$o]=!1;function Uo(e){return le(e)&&ar(e.length)&&!!Y[pe(e)]}function qo(e){return function(t){return e(t)}}var pr=typeof M=="object"&&M&&!M.nodeType&&M,Ie=pr&&typeof module=="object"&&module&&!module.nodeType&&module,Yo=Ie&&Ie.exports===pr,yt=Yo&&Kt.process,gr=function(){try{var e=Ie&&Ie.require&&Ie.require("util").types;return e||yt&&yt.binding&&yt.binding("util")}catch{}}(),hr=gr&&gr.isTypedArray,_t=hr?qo(hr):Uo,Go=Object.prototype,Xo=Go.hasOwnProperty;function mr(e,t){var r=te(e),n=!r&&vt(e),o=!r&&!n&&Ye(e),s=!r&&!n&&!o&&_t(e),i=r||n||o||s,a=i?go(e.length,String):[],c=a.length;for(var u in e)(t||Xo.call(e,u))&&!(i&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||ht(u,c)))&&a.push(u);return a}function br(e,t){return function(r){return e(t(r))}}var Ko=br(Object.keys,Object),Jo=Object.prototype,Zo=Jo.hasOwnProperty;function Qo(e){if(!bt(e))return Ko(e);var t=[];for(var r in Object(e))Zo.call(e,r)&&r!="constructor"&&t.push(r);return t}function es(e){return qe(e)?mr(e):Qo(e)}function ts(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var rs=Object.prototype,ns=rs.hasOwnProperty;function os(e){if(!se(e))return ts(e);var t=bt(e),r=[];for(var n in e)n=="constructor"&&(t||!ns.call(e,n))||r.push(n);return r}function vr(e){return qe(e)?mr(e,!0):os(e)}var ss=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,is=/^\w*$/;function as(e,t){if(te(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||dt(e)?!0:is.test(e)||!ss.test(e)||t!=null&&e in Object(t)}var ze=Te(Object,"create");function ls(){this.__data__=ze?ze(null):{},this.size=0}function cs(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var us="__lodash_hash_undefined__",fs=Object.prototype,ds=fs.hasOwnProperty;function ps(e){var t=this.__data__;if(ze){var r=t[e];return r===us?void 0:r}return ds.call(t,e)?t[e]:void 0}var gs=Object.prototype,hs=gs.hasOwnProperty;function ms(e){var t=this.__data__;return ze?t[e]!==void 0:hs.call(t,e)}var bs="__lodash_hash_undefined__";function vs(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ze&&t===void 0?bs:t,this}function Se(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Se.prototype.clear=ls,Se.prototype.delete=cs,Se.prototype.get=ps,Se.prototype.has=ms,Se.prototype.set=vs;function ys(){this.__data__=[],this.size=0}function Ge(e,t){for(var r=e.length;r--;)if(ke(e[r][0],t))return r;return-1}var _s=Array.prototype,ws=_s.splice;function Cs(e){var t=this.__data__,r=Ge(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():ws.call(t,r,1),--this.size,!0}function xs(e){var t=this.__data__,r=Ge(t,e);return r<0?void 0:t[r][1]}function Ts(e){return Ge(this.__data__,e)>-1}function Ss(e,t){var r=this.__data__,n=Ge(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function ge(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ge.prototype.clear=ys,ge.prototype.delete=Cs,ge.prototype.get=xs,ge.prototype.has=Ts,ge.prototype.set=Ss;var Le=Te(de,"Map");function Ps(){this.size=0,this.__data__={hash:new Se,map:new(Le||ge),string:new Se}}function Es(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Xe(e,t){var r=e.__data__;return Es(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Fs(e){var t=Xe(this,e).delete(e);return this.size-=t?1:0,t}function js(e){return Xe(this,e).get(e)}function Ds(e){return Xe(this,e).has(e)}function As(e,t){var r=Xe(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function he(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}he.prototype.clear=Ps,he.prototype.delete=Fs,he.prototype.get=js,he.prototype.has=Ds,he.prototype.set=As;var Os="Expected a function";function wt(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Os);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],s=r.cache;if(s.has(o))return s.get(o);var i=e.apply(this,n);return r.cache=s.set(o,i)||s,i};return r.cache=new(wt.Cache||he),r}wt.Cache=he;var $s=500;function Ms(e){var t=wt(e,function(n){return r.size===$s&&r.clear(),n}),r=t.cache;return t}var Rs=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ks=/\\(\\)?/g,Is=Ms(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Rs,function(r,n,o,s){t.push(o?s.replace(ks,"$1"):n||r)}),t});function zs(e){return e==null?"":tr(e)}function Ls(e,t){return te(e)?e:as(e,t)?[e]:Is(zs(e))}var Ns=1/0;function Ws(e){if(typeof e=="string"||dt(e))return e;var t=e+"";return t=="0"&&1/e==-Ns?"-0":t}function Bs(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var yr=br(Object.getPrototypeOf,Object),Hs="[object Object]",Vs=Function.prototype,Us=Object.prototype,_r=Vs.toString,qs=Us.hasOwnProperty,Ys=_r.call(Object);function Gs(e){if(!le(e)||pe(e)!=Hs)return!1;var t=yr(e);if(t===null)return!0;var r=qs.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&_r.call(r)==Ys}function Xs(){this.__data__=new ge,this.size=0}function Ks(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function Js(e){return this.__data__.get(e)}function Zs(e){return this.__data__.has(e)}var Qs=200;function ei(e,t){var r=this.__data__;if(r instanceof ge){var n=r.__data__;if(!Le||n.length<Qs-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new he(n)}return r.set(e,t),this.size=r.size,this}function me(e){var t=this.__data__=new ge(e);this.size=t.size}me.prototype.clear=Xs,me.prototype.delete=Ks,me.prototype.get=Js,me.prototype.has=Zs,me.prototype.set=ei;var wr=typeof M=="object"&&M&&!M.nodeType&&M,Cr=wr&&typeof module=="object"&&module&&!module.nodeType&&module,ti=Cr&&Cr.exports===wr,xr=ti?de.Buffer:void 0;xr&&xr.allocUnsafe;function ri(e,t){return e.slice()}function ni(e,t){for(var r=-1,n=e==null?0:e.length,o=0,s=[];++r<n;){var i=e[r];t(i,r,e)&&(s[o++]=i)}return s}function oi(){return[]}var si=Object.prototype,ii=si.propertyIsEnumerable,Tr=Object.getOwnPropertySymbols,ai=Tr?function(e){return e==null?[]:(e=Object(e),ni(Tr(e),function(t){return ii.call(e,t)}))}:oi;function li(e,t,r){var n=t(e);return te(e)?n:Bs(n,r(e))}function Sr(e){return li(e,es,ai)}var Ct=Te(de,"DataView"),xt=Te(de,"Promise"),Tt=Te(de,"Set"),Pr="[object Map]",ci="[object Object]",Er="[object Promise]",Fr="[object Set]",jr="[object WeakMap]",Dr="[object DataView]",ui=xe(Ct),fi=xe(Le),di=xe(xt),pi=xe(Tt),gi=xe(gt),we=pe;(Ct&&we(new Ct(new ArrayBuffer(1)))!=Dr||Le&&we(new Le)!=Pr||xt&&we(xt.resolve())!=Er||Tt&&we(new Tt)!=Fr||gt&&we(new gt)!=jr)&&(we=function(e){var t=pe(e),r=t==ci?e.constructor:void 0,n=r?xe(r):"";if(n)switch(n){case ui:return Dr;case fi:return Pr;case di:return Er;case pi:return Fr;case gi:return jr}return t});var Ke=de.Uint8Array;function hi(e){var t=new e.constructor(e.byteLength);return new Ke(t).set(new Ke(e)),t}function mi(e,t){var r=hi(e.buffer);return new e.constructor(r,e.byteOffset,e.length)}function bi(e){return typeof e.constructor=="function"&&!bt(e)?qn(yr(e)):{}}var vi="__lodash_hash_undefined__";function yi(e){return this.__data__.set(e,vi),this}function _i(e){return this.__data__.has(e)}function Je(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new he;++t<r;)this.add(e[t])}Je.prototype.add=Je.prototype.push=yi,Je.prototype.has=_i;function wi(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function Ci(e,t){return e.has(t)}var xi=1,Ti=2;function Ar(e,t,r,n,o,s){var i=r&xi,a=e.length,c=t.length;if(a!=c&&!(i&&c>a))return!1;var u=s.get(e),f=s.get(t);if(u&&f)return u==t&&f==e;var h=-1,d=!0,v=r&Ti?new Je:void 0;for(s.set(e,t),s.set(t,e);++h<a;){var g=e[h],y=t[h];if(n)var C=i?n(y,g,h,t,e,s):n(g,y,h,e,t,s);if(C!==void 0){if(C)continue;d=!1;break}if(v){if(!wi(t,function(j,P){if(!Ci(v,P)&&(g===j||o(g,j,r,n,s)))return v.push(P)})){d=!1;break}}else if(!(g===y||o(g,y,r,n,s))){d=!1;break}}return s.delete(e),s.delete(t),d}function Si(e){var t=-1,r=Array(e.size);return e.forEach(function(n,o){r[++t]=[o,n]}),r}function Pi(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Ei=1,Fi=2,ji="[object Boolean]",Di="[object Date]",Ai="[object Error]",Oi="[object Map]",$i="[object Number]",Mi="[object RegExp]",Ri="[object Set]",ki="[object String]",Ii="[object Symbol]",zi="[object ArrayBuffer]",Li="[object DataView]",Or=_e?_e.prototype:void 0,St=Or?Or.valueOf:void 0;function Ni(e,t,r,n,o,s,i){switch(r){case Li:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case zi:return!(e.byteLength!=t.byteLength||!s(new Ke(e),new Ke(t)));case ji:case Di:case $i:return ke(+e,+t);case Ai:return e.name==t.name&&e.message==t.message;case Mi:case ki:return e==t+"";case Oi:var a=Si;case Ri:var c=n&Ei;if(a||(a=Pi),e.size!=t.size&&!c)return!1;var u=i.get(e);if(u)return u==t;n|=Fi,i.set(e,t);var f=Ar(a(e),a(t),n,o,s,i);return i.delete(e),f;case Ii:if(St)return St.call(e)==St.call(t)}return!1}var Wi=1,Bi=Object.prototype,Hi=Bi.hasOwnProperty;function Vi(e,t,r,n,o,s){var i=r&Wi,a=Sr(e),c=a.length,u=Sr(t),f=u.length;if(c!=f&&!i)return!1;for(var h=c;h--;){var d=a[h];if(!(i?d in t:Hi.call(t,d)))return!1}var v=s.get(e),g=s.get(t);if(v&&g)return v==t&&g==e;var y=!0;s.set(e,t),s.set(t,e);for(var C=i;++h<c;){d=a[h];var j=e[d],P=t[d];if(n)var D=i?n(P,j,d,t,e,s):n(j,P,d,e,t,s);if(!(D===void 0?j===P||o(j,P,r,n,s):D)){y=!1;break}C||(C=d=="constructor")}if(y&&!C){var z=e.constructor,W=t.constructor;z!=W&&"constructor"in e&&"constructor"in t&&!(typeof z=="function"&&z instanceof z&&typeof W=="function"&&W instanceof W)&&(y=!1)}return s.delete(e),s.delete(t),y}var Ui=1,$r="[object Arguments]",Mr="[object Array]",Ze="[object Object]",qi=Object.prototype,Rr=qi.hasOwnProperty;function Yi(e,t,r,n,o,s){var i=te(e),a=te(t),c=i?Mr:we(e),u=a?Mr:we(t);c=c==$r?Ze:c,u=u==$r?Ze:u;var f=c==Ze,h=u==Ze,d=c==u;if(d&&Ye(e)){if(!Ye(t))return!1;i=!0,f=!1}if(d&&!f)return s||(s=new me),i||_t(e)?Ar(e,t,r,n,o,s):Ni(e,t,c,r,n,o,s);if(!(r&Ui)){var v=f&&Rr.call(e,"__wrapped__"),g=h&&Rr.call(t,"__wrapped__");if(v||g){var y=v?e.value():e,C=g?t.value():t;return s||(s=new me),o(y,C,r,n,s)}}return d?(s||(s=new me),Vi(e,t,r,n,o,s)):!1}function kr(e,t,r,n,o){return e===t?!0:e==null||t==null||!le(e)&&!le(t)?e!==e&&t!==t:Yi(e,t,r,n,kr,o)}function Gi(e){return function(t,r,n){for(var o=-1,s=Object(t),i=n(t),a=i.length;a--;){var c=i[++o];if(r(s[c],c,s)===!1)break}return t}}var Xi=Gi();function Pt(e,t,r){(r!==void 0&&!ke(e[t],r)||r===void 0&&!(t in e))&&mt(e,t,r)}function Ki(e){return le(e)&&qe(e)}function Et(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function Ji(e){return io(e,vr(e))}function Zi(e,t,r,n,o,s,i){var a=Et(e,r),c=Et(t,r),u=i.get(c);if(u){Pt(e,r,u);return}var f=s?s(a,c,r+"",e,t,i):void 0,h=f===void 0;if(h){var d=te(c),v=!d&&Ye(c),g=!d&&!v&&_t(c);f=c,d||v||g?te(a)?f=a:Ki(a)?f=Gn(a):v?(h=!1,f=ri(c)):g?(h=!1,f=mi(c)):f=[]:Gs(c)||vt(c)?(f=a,vt(a)?f=Ji(a):(!se(a)||Z(a))&&(f=bi(c))):h=!1}h&&(i.set(c,f),o(f,c,n,s,i),i.delete(c)),Pt(e,r,f)}function Ir(e,t,r,n,o){e!==t&&Xi(t,function(s,i){if(o||(o=new me),se(s))Zi(e,t,i,r,Ir,n,o);else{var a=n?n(Et(e,i),s,i+"",e,t,o):void 0;a===void 0&&(a=s),Pt(e,i,a)}},vr)}var Qi="[object String]";function zr(e){return typeof e=="string"||!te(e)&&le(e)&&pe(e)==Qi}var ea="[object Boolean]";function Ft(e){return e===!0||e===!1||le(e)&&pe(e)==ea}function Qe(e,t){return kr(e,t)}var ta="[object Number]";function ra(e){return typeof e=="number"||le(e)&&pe(e)==ta}function Lr(e){return e==null}function na(e){return e===null}var ce=fo(function(e,t,r){Ir(e,t,r)});function oa(e,t,r,n){if(!se(e))return e;t=Ls(t,e);for(var o=-1,s=t.length,i=s-1,a=e;a!=null&&++o<s;){var c=Ws(t[o]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(o!=i){var f=a[c];u=void 0,u===void 0&&(u=se(f)?f:ht(t[o+1])?[]:{})}sr(a,c,u),a=a[c]}return e}function Nr(e,t,r){return e==null?e:oa(e,t,r)}function sa(e){const{inherit:t=!0}=e,{extendActionsProps:r,extendAuthProps:n}=Ur(),s={...ce(ce({items:[],max:10},t?r:{}),e)},i={...ce({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:i}}function Wr(e){return"component"in e}function ia(e){return"render"in e}function aa(e,t){const{type:r,disabled:n,items:o,max:s}=e,i=h=>{const{auth:d}=h;let v=!1;return d?te(d)?v=d.every(g=>t(g)):v=t(d):v=!0,v},a=h=>{let{ifShow:d=!0}=h;return d=d&&Z(d)?d():d,d&&i(h)},c=h=>{const{component:d,render:v,componentProps:g}=h;if(d)switch(d){case"Dropdown":{const{dropDownItems:y}=g;return!!y.length}default:return!0}return!!v},u=o.map(h=>{const d={...h};if(Wr(d)){const v=d.component;switch(d.componentProps={type:r,disabled:n,...d.componentProps},v){case"Dropdown":{d.componentProps.dropDownItems=(d.componentProps.dropDownItems||[]).filter(a);break}}}return d}).filter(a).filter(c),f=ra(s)&&s>=0;return{showActionItems:u.slice(0,f?s:u.length),ellipsisActionItems:u.slice(f?s:u.length)}}const la=e=>{const{componentProps:t}=e,r=()=>{const{...n}=t;return n};return m.jsx(T.Button,{...r()})},ca=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...i}=t;return i})();return m.jsx(T.Dropdown,{disabled:n.disabled,menu:{items:t==null?void 0:t.dropDownItems,onClick:t==null?void 0:t.onClick},trigger:["click"],children:m.jsx("div",{children:m.jsxs(T.Button,{...n,children:[n.children,m.jsx(fe.CaretDownOutlined,{})]})})})},et=new Map;et.set("Button",la),et.set("Dropdown",ca);function Br(){const{setExtendActionsComp:e}=Ur();return e(et),{renderContent:p.useCallback((r,n)=>{const o=Wr(r),s=ia(r);if(o){const i=et.get(r.component);return p.createElement(i,{...r,key:n})}return s?m.jsx("div",{children:r.render},n):null},[])}}const Hr=p.createContext({}),ua=e=>{const{extendProps:t,extendComp:r}=e.value;return m.jsx(Hr.Provider,{value:{extendProps:t,extendComp:r},children:e.children})},Fe=()=>p.useContext(Hr),Vr=e=>{const[t,r]=p.useState(e),n=p.useRef(null);return p.useEffect(()=>{n.current&&(n.current(),n.current=null)},[t]),[t,s=>new Promise((i,a)=>{r(c=>{const u=typeof s=="function"?s(c):s;return n.current=i,u})})]},Ur=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.actions;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendAuthProps:e==null?void 0:e.auth,extendActionsProps:e==null?void 0:e.actions,setExtendActionsComp:r}},{useToken:fa}=T.theme,da=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Br(),{token:s}=fa(),i={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},a=()=>m.jsx("div",{style:i,children:m.jsx(T.Space,{style:{padding:8},children:e==null?void 0:e.map((c,u)=>o(c,u))})});return m.jsx(T.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:a,trigger:["click"],children:m.jsxs(T.Button,{type:r,children:["更多",m.jsx(fe.CaretDownOutlined,{})]})})},tt=e=>{const{actionsProps:t,authProps:r}=sa(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=aa(t,n),{renderContent:i}=Br();return t!=null&&t.render?t.render:m.jsxs(p.Fragment,{children:[o==null?void 0:o.map((a,c)=>i(a,c)),s!=null&&s.length?m.jsx(da,{actionsProps:t,items:s}):null]})};function pa(e,t){const{okText:r,cancelText:n,onCancel:o,onOk:s,okProps:i,cancelProps:a}=e;return{footerActions:{disabled:t,max:2,items:[{component:"Button",componentProps:{...a,children:n,onClick:o}},{component:"Button",componentProps:{type:"primary",loading:t,...i,children:r,onClick:s}}]}}}const ga=e=>{const{extendDialogProps:t}=ha(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body},n={...ce(ce(r,t),e)};return{dialogProps:{...n,getPopperContainer:()=>{const s=n.getPopperContainer();return n.mask?document.body:s}},baseDialogProps:r}},ha=()=>{const{extendProps:e}=Fe();return{extendDialogProps:e==null?void 0:e.dialog}},ma=(e,t,r,n)=>{const{onOpen:o,onClose:s}=t;return{open:async()=>{e||(o&&o(),await r(!0))},close:()=>{r(!1),n(!1),s&&s()}}},ba=({initWidth:e,initHeight:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,i]=p.useState(t.current);return{dialogWidth:n,dialogHeight:s,setDialogSize:({width:c,height:u})=>{r({width:n,height:s}),c!==void 0&&o(c),u!==void 0&&i(u)}}},va=({initLeft:e,initTop:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,i]=p.useState(t.current);return{dialogLeft:n,dialogTop:s,setDialogPosition:({left:c,top:u})=>{r({left:n,top:s}),c!==void 0&&o(c),u!==void 0&&i(u)}}},qr=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=p.useRef(0),s=p.useRef(0),i=f=>{const h=f.getBoundingClientRect(),d=h.width,v=h.height,g=-.5*d,y=-.5*v;return{translateX:g,translateY:y}},a=p.useCallback(f=>{const{offsetLeft:h,offsetTop:d}=r.current;o.current=f.clientX-h,s.current=f.clientY-d,document.addEventListener("mousemove",c),document.addEventListener("mouseup",u)},[]),c=p.useCallback(f=>{const h=r.current,{translateX:d,translateY:v}=i(h);let g=f.clientX-o.current,y=f.clientY-s.current;const C=-d,j=-v,P=e.current.scrollWidth-h.offsetWidth-d,D=e.current.scrollHeight-h.offsetHeight-v;g<C&&(g=C),g>P&&(g=P),y<j&&(y=j),y>D&&(y=D),n({left:g,top:y})},[]),u=p.useCallback(()=>{document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",u)},[]);return p.useEffect(()=>{const f=t.current;return f.addEventListener("mousedown",a),()=>{f.removeEventListener("mousedown",a)}},[]),{}},ya=({containerSizeTarget:e,dialogChangeRecord:t,close:r,setDialogSize:n,setDialogPosition:o})=>{const[s,i]=p.useState(!1),[a,c]=p.useState(!1);return{minimizeVisible:s,maximizeVisible:a,setMinimizeVisible:i,setMaximizeVisible:c,onMinimize:()=>{i(!0)},onMaximize:v=>{if(v==="minimize"&&i(!1),v==="maximize"){const{scrollWidth:g,scrollHeight:y}=e.current,C=Math.floor(g),j=Math.floor(y),P=Math.floor(g/2),D=Math.floor(y/2);n({width:C,height:j}),o({top:D,left:P}),c(!0)}},onRecovery:()=>{const{top:v,left:g,width:y,height:C}=t.current;n({width:y,height:C}),o({top:v,left:g}),c(!1)},onClose:()=>{i(!1),c(!1),r()}}},_a=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:i,scrollHeight:a}=t.current,[c,u]=p.useState(0),[f,h]=p.useState("unset"),d=(v,g)=>{var W,G;const j=(W=o.current)==null?void 0:W.offsetHeight,P=(G=s.current)==null?void 0:G.offsetHeight;let D=v-j-P-0;const z=g-j-P-0;return D>z&&(D=z),D};return p.useEffect(()=>{var v;if(c===i){console.log("触发了dialogMaxHeight改变");const g=(v=n.current)==null?void 0:v.getBoundingClientRect().height;h(d(g,i)),u("unset")}},[c]),p.useEffect(()=>{r!=="unset"&&r!==0&&(console.log("触发了重新设置contentMaxHeight",r),h(d(r,r>i?a:i)),u("unset"))},[r]),p.useEffect(()=>{e?u(i):(u(0),h("unset"))},[e]),{dialogMaxHeight:c,contentMaxHeight:f}},wa=()=>{const[e,t]=p.useState(160),[r,n]=p.useState(60),o=p.useRef(null);return{minimizeTop:r,minimizeLeft:e,minimizeRef:o,setMinimizePosition:({left:i,top:a})=>{i!==void 0&&t(i),a!==void 0&&n(a)}}},Ca=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=(a,c)=>{console.log("触发插入"),a.querySelector(`.${o.xphDialogWrapper}`).style.opacity="unset",a.querySelector(`.${o.xphMinimizeDialog}`).style.opacity="unset",c.querySelector(`.${o.xphDialogWrapper}`).style.opacity=.7,c.querySelector(`.${o.xphMinimizeDialog}`).style.opacity=.7;const u=document.createElement("div");u.style.visibility="hidden",c.parentNode.insertBefore(u,c.nextSibling),c.parentNode.insertBefore(a,u),c.parentNode.removeChild(u)},i=a=>{var f,h;const c=n.querySelectorAll(`.${o.xphDialog}`),u=c[c.length-1];if(((f=t.current)==null?void 0:f.parentNode)!==u&&(s((h=t.current)==null?void 0:h.parentNode,u),a)){const d=a.target;d.tagName==="INPUT"&&d.focus&&d.focus()}};return p.useEffect(()=>{var a,c;return(a=t.current)==null||a.addEventListener("mousedown",i,!1),(c=r.current)==null||c.addEventListener("mousedown",i,!1),()=>{var u,f;(u=t.current)==null||u.removeEventListener("mousedown",i,!1),(f=r.current)==null||f.removeEventListener("mousedown",i,!1)}},[]),p.useEffect(()=>{if(e)i();else{const a=Array.from(n.querySelectorAll(`.${o.xphDialog}`)),c=a.map(d=>d.querySelector(`.${o.xphDialogWrapper}`)).filter(d=>d!==null),u=a.map(d=>d.querySelector(`.${o.xphMinimizeDialog}`)).filter(d=>d!==null),f=c.filter(d=>d.style.display==="flex"),h=u.filter(d=>d.style.display==="flex");if(f.length){s(f[f.length-1].parentNode,a[a.length-1]);return}if(h.length){s(h[h.length-1].parentNode,a[a.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},xa=({initWidth:e,initHeight:t,initLeft:r,initTop:n,curPropsWidth:o,curPropsHeight:s,setDialogSize:i,setDialogPosition:a})=>{p.useEffect(()=>{o!==e.current&&(console.log("重新设置了宽度"),i({width:o})),s!==t.current&&(console.log("重新设置了高度"),i({height:s}))},[o,s]),p.useEffect(()=>{o!==e.current&&(console.log("重新设置了左边位置"),a({left:r.current})),s!==t.current&&(console.log("重新设置了上边位置"),a({top:n.current}))},[o,s])},Ta=()=>{const e=p.useRef({left:0,top:0,width:0,height:0});return{dialogChangeRecord:e,setDialogChangeRecord:({left:r,top:n,width:o,height:s})=>{const{left:i,top:a,width:c,height:u}=e.current;e.current={left:r??i,top:n??a,width:o??c,height:s??u}}}},Sa=({containerSizeTarget:e,dialogRef:t,minResizeRecord:r,setDialogSize:n,setDialogPosition:o})=>{const s=p.useCallback(()=>m.jsx("div",{ref:i,style:{position:"absolute",border:"4px dashed #ccc",display:"none"}}),[]),i=p.useRef(null),a=p.useRef(),c=p.useRef(!1),[u,f]=p.useState(!1),h=p.useRef(0),d=p.useRef(0),v=(k,S)=>{c.current=!0,f(!0),a.current=S;const{clientX:x,clientY:w}=k;h.current=x,d.current=w;const E=parseFloat(t.current.style.left),O=parseFloat(t.current.style.top),A=t.current.offsetWidth,$=t.current.offsetHeight;i.current.style.display="block",i.current.style.left=`${E-.5*A}px`,i.current.style.top=`${O-.5*$}px`,i.current.style.width=`${A}px`,i.current.style.height=`${$}px`},g=k=>{if(c.current){const{clientX:S,clientY:x}=k,w=S-h.current,E=x-d.current,O=parseFloat(i.current.style.left),A=parseFloat(i.current.style.top),$=i.current.offsetWidth,B=i.current.offsetHeight,Q=r.current.width,ne=r.current.height,ue=e.current.scrollWidth,ie=e.current.scrollHeight;let H=$,V=B,q=O,X=A;switch(a.current){case"lt":{H=H-w,V=V-E,X=X+E,q=q+w,H<Q&&(H=$,q=O),V<ne&&(V=B,X=A),q<0&&(q=0,H=$),X<0&&(X=0,V=B);break}case"rt":{H=H+w,V=V-E,X=X+E,q=O,H<Q&&(H=$),V<ne&&(V=B,X=A),H>ue-q&&(H=ue-q),X<0&&(X=0,V=B);break}case"rb":{H=H+w,V=V+E,X=A,q=O,H<Q&&(H=$),V<ne&&(V=B),H>ue-q&&(H=ue-q),V>ie-X&&(V=ie-X);break}case"lb":{H=H-w,V=V+E,X=A,q=q+w,H<Q&&(H=$,q=O),V<ne&&(V=B),q<0&&(q=0,H=$),V>ie-X&&(V=ie-X);break}}i.current.style.left=`${q}px`,i.current.style.top=`${X}px`,i.current.style.width=`${H}px`,i.current.style.height=`${V}px`,h.current=S,d.current=x}},y=()=>{if(c.current){c.current=!1,f(!1),i.current.style.display="none";const{left:k,top:S,width:x,height:w}=i.current.style,E=parseFloat(k)+.5*parseFloat(x),O=parseFloat(S)+.5*parseFloat(w),A=parseFloat(x),$=parseFloat(w);o({left:E,top:O}),n({width:A,height:$})}},C=k=>v(k,"lt"),j=k=>v(k,"rt"),P=k=>v(k,"rb"),D=k=>v(k,"lb"),z=p.useCallback(k=>{g(k)},[]),W=p.useCallback(()=>{y()},[]),G=p.useCallback(()=>{y()},[]);return p.useEffect(()=>(document.body.addEventListener("mousemove",z),document.body.addEventListener("mouseup",W),document.body.addEventListener("mouseleave",G),()=>{document.body.removeEventListener("mousemove",z),document.body.removeEventListener("mouseup",W),document.body.removeEventListener("mouseleave",G)}),[]),{resizingState:u,DashedBox:s,onMousedownResizeLt:C,onMousedownResizeRt:j,onMousedownResizeRb:P,onMousedownResizeLb:D}},Pa=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=p.useState(0),s=()=>{o(S=>S+1)};p.useEffect(()=>(window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}),[]);const{containerSizeTarget:i,setContainerSizeTarget:a}=Fa({container:e}),{width:c,height:u}=r,{width:f,height:h}=t,d=f||c,v=h||u,{clientWidth:g,clientHeight:y}=i.current,C=d?d>g?g:d:0,j=v?v>y?y:v:"unset",P=p.useRef(C),D=p.useRef(j),z=S=>{P.current=S.width,D.current=S.height},W=p.useRef(Math.floor(g/2)),G=p.useRef(Math.floor(y/2)),k=S=>{W.current=S.left,G.current=S.top};return p.useEffect(()=>{a(),z({width:C,height:j}),k({left:Math.floor(g/2),top:Math.floor(y/2)})},[n]),{containerSizeTarget:i,parentResizeRecord:n,initLeft:W,initTop:G,initWidth:P,initHeight:D,curPropsWidth:C,curPropsHeight:j,setInitPosition:k,setInitSize:z}},Ea=(e,t,r,n)=>{const o=p.useRef(null);return p.useEffect(()=>{if(e){const s=t.current.offsetWidth,i=t.current.offsetHeight;o.current={width:s,height:i}}else o.current=null},[r,n,e]),{minResizeRecord:o}},Fa=({container:e})=>{const t=e===document.body,r=p.useRef({clientWidth:t?window.innerWidth:e.clientWidth,clientHeight:t?window.innerHeight:e.clientHeight,scrollWidth:t?window.innerWidth:e.scrollWidth,scrollHeight:t?window.innerHeight:e.scrollHeight});return{containerSizeTarget:r,setContainerSizeTarget:()=>{r.current={clientWidth:t?window.innerWidth:e.clientWidth,clientHeight:t?window.innerHeight:e.clientHeight,scrollWidth:t?window.innerWidth:e.scrollWidth,scrollHeight:t?window.innerHeight:e.scrollHeight}}}},jt={"minimize-windows":"_minimize-windows_12u3y_1","minimize-windows-title":"_minimize-windows-title_12u3y_43","minimize-windows-operate":"_minimize-windows-operate_12u3y_55"},ja=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.ShrinkOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Yr=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Da=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenExitOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Gr=({onClick:e,disabled:t})=>m.jsx(T.Button,{type:"link",onClick:e,disabled:t,icon:m.jsx(fe.CloseOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),{useToken:Aa}=T.theme,Oa=p.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:i,className:a},c)=>{const{token:u}=Aa(),f={borderRadius:u.borderRadiusLG};return m.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...f},className:`${jt["minimize-windows"]} ${a}`,ref:c,children:[m.jsx("div",{className:jt["minimize-windows-title"],title:e,children:e}),m.jsxs("div",{className:jt["minimize-windows-operate"],children:[m.jsx(Yr,{onClick:s}),m.jsx(Gr,{onClick:i,disabled:o})]})]})}),re={"xph-dialog-mask":"_xph-dialog-mask_128q2_1","xph-dialog-wrapper":"_xph-dialog-wrapper_128q2_23",dialog__header:"_dialog__header_128q2_45","dialog__header-btns":"_dialog__header-btns_128q2_63",dialog__main:"_dialog__main_128q2_71",dialog__footer:"_dialog__footer_128q2_85",dialog__resize:"_dialog__resize_128q2_99","dialog__resize-lt":"_dialog__resize-lt_128q2_113","dialog__resize-rt":"_dialog__resize-rt_128q2_125","dialog__resize-rb":"_dialog__resize-rb_128q2_137","dialog__resize-lb":"_dialog__resize-lb_128q2_149"},{useToken:$a}=T.theme,Ma=p.forwardRef((e,t)=>{console.log("render Dialog==============================================");const{token:r}=$a(),n={borderRadius:r.borderRadiusLG},{children:o,baseDialogProps:s,mask:i,title:a,renderFooter:c,renderTitle:u,getPopperContainer:f}=e,h=f(),[d,v]=Vr(!1),[g,y]=p.useState(!1),{open:C,close:j}=ma(d,e,v,y),{footerActions:P}=pa(e,g),D=p.useRef(null),z=p.useRef(null),W=p.useRef(null),G=p.useRef(null),{containerSizeTarget:k,parentResizeRecord:S,initLeft:x,initTop:w,initWidth:E,initHeight:O,curPropsWidth:A,curPropsHeight:$}=Pa({container:h,dialogProps:e,baseDialogProps:s}),{dialogChangeRecord:B,setDialogChangeRecord:Q}=Ta(),{dialogWidth:ne,dialogHeight:ue,setDialogSize:ie}=ba({initWidth:E,initHeight:O,setDialogChangeRecord:Q}),{dialogLeft:H,dialogTop:V,setDialogPosition:q}=va({initTop:w,initLeft:x,setDialogChangeRecord:Q}),{dialogMaxHeight:X,contentMaxHeight:$t}=_a({visible:d,containerSizeTarget:k,dialogHeight:ue,dialogRef:D,dialogHeaderRef:z,dialogFooterRef:G}),{minResizeRecord:Mt}=Ea(d,D,ne,ue),{minimizeLeft:Ne,minimizeTop:We,minimizeRef:ve,setMinimizePosition:je}=wa(),{minimizeVisible:Pe,maximizeVisible:Rt,setMaximizeVisible:ot,onMaximize:st,onMinimize:kt,onRecovery:De,onClose:ye}=ya({containerSizeTarget:k,dialogChangeRecord:B,close:j,setDialogSize:ie,setDialogPosition:q}),it=()=>{console.log("触发了initDialog"),ie({width:E.current,height:O.current}),q({left:x.current,top:w.current}),je({left:160,top:60}),ot(!1)};p.useEffect(()=>{it()},[S]),xa({initWidth:E,initHeight:O,initLeft:x,initTop:w,curPropsWidth:A,curPropsHeight:$,setDialogSize:ie,setDialogPosition:q}),qr({containerSizeTarget:k,dialogHeaderRef:z,dialogRef:D,setDialogPosition:q}),qr({containerSizeTarget:k,dialogHeaderRef:ve,dialogRef:ve,setDialogPosition:je});const{dialogTopShowClassConfig:Ce}=Ca({visible:d,container:h,dialogRef:D,minimizeRef:ve}),{resizingState:zt,DashedBox:Lt,onMousedownResizeLt:Be,onMousedownResizeRt:Nt,onMousedownResizeRb:Wt,onMousedownResizeLb:at}=Sa({containerSizeTarget:k,dialogRef:D,minResizeRecord:Mt,setDialogSize:ie,setDialogPosition:q});return p.useImperativeHandle(t,()=>({open:C,close:ye,setLoading:y,getVisible:()=>d})),m.jsxs("div",{className:Ce.xphDialog,children:[i&&d?m.jsx("div",{className:re["xph-dialog-mask"]}):null,m.jsx(Oa,{visible:Pe,className:`${Ce.xphMinimizeDialog}`,loading:g,ref:ve,left:Ne,top:We,title:a,onMaximize:()=>st("minimize"),onClosesquare:ye}),m.jsxs("div",{ref:D,className:`${re["xph-dialog-wrapper"]} ${Ce.xphDialogWrapper}`,style:{display:d&&!Pe?"flex":"none",left:H,top:V,width:ne,height:ue,maxHeight:X,opacity:zt?.2:"unset",...n},children:[m.jsxs("div",{ref:z,className:re.dialog__header,children:[m.jsx("div",{children:u?u():a}),m.jsxs("div",{className:re["dialog__header-btns"],children:[m.jsx(ja,{onClick:kt}),Rt?m.jsx(Da,{onClick:De}):m.jsx(Yr,{onClick:()=>st("maximize")}),m.jsx(Gr,{onClick:ye,disabled:g})]})]}),m.jsx("div",{ref:W,className:re.dialog__main,style:{maxHeight:$t},children:m.jsx(T.Spin,{spinning:g,children:d?o:null})}),c?m.jsx("div",{ref:G,children:c({loading:g})}):m.jsx("div",{ref:G,className:re.dialog__footer,children:m.jsx(tt,{...P})}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lt"]}`,onMouseDown:Be}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rt"]}`,onMouseDown:Nt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rb"]}`,onMouseDown:Wt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lb"]}`,onMouseDown:at})]}),m.jsx(Lt,{})]})}),Ra=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=ga(n),{getPopperContainer:i}=s;return console.log("render XphDialog=============================================="),m.jsx(Kr,{getPopperContainer:i,children:m.jsx(Ma,{...s,baseDialogProps:o,ref:t,children:r})})},Xr=p.forwardRef(Ra),Kr=({children:e,getPopperContainer:t})=>{const[r,n]=p.useState(null);return p.useEffect(()=>{const o=t();n(o)},[]),r?hn.createPortal(e,r):null};function ka(e){const{extendAuthProps:t}=Ia();return{authProps:{...ce(ce({auth:o=>!1},t),e)}}}const Ia=()=>{const{extendProps:e}=Fe();return{extendAuthProps:e==null?void 0:e.auth}},za=e=>{const{children:t,...r}=e,{authProps:n}=ka(r),{auth:o,authCode:s}=n;return p.useMemo(()=>{let a=!1;return s&&o&&(te(s)?a=s.every(c=>o(c)):a=o(s)),a},[o,s])?t:null};function Dt(e){return"component"in e}function At(e){return"render"in e}function La(e){return e.includes("Input")||e.includes("Complete")?"请输入":e.includes("Picker")||e.includes("Select")||e.includes("Cascader")||e.includes("Checkbox")||e.includes("Radio")||e.includes("Switch")?"请选择":""}function Na(e,t,r){["DatePicker","MonthPicker","WeekPicker","TimePicker"].includes(t)?e.type=r?"string":"object":["RangePicker","Upload","CheckboxGroup","TimePicker"].includes(t)?e.type="array":["InputNumber"].includes(t)&&(e.type="number")}const Wa=["DatePicker","MonthPicker","RangePicker","WeekPicker","TimePicker"],Ba=e=>{const{show:t,ifShow:r,required:n,disabled:o,componentProps:s}=e;return!!(Z(t)||Z(r)||Z(n)||Z(o)||Z(s)||At(e))},Ha=e=>["application/json","application/javascript","text/plain","text/html","text/css"].includes(e)?`${e}; charset=utf-8`:e,Va=(e,t,r)=>{const n=p.useRef(null),o=p.useRef(null),{handleCollapseChangeFalse:s}=r.current||{},{show:i,ifShow:a}=e;let c=!0,u=!0;if(Ft(i)&&(c=i),Ft(a)&&(u=a),Z(i)){c=i({model:t});const f=Lr(n.current)?c:n.current;p.useEffect(()=>{Qe(c,f)||s&&s()},[t])}if(Z(a)){u=a({model:t});const f=Lr(o.current)?u:o.current;p.useEffect(()=>{Qe(u,f)||s&&s()},[t])}return n.current=c,o.current=u,{isShow:c,isIfShow:u}},Ua=(e,t)=>{const{collapsible:r,collapseNum:n}=e,[o,s]=p.useState(!!(r&&t>=n));return{itemCollapse:o,setItemCollapse:s}},qa=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:i}=e;let a=o;const c=Dt(e),u=c?La(e.component)+s:"";function f(g,y){const C=g.message||u;return y===void 0||na(y)||Array.isArray(y)&&y.length===0||typeof y=="string"&&y.trim()===""||typeof y=="object"&&Reflect.has(y,"checked")&&Reflect.has(y,"halfChecked")&&Array.isArray(y.checked)&&Array.isArray(y.halfChecked)&&y.checked.length===0&&y.halfChecked.length===0?Promise.reject(C):Promise.resolve()}const h=Z(i)?i({model:t}):i;h&&(!a||a.length===0?a=[{required:h,validator:f}]:a.findIndex(y=>Reflect.has(y,"required"))===-1&&a.push({required:h,validator:f}));const d=a.findIndex(g=>Reflect.has(g,"required")&&!Reflect.has(g,"validator"));if(d!==-1){const g=a[d];if(r||(g.required=!1),c){const{component:y}=e;Reflect.has(g,"type")||(g.type=y==="InputNumber"?"number":"string"),g.message=g.message||u,(y.includes("Input")||y.includes("Textarea"))&&(g.whitespace=!0);const C=n.valueFormat;Na(g,y,C)}}const v=a.findIndex(g=>g.max);return v!==-1&&!a[v].validator&&(a[v].message=a[v].message||`字符数应小于${a[v].max}位`),{rules:a}},Ya=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Z(s)&&(o=s({model:r})),Ft(s)&&(o=s),{disabled:Reflect.has(t,"disabled")?o:n}},Ga=(e,t)=>{const r={},{componentProps:n={}}=e;return Z(n)&&Object.assign(r,n({model:t})),Object.assign(r,n),{componentProps:r}},Xa=(e,t)=>{const{colProps:r={}}=e,{colProps:n={span:24}}=t;return{colProps:{...n,...r}}},Ka=({formProps:e})=>{const{items:t}=e;return{formItems:t.map(n=>({...n}))}},Ja=(e,t)=>{const r=a=>(Object.keys(a).forEach(c=>{Object.defineProperty(a,c,{value:a[c],writable:!1,enumerable:!0,configurable:!1})}),a),n={};e.items.forEach(a=>{n[a.name]=a.initialValue});const o=Ba(t),s=o?T.Form.useWatch(a=>r(a)):null;return{rewritingModel:p.useMemo(()=>s||r(n),[s]),isusewatch:o}},Za=()=>{const e=p.useRef(null);function t(n){e.current=n}const r={getFieldsValue:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.getFieldsValue(...n)},setFieldsValue:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.setFieldsValue(...n)},resetFields:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.resetFields(...n)},validator:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.validator(...n)},scrollToField:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.scrollToField(...n)}};return p.useEffect(()=>(console.log("ParentComponent is mounted====================================="),()=>{console.log("ParentComponent is unmounted===================================="),e.current=null}),[]),[t,r]};function Qa(e,t={}){const r=/^\[(.+)\]$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s=[];return o.forEach((i,a)=>{Nr(s,a,t[i.trim()])}),s.filter(Boolean).length?s:void 0}}}function el(e,t={}){const r=/^\{(.+)\}$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s={};return o.forEach(i=>{Nr(s,i.trim(),t[i.trim()])}),Object.values(s).filter(Boolean).length?s:void 0}}}function tl(e,t){const r=t.fieldMapToTime;if(!r||!Array.isArray(r))return e;for(const[n,[o,s],i="YYYY-MM-DD"]of r){if(!n||!o||!s)continue;if(!e[n]){Reflect.deleteProperty(e,n);continue}const[a,c]=e[n],[u,f]=Array.isArray(i)?i:[i,i];e[o]=Ve(a).format(u),e[s]=Ve(c).format(f),Reflect.deleteProperty(e,n)}return e}const rl=(e,t,r)=>{const n=e.filter(i=>i.name);return{handleFormatRenderValues:i=>{const a={},c=[];return n.forEach(u=>{const f=Reflect.has(i,u.name),h=Qa(u.name,i)||el(u.name,i);if(f||h){const d=h||i[u.name];if(Dt(u))if(Wa.includes(u.component)){if(te(d)){const v=[];for(const g of d)v.push(g?Ve(g):null);a[u.name]=v}else a[u.name]=d?Ve(d):null;c.push(u.name)}else a[u.name]=d,c.push(u.name);At(u)&&(a[u.name]=d,c.push(u.name))}}),{renderValues:a,validKeys:c}},handleFormatReturnValues:i=>{var c,u,f,h,d;if(!se(i))return{};const a={};for(const v of Object.entries(i)){let[,g]=v;const[y]=v;if(!y||Z(g))continue;const{transformDateFunc:C}=t,j=(f=(u=(c=r.current)==null?void 0:c.get(y))==null?void 0:u.current)==null?void 0:f.componentProps,P=j==null?void 0:j.valueFormat;if(se(g)){const D=g;D.format&&(g=C==null?void 0:C(D,P))}te(g)&&((h=g[0])!=null&&h.format)&&((d=g[1])!=null&&d.format)&&(g=g.map(D=>C==null?void 0:C(D,P))),zr(g)&&(g===""?g=void 0:g=g.trim()),a[y]=g}return tl(a,t)}}},nl=(e,t,r)=>({getFieldsValue:(...c)=>r(e.getFieldsValue(...c)),setFieldsValue:c=>{const{renderValues:u,validKeys:f}=t(c);e.setFieldsValue(u),e.validateFields(f)},resetFields:async()=>e.resetFields(),validator:async c=>e.validateFields(c).then(u=>r(u)),scrollToField:async(c,u)=>e.scrollToField(c,u)}),ol=e=>{const{extendFormProps:t}=Jr();return{formProps:{...ce(ce({collapseNum:5,colon:!1,items:[],labelWrap:!0,transformDateFunc:(o,s)=>{var i;return((i=o==null?void 0:o.format)==null?void 0:i.call(o,s||"YYYY-MM-DD HH:mm:ss"))??o},fieldMapToTime:[]},t),e)}}},rt=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,i=p.useRef(!0),a=p.useRef(r),c=()=>{n&&Z(n)&&(r?n(r).then(o):n().then(o),a.current=r)};return p.useEffect(()=>{i.current&&(t&&c(),i.current=!1),!i.current&&s&&(Qe(r,a.current)||t&&c())},[r]),{getApiData:c}},sl=(e,t)=>{const{collapsible:r,collapseNum:n}=e,o=p.useRef();return{collapsible:r,collapseNum:n,collapseRef:o,onClickCollapseToTrue:()=>{var a;(a=t.current)==null||a.forEach(c=>{if(c.current){const{itemIndex:u}=c.current;u>=n&&r&&c.current.setItemCollapse(!0)}})},onClickCollapseToFalse:()=>{var a;(a=t.current)==null||a.forEach(c=>{if(c.current){const{itemCollapse:u}=c.current;u&&c.current.setItemCollapse(!1)}})}}},Jr=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.form;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendFormProps:e==null?void 0:e.form,setExtendFormComp:r}},il=e=>{console.log("render ApiSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.Select,{...h(),options:a,onDropdownVisibleChange:f})},al=e=>{console.log("render ApiTreeSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.TreeSelect,{...h(),treeData:a,onDropdownVisibleChange:f})},ll=e=>{console.log("render ApiTransfer");const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,i]=p.useState([]);rt({api:t,params:r,apiCallback:i,isUseWatch:o});const a=()=>{const{api:c,params:u,isusewatch:f,...h}=e;return h};return m.jsx(T.Transfer,{...a(),dataSource:s})},cl=e=>{console.log("render ApiAutoComplete");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.AutoComplete,{...h(),options:a,onDropdownVisibleChange:f})},be={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},ul=e=>{console.log("render AutoUpload"),console.log(ct());const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:i=!1,data:a,returnType:c=be.String,value:u=t,onChange:f}=e,h=p.useRef(!0),d=p.useRef(0),v=p.useRef([]),[g,y]=p.useState([]),C=S=>{v.current=S,y([...S])},j=()=>{const{api:S,maxCount:x,maxSize:w,openCrop:E,beforeUpload:O,fileList:A,returnType:$,...B}=e;return B},P=S=>{const x=S.size/1024/1024<o;x||T.message.error(`文件大小超过:${o}M, 请重试`);const w=v.current.length+d.current<n;return w||T.message.error(`文件数量不能超过${n}个`),x&&w&&d.current++,x&&w&&D(S),T.Upload.LIST_IGNORE},D=S=>{i?(T.message.error("暂时不支持裁剪功能,后续兼容。。。。"),z({file:S})):z({file:S})},z=S=>{r?r({file:S.file,...a}).then(x=>{C([...v.current,...x])}).finally(()=>{d.current--}):(Object.assign(S.file,{status:"done",url:URL.createObjectURL(new Blob([S.file],{type:Ha(S.file.type)}))}),C([...v.current,S.file]),d.current--)},W=S=>{const{file:x,fileList:w}=S,{status:E}=x;switch(E){case"removed":{C([...w]);break}}},G=S=>{const x=E=>{const O=E.split("/"),A=O[O.length-1],[$]=A.split("?");return $};return{uid:(E=>{const O=v.current.find(A=>A.url===E);return O?O.uid:ct()})(S),name:x(S),url:S,status:"done"}},k=()=>{switch(c){case be.String:return g.map(S=>S.url).join(",");case be["String[]"]:return g.map(S=>S.url);case be["File[]"]:return[...g];case be.FileList:return[...g]}};return p.useEffect(()=>{const S=k();if(Qe(S,u))return;let x=[];switch(c){case be.String:{x=(u||"").split(",").filter(w=>w).map(w=>G(w));break}case be["String[]"]:{x=(u||[]).map(w=>G(w));break}case be["File[]"]:{x=(u||[]).map(w=>w);break}case be.FileList:{x=(u||[]).map(w=>w);break}}C(x)},[u]),p.useEffect(()=>{if(h.current){h.current=!1;return}const S=k();f==null||f(S)},[g]),m.jsx(T.Upload,{listType:s,...j(),fileList:g,beforeUpload:P,onChange:W,children:"上传"})},N=new Map;N.set("Input",T.Input),N.set("ApiSelect",il),N.set("Select",T.Select),N.set("InputNumber",T.InputNumber),N.set("ApiTreeSelect",al),N.set("TreeSelect",T.TreeSelect),N.set("ApiTransfer",ll),N.set("Transfer",T.Transfer),N.set("Switch",T.Switch),N.set("Button",T.Button),N.set("Radio",T.Radio),N.set("RadioGroup",T.Radio.Group),N.set("Checkbox",T.Checkbox),N.set("CheckboxGroup",T.Checkbox.Group),N.set("Cascader",T.Cascader),N.set("TimePicker",T.TimePicker),N.set("DatePicker",T.DatePicker),N.set("MonthPicker",T.DatePicker.MonthPicker),N.set("WeekPicker",T.DatePicker.WeekPicker),N.set("RangePicker",T.DatePicker.RangePicker),N.set("InputPassword",T.Input.Password),N.set("InputTextArea",T.Input.TextArea),N.set("ApiAutoComplete",cl),N.set("AutoComplete",T.AutoComplete),N.set("Upload",T.Upload),N.set("AutoUpload",ul);const Zr={"form-item-force":"_form-item-force_1hsf3_1","form-item-hidden":"_form-item-hidden_1hsf3_9"},fl=p.forwardRef(({itemIndex:e,itemProps:t,methods:r,formProps:n,collapseRef:o},s)=>{console.log("render FormItem",t.name);const{rewritingModel:i,isusewatch:a}=Ja(n,t),{isIfShow:c,isShow:u}=Va(t,i,o),{colProps:f}=Xa(t,n),{componentProps:h}=Ga(t,i),{rules:d}=qa({item:t,model:i,isShow:u,componentProps:h}),{disabled:v}=Ya(n,t,i),{itemCollapse:g,setItemCollapse:y}=Ua(n,e),{name:C,label:j,wrapperCol:P,labelCol:D,valuePropName:z,initialValue:W,forceRow:G}=t;p.useImperativeHandle(s,()=>({itemIndex:e,componentProps:h,itemCollapse:g,setItemCollapse:y}));const k=()=>({name:C,label:j,rules:d,wrapperCol:P,labelCol:D,valuePropName:z,initialValue:W}),{setExtendFormComp:S}=Jr();S(N);const x=Dt(t),w=At(t),E=()=>{if(x){const O=N.get(t.component);return m.jsx(O,{...h,disabled:v,isusewatch:a.toString()})}return w?t.render({model:i,name:C,disabled:v,methods:r,componentProps:h}):null};return m.jsxs(p.Fragment,{children:[G?m.jsx("div",{className:Zr["form-item-force"]}):null,c?m.jsx(T.Col,{...f,className:u&&!g?void 0:Zr["form-item-hidden"],children:m.jsx(T.Form.Item,{...k(),children:E()})}):null]})}),dl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},pl=p.forwardRef(({collapsible:e,onClickExpand:t,onClickFold:r},n)=>{const[o,s]=p.useState(e),i=p.useMemo(()=>o,[o]),a=()=>{r(),s(!0)},c=()=>{t(),s(!1)};return p.useImperativeHandle(n,()=>({handleCollapseChangeFalse:c})),m.jsx("div",{className:dl["collapse-wrapper"],children:i?m.jsx(T.Button,{onClick:c,type:"link",icon:m.jsx(fe.DownOutlined,{}),children:"展开"}):m.jsx(T.Button,{onClick:a,type:"link",icon:m.jsx(fe.UpOutlined,{}),children:"折叠"})})}),gl={"group-wrapper":"_group-wrapper_g8zqi_1"},hl=({formProps:e})=>{const{renderActions:t}=e;return m.jsx("div",{className:gl["group-wrapper"],children:t==null?void 0:t()})},ml={"xph-form-action":"_xph-form-action_8ws73_1"},bl=(e,t)=>{console.log("render Form");const[r]=T.Form.useForm(),{formProps:n}=ol(e),{formItems:o}=Ka({formProps:n}),s=p.useRef(new Map),{collapsible:i,collapseNum:a,collapseRef:c,onClickCollapseToFalse:u,onClickCollapseToTrue:f}=sl(n,s),{handleFormatRenderValues:h,handleFormatReturnValues:d}=rl(o,n,s),{setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:C,scrollToField:j}=nl(r,h,d),P=()=>{const{layout:z,wrapperCol:W,labelCol:G,colon:k,disabled:S,labelWrap:x,labelAlign:w,scrollToFirstError:E,size:O}=n;return{layout:z,wrapperCol:W,labelCol:G,colon:k,disabled:S,labelWrap:x,labelAlign:w,scrollToFirstError:E,size:O}},D={setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:C,scrollToField:j};return p.useImperativeHandle(t,()=>({...D})),p.useEffect(()=>(console.log("Form is mounted======================="),n.register&&n.register(D),()=>{console.log("Form is unmounted========================="),s.current.clear()}),[]),m.jsxs(T.Form,{form:r,...P(),children:[m.jsx(T.Row,{children:o.map((z,W)=>(s.current.has(z.name)||s.current.set(z.name,p.createRef()),m.jsx(fl,{ref:s.current.get(z.name),itemIndex:W,itemProps:z,formProps:n,methods:D,collapseRef:c},W)))}),m.jsxs("div",{className:ml["xph-form-action"],children:[m.jsx(hl,{formProps:n}),i?m.jsx(pl,{ref:c,collapsible:o.length>a,onClickExpand:u,onClickFold:f}):null]})]})},Ot=p.forwardRef(bl),vl=p.memo(Ot),yl=p.forwardRef((e,t)=>{const{renderActions:r,showSearch:n,tableRef:o}=e,[s,i]=p.useState(!1),a=p.useRef(null),c=()=>{const{reloadData:d}=o.current;d()},u=()=>{const{resetData:d}=o.current;d()},f=p.useCallback(()=>m.jsxs("div",{style:{width:"100%",display:"flex"},children:[m.jsx("div",{style:{flex:1,width:0},children:r==null?void 0:r()}),n&&m.jsxs("div",{style:{display:"flex",gap:"8px"},children:[m.jsx(T.Button,{type:"primary",icon:m.jsx(fe.SearchOutlined,{}),onClick:c,children:"搜索"}),m.jsx(T.Button,{icon:m.jsx(fe.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),h=()=>{const{renderActions:d,...v}=e;return{...v,renderActions:f}};return p.useImperativeHandle(t,()=>({setFormLoading:i,...a.current})),m.jsx(T.Spin,{spinning:s,children:m.jsx(vl,{ref:a,...h()})})}),_l=p.memo(Ot),wl=(e,t)=>{const r=p.useRef(null),n=p.useRef(null),{formProps:o}=e,i=(()=>{const{formProps:f,...h}=e;return h})(),a=p.useRef(null),c=async()=>{const{onOk:f,renderFooter:h}=i;if(!h){const{ok:d,data:v}=a.current;if(d){n.current.validator().then(async g=>{r.current.setLoading(!0),await d({values:n.current.getFieldsValue()}).then(C=>C).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}if(f){n.current.validator().then(async g=>{r.current.setLoading(!0),await f({values:g,data:v}).then(C=>(console.log(C),C)).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}r.current.close(),a.current=null}},u=async()=>{const{onCancel:f,renderFooter:h}=i;if(!h){const{cancel:d,data:v}=a.current;if(d){if(await d({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),a.current=null;return}if(f){if(await f({values:n.current.getFieldsValue(!0),data:v})===!1)return;r.current.close(),a.current=null;return}r.current.close(),a.current=null}};return p.useImperativeHandle(t,()=>({open:async f=>{if(r.current.getVisible())return;const{renderFooter:d}=i;return!d&&(a.current=f),r.current.open().then(()=>{n.current.setFieldsValue(f.data||{})})},close:(...f)=>r.current.close(...f),setLoading:(...f)=>r.current.setLoading(...f),getVisible:(...f)=>r.current.getVisible(...f),getFieldsValue:(...f)=>n.current.getFieldsValue(...f),setFieldsValue:(...f)=>n.current.setFieldsValue(...f),resetFields:(...f)=>n.current.resetFields(...f),validator:(...f)=>n.current.validator(...f),scrollToField:(...f)=>n.current.scrollToField(...f)})),m.jsx(Xr,{...i,ref:r,onOk:c,onCancel:u,children:m.jsx(_l,{...o,ref:n})})},Qr=p.forwardRef(wl);function Cl({searchForm:e}){return{searchFormRef:p.useRef(null),searchFormProps:e}}function xl(e){return"cellFunc"in e}function Tl(e){return"children"in e}const{useToken:Sl}=T.theme,Pl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t,{url:s,onClick:i}=n,{token:a}=Sl(),c={color:a.colorLink,cursor:"pointer"},u=()=>{if(r.mainClick&&r.mainClick(),i){i();return}if(s){window.open(s,"_blank");return}};return m.jsx(e,{...r,mainClick:u,mainStyle:Object.assign(c,(r==null?void 0:r.mainStyle)||{})})},El={"cellfunc-actions":"_cellfunc-actions_14drt_1"},Fl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t;return m.jsx("div",{className:El["cellfunc-actions"],children:m.jsx(tt,{...n})})},{useToken:jl}=T.theme,Dl={0:{color:"orange",backgroundColor:"unset",border:"1px solid orange"},1:{color:"purple",backgroundColor:"unset",border:"1px solid purple"},2:{color:"blue",backgroundColor:"unset",border:"1px solid blue"},3:{color:"green",backgroundColor:"unset",border:"1px solid green"},4:{color:"red",backgroundColor:"unset",border:"1px solid red"},5:{color:"pink",backgroundColor:"unset",border:"1px solid pink"},6:{color:"cyan",backgroundColor:"unset",border:"1px solid cyan"},7:{color:"magenta",backgroundColor:"unset",border:"1px solid magenta"},8:{color:"yellow",backgroundColor:"unset",border:"1px solid yellow"},9:{color:"teal",backgroundColor:"unset",border:"1px solid teal"},10:{color:"brown",backgroundColor:"unset",border:"1px solid brown"},11:{color:"gray",backgroundColor:"unset",border:"1px solid gray"},12:{color:"olive",backgroundColor:"unset",border:"1px solid olive"},13:{color:"navy",backgroundColor:"unset",border:"1px solid navy"},14:{color:"lime",backgroundColor:"unset",border:"1px solid lime"},15:{color:"maroon",backgroundColor:"unset",border:"1px solid maroon"}},Al=(e,t,r)=>e.reduce((n,o,s)=>{var u;const i=`${String(t.dataIndex)}${o.value}`,a=(u=o.config)==null?void 0:u.color,c=a?r[a]??{color:a,backgroundColor:"unset",border:`1px solid ${a}`}:Dl[s]||{};return n[i]={color:c.color,backgroundColor:c.backgroundColor,border:c.border},n},{}),en={link:{Comp:Pl},actions:{Comp:Fl},tag:{Comp:(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:{text:o,column:s}}}=t,{token:i}=jl(),{enums:a}=n,c={primary:{color:i.colorPrimary,backgroundColor:i.colorPrimaryBg,border:`1px solid ${i.colorPrimary}`},success:{color:i.colorSuccess,backgroundColor:i.colorSuccessBg,border:`1px solid ${i.colorSuccess}`},warning:{color:i.colorWarning,backgroundColor:i.colorWarningBg,border:`1px solid ${i.colorWarning}`},info:{color:i.colorInfo,backgroundColor:i.colorInfoBg,border:`1px solid ${i.colorInfo}`},error:{color:i.colorError,backgroundColor:i.colorErrorBg,border:`1px solid ${i.colorError}`}},f=Al(a,s,c)[`${String(s.dataIndex)}${o}`]||{},h={padding:"0 8px",borderRadius:i.borderRadiusLG,fontSize:i.fontSizeSM,...f},d=()=>{var g;return(g=a.find(y=>y.value===o))==null?void 0:g.label};return m.jsx(e,{...r,mainHandleText:d,mainStyle:Object.assign((r==null?void 0:r.mainStyle)||{},h)})}}},Ol=(e,t)=>{var o;const{renderPrams:{text:r}}=e,n=(o=t==null?void 0:t.mainHandleText)==null?void 0:o.call(t);return m.jsx("span",{onClick:t==null?void 0:t.mainClick,style:t==null?void 0:t.mainStyle,children:n??r})},$l=e=>{const{setExtendTableCellComp:t}=rn();t(en);const{dslConfig:r}=e;let n=Ol.bind(null,e),o=0;for(;o<r.length;){const s=o++,i=en[r[s].component];i&&(n=i.Comp.bind(null,n,{curComponentProps:r[s].componentProps||{},cellFuncProps:e}))}return m.jsx(n,{})};function tn(e){return e.map(t=>{let r={...t};if(xl(r)){const{cellFunc:n,...o}=r;r={...o,render:(...s)=>{const i=Z(n),[a,c,u]=s,f={text:a,record:c,index:u,column:JSON.parse(JSON.stringify(o))},h=i?n(f):n;return m.jsx($l,{dslConfig:h,renderPrams:f})}}}return Tl(r)&&r.children&&Array.isArray(r.children)&&(r.children=tn(r.children)),r})}function Ml(e){const{columns:t}=e.table;return{columns:tn(t)}}const Rl=e=>{const{extendTableProps:t}=rn();return{tableProps:{...ce(ce({table:{columns:[],fullHeight:!1,autoRequest:!0,pagination:{pageSize:20,total:0,showTotal:o=>`共:${o} 条`,current:1,pageSizeOptions:[10,20,50,100],showSizeChanger:!0,showQuickJumper:!0},requestFields:{pageSize:"pageSize",current:"current"},responseFields:{current:"current",list:"data",total:"total"}},crudFormDialog:void 0,searchForm:{showSearch:!0,items:[]}},t),e)}}};function kl(e){const{pagination:t,autoPagination:r}=e.table,[n,o]=p.useState(t),s=p.useRef(t),i=p.useMemo(()=>n&&(r===!0||r===void 0)||!1,[n]);return{pagination:{model:n,update:c=>{if(!s.current)return;const u={...s.current,...c};o(u),s.current=u},show:i},lastPaginationState:s}}function Il(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:i,responseFields:a}=e.table,c=e.onPaginationChange,{pagination:u,lastPaginationState:f}=kl(e),[h,d]=p.useState({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),v=p.useRef({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),g={model:h,update:x=>{var E;const w={...v.current,...x};d(w),v.current=w,(E=t.current)==null||E.setFormLoading(w.loading)}},y=async()=>{p.useEffect(()=>{const{autoRequest:x}=e.table,{validator:w}=t.current;x&&w().then(E=>{D({searchFormParams:E})})},[])},C=async({searchFormParams:x,paginationParams:w})=>{const E={...x,[`${i.current}`]:f.current.current,[`${i.pageSize}`]:f.current.pageSize,...w?{[`${i.current}`]:w.current,[`${i.pageSize}`]:w.pageSize}:{}};return r(E).then(O=>{const{current:A,list:$,total:B}=ut(a,O);g.update({dataSource:n?n($):$}),u.update({total:B,current:A,pageSize:E[`${i.pageSize}`]})}).finally(()=>{g.update({loading:!1})})},j=async({searchFormParams:x,paginationParams:w})=>{const E={...x};return r(E).then(O=>{const{list:A}=ut(a,O),$=n?n(A):A;g.update({selection:[],dataSource:$}),u.update({current:1,total:A.length})}).finally(()=>{g.update({loading:!1})})},P=async({searchFormParams:x,paginationParams:w})=>{var O;const E={...x};if(w){const{current:A,pageSize:$}=w;u.update({current:A,pageSize:$});const B=(A-1)*$,Q=B+$,ne=(O=v.current.backupsDataSource)==null?void 0:O.slice(B,Q);return g.update({loading:!1,selection:[],dataSource:ne})}else return r(E).then(A=>{let $=n?n(A):A;const B=[...$],Q=0,ne=Q+f.current.pageSize;$=$.slice(Q,ne),g.update({selection:[],dataSource:$,backupsDataSource:B}),u.update({current:1,total:A.length})}).finally(()=>{g.update({loading:!1})})},D=async({searchFormParams:x,paginationParams:w})=>{if(g.update({loading:!0,selection:[]}),r)switch(!!f.current){case!0:return o===!0?P({searchFormParams:x,paginationParams:w}):o===!1?j({searchFormParams:x,paginationParams:w}):C({searchFormParams:x,paginationParams:w});case!1:return j({searchFormParams:x,paginationParams:w})}return g.update({loading:!1})};return{table:g,pagination:u,firstGetTableData:y,onPaginationChange:(x,w)=>{const{validator:E}=t.current;E().then(O=>{D({searchFormParams:O,paginationParams:{current:x,pageSize:w}})}),c&&c(x,w)},onAllChange:async(...x)=>{const[w,E,O,A]=x,$=[];for(let B=0;B<$.length&&!$[B]();B++);s&&s(E,O,A)},resetData:async()=>{const{resetFields:x,validator:w}=t.current;return x().then(async()=>{const E=await w();return D({searchFormParams:E})})},resetAllData:async()=>{const{resetFields:x,validator:w}=t.current;return x().then(async()=>{const E={};if(f.current){const{pageSize:O}=f.current;o===void 0&&(E.paginationParams={current:1,pageSize:O})}return E.searchFormParams=await w(),D(E)})},reloadData:async()=>{const{validator:x}=t.current;return x().then(w=>D({searchFormParams:w}))}}}const zl=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(zr(n))return{type:n,onChange:(s,i,a)=>{t.update({selection:i}),r&&r(s,i)}};if(se(n)){const{onChange:s}=n;return{...n,onChange:(i,a,c)=>{t.update({selection:a}),s&&s(i,a,c),r&&r(i,a)}}}return n};return{rowSelection:o(),getNewRowSelection:o}};function Ll(e,t){const{scroll:r,virtual:n}=e.table,o=p.useRef(null),[s,i]=p.useState(0),[a,c]=p.useState(0),u=()=>{o.current&&(i(o.current.offsetWidth),c(o.current.offsetHeight))};p.useEffect(()=>(u(),window.addEventListener("resize",u),()=>{window.removeEventListener("resize",u)}),[]);const f=p.useMemo(()=>t?n?{x:s,y:a-70,...r}:{x:"max-content",y:a-70,...r}:{x:"max-content",...r},[a]);return{divRef:o,scroll:f}}function Nl(e,t){const{toolbar:r}=e.table;return{getTopToolbarBindProps:()=>{if(Z(r)){const o=r({loading:t.model.loading,selection:t.model.selection});return{...o,disabled:t.model.loading||o.disabled}}return{...r,disabled:t.model.loading||(r==null?void 0:r.disabled)}}}}const rn=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.tableCellFunc;o&&Object.keys(o).forEach(s=>{const i=o[s];n[s]={Comp:i}})};return{extendTableProps:e==null?void 0:e.table,setExtendTableCellComp:r}},Wl=({crudFormDialog:e})=>({crudFormDialogRef:p.useRef(null),crudFormProps:e}),nt={"main-container":"_main-container_1yx5k_1",container__toolbar:"_container__toolbar_1yx5k_13",container__table:"_container__table_1yx5k_27",container__pagination:"_container__pagination_1yx5k_35"},Bl=p.forwardRef(({tableProps:e,searchFormRef:t,fullHeight:r},n)=>{const{columns:o}=Ml(e),s=p.useRef(null),{table:i,pagination:a,firstGetTableData:c,onPaginationChange:u,onAllChange:f,resetData:h,resetAllData:d,reloadData:v}=Il(e,t),{rowSelection:g}=zl(e,i),{divRef:y,scroll:C}=Ll(e,r),{getTopToolbarBindProps:j}=Nl(e,i),P=()=>{const{autoRequest:D,api:z,formatDataSource:W,autoPagination:G,columns:k,scroll:S,pagination:x,rowSelection:w,onChange:E,...O}=e.table;return O};return c(),p.useImperativeHandle(n,()=>({resetData:h,resetAllData:d,reloadData:v,...s.current})),console.log("render Table"),m.jsxs("div",{className:r?nt["main-container"]:void 0,children:[m.jsx("div",{className:nt.container__toolbar,children:m.jsx(tt,{...j()})}),m.jsx("div",{ref:y,className:r?nt.container__table:void 0,children:m.jsx(T.Table,{ref:s,...P(),loading:i.model.loading,columns:o,dataSource:i.model.dataSource,pagination:!1,rowSelection:g,scroll:C,onChange:f})}),a.show?m.jsx("div",{className:nt.container__pagination,children:m.jsx(T.Pagination,{disabled:i.model.loading,...a.model,onChange:u})}):null]})}),nn={"xph-table-full-wrapper":"_xph-table-full-wrapper_mdv0g_1","full-wrapper__table":"_full-wrapper__table_mdv0g_13"},Hl=(e,t)=>{const{tableProps:r}=Rl(e),n=p.useRef(null),{searchFormRef:o,searchFormProps:s}=Cl(r),{crudFormDialogRef:i,crudFormProps:a}=Wl(r);let{fullHeight:c}=r.table;const{virtual:u}=r.table;return u&&(c=!0),p.useImperativeHandle(t,()=>({...n.current,...i.current})),m.jsxs("div",{className:c?nn["xph-table-full-wrapper"]:void 0,children:[m.jsx("div",{children:m.jsx(yl,{ref:o,tableRef:n,...s})}),m.jsx("div",{className:c?nn["full-wrapper__table"]:void 0,children:m.jsx(Bl,{ref:n,searchFormRef:o,fullHeight:c,tableProps:r})}),a?m.jsx(Qr,{ref:i,...a}):null]})},Vl=p.forwardRef(Hl);M.XphActions=tt,M.XphAuth=za,M.XphCrudFormDialog=Qr,M.XphDialog=Xr,M.XphExtendCompPropsProvider=ua,M.XphForm=Ot,M.XphPortal=Kr,M.XphTable=Vl,M.buildUUID=ct,M.getValueByPath=Yt,M.getValuesByPathObj=ut,M.useAsyncState=Vr,M.useXphExtendCompProps=Fe,M.useXphForm=Za,Object.defineProperty(M,Symbol.toStringTag,{value:"Module"})});
|
|
30
|
+
<%s key={someKey} {...props} />`,qt,Ee,ac,Ee),pn[Ee+qt]=!0}}return l===n?rc(J):tc(J),J}}function nc(l,b,_){return gn(l,b,_,!0)}function oc(l,b,_){return gn(l,b,_,!1)}var sc=oc,ic=nc;Re.Fragment=n,Re.jsx=sc,Re.jsxs=ic}()),Re}process.env.NODE_ENV==="production"?ft.exports=mn():ft.exports=bn();var m=ft.exports,Kt=typeof global=="object"&&global&&global.Object===Object&&global,vn=typeof self=="object"&&self&&self.Object===Object&&self,de=Kt||vn||Function("return this")(),_e=de.Symbol,Jt=Object.prototype,yn=Jt.hasOwnProperty,_n=Jt.toString,Me=_e?_e.toStringTag:void 0;function wn(e){var t=yn.call(e,Me),r=e[Me];try{e[Me]=void 0;var n=!0}catch{}var o=_n.call(e);return n&&(t?e[Me]=r:delete e[Me]),o}var Cn=Object.prototype,xn=Cn.toString;function Tn(e){return xn.call(e)}var Sn="[object Null]",Pn="[object Undefined]",Zt=_e?_e.toStringTag:void 0;function pe(e){return e==null?e===void 0?Pn:Sn:Zt&&Zt in Object(e)?wn(e):Tn(e)}function le(e){return e!=null&&typeof e=="object"}var En="[object Symbol]";function dt(e){return typeof e=="symbol"||le(e)&&pe(e)==En}function Fn(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var te=Array.isArray,jn=1/0,Qt=_e?_e.prototype:void 0,er=Qt?Qt.toString:void 0;function tr(e){if(typeof e=="string")return e;if(te(e))return Fn(e,tr)+"";if(dt(e))return er?er.call(e):"";var t=e+"";return t=="0"&&1/e==-jn?"-0":t}function se(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function rr(e){return e}var Dn="[object AsyncFunction]",An="[object Function]",On="[object GeneratorFunction]",$n="[object Proxy]";function Z(e){if(!se(e))return!1;var t=pe(e);return t==An||t==On||t==Dn||t==$n}var pt=de["__core-js_shared__"],nr=function(){var e=/[^.]+$/.exec(pt&&pt.keys&&pt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Rn(e){return!!nr&&nr in e}var Mn=Function.prototype,kn=Mn.toString;function xe(e){if(e!=null){try{return kn.call(e)}catch{}try{return e+""}catch{}}return""}var In=/[\\^$.*+?()[\]{}|]/g,zn=/^\[object .+?Constructor\]$/,Ln=Function.prototype,Nn=Object.prototype,Wn=Ln.toString,Bn=Nn.hasOwnProperty,Hn=RegExp("^"+Wn.call(Bn).replace(In,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Vn(e){if(!se(e)||Rn(e))return!1;var t=Z(e)?Hn:zn;return t.test(xe(e))}function Un(e,t){return e==null?void 0:e[t]}function Te(e,t){var r=Un(e,t);return Vn(r)?r:void 0}var gt=Te(de,"WeakMap"),or=Object.create,qn=function(){function e(){}return function(t){if(!se(t))return{};if(or)return or(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function Yn(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Gn(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Xn=800,Kn=16,Jn=Date.now;function Zn(e){var t=0,r=0;return function(){var n=Jn(),o=Kn-(n-r);if(r=n,o>0){if(++t>=Xn)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Qn(e){return function(){return e}}var Ue=function(){try{var e=Te(Object,"defineProperty");return e({},"",{}),e}catch{}}(),eo=Ue?function(e,t){return Ue(e,"toString",{configurable:!0,enumerable:!1,value:Qn(t),writable:!0})}:rr,to=Zn(eo),ro=9007199254740991,no=/^(?:0|[1-9]\d*)$/;function ht(e,t){var r=typeof e;return t=t??ro,!!t&&(r=="number"||r!="symbol"&&no.test(e))&&e>-1&&e%1==0&&e<t}function mt(e,t,r){t=="__proto__"&&Ue?Ue(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function ke(e,t){return e===t||e!==e&&t!==t}var oo=Object.prototype,so=oo.hasOwnProperty;function sr(e,t,r){var n=e[t];(!(so.call(e,t)&&ke(n,r))||r===void 0&&!(t in e))&&mt(e,t,r)}function io(e,t,r,n){var o=!r;r||(r={});for(var s=-1,i=t.length;++s<i;){var a=t[s],c=void 0;c===void 0&&(c=e[a]),o?mt(r,a,c):sr(r,a,c)}return r}var ir=Math.max;function ao(e,t,r){return t=ir(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,s=ir(n.length-t,0),i=Array(s);++o<s;)i[o]=n[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=n[o];return a[t]=r(i),Yn(e,this,a)}}function lo(e,t){return to(ao(e,t,rr),e+"")}var co=9007199254740991;function ar(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=co}function qe(e){return e!=null&&ar(e.length)&&!Z(e)}function uo(e,t,r){if(!se(r))return!1;var n=typeof t;return(n=="number"?qe(r)&&ht(t,r.length):n=="string"&&t in r)?ke(r[t],e):!1}function fo(e){return lo(function(t,r){var n=-1,o=r.length,s=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(o--,s):void 0,i&&uo(r[0],r[1],i)&&(s=o<3?void 0:s,o=1),t=Object(t);++n<o;){var a=r[n];a&&e(t,a,n,s)}return t})}var po=Object.prototype;function bt(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||po;return e===r}function go(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var ho="[object Arguments]";function lr(e){return le(e)&&pe(e)==ho}var cr=Object.prototype,mo=cr.hasOwnProperty,bo=cr.propertyIsEnumerable,vt=lr(function(){return arguments}())?lr:function(e){return le(e)&&mo.call(e,"callee")&&!bo.call(e,"callee")};function vo(){return!1}var ur=typeof R=="object"&&R&&!R.nodeType&&R,fr=ur&&typeof module=="object"&&module&&!module.nodeType&&module,yo=fr&&fr.exports===ur,dr=yo?de.Buffer:void 0,_o=dr?dr.isBuffer:void 0,Ye=_o||vo,wo="[object Arguments]",Co="[object Array]",xo="[object Boolean]",To="[object Date]",So="[object Error]",Po="[object Function]",Eo="[object Map]",Fo="[object Number]",jo="[object Object]",Do="[object RegExp]",Ao="[object Set]",Oo="[object String]",$o="[object WeakMap]",Ro="[object ArrayBuffer]",Mo="[object DataView]",ko="[object Float32Array]",Io="[object Float64Array]",zo="[object Int8Array]",Lo="[object Int16Array]",No="[object Int32Array]",Wo="[object Uint8Array]",Bo="[object Uint8ClampedArray]",Ho="[object Uint16Array]",Vo="[object Uint32Array]",Y={};Y[ko]=Y[Io]=Y[zo]=Y[Lo]=Y[No]=Y[Wo]=Y[Bo]=Y[Ho]=Y[Vo]=!0,Y[wo]=Y[Co]=Y[Ro]=Y[xo]=Y[Mo]=Y[To]=Y[So]=Y[Po]=Y[Eo]=Y[Fo]=Y[jo]=Y[Do]=Y[Ao]=Y[Oo]=Y[$o]=!1;function Uo(e){return le(e)&&ar(e.length)&&!!Y[pe(e)]}function qo(e){return function(t){return e(t)}}var pr=typeof R=="object"&&R&&!R.nodeType&&R,Ie=pr&&typeof module=="object"&&module&&!module.nodeType&&module,Yo=Ie&&Ie.exports===pr,yt=Yo&&Kt.process,gr=function(){try{var e=Ie&&Ie.require&&Ie.require("util").types;return e||yt&&yt.binding&&yt.binding("util")}catch{}}(),hr=gr&&gr.isTypedArray,_t=hr?qo(hr):Uo,Go=Object.prototype,Xo=Go.hasOwnProperty;function mr(e,t){var r=te(e),n=!r&&vt(e),o=!r&&!n&&Ye(e),s=!r&&!n&&!o&&_t(e),i=r||n||o||s,a=i?go(e.length,String):[],c=a.length;for(var u in e)(t||Xo.call(e,u))&&!(i&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||ht(u,c)))&&a.push(u);return a}function br(e,t){return function(r){return e(t(r))}}var Ko=br(Object.keys,Object),Jo=Object.prototype,Zo=Jo.hasOwnProperty;function Qo(e){if(!bt(e))return Ko(e);var t=[];for(var r in Object(e))Zo.call(e,r)&&r!="constructor"&&t.push(r);return t}function es(e){return qe(e)?mr(e):Qo(e)}function ts(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var rs=Object.prototype,ns=rs.hasOwnProperty;function os(e){if(!se(e))return ts(e);var t=bt(e),r=[];for(var n in e)n=="constructor"&&(t||!ns.call(e,n))||r.push(n);return r}function vr(e){return qe(e)?mr(e,!0):os(e)}var ss=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,is=/^\w*$/;function as(e,t){if(te(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||dt(e)?!0:is.test(e)||!ss.test(e)||t!=null&&e in Object(t)}var ze=Te(Object,"create");function ls(){this.__data__=ze?ze(null):{},this.size=0}function cs(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var us="__lodash_hash_undefined__",fs=Object.prototype,ds=fs.hasOwnProperty;function ps(e){var t=this.__data__;if(ze){var r=t[e];return r===us?void 0:r}return ds.call(t,e)?t[e]:void 0}var gs=Object.prototype,hs=gs.hasOwnProperty;function ms(e){var t=this.__data__;return ze?t[e]!==void 0:hs.call(t,e)}var bs="__lodash_hash_undefined__";function vs(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ze&&t===void 0?bs:t,this}function Se(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Se.prototype.clear=ls,Se.prototype.delete=cs,Se.prototype.get=ps,Se.prototype.has=ms,Se.prototype.set=vs;function ys(){this.__data__=[],this.size=0}function Ge(e,t){for(var r=e.length;r--;)if(ke(e[r][0],t))return r;return-1}var _s=Array.prototype,ws=_s.splice;function Cs(e){var t=this.__data__,r=Ge(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():ws.call(t,r,1),--this.size,!0}function xs(e){var t=this.__data__,r=Ge(t,e);return r<0?void 0:t[r][1]}function Ts(e){return Ge(this.__data__,e)>-1}function Ss(e,t){var r=this.__data__,n=Ge(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function ge(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}ge.prototype.clear=ys,ge.prototype.delete=Cs,ge.prototype.get=xs,ge.prototype.has=Ts,ge.prototype.set=Ss;var Le=Te(de,"Map");function Ps(){this.size=0,this.__data__={hash:new Se,map:new(Le||ge),string:new Se}}function Es(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Xe(e,t){var r=e.__data__;return Es(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Fs(e){var t=Xe(this,e).delete(e);return this.size-=t?1:0,t}function js(e){return Xe(this,e).get(e)}function Ds(e){return Xe(this,e).has(e)}function As(e,t){var r=Xe(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function he(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}he.prototype.clear=Ps,he.prototype.delete=Fs,he.prototype.get=js,he.prototype.has=Ds,he.prototype.set=As;var Os="Expected a function";function wt(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Os);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],s=r.cache;if(s.has(o))return s.get(o);var i=e.apply(this,n);return r.cache=s.set(o,i)||s,i};return r.cache=new(wt.Cache||he),r}wt.Cache=he;var $s=500;function Rs(e){var t=wt(e,function(n){return r.size===$s&&r.clear(),n}),r=t.cache;return t}var Ms=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ks=/\\(\\)?/g,Is=Rs(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Ms,function(r,n,o,s){t.push(o?s.replace(ks,"$1"):n||r)}),t});function zs(e){return e==null?"":tr(e)}function Ls(e,t){return te(e)?e:as(e,t)?[e]:Is(zs(e))}var Ns=1/0;function Ws(e){if(typeof e=="string"||dt(e))return e;var t=e+"";return t=="0"&&1/e==-Ns?"-0":t}function Bs(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var yr=br(Object.getPrototypeOf,Object),Hs="[object Object]",Vs=Function.prototype,Us=Object.prototype,_r=Vs.toString,qs=Us.hasOwnProperty,Ys=_r.call(Object);function Gs(e){if(!le(e)||pe(e)!=Hs)return!1;var t=yr(e);if(t===null)return!0;var r=qs.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&_r.call(r)==Ys}function Xs(){this.__data__=new ge,this.size=0}function Ks(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function Js(e){return this.__data__.get(e)}function Zs(e){return this.__data__.has(e)}var Qs=200;function ei(e,t){var r=this.__data__;if(r instanceof ge){var n=r.__data__;if(!Le||n.length<Qs-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new he(n)}return r.set(e,t),this.size=r.size,this}function me(e){var t=this.__data__=new ge(e);this.size=t.size}me.prototype.clear=Xs,me.prototype.delete=Ks,me.prototype.get=Js,me.prototype.has=Zs,me.prototype.set=ei;var wr=typeof R=="object"&&R&&!R.nodeType&&R,Cr=wr&&typeof module=="object"&&module&&!module.nodeType&&module,ti=Cr&&Cr.exports===wr,xr=ti?de.Buffer:void 0;xr&&xr.allocUnsafe;function ri(e,t){return e.slice()}function ni(e,t){for(var r=-1,n=e==null?0:e.length,o=0,s=[];++r<n;){var i=e[r];t(i,r,e)&&(s[o++]=i)}return s}function oi(){return[]}var si=Object.prototype,ii=si.propertyIsEnumerable,Tr=Object.getOwnPropertySymbols,ai=Tr?function(e){return e==null?[]:(e=Object(e),ni(Tr(e),function(t){return ii.call(e,t)}))}:oi;function li(e,t,r){var n=t(e);return te(e)?n:Bs(n,r(e))}function Sr(e){return li(e,es,ai)}var Ct=Te(de,"DataView"),xt=Te(de,"Promise"),Tt=Te(de,"Set"),Pr="[object Map]",ci="[object Object]",Er="[object Promise]",Fr="[object Set]",jr="[object WeakMap]",Dr="[object DataView]",ui=xe(Ct),fi=xe(Le),di=xe(xt),pi=xe(Tt),gi=xe(gt),we=pe;(Ct&&we(new Ct(new ArrayBuffer(1)))!=Dr||Le&&we(new Le)!=Pr||xt&&we(xt.resolve())!=Er||Tt&&we(new Tt)!=Fr||gt&&we(new gt)!=jr)&&(we=function(e){var t=pe(e),r=t==ci?e.constructor:void 0,n=r?xe(r):"";if(n)switch(n){case ui:return Dr;case fi:return Pr;case di:return Er;case pi:return Fr;case gi:return jr}return t});var Ke=de.Uint8Array;function hi(e){var t=new e.constructor(e.byteLength);return new Ke(t).set(new Ke(e)),t}function mi(e,t){var r=hi(e.buffer);return new e.constructor(r,e.byteOffset,e.length)}function bi(e){return typeof e.constructor=="function"&&!bt(e)?qn(yr(e)):{}}var vi="__lodash_hash_undefined__";function yi(e){return this.__data__.set(e,vi),this}function _i(e){return this.__data__.has(e)}function Je(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new he;++t<r;)this.add(e[t])}Je.prototype.add=Je.prototype.push=yi,Je.prototype.has=_i;function wi(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function Ci(e,t){return e.has(t)}var xi=1,Ti=2;function Ar(e,t,r,n,o,s){var i=r&xi,a=e.length,c=t.length;if(a!=c&&!(i&&c>a))return!1;var u=s.get(e),f=s.get(t);if(u&&f)return u==t&&f==e;var h=-1,d=!0,v=r&Ti?new Je:void 0;for(s.set(e,t),s.set(t,e);++h<a;){var g=e[h],y=t[h];if(n)var C=i?n(y,g,h,t,e,s):n(g,y,h,e,t,s);if(C!==void 0){if(C)continue;d=!1;break}if(v){if(!wi(t,function(j,P){if(!Ci(v,P)&&(g===j||o(g,j,r,n,s)))return v.push(P)})){d=!1;break}}else if(!(g===y||o(g,y,r,n,s))){d=!1;break}}return s.delete(e),s.delete(t),d}function Si(e){var t=-1,r=Array(e.size);return e.forEach(function(n,o){r[++t]=[o,n]}),r}function Pi(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Ei=1,Fi=2,ji="[object Boolean]",Di="[object Date]",Ai="[object Error]",Oi="[object Map]",$i="[object Number]",Ri="[object RegExp]",Mi="[object Set]",ki="[object String]",Ii="[object Symbol]",zi="[object ArrayBuffer]",Li="[object DataView]",Or=_e?_e.prototype:void 0,St=Or?Or.valueOf:void 0;function Ni(e,t,r,n,o,s,i){switch(r){case Li:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case zi:return!(e.byteLength!=t.byteLength||!s(new Ke(e),new Ke(t)));case ji:case Di:case $i:return ke(+e,+t);case Ai:return e.name==t.name&&e.message==t.message;case Ri:case ki:return e==t+"";case Oi:var a=Si;case Mi:var c=n&Ei;if(a||(a=Pi),e.size!=t.size&&!c)return!1;var u=i.get(e);if(u)return u==t;n|=Fi,i.set(e,t);var f=Ar(a(e),a(t),n,o,s,i);return i.delete(e),f;case Ii:if(St)return St.call(e)==St.call(t)}return!1}var Wi=1,Bi=Object.prototype,Hi=Bi.hasOwnProperty;function Vi(e,t,r,n,o,s){var i=r&Wi,a=Sr(e),c=a.length,u=Sr(t),f=u.length;if(c!=f&&!i)return!1;for(var h=c;h--;){var d=a[h];if(!(i?d in t:Hi.call(t,d)))return!1}var v=s.get(e),g=s.get(t);if(v&&g)return v==t&&g==e;var y=!0;s.set(e,t),s.set(t,e);for(var C=i;++h<c;){d=a[h];var j=e[d],P=t[d];if(n)var D=i?n(P,j,d,t,e,s):n(j,P,d,e,t,s);if(!(D===void 0?j===P||o(j,P,r,n,s):D)){y=!1;break}C||(C=d=="constructor")}if(y&&!C){var z=e.constructor,W=t.constructor;z!=W&&"constructor"in e&&"constructor"in t&&!(typeof z=="function"&&z instanceof z&&typeof W=="function"&&W instanceof W)&&(y=!1)}return s.delete(e),s.delete(t),y}var Ui=1,$r="[object Arguments]",Rr="[object Array]",Ze="[object Object]",qi=Object.prototype,Mr=qi.hasOwnProperty;function Yi(e,t,r,n,o,s){var i=te(e),a=te(t),c=i?Rr:we(e),u=a?Rr:we(t);c=c==$r?Ze:c,u=u==$r?Ze:u;var f=c==Ze,h=u==Ze,d=c==u;if(d&&Ye(e)){if(!Ye(t))return!1;i=!0,f=!1}if(d&&!f)return s||(s=new me),i||_t(e)?Ar(e,t,r,n,o,s):Ni(e,t,c,r,n,o,s);if(!(r&Ui)){var v=f&&Mr.call(e,"__wrapped__"),g=h&&Mr.call(t,"__wrapped__");if(v||g){var y=v?e.value():e,C=g?t.value():t;return s||(s=new me),o(y,C,r,n,s)}}return d?(s||(s=new me),Vi(e,t,r,n,o,s)):!1}function kr(e,t,r,n,o){return e===t?!0:e==null||t==null||!le(e)&&!le(t)?e!==e&&t!==t:Yi(e,t,r,n,kr,o)}function Gi(e){return function(t,r,n){for(var o=-1,s=Object(t),i=n(t),a=i.length;a--;){var c=i[++o];if(r(s[c],c,s)===!1)break}return t}}var Xi=Gi();function Pt(e,t,r){(r!==void 0&&!ke(e[t],r)||r===void 0&&!(t in e))&&mt(e,t,r)}function Ki(e){return le(e)&&qe(e)}function Et(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function Ji(e){return io(e,vr(e))}function Zi(e,t,r,n,o,s,i){var a=Et(e,r),c=Et(t,r),u=i.get(c);if(u){Pt(e,r,u);return}var f=s?s(a,c,r+"",e,t,i):void 0,h=f===void 0;if(h){var d=te(c),v=!d&&Ye(c),g=!d&&!v&&_t(c);f=c,d||v||g?te(a)?f=a:Ki(a)?f=Gn(a):v?(h=!1,f=ri(c)):g?(h=!1,f=mi(c)):f=[]:Gs(c)||vt(c)?(f=a,vt(a)?f=Ji(a):(!se(a)||Z(a))&&(f=bi(c))):h=!1}h&&(i.set(c,f),o(f,c,n,s,i),i.delete(c)),Pt(e,r,f)}function Ir(e,t,r,n,o){e!==t&&Xi(t,function(s,i){if(o||(o=new me),se(s))Zi(e,t,i,r,Ir,n,o);else{var a=n?n(Et(e,i),s,i+"",e,t,o):void 0;a===void 0&&(a=s),Pt(e,i,a)}},vr)}var Qi="[object String]";function zr(e){return typeof e=="string"||!te(e)&&le(e)&&pe(e)==Qi}var ea="[object Boolean]";function Ft(e){return e===!0||e===!1||le(e)&&pe(e)==ea}function Qe(e,t){return kr(e,t)}var ta="[object Number]";function ra(e){return typeof e=="number"||le(e)&&pe(e)==ta}function Lr(e){return e==null}function na(e){return e===null}var ce=fo(function(e,t,r){Ir(e,t,r)});function oa(e,t,r,n){if(!se(e))return e;t=Ls(t,e);for(var o=-1,s=t.length,i=s-1,a=e;a!=null&&++o<s;){var c=Ws(t[o]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(o!=i){var f=a[c];u=void 0,u===void 0&&(u=se(f)?f:ht(t[o+1])?[]:{})}sr(a,c,u),a=a[c]}return e}function Nr(e,t,r){return e==null?e:oa(e,t,r)}function sa(e){const{inherit:t=!0}=e,{extendActionsProps:r,extendAuthProps:n}=Ur(),s={...ce(ce({items:[],max:10},t?r:{}),e)},i={...ce({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:i}}function Wr(e){return"component"in e}function ia(e){return"render"in e}function aa(e,t){const{type:r,disabled:n,items:o,max:s}=e,i=h=>{const{auth:d}=h;let v=!1;return d?te(d)?v=d.every(g=>t(g)):v=t(d):v=!0,v},a=h=>{let{ifShow:d=!0}=h;return d=d&&Z(d)?d():d,d&&i(h)},c=h=>{const{component:d,render:v,componentProps:g}=h;if(d)switch(d){case"Dropdown":{const{dropDownItems:y}=g;return!!y.length}default:return!0}return!!v},u=o.map(h=>{const d={...h};if(Wr(d)){const v=d.component;switch(d.componentProps={type:r,disabled:n,...d.componentProps},v){case"Dropdown":{d.componentProps.dropDownItems=(d.componentProps.dropDownItems||[]).filter(a);break}}}return d}).filter(a).filter(c),f=ra(s)&&s>=0;return{showActionItems:u.slice(0,f?s:u.length),ellipsisActionItems:u.slice(f?s:u.length)}}const la=e=>{const{componentProps:t}=e,r=()=>{const{...n}=t;return n};return m.jsx(T.Button,{...r()})},ca=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...i}=t;return i})();return m.jsx(T.Dropdown,{disabled:n.disabled,menu:{items:t==null?void 0:t.dropDownItems,onClick:t==null?void 0:t.onClick},trigger:["click"],children:m.jsx("div",{children:m.jsxs(T.Button,{...n,children:[n.children,m.jsx(fe.CaretDownOutlined,{})]})})})},et=new Map;et.set("Button",la),et.set("Dropdown",ca);function Br(){const{setExtendActionsComp:e}=Ur();return e(et),{renderContent:p.useCallback((r,n)=>{const o=Wr(r),s=ia(r);if(o){const i=et.get(r.component);return p.createElement(i,{...r,key:n})}return s?m.jsx("div",{children:r.render},n):null},[])}}const Hr=p.createContext({}),ua=e=>{const{extendProps:t,extendComp:r}=e.value;return m.jsx(Hr.Provider,{value:{extendProps:t,extendComp:r},children:e.children})},Fe=()=>p.useContext(Hr),Vr=e=>{const[t,r]=p.useState(e),n=p.useRef(null);return p.useEffect(()=>{n.current&&(n.current(),n.current=null)},[t]),[t,s=>new Promise((i,a)=>{r(c=>{const u=typeof s=="function"?s(c):s;return n.current=i,u})})]},Ur=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.actions;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendAuthProps:e==null?void 0:e.auth,extendActionsProps:e==null?void 0:e.actions,setExtendActionsComp:r}},{useToken:fa}=T.theme,da=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Br(),{token:s}=fa(),i={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},a=()=>m.jsx("div",{style:i,children:m.jsx(T.Space,{style:{padding:8},children:e==null?void 0:e.map((c,u)=>o(c,u))})});return m.jsx(T.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:a,trigger:["click"],children:m.jsxs(T.Button,{type:r,children:["更多",m.jsx(fe.CaretDownOutlined,{})]})})},tt=e=>{const{actionsProps:t,authProps:r}=sa(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=aa(t,n),{renderContent:i}=Br();return t!=null&&t.render?t.render:m.jsxs(p.Fragment,{children:[o==null?void 0:o.map((a,c)=>i(a,c)),s!=null&&s.length?m.jsx(da,{actionsProps:t,items:s}):null]})};function pa(e,t){const{okText:r,cancelText:n,onCancel:o,onOk:s,okProps:i,cancelProps:a}=e;return{footerActions:{disabled:t,max:2,items:[{component:"Button",componentProps:{...a,children:n,onClick:o}},{component:"Button",componentProps:{type:"primary",loading:t,...i,children:r,onClick:s}}]}}}const ga=e=>{const{extendDialogProps:t}=ha(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body},n={...ce(ce(r,t),e)};return{dialogProps:{...n,getPopperContainer:()=>{const s=n.getPopperContainer();return n.mask?document.body:s}},baseDialogProps:r}},ha=()=>{const{extendProps:e}=Fe();return{extendDialogProps:e==null?void 0:e.dialog}},ma=(e,t,r,n)=>{const{onOpen:o,onClose:s}=t;return{open:async()=>{e||(o&&o(),await r(!0))},close:()=>{r(!1),n(!1),s&&s()}}},ba=({initWidth:e,initHeight:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,i]=p.useState(t.current);return{dialogWidth:n,dialogHeight:s,setDialogSize:({width:c,height:u})=>{r({width:n,height:s}),c!==void 0&&o(c),u!==void 0&&i(u)}}},va=({initLeft:e,initTop:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,i]=p.useState(t.current);return{dialogLeft:n,dialogTop:s,setDialogPosition:({left:c,top:u})=>{r({left:n,top:s}),c!==void 0&&o(c),u!==void 0&&i(u)}}},qr=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=p.useRef(0),s=p.useRef(0),i=f=>{const h=f.getBoundingClientRect(),d=h.width,v=h.height,g=-.5*d,y=-.5*v;return{translateX:g,translateY:y}},a=p.useCallback(f=>{const{offsetLeft:h,offsetTop:d}=r.current;o.current=f.clientX-h,s.current=f.clientY-d,document.addEventListener("mousemove",c),document.addEventListener("mouseup",u)},[]),c=p.useCallback(f=>{const h=r.current,{translateX:d,translateY:v}=i(h);let g=f.clientX-o.current,y=f.clientY-s.current;const C=-d,j=-v,P=e.current.scrollWidth-h.offsetWidth-d,D=e.current.scrollHeight-h.offsetHeight-v;g<C&&(g=C),g>P&&(g=P),y<j&&(y=j),y>D&&(y=D),n({left:g,top:y})},[]),u=p.useCallback(()=>{document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",u)},[]);return p.useEffect(()=>{const f=t.current;return f.addEventListener("mousedown",a),()=>{f.removeEventListener("mousedown",a)}},[]),{}},ya=({containerSizeTarget:e,dialogChangeRecord:t,close:r,setDialogSize:n,setDialogPosition:o})=>{const[s,i]=p.useState(!1),[a,c]=p.useState(!1);return{minimizeVisible:s,maximizeVisible:a,setMinimizeVisible:i,setMaximizeVisible:c,onMinimize:()=>{i(!0)},onMaximize:v=>{if(v==="minimize"&&i(!1),v==="maximize"){const{scrollWidth:g,scrollHeight:y}=e.current,C=Math.floor(g),j=Math.floor(y),P=Math.floor(g/2),D=Math.floor(y/2);n({width:C,height:j}),o({top:D,left:P}),c(!0)}},onRecovery:()=>{const{top:v,left:g,width:y,height:C}=t.current;n({width:y,height:C}),o({top:v,left:g}),c(!1)},onClose:()=>{i(!1),c(!1),r()}}},_a=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:i,scrollHeight:a}=t.current,[c,u]=p.useState(0),[f,h]=p.useState("unset"),d=(v,g)=>{var W,G;const j=(W=o.current)==null?void 0:W.offsetHeight,P=(G=s.current)==null?void 0:G.offsetHeight;let D=v-j-P-0;const z=g-j-P-0;return D>z&&(D=z),D};return p.useEffect(()=>{var v;if(c===i){console.log("触发了dialogMaxHeight改变");const g=(v=n.current)==null?void 0:v.getBoundingClientRect().height;h(d(g,i)),u("unset")}},[c]),p.useEffect(()=>{r!=="unset"&&r!==0&&(console.log("触发了重新设置contentMaxHeight",r),h(d(r,r>i?a:i)),u("unset"))},[r]),p.useEffect(()=>{e?u(i):(u(0),h("unset"))},[e]),{dialogMaxHeight:c,contentMaxHeight:f}},wa=()=>{const[e,t]=p.useState(160),[r,n]=p.useState(60),o=p.useRef(null);return{minimizeTop:r,minimizeLeft:e,minimizeRef:o,setMinimizePosition:({left:i,top:a})=>{i!==void 0&&t(i),a!==void 0&&n(a)}}},Ca=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=(a,c)=>{console.log("触发插入"),a.querySelector(`.${o.xphDialogWrapper}`).style.opacity="unset",a.querySelector(`.${o.xphMinimizeDialog}`).style.opacity="unset",c.querySelector(`.${o.xphDialogWrapper}`).style.opacity=.7,c.querySelector(`.${o.xphMinimizeDialog}`).style.opacity=.7;const u=document.createElement("div");u.style.visibility="hidden",c.parentNode.insertBefore(u,c.nextSibling),c.parentNode.insertBefore(a,u),c.parentNode.removeChild(u)},i=a=>{var f,h;const c=n.querySelectorAll(`.${o.xphDialog}`),u=c[c.length-1];if(((f=t.current)==null?void 0:f.parentNode)!==u&&(s((h=t.current)==null?void 0:h.parentNode,u),a)){const d=a.target;d.tagName==="INPUT"&&d.focus&&d.focus()}};return p.useEffect(()=>{var a,c;return(a=t.current)==null||a.addEventListener("mousedown",i,!1),(c=r.current)==null||c.addEventListener("mousedown",i,!1),()=>{var u,f;(u=t.current)==null||u.removeEventListener("mousedown",i,!1),(f=r.current)==null||f.removeEventListener("mousedown",i,!1)}},[]),p.useEffect(()=>{if(e)i();else{const a=Array.from(n.querySelectorAll(`.${o.xphDialog}`)),c=a.map(d=>d.querySelector(`.${o.xphDialogWrapper}`)).filter(d=>d!==null),u=a.map(d=>d.querySelector(`.${o.xphMinimizeDialog}`)).filter(d=>d!==null),f=c.filter(d=>d.style.display==="flex"),h=u.filter(d=>d.style.display==="flex");if(f.length){s(f[f.length-1].parentNode,a[a.length-1]);return}if(h.length){s(h[h.length-1].parentNode,a[a.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},xa=({initWidth:e,initHeight:t,initLeft:r,initTop:n,curPropsWidth:o,curPropsHeight:s,setDialogSize:i,setDialogPosition:a})=>{p.useEffect(()=>{o!==e.current&&(console.log("重新设置了宽度"),i({width:o})),s!==t.current&&(console.log("重新设置了高度"),i({height:s}))},[o,s]),p.useEffect(()=>{o!==e.current&&(console.log("重新设置了左边位置"),a({left:r.current})),s!==t.current&&(console.log("重新设置了上边位置"),a({top:n.current}))},[o,s])},Ta=()=>{const e=p.useRef({left:0,top:0,width:0,height:0});return{dialogChangeRecord:e,setDialogChangeRecord:({left:r,top:n,width:o,height:s})=>{const{left:i,top:a,width:c,height:u}=e.current;e.current={left:r??i,top:n??a,width:o??c,height:s??u}}}},Sa=({containerSizeTarget:e,dialogRef:t,minResizeRecord:r,setDialogSize:n,setDialogPosition:o})=>{const s=p.useCallback(()=>m.jsx("div",{ref:i,style:{position:"absolute",border:"4px dashed #ccc",display:"none"}}),[]),i=p.useRef(null),a=p.useRef(),c=p.useRef(!1),[u,f]=p.useState(!1),h=p.useRef(0),d=p.useRef(0),v=(k,S)=>{c.current=!0,f(!0),a.current=S;const{clientX:x,clientY:w}=k;h.current=x,d.current=w;const E=parseFloat(t.current.style.left),O=parseFloat(t.current.style.top),A=t.current.offsetWidth,$=t.current.offsetHeight;i.current.style.display="block",i.current.style.left=`${E-.5*A}px`,i.current.style.top=`${O-.5*$}px`,i.current.style.width=`${A}px`,i.current.style.height=`${$}px`},g=k=>{if(c.current){const{clientX:S,clientY:x}=k,w=S-h.current,E=x-d.current,O=parseFloat(i.current.style.left),A=parseFloat(i.current.style.top),$=i.current.offsetWidth,B=i.current.offsetHeight,Q=r.current.width,ne=r.current.height,ue=e.current.scrollWidth,ie=e.current.scrollHeight;let H=$,V=B,q=O,X=A;switch(a.current){case"lt":{H=H-w,V=V-E,X=X+E,q=q+w,H<Q&&(H=$,q=O),V<ne&&(V=B,X=A),q<0&&(q=0,H=$),X<0&&(X=0,V=B);break}case"rt":{H=H+w,V=V-E,X=X+E,q=O,H<Q&&(H=$),V<ne&&(V=B,X=A),H>ue-q&&(H=ue-q),X<0&&(X=0,V=B);break}case"rb":{H=H+w,V=V+E,X=A,q=O,H<Q&&(H=$),V<ne&&(V=B),H>ue-q&&(H=ue-q),V>ie-X&&(V=ie-X);break}case"lb":{H=H-w,V=V+E,X=A,q=q+w,H<Q&&(H=$,q=O),V<ne&&(V=B),q<0&&(q=0,H=$),V>ie-X&&(V=ie-X);break}}i.current.style.left=`${q}px`,i.current.style.top=`${X}px`,i.current.style.width=`${H}px`,i.current.style.height=`${V}px`,h.current=S,d.current=x}},y=()=>{if(c.current){c.current=!1,f(!1),i.current.style.display="none";const{left:k,top:S,width:x,height:w}=i.current.style,E=parseFloat(k)+.5*parseFloat(x),O=parseFloat(S)+.5*parseFloat(w),A=parseFloat(x),$=parseFloat(w);o({left:E,top:O}),n({width:A,height:$})}},C=k=>v(k,"lt"),j=k=>v(k,"rt"),P=k=>v(k,"rb"),D=k=>v(k,"lb"),z=p.useCallback(k=>{g(k)},[]),W=p.useCallback(()=>{y()},[]),G=p.useCallback(()=>{y()},[]);return p.useEffect(()=>(document.body.addEventListener("mousemove",z),document.body.addEventListener("mouseup",W),document.body.addEventListener("mouseleave",G),()=>{document.body.removeEventListener("mousemove",z),document.body.removeEventListener("mouseup",W),document.body.removeEventListener("mouseleave",G)}),[]),{resizingState:u,DashedBox:s,onMousedownResizeLt:C,onMousedownResizeRt:j,onMousedownResizeRb:P,onMousedownResizeLb:D}},Pa=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=p.useState(0),s=()=>{o(S=>S+1)};p.useEffect(()=>(window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}),[]);const{containerSizeTarget:i,setContainerSizeTarget:a}=Fa({container:e}),{width:c,height:u}=r,{width:f,height:h}=t,d=f||c,v=h||u,{clientWidth:g,clientHeight:y}=i.current,C=d?d>g?g:d:0,j=v?v>y?y:v:"unset",P=p.useRef(C),D=p.useRef(j),z=S=>{P.current=S.width,D.current=S.height},W=p.useRef(Math.floor(g/2)),G=p.useRef(Math.floor(y/2)),k=S=>{W.current=S.left,G.current=S.top};return p.useEffect(()=>{a(),z({width:C,height:j}),k({left:Math.floor(g/2),top:Math.floor(y/2)})},[n]),{containerSizeTarget:i,parentResizeRecord:n,initLeft:W,initTop:G,initWidth:P,initHeight:D,curPropsWidth:C,curPropsHeight:j,setInitPosition:k,setInitSize:z}},Ea=(e,t,r,n)=>{const o=p.useRef(null);return p.useEffect(()=>{if(e){const s=t.current.offsetWidth,i=t.current.offsetHeight;o.current={width:s,height:i}}else o.current=null},[r,n,e]),{minResizeRecord:o}},Fa=({container:e})=>{const t=e===document.body,r=p.useRef({clientWidth:t?window.innerWidth:e.clientWidth,clientHeight:t?window.innerHeight:e.clientHeight,scrollWidth:t?window.innerWidth:e.scrollWidth,scrollHeight:t?window.innerHeight:e.scrollHeight});return{containerSizeTarget:r,setContainerSizeTarget:()=>{r.current={clientWidth:t?window.innerWidth:e.clientWidth,clientHeight:t?window.innerHeight:e.clientHeight,scrollWidth:t?window.innerWidth:e.scrollWidth,scrollHeight:t?window.innerHeight:e.scrollHeight}}}},jt={"minimize-windows":"_minimize-windows_12u3y_1","minimize-windows-title":"_minimize-windows-title_12u3y_43","minimize-windows-operate":"_minimize-windows-operate_12u3y_55"},ja=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.ShrinkOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Yr=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Da=({onClick:e})=>m.jsx(T.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenExitOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Gr=({onClick:e,disabled:t})=>m.jsx(T.Button,{type:"link",onClick:e,disabled:t,icon:m.jsx(fe.CloseOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),{useToken:Aa}=T.theme,Oa=p.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:i,className:a},c)=>{const{token:u}=Aa(),f={borderRadius:u.borderRadiusLG};return m.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...f},className:`${jt["minimize-windows"]} ${a}`,ref:c,children:[m.jsx("div",{className:jt["minimize-windows-title"],title:e,children:e}),m.jsxs("div",{className:jt["minimize-windows-operate"],children:[m.jsx(Yr,{onClick:s}),m.jsx(Gr,{onClick:i,disabled:o})]})]})}),re={"xph-dialog-mask":"_xph-dialog-mask_128q2_1","xph-dialog-wrapper":"_xph-dialog-wrapper_128q2_23",dialog__header:"_dialog__header_128q2_45","dialog__header-btns":"_dialog__header-btns_128q2_63",dialog__main:"_dialog__main_128q2_71",dialog__footer:"_dialog__footer_128q2_85",dialog__resize:"_dialog__resize_128q2_99","dialog__resize-lt":"_dialog__resize-lt_128q2_113","dialog__resize-rt":"_dialog__resize-rt_128q2_125","dialog__resize-rb":"_dialog__resize-rb_128q2_137","dialog__resize-lb":"_dialog__resize-lb_128q2_149"},{useToken:$a}=T.theme,Ra=p.forwardRef((e,t)=>{console.log("render Dialog==============================================");const{token:r}=$a(),n={borderRadius:r.borderRadiusLG},{children:o,baseDialogProps:s,mask:i,title:a,renderFooter:c,renderTitle:u,getPopperContainer:f}=e,h=f(),[d,v]=Vr(!1),[g,y]=p.useState(!1),{open:C,close:j}=ma(d,e,v,y),{footerActions:P}=pa(e,g),D=p.useRef(null),z=p.useRef(null),W=p.useRef(null),G=p.useRef(null),{containerSizeTarget:k,parentResizeRecord:S,initLeft:x,initTop:w,initWidth:E,initHeight:O,curPropsWidth:A,curPropsHeight:$}=Pa({container:h,dialogProps:e,baseDialogProps:s}),{dialogChangeRecord:B,setDialogChangeRecord:Q}=Ta(),{dialogWidth:ne,dialogHeight:ue,setDialogSize:ie}=ba({initWidth:E,initHeight:O,setDialogChangeRecord:Q}),{dialogLeft:H,dialogTop:V,setDialogPosition:q}=va({initTop:w,initLeft:x,setDialogChangeRecord:Q}),{dialogMaxHeight:X,contentMaxHeight:$t}=_a({visible:d,containerSizeTarget:k,dialogHeight:ue,dialogRef:D,dialogHeaderRef:z,dialogFooterRef:G}),{minResizeRecord:Rt}=Ea(d,D,ne,ue),{minimizeLeft:Ne,minimizeTop:We,minimizeRef:ve,setMinimizePosition:je}=wa(),{minimizeVisible:Pe,maximizeVisible:Mt,setMaximizeVisible:ot,onMaximize:st,onMinimize:kt,onRecovery:De,onClose:ye}=ya({containerSizeTarget:k,dialogChangeRecord:B,close:j,setDialogSize:ie,setDialogPosition:q}),it=()=>{console.log("触发了initDialog"),ie({width:E.current,height:O.current}),q({left:x.current,top:w.current}),je({left:160,top:60}),ot(!1)};p.useEffect(()=>{it()},[S]),xa({initWidth:E,initHeight:O,initLeft:x,initTop:w,curPropsWidth:A,curPropsHeight:$,setDialogSize:ie,setDialogPosition:q}),qr({containerSizeTarget:k,dialogHeaderRef:z,dialogRef:D,setDialogPosition:q}),qr({containerSizeTarget:k,dialogHeaderRef:ve,dialogRef:ve,setDialogPosition:je});const{dialogTopShowClassConfig:Ce}=Ca({visible:d,container:h,dialogRef:D,minimizeRef:ve}),{resizingState:zt,DashedBox:Lt,onMousedownResizeLt:Be,onMousedownResizeRt:Nt,onMousedownResizeRb:Wt,onMousedownResizeLb:at}=Sa({containerSizeTarget:k,dialogRef:D,minResizeRecord:Rt,setDialogSize:ie,setDialogPosition:q});return p.useImperativeHandle(t,()=>({open:C,close:ye,setLoading:y,getVisible:()=>d})),m.jsxs("div",{className:Ce.xphDialog,children:[i&&d?m.jsx("div",{className:re["xph-dialog-mask"]}):null,m.jsx(Oa,{visible:Pe,className:`${Ce.xphMinimizeDialog}`,loading:g,ref:ve,left:Ne,top:We,title:a,onMaximize:()=>st("minimize"),onClosesquare:ye}),m.jsxs("div",{ref:D,className:`${re["xph-dialog-wrapper"]} ${Ce.xphDialogWrapper}`,style:{display:d&&!Pe?"flex":"none",left:H,top:V,width:ne,height:ue,maxHeight:X,opacity:zt?.2:"unset",...n},children:[m.jsxs("div",{ref:z,className:re.dialog__header,children:[m.jsx("div",{children:u?u():a}),m.jsxs("div",{className:re["dialog__header-btns"],children:[m.jsx(ja,{onClick:kt}),Mt?m.jsx(Da,{onClick:De}):m.jsx(Yr,{onClick:()=>st("maximize")}),m.jsx(Gr,{onClick:ye,disabled:g})]})]}),m.jsx("div",{ref:W,className:re.dialog__main,style:{maxHeight:$t},children:m.jsx(T.Spin,{spinning:g,children:d?o:null})}),c?m.jsx("div",{ref:G,children:c({loading:g})}):m.jsx("div",{ref:G,className:re.dialog__footer,children:m.jsx(tt,{...P})}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lt"]}`,onMouseDown:Be}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rt"]}`,onMouseDown:Nt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rb"]}`,onMouseDown:Wt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lb"]}`,onMouseDown:at})]}),m.jsx(Lt,{})]})}),Ma=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=ga(n),{getPopperContainer:i}=s;return console.log("render XphDialog=============================================="),m.jsx(Kr,{getPopperContainer:i,children:m.jsx(Ra,{...s,baseDialogProps:o,ref:t,children:r})})},Xr=p.forwardRef(Ma),Kr=({children:e,getPopperContainer:t})=>{const[r,n]=p.useState(null);return p.useEffect(()=>{const o=t();n(o)},[]),r?hn.createPortal(e,r):null};function ka(e){const{extendAuthProps:t}=Ia();return{authProps:{...ce(ce({auth:o=>!1},t),e)}}}const Ia=()=>{const{extendProps:e}=Fe();return{extendAuthProps:e==null?void 0:e.auth}},za=e=>{const{children:t,...r}=e,{authProps:n}=ka(r),{auth:o,authCode:s}=n;return(()=>{let a=!1;return s&&o&&(te(s)?a=s.every(c=>o(c)):a=o(s)),a})()?t:null};function Dt(e){return"component"in e}function At(e){return"render"in e}function La(e){return e.includes("Input")||e.includes("Complete")?"请输入":e.includes("Picker")||e.includes("Select")||e.includes("Cascader")||e.includes("Checkbox")||e.includes("Radio")||e.includes("Switch")?"请选择":""}function Na(e,t,r){["DatePicker","MonthPicker","WeekPicker","TimePicker"].includes(t)?e.type=r?"string":"object":["RangePicker","Upload","CheckboxGroup","TimePicker"].includes(t)?e.type="array":["InputNumber"].includes(t)&&(e.type="number")}const Wa=["DatePicker","MonthPicker","RangePicker","WeekPicker","TimePicker"],Ba=e=>{const{show:t,ifShow:r,required:n,disabled:o,componentProps:s}=e;return!!(Z(t)||Z(r)||Z(n)||Z(o)||Z(s)||At(e))},Ha=e=>["application/json","application/javascript","text/plain","text/html","text/css"].includes(e)?`${e}; charset=utf-8`:e,Va=(e,t,r)=>{const n=p.useRef(null),o=p.useRef(null),{handleCollapseChangeFalse:s}=r.current||{},{show:i,ifShow:a}=e;let c=!0,u=!0;if(Ft(i)&&(c=i),Ft(a)&&(u=a),Z(i)){c=i({model:t});const f=Lr(n.current)?c:n.current;p.useEffect(()=>{Qe(c,f)||s&&s()},[t])}if(Z(a)){u=a({model:t});const f=Lr(o.current)?u:o.current;p.useEffect(()=>{Qe(u,f)||s&&s()},[t])}return n.current=c,o.current=u,{isShow:c,isIfShow:u}},Ua=(e,t)=>{const{collapsible:r,collapseNum:n}=e,[o,s]=p.useState(!!(r&&t>=n));return{itemCollapse:o,setItemCollapse:s}},qa=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:i}=e;let a=o;const c=Dt(e),u=c?La(e.component)+s:"";function f(g,y){const C=g.message||u;return y===void 0||na(y)||Array.isArray(y)&&y.length===0||typeof y=="string"&&y.trim()===""||typeof y=="object"&&Reflect.has(y,"checked")&&Reflect.has(y,"halfChecked")&&Array.isArray(y.checked)&&Array.isArray(y.halfChecked)&&y.checked.length===0&&y.halfChecked.length===0?Promise.reject(C):Promise.resolve()}const h=Z(i)?i({model:t}):i;h&&(!a||a.length===0?a=[{required:h,validator:f}]:a.findIndex(y=>Reflect.has(y,"required"))===-1&&a.push({required:h,validator:f}));const d=a.findIndex(g=>Reflect.has(g,"required")&&!Reflect.has(g,"validator"));if(d!==-1){const g=a[d];if(r||(g.required=!1),c){const{component:y}=e;Reflect.has(g,"type")||(g.type=y==="InputNumber"?"number":"string"),g.message=g.message||u,(y.includes("Input")||y.includes("Textarea"))&&(g.whitespace=!0);const C=n.valueFormat;Na(g,y,C)}}const v=a.findIndex(g=>g.max);return v!==-1&&!a[v].validator&&(a[v].message=a[v].message||`字符数应小于${a[v].max}位`),{rules:a}},Ya=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Z(s)&&(o=s({model:r})),Ft(s)&&(o=s),{disabled:Reflect.has(t,"disabled")?o:n}},Ga=(e,t)=>{const r={},{componentProps:n={}}=e;return Z(n)&&Object.assign(r,n({model:t})),Object.assign(r,n),{componentProps:r}},Xa=(e,t)=>{const{colProps:r={}}=e,{colProps:n={span:24}}=t;return{colProps:{...n,...r}}},Ka=({formProps:e})=>{const{items:t}=e;return{formItems:t.map(n=>({...n}))}},Ja=(e,t)=>{const r=a=>(Object.keys(a).forEach(c=>{Object.defineProperty(a,c,{value:a[c],writable:!1,enumerable:!0,configurable:!1})}),a),n={};e.items.forEach(a=>{n[a.name]=a.initialValue});const o=Ba(t),s=o?T.Form.useWatch(a=>r(a)):null;return{rewritingModel:p.useMemo(()=>s||r(n),[s]),isusewatch:o}},Za=()=>{const e=p.useRef(null);function t(n){e.current=n}const r={getFieldsValue:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.getFieldsValue(...n)},setFieldsValue:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.setFieldsValue(...n)},resetFields:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.resetFields(...n)},validator:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.validator(...n)},scrollToField:(...n)=>{if(!e.current)throw new Error("表单还没初始化完成");return e.current.scrollToField(...n)}};return p.useEffect(()=>(console.log("ParentComponent is mounted====================================="),()=>{console.log("ParentComponent is unmounted===================================="),e.current=null}),[]),[t,r]};function Qa(e,t={}){const r=/^\[(.+)\]$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s=[];return o.forEach((i,a)=>{Nr(s,a,t[i.trim()])}),s.filter(Boolean).length?s:void 0}}}function el(e,t={}){const r=/^\{(.+)\}$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s={};return o.forEach(i=>{Nr(s,i.trim(),t[i.trim()])}),Object.values(s).filter(Boolean).length?s:void 0}}}function tl(e,t){const r=t.fieldMapToTime;if(!r||!Array.isArray(r))return e;for(const[n,[o,s],i="YYYY-MM-DD"]of r){if(!n||!o||!s)continue;if(!e[n]){Reflect.deleteProperty(e,n);continue}const[a,c]=e[n],[u,f]=Array.isArray(i)?i:[i,i];e[o]=Ve(a).format(u),e[s]=Ve(c).format(f),Reflect.deleteProperty(e,n)}return e}const rl=(e,t,r)=>{const n=e.filter(i=>i.name);return{handleFormatRenderValues:i=>{const a={},c=[];return n.forEach(u=>{const f=Reflect.has(i,u.name),h=Qa(u.name,i)||el(u.name,i);if(f||h){const d=h||i[u.name];if(Dt(u))if(Wa.includes(u.component)){if(te(d)){const v=[];for(const g of d)v.push(g?Ve(g):null);a[u.name]=v}else a[u.name]=d?Ve(d):null;c.push(u.name)}else a[u.name]=d,c.push(u.name);At(u)&&(a[u.name]=d,c.push(u.name))}}),{renderValues:a,validKeys:c}},handleFormatReturnValues:i=>{var c,u,f,h,d;if(!se(i))return{};const a={};for(const v of Object.entries(i)){let[,g]=v;const[y]=v;if(!y||Z(g))continue;const{transformDateFunc:C}=t,j=(f=(u=(c=r.current)==null?void 0:c.get(y))==null?void 0:u.current)==null?void 0:f.componentProps,P=j==null?void 0:j.valueFormat;if(se(g)){const D=g;D.format&&(g=C==null?void 0:C(D,P))}te(g)&&((h=g[0])!=null&&h.format)&&((d=g[1])!=null&&d.format)&&(g=g.map(D=>C==null?void 0:C(D,P))),zr(g)&&(g===""?g=void 0:g=g.trim()),a[y]=g}return tl(a,t)}}},nl=(e,t,r)=>({getFieldsValue:(...c)=>r(e.getFieldsValue(...c)),setFieldsValue:c=>{const{renderValues:u,validKeys:f}=t(c);e.setFieldsValue(u),e.validateFields(f)},resetFields:async()=>e.resetFields(),validator:async c=>e.validateFields(c).then(u=>r(u)),scrollToField:async(c,u)=>e.scrollToField(c,u)}),ol=e=>{const{extendFormProps:t}=Jr();return{formProps:{...ce(ce({collapseNum:5,colon:!1,items:[],labelWrap:!0,transformDateFunc:(o,s)=>{var i;return((i=o==null?void 0:o.format)==null?void 0:i.call(o,s||"YYYY-MM-DD HH:mm:ss"))??o},fieldMapToTime:[]},t),e)}}},rt=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,i=p.useRef(!0),a=p.useRef(r),c=()=>{n&&Z(n)&&(r?n(r).then(o):n().then(o),a.current=r)};return p.useEffect(()=>{i.current&&(t&&c(),i.current=!1),!i.current&&s&&(Qe(r,a.current)||t&&c())},[r]),{getApiData:c}},sl=(e,t)=>{const{collapsible:r,collapseNum:n}=e,o=p.useRef();return{collapsible:r,collapseNum:n,collapseRef:o,onClickCollapseToTrue:()=>{var a;(a=t.current)==null||a.forEach(c=>{if(c.current){const{itemIndex:u}=c.current;u>=n&&r&&c.current.setItemCollapse(!0)}})},onClickCollapseToFalse:()=>{var a;(a=t.current)==null||a.forEach(c=>{if(c.current){const{itemCollapse:u}=c.current;u&&c.current.setItemCollapse(!1)}})}}},Jr=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.form;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendFormProps:e==null?void 0:e.form,setExtendFormComp:r}},il=e=>{console.log("render ApiSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.Select,{...h(),options:a,onDropdownVisibleChange:f})},al=e=>{console.log("render ApiTreeSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.TreeSelect,{...h(),treeData:a,onDropdownVisibleChange:f})},ll=e=>{console.log("render ApiTransfer");const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,i]=p.useState([]);rt({api:t,params:r,apiCallback:i,isUseWatch:o});const a=()=>{const{api:c,params:u,isusewatch:f,...h}=e;return h};return m.jsx(T.Transfer,{...a(),dataSource:s})},cl=e=>{console.log("render ApiAutoComplete");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,c]=p.useState([]),{getApiData:u}=rt({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...C}=e;return C};return m.jsx(T.AutoComplete,{...h(),options:a,onDropdownVisibleChange:f})},be={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},ul=e=>{console.log("render AutoUpload"),console.log(ct());const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:i=!1,data:a,returnType:c=be.String,value:u=t,onChange:f}=e,h=p.useRef(!0),d=p.useRef(0),v=p.useRef([]),[g,y]=p.useState([]),C=S=>{v.current=S,y([...S])},j=()=>{const{api:S,maxCount:x,maxSize:w,openCrop:E,beforeUpload:O,fileList:A,returnType:$,...B}=e;return B},P=S=>{const x=S.size/1024/1024<o;x||T.message.error(`文件大小超过:${o}M, 请重试`);const w=v.current.length+d.current<n;return w||T.message.error(`文件数量不能超过${n}个`),x&&w&&d.current++,x&&w&&D(S),T.Upload.LIST_IGNORE},D=S=>{i?(T.message.error("暂时不支持裁剪功能,后续兼容。。。。"),z({file:S})):z({file:S})},z=S=>{r?r({file:S.file,...a}).then(x=>{C([...v.current,...x])}).finally(()=>{d.current--}):(Object.assign(S.file,{status:"done",url:URL.createObjectURL(new Blob([S.file],{type:Ha(S.file.type)}))}),C([...v.current,S.file]),d.current--)},W=S=>{const{file:x,fileList:w}=S,{status:E}=x;switch(E){case"removed":{C([...w]);break}}},G=S=>{const x=E=>{const O=E.split("/"),A=O[O.length-1],[$]=A.split("?");return $};return{uid:(E=>{const O=v.current.find(A=>A.url===E);return O?O.uid:ct()})(S),name:x(S),url:S,status:"done"}},k=()=>{switch(c){case be.String:return g.map(S=>S.url).join(",");case be["String[]"]:return g.map(S=>S.url);case be["File[]"]:return[...g];case be.FileList:return[...g]}};return p.useEffect(()=>{const S=k();if(Qe(S,u))return;let x=[];switch(c){case be.String:{x=(u||"").split(",").filter(w=>w).map(w=>G(w));break}case be["String[]"]:{x=(u||[]).map(w=>G(w));break}case be["File[]"]:{x=(u||[]).map(w=>w);break}case be.FileList:{x=(u||[]).map(w=>w);break}}C(x)},[u]),p.useEffect(()=>{if(h.current){h.current=!1;return}const S=k();f==null||f(S)},[g]),m.jsx(T.Upload,{listType:s,...j(),fileList:g,beforeUpload:P,onChange:W,children:"上传"})},N=new Map;N.set("Input",T.Input),N.set("ApiSelect",il),N.set("Select",T.Select),N.set("InputNumber",T.InputNumber),N.set("ApiTreeSelect",al),N.set("TreeSelect",T.TreeSelect),N.set("ApiTransfer",ll),N.set("Transfer",T.Transfer),N.set("Switch",T.Switch),N.set("Button",T.Button),N.set("Radio",T.Radio),N.set("RadioGroup",T.Radio.Group),N.set("Checkbox",T.Checkbox),N.set("CheckboxGroup",T.Checkbox.Group),N.set("Cascader",T.Cascader),N.set("TimePicker",T.TimePicker),N.set("DatePicker",T.DatePicker),N.set("MonthPicker",T.DatePicker.MonthPicker),N.set("WeekPicker",T.DatePicker.WeekPicker),N.set("RangePicker",T.DatePicker.RangePicker),N.set("InputPassword",T.Input.Password),N.set("InputTextArea",T.Input.TextArea),N.set("ApiAutoComplete",cl),N.set("AutoComplete",T.AutoComplete),N.set("Upload",T.Upload),N.set("AutoUpload",ul);const Zr={"form-item-force":"_form-item-force_1hsf3_1","form-item-hidden":"_form-item-hidden_1hsf3_9"},fl=p.forwardRef(({itemIndex:e,itemProps:t,methods:r,formProps:n,collapseRef:o},s)=>{console.log("render FormItem",t.name);const{rewritingModel:i,isusewatch:a}=Ja(n,t),{isIfShow:c,isShow:u}=Va(t,i,o),{colProps:f}=Xa(t,n),{componentProps:h}=Ga(t,i),{rules:d}=qa({item:t,model:i,isShow:u,componentProps:h}),{disabled:v}=Ya(n,t,i),{itemCollapse:g,setItemCollapse:y}=Ua(n,e),{name:C,label:j,wrapperCol:P,labelCol:D,valuePropName:z,initialValue:W,forceRow:G}=t;p.useImperativeHandle(s,()=>({itemIndex:e,componentProps:h,itemCollapse:g,setItemCollapse:y}));const k=()=>({name:C,label:j,rules:d,wrapperCol:P,labelCol:D,valuePropName:z,initialValue:W}),{setExtendFormComp:S}=Jr();S(N);const x=Dt(t),w=At(t),E=()=>{if(x){const O=N.get(t.component);return m.jsx(O,{...h,disabled:v,isusewatch:a.toString()})}return w?t.render({model:i,name:C,disabled:v,methods:r,componentProps:h}):null};return m.jsxs(p.Fragment,{children:[G?m.jsx("div",{className:Zr["form-item-force"]}):null,c?m.jsx(T.Col,{...f,className:u&&!g?void 0:Zr["form-item-hidden"],children:m.jsx(T.Form.Item,{...k(),children:E()})}):null]})}),dl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},pl=p.forwardRef(({collapsible:e,onClickExpand:t,onClickFold:r},n)=>{const[o,s]=p.useState(e),i=p.useMemo(()=>o,[o]),a=()=>{r(),s(!0)},c=()=>{t(),s(!1)};return p.useImperativeHandle(n,()=>({handleCollapseChangeFalse:c})),m.jsx("div",{className:dl["collapse-wrapper"],children:i?m.jsx(T.Button,{onClick:c,type:"link",icon:m.jsx(fe.DownOutlined,{}),children:"展开"}):m.jsx(T.Button,{onClick:a,type:"link",icon:m.jsx(fe.UpOutlined,{}),children:"折叠"})})}),gl={"group-wrapper":"_group-wrapper_g8zqi_1"},hl=({formProps:e})=>{const{renderActions:t}=e;return m.jsx("div",{className:gl["group-wrapper"],children:t==null?void 0:t()})},ml={"xph-form-action":"_xph-form-action_8ws73_1"},bl=(e,t)=>{console.log("render Form");const[r]=T.Form.useForm(),{formProps:n}=ol(e),{formItems:o}=Ka({formProps:n}),s=p.useRef(new Map),{collapsible:i,collapseNum:a,collapseRef:c,onClickCollapseToFalse:u,onClickCollapseToTrue:f}=sl(n,s),{handleFormatRenderValues:h,handleFormatReturnValues:d}=rl(o,n,s),{setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:C,scrollToField:j}=nl(r,h,d),P=()=>{const{layout:z,wrapperCol:W,labelCol:G,colon:k,disabled:S,labelWrap:x,labelAlign:w,scrollToFirstError:E,size:O}=n;return{layout:z,wrapperCol:W,labelCol:G,colon:k,disabled:S,labelWrap:x,labelAlign:w,scrollToFirstError:E,size:O}},D={setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:C,scrollToField:j};return p.useImperativeHandle(t,()=>({...D})),p.useEffect(()=>(console.log("Form is mounted======================="),n.register&&n.register(D),()=>{console.log("Form is unmounted========================="),s.current.clear()}),[]),m.jsxs(T.Form,{form:r,...P(),children:[m.jsx(T.Row,{children:o.map((z,W)=>(s.current.has(z.name)||s.current.set(z.name,p.createRef()),m.jsx(fl,{ref:s.current.get(z.name),itemIndex:W,itemProps:z,formProps:n,methods:D,collapseRef:c},W)))}),m.jsxs("div",{className:ml["xph-form-action"],children:[m.jsx(hl,{formProps:n}),i?m.jsx(pl,{ref:c,collapsible:o.length>a,onClickExpand:u,onClickFold:f}):null]})]})},Ot=p.forwardRef(bl),vl=p.memo(Ot),yl=p.forwardRef((e,t)=>{const{renderActions:r,showSearch:n,tableRef:o}=e,[s,i]=p.useState(!1),a=p.useRef(null),c=()=>{const{reloadData:d}=o.current;d()},u=()=>{const{resetData:d}=o.current;d()},f=p.useCallback(()=>m.jsxs("div",{style:{width:"100%",display:"flex"},children:[m.jsx("div",{style:{flex:1,width:0},children:r==null?void 0:r()}),n&&m.jsxs("div",{style:{display:"flex",gap:"8px"},children:[m.jsx(T.Button,{type:"primary",icon:m.jsx(fe.SearchOutlined,{}),onClick:c,children:"搜索"}),m.jsx(T.Button,{icon:m.jsx(fe.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),h=()=>{const{renderActions:d,...v}=e;return{...v,renderActions:f}};return p.useImperativeHandle(t,()=>({setFormLoading:i,...a.current})),m.jsx(T.Spin,{spinning:s,children:m.jsx(vl,{ref:a,...h()})})}),_l=p.memo(Ot),wl=(e,t)=>{const r=p.useRef(null),n=p.useRef(null),{formProps:o}=e,i=(()=>{const{formProps:f,...h}=e;return h})(),a=p.useRef(null),c=async()=>{const{onOk:f,renderFooter:h}=i;if(!h){const{ok:d,data:v}=a.current;if(d){n.current.validator().then(async g=>{r.current.setLoading(!0),await d({values:n.current.getFieldsValue()}).then(C=>C).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}if(f){n.current.validator().then(async g=>{r.current.setLoading(!0),await f({values:g,data:v}).then(C=>(console.log(C),C)).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}r.current.close(),a.current=null}},u=async()=>{const{onCancel:f,renderFooter:h}=i;if(!h){const{cancel:d,data:v}=a.current;if(d){if(await d({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),a.current=null;return}if(f){if(await f({values:n.current.getFieldsValue(!0),data:v})===!1)return;r.current.close(),a.current=null;return}r.current.close(),a.current=null}};return p.useImperativeHandle(t,()=>({open:async f=>{if(r.current.getVisible())return;const{renderFooter:d}=i;return!d&&(a.current=f),r.current.open().then(()=>{n.current.setFieldsValue(f.data||{})})},close:(...f)=>r.current.close(...f),setLoading:(...f)=>r.current.setLoading(...f),getVisible:(...f)=>r.current.getVisible(...f),getFieldsValue:(...f)=>n.current.getFieldsValue(...f),setFieldsValue:(...f)=>n.current.setFieldsValue(...f),resetFields:(...f)=>n.current.resetFields(...f),validator:(...f)=>n.current.validator(...f),scrollToField:(...f)=>n.current.scrollToField(...f)})),m.jsx(Xr,{...i,ref:r,onOk:c,onCancel:u,children:m.jsx(_l,{...o,ref:n})})},Qr=p.forwardRef(wl);function Cl({searchForm:e}){return{searchFormRef:p.useRef(null),searchFormProps:e}}function xl(e){return"cellFunc"in e}function Tl(e){return"children"in e}const{useToken:Sl}=T.theme,Pl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t,{url:s,onClick:i}=n,{token:a}=Sl(),c={color:a.colorLink,cursor:"pointer"},u=()=>{if(r.mainClick&&r.mainClick(),i){i();return}if(s){window.open(s,"_blank");return}};return m.jsx(e,{...r,mainClick:u,mainStyle:Object.assign(c,(r==null?void 0:r.mainStyle)||{})})},El={"cellfunc-actions":"_cellfunc-actions_14drt_1"},Fl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t;return m.jsx("div",{className:El["cellfunc-actions"],children:m.jsx(tt,{...n})})},{useToken:jl}=T.theme,Dl={0:{color:"orange",backgroundColor:"unset",border:"1px solid orange"},1:{color:"purple",backgroundColor:"unset",border:"1px solid purple"},2:{color:"blue",backgroundColor:"unset",border:"1px solid blue"},3:{color:"green",backgroundColor:"unset",border:"1px solid green"},4:{color:"red",backgroundColor:"unset",border:"1px solid red"},5:{color:"pink",backgroundColor:"unset",border:"1px solid pink"},6:{color:"cyan",backgroundColor:"unset",border:"1px solid cyan"},7:{color:"magenta",backgroundColor:"unset",border:"1px solid magenta"},8:{color:"yellow",backgroundColor:"unset",border:"1px solid yellow"},9:{color:"teal",backgroundColor:"unset",border:"1px solid teal"},10:{color:"brown",backgroundColor:"unset",border:"1px solid brown"},11:{color:"gray",backgroundColor:"unset",border:"1px solid gray"},12:{color:"olive",backgroundColor:"unset",border:"1px solid olive"},13:{color:"navy",backgroundColor:"unset",border:"1px solid navy"},14:{color:"lime",backgroundColor:"unset",border:"1px solid lime"},15:{color:"maroon",backgroundColor:"unset",border:"1px solid maroon"}},Al=(e,t,r)=>e.reduce((n,o,s)=>{var u;const i=`${String(t.dataIndex)}${o.value}`,a=(u=o.config)==null?void 0:u.color,c=a?r[a]??{color:a,backgroundColor:"unset",border:`1px solid ${a}`}:Dl[s]||{};return n[i]={color:c.color,backgroundColor:c.backgroundColor,border:c.border},n},{}),en={link:{Comp:Pl},actions:{Comp:Fl},tag:{Comp:(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:{text:o,column:s}}}=t,{token:i}=jl(),{enums:a}=n,c={primary:{color:i.colorPrimary,backgroundColor:i.colorPrimaryBg,border:`1px solid ${i.colorPrimary}`},success:{color:i.colorSuccess,backgroundColor:i.colorSuccessBg,border:`1px solid ${i.colorSuccess}`},warning:{color:i.colorWarning,backgroundColor:i.colorWarningBg,border:`1px solid ${i.colorWarning}`},info:{color:i.colorInfo,backgroundColor:i.colorInfoBg,border:`1px solid ${i.colorInfo}`},error:{color:i.colorError,backgroundColor:i.colorErrorBg,border:`1px solid ${i.colorError}`}},f=Al(a,s,c)[`${String(s.dataIndex)}${o}`]||{},h={padding:"0 8px",borderRadius:i.borderRadiusLG,fontSize:i.fontSizeSM,...f},d=()=>{var g;return(g=a.find(y=>y.value===o))==null?void 0:g.label};return m.jsx(e,{...r,mainHandleText:d,mainStyle:Object.assign((r==null?void 0:r.mainStyle)||{},h)})}}},Ol=(e,t)=>{var o;const{renderPrams:{text:r}}=e,n=(o=t==null?void 0:t.mainHandleText)==null?void 0:o.call(t);return m.jsx("span",{onClick:t==null?void 0:t.mainClick,style:t==null?void 0:t.mainStyle,children:n??r})},$l=e=>{const{setExtendTableCellComp:t}=rn();t(en);const{dslConfig:r}=e;let n=Ol.bind(null,e),o=0;for(;o<r.length;){const s=o++,i=en[r[s].component];i&&(n=i.Comp.bind(null,n,{curComponentProps:r[s].componentProps||{},cellFuncProps:e}))}return m.jsx(n,{})};function tn(e){return e.map(t=>{let r={...t};if(xl(r)){const{cellFunc:n,...o}=r;r={...o,render:(...s)=>{const i=Z(n),[a,c,u]=s,f={text:a,record:c,index:u,column:JSON.parse(JSON.stringify(o))},h=i?n(f):n;return m.jsx($l,{dslConfig:h,renderPrams:f})}}}return Tl(r)&&r.children&&Array.isArray(r.children)&&(r.children=tn(r.children)),r})}function Rl(e){const{columns:t}=e.table;return{columns:tn(t)}}const Ml=e=>{const{extendTableProps:t}=rn();return{tableProps:{...ce(ce({table:{columns:[],fullHeight:!1,autoRequest:!0,pagination:{pageSize:20,total:0,showTotal:o=>`共:${o} 条`,current:1,pageSizeOptions:[10,20,50,100],showSizeChanger:!0,showQuickJumper:!0},requestFields:{pageSize:"pageSize",current:"current"},responseFields:{current:"current",list:"data",total:"total"}},crudFormDialog:void 0,searchForm:{showSearch:!0,items:[]}},t),e)}}};function kl(e){const{pagination:t,autoPagination:r}=e.table,[n,o]=p.useState(t),s=p.useRef(t),i=p.useMemo(()=>n&&(r===!0||r===void 0)||!1,[n]);return{pagination:{model:n,update:c=>{if(!s.current)return;const u={...s.current,...c};o(u),s.current=u},show:i},lastPaginationState:s}}function Il(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:i,responseFields:a}=e.table,c=e.onPaginationChange,{pagination:u,lastPaginationState:f}=kl(e),[h,d]=p.useState({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),v=p.useRef({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),g={model:h,update:x=>{var E;const w={...v.current,...x};d(w),v.current=w,(E=t.current)==null||E.setFormLoading(w.loading)}},y=async()=>{p.useEffect(()=>{const{autoRequest:x}=e.table,{validator:w}=t.current;x&&w().then(E=>{D({searchFormParams:E})})},[])},C=async({searchFormParams:x,paginationParams:w})=>{const E={...x,[`${i.current}`]:f.current.current,[`${i.pageSize}`]:f.current.pageSize,...w?{[`${i.current}`]:w.current,[`${i.pageSize}`]:w.pageSize}:{}};return r(E).then(O=>{const{current:A,list:$,total:B}=ut(a,O);g.update({dataSource:n?n($):$}),u.update({total:B,current:A,pageSize:E[`${i.pageSize}`]})}).finally(()=>{g.update({loading:!1})})},j=async({searchFormParams:x,paginationParams:w})=>{const E={...x};return r(E).then(O=>{const{list:A}=ut(a,O),$=n?n(A):A;g.update({selection:[],dataSource:$}),u.update({current:1,total:A.length})}).finally(()=>{g.update({loading:!1})})},P=async({searchFormParams:x,paginationParams:w})=>{var O;const E={...x};if(w){const{current:A,pageSize:$}=w;u.update({current:A,pageSize:$});const B=(A-1)*$,Q=B+$,ne=(O=v.current.backupsDataSource)==null?void 0:O.slice(B,Q);return g.update({loading:!1,selection:[],dataSource:ne})}else return r(E).then(A=>{let $=n?n(A):A;const B=[...$],Q=0,ne=Q+f.current.pageSize;$=$.slice(Q,ne),g.update({selection:[],dataSource:$,backupsDataSource:B}),u.update({current:1,total:A.length})}).finally(()=>{g.update({loading:!1})})},D=async({searchFormParams:x,paginationParams:w})=>{if(g.update({loading:!0,selection:[]}),r)switch(!!f.current){case!0:return o===!0?P({searchFormParams:x,paginationParams:w}):o===!1?j({searchFormParams:x,paginationParams:w}):C({searchFormParams:x,paginationParams:w});case!1:return j({searchFormParams:x,paginationParams:w})}return g.update({loading:!1})};return{table:g,pagination:u,firstGetTableData:y,onPaginationChange:(x,w)=>{const{validator:E}=t.current;E().then(O=>{D({searchFormParams:O,paginationParams:{current:x,pageSize:w}})}),c&&c(x,w)},onAllChange:async(...x)=>{const[w,E,O,A]=x,$=[];for(let B=0;B<$.length&&!$[B]();B++);s&&s(E,O,A)},resetData:async()=>{const{resetFields:x,validator:w}=t.current;return x().then(async()=>{const E=await w();return D({searchFormParams:E})})},resetAllData:async()=>{const{resetFields:x,validator:w}=t.current;return x().then(async()=>{const E={};if(f.current){const{pageSize:O}=f.current;o===void 0&&(E.paginationParams={current:1,pageSize:O})}return E.searchFormParams=await w(),D(E)})},reloadData:async()=>{const{validator:x}=t.current;return x().then(w=>D({searchFormParams:w}))}}}const zl=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(zr(n))return{type:n,onChange:(s,i,a)=>{t.update({selection:i}),r&&r(s,i)}};if(se(n)){const{onChange:s}=n;return{...n,onChange:(i,a,c)=>{t.update({selection:a}),s&&s(i,a,c),r&&r(i,a)}}}return n};return{rowSelection:o(),getNewRowSelection:o}};function Ll(e,t){const{scroll:r,virtual:n}=e.table,o=p.useRef(null),[s,i]=p.useState(0),[a,c]=p.useState(0),u=()=>{o.current&&(i(o.current.offsetWidth),c(o.current.offsetHeight))};p.useEffect(()=>(u(),window.addEventListener("resize",u),()=>{window.removeEventListener("resize",u)}),[]);const f=p.useMemo(()=>t?n?{x:s,y:a-70,...r}:{x:"max-content",y:a-70,...r}:{x:"max-content",...r},[a]);return{divRef:o,scroll:f}}function Nl(e,t){const{toolbar:r}=e.table;return{getTopToolbarBindProps:()=>{if(Z(r)){const o=r({loading:t.model.loading,selection:t.model.selection});return{...o,disabled:t.model.loading||o.disabled}}return{...r,disabled:t.model.loading||(r==null?void 0:r.disabled)}}}}const rn=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.tableCellFunc;o&&Object.keys(o).forEach(s=>{const i=o[s];n[s]={Comp:i}})};return{extendTableProps:e==null?void 0:e.table,setExtendTableCellComp:r}},Wl=({crudFormDialog:e})=>({crudFormDialogRef:p.useRef(null),crudFormProps:e}),nt={"main-container":"_main-container_1yx5k_1",container__toolbar:"_container__toolbar_1yx5k_13",container__table:"_container__table_1yx5k_27",container__pagination:"_container__pagination_1yx5k_35"},Bl=p.forwardRef(({tableProps:e,searchFormRef:t,fullHeight:r},n)=>{const{columns:o}=Rl(e),s=p.useRef(null),{table:i,pagination:a,firstGetTableData:c,onPaginationChange:u,onAllChange:f,resetData:h,resetAllData:d,reloadData:v}=Il(e,t),{rowSelection:g}=zl(e,i),{divRef:y,scroll:C}=Ll(e,r),{getTopToolbarBindProps:j}=Nl(e,i),P=()=>{const{autoRequest:D,api:z,formatDataSource:W,autoPagination:G,columns:k,scroll:S,pagination:x,rowSelection:w,onChange:E,...O}=e.table;return O};return c(),p.useImperativeHandle(n,()=>({resetData:h,resetAllData:d,reloadData:v,...s.current})),console.log("render Table"),m.jsxs("div",{className:r?nt["main-container"]:void 0,children:[m.jsx("div",{className:nt.container__toolbar,children:m.jsx(tt,{...j()})}),m.jsx("div",{ref:y,className:r?nt.container__table:void 0,children:m.jsx(T.Table,{ref:s,...P(),loading:i.model.loading,columns:o,dataSource:i.model.dataSource,pagination:!1,rowSelection:g,scroll:C,onChange:f})}),a.show?m.jsx("div",{className:nt.container__pagination,children:m.jsx(T.Pagination,{disabled:i.model.loading,...a.model,onChange:u})}):null]})}),nn={"xph-table-full-wrapper":"_xph-table-full-wrapper_mdv0g_1","full-wrapper__table":"_full-wrapper__table_mdv0g_13"},Hl=(e,t)=>{const{tableProps:r}=Ml(e),n=p.useRef(null),{searchFormRef:o,searchFormProps:s}=Cl(r),{crudFormDialogRef:i,crudFormProps:a}=Wl(r);let{fullHeight:c}=r.table;const{virtual:u}=r.table;return u&&(c=!0),p.useImperativeHandle(t,()=>({...n.current,...i.current})),m.jsxs("div",{className:c?nn["xph-table-full-wrapper"]:void 0,children:[m.jsx("div",{children:m.jsx(yl,{ref:o,tableRef:n,...s})}),m.jsx("div",{className:c?nn["full-wrapper__table"]:void 0,children:m.jsx(Bl,{ref:n,searchFormRef:o,fullHeight:c,tableProps:r})}),a?m.jsx(Qr,{ref:i,...a}):null]})},Vl=p.forwardRef(Hl);R.XphActions=tt,R.XphAuth=za,R.XphCrudFormDialog=Qr,R.XphDialog=Xr,R.XphExtendCompPropsProvider=ua,R.XphForm=Ot,R.XphPortal=Kr,R.XphTable=Vl,R.buildUUID=ct,R.getValueByPath=Yt,R.getValuesByPathObj=ut,R.useAsyncState=Vr,R.useXphExtendCompProps=Fe,R.useXphForm=Za,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"})});
|
|
@@ -4,6 +4,6 @@ import { TXphExtendComponentPropsMap } from '../../../types';
|
|
|
4
4
|
export default function useActionsProps<T extends TXphExtendComponentPropsMap>(props: IActionsProps<T>): {
|
|
5
5
|
actionsProps: IActionsProps<{}>;
|
|
6
6
|
authProps: {
|
|
7
|
-
auth: () => true;
|
|
7
|
+
auth: (() => true) & ((key: string) => boolean);
|
|
8
8
|
};
|
|
9
9
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
declare const useExtendActions: () => {
|
|
2
|
-
extendAuthProps: Omit<import('../..').IXphAuthProps, "
|
|
2
|
+
extendAuthProps: Omit<import('../..').IXphAuthProps, "children" | "authCode"> | undefined;
|
|
3
3
|
extendActionsProps: import('../types').IActionsProps<{}> | undefined;
|
|
4
4
|
setExtendActionsComp: (componentMap: Map<any, React.FC<any>>) => void;
|
|
5
5
|
};
|