xph-crud 0.2.9 → 0.3.0

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 CHANGED
@@ -89,10 +89,10 @@ function _o() {
89
89
  H.unshift("Warning: " + m), Function.prototype.apply.call(console[c], console, H);
90
90
  }
91
91
  }
92
- var k = !1, I = !1, U = !1, Y = !1, w = !1, C;
92
+ var k = !1, I = !1, U = !1, Y = !1, x = !1, C;
93
93
  C = Symbol.for("react.module.reference");
94
- function x(c) {
95
- return !!(typeof c == "string" || typeof c == "function" || c === n || c === s || w || c === o || c === u || c === d || Y || c === b || k || I || U || typeof c == "object" && c !== null && (c.$$typeof === f || c.$$typeof === g || c.$$typeof === a || c.$$typeof === i || c.$$typeof === l || // This needs to include all possible module reference object
94
+ function w(c) {
95
+ return !!(typeof c == "string" || typeof c == "function" || c === n || c === s || x || c === o || c === u || c === d || Y || c === b || k || I || U || typeof c == "object" && c !== null && (c.$$typeof === f || c.$$typeof === g || c.$$typeof === a || c.$$typeof === i || c.$$typeof === l || // This needs to include all possible module reference object
96
96
  // types supported by any Flight configuration anywhere since
97
97
  // we don't know which Flight build this will end up being used
98
98
  // with.
@@ -308,7 +308,7 @@ function _o() {
308
308
  function _t(c, m, y) {
309
309
  return Ne(c, !1);
310
310
  }
311
- function xt(c) {
311
+ function wt(c) {
312
312
  var m = c.prototype;
313
313
  return !!(m && m.isReactComponent);
314
314
  }
@@ -316,7 +316,7 @@ function _o() {
316
316
  if (c == null)
317
317
  return "";
318
318
  if (typeof c == "function")
319
- return Ne(c, xt(c));
319
+ return Ne(c, wt(c));
320
320
  if (typeof c == "string")
321
321
  return $e(c);
322
322
  switch (c) {
@@ -372,7 +372,7 @@ function _o() {
372
372
  function Be(c) {
373
373
  return He(c);
374
374
  }
375
- function wt(c) {
375
+ function xt(c) {
376
376
  {
377
377
  var m = typeof Symbol == "function" && Symbol.toStringTag, y = m && c[Symbol.toStringTag] || c.constructor.name || "Object";
378
378
  return y;
@@ -390,7 +390,7 @@ function _o() {
390
390
  }
391
391
  function rt(c) {
392
392
  if (Ct(c))
393
- return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", wt(c)), tt(c);
393
+ return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", xt(c)), tt(c);
394
394
  }
395
395
  var je = R.ReactCurrentOwner, Dn = {
396
396
  key: !0,
@@ -603,7 +603,7 @@ Check the top-level render call using <` + y + ">.");
603
603
  var lr = {};
604
604
  function ur(c, m, y, P, z, H) {
605
605
  {
606
- var $ = x(c);
606
+ var $ = w(c);
607
607
  if (!$) {
608
608
  var O = "";
609
609
  (c === void 0 || typeof c == "object" && c !== null && Object.keys(c).length === 0) && (O += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
@@ -656,9 +656,9 @@ React keys must be passed directly to JSX without using spread:
656
656
  }()), Ue;
657
657
  }
658
658
  process.env.NODE_ENV === "production" ? kt.exports = yo() : kt.exports = _o();
659
- var h = kt.exports, tn = typeof global == "object" && global && global.Object === Object && global, xo = typeof self == "object" && self && self.Object === Object && self, pe = tn || xo || Function("return this")(), Ce = pe.Symbol, rn = Object.prototype, wo = rn.hasOwnProperty, Co = rn.toString, Ye = Ce ? Ce.toStringTag : void 0;
659
+ var h = kt.exports, tn = typeof global == "object" && global && global.Object === Object && global, wo = typeof self == "object" && self && self.Object === Object && self, pe = tn || wo || Function("return this")(), Ce = pe.Symbol, rn = Object.prototype, xo = rn.hasOwnProperty, Co = rn.toString, Ye = Ce ? Ce.toStringTag : void 0;
660
660
  function To(e) {
661
- var t = wo.call(e, Ye), r = e[Ye];
661
+ var t = xo.call(e, Ye), r = e[Ye];
662
662
  try {
663
663
  e[Ye] = void 0;
664
664
  var n = !0;
@@ -890,18 +890,18 @@ function ms(e, t) {
890
890
  return n;
891
891
  }
892
892
  var bs = "[object Arguments]";
893
- function xr(e) {
893
+ function wr(e) {
894
894
  return ue(e) && ge(e) == bs;
895
895
  }
896
- var cn = Object.prototype, vs = cn.hasOwnProperty, ys = cn.propertyIsEnumerable, It = xr(/* @__PURE__ */ function() {
896
+ var cn = Object.prototype, vs = cn.hasOwnProperty, ys = cn.propertyIsEnumerable, It = wr(/* @__PURE__ */ function() {
897
897
  return arguments;
898
- }()) ? xr : function(e) {
898
+ }()) ? wr : function(e) {
899
899
  return ue(e) && vs.call(e, "callee") && !ys.call(e, "callee");
900
900
  };
901
901
  function _s() {
902
902
  return !1;
903
903
  }
904
- var ln = typeof exports == "object" && exports && !exports.nodeType && exports, wr = ln && typeof module == "object" && module && !module.nodeType && module, xs = wr && wr.exports === ln, Cr = xs ? pe.Buffer : void 0, ws = Cr ? Cr.isBuffer : void 0, ct = ws || _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]", Ws = "[object Int8Array]", Ns = "[object Int16Array]", Hs = "[object Int32Array]", Bs = "[object Uint8Array]", Vs = "[object Uint8ClampedArray]", Us = "[object Uint16Array]", Ys = "[object Uint32Array]", V = {};
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, ct = 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]", Ws = "[object Int8Array]", Ns = "[object Int16Array]", Hs = "[object Int32Array]", Bs = "[object Uint8Array]", Vs = "[object Uint8ClampedArray]", Us = "[object Uint16Array]", Ys = "[object Uint32Array]", V = {};
905
905
  V[Is] = V[Ls] = V[Ws] = V[Ns] = V[Hs] = V[Bs] = V[Vs] = V[Us] = V[Ys] = !0;
906
906
  V[Cs] = V[Ts] = V[ks] = V[Ss] = V[zs] = V[Ps] = V[Rs] = V[js] = V[Fs] = V[Es] = V[As] = V[Ds] = V[Os] = V[$s] = V[Ms] = !1;
907
907
  function Gs(e) {
@@ -1011,7 +1011,7 @@ Ee.prototype.delete = di;
1011
1011
  Ee.prototype.get = hi;
1012
1012
  Ee.prototype.has = vi;
1013
1013
  Ee.prototype.set = _i;
1014
- function xi() {
1014
+ function wi() {
1015
1015
  this.__data__ = [], this.size = 0;
1016
1016
  }
1017
1017
  function mt(e, t) {
@@ -1020,7 +1020,7 @@ function mt(e, t) {
1020
1020
  return r;
1021
1021
  return -1;
1022
1022
  }
1023
- var wi = Array.prototype, Ci = wi.splice;
1023
+ var xi = Array.prototype, Ci = xi.splice;
1024
1024
  function Ti(e) {
1025
1025
  var t = this.__data__, r = mt(t, e);
1026
1026
  if (r < 0)
@@ -1046,7 +1046,7 @@ function _e(e) {
1046
1046
  this.set(n[0], n[1]);
1047
1047
  }
1048
1048
  }
1049
- _e.prototype.clear = xi;
1049
+ _e.prototype.clear = wi;
1050
1050
  _e.prototype.delete = Ti;
1051
1051
  _e.prototype.get = Si;
1052
1052
  _e.prototype.has = Pi;
@@ -1081,18 +1081,18 @@ function Oi(e, t) {
1081
1081
  var r = bt(this, e), n = r.size;
1082
1082
  return r.set(e, t), this.size += r.size == n ? 0 : 1, this;
1083
1083
  }
1084
- function xe(e) {
1084
+ function we(e) {
1085
1085
  var t = -1, r = e == null ? 0 : e.length;
1086
1086
  for (this.clear(); ++t < r; ) {
1087
1087
  var n = e[t];
1088
1088
  this.set(n[0], n[1]);
1089
1089
  }
1090
1090
  }
1091
- xe.prototype.clear = ji;
1092
- xe.prototype.delete = Ei;
1093
- xe.prototype.get = Ai;
1094
- xe.prototype.has = Di;
1095
- xe.prototype.set = Oi;
1091
+ we.prototype.clear = ji;
1092
+ we.prototype.delete = Ei;
1093
+ we.prototype.get = Ai;
1094
+ we.prototype.has = Di;
1095
+ we.prototype.set = Oi;
1096
1096
  var $i = "Expected a function";
1097
1097
  function Jt(e, t) {
1098
1098
  if (typeof e != "function" || t != null && typeof t != "function")
@@ -1104,9 +1104,9 @@ function Jt(e, t) {
1104
1104
  var a = e.apply(this, n);
1105
1105
  return r.cache = s.set(o, a) || s, a;
1106
1106
  };
1107
- return r.cache = new (Jt.Cache || xe)(), r;
1107
+ return r.cache = new (Jt.Cache || we)(), r;
1108
1108
  }
1109
- Jt.Cache = xe;
1109
+ Jt.Cache = we;
1110
1110
  var Mi = 500;
1111
1111
  function ki(e) {
1112
1112
  var t = Jt(e, function(n) {
@@ -1168,7 +1168,7 @@ function ra(e, t) {
1168
1168
  var n = r.__data__;
1169
1169
  if (!qe || n.length < ta - 1)
1170
1170
  return n.push([e, t]), this.size = ++r.size, this;
1171
- r = this.__data__ = new xe(n);
1171
+ r = this.__data__ = new we(n);
1172
1172
  }
1173
1173
  return r.set(e, t), this.size = r.size, this;
1174
1174
  }
@@ -1208,8 +1208,8 @@ function ua(e, t, r) {
1208
1208
  function Fr(e) {
1209
1209
  return ua(e, ri, la);
1210
1210
  }
1211
- var Lt = De(pe, "DataView"), Wt = De(pe, "Promise"), Nt = De(pe, "Set"), Er = "[object Map]", da = "[object Object]", Ar = "[object Promise]", Dr = "[object Set]", Or = "[object WeakMap]", $r = "[object DataView]", fa = Ae(Lt), pa = Ae(qe), ga = Ae(Wt), ha = Ae(Nt), ma = Ae(zt), we = ge;
1212
- (Lt && we(new Lt(new ArrayBuffer(1))) != $r || qe && we(new qe()) != Er || Wt && we(Wt.resolve()) != Ar || Nt && we(new Nt()) != Dr || zt && we(new zt()) != Or) && (we = function(e) {
1211
+ var Lt = De(pe, "DataView"), Wt = De(pe, "Promise"), Nt = De(pe, "Set"), Er = "[object Map]", da = "[object Object]", Ar = "[object Promise]", Dr = "[object Set]", Or = "[object WeakMap]", $r = "[object DataView]", fa = Ae(Lt), pa = Ae(qe), ga = Ae(Wt), ha = Ae(Nt), ma = Ae(zt), xe = ge;
1212
+ (Lt && xe(new Lt(new ArrayBuffer(1))) != $r || qe && xe(new qe()) != Er || Wt && xe(Wt.resolve()) != Ar || Nt && xe(new Nt()) != Dr || zt && xe(new zt()) != Or) && (xe = function(e) {
1213
1213
  var t = ge(e), r = t == da ? e.constructor : void 0, n = r ? Ae(r) : "";
1214
1214
  if (n)
1215
1215
  switch (n) {
@@ -1239,19 +1239,19 @@ function ya(e) {
1239
1239
  return typeof e.constructor == "function" && !qt(e) ? qo(gn(e)) : {};
1240
1240
  }
1241
1241
  var _a = "__lodash_hash_undefined__";
1242
- function xa(e) {
1242
+ function wa(e) {
1243
1243
  return this.__data__.set(e, _a), this;
1244
1244
  }
1245
- function wa(e) {
1245
+ function xa(e) {
1246
1246
  return this.__data__.has(e);
1247
1247
  }
1248
1248
  function ut(e) {
1249
1249
  var t = -1, r = e == null ? 0 : e.length;
1250
- for (this.__data__ = new xe(); ++t < r; )
1250
+ for (this.__data__ = new we(); ++t < r; )
1251
1251
  this.add(e[t]);
1252
1252
  }
1253
- ut.prototype.add = ut.prototype.push = xa;
1254
- ut.prototype.has = wa;
1253
+ ut.prototype.add = ut.prototype.push = wa;
1254
+ ut.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))
@@ -1377,7 +1377,7 @@ function Ya(e, t, r, n, o, s) {
1377
1377
  }
1378
1378
  var Ga = 1, kr = "[object Arguments]", zr = "[object Array]", nt = "[object Object]", Xa = Object.prototype, Ir = Xa.hasOwnProperty;
1379
1379
  function qa(e, t, r, n, o, s) {
1380
- var a = oe(e), i = oe(t), l = a ? zr : we(e), u = i ? zr : we(t);
1380
+ var a = oe(e), i = oe(t), l = a ? zr : xe(e), u = i ? zr : xe(t);
1381
1381
  l = l == kr ? nt : l, u = u == kr ? nt : u;
1382
1382
  var d = l == nt, g = u == nt, f = l == u;
1383
1383
  if (f && ct(e)) {
@@ -1486,7 +1486,7 @@ function ic(e, t, r, n) {
1486
1486
  }
1487
1487
  return e;
1488
1488
  }
1489
- function xn(e, t, r) {
1489
+ function wn(e, t, r) {
1490
1490
  return e == null ? e : ic(e, t, r);
1491
1491
  }
1492
1492
  function ac(e) {
@@ -1509,7 +1509,7 @@ function ac(e) {
1509
1509
  authProps: a
1510
1510
  };
1511
1511
  }
1512
- function wn(e) {
1512
+ function xn(e) {
1513
1513
  return "component" in e;
1514
1514
  }
1515
1515
  function cc(e) {
@@ -1537,7 +1537,7 @@ function lc(e, t) {
1537
1537
  return !!b;
1538
1538
  }, u = o.map((g) => {
1539
1539
  const f = { ...g };
1540
- if (wn(f)) {
1540
+ if (xn(f)) {
1541
1541
  const b = f.component;
1542
1542
  switch (f.componentProps = {
1543
1543
  type: r,
@@ -1599,7 +1599,7 @@ function Cn() {
1599
1599
  return e(ft), {
1600
1600
  renderContent: ve(
1601
1601
  (r, n) => {
1602
- const o = wn(r), s = cc(r);
1602
+ const o = xn(r), s = cc(r);
1603
1603
  if (o) {
1604
1604
  const a = ft.get(r.component);
1605
1605
  return /* @__PURE__ */ Kn(a, { ...r, key: n });
@@ -1803,7 +1803,7 @@ const mc = (e) => {
1803
1803
  d.removeEventListener("mousedown", i);
1804
1804
  };
1805
1805
  }, []), {};
1806
- }, xc = ({
1806
+ }, wc = ({
1807
1807
  containerSizeTarget: e,
1808
1808
  dialogChangeRecord: t,
1809
1809
  close: r,
@@ -1833,7 +1833,7 @@ const mc = (e) => {
1833
1833
  a(!1), l(!1), r();
1834
1834
  }
1835
1835
  };
1836
- }, wc = ({
1836
+ }, xc = ({
1837
1837
  visible: e,
1838
1838
  containerSizeTarget: t,
1839
1839
  dialogHeight: r,
@@ -2031,18 +2031,18 @@ const mc = (e) => {
2031
2031
  display: "none"
2032
2032
  }
2033
2033
  }
2034
- ), []), i = A(null), l = A(), u = A(!1), [d, g] = X(!1), f = A(0), b = A(0), p = (w, C) => {
2034
+ ), []), i = A(null), l = A(), u = A(!1), [d, g] = X(!1), f = A(0), b = A(0), p = (x, C) => {
2035
2035
  r.current || s({
2036
2036
  width: t.current.offsetWidth,
2037
2037
  height: t.current.offsetHeight
2038
2038
  }), u.current = !0, g(!0), l.current = C;
2039
- const { clientX: x, clientY: T } = w;
2040
- f.current = x, b.current = T;
2039
+ const { clientX: w, clientY: T } = x;
2040
+ f.current = w, b.current = T;
2041
2041
  const F = parseFloat(t.current.style.left), E = parseFloat(t.current.style.top), D = t.current.offsetWidth, M = t.current.offsetHeight;
2042
2042
  i.current.style.display = "block", i.current.style.left = `${F - 0.5 * D}px`, i.current.style.top = `${E - 0.5 * M}px`, i.current.style.width = `${D}px`, i.current.style.height = `${M}px`;
2043
- }, v = (w) => {
2043
+ }, v = (x) => {
2044
2044
  if (u.current) {
2045
- const { clientX: C, clientY: x } = w, T = C - f.current, F = x - b.current, E = parseFloat(i.current.style.left), D = parseFloat(i.current.style.top), M = i.current.offsetWidth, Q = i.current.offsetHeight, te = r.current.width, he = r.current.height, de = e.current.scrollWidth, ce = e.current.scrollHeight;
2045
+ const { clientX: C, clientY: w } = x, T = C - f.current, F = w - b.current, E = parseFloat(i.current.style.left), D = parseFloat(i.current.style.top), M = i.current.offsetWidth, Q = i.current.offsetHeight, te = r.current.width, he = r.current.height, de = e.current.scrollWidth, ce = e.current.scrollHeight;
2046
2046
  let L = M, W = Q, B = E, q = D;
2047
2047
  switch (l.current) {
2048
2048
  case "lt": {
@@ -2062,16 +2062,16 @@ const mc = (e) => {
2062
2062
  break;
2063
2063
  }
2064
2064
  }
2065
- i.current.style.left = `${B}px`, i.current.style.top = `${q}px`, i.current.style.width = `${L}px`, i.current.style.height = `${W}px`, f.current = C, b.current = x;
2065
+ i.current.style.left = `${B}px`, i.current.style.top = `${q}px`, i.current.style.width = `${L}px`, i.current.style.height = `${W}px`, f.current = C, b.current = w;
2066
2066
  }
2067
2067
  }, _ = () => {
2068
2068
  if (u.current) {
2069
2069
  u.current = !1, g(!1), i.current.style.display = "none";
2070
- const { left: w, top: C, width: x, height: T } = i.current.style, F = parseFloat(w) + 0.5 * parseFloat(x), E = parseFloat(C) + 0.5 * parseFloat(T), D = parseFloat(x), M = parseFloat(T);
2070
+ const { left: x, top: C, width: w, height: T } = i.current.style, F = parseFloat(x) + 0.5 * parseFloat(w), E = parseFloat(C) + 0.5 * parseFloat(T), D = parseFloat(w), M = parseFloat(T);
2071
2071
  o({ left: F, top: E }), n({ width: D, height: M });
2072
2072
  }
2073
- }, R = (w) => p(w, "lt"), S = (w) => p(w, "rt"), j = (w) => p(w, "rb"), k = (w) => p(w, "lb"), I = ve((w) => {
2074
- v(w);
2073
+ }, R = (x) => p(x, "lt"), S = (x) => p(x, "rt"), j = (x) => p(x, "rb"), k = (x) => p(x, "lb"), I = ve((x) => {
2074
+ v(x);
2075
2075
  }, []), U = ve(() => {
2076
2076
  _();
2077
2077
  }, []), Y = ve(() => {
@@ -2093,17 +2093,17 @@ const mc = (e) => {
2093
2093
  baseDialogProps: r
2094
2094
  }) => {
2095
2095
  const [n, o] = X(0), s = () => {
2096
- o((w) => w + 1);
2096
+ o((x) => x + 1);
2097
2097
  };
2098
2098
  G(() => (window.addEventListener("resize", s), () => {
2099
2099
  window.removeEventListener("resize", s);
2100
2100
  }), []);
2101
2101
  const { containerSizeTarget: a, setContainerSizeTarget: i } = Ec({
2102
2102
  container: e
2103
- }), { width: l, height: u } = r, { width: d, height: g } = t, f = d || l, b = g || u, { clientWidth: p, clientHeight: v } = a.current, _ = f ? f > p ? p : f : 0, R = b ? b > v ? v : b : "unset", S = A(_), j = A(R), k = (w) => {
2104
- S.current = w.width, j.current = w.height;
2105
- }, I = A(Math.floor(p / 2)), U = A(Math.floor(v / 2)), Y = (w) => {
2106
- I.current = w.left, U.current = w.top;
2103
+ }), { width: l, height: u } = r, { width: d, height: g } = t, f = d || l, b = g || u, { clientWidth: p, clientHeight: v } = a.current, _ = f ? f > p ? p : f : 0, R = b ? b > v ? v : b : "unset", S = A(_), j = A(R), k = (x) => {
2104
+ S.current = x.width, j.current = x.height;
2105
+ }, I = A(Math.floor(p / 2)), U = A(Math.floor(v / 2)), Y = (x) => {
2106
+ I.current = x.left, U.current = x.top;
2107
2107
  };
2108
2108
  return G(() => {
2109
2109
  i(), k({ width: _, height: R }), Y({
@@ -2289,9 +2289,9 @@ const mc = (e) => {
2289
2289
  v
2290
2290
  ), { footerActions: S } = hc(e, p), j = A(null), k = A(null), I = A(null), U = A(null), {
2291
2291
  containerSizeTarget: Y,
2292
- parentInitRecord: w,
2292
+ parentInitRecord: x,
2293
2293
  initLeft: C,
2294
- initTop: x,
2294
+ initTop: w,
2295
2295
  initWidth: T,
2296
2296
  initHeight: F,
2297
2297
  curPropsWidth: E,
@@ -2306,10 +2306,10 @@ const mc = (e) => {
2306
2306
  initHeight: F,
2307
2307
  setDialogChangeRecord: te
2308
2308
  }), { dialogLeft: L, dialogTop: W, setDialogPosition: B } = _c({
2309
- initTop: x,
2309
+ initTop: w,
2310
2310
  initLeft: C,
2311
2311
  setDialogChangeRecord: te
2312
- }), { dialogMaxHeight: q, contentMaxHeight: yt } = wc({
2312
+ }), { dialogMaxHeight: q, contentMaxHeight: yt } = xc({
2313
2313
  visible: f,
2314
2314
  containerSizeTarget: Y,
2315
2315
  dialogHeight: de,
@@ -2319,23 +2319,23 @@ const mc = (e) => {
2319
2319
  }), { minResizeRecord: Le, setMinResizeRecord: Oe } = Fc(), { minimizeLeft: $e, minimizeTop: We, minimizeRef: me, setMinimizePosition: Qe } = Cc(), {
2320
2320
  minimizeVisible: Ne,
2321
2321
  maximizeVisible: _t,
2322
- setMaximizeVisible: xt,
2322
+ setMaximizeVisible: wt,
2323
2323
  onMaximize: Pe,
2324
2324
  onMinimize: Re,
2325
2325
  onRecovery: et,
2326
2326
  onClose: Me
2327
- } = xc({
2327
+ } = wc({
2328
2328
  containerSizeTarget: Y,
2329
2329
  dialogChangeRecord: Q,
2330
2330
  close: R,
2331
2331
  setDialogSize: ce,
2332
2332
  setDialogPosition: B
2333
2333
  }), ke = () => {
2334
- console.log("触发了initDialog"), ce({ width: T.current, height: F.current }), B({ left: C.current, top: x.current }), Qe({ left: 160, top: 60 }), xt(!1), Oe(null);
2334
+ console.log("触发了initDialog"), ce({ width: T.current, height: F.current }), B({ left: C.current, top: w.current }), Qe({ left: 160, top: 60 }), wt(!1), Oe(null);
2335
2335
  };
2336
2336
  G(() => {
2337
2337
  ke();
2338
- }, [w]), Sc({
2338
+ }, [x]), Sc({
2339
2339
  initWidth: T,
2340
2340
  initHeight: F,
2341
2341
  curPropsWidth: E,
@@ -2359,7 +2359,7 @@ const mc = (e) => {
2359
2359
  minimizeRef: me
2360
2360
  }), {
2361
2361
  resizingState: Be,
2362
- DashedBox: wt,
2362
+ DashedBox: xt,
2363
2363
  onMousedownResizeLt: Ct,
2364
2364
  onMousedownResizeRt: tt,
2365
2365
  onMousedownResizeRb: rt,
@@ -2461,7 +2461,7 @@ const mc = (e) => {
2461
2461
  ]
2462
2462
  }
2463
2463
  ),
2464
- /* @__PURE__ */ h.jsx(wt, {})
2464
+ /* @__PURE__ */ h.jsx(xt, {})
2465
2465
  ] });
2466
2466
  }), Nc = (e, t) => {
2467
2467
  const { children: r, ...n } = e, { baseDialogProps: o, dialogProps: s } = mc(n), { getPopperContainer: a } = s;
@@ -2675,7 +2675,7 @@ function sl(e, t = {}) {
2675
2675
  return;
2676
2676
  const s = [];
2677
2677
  return o.forEach((a, i) => {
2678
- xn(s, i, t[a.trim()]);
2678
+ wn(s, i, t[a.trim()]);
2679
2679
  }), s.filter(Boolean).length ? s : void 0;
2680
2680
  }
2681
2681
  }
@@ -2690,7 +2690,7 @@ function il(e, t = {}) {
2690
2690
  return;
2691
2691
  const s = {};
2692
2692
  return o.forEach((a) => {
2693
- xn(s, a.trim(), t[a.trim()]);
2693
+ wn(s, a.trim(), t[a.trim()]);
2694
2694
  }), Object.values(s).filter(Boolean).length ? s : void 0;
2695
2695
  }
2696
2696
  }
@@ -2960,13 +2960,13 @@ const cl = (e, t, r) => {
2960
2960
  value: u = t,
2961
2961
  // 默认文件列表
2962
2962
  onChange: d
2963
- } = e, g = A(!0), f = A(0), b = A([]), [p, v] = X([]), _ = (w) => {
2964
- b.current = w, v([...w]);
2963
+ } = e, g = A(!0), f = A(0), b = A([]), [p, v] = X([]), _ = (x) => {
2964
+ b.current = x, v([...x]);
2965
2965
  }, R = () => {
2966
2966
  const {
2967
- api: w,
2967
+ api: x,
2968
2968
  maxCount: C,
2969
- maxSize: x,
2969
+ maxSize: w,
2970
2970
  openCrop: T,
2971
2971
  beforeUpload: F,
2972
2972
  fileList: E,
@@ -2974,35 +2974,35 @@ const cl = (e, t, r) => {
2974
2974
  ...M
2975
2975
  } = e;
2976
2976
  return M;
2977
- }, S = (w) => {
2978
- const C = w.size / 1024 / 1024 < o;
2977
+ }, S = (x) => {
2978
+ const C = x.size / 1024 / 1024 < o;
2979
2979
  C || Ft.error(`文件大小超过:${o}M, 请重试`);
2980
- const x = b.current.length + f.current < n;
2981
- return x || Ft.error(`文件数量不能超过${n}个`), C && x && f.current++, C && x && j(w), $t.LIST_IGNORE;
2982
- }, j = (w) => {
2983
- a ? (Ft.error("暂时不支持裁剪功能,后续兼容。。。。"), k({ file: w })) : k({ file: w });
2984
- }, k = (w) => {
2985
- r ? r({ file: w.file, ...i }).then((C) => {
2980
+ const w = b.current.length + f.current < n;
2981
+ return w || Ft.error(`文件数量不能超过${n}个`), C && w && f.current++, C && w && j(x), $t.LIST_IGNORE;
2982
+ }, j = (x) => {
2983
+ a ? (Ft.error("暂时不支持裁剪功能,后续兼容。。。。"), k({ file: x })) : k({ file: x });
2984
+ }, k = (x) => {
2985
+ r ? r({ file: x.file, ...i }).then((C) => {
2986
2986
  _([...b.current, ...C]);
2987
2987
  }).finally(() => {
2988
2988
  f.current--;
2989
- }) : (Object.assign(w.file, {
2989
+ }) : (Object.assign(x.file, {
2990
2990
  status: "done",
2991
2991
  url: URL.createObjectURL(
2992
- new Blob([w.file], {
2993
- type: Kc(w.file.type)
2992
+ new Blob([x.file], {
2993
+ type: Kc(x.file.type)
2994
2994
  })
2995
2995
  )
2996
- }), _([...b.current, w.file]), f.current--);
2997
- }, I = (w) => {
2998
- const { file: C, fileList: x } = w, { status: T } = C;
2996
+ }), _([...b.current, x.file]), f.current--);
2997
+ }, I = (x) => {
2998
+ const { file: C, fileList: w } = x, { status: T } = C;
2999
2999
  switch (T) {
3000
3000
  case "removed": {
3001
- _([...x]);
3001
+ _([...w]);
3002
3002
  break;
3003
3003
  }
3004
3004
  }
3005
- }, U = (w) => {
3005
+ }, U = (x) => {
3006
3006
  const C = (T) => {
3007
3007
  const F = T.split("/"), E = F[F.length - 1], [D] = E.split("?");
3008
3008
  return D;
@@ -3010,13 +3010,13 @@ const cl = (e, t, r) => {
3010
3010
  return { uid: ((T) => {
3011
3011
  const F = b.current.find((E) => E.url === T);
3012
3012
  return F ? F.uid : dr();
3013
- })(w), name: C(w), url: w, status: "done" };
3013
+ })(x), name: C(x), url: x, status: "done" };
3014
3014
  }, Y = () => {
3015
3015
  switch (l) {
3016
3016
  case be.String:
3017
- return p.map((w) => w.url).join(",");
3017
+ return p.map((x) => x.url).join(",");
3018
3018
  case be["String[]"]:
3019
- return p.map((w) => w.url);
3019
+ return p.map((x) => x.url);
3020
3020
  case be["File[]"]:
3021
3021
  return [...p];
3022
3022
  case be.FileList:
@@ -3024,24 +3024,24 @@ const cl = (e, t, r) => {
3024
3024
  }
3025
3025
  };
3026
3026
  return G(() => {
3027
- const w = Y();
3028
- if (dt(w, u)) return;
3027
+ const x = Y();
3028
+ if (dt(x, u)) return;
3029
3029
  let C = [];
3030
3030
  switch (l) {
3031
3031
  case be.String: {
3032
- C = (u || "").split(",").filter((x) => x).map((x) => U(x));
3032
+ C = (u || "").split(",").filter((w) => w).map((w) => U(w));
3033
3033
  break;
3034
3034
  }
3035
3035
  case be["String[]"]: {
3036
- C = (u || []).map((x) => U(x));
3036
+ C = (u || []).map((w) => U(w));
3037
3037
  break;
3038
3038
  }
3039
3039
  case be["File[]"]: {
3040
- C = (u || []).map((x) => x);
3040
+ C = (u || []).map((w) => w);
3041
3041
  break;
3042
3042
  }
3043
3043
  case be.FileList: {
3044
- C = (u || []).map((x) => x);
3044
+ C = (u || []).map((w) => w);
3045
3045
  break;
3046
3046
  }
3047
3047
  }
@@ -3051,8 +3051,8 @@ const cl = (e, t, r) => {
3051
3051
  g.current = !1;
3052
3052
  return;
3053
3053
  }
3054
- const w = Y();
3055
- d == null || d(w);
3054
+ const x = Y();
3055
+ d == null || d(x);
3056
3056
  }, [p]), /* @__PURE__ */ h.jsx(
3057
3057
  $t,
3058
3058
  {
@@ -3145,9 +3145,9 @@ const Nr = {
3145
3145
  labelCol: j,
3146
3146
  valuePropName: k,
3147
3147
  initialValue: I
3148
- }), { setExtendFormComp: w } = jn();
3149
- w(N);
3150
- const C = Qt(t), x = er(t), T = () => {
3148
+ }), { setExtendFormComp: x } = jn();
3149
+ x(N);
3150
+ const C = Qt(t), w = er(t), T = () => {
3151
3151
  if (C) {
3152
3152
  const F = N.get(t.component);
3153
3153
  return /* @__PURE__ */ h.jsx(
@@ -3159,7 +3159,7 @@ const Nr = {
3159
3159
  }
3160
3160
  );
3161
3161
  }
3162
- return x ? t.render({
3162
+ return w ? t.render({
3163
3163
  model: a,
3164
3164
  name: _,
3165
3165
  disabled: b,
@@ -3214,10 +3214,10 @@ const Nr = {
3214
3214
  }
3215
3215
  ), _l = {
3216
3216
  "group-wrapper": "_group-wrapper_g8zqi_1"
3217
- }, xl = ({ formProps: e }) => {
3217
+ }, wl = ({ formProps: e }) => {
3218
3218
  const { renderActions: t } = e;
3219
3219
  return /* @__PURE__ */ h.jsx("div", { className: _l["group-wrapper"], children: t == null ? void 0 : t() });
3220
- }, wl = {
3220
+ }, xl = {
3221
3221
  "xph-form-action": "_xph-form-action_8ws73_1"
3222
3222
  }, Cl = (e, t) => {
3223
3223
  console.log("render Form");
@@ -3247,9 +3247,9 @@ const Nr = {
3247
3247
  wrapperCol: I,
3248
3248
  labelCol: U,
3249
3249
  colon: Y,
3250
- disabled: w,
3250
+ disabled: x,
3251
3251
  labelWrap: C,
3252
- labelAlign: x,
3252
+ labelAlign: w,
3253
3253
  scrollToFirstError: T,
3254
3254
  size: F
3255
3255
  } = n;
@@ -3258,9 +3258,9 @@ const Nr = {
3258
3258
  wrapperCol: I,
3259
3259
  labelCol: U,
3260
3260
  colon: Y,
3261
- disabled: w,
3261
+ disabled: x,
3262
3262
  labelWrap: C,
3263
- labelAlign: x,
3263
+ labelAlign: w,
3264
3264
  scrollToFirstError: T,
3265
3265
  size: F
3266
3266
  };
@@ -3288,8 +3288,8 @@ const Nr = {
3288
3288
  },
3289
3289
  I
3290
3290
  ))) }),
3291
- /* @__PURE__ */ h.jsxs("div", { className: wl["xph-form-action"], children: [
3292
- /* @__PURE__ */ h.jsx(xl, { formProps: n }),
3291
+ /* @__PURE__ */ h.jsxs("div", { className: xl["xph-form-action"], children: [
3292
+ /* @__PURE__ */ h.jsx(wl, { formProps: n }),
3293
3293
  a ? /* @__PURE__ */ h.jsx(
3294
3294
  yl,
3295
3295
  {
@@ -3738,28 +3738,28 @@ function Ul(e, t) {
3738
3738
  model: g,
3739
3739
  update: (C) => {
3740
3740
  var T;
3741
- const x = { ...b.current, ...C };
3742
- f(x), b.current = x, (T = t.current) == null || T.setFormLoading(x.loading);
3741
+ const w = { ...b.current, ...C };
3742
+ f(w), b.current = w, (T = t.current) == null || T.setFormLoading(w.loading);
3743
3743
  }
3744
3744
  }, v = async () => {
3745
3745
  G(() => {
3746
- const { autoRequest: C } = e.table, { validator: x } = t.current;
3747
- C && x().then((T) => {
3746
+ const { autoRequest: C } = e.table, { validator: w } = t.current;
3747
+ C && w().then((T) => {
3748
3748
  j({ searchFormParams: T });
3749
3749
  });
3750
3750
  }, []);
3751
3751
  }, _ = async ({
3752
3752
  searchFormParams: C,
3753
- paginationParams: x
3753
+ paginationParams: w
3754
3754
  }) => {
3755
3755
  const T = {
3756
3756
  ...C,
3757
3757
  /** 没传paginationParams默认就是上一次 */
3758
3758
  [`${a.current}`]: d.current.current,
3759
3759
  [`${a.pageSize}`]: d.current.pageSize,
3760
- ...x ? {
3761
- [`${a.current}`]: x.current,
3762
- [`${a.pageSize}`]: x.pageSize
3760
+ ...w ? {
3761
+ [`${a.current}`]: w.current,
3762
+ [`${a.pageSize}`]: w.pageSize
3763
3763
  } : {}
3764
3764
  };
3765
3765
  return r(T).then((F) => {
@@ -3779,7 +3779,7 @@ function Ul(e, t) {
3779
3779
  });
3780
3780
  }, R = async ({
3781
3781
  searchFormParams: C,
3782
- paginationParams: x
3782
+ paginationParams: w
3783
3783
  }) => {
3784
3784
  const T = { ...C };
3785
3785
  return r(T).then((F) => {
@@ -3796,12 +3796,12 @@ function Ul(e, t) {
3796
3796
  });
3797
3797
  }, S = async ({
3798
3798
  searchFormParams: C,
3799
- paginationParams: x
3799
+ paginationParams: w
3800
3800
  }) => {
3801
3801
  var F;
3802
3802
  const T = { ...C };
3803
- if (x) {
3804
- const { current: E, pageSize: D } = x;
3803
+ if (w) {
3804
+ const { current: E, pageSize: D } = w;
3805
3805
  u.update({
3806
3806
  current: E,
3807
3807
  pageSize: D
@@ -3832,25 +3832,25 @@ function Ul(e, t) {
3832
3832
  });
3833
3833
  }, j = async ({
3834
3834
  searchFormParams: C,
3835
- paginationParams: x
3835
+ paginationParams: w
3836
3836
  }) => {
3837
3837
  if (p.update({ loading: !0, selection: [] }), r)
3838
3838
  switch (!!d.current) {
3839
3839
  case !0:
3840
3840
  return o === !0 ? S({
3841
3841
  searchFormParams: C,
3842
- paginationParams: x
3842
+ paginationParams: w
3843
3843
  }) : o === !1 ? R({
3844
3844
  searchFormParams: C,
3845
- paginationParams: x
3845
+ paginationParams: w
3846
3846
  }) : _({
3847
3847
  searchFormParams: C,
3848
- paginationParams: x
3848
+ paginationParams: w
3849
3849
  });
3850
3850
  case !1:
3851
3851
  return R({
3852
3852
  searchFormParams: C,
3853
- paginationParams: x
3853
+ paginationParams: w
3854
3854
  });
3855
3855
  }
3856
3856
  return p.update({ loading: !1 });
@@ -3859,43 +3859,43 @@ function Ul(e, t) {
3859
3859
  table: p,
3860
3860
  pagination: u,
3861
3861
  firstGetTableData: v,
3862
- onPaginationChange: (C, x) => {
3862
+ onPaginationChange: (C, w) => {
3863
3863
  const { validator: T } = t.current;
3864
3864
  T().then((F) => {
3865
3865
  j({
3866
3866
  searchFormParams: F,
3867
- paginationParams: { current: C, pageSize: x }
3867
+ paginationParams: { current: C, pageSize: w }
3868
3868
  });
3869
- }), l && l(C, x);
3869
+ }), l && l(C, w);
3870
3870
  },
3871
3871
  onAllChange: async (...C) => {
3872
- const [x, T, F, E] = C, D = [];
3872
+ const [w, T, F, E] = C, D = [];
3873
3873
  for (let M = 0; M < D.length && !D[M](); M++)
3874
3874
  ;
3875
3875
  s && s(T, F, E);
3876
3876
  },
3877
3877
  resetData: async () => {
3878
- const { resetFields: C, validator: x } = t.current;
3878
+ const { resetFields: C, validator: w } = t.current;
3879
3879
  return C().then(async () => {
3880
- const T = await x();
3880
+ const T = await w();
3881
3881
  return j({ searchFormParams: T });
3882
3882
  });
3883
3883
  },
3884
3884
  resetAllData: async () => {
3885
- const { resetFields: C, validator: x } = t.current;
3885
+ const { resetFields: C, validator: w } = t.current;
3886
3886
  return C().then(async () => {
3887
3887
  const T = {};
3888
3888
  if (d.current) {
3889
3889
  const { pageSize: F } = d.current;
3890
3890
  o === void 0 && (T.paginationParams = { current: 1, pageSize: F });
3891
3891
  }
3892
- return T.searchFormParams = await x(), j(T);
3892
+ return T.searchFormParams = await w(), j(T);
3893
3893
  });
3894
3894
  },
3895
3895
  reloadData: async () => {
3896
3896
  const { validator: C } = t.current;
3897
- return C().then((x) => j({
3898
- searchFormParams: x
3897
+ return C().then((w) => j({
3898
+ searchFormParams: w
3899
3899
  }));
3900
3900
  }
3901
3901
  };
@@ -3939,8 +3939,7 @@ function Gl(e, t) {
3939
3939
  g && o.current && g.unobserve(o.current);
3940
3940
  };
3941
3941
  }, []);
3942
- const d = pt(() => t ? n ? { x: s, y: i - 70, ...r } : { x: "max-content", y: i - 70, ...r } : {
3943
- x: "max-content",
3942
+ const d = pt(() => t ? n ? { x: s, y: i - 70, ...r } : { y: i - 70, ...r } : {
3944
3943
  ...r
3945
3944
  }, [i]);
3946
3945
  return {
@@ -4010,9 +4009,9 @@ const An = () => {
4010
4009
  formatDataSource: I,
4011
4010
  autoPagination: U,
4012
4011
  columns: Y,
4013
- scroll: w,
4012
+ scroll: x,
4014
4013
  pagination: C,
4015
- rowSelection: x,
4014
+ rowSelection: w,
4016
4015
  onChange: T,
4017
4016
  ...F
4018
4017
  } = e.table;
@@ -27,4 +27,4 @@ Check the top-level render call using <`+_+">.")}return b}}function fn(l,b){{if(
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} />`,Yt,Fe,ac,Fe),pn[Fe+Yt]=!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;Ie.Fragment=n,Ie.jsx=sc,Ie.jsxs=ic}()),Ie}process.env.NODE_ENV==="production"?ht.exports=mn():ht.exports=bn();var m=ht.exports,Kt=typeof global=="object"&&global&&global.Object===Object&&global,vn=typeof self=="object"&&self&&self.Object===Object&&self,fe=Kt||vn||Function("return this")(),_e=fe.Symbol,Jt=Object.prototype,yn=Jt.hasOwnProperty,_n=Jt.toString,ze=_e?_e.toStringTag:void 0;function wn(e){var t=yn.call(e,ze),r=e[ze];try{e[ze]=void 0;var n=!0}catch{}var o=_n.call(e);return n&&(t?e[ze]=r:delete e[ze]),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 de(e){return e==null?e===void 0?Pn:Sn:Zt&&Zt in Object(e)?wn(e):Tn(e)}function ae(e){return e!=null&&typeof e=="object"}var En="[object Symbol]";function mt(e){return typeof e=="symbol"||ae(e)&&de(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(mt(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=de(e);return t==An||t==On||t==Dn||t==$n}var bt=fe["__core-js_shared__"],nr=function(){var e=/[^.]+$/.exec(bt&&bt.keys&&bt.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 Ce(e){if(e!=null){try{return kn.call(e)}catch{}try{return e+""}catch{}}return""}var In=/[\\^$.*+?()[\]{}|]/g,zn=/^\[object .+?Constructor\]$/,Ln=Function.prototype,Wn=Object.prototype,Nn=Ln.toString,Bn=Wn.hasOwnProperty,Hn=RegExp("^"+Nn.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(Ce(e))}function Un(e,t){return e==null?void 0:e[t]}function xe(e,t){var r=Un(e,t);return Vn(r)?r:void 0}var vt=xe(fe,"WeakMap"),or=Object.create,Yn=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 qn(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 Xe=function(){try{var e=xe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),eo=Xe?function(e,t){return Xe(e,"toString",{configurable:!0,enumerable:!1,value:Qn(t),writable:!0})}:rr,to=Zn(eo),ro=9007199254740991,no=/^(?:0|[1-9]\d*)$/;function yt(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 _t(e,t,r){t=="__proto__"&&Xe?Xe(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Le(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)&&Le(n,r))||r===void 0&&!(t in e))&&_t(e,t,r)}function io(e,t,r,n){var o=!r;r||(r={});for(var s=-1,a=t.length;++s<a;){var i=t[s],c=void 0;c===void 0&&(c=e[i]),o?_t(r,i,c):sr(r,i,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),a=Array(s);++o<s;)a[o]=n[t+o];o=-1;for(var i=Array(t+1);++o<t;)i[o]=n[o];return i[t]=r(a),qn(e,this,i)}}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 Ke(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"?Ke(r)&&yt(t,r.length):n=="string"&&t in r)?Le(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,a=o>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(o--,s):void 0,a&&uo(r[0],r[1],a)&&(s=o<3?void 0:s,o=1),t=Object(t);++n<o;){var i=r[n];i&&e(t,i,n,s)}return t})}var po=Object.prototype;function wt(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 ae(e)&&de(e)==ho}var cr=Object.prototype,mo=cr.hasOwnProperty,bo=cr.propertyIsEnumerable,Ct=lr(function(){return arguments}())?lr:function(e){return ae(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?fe.Buffer:void 0,_o=dr?dr.isBuffer:void 0,Je=_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]",Wo="[object Int32Array]",No="[object Uint8Array]",Bo="[object Uint8ClampedArray]",Ho="[object Uint16Array]",Vo="[object Uint32Array]",U={};U[ko]=U[Io]=U[zo]=U[Lo]=U[Wo]=U[No]=U[Bo]=U[Ho]=U[Vo]=!0,U[wo]=U[Co]=U[Ro]=U[xo]=U[Mo]=U[To]=U[So]=U[Po]=U[Eo]=U[Fo]=U[jo]=U[Do]=U[Ao]=U[Oo]=U[$o]=!1;function Uo(e){return ae(e)&&ar(e.length)&&!!U[de(e)]}function Yo(e){return function(t){return e(t)}}var pr=typeof R=="object"&&R&&!R.nodeType&&R,We=pr&&typeof module=="object"&&module&&!module.nodeType&&module,qo=We&&We.exports===pr,xt=qo&&Kt.process,gr=function(){try{var e=We&&We.require&&We.require("util").types;return e||xt&&xt.binding&&xt.binding("util")}catch{}}(),hr=gr&&gr.isTypedArray,Tt=hr?Yo(hr):Uo,Go=Object.prototype,Xo=Go.hasOwnProperty;function mr(e,t){var r=te(e),n=!r&&Ct(e),o=!r&&!n&&Je(e),s=!r&&!n&&!o&&Tt(e),a=r||n||o||s,i=a?go(e.length,String):[],c=i.length;for(var u in e)(t||Xo.call(e,u))&&!(a&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||yt(u,c)))&&i.push(u);return i}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(!wt(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 Ke(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=wt(e),r=[];for(var n in e)n=="constructor"&&(t||!ns.call(e,n))||r.push(n);return r}function vr(e){return Ke(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||mt(e)?!0:is.test(e)||!ss.test(e)||t!=null&&e in Object(t)}var Ne=xe(Object,"create");function ls(){this.__data__=Ne?Ne(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(Ne){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 Ne?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]=Ne&&t===void 0?bs:t,this}function Te(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])}}Te.prototype.clear=ls,Te.prototype.delete=cs,Te.prototype.get=ps,Te.prototype.has=ms,Te.prototype.set=vs;function ys(){this.__data__=[],this.size=0}function Ze(e,t){for(var r=e.length;r--;)if(Le(e[r][0],t))return r;return-1}var _s=Array.prototype,ws=_s.splice;function Cs(e){var t=this.__data__,r=Ze(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=Ze(t,e);return r<0?void 0:t[r][1]}function Ts(e){return Ze(this.__data__,e)>-1}function Ss(e,t){var r=this.__data__,n=Ze(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 Be=xe(fe,"Map");function Ps(){this.size=0,this.__data__={hash:new Te,map:new(Be||ge),string:new Te}}function Es(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Qe(e,t){var r=e.__data__;return Es(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Fs(e){var t=Qe(this,e).delete(e);return this.size-=t?1:0,t}function js(e){return Qe(this,e).get(e)}function Ds(e){return Qe(this,e).has(e)}function As(e,t){var r=Qe(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 St(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 a=e.apply(this,n);return r.cache=s.set(o,a)||s,a};return r.cache=new(St.Cache||he),r}St.Cache=he;var $s=500;function Rs(e){var t=St(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 Ws=1/0;function Ns(e){if(typeof e=="string"||mt(e))return e;var t=e+"";return t=="0"&&1/e==-Ws?"-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,Ys=Us.hasOwnProperty,qs=_r.call(Object);function Gs(e){if(!ae(e)||de(e)!=Hs)return!1;var t=yr(e);if(t===null)return!0;var r=Ys.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&_r.call(r)==qs}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(!Be||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?fe.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 a=e[r];t(a,r,e)&&(s[o++]=a)}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 Pt=xe(fe,"DataView"),Et=xe(fe,"Promise"),Ft=xe(fe,"Set"),Pr="[object Map]",ci="[object Object]",Er="[object Promise]",Fr="[object Set]",jr="[object WeakMap]",Dr="[object DataView]",ui=Ce(Pt),fi=Ce(Be),di=Ce(Et),pi=Ce(Ft),gi=Ce(vt),we=de;(Pt&&we(new Pt(new ArrayBuffer(1)))!=Dr||Be&&we(new Be)!=Pr||Et&&we(Et.resolve())!=Er||Ft&&we(new Ft)!=Fr||vt&&we(new vt)!=jr)&&(we=function(e){var t=de(e),r=t==ci?e.constructor:void 0,n=r?Ce(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 et=fe.Uint8Array;function hi(e){var t=new e.constructor(e.byteLength);return new et(t).set(new et(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"&&!wt(e)?Yn(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 tt(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new he;++t<r;)this.add(e[t])}tt.prototype.add=tt.prototype.push=yi,tt.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 a=r&xi,i=e.length,c=t.length;if(i!=c&&!(a&&c>i))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 tt:void 0;for(s.set(e,t),s.set(t,e);++h<i;){var g=e[h],y=t[h];if(n)var w=a?n(y,g,h,t,e,s):n(g,y,h,e,t,s);if(w!==void 0){if(w)continue;d=!1;break}if(v){if(!wi(t,function(j,E){if(!Ci(v,E)&&(g===j||o(g,j,r,n,s)))return v.push(E)})){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,jt=Or?Or.valueOf:void 0;function Wi(e,t,r,n,o,s,a){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 et(e),new et(t)));case ji:case Di:case $i:return Le(+e,+t);case Ai:return e.name==t.name&&e.message==t.message;case Ri:case ki:return e==t+"";case Oi:var i=Si;case Mi:var c=n&Ei;if(i||(i=Pi),e.size!=t.size&&!c)return!1;var u=a.get(e);if(u)return u==t;n|=Fi,a.set(e,t);var f=Ar(i(e),i(t),n,o,s,a);return a.delete(e),f;case Ii:if(jt)return jt.call(e)==jt.call(t)}return!1}var Ni=1,Bi=Object.prototype,Hi=Bi.hasOwnProperty;function Vi(e,t,r,n,o,s){var a=r&Ni,i=Sr(e),c=i.length,u=Sr(t),f=u.length;if(c!=f&&!a)return!1;for(var h=c;h--;){var d=i[h];if(!(a?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 w=a;++h<c;){d=i[h];var j=e[d],E=t[d];if(n)var D=a?n(E,j,d,t,e,s):n(j,E,d,e,t,s);if(!(D===void 0?j===E||o(j,E,r,n,s):D)){y=!1;break}w||(w=d=="constructor")}if(y&&!w){var z=e.constructor,N=t.constructor;z!=N&&"constructor"in e&&"constructor"in t&&!(typeof z=="function"&&z instanceof z&&typeof N=="function"&&N instanceof N)&&(y=!1)}return s.delete(e),s.delete(t),y}var Ui=1,$r="[object Arguments]",Rr="[object Array]",rt="[object Object]",Yi=Object.prototype,Mr=Yi.hasOwnProperty;function qi(e,t,r,n,o,s){var a=te(e),i=te(t),c=a?Rr:we(e),u=i?Rr:we(t);c=c==$r?rt:c,u=u==$r?rt:u;var f=c==rt,h=u==rt,d=c==u;if(d&&Je(e)){if(!Je(t))return!1;a=!0,f=!1}if(d&&!f)return s||(s=new me),a||Tt(e)?Ar(e,t,r,n,o,s):Wi(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,w=g?t.value():t;return s||(s=new me),o(y,w,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||!ae(e)&&!ae(t)?e!==e&&t!==t:qi(e,t,r,n,kr,o)}function Gi(e){return function(t,r,n){for(var o=-1,s=Object(t),a=n(t),i=a.length;i--;){var c=a[++o];if(r(s[c],c,s)===!1)break}return t}}var Xi=Gi();function Dt(e,t,r){(r!==void 0&&!Le(e[t],r)||r===void 0&&!(t in e))&&_t(e,t,r)}function Ki(e){return ae(e)&&Ke(e)}function At(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,a){var i=At(e,r),c=At(t,r),u=a.get(c);if(u){Dt(e,r,u);return}var f=s?s(i,c,r+"",e,t,a):void 0,h=f===void 0;if(h){var d=te(c),v=!d&&Je(c),g=!d&&!v&&Tt(c);f=c,d||v||g?te(i)?f=i:Ki(i)?f=Gn(i):v?(h=!1,f=ri(c)):g?(h=!1,f=mi(c)):f=[]:Gs(c)||Ct(c)?(f=i,Ct(i)?f=Ji(i):(!se(i)||Z(i))&&(f=bi(c))):h=!1}h&&(a.set(c,f),o(f,c,n,s,a),a.delete(c)),Dt(e,r,f)}function Ir(e,t,r,n,o){e!==t&&Xi(t,function(s,a){if(o||(o=new me),se(s))Zi(e,t,a,r,Ir,n,o);else{var i=n?n(At(e,a),s,a+"",e,t,o):void 0;i===void 0&&(i=s),Dt(e,a,i)}},vr)}var Qi="[object String]";function zr(e){return typeof e=="string"||!te(e)&&ae(e)&&de(e)==Qi}var ea="[object Boolean]";function Ot(e){return e===!0||e===!1||ae(e)&&de(e)==ea}function nt(e,t){return kr(e,t)}var ta="[object Number]";function ra(e){return typeof e=="number"||ae(e)&&de(e)==ta}function Lr(e){return e==null}function na(e){return e===null}var le=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,a=s-1,i=e;i!=null&&++o<s;){var c=Ns(t[o]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(o!=a){var f=i[c];u=void 0,u===void 0&&(u=se(f)?f:yt(t[o+1])?[]:{})}sr(i,c,u),i=i[c]}return e}function Wr(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={...le(le({items:[],max:10},t?r:{}),e)},a={...le({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:a}}function Nr(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,a=h=>{const{auth:d}=h;let v=!1;return d?te(d)?v=d.every(g=>t(g)):v=t(d):v=!0,v},i=h=>{let{ifShow:d=!0}=h;return d=d&&Z(d)?d():d,d&&a(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(Nr(d)){const v=d.component;switch(d.componentProps={type:r,disabled:n,...d.componentProps},v){case"Dropdown":{d.componentProps.dropDownItems=(d.componentProps.dropDownItems||[]).filter(i);break}}}return d}).filter(i).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(S.Button,{...r()})},ca=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...a}=t;return a})();return m.jsx(S.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(S.Button,{...n,children:[n.children,m.jsx(ue.CaretDownOutlined,{})]})})})},ot=new Map;ot.set("Button",la),ot.set("Dropdown",ca);function Br(){const{setExtendActionsComp:e}=Ur();return e(ot),{renderContent:p.useCallback((r,n)=>{const o=Nr(r),s=ia(r);if(o){const a=ot.get(r.component);return p.createElement(a,{...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})},je=()=>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((a,i)=>{r(c=>{const u=typeof s=="function"?s(c):s;return n.current=a,u})})]},Ur=()=>{const{extendProps:e,extendComp:t}=je(),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}=S.theme,da=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Br(),{token:s}=fa(),a={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},i=()=>m.jsx("div",{style:a,children:m.jsx(S.Space,{style:{padding:8},children:e==null?void 0:e.map((c,u)=>o(c,u))})});return m.jsx(S.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:i,trigger:["click"],children:m.jsxs(S.Button,{type:r,children:["更多",m.jsx(ue.CaretDownOutlined,{})]})})},st=e=>{const{actionsProps:t,authProps:r}=sa(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=aa(t,n),{renderContent:a}=Br();return t!=null&&t.render?t.render:m.jsxs(p.Fragment,{children:[o==null?void 0:o.map((i,c)=>a(i,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:a,cancelProps:i}=e;return{footerActions:{disabled:t,max:2,items:[{component:"Button",componentProps:{...i,children:n,onClick:o}},{component:"Button",componentProps:{type:"primary",loading:t,...a,children:r,onClick:s}}]}}}const ga=e=>{const{extendDialogProps:t}=ha(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body},n={...le(le(r,t),e)};return{dialogProps:{...n,getPopperContainer:()=>{const s=n.getPopperContainer();return n.mask?document.body:s}},baseDialogProps:r}},ha=()=>{const{extendProps:e}=je();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,a]=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&&a(u)}}},va=({initLeft:e,initTop:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,a]=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&&a(u)}}},Yr=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=p.useRef(0),s=p.useRef(0),a=f=>{const h=f.getBoundingClientRect(),d=h.width,v=h.height,g=-.5*d,y=-.5*v;return{translateX:g,translateY:y}},i=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}=a(h);let g=f.clientX-o.current,y=f.clientY-s.current;const w=-d,j=-v,E=e.current.scrollWidth-h.offsetWidth-d,D=e.current.scrollHeight-h.offsetHeight-v;g<w&&(g=w),g>E&&(g=E),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",i),()=>{f.removeEventListener("mousedown",i)}},[]),{}},ya=({containerSizeTarget:e,dialogChangeRecord:t,close:r,setDialogSize:n,setDialogPosition:o})=>{const[s,a]=p.useState(!1),[i,c]=p.useState(!1);return{minimizeVisible:s,maximizeVisible:i,setMinimizeVisible:a,setMaximizeVisible:c,onMinimize:()=>{a(!0)},onMaximize:v=>{if(v==="minimize"&&a(!1),v==="maximize"){const{scrollWidth:g,scrollHeight:y}=e.current,w=Math.floor(g),j=Math.floor(y),E=Math.floor(g/2),D=Math.floor(y/2);n({width:w,height:j}),o({top:D,left:E}),c(!0)}},onRecovery:()=>{const{top:v,left:g,width:y,height:w}=t.current;n({width:y,height:w}),o({top:v,left:g}),c(!1)},onClose:()=>{a(!1),c(!1),r()}}},_a=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:a,scrollHeight:i}=t.current,[c,u]=p.useState(0),[f,h]=p.useState("unset"),d=(v,g)=>{var N,q;const j=(N=o.current)==null?void 0:N.offsetHeight,E=(q=s.current)==null?void 0:q.offsetHeight;let D=v-j-E-0;const z=g-j-E-0;return D>z&&(D=z),D};return p.useEffect(()=>{var v;if(c===a){console.log("触发了dialogMaxHeight改变");const g=(v=n.current)==null?void 0:v.getBoundingClientRect().height;h(d(g,a)),u("unset")}},[c]),p.useEffect(()=>{r!=="unset"&&r!==0&&(console.log("触发了重新设置contentMaxHeight",r),h(d(r,r>a?i:a)),u("unset"))},[r]),p.useEffect(()=>{e?u(a):(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:a,top:i})=>{a!==void 0&&t(a),i!==void 0&&n(i)}}},Ca=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=(i,c)=>{console.log("触发插入"),i.querySelector(`.${o.xphDialogWrapper}`).style.opacity="unset",i.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(i,u),c.parentNode.removeChild(u)},a=i=>{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),i)){const d=i.target;d.tagName==="INPUT"&&d.focus&&d.focus()}};return p.useEffect(()=>{var i,c;return(i=t.current)==null||i.addEventListener("mousedown",a,!1),(c=r.current)==null||c.addEventListener("mousedown",a,!1),()=>{var u,f;(u=t.current)==null||u.removeEventListener("mousedown",a,!1),(f=r.current)==null||f.removeEventListener("mousedown",a,!1)}},[]),p.useEffect(()=>{if(e)a();else{const i=Array.from(n.querySelectorAll(`.${o.xphDialog}`)),c=i.map(d=>d.querySelector(`.${o.xphDialogWrapper}`)).filter(d=>d!==null),u=i.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,i[i.length-1]);return}if(h.length){s(h[h.length-1].parentNode,i[i.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},xa=({initWidth:e,initHeight:t,curPropsWidth:r,curPropsHeight:n,setParentInitRecord:o})=>{p.useEffect(()=>{if(r!==e.current){console.log("动态设置了宽度"),o(s=>s+1);return}if(n!==t.current){console.log("动态设置了高度"),o(s=>s+1);return}},[r,n])},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:a,top:i,width:c,height:u}=e.current;e.current={left:r??a,top:n??i,width:o??c,height:s??u}}}},Sa=({containerSizeTarget:e,dialogRef:t,minResizeRecord:r,setDialogSize:n,setDialogPosition:o,setMinResizeRecord:s})=>{const a=p.useCallback(()=>m.jsx("div",{ref:i,style:{position:"absolute",border:"4px dashed #ccc",display:"none"}}),[]),i=p.useRef(null),c=p.useRef(),u=p.useRef(!1),[f,h]=p.useState(!1),d=p.useRef(0),v=p.useRef(0),g=(x,T)=>{r.current||s({width:t.current.offsetWidth,height:t.current.offsetHeight}),u.current=!0,h(!0),c.current=T;const{clientX:C,clientY:P}=x;d.current=C,v.current=P;const A=parseFloat(t.current.style.left),O=parseFloat(t.current.style.top),$=t.current.offsetWidth,I=t.current.offsetHeight;i.current.style.display="block",i.current.style.left=`${A-.5*$}px`,i.current.style.top=`${O-.5*I}px`,i.current.style.width=`${$}px`,i.current.style.height=`${I}px`},y=x=>{if(u.current){const{clientX:T,clientY:C}=x,P=T-d.current,A=C-v.current,O=parseFloat(i.current.style.left),$=parseFloat(i.current.style.top),I=i.current.offsetWidth,Q=i.current.offsetHeight,ne=r.current.width,ve=r.current.height,pe=e.current.scrollWidth,ce=e.current.scrollHeight;let B=I,H=Q,Y=O,X=$;switch(c.current){case"lt":{B=B-P,H=H-A,X=X+A,Y=Y+P,B<ne&&(B=I,Y=O),H<ve&&(H=Q,X=$),Y<0&&(Y=0,B=I),X<0&&(X=0,H=Q);break}case"rt":{B=B+P,H=H-A,X=X+A,Y=O,B<ne&&(B=I),H<ve&&(H=Q,X=$),B>pe-Y&&(B=pe-Y),X<0&&(X=0,H=Q);break}case"rb":{B=B+P,H=H+A,X=$,Y=O,B<ne&&(B=I),H<ve&&(H=Q),B>pe-Y&&(B=pe-Y),H>ce-X&&(H=ce-X);break}case"lb":{B=B-P,H=H+A,X=$,Y=Y+P,B<ne&&(B=I,Y=O),H<ve&&(H=Q),Y<0&&(Y=0,B=I),H>ce-X&&(H=ce-X);break}}i.current.style.left=`${Y}px`,i.current.style.top=`${X}px`,i.current.style.width=`${B}px`,i.current.style.height=`${H}px`,d.current=T,v.current=C}},w=()=>{if(u.current){u.current=!1,h(!1),i.current.style.display="none";const{left:x,top:T,width:C,height:P}=i.current.style,A=parseFloat(x)+.5*parseFloat(C),O=parseFloat(T)+.5*parseFloat(P),$=parseFloat(C),I=parseFloat(P);o({left:A,top:O}),n({width:$,height:I})}},j=x=>g(x,"lt"),E=x=>g(x,"rt"),D=x=>g(x,"rb"),z=x=>g(x,"lb"),N=p.useCallback(x=>{y(x)},[]),q=p.useCallback(()=>{w()},[]),G=p.useCallback(()=>{w()},[]);return p.useEffect(()=>(document.body.addEventListener("mousemove",N),document.body.addEventListener("mouseup",q),document.body.addEventListener("mouseleave",G),()=>{document.body.removeEventListener("mousemove",N),document.body.removeEventListener("mouseup",q),document.body.removeEventListener("mouseleave",G)}),[]),{resizingState:f,DashedBox:a,onMousedownResizeLt:j,onMousedownResizeRt:E,onMousedownResizeRb:D,onMousedownResizeLb:z}},Pa=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=p.useState(0),s=()=>{o(x=>x+1)};p.useEffect(()=>(window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}),[]);const{containerSizeTarget:a,setContainerSizeTarget:i}=Fa({container:e}),{width:c,height:u}=r,{width:f,height:h}=t,d=f||c,v=h||u,{clientWidth:g,clientHeight:y}=a.current,w=d?d>g?g:d:0,j=v?v>y?y:v:"unset",E=p.useRef(w),D=p.useRef(j),z=x=>{E.current=x.width,D.current=x.height},N=p.useRef(Math.floor(g/2)),q=p.useRef(Math.floor(y/2)),G=x=>{N.current=x.left,q.current=x.top};return p.useEffect(()=>{i(),z({width:w,height:j}),G({left:Math.floor(g/2),top:Math.floor(y/2)})},[n]),{containerSizeTarget:a,parentInitRecord:n,initLeft:N,initTop:q,initWidth:E,initHeight:D,curPropsWidth:w,curPropsHeight:j,setInitPosition:G,setInitSize:z,setParentInitRecord:o}},Ea=()=>{const e=p.useRef(null);return{minResizeRecord:e,setMinResizeRecord:r=>{e.current=r}}},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}}}},$t={"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(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.ShrinkOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),qr=({onClick:e})=>m.jsx(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.FullscreenOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Da=({onClick:e})=>m.jsx(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.FullscreenExitOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Gr=({onClick:e,disabled:t})=>m.jsx(S.Button,{type:"link",onClick:e,disabled:t,icon:m.jsx(ue.CloseOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),{useToken:Aa}=S.theme,Oa=p.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:a,className:i},c)=>{const{token:u}=Aa(),f={borderRadius:u.borderRadiusLG};return m.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...f},className:`${$t["minimize-windows"]} ${i}`,ref:c,children:[m.jsx("div",{className:$t["minimize-windows-title"],title:e,children:e}),m.jsxs("div",{className:$t["minimize-windows-operate"],children:[m.jsx(qr,{onClick:s}),m.jsx(Gr,{onClick:a,disabled:o})]})]})}),re={"xph-dialog-mask":"_xph-dialog-mask_o2yvb_1","xph-dialog-wrapper":"_xph-dialog-wrapper_o2yvb_23",dialog__header:"_dialog__header_o2yvb_45","dialog__header-btns":"_dialog__header-btns_o2yvb_63",dialog__main:"_dialog__main_o2yvb_71",dialog__footer:"_dialog__footer_o2yvb_85",dialog__resize:"_dialog__resize_o2yvb_99","dialog__resize-lt":"_dialog__resize-lt_o2yvb_113","dialog__resize-rt":"_dialog__resize-rt_o2yvb_125","dialog__resize-rb":"_dialog__resize-rb_o2yvb_137","dialog__resize-lb":"_dialog__resize-lb_o2yvb_149"},{useToken:$a}=S.theme,Ra=p.forwardRef((e,t)=>{console.log("render Dialog==============================================");const{token:r}=$a(),n={borderRadius:r.borderRadiusLG},{children:o,baseDialogProps:s,mask:a,title:i,renderFooter:c,renderTitle:u,getPopperContainer:f}=e,h=f(),[d,v]=Vr(!1),[g,y]=p.useState(!1),{open:w,close:j}=ma(d,e,v,y),{footerActions:E}=pa(e,g),D=p.useRef(null),z=p.useRef(null),N=p.useRef(null),q=p.useRef(null),{containerSizeTarget:G,parentInitRecord:x,initLeft:T,initTop:C,initWidth:P,initHeight:A,curPropsWidth:O,curPropsHeight:$,setParentInitRecord:I}=Pa({container:h,dialogProps:e,baseDialogProps:s}),{dialogChangeRecord:Q,setDialogChangeRecord:ne}=Ta(),{dialogWidth:ve,dialogHeight:pe,setDialogSize:ce}=ba({initWidth:P,initHeight:A,setDialogChangeRecord:ne}),{dialogLeft:B,dialogTop:H,setDialogPosition:Y}=va({initTop:C,initLeft:T,setDialogChangeRecord:ne}),{dialogMaxHeight:X,contentMaxHeight:It}=_a({visible:d,containerSizeTarget:G,dialogHeight:pe,dialogRef:D,dialogHeaderRef:z,dialogFooterRef:q}),{minResizeRecord:He,setMinResizeRecord:De}=Ea(),{minimizeLeft:Ae,minimizeTop:Ve,minimizeRef:ye,setMinimizePosition:lt}=wa(),{minimizeVisible:Ue,maximizeVisible:zt,setMaximizeVisible:Lt,onMaximize:Se,onMinimize:Pe,onRecovery:ct,onClose:Oe}=ya({containerSizeTarget:G,dialogChangeRecord:Q,close:j,setDialogSize:ce,setDialogPosition:Y}),$e=()=>{console.log("触发了initDialog"),ce({width:P.current,height:A.current}),Y({left:T.current,top:C.current}),lt({left:160,top:60}),Lt(!1),De(null)};p.useEffect(()=>{$e()},[x]),xa({initWidth:P,initHeight:A,curPropsWidth:O,curPropsHeight:$,setParentInitRecord:I}),Yr({containerSizeTarget:G,dialogHeaderRef:z,dialogRef:D,setDialogPosition:Y}),Yr({containerSizeTarget:G,dialogHeaderRef:ye,dialogRef:ye,setDialogPosition:lt});const{dialogTopShowClassConfig:Ye}=Ca({visible:d,container:h,dialogRef:D,minimizeRef:ye}),{resizingState:qe,DashedBox:Wt,onMousedownResizeLt:Nt,onMousedownResizeRt:ut,onMousedownResizeRb:ft,onMousedownResizeLb:Ee}=Sa({containerSizeTarget:G,dialogRef:D,minResizeRecord:He,setDialogSize:ce,setDialogPosition:Y,setMinResizeRecord:De});return p.useImperativeHandle(t,()=>({open:w,close:Oe,setLoading:y,getVisible:()=>d})),m.jsxs("div",{className:Ye.xphDialog,children:[a&&d?m.jsx("div",{className:re["xph-dialog-mask"]}):null,m.jsx(Oa,{visible:Ue,className:`${Ye.xphMinimizeDialog}`,loading:g,ref:ye,left:Ae,top:Ve,title:i,onMaximize:()=>Se("minimize"),onClosesquare:Oe}),m.jsxs("div",{ref:D,className:`${re["xph-dialog-wrapper"]} ${Ye.xphDialogWrapper}`,style:{display:d&&!Ue?"flex":"none",left:B,top:H,width:ve,height:pe,maxHeight:X,opacity:qe?.2:"unset",...n},children:[m.jsxs("div",{ref:z,className:re.dialog__header,children:[m.jsx("div",{children:u?u():i}),m.jsxs("div",{className:re["dialog__header-btns"],children:[m.jsx(ja,{onClick:Pe}),zt?m.jsx(Da,{onClick:ct}):m.jsx(qr,{onClick:()=>Se("maximize")}),m.jsx(Gr,{onClick:Oe,disabled:g})]})]}),m.jsx("div",{ref:N,className:re.dialog__main,style:{maxHeight:It},children:m.jsx(S.Spin,{spinning:g,children:d?o:null})}),c?m.jsx("div",{ref:q,children:c({loading:g})}):m.jsx("div",{ref:q,className:re.dialog__footer,children:m.jsx(st,{...E})}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lt"]}`,onMouseDown:Nt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rt"]}`,onMouseDown:ut}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rb"]}`,onMouseDown:ft}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lb"]}`,onMouseDown:Ee})]}),m.jsx(Wt,{})]})}),Ma=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=ga(n),{getPopperContainer:a}=s;return console.log("render XphDialog=============================================="),m.jsx(Kr,{getPopperContainer:a,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:{...le(le({auth:o=>!1},t),e)}}}const Ia=()=>{const{extendProps:e}=je();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 i=!1;return s&&o&&(te(s)?i=s.every(c=>o(c)):i=o(s)),i})()?t:null};function Rt(e){return"component"in e}function Mt(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 Wa(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 Na=["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)||Mt(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:a,ifShow:i}=e;let c=!0,u=!0;if(Ot(a)&&(c=a),Ot(i)&&(u=i),Z(a)){c=a({model:t});const f=Lr(n.current)?c:n.current;p.useEffect(()=>{nt(c,f)||s&&s()},[t])}if(Z(i)){u=i({model:t});const f=Lr(o.current)?u:o.current;p.useEffect(()=>{nt(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}},Ya=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:a}=e;let i=o;const c=Rt(e),u=c?La(e.component)+s:"";function f(g,y){const w=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(w):Promise.resolve()}const h=Z(a)?a({model:t}):a;h&&(!i||i.length===0?i=[{required:h,validator:f}]:i.findIndex(y=>Reflect.has(y,"required"))===-1&&i.push({required:h,validator:f}));const d=i.findIndex(g=>Reflect.has(g,"required")&&!Reflect.has(g,"validator"));if(d!==-1){const g=i[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 w=n.valueFormat;Wa(g,y,w)}}const v=i.findIndex(g=>g.max);return v!==-1&&!i[v].validator&&(i[v].message=i[v].message||`字符数应小于${i[v].max}位`),{rules:i}},qa=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Z(s)&&(o=s({model:r})),Ot(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=i=>(Object.keys(i).forEach(c=>{Object.defineProperty(i,c,{value:i[c],writable:!1,enumerable:!0,configurable:!1})}),i),n={};e.items.forEach(i=>{n[i.name]=i.initialValue});const o=Ba(t),s=o?S.Form.useWatch(i=>r(i)):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((a,i)=>{Wr(s,i,t[a.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(a=>{Wr(s,a.trim(),t[a.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],a="YYYY-MM-DD"]of r){if(!n||!o||!s)continue;if(!e[n]){Reflect.deleteProperty(e,n);continue}const[i,c]=e[n],[u,f]=Array.isArray(a)?a:[a,a];e[o]=Ge(i).format(u),e[s]=Ge(c).format(f),Reflect.deleteProperty(e,n)}return e}const rl=(e,t,r)=>{const n=e.filter(a=>a.name);return{handleFormatRenderValues:a=>{const i={},c=[];return n.forEach(u=>{const f=Reflect.has(a,u.name),h=Qa(u.name,a)||el(u.name,a);if(f||h){const d=h||a[u.name];if(Rt(u))if(Na.includes(u.component)){if(te(d)){const v=[];for(const g of d)v.push(g?Ge(g):null);i[u.name]=v}else i[u.name]=d?Ge(d):null;c.push(u.name)}else i[u.name]=d,c.push(u.name);Mt(u)&&(i[u.name]=d,c.push(u.name))}}),{renderValues:i,validKeys:c}},handleFormatReturnValues:a=>{var c,u,f,h,d;if(!se(a))return{};const i={};for(const v of Object.entries(a)){let[,g]=v;const[y]=v;if(!y||Z(g))continue;const{transformDateFunc:w}=t,j=(f=(u=(c=r.current)==null?void 0:c.get(y))==null?void 0:u.current)==null?void 0:f.componentProps,E=j==null?void 0:j.valueFormat;if(se(g)){const D=g;D.format&&(g=w==null?void 0:w(D,E))}te(g)&&((h=g[0])!=null&&h.format)&&((d=g[1])!=null&&d.format)&&(g=g.map(D=>w==null?void 0:w(D,E))),zr(g)&&(g===""?g=void 0:g=g.trim()),i[y]=g}return tl(i,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:{...le(le({collapseNum:5,colon:!1,items:[],labelWrap:!0,transformDateFunc:(o,s)=>{var a;return((a=o==null?void 0:o.format)==null?void 0:a.call(o,s||"YYYY-MM-DD HH:mm:ss"))??o},fieldMapToTime:[]},t),e)}}},it=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,a=p.useRef(!0),i=p.useRef(r),c=()=>{n&&Z(n)&&(r?n(r).then(o):n().then(o),i.current=r)};return p.useEffect(()=>{a.current&&(t&&c(),a.current=!1),!a.current&&s&&(nt(r,i.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 i;(i=t.current)==null||i.forEach(c=>{if(c.current){const{itemIndex:u}=c.current;u>=n&&r&&c.current.setItemCollapse(!0)}})},onClickCollapseToFalse:()=>{var i;(i=t.current)==null||i.forEach(c=>{if(c.current){const{itemCollapse:u}=c.current;u&&c.current.setItemCollapse(!1)}})}}},Jr=()=>{const{extendProps:e,extendComp:t}=je(),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,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.Select,{...h(),options:i,onDropdownVisibleChange:f})},al=e=>{console.log("render ApiTreeSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.TreeSelect,{...h(),treeData:i,onDropdownVisibleChange:f})},ll=e=>{console.log("render ApiTransfer");const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,a]=p.useState([]);it({api:t,params:r,apiCallback:a,isUseWatch:o});const i=()=>{const{api:c,params:u,isusewatch:f,...h}=e;return h};return m.jsx(S.Transfer,{...i(),dataSource:s})},cl=e=>{console.log("render ApiAutoComplete");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.AutoComplete,{...h(),options:i,onDropdownVisibleChange:f})},be={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},ul=e=>{console.log("render AutoUpload"),console.log(pt());const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:a=!1,data:i,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([]),w=x=>{v.current=x,y([...x])},j=()=>{const{api:x,maxCount:T,maxSize:C,openCrop:P,beforeUpload:A,fileList:O,returnType:$,...I}=e;return I},E=x=>{const T=x.size/1024/1024<o;T||S.message.error(`文件大小超过:${o}M, 请重试`);const C=v.current.length+d.current<n;return C||S.message.error(`文件数量不能超过${n}个`),T&&C&&d.current++,T&&C&&D(x),S.Upload.LIST_IGNORE},D=x=>{a?(S.message.error("暂时不支持裁剪功能,后续兼容。。。。"),z({file:x})):z({file:x})},z=x=>{r?r({file:x.file,...i}).then(T=>{w([...v.current,...T])}).finally(()=>{d.current--}):(Object.assign(x.file,{status:"done",url:URL.createObjectURL(new Blob([x.file],{type:Ha(x.file.type)}))}),w([...v.current,x.file]),d.current--)},N=x=>{const{file:T,fileList:C}=x,{status:P}=T;switch(P){case"removed":{w([...C]);break}}},q=x=>{const T=P=>{const A=P.split("/"),O=A[A.length-1],[$]=O.split("?");return $};return{uid:(P=>{const A=v.current.find(O=>O.url===P);return A?A.uid:pt()})(x),name:T(x),url:x,status:"done"}},G=()=>{switch(c){case be.String:return g.map(x=>x.url).join(",");case be["String[]"]:return g.map(x=>x.url);case be["File[]"]:return[...g];case be.FileList:return[...g]}};return p.useEffect(()=>{const x=G();if(nt(x,u))return;let T=[];switch(c){case be.String:{T=(u||"").split(",").filter(C=>C).map(C=>q(C));break}case be["String[]"]:{T=(u||[]).map(C=>q(C));break}case be["File[]"]:{T=(u||[]).map(C=>C);break}case be.FileList:{T=(u||[]).map(C=>C);break}}w(T)},[u]),p.useEffect(()=>{if(h.current){h.current=!1;return}const x=G();f==null||f(x)},[g]),m.jsx(S.Upload,{listType:s,...j(),fileList:g,beforeUpload:E,onChange:N,children:"上传"})},W=new Map;W.set("Input",S.Input),W.set("ApiSelect",il),W.set("Select",S.Select),W.set("InputNumber",S.InputNumber),W.set("ApiTreeSelect",al),W.set("TreeSelect",S.TreeSelect),W.set("ApiTransfer",ll),W.set("Transfer",S.Transfer),W.set("Switch",S.Switch),W.set("Button",S.Button),W.set("Radio",S.Radio),W.set("RadioGroup",S.Radio.Group),W.set("Checkbox",S.Checkbox),W.set("CheckboxGroup",S.Checkbox.Group),W.set("Cascader",S.Cascader),W.set("TimePicker",S.TimePicker),W.set("DatePicker",S.DatePicker),W.set("MonthPicker",S.DatePicker.MonthPicker),W.set("WeekPicker",S.DatePicker.WeekPicker),W.set("RangePicker",S.DatePicker.RangePicker),W.set("InputPassword",S.Input.Password),W.set("InputTextArea",S.Input.TextArea),W.set("ApiAutoComplete",cl),W.set("AutoComplete",S.AutoComplete),W.set("Upload",S.Upload),W.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:a,isusewatch:i}=Ja(n,t),{isIfShow:c,isShow:u}=Va(t,a,o),{colProps:f}=Xa(t,n),{componentProps:h}=Ga(t,a),{rules:d}=Ya({item:t,model:a,isShow:u,componentProps:h}),{disabled:v}=qa(n,t,a),{itemCollapse:g,setItemCollapse:y}=Ua(n,e),{name:w,label:j,wrapperCol:E,labelCol:D,valuePropName:z,initialValue:N,forceRow:q}=t;p.useImperativeHandle(s,()=>({itemIndex:e,componentProps:h,itemCollapse:g,setItemCollapse:y}));const G=()=>({name:w,label:j,rules:d,wrapperCol:E,labelCol:D,valuePropName:z,initialValue:N}),{setExtendFormComp:x}=Jr();x(W);const T=Rt(t),C=Mt(t),P=()=>{if(T){const A=W.get(t.component);return m.jsx(A,{...h,disabled:v,isusewatch:i.toString()})}return C?t.render({model:a,name:w,disabled:v,methods:r,componentProps:h}):null};return m.jsxs(p.Fragment,{children:[q?m.jsx("div",{className:Zr["form-item-force"]}):null,c?m.jsx(S.Col,{...f,className:u&&!g?void 0:Zr["form-item-hidden"],children:m.jsx(S.Form.Item,{...G(),children:P()})}):null]})}),dl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},pl=p.forwardRef(({collapsible:e,onClickExpand:t,onClickFold:r},n)=>{const[o,s]=p.useState(e),a=p.useMemo(()=>o,[o]),i=()=>{r(),s(!0)},c=()=>{t(),s(!1)};return p.useImperativeHandle(n,()=>({handleCollapseChangeFalse:c})),m.jsx("div",{className:dl["collapse-wrapper"],children:a?m.jsx(S.Button,{onClick:c,type:"link",icon:m.jsx(ue.DownOutlined,{}),children:"展开"}):m.jsx(S.Button,{onClick:i,type:"link",icon:m.jsx(ue.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]=S.Form.useForm(),{formProps:n}=ol(e),{formItems:o}=Ka({formProps:n}),s=p.useRef(new Map),{collapsible:a,collapseNum:i,collapseRef:c,onClickCollapseToFalse:u,onClickCollapseToTrue:f}=sl(n,s),{handleFormatRenderValues:h,handleFormatReturnValues:d}=rl(o,n,s),{setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:w,scrollToField:j}=nl(r,h,d),E=()=>{const{layout:z,wrapperCol:N,labelCol:q,colon:G,disabled:x,labelWrap:T,labelAlign:C,scrollToFirstError:P,size:A}=n;return{layout:z,wrapperCol:N,labelCol:q,colon:G,disabled:x,labelWrap:T,labelAlign:C,scrollToFirstError:P,size:A}},D={setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:w,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(S.Form,{form:r,...E(),children:[m.jsx(S.Row,{children:o.map((z,N)=>(s.current.has(z.name)||s.current.set(z.name,p.createRef()),m.jsx(fl,{ref:s.current.get(z.name),itemIndex:N,itemProps:z,formProps:n,methods:D,collapseRef:c},N)))}),m.jsxs("div",{className:ml["xph-form-action"],children:[m.jsx(hl,{formProps:n}),a?m.jsx(pl,{ref:c,collapsible:o.length>i,onClickExpand:u,onClickFold:f}):null]})]})},kt=p.forwardRef(bl),vl=p.memo(kt),yl=p.forwardRef((e,t)=>{const{renderActions:r,showSearch:n,tableRef:o}=e,[s,a]=p.useState(!1),i=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(S.Button,{type:"primary",icon:m.jsx(ue.SearchOutlined,{}),onClick:c,children:"搜索"}),m.jsx(S.Button,{icon:m.jsx(ue.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),h=()=>{const{renderActions:d,...v}=e;return{...v,renderActions:f}};return p.useImperativeHandle(t,()=>({setFormLoading:a,...i.current})),m.jsx(S.Spin,{spinning:s,children:m.jsx(vl,{ref:i,...h()})})}),_l=p.memo(kt),wl=(e,t)=>{const r=p.useRef(null),n=p.useRef(null),{formProps:o}=e,a=(()=>{const{formProps:f,...h}=e;return h})(),i=p.useRef(null),c=async()=>{const{onOk:f,renderFooter:h}=a;if(!h){const{ok:d,data:v}=i.current;if(d){n.current.validator().then(async g=>{r.current.setLoading(!0),await d({values:n.current.getFieldsValue()}).then(w=>w).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),i.current=null)});return}if(f){n.current.validator().then(async g=>{r.current.setLoading(!0),await f({values:g,data:v}).then(w=>(console.log(w),w)).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),i.current=null)});return}r.current.close(),i.current=null}},u=async()=>{const{onCancel:f,renderFooter:h}=a;if(!h){const{cancel:d,data:v}=i.current;if(d){if(await d({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),i.current=null;return}if(f){if(await f({values:n.current.getFieldsValue(!0),data:v})===!1)return;r.current.close(),i.current=null;return}r.current.close(),i.current=null}};return p.useImperativeHandle(t,()=>({open:async f=>{if(r.current.getVisible())return;const{renderFooter:d}=a;return!d&&(i.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,{...a,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}=S.theme,Pl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t,{url:s,onClick:a}=n,{token:i}=Sl(),c={color:i.colorLink,cursor:"pointer"},u=()=>{if(r.mainClick&&r.mainClick(),a){a();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(st,{...n})})},{useToken:jl}=S.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 a=`${String(t.dataIndex)}${o.value}`,i=(u=o.config)==null?void 0:u.color,c=i?r[i]??{color:i,backgroundColor:"unset",border:`1px solid ${i}`}:Dl[s]||{};return n[a]={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:a}=jl(),{enums:i}=n,c={primary:{color:a.colorPrimary,backgroundColor:a.colorPrimaryBg,border:`1px solid ${a.colorPrimary}`},success:{color:a.colorSuccess,backgroundColor:a.colorSuccessBg,border:`1px solid ${a.colorSuccess}`},warning:{color:a.colorWarning,backgroundColor:a.colorWarningBg,border:`1px solid ${a.colorWarning}`},info:{color:a.colorInfo,backgroundColor:a.colorInfoBg,border:`1px solid ${a.colorInfo}`},error:{color:a.colorError,backgroundColor:a.colorErrorBg,border:`1px solid ${a.colorError}`}},f=Al(i,s,c)[`${String(s.dataIndex)}${o}`]||{},h={padding:"0 8px",borderRadius:a.borderRadiusLG,fontSize:a.fontSizeSM,...f},d=()=>{var g;return(g=i.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++,a=en[r[s].component];a&&(n=a.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 a=Z(n),[i,c,u]=s,f={text:i,record:c,index:u,column:JSON.parse(JSON.stringify(o))},h=a?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:{...le(le({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),a=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:a},lastPaginationState:s}}function Il(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:a,responseFields:i}=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:T=>{var P;const C={...v.current,...T};d(C),v.current=C,(P=t.current)==null||P.setFormLoading(C.loading)}},y=async()=>{p.useEffect(()=>{const{autoRequest:T}=e.table,{validator:C}=t.current;T&&C().then(P=>{D({searchFormParams:P})})},[])},w=async({searchFormParams:T,paginationParams:C})=>{const P={...T,[`${a.current}`]:f.current.current,[`${a.pageSize}`]:f.current.pageSize,...C?{[`${a.current}`]:C.current,[`${a.pageSize}`]:C.pageSize}:{}};return r(P).then(A=>{const{current:O,list:$,total:I}=gt(i,A);g.update({dataSource:n?n($):$}),u.update({total:I,current:O,pageSize:P[`${a.pageSize}`]})}).finally(()=>{g.update({loading:!1})})},j=async({searchFormParams:T,paginationParams:C})=>{const P={...T};return r(P).then(A=>{const{list:O}=gt(i,A),$=n?n(O):O;g.update({selection:[],dataSource:$}),u.update({current:1,total:O.length})}).finally(()=>{g.update({loading:!1})})},E=async({searchFormParams:T,paginationParams:C})=>{var A;const P={...T};if(C){const{current:O,pageSize:$}=C;u.update({current:O,pageSize:$});const I=(O-1)*$,Q=I+$,ne=(A=v.current.backupsDataSource)==null?void 0:A.slice(I,Q);return g.update({loading:!1,selection:[],dataSource:ne})}else return r(P).then(O=>{let $=n?n(O):O;const I=[...$],Q=0,ne=Q+f.current.pageSize;$=$.slice(Q,ne),g.update({selection:[],dataSource:$,backupsDataSource:I}),u.update({current:1,total:O.length})}).finally(()=>{g.update({loading:!1})})},D=async({searchFormParams:T,paginationParams:C})=>{if(g.update({loading:!0,selection:[]}),r)switch(!!f.current){case!0:return o===!0?E({searchFormParams:T,paginationParams:C}):o===!1?j({searchFormParams:T,paginationParams:C}):w({searchFormParams:T,paginationParams:C});case!1:return j({searchFormParams:T,paginationParams:C})}return g.update({loading:!1})};return{table:g,pagination:u,firstGetTableData:y,onPaginationChange:(T,C)=>{const{validator:P}=t.current;P().then(A=>{D({searchFormParams:A,paginationParams:{current:T,pageSize:C}})}),c&&c(T,C)},onAllChange:async(...T)=>{const[C,P,A,O]=T,$=[];for(let I=0;I<$.length&&!$[I]();I++);s&&s(P,A,O)},resetData:async()=>{const{resetFields:T,validator:C}=t.current;return T().then(async()=>{const P=await C();return D({searchFormParams:P})})},resetAllData:async()=>{const{resetFields:T,validator:C}=t.current;return T().then(async()=>{const P={};if(f.current){const{pageSize:A}=f.current;o===void 0&&(P.paginationParams={current:1,pageSize:A})}return P.searchFormParams=await C(),D(P)})},reloadData:async()=>{const{validator:T}=t.current;return T().then(C=>D({searchFormParams:C}))}}}const zl=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(zr(n))return{type:n,onChange:(s,a,i)=>{t.update({selection:a}),r&&r(s,a)}};if(se(n)){const{onChange:s}=n;return{...n,onChange:(a,i,c)=>{t.update({selection:i}),s&&s(a,i,c),r&&r(a,i)}}}return n};return{rowSelection:o(),getNewRowSelection:o}};function Ll(e,t){const{scroll:r,virtual:n}=e.table,o=p.useRef(null),[s,a]=p.useState(0),[i,c]=p.useState(0),u=()=>{o.current&&(console.log("触发了table的handleResize"),a(o.current.offsetWidth),c(o.current.offsetHeight))};p.useEffect(()=>{const h=new ResizeObserver(u);return o.current&&h.observe(o.current),()=>{h&&o.current&&h.unobserve(o.current)}},[]);const f=p.useMemo(()=>t?n?{x:s,y:i-70,...r}:{x:"max-content",y:i-70,...r}:{x:"max-content",...r},[i]);return{divRef:o,scroll:f}}function Wl(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}=je(),r=n=>{const o=t==null?void 0:t.tableCellFunc;o&&Object.keys(o).forEach(s=>{const a=o[s];n[s]={Comp:a}})};return{extendTableProps:e==null?void 0:e.table,setExtendTableCellComp:r}},Nl=({crudFormDialog:e})=>({crudFormDialogRef:p.useRef(null),crudFormProps:e}),at={"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:a,pagination:i,firstGetTableData:c,onPaginationChange:u,onAllChange:f,resetData:h,resetAllData:d,reloadData:v}=Il(e,t),{rowSelection:g}=zl(e,a),{divRef:y,scroll:w}=Ll(e,r),{getTopToolbarBindProps:j}=Wl(e,a),E=()=>{const{autoRequest:D,api:z,formatDataSource:N,autoPagination:q,columns:G,scroll:x,pagination:T,rowSelection:C,onChange:P,...A}=e.table;return A};return c(),p.useImperativeHandle(n,()=>({resetData:h,resetAllData:d,reloadData:v,...s.current})),console.log("render Table"),m.jsxs("div",{className:r?at["main-container"]:void 0,children:[m.jsx("div",{className:at.container__toolbar,children:m.jsx(st,{...j()})}),m.jsx("div",{ref:y,className:r?at.container__table:void 0,children:m.jsx(S.Table,{ref:s,...E(),loading:a.model.loading,columns:o,dataSource:a.model.dataSource,pagination:!1,rowSelection:g,scroll:w,onChange:f})}),i.show?m.jsx("div",{className:at.container__pagination,children:m.jsx(S.Pagination,{disabled:a.model.loading,...i.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:a,crudFormProps:i}=Nl(r);let{fullHeight:c}=r.table;const{virtual:u}=r.table;return u&&(c=!0),p.useImperativeHandle(t,()=>({...n.current,...a.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})}),i?m.jsx(Qr,{ref:a,...i}):null]})},Vl=p.forwardRef(Hl);R.XphActions=st,R.XphAuth=za,R.XphCrudFormDialog=Qr,R.XphDialog=Xr,R.XphExtendCompPropsProvider=ua,R.XphForm=kt,R.XphPortal=Kr,R.XphTable=Vl,R.buildUUID=pt,R.getValueByPath=qt,R.getValuesByPathObj=gt,R.useAsyncState=Vr,R.useXphExtendCompProps=je,R.useXphForm=Za,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"})});
30
+ <%s key={someKey} {...props} />`,Yt,Fe,ac,Fe),pn[Fe+Yt]=!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;Ie.Fragment=n,Ie.jsx=sc,Ie.jsxs=ic}()),Ie}process.env.NODE_ENV==="production"?ht.exports=mn():ht.exports=bn();var m=ht.exports,Kt=typeof global=="object"&&global&&global.Object===Object&&global,vn=typeof self=="object"&&self&&self.Object===Object&&self,fe=Kt||vn||Function("return this")(),_e=fe.Symbol,Jt=Object.prototype,yn=Jt.hasOwnProperty,_n=Jt.toString,ze=_e?_e.toStringTag:void 0;function wn(e){var t=yn.call(e,ze),r=e[ze];try{e[ze]=void 0;var n=!0}catch{}var o=_n.call(e);return n&&(t?e[ze]=r:delete e[ze]),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 de(e){return e==null?e===void 0?Pn:Sn:Zt&&Zt in Object(e)?wn(e):Tn(e)}function ae(e){return e!=null&&typeof e=="object"}var En="[object Symbol]";function mt(e){return typeof e=="symbol"||ae(e)&&de(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(mt(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=de(e);return t==An||t==On||t==Dn||t==$n}var bt=fe["__core-js_shared__"],nr=function(){var e=/[^.]+$/.exec(bt&&bt.keys&&bt.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 Ce(e){if(e!=null){try{return kn.call(e)}catch{}try{return e+""}catch{}}return""}var In=/[\\^$.*+?()[\]{}|]/g,zn=/^\[object .+?Constructor\]$/,Ln=Function.prototype,Wn=Object.prototype,Nn=Ln.toString,Bn=Wn.hasOwnProperty,Hn=RegExp("^"+Nn.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(Ce(e))}function Un(e,t){return e==null?void 0:e[t]}function xe(e,t){var r=Un(e,t);return Vn(r)?r:void 0}var vt=xe(fe,"WeakMap"),or=Object.create,Yn=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 qn(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 Xe=function(){try{var e=xe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),eo=Xe?function(e,t){return Xe(e,"toString",{configurable:!0,enumerable:!1,value:Qn(t),writable:!0})}:rr,to=Zn(eo),ro=9007199254740991,no=/^(?:0|[1-9]\d*)$/;function yt(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 _t(e,t,r){t=="__proto__"&&Xe?Xe(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Le(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)&&Le(n,r))||r===void 0&&!(t in e))&&_t(e,t,r)}function io(e,t,r,n){var o=!r;r||(r={});for(var s=-1,a=t.length;++s<a;){var i=t[s],c=void 0;c===void 0&&(c=e[i]),o?_t(r,i,c):sr(r,i,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),a=Array(s);++o<s;)a[o]=n[t+o];o=-1;for(var i=Array(t+1);++o<t;)i[o]=n[o];return i[t]=r(a),qn(e,this,i)}}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 Ke(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"?Ke(r)&&yt(t,r.length):n=="string"&&t in r)?Le(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,a=o>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(o--,s):void 0,a&&uo(r[0],r[1],a)&&(s=o<3?void 0:s,o=1),t=Object(t);++n<o;){var i=r[n];i&&e(t,i,n,s)}return t})}var po=Object.prototype;function wt(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 ae(e)&&de(e)==ho}var cr=Object.prototype,mo=cr.hasOwnProperty,bo=cr.propertyIsEnumerable,Ct=lr(function(){return arguments}())?lr:function(e){return ae(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?fe.Buffer:void 0,_o=dr?dr.isBuffer:void 0,Je=_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]",Wo="[object Int32Array]",No="[object Uint8Array]",Bo="[object Uint8ClampedArray]",Ho="[object Uint16Array]",Vo="[object Uint32Array]",U={};U[ko]=U[Io]=U[zo]=U[Lo]=U[Wo]=U[No]=U[Bo]=U[Ho]=U[Vo]=!0,U[wo]=U[Co]=U[Ro]=U[xo]=U[Mo]=U[To]=U[So]=U[Po]=U[Eo]=U[Fo]=U[jo]=U[Do]=U[Ao]=U[Oo]=U[$o]=!1;function Uo(e){return ae(e)&&ar(e.length)&&!!U[de(e)]}function Yo(e){return function(t){return e(t)}}var pr=typeof R=="object"&&R&&!R.nodeType&&R,We=pr&&typeof module=="object"&&module&&!module.nodeType&&module,qo=We&&We.exports===pr,xt=qo&&Kt.process,gr=function(){try{var e=We&&We.require&&We.require("util").types;return e||xt&&xt.binding&&xt.binding("util")}catch{}}(),hr=gr&&gr.isTypedArray,Tt=hr?Yo(hr):Uo,Go=Object.prototype,Xo=Go.hasOwnProperty;function mr(e,t){var r=te(e),n=!r&&Ct(e),o=!r&&!n&&Je(e),s=!r&&!n&&!o&&Tt(e),a=r||n||o||s,i=a?go(e.length,String):[],c=i.length;for(var u in e)(t||Xo.call(e,u))&&!(a&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||yt(u,c)))&&i.push(u);return i}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(!wt(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 Ke(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=wt(e),r=[];for(var n in e)n=="constructor"&&(t||!ns.call(e,n))||r.push(n);return r}function vr(e){return Ke(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||mt(e)?!0:is.test(e)||!ss.test(e)||t!=null&&e in Object(t)}var Ne=xe(Object,"create");function ls(){this.__data__=Ne?Ne(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(Ne){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 Ne?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]=Ne&&t===void 0?bs:t,this}function Te(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])}}Te.prototype.clear=ls,Te.prototype.delete=cs,Te.prototype.get=ps,Te.prototype.has=ms,Te.prototype.set=vs;function ys(){this.__data__=[],this.size=0}function Ze(e,t){for(var r=e.length;r--;)if(Le(e[r][0],t))return r;return-1}var _s=Array.prototype,ws=_s.splice;function Cs(e){var t=this.__data__,r=Ze(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=Ze(t,e);return r<0?void 0:t[r][1]}function Ts(e){return Ze(this.__data__,e)>-1}function Ss(e,t){var r=this.__data__,n=Ze(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 Be=xe(fe,"Map");function Ps(){this.size=0,this.__data__={hash:new Te,map:new(Be||ge),string:new Te}}function Es(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Qe(e,t){var r=e.__data__;return Es(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Fs(e){var t=Qe(this,e).delete(e);return this.size-=t?1:0,t}function js(e){return Qe(this,e).get(e)}function Ds(e){return Qe(this,e).has(e)}function As(e,t){var r=Qe(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 St(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 a=e.apply(this,n);return r.cache=s.set(o,a)||s,a};return r.cache=new(St.Cache||he),r}St.Cache=he;var $s=500;function Rs(e){var t=St(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 Ws=1/0;function Ns(e){if(typeof e=="string"||mt(e))return e;var t=e+"";return t=="0"&&1/e==-Ws?"-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,Ys=Us.hasOwnProperty,qs=_r.call(Object);function Gs(e){if(!ae(e)||de(e)!=Hs)return!1;var t=yr(e);if(t===null)return!0;var r=Ys.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&_r.call(r)==qs}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(!Be||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?fe.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 a=e[r];t(a,r,e)&&(s[o++]=a)}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 Pt=xe(fe,"DataView"),Et=xe(fe,"Promise"),Ft=xe(fe,"Set"),Pr="[object Map]",ci="[object Object]",Er="[object Promise]",Fr="[object Set]",jr="[object WeakMap]",Dr="[object DataView]",ui=Ce(Pt),fi=Ce(Be),di=Ce(Et),pi=Ce(Ft),gi=Ce(vt),we=de;(Pt&&we(new Pt(new ArrayBuffer(1)))!=Dr||Be&&we(new Be)!=Pr||Et&&we(Et.resolve())!=Er||Ft&&we(new Ft)!=Fr||vt&&we(new vt)!=jr)&&(we=function(e){var t=de(e),r=t==ci?e.constructor:void 0,n=r?Ce(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 et=fe.Uint8Array;function hi(e){var t=new e.constructor(e.byteLength);return new et(t).set(new et(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"&&!wt(e)?Yn(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 tt(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new he;++t<r;)this.add(e[t])}tt.prototype.add=tt.prototype.push=yi,tt.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 a=r&xi,i=e.length,c=t.length;if(i!=c&&!(a&&c>i))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 tt:void 0;for(s.set(e,t),s.set(t,e);++h<i;){var g=e[h],y=t[h];if(n)var w=a?n(y,g,h,t,e,s):n(g,y,h,e,t,s);if(w!==void 0){if(w)continue;d=!1;break}if(v){if(!wi(t,function(j,E){if(!Ci(v,E)&&(g===j||o(g,j,r,n,s)))return v.push(E)})){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,jt=Or?Or.valueOf:void 0;function Wi(e,t,r,n,o,s,a){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 et(e),new et(t)));case ji:case Di:case $i:return Le(+e,+t);case Ai:return e.name==t.name&&e.message==t.message;case Ri:case ki:return e==t+"";case Oi:var i=Si;case Mi:var c=n&Ei;if(i||(i=Pi),e.size!=t.size&&!c)return!1;var u=a.get(e);if(u)return u==t;n|=Fi,a.set(e,t);var f=Ar(i(e),i(t),n,o,s,a);return a.delete(e),f;case Ii:if(jt)return jt.call(e)==jt.call(t)}return!1}var Ni=1,Bi=Object.prototype,Hi=Bi.hasOwnProperty;function Vi(e,t,r,n,o,s){var a=r&Ni,i=Sr(e),c=i.length,u=Sr(t),f=u.length;if(c!=f&&!a)return!1;for(var h=c;h--;){var d=i[h];if(!(a?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 w=a;++h<c;){d=i[h];var j=e[d],E=t[d];if(n)var D=a?n(E,j,d,t,e,s):n(j,E,d,e,t,s);if(!(D===void 0?j===E||o(j,E,r,n,s):D)){y=!1;break}w||(w=d=="constructor")}if(y&&!w){var z=e.constructor,N=t.constructor;z!=N&&"constructor"in e&&"constructor"in t&&!(typeof z=="function"&&z instanceof z&&typeof N=="function"&&N instanceof N)&&(y=!1)}return s.delete(e),s.delete(t),y}var Ui=1,$r="[object Arguments]",Rr="[object Array]",rt="[object Object]",Yi=Object.prototype,Mr=Yi.hasOwnProperty;function qi(e,t,r,n,o,s){var a=te(e),i=te(t),c=a?Rr:we(e),u=i?Rr:we(t);c=c==$r?rt:c,u=u==$r?rt:u;var f=c==rt,h=u==rt,d=c==u;if(d&&Je(e)){if(!Je(t))return!1;a=!0,f=!1}if(d&&!f)return s||(s=new me),a||Tt(e)?Ar(e,t,r,n,o,s):Wi(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,w=g?t.value():t;return s||(s=new me),o(y,w,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||!ae(e)&&!ae(t)?e!==e&&t!==t:qi(e,t,r,n,kr,o)}function Gi(e){return function(t,r,n){for(var o=-1,s=Object(t),a=n(t),i=a.length;i--;){var c=a[++o];if(r(s[c],c,s)===!1)break}return t}}var Xi=Gi();function Dt(e,t,r){(r!==void 0&&!Le(e[t],r)||r===void 0&&!(t in e))&&_t(e,t,r)}function Ki(e){return ae(e)&&Ke(e)}function At(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,a){var i=At(e,r),c=At(t,r),u=a.get(c);if(u){Dt(e,r,u);return}var f=s?s(i,c,r+"",e,t,a):void 0,h=f===void 0;if(h){var d=te(c),v=!d&&Je(c),g=!d&&!v&&Tt(c);f=c,d||v||g?te(i)?f=i:Ki(i)?f=Gn(i):v?(h=!1,f=ri(c)):g?(h=!1,f=mi(c)):f=[]:Gs(c)||Ct(c)?(f=i,Ct(i)?f=Ji(i):(!se(i)||Z(i))&&(f=bi(c))):h=!1}h&&(a.set(c,f),o(f,c,n,s,a),a.delete(c)),Dt(e,r,f)}function Ir(e,t,r,n,o){e!==t&&Xi(t,function(s,a){if(o||(o=new me),se(s))Zi(e,t,a,r,Ir,n,o);else{var i=n?n(At(e,a),s,a+"",e,t,o):void 0;i===void 0&&(i=s),Dt(e,a,i)}},vr)}var Qi="[object String]";function zr(e){return typeof e=="string"||!te(e)&&ae(e)&&de(e)==Qi}var ea="[object Boolean]";function Ot(e){return e===!0||e===!1||ae(e)&&de(e)==ea}function nt(e,t){return kr(e,t)}var ta="[object Number]";function ra(e){return typeof e=="number"||ae(e)&&de(e)==ta}function Lr(e){return e==null}function na(e){return e===null}var le=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,a=s-1,i=e;i!=null&&++o<s;){var c=Ns(t[o]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(o!=a){var f=i[c];u=void 0,u===void 0&&(u=se(f)?f:yt(t[o+1])?[]:{})}sr(i,c,u),i=i[c]}return e}function Wr(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={...le(le({items:[],max:10},t?r:{}),e)},a={...le({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:a}}function Nr(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,a=h=>{const{auth:d}=h;let v=!1;return d?te(d)?v=d.every(g=>t(g)):v=t(d):v=!0,v},i=h=>{let{ifShow:d=!0}=h;return d=d&&Z(d)?d():d,d&&a(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(Nr(d)){const v=d.component;switch(d.componentProps={type:r,disabled:n,...d.componentProps},v){case"Dropdown":{d.componentProps.dropDownItems=(d.componentProps.dropDownItems||[]).filter(i);break}}}return d}).filter(i).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(S.Button,{...r()})},ca=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...a}=t;return a})();return m.jsx(S.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(S.Button,{...n,children:[n.children,m.jsx(ue.CaretDownOutlined,{})]})})})},ot=new Map;ot.set("Button",la),ot.set("Dropdown",ca);function Br(){const{setExtendActionsComp:e}=Ur();return e(ot),{renderContent:p.useCallback((r,n)=>{const o=Nr(r),s=ia(r);if(o){const a=ot.get(r.component);return p.createElement(a,{...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})},je=()=>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((a,i)=>{r(c=>{const u=typeof s=="function"?s(c):s;return n.current=a,u})})]},Ur=()=>{const{extendProps:e,extendComp:t}=je(),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}=S.theme,da=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Br(),{token:s}=fa(),a={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},i=()=>m.jsx("div",{style:a,children:m.jsx(S.Space,{style:{padding:8},children:e==null?void 0:e.map((c,u)=>o(c,u))})});return m.jsx(S.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:i,trigger:["click"],children:m.jsxs(S.Button,{type:r,children:["更多",m.jsx(ue.CaretDownOutlined,{})]})})},st=e=>{const{actionsProps:t,authProps:r}=sa(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=aa(t,n),{renderContent:a}=Br();return t!=null&&t.render?t.render:m.jsxs(p.Fragment,{children:[o==null?void 0:o.map((i,c)=>a(i,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:a,cancelProps:i}=e;return{footerActions:{disabled:t,max:2,items:[{component:"Button",componentProps:{...i,children:n,onClick:o}},{component:"Button",componentProps:{type:"primary",loading:t,...a,children:r,onClick:s}}]}}}const ga=e=>{const{extendDialogProps:t}=ha(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body},n={...le(le(r,t),e)};return{dialogProps:{...n,getPopperContainer:()=>{const s=n.getPopperContainer();return n.mask?document.body:s}},baseDialogProps:r}},ha=()=>{const{extendProps:e}=je();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,a]=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&&a(u)}}},va=({initLeft:e,initTop:t,setDialogChangeRecord:r})=>{const[n,o]=p.useState(e.current),[s,a]=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&&a(u)}}},Yr=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=p.useRef(0),s=p.useRef(0),a=f=>{const h=f.getBoundingClientRect(),d=h.width,v=h.height,g=-.5*d,y=-.5*v;return{translateX:g,translateY:y}},i=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}=a(h);let g=f.clientX-o.current,y=f.clientY-s.current;const w=-d,j=-v,E=e.current.scrollWidth-h.offsetWidth-d,D=e.current.scrollHeight-h.offsetHeight-v;g<w&&(g=w),g>E&&(g=E),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",i),()=>{f.removeEventListener("mousedown",i)}},[]),{}},ya=({containerSizeTarget:e,dialogChangeRecord:t,close:r,setDialogSize:n,setDialogPosition:o})=>{const[s,a]=p.useState(!1),[i,c]=p.useState(!1);return{minimizeVisible:s,maximizeVisible:i,setMinimizeVisible:a,setMaximizeVisible:c,onMinimize:()=>{a(!0)},onMaximize:v=>{if(v==="minimize"&&a(!1),v==="maximize"){const{scrollWidth:g,scrollHeight:y}=e.current,w=Math.floor(g),j=Math.floor(y),E=Math.floor(g/2),D=Math.floor(y/2);n({width:w,height:j}),o({top:D,left:E}),c(!0)}},onRecovery:()=>{const{top:v,left:g,width:y,height:w}=t.current;n({width:y,height:w}),o({top:v,left:g}),c(!1)},onClose:()=>{a(!1),c(!1),r()}}},_a=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:a,scrollHeight:i}=t.current,[c,u]=p.useState(0),[f,h]=p.useState("unset"),d=(v,g)=>{var N,q;const j=(N=o.current)==null?void 0:N.offsetHeight,E=(q=s.current)==null?void 0:q.offsetHeight;let D=v-j-E-0;const z=g-j-E-0;return D>z&&(D=z),D};return p.useEffect(()=>{var v;if(c===a){console.log("触发了dialogMaxHeight改变");const g=(v=n.current)==null?void 0:v.getBoundingClientRect().height;h(d(g,a)),u("unset")}},[c]),p.useEffect(()=>{r!=="unset"&&r!==0&&(console.log("触发了重新设置contentMaxHeight",r),h(d(r,r>a?i:a)),u("unset"))},[r]),p.useEffect(()=>{e?u(a):(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:a,top:i})=>{a!==void 0&&t(a),i!==void 0&&n(i)}}},Ca=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=(i,c)=>{console.log("触发插入"),i.querySelector(`.${o.xphDialogWrapper}`).style.opacity="unset",i.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(i,u),c.parentNode.removeChild(u)},a=i=>{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),i)){const d=i.target;d.tagName==="INPUT"&&d.focus&&d.focus()}};return p.useEffect(()=>{var i,c;return(i=t.current)==null||i.addEventListener("mousedown",a,!1),(c=r.current)==null||c.addEventListener("mousedown",a,!1),()=>{var u,f;(u=t.current)==null||u.removeEventListener("mousedown",a,!1),(f=r.current)==null||f.removeEventListener("mousedown",a,!1)}},[]),p.useEffect(()=>{if(e)a();else{const i=Array.from(n.querySelectorAll(`.${o.xphDialog}`)),c=i.map(d=>d.querySelector(`.${o.xphDialogWrapper}`)).filter(d=>d!==null),u=i.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,i[i.length-1]);return}if(h.length){s(h[h.length-1].parentNode,i[i.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},xa=({initWidth:e,initHeight:t,curPropsWidth:r,curPropsHeight:n,setParentInitRecord:o})=>{p.useEffect(()=>{if(r!==e.current){console.log("动态设置了宽度"),o(s=>s+1);return}if(n!==t.current){console.log("动态设置了高度"),o(s=>s+1);return}},[r,n])},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:a,top:i,width:c,height:u}=e.current;e.current={left:r??a,top:n??i,width:o??c,height:s??u}}}},Sa=({containerSizeTarget:e,dialogRef:t,minResizeRecord:r,setDialogSize:n,setDialogPosition:o,setMinResizeRecord:s})=>{const a=p.useCallback(()=>m.jsx("div",{ref:i,style:{position:"absolute",border:"4px dashed #ccc",display:"none"}}),[]),i=p.useRef(null),c=p.useRef(),u=p.useRef(!1),[f,h]=p.useState(!1),d=p.useRef(0),v=p.useRef(0),g=(x,T)=>{r.current||s({width:t.current.offsetWidth,height:t.current.offsetHeight}),u.current=!0,h(!0),c.current=T;const{clientX:C,clientY:P}=x;d.current=C,v.current=P;const A=parseFloat(t.current.style.left),O=parseFloat(t.current.style.top),$=t.current.offsetWidth,I=t.current.offsetHeight;i.current.style.display="block",i.current.style.left=`${A-.5*$}px`,i.current.style.top=`${O-.5*I}px`,i.current.style.width=`${$}px`,i.current.style.height=`${I}px`},y=x=>{if(u.current){const{clientX:T,clientY:C}=x,P=T-d.current,A=C-v.current,O=parseFloat(i.current.style.left),$=parseFloat(i.current.style.top),I=i.current.offsetWidth,Q=i.current.offsetHeight,ne=r.current.width,ve=r.current.height,pe=e.current.scrollWidth,ce=e.current.scrollHeight;let B=I,H=Q,Y=O,X=$;switch(c.current){case"lt":{B=B-P,H=H-A,X=X+A,Y=Y+P,B<ne&&(B=I,Y=O),H<ve&&(H=Q,X=$),Y<0&&(Y=0,B=I),X<0&&(X=0,H=Q);break}case"rt":{B=B+P,H=H-A,X=X+A,Y=O,B<ne&&(B=I),H<ve&&(H=Q,X=$),B>pe-Y&&(B=pe-Y),X<0&&(X=0,H=Q);break}case"rb":{B=B+P,H=H+A,X=$,Y=O,B<ne&&(B=I),H<ve&&(H=Q),B>pe-Y&&(B=pe-Y),H>ce-X&&(H=ce-X);break}case"lb":{B=B-P,H=H+A,X=$,Y=Y+P,B<ne&&(B=I,Y=O),H<ve&&(H=Q),Y<0&&(Y=0,B=I),H>ce-X&&(H=ce-X);break}}i.current.style.left=`${Y}px`,i.current.style.top=`${X}px`,i.current.style.width=`${B}px`,i.current.style.height=`${H}px`,d.current=T,v.current=C}},w=()=>{if(u.current){u.current=!1,h(!1),i.current.style.display="none";const{left:x,top:T,width:C,height:P}=i.current.style,A=parseFloat(x)+.5*parseFloat(C),O=parseFloat(T)+.5*parseFloat(P),$=parseFloat(C),I=parseFloat(P);o({left:A,top:O}),n({width:$,height:I})}},j=x=>g(x,"lt"),E=x=>g(x,"rt"),D=x=>g(x,"rb"),z=x=>g(x,"lb"),N=p.useCallback(x=>{y(x)},[]),q=p.useCallback(()=>{w()},[]),G=p.useCallback(()=>{w()},[]);return p.useEffect(()=>(document.body.addEventListener("mousemove",N),document.body.addEventListener("mouseup",q),document.body.addEventListener("mouseleave",G),()=>{document.body.removeEventListener("mousemove",N),document.body.removeEventListener("mouseup",q),document.body.removeEventListener("mouseleave",G)}),[]),{resizingState:f,DashedBox:a,onMousedownResizeLt:j,onMousedownResizeRt:E,onMousedownResizeRb:D,onMousedownResizeLb:z}},Pa=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=p.useState(0),s=()=>{o(x=>x+1)};p.useEffect(()=>(window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}),[]);const{containerSizeTarget:a,setContainerSizeTarget:i}=Fa({container:e}),{width:c,height:u}=r,{width:f,height:h}=t,d=f||c,v=h||u,{clientWidth:g,clientHeight:y}=a.current,w=d?d>g?g:d:0,j=v?v>y?y:v:"unset",E=p.useRef(w),D=p.useRef(j),z=x=>{E.current=x.width,D.current=x.height},N=p.useRef(Math.floor(g/2)),q=p.useRef(Math.floor(y/2)),G=x=>{N.current=x.left,q.current=x.top};return p.useEffect(()=>{i(),z({width:w,height:j}),G({left:Math.floor(g/2),top:Math.floor(y/2)})},[n]),{containerSizeTarget:a,parentInitRecord:n,initLeft:N,initTop:q,initWidth:E,initHeight:D,curPropsWidth:w,curPropsHeight:j,setInitPosition:G,setInitSize:z,setParentInitRecord:o}},Ea=()=>{const e=p.useRef(null);return{minResizeRecord:e,setMinResizeRecord:r=>{e.current=r}}},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}}}},$t={"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(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.ShrinkOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),qr=({onClick:e})=>m.jsx(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.FullscreenOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Da=({onClick:e})=>m.jsx(S.Button,{type:"link",onClick:e,icon:m.jsx(ue.FullscreenExitOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Gr=({onClick:e,disabled:t})=>m.jsx(S.Button,{type:"link",onClick:e,disabled:t,icon:m.jsx(ue.CloseOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),{useToken:Aa}=S.theme,Oa=p.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:a,className:i},c)=>{const{token:u}=Aa(),f={borderRadius:u.borderRadiusLG};return m.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...f},className:`${$t["minimize-windows"]} ${i}`,ref:c,children:[m.jsx("div",{className:$t["minimize-windows-title"],title:e,children:e}),m.jsxs("div",{className:$t["minimize-windows-operate"],children:[m.jsx(qr,{onClick:s}),m.jsx(Gr,{onClick:a,disabled:o})]})]})}),re={"xph-dialog-mask":"_xph-dialog-mask_o2yvb_1","xph-dialog-wrapper":"_xph-dialog-wrapper_o2yvb_23",dialog__header:"_dialog__header_o2yvb_45","dialog__header-btns":"_dialog__header-btns_o2yvb_63",dialog__main:"_dialog__main_o2yvb_71",dialog__footer:"_dialog__footer_o2yvb_85",dialog__resize:"_dialog__resize_o2yvb_99","dialog__resize-lt":"_dialog__resize-lt_o2yvb_113","dialog__resize-rt":"_dialog__resize-rt_o2yvb_125","dialog__resize-rb":"_dialog__resize-rb_o2yvb_137","dialog__resize-lb":"_dialog__resize-lb_o2yvb_149"},{useToken:$a}=S.theme,Ra=p.forwardRef((e,t)=>{console.log("render Dialog==============================================");const{token:r}=$a(),n={borderRadius:r.borderRadiusLG},{children:o,baseDialogProps:s,mask:a,title:i,renderFooter:c,renderTitle:u,getPopperContainer:f}=e,h=f(),[d,v]=Vr(!1),[g,y]=p.useState(!1),{open:w,close:j}=ma(d,e,v,y),{footerActions:E}=pa(e,g),D=p.useRef(null),z=p.useRef(null),N=p.useRef(null),q=p.useRef(null),{containerSizeTarget:G,parentInitRecord:x,initLeft:T,initTop:C,initWidth:P,initHeight:A,curPropsWidth:O,curPropsHeight:$,setParentInitRecord:I}=Pa({container:h,dialogProps:e,baseDialogProps:s}),{dialogChangeRecord:Q,setDialogChangeRecord:ne}=Ta(),{dialogWidth:ve,dialogHeight:pe,setDialogSize:ce}=ba({initWidth:P,initHeight:A,setDialogChangeRecord:ne}),{dialogLeft:B,dialogTop:H,setDialogPosition:Y}=va({initTop:C,initLeft:T,setDialogChangeRecord:ne}),{dialogMaxHeight:X,contentMaxHeight:It}=_a({visible:d,containerSizeTarget:G,dialogHeight:pe,dialogRef:D,dialogHeaderRef:z,dialogFooterRef:q}),{minResizeRecord:He,setMinResizeRecord:De}=Ea(),{minimizeLeft:Ae,minimizeTop:Ve,minimizeRef:ye,setMinimizePosition:lt}=wa(),{minimizeVisible:Ue,maximizeVisible:zt,setMaximizeVisible:Lt,onMaximize:Se,onMinimize:Pe,onRecovery:ct,onClose:Oe}=ya({containerSizeTarget:G,dialogChangeRecord:Q,close:j,setDialogSize:ce,setDialogPosition:Y}),$e=()=>{console.log("触发了initDialog"),ce({width:P.current,height:A.current}),Y({left:T.current,top:C.current}),lt({left:160,top:60}),Lt(!1),De(null)};p.useEffect(()=>{$e()},[x]),xa({initWidth:P,initHeight:A,curPropsWidth:O,curPropsHeight:$,setParentInitRecord:I}),Yr({containerSizeTarget:G,dialogHeaderRef:z,dialogRef:D,setDialogPosition:Y}),Yr({containerSizeTarget:G,dialogHeaderRef:ye,dialogRef:ye,setDialogPosition:lt});const{dialogTopShowClassConfig:Ye}=Ca({visible:d,container:h,dialogRef:D,minimizeRef:ye}),{resizingState:qe,DashedBox:Wt,onMousedownResizeLt:Nt,onMousedownResizeRt:ut,onMousedownResizeRb:ft,onMousedownResizeLb:Ee}=Sa({containerSizeTarget:G,dialogRef:D,minResizeRecord:He,setDialogSize:ce,setDialogPosition:Y,setMinResizeRecord:De});return p.useImperativeHandle(t,()=>({open:w,close:Oe,setLoading:y,getVisible:()=>d})),m.jsxs("div",{className:Ye.xphDialog,children:[a&&d?m.jsx("div",{className:re["xph-dialog-mask"]}):null,m.jsx(Oa,{visible:Ue,className:`${Ye.xphMinimizeDialog}`,loading:g,ref:ye,left:Ae,top:Ve,title:i,onMaximize:()=>Se("minimize"),onClosesquare:Oe}),m.jsxs("div",{ref:D,className:`${re["xph-dialog-wrapper"]} ${Ye.xphDialogWrapper}`,style:{display:d&&!Ue?"flex":"none",left:B,top:H,width:ve,height:pe,maxHeight:X,opacity:qe?.2:"unset",...n},children:[m.jsxs("div",{ref:z,className:re.dialog__header,children:[m.jsx("div",{children:u?u():i}),m.jsxs("div",{className:re["dialog__header-btns"],children:[m.jsx(ja,{onClick:Pe}),zt?m.jsx(Da,{onClick:ct}):m.jsx(qr,{onClick:()=>Se("maximize")}),m.jsx(Gr,{onClick:Oe,disabled:g})]})]}),m.jsx("div",{ref:N,className:re.dialog__main,style:{maxHeight:It},children:m.jsx(S.Spin,{spinning:g,children:d?o:null})}),c?m.jsx("div",{ref:q,children:c({loading:g})}):m.jsx("div",{ref:q,className:re.dialog__footer,children:m.jsx(st,{...E})}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lt"]}`,onMouseDown:Nt}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rt"]}`,onMouseDown:ut}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-rb"]}`,onMouseDown:ft}),m.jsx("div",{className:`${re.dialog__resize} ${re["dialog__resize-lb"]}`,onMouseDown:Ee})]}),m.jsx(Wt,{})]})}),Ma=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=ga(n),{getPopperContainer:a}=s;return console.log("render XphDialog=============================================="),m.jsx(Kr,{getPopperContainer:a,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:{...le(le({auth:o=>!1},t),e)}}}const Ia=()=>{const{extendProps:e}=je();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 i=!1;return s&&o&&(te(s)?i=s.every(c=>o(c)):i=o(s)),i})()?t:null};function Rt(e){return"component"in e}function Mt(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 Wa(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 Na=["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)||Mt(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:a,ifShow:i}=e;let c=!0,u=!0;if(Ot(a)&&(c=a),Ot(i)&&(u=i),Z(a)){c=a({model:t});const f=Lr(n.current)?c:n.current;p.useEffect(()=>{nt(c,f)||s&&s()},[t])}if(Z(i)){u=i({model:t});const f=Lr(o.current)?u:o.current;p.useEffect(()=>{nt(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}},Ya=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:a}=e;let i=o;const c=Rt(e),u=c?La(e.component)+s:"";function f(g,y){const w=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(w):Promise.resolve()}const h=Z(a)?a({model:t}):a;h&&(!i||i.length===0?i=[{required:h,validator:f}]:i.findIndex(y=>Reflect.has(y,"required"))===-1&&i.push({required:h,validator:f}));const d=i.findIndex(g=>Reflect.has(g,"required")&&!Reflect.has(g,"validator"));if(d!==-1){const g=i[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 w=n.valueFormat;Wa(g,y,w)}}const v=i.findIndex(g=>g.max);return v!==-1&&!i[v].validator&&(i[v].message=i[v].message||`字符数应小于${i[v].max}位`),{rules:i}},qa=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Z(s)&&(o=s({model:r})),Ot(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=i=>(Object.keys(i).forEach(c=>{Object.defineProperty(i,c,{value:i[c],writable:!1,enumerable:!0,configurable:!1})}),i),n={};e.items.forEach(i=>{n[i.name]=i.initialValue});const o=Ba(t),s=o?S.Form.useWatch(i=>r(i)):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((a,i)=>{Wr(s,i,t[a.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(a=>{Wr(s,a.trim(),t[a.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],a="YYYY-MM-DD"]of r){if(!n||!o||!s)continue;if(!e[n]){Reflect.deleteProperty(e,n);continue}const[i,c]=e[n],[u,f]=Array.isArray(a)?a:[a,a];e[o]=Ge(i).format(u),e[s]=Ge(c).format(f),Reflect.deleteProperty(e,n)}return e}const rl=(e,t,r)=>{const n=e.filter(a=>a.name);return{handleFormatRenderValues:a=>{const i={},c=[];return n.forEach(u=>{const f=Reflect.has(a,u.name),h=Qa(u.name,a)||el(u.name,a);if(f||h){const d=h||a[u.name];if(Rt(u))if(Na.includes(u.component)){if(te(d)){const v=[];for(const g of d)v.push(g?Ge(g):null);i[u.name]=v}else i[u.name]=d?Ge(d):null;c.push(u.name)}else i[u.name]=d,c.push(u.name);Mt(u)&&(i[u.name]=d,c.push(u.name))}}),{renderValues:i,validKeys:c}},handleFormatReturnValues:a=>{var c,u,f,h,d;if(!se(a))return{};const i={};for(const v of Object.entries(a)){let[,g]=v;const[y]=v;if(!y||Z(g))continue;const{transformDateFunc:w}=t,j=(f=(u=(c=r.current)==null?void 0:c.get(y))==null?void 0:u.current)==null?void 0:f.componentProps,E=j==null?void 0:j.valueFormat;if(se(g)){const D=g;D.format&&(g=w==null?void 0:w(D,E))}te(g)&&((h=g[0])!=null&&h.format)&&((d=g[1])!=null&&d.format)&&(g=g.map(D=>w==null?void 0:w(D,E))),zr(g)&&(g===""?g=void 0:g=g.trim()),i[y]=g}return tl(i,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:{...le(le({collapseNum:5,colon:!1,items:[],labelWrap:!0,transformDateFunc:(o,s)=>{var a;return((a=o==null?void 0:o.format)==null?void 0:a.call(o,s||"YYYY-MM-DD HH:mm:ss"))??o},fieldMapToTime:[]},t),e)}}},it=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,a=p.useRef(!0),i=p.useRef(r),c=()=>{n&&Z(n)&&(r?n(r).then(o):n().then(o),i.current=r)};return p.useEffect(()=>{a.current&&(t&&c(),a.current=!1),!a.current&&s&&(nt(r,i.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 i;(i=t.current)==null||i.forEach(c=>{if(c.current){const{itemIndex:u}=c.current;u>=n&&r&&c.current.setItemCollapse(!0)}})},onClickCollapseToFalse:()=>{var i;(i=t.current)==null||i.forEach(c=>{if(c.current){const{itemCollapse:u}=c.current;u&&c.current.setItemCollapse(!1)}})}}},Jr=()=>{const{extendProps:e,extendComp:t}=je(),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,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.Select,{...h(),options:i,onDropdownVisibleChange:f})},al=e=>{console.log("render ApiTreeSelect");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.TreeSelect,{...h(),treeData:i,onDropdownVisibleChange:f})},ll=e=>{console.log("render ApiTransfer");const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,a]=p.useState([]);it({api:t,params:r,apiCallback:a,isUseWatch:o});const i=()=>{const{api:c,params:u,isusewatch:f,...h}=e;return h};return m.jsx(S.Transfer,{...i(),dataSource:s})},cl=e=>{console.log("render ApiAutoComplete");const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=it({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),f=d=>{d&&!n&&u(),s&&s(d)},h=()=>{const{api:d,params:v,immediate:g,isusewatch:y,...w}=e;return w};return m.jsx(S.AutoComplete,{...h(),options:i,onDropdownVisibleChange:f})},be={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},ul=e=>{console.log("render AutoUpload"),console.log(pt());const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:a=!1,data:i,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([]),w=x=>{v.current=x,y([...x])},j=()=>{const{api:x,maxCount:T,maxSize:C,openCrop:P,beforeUpload:A,fileList:O,returnType:$,...I}=e;return I},E=x=>{const T=x.size/1024/1024<o;T||S.message.error(`文件大小超过:${o}M, 请重试`);const C=v.current.length+d.current<n;return C||S.message.error(`文件数量不能超过${n}个`),T&&C&&d.current++,T&&C&&D(x),S.Upload.LIST_IGNORE},D=x=>{a?(S.message.error("暂时不支持裁剪功能,后续兼容。。。。"),z({file:x})):z({file:x})},z=x=>{r?r({file:x.file,...i}).then(T=>{w([...v.current,...T])}).finally(()=>{d.current--}):(Object.assign(x.file,{status:"done",url:URL.createObjectURL(new Blob([x.file],{type:Ha(x.file.type)}))}),w([...v.current,x.file]),d.current--)},N=x=>{const{file:T,fileList:C}=x,{status:P}=T;switch(P){case"removed":{w([...C]);break}}},q=x=>{const T=P=>{const A=P.split("/"),O=A[A.length-1],[$]=O.split("?");return $};return{uid:(P=>{const A=v.current.find(O=>O.url===P);return A?A.uid:pt()})(x),name:T(x),url:x,status:"done"}},G=()=>{switch(c){case be.String:return g.map(x=>x.url).join(",");case be["String[]"]:return g.map(x=>x.url);case be["File[]"]:return[...g];case be.FileList:return[...g]}};return p.useEffect(()=>{const x=G();if(nt(x,u))return;let T=[];switch(c){case be.String:{T=(u||"").split(",").filter(C=>C).map(C=>q(C));break}case be["String[]"]:{T=(u||[]).map(C=>q(C));break}case be["File[]"]:{T=(u||[]).map(C=>C);break}case be.FileList:{T=(u||[]).map(C=>C);break}}w(T)},[u]),p.useEffect(()=>{if(h.current){h.current=!1;return}const x=G();f==null||f(x)},[g]),m.jsx(S.Upload,{listType:s,...j(),fileList:g,beforeUpload:E,onChange:N,children:"上传"})},W=new Map;W.set("Input",S.Input),W.set("ApiSelect",il),W.set("Select",S.Select),W.set("InputNumber",S.InputNumber),W.set("ApiTreeSelect",al),W.set("TreeSelect",S.TreeSelect),W.set("ApiTransfer",ll),W.set("Transfer",S.Transfer),W.set("Switch",S.Switch),W.set("Button",S.Button),W.set("Radio",S.Radio),W.set("RadioGroup",S.Radio.Group),W.set("Checkbox",S.Checkbox),W.set("CheckboxGroup",S.Checkbox.Group),W.set("Cascader",S.Cascader),W.set("TimePicker",S.TimePicker),W.set("DatePicker",S.DatePicker),W.set("MonthPicker",S.DatePicker.MonthPicker),W.set("WeekPicker",S.DatePicker.WeekPicker),W.set("RangePicker",S.DatePicker.RangePicker),W.set("InputPassword",S.Input.Password),W.set("InputTextArea",S.Input.TextArea),W.set("ApiAutoComplete",cl),W.set("AutoComplete",S.AutoComplete),W.set("Upload",S.Upload),W.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:a,isusewatch:i}=Ja(n,t),{isIfShow:c,isShow:u}=Va(t,a,o),{colProps:f}=Xa(t,n),{componentProps:h}=Ga(t,a),{rules:d}=Ya({item:t,model:a,isShow:u,componentProps:h}),{disabled:v}=qa(n,t,a),{itemCollapse:g,setItemCollapse:y}=Ua(n,e),{name:w,label:j,wrapperCol:E,labelCol:D,valuePropName:z,initialValue:N,forceRow:q}=t;p.useImperativeHandle(s,()=>({itemIndex:e,componentProps:h,itemCollapse:g,setItemCollapse:y}));const G=()=>({name:w,label:j,rules:d,wrapperCol:E,labelCol:D,valuePropName:z,initialValue:N}),{setExtendFormComp:x}=Jr();x(W);const T=Rt(t),C=Mt(t),P=()=>{if(T){const A=W.get(t.component);return m.jsx(A,{...h,disabled:v,isusewatch:i.toString()})}return C?t.render({model:a,name:w,disabled:v,methods:r,componentProps:h}):null};return m.jsxs(p.Fragment,{children:[q?m.jsx("div",{className:Zr["form-item-force"]}):null,c?m.jsx(S.Col,{...f,className:u&&!g?void 0:Zr["form-item-hidden"],children:m.jsx(S.Form.Item,{...G(),children:P()})}):null]})}),dl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},pl=p.forwardRef(({collapsible:e,onClickExpand:t,onClickFold:r},n)=>{const[o,s]=p.useState(e),a=p.useMemo(()=>o,[o]),i=()=>{r(),s(!0)},c=()=>{t(),s(!1)};return p.useImperativeHandle(n,()=>({handleCollapseChangeFalse:c})),m.jsx("div",{className:dl["collapse-wrapper"],children:a?m.jsx(S.Button,{onClick:c,type:"link",icon:m.jsx(ue.DownOutlined,{}),children:"展开"}):m.jsx(S.Button,{onClick:i,type:"link",icon:m.jsx(ue.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]=S.Form.useForm(),{formProps:n}=ol(e),{formItems:o}=Ka({formProps:n}),s=p.useRef(new Map),{collapsible:a,collapseNum:i,collapseRef:c,onClickCollapseToFalse:u,onClickCollapseToTrue:f}=sl(n,s),{handleFormatRenderValues:h,handleFormatReturnValues:d}=rl(o,n,s),{setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:w,scrollToField:j}=nl(r,h,d),E=()=>{const{layout:z,wrapperCol:N,labelCol:q,colon:G,disabled:x,labelWrap:T,labelAlign:C,scrollToFirstError:P,size:A}=n;return{layout:z,wrapperCol:N,labelCol:q,colon:G,disabled:x,labelWrap:T,labelAlign:C,scrollToFirstError:P,size:A}},D={setFieldsValue:v,getFieldsValue:g,resetFields:y,validator:w,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(S.Form,{form:r,...E(),children:[m.jsx(S.Row,{children:o.map((z,N)=>(s.current.has(z.name)||s.current.set(z.name,p.createRef()),m.jsx(fl,{ref:s.current.get(z.name),itemIndex:N,itemProps:z,formProps:n,methods:D,collapseRef:c},N)))}),m.jsxs("div",{className:ml["xph-form-action"],children:[m.jsx(hl,{formProps:n}),a?m.jsx(pl,{ref:c,collapsible:o.length>i,onClickExpand:u,onClickFold:f}):null]})]})},kt=p.forwardRef(bl),vl=p.memo(kt),yl=p.forwardRef((e,t)=>{const{renderActions:r,showSearch:n,tableRef:o}=e,[s,a]=p.useState(!1),i=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(S.Button,{type:"primary",icon:m.jsx(ue.SearchOutlined,{}),onClick:c,children:"搜索"}),m.jsx(S.Button,{icon:m.jsx(ue.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),h=()=>{const{renderActions:d,...v}=e;return{...v,renderActions:f}};return p.useImperativeHandle(t,()=>({setFormLoading:a,...i.current})),m.jsx(S.Spin,{spinning:s,children:m.jsx(vl,{ref:i,...h()})})}),_l=p.memo(kt),wl=(e,t)=>{const r=p.useRef(null),n=p.useRef(null),{formProps:o}=e,a=(()=>{const{formProps:f,...h}=e;return h})(),i=p.useRef(null),c=async()=>{const{onOk:f,renderFooter:h}=a;if(!h){const{ok:d,data:v}=i.current;if(d){n.current.validator().then(async g=>{r.current.setLoading(!0),await d({values:n.current.getFieldsValue()}).then(w=>w).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),i.current=null)});return}if(f){n.current.validator().then(async g=>{r.current.setLoading(!0),await f({values:g,data:v}).then(w=>(console.log(w),w)).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),i.current=null)});return}r.current.close(),i.current=null}},u=async()=>{const{onCancel:f,renderFooter:h}=a;if(!h){const{cancel:d,data:v}=i.current;if(d){if(await d({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),i.current=null;return}if(f){if(await f({values:n.current.getFieldsValue(!0),data:v})===!1)return;r.current.close(),i.current=null;return}r.current.close(),i.current=null}};return p.useImperativeHandle(t,()=>({open:async f=>{if(r.current.getVisible())return;const{renderFooter:d}=a;return!d&&(i.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,{...a,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}=S.theme,Pl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t,{url:s,onClick:a}=n,{token:i}=Sl(),c={color:i.colorLink,cursor:"pointer"},u=()=>{if(r.mainClick&&r.mainClick(),a){a();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(st,{...n})})},{useToken:jl}=S.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 a=`${String(t.dataIndex)}${o.value}`,i=(u=o.config)==null?void 0:u.color,c=i?r[i]??{color:i,backgroundColor:"unset",border:`1px solid ${i}`}:Dl[s]||{};return n[a]={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:a}=jl(),{enums:i}=n,c={primary:{color:a.colorPrimary,backgroundColor:a.colorPrimaryBg,border:`1px solid ${a.colorPrimary}`},success:{color:a.colorSuccess,backgroundColor:a.colorSuccessBg,border:`1px solid ${a.colorSuccess}`},warning:{color:a.colorWarning,backgroundColor:a.colorWarningBg,border:`1px solid ${a.colorWarning}`},info:{color:a.colorInfo,backgroundColor:a.colorInfoBg,border:`1px solid ${a.colorInfo}`},error:{color:a.colorError,backgroundColor:a.colorErrorBg,border:`1px solid ${a.colorError}`}},f=Al(i,s,c)[`${String(s.dataIndex)}${o}`]||{},h={padding:"0 8px",borderRadius:a.borderRadiusLG,fontSize:a.fontSizeSM,...f},d=()=>{var g;return(g=i.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++,a=en[r[s].component];a&&(n=a.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 a=Z(n),[i,c,u]=s,f={text:i,record:c,index:u,column:JSON.parse(JSON.stringify(o))},h=a?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:{...le(le({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),a=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:a},lastPaginationState:s}}function Il(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:a,responseFields:i}=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:T=>{var P;const C={...v.current,...T};d(C),v.current=C,(P=t.current)==null||P.setFormLoading(C.loading)}},y=async()=>{p.useEffect(()=>{const{autoRequest:T}=e.table,{validator:C}=t.current;T&&C().then(P=>{D({searchFormParams:P})})},[])},w=async({searchFormParams:T,paginationParams:C})=>{const P={...T,[`${a.current}`]:f.current.current,[`${a.pageSize}`]:f.current.pageSize,...C?{[`${a.current}`]:C.current,[`${a.pageSize}`]:C.pageSize}:{}};return r(P).then(A=>{const{current:O,list:$,total:I}=gt(i,A);g.update({dataSource:n?n($):$}),u.update({total:I,current:O,pageSize:P[`${a.pageSize}`]})}).finally(()=>{g.update({loading:!1})})},j=async({searchFormParams:T,paginationParams:C})=>{const P={...T};return r(P).then(A=>{const{list:O}=gt(i,A),$=n?n(O):O;g.update({selection:[],dataSource:$}),u.update({current:1,total:O.length})}).finally(()=>{g.update({loading:!1})})},E=async({searchFormParams:T,paginationParams:C})=>{var A;const P={...T};if(C){const{current:O,pageSize:$}=C;u.update({current:O,pageSize:$});const I=(O-1)*$,Q=I+$,ne=(A=v.current.backupsDataSource)==null?void 0:A.slice(I,Q);return g.update({loading:!1,selection:[],dataSource:ne})}else return r(P).then(O=>{let $=n?n(O):O;const I=[...$],Q=0,ne=Q+f.current.pageSize;$=$.slice(Q,ne),g.update({selection:[],dataSource:$,backupsDataSource:I}),u.update({current:1,total:O.length})}).finally(()=>{g.update({loading:!1})})},D=async({searchFormParams:T,paginationParams:C})=>{if(g.update({loading:!0,selection:[]}),r)switch(!!f.current){case!0:return o===!0?E({searchFormParams:T,paginationParams:C}):o===!1?j({searchFormParams:T,paginationParams:C}):w({searchFormParams:T,paginationParams:C});case!1:return j({searchFormParams:T,paginationParams:C})}return g.update({loading:!1})};return{table:g,pagination:u,firstGetTableData:y,onPaginationChange:(T,C)=>{const{validator:P}=t.current;P().then(A=>{D({searchFormParams:A,paginationParams:{current:T,pageSize:C}})}),c&&c(T,C)},onAllChange:async(...T)=>{const[C,P,A,O]=T,$=[];for(let I=0;I<$.length&&!$[I]();I++);s&&s(P,A,O)},resetData:async()=>{const{resetFields:T,validator:C}=t.current;return T().then(async()=>{const P=await C();return D({searchFormParams:P})})},resetAllData:async()=>{const{resetFields:T,validator:C}=t.current;return T().then(async()=>{const P={};if(f.current){const{pageSize:A}=f.current;o===void 0&&(P.paginationParams={current:1,pageSize:A})}return P.searchFormParams=await C(),D(P)})},reloadData:async()=>{const{validator:T}=t.current;return T().then(C=>D({searchFormParams:C}))}}}const zl=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(zr(n))return{type:n,onChange:(s,a,i)=>{t.update({selection:a}),r&&r(s,a)}};if(se(n)){const{onChange:s}=n;return{...n,onChange:(a,i,c)=>{t.update({selection:i}),s&&s(a,i,c),r&&r(a,i)}}}return n};return{rowSelection:o(),getNewRowSelection:o}};function Ll(e,t){const{scroll:r,virtual:n}=e.table,o=p.useRef(null),[s,a]=p.useState(0),[i,c]=p.useState(0),u=()=>{o.current&&(console.log("触发了table的handleResize"),a(o.current.offsetWidth),c(o.current.offsetHeight))};p.useEffect(()=>{const h=new ResizeObserver(u);return o.current&&h.observe(o.current),()=>{h&&o.current&&h.unobserve(o.current)}},[]);const f=p.useMemo(()=>t?n?{x:s,y:i-70,...r}:{y:i-70,...r}:{...r},[i]);return{divRef:o,scroll:f}}function Wl(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}=je(),r=n=>{const o=t==null?void 0:t.tableCellFunc;o&&Object.keys(o).forEach(s=>{const a=o[s];n[s]={Comp:a}})};return{extendTableProps:e==null?void 0:e.table,setExtendTableCellComp:r}},Nl=({crudFormDialog:e})=>({crudFormDialogRef:p.useRef(null),crudFormProps:e}),at={"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:a,pagination:i,firstGetTableData:c,onPaginationChange:u,onAllChange:f,resetData:h,resetAllData:d,reloadData:v}=Il(e,t),{rowSelection:g}=zl(e,a),{divRef:y,scroll:w}=Ll(e,r),{getTopToolbarBindProps:j}=Wl(e,a),E=()=>{const{autoRequest:D,api:z,formatDataSource:N,autoPagination:q,columns:G,scroll:x,pagination:T,rowSelection:C,onChange:P,...A}=e.table;return A};return c(),p.useImperativeHandle(n,()=>({resetData:h,resetAllData:d,reloadData:v,...s.current})),console.log("render Table"),m.jsxs("div",{className:r?at["main-container"]:void 0,children:[m.jsx("div",{className:at.container__toolbar,children:m.jsx(st,{...j()})}),m.jsx("div",{ref:y,className:r?at.container__table:void 0,children:m.jsx(S.Table,{ref:s,...E(),loading:a.model.loading,columns:o,dataSource:a.model.dataSource,pagination:!1,rowSelection:g,scroll:w,onChange:f})}),i.show?m.jsx("div",{className:at.container__pagination,children:m.jsx(S.Pagination,{disabled:a.model.loading,...i.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:a,crudFormProps:i}=Nl(r);let{fullHeight:c}=r.table;const{virtual:u}=r.table;return u&&(c=!0),p.useImperativeHandle(t,()=>({...n.current,...a.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})}),i?m.jsx(Qr,{ref:a,...i}):null]})},Vl=p.forwardRef(Hl);R.XphActions=st,R.XphAuth=za,R.XphCrudFormDialog=Qr,R.XphDialog=Xr,R.XphExtendCompPropsProvider=ua,R.XphForm=kt,R.XphPortal=Kr,R.XphTable=Vl,R.buildUUID=pt,R.getValueByPath=qt,R.getValuesByPathObj=gt,R.useAsyncState=Vr,R.useXphExtendCompProps=je,R.useXphForm=Za,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"})});
@@ -3,7 +3,7 @@ import { TTableProps } from '../types';
3
3
  export default function useTableScroll(tableProps: TTableProps, fullHeight?: boolean): {
4
4
  divRef: import('react').RefObject<HTMLDivElement>;
5
5
  scroll: {
6
- x: string | number | true;
6
+ x?: string | number | true | undefined;
7
7
  y?: string | number | undefined;
8
8
  scrollToFirstRowOnChange?: boolean | undefined;
9
9
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xph-crud",
3
- "version": "0.2.9",
3
+ "version": "0.3.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/types/index.d.ts",