xph-crud 0.3.9 → 0.4.1
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 +2347 -2041
- package/dist/index.umd.cjs +10 -10
- package/dist/style.css +1 -1
- package/dist/types/common/src/components/dialog/hooks/dialogScrollEvents.d.ts +2 -0
- package/dist/types/common/src/components/dialog/hooks/useDialogLayer.d.ts +10 -0
- package/dist/types/common/src/components/dialog/hooks/useDialogProps.d.ts +1 -19
- package/dist/types/common/src/components/dialog/hooks/useDialogScrollLock.d.ts +6 -0
- package/dist/types/common/src/components/dialog/hooks/useOnContainerSizeChange.d.ts +1 -0
- package/dist/types/common/src/components/dialog/hooks/useOnPropsSizeChange.d.ts +4 -4
- package/dist/types/common/src/components/dialog/hooks/usePopperContainerSize.d.ts +4 -3
- package/dist/types/common/src/components/dialog/types/dialog.d.ts +2 -2
- package/package.json +1 -1
package/dist/index.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(k,m){typeof exports=="object"&&typeof module<"u"?m(exports,require("react"),require("antd"),require("@ant-design/icons"),require("react-dom"),require("dayjs")):typeof define=="function"&&define.amd?define(["exports","react","antd","@ant-design/icons","react-dom","dayjs"],m):(k=typeof globalThis<"u"?globalThis:k||self,m(k["xph-crud"]={},k.React,k.Antd,k.AntDesignIcons,k.ReactDOM,k.Dayjs))})(this,function(k,m,E,ue,Tn,Je){"use strict";const wt=[];for(let e=0;e<=15;e++)wt[e]=e.toString(16);function tr(){let e="";for(let t=1;t<=36;t++)t===9||t===14||t===19||t===24?e+="-":t===15?e+=4:t===20?e+=wt[Math.random()*4|8]:e+=wt[Math.random()*16|0];return e.replace(/-/g,"")}const rr=(e,t)=>{const r=t.split(".").filter(Boolean);let n=e;for(const o of r)if(n[o]!==void 0)n=n[o];else return;return r.length?n:void 0},_t=(e,t)=>{const r={};for(const[n,o]of Object.entries(e))r[n]=rr(t,o);return r};var Ct={exports:{}},Ie={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var nr;function Pn(){if(nr)return Ie;nr=1;var e=m,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function i(a,l,u){var f,p={},d=null,g=null;u!==void 0&&(d=""+u),l.key!==void 0&&(d=""+l.key),l.ref!==void 0&&(g=l.ref);for(f in l)n.call(l,f)&&!s.hasOwnProperty(f)&&(p[f]=l[f]);if(a&&a.defaultProps)for(f in l=a.defaultProps,l)p[f]===void 0&&(p[f]=l[f]);return{$$typeof:t,type:a,key:d,ref:g,props:p,_owner:o.current}}return Ie.Fragment=r,Ie.jsx=i,Ie.jsxs=i,Ie}var ze={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,17 +14,17 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),te
|
|
20
|
-
`),J=
|
|
21
|
-
`+
|
|
17
|
+
*/var or;function En(){return or||(or=1,process.env.NODE_ENV!=="production"&&function(){var e=m,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),h=Symbol.iterator,y="@@iterator";function w(c){if(c===null||typeof c!="object")return null;var b=h&&c[h]||c[y];return typeof b=="function"?b:null}var D=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function T(c){{for(var b=arguments.length,P=new Array(b>1?b-1:0),$=1;$<b;$++)P[$-1]=arguments[$];_("error",c,P)}}function _(c,b,P){{var $=D.ReactDebugCurrentFrame,W=$.getStackAddendum();W!==""&&(b+="%s",P=P.concat([W]));var Y=P.map(function(N){return String(N)});Y.unshift("Warning: "+b),Function.prototype.apply.call(console[c],console,Y)}}var F=!1,j=!1,R=!1,B=!1,x=!1,A;A=Symbol.for("react.module.reference");function S(c){return!!(typeof c=="string"||typeof c=="function"||c===n||c===s||x||c===o||c===u||c===f||B||c===g||F||j||R||typeof c=="object"&&c!==null&&(c.$$typeof===d||c.$$typeof===p||c.$$typeof===i||c.$$typeof===a||c.$$typeof===l||c.$$typeof===A||c.getModuleId!==void 0))}function C(c,b,P){var $=c.displayName;if($)return $;var W=b.displayName||b.name||"";return W!==""?P+"("+W+")":P}function O(c){return c.displayName||"Context"}function M(c){if(c==null)return null;if(typeof c.tag=="number"&&T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case n:return"Fragment";case r:return"Portal";case s:return"Profiler";case o:return"StrictMode";case u:return"Suspense";case f:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case a:var b=c;return O(b)+".Consumer";case i:var P=c;return O(P._context)+".Provider";case l:return C(c,c.render,"ForwardRef");case p:var $=c.displayName||null;return $!==null?$:M(c.type)||"Memo";case d:{var W=c,Y=W._payload,N=W._init;try{return M(N(Y))}catch{return null}}}return null}var I=Object.assign,z=0,G,ne,se,be,pe,U,H;function X(){}X.__reactDisabledLog=!0;function K(){{if(z===0){G=console.log,ne=console.info,se=console.warn,be=console.error,pe=console.group,U=console.groupCollapsed,H=console.groupEnd;var c={configurable:!0,enumerable:!0,value:X,writable:!0};Object.defineProperties(console,{info:c,log:c,warn:c,error:c,group:c,groupCollapsed:c,groupEnd:c})}z++}}function Ut(){{if(z--,z===0){var c={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:I({},c,{value:G}),info:I({},c,{value:ne}),warn:I({},c,{value:se}),error:I({},c,{value:be}),group:I({},c,{value:pe}),groupCollapsed:I({},c,{value:U}),groupEnd:I({},c,{value:H})})}z<0&&T("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Ce=D.ReactCurrentDispatcher,Ue;function je(c,b,P){{if(Ue===void 0)try{throw Error()}catch(W){var $=W.stack.trim().match(/\n( *(at )?)/);Ue=$&&$[1]||""}return`
|
|
18
|
+
`+Ue+c}}var Ye=!1,Oe;{var Me=typeof WeakMap=="function"?WeakMap:Map;Oe=new Me}function qe(c,b){if(!c||Ye)return"";{var P=Oe.get(c);if(P!==void 0)return P}var $;Ye=!0;var W=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var Y;Y=Ce.current,Ce.current=null,K();try{if(b){var N=function(){throw Error()};if(Object.defineProperty(N.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(N,[])}catch(oe){$=oe}Reflect.construct(c,[],N)}else{try{N.call()}catch(oe){$=oe}c.call(N.prototype)}}else{try{throw Error()}catch(oe){$=oe}c()}}catch(oe){if(oe&&$&&typeof oe.stack=="string"){for(var L=oe.stack.split(`
|
|
19
|
+
`),te=$.stack.split(`
|
|
20
|
+
`),J=L.length-1,Z=te.length-1;J>=1&&Z>=0&&L[J]!==te[Z];)Z--;for(;J>=1&&Z>=0;J--,Z--)if(L[J]!==te[Z]){if(J!==1||Z!==1)do if(J--,Z--,Z<0||L[J]!==te[Z]){var ae=`
|
|
21
|
+
`+L[J].replace(" at new "," at ");return c.displayName&&ae.includes("<anonymous>")&&(ae=ae.replace("<anonymous>",c.displayName)),typeof c=="function"&&Oe.set(c,ae),ae}while(J>=1&&Z>=0);break}}}finally{Ye=!1,Ce.current=Y,Ut(),Error.prepareStackTrace=W}var Re=c?c.displayName||c.name:"",Ae=Re?je(Re):"";return typeof c=="function"&&Oe.set(c,Ae),Ae}function Xe(c,b,P){return qe(c,!1)}function Yt(c){var b=c.prototype;return!!(b&&b.isReactComponent)}function $e(c,b,P){if(c==null)return"";if(typeof c=="function")return qe(c,Yt(c));if(typeof c=="string")return je(c);switch(c){case u:return je("Suspense");case f:return je("SuspenseList")}if(typeof c=="object")switch(c.$$typeof){case l:return Xe(c.render);case p:return $e(c.type,b,P);case d:{var $=c,W=$._payload,Y=$._init;try{return $e(Y(W),b,P)}catch{}}}return""}var xe=Object.prototype.hasOwnProperty,ht={},gt=D.ReactDebugCurrentFrame;function Se(c){if(c){var b=c._owner,P=$e(c.type,c._source,b?b.type:null);gt.setExtraStackFrame(P)}else gt.setExtraStackFrame(null)}function qt(c,b,P,$,W){{var Y=Function.call.bind(xe);for(var N in c)if(Y(c,N)){var L=void 0;try{if(typeof c[N]!="function"){var te=Error(($||"React class")+": "+P+" type `"+N+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof c[N]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw te.name="Invariant Violation",te}L=c[N](b,N,$,P,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(J){L=J}L&&!(L instanceof Error)&&(Se(W),T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",$||"React class",P,N,typeof L),Se(null)),L instanceof Error&&!(L.message in ht)&&(ht[L.message]=!0,Se(W),T("Failed %s type: %s",P,L.message),Se(null))}}}var Xt=Array.isArray;function Ge(c){return Xt(c)}function yn(c){{var b=typeof Symbol=="function"&&Symbol.toStringTag,P=b&&c[Symbol.toStringTag]||c.constructor.name||"Object";return P}}function Ke(c){try{return mt(c),!1}catch{return!0}}function mt(c){return""+c}function yt(c){if(Ke(c))return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",yn(c)),mt(c)}var Fe=D.ReactCurrentOwner,Gt={key:!0,ref:!0,__self:!0,__source:!0},vt,bt,Kt;Kt={};function uc(c){if(xe.call(c,"ref")){var b=Object.getOwnPropertyDescriptor(c,"ref").get;if(b&&b.isReactWarning)return!1}return c.ref!==void 0}function dc(c){if(xe.call(c,"key")){var b=Object.getOwnPropertyDescriptor(c,"key").get;if(b&&b.isReactWarning)return!1}return c.key!==void 0}function fc(c,b){if(typeof c.ref=="string"&&Fe.current&&b&&Fe.current.stateNode!==b){var P=M(Fe.current.type);Kt[P]||(T('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',M(Fe.current.type),c.ref),Kt[P]=!0)}}function pc(c,b){{var P=function(){vt||(vt=!0,T("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",b))};P.isReactWarning=!0,Object.defineProperty(c,"key",{get:P,configurable:!0})}}function hc(c,b){{var P=function(){bt||(bt=!0,T("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",b))};P.isReactWarning=!0,Object.defineProperty(c,"ref",{get:P,configurable:!0})}}var gc=function(c,b,P,$,W,Y,N){var L={$$typeof:t,type:c,key:b,ref:P,props:N,_owner:Y};return L._store={},Object.defineProperty(L._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(L,"_self",{configurable:!1,enumerable:!1,writable:!1,value:$}),Object.defineProperty(L,"_source",{configurable:!1,enumerable:!1,writable:!1,value:W}),Object.freeze&&(Object.freeze(L.props),Object.freeze(L)),L};function mc(c,b,P,$,W){{var Y,N={},L=null,te=null;P!==void 0&&(yt(P),L=""+P),dc(b)&&(yt(b.key),L=""+b.key),uc(b)&&(te=b.ref,fc(b,W));for(Y in b)xe.call(b,Y)&&!Gt.hasOwnProperty(Y)&&(N[Y]=b[Y]);if(c&&c.defaultProps){var J=c.defaultProps;for(Y in J)N[Y]===void 0&&(N[Y]=J[Y])}if(L||te){var Z=typeof c=="function"?c.displayName||c.name||"Unknown":c;L&&pc(N,Z),te&&hc(N,Z)}return gc(c,L,te,W,$,Fe.current,N)}}var Jt=D.ReactCurrentOwner,vn=D.ReactDebugCurrentFrame;function ke(c){if(c){var b=c._owner,P=$e(c.type,c._source,b?b.type:null);vn.setExtraStackFrame(P)}else vn.setExtraStackFrame(null)}var Zt;Zt=!1;function Qt(c){return typeof c=="object"&&c!==null&&c.$$typeof===t}function bn(){{if(Jt.current){var c=M(Jt.current.type);if(c)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+c+"`."}return""}}function yc(c){return""}var wn={};function vc(c){{var b=bn();if(!b){var P=typeof c=="string"?c:c.displayName||c.name;P&&(b=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+
|
|
25
|
+
Check the top-level render call using <`+P+">.")}return b}}function _n(c,b){{if(!c._store||c._store.validated||c.key!=null)return;c._store.validated=!0;var P=vc(b);if(wn[P])return;wn[P]=!0;var $="";c&&c._owner&&c._owner!==Jt.current&&($=" It was passed a child from "+M(c._owner.type)+"."),ke(c),T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',P,$),ke(null)}}function Cn(c,b){{if(typeof c!="object")return;if(Ge(c))for(var P=0;P<c.length;P++){var $=c[P];Qt($)&&_n($,b)}else if(Qt(c))c._store&&(c._store.validated=!0);else if(c){var W=w(c);if(typeof W=="function"&&W!==c.entries)for(var Y=W.call(c),N;!(N=Y.next()).done;)Qt(N.value)&&_n(N.value,b)}}}function bc(c){{var b=c.type;if(b==null||typeof b=="string")return;var P;if(typeof b=="function")P=b.propTypes;else if(typeof b=="object"&&(b.$$typeof===l||b.$$typeof===p))P=b.propTypes;else return;if(P){var $=M(b);qt(P,c.props,"prop",$,c)}else if(b.PropTypes!==void 0&&!Zt){Zt=!0;var W=M(b);T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",W||"Unknown")}typeof b.getDefaultProps=="function"&&!b.getDefaultProps.isReactClassApproved&&T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function wc(c){{for(var b=Object.keys(c.props),P=0;P<b.length;P++){var $=b[P];if($!=="children"&&$!=="key"){ke(c),T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",$),ke(null);break}}c.ref!==null&&(ke(c),T("Invalid attribute `ref` supplied to `React.Fragment`."),ke(null))}}var xn={};function Sn(c,b,P,$,W,Y){{var N=S(c);if(!N){var L="";(c===void 0||typeof c=="object"&&c!==null&&Object.keys(c).length===0)&&(L+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var te=yc();te?L+=te:L+=bn();var J;c===null?J="null":Ge(c)?J="array":c!==void 0&&c.$$typeof===t?(J="<"+(M(c.type)||"Unknown")+" />",L=" Did you accidentally export a JSX literal instead of a component?"):J=typeof c,T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",J,L)}var Z=mc(c,b,P,W,Y);if(Z==null)return Z;if(N){var ae=b.children;if(ae!==void 0)if($)if(Ge(ae)){for(var Re=0;Re<ae.length;Re++)Cn(ae[Re],c);Object.freeze&&Object.freeze(ae)}else T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Cn(ae,c)}if(xe.call(b,"key")){var Ae=M(c),oe=Object.keys(b).filter(function(Pc){return Pc!=="key"}),er=oe.length>0?"{key: someKey, "+oe.join(": ..., ")+": ...}":"{key: someKey}";if(!xn[Ae+er]){var Tc=oe.length>0?"{"+oe.join(": ..., ")+": ...}":"{}";T(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,qt,je,fc,je),mn[je+qt]=!0}}return l===n?ic(Z):sc(Z),Z}}function ac(l,b,_){return bn(l,b,_,!0)}function lc(l,b,_){return bn(l,b,_,!1)}var cc=lc,uc=ac;Ie.Fragment=n,Ie.jsx=cc,Ie.jsxs=uc}()),Ie}process.env.NODE_ENV==="production"?bt.exports=yn():bt.exports=_n();var m=bt.exports,Zt=typeof global=="object"&&global&&global.Object===Object&&global,wn=typeof self=="object"&&self&&self.Object===Object&&self,de=Zt||wn||Function("return this")(),_e=de.Symbol,Qt=Object.prototype,Cn=Qt.hasOwnProperty,xn=Qt.toString,ze=_e?_e.toStringTag:void 0;function Tn(e){var t=Cn.call(e,ze),r=e[ze];try{e[ze]=void 0;var n=!0}catch{}var o=xn.call(e);return n&&(t?e[ze]=r:delete e[ze]),o}var Sn=Object.prototype,Pn=Sn.toString;function En(e){return Pn.call(e)}var jn="[object Null]",Fn="[object Undefined]",er=_e?_e.toStringTag:void 0;function pe(e){return e==null?e===void 0?Fn:jn:er&&er in Object(e)?Tn(e):En(e)}function le(e){return e!=null&&typeof e=="object"}var An="[object Symbol]";function vt(e){return typeof e=="symbol"||le(e)&&pe(e)==An}function Dn(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 re=Array.isArray,On=1/0,tr=_e?_e.prototype:void 0,rr=tr?tr.toString:void 0;function nr(e){if(typeof e=="string")return e;if(re(e))return Dn(e,nr)+"";if(vt(e))return rr?rr.call(e):"";var t=e+"";return t=="0"&&1/e==-On?"-0":t}function ie(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function or(e){return e}var $n="[object AsyncFunction]",Rn="[object Function]",kn="[object GeneratorFunction]",Mn="[object Proxy]";function Q(e){if(!ie(e))return!1;var t=pe(e);return t==Rn||t==kn||t==$n||t==Mn}var yt=de["__core-js_shared__"],sr=function(){var e=/[^.]+$/.exec(yt&&yt.keys&&yt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function In(e){return!!sr&&sr in e}var zn=Function.prototype,Ln=zn.toString;function Ce(e){if(e!=null){try{return Ln.call(e)}catch{}try{return e+""}catch{}}return""}var Nn=/[\\^$.*+?()[\]{}|]/g,Wn=/^\[object .+?Constructor\]$/,Hn=Function.prototype,Bn=Object.prototype,Vn=Hn.toString,Un=Bn.hasOwnProperty,Yn=RegExp("^"+Vn.call(Un).replace(Nn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function qn(e){if(!ie(e)||In(e))return!1;var t=Q(e)?Yn:Wn;return t.test(Ce(e))}function Gn(e,t){return e==null?void 0:e[t]}function xe(e,t){var r=Gn(e,t);return qn(r)?r:void 0}var _t=xe(de,"WeakMap"),ir=Object.create,Xn=function(){function e(){}return function(t){if(!ie(t))return{};if(ir)return ir(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function Kn(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 Jn(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Zn=800,Qn=16,eo=Date.now;function to(e){var t=0,r=0;return function(){var n=eo(),o=Qn-(n-r);if(r=n,o>0){if(++t>=Zn)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function ro(e){return function(){return e}}var Xe=function(){try{var e=xe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),no=Xe?function(e,t){return Xe(e,"toString",{configurable:!0,enumerable:!1,value:ro(t),writable:!0})}:or,oo=to(no),so=9007199254740991,io=/^(?:0|[1-9]\d*)$/;function wt(e,t){var r=typeof e;return t=t??so,!!t&&(r=="number"||r!="symbol"&&io.test(e))&&e>-1&&e%1==0&&e<t}function Ct(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 ao=Object.prototype,lo=ao.hasOwnProperty;function ar(e,t,r){var n=e[t];(!(lo.call(e,t)&&Le(n,r))||r===void 0&&!(t in e))&&Ct(e,t,r)}function co(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?Ct(r,i,c):ar(r,i,c)}return r}var lr=Math.max;function uo(e,t,r){return t=lr(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,s=lr(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),Kn(e,this,i)}}function fo(e,t){return oo(uo(e,t,or),e+"")}var po=9007199254740991;function cr(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=po}function Ke(e){return e!=null&&cr(e.length)&&!Q(e)}function ho(e,t,r){if(!ie(r))return!1;var n=typeof t;return(n=="number"?Ke(r)&&wt(t,r.length):n=="string"&&t in r)?Le(r[t],e):!1}function go(e){return fo(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&&ho(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 mo=Object.prototype;function xt(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||mo;return e===r}function bo(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var vo="[object Arguments]";function ur(e){return le(e)&&pe(e)==vo}var fr=Object.prototype,yo=fr.hasOwnProperty,_o=fr.propertyIsEnumerable,Tt=ur(function(){return arguments}())?ur:function(e){return le(e)&&yo.call(e,"callee")&&!_o.call(e,"callee")};function wo(){return!1}var dr=typeof A=="object"&&A&&!A.nodeType&&A,pr=dr&&typeof module=="object"&&module&&!module.nodeType&&module,Co=pr&&pr.exports===dr,hr=Co?de.Buffer:void 0,xo=hr?hr.isBuffer:void 0,Je=xo||wo,To="[object Arguments]",So="[object Array]",Po="[object Boolean]",Eo="[object Date]",jo="[object Error]",Fo="[object Function]",Ao="[object Map]",Do="[object Number]",Oo="[object Object]",$o="[object RegExp]",Ro="[object Set]",ko="[object String]",Mo="[object WeakMap]",Io="[object ArrayBuffer]",zo="[object DataView]",Lo="[object Float32Array]",No="[object Float64Array]",Wo="[object Int8Array]",Ho="[object Int16Array]",Bo="[object Int32Array]",Vo="[object Uint8Array]",Uo="[object Uint8ClampedArray]",Yo="[object Uint16Array]",qo="[object Uint32Array]",U={};U[Lo]=U[No]=U[Wo]=U[Ho]=U[Bo]=U[Vo]=U[Uo]=U[Yo]=U[qo]=!0,U[To]=U[So]=U[Io]=U[Po]=U[zo]=U[Eo]=U[jo]=U[Fo]=U[Ao]=U[Do]=U[Oo]=U[$o]=U[Ro]=U[ko]=U[Mo]=!1;function Go(e){return le(e)&&cr(e.length)&&!!U[pe(e)]}function Xo(e){return function(t){return e(t)}}var gr=typeof A=="object"&&A&&!A.nodeType&&A,Ne=gr&&typeof module=="object"&&module&&!module.nodeType&&module,Ko=Ne&&Ne.exports===gr,St=Ko&&Zt.process,mr=function(){try{var e=Ne&&Ne.require&&Ne.require("util").types;return e||St&&St.binding&&St.binding("util")}catch{}}(),br=mr&&mr.isTypedArray,Pt=br?Xo(br):Go,Jo=Object.prototype,Zo=Jo.hasOwnProperty;function vr(e,t){var r=re(e),n=!r&&Tt(e),o=!r&&!n&&Je(e),s=!r&&!n&&!o&&Pt(e),a=r||n||o||s,i=a?bo(e.length,String):[],c=i.length;for(var u in e)(t||Zo.call(e,u))&&!(a&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||wt(u,c)))&&i.push(u);return i}function yr(e,t){return function(r){return e(t(r))}}var Qo=yr(Object.keys,Object),es=Object.prototype,ts=es.hasOwnProperty;function rs(e){if(!xt(e))return Qo(e);var t=[];for(var r in Object(e))ts.call(e,r)&&r!="constructor"&&t.push(r);return t}function ns(e){return Ke(e)?vr(e):rs(e)}function os(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var ss=Object.prototype,is=ss.hasOwnProperty;function as(e){if(!ie(e))return os(e);var t=xt(e),r=[];for(var n in e)n=="constructor"&&(t||!is.call(e,n))||r.push(n);return r}function _r(e){return Ke(e)?vr(e,!0):as(e)}var ls=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,cs=/^\w*$/;function us(e,t){if(re(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||vt(e)?!0:cs.test(e)||!ls.test(e)||t!=null&&e in Object(t)}var We=xe(Object,"create");function fs(){this.__data__=We?We(null):{},this.size=0}function ds(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var ps="__lodash_hash_undefined__",hs=Object.prototype,gs=hs.hasOwnProperty;function ms(e){var t=this.__data__;if(We){var r=t[e];return r===ps?void 0:r}return gs.call(t,e)?t[e]:void 0}var bs=Object.prototype,vs=bs.hasOwnProperty;function ys(e){var t=this.__data__;return We?t[e]!==void 0:vs.call(t,e)}var _s="__lodash_hash_undefined__";function ws(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=We&&t===void 0?_s: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=fs,Te.prototype.delete=ds,Te.prototype.get=ms,Te.prototype.has=ys,Te.prototype.set=ws;function Cs(){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 xs=Array.prototype,Ts=xs.splice;function Ss(e){var t=this.__data__,r=Ze(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Ts.call(t,r,1),--this.size,!0}function Ps(e){var t=this.__data__,r=Ze(t,e);return r<0?void 0:t[r][1]}function Es(e){return Ze(this.__data__,e)>-1}function js(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=Cs,ge.prototype.delete=Ss,ge.prototype.get=Ps,ge.prototype.has=Es,ge.prototype.set=js;var He=xe(de,"Map");function Fs(){this.size=0,this.__data__={hash:new Te,map:new(He||ge),string:new Te}}function As(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 As(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Ds(e){var t=Qe(this,e).delete(e);return this.size-=t?1:0,t}function Os(e){return Qe(this,e).get(e)}function $s(e){return Qe(this,e).has(e)}function Rs(e,t){var r=Qe(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function me(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])}}me.prototype.clear=Fs,me.prototype.delete=Ds,me.prototype.get=Os,me.prototype.has=$s,me.prototype.set=Rs;var ks="Expected a function";function Et(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(ks);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(Et.Cache||me),r}Et.Cache=me;var Ms=500;function Is(e){var t=Et(e,function(n){return r.size===Ms&&r.clear(),n}),r=t.cache;return t}var zs=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ls=/\\(\\)?/g,Ns=Is(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(zs,function(r,n,o,s){t.push(o?s.replace(Ls,"$1"):n||r)}),t});function Ws(e){return e==null?"":nr(e)}function Hs(e,t){return re(e)?e:us(e,t)?[e]:Ns(Ws(e))}var Bs=1/0;function Vs(e){if(typeof e=="string"||vt(e))return e;var t=e+"";return t=="0"&&1/e==-Bs?"-0":t}function Us(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var wr=yr(Object.getPrototypeOf,Object),Ys="[object Object]",qs=Function.prototype,Gs=Object.prototype,Cr=qs.toString,Xs=Gs.hasOwnProperty,Ks=Cr.call(Object);function Js(e){if(!le(e)||pe(e)!=Ys)return!1;var t=wr(e);if(t===null)return!0;var r=Xs.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Cr.call(r)==Ks}function Zs(){this.__data__=new ge,this.size=0}function Qs(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function ei(e){return this.__data__.get(e)}function ti(e){return this.__data__.has(e)}var ri=200;function ni(e,t){var r=this.__data__;if(r instanceof ge){var n=r.__data__;if(!He||n.length<ri-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new me(n)}return r.set(e,t),this.size=r.size,this}function be(e){var t=this.__data__=new ge(e);this.size=t.size}be.prototype.clear=Zs,be.prototype.delete=Qs,be.prototype.get=ei,be.prototype.has=ti,be.prototype.set=ni;var xr=typeof A=="object"&&A&&!A.nodeType&&A,Tr=xr&&typeof module=="object"&&module&&!module.nodeType&&module,oi=Tr&&Tr.exports===xr,Sr=oi?de.Buffer:void 0;Sr&&Sr.allocUnsafe;function si(e,t){return e.slice()}function ii(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 ai(){return[]}var li=Object.prototype,ci=li.propertyIsEnumerable,Pr=Object.getOwnPropertySymbols,ui=Pr?function(e){return e==null?[]:(e=Object(e),ii(Pr(e),function(t){return ci.call(e,t)}))}:ai;function fi(e,t,r){var n=t(e);return re(e)?n:Us(n,r(e))}function Er(e){return fi(e,ns,ui)}var jt=xe(de,"DataView"),Ft=xe(de,"Promise"),At=xe(de,"Set"),jr="[object Map]",di="[object Object]",Fr="[object Promise]",Ar="[object Set]",Dr="[object WeakMap]",Or="[object DataView]",pi=Ce(jt),hi=Ce(He),gi=Ce(Ft),mi=Ce(At),bi=Ce(_t),we=pe;(jt&&we(new jt(new ArrayBuffer(1)))!=Or||He&&we(new He)!=jr||Ft&&we(Ft.resolve())!=Fr||At&&we(new At)!=Ar||_t&&we(new _t)!=Dr)&&(we=function(e){var t=pe(e),r=t==di?e.constructor:void 0,n=r?Ce(r):"";if(n)switch(n){case pi:return Or;case hi:return jr;case gi:return Fr;case mi:return Ar;case bi:return Dr}return t});var et=de.Uint8Array;function vi(e){var t=new e.constructor(e.byteLength);return new et(t).set(new et(e)),t}function yi(e,t){var r=vi(e.buffer);return new e.constructor(r,e.byteOffset,e.length)}function _i(e){return typeof e.constructor=="function"&&!xt(e)?Xn(wr(e)):{}}var wi="__lodash_hash_undefined__";function Ci(e){return this.__data__.set(e,wi),this}function xi(e){return this.__data__.has(e)}function tt(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new me;++t<r;)this.add(e[t])}tt.prototype.add=tt.prototype.push=Ci,tt.prototype.has=xi;function Ti(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 Si(e,t){return e.has(t)}var Pi=1,Ei=2;function $r(e,t,r,n,o,s){var a=r&Pi,i=e.length,c=t.length;if(i!=c&&!(a&&c>i))return!1;var u=s.get(e),d=s.get(t);if(u&&d)return u==t&&d==e;var g=-1,f=!0,v=r&Ei?new tt:void 0;for(s.set(e,t),s.set(t,e);++g<i;){var h=e[g],y=t[g];if(n)var w=a?n(y,h,g,t,e,s):n(h,y,g,e,t,s);if(w!==void 0){if(w)continue;f=!1;break}if(v){if(!Ti(t,function(F,P){if(!Si(v,P)&&(h===F||o(h,F,r,n,s)))return v.push(P)})){f=!1;break}}else if(!(h===y||o(h,y,r,n,s))){f=!1;break}}return s.delete(e),s.delete(t),f}function ji(e){var t=-1,r=Array(e.size);return e.forEach(function(n,o){r[++t]=[o,n]}),r}function Fi(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Ai=1,Di=2,Oi="[object Boolean]",$i="[object Date]",Ri="[object Error]",ki="[object Map]",Mi="[object Number]",Ii="[object RegExp]",zi="[object Set]",Li="[object String]",Ni="[object Symbol]",Wi="[object ArrayBuffer]",Hi="[object DataView]",Rr=_e?_e.prototype:void 0,Dt=Rr?Rr.valueOf:void 0;function Bi(e,t,r,n,o,s,a){switch(r){case Hi:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Wi:return!(e.byteLength!=t.byteLength||!s(new et(e),new et(t)));case Oi:case $i:case Mi:return Le(+e,+t);case Ri:return e.name==t.name&&e.message==t.message;case Ii:case Li:return e==t+"";case ki:var i=ji;case zi:var c=n&Ai;if(i||(i=Fi),e.size!=t.size&&!c)return!1;var u=a.get(e);if(u)return u==t;n|=Di,a.set(e,t);var d=$r(i(e),i(t),n,o,s,a);return a.delete(e),d;case Ni:if(Dt)return Dt.call(e)==Dt.call(t)}return!1}var Vi=1,Ui=Object.prototype,Yi=Ui.hasOwnProperty;function qi(e,t,r,n,o,s){var a=r&Vi,i=Er(e),c=i.length,u=Er(t),d=u.length;if(c!=d&&!a)return!1;for(var g=c;g--;){var f=i[g];if(!(a?f in t:Yi.call(t,f)))return!1}var v=s.get(e),h=s.get(t);if(v&&h)return v==t&&h==e;var y=!0;s.set(e,t),s.set(t,e);for(var w=a;++g<c;){f=i[g];var F=e[f],P=t[f];if(n)var D=a?n(P,F,f,t,e,s):n(F,P,f,e,t,s);if(!(D===void 0?F===P||o(F,P,r,n,s):D)){y=!1;break}w||(w=f=="constructor")}if(y&&!w){var k=e.constructor,W=t.constructor;k!=W&&"constructor"in e&&"constructor"in t&&!(typeof k=="function"&&k instanceof k&&typeof W=="function"&&W instanceof W)&&(y=!1)}return s.delete(e),s.delete(t),y}var Gi=1,kr="[object Arguments]",Mr="[object Array]",rt="[object Object]",Xi=Object.prototype,Ir=Xi.hasOwnProperty;function Ki(e,t,r,n,o,s){var a=re(e),i=re(t),c=a?Mr:we(e),u=i?Mr:we(t);c=c==kr?rt:c,u=u==kr?rt:u;var d=c==rt,g=u==rt,f=c==u;if(f&&Je(e)){if(!Je(t))return!1;a=!0,d=!1}if(f&&!d)return s||(s=new be),a||Pt(e)?$r(e,t,r,n,o,s):Bi(e,t,c,r,n,o,s);if(!(r&Gi)){var v=d&&Ir.call(e,"__wrapped__"),h=g&&Ir.call(t,"__wrapped__");if(v||h){var y=v?e.value():e,w=h?t.value():t;return s||(s=new be),o(y,w,r,n,s)}}return f?(s||(s=new be),qi(e,t,r,n,o,s)):!1}function zr(e,t,r,n,o){return e===t?!0:e==null||t==null||!le(e)&&!le(t)?e!==e&&t!==t:Ki(e,t,r,n,zr,o)}function Ji(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 Zi=Ji();function Ot(e,t,r){(r!==void 0&&!Le(e[t],r)||r===void 0&&!(t in e))&&Ct(e,t,r)}function Qi(e){return le(e)&&Ke(e)}function $t(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function ea(e){return co(e,_r(e))}function ta(e,t,r,n,o,s,a){var i=$t(e,r),c=$t(t,r),u=a.get(c);if(u){Ot(e,r,u);return}var d=s?s(i,c,r+"",e,t,a):void 0,g=d===void 0;if(g){var f=re(c),v=!f&&Je(c),h=!f&&!v&&Pt(c);d=c,f||v||h?re(i)?d=i:Qi(i)?d=Jn(i):v?(g=!1,d=si(c)):h?(g=!1,d=yi(c)):d=[]:Js(c)||Tt(c)?(d=i,Tt(i)?d=ea(i):(!ie(i)||Q(i))&&(d=_i(c))):g=!1}g&&(a.set(c,d),o(d,c,n,s,a),a.delete(c)),Ot(e,r,d)}function Lr(e,t,r,n,o){e!==t&&Zi(t,function(s,a){if(o||(o=new be),ie(s))ta(e,t,a,r,Lr,n,o);else{var i=n?n($t(e,a),s,a+"",e,t,o):void 0;i===void 0&&(i=s),Ot(e,a,i)}},_r)}var ra="[object String]";function Rt(e){return typeof e=="string"||!re(e)&&le(e)&&pe(e)==ra}var na="[object Boolean]";function nt(e){return e===!0||e===!1||le(e)&&pe(e)==na}function ot(e,t){return zr(e,t)}var oa="[object Number]";function sa(e){return typeof e=="number"||le(e)&&pe(e)==oa}function Nr(e){return e==null}function ia(e){return e===null}var ce=go(function(e,t,r){Lr(e,t,r)});function aa(e,t,r,n){if(!ie(e))return e;t=Hs(t,e);for(var o=-1,s=t.length,a=s-1,i=e;i!=null&&++o<s;){var c=Vs(t[o]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(o!=a){var d=i[c];u=void 0,u===void 0&&(u=ie(d)?d:wt(t[o+1])?[]:{})}ar(i,c,u),i=i[c]}return e}function Wr(e,t,r){return e==null?e:aa(e,t,r)}function la(e){const{inherit:t=!0}=e,{extendActionsProps:r,extendAuthProps:n}=Yr(),s={...ce(ce({items:[],max:10},t?r:{}),e)},a={...ce({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:a}}function kt(e){return"component"in e}function Hr(e){return"render"in e}function ca(e,t){const{type:r,disabled:n,items:o,max:s}=e,a=g=>{const{auth:f}=g;let v=!1;return f?re(f)?v=f.every(h=>t(h)):v=t(f):v=!0,v},i=g=>{let{ifShow:f=!0}=g;return f=f&&Q(f)?f():f,f&&a(g)},c=g=>{const{component:f,render:v,componentProps:h}=g;if(f)switch(f){case"Dropdown":{const{dropDownItems:y}=h;return!!y.length}default:return!0}return!!v},u=o.map(g=>{const f={...g};if(kt(f)){const v=f.component;switch(f.componentProps={type:r,disabled:n,...f.componentProps},v){case"Dropdown":{f.componentProps.dropDownItems=(f.componentProps.dropDownItems||[]).filter(i);break}}}return f}).filter(i).filter(c),d=sa(s)&&s>=0;return{showActionItems:u.slice(0,d?s:u.length),ellipsisActionItems:u.slice(d?s:u.length)}}const ua=e=>{const{componentProps:t}=e,r=()=>{const{...n}=t;return n};return m.jsx(x.Button,{...r()})},fa=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...a}=t;return a})();return m.jsx(x.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(x.Button,{...n,children:[n.children,m.jsx(fe.CaretDownOutlined,{})]})})})},st=new Map;st.set("Button",ua),st.set("Dropdown",fa);function Br(){const{setExtendActionsComp:e}=Yr();return e(st),{renderContent:p.useCallback((r,n)=>{const o=kt(r),s=Hr(r);if(o){const a=st.get(r.component);return p.createElement(a,{...r,key:n})}return s?m.jsx("div",{children:r.render},n):null},[])}}const Vr=p.createContext({}),da=e=>{const{extendProps:t,extendComp:r}=e.value;return m.jsx(Vr.Provider,{value:{extendProps:t,extendComp:r},children:e.children})},Fe=()=>p.useContext(Vr),Ur=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})})]},Yr=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.actions;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendAuthProps:e==null?void 0:e.auth,extendActionsProps:e==null?void 0:e.actions,setExtendActionsComp:r}},{useToken:pa}=x.theme,ha=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Br(),{token:s}=pa(),a={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},i=()=>m.jsx("div",{style:a,children:m.jsx(x.Space,{style:{padding:8},children:e==null?void 0:e.map((c,u)=>o(c,u))})});return m.jsx(x.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:i,trigger:["click"],children:m.jsxs(x.Button,{type:r,children:["更多",m.jsx(fe.CaretDownOutlined,{})]})})},it=e=>{const{actionsProps:t,authProps:r}=la(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=ca(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(ha,{actionsProps:t,items:s}):null]})};function ga(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 ma=e=>{const{extendDialogProps:t}=ba(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body},n={...ce(ce(r,t),e)};return{dialogProps:{...n,getPopperContainer:()=>{const s=n.getPopperContainer();return n.mask?document.body:s}},baseDialogProps:r}},ba=()=>{const{extendProps:e}=Fe();return{extendDialogProps:e==null?void 0:e.dialog}},va=(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()}}},ya=({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)}}},_a=({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)}}},qr=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=p.useRef(0),s=p.useRef(0),a=d=>{const g=d.getBoundingClientRect(),f=g.width,v=g.height,h=-.5*f,y=-.5*v;return{translateX:h,translateY:y}},i=p.useCallback(d=>{const{offsetLeft:g,offsetTop:f}=r.current;o.current=d.clientX-g,s.current=d.clientY-f,document.addEventListener("mousemove",c),document.addEventListener("mouseup",u)},[]),c=p.useCallback(d=>{const g=r.current,{translateX:f,translateY:v}=a(g);let h=d.clientX-o.current,y=d.clientY-s.current;const w=-f,F=-v,P=e.current.scrollWidth-g.offsetWidth-f,D=e.current.scrollHeight-g.offsetHeight-v;h<w&&(h=w),h>P&&(h=P),y<F&&(y=F),y>D&&(y=D),n({left:h,top:y})},[]),u=p.useCallback(()=>{document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",u)},[]);return p.useEffect(()=>{const d=t.current;return d.addEventListener("mousedown",i),()=>{d.removeEventListener("mousedown",i)}},[]),{}},wa=({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:h,scrollHeight:y}=e.current,w=Math.floor(h),F=Math.floor(y),P=Math.floor(h/2),D=Math.floor(y/2);n({width:w,height:F}),o({top:D,left:P}),c(!0)}},onRecovery:()=>{const{top:v,left:h,width:y,height:w}=t.current;n({width:y,height:w}),o({top:v,left:h}),c(!1)},onClose:()=>{a(!1),r()}}},Ca=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:a,scrollHeight:i}=t.current,[c,u]=p.useState(0),[d,g]=p.useState("unset"),f=(v,h)=>{var W,q;const F=(W=o.current)==null?void 0:W.offsetHeight,P=(q=s.current)==null?void 0:q.offsetHeight;let D=v-F-P-0;const k=h-F-P-0;return D>k&&(D=k),D};return p.useEffect(()=>{var v;if(c===a){const h=(v=n.current)==null?void 0:v.getBoundingClientRect().height;g(f(h,a)),u("unset")}},[c]),p.useEffect(()=>{r!=="unset"&&r!==0&&(g(f(r,r>a?i:a)),u("unset"))},[r]),p.useEffect(()=>{e?u(a):(u(0),g("unset"))},[e]),{dialogMaxHeight:c,contentMaxHeight:d}},xa=()=>{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)}}},Ta=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=(i,c)=>{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 d,g;const c=Array.from(n.querySelectorAll(`.${o.xphDialog}`)).filter(f=>(f==null?void 0:f.parentNode)===n),u=c[c.length-1];if(((d=t.current)==null?void 0:d.parentNode)!==u&&(s((g=t.current)==null?void 0:g.parentNode,u),i)){const f=i.target;f.tagName==="INPUT"&&f.focus&&f.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,d;(u=t.current)==null||u.removeEventListener("mousedown",a,!1),(d=r.current)==null||d.removeEventListener("mousedown",a,!1)}},[]),p.useEffect(()=>{if(e)a();else{const i=Array.from(n.querySelectorAll(`.${o.xphDialog}`)).filter(f=>(f==null?void 0:f.parentNode)===n),c=i.map(f=>f.querySelector(`.${o.xphDialogWrapper}`)).filter(f=>f!==null),u=i.map(f=>f.querySelector(`.${o.xphMinimizeDialog}`)).filter(f=>f!==null),d=c.filter(f=>f.style.display==="flex"),g=u.filter(f=>f.style.display==="flex");if(d.length){s(d[d.length-1].parentNode,i[i.length-1]);return}if(g.length){s(g[g.length-1].parentNode,i[i.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},Sa=({initWidth:e,initHeight:t,curPropsWidth:r,curPropsHeight:n,setParentInitRecord:o})=>{p.useEffect(()=>{if(r!==e.current){o(s=>s+1);return}if(n!==t.current){o(s=>s+1);return}},[r,n])},Pa=()=>{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}}}},Ea=({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",zIndex:999}}),[]),i=p.useRef(null),c=p.useRef(),u=p.useRef(!1),[d,g]=p.useState(!1),f=p.useRef(0),v=p.useRef(0),h=(C,I)=>{r.current||s({width:t.current.offsetWidth,height:t.current.offsetHeight}),u.current=!0,g(!0),c.current=I;const{clientX:T,clientY:S}=C;f.current=T,v.current=S;const E=parseFloat(t.current.style.left),O=parseFloat(t.current.style.top),R=t.current.offsetWidth,$=t.current.offsetHeight;i.current.style.display="block",i.current.style.left=`${E-.5*R}px`,i.current.style.top=`${O-.5*$}px`,i.current.style.width=`${R}px`,i.current.style.height=`${$}px`},y=C=>{if(u.current){const{clientX:I,clientY:T}=C,S=I-f.current,E=T-v.current,O=parseFloat(i.current.style.left),R=parseFloat(i.current.style.top),$=i.current.offsetWidth,G=i.current.offsetHeight,ee=r.current.width,se=r.current.height,he=e.current.scrollWidth,ue=e.current.scrollHeight;let H=$,B=G,Y=O,K=R;switch(c.current){case"lt":{H=H-S,B=B-E,K=K+E,Y=Y+S,H<ee&&(H=$,Y=O),B<se&&(B=G,K=R),Y<0&&(Y=0,H=$),K<0&&(K=0,B=G);break}case"rt":{H=H+S,B=B-E,K=K+E,Y=O,H<ee&&(H=$),B<se&&(B=G,K=R),H>he-Y&&(H=he-Y),K<0&&(K=0,B=G);break}case"rb":{H=H+S,B=B+E,K=R,Y=O,H<ee&&(H=$),B<se&&(B=G),H>he-Y&&(H=he-Y),B>ue-K&&(B=ue-K);break}case"lb":{H=H-S,B=B+E,K=R,Y=Y+S,H<ee&&(H=$,Y=O),B<se&&(B=G),Y<0&&(Y=0,H=$),B>ue-K&&(B=ue-K);break}}i.current.style.left=`${Y}px`,i.current.style.top=`${K}px`,i.current.style.width=`${H}px`,i.current.style.height=`${B}px`,f.current=I,v.current=T}},w=()=>{if(u.current){u.current=!1,g(!1),i.current.style.display="none";const{left:C,top:I,width:T,height:S}=i.current.style,E=parseFloat(C)+.5*parseFloat(T),O=parseFloat(I)+.5*parseFloat(S),R=parseFloat(T),$=parseFloat(S);o({left:E,top:O}),n({width:R,height:$})}},F=C=>h(C,"lt"),P=C=>h(C,"rt"),D=C=>h(C,"rb"),k=C=>h(C,"lb"),W=p.useCallback(C=>{y(C)},[]),q=p.useCallback(()=>{w()},[]),X=p.useCallback(()=>{w()},[]);return p.useEffect(()=>(document.body.addEventListener("mousemove",W),document.body.addEventListener("mouseup",q),document.body.addEventListener("mouseleave",X),()=>{document.body.removeEventListener("mousemove",W),document.body.removeEventListener("mouseup",q),document.body.removeEventListener("mouseleave",X)}),[]),{resizingState:d,DashedBox:a,onMousedownResizeLt:F,onMousedownResizeRt:P,onMousedownResizeRb:D,onMousedownResizeLb:k}},ja=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=p.useState(0),s=()=>{o(C=>C+1)};p.useEffect(()=>(window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}),[]);const{containerSizeTarget:a,setContainerSizeTarget:i}=Aa({container:e}),{width:c,height:u}=r,{width:d,height:g}=t,f=d||c,v=g||u,{clientWidth:h,clientHeight:y}=a.current,w=f?f>h?h:f:0,F=v?v>y?y:v:"unset",P=p.useRef(w),D=p.useRef(F),k=C=>{P.current=C.width,D.current=C.height},W=p.useRef(Math.floor(h/2)),q=p.useRef(Math.floor(y/2)),X=C=>{W.current=C.left,q.current=C.top};return p.useEffect(()=>{i(),k({width:w,height:F}),X({left:Math.floor(h/2),top:Math.floor(y/2)})},[n]),{containerSizeTarget:a,parentInitRecord:n,initLeft:W,initTop:q,initWidth:P,initHeight:D,curPropsWidth:w,curPropsHeight:F,setInitPosition:X,setInitSize:k,setParentInitRecord:o}},Fa=()=>{const e=p.useRef(null);return{minResizeRecord:e,setMinResizeRecord:r=>{e.current=r}}},Aa=({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}}}},Mt={"minimize-windows":"_minimize-windows_12u3y_1","minimize-windows-title":"_minimize-windows-title_12u3y_43","minimize-windows-operate":"_minimize-windows-operate_12u3y_55"},Da=({onClick:e})=>m.jsx(x.Button,{type:"link",onClick:e,icon:m.jsx(fe.ShrinkOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Gr=({onClick:e})=>m.jsx(x.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Oa=({onClick:e})=>m.jsx(x.Button,{type:"link",onClick:e,icon:m.jsx(fe.FullscreenExitOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),Xr=({onClick:e,disabled:t})=>m.jsx(x.Button,{type:"link",onClick:e,disabled:t,icon:m.jsx(fe.CloseOutlined,{style:{fontSize:"22px",cursor:"pointer"}})}),{useToken:$a}=x.theme,Ra=p.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:a,className:i},c)=>{const{token:u}=$a(),d={borderRadius:u.borderRadiusLG};return m.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...d},className:`${Mt["minimize-windows"]} ${i}`,ref:c,children:[m.jsx("div",{className:Mt["minimize-windows-title"],title:e,children:e}),m.jsxs("div",{className:Mt["minimize-windows-operate"],children:[m.jsx(Gr,{onClick:s}),m.jsx(Xr,{onClick:a,disabled:o})]})]})}),ne={"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:ka}=x.theme,Ma=p.forwardRef((e,t)=>{const{token:r}=ka(),n={borderRadius:r.borderRadiusLG},{children:o,baseDialogProps:s,mask:a,title:i,renderFooter:c,renderTitle:u,getPopperContainer:d}=e,g=d(),[f,v]=Ur(!1),[h,y]=p.useState(!1),{open:w,close:F}=va(f,e,v,y),{footerActions:P}=ga(e,h),D=p.useRef(null),k=p.useRef(null),W=p.useRef(null),q=p.useRef(null),{containerSizeTarget:X,parentInitRecord:C,initLeft:I,initTop:T,initWidth:S,initHeight:E,curPropsWidth:O,curPropsHeight:R,setParentInitRecord:$}=ja({container:g,dialogProps:e,baseDialogProps:s}),{dialogChangeRecord:G,setDialogChangeRecord:ee}=Pa(),{dialogWidth:se,dialogHeight:he,setDialogSize:ue}=ya({initWidth:S,initHeight:E,setDialogChangeRecord:ee}),{dialogLeft:H,dialogTop:B,setDialogPosition:Y}=_a({initTop:T,initLeft:I,setDialogChangeRecord:ee}),{dialogMaxHeight:K,contentMaxHeight:zt}=Ca({visible:f,containerSizeTarget:X,dialogHeight:he,dialogRef:D,dialogHeaderRef:k,dialogFooterRef:q}),{minResizeRecord:Be,setMinResizeRecord:Ae}=Fa(),{minimizeLeft:De,minimizeTop:Ve,minimizeRef:ye,setMinimizePosition:ft}=xa(),{minimizeVisible:Ue,maximizeVisible:Lt,setMaximizeVisible:Nt,onMaximize:Se,onMinimize:Pe,onRecovery:dt,onClose:Oe}=wa({containerSizeTarget:X,dialogChangeRecord:G,close:F,setDialogSize:ue,setDialogPosition:Y}),$e=()=>{ue({width:S.current,height:E.current}),Y({left:I.current,top:T.current}),ft({left:160,top:60}),Nt(!1),Ae(null)};p.useEffect(()=>{$e()},[C]),Sa({initWidth:S,initHeight:E,curPropsWidth:O,curPropsHeight:R,setParentInitRecord:$}),qr({containerSizeTarget:X,dialogHeaderRef:k,dialogRef:D,setDialogPosition:Y}),qr({containerSizeTarget:X,dialogHeaderRef:ye,dialogRef:ye,setDialogPosition:ft});const{dialogTopShowClassConfig:Ye}=Ta({visible:f,container:g,dialogRef:D,minimizeRef:ye}),{resizingState:qe,DashedBox:Wt,onMousedownResizeLt:Ht,onMousedownResizeRt:pt,onMousedownResizeRb:ht,onMousedownResizeLb:Ee}=Ea({containerSizeTarget:X,dialogRef:D,minResizeRecord:Be,setDialogSize:ue,setDialogPosition:Y,setMinResizeRecord:Ae});return p.useImperativeHandle(t,()=>({open:w,close:Oe,setLoading:y,getVisible:()=>f})),m.jsxs("div",{className:Ye.xphDialog,children:[a&&f?m.jsx("div",{className:ne["xph-dialog-mask"]}):null,m.jsx(Ra,{visible:Ue,className:`${Ye.xphMinimizeDialog}`,loading:h,ref:ye,left:De,top:Ve,title:i,onMaximize:()=>Se("minimize"),onClosesquare:Oe}),m.jsxs("div",{ref:D,className:`${ne["xph-dialog-wrapper"]} ${Ye.xphDialogWrapper}`,style:{display:f&&!Ue?"flex":"none",left:H,top:B,width:se,height:he,maxHeight:K,opacity:qe?.2:"unset",...n},children:[m.jsxs("div",{ref:k,className:ne.dialog__header,children:[m.jsx("div",{children:u?u():i}),m.jsxs("div",{className:ne["dialog__header-btns"],children:[m.jsx(Da,{onClick:Pe}),Lt?m.jsx(Oa,{onClick:dt}):m.jsx(Gr,{onClick:()=>Se("maximize")}),m.jsx(Xr,{onClick:Oe,disabled:h})]})]}),m.jsx("div",{ref:W,className:ne.dialog__main,style:{maxHeight:zt},children:m.jsx(x.Spin,{spinning:h,children:f?o:null})}),c?m.jsx("div",{ref:q,children:c({loading:h})}):m.jsx("div",{ref:q,className:ne.dialog__footer,children:m.jsx(it,{...P})}),m.jsx("div",{className:`${ne.dialog__resize} ${ne["dialog__resize-lt"]}`,onMouseDown:Ht}),m.jsx("div",{className:`${ne.dialog__resize} ${ne["dialog__resize-rt"]}`,onMouseDown:pt}),m.jsx("div",{className:`${ne.dialog__resize} ${ne["dialog__resize-rb"]}`,onMouseDown:ht}),m.jsx("div",{className:`${ne.dialog__resize} ${ne["dialog__resize-lb"]}`,onMouseDown:Ee})]}),m.jsx(Wt,{})]})}),Ia=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=ma(n),{getPopperContainer:a}=s;return m.jsx(Jr,{getPopperContainer:a,children:m.jsx(Ma,{...s,baseDialogProps:o,ref:t,children:r})})},Kr=p.forwardRef(Ia),Jr=({children:e,getPopperContainer:t})=>{const[r,n]=p.useState(null);return p.useEffect(()=>{const o=t();n(o)},[]),r?vn.createPortal(e,r):null};function za(e){const{extendAuthProps:t}=La();return{authProps:{...ce(ce({auth:o=>!1},t),e)}}}const La=()=>{const{extendProps:e}=Fe();return{extendAuthProps:e==null?void 0:e.auth}},Na=e=>{const{children:t,...r}=e,{authProps:n}=za(r),{auth:o,authCode:s}=n;return(()=>{let i=!1;return s&&o&&(re(s)?i=s.every(c=>o(c)):i=o(s)),i})()?t:null};function at(e){return"component"in e}function lt(e){return"render"in e}function Wa(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 Ha(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 Ba=["DatePicker","MonthPicker","RangePicker","WeekPicker","TimePicker"],Va=e=>{const{show:t,ifShow:r,required:n,disabled:o,componentProps:s}=e;return!!(Q(t)||Q(r)||Q(n)||Q(o)||Q(s)||lt(e))},Ua=e=>["application/json","application/javascript","text/plain","text/html","text/css"].includes(e)?`${e}; charset=utf-8`:e,Ya=(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(nt(a)&&(c=a),nt(i)&&(u=i),Q(a)){c=a({model:t});const d=Nr(n.current)?c:n.current;p.useEffect(()=>{ot(c,d)||s&&s()},[t])}if(Q(i)){u=i({model:t});const d=Nr(o.current)?u:o.current;p.useEffect(()=>{ot(u,d)||s&&s()},[t])}return n.current=c,o.current=u,{isShow:c,isIfShow:u}},qa=(e,t)=>{const{collapsible:r,collapseNum:n}=e,[o,s]=p.useState(!!(r&&t>=n));return{itemCollapse:o,setItemCollapse:s}},Ga=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:a}=e;let i=o;const c=at(e),u=c?Wa(e.component)+s:"";function d(h,y){const w=h.message||u;return y===void 0||ia(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 g=Q(a)?a({model:t}):a;g&&(!i||i.length===0?i=[{required:g,validator:d}]:i.findIndex(y=>Reflect.has(y,"required"))===-1&&i.push({required:g,validator:d}));const f=i.findIndex(h=>Reflect.has(h,"required")&&!Reflect.has(h,"validator"));if(f!==-1){const h=i[f];if(r||(h.required=!1),c){const{component:y}=e;Reflect.has(h,"type")||(h.type=y==="InputNumber"?"number":"string"),h.message=h.message||u,(y.includes("Input")||y.includes("Textarea"))&&(h.whitespace=!0);const w=n.valueFormat;Ha(h,y,w)}}const v=i.findIndex(h=>h.max);return v!==-1&&!i[v].validator&&(i[v].message=i[v].message||`字符数应小于${i[v].max}位`),{rules:i}},Xa=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Q(s)&&(o=s({model:r})),nt(s)&&(o=s),{disabled:Reflect.has(t,"disabled")?o:n}},Ka=(e,t)=>{const r={},{componentProps:n={}}=e;return Q(n)&&Object.assign(r,n({model:t})),Object.assign(r,n),{componentProps:r}},Ja=(e,t)=>{const{colProps:r={}}=e,{colProps:n={span:24}}=t;return{colProps:{...n,...r}}},Za=({formProps:e})=>{const{items:t}=e;return{formItems:t.map(n=>({...n}))}},Qa=(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=Va(t),s=o?x.Form.useWatch(i=>r(i)):null;return{rewritingModel:p.useMemo(()=>s||r(n),[s]),isusewatch:o}},el=()=>{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(()=>()=>{e.current=null},[]),[t,r]};function tl(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 rl(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 nl(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,d]=Array.isArray(a)?a:[a,a];e[o]=Ge(i).format(u),e[s]=Ge(c).format(d),Reflect.deleteProperty(e,n)}return e}const ol=(e,t,r)=>{const n=e.filter(a=>a.name);return{handleFormatRenderValues:a=>{const i={},c=[];return n.forEach(u=>{const d=Reflect.has(a,u.name),g=tl(u.name,a)||rl(u.name,a);if(d||g){const f=g||a[u.name];if(at(u))if(Ba.includes(u.component)){if(re(f)){const v=[];for(const h of f)v.push(h?Ge(h):null);i[u.name]=v}else i[u.name]=f?Ge(f):null;c.push(u.name)}else i[u.name]=f,c.push(u.name);lt(u)&&(i[u.name]=f,c.push(u.name))}}),{renderValues:i,validKeys:c}},handleFormatReturnValues:a=>{var c,u,d,g,f;if(!ie(a))return{};const i={};for(const v of Object.entries(a)){let[,h]=v;const[y]=v;if(!y||Q(h))continue;const{transformDateFunc:w}=t,F=(d=(u=(c=r.current)==null?void 0:c.get(y))==null?void 0:u.current)==null?void 0:d.componentProps,P=F==null?void 0:F.valueFormat;if(ie(h)){const D=h;D.format&&(h=w==null?void 0:w(D,P))}re(h)&&((g=h[0])!=null&&g.format)&&((f=h[1])!=null&&f.format)&&(h=h.map(D=>w==null?void 0:w(D,P))),Rt(h)&&(h===""?h=void 0:h=h.trim()),i[y]=h}return nl(i,t)}}},sl=(e,t,r)=>({getFieldsValue:(...c)=>r(e.getFieldsValue(...c)),setFieldsValue:c=>{const{renderValues:u,validKeys:d}=t(c);e.setFieldsValue(u),e.validateFields(d)},resetFields:async()=>e.resetFields(),validator:async c=>e.validateFields(c).then(u=>r(u)),scrollToField:async(c,u)=>e.scrollToField(c,u)}),il=e=>{const{extendFormProps:t}=Zr();return{formProps:{...ce(ce({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)}}},ct=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,a=p.useRef(!0),i=p.useRef(r),c=()=>{n&&Q(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&&(ot(r,i.current)||t&&c())},[r]),{getApiData:c}},al=(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)}})}}},Zr=()=>{const{extendProps:e,extendComp:t}=Fe(),r=n=>{const o=t==null?void 0:t.form;o&&Object.keys(o).forEach(s=>{n.set(s,o[s])})};return{extendFormProps:e==null?void 0:e.form,setExtendFormComp:r}},ll=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=ct({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),d=f=>{f&&!n&&u(),s&&s(f)},g=()=>{const{api:f,params:v,immediate:h,isusewatch:y,...w}=e;return w};return m.jsx(x.Select,{...g(),options:i,onDropdownVisibleChange:d})},cl=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=ct({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),d=f=>{f&&!n&&u(),s&&s(f)},g=()=>{const{api:f,params:v,immediate:h,isusewatch:y,...w}=e;return w};return m.jsx(x.TreeSelect,{...g(),treeData:i,onDropdownVisibleChange:d})},ul=e=>{const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,a]=p.useState([]);ct({api:t,params:r,apiCallback:a,isUseWatch:o});const i=()=>{const{api:c,params:u,isusewatch:d,...g}=e;return g};return m.jsx(x.Transfer,{...i(),dataSource:s})},fl=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,a=o==="true",[i,c]=p.useState([]),{getApiData:u}=ct({api:t,immediate:n,params:r,apiCallback:c,isUseWatch:a}),d=f=>{f&&!n&&u(),s&&s(f)},g=()=>{const{api:f,params:v,immediate:h,isusewatch:y,...w}=e;return w};return m.jsx(x.AutoComplete,{...g(),options:i,onDropdownVisibleChange:d})},ve={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},dl=e=>{const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:a=!1,data:i,returnType:c=ve.String,value:u=t,onChange:d}=e,g=p.useRef(!0),f=p.useRef(0),v=p.useRef([]),[h,y]=p.useState([]),w=C=>{v.current=C,y([...C])},F=()=>{const{api:C,maxCount:I,maxSize:T,openCrop:S,beforeUpload:E,fileList:O,returnType:R,...$}=e;return $},P=C=>{const I=C.size/1024/1024<o;I||x.message.error(`文件大小超过:${o}M, 请重试`);const T=v.current.length+f.current<n;return T||x.message.error(`文件数量不能超过${n}个`),I&&T&&f.current++,I&&T&&D(C),x.Upload.LIST_IGNORE},D=C=>{a?(x.message.error("暂时不支持裁剪功能,后续兼容。。。。"),k({file:C})):k({file:C})},k=C=>{r?r({file:C.file,...i}).then(I=>{w([...v.current,...I])}).finally(()=>{f.current--}):(Object.assign(C.file,{status:"done",url:URL.createObjectURL(new Blob([C.file],{type:Ua(C.file.type)}))}),w([...v.current,C.file]),f.current--)},W=C=>{const{file:I,fileList:T}=C,{status:S}=I;switch(S){case"removed":{w([...T]);break}}},q=C=>{const I=S=>{const E=S.split("/"),O=E[E.length-1],[R]=O.split("?");return R};return{uid:(S=>{const E=v.current.find(O=>O.url===S);return E?E.uid:Gt()})(C),name:I(C),url:C,status:"done"}},X=()=>{switch(c){case ve.String:return h.map(C=>C.url).join(",");case ve["String[]"]:return h.map(C=>C.url);case ve["File[]"]:return[...h];case ve.FileList:return[...h]}};return p.useEffect(()=>{const C=X();if(ot(C,u))return;let I=[];switch(c){case ve.String:{I=(u||"").split(",").filter(T=>T).map(T=>q(T));break}case ve["String[]"]:{I=(u||[]).map(T=>q(T));break}case ve["File[]"]:{I=(u||[]).map(T=>T);break}case ve.FileList:{I=(u||[]).map(T=>T);break}}w(I)},[u]),p.useEffect(()=>{if(g.current){g.current=!1;return}const C=X();d==null||d(C)},[h]),m.jsx(x.Upload,{listType:s,...F(),fileList:h,beforeUpload:P,onChange:W,children:"上传"})},N=new Map;N.set("Input",x.Input),N.set("ApiSelect",ll),N.set("Select",x.Select),N.set("InputNumber",x.InputNumber),N.set("ApiTreeSelect",cl),N.set("TreeSelect",x.TreeSelect),N.set("ApiTransfer",ul),N.set("Transfer",x.Transfer),N.set("Switch",x.Switch),N.set("Button",x.Button),N.set("Radio",x.Radio),N.set("RadioGroup",x.Radio.Group),N.set("Checkbox",x.Checkbox),N.set("CheckboxGroup",x.Checkbox.Group),N.set("Cascader",x.Cascader),N.set("TimePicker",x.TimePicker),N.set("DatePicker",x.DatePicker),N.set("MonthPicker",x.DatePicker.MonthPicker),N.set("WeekPicker",x.DatePicker.WeekPicker),N.set("RangePicker",x.DatePicker.RangePicker),N.set("InputPassword",x.Input.Password),N.set("InputTextArea",x.Input.TextArea),N.set("ApiAutoComplete",fl),N.set("AutoComplete",x.AutoComplete),N.set("Upload",x.Upload),N.set("AutoUpload",dl);const Qr={"form-item-force":"_form-item-force_1hsf3_1","form-item-hidden":"_form-item-hidden_1hsf3_9"},pl=p.forwardRef(({itemIndex:e,itemProps:t,methods:r,formProps:n,collapseRef:o},s)=>{const{rewritingModel:a,isusewatch:i}=Qa(n,t),{isIfShow:c,isShow:u}=Ya(t,a,o),{colProps:d}=Ja(t,n),{componentProps:g}=Ka(t,a),{rules:f}=Ga({item:t,model:a,isShow:u,componentProps:g}),{disabled:v}=Xa(n,t,a),{itemCollapse:h,setItemCollapse:y}=qa(n,e),{name:w,label:F,wrapperCol:P,labelCol:D,valuePropName:k,initialValue:W,forceRow:q}=t;p.useImperativeHandle(s,()=>({itemIndex:e,componentProps:g,itemCollapse:h,setItemCollapse:y}));const X=()=>({name:w,label:F,rules:f,wrapperCol:P,labelCol:D,valuePropName:k,initialValue:W}),{setExtendFormComp:C}=Zr();C(N);const I=at(t),T=lt(t),S=()=>{if(I){const E=N.get(t.component);return m.jsx(E,{...g,disabled:v,isusewatch:i.toString()})}return T?t.render({model:a,name:w,disabled:v,methods:r,componentProps:g}):null};return m.jsxs(p.Fragment,{children:[q?m.jsx("div",{className:Qr["form-item-force"]}):null,c?m.jsx(x.Col,{...d,className:u&&!h?void 0:Qr["form-item-hidden"],children:m.jsx(x.Form.Item,{...X(),children:S()})}):null]})}),hl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},gl=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:hl["collapse-wrapper"],children:a?m.jsx(x.Button,{onClick:c,type:"link",icon:m.jsx(fe.DownOutlined,{}),children:"展开"}):m.jsx(x.Button,{onClick:i,type:"link",icon:m.jsx(fe.UpOutlined,{}),children:"折叠"})})}),ml={"group-wrapper":"_group-wrapper_g8zqi_1"},bl=({formProps:e})=>{const{renderActions:t}=e;return m.jsx("div",{className:ml["group-wrapper"],children:t==null?void 0:t()})},vl={"xph-form-action":"_xph-form-action_8ws73_1"},yl=(e,t)=>{const[r]=x.Form.useForm(),{formProps:n}=il(e),{formItems:o}=Za({formProps:n}),s=p.useRef(new Map),{collapsible:a,collapseNum:i,collapseRef:c,onClickCollapseToFalse:u,onClickCollapseToTrue:d}=al(n,s),{handleFormatRenderValues:g,handleFormatReturnValues:f}=ol(o,n,s),{setFieldsValue:v,getFieldsValue:h,resetFields:y,validator:w,scrollToField:F}=sl(r,g,f),P=()=>{const{layout:k,wrapperCol:W,labelCol:q,colon:X,disabled:C,labelWrap:I,labelAlign:T,scrollToFirstError:S,size:E}=n;return{layout:k,wrapperCol:W,labelCol:q,colon:X,disabled:C,labelWrap:I,labelAlign:T,scrollToFirstError:S,size:E}},D={setFieldsValue:v,getFieldsValue:h,resetFields:y,validator:w,scrollToField:F};return p.useImperativeHandle(t,()=>({...D})),p.useEffect(()=>(n.register&&n.register(D),()=>{s.current.clear()}),[]),m.jsxs(x.Form,{form:r,...P(),children:[m.jsx(x.Row,{children:o.map((k,W)=>(s.current.has(k.name)||s.current.set(k.name,p.createRef()),m.jsx(pl,{ref:s.current.get(k.name),itemIndex:W,itemProps:k,formProps:n,methods:D,collapseRef:c},W)))}),m.jsxs("div",{className:vl["xph-form-action"],children:[m.jsx(bl,{formProps:n}),a?m.jsx(gl,{ref:c,collapsible:o.length>i,onClickExpand:u,onClickFold:d}):null]})]})},It=p.forwardRef(yl),_l=p.memo(It),wl=p.forwardRef((e,t)=>{const{renderActions:r,showSearch:n=!0,tableRef:o}=e,[s,a]=p.useState(!1),i=p.useRef(null),c=()=>{const{reloadData:f}=o.current;f()},u=()=>{const{resetData:f}=o.current;f()},d=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(x.Button,{type:"primary",icon:m.jsx(fe.SearchOutlined,{}),onClick:c,children:"搜索"}),m.jsx(x.Button,{icon:m.jsx(fe.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),g=()=>{const{renderActions:f,...v}=e;return{...v,renderActions:d}};return p.useImperativeHandle(t,()=>({setFormLoading:a,...i.current})),m.jsx(x.Spin,{spinning:s,children:m.jsx(_l,{ref:i,...g()})})}),Cl=p.memo(It),xl=(e,t)=>{const r=p.useRef(null),n=p.useRef(null),{formProps:o}=e,a=(()=>{const{formProps:d,...g}=e;return g})(),i=p.useRef(null),c=async()=>{const{onOk:d,renderFooter:g}=a;if(!g){const{ok:f,data:v}=i.current;if(f){n.current.validator().then(async h=>{r.current.setLoading(!0),await f({values:n.current.getFieldsValue()}).then(w=>w).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),i.current=null)});return}if(d){n.current.validator().then(async h=>{r.current.setLoading(!0),await d({values:h,data:v}).then(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:d,renderFooter:g}=a;if(!g){const{cancel:f,data:v}=i.current;if(f){if(await f({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),i.current=null;return}if(d){if(await d({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 d=>{if(r.current.getVisible())return;const{renderFooter:f}=a;return!f&&(i.current=d),r.current.open().then(()=>{n.current.setFieldsValue(d.data||{})})},close:(...d)=>r.current.close(...d),setLoading:(...d)=>r.current.setLoading(...d),getVisible:(...d)=>r.current.getVisible(...d),getFieldsValue:(...d)=>n.current.getFieldsValue(...d),setFieldsValue:(...d)=>n.current.setFieldsValue(...d),resetFields:(...d)=>n.current.resetFields(...d),validator:(...d)=>n.current.validator(...d),scrollToField:(...d)=>n.current.scrollToField(...d)})),m.jsx(Kr,{...a,ref:r,onOk:c,onCancel:u,children:m.jsx(Cl,{...o,ref:n})})},en=p.forwardRef(xl);function Tl({searchForm:e}){return{searchFormRef:p.useRef(null),searchFormProps:e}}function tn(e){return"cellFunc"in e}function rn(e){return"children"in e}const{useToken:Sl}=x.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"},jl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t;return m.jsx("div",{className:El["cellfunc-actions"],children:m.jsx(it,{...n})})},{useToken:Fl}=x.theme,Al={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"}},Dl=(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}`}:Al[s]||{};return n[a]={color:c.color,backgroundColor:c.backgroundColor,border:c.border},n},{}),Ol=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:{text:o,column:s}}}=t,{token:a}=Fl(),{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}`}},d=Dl(i,s,c)[`${String(s.dataIndex)}${o}`]||{},g={padding:"0 8px",borderRadius:a.borderRadiusLG,fontSize:a.fontSizeSM,...d},f=()=>{var h;return(h=i.find(y=>y.value===o))==null?void 0:h.label};return m.jsx(e,{...r,mainHandleText:f,mainStyle:Object.assign((r==null?void 0:r.mainStyle)||{},g)})},{useToken:$l}=x.theme,nn={link:{Comp:Pl},actions:{Comp:jl},tag:{Comp:Ol},copy:{Comp:(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:o}}=t,{token:s}=$l(),{text:a,onClick:i,size:c="default"}=n,u={small:16,default:18,large:20},{copy:d}=Ul(),g=()=>{let f=o.text;if(a&&(Q(a)&&(f=a(o.record)),Rt(a)&&(f=a)),i)return i(o.record);d(f)&&x.message.success("复制成功")};return m.jsxs(m.Fragment,{children:[m.jsx("span",{onClick:g,children:m.jsx("svg",{viewBox:"0 0 1024 1024",version:"1.1",xmlns:"http://www.w3.org/2000/svg","p-id":"4503",width:u[c],height:u[c],style:{cursor:"pointer",verticalAlign:"text-top"},children:m.jsx("path",{d:"M682.666667 42.666667H85.333333v682.666666h85.333334V128h512V42.666667zM256 213.333333l4.522667 768H896V213.333333H256z m554.666667 682.666667H341.333333V298.666667h469.333334v597.333333z",fill:s.colorLink,"p-id":"4504"})})}),m.jsx(e,{...r})]})}}},Rl=(e,t)=>{var a,i;const{renderPrams:{text:r,column:n}}=e,o=(a=t==null?void 0:t.mainHandleText)==null?void 0:a.call(t),s=nt(n==null?void 0:n.ellipsis)?n==null?void 0:n.ellipsis:(i=n==null?void 0:n.ellipsis)==null?void 0:i.showTitle;return m.jsx("span",{onClick:t==null?void 0:t.mainClick,style:t==null?void 0:t.mainStyle,title:s?`${o??r}`:void 0,children:o??r})},kl=e=>{const{setExtendTableCellComp:t}=sn();t(nn);const{dslConfig:r}=e;let n=Rl.bind(null,e),o=0;for(;o<r.length;){const s=o++,a=nn[r[s].component];a&&(n=a.Comp.bind(null,n,{curComponentProps:r[s].componentProps||{},cellFuncProps:e}))}return m.jsx(n,{})};function on(e){return e.map(t=>{let r={...t};if(tn(r)){const{cellFunc:n,...o}=r;r={...o,render:(...s)=>{const a=Q(n),[i,c,u]=s,d={text:i,record:c,index:u,column:JSON.parse(JSON.stringify(o))},g=a?n(d):n;return m.jsx(kl,{dslConfig:g,renderPrams:d})}}}return rn(r)&&r.children&&Array.isArray(r.children)&&(r.children=on(r.children)),r})}function Ml(e){const{columns:t}=e.table;return{columns:on(t)}}const Il=e=>{const{extendTableProps:t}=sn();return{tableProps:{...ce(ce({table:{columns:[],fullHeight:!1,autoRequest:!0,pagination:{pageSize:20,total:0,showTotal:o=>`共:${o} 条`,current:1,pageSizeOptions:[10,20,50,100],showSizeChanger:!0,showQuickJumper:!0},requestFields:{pageSize:"pageSize",current:"current"},responseFields:{current:"current",list:"data",total:"total"}},crudFormDialog:void 0,searchForm:void 0},t),e)}}};function zl(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 Ll(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:a,responseFields:i}=e.table,c=e.onPaginationChange,{pagination:u,lastPaginationState:d}=zl(e),[g,f]=p.useState({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),v=p.useRef({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),h={model:g,update:T=>{const S={...v.current,...T};f(S),v.current=S,t.current&&t.current.setFormLoading(S.loading)}},y={validator:async()=>({}),resetFields:async()=>{}},w=async()=>{p.useEffect(()=>{const{autoRequest:T}=e.table,{validator:S}=t.current||y;T&&S().then(E=>{k({searchFormParams:E})})},[])},F=async({searchFormParams:T,paginationParams:S})=>{const E={...T,[`${a.current}`]:d.current.current,[`${a.pageSize}`]:d.current.pageSize,...S?{[`${a.current}`]:S.current,[`${a.pageSize}`]:S.pageSize}:{}};return r(E).then(O=>{const{current:R,list:$,total:G}=mt(i,O);h.update({dataSource:n?n($):$}),u.update({total:G,current:R,pageSize:E[`${a.pageSize}`]})}).finally(()=>{h.update({loading:!1})})},P=async({searchFormParams:T,paginationParams:S})=>{const E={...T};return r(E).then(O=>{const{list:R}=mt(i,O),$=n?n(R):R;h.update({selection:[],dataSource:$}),u.update({current:1,total:R.length})}).finally(()=>{h.update({loading:!1})})},D=async({searchFormParams:T,paginationParams:S})=>{var O;const E={...T};if(S){const{current:R,pageSize:$}=S;u.update({current:R,pageSize:$});const G=(R-1)*$,ee=G+$,se=(O=v.current.backupsDataSource)==null?void 0:O.slice(G,ee);return h.update({loading:!1,selection:[],dataSource:se})}else return r(E).then(R=>{let $=n?n(R):R;const G=[...$],ee=0,se=ee+d.current.pageSize;$=$.slice(ee,se),h.update({selection:[],dataSource:$,backupsDataSource:G}),u.update({current:1,total:R.length})}).finally(()=>{h.update({loading:!1})})},k=async({searchFormParams:T,paginationParams:S})=>{if(h.update({loading:!0,selection:[]}),r)switch(!!d.current){case!0:return o===!0?D({searchFormParams:T,paginationParams:S}):o===!1?P({searchFormParams:T,paginationParams:S}):F({searchFormParams:T,paginationParams:S});case!1:return P({searchFormParams:T,paginationParams:S})}return h.update({loading:!1})};return{table:h,pagination:u,firstGetTableData:w,onPaginationChange:(T,S)=>{const{validator:E}=t.current||y;E().then(O=>{k({searchFormParams:O,paginationParams:{current:T,pageSize:S}})}),c&&c(T,S)},onAllChange:async(...T)=>{const[S,E,O,R]=T,$=[];for(let G=0;G<$.length&&!$[G]();G++);s&&s(E,O,R)},resetData:async()=>{const{resetFields:T,validator:S}=t.current||y;return T().then(async()=>{const E=await S();return k({searchFormParams:E})})},resetAllData:async()=>{const{resetFields:T,validator:S}=t.current||y;return T().then(async()=>{const E={};if(d.current){const{pageSize:O}=d.current;o===void 0&&(E.paginationParams={current:1,pageSize:O})}return E.searchFormParams=await S(),k(E)})},reloadData:async()=>{const{validator:T}=t.current||y;return T().then(S=>k({searchFormParams:S}))}}}const Nl=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(Rt(n))return{type:n,onChange:(s,a,i)=>{t.update({selection:a}),r&&r(s,a)}};if(ie(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 Wl(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&&(a(o.current.offsetWidth),c(o.current.offsetHeight))};p.useEffect(()=>{const g=new ResizeObserver(u);return o.current&&g.observe(o.current),()=>{g&&o.current&&g.unobserve(o.current)}},[]);const d=p.useMemo(()=>t?n?{x:s,y:i-70,...r}:{y:i-70,...r}:{...r},[i]);return{divRef:o,scroll:d}}function Hl(e,t){const{toolbar:r}=e.table;return{getTopToolbarBindProps:()=>{if(Q(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 sn=()=>{const{extendProps:e,extendComp:t}=Fe(),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}},Bl=({crudFormDialog:e})=>({crudFormDialogRef:p.useRef(null),crudFormProps:e});function Vl(e,{target:t=document.body}={}){const r=document.createElement("textarea"),n=document.activeElement;r.value=e,r.setAttribute("readonly",""),r.style.contain="strict",r.style.position="absolute",r.style.left="-9999px",r.style.fontSize="12pt";const o=document.getSelection();let s;o&&o.rangeCount>0&&(s=o.getRangeAt(0)),t.append(r),r.select(),r.selectionStart=0,r.selectionEnd=e.length;let a=!1;try{a=document.execCommand("copy")}catch(i){throw new Error(i)}return r.remove(),s&&o&&(o.removeAllRanges(),o.addRange(s)),n&&n.focus(),a}function Ul(){function e(t){try{return Vl(t)}catch{return!1}}return{copy:e}}const ut={"main-container":"_main-container_1yx5k_1",container__toolbar:"_container__toolbar_1yx5k_13",container__table:"_container__table_1yx5k_27",container__pagination:"_container__pagination_1yx5k_35"},Yl=p.forwardRef(({tableProps:e,searchFormRef:t,fullHeight:r},n)=>{const{columns:o}=Ml(e),s=p.useRef(null),{table:a,pagination:i,firstGetTableData:c,onPaginationChange:u,onAllChange:d,resetData:g,resetAllData:f,reloadData:v}=Ll(e,t),{rowSelection:h}=Nl(e,a),{divRef:y,scroll:w}=Wl(e,r),{getTopToolbarBindProps:F}=Hl(e,a),P=()=>{const{autoRequest:D,api:k,formatDataSource:W,autoPagination:q,columns:X,scroll:C,pagination:I,rowSelection:T,onChange:S,...E}=e.table;return E};return c(),p.useImperativeHandle(n,()=>({resetData:g,resetAllData:f,reloadData:v,...s.current})),m.jsxs("div",{className:r?ut["main-container"]:void 0,children:[m.jsx("div",{className:ut.container__toolbar,children:m.jsx(it,{...F()})}),m.jsx("div",{ref:y,className:r?ut.container__table:void 0,children:m.jsx(x.Table,{ref:s,...P(),loading:a.model.loading,columns:o,dataSource:a.model.dataSource,pagination:!1,rowSelection:h,scroll:w,onChange:d})}),i.show?m.jsx("div",{className:ut.container__pagination,children:m.jsx(x.Pagination,{disabled:a.model.loading,...i.model,onChange:u})}):null]})}),an={"xph-table-full-wrapper":"_xph-table-full-wrapper_mdv0g_1","full-wrapper__table":"_full-wrapper__table_mdv0g_13"},ql=(e,t)=>{const{tableProps:r}=Il(e),n=p.useRef(null),{searchFormRef:o,searchFormProps:s}=Tl(r),{crudFormDialogRef:a,crudFormProps:i}=Bl(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?an["xph-table-full-wrapper"]:void 0,children:[s?m.jsx("div",{children:m.jsx(wl,{ref:o,tableRef:n,...s})}):null,m.jsx("div",{className:c?an["full-wrapper__table"]:void 0,children:m.jsx(Yl,{ref:n,searchFormRef:o,fullHeight:c,tableProps:r})}),i?m.jsx(en,{ref:a,...i}):null]})},Gl=p.forwardRef(ql);A.XphActions=it,A.XphAuth=Na,A.XphCrudFormDialog=en,A.XphDialog=Kr,A.XphExtendCompPropsProvider=da,A.XphForm=It,A.XphPortal=Jr,A.XphTable=Gl,A.buildUUID=Gt,A.getValueByPath=Xt,A.getValuesByPathObj=mt,A.isChildrenColumnProps=rn,A.isComponentActionItemProps=kt,A.isComponentColumnProps=tn,A.isComponentFormItemProps=at,A.isRenderActionItemProps=Hr,A.isRenderFormItemProps=lt,A.useAsyncState=Ur,A.useXphExtendCompProps=Fe,A.useXphForm=el,Object.defineProperty(A,Symbol.toStringTag,{value:"Module"})});
|
|
30
|
+
<%s key={someKey} {...props} />`,er,Ae,Tc,Ae),xn[Ae+er]=!0}}return c===n?wc(Z):bc(Z),Z}}function _c(c,b,P){return Sn(c,b,P,!0)}function Cc(c,b,P){return Sn(c,b,P,!1)}var xc=Cc,Sc=_c;ze.Fragment=n,ze.jsx=xc,ze.jsxs=Sc}()),ze}process.env.NODE_ENV==="production"?Ct.exports=Pn():Ct.exports=En();var v=Ct.exports,sr=typeof global=="object"&&global&&global.Object===Object&&global,jn=typeof self=="object"&&self&&self.Object===Object&&self,de=sr||jn||Function("return this")(),we=de.Symbol,ir=Object.prototype,Fn=ir.hasOwnProperty,An=ir.toString,Le=we?we.toStringTag:void 0;function Dn(e){var t=Fn.call(e,Le),r=e[Le];try{e[Le]=void 0;var n=!0}catch{}var o=An.call(e);return n&&(t?e[Le]=r:delete e[Le]),o}var On=Object.prototype,Mn=On.toString;function $n(e){return Mn.call(e)}var kn="[object Null]",Rn="[object Undefined]",ar=we?we.toStringTag:void 0;function fe(e){return e==null?e===void 0?Rn:kn:ar&&ar in Object(e)?Dn(e):$n(e)}function le(e){return e!=null&&typeof e=="object"}var In="[object Symbol]";function xt(e){return typeof e=="symbol"||le(e)&&fe(e)==In}function zn(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 re=Array.isArray,Ln=1/0,lr=we?we.prototype:void 0,cr=lr?lr.toString:void 0;function ur(e){if(typeof e=="string")return e;if(re(e))return zn(e,ur)+"";if(xt(e))return cr?cr.call(e):"";var t=e+"";return t=="0"&&1/e==-Ln?"-0":t}function ie(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function dr(e){return e}var Nn="[object AsyncFunction]",Bn="[object Function]",Wn="[object GeneratorFunction]",Hn="[object Proxy]";function Q(e){if(!ie(e))return!1;var t=fe(e);return t==Bn||t==Wn||t==Nn||t==Hn}var St=de["__core-js_shared__"],fr=function(){var e=/[^.]+$/.exec(St&&St.keys&&St.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Vn(e){return!!fr&&fr in e}var Un=Function.prototype,Yn=Un.toString;function Te(e){if(e!=null){try{return Yn.call(e)}catch{}try{return e+""}catch{}}return""}var qn=/[\\^$.*+?()[\]{}|]/g,Xn=/^\[object .+?Constructor\]$/,Gn=Function.prototype,Kn=Object.prototype,Jn=Gn.toString,Zn=Kn.hasOwnProperty,Qn=RegExp("^"+Jn.call(Zn).replace(qn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function eo(e){if(!ie(e)||Vn(e))return!1;var t=Q(e)?Qn:Xn;return t.test(Te(e))}function to(e,t){return e==null?void 0:e[t]}function Pe(e,t){var r=to(e,t);return eo(r)?r:void 0}var Tt=Pe(de,"WeakMap"),pr=Object.create,ro=function(){function e(){}return function(t){if(!ie(t))return{};if(pr)return pr(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function no(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 oo(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var so=800,io=16,ao=Date.now;function lo(e){var t=0,r=0;return function(){var n=ao(),o=io-(n-r);if(r=n,o>0){if(++t>=so)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function co(e){return function(){return e}}var Ze=function(){try{var e=Pe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),uo=Ze?function(e,t){return Ze(e,"toString",{configurable:!0,enumerable:!1,value:co(t),writable:!0})}:dr,fo=lo(uo),po=9007199254740991,ho=/^(?:0|[1-9]\d*)$/;function Pt(e,t){var r=typeof e;return t=t??po,!!t&&(r=="number"||r!="symbol"&&ho.test(e))&&e>-1&&e%1==0&&e<t}function Et(e,t,r){t=="__proto__"&&Ze?Ze(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Ne(e,t){return e===t||e!==e&&t!==t}var go=Object.prototype,mo=go.hasOwnProperty;function hr(e,t,r){var n=e[t];(!(mo.call(e,t)&&Ne(n,r))||r===void 0&&!(t in e))&&Et(e,t,r)}function yo(e,t,r,n){var o=!r;r||(r={});for(var s=-1,i=t.length;++s<i;){var a=t[s],l=void 0;l===void 0&&(l=e[a]),o?Et(r,a,l):hr(r,a,l)}return r}var gr=Math.max;function vo(e,t,r){return t=gr(t===void 0?e.length-1:t,0),function(){for(var n=arguments,o=-1,s=gr(n.length-t,0),i=Array(s);++o<s;)i[o]=n[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=n[o];return a[t]=r(i),no(e,this,a)}}function bo(e,t){return fo(vo(e,t,dr),e+"")}var wo=9007199254740991;function mr(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=wo}function Qe(e){return e!=null&&mr(e.length)&&!Q(e)}function _o(e,t,r){if(!ie(r))return!1;var n=typeof t;return(n=="number"?Qe(r)&&Pt(t,r.length):n=="string"&&t in r)?Ne(r[t],e):!1}function Co(e){return bo(function(t,r){var n=-1,o=r.length,s=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(s=e.length>3&&typeof s=="function"?(o--,s):void 0,i&&_o(r[0],r[1],i)&&(s=o<3?void 0:s,o=1),t=Object(t);++n<o;){var a=r[n];a&&e(t,a,n,s)}return t})}var xo=Object.prototype;function jt(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||xo;return e===r}function So(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var To="[object Arguments]";function yr(e){return le(e)&&fe(e)==To}var vr=Object.prototype,Po=vr.hasOwnProperty,Eo=vr.propertyIsEnumerable,Ft=yr(function(){return arguments}())?yr:function(e){return le(e)&&Po.call(e,"callee")&&!Eo.call(e,"callee")};function jo(){return!1}var br=typeof k=="object"&&k&&!k.nodeType&&k,wr=br&&typeof module=="object"&&module&&!module.nodeType&&module,Fo=wr&&wr.exports===br,_r=Fo?de.Buffer:void 0,Ao=_r?_r.isBuffer:void 0,et=Ao||jo,Do="[object Arguments]",Oo="[object Array]",Mo="[object Boolean]",$o="[object Date]",ko="[object Error]",Ro="[object Function]",Io="[object Map]",zo="[object Number]",Lo="[object Object]",No="[object RegExp]",Bo="[object Set]",Wo="[object String]",Ho="[object WeakMap]",Vo="[object ArrayBuffer]",Uo="[object DataView]",Yo="[object Float32Array]",qo="[object Float64Array]",Xo="[object Int8Array]",Go="[object Int16Array]",Ko="[object Int32Array]",Jo="[object Uint8Array]",Zo="[object Uint8ClampedArray]",Qo="[object Uint16Array]",es="[object Uint32Array]",q={};q[Yo]=q[qo]=q[Xo]=q[Go]=q[Ko]=q[Jo]=q[Zo]=q[Qo]=q[es]=!0,q[Do]=q[Oo]=q[Vo]=q[Mo]=q[Uo]=q[$o]=q[ko]=q[Ro]=q[Io]=q[zo]=q[Lo]=q[No]=q[Bo]=q[Wo]=q[Ho]=!1;function ts(e){return le(e)&&mr(e.length)&&!!q[fe(e)]}function rs(e){return function(t){return e(t)}}var Cr=typeof k=="object"&&k&&!k.nodeType&&k,Be=Cr&&typeof module=="object"&&module&&!module.nodeType&&module,ns=Be&&Be.exports===Cr,At=ns&&sr.process,xr=function(){try{var e=Be&&Be.require&&Be.require("util").types;return e||At&&At.binding&&At.binding("util")}catch{}}(),Sr=xr&&xr.isTypedArray,Dt=Sr?rs(Sr):ts,os=Object.prototype,ss=os.hasOwnProperty;function Tr(e,t){var r=re(e),n=!r&&Ft(e),o=!r&&!n&&et(e),s=!r&&!n&&!o&&Dt(e),i=r||n||o||s,a=i?So(e.length,String):[],l=a.length;for(var u in e)(t||ss.call(e,u))&&!(i&&(u=="length"||o&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||Pt(u,l)))&&a.push(u);return a}function Pr(e,t){return function(r){return e(t(r))}}var is=Pr(Object.keys,Object),as=Object.prototype,ls=as.hasOwnProperty;function cs(e){if(!jt(e))return is(e);var t=[];for(var r in Object(e))ls.call(e,r)&&r!="constructor"&&t.push(r);return t}function us(e){return Qe(e)?Tr(e):cs(e)}function ds(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var fs=Object.prototype,ps=fs.hasOwnProperty;function hs(e){if(!ie(e))return ds(e);var t=jt(e),r=[];for(var n in e)n=="constructor"&&(t||!ps.call(e,n))||r.push(n);return r}function Er(e){return Qe(e)?Tr(e,!0):hs(e)}var gs=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ms=/^\w*$/;function ys(e,t){if(re(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||xt(e)?!0:ms.test(e)||!gs.test(e)||t!=null&&e in Object(t)}var We=Pe(Object,"create");function vs(){this.__data__=We?We(null):{},this.size=0}function bs(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var ws="__lodash_hash_undefined__",_s=Object.prototype,Cs=_s.hasOwnProperty;function xs(e){var t=this.__data__;if(We){var r=t[e];return r===ws?void 0:r}return Cs.call(t,e)?t[e]:void 0}var Ss=Object.prototype,Ts=Ss.hasOwnProperty;function Ps(e){var t=this.__data__;return We?t[e]!==void 0:Ts.call(t,e)}var Es="__lodash_hash_undefined__";function js(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=We&&t===void 0?Es:t,this}function Ee(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])}}Ee.prototype.clear=vs,Ee.prototype.delete=bs,Ee.prototype.get=xs,Ee.prototype.has=Ps,Ee.prototype.set=js;function Fs(){this.__data__=[],this.size=0}function tt(e,t){for(var r=e.length;r--;)if(Ne(e[r][0],t))return r;return-1}var As=Array.prototype,Ds=As.splice;function Os(e){var t=this.__data__,r=tt(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Ds.call(t,r,1),--this.size,!0}function Ms(e){var t=this.__data__,r=tt(t,e);return r<0?void 0:t[r][1]}function $s(e){return tt(this.__data__,e)>-1}function ks(e,t){var r=this.__data__,n=tt(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,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=Fs,he.prototype.delete=Os,he.prototype.get=Ms,he.prototype.has=$s,he.prototype.set=ks;var He=Pe(de,"Map");function Rs(){this.size=0,this.__data__={hash:new Ee,map:new(He||he),string:new Ee}}function Is(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function rt(e,t){var r=e.__data__;return Is(t)?r[typeof t=="string"?"string":"hash"]:r.map}function zs(e){var t=rt(this,e).delete(e);return this.size-=t?1:0,t}function Ls(e){return rt(this,e).get(e)}function Ns(e){return rt(this,e).has(e)}function Bs(e,t){var r=rt(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,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=Rs,ge.prototype.delete=zs,ge.prototype.get=Ls,ge.prototype.has=Ns,ge.prototype.set=Bs;var Ws="Expected a function";function Ot(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Ws);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],s=r.cache;if(s.has(o))return s.get(o);var i=e.apply(this,n);return r.cache=s.set(o,i)||s,i};return r.cache=new(Ot.Cache||ge),r}Ot.Cache=ge;var Hs=500;function Vs(e){var t=Ot(e,function(n){return r.size===Hs&&r.clear(),n}),r=t.cache;return t}var Us=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ys=/\\(\\)?/g,qs=Vs(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Us,function(r,n,o,s){t.push(o?s.replace(Ys,"$1"):n||r)}),t});function Xs(e){return e==null?"":ur(e)}function Gs(e,t){return re(e)?e:ys(e,t)?[e]:qs(Xs(e))}var Ks=1/0;function Js(e){if(typeof e=="string"||xt(e))return e;var t=e+"";return t=="0"&&1/e==-Ks?"-0":t}function Zs(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var jr=Pr(Object.getPrototypeOf,Object),Qs="[object Object]",ei=Function.prototype,ti=Object.prototype,Fr=ei.toString,ri=ti.hasOwnProperty,ni=Fr.call(Object);function oi(e){if(!le(e)||fe(e)!=Qs)return!1;var t=jr(e);if(t===null)return!0;var r=ri.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Fr.call(r)==ni}function si(){this.__data__=new he,this.size=0}function ii(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function ai(e){return this.__data__.get(e)}function li(e){return this.__data__.has(e)}var ci=200;function ui(e,t){var r=this.__data__;if(r instanceof he){var n=r.__data__;if(!He||n.length<ci-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new ge(n)}return r.set(e,t),this.size=r.size,this}function me(e){var t=this.__data__=new he(e);this.size=t.size}me.prototype.clear=si,me.prototype.delete=ii,me.prototype.get=ai,me.prototype.has=li,me.prototype.set=ui;var Ar=typeof k=="object"&&k&&!k.nodeType&&k,Dr=Ar&&typeof module=="object"&&module&&!module.nodeType&&module,di=Dr&&Dr.exports===Ar,Or=di?de.Buffer:void 0;Or&&Or.allocUnsafe;function fi(e,t){return e.slice()}function pi(e,t){for(var r=-1,n=e==null?0:e.length,o=0,s=[];++r<n;){var i=e[r];t(i,r,e)&&(s[o++]=i)}return s}function hi(){return[]}var gi=Object.prototype,mi=gi.propertyIsEnumerable,Mr=Object.getOwnPropertySymbols,yi=Mr?function(e){return e==null?[]:(e=Object(e),pi(Mr(e),function(t){return mi.call(e,t)}))}:hi;function vi(e,t,r){var n=t(e);return re(e)?n:Zs(n,r(e))}function $r(e){return vi(e,us,yi)}var Mt=Pe(de,"DataView"),$t=Pe(de,"Promise"),kt=Pe(de,"Set"),kr="[object Map]",bi="[object Object]",Rr="[object Promise]",Ir="[object Set]",zr="[object WeakMap]",Lr="[object DataView]",wi=Te(Mt),_i=Te(He),Ci=Te($t),xi=Te(kt),Si=Te(Tt),_e=fe;(Mt&&_e(new Mt(new ArrayBuffer(1)))!=Lr||He&&_e(new He)!=kr||$t&&_e($t.resolve())!=Rr||kt&&_e(new kt)!=Ir||Tt&&_e(new Tt)!=zr)&&(_e=function(e){var t=fe(e),r=t==bi?e.constructor:void 0,n=r?Te(r):"";if(n)switch(n){case wi:return Lr;case _i:return kr;case Ci:return Rr;case xi:return Ir;case Si:return zr}return t});var nt=de.Uint8Array;function Ti(e){var t=new e.constructor(e.byteLength);return new nt(t).set(new nt(e)),t}function Pi(e,t){var r=Ti(e.buffer);return new e.constructor(r,e.byteOffset,e.length)}function Ei(e){return typeof e.constructor=="function"&&!jt(e)?ro(jr(e)):{}}var ji="__lodash_hash_undefined__";function Fi(e){return this.__data__.set(e,ji),this}function Ai(e){return this.__data__.has(e)}function ot(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new ge;++t<r;)this.add(e[t])}ot.prototype.add=ot.prototype.push=Fi,ot.prototype.has=Ai;function Di(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 Oi(e,t){return e.has(t)}var Mi=1,$i=2;function Nr(e,t,r,n,o,s){var i=r&Mi,a=e.length,l=t.length;if(a!=l&&!(i&&l>a))return!1;var u=s.get(e),f=s.get(t);if(u&&f)return u==t&&f==e;var p=-1,d=!0,g=r&$i?new ot:void 0;for(s.set(e,t),s.set(t,e);++p<a;){var h=e[p],y=t[p];if(n)var w=i?n(y,h,p,t,e,s):n(h,y,p,e,t,s);if(w!==void 0){if(w)continue;d=!1;break}if(g){if(!Di(t,function(D,T){if(!Oi(g,T)&&(h===D||o(h,D,r,n,s)))return g.push(T)})){d=!1;break}}else if(!(h===y||o(h,y,r,n,s))){d=!1;break}}return s.delete(e),s.delete(t),d}function ki(e){var t=-1,r=Array(e.size);return e.forEach(function(n,o){r[++t]=[o,n]}),r}function Ri(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Ii=1,zi=2,Li="[object Boolean]",Ni="[object Date]",Bi="[object Error]",Wi="[object Map]",Hi="[object Number]",Vi="[object RegExp]",Ui="[object Set]",Yi="[object String]",qi="[object Symbol]",Xi="[object ArrayBuffer]",Gi="[object DataView]",Br=we?we.prototype:void 0,Rt=Br?Br.valueOf:void 0;function Ki(e,t,r,n,o,s,i){switch(r){case Gi:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Xi:return!(e.byteLength!=t.byteLength||!s(new nt(e),new nt(t)));case Li:case Ni:case Hi:return Ne(+e,+t);case Bi:return e.name==t.name&&e.message==t.message;case Vi:case Yi:return e==t+"";case Wi:var a=ki;case Ui:var l=n&Ii;if(a||(a=Ri),e.size!=t.size&&!l)return!1;var u=i.get(e);if(u)return u==t;n|=zi,i.set(e,t);var f=Nr(a(e),a(t),n,o,s,i);return i.delete(e),f;case qi:if(Rt)return Rt.call(e)==Rt.call(t)}return!1}var Ji=1,Zi=Object.prototype,Qi=Zi.hasOwnProperty;function ea(e,t,r,n,o,s){var i=r&Ji,a=$r(e),l=a.length,u=$r(t),f=u.length;if(l!=f&&!i)return!1;for(var p=l;p--;){var d=a[p];if(!(i?d in t:Qi.call(t,d)))return!1}var g=s.get(e),h=s.get(t);if(g&&h)return g==t&&h==e;var y=!0;s.set(e,t),s.set(t,e);for(var w=i;++p<l;){d=a[p];var D=e[d],T=t[d];if(n)var _=i?n(T,D,d,t,e,s):n(D,T,d,e,t,s);if(!(_===void 0?D===T||o(D,T,r,n,s):_)){y=!1;break}w||(w=d=="constructor")}if(y&&!w){var F=e.constructor,j=t.constructor;F!=j&&"constructor"in e&&"constructor"in t&&!(typeof F=="function"&&F instanceof F&&typeof j=="function"&&j instanceof j)&&(y=!1)}return s.delete(e),s.delete(t),y}var ta=1,Wr="[object Arguments]",Hr="[object Array]",st="[object Object]",ra=Object.prototype,Vr=ra.hasOwnProperty;function na(e,t,r,n,o,s){var i=re(e),a=re(t),l=i?Hr:_e(e),u=a?Hr:_e(t);l=l==Wr?st:l,u=u==Wr?st:u;var f=l==st,p=u==st,d=l==u;if(d&&et(e)){if(!et(t))return!1;i=!0,f=!1}if(d&&!f)return s||(s=new me),i||Dt(e)?Nr(e,t,r,n,o,s):Ki(e,t,l,r,n,o,s);if(!(r&ta)){var g=f&&Vr.call(e,"__wrapped__"),h=p&&Vr.call(t,"__wrapped__");if(g||h){var y=g?e.value():e,w=h?t.value():t;return s||(s=new me),o(y,w,r,n,s)}}return d?(s||(s=new me),ea(e,t,r,n,o,s)):!1}function Ur(e,t,r,n,o){return e===t?!0:e==null||t==null||!le(e)&&!le(t)?e!==e&&t!==t:na(e,t,r,n,Ur,o)}function oa(e){return function(t,r,n){for(var o=-1,s=Object(t),i=n(t),a=i.length;a--;){var l=i[++o];if(r(s[l],l,s)===!1)break}return t}}var sa=oa();function It(e,t,r){(r!==void 0&&!Ne(e[t],r)||r===void 0&&!(t in e))&&Et(e,t,r)}function ia(e){return le(e)&&Qe(e)}function zt(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function aa(e){return yo(e,Er(e))}function la(e,t,r,n,o,s,i){var a=zt(e,r),l=zt(t,r),u=i.get(l);if(u){It(e,r,u);return}var f=s?s(a,l,r+"",e,t,i):void 0,p=f===void 0;if(p){var d=re(l),g=!d&&et(l),h=!d&&!g&&Dt(l);f=l,d||g||h?re(a)?f=a:ia(a)?f=oo(a):g?(p=!1,f=fi(l)):h?(p=!1,f=Pi(l)):f=[]:oi(l)||Ft(l)?(f=a,Ft(a)?f=aa(a):(!ie(a)||Q(a))&&(f=Ei(l))):p=!1}p&&(i.set(l,f),o(f,l,n,s,i),i.delete(l)),It(e,r,f)}function Yr(e,t,r,n,o){e!==t&&sa(t,function(s,i){if(o||(o=new me),ie(s))la(e,t,i,r,Yr,n,o);else{var a=n?n(zt(e,i),s,i+"",e,t,o):void 0;a===void 0&&(a=s),It(e,i,a)}},Er)}var ca="[object String]";function Lt(e){return typeof e=="string"||!re(e)&&le(e)&&fe(e)==ca}var ua="[object Boolean]";function it(e){return e===!0||e===!1||le(e)&&fe(e)==ua}function at(e,t){return Ur(e,t)}var da="[object Number]";function fa(e){return typeof e=="number"||le(e)&&fe(e)==da}function qr(e){return e==null}function pa(e){return e===null}var ce=Co(function(e,t,r){Yr(e,t,r)});function ha(e,t,r,n){if(!ie(e))return e;t=Gs(t,e);for(var o=-1,s=t.length,i=s-1,a=e;a!=null&&++o<s;){var l=Js(t[o]),u=r;if(l==="__proto__"||l==="constructor"||l==="prototype")return e;if(o!=i){var f=a[l];u=void 0,u===void 0&&(u=ie(f)?f:Pt(t[o+1])?[]:{})}hr(a,l,u),a=a[l]}return e}function Xr(e,t,r){return e==null?e:ha(e,t,r)}function ga(e){const{inherit:t=!0}=e,{extendActionsProps:r,extendAuthProps:n}=Qr(),s={...ce(ce({items:[],max:10},t?r:{}),e)},i={...ce({auth:()=>!0},t?n:{})};return{actionsProps:s,authProps:i}}function Nt(e){return"component"in e}function Gr(e){return"render"in e}function ma(e,t){const{type:r,disabled:n,items:o,max:s}=e,i=p=>{const{auth:d}=p;let g=!1;return d?re(d)?g=d.every(h=>t(h)):g=t(d):g=!0,g},a=p=>{let{ifShow:d=!0}=p;return d=d&&Q(d)?d():d,d&&i(p)},l=p=>{const{component:d,render:g,componentProps:h}=p;if(d)switch(d){case"Dropdown":{const{dropDownItems:y}=h;return!!y.length}default:return!0}return!!g},u=o.map(p=>{const d={...p};if(Nt(d)){const g=d.component;switch(d.componentProps={type:r,disabled:n,...d.componentProps},g){case"Dropdown":{d.componentProps.dropDownItems=(d.componentProps.dropDownItems||[]).filter(a);break}}}return d}).filter(a).filter(l),f=fa(s)&&s>=0;return{showActionItems:u.slice(0,f?s:u.length),ellipsisActionItems:u.slice(f?s:u.length)}}const ya=e=>{const{componentProps:t}=e,r=()=>{const{...n}=t;return n};return v.jsx(E.Button,{...r()})},va=e=>{const{componentProps:t}=e,n=(()=>{const{dropDownItems:o,onClick:s,...i}=t;return i})();return v.jsx(E.Dropdown,{disabled:n.disabled,menu:{items:t==null?void 0:t.dropDownItems,onClick:t==null?void 0:t.onClick},trigger:["click"],children:v.jsx("div",{children:v.jsxs(E.Button,{...n,children:[n.children,v.jsx(ue.CaretDownOutlined,{})]})})})},lt=new Map;lt.set("Button",ya),lt.set("Dropdown",va);function Kr(){const{setExtendActionsComp:e}=Qr();return e(lt),{renderContent:m.useCallback((r,n)=>{const o=Nt(r),s=Gr(r);if(o){const i=lt.get(r.component);return m.createElement(i,{...r,key:n})}return s?v.jsx("div",{children:r.render},n):null},[])}}const Jr=m.createContext({}),ba=e=>{const{extendProps:t,extendComp:r}=e.value;return v.jsx(Jr.Provider,{value:{extendProps:t,extendComp:r},children:e.children})},De=()=>m.useContext(Jr),Zr=e=>{const[t,r]=m.useState(e),n=m.useRef(null);return m.useEffect(()=>{n.current&&(n.current(),n.current=null)},[t]),[t,s=>new Promise((i,a)=>{r(l=>{const u=typeof s=="function"?s(l):s;return n.current=i,u})})]},Qr=()=>{const{extendProps:e,extendComp:t}=De(),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:wa}=E.theme,_a=({items:e,actionsProps:t})=>{const{type:r,disabled:n}=t,{renderContent:o}=Kr(),{token:s}=wa(),i={backgroundColor:s.colorBgElevated,borderRadius:s.borderRadiusLG,boxShadow:s.boxShadowSecondary},a=()=>v.jsx("div",{style:i,children:v.jsx(E.Space,{style:{padding:8},children:e==null?void 0:e.map((l,u)=>o(l,u))})});return v.jsx(E.Dropdown,{disabled:n,menu:{items:[]},dropdownRender:a,trigger:["click"],children:v.jsxs(E.Button,{type:r,children:["更多",v.jsx(ue.CaretDownOutlined,{})]})})},ct=e=>{const{actionsProps:t,authProps:r}=ga(e),{auth:n}=r,{showActionItems:o,ellipsisActionItems:s}=ma(t,n),{renderContent:i}=Kr();return t!=null&&t.render?t.render:v.jsxs(m.Fragment,{children:[o==null?void 0:o.map((a,l)=>i(a,l)),s!=null&&s.length?v.jsx(_a,{actionsProps:t,items:s}):null]})};function Ca(e,t){const{okText:r,cancelText:n,onCancel:o,onOk:s,okProps:i,cancelProps:a}=e;return{footerActions:{disabled:t,max:2,items:[{component:"Button",componentProps:{...a,children:n,onClick:o}},{component:"Button",componentProps:{type:"primary",loading:t,...i,children:r,onClick:s}}]}}}const xa=e=>{const{extendDialogProps:t}=Sa(),r={width:700,okText:"确定",cancelText:"取消",getPopperContainer:()=>document.body};return{dialogProps:{...ce(ce(r,t),e)},baseDialogProps:r}},Sa=()=>{const{extendProps:e}=De();return{extendDialogProps:e==null?void 0:e.dialog}},Ta=(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()}}},Pa=({initWidth:e,initHeight:t,setDialogChangeRecord:r})=>{const[n,o]=m.useState(e.current),[s,i]=m.useState(t.current);return{dialogWidth:n,dialogHeight:s,setDialogSize:({width:l,height:u})=>{r({width:n,height:s}),l!==void 0&&o(l),u!==void 0&&i(u)}}},Ea=({initLeft:e,initTop:t,setDialogChangeRecord:r})=>{const[n,o]=m.useState(e.current),[s,i]=m.useState(t.current);return{dialogLeft:n,dialogTop:s,setDialogPosition:({left:l,top:u})=>{r({left:n,top:s}),l!==void 0&&o(l),u!==void 0&&i(u)}}},en=({containerSizeTarget:e,dialogHeaderRef:t,dialogRef:r,setDialogPosition:n})=>{const o=m.useRef(0),s=m.useRef(0),i=f=>{const p=f.getBoundingClientRect(),d=p.width,g=p.height,h=-.5*d,y=-.5*g;return{translateX:h,translateY:y}},a=m.useCallback(f=>{const{offsetLeft:p,offsetTop:d}=r.current;o.current=f.clientX-p,s.current=f.clientY-d,document.addEventListener("mousemove",l),document.addEventListener("mouseup",u)},[]),l=m.useCallback(f=>{const p=r.current,{translateX:d,translateY:g}=i(p);let h=f.clientX-o.current,y=f.clientY-s.current;const w=-d,D=-g,T=e.current.scrollWidth-p.offsetWidth-d,_=e.current.scrollHeight-p.offsetHeight-g;h<w&&(h=w),h>T&&(h=T),y<D&&(y=D),y>_&&(y=_),n({left:h,top:y})},[]),u=m.useCallback(()=>{document.removeEventListener("mousemove",l),document.removeEventListener("mouseup",u)},[]);return m.useEffect(()=>{const f=t.current;return f.addEventListener("mousedown",a),()=>{f.removeEventListener("mousedown",a)}},[]),{}},ja=({containerSizeTarget:e,dialogChangeRecord:t,close:r,setDialogSize:n,setDialogPosition:o})=>{const[s,i]=m.useState(!1),[a,l]=m.useState(!1);return{minimizeVisible:s,maximizeVisible:a,setMinimizeVisible:i,setMaximizeVisible:l,onMinimize:()=>{i(!0)},onMaximize:g=>{if(g==="minimize"&&i(!1),g==="maximize"){const{scrollWidth:h,scrollHeight:y}=e.current,w=Math.floor(h),D=Math.floor(y),T=Math.floor(h/2),_=Math.floor(y/2);n({width:w,height:D}),o({top:_,left:T}),l(!0)}},onRecovery:()=>{const{top:g,left:h,width:y,height:w}=t.current;n({width:y,height:w}),o({top:g,left:h}),l(!1)},onClose:()=>{i(!1),r()}}},Fa=({visible:e,containerSizeTarget:t,dialogHeight:r,dialogRef:n,dialogHeaderRef:o,dialogFooterRef:s})=>{const{clientHeight:i,scrollHeight:a}=t.current,l=typeof r=="number"&&r>i?a:i,[u,f]=m.useState(0),[p,d]=m.useState("unset"),g=m.useCallback(()=>{const y=n.current;return l>0&&(y==null?void 0:y.isConnected)&&y.getClientRects().length>0},[l,n]),h=m.useCallback((y,w)=>{var B,x;const _=((B=o.current)==null?void 0:B.offsetHeight)??0,F=((x=s.current)==null?void 0:x.offsetHeight)??0;let j=y-_-F-0;const R=w-_-F-0;return j>R&&(j=R),Math.max(0,j)},[o,s]);return m.useEffect(()=>{var y;if(!(!e||!g())&&u===l){const w=(y=n.current)==null?void 0:y.getBoundingClientRect().height;d(h(w,l)),f("unset")}},[e,u,l,n,h,g]),m.useEffect(()=>{!e||!g()||r!=="unset"&&r!==0&&(d(h(r,l)),f("unset"))},[e,r,l,h,g]),m.useEffect(()=>{if(e){if(!g())return;d("unset"),f(l)}else f(0),d("unset")},[e,l,g]),{dialogMaxHeight:u,contentMaxHeight:p}},Aa=()=>{const[e,t]=m.useState(160),[r,n]=m.useState(60),o=m.useRef(null);return{minimizeTop:r,minimizeLeft:e,minimizeRef:o,setMinimizePosition:({left:i,top:a})=>{i!==void 0&&t(i),a!==void 0&&n(a)}}},Da=({visible:e,dialogRef:t,minimizeRef:r,container:n})=>{const o={xphDialog:"xph--dialog",xphDialogWrapper:"xph--dialog--wrapper",xphMinimizeDialog:"xph--dialog--minimize"},s=l=>{Array.from(n.children).forEach(u=>{u.classList.contains(o.xphDialog)&&u.setAttribute("data-xph-dialog-active",String(u===l))})},i=(l,u)=>{s(l);const f=document.createElement("div");f.style.visibility="hidden",u.parentNode.insertBefore(f,u.nextSibling),u.parentNode.insertBefore(l,f),u.parentNode.removeChild(f)},a=l=>{var d;const u=Array.from(n.querySelectorAll(`.${o.xphDialog}`)).filter(g=>(g==null?void 0:g.parentNode)===n),f=u[u.length-1],p=(d=t.current)==null?void 0:d.parentElement;if(!(!p||!f)){if(p===f){s(p);return}if(i(p,f),l){const g=l.target;g.tagName==="INPUT"&&g.focus&&g.focus()}}};return m.useEffect(()=>{var l,u;return(l=t.current)==null||l.addEventListener("mousedown",a,!1),(u=r.current)==null||u.addEventListener("mousedown",a,!1),()=>{var f,p;(f=t.current)==null||f.removeEventListener("mousedown",a,!1),(p=r.current)==null||p.removeEventListener("mousedown",a,!1)}},[]),m.useEffect(()=>{if(e)a();else{const l=Array.from(n.querySelectorAll(`.${o.xphDialog}`)).filter(g=>(g==null?void 0:g.parentNode)===n),u=l.map(g=>g.querySelector(`.${o.xphDialogWrapper}`)).filter(g=>g!==null),f=l.map(g=>g.querySelector(`.${o.xphMinimizeDialog}`)).filter(g=>g!==null),p=u.filter(g=>g.style.display==="flex"),d=f.filter(g=>g.style.display==="flex");if(p.length){i(p[p.length-1].parentNode,l[l.length-1]);return}if(d.length){i(d[d.length-1].parentNode,l[l.length-1]);return}}},[e]),{dialogTopShowClassConfig:o}},Oa=({curPropsWidth:e,curPropsHeight:t,setParentInitRecord:r})=>{const n=m.useRef({width:e,height:t});m.useEffect(()=>{const o=n.current;n.current={width:e,height:t},(e!==o.width||t!==o.height)&&r(s=>s+1)},[e,t,r])},Ma=()=>{const e=m.useRef({left:0,top:0,width:0,height:0});return{dialogChangeRecord:e,setDialogChangeRecord:({left:r,top:n,width:o,height:s})=>{const{left:i,top:a,width:l,height:u}=e.current;e.current={left:r??i,top:n??a,width:o??l,height:s??u}}}},$a=({containerSizeTarget:e,dialogRef:t,minResizeRecord:r,setDialogSize:n,setDialogPosition:o,setMinResizeRecord:s})=>{const i=m.useCallback(()=>v.jsx("div",{ref:a,style:{position:"absolute",border:"4px dashed #ccc",display:"none",zIndex:999}}),[]),a=m.useRef(null),l=m.useRef(),u=m.useRef(!1),[f,p]=m.useState(!1),d=m.useRef(0),g=m.useRef(0),h=(x,A)=>{r.current||s({width:t.current.offsetWidth,height:t.current.offsetHeight}),u.current=!0,p(!0),l.current=A;const{clientX:S,clientY:C}=x;d.current=S,g.current=C;const O=parseFloat(t.current.style.left),M=parseFloat(t.current.style.top),I=t.current.offsetWidth,z=t.current.offsetHeight;a.current.style.display="block",a.current.style.left=`${O-.5*I}px`,a.current.style.top=`${M-.5*z}px`,a.current.style.width=`${I}px`,a.current.style.height=`${z}px`},y=x=>{if(u.current){const{clientX:A,clientY:S}=x,C=A-d.current,O=S-g.current,M=parseFloat(a.current.style.left),I=parseFloat(a.current.style.top),z=a.current.offsetWidth,G=a.current.offsetHeight,ne=r.current.width,se=r.current.height,be=e.current.scrollWidth,pe=e.current.scrollHeight;let U=z,H=G,X=M,K=I;switch(l.current){case"lt":{U=U-C,H=H-O,K=K+O,X=X+C,U<ne&&(U=z,X=M),H<se&&(H=G,K=I),X<0&&(X=0,U=z),K<0&&(K=0,H=G);break}case"rt":{U=U+C,H=H-O,K=K+O,X=M,U<ne&&(U=z),H<se&&(H=G,K=I),U>be-X&&(U=be-X),K<0&&(K=0,H=G);break}case"rb":{U=U+C,H=H+O,K=I,X=M,U<ne&&(U=z),H<se&&(H=G),U>be-X&&(U=be-X),H>pe-K&&(H=pe-K);break}case"lb":{U=U-C,H=H+O,K=I,X=X+C,U<ne&&(U=z,X=M),H<se&&(H=G),X<0&&(X=0,U=z),H>pe-K&&(H=pe-K);break}}a.current.style.left=`${X}px`,a.current.style.top=`${K}px`,a.current.style.width=`${U}px`,a.current.style.height=`${H}px`,d.current=A,g.current=S}},w=()=>{if(u.current){u.current=!1,p(!1),a.current.style.display="none";const{left:x,top:A,width:S,height:C}=a.current.style,O=parseFloat(x)+.5*parseFloat(S),M=parseFloat(A)+.5*parseFloat(C),I=parseFloat(S),z=parseFloat(C);o({left:O,top:M}),n({width:I,height:z})}},D=x=>h(x,"lt"),T=x=>h(x,"rt"),_=x=>h(x,"rb"),F=x=>h(x,"lb"),j=m.useCallback(x=>{y(x)},[]),R=m.useCallback(()=>{w()},[]),B=m.useCallback(()=>{w()},[]);return m.useEffect(()=>(document.body.addEventListener("mousemove",j),document.body.addEventListener("mouseup",R),document.body.addEventListener("mouseleave",B),()=>{document.body.removeEventListener("mousemove",j),document.body.removeEventListener("mouseup",R),document.body.removeEventListener("mouseleave",B)}),[]),{resizingState:f,DashedBox:i,onMousedownResizeLt:D,onMousedownResizeRt:T,onMousedownResizeRb:_,onMousedownResizeLb:F}},ka=({container:e,dialogProps:t,baseDialogProps:r})=>{const[n,o]=m.useState(0),{containerSizeTarget:s,setContainerSizeTarget:i}=Ia({container:e,mask:t.mask}),[a,l]=m.useState(()=>e.isConnected&&s.current.clientWidth>0&&s.current.clientHeight>0);m.useEffect(()=>{const A=()=>{const C=s.current,O=i();if(l(O),!O)return;const M=s.current;C.clientWidth===M.clientWidth&&C.clientHeight===M.clientHeight||o(I=>I+1)};l(i()),o(C=>C+1),window.addEventListener("resize",A);const S=typeof ResizeObserver>"u"?void 0:new ResizeObserver(A);return S==null||S.observe(e===document.body?document.documentElement:e),()=>{window.removeEventListener("resize",A),S==null||S.disconnect()}},[e,t.mask,s,i]);const{width:u,height:f}=r,{width:p,height:d}=t,g=p||u,h=d||f,{clientWidth:y,clientHeight:w}=s.current,D=g?g>y?y:g:0,T=h?h>w?w:h:"unset",_=m.useRef(D),F=m.useRef(T),j=A=>{_.current=A.width,F.current=A.height},R=m.useRef(Math.floor(y/2)),B=m.useRef(Math.floor(w/2)),x=A=>{R.current=A.left,B.current=A.top};return m.useEffect(()=>{j({width:D,height:T}),x({left:Math.floor(y/2),top:Math.floor(w/2)})},[n,y,w,D,T]),{containerSizeTarget:s,containerMeasurable:a,parentInitRecord:n,initLeft:R,initTop:B,initWidth:_,initHeight:F,curPropsWidth:D,curPropsHeight:T,setInitPosition:x,setInitSize:j,setParentInitRecord:o}},Ra=()=>{const e=m.useRef(null);return{minResizeRecord:e,setMinResizeRecord:r=>{e.current=r}}},Ia=({container:e,mask:t})=>{const r=e===document.body,n=m.useCallback(()=>{const i=r?t?document.documentElement.clientWidth:window.innerWidth:e.clientWidth,a=r?t?document.documentElement.clientHeight:window.innerHeight:e.clientHeight;return{clientWidth:i,clientHeight:a,scrollWidth:t||r?i:e.scrollWidth,scrollHeight:t||r?a:e.scrollHeight}},[e,r,t]),o=m.useRef(n()),s=m.useCallback(()=>{const i=n();return!e.isConnected||i.clientWidth<=0||i.clientHeight<=0?!1:(o.current=i,!0)},[e,n]);return{containerSizeTarget:o,setContainerSizeTarget:s}},Bt={"minimize-windows":"_minimize-windows_y0g8r_1","minimize-windows-title":"_minimize-windows-title_y0g8r_59","minimize-windows-operate":"_minimize-windows-operate_y0g8r_79"},ye={"window-control":"_window-control_1j8ma_3","window-control-icon":"_window-control-icon_1j8ma_31","window-control-close":"_window-control-close_1j8ma_61"},za=({onClick:e})=>v.jsx(E.Button,{type:"text",className:ye["window-control"],"aria-label":"最小化",title:"最小化",onClick:e,icon:v.jsx(ue.MinusOutlined,{className:ye["window-control-icon"]})}),tn=({onClick:e})=>v.jsx(E.Button,{type:"text",className:ye["window-control"],"aria-label":"最大化",title:"最大化",onClick:e,icon:v.jsx(ue.BorderOutlined,{className:ye["window-control-icon"]})}),La=({onClick:e})=>v.jsx(E.Button,{type:"text",className:ye["window-control"],"aria-label":"还原",title:"还原",onClick:e,icon:v.jsx(ue.CopyOutlined,{className:ye["window-control-icon"]})}),rn=({onClick:e,disabled:t})=>v.jsx(E.Button,{type:"text",className:`${ye["window-control"]} ${ye["window-control-close"]}`,"aria-label":"关闭",title:"关闭",onClick:e,disabled:t,icon:v.jsx(ue.CloseOutlined,{className:ye["window-control-icon"]})}),{useToken:Na}=E.theme,Ba=m.forwardRef(({title:e,left:t,top:r,visible:n,loading:o,onMaximize:s,onClosesquare:i,className:a},l)=>{const{token:u}=Na(),f={borderRadius:u.borderRadiusLG};return v.jsxs("div",{style:{display:n?"flex":"none",left:t,top:r,...f},className:`${Bt["minimize-windows"]} ${a}`,ref:l,children:[v.jsx("div",{className:Bt["minimize-windows-title"],title:e,children:e}),v.jsxs("div",{className:Bt["minimize-windows-operate"],children:[v.jsx(tn,{onClick:s}),v.jsx(rn,{onClick:i,disabled:o})]})]})}),ee={"xph-dialog-mask":"_xph-dialog-mask_pi1qv_1","xph-dialog-wrapper":"_xph-dialog-wrapper_pi1qv_19",dialog__header:"_dialog__header_pi1qv_69",dialog__title:"_dialog__title_pi1qv_109","dialog__title-text":"_dialog__title-text_pi1qv_121","dialog__header-btns":"_dialog__header-btns_pi1qv_131",dialog__main:"_dialog__main_pi1qv_157",dialog__footer:"_dialog__footer_pi1qv_171",dialog__resize:"_dialog__resize_pi1qv_185","dialog__resize-lt":"_dialog__resize-lt_pi1qv_199","dialog__resize-rt":"_dialog__resize-rt_pi1qv_211","dialog__resize-rb":"_dialog__resize-rb_pi1qv_223","dialog__resize-lb":"_dialog__resize-lb_pi1qv_235"},Wa=".xph--dialog--wrapper, .xph--dialog--minimize",Ha=[".ant-select-dropdown",".ant-picker-dropdown",".ant-dropdown",".ant-cascader-dropdown",".ant-tree-select-dropdown",".ant-popover",".ant-mentions-dropdown",".ant-table-filter-dropdown",'[role="listbox"]','[role="menu"]','[role="tree"]','[role="dialog"]'].join(","),nn=e=>e instanceof Element?e:e instanceof Node?e.parentElement:null;function Va(e){const r=e===document.body?document:e;let n;const o=(p,d,g)=>{const h=nn(p);if(!h||!e.contains(h))return!1;const y=h.closest(Wa)||h.closest(Ha);if(!y||!e.contains(y))return!1;const w=Math.abs(d)>Math.abs(g),D=w?d:g;if(!D)return!0;for(let T=h;T&&T!==e;T=T.parentElement){const _=window.getComputedStyle(T),F=w?_.overflowX:_.overflowY;if(!/^(auto|scroll|overlay)$/.test(F))continue;const j=w?T.scrollWidth-T.clientWidth:T.scrollHeight-T.clientHeight;if(j<=0)continue;const R=w?T.scrollLeft:T.scrollTop;if(w&&_.direction==="rtl"){if(D>0?R<-.5:R>-j+.5)return!0}else if(D>0?R<j-.5:R>.5)return!0}return!1},s=p=>{p.cancelable&&p.preventDefault()},i=p=>{if(p.ctrlKey||p.defaultPrevented)return;const d=p.shiftKey&&!p.deltaX,g=d?p.deltaY:p.deltaX,h=d?0:p.deltaY;!g&&!h||o(p.target,g,h)||s(p)},a=p=>{const d=p.touches.length===1?p.touches[0]:void 0;n=d?{x:d.clientX,y:d.clientY}:void 0},l=p=>{var w,D;if(p.touches.length!==1){n=void 0;return}const d=p.touches[0],g=n;if(n={x:d.clientX,y:d.clientY},!g||p.defaultPrevented||(((D=(w=e.ownerDocument.defaultView)==null?void 0:w.visualViewport)==null?void 0:D.scale)??1)>1)return;const h=g.x-d.clientX,y=g.y-d.clientY;!h&&!y||o(p.target,h,y)||s(p)},u=()=>{n=void 0},f=p=>{if(p.defaultPrevented||p.altKey||p.metaKey)return;const d=nn(p.target);if(d!=null&&d.closest("input, textarea, select")||d instanceof HTMLElement&&d.isContentEditable)return;let g=0,h=0;switch(p.key){case"ArrowLeft":g=-1;break;case"ArrowRight":g=1;break;case"ArrowUp":case"PageUp":case"Home":h=-1;break;case"ArrowDown":case"PageDown":case"End":h=1;break;case" ":case"Spacebar":if(d!=null&&d.closest('button, [role="button"]'))return;h=p.shiftKey?-1:1;break;default:return}o(p.target,g,h)||s(p)};return e.addEventListener("wheel",i,{passive:!1}),e.addEventListener("touchstart",a,{passive:!0}),e.addEventListener("touchmove",l,{passive:!1}),e.addEventListener("touchend",u,{passive:!0}),e.addEventListener("touchcancel",u,{passive:!0}),r.addEventListener("keydown",f),()=>{e.removeEventListener("wheel",i),e.removeEventListener("touchstart",a),e.removeEventListener("touchmove",l),e.removeEventListener("touchend",u),e.removeEventListener("touchcancel",u),r.removeEventListener("keydown",f),n=void 0}}const Wt=new WeakMap,Ua=(e,t)=>{var T;const r=e.ownerDocument,n=e===r.body,o=[],s=[t];let i=!1;if(n&&t!==r.body){const _=getComputedStyle(r.body);if(/auto|scroll|overlay/.test(`${_.overflowX} ${_.overflowY}`)){const F=getComputedStyle(r.documentElement);i=F.overflowX==="visible"&&F.overflowY==="visible"&&F.contain==="none"&&_.contain==="none",i||s.push(r.body)}}const a=s.map(_=>({element:_,left:_.scrollLeft,top:_.scrollTop})),l=(_,F,j)=>{o.push({element:_,property:F,value:_.style.getPropertyValue(F),priority:_.style.getPropertyPriority(F),appliedValue:j}),_.style.setProperty(F,j,"important")},u=getComputedStyle(t);(n?r.defaultView.innerWidth-t.clientWidth:t.offsetWidth-t.clientWidth-parseFloat(u.borderLeftWidth||"0")-parseFloat(u.borderRightWidth||"0"))>0&&!u.getPropertyValue("scrollbar-gutter").includes("stable")&&"scrollbarGutter"in t.style&&l(t,"scrollbar-gutter","stable"),i&&(l(r.body,"overflow-x","visible"),l(r.body,"overflow-y","visible"));const p=(T=r.defaultView)==null?void 0:T.visualViewport,d=()=>((p==null?void 0:p.scale)??1)>1?"auto":"none";s.forEach(_=>{l(_,"overflow-x","hidden"),l(_,"overflow-y","hidden"),l(_,"overscroll-behavior-x",d()),l(_,"overscroll-behavior-y",d()),l(_,"scroll-behavior","auto")});const g=o.filter(_=>_.property.startsWith("overscroll-behavior-")),h=()=>{const _=d();g.forEach(F=>{const{element:j,property:R,appliedValue:B}=F;j.style.getPropertyValue(R)!==B||j.style.getPropertyPriority(R)!=="important"||(j.style.setProperty(R,_,"important"),F.appliedValue=_)})};p==null||p.addEventListener("resize",h);const y=()=>{a.forEach(({element:_,left:F,top:j})=>{const R=Math.max(0,_.scrollWidth-_.clientWidth),B=Math.max(0,_.scrollHeight-_.clientHeight),x=Math.max(-R,Math.min(F,R)),A=Math.max(0,Math.min(j,B));_.scrollLeft!==x&&(_.scrollLeft=x),_.scrollTop!==A&&(_.scrollTop=A)})};y();const w=new Set(s);n&&w.add(r),w.forEach(_=>{_.addEventListener("scroll",y,{passive:!0})});const D=Va(e);return()=>{p==null||p.removeEventListener("resize",h),D(),w.forEach(j=>{j.removeEventListener("scroll",y)});const _=j=>{const{element:R,property:B,value:x,priority:A,appliedValue:S}=j;R.style.getPropertyValue(B)!==S||R.style.getPropertyPriority(B)!=="important"||(x?R.style.setProperty(B,x,A):R.style.removeProperty(B))},F=o.reverse();F.filter(j=>j.property!=="scroll-behavior").forEach(_),y(),F.filter(j=>j.property==="scroll-behavior").forEach(_)}},Ya=e=>{const t=e.ownerDocument,r=e===t.body?t.scrollingElement||t.documentElement:e;let n=Wt.get(r);n?n.count+=1:(n={count:1,release:Ua(e,r)},Wt.set(r,n));const o=n;return()=>{o.count-=1,!o.count&&(Wt.delete(r),o.release())}},qa=({container:e,mask:t,visible:r})=>{m.useLayoutEffect(()=>{if(!(!t||!r))return Ya(e)},[e,t,r])},Ht=new WeakMap,Xa=e=>{let t=Ht.get(e);if(t)t.count+=1;else{if(window.getComputedStyle(e).position!=="static")return()=>{};t={count:1,originalPosition:e.style.getPropertyValue("position"),originalPriority:e.style.getPropertyPriority("position"),appliedPriority:""},e.style.setProperty("position","relative",t.originalPriority),window.getComputedStyle(e).position==="static"&&e.style.setProperty("position","relative","important"),t.appliedPriority=e.style.getPropertyPriority("position"),Ht.set(e,t)}const r=t;return()=>{r.count-=1,!(r.count>0)&&(Ht.delete(e),!(e.style.getPropertyValue("position")!=="relative"||e.style.getPropertyPriority("position")!==r.appliedPriority)&&(r.originalPosition?e.style.setProperty("position",r.originalPosition,r.originalPriority):e.style.removeProperty("position")))}},on=e=>({left:e.scrollLeft,top:e.scrollTop,width:e.clientWidth,height:e.clientHeight}),Ga=({container:e,mask:t,visible:r})=>{const n=e===document.body,[o,s]=m.useState(()=>on(e));return m.useLayoutEffect(()=>{if(!n)return Xa(e)},[e,n]),qa({container:e,mask:t,visible:r}),m.useLayoutEffect(()=>{if(!t||n)return;const a=()=>{const u=on(e);s(f=>f.left===u.left&&f.top===u.top&&f.width===u.width&&f.height===u.height?f:u)};a(),e.addEventListener("scroll",a,{passive:!0});const l=typeof ResizeObserver>"u"?void 0:new ResizeObserver(a);return l==null||l.observe(e),l||window.addEventListener("resize",a),()=>{e.removeEventListener("scroll",a),l==null||l.disconnect(),l||window.removeEventListener("resize",a)}},[e,n,t,r]),{layerStyle:t?{position:n?"fixed":"absolute",...n?{inset:0}:o,zIndex:999,pointerEvents:"none",display:r?void 0:"none"}:void 0}},{useToken:Ka}=E.theme,Ja=m.forwardRef((e,t)=>{const{token:r}=Ka(),n={borderRadius:r.borderRadiusLG},o={"--xph-dialog-bg":r.colorBgElevated,"--xph-dialog-text":r.colorText,"--xph-dialog-muted-text":r.colorTextSecondary,"--xph-dialog-header-bg":r.colorFillAlter,"--xph-dialog-header-active-bg":r.colorPrimaryBg,"--xph-dialog-border":r.colorBorder,"--xph-dialog-separator":r.colorBorderSecondary,"--xph-dialog-active-border":r.colorPrimaryBorder,"--xph-dialog-control-hover-bg":r.colorFillSecondary,"--xph-dialog-close-hover-bg":r.colorError,"--xph-dialog-close-color":r.colorTextLightSolid},{children:s,baseDialogProps:i,mask:a,title:l,renderFooter:u,renderTitle:f,getPopperContainer:p}=e,[d]=m.useState(()=>p()),[g,h]=Zr(!1),[y,w]=m.useState(!1),{layerStyle:D}=Ga({container:d,mask:a,visible:g}),{open:T,close:_}=Ta(g,e,h,w),{footerActions:F}=Ca(e,y),j=m.useRef(null),R=m.useRef(null),B=m.useRef(null),x=m.useRef(null),{containerSizeTarget:A,containerMeasurable:S,parentInitRecord:C,initLeft:O,initTop:M,initWidth:I,initHeight:z,curPropsWidth:G,curPropsHeight:ne,setParentInitRecord:se}=ka({container:d,dialogProps:e,baseDialogProps:i}),{dialogChangeRecord:be,setDialogChangeRecord:pe}=Ma(),{dialogWidth:U,dialogHeight:H,setDialogSize:X}=Pa({initWidth:I,initHeight:z,setDialogChangeRecord:pe}),{dialogLeft:K,dialogTop:Ut,setDialogPosition:Ce}=Ea({initTop:M,initLeft:O,setDialogChangeRecord:pe}),{minResizeRecord:Ue,setMinResizeRecord:je}=Ra(),{minimizeLeft:Ye,minimizeTop:Oe,minimizeRef:Me,setMinimizePosition:qe}=Aa(),{minimizeVisible:Xe,maximizeVisible:Yt,setMaximizeVisible:$e,onMaximize:xe,onMinimize:ht,onRecovery:gt,onClose:Se}=ja({containerSizeTarget:A,dialogChangeRecord:be,close:_,setDialogSize:X,setDialogPosition:Ce}),{dialogMaxHeight:qt,contentMaxHeight:Xt}=Fa({visible:g&&!Xe&&S,containerSizeTarget:A,dialogHeight:H,dialogRef:j,dialogHeaderRef:R,dialogFooterRef:x}),Ge=()=>{X({width:I.current,height:z.current}),Ce({left:O.current,top:M.current}),qe({left:160,top:60}),$e(!1),je(null)};m.useEffect(()=>{Ge()},[C]),Oa({curPropsWidth:G,curPropsHeight:ne,setParentInitRecord:se}),en({containerSizeTarget:A,dialogHeaderRef:R,dialogRef:j,setDialogPosition:Ce}),en({containerSizeTarget:A,dialogHeaderRef:Me,dialogRef:Me,setDialogPosition:qe});const{dialogTopShowClassConfig:Ke}=Da({visible:g,container:d,dialogRef:j,minimizeRef:Me}),{resizingState:mt,DashedBox:yt,onMousedownResizeLt:Fe,onMousedownResizeRt:Gt,onMousedownResizeRb:vt,onMousedownResizeLb:bt}=$a({containerSizeTarget:A,dialogRef:j,minResizeRecord:Ue,setDialogSize:X,setDialogPosition:Ce,setMinResizeRecord:je});return m.useImperativeHandle(t,()=>({open:T,close:Se,setLoading:w,getVisible:()=>g})),v.jsxs("div",{className:Ke.xphDialog,style:{...o,...D},children:[a&&g?v.jsx("div",{className:ee["xph-dialog-mask"]}):null,v.jsx(Ba,{visible:Xe,className:`${Ke.xphMinimizeDialog}`,loading:y,ref:Me,left:Ye,top:Oe,title:l,onMaximize:()=>xe("minimize"),onClosesquare:Se}),v.jsxs("div",{ref:j,className:`${ee["xph-dialog-wrapper"]} ${Ke.xphDialogWrapper}`,style:{display:g&&!Xe?"flex":"none",left:K,top:Ut,width:U,height:H,maxHeight:qt,opacity:mt?.2:"unset",...n},children:[v.jsxs("div",{ref:R,className:ee.dialog__header,children:[v.jsx("div",{className:`${ee.dialog__title} ${f?"":ee["dialog__title-text"]}`,title:f?void 0:l,children:f?f():l}),v.jsxs("div",{className:ee["dialog__header-btns"],children:[v.jsx(za,{onClick:ht}),Yt?v.jsx(La,{onClick:gt}):v.jsx(tn,{onClick:()=>xe("maximize")}),v.jsx(rn,{onClick:Se,disabled:y})]})]}),v.jsx("div",{ref:B,className:ee.dialog__main,style:{maxHeight:Xt,overscrollBehavior:a?"contain":void 0},children:v.jsx(E.Spin,{spinning:y,children:g?s:null})}),u?v.jsx("div",{ref:x,children:u({loading:y})}):v.jsx("div",{ref:x,className:ee.dialog__footer,children:v.jsx(ct,{...F})}),v.jsx("div",{className:`${ee.dialog__resize} ${ee["dialog__resize-lt"]}`,onMouseDown:Fe}),v.jsx("div",{className:`${ee.dialog__resize} ${ee["dialog__resize-rt"]}`,onMouseDown:Gt}),v.jsx("div",{className:`${ee.dialog__resize} ${ee["dialog__resize-rb"]}`,onMouseDown:vt}),v.jsx("div",{className:`${ee.dialog__resize} ${ee["dialog__resize-lb"]}`,onMouseDown:bt})]}),v.jsx(yt,{})]})}),Za=(e,t)=>{const{children:r,...n}=e,{baseDialogProps:o,dialogProps:s}=xa(n),{getPopperContainer:i}=s;return v.jsx(an,{getPopperContainer:i,children:v.jsx(Ja,{...s,baseDialogProps:o,ref:t,children:r})})},sn=m.forwardRef(Za),an=({children:e,getPopperContainer:t})=>{const[r,n]=m.useState(null);return m.useEffect(()=>{const o=t();n(o)},[]),r?Tn.createPortal(e,r):null};function Qa(e){const{extendAuthProps:t}=el();return{authProps:{...ce(ce({auth:o=>!1},t),e)}}}const el=()=>{const{extendProps:e}=De();return{extendAuthProps:e==null?void 0:e.auth}},tl=e=>{const{children:t,...r}=e,{authProps:n}=Qa(r),{auth:o,authCode:s}=n;return(()=>{let a=!1;return s&&o&&(re(s)?a=s.every(l=>o(l)):a=o(s)),a})()?t:null};function ut(e){return"component"in e}function dt(e){return"render"in e}function rl(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 nl(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 ol=["DatePicker","MonthPicker","RangePicker","WeekPicker","TimePicker"],sl=e=>{const{show:t,ifShow:r,required:n,disabled:o,componentProps:s}=e;return!!(Q(t)||Q(r)||Q(n)||Q(o)||Q(s)||dt(e))},il=e=>["application/json","application/javascript","text/plain","text/html","text/css"].includes(e)?`${e}; charset=utf-8`:e,al=(e,t,r)=>{const n=m.useRef(null),o=m.useRef(null),{handleCollapseChangeFalse:s}=r.current||{},{show:i,ifShow:a}=e;let l=!0,u=!0;if(it(i)&&(l=i),it(a)&&(u=a),Q(i)){l=i({model:t});const f=qr(n.current)?l:n.current;m.useEffect(()=>{at(l,f)||s&&s()},[t])}if(Q(a)){u=a({model:t});const f=qr(o.current)?u:o.current;m.useEffect(()=>{at(u,f)||s&&s()},[t])}return n.current=l,o.current=u,{isShow:l,isIfShow:u}},ll=(e,t)=>{const{collapsible:r,collapseNum:n}=e,[o,s]=m.useState(!!(r&&t>=n));return{itemCollapse:o,setItemCollapse:s}},cl=({item:e,model:t,isShow:r,componentProps:n})=>{const{rules:o=[],label:s,required:i}=e;let a=o;const l=ut(e),u=l?rl(e.component)+s:"";function f(h,y){const w=h.message||u;return y===void 0||pa(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 p=Q(i)?i({model:t}):i;p&&(!a||a.length===0?a=[{required:p,validator:f}]:a.findIndex(y=>Reflect.has(y,"required"))===-1&&a.push({required:p,validator:f}));const d=a.findIndex(h=>Reflect.has(h,"required")&&!Reflect.has(h,"validator"));if(d!==-1){const h=a[d];if(r||(h.required=!1),l){const{component:y}=e;Reflect.has(h,"type")||(h.type=y==="InputNumber"?"number":"string"),h.message=h.message||u,(y.includes("Input")||y.includes("Textarea"))&&(h.whitespace=!0);const w=n.valueFormat;nl(h,y,w)}}const g=a.findIndex(h=>h.max);return g!==-1&&!a[g].validator&&(a[g].message=a[g].message||`字符数应小于${a[g].max}位`),{rules:a}},ul=(e,t,r)=>{const{disabled:n}=e;let o=!1;const{disabled:s}=t;return Q(s)&&(o=s({model:r})),it(s)&&(o=s),{disabled:Reflect.has(t,"disabled")?o:n}},dl=(e,t)=>{const r={},{componentProps:n={}}=e;return Q(n)&&Object.assign(r,n({model:t})),Object.assign(r,n),{componentProps:r}},fl=(e,t)=>{const{colProps:r={}}=e,{colProps:n={span:24}}=t;return{colProps:{...n,...r}}},pl=({formProps:e})=>{const{items:t}=e;return{formItems:t.map(n=>({...n}))}},hl=(e,t)=>{const r=a=>(Object.keys(a).forEach(l=>{Object.defineProperty(a,l,{value:a[l],writable:!1,enumerable:!0,configurable:!1})}),a),n={};e.items.forEach(a=>{n[a.name]=a.initialValue});const o=sl(t),s=o?E.Form.useWatch(a=>r(a)):null;return{rewritingModel:m.useMemo(()=>s||r(n),[s]),isusewatch:o}},gl=()=>{const e=m.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 m.useEffect(()=>()=>{e.current=null},[]),[t,r]};function ml(e,t={}){const r=/^\[(.+)\]$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s=[];return o.forEach((i,a)=>{Xr(s,a,t[i.trim()])}),s.filter(Boolean).length?s:void 0}}}function yl(e,t={}){const r=/^\{(.+)\}$/;if(r.test(e)){const n=e.match(r);if(n&&n[1]){const o=n[1].split(",");if(!o.length)return;const s={};return o.forEach(i=>{Xr(s,i.trim(),t[i.trim()])}),Object.values(s).filter(Boolean).length?s:void 0}}}function vl(e,t){const r=t.fieldMapToTime;if(!r||!Array.isArray(r))return e;for(const[n,[o,s],i="YYYY-MM-DD"]of r){if(!n||!o||!s)continue;if(!e[n]){Reflect.deleteProperty(e,n);continue}const[a,l]=e[n],[u,f]=Array.isArray(i)?i:[i,i];e[o]=Je(a).format(u),e[s]=Je(l).format(f),Reflect.deleteProperty(e,n)}return e}const bl=(e,t,r)=>{const n=e.filter(i=>i.name);return{handleFormatRenderValues:i=>{const a={},l=[];return n.forEach(u=>{const f=Reflect.has(i,u.name),p=ml(u.name,i)||yl(u.name,i);if(f||p){const d=p||i[u.name];if(ut(u))if(ol.includes(u.component)){if(re(d)){const g=[];for(const h of d)g.push(h?Je(h):null);a[u.name]=g}else a[u.name]=d?Je(d):null;l.push(u.name)}else a[u.name]=d,l.push(u.name);dt(u)&&(a[u.name]=d,l.push(u.name))}}),{renderValues:a,validKeys:l}},handleFormatReturnValues:i=>{var l,u,f,p,d;if(!ie(i))return{};const a={};for(const g of Object.entries(i)){let[,h]=g;const[y]=g;if(!y||Q(h))continue;const{transformDateFunc:w}=t,D=(f=(u=(l=r.current)==null?void 0:l.get(y))==null?void 0:u.current)==null?void 0:f.componentProps,T=D==null?void 0:D.valueFormat;if(ie(h)){const _=h;_.format&&(h=w==null?void 0:w(_,T))}re(h)&&((p=h[0])!=null&&p.format)&&((d=h[1])!=null&&d.format)&&(h=h.map(_=>w==null?void 0:w(_,T))),Lt(h)&&(h===""?h=void 0:h=h.trim()),a[y]=h}return vl(a,t)}}},wl=(e,t,r)=>({getFieldsValue:(...l)=>r(e.getFieldsValue(...l)),setFieldsValue:l=>{const{renderValues:u,validKeys:f}=t(l);e.setFieldsValue(u),e.validateFields(f)},resetFields:async()=>e.resetFields(),validator:async l=>e.validateFields(l).then(u=>r(u)),scrollToField:async(l,u)=>e.scrollToField(l,u)}),_l=e=>{const{extendFormProps:t}=ln();return{formProps:{...ce(ce({collapseNum:5,colon:!1,items:[],labelWrap:!0,transformDateFunc:(o,s)=>{var i;return((i=o==null?void 0:o.format)==null?void 0:i.call(o,s||"YYYY-MM-DD HH:mm:ss"))??o},fieldMapToTime:[]},t),e)}}},ft=e=>{const{immediate:t=!0,params:r,api:n,apiCallback:o,isUseWatch:s}=e,i=m.useRef(!0),a=m.useRef(r),l=()=>{n&&Q(n)&&(r?n(r).then(o):n().then(o),a.current=r)};return m.useEffect(()=>{i.current&&(t&&l(),i.current=!1),!i.current&&s&&(at(r,a.current)||t&&l())},[r]),{getApiData:l}},Cl=(e,t)=>{const{collapsible:r,collapseNum:n}=e,o=m.useRef();return{collapsible:r,collapseNum:n,collapseRef:o,onClickCollapseToTrue:()=>{var a;(a=t.current)==null||a.forEach(l=>{if(l.current){const{itemIndex:u}=l.current;u>=n&&r&&l.current.setItemCollapse(!0)}})},onClickCollapseToFalse:()=>{var a;(a=t.current)==null||a.forEach(l=>{if(l.current){const{itemCollapse:u}=l.current;u&&l.current.setItemCollapse(!1)}})}}},ln=()=>{const{extendProps:e,extendComp:t}=De(),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}},xl=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,l]=m.useState([]),{getApiData:u}=ft({api:t,immediate:n,params:r,apiCallback:l,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},p=()=>{const{api:d,params:g,immediate:h,isusewatch:y,...w}=e;return w};return v.jsx(E.Select,{...p(),options:a,onDropdownVisibleChange:f})},Sl=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,l]=m.useState([]),{getApiData:u}=ft({api:t,immediate:n,params:r,apiCallback:l,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},p=()=>{const{api:d,params:g,immediate:h,isusewatch:y,...w}=e;return w};return v.jsx(E.TreeSelect,{...p(),treeData:a,onDropdownVisibleChange:f})},Tl=e=>{const{api:t,params:r,isusewatch:n}=e,o=n==="true",[s,i]=m.useState([]);ft({api:t,params:r,apiCallback:i,isUseWatch:o});const a=()=>{const{api:l,params:u,isusewatch:f,...p}=e;return p};return v.jsx(E.Transfer,{...a(),dataSource:s})},Pl=e=>{const{api:t,params:r,immediate:n=!0,isusewatch:o,onDropdownVisibleChange:s}=e,i=o==="true",[a,l]=m.useState([]),{getApiData:u}=ft({api:t,immediate:n,params:r,apiCallback:l,isUseWatch:i}),f=d=>{d&&!n&&u(),s&&s(d)},p=()=>{const{api:d,params:g,immediate:h,isusewatch:y,...w}=e;return w};return v.jsx(E.AutoComplete,{...p(),options:a,onDropdownVisibleChange:f})},ve={String:"String","String[]":"String[]","File[]":"File[]",FileList:"FileList"},El=e=>{const t="",{api:r,maxCount:n=1,maxSize:o=2,listType:s="picture-card",openCrop:i=!1,data:a,returnType:l=ve.String,value:u=t,onChange:f}=e,p=m.useRef(!0),d=m.useRef(0),g=m.useRef([]),[h,y]=m.useState([]),w=x=>{g.current=x,y([...x])},D=()=>{const{api:x,maxCount:A,maxSize:S,openCrop:C,beforeUpload:O,fileList:M,returnType:I,...z}=e;return z},T=x=>{const A=x.size/1024/1024<o;A||E.message.error(`文件大小超过:${o}M, 请重试`);const S=g.current.length+d.current<n;return S||E.message.error(`文件数量不能超过${n}个`),A&&S&&d.current++,A&&S&&_(x),E.Upload.LIST_IGNORE},_=x=>{i?(E.message.error("暂时不支持裁剪功能,后续兼容。。。。"),F({file:x})):F({file:x})},F=x=>{r?r({file:x.file,...a}).then(A=>{w([...g.current,...A])}).finally(()=>{d.current--}):(Object.assign(x.file,{status:"done",url:URL.createObjectURL(new Blob([x.file],{type:il(x.file.type)}))}),w([...g.current,x.file]),d.current--)},j=x=>{const{file:A,fileList:S}=x,{status:C}=A;switch(C){case"removed":{w([...S]);break}}},R=x=>{const A=C=>{const O=C.split("/"),M=O[O.length-1],[I]=M.split("?");return I};return{uid:(C=>{const O=g.current.find(M=>M.url===C);return O?O.uid:tr()})(x),name:A(x),url:x,status:"done"}},B=()=>{switch(l){case ve.String:return h.map(x=>x.url).join(",");case ve["String[]"]:return h.map(x=>x.url);case ve["File[]"]:return[...h];case ve.FileList:return[...h]}};return m.useEffect(()=>{const x=B();if(at(x,u))return;let A=[];switch(l){case ve.String:{A=(u||"").split(",").filter(S=>S).map(S=>R(S));break}case ve["String[]"]:{A=(u||[]).map(S=>R(S));break}case ve["File[]"]:{A=(u||[]).map(S=>S);break}case ve.FileList:{A=(u||[]).map(S=>S);break}}w(A)},[u]),m.useEffect(()=>{if(p.current){p.current=!1;return}const x=B();f==null||f(x)},[h]),v.jsx(E.Upload,{listType:s,...D(),fileList:h,beforeUpload:T,onChange:j,children:"上传"})},V=new Map;V.set("Input",E.Input),V.set("ApiSelect",xl),V.set("Select",E.Select),V.set("InputNumber",E.InputNumber),V.set("ApiTreeSelect",Sl),V.set("TreeSelect",E.TreeSelect),V.set("ApiTransfer",Tl),V.set("Transfer",E.Transfer),V.set("Switch",E.Switch),V.set("Button",E.Button),V.set("Radio",E.Radio),V.set("RadioGroup",E.Radio.Group),V.set("Checkbox",E.Checkbox),V.set("CheckboxGroup",E.Checkbox.Group),V.set("Cascader",E.Cascader),V.set("TimePicker",E.TimePicker),V.set("DatePicker",E.DatePicker),V.set("MonthPicker",E.DatePicker.MonthPicker),V.set("WeekPicker",E.DatePicker.WeekPicker),V.set("RangePicker",E.DatePicker.RangePicker),V.set("InputPassword",E.Input.Password),V.set("InputTextArea",E.Input.TextArea),V.set("ApiAutoComplete",Pl),V.set("AutoComplete",E.AutoComplete),V.set("Upload",E.Upload),V.set("AutoUpload",El);const cn={"form-item-force":"_form-item-force_1hsf3_1","form-item-hidden":"_form-item-hidden_1hsf3_9"},jl=m.forwardRef(({itemIndex:e,itemProps:t,methods:r,formProps:n,collapseRef:o},s)=>{const{rewritingModel:i,isusewatch:a}=hl(n,t),{isIfShow:l,isShow:u}=al(t,i,o),{colProps:f}=fl(t,n),{componentProps:p}=dl(t,i),{rules:d}=cl({item:t,model:i,isShow:u,componentProps:p}),{disabled:g}=ul(n,t,i),{itemCollapse:h,setItemCollapse:y}=ll(n,e),{name:w,label:D,wrapperCol:T,labelCol:_,valuePropName:F,initialValue:j,forceRow:R}=t;m.useImperativeHandle(s,()=>({itemIndex:e,componentProps:p,itemCollapse:h,setItemCollapse:y}));const B=()=>({name:w,label:D,rules:d,wrapperCol:T,labelCol:_,valuePropName:F,initialValue:j}),{setExtendFormComp:x}=ln();x(V);const A=ut(t),S=dt(t),C=()=>{if(A){const O=V.get(t.component);return v.jsx(O,{...p,disabled:g,isusewatch:a.toString()})}return S?t.render({model:i,name:w,disabled:g,methods:r,componentProps:p}):null};return v.jsxs(m.Fragment,{children:[R?v.jsx("div",{className:cn["form-item-force"]}):null,l?v.jsx(E.Col,{...f,className:u&&!h?void 0:cn["form-item-hidden"],children:v.jsx(E.Form.Item,{...B(),children:C()})}):null]})}),Fl={"collapse-wrapper":"_collapse-wrapper_ylm01_1"},Al=m.forwardRef(({collapsible:e,onClickExpand:t,onClickFold:r},n)=>{const[o,s]=m.useState(e),i=m.useMemo(()=>o,[o]),a=()=>{r(),s(!0)},l=()=>{t(),s(!1)};return m.useImperativeHandle(n,()=>({handleCollapseChangeFalse:l})),v.jsx("div",{className:Fl["collapse-wrapper"],children:i?v.jsx(E.Button,{onClick:l,type:"link",icon:v.jsx(ue.DownOutlined,{}),children:"展开"}):v.jsx(E.Button,{onClick:a,type:"link",icon:v.jsx(ue.UpOutlined,{}),children:"折叠"})})}),Dl={"group-wrapper":"_group-wrapper_g8zqi_1"},Ol=({formProps:e})=>{const{renderActions:t}=e;return v.jsx("div",{className:Dl["group-wrapper"],children:t==null?void 0:t()})},Ml={"xph-form-action":"_xph-form-action_8ws73_1"},$l=(e,t)=>{const[r]=E.Form.useForm(),{formProps:n}=_l(e),{formItems:o}=pl({formProps:n}),s=m.useRef(new Map),{collapsible:i,collapseNum:a,collapseRef:l,onClickCollapseToFalse:u,onClickCollapseToTrue:f}=Cl(n,s),{handleFormatRenderValues:p,handleFormatReturnValues:d}=bl(o,n,s),{setFieldsValue:g,getFieldsValue:h,resetFields:y,validator:w,scrollToField:D}=wl(r,p,d),T=()=>{const{layout:F,wrapperCol:j,labelCol:R,colon:B,disabled:x,labelWrap:A,labelAlign:S,scrollToFirstError:C,size:O}=n;return{layout:F,wrapperCol:j,labelCol:R,colon:B,disabled:x,labelWrap:A,labelAlign:S,scrollToFirstError:C,size:O}},_={setFieldsValue:g,getFieldsValue:h,resetFields:y,validator:w,scrollToField:D};return m.useImperativeHandle(t,()=>({..._})),m.useEffect(()=>(n.register&&n.register(_),()=>{s.current.clear()}),[]),v.jsxs(E.Form,{form:r,...T(),children:[v.jsx(E.Row,{children:o.map((F,j)=>(s.current.has(F.name)||s.current.set(F.name,m.createRef()),v.jsx(jl,{ref:s.current.get(F.name),itemIndex:j,itemProps:F,formProps:n,methods:_,collapseRef:l},j)))}),v.jsxs("div",{className:Ml["xph-form-action"],children:[v.jsx(Ol,{formProps:n}),i?v.jsx(Al,{ref:l,collapsible:o.length>a,onClickExpand:u,onClickFold:f}):null]})]})},Vt=m.forwardRef($l),kl=m.memo(Vt),Rl=m.forwardRef((e,t)=>{const{renderActions:r,showSearch:n=!0,tableRef:o}=e,[s,i]=m.useState(!1),a=m.useRef(null),l=()=>{const{reloadData:d}=o.current;d()},u=()=>{const{resetData:d}=o.current;d()},f=m.useCallback(()=>v.jsxs("div",{style:{width:"100%",display:"flex"},children:[v.jsx("div",{style:{flex:1,width:0},children:r==null?void 0:r()}),n&&v.jsxs("div",{style:{display:"flex",gap:"8px"},children:[v.jsx(E.Button,{type:"primary",icon:v.jsx(ue.SearchOutlined,{}),onClick:l,children:"搜索"}),v.jsx(E.Button,{icon:v.jsx(ue.ReloadOutlined,{}),onClick:u,children:"重置"})]})]}),[n,r]),p=()=>{const{renderActions:d,...g}=e;return{...g,renderActions:f}};return m.useImperativeHandle(t,()=>({setFormLoading:i,...a.current})),v.jsx(E.Spin,{spinning:s,children:v.jsx(kl,{ref:a,...p()})})}),Il=m.memo(Vt),zl=(e,t)=>{const r=m.useRef(null),n=m.useRef(null),{formProps:o}=e,i=(()=>{const{formProps:f,...p}=e;return p})(),a=m.useRef(null),l=async()=>{const{onOk:f,renderFooter:p}=i;if(!p){const{ok:d,data:g}=a.current;if(d){n.current.validator().then(async h=>{r.current.setLoading(!0),await d({values:n.current.getFieldsValue()}).then(w=>w).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}if(f){n.current.validator().then(async h=>{r.current.setLoading(!0),await f({values:h,data:g}).then(w=>w).finally(()=>{r.current.setLoading(!1)})!==!1&&(r.current.close(),a.current=null)});return}r.current.close(),a.current=null}},u=async()=>{const{onCancel:f,renderFooter:p}=i;if(!p){const{cancel:d,data:g}=a.current;if(d){if(await d({values:n.current.getFieldsValue(!0)})===!1)return;r.current.close(),a.current=null;return}if(f){if(await f({values:n.current.getFieldsValue(!0),data:g})===!1)return;r.current.close(),a.current=null;return}r.current.close(),a.current=null}};return m.useImperativeHandle(t,()=>({open:async f=>{if(r.current.getVisible())return;const{renderFooter:d}=i;return!d&&(a.current=f),r.current.open().then(()=>{n.current.setFieldsValue(f.data||{})})},close:(...f)=>r.current.close(...f),setLoading:(...f)=>r.current.setLoading(...f),getVisible:(...f)=>r.current.getVisible(...f),getFieldsValue:(...f)=>n.current.getFieldsValue(...f),setFieldsValue:(...f)=>n.current.setFieldsValue(...f),resetFields:(...f)=>n.current.resetFields(...f),validator:(...f)=>n.current.validator(...f),scrollToField:(...f)=>n.current.scrollToField(...f)})),v.jsx(sn,{...i,ref:r,onOk:l,onCancel:u,children:v.jsx(Il,{...o,ref:n})})},un=m.forwardRef(zl);function Ll({searchForm:e}){return{searchFormRef:m.useRef(null),searchFormProps:e}}function dn(e){return"cellFunc"in e}function fn(e){return"children"in e}const{useToken:Nl}=E.theme,Bl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t,{url:s,onClick:i}=n,{token:a}=Nl(),l={color:a.colorLink,cursor:"pointer"},u=()=>{if(r.mainClick&&r.mainClick(),i){i();return}if(s){window.open(s,"_blank");return}};return v.jsx(e,{...r,mainClick:u,mainStyle:Object.assign(l,(r==null?void 0:r.mainStyle)||{})})},Wl={"cellfunc-actions":"_cellfunc-actions_14drt_1"},Hl=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:o}=t;return v.jsx("div",{className:Wl["cellfunc-actions"],children:v.jsx(ct,{...n})})},{useToken:Vl}=E.theme,Ul={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"}},Yl=(e,t,r)=>e.reduce((n,o,s)=>{var u;const i=`${String(t.dataIndex)}${o.value}`,a=(u=o.config)==null?void 0:u.color,l=a?r[a]??{color:a,backgroundColor:"unset",border:`1px solid ${a}`}:Ul[s]||{};return n[i]={color:l.color,backgroundColor:l.backgroundColor,border:l.border},n},{}),ql=(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:{text:o,column:s}}}=t,{token:i}=Vl(),{enums:a}=n,l={primary:{color:i.colorPrimary,backgroundColor:i.colorPrimaryBg,border:`1px solid ${i.colorPrimary}`},success:{color:i.colorSuccess,backgroundColor:i.colorSuccessBg,border:`1px solid ${i.colorSuccess}`},warning:{color:i.colorWarning,backgroundColor:i.colorWarningBg,border:`1px solid ${i.colorWarning}`},info:{color:i.colorInfo,backgroundColor:i.colorInfoBg,border:`1px solid ${i.colorInfo}`},error:{color:i.colorError,backgroundColor:i.colorErrorBg,border:`1px solid ${i.colorError}`}},f=Yl(a,s,l)[`${String(s.dataIndex)}${o}`]||{},p={padding:"0 8px",borderRadius:i.borderRadiusLG,fontSize:i.fontSizeSM,...f},d=()=>{var h;return(h=a.find(y=>y.value===o))==null?void 0:h.label};return v.jsx(e,{...r,mainHandleText:d,mainStyle:Object.assign((r==null?void 0:r.mainStyle)||{},p)})},{useToken:Xl}=E.theme,pn={link:{Comp:Bl},actions:{Comp:Hl},tag:{Comp:ql},copy:{Comp:(e,t,r)=>{const{curComponentProps:n,cellFuncProps:{renderPrams:o}}=t,{token:s}=Xl(),{text:i,onClick:a,size:l="default"}=n,u={small:16,default:18,large:20},{copy:f}=ic(),p=()=>{let d=o.text;if(i&&(Q(i)&&(d=i(o.record)),Lt(i)&&(d=i)),a)return a(o.record);f(d)&&E.message.success("复制成功")};return v.jsxs(v.Fragment,{children:[v.jsx("span",{onClick:p,children:v.jsx("svg",{viewBox:"0 0 1024 1024",version:"1.1",xmlns:"http://www.w3.org/2000/svg","p-id":"4503",width:u[l],height:u[l],style:{cursor:"pointer",verticalAlign:"text-top"},children:v.jsx("path",{d:"M682.666667 42.666667H85.333333v682.666666h85.333334V128h512V42.666667zM256 213.333333l4.522667 768H896V213.333333H256z m554.666667 682.666667H341.333333V298.666667h469.333334v597.333333z",fill:s.colorLink,"p-id":"4504"})})}),v.jsx(e,{...r})]})}}},Gl=(e,t)=>{var i,a;const{renderPrams:{text:r,column:n}}=e,o=(i=t==null?void 0:t.mainHandleText)==null?void 0:i.call(t),s=it(n==null?void 0:n.ellipsis)?n==null?void 0:n.ellipsis:(a=n==null?void 0:n.ellipsis)==null?void 0:a.showTitle;return v.jsx("span",{onClick:t==null?void 0:t.mainClick,style:t==null?void 0:t.mainStyle,title:s?`${o??r}`:void 0,children:o??r})},Kl=e=>{const{setExtendTableCellComp:t}=gn();t(pn);const{dslConfig:r}=e;let n=Gl.bind(null,e),o=0;for(;o<r.length;){const s=o++,i=pn[r[s].component];i&&(n=i.Comp.bind(null,n,{curComponentProps:r[s].componentProps||{},cellFuncProps:e}))}return v.jsx(n,{})};function hn(e){return e.map(t=>{let r={...t};if(dn(r)){const{cellFunc:n,...o}=r;r={...o,render:(...s)=>{const i=Q(n),[a,l,u]=s,f={text:a,record:l,index:u,column:JSON.parse(JSON.stringify(o))},p=i?n(f):n;return v.jsx(Kl,{dslConfig:p,renderPrams:f})}}}return fn(r)&&r.children&&Array.isArray(r.children)&&(r.children=hn(r.children)),r})}function Jl(e){const{columns:t}=e.table;return{columns:hn(t)}}const Zl=e=>{const{extendTableProps:t}=gn();return{tableProps:{...ce(ce({table:{columns:[],fullHeight:!1,autoRequest:!0,pagination:{pageSize:20,total:0,showTotal:o=>`共:${o} 条`,current:1,pageSizeOptions:[10,20,50,100],showSizeChanger:!0,showQuickJumper:!0},requestFields:{pageSize:"pageSize",current:"current"},responseFields:{current:"current",list:"data",total:"total"}},crudFormDialog:void 0,searchForm:void 0},t),e)}}};function Ql(e){const{pagination:t,autoPagination:r}=e.table,[n,o]=m.useState(t),s=m.useRef(t),i=m.useMemo(()=>n&&(r===!0||r===void 0)||!1,[n]);return{pagination:{model:n,update:l=>{if(!s.current)return;const u={...s.current,...l};o(u),s.current=u},show:i},lastPaginationState:s}}function ec(e,t){const{api:r,formatDataSource:n,autoPagination:o,onChange:s,requestFields:i,responseFields:a}=e.table,l=e.onPaginationChange,{pagination:u,lastPaginationState:f}=Ql(e),[p,d]=m.useState({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),g=m.useRef({loading:!1,dataSource:[],selection:[],backupsDataSource:[]}),h={model:p,update:S=>{const C={...g.current,...S};d(C),g.current=C,t.current&&t.current.setFormLoading(C.loading)}},y={validator:async()=>({}),resetFields:async()=>{}},w=async()=>{m.useEffect(()=>{const{autoRequest:S}=e.table,{validator:C}=t.current||y;S&&C().then(O=>{F({searchFormParams:O})})},[])},D=async({searchFormParams:S,paginationParams:C})=>{const O={...S,[`${i.current}`]:f.current.current,[`${i.pageSize}`]:f.current.pageSize,...C?{[`${i.current}`]:C.current,[`${i.pageSize}`]:C.pageSize}:{}};return r(O).then(M=>{const{current:I,list:z,total:G}=_t(a,M);h.update({dataSource:n?n(z):z}),u.update({total:G,current:I,pageSize:O[`${i.pageSize}`]})}).finally(()=>{h.update({loading:!1})})},T=async({searchFormParams:S,paginationParams:C})=>{const O={...S};return r(O).then(M=>{const{list:I}=_t(a,M),z=n?n(I):I;h.update({selection:[],dataSource:z}),u.update({current:1,total:I.length})}).finally(()=>{h.update({loading:!1})})},_=async({searchFormParams:S,paginationParams:C})=>{var M;const O={...S};if(C){const{current:I,pageSize:z}=C;u.update({current:I,pageSize:z});const G=(I-1)*z,ne=G+z,se=(M=g.current.backupsDataSource)==null?void 0:M.slice(G,ne);return h.update({loading:!1,selection:[],dataSource:se})}else return r(O).then(I=>{let z=n?n(I):I;const G=[...z],ne=0,se=ne+f.current.pageSize;z=z.slice(ne,se),h.update({selection:[],dataSource:z,backupsDataSource:G}),u.update({current:1,total:I.length})}).finally(()=>{h.update({loading:!1})})},F=async({searchFormParams:S,paginationParams:C})=>{if(h.update({loading:!0,selection:[]}),r)switch(!!f.current){case!0:return o===!0?_({searchFormParams:S,paginationParams:C}):o===!1?T({searchFormParams:S,paginationParams:C}):D({searchFormParams:S,paginationParams:C});case!1:return T({searchFormParams:S,paginationParams:C})}return h.update({loading:!1})};return{table:h,pagination:u,firstGetTableData:w,onPaginationChange:(S,C)=>{const{validator:O}=t.current||y;O().then(M=>{F({searchFormParams:M,paginationParams:{current:S,pageSize:C}})}),l&&l(S,C)},onAllChange:async(...S)=>{const[C,O,M,I]=S,z=[];for(let G=0;G<z.length&&!z[G]();G++);s&&s(O,M,I)},resetData:async()=>{const{resetFields:S,validator:C}=t.current||y;return S().then(async()=>{const O=await C();return F({searchFormParams:O})})},resetAllData:async()=>{const{resetFields:S,validator:C}=t.current||y;return S().then(async()=>{const O={};if(f.current){const{pageSize:M}=f.current;o===void 0&&(O.paginationParams={current:1,pageSize:M})}return O.searchFormParams=await C(),F(O)})},reloadData:async()=>{const{validator:S}=t.current||y;return S().then(C=>F({searchFormParams:C}))}}}const tc=(e,t)=>{const{onRowSelectionChange:r}=e,{rowSelection:n}=e.table,o=()=>{if(Lt(n))return{type:n,onChange:(s,i,a)=>{t.update({selection:i}),r&&r(s,i)}};if(ie(n)){const{onChange:s}=n;return{...n,onChange:(i,a,l)=>{t.update({selection:a}),s&&s(i,a,l),r&&r(i,a)}}}return n};return{rowSelection:o(),getNewRowSelection:o}},Ve=(e,t)=>Array.from((e==null?void 0:e.children)??[]).find(r=>r.classList.contains(t));function rc(e,t){const{scroll:r,virtual:n,prefixCls:o}=e.table,{getPrefixCls:s}=m.useContext(E.ConfigProvider.ConfigContext),i=s("table",o),a=m.useRef(null),[{width:l,height:u},f]=m.useState({width:1,height:1});m.useLayoutEffect(()=>{const d=a.current;if(!t||!d)return;let g;const h=new Set,y=()=>{const _=d.firstElementChild,F=_==null?void 0:_.getElementsByClassName(i)[0],j=Ve(F,`${i}-container`),R=Ve(j,`${i}-header`),B=Ve(j,`${i}-tbody-virtual`),x=Ve(B,`${i}-tbody-virtual-holder`)??Ve(j,`${i}-body`),A=new Set([d,_,F,R,x].filter(C=>!!C));h.forEach(C=>{A.has(C)||D.unobserve(C)}),A.forEach(C=>{h.has(C)||D.observe(C)}),h.clear(),A.forEach(C=>h.add(C));const S=_&&x?_.offsetHeight-x.offsetHeight:void 0;f(C=>{const O=Math.max(1,d.clientWidth),M=S===void 0?C.height:Math.max(1,d.clientHeight-S);return C.width===O&&C.height===M?C:{width:O,height:M}})},w=()=>{g===void 0&&(g=requestAnimationFrame(()=>{g=void 0,y()}))},D=new ResizeObserver(w),T=new MutationObserver(w);return T.observe(d,{childList:!0,subtree:!0}),y(),()=>{D.disconnect(),T.disconnect(),g!==void 0&&cancelAnimationFrame(g)}},[t,n,i]);const p=m.useMemo(()=>t?n?{x:l,y:u,...r}:{y:u,...r}:{...r},[t,n,l,u,r]);return{divRef:a,scroll:p}}function nc(e,t){const{toolbar:r}=e.table;return{getTopToolbarBindProps:()=>{if(Q(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 gn=()=>{const{extendProps:e,extendComp:t}=De(),r=n=>{const o=t==null?void 0:t.tableCellFunc;o&&Object.keys(o).forEach(s=>{const i=o[s];n[s]={Comp:i}})};return{extendTableProps:e==null?void 0:e.table,setExtendTableCellComp:r}},oc=({crudFormDialog:e})=>({crudFormDialogRef:m.useRef(null),crudFormProps:e});function sc(e,{target:t=document.body}={}){const r=document.createElement("textarea"),n=document.activeElement;r.value=e,r.setAttribute("readonly",""),r.style.contain="strict",r.style.position="absolute",r.style.left="-9999px",r.style.fontSize="12pt";const o=document.getSelection();let s;o&&o.rangeCount>0&&(s=o.getRangeAt(0)),t.append(r),r.select(),r.selectionStart=0,r.selectionEnd=e.length;let i=!1;try{i=document.execCommand("copy")}catch(a){throw new Error(a)}return r.remove(),s&&o&&(o.removeAllRanges(),o.addRange(s)),n&&n.focus(),i}function ic(){function e(t){try{return sc(t)}catch{return!1}}return{copy:e}}const pt={"main-container":"_main-container_1yx5k_1",container__toolbar:"_container__toolbar_1yx5k_13",container__table:"_container__table_1yx5k_27",container__pagination:"_container__pagination_1yx5k_35"},ac=m.forwardRef(({tableProps:e,searchFormRef:t,fullHeight:r},n)=>{const{columns:o}=Jl(e),s=m.useRef(null),{table:i,pagination:a,firstGetTableData:l,onPaginationChange:u,onAllChange:f,resetData:p,resetAllData:d,reloadData:g}=ec(e,t),{rowSelection:h}=tc(e,i),{divRef:y,scroll:w}=rc(e,r),{getTopToolbarBindProps:D}=nc(e,i),T=()=>{const{autoRequest:_,api:F,formatDataSource:j,autoPagination:R,columns:B,scroll:x,pagination:A,rowSelection:S,onChange:C,...O}=e.table;return O};return l(),m.useImperativeHandle(n,()=>({resetData:p,resetAllData:d,reloadData:g,...s.current})),v.jsxs("div",{className:r?pt["main-container"]:void 0,children:[v.jsx("div",{className:pt.container__toolbar,children:v.jsx(ct,{...D()})}),v.jsx("div",{ref:y,className:r?pt.container__table:void 0,children:v.jsx(E.Table,{ref:s,...T(),loading:i.model.loading,columns:o,dataSource:i.model.dataSource,pagination:!1,rowSelection:h,scroll:w,onChange:f})}),a.show?v.jsx("div",{className:pt.container__pagination,children:v.jsx(E.Pagination,{disabled:i.model.loading,...a.model,onChange:u})}):null]})}),mn={"xph-table-full-wrapper":"_xph-table-full-wrapper_mdv0g_1","full-wrapper__table":"_full-wrapper__table_mdv0g_13"},lc=(e,t)=>{const{tableProps:r}=Zl(e),n=m.useRef(null),{searchFormRef:o,searchFormProps:s}=Ll(r),{crudFormDialogRef:i,crudFormProps:a}=oc(r);let{fullHeight:l}=r.table;const{virtual:u}=r.table;return u&&(l=!0),m.useImperativeHandle(t,()=>({...n.current,...i.current})),v.jsxs("div",{className:l?mn["xph-table-full-wrapper"]:void 0,children:[s?v.jsx("div",{children:v.jsx(Rl,{ref:o,tableRef:n,...s})}):null,v.jsx("div",{className:l?mn["full-wrapper__table"]:void 0,children:v.jsx(ac,{ref:n,searchFormRef:o,fullHeight:l,tableProps:r})}),a?v.jsx(un,{ref:i,...a}):null]})},cc=m.forwardRef(lc);k.XphActions=ct,k.XphAuth=tl,k.XphCrudFormDialog=un,k.XphDialog=sn,k.XphExtendCompPropsProvider=ba,k.XphForm=Vt,k.XphPortal=an,k.XphTable=cc,k.buildUUID=tr,k.getValueByPath=rr,k.getValuesByPathObj=_t,k.isChildrenColumnProps=fn,k.isComponentActionItemProps=Nt,k.isComponentColumnProps=dn,k.isComponentFormItemProps=ut,k.isRenderActionItemProps=Gr,k.isRenderFormItemProps=dt,k.useAsyncState=Zr,k.useXphExtendCompProps=De,k.useXphForm=gl,Object.defineProperty(k,Symbol.toStringTag,{value:"Module"})});
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
._minimize-
|
|
1
|
+
._minimize-windows_y0g8r_1{--xph-dialog-chrome-color: var(--xph-dialog-muted-text, #666);position:absolute;pointer-events:auto;z-index:999;display:flex;flex-wrap:nowrap;align-items:center;justify-content:space-between;gap:8px;width:250px;transform:translate(-50%,-50%);padding:4px;background-color:var(--xph-dialog-bg, #fff);color:var(--xph-dialog-chrome-color);cursor:move;-webkit-user-select:none;user-select:none;border:1px solid var(--xph-dialog-border, #d9d9d9);box-shadow:0 3px 10px #0000001a;transition:box-shadow .16s ease,border-color .16s ease,background-color .16s ease,color .16s ease}.xph--dialog[data-xph-dialog-active=true]>._minimize-windows_y0g8r_1{--xph-dialog-chrome-color: var(--xph-dialog-text, #1f1f1f);background-color:var(--xph-dialog-header-active-bg, #e6f4ff);border-color:var(--xph-dialog-active-border, #91caff);box-shadow:0 8px 20px #0000002e}._minimize-windows-title_y0g8r_59{flex:1;min-width:0;padding-left:8px;font-weight:600;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}._minimize-windows-operate_y0g8r_79{display:flex;align-items:center;gap:4px;flex-wrap:nowrap;flex-shrink:0}@media (prefers-reduced-motion: reduce){._minimize-windows_y0g8r_1{transition:none}}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3{flex:0 0 32px;width:32px;min-width:32px;height:32px;padding:0;border:0;border-radius:4px;font-size:16px;line-height:1;box-shadow:none;transition:color .15s ease,background-color .15s ease}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3 ._window-control-icon_1j8ma_31{font-size:16px}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3:not(:disabled){color:var(--xph-dialog-chrome-color, #595959);background-color:transparent}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3:not(:disabled):hover,._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3:not(:disabled):active{color:var(--xph-dialog-chrome-color, #595959);background-color:var(--xph-dialog-control-hover-bg, rgba(0, 0, 0, .06))}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3._window-control-close_1j8ma_61:not(:disabled):hover,._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3._window-control-close_1j8ma_61:not(:disabled):active{color:var(--xph-dialog-close-color, #fff);background-color:var(--xph-dialog-close-hover-bg, #d13438)}._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3:focus-visible{outline:2px solid var(--xph-dialog-active-border, #91caff);outline-offset:-2px}@media (prefers-reduced-motion: reduce){._window-control_1j8ma_3._window-control_1j8ma_3._window-control_1j8ma_3{transition:none}}._xph-dialog-mask_pi1qv_1{position:absolute;top:0;right:0;bottom:0;left:0;background-color:#000;opacity:.7;z-index:999;pointer-events:auto}._xph-dialog-wrapper_pi1qv_19{--xph-dialog-chrome-color: var(--xph-dialog-muted-text, #666);position:absolute;pointer-events:auto;z-index:999;background-color:var(--xph-dialog-bg, #fff);color:var(--xph-dialog-text, #1f1f1f);transform:translate(-50%,-50%);display:flex;flex-direction:column;overflow:hidden;outline:1px solid var(--xph-dialog-border, #d9d9d9);outline-offset:-1px;box-shadow:0 3px 10px #0000001a;transition:box-shadow .16s ease,outline-color .16s ease}.xph--dialog[data-xph-dialog-active=true]>._xph-dialog-wrapper_pi1qv_19{--xph-dialog-chrome-color: var(--xph-dialog-text, #1f1f1f);outline-color:var(--xph-dialog-active-border, #91caff);box-shadow:0 12px 32px #0003,0 3px 8px #00000014}._dialog__header_pi1qv_69{display:flex;padding:6px 8px 6px 12px;gap:8px;justify-content:space-between;align-items:center;cursor:move;-webkit-user-select:none;user-select:none;border-bottom:1px solid var(--xph-dialog-separator, #f0f0f0);background-color:var(--xph-dialog-header-bg, #fafafa);color:var(--xph-dialog-chrome-color);transition:background-color .16s ease,color .16s ease}.xph--dialog[data-xph-dialog-active=true]>._xph-dialog-wrapper_pi1qv_19>._dialog__header_pi1qv_69{background-color:var(--xph-dialog-header-active-bg, #e6f4ff)}._dialog__title_pi1qv_109{flex:1;min-width:0;font-weight:600}._dialog__title-text_pi1qv_121{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}._dialog__header-btns_pi1qv_131{display:flex;flex-shrink:0;align-items:center;gap:4px}@media (prefers-reduced-motion: reduce){._xph-dialog-wrapper_pi1qv_19,._dialog__header_pi1qv_69{transition:none}}._dialog__main_pi1qv_157{flex:1;height:0;box-sizing:border-box;padding:16px;overflow-y:auto}._dialog__footer_pi1qv_171{padding:8px;display:flex;justify-content:flex-end;gap:8px}._dialog__resize_pi1qv_185{position:absolute;width:8px;height:8px;-webkit-user-select:none;user-select:none}._dialog__resize-lt_pi1qv_199{top:0;left:0;cursor:nw-resize}._dialog__resize-rt_pi1qv_211{top:0;right:0;cursor:ne-resize}._dialog__resize-rb_pi1qv_223{right:0;bottom:0;cursor:nw-resize}._dialog__resize-lb_pi1qv_235{bottom:0;left:0;cursor:ne-resize}._dialog__main_pi1qv_157::-webkit-scrollbar{width:12px;height:12px}._dialog__main_pi1qv_157::-webkit-scrollbar-track{background:#f1f1f1;border-radius:10px}._dialog__main_pi1qv_157::-webkit-scrollbar-thumb{background:#888;border-radius:10px}._dialog__main_pi1qv_157::-webkit-scrollbar-thumb:hover{background:#555}._dialog__main_pi1qv_157{scrollbar-width:thin;scrollbar-color:#888 #f1f1f1}._form-item-force_1hsf3_1{flex-basis:100%;height:0}._form-item-hidden_1hsf3_9{display:none}._collapse-wrapper_ylm01_1{display:inline-block;margin-right:8px}._group-wrapper_g8zqi_1{display:flex;flex:1;width:0}._xph-form-action_8ws73_1{display:flex;align-items:center;gap:8px}._cellfunc-actions_14drt_1{display:flex;align-items:center;gap:4px;flex-wrap:wrap}._main-container_1yx5k_1{width:100%;height:100%;display:flex;flex-direction:column}._container__toolbar_1yx5k_13{display:flex;gap:8px;margin:4px 0;align-items:center;flex-wrap:wrap}._container__table_1yx5k_27{flex:1;height:0}._container__pagination_1yx5k_35{display:flex;justify-content:flex-end;align-items:center;margin-right:8px}._xph-table-full-wrapper_mdv0g_1{width:100%;height:100%;display:flex;flex-direction:column}._full-wrapper__table_mdv0g_13{flex:1;height:0}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
2
|
+
|
|
3
|
+
declare const useDialogLayer: ({ container, mask, visible, }: {
|
|
4
|
+
container: HTMLElement;
|
|
5
|
+
mask?: boolean | undefined;
|
|
6
|
+
visible: boolean;
|
|
7
|
+
}) => {
|
|
8
|
+
layerStyle: CSSProperties | undefined;
|
|
9
|
+
};
|
|
10
|
+
export default useDialogLayer;
|
|
@@ -1,25 +1,7 @@
|
|
|
1
1
|
import { IDialogProps } from '../types';
|
|
2
2
|
|
|
3
3
|
declare const useDialogPorps: (dialogProps: IDialogProps) => {
|
|
4
|
-
dialogProps:
|
|
5
|
-
getPopperContainer: () => HTMLElement;
|
|
6
|
-
width?: number | undefined;
|
|
7
|
-
height?: number | undefined;
|
|
8
|
-
mask?: boolean | undefined;
|
|
9
|
-
title?: string | undefined;
|
|
10
|
-
okProps?: Omit<import('antd').ButtonProps, "children" | "onClick"> | undefined;
|
|
11
|
-
cancelProps?: Omit<import('antd').ButtonProps, "children" | "onClick"> | undefined;
|
|
12
|
-
okText?: string | undefined;
|
|
13
|
-
cancelText?: string | undefined;
|
|
14
|
-
onOk?: ((args: any) => Promise<void>) | undefined;
|
|
15
|
-
onCancel?: ((args: any) => Promise<void>) | undefined;
|
|
16
|
-
renderFooter?: (({ loading }: {
|
|
17
|
-
loading: boolean;
|
|
18
|
-
}) => import('react').ReactElement<any, string | import('react').JSXElementConstructor<any>>) | undefined;
|
|
19
|
-
renderTitle?: (() => import('react').ReactElement<any, string | import('react').JSXElementConstructor<any>>) | undefined;
|
|
20
|
-
onOpen?: (() => void) | undefined;
|
|
21
|
-
onClose?: (() => void) | undefined;
|
|
22
|
-
};
|
|
4
|
+
dialogProps: IDialogProps;
|
|
23
5
|
baseDialogProps: Partial<IDialogProps>;
|
|
24
6
|
};
|
|
25
7
|
export default useDialogPorps;
|