var FTe=Object.defineProperty;var LTe=(e,t,r)=>t in e?FTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Ie=(e,t,r)=>LTe(e,typeof t!="symbol"?t+"":t,r);function ese(e,t){for(var r=0;rn[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}function Sx(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var u_={exports:{}},Zb={},d_={exports:{}},tn={};/** * @license React * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var I9;function _Te(){if(I9)return tn;I9=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),c=Symbol.for("react.memo"),u=Symbol.for("react.lazy"),d=Symbol.iterator;function h(V){return V===null||typeof V!="object"?null:(V=d&&V[d]||V["@@iterator"],typeof V=="function"?V:null)}var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},f=Object.assign,g={};function m(V,$,K){this.props=V,this.context=$,this.refs=g,this.updater=K||p}m.prototype.isReactComponent={},m.prototype.setState=function(V,$){if(typeof V!="object"&&typeof V!="function"&&V!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,V,$,"setState")},m.prototype.forceUpdate=function(V){this.updater.enqueueForceUpdate(this,V,"forceUpdate")};function v(){}v.prototype=m.prototype;function b(V,$,K){this.props=V,this.context=$,this.refs=g,this.updater=K||p}var S=b.prototype=new v;S.constructor=b,f(S,m.prototype),S.isPureReactComponent=!0;var x=Array.isArray,E=Object.prototype.hasOwnProperty,R={current:null},T={key:!0,ref:!0,__self:!0,__source:!0};function M(V,$,K){var q,X={},Y=null,oe=null;if($!=null)for(q in $.ref!==void 0&&(oe=$.ref),$.key!==void 0&&(Y=""+$.key),$)E.call($,q)&&!T.hasOwnProperty(q)&&(X[q]=$[q]);var ee=arguments.length-2;if(ee===1)X.children=K;else if(1>>1,$=N[V];if(0>>1;Vi(X,W))Y<$&&0>i(oe,X)?(N[V]=oe,N[Y]=W,V=Y):(N[V]=X,N[q]=W,V=q);else if(Y<$&&0>i(oe,W))N[V]=oe,N[Y]=W,V=Y;else break e}}return z}function i(N,z){var W=N.sortIndex-z.sortIndex;return W!==0?W:N.id-z.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var s=Date,a=s.now();e.unstable_now=function(){return s.now()-a}}var l=[],c=[],u=1,d=null,h=3,p=!1,f=!1,g=!1,m=typeof setTimeout=="function"?setTimeout:null,v=typeof clearTimeout=="function"?clearTimeout:null,b=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function S(N){for(var z=r(c);z!==null;){if(z.callback===null)n(c);else if(z.startTime<=N)n(c),z.sortIndex=z.expirationTime,t(l,z);else break;z=r(c)}}function x(N){if(g=!1,S(N),!f)if(r(l)!==null)f=!0,B(E);else{var z=r(c);z!==null&&H(x,z.startTime-N)}}function E(N,z){f=!1,g&&(g=!1,v(M),M=-1),p=!0;var W=h;try{for(S(z),d=r(l);d!==null&&(!(d.expirationTime>z)||N&&!I());){var V=d.callback;if(typeof V=="function"){d.callback=null,h=d.priorityLevel;var $=V(d.expirationTime<=z);z=e.unstable_now(),typeof $=="function"?d.callback=$:d===r(l)&&n(l),S(z)}else n(l);d=r(l)}if(d!==null)var K=!0;else{var q=r(c);q!==null&&H(x,q.startTime-z),K=!1}return K}finally{d=null,h=W,p=!1}}var R=!1,T=null,M=-1,D=5,A=-1;function I(){return!(e.unstable_now()-AN||125V?(N.sortIndex=W,t(c,N),r(l)===null&&N===r(c)&&(g?(v(M),M=-1):g=!0,H(x,W-V))):(N.sortIndex=$,t(l,N),f||p||(f=!0,B(E))),N},e.unstable_shouldYield=I,e.unstable_wrapCallback=function(N){var z=h;return function(){var W=h;h=z;try{return N.apply(this,arguments)}finally{h=W}}}})(f_)),f_}var _9;function BTe(){return _9||(_9=1,p_.exports=NTe()),p_.exports}/** * @license React * react-dom.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var O9;function $Te(){if(O9)return zs;O9=1;var e=l3(),t=BTe();function r(C){for(var w="https://reactjs.org/docs/error-decoder.html?invariant="+C,P=1;P"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),l=Object.prototype.hasOwnProperty,c=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,u={},d={};function h(C){return l.call(d,C)?!0:l.call(u,C)?!1:c.test(C)?d[C]=!0:(u[C]=!0,!1)}function p(C,w,P,_){if(P!==null&&P.type===0)return!1;switch(typeof w){case"function":case"symbol":return!0;case"boolean":return _?!1:P!==null?!P.acceptsBooleans:(C=C.toLowerCase().slice(0,5),C!=="data-"&&C!=="aria-");default:return!1}}function f(C,w,P,_){if(w===null||typeof w>"u"||p(C,w,P,_))return!0;if(_)return!1;if(P!==null)switch(P.type){case 3:return!w;case 4:return w===!1;case 5:return isNaN(w);case 6:return isNaN(w)||1>w}return!1}function g(C,w,P,_,G,U,te){this.acceptsBooleans=w===2||w===3||w===4,this.attributeName=_,this.attributeNamespace=G,this.mustUseProperty=P,this.propertyName=C,this.type=w,this.sanitizeURL=U,this.removeEmptyString=te}var m={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(C){m[C]=new g(C,0,!1,C,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(C){var w=C[0];m[w]=new g(w,1,!1,C[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(C){m[C]=new g(C,2,!1,C.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(C){m[C]=new g(C,2,!1,C,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(C){m[C]=new g(C,3,!1,C.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(C){m[C]=new g(C,3,!0,C,null,!1,!1)}),["capture","download"].forEach(function(C){m[C]=new g(C,4,!1,C,null,!1,!1)}),["cols","rows","size","span"].forEach(function(C){m[C]=new g(C,6,!1,C,null,!1,!1)}),["rowSpan","start"].forEach(function(C){m[C]=new g(C,5,!1,C.toLowerCase(),null,!1,!1)});var v=/[\-:]([a-z])/g;function b(C){return C[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(C){var w=C.replace(v,b);m[w]=new g(w,1,!1,C,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(C){var w=C.replace(v,b);m[w]=new g(w,1,!1,C,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(C){var w=C.replace(v,b);m[w]=new g(w,1,!1,C,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(C){m[C]=new g(C,1,!1,C.toLowerCase(),null,!1,!1)}),m.xlinkHref=new g("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(C){m[C]=new g(C,1,!1,C.toLowerCase(),null,!0,!0)});function S(C,w,P,_){var G=m.hasOwnProperty(w)?m[w]:null;(G!==null?G.type!==0:_||!(2ye||G[te]!==U[ye]){var Se=` `+G[te].replace(" at new "," at ");return C.displayName&&Se.includes("")&&(Se=Se.replace("",C.displayName)),Se}while(1<=te&&0<=ye);break}}}finally{K=!1,Error.prepareStackTrace=P}return(C=C?C.displayName||C.name:"")?$(C):""}function X(C){switch(C.tag){case 5:return $(C.type);case 16:return $("Lazy");case 13:return $("Suspense");case 19:return $("SuspenseList");case 0:case 2:case 15:return C=q(C.type,!1),C;case 11:return C=q(C.type.render,!1),C;case 1:return C=q(C.type,!0),C;default:return""}}function Y(C){if(C==null)return null;if(typeof C=="function")return C.displayName||C.name||null;if(typeof C=="string")return C;switch(C){case T:return"Fragment";case R:return"Portal";case D:return"Profiler";case M:return"StrictMode";case F:return"Suspense";case k:return"SuspenseList"}if(typeof C=="object")switch(C.$$typeof){case I:return(C.displayName||"Context")+".Consumer";case A:return(C._context.displayName||"Context")+".Provider";case L:var w=C.render;return C=C.displayName,C||(C=w.displayName||w.name||"",C=C!==""?"ForwardRef("+C+")":"ForwardRef"),C;case O:return w=C.displayName||null,w!==null?w:Y(C.type)||"Memo";case B:w=C._payload,C=C._init;try{return Y(C(w))}catch{}}return null}function oe(C){var w=C.type;switch(C.tag){case 24:return"Cache";case 9:return(w.displayName||"Context")+".Consumer";case 10:return(w._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return C=w.render,C=C.displayName||C.name||"",w.displayName||(C!==""?"ForwardRef("+C+")":"ForwardRef");case 7:return"Fragment";case 5:return w;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Y(w);case 8:return w===M?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof w=="function")return w.displayName||w.name||null;if(typeof w=="string")return w}return null}function ee(C){switch(typeof C){case"boolean":case"number":case"string":case"undefined":return C;case"object":return C;default:return""}}function ne(C){var w=C.type;return(C=C.nodeName)&&C.toLowerCase()==="input"&&(w==="checkbox"||w==="radio")}function le(C){var w=ne(C)?"checked":"value",P=Object.getOwnPropertyDescriptor(C.constructor.prototype,w),_=""+C[w];if(!C.hasOwnProperty(w)&&typeof P<"u"&&typeof P.get=="function"&&typeof P.set=="function"){var G=P.get,U=P.set;return Object.defineProperty(C,w,{configurable:!0,get:function(){return G.call(this)},set:function(te){_=""+te,U.call(this,te)}}),Object.defineProperty(C,w,{enumerable:P.enumerable}),{getValue:function(){return _},setValue:function(te){_=""+te},stopTracking:function(){C._valueTracker=null,delete C[w]}}}}function he(C){C._valueTracker||(C._valueTracker=le(C))}function re(C){if(!C)return!1;var w=C._valueTracker;if(!w)return!0;var P=w.getValue(),_="";return C&&(_=ne(C)?C.checked?"true":"false":C.value),C=_,C!==P?(w.setValue(C),!0):!1}function ie(C){if(C=C||(typeof document<"u"?document:void 0),typeof C>"u")return null;try{return C.activeElement||C.body}catch{return C.body}}function de(C,w){var P=w.checked;return W({},w,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:P??C._wrapperState.initialChecked})}function J(C,w){var P=w.defaultValue==null?"":w.defaultValue,_=w.checked!=null?w.checked:w.defaultChecked;P=ee(w.value!=null?w.value:P),C._wrapperState={initialChecked:_,initialValue:P,controlled:w.type==="checkbox"||w.type==="radio"?w.checked!=null:w.value!=null}}function ue(C,w){w=w.checked,w!=null&&S(C,"checked",w,!1)}function ve(C,w){ue(C,w);var P=ee(w.value),_=w.type;if(P!=null)_==="number"?(P===0&&C.value===""||C.value!=P)&&(C.value=""+P):C.value!==""+P&&(C.value=""+P);else if(_==="submit"||_==="reset"){C.removeAttribute("value");return}w.hasOwnProperty("value")?me(C,w.type,P):w.hasOwnProperty("defaultValue")&&me(C,w.type,ee(w.defaultValue)),w.checked==null&&w.defaultChecked!=null&&(C.defaultChecked=!!w.defaultChecked)}function pe(C,w,P){if(w.hasOwnProperty("value")||w.hasOwnProperty("defaultValue")){var _=w.type;if(!(_!=="submit"&&_!=="reset"||w.value!==void 0&&w.value!==null))return;w=""+C._wrapperState.initialValue,P||w===C.value||(C.value=w),C.defaultValue=w}P=C.name,P!==""&&(C.name=""),C.defaultChecked=!!C._wrapperState.initialChecked,P!==""&&(C.name=P)}function me(C,w,P){(w!=="number"||ie(C.ownerDocument)!==C)&&(P==null?C.defaultValue=""+C._wrapperState.initialValue:C.defaultValue!==""+P&&(C.defaultValue=""+P))}var ke=Array.isArray;function De(C,w,P,_){if(C=C.options,w){w={};for(var G=0;G"+w.valueOf().toString()+"",w=Ze.firstChild;C.firstChild;)C.removeChild(C.firstChild);for(;w.firstChild;)C.appendChild(w.firstChild)}});function tt(C,w){if(w){var P=C.firstChild;if(P&&P===C.lastChild&&P.nodeType===3){P.nodeValue=w;return}}C.textContent=w}var Ne={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},rt=["Webkit","ms","Moz","O"];Object.keys(Ne).forEach(function(C){rt.forEach(function(w){w=w+C.charAt(0).toUpperCase()+C.substring(1),Ne[w]=Ne[C]})});function ot(C,w,P){return w==null||typeof w=="boolean"||w===""?"":P||typeof w!="number"||w===0||Ne.hasOwnProperty(C)&&Ne[C]?(""+w).trim():w+"px"}function Ye(C,w){C=C.style;for(var P in w)if(w.hasOwnProperty(P)){var _=P.indexOf("--")===0,G=ot(P,w[P],_);P==="float"&&(P="cssFloat"),_?C.setProperty(P,G):C[P]=G}}var Ae=W({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function nt(C,w){if(w){if(Ae[C]&&(w.children!=null||w.dangerouslySetInnerHTML!=null))throw Error(r(137,C));if(w.dangerouslySetInnerHTML!=null){if(w.children!=null)throw Error(r(60));if(typeof w.dangerouslySetInnerHTML!="object"||!("__html"in w.dangerouslySetInnerHTML))throw Error(r(61))}if(w.style!=null&&typeof w.style!="object")throw Error(r(62))}}function Et(C,w){if(C.indexOf("-")===-1)return typeof w.is=="string";switch(C){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Tt=null;function kt(C){return C=C.target||C.srcElement||window,C.correspondingUseElement&&(C=C.correspondingUseElement),C.nodeType===3?C.parentNode:C}var Wt=null,at=null,lt=null;function Ut(C){if(C=kb(C)){if(typeof Wt!="function")throw Error(r(280));var w=C.stateNode;w&&(w=iE(w),Wt(C.stateNode,C.type,w))}}function cr(C){at?lt?lt.push(C):lt=[C]:at=C}function _e(){if(at){var C=at,w=lt;if(lt=at=null,Ut(C),w)for(C=0;C>>=0,C===0?32:31-(vr(C)/wn|0)|0}var Ni=64,Ha=4194304;function Uo(C){switch(C&-C){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return C&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return C&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return C}}function ks(C,w){var P=C.pendingLanes;if(P===0)return 0;var _=0,G=C.suspendedLanes,U=C.pingedLanes,te=P&268435455;if(te!==0){var ye=te&~G;ye!==0?_=Uo(ye):(U&=te,U!==0&&(_=Uo(U)))}else te=P&~G,te!==0?_=Uo(te):U!==0&&(_=Uo(U));if(_===0)return 0;if(w!==0&&w!==_&&(w&G)===0&&(G=_&-_,U=w&-w,G>=U||G===16&&(U&4194240)!==0))return w;if((_&4)!==0&&(_|=P&16),w=C.entangledLanes,w!==0)for(C=C.entanglements,w&=_;0P;P++)w.push(C);return w}function ga(C,w,P){C.pendingLanes|=w,w!==536870912&&(C.suspendedLanes=0,C.pingedLanes=0),C=C.eventTimes,w=31-Ct(w),C[w]=P}function z1(C,w){var P=C.pendingLanes&~w;C.pendingLanes=w,C.suspendedLanes=0,C.pingedLanes=0,C.expiredLanes&=w,C.mutableReadLanes&=w,C.entangledLanes&=w,w=C.entanglements;var _=C.eventTimes;for(C=C.expirationTimes;0=Pb),wU=" ",xU=!1;function EU(C,w){switch(C){case"keyup":return PEe.indexOf(w.keyCode)!==-1;case"keydown":return w.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function TU(C){return C=C.detail,typeof C=="object"&&"data"in C?C.data:null}var Hm=!1;function IEe(C,w){switch(C){case"compositionend":return TU(w);case"keypress":return w.which!==32?null:(xU=!0,wU);case"textInput":return C=w.data,C===wU&&xU?null:C;default:return null}}function DEe(C,w){if(Hm)return C==="compositionend"||!WF&&EU(C,w)?(C=mU(),K1=BF=oh=null,Hm=!1,C):null;switch(C){case"paste":return null;case"keypress":if(!(w.ctrlKey||w.altKey||w.metaKey)||w.ctrlKey&&w.altKey){if(w.char&&1=w)return{node:P,offset:w-C};C=_}e:{for(;P;){if(P.nextSibling){P=P.nextSibling;break e}P=P.parentNode}P=void 0}P=FU(P)}}function _U(C,w){return C&&w?C===w?!0:C&&C.nodeType===3?!1:w&&w.nodeType===3?_U(C,w.parentNode):"contains"in C?C.contains(w):C.compareDocumentPosition?!!(C.compareDocumentPosition(w)&16):!1:!1}function OU(){for(var C=window,w=ie();w instanceof C.HTMLIFrameElement;){try{var P=typeof w.contentWindow.location.href=="string"}catch{P=!1}if(P)C=w.contentWindow;else break;w=ie(C.document)}return w}function KF(C){var w=C&&C.nodeName&&C.nodeName.toLowerCase();return w&&(w==="input"&&(C.type==="text"||C.type==="search"||C.type==="tel"||C.type==="url"||C.type==="password")||w==="textarea"||C.contentEditable==="true")}function $Ee(C){var w=OU(),P=C.focusedElem,_=C.selectionRange;if(w!==P&&P&&P.ownerDocument&&_U(P.ownerDocument.documentElement,P)){if(_!==null&&KF(P)){if(w=_.start,C=_.end,C===void 0&&(C=w),"selectionStart"in P)P.selectionStart=w,P.selectionEnd=Math.min(C,P.value.length);else if(C=(w=P.ownerDocument||document)&&w.defaultView||window,C.getSelection){C=C.getSelection();var G=P.textContent.length,U=Math.min(_.start,G);_=_.end===void 0?U:Math.min(_.end,G),!C.extend&&U>_&&(G=_,_=U,U=G),G=LU(P,U);var te=LU(P,_);G&&te&&(C.rangeCount!==1||C.anchorNode!==G.node||C.anchorOffset!==G.offset||C.focusNode!==te.node||C.focusOffset!==te.offset)&&(w=w.createRange(),w.setStart(G.node,G.offset),C.removeAllRanges(),U>_?(C.addRange(w),C.extend(te.node,te.offset)):(w.setEnd(te.node,te.offset),C.addRange(w)))}}for(w=[],C=P;C=C.parentNode;)C.nodeType===1&&w.push({element:C,left:C.scrollLeft,top:C.scrollTop});for(typeof P.focus=="function"&&P.focus(),P=0;P=document.documentMode,Wm=null,qF=null,Ab=null,XF=!1;function kU(C,w,P){var _=P.window===P?P.document:P.nodeType===9?P:P.ownerDocument;XF||Wm==null||Wm!==ie(_)||(_=Wm,"selectionStart"in _&&KF(_)?_={start:_.selectionStart,end:_.selectionEnd}:(_=(_.ownerDocument&&_.ownerDocument.defaultView||window).getSelection(),_={anchorNode:_.anchorNode,anchorOffset:_.anchorOffset,focusNode:_.focusNode,focusOffset:_.focusOffset}),Ab&&Db(Ab,_)||(Ab=_,_=tE(qF,"onSelect"),0<_.length&&(w=new $F("onSelect","select",null,w,P),C.push({event:w,listeners:_}),w.target=Wm)))}function Q1(C,w){var P={};return P[C.toLowerCase()]=w.toLowerCase(),P["Webkit"+C]="webkit"+w,P["Moz"+C]="moz"+w,P}var Um={animationend:Q1("Animation","AnimationEnd"),animationiteration:Q1("Animation","AnimationIteration"),animationstart:Q1("Animation","AnimationStart"),transitionend:Q1("Transition","TransitionEnd")},YF={},NU={};a&&(NU=document.createElement("div").style,"AnimationEvent"in window||(delete Um.animationend.animation,delete Um.animationiteration.animation,delete Um.animationstart.animation),"TransitionEvent"in window||delete Um.transitionend.transition);function J1(C){if(YF[C])return YF[C];if(!Um[C])return C;var w=Um[C],P;for(P in w)if(w.hasOwnProperty(P)&&P in NU)return YF[C]=w[P];return C}var BU=J1("animationend"),$U=J1("animationiteration"),GU=J1("animationstart"),VU=J1("transitionend"),zU=new Map,HU="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function sh(C,w){zU.set(C,w),o(w,[C])}for(var ZF=0;ZFXm||(C.current=aL[Xm],aL[Xm]=null,Xm--)}function Hn(C,w){Xm++,aL[Xm]=C.current,C.current=w}var ch={},jo=lh(ch),Ns=lh(!1),af=ch;function Ym(C,w){var P=C.type.contextTypes;if(!P)return ch;var _=C.stateNode;if(_&&_.__reactInternalMemoizedUnmaskedChildContext===w)return _.__reactInternalMemoizedMaskedChildContext;var G={},U;for(U in P)G[U]=w[U];return _&&(C=C.stateNode,C.__reactInternalMemoizedUnmaskedChildContext=w,C.__reactInternalMemoizedMaskedChildContext=G),G}function Bs(C){return C=C.childContextTypes,C!=null}function oE(){Xn(Ns),Xn(jo)}function ZU(C,w,P){if(jo.current!==ch)throw Error(r(168));Hn(jo,w),Hn(Ns,P)}function QU(C,w,P){var _=C.stateNode;if(w=w.childContextTypes,typeof _.getChildContext!="function")return P;_=_.getChildContext();for(var G in _)if(!(G in w))throw Error(r(108,oe(C)||"Unknown",G));return W({},P,_)}function sE(C){return C=(C=C.stateNode)&&C.__reactInternalMemoizedMergedChildContext||ch,af=jo.current,Hn(jo,C),Hn(Ns,Ns.current),!0}function JU(C,w,P){var _=C.stateNode;if(!_)throw Error(r(169));P?(C=QU(C,w,af),_.__reactInternalMemoizedMergedChildContext=C,Xn(Ns),Xn(jo),Hn(jo,C)):Xn(Ns),Hn(Ns,P)}var Bu=null,aE=!1,lL=!1;function e7(C){Bu===null?Bu=[C]:Bu.push(C)}function ZEe(C){aE=!0,e7(C)}function uh(){if(!lL&&Bu!==null){lL=!0;var C=0,w=Cn;try{var P=Bu;for(Cn=1;C>=te,G-=te,$u=1<<32-Ct(w)+G|P<Fr?(vo=xr,xr=null):vo=xr.sibling;var bn=ut(Le,xr,Ge[Fr],Rt);if(bn===null){xr===null&&(xr=vo);break}C&&xr&&bn.alternate===null&&w(Le,xr),Me=U(bn,Me,Fr),wr===null?dr=bn:wr.sibling=bn,wr=bn,xr=vo}if(Fr===Ge.length)return P(Le,xr),ni&&cf(Le,Fr),dr;if(xr===null){for(;FrFr?(vo=xr,xr=null):vo=xr.sibling;var Ch=ut(Le,xr,bn.value,Rt);if(Ch===null){xr===null&&(xr=vo);break}C&&xr&&Ch.alternate===null&&w(Le,xr),Me=U(Ch,Me,Fr),wr===null?dr=Ch:wr.sibling=Ch,wr=Ch,xr=vo}if(bn.done)return P(Le,xr),ni&&cf(Le,Fr),dr;if(xr===null){for(;!bn.done;Fr++,bn=Ge.next())bn=bt(Le,bn.value,Rt),bn!==null&&(Me=U(bn,Me,Fr),wr===null?dr=bn:wr.sibling=bn,wr=bn);return ni&&cf(Le,Fr),dr}for(xr=_(Le,xr);!bn.done;Fr++,bn=Ge.next())bn=Jt(xr,Le,Fr,bn.value,Rt),bn!==null&&(C&&bn.alternate!==null&&xr.delete(bn.key===null?Fr:bn.key),Me=U(bn,Me,Fr),wr===null?dr=bn:wr.sibling=bn,wr=bn);return C&&xr.forEach(function(ATe){return w(Le,ATe)}),ni&&cf(Le,Fr),dr}function Ri(Le,Me,Ge,Rt){if(typeof Ge=="object"&&Ge!==null&&Ge.type===T&&Ge.key===null&&(Ge=Ge.props.children),typeof Ge=="object"&&Ge!==null){switch(Ge.$$typeof){case E:e:{for(var dr=Ge.key,wr=Me;wr!==null;){if(wr.key===dr){if(dr=Ge.type,dr===T){if(wr.tag===7){P(Le,wr.sibling),Me=G(wr,Ge.props.children),Me.return=Le,Le=Me;break e}}else if(wr.elementType===dr||typeof dr=="object"&&dr!==null&&dr.$$typeof===B&&s7(dr)===wr.type){P(Le,wr.sibling),Me=G(wr,Ge.props),Me.ref=Nb(Le,wr,Ge),Me.return=Le,Le=Me;break e}P(Le,wr);break}else w(Le,wr);wr=wr.sibling}Ge.type===T?(Me=vf(Ge.props.children,Le.mode,Rt,Ge.key),Me.return=Le,Le=Me):(Rt=OE(Ge.type,Ge.key,Ge.props,null,Le.mode,Rt),Rt.ref=Nb(Le,Me,Ge),Rt.return=Le,Le=Rt)}return te(Le);case R:e:{for(wr=Ge.key;Me!==null;){if(Me.key===wr)if(Me.tag===4&&Me.stateNode.containerInfo===Ge.containerInfo&&Me.stateNode.implementation===Ge.implementation){P(Le,Me.sibling),Me=G(Me,Ge.children||[]),Me.return=Le,Le=Me;break e}else{P(Le,Me);break}else w(Le,Me);Me=Me.sibling}Me=o_(Ge,Le.mode,Rt),Me.return=Le,Le=Me}return te(Le);case B:return wr=Ge._init,Ri(Le,Me,wr(Ge._payload),Rt)}if(ke(Ge))return or(Le,Me,Ge,Rt);if(z(Ge))return sr(Le,Me,Ge,Rt);dE(Le,Ge)}return typeof Ge=="string"&&Ge!==""||typeof Ge=="number"?(Ge=""+Ge,Me!==null&&Me.tag===6?(P(Le,Me.sibling),Me=G(Me,Ge),Me.return=Le,Le=Me):(P(Le,Me),Me=i_(Ge,Le.mode,Rt),Me.return=Le,Le=Me),te(Le)):P(Le,Me)}return Ri}var ev=a7(!0),l7=a7(!1),hE=lh(null),pE=null,tv=null,fL=null;function gL(){fL=tv=pE=null}function mL(C){var w=hE.current;Xn(hE),C._currentValue=w}function vL(C,w,P){for(;C!==null;){var _=C.alternate;if((C.childLanes&w)!==w?(C.childLanes|=w,_!==null&&(_.childLanes|=w)):_!==null&&(_.childLanes&w)!==w&&(_.childLanes|=w),C===P)break;C=C.return}}function rv(C,w){pE=C,fL=tv=null,C=C.dependencies,C!==null&&C.firstContext!==null&&((C.lanes&w)!==0&&($s=!0),C.firstContext=null)}function ja(C){var w=C._currentValue;if(fL!==C)if(C={context:C,memoizedValue:w,next:null},tv===null){if(pE===null)throw Error(r(308));tv=C,pE.dependencies={lanes:0,firstContext:C}}else tv=tv.next=C;return w}var uf=null;function yL(C){uf===null?uf=[C]:uf.push(C)}function c7(C,w,P,_){var G=w.interleaved;return G===null?(P.next=P,yL(w)):(P.next=G.next,G.next=P),w.interleaved=P,Vu(C,_)}function Vu(C,w){C.lanes|=w;var P=C.alternate;for(P!==null&&(P.lanes|=w),P=C,C=C.return;C!==null;)C.childLanes|=w,P=C.alternate,P!==null&&(P.childLanes|=w),P=C,C=C.return;return P.tag===3?P.stateNode:null}var dh=!1;function CL(C){C.updateQueue={baseState:C.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function u7(C,w){C=C.updateQueue,w.updateQueue===C&&(w.updateQueue={baseState:C.baseState,firstBaseUpdate:C.firstBaseUpdate,lastBaseUpdate:C.lastBaseUpdate,shared:C.shared,effects:C.effects})}function zu(C,w){return{eventTime:C,lane:w,tag:0,payload:null,callback:null,next:null}}function hh(C,w,P){var _=C.updateQueue;if(_===null)return null;if(_=_.shared,(mn&2)!==0){var G=_.pending;return G===null?w.next=w:(w.next=G.next,G.next=w),_.pending=w,Vu(C,P)}return G=_.interleaved,G===null?(w.next=w,yL(_)):(w.next=G.next,G.next=w),_.interleaved=w,Vu(C,P)}function fE(C,w,P){if(w=w.updateQueue,w!==null&&(w=w.shared,(P&4194240)!==0)){var _=w.lanes;_&=C.pendingLanes,P|=_,w.lanes=P,Cb(C,P)}}function d7(C,w){var P=C.updateQueue,_=C.alternate;if(_!==null&&(_=_.updateQueue,P===_)){var G=null,U=null;if(P=P.firstBaseUpdate,P!==null){do{var te={eventTime:P.eventTime,lane:P.lane,tag:P.tag,payload:P.payload,callback:P.callback,next:null};U===null?G=U=te:U=U.next=te,P=P.next}while(P!==null);U===null?G=U=w:U=U.next=w}else G=U=w;P={baseState:_.baseState,firstBaseUpdate:G,lastBaseUpdate:U,shared:_.shared,effects:_.effects},C.updateQueue=P;return}C=P.lastBaseUpdate,C===null?P.firstBaseUpdate=w:C.next=w,P.lastBaseUpdate=w}function gE(C,w,P,_){var G=C.updateQueue;dh=!1;var U=G.firstBaseUpdate,te=G.lastBaseUpdate,ye=G.shared.pending;if(ye!==null){G.shared.pending=null;var Se=ye,He=Se.next;Se.next=null,te===null?U=He:te.next=He,te=Se;var ft=C.alternate;ft!==null&&(ft=ft.updateQueue,ye=ft.lastBaseUpdate,ye!==te&&(ye===null?ft.firstBaseUpdate=He:ye.next=He,ft.lastBaseUpdate=Se))}if(U!==null){var bt=G.baseState;te=0,ft=He=Se=null,ye=U;do{var ut=ye.lane,Jt=ye.eventTime;if((_&ut)===ut){ft!==null&&(ft=ft.next={eventTime:Jt,lane:0,tag:ye.tag,payload:ye.payload,callback:ye.callback,next:null});e:{var or=C,sr=ye;switch(ut=w,Jt=P,sr.tag){case 1:if(or=sr.payload,typeof or=="function"){bt=or.call(Jt,bt,ut);break e}bt=or;break e;case 3:or.flags=or.flags&-65537|128;case 0:if(or=sr.payload,ut=typeof or=="function"?or.call(Jt,bt,ut):or,ut==null)break e;bt=W({},bt,ut);break e;case 2:dh=!0}}ye.callback!==null&&ye.lane!==0&&(C.flags|=64,ut=G.effects,ut===null?G.effects=[ye]:ut.push(ye))}else Jt={eventTime:Jt,lane:ut,tag:ye.tag,payload:ye.payload,callback:ye.callback,next:null},ft===null?(He=ft=Jt,Se=bt):ft=ft.next=Jt,te|=ut;if(ye=ye.next,ye===null){if(ye=G.shared.pending,ye===null)break;ut=ye,ye=ut.next,ut.next=null,G.lastBaseUpdate=ut,G.shared.pending=null}}while(!0);if(ft===null&&(Se=bt),G.baseState=Se,G.firstBaseUpdate=He,G.lastBaseUpdate=ft,w=G.shared.interleaved,w!==null){G=w;do te|=G.lane,G=G.next;while(G!==w)}else U===null&&(G.shared.lanes=0);pf|=te,C.lanes=te,C.memoizedState=bt}}function h7(C,w,P){if(C=w.effects,w.effects=null,C!==null)for(w=0;wP?P:4,C(!0);var _=EL.transition;EL.transition={};try{C(!1),w()}finally{Cn=P,EL.transition=_}}function A7(){return Ka().memoizedState}function tTe(C,w,P){var _=mh(C);if(P={lane:_,action:P,hasEagerState:!1,eagerState:null,next:null},F7(C))L7(w,P);else if(P=c7(C,w,P,_),P!==null){var G=vs();zl(P,C,_,G),_7(P,w,_)}}function rTe(C,w,P){var _=mh(C),G={lane:_,action:P,hasEagerState:!1,eagerState:null,next:null};if(F7(C))L7(w,G);else{var U=C.alternate;if(C.lanes===0&&(U===null||U.lanes===0)&&(U=w.lastRenderedReducer,U!==null))try{var te=w.lastRenderedState,ye=U(te,P);if(G.hasEagerState=!0,G.eagerState=ye,Nl(ye,te)){var Se=w.interleaved;Se===null?(G.next=G,yL(w)):(G.next=Se.next,Se.next=G),w.interleaved=G;return}}catch{}finally{}P=c7(C,w,G,_),P!==null&&(G=vs(),zl(P,C,_,G),_7(P,w,_))}}function F7(C){var w=C.alternate;return C===ci||w!==null&&w===ci}function L7(C,w){Vb=yE=!0;var P=C.pending;P===null?w.next=w:(w.next=P.next,P.next=w),C.pending=w}function _7(C,w,P){if((P&4194240)!==0){var _=w.lanes;_&=C.pendingLanes,P|=_,w.lanes=P,Cb(C,P)}}var SE={readContext:ja,useCallback:Ko,useContext:Ko,useEffect:Ko,useImperativeHandle:Ko,useInsertionEffect:Ko,useLayoutEffect:Ko,useMemo:Ko,useReducer:Ko,useRef:Ko,useState:Ko,useDebugValue:Ko,useDeferredValue:Ko,useTransition:Ko,useMutableSource:Ko,useSyncExternalStore:Ko,useId:Ko,unstable_isNewReconciler:!1},nTe={readContext:ja,useCallback:function(C,w){return Lc().memoizedState=[C,w===void 0?null:w],C},useContext:ja,useEffect:x7,useImperativeHandle:function(C,w,P){return P=P!=null?P.concat([C]):null,CE(4194308,4,R7.bind(null,w,C),P)},useLayoutEffect:function(C,w){return CE(4194308,4,C,w)},useInsertionEffect:function(C,w){return CE(4,2,C,w)},useMemo:function(C,w){var P=Lc();return w=w===void 0?null:w,C=C(),P.memoizedState=[C,w],C},useReducer:function(C,w,P){var _=Lc();return w=P!==void 0?P(w):w,_.memoizedState=_.baseState=w,C={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:C,lastRenderedState:w},_.queue=C,C=C.dispatch=tTe.bind(null,ci,C),[_.memoizedState,C]},useRef:function(C){var w=Lc();return C={current:C},w.memoizedState=C},useState:S7,useDebugValue:AL,useDeferredValue:function(C){return Lc().memoizedState=C},useTransition:function(){var C=S7(!1),w=C[0];return C=eTe.bind(null,C[1]),Lc().memoizedState=C,[w,C]},useMutableSource:function(){},useSyncExternalStore:function(C,w,P){var _=ci,G=Lc();if(ni){if(P===void 0)throw Error(r(407));P=P()}else{if(P=w(),mo===null)throw Error(r(349));(hf&30)!==0||m7(_,w,P)}G.memoizedState=P;var U={value:P,getSnapshot:w};return G.queue=U,x7(y7.bind(null,_,U,C),[C]),_.flags|=2048,Wb(9,v7.bind(null,_,U,P,w),void 0,null),P},useId:function(){var C=Lc(),w=mo.identifierPrefix;if(ni){var P=Gu,_=$u;P=(_&~(1<<32-Ct(_)-1)).toString(32)+P,w=":"+w+"R"+P,P=zb++,0<\/script>",C=C.removeChild(C.firstChild)):typeof _.is=="string"?C=te.createElement(P,{is:_.is}):(C=te.createElement(P),P==="select"&&(te=C,_.multiple?te.multiple=!0:_.size&&(te.size=_.size))):C=te.createElementNS(C,P),C[Ac]=w,C[Ob]=_,e9(C,w,!1,!1),w.stateNode=C;e:{switch(te=Et(P,_),P){case"dialog":qn("cancel",C),qn("close",C),G=_;break;case"iframe":case"object":case"embed":qn("load",C),G=_;break;case"video":case"audio":for(G=0;Gav&&(w.flags|=128,_=!0,Ub(U,!1),w.lanes=4194304)}else{if(!_)if(C=mE(te),C!==null){if(w.flags|=128,_=!0,P=C.updateQueue,P!==null&&(w.updateQueue=P,w.flags|=4),Ub(U,!0),U.tail===null&&U.tailMode==="hidden"&&!te.alternate&&!ni)return qo(w),null}else 2*rr()-U.renderingStartTime>av&&P!==1073741824&&(w.flags|=128,_=!0,Ub(U,!1),w.lanes=4194304);U.isBackwards?(te.sibling=w.child,w.child=te):(P=U.last,P!==null?P.sibling=te:w.child=te,U.last=te)}return U.tail!==null?(w=U.tail,U.rendering=w,U.tail=w.sibling,U.renderingStartTime=rr(),w.sibling=null,P=li.current,Hn(li,_?P&1|2:P&1),w):(qo(w),null);case 22:case 23:return t_(),_=w.memoizedState!==null,C!==null&&C.memoizedState!==null!==_&&(w.flags|=8192),_&&(w.mode&1)!==0?(Ca&1073741824)!==0&&(qo(w),w.subtreeFlags&6&&(w.flags|=8192)):qo(w),null;case 24:return null;case 25:return null}throw Error(r(156,w.tag))}function dTe(C,w){switch(uL(w),w.tag){case 1:return Bs(w.type)&&oE(),C=w.flags,C&65536?(w.flags=C&-65537|128,w):null;case 3:return nv(),Xn(Ns),Xn(jo),xL(),C=w.flags,(C&65536)!==0&&(C&128)===0?(w.flags=C&-65537|128,w):null;case 5:return SL(w),null;case 13:if(Xn(li),C=w.memoizedState,C!==null&&C.dehydrated!==null){if(w.alternate===null)throw Error(r(340));Jm()}return C=w.flags,C&65536?(w.flags=C&-65537|128,w):null;case 19:return Xn(li),null;case 4:return nv(),null;case 10:return mL(w.type._context),null;case 22:case 23:return t_(),null;case 24:return null;default:return null}}var TE=!1,Xo=!1,hTe=typeof WeakSet=="function"?WeakSet:Set,nr=null;function ov(C,w){var P=C.ref;if(P!==null)if(typeof P=="function")try{P(null)}catch(_){gi(C,w,_)}else P.current=null}function HL(C,w,P){try{P()}catch(_){gi(C,w,_)}}var n9=!1;function pTe(C,w){if(tL=U1,C=OU(),KF(C)){if("selectionStart"in C)var P={start:C.selectionStart,end:C.selectionEnd};else e:{P=(P=C.ownerDocument)&&P.defaultView||window;var _=P.getSelection&&P.getSelection();if(_&&_.rangeCount!==0){P=_.anchorNode;var G=_.anchorOffset,U=_.focusNode;_=_.focusOffset;try{P.nodeType,U.nodeType}catch{P=null;break e}var te=0,ye=-1,Se=-1,He=0,ft=0,bt=C,ut=null;t:for(;;){for(var Jt;bt!==P||G!==0&&bt.nodeType!==3||(ye=te+G),bt!==U||_!==0&&bt.nodeType!==3||(Se=te+_),bt.nodeType===3&&(te+=bt.nodeValue.length),(Jt=bt.firstChild)!==null;)ut=bt,bt=Jt;for(;;){if(bt===C)break t;if(ut===P&&++He===G&&(ye=te),ut===U&&++ft===_&&(Se=te),(Jt=bt.nextSibling)!==null)break;bt=ut,ut=bt.parentNode}bt=Jt}P=ye===-1||Se===-1?null:{start:ye,end:Se}}else P=null}P=P||{start:0,end:0}}else P=null;for(rL={focusedElem:C,selectionRange:P},U1=!1,nr=w;nr!==null;)if(w=nr,C=w.child,(w.subtreeFlags&1028)!==0&&C!==null)C.return=w,nr=C;else for(;nr!==null;){w=nr;try{var or=w.alternate;if((w.flags&1024)!==0)switch(w.tag){case 0:case 11:case 15:break;case 1:if(or!==null){var sr=or.memoizedProps,Ri=or.memoizedState,Le=w.stateNode,Me=Le.getSnapshotBeforeUpdate(w.elementType===w.type?sr:$l(w.type,sr),Ri);Le.__reactInternalSnapshotBeforeUpdate=Me}break;case 3:var Ge=w.stateNode.containerInfo;Ge.nodeType===1?Ge.textContent="":Ge.nodeType===9&&Ge.documentElement&&Ge.removeChild(Ge.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(r(163))}}catch(Rt){gi(w,w.return,Rt)}if(C=w.sibling,C!==null){C.return=w.return,nr=C;break}nr=w.return}return or=n9,n9=!1,or}function jb(C,w,P){var _=w.updateQueue;if(_=_!==null?_.lastEffect:null,_!==null){var G=_=_.next;do{if((G.tag&C)===C){var U=G.destroy;G.destroy=void 0,U!==void 0&&HL(w,P,U)}G=G.next}while(G!==_)}}function RE(C,w){if(w=w.updateQueue,w=w!==null?w.lastEffect:null,w!==null){var P=w=w.next;do{if((P.tag&C)===C){var _=P.create;P.destroy=_()}P=P.next}while(P!==w)}}function WL(C){var w=C.ref;if(w!==null){var P=C.stateNode;switch(C.tag){case 5:C=P;break;default:C=P}typeof w=="function"?w(C):w.current=C}}function i9(C){var w=C.alternate;w!==null&&(C.alternate=null,i9(w)),C.child=null,C.deletions=null,C.sibling=null,C.tag===5&&(w=C.stateNode,w!==null&&(delete w[Ac],delete w[Ob],delete w[sL],delete w[XEe],delete w[YEe])),C.stateNode=null,C.return=null,C.dependencies=null,C.memoizedProps=null,C.memoizedState=null,C.pendingProps=null,C.stateNode=null,C.updateQueue=null}function o9(C){return C.tag===5||C.tag===3||C.tag===4}function s9(C){e:for(;;){for(;C.sibling===null;){if(C.return===null||o9(C.return))return null;C=C.return}for(C.sibling.return=C.return,C=C.sibling;C.tag!==5&&C.tag!==6&&C.tag!==18;){if(C.flags&2||C.child===null||C.tag===4)continue e;C.child.return=C,C=C.child}if(!(C.flags&2))return C.stateNode}}function UL(C,w,P){var _=C.tag;if(_===5||_===6)C=C.stateNode,w?P.nodeType===8?P.parentNode.insertBefore(C,w):P.insertBefore(C,w):(P.nodeType===8?(w=P.parentNode,w.insertBefore(C,P)):(w=P,w.appendChild(C)),P=P._reactRootContainer,P!=null||w.onclick!==null||(w.onclick=nE));else if(_!==4&&(C=C.child,C!==null))for(UL(C,w,P),C=C.sibling;C!==null;)UL(C,w,P),C=C.sibling}function jL(C,w,P){var _=C.tag;if(_===5||_===6)C=C.stateNode,w?P.insertBefore(C,w):P.appendChild(C);else if(_!==4&&(C=C.child,C!==null))for(jL(C,w,P),C=C.sibling;C!==null;)jL(C,w,P),C=C.sibling}var Do=null,Gl=!1;function ph(C,w,P){for(P=P.child;P!==null;)a9(C,w,P),P=P.sibling}function a9(C,w,P){if(ti&&typeof ti.onCommitFiberUnmount=="function")try{ti.onCommitFiberUnmount(sn,P)}catch{}switch(P.tag){case 5:Xo||ov(P,w);case 6:var _=Do,G=Gl;Do=null,ph(C,w,P),Do=_,Gl=G,Do!==null&&(Gl?(C=Do,P=P.stateNode,C.nodeType===8?C.parentNode.removeChild(P):C.removeChild(P)):Do.removeChild(P.stateNode));break;case 18:Do!==null&&(Gl?(C=Do,P=P.stateNode,C.nodeType===8?oL(C.parentNode,P):C.nodeType===1&&oL(C,P),Eb(C)):oL(Do,P.stateNode));break;case 4:_=Do,G=Gl,Do=P.stateNode.containerInfo,Gl=!0,ph(C,w,P),Do=_,Gl=G;break;case 0:case 11:case 14:case 15:if(!Xo&&(_=P.updateQueue,_!==null&&(_=_.lastEffect,_!==null))){G=_=_.next;do{var U=G,te=U.destroy;U=U.tag,te!==void 0&&((U&2)!==0||(U&4)!==0)&&HL(P,w,te),G=G.next}while(G!==_)}ph(C,w,P);break;case 1:if(!Xo&&(ov(P,w),_=P.stateNode,typeof _.componentWillUnmount=="function"))try{_.props=P.memoizedProps,_.state=P.memoizedState,_.componentWillUnmount()}catch(ye){gi(P,w,ye)}ph(C,w,P);break;case 21:ph(C,w,P);break;case 22:P.mode&1?(Xo=(_=Xo)||P.memoizedState!==null,ph(C,w,P),Xo=_):ph(C,w,P);break;default:ph(C,w,P)}}function l9(C){var w=C.updateQueue;if(w!==null){C.updateQueue=null;var P=C.stateNode;P===null&&(P=C.stateNode=new hTe),w.forEach(function(_){var G=wTe.bind(null,C,_);P.has(_)||(P.add(_),_.then(G,G))})}}function Vl(C,w){var P=w.deletions;if(P!==null)for(var _=0;_G&&(G=te),_&=~U}if(_=G,_=rr()-_,_=(120>_?120:480>_?480:1080>_?1080:1920>_?1920:3e3>_?3e3:4320>_?4320:1960*gTe(_/1960))-_,10<_){C.timeoutHandle=iL(mf.bind(null,C,Gs,Wu),_);break}mf(C,Gs,Wu);break;case 5:mf(C,Gs,Wu);break;default:throw Error(r(329))}}}return Vs(C,rr()),C.callbackNode===P?f9.bind(null,C):null}function QL(C,w){var P=qb;return C.current.memoizedState.isDehydrated&&(gf(C,w).flags|=256),C=_E(C,w),C!==2&&(w=Gs,Gs=P,w!==null&&JL(w)),C}function JL(C){Gs===null?Gs=C:Gs.push.apply(Gs,C)}function mTe(C){for(var w=C;;){if(w.flags&16384){var P=w.updateQueue;if(P!==null&&(P=P.stores,P!==null))for(var _=0;_C?16:C,gh===null)var _=!1;else{if(C=gh,gh=null,AE=0,(mn&6)!==0)throw Error(r(331));var G=mn;for(mn|=4,nr=C.current;nr!==null;){var U=nr,te=U.child;if((nr.flags&16)!==0){var ye=U.deletions;if(ye!==null){for(var Se=0;Serr()-XL?gf(C,0):qL|=P),Vs(C,w)}function S9(C,w){w===0&&((C.mode&1)===0?w=1:(w=Ha,Ha<<=1,(Ha&130023424)===0&&(Ha=4194304)));var P=vs();C=Vu(C,w),C!==null&&(ga(C,w,P),Vs(C,P))}function STe(C){var w=C.memoizedState,P=0;w!==null&&(P=w.retryLane),S9(C,P)}function wTe(C,w){var P=0;switch(C.tag){case 13:var _=C.stateNode,G=C.memoizedState;G!==null&&(P=G.retryLane);break;case 19:_=C.stateNode;break;default:throw Error(r(314))}_!==null&&_.delete(w),S9(C,P)}var w9;w9=function(C,w,P){if(C!==null)if(C.memoizedProps!==w.pendingProps||Ns.current)$s=!0;else{if((C.lanes&P)===0&&(w.flags&128)===0)return $s=!1,cTe(C,w,P);$s=(C.flags&131072)!==0}else $s=!1,ni&&(w.flags&1048576)!==0&&t7(w,cE,w.index);switch(w.lanes=0,w.tag){case 2:var _=w.type;EE(C,w),C=w.pendingProps;var G=Ym(w,jo.current);rv(w,P),G=RL(null,w,_,C,G,P);var U=PL();return w.flags|=1,typeof G=="object"&&G!==null&&typeof G.render=="function"&&G.$$typeof===void 0?(w.tag=1,w.memoizedState=null,w.updateQueue=null,Bs(_)?(U=!0,sE(w)):U=!1,w.memoizedState=G.state!==null&&G.state!==void 0?G.state:null,CL(w),G.updater=wE,w.stateNode=G,G._reactInternals=w,LL(w,_,C,P),w=NL(null,w,_,!0,U,P)):(w.tag=0,ni&&U&&cL(w),ms(null,w,G,P),w=w.child),w;case 16:_=w.elementType;e:{switch(EE(C,w),C=w.pendingProps,G=_._init,_=G(_._payload),w.type=_,G=w.tag=ETe(_),C=$l(_,C),G){case 0:w=kL(null,w,_,C,P);break e;case 1:w=q7(null,w,_,C,P);break e;case 11:w=H7(null,w,_,C,P);break e;case 14:w=W7(null,w,_,$l(_.type,C),P);break e}throw Error(r(306,_,""))}return w;case 0:return _=w.type,G=w.pendingProps,G=w.elementType===_?G:$l(_,G),kL(C,w,_,G,P);case 1:return _=w.type,G=w.pendingProps,G=w.elementType===_?G:$l(_,G),q7(C,w,_,G,P);case 3:e:{if(X7(w),C===null)throw Error(r(387));_=w.pendingProps,U=w.memoizedState,G=U.element,u7(C,w),gE(w,_,null,P);var te=w.memoizedState;if(_=te.element,U.isDehydrated)if(U={element:_,isDehydrated:!1,cache:te.cache,pendingSuspenseBoundaries:te.pendingSuspenseBoundaries,transitions:te.transitions},w.updateQueue.baseState=U,w.memoizedState=U,w.flags&256){G=iv(Error(r(423)),w),w=Y7(C,w,_,P,G);break e}else if(_!==G){G=iv(Error(r(424)),w),w=Y7(C,w,_,P,G);break e}else for(ya=ah(w.stateNode.containerInfo.firstChild),va=w,ni=!0,Bl=null,P=l7(w,null,_,P),w.child=P;P;)P.flags=P.flags&-3|4096,P=P.sibling;else{if(Jm(),_===G){w=Hu(C,w,P);break e}ms(C,w,_,P)}w=w.child}return w;case 5:return p7(w),C===null&&hL(w),_=w.type,G=w.pendingProps,U=C!==null?C.memoizedProps:null,te=G.children,nL(_,G)?te=null:U!==null&&nL(_,U)&&(w.flags|=32),K7(C,w),ms(C,w,te,P),w.child;case 6:return C===null&&hL(w),null;case 13:return Z7(C,w,P);case 4:return bL(w,w.stateNode.containerInfo),_=w.pendingProps,C===null?w.child=ev(w,null,_,P):ms(C,w,_,P),w.child;case 11:return _=w.type,G=w.pendingProps,G=w.elementType===_?G:$l(_,G),H7(C,w,_,G,P);case 7:return ms(C,w,w.pendingProps,P),w.child;case 8:return ms(C,w,w.pendingProps.children,P),w.child;case 12:return ms(C,w,w.pendingProps.children,P),w.child;case 10:e:{if(_=w.type._context,G=w.pendingProps,U=w.memoizedProps,te=G.value,Hn(hE,_._currentValue),_._currentValue=te,U!==null)if(Nl(U.value,te)){if(U.children===G.children&&!Ns.current){w=Hu(C,w,P);break e}}else for(U=w.child,U!==null&&(U.return=w);U!==null;){var ye=U.dependencies;if(ye!==null){te=U.child;for(var Se=ye.firstContext;Se!==null;){if(Se.context===_){if(U.tag===1){Se=zu(-1,P&-P),Se.tag=2;var He=U.updateQueue;if(He!==null){He=He.shared;var ft=He.pending;ft===null?Se.next=Se:(Se.next=ft.next,ft.next=Se),He.pending=Se}}U.lanes|=P,Se=U.alternate,Se!==null&&(Se.lanes|=P),vL(U.return,P,w),ye.lanes|=P;break}Se=Se.next}}else if(U.tag===10)te=U.type===w.type?null:U.child;else if(U.tag===18){if(te=U.return,te===null)throw Error(r(341));te.lanes|=P,ye=te.alternate,ye!==null&&(ye.lanes|=P),vL(te,P,w),te=U.sibling}else te=U.child;if(te!==null)te.return=U;else for(te=U;te!==null;){if(te===w){te=null;break}if(U=te.sibling,U!==null){U.return=te.return,te=U;break}te=te.return}U=te}ms(C,w,G.children,P),w=w.child}return w;case 9:return G=w.type,_=w.pendingProps.children,rv(w,P),G=ja(G),_=_(G),w.flags|=1,ms(C,w,_,P),w.child;case 14:return _=w.type,G=$l(_,w.pendingProps),G=$l(_.type,G),W7(C,w,_,G,P);case 15:return U7(C,w,w.type,w.pendingProps,P);case 17:return _=w.type,G=w.pendingProps,G=w.elementType===_?G:$l(_,G),EE(C,w),w.tag=1,Bs(_)?(C=!0,sE(w)):C=!1,rv(w,P),k7(w,_,G),LL(w,_,G,P),NL(null,w,_,!0,C,P);case 19:return J7(C,w,P);case 22:return j7(C,w,P)}throw Error(r(156,w.tag))};function x9(C,w){return Qt(C,w)}function xTe(C,w,P,_){this.tag=C,this.key=P,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=w,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=_,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Xa(C,w,P,_){return new xTe(C,w,P,_)}function n_(C){return C=C.prototype,!(!C||!C.isReactComponent)}function ETe(C){if(typeof C=="function")return n_(C)?1:0;if(C!=null){if(C=C.$$typeof,C===L)return 11;if(C===O)return 14}return 2}function yh(C,w){var P=C.alternate;return P===null?(P=Xa(C.tag,w,C.key,C.mode),P.elementType=C.elementType,P.type=C.type,P.stateNode=C.stateNode,P.alternate=C,C.alternate=P):(P.pendingProps=w,P.type=C.type,P.flags=0,P.subtreeFlags=0,P.deletions=null),P.flags=C.flags&14680064,P.childLanes=C.childLanes,P.lanes=C.lanes,P.child=C.child,P.memoizedProps=C.memoizedProps,P.memoizedState=C.memoizedState,P.updateQueue=C.updateQueue,w=C.dependencies,P.dependencies=w===null?null:{lanes:w.lanes,firstContext:w.firstContext},P.sibling=C.sibling,P.index=C.index,P.ref=C.ref,P}function OE(C,w,P,_,G,U){var te=2;if(_=C,typeof C=="function")n_(C)&&(te=1);else if(typeof C=="string")te=5;else e:switch(C){case T:return vf(P.children,G,U,w);case M:te=8,G|=8;break;case D:return C=Xa(12,P,w,G|2),C.elementType=D,C.lanes=U,C;case F:return C=Xa(13,P,w,G),C.elementType=F,C.lanes=U,C;case k:return C=Xa(19,P,w,G),C.elementType=k,C.lanes=U,C;case H:return kE(P,G,U,w);default:if(typeof C=="object"&&C!==null)switch(C.$$typeof){case A:te=10;break e;case I:te=9;break e;case L:te=11;break e;case O:te=14;break e;case B:te=16,_=null;break e}throw Error(r(130,C==null?C:typeof C,""))}return w=Xa(te,P,w,G),w.elementType=C,w.type=_,w.lanes=U,w}function vf(C,w,P,_){return C=Xa(7,C,_,w),C.lanes=P,C}function kE(C,w,P,_){return C=Xa(22,C,_,w),C.elementType=H,C.lanes=P,C.stateNode={isHidden:!1},C}function i_(C,w,P){return C=Xa(6,C,null,w),C.lanes=P,C}function o_(C,w,P){return w=Xa(4,C.children!==null?C.children:[],C.key,w),w.lanes=P,w.stateNode={containerInfo:C.containerInfo,pendingChildren:null,implementation:C.implementation},w}function TTe(C,w,P,_,G){this.tag=w,this.containerInfo=C,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Dc(0),this.expirationTimes=Dc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Dc(0),this.identifierPrefix=_,this.onRecoverableError=G,this.mutableSourceEagerHydrationData=null}function s_(C,w,P,_,G,U,te,ye,Se){return C=new TTe(C,w,P,ye,Se),w===1?(w=1,U===!0&&(w|=8)):w=0,U=Xa(3,null,null,w),C.current=U,U.stateNode=C,U.memoizedState={element:_,isDehydrated:P,cache:null,transitions:null,pendingSuspenseBoundaries:null},CL(U),C}function RTe(C,w,P){var _=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),h_.exports=$Te(),h_.exports}var N9;function GTe(){if(N9)return HE;N9=1;var e=rse();return HE.createRoot=e.createRoot,HE.hydrateRoot=e.hydrateRoot,HE}var nse=GTe();const sBt=Sx(nse);var $a=rse();const ise=Sx($a),VTe=ese({__proto__:null,default:ise},[$a]);/** * @remix-run/router v1.23.0 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function ii(){return ii=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function ky(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function HTe(){return Math.random().toString(36).substr(2,8)}function $9(e,t){return{usr:e.state,key:e.key,idx:t}}function f0(e,t,r,n){return r===void 0&&(r=null),ii({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Vp(t):t,{state:r,key:t&&t.key||n||HTe()})}function Qg(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Vp(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function WTe(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:o=!1}=n,s=i.history,a=Vi.Pop,l=null,c=u();c==null&&(c=0,s.replaceState(ii({},s.state,{idx:c}),""));function u(){return(s.state||{idx:null}).idx}function d(){a=Vi.Pop;let m=u(),v=m==null?null:m-c;c=m,l&&l({action:a,location:g.location,delta:v})}function h(m,v){a=Vi.Push;let b=f0(g.location,m,v);c=u()+1;let S=$9(b,c),x=g.createHref(b);try{s.pushState(S,"",x)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;i.location.assign(x)}o&&l&&l({action:a,location:g.location,delta:1})}function p(m,v){a=Vi.Replace;let b=f0(g.location,m,v);c=u();let S=$9(b,c),x=g.createHref(b);s.replaceState(S,"",x),o&&l&&l({action:a,location:g.location,delta:0})}function f(m){let v=i.location.origin!=="null"?i.location.origin:i.location.href,b=typeof m=="string"?m:Qg(m);return b=b.replace(/ $/,"%20"),ln(v,"No window.location.(origin|href) available to create URL for href: "+b),new URL(b,v)}let g={get action(){return a},get location(){return e(i,s)},listen(m){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(B9,d),l=m,()=>{i.removeEventListener(B9,d),l=null}},createHref(m){return t(i,m)},createURL:f,encodeLocation(m){let v=f(m);return{pathname:v.pathname,search:v.search,hash:v.hash}},push:h,replace:p,go(m){return s.go(m)}};return g}var Fn;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Fn||(Fn={}));const UTe=new Set(["lazy","caseSensitive","path","id","index","children"]);function jTe(e){return e.index===!0}function tM(e,t,r,n){return r===void 0&&(r=[]),n===void 0&&(n={}),e.map((i,o)=>{let s=[...r,String(o)],a=typeof i.id=="string"?i.id:s.join("-");if(ln(i.index!==!0||!i.children,"Cannot specify children on an index route"),ln(!n[a],'Found a route id collision on id "'+a+`". Route id's must be globally unique within Data Router usages`),jTe(i)){let l=ii({},i,t(i),{id:a});return n[a]=l,l}else{let l=ii({},i,t(i),{id:a,children:void 0});return n[a]=l,i.children&&(l.children=tM(i.children,t,s,n)),l}})}function ng(e,t,r){return r===void 0&&(r="/"),eP(e,t,r,!1)}function eP(e,t,r,n){let i=typeof t=="string"?Vp(t):t,o=EC(i.pathname||"/",r);if(o==null)return null;let s=ose(e);qTe(s);let a=null;for(let l=0;a==null&&l{let l={relativePath:a===void 0?o.path||"":a,caseSensitive:o.caseSensitive===!0,childrenIndex:s,route:o};l.relativePath.startsWith("/")&&(ln(l.relativePath.startsWith(n),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(n.length));let c=yd([n,l.relativePath]),u=r.concat(l);o.children&&o.children.length>0&&(ln(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),ose(o.children,t,u,c)),!(o.path==null&&!o.index)&&t.push({path:c,score:tRe(c,o.index),routesMeta:u})};return e.forEach((o,s)=>{var a;if(o.path===""||!((a=o.path)!=null&&a.includes("?")))i(o,s);else for(let l of sse(o.path))i(o,s,l)}),t}function sse(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),o=r.replace(/\?$/,"");if(n.length===0)return i?[o,""]:[o];let s=sse(n.join("/")),a=[];return a.push(...s.map(l=>l===""?o:[o,l].join("/"))),i&&a.push(...s),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function qTe(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:rRe(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const XTe=/^:[\w-]+$/,YTe=3,ZTe=2,QTe=1,JTe=10,eRe=-2,G9=e=>e==="*";function tRe(e,t){let r=e.split("/"),n=r.length;return r.some(G9)&&(n+=eRe),t&&(n+=ZTe),r.filter(i=>!G9(i)).reduce((i,o)=>i+(XTe.test(o)?YTe:o===""?QTe:JTe),n)}function rRe(e,t){return e.length===t.length&&e.slice(0,-1).every((n,i)=>n===t[i])?e[e.length-1]-t[t.length-1]:0}function nRe(e,t,r){r===void 0&&(r=!1);let{routesMeta:n}=e,i={},o="/",s=[];for(let a=0;a{let{paramName:h,isOptional:p}=u;if(h==="*"){let g=a[d]||"";s=o.slice(0,o.length-g.length).replace(/(.)\/+$/,"$1")}const f=a[d];return p&&!f?c[h]=void 0:c[h]=(f||"").replace(/%2F/g,"/"),c},{}),pathname:o,pathnameBase:s,pattern:e}}function iRe(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),ky(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,a,l)=>(n.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function oRe(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return ky(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function EC(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function sRe(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?Vp(e):e;return{pathname:r?r.startsWith("/")?r:aRe(r,t):t,search:cRe(n),hash:uRe(i)}}function aRe(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function g_(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function ase(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function TD(e,t){let r=ase(e);return t?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function RD(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Vp(e):(i=ii({},e),ln(!i.pathname||!i.pathname.includes("?"),g_("?","pathname","search",i)),ln(!i.pathname||!i.pathname.includes("#"),g_("#","pathname","hash",i)),ln(!i.search||!i.search.includes("#"),g_("#","search","hash",i)));let o=e===""||i.pathname==="",s=o?"/":i.pathname,a;if(s==null)a=r;else{let d=t.length-1;if(!n&&s.startsWith("..")){let h=s.split("/");for(;h[0]==="..";)h.shift(),d-=1;i.pathname=h.join("/")}a=d>=0?t[d]:"/"}let l=sRe(i,a),c=s&&s!=="/"&&s.endsWith("/"),u=(o||s===".")&&r.endsWith("/");return!l.pathname.endsWith("/")&&(c||u)&&(l.pathname+="/"),l}const yd=e=>e.join("/").replace(/\/\/+/g,"/"),lRe=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),cRe=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,uRe=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;class rM{constructor(t,r,n,i){i===void 0&&(i=!1),this.status=t,this.statusText=r||"",this.internal=i,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}}function g0(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const lse=["post","put","patch","delete"],dRe=new Set(lse),hRe=["get",...lse],pRe=new Set(hRe),fRe=new Set([301,302,303,307,308]),gRe=new Set([307,308]),m_={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},mRe={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Qb={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},c3=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,vRe=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),cse="remix-router-transitions";function yRe(e){const t=e.window?e.window:typeof window<"u"?window:void 0,r=typeof t<"u"&&typeof t.document<"u"&&typeof t.document.createElement<"u",n=!r;ln(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let i;if(e.mapRouteProperties)i=e.mapRouteProperties;else if(e.detectErrorBoundary){let se=e.detectErrorBoundary;i=ce=>({hasErrorBoundary:se(ce)})}else i=vRe;let o={},s=tM(e.routes,i,void 0,o),a,l=e.basename||"/",c=e.dataStrategy||wRe,u=e.patchRoutesOnNavigation,d=ii({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),h=null,p=new Set,f=null,g=null,m=null,v=e.hydrationData!=null,b=ng(s,e.history.location,l),S=!1,x=null;if(b==null&&!u){let se=qs(404,{pathname:e.history.location.pathname}),{matches:ce,route:fe}=Q9(s);b=ce,x={[fe.id]:se}}b&&!e.hydrationData&&Re(b,s,e.history.location.pathname).active&&(b=null);let E;if(b)if(b.some(se=>se.route.lazy))E=!1;else if(!b.some(se=>se.route.loader))E=!0;else if(d.v7_partialHydration){let se=e.hydrationData?e.hydrationData.loaderData:null,ce=e.hydrationData?e.hydrationData.errors:null;if(ce){let fe=b.findIndex(Te=>ce[Te.route.id]!==void 0);E=b.slice(0,fe+1).every(Te=>!X2(Te.route,se,ce))}else E=b.every(fe=>!X2(fe.route,se,ce))}else E=e.hydrationData!=null;else if(E=!1,b=[],d.v7_partialHydration){let se=Re(null,s,e.history.location.pathname);se.active&&se.matches&&(S=!0,b=se.matches)}let R,T={historyAction:e.history.action,location:e.history.location,matches:b,initialized:E,navigation:m_,restoreScrollPosition:e.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||x,fetchers:new Map,blockers:new Map},M=Vi.Pop,D=!1,A,I=!1,L=new Map,F=null,k=!1,O=!1,B=[],H=new Set,N=new Map,z=0,W=-1,V=new Map,$=new Set,K=new Map,q=new Map,X=new Set,Y=new Map,oe=new Map,ee;function ne(){if(h=e.history.listen(se=>{let{action:ce,location:fe,delta:Te}=se;if(ee){ee(),ee=void 0;return}ky(oe.size===0||Te!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let $e=Wt({currentLocation:T.location,nextLocation:fe,historyAction:ce});if($e&&Te!=null){let et=new Promise(Dt=>{ee=Dt});e.history.go(Te*-1),kt($e,{state:"blocked",location:fe,proceed(){kt($e,{state:"proceeding",proceed:void 0,reset:void 0,location:fe}),et.then(()=>e.history.go(Te))},reset(){let Dt=new Map(T.blockers);Dt.set($e,Qb),re({blockers:Dt})}});return}return ue(ce,fe)}),r){kRe(t,L);let se=()=>NRe(t,L);t.addEventListener("pagehide",se),F=()=>t.removeEventListener("pagehide",se)}return T.initialized||ue(Vi.Pop,T.location,{initialHydration:!0}),R}function le(){h&&h(),F&&F(),p.clear(),A&&A.abort(),T.fetchers.forEach((se,ce)=>Ne(ce)),T.blockers.forEach((se,ce)=>Tt(ce))}function he(se){return p.add(se),()=>p.delete(se)}function re(se,ce){ce===void 0&&(ce={}),T=ii({},T,se);let fe=[],Te=[];d.v7_fetcherPersist&&T.fetchers.forEach(($e,et)=>{$e.state==="idle"&&(X.has(et)?Te.push(et):fe.push(et))}),X.forEach($e=>{!T.fetchers.has($e)&&!N.has($e)&&Te.push($e)}),[...p].forEach($e=>$e(T,{deletedFetchers:Te,viewTransitionOpts:ce.viewTransitionOpts,flushSync:ce.flushSync===!0})),d.v7_fetcherPersist?(fe.forEach($e=>T.fetchers.delete($e)),Te.forEach($e=>Ne($e))):Te.forEach($e=>X.delete($e))}function ie(se,ce,fe){var Te,$e;let{flushSync:et}=fe===void 0?{}:fe,Dt=T.actionData!=null&&T.navigation.formMethod!=null&&Yl(T.navigation.formMethod)&&T.navigation.state==="loading"&&((Te=se.state)==null?void 0:Te._isRedirect)!==!0,ct;ce.actionData?Object.keys(ce.actionData).length>0?ct=ce.actionData:ct=null:Dt?ct=T.actionData:ct=null;let st=ce.loaderData?Y9(T.loaderData,ce.loaderData,ce.matches||[],ce.errors):T.loaderData,wt=T.blockers;wt.size>0&&(wt=new Map(wt),wt.forEach((At,pt)=>wt.set(pt,Qb)));let Mt=D===!0||T.navigation.formMethod!=null&&Yl(T.navigation.formMethod)&&(($e=se.state)==null?void 0:$e._isRedirect)!==!0;a&&(s=a,a=void 0),k||M===Vi.Pop||(M===Vi.Push?e.history.push(se,se.state):M===Vi.Replace&&e.history.replace(se,se.state));let _t;if(M===Vi.Pop){let At=L.get(T.location.pathname);At&&At.has(se.pathname)?_t={currentLocation:T.location,nextLocation:se}:L.has(se.pathname)&&(_t={currentLocation:se,nextLocation:T.location})}else if(I){let At=L.get(T.location.pathname);At?At.add(se.pathname):(At=new Set([se.pathname]),L.set(T.location.pathname,At)),_t={currentLocation:T.location,nextLocation:se}}re(ii({},ce,{actionData:ct,loaderData:st,historyAction:M,location:se,initialized:!0,navigation:m_,revalidation:"idle",restoreScrollPosition:qe(se,ce.matches||T.matches),preventScrollReset:Mt,blockers:wt}),{viewTransitionOpts:_t,flushSync:et===!0}),M=Vi.Pop,D=!1,I=!1,k=!1,O=!1,B=[]}async function de(se,ce){if(typeof se=="number"){e.history.go(se);return}let fe=q2(T.location,T.matches,l,d.v7_prependBasename,se,d.v7_relativeSplatPath,ce==null?void 0:ce.fromRouteId,ce==null?void 0:ce.relative),{path:Te,submission:$e,error:et}=z9(d.v7_normalizeFormMethod,!1,fe,ce),Dt=T.location,ct=f0(T.location,Te,ce&&ce.state);ct=ii({},ct,e.history.encodeLocation(ct));let st=ce&&ce.replace!=null?ce.replace:void 0,wt=Vi.Push;st===!0?wt=Vi.Replace:st===!1||$e!=null&&Yl($e.formMethod)&&$e.formAction===T.location.pathname+T.location.search&&(wt=Vi.Replace);let Mt=ce&&"preventScrollReset"in ce?ce.preventScrollReset===!0:void 0,_t=(ce&&ce.flushSync)===!0,At=Wt({currentLocation:Dt,nextLocation:ct,historyAction:wt});if(At){kt(At,{state:"blocked",location:ct,proceed(){kt(At,{state:"proceeding",proceed:void 0,reset:void 0,location:ct}),de(se,ce)},reset(){let pt=new Map(T.blockers);pt.set(At,Qb),re({blockers:pt})}});return}return await ue(wt,ct,{submission:$e,pendingError:et,preventScrollReset:Mt,replace:ce&&ce.replace,enableViewTransition:ce&&ce.viewTransition,flushSync:_t})}function J(){if(St(),re({revalidation:"loading"}),T.navigation.state!=="submitting"){if(T.navigation.state==="idle"){ue(T.historyAction,T.location,{startUninterruptedRevalidation:!0});return}ue(M||T.historyAction,T.navigation.location,{overrideNavigation:T.navigation,enableViewTransition:I===!0})}}async function ue(se,ce,fe){A&&A.abort(),A=null,M=se,k=(fe&&fe.startUninterruptedRevalidation)===!0,_e(T.location,T.matches),D=(fe&&fe.preventScrollReset)===!0,I=(fe&&fe.enableViewTransition)===!0;let Te=a||s,$e=fe&&fe.overrideNavigation,et=fe!=null&&fe.initialHydration&&T.matches&&T.matches.length>0&&!S?T.matches:ng(Te,ce,l),Dt=(fe&&fe.flushSync)===!0;if(et&&T.initialized&&!O&&MRe(T.location,ce)&&!(fe&&fe.submission&&Yl(fe.submission.formMethod))){ie(ce,{matches:et},{flushSync:Dt});return}let ct=Re(et,Te,ce.pathname);if(ct.active&&ct.matches&&(et=ct.matches),!et){let{error:yt,notFoundMatches:It,route:Qt}=at(ce.pathname);ie(ce,{matches:It,loaderData:{},errors:{[Qt.id]:yt}},{flushSync:Dt});return}A=new AbortController;let st=cv(e.history,ce,A.signal,fe&&fe.submission),wt;if(fe&&fe.pendingError)wt=[ig(et).route.id,{type:Fn.error,error:fe.pendingError}];else if(fe&&fe.submission&&Yl(fe.submission.formMethod)){let yt=await ve(st,ce,fe.submission,et,ct.active,{replace:fe.replace,flushSync:Dt});if(yt.shortCircuited)return;if(yt.pendingActionResult){let[It,Qt]=yt.pendingActionResult;if(Pa(Qt)&&g0(Qt.error)&&Qt.error.status===404){A=null,ie(ce,{matches:yt.matches,loaderData:{},errors:{[It]:Qt.error}});return}}et=yt.matches||et,wt=yt.pendingActionResult,$e=v_(ce,fe.submission),Dt=!1,ct.active=!1,st=cv(e.history,st.url,st.signal)}let{shortCircuited:Mt,matches:_t,loaderData:At,errors:pt}=await pe(st,ce,et,ct.active,$e,fe&&fe.submission,fe&&fe.fetcherSubmission,fe&&fe.replace,fe&&fe.initialHydration===!0,Dt,wt);Mt||(A=null,ie(ce,ii({matches:_t||et},Z9(wt),{loaderData:At,errors:pt})))}async function ve(se,ce,fe,Te,$e,et){et===void 0&&(et={}),St();let Dt=_Re(ce,fe);if(re({navigation:Dt},{flushSync:et.flushSync===!0}),$e){let wt=await it(Te,ce.pathname,se.signal);if(wt.type==="aborted")return{shortCircuited:!0};if(wt.type==="error"){let Mt=ig(wt.partialMatches).route.id;return{matches:wt.partialMatches,pendingActionResult:[Mt,{type:Fn.error,error:wt.error}]}}else if(wt.matches)Te=wt.matches;else{let{notFoundMatches:Mt,error:_t,route:At}=at(ce.pathname);return{matches:Mt,pendingActionResult:[At.id,{type:Fn.error,error:_t}]}}}let ct,st=JS(Te,ce);if(!st.route.action&&!st.route.lazy)ct={type:Fn.error,error:qs(405,{method:se.method,pathname:ce.pathname,routeId:st.route.id})};else if(ct=(await mt("action",T,se,[st],Te,null))[st.route.id],se.signal.aborted)return{shortCircuited:!0};if(gg(ct)){let wt;return et&&et.replace!=null?wt=et.replace:wt=K9(ct.response.headers.get("Location"),new URL(se.url),l)===T.location.pathname+T.location.search,await ze(se,ct,!0,{submission:fe,replace:wt}),{shortCircuited:!0}}if(Jh(ct))throw qs(400,{type:"defer-action"});if(Pa(ct)){let wt=ig(Te,st.route.id);return(et&&et.replace)!==!0&&(M=Vi.Push),{matches:Te,pendingActionResult:[wt.route.id,ct]}}return{matches:Te,pendingActionResult:[st.route.id,ct]}}async function pe(se,ce,fe,Te,$e,et,Dt,ct,st,wt,Mt){let _t=$e||v_(ce,et),At=et||Dt||ej(_t),pt=!k&&(!d.v7_partialHydration||!st);if(Te){if(pt){let sn=me(Mt);re(ii({navigation:_t},sn!==void 0?{actionData:sn}:{}),{flushSync:wt})}let Dr=await it(fe,ce.pathname,se.signal);if(Dr.type==="aborted")return{shortCircuited:!0};if(Dr.type==="error"){let sn=ig(Dr.partialMatches).route.id;return{matches:Dr.partialMatches,loaderData:{},errors:{[sn]:Dr.error}}}else if(Dr.matches)fe=Dr.matches;else{let{error:sn,notFoundMatches:ti,route:mr}=at(ce.pathname);return{matches:ti,loaderData:{},errors:{[mr.id]:sn}}}}let yt=a||s,[It,Qt]=W9(e.history,T,fe,At,ce,d.v7_partialHydration&&st===!0,d.v7_skipActionErrorRevalidation,O,B,H,X,K,$,yt,l,Mt);if(lt(Dr=>!(fe&&fe.some(sn=>sn.route.id===Dr))||It&&It.some(sn=>sn.route.id===Dr)),W=++z,It.length===0&&Qt.length===0){let Dr=Ae();return ie(ce,ii({matches:fe,loaderData:{},errors:Mt&&Pa(Mt[1])?{[Mt[0]]:Mt[1].error}:null},Z9(Mt),Dr?{fetchers:new Map(T.fetchers)}:{}),{flushSync:wt}),{shortCircuited:!0}}if(pt){let Dr={};if(!Te){Dr.navigation=_t;let sn=me(Mt);sn!==void 0&&(Dr.actionData=sn)}Qt.length>0&&(Dr.fetchers=ke(Qt)),re(Dr,{flushSync:wt})}Qt.forEach(Dr=>{ot(Dr.key),Dr.controller&&N.set(Dr.key,Dr.controller)});let Ft=()=>Qt.forEach(Dr=>ot(Dr.key));A&&A.signal.addEventListener("abort",Ft);let{loaderResults:ur,fetcherResults:fr}=await Nt(T,fe,It,Qt,se);if(se.signal.aborted)return{shortCircuited:!0};A&&A.signal.removeEventListener("abort",Ft),Qt.forEach(Dr=>N.delete(Dr.key));let rr=WE(ur);if(rr)return await ze(se,rr.result,!0,{replace:ct}),{shortCircuited:!0};if(rr=WE(fr),rr)return $.add(rr.key),await ze(se,rr.result,!0,{replace:ct}),{shortCircuited:!0};let{loaderData:yn,errors:dn}=X9(T,fe,ur,Mt,Qt,fr,Y);Y.forEach((Dr,sn)=>{Dr.subscribe(ti=>{(ti||Dr.done)&&Y.delete(sn)})}),d.v7_partialHydration&&st&&T.errors&&(dn=ii({},T.errors,dn));let hn=Ae(),en=nt(W),fo=hn||en||Qt.length>0;return ii({matches:fe,loaderData:yn,errors:dn},fo?{fetchers:new Map(T.fetchers)}:{})}function me(se){if(se&&!Pa(se[1]))return{[se[0]]:se[1].data};if(T.actionData)return Object.keys(T.actionData).length===0?null:T.actionData}function ke(se){return se.forEach(ce=>{let fe=T.fetchers.get(ce.key),Te=Jb(void 0,fe?fe.data:void 0);T.fetchers.set(ce.key,Te)}),new Map(T.fetchers)}function De(se,ce,fe,Te){if(n)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");ot(se);let $e=(Te&&Te.flushSync)===!0,et=a||s,Dt=q2(T.location,T.matches,l,d.v7_prependBasename,fe,d.v7_relativeSplatPath,ce,Te==null?void 0:Te.relative),ct=ng(et,Dt,l),st=Re(ct,et,Dt);if(st.active&&st.matches&&(ct=st.matches),!ct){Fe(se,ce,qs(404,{pathname:Dt}),{flushSync:$e});return}let{path:wt,submission:Mt,error:_t}=z9(d.v7_normalizeFormMethod,!0,Dt,Te);if(_t){Fe(se,ce,_t,{flushSync:$e});return}let At=JS(ct,wt),pt=(Te&&Te.preventScrollReset)===!0;if(Mt&&Yl(Mt.formMethod)){Ee(se,ce,wt,At,ct,st.active,$e,pt,Mt);return}K.set(se,{routeId:ce,path:wt}),We(se,ce,wt,At,ct,st.active,$e,pt,Mt)}async function Ee(se,ce,fe,Te,$e,et,Dt,ct,st){St(),K.delete(se);function wt(Ct){if(!Ct.route.action&&!Ct.route.lazy){let vr=qs(405,{method:st.formMethod,pathname:fe,routeId:ce});return Fe(se,ce,vr,{flushSync:Dt}),!0}return!1}if(!et&&wt(Te))return;let Mt=T.fetchers.get(se);Ze(se,ORe(st,Mt),{flushSync:Dt});let _t=new AbortController,At=cv(e.history,fe,_t.signal,st);if(et){let Ct=await it($e,new URL(At.url).pathname,At.signal,se);if(Ct.type==="aborted")return;if(Ct.type==="error"){Fe(se,ce,Ct.error,{flushSync:Dt});return}else if(Ct.matches){if($e=Ct.matches,Te=JS($e,fe),wt(Te))return}else{Fe(se,ce,qs(404,{pathname:fe}),{flushSync:Dt});return}}N.set(se,_t);let pt=z,It=(await mt("action",T,At,[Te],$e,se))[Te.route.id];if(At.signal.aborted){N.get(se)===_t&&N.delete(se);return}if(d.v7_fetcherPersist&&X.has(se)){if(gg(It)||Pa(It)){Ze(se,Lh(void 0));return}}else{if(gg(It))if(N.delete(se),W>pt){Ze(se,Lh(void 0));return}else return $.add(se),Ze(se,Jb(st)),ze(At,It,!1,{fetcherSubmission:st,preventScrollReset:ct});if(Pa(It)){Fe(se,ce,It.error);return}}if(Jh(It))throw qs(400,{type:"defer-action"});let Qt=T.navigation.location||T.location,Ft=cv(e.history,Qt,_t.signal),ur=a||s,fr=T.navigation.state!=="idle"?ng(ur,T.navigation.location,l):T.matches;ln(fr,"Didn't find any matches after fetcher action");let rr=++z;V.set(se,rr);let yn=Jb(st,It.data);T.fetchers.set(se,yn);let[dn,hn]=W9(e.history,T,fr,st,Qt,!1,d.v7_skipActionErrorRevalidation,O,B,H,X,K,$,ur,l,[Te.route.id,It]);hn.filter(Ct=>Ct.key!==se).forEach(Ct=>{let vr=Ct.key,wn=T.fetchers.get(vr),ri=Jb(void 0,wn?wn.data:void 0);T.fetchers.set(vr,ri),ot(vr),Ct.controller&&N.set(vr,Ct.controller)}),re({fetchers:new Map(T.fetchers)});let en=()=>hn.forEach(Ct=>ot(Ct.key));_t.signal.addEventListener("abort",en);let{loaderResults:fo,fetcherResults:Dr}=await Nt(T,fr,dn,hn,Ft);if(_t.signal.aborted)return;_t.signal.removeEventListener("abort",en),V.delete(se),N.delete(se),hn.forEach(Ct=>N.delete(Ct.key));let sn=WE(fo);if(sn)return ze(Ft,sn.result,!1,{preventScrollReset:ct});if(sn=WE(Dr),sn)return $.add(sn.key),ze(Ft,sn.result,!1,{preventScrollReset:ct});let{loaderData:ti,errors:mr}=X9(T,fr,fo,void 0,hn,Dr,Y);if(T.fetchers.has(se)){let Ct=Lh(It.data);T.fetchers.set(se,Ct)}nt(rr),T.navigation.state==="loading"&&rr>W?(ln(M,"Expected pending action"),A&&A.abort(),ie(T.navigation.location,{matches:fr,loaderData:ti,errors:mr,fetchers:new Map(T.fetchers)})):(re({errors:mr,loaderData:Y9(T.loaderData,ti,fr,mr),fetchers:new Map(T.fetchers)}),O=!1)}async function We(se,ce,fe,Te,$e,et,Dt,ct,st){let wt=T.fetchers.get(se);Ze(se,Jb(st,wt?wt.data:void 0),{flushSync:Dt});let Mt=new AbortController,_t=cv(e.history,fe,Mt.signal);if(et){let It=await it($e,new URL(_t.url).pathname,_t.signal,se);if(It.type==="aborted")return;if(It.type==="error"){Fe(se,ce,It.error,{flushSync:Dt});return}else if(It.matches)$e=It.matches,Te=JS($e,fe);else{Fe(se,ce,qs(404,{pathname:fe}),{flushSync:Dt});return}}N.set(se,Mt);let At=z,yt=(await mt("loader",T,_t,[Te],$e,se))[Te.route.id];if(Jh(yt)&&(yt=await u3(yt,_t.signal,!0)||yt),N.get(se)===Mt&&N.delete(se),!_t.signal.aborted){if(X.has(se)){Ze(se,Lh(void 0));return}if(gg(yt))if(W>At){Ze(se,Lh(void 0));return}else{$.add(se),await ze(_t,yt,!1,{preventScrollReset:ct});return}if(Pa(yt)){Fe(se,ce,yt.error);return}ln(!Jh(yt),"Unhandled fetcher deferred data"),Ze(se,Lh(yt.data))}}async function ze(se,ce,fe,Te){let{submission:$e,fetcherSubmission:et,preventScrollReset:Dt,replace:ct}=Te===void 0?{}:Te;ce.response.headers.has("X-Remix-Revalidate")&&(O=!0);let st=ce.response.headers.get("Location");ln(st,"Expected a Location header on the redirect Response"),st=K9(st,new URL(se.url),l);let wt=f0(T.location,st,{_isRedirect:!0});if(r){let It=!1;if(ce.response.headers.has("X-Remix-Reload-Document"))It=!0;else if(c3.test(st)){const Qt=e.history.createURL(st);It=Qt.origin!==t.location.origin||EC(Qt.pathname,l)==null}if(It){ct?t.location.replace(st):t.location.assign(st);return}}A=null;let Mt=ct===!0||ce.response.headers.has("X-Remix-Replace")?Vi.Replace:Vi.Push,{formMethod:_t,formAction:At,formEncType:pt}=T.navigation;!$e&&!et&&_t&&At&&pt&&($e=ej(T.navigation));let yt=$e||et;if(gRe.has(ce.response.status)&&yt&&Yl(yt.formMethod))await ue(Mt,wt,{submission:ii({},yt,{formAction:st}),preventScrollReset:Dt||D,enableViewTransition:fe?I:void 0});else{let It=v_(wt,$e);await ue(Mt,wt,{overrideNavigation:It,fetcherSubmission:et,preventScrollReset:Dt||D,enableViewTransition:fe?I:void 0})}}async function mt(se,ce,fe,Te,$e,et){let Dt,ct={};try{Dt=await xRe(c,se,ce,fe,Te,$e,et,o,i)}catch(st){return Te.forEach(wt=>{ct[wt.route.id]={type:Fn.error,error:st}}),ct}for(let[st,wt]of Object.entries(Dt))if(IRe(wt)){let Mt=wt.result;ct[st]={type:Fn.redirect,response:RRe(Mt,fe,st,$e,l,d.v7_relativeSplatPath)}}else ct[st]=await TRe(wt);return ct}async function Nt(se,ce,fe,Te,$e){let et=se.matches,Dt=mt("loader",se,$e,fe,ce,null),ct=Promise.all(Te.map(async Mt=>{if(Mt.matches&&Mt.match&&Mt.controller){let At=(await mt("loader",se,cv(e.history,Mt.path,Mt.controller.signal),[Mt.match],Mt.matches,Mt.key))[Mt.match.route.id];return{[Mt.key]:At}}else return Promise.resolve({[Mt.key]:{type:Fn.error,error:qs(404,{pathname:Mt.path})}})})),st=await Dt,wt=(await ct).reduce((Mt,_t)=>Object.assign(Mt,_t),{});return await Promise.all([FRe(ce,st,$e.signal,et,se.loaderData),LRe(ce,wt,Te)]),{loaderResults:st,fetcherResults:wt}}function St(){O=!0,B.push(...lt()),K.forEach((se,ce)=>{N.has(ce)&&H.add(ce),ot(ce)})}function Ze(se,ce,fe){fe===void 0&&(fe={}),T.fetchers.set(se,ce),re({fetchers:new Map(T.fetchers)},{flushSync:(fe&&fe.flushSync)===!0})}function Fe(se,ce,fe,Te){Te===void 0&&(Te={});let $e=ig(T.matches,ce);Ne(se),re({errors:{[$e.route.id]:fe},fetchers:new Map(T.fetchers)},{flushSync:(Te&&Te.flushSync)===!0})}function tt(se){return q.set(se,(q.get(se)||0)+1),X.has(se)&&X.delete(se),T.fetchers.get(se)||mRe}function Ne(se){let ce=T.fetchers.get(se);N.has(se)&&!(ce&&ce.state==="loading"&&V.has(se))&&ot(se),K.delete(se),V.delete(se),$.delete(se),d.v7_fetcherPersist&&X.delete(se),H.delete(se),T.fetchers.delete(se)}function rt(se){let ce=(q.get(se)||0)-1;ce<=0?(q.delete(se),X.add(se),d.v7_fetcherPersist||Ne(se)):q.set(se,ce),re({fetchers:new Map(T.fetchers)})}function ot(se){let ce=N.get(se);ce&&(ce.abort(),N.delete(se))}function Ye(se){for(let ce of se){let fe=tt(ce),Te=Lh(fe.data);T.fetchers.set(ce,Te)}}function Ae(){let se=[],ce=!1;for(let fe of $){let Te=T.fetchers.get(fe);ln(Te,"Expected fetcher: "+fe),Te.state==="loading"&&($.delete(fe),se.push(fe),ce=!0)}return Ye(se),ce}function nt(se){let ce=[];for(let[fe,Te]of V)if(Te0}function Et(se,ce){let fe=T.blockers.get(se)||Qb;return oe.get(se)!==ce&&oe.set(se,ce),fe}function Tt(se){T.blockers.delete(se),oe.delete(se)}function kt(se,ce){let fe=T.blockers.get(se)||Qb;ln(fe.state==="unblocked"&&ce.state==="blocked"||fe.state==="blocked"&&ce.state==="blocked"||fe.state==="blocked"&&ce.state==="proceeding"||fe.state==="blocked"&&ce.state==="unblocked"||fe.state==="proceeding"&&ce.state==="unblocked","Invalid blocker state transition: "+fe.state+" -> "+ce.state);let Te=new Map(T.blockers);Te.set(se,ce),re({blockers:Te})}function Wt(se){let{currentLocation:ce,nextLocation:fe,historyAction:Te}=se;if(oe.size===0)return;oe.size>1&&ky(!1,"A router only supports one blocker at a time");let $e=Array.from(oe.entries()),[et,Dt]=$e[$e.length-1],ct=T.blockers.get(et);if(!(ct&&ct.state==="proceeding")&&Dt({currentLocation:ce,nextLocation:fe,historyAction:Te}))return et}function at(se){let ce=qs(404,{pathname:se}),fe=a||s,{matches:Te,route:$e}=Q9(fe);return lt(),{notFoundMatches:Te,route:$e,error:ce}}function lt(se){let ce=[];return Y.forEach((fe,Te)=>{(!se||se(Te))&&(fe.cancel(),ce.push(Te),Y.delete(Te))}),ce}function Ut(se,ce,fe){if(f=se,m=ce,g=fe||null,!v&&T.navigation===m_){v=!0;let Te=qe(T.location,T.matches);Te!=null&&re({restoreScrollPosition:Te})}return()=>{f=null,m=null,g=null}}function cr(se,ce){return g&&g(se,ce.map(Te=>KTe(Te,T.loaderData)))||se.key}function _e(se,ce){if(f&&m){let fe=cr(se,ce);f[fe]=m()}}function qe(se,ce){if(f){let fe=cr(se,ce),Te=f[fe];if(typeof Te=="number")return Te}return null}function Re(se,ce,fe){if(u)if(se){if(Object.keys(se[0].params).length>0)return{active:!0,matches:eP(ce,fe,l,!0)}}else return{active:!0,matches:eP(ce,fe,l,!0)||[]};return{active:!1,matches:null}}async function it(se,ce,fe,Te){if(!u)return{type:"success",matches:se};let $e=se;for(;;){let et=a==null,Dt=a||s,ct=o;try{await u({signal:fe,path:ce,matches:$e,fetcherKey:Te,patch:(Mt,_t)=>{fe.aborted||j9(Mt,_t,Dt,ct,i)}})}catch(Mt){return{type:"error",error:Mt,partialMatches:$e}}finally{et&&!fe.aborted&&(s=[...s])}if(fe.aborted)return{type:"aborted"};let st=ng(Dt,ce,l);if(st)return{type:"success",matches:st};let wt=eP(Dt,ce,l,!0);if(!wt||$e.length===wt.length&&$e.every((Mt,_t)=>Mt.route.id===wt[_t].route.id))return{type:"success",matches:null};$e=wt}}function Ve(se){o={},a=tM(se,i,void 0,o)}function Oe(se,ce){let fe=a==null;j9(se,ce,a||s,o,i),fe&&(s=[...s],re({}))}return R={get basename(){return l},get future(){return d},get state(){return T},get routes(){return s},get window(){return t},initialize:ne,subscribe:he,enableScrollRestoration:Ut,navigate:de,fetch:De,revalidate:J,createHref:se=>e.history.createHref(se),encodeLocation:se=>e.history.encodeLocation(se),getFetcher:tt,deleteFetcher:rt,dispose:le,getBlocker:Et,deleteBlocker:Tt,patchRoutes:Oe,_internalFetchControllers:N,_internalActiveDeferreds:Y,_internalSetRoutes:Ve},R}function CRe(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function q2(e,t,r,n,i,o,s,a){let l,c;if(s){l=[];for(let d of t)if(l.push(d),d.route.id===s){c=d;break}}else l=t,c=t[t.length-1];let u=RD(i||".",TD(l,o),EC(e.pathname,r)||e.pathname,a==="path");if(i==null&&(u.search=e.search,u.hash=e.hash),(i==null||i===""||i===".")&&c){let d=d3(u.search);if(c.route.index&&!d)u.search=u.search?u.search.replace(/^\?/,"?index&"):"?index";else if(!c.route.index&&d){let h=new URLSearchParams(u.search),p=h.getAll("index");h.delete("index"),p.filter(g=>g).forEach(g=>h.append("index",g));let f=h.toString();u.search=f?"?"+f:""}}return n&&r!=="/"&&(u.pathname=u.pathname==="/"?r:yd([r,u.pathname])),Qg(u)}function z9(e,t,r,n){if(!n||!CRe(n))return{path:r};if(n.formMethod&&!ARe(n.formMethod))return{path:r,error:qs(405,{method:n.formMethod})};let i=()=>({path:r,error:qs(400,{type:"invalid-body"})}),o=n.formMethod||"get",s=e?o.toUpperCase():o.toLowerCase(),a=hse(r);if(n.body!==void 0){if(n.formEncType==="text/plain"){if(!Yl(s))return i();let h=typeof n.body=="string"?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((p,f)=>{let[g,m]=f;return""+p+g+"="+m+` `},""):String(n.body);return{path:r,submission:{formMethod:s,formAction:a,formEncType:n.formEncType,formData:void 0,json:void 0,text:h}}}else if(n.formEncType==="application/json"){if(!Yl(s))return i();try{let h=typeof n.body=="string"?JSON.parse(n.body):n.body;return{path:r,submission:{formMethod:s,formAction:a,formEncType:n.formEncType,formData:void 0,json:h,text:void 0}}}catch{return i()}}}ln(typeof FormData=="function","FormData is not available in this environment");let l,c;if(n.formData)l=Y2(n.formData),c=n.formData;else if(n.body instanceof FormData)l=Y2(n.body),c=n.body;else if(n.body instanceof URLSearchParams)l=n.body,c=q9(l);else if(n.body==null)l=new URLSearchParams,c=new FormData;else try{l=new URLSearchParams(n.body),c=q9(l)}catch{return i()}let u={formMethod:s,formAction:a,formEncType:n&&n.formEncType||"application/x-www-form-urlencoded",formData:c,json:void 0,text:void 0};if(Yl(u.formMethod))return{path:r,submission:u};let d=Vp(r);return t&&d.search&&d3(d.search)&&l.append("index",""),d.search="?"+l,{path:Qg(d),submission:u}}function H9(e,t,r){r===void 0&&(r=!1);let n=e.findIndex(i=>i.route.id===t);return n>=0?e.slice(0,r?n+1:n):e}function W9(e,t,r,n,i,o,s,a,l,c,u,d,h,p,f,g){let m=g?Pa(g[1])?g[1].error:g[1].data:void 0,v=e.createURL(t.location),b=e.createURL(i),S=r;o&&t.errors?S=H9(r,Object.keys(t.errors)[0],!0):g&&Pa(g[1])&&(S=H9(r,g[0]));let x=g?g[1].statusCode:void 0,E=s&&x&&x>=400,R=S.filter((M,D)=>{let{route:A}=M;if(A.lazy)return!0;if(A.loader==null)return!1;if(o)return X2(A,t.loaderData,t.errors);if(bRe(t.loaderData,t.matches[D],M)||l.some(F=>F===M.route.id))return!0;let I=t.matches[D],L=M;return U9(M,ii({currentUrl:v,currentParams:I.params,nextUrl:b,nextParams:L.params},n,{actionResult:m,actionStatus:x,defaultShouldRevalidate:E?!1:a||v.pathname+v.search===b.pathname+b.search||v.search!==b.search||use(I,L)}))}),T=[];return d.forEach((M,D)=>{if(o||!r.some(k=>k.route.id===M.routeId)||u.has(D))return;let A=ng(p,M.path,f);if(!A){T.push({key:D,routeId:M.routeId,path:M.path,matches:null,match:null,controller:null});return}let I=t.fetchers.get(D),L=JS(A,M.path),F=!1;h.has(D)?F=!1:c.has(D)?(c.delete(D),F=!0):I&&I.state!=="idle"&&I.data===void 0?F=a:F=U9(L,ii({currentUrl:v,currentParams:t.matches[t.matches.length-1].params,nextUrl:b,nextParams:r[r.length-1].params},n,{actionResult:m,actionStatus:x,defaultShouldRevalidate:E?!1:a})),F&&T.push({key:D,routeId:M.routeId,path:M.path,matches:A,match:L,controller:new AbortController})}),[R,T]}function X2(e,t,r){if(e.lazy)return!0;if(!e.loader)return!1;let n=t!=null&&t[e.id]!==void 0,i=r!=null&&r[e.id]!==void 0;return!n&&i?!1:typeof e.loader=="function"&&e.loader.hydrate===!0?!0:!n&&!i}function bRe(e,t,r){let n=!t||r.route.id!==t.route.id,i=e[r.route.id]===void 0;return n||i}function use(e,t){let r=e.route.path;return e.pathname!==t.pathname||r!=null&&r.endsWith("*")&&e.params["*"]!==t.params["*"]}function U9(e,t){if(e.route.shouldRevalidate){let r=e.route.shouldRevalidate(t);if(typeof r=="boolean")return r}return t.defaultShouldRevalidate}function j9(e,t,r,n,i){var o;let s;if(e){let c=n[e];ln(c,"No route found to patch children into: routeId = "+e),c.children||(c.children=[]),s=c.children}else s=r;let a=t.filter(c=>!s.some(u=>dse(c,u))),l=tM(a,i,[e||"_","patch",String(((o=s)==null?void 0:o.length)||"0")],n);s.push(...l)}function dse(e,t){return"id"in e&&"id"in t&&e.id===t.id?!0:e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive?(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children.every((r,n)=>{var i;return(i=t.children)==null?void 0:i.some(o=>dse(r,o))}):!1}async function SRe(e,t,r){if(!e.lazy)return;let n=await e.lazy();if(!e.lazy)return;let i=r[e.id];ln(i,"No route found in manifest");let o={};for(let s in n){let l=i[s]!==void 0&&s!=="hasErrorBoundary";ky(!l,'Route "'+i.id+'" has a static property "'+s+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+s+'" will be ignored.')),!l&&!UTe.has(s)&&(o[s]=n[s])}Object.assign(i,o),Object.assign(i,ii({},t(i),{lazy:void 0}))}async function wRe(e){let{matches:t}=e,r=t.filter(i=>i.shouldLoad);return(await Promise.all(r.map(i=>i.resolve()))).reduce((i,o,s)=>Object.assign(i,{[r[s].route.id]:o}),{})}async function xRe(e,t,r,n,i,o,s,a,l,c){let u=o.map(p=>p.route.lazy?SRe(p.route,l,a):void 0),d=o.map((p,f)=>{let g=u[f],m=i.some(b=>b.route.id===p.route.id);return ii({},p,{shouldLoad:m,resolve:async b=>(b&&n.method==="GET"&&(p.route.lazy||p.route.loader)&&(m=!0),m?ERe(t,n,p,g,b,c):Promise.resolve({type:Fn.data,result:void 0}))})}),h=await e({matches:d,request:n,params:o[0].params,fetcherKey:s,context:c});try{await Promise.all(u)}catch{}return h}async function ERe(e,t,r,n,i,o){let s,a,l=c=>{let u,d=new Promise((f,g)=>u=g);a=()=>u(),t.signal.addEventListener("abort",a);let h=f=>typeof c!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+e+'" [routeId: '+r.route.id+"]"))):c({request:t,params:r.params,context:o},...f!==void 0?[f]:[]),p=(async()=>{try{return{type:"data",result:await(i?i(g=>h(g)):h())}}catch(f){return{type:"error",result:f}}})();return Promise.race([p,d])};try{let c=r.route[e];if(n)if(c){let u,[d]=await Promise.all([l(c).catch(h=>{u=h}),n]);if(u!==void 0)throw u;s=d}else if(await n,c=r.route[e],c)s=await l(c);else if(e==="action"){let u=new URL(t.url),d=u.pathname+u.search;throw qs(405,{method:t.method,pathname:d,routeId:r.route.id})}else return{type:Fn.data,result:void 0};else if(c)s=await l(c);else{let u=new URL(t.url),d=u.pathname+u.search;throw qs(404,{pathname:d})}ln(s.result!==void 0,"You defined "+(e==="action"?"an action":"a loader")+" for route "+('"'+r.route.id+"\" but didn't return anything from your `"+e+"` ")+"function. Please return a value or `null`.")}catch(c){return{type:Fn.error,result:c}}finally{a&&t.signal.removeEventListener("abort",a)}return s}async function TRe(e){let{result:t,type:r}=e;if(pse(t)){let d;try{let h=t.headers.get("Content-Type");h&&/\bapplication\/json\b/.test(h)?t.body==null?d=null:d=await t.json():d=await t.text()}catch(h){return{type:Fn.error,error:h}}return r===Fn.error?{type:Fn.error,error:new rM(t.status,t.statusText,d),statusCode:t.status,headers:t.headers}:{type:Fn.data,data:d,statusCode:t.status,headers:t.headers}}if(r===Fn.error){if(J9(t)){var n,i;if(t.data instanceof Error){var o,s;return{type:Fn.error,error:t.data,statusCode:(o=t.init)==null?void 0:o.status,headers:(s=t.init)!=null&&s.headers?new Headers(t.init.headers):void 0}}return{type:Fn.error,error:new rM(((n=t.init)==null?void 0:n.status)||500,void 0,t.data),statusCode:g0(t)?t.status:void 0,headers:(i=t.init)!=null&&i.headers?new Headers(t.init.headers):void 0}}return{type:Fn.error,error:t,statusCode:g0(t)?t.status:void 0}}if(DRe(t)){var a,l;return{type:Fn.deferred,deferredData:t,statusCode:(a=t.init)==null?void 0:a.status,headers:((l=t.init)==null?void 0:l.headers)&&new Headers(t.init.headers)}}if(J9(t)){var c,u;return{type:Fn.data,data:t.data,statusCode:(c=t.init)==null?void 0:c.status,headers:(u=t.init)!=null&&u.headers?new Headers(t.init.headers):void 0}}return{type:Fn.data,data:t}}function RRe(e,t,r,n,i,o){let s=e.headers.get("Location");if(ln(s,"Redirects returned/thrown from loaders/actions must have a Location header"),!c3.test(s)){let a=n.slice(0,n.findIndex(l=>l.route.id===r)+1);s=q2(new URL(t.url),a,i,!0,s,o),e.headers.set("Location",s)}return e}function K9(e,t,r){if(c3.test(e)){let n=e,i=n.startsWith("//")?new URL(t.protocol+n):new URL(n),o=EC(i.pathname,r)!=null;if(i.origin===t.origin&&o)return i.pathname+i.search+i.hash}return e}function cv(e,t,r,n){let i=e.createURL(hse(t)).toString(),o={signal:r};if(n&&Yl(n.formMethod)){let{formMethod:s,formEncType:a}=n;o.method=s.toUpperCase(),a==="application/json"?(o.headers=new Headers({"Content-Type":a}),o.body=JSON.stringify(n.json)):a==="text/plain"?o.body=n.text:a==="application/x-www-form-urlencoded"&&n.formData?o.body=Y2(n.formData):o.body=n.formData}return new Request(i,o)}function Y2(e){let t=new URLSearchParams;for(let[r,n]of e.entries())t.append(r,typeof n=="string"?n:n.name);return t}function q9(e){let t=new FormData;for(let[r,n]of e.entries())t.append(r,n);return t}function PRe(e,t,r,n,i){let o={},s=null,a,l=!1,c={},u=r&&Pa(r[1])?r[1].error:void 0;return e.forEach(d=>{if(!(d.route.id in t))return;let h=d.route.id,p=t[h];if(ln(!gg(p),"Cannot handle redirect results in processLoaderData"),Pa(p)){let f=p.error;u!==void 0&&(f=u,u=void 0),s=s||{};{let g=ig(e,h);s[g.route.id]==null&&(s[g.route.id]=f)}o[h]=void 0,l||(l=!0,a=g0(p.error)?p.error.status:500),p.headers&&(c[h]=p.headers)}else Jh(p)?(n.set(h,p.deferredData),o[h]=p.deferredData.data,p.statusCode!=null&&p.statusCode!==200&&!l&&(a=p.statusCode),p.headers&&(c[h]=p.headers)):(o[h]=p.data,p.statusCode&&p.statusCode!==200&&!l&&(a=p.statusCode),p.headers&&(c[h]=p.headers))}),u!==void 0&&r&&(s={[r[0]]:u},o[r[0]]=void 0),{loaderData:o,errors:s,statusCode:a||200,loaderHeaders:c}}function X9(e,t,r,n,i,o,s){let{loaderData:a,errors:l}=PRe(t,r,n,s);return i.forEach(c=>{let{key:u,match:d,controller:h}=c,p=o[u];if(ln(p,"Did not find corresponding fetcher result"),!(h&&h.signal.aborted))if(Pa(p)){let f=ig(e.matches,d==null?void 0:d.route.id);l&&l[f.route.id]||(l=ii({},l,{[f.route.id]:p.error})),e.fetchers.delete(u)}else if(gg(p))ln(!1,"Unhandled fetcher revalidation redirect");else if(Jh(p))ln(!1,"Unhandled fetcher deferred data");else{let f=Lh(p.data);e.fetchers.set(u,f)}}),{loaderData:a,errors:l}}function Y9(e,t,r,n){let i=ii({},t);for(let o of r){let s=o.route.id;if(t.hasOwnProperty(s)?t[s]!==void 0&&(i[s]=t[s]):e[s]!==void 0&&o.route.loader&&(i[s]=e[s]),n&&n.hasOwnProperty(s))break}return i}function Z9(e){return e?Pa(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function ig(e,t){return(t?e.slice(0,e.findIndex(n=>n.route.id===t)+1):[...e]).reverse().find(n=>n.route.hasErrorBoundary===!0)||e[0]}function Q9(e){let t=e.length===1?e[0]:e.find(r=>r.index||!r.path||r.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function qs(e,t){let{pathname:r,routeId:n,method:i,type:o,message:s}=t===void 0?{}:t,a="Unknown Server Error",l="Unknown @remix-run/router error";return e===400?(a="Bad Request",i&&r&&n?l="You made a "+i+' request to "'+r+'" but '+('did not provide a `loader` for route "'+n+'", ')+"so there is no way to handle the request.":o==="defer-action"?l="defer() is not supported in actions":o==="invalid-body"&&(l="Unable to encode submission body")):e===403?(a="Forbidden",l='Route "'+n+'" does not match URL "'+r+'"'):e===404?(a="Not Found",l='No route matches URL "'+r+'"'):e===405&&(a="Method Not Allowed",i&&r&&n?l="You made a "+i.toUpperCase()+' request to "'+r+'" but '+('did not provide an `action` for route "'+n+'", ')+"so there is no way to handle the request.":i&&(l='Invalid request method "'+i.toUpperCase()+'"')),new rM(e||500,a,new Error(l),!0)}function WE(e){let t=Object.entries(e);for(let r=t.length-1;r>=0;r--){let[n,i]=t[r];if(gg(i))return{key:n,result:i}}}function hse(e){let t=typeof e=="string"?Vp(e):e;return Qg(ii({},t,{hash:""}))}function MRe(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===""?t.hash!=="":e.hash===t.hash?!0:t.hash!==""}function IRe(e){return pse(e.result)&&fRe.has(e.result.status)}function Jh(e){return e.type===Fn.deferred}function Pa(e){return e.type===Fn.error}function gg(e){return(e&&e.type)===Fn.redirect}function J9(e){return typeof e=="object"&&e!=null&&"type"in e&&"data"in e&&"init"in e&&e.type==="DataWithResponseInit"}function DRe(e){let t=e;return t&&typeof t=="object"&&typeof t.data=="object"&&typeof t.subscribe=="function"&&typeof t.cancel=="function"&&typeof t.resolveData=="function"}function pse(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function ARe(e){return pRe.has(e.toLowerCase())}function Yl(e){return dRe.has(e.toLowerCase())}async function FRe(e,t,r,n,i){let o=Object.entries(t);for(let s=0;s(h==null?void 0:h.route.id)===a);if(!c)continue;let u=n.find(h=>h.route.id===c.route.id),d=u!=null&&!use(u,c)&&(i&&i[c.route.id])!==void 0;Jh(l)&&d&&await u3(l,r,!1).then(h=>{h&&(t[a]=h)})}}async function LRe(e,t,r){for(let n=0;n(c==null?void 0:c.route.id)===o)&&Jh(a)&&(ln(s,"Expected an AbortController for revalidating fetcher deferred result"),await u3(a,s.signal,!0).then(c=>{c&&(t[i]=c)}))}}async function u3(e,t,r){if(r===void 0&&(r=!1),!await e.deferredData.resolveData(t)){if(r)try{return{type:Fn.data,data:e.deferredData.unwrappedData}}catch(i){return{type:Fn.error,error:i}}return{type:Fn.data,data:e.deferredData.data}}}function d3(e){return new URLSearchParams(e).getAll("index").some(t=>t==="")}function JS(e,t){let r=typeof t=="string"?Vp(t).search:t.search;if(e[e.length-1].route.index&&d3(r||""))return e[e.length-1];let n=ase(e);return n[n.length-1]}function ej(e){let{formMethod:t,formAction:r,formEncType:n,text:i,formData:o,json:s}=e;if(!(!t||!r||!n)){if(i!=null)return{formMethod:t,formAction:r,formEncType:n,formData:void 0,json:void 0,text:i};if(o!=null)return{formMethod:t,formAction:r,formEncType:n,formData:o,json:void 0,text:void 0};if(s!==void 0)return{formMethod:t,formAction:r,formEncType:n,formData:void 0,json:s,text:void 0}}}function v_(e,t){return t?{state:"loading",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function _Re(e,t){return{state:"submitting",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function Jb(e,t){return e?{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function ORe(e,t){return{state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function Lh(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function kRe(e,t){try{let r=e.sessionStorage.getItem(cse);if(r){let n=JSON.parse(r);for(let[i,o]of Object.entries(n||{}))o&&Array.isArray(o)&&t.set(i,new Set(o||[]))}}catch{}}function NRe(e,t){if(t.size>0){let r={};for(let[n,i]of t)r[n]=[...i];try{e.sessionStorage.setItem(cse,JSON.stringify(r))}catch(n){ky(!1,"Failed to save applied view transitions in sessionStorage ("+n+").")}}}/** * React Router v6.30.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function nM(){return nM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),y.useCallback(function(c,u){if(u===void 0&&(u={}),!a.current)return;if(typeof c=="number"){n.go(c);return}let d=RD(c,JSON.parse(s),o,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:yd([t,d.pathname])),(u.replace?n.replace:n.push)(d,u.state,u)},[t,n,s,o,e])}const GRe=y.createContext(null);function VRe(e){let t=y.useContext(Ru).outlet;return t&&y.createElement(GRe.Provider,{value:e},t)}function aBt(){let{matches:e}=y.useContext(Ru),t=e[e.length-1];return t?t.params:{}}function vse(e,t){let{relative:r}=t===void 0?{}:t,{future:n}=y.useContext(zp),{matches:i}=y.useContext(Ru),{pathname:o}=RC(),s=JSON.stringify(TD(i,n.v7_relativeSplatPath));return y.useMemo(()=>RD(e,JSON.parse(s),o,r==="path"),[e,s,o,r])}function zRe(e,t,r,n){TC()||ln(!1);let{navigator:i}=y.useContext(zp),{matches:o}=y.useContext(Ru),s=o[o.length-1],a=s?s.params:{};s&&s.pathname;let l=s?s.pathnameBase:"/";s&&s.route;let c=RC(),u;u=c;let d=u.pathname||"/",h=d;if(l!=="/"){let g=l.replace(/^\//,"").split("/");h="/"+d.replace(/^\//,"").split("/").slice(g.length).join("/")}let p=ng(e,{pathname:h});return KRe(p&&p.map(g=>Object.assign({},g,{params:Object.assign({},a,g.params),pathname:yd([l,i.encodeLocation?i.encodeLocation(g.pathname).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?l:yd([l,i.encodeLocation?i.encodeLocation(g.pathnameBase).pathname:g.pathnameBase])})),o,r,n)}function HRe(){let e=ZRe(),t=g0(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return y.createElement(y.Fragment,null,y.createElement("h2",null,"Unexpected Application Error!"),y.createElement("h3",{style:{fontStyle:"italic"}},t),r?y.createElement("pre",{style:i},r):null,null)}const WRe=y.createElement(HRe,null);class URe extends y.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?y.createElement(Ru.Provider,{value:this.props.routeContext},y.createElement(gse.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function jRe(e){let{routeContext:t,match:r,children:n}=e,i=y.useContext(PD);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),y.createElement(Ru.Provider,{value:t},n)}function KRe(e,t,r,n){var i;if(t===void 0&&(t=[]),r===void 0&&(r=null),n===void 0&&(n=null),e==null){var o;if(!r)return null;if(r.errors)e=r.matches;else if((o=n)!=null&&o.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let s=e,a=(i=r)==null?void 0:i.errors;if(a!=null){let u=s.findIndex(d=>d.route.id&&(a==null?void 0:a[d.route.id])!==void 0);u>=0||ln(!1),s=s.slice(0,Math.min(s.length,u+1))}let l=!1,c=-1;if(r&&n&&n.v7_partialHydration)for(let u=0;u=0?s=s.slice(0,c+1):s=[s[0]];break}}}return s.reduceRight((u,d,h)=>{let p,f=!1,g=null,m=null;r&&(p=a&&d.route.id?a[d.route.id]:void 0,g=d.route.errorElement||WRe,l&&(c<0&&h===0?(JRe("route-fallback"),f=!0,m=null):c===h&&(f=!0,m=d.route.hydrateFallbackElement||null)));let v=t.concat(s.slice(0,h+1)),b=()=>{let S;return p?S=g:f?S=m:d.route.Component?S=y.createElement(d.route.Component,null):d.route.element?S=d.route.element:S=u,y.createElement(jRe,{match:d,routeContext:{outlet:u,matches:v,isDataRoute:r!=null},children:S})};return r&&(d.route.ErrorBoundary||d.route.errorElement||h===0)?y.createElement(URe,{location:r.location,revalidation:r.revalidation,component:g,error:p,children:b(),routeContext:{outlet:null,matches:v,isDataRoute:!0}}):b()},null)}var yse=(function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e})(yse||{}),Cse=(function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e})(Cse||{});function qRe(e){let t=y.useContext(PD);return t||ln(!1),t}function XRe(e){let t=y.useContext(fse);return t||ln(!1),t}function YRe(e){let t=y.useContext(Ru);return t||ln(!1),t}function bse(e){let t=YRe(),r=t.matches[t.matches.length-1];return r.route.id||ln(!1),r.route.id}function ZRe(){var e;let t=y.useContext(gse),r=XRe(Cse.UseRouteError),n=bse();return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function QRe(){let{router:e}=qRe(yse.UseNavigateStable),t=bse(),r=y.useRef(!1);return mse(()=>{r.current=!0}),y.useCallback(function(i,o){o===void 0&&(o={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,nM({fromRouteId:t},o)))},[e,t])}const tj={};function JRe(e,t,r){tj[e]||(tj[e]=!0)}function ePe(e,t){e==null||e.v7_startTransition,(e==null?void 0:e.v7_relativeSplatPath)===void 0&&(!t||t.v7_relativeSplatPath),t&&(t.v7_fetcherPersist,t.v7_normalizeFormMethod,t.v7_partialHydration,t.v7_skipActionErrorRevalidation)}function lBt(e){let{to:t,replace:r,state:n,relative:i}=e;TC()||ln(!1);let{future:o,static:s}=y.useContext(zp),{matches:a}=y.useContext(Ru),{pathname:l}=RC(),c=p3(),u=RD(t,TD(a,o.v7_relativeSplatPath),l,i==="path"),d=JSON.stringify(u);return y.useEffect(()=>c(JSON.parse(d),{replace:r,state:n,relative:i}),[c,d,i,r,n]),null}function cBt(e){return VRe(e.context)}function tPe(e){let{basename:t="/",children:r=null,location:n,navigationType:i=Vi.Pop,navigator:o,static:s=!1,future:a}=e;TC()&&ln(!1);let l=t.replace(/^\/*/,"/"),c=y.useMemo(()=>({basename:l,navigator:o,static:s,future:nM({v7_relativeSplatPath:!1},a)}),[l,a,o,s]);typeof n=="string"&&(n=Vp(n));let{pathname:u="/",search:d="",hash:h="",state:p=null,key:f="default"}=n,g=y.useMemo(()=>{let m=EC(u,l);return m==null?null:{location:{pathname:m,search:d,hash:h,state:p,key:f},navigationType:i}},[l,u,d,h,p,f,i]);return g==null?null:y.createElement(zp.Provider,{value:c},y.createElement(h3.Provider,{children:r,value:g}))}new Promise(()=>{});function rPe(e){let t={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(t,{element:y.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:y.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:y.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}/** * React Router DOM v6.30.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function m0(){return m0=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(r[i]=e[i]);return r}function iPe(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function oPe(e,t){return e.button===0&&(!t||t==="_self")&&!iPe(e)}function Z2(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let n=e[r];return t.concat(Array.isArray(n)?n.map(i=>[r,i]):[[r,n]])},[]))}function sPe(e,t){let r=Z2(e);return t&&t.forEach((n,i)=>{r.has(i)||t.getAll(i).forEach(o=>{r.append(i,o)})}),r}const aPe=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],lPe="6";try{window.__reactRouterVersion=lPe}catch{}function uBt(e,t){return yRe({basename:void 0,future:m0({},void 0,{v7_prependBasename:!0}),history:zTe({window:void 0}),hydrationData:cPe(),routes:e,mapRouteProperties:rPe,dataStrategy:void 0,patchRoutesOnNavigation:void 0,window:void 0}).initialize()}function cPe(){var e;let t=(e=window)==null?void 0:e.__staticRouterHydrationData;return t&&t.errors&&(t=m0({},t,{errors:uPe(t.errors)})),t}function uPe(e){if(!e)return null;let t=Object.entries(e),r={};for(let[n,i]of t)if(i&&i.__type==="RouteErrorResponse")r[n]=new rM(i.status,i.statusText,i.data,i.internal===!0);else if(i&&i.__type==="Error"){if(i.__subType){let o=window[i.__subType];if(typeof o=="function")try{let s=new o(i.message);s.stack="",r[n]=s}catch{}}if(r[n]==null){let o=new Error(i.message);o.stack="",r[n]=o}}else r[n]=i;return r}const dPe=y.createContext({isTransitioning:!1}),hPe=y.createContext(new Map),pPe="startTransition",rj=tse[pPe],fPe="flushSync",nj=VTe[fPe];function gPe(e){rj?rj(e):e()}function eS(e){nj?nj(e):e()}class mPe{constructor(){this.status="pending",this.promise=new Promise((t,r)=>{this.resolve=n=>{this.status==="pending"&&(this.status="resolved",t(n))},this.reject=n=>{this.status==="pending"&&(this.status="rejected",r(n))}})}}function dBt(e){let{fallbackElement:t,router:r,future:n}=e,[i,o]=y.useState(r.state),[s,a]=y.useState(),[l,c]=y.useState({isTransitioning:!1}),[u,d]=y.useState(),[h,p]=y.useState(),[f,g]=y.useState(),m=y.useRef(new Map),{v7_startTransition:v}=n||{},b=y.useCallback(M=>{v?gPe(M):M()},[v]),S=y.useCallback((M,D)=>{let{deletedFetchers:A,flushSync:I,viewTransitionOpts:L}=D;M.fetchers.forEach((k,O)=>{k.data!==void 0&&m.current.set(O,k.data)}),A.forEach(k=>m.current.delete(k));let F=r.window==null||r.window.document==null||typeof r.window.document.startViewTransition!="function";if(!L||F){I?eS(()=>o(M)):b(()=>o(M));return}if(I){eS(()=>{h&&(u&&u.resolve(),h.skipTransition()),c({isTransitioning:!0,flushSync:!0,currentLocation:L.currentLocation,nextLocation:L.nextLocation})});let k=r.window.document.startViewTransition(()=>{eS(()=>o(M))});k.finished.finally(()=>{eS(()=>{d(void 0),p(void 0),a(void 0),c({isTransitioning:!1})})}),eS(()=>p(k));return}h?(u&&u.resolve(),h.skipTransition(),g({state:M,currentLocation:L.currentLocation,nextLocation:L.nextLocation})):(a(M),c({isTransitioning:!0,flushSync:!1,currentLocation:L.currentLocation,nextLocation:L.nextLocation}))},[r.window,h,u,m,b]);y.useLayoutEffect(()=>r.subscribe(S),[r,S]),y.useEffect(()=>{l.isTransitioning&&!l.flushSync&&d(new mPe)},[l]),y.useEffect(()=>{if(u&&s&&r.window){let M=s,D=u.promise,A=r.window.document.startViewTransition(async()=>{b(()=>o(M)),await D});A.finished.finally(()=>{d(void 0),p(void 0),a(void 0),c({isTransitioning:!1})}),p(A)}},[b,s,u,r.window]),y.useEffect(()=>{u&&s&&i.location.key===s.location.key&&u.resolve()},[u,h,i.location,s]),y.useEffect(()=>{!l.isTransitioning&&f&&(a(f.state),c({isTransitioning:!0,flushSync:!1,currentLocation:f.currentLocation,nextLocation:f.nextLocation}),g(void 0))},[l.isTransitioning,f]),y.useEffect(()=>{},[]);let x=y.useMemo(()=>({createHref:r.createHref,encodeLocation:r.encodeLocation,go:M=>r.navigate(M),push:(M,D,A)=>r.navigate(M,{state:D,preventScrollReset:A==null?void 0:A.preventScrollReset}),replace:(M,D,A)=>r.navigate(M,{replace:!0,state:D,preventScrollReset:A==null?void 0:A.preventScrollReset})}),[r]),E=r.basename||"/",R=y.useMemo(()=>({router:r,navigator:x,static:!1,basename:E}),[r,x,E]),T=y.useMemo(()=>({v7_relativeSplatPath:r.future.v7_relativeSplatPath}),[r.future.v7_relativeSplatPath]);return y.useEffect(()=>ePe(n,r.future),[n,r.future]),y.createElement(y.Fragment,null,y.createElement(PD.Provider,{value:R},y.createElement(fse.Provider,{value:i},y.createElement(hPe.Provider,{value:m.current},y.createElement(dPe.Provider,{value:l},y.createElement(tPe,{basename:E,location:i.location,navigationType:i.historyAction,navigator:x,future:T},i.initialized||r.future.v7_partialHydration?y.createElement(vPe,{routes:r.routes,future:r.future,state:i}):t))))),null)}const vPe=y.memo(yPe);function yPe(e){let{routes:t,future:r,state:n}=e;return zRe(t,void 0,n,r)}const CPe=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",bPe=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,hBt=y.forwardRef(function(t,r){let{onClick:n,relative:i,reloadDocument:o,replace:s,state:a,target:l,to:c,preventScrollReset:u,viewTransition:d}=t,h=nPe(t,aPe),{basename:p}=y.useContext(zp),f,g=!1;if(typeof c=="string"&&bPe.test(c)&&(f=c,CPe))try{let S=new URL(window.location.href),x=c.startsWith("//")?new URL(S.protocol+c):new URL(c),E=EC(x.pathname,p);x.origin===S.origin&&E!=null?c=E+x.search+x.hash:g=!0}catch{}let m=BRe(c,{relative:i}),v=SPe(c,{replace:s,state:a,target:l,preventScrollReset:u,relative:i,viewTransition:d});function b(S){n&&n(S),S.defaultPrevented||v(S)}return y.createElement("a",m0({},h,{href:f||m,onClick:g||o?n:b,ref:r,target:l}))});var ij;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(ij||(ij={}));var oj;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(oj||(oj={}));function SPe(e,t){let{target:r,replace:n,state:i,preventScrollReset:o,relative:s,viewTransition:a}=t===void 0?{}:t,l=p3(),c=RC(),u=vse(e,{relative:s});return y.useCallback(d=>{if(oPe(d,r)){d.preventDefault();let h=n!==void 0?n:Qg(c)===Qg(u);l(e,{replace:h,state:i,preventScrollReset:o,relative:s,viewTransition:a})}},[c,l,u,n,i,r,e,o,s,a])}function pBt(e){let t=y.useRef(Z2(e)),r=y.useRef(!1),n=RC(),i=y.useMemo(()=>sPe(n.search,r.current?null:t.current),[n.search]),o=p3(),s=y.useCallback((a,l)=>{const c=Z2(typeof a=="function"?a(i):a);r.current=!0,o("?"+c,l)},[o,i]);return[i,s]}function Sse(e,t){return function(){return e.apply(t,arguments)}}const{toString:wPe}=Object.prototype,{getPrototypeOf:f3}=Object,{iterator:MD,toStringTag:wse}=Symbol,ID=(e=>t=>{const r=wPe.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),wc=e=>(e=e.toLowerCase(),t=>ID(t)===e),DD=e=>t=>typeof t===e,{isArray:PC}=Array,Ny=DD("undefined");function xx(e){return e!==null&&!Ny(e)&&e.constructor!==null&&!Ny(e.constructor)&&Js(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const xse=wc("ArrayBuffer");function xPe(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&xse(e.buffer),t}const EPe=DD("string"),Js=DD("function"),Ese=DD("number"),Ex=e=>e!==null&&typeof e=="object",TPe=e=>e===!0||e===!1,tP=e=>{if(ID(e)!=="object")return!1;const t=f3(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(wse in e)&&!(MD in e)},RPe=e=>{if(!Ex(e)||xx(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},PPe=wc("Date"),MPe=wc("File"),IPe=e=>!!(e&&typeof e.uri<"u"),DPe=e=>e&&typeof e.getParts<"u",APe=wc("Blob"),FPe=wc("FileList"),LPe=e=>Ex(e)&&Js(e.pipe);function _Pe(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const sj=_Pe(),aj=typeof sj.FormData<"u"?sj.FormData:void 0,OPe=e=>{let t;return e&&(aj&&e instanceof aj||Js(e.append)&&((t=ID(e))==="formdata"||t==="object"&&Js(e.toString)&&e.toString()==="[object FormData]"))},kPe=wc("URLSearchParams"),[NPe,BPe,$Pe,GPe]=["ReadableStream","Request","Response","Headers"].map(wc),VPe=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Tx(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,i;if(typeof e!="object"&&(e=[e]),PC(e))for(n=0,i=e.length;n0;)if(i=r[n],t===i.toLowerCase())return i;return null}const mg=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Rse=e=>!Ny(e)&&e!==mg;function Q2(){const{caseless:e,skipUndefined:t}=Rse(this)&&this||{},r={},n=(i,o)=>{if(o==="__proto__"||o==="constructor"||o==="prototype")return;const s=e&&Tse(r,o)||o;tP(r[s])&&tP(i)?r[s]=Q2(r[s],i):tP(i)?r[s]=Q2({},i):PC(i)?r[s]=i.slice():(!t||!Ny(i))&&(r[s]=i)};for(let i=0,o=arguments.length;i(Tx(t,(i,o)=>{r&&Js(i)?Object.defineProperty(e,o,{value:Sse(i,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,o,{value:i,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),HPe=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),WPe=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},UPe=(e,t,r,n)=>{let i,o,s;const a={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)s=i[o],(!n||n(s,e,t))&&!a[s]&&(t[s]=e[s],a[s]=!0);e=r!==!1&&f3(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},jPe=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},KPe=e=>{if(!e)return null;if(PC(e))return e;let t=e.length;if(!Ese(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},qPe=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&f3(Uint8Array)),XPe=(e,t)=>{const n=(e&&e[MD]).call(e);let i;for(;(i=n.next())&&!i.done;){const o=i.value;t.call(e,o[0],o[1])}},YPe=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},ZPe=wc("HTMLFormElement"),QPe=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,i){return n.toUpperCase()+i}),lj=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),JPe=wc("RegExp"),Pse=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};Tx(r,(i,o)=>{let s;(s=t(i,o,e))!==!1&&(n[o]=s||i)}),Object.defineProperties(e,n)},eMe=e=>{Pse(e,(t,r)=>{if(Js(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(Js(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},tMe=(e,t)=>{const r={},n=i=>{i.forEach(o=>{r[o]=!0})};return PC(e)?n(e):n(String(e).split(t)),r},rMe=()=>{},nMe=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function iMe(e){return!!(e&&Js(e.append)&&e[wse]==="FormData"&&e[MD])}const oMe=e=>{const t=new Array(10),r=(n,i)=>{if(Ex(n)){if(t.indexOf(n)>=0)return;if(xx(n))return n;if(!("toJSON"in n)){t[i]=n;const o=PC(n)?[]:{};return Tx(n,(s,a)=>{const l=r(s,i+1);!Ny(l)&&(o[a]=l)}),t[i]=void 0,o}}return n};return r(e,0)},sMe=wc("AsyncFunction"),aMe=e=>e&&(Ex(e)||Js(e))&&Js(e.then)&&Js(e.catch),Mse=((e,t)=>e?setImmediate:t?((r,n)=>(mg.addEventListener("message",({source:i,data:o})=>{i===mg&&o===r&&n.length&&n.shift()()},!1),i=>{n.push(i),mg.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",Js(mg.postMessage)),lMe=typeof queueMicrotask<"u"?queueMicrotask.bind(mg):typeof process<"u"&&process.nextTick||Mse,cMe=e=>e!=null&&Js(e[MD]),je={isArray:PC,isArrayBuffer:xse,isBuffer:xx,isFormData:OPe,isArrayBufferView:xPe,isString:EPe,isNumber:Ese,isBoolean:TPe,isObject:Ex,isPlainObject:tP,isEmptyObject:RPe,isReadableStream:NPe,isRequest:BPe,isResponse:$Pe,isHeaders:GPe,isUndefined:Ny,isDate:PPe,isFile:MPe,isReactNativeBlob:IPe,isReactNative:DPe,isBlob:APe,isRegExp:JPe,isFunction:Js,isStream:LPe,isURLSearchParams:kPe,isTypedArray:qPe,isFileList:FPe,forEach:Tx,merge:Q2,extend:zPe,trim:VPe,stripBOM:HPe,inherits:WPe,toFlatObject:UPe,kindOf:ID,kindOfTest:wc,endsWith:jPe,toArray:KPe,forEachEntry:XPe,matchAll:YPe,isHTMLForm:ZPe,hasOwnProperty:lj,hasOwnProp:lj,reduceDescriptors:Pse,freezeMethods:eMe,toObjectSet:tMe,toCamelCase:QPe,noop:rMe,toFiniteNumber:nMe,findKey:Tse,global:mg,isContextDefined:Rse,isSpecCompliantForm:iMe,toJSONObject:oMe,isAsyncFn:sMe,isThenable:aMe,setImmediate:Mse,asap:lMe,isIterable:cMe};let Ar=class Ise extends Error{static from(t,r,n,i,o,s){const a=new Ise(t.message,r||t.code,n,i,o);return a.cause=t,a.name=t.name,t.status!=null&&a.status==null&&(a.status=t.status),s&&Object.assign(a,s),a}constructor(t,r,n,i,o){super(t),Object.defineProperty(this,"message",{value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,r&&(this.code=r),n&&(this.config=n),i&&(this.request=i),o&&(this.response=o,this.status=o.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:je.toJSONObject(this.config),code:this.code,status:this.status}}};Ar.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";Ar.ERR_BAD_OPTION="ERR_BAD_OPTION";Ar.ECONNABORTED="ECONNABORTED";Ar.ETIMEDOUT="ETIMEDOUT";Ar.ERR_NETWORK="ERR_NETWORK";Ar.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";Ar.ERR_DEPRECATED="ERR_DEPRECATED";Ar.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";Ar.ERR_BAD_REQUEST="ERR_BAD_REQUEST";Ar.ERR_CANCELED="ERR_CANCELED";Ar.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";Ar.ERR_INVALID_URL="ERR_INVALID_URL";const uMe=null;function J2(e){return je.isPlainObject(e)||je.isArray(e)}function Dse(e){return je.endsWith(e,"[]")?e.slice(0,-2):e}function y_(e,t,r){return e?e.concat(t).map(function(i,o){return i=Dse(i),!r&&o?"["+i+"]":i}).join(r?".":""):t}function dMe(e){return je.isArray(e)&&!e.some(J2)}const hMe=je.toFlatObject(je,{},null,function(t){return/^is[A-Z]/.test(t)});function AD(e,t,r){if(!je.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=je.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(g,m){return!je.isUndefined(m[g])});const n=r.metaTokens,i=r.visitor||u,o=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&je.isSpecCompliantForm(t);if(!je.isFunction(i))throw new TypeError("visitor must be a function");function c(f){if(f===null)return"";if(je.isDate(f))return f.toISOString();if(je.isBoolean(f))return f.toString();if(!l&&je.isBlob(f))throw new Ar("Blob is not supported. Use a Buffer instead.");return je.isArrayBuffer(f)||je.isTypedArray(f)?l&&typeof Blob=="function"?new Blob([f]):Buffer.from(f):f}function u(f,g,m){let v=f;if(je.isReactNative(t)&&je.isReactNativeBlob(f))return t.append(y_(m,g,o),c(f)),!1;if(f&&!m&&typeof f=="object"){if(je.endsWith(g,"{}"))g=n?g:g.slice(0,-2),f=JSON.stringify(f);else if(je.isArray(f)&&dMe(f)||(je.isFileList(f)||je.endsWith(g,"[]"))&&(v=je.toArray(f)))return g=Dse(g),v.forEach(function(S,x){!(je.isUndefined(S)||S===null)&&t.append(s===!0?y_([g],x,o):s===null?g:g+"[]",c(S))}),!1}return J2(f)?!0:(t.append(y_(m,g,o),c(f)),!1)}const d=[],h=Object.assign(hMe,{defaultVisitor:u,convertValue:c,isVisitable:J2});function p(f,g){if(!je.isUndefined(f)){if(d.indexOf(f)!==-1)throw Error("Circular reference detected in "+g.join("."));d.push(f),je.forEach(f,function(v,b){(!(je.isUndefined(v)||v===null)&&i.call(t,v,je.isString(b)?b.trim():b,g,h))===!0&&p(v,g?g.concat(b):[b])}),d.pop()}}if(!je.isObject(e))throw new TypeError("data must be an object");return p(e),t}function cj(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function g3(e,t){this._pairs=[],e&&AD(e,this,t)}const Ase=g3.prototype;Ase.append=function(t,r){this._pairs.push([t,r])};Ase.toString=function(t){const r=t?function(n){return t.call(this,n,cj)}:cj;return this._pairs.map(function(i){return r(i[0])+"="+r(i[1])},"").join("&")};function pMe(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Fse(e,t,r){if(!t)return e;const n=r&&r.encode||pMe,i=je.isFunction(r)?{serialize:r}:r,o=i&&i.serialize;let s;if(o?s=o(t,i):s=je.isURLSearchParams(t)?t.toString():new g3(t,i).toString(n),s){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}let uj=class{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){je.forEach(this.handlers,function(n){n!==null&&t(n)})}};const m3={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},fMe=typeof URLSearchParams<"u"?URLSearchParams:g3,gMe=typeof FormData<"u"?FormData:null,mMe=typeof Blob<"u"?Blob:null,vMe={isBrowser:!0,classes:{URLSearchParams:fMe,FormData:gMe,Blob:mMe},protocols:["http","https","file","blob","url","data"]},v3=typeof window<"u"&&typeof document<"u",eB=typeof navigator=="object"&&navigator||void 0,yMe=v3&&(!eB||["ReactNative","NativeScript","NS"].indexOf(eB.product)<0),CMe=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",bMe=v3&&window.location.href||"http://localhost",SMe=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:v3,hasStandardBrowserEnv:yMe,hasStandardBrowserWebWorkerEnv:CMe,navigator:eB,origin:bMe},Symbol.toStringTag,{value:"Module"})),ss={...SMe,...vMe};function wMe(e,t){return AD(e,new ss.classes.URLSearchParams,{visitor:function(r,n,i,o){return ss.isNode&&je.isBuffer(r)?(this.append(n,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...t})}function xMe(e){return je.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function EMe(e){const t={},r=Object.keys(e);let n;const i=r.length;let o;for(n=0;n=r.length;return s=!s&&je.isArray(i)?i.length:s,l?(je.hasOwnProp(i,s)?i[s]=[i[s],n]:i[s]=n,!a):((!i[s]||!je.isObject(i[s]))&&(i[s]=[]),t(r,n,i[s],o)&&je.isArray(i[s])&&(i[s]=EMe(i[s])),!a)}if(je.isFormData(e)&&je.isFunction(e.entries)){const r={};return je.forEachEntry(e,(n,i)=>{t(xMe(n),i,r,0)}),r}return null}function TMe(e,t,r){if(je.isString(e))try{return(t||JSON.parse)(e),je.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const Rx={transitional:m3,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",i=n.indexOf("application/json")>-1,o=je.isObject(t);if(o&&je.isHTMLForm(t)&&(t=new FormData(t)),je.isFormData(t))return i?JSON.stringify(Lse(t)):t;if(je.isArrayBuffer(t)||je.isBuffer(t)||je.isStream(t)||je.isFile(t)||je.isBlob(t)||je.isReadableStream(t))return t;if(je.isArrayBufferView(t))return t.buffer;if(je.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return wMe(t,this.formSerializer).toString();if((a=je.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return AD(a?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||i?(r.setContentType("application/json",!1),TMe(t)):t}],transformResponse:[function(t){const r=this.transitional||Rx.transitional,n=r&&r.forcedJSONParsing,i=this.responseType==="json";if(je.isResponse(t)||je.isReadableStream(t))return t;if(t&&je.isString(t)&&(n&&!this.responseType||i)){const s=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(t,this.parseReviver)}catch(a){if(s)throw a.name==="SyntaxError"?Ar.from(a,Ar.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ss.classes.FormData,Blob:ss.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};je.forEach(["delete","get","head","post","put","patch"],e=>{Rx.headers[e]={}});const RMe=je.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),PMe=e=>{const t={};let r,n,i;return e&&e.split(` `).forEach(function(s){i=s.indexOf(":"),r=s.substring(0,i).trim().toLowerCase(),n=s.substring(i+1).trim(),!(!r||t[r]&&RMe[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},dj=Symbol("internals");function tS(e){return e&&String(e).trim().toLowerCase()}function rP(e){return e===!1||e==null?e:je.isArray(e)?e.map(rP):String(e)}function MMe(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const IMe=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function C_(e,t,r,n,i){if(je.isFunction(n))return n.call(this,t,r);if(i&&(t=r),!!je.isString(t)){if(je.isString(n))return t.indexOf(n)!==-1;if(je.isRegExp(n))return n.test(t)}}function DMe(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function AMe(e,t){const r=je.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(i,o,s){return this[n].call(this,t,i,o,s)},configurable:!0})})}let ea=class{constructor(t){t&&this.set(t)}set(t,r,n){const i=this;function o(a,l,c){const u=tS(l);if(!u)throw new Error("header name must be a non-empty string");const d=je.findKey(i,u);(!d||i[d]===void 0||c===!0||c===void 0&&i[d]!==!1)&&(i[d||l]=rP(a))}const s=(a,l)=>je.forEach(a,(c,u)=>o(c,u,l));if(je.isPlainObject(t)||t instanceof this.constructor)s(t,r);else if(je.isString(t)&&(t=t.trim())&&!IMe(t))s(PMe(t),r);else if(je.isObject(t)&&je.isIterable(t)){let a={},l,c;for(const u of t){if(!je.isArray(u))throw TypeError("Object iterator must return a key-value pair");a[c=u[0]]=(l=a[c])?je.isArray(l)?[...l,u[1]]:[l,u[1]]:u[1]}s(a,r)}else t!=null&&o(r,t,n);return this}get(t,r){if(t=tS(t),t){const n=je.findKey(this,t);if(n){const i=this[n];if(!r)return i;if(r===!0)return MMe(i);if(je.isFunction(r))return r.call(this,i,n);if(je.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=tS(t),t){const n=je.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||C_(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let i=!1;function o(s){if(s=tS(s),s){const a=je.findKey(n,s);a&&(!r||C_(n,n[a],a,r))&&(delete n[a],i=!0)}}return je.isArray(t)?t.forEach(o):o(t),i}clear(t){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const o=r[n];(!t||C_(this,this[o],o,t,!0))&&(delete this[o],i=!0)}return i}normalize(t){const r=this,n={};return je.forEach(this,(i,o)=>{const s=je.findKey(n,o);if(s){r[s]=rP(i),delete r[o];return}const a=t?DMe(o):String(o).trim();a!==o&&delete r[o],r[a]=rP(i),n[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return je.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=t&&je.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(` `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(i=>n.set(i)),n}static accessor(t){const n=(this[dj]=this[dj]={accessors:{}}).accessors,i=this.prototype;function o(s){const a=tS(s);n[a]||(AMe(i,s),n[a]=!0)}return je.isArray(t)?t.forEach(o):o(t),this}};ea.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);je.reduceDescriptors(ea.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});je.freezeMethods(ea);function b_(e,t){const r=this||Rx,n=t||r,i=ea.from(n.headers);let o=n.data;return je.forEach(e,function(a){o=a.call(r,o,i.normalize(),t?t.status:void 0)}),i.normalize(),o}function _se(e){return!!(e&&e.__CANCEL__)}let Px=class extends Ar{constructor(t,r,n){super(t??"canceled",Ar.ERR_CANCELED,r,n),this.name="CanceledError",this.__CANCEL__=!0}};function Ose(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new Ar("Request failed with status code "+r.status,[Ar.ERR_BAD_REQUEST,Ar.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function FMe(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function LMe(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i=0,o=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=n[o];s||(s=c),r[i]=l,n[i]=c;let d=o,h=0;for(;d!==i;)h+=r[d++],d=d%e;if(i=(i+1)%e,i===o&&(o=(o+1)%e),c-s{r=u,i=null,o&&(clearTimeout(o),o=null),e(...c)};return[(...c)=>{const u=Date.now(),d=u-r;d>=n?s(c,u):(i=c,o||(o=setTimeout(()=>{o=null,s(i)},n-d)))},()=>i&&s(i)]}const iM=(e,t,r=3)=>{let n=0;const i=LMe(50,250);return _Me(o=>{const s=o.loaded,a=o.lengthComputable?o.total:void 0,l=s-n,c=i(l),u=s<=a;n=s;const d={loaded:s,total:a,progress:a?s/a:void 0,bytes:l,rate:c||void 0,estimated:c&&a&&u?(a-s)/c:void 0,event:o,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(d)},r)},hj=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},pj=e=>(...t)=>je.asap(()=>e(...t)),OMe=ss.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,ss.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(ss.origin),ss.navigator&&/(msie|trident)/i.test(ss.navigator.userAgent)):()=>!0,kMe=ss.hasStandardBrowserEnv?{write(e,t,r,n,i,o,s){if(typeof document>"u")return;const a=[`${e}=${encodeURIComponent(t)}`];je.isNumber(r)&&a.push(`expires=${new Date(r).toUTCString()}`),je.isString(n)&&a.push(`path=${n}`),je.isString(i)&&a.push(`domain=${i}`),o===!0&&a.push("secure"),je.isString(s)&&a.push(`SameSite=${s}`),document.cookie=a.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function NMe(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function BMe(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function kse(e,t,r){let n=!NMe(t);return e&&(n||r==!1)?BMe(e,t):t}const fj=e=>e instanceof ea?{...e}:e;function Jg(e,t){t=t||{};const r={};function n(c,u,d,h){return je.isPlainObject(c)&&je.isPlainObject(u)?je.merge.call({caseless:h},c,u):je.isPlainObject(u)?je.merge({},u):je.isArray(u)?u.slice():u}function i(c,u,d,h){if(je.isUndefined(u)){if(!je.isUndefined(c))return n(void 0,c,d,h)}else return n(c,u,d,h)}function o(c,u){if(!je.isUndefined(u))return n(void 0,u)}function s(c,u){if(je.isUndefined(u)){if(!je.isUndefined(c))return n(void 0,c)}else return n(void 0,u)}function a(c,u,d){if(d in t)return n(c,u);if(d in e)return n(void 0,c)}const l={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:a,headers:(c,u,d)=>i(fj(c),fj(u),d,!0)};return je.forEach(Object.keys({...e,...t}),function(u){if(u==="__proto__"||u==="constructor"||u==="prototype")return;const d=je.hasOwnProp(l,u)?l[u]:i,h=d(e[u],t[u],u);je.isUndefined(h)&&d!==a||(r[u]=h)}),r}const Nse=e=>{const t=Jg({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:o,headers:s,auth:a}=t;if(t.headers=s=ea.from(s),t.url=Fse(kse(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),a&&s.set("Authorization","Basic "+btoa((a.username||"")+":"+(a.password?unescape(encodeURIComponent(a.password)):""))),je.isFormData(r)){if(ss.hasStandardBrowserEnv||ss.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(je.isFunction(r.getHeaders)){const l=r.getHeaders(),c=["content-type","content-length"];Object.entries(l).forEach(([u,d])=>{c.includes(u.toLowerCase())&&s.set(u,d)})}}if(ss.hasStandardBrowserEnv&&(n&&je.isFunction(n)&&(n=n(t)),n||n!==!1&&OMe(t.url))){const l=i&&o&&kMe.read(o);l&&s.set(i,l)}return t},$Me=typeof XMLHttpRequest<"u",GMe=$Me&&function(e){return new Promise(function(r,n){const i=Nse(e);let o=i.data;const s=ea.from(i.headers).normalize();let{responseType:a,onUploadProgress:l,onDownloadProgress:c}=i,u,d,h,p,f;function g(){p&&p(),f&&f(),i.cancelToken&&i.cancelToken.unsubscribe(u),i.signal&&i.signal.removeEventListener("abort",u)}let m=new XMLHttpRequest;m.open(i.method.toUpperCase(),i.url,!0),m.timeout=i.timeout;function v(){if(!m)return;const S=ea.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),E={data:!a||a==="text"||a==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:S,config:e,request:m};Ose(function(T){r(T),g()},function(T){n(T),g()},E),m=null}"onloadend"in m?m.onloadend=v:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(v)},m.onabort=function(){m&&(n(new Ar("Request aborted",Ar.ECONNABORTED,e,m)),m=null)},m.onerror=function(x){const E=x&&x.message?x.message:"Network Error",R=new Ar(E,Ar.ERR_NETWORK,e,m);R.event=x||null,n(R),m=null},m.ontimeout=function(){let x=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const E=i.transitional||m3;i.timeoutErrorMessage&&(x=i.timeoutErrorMessage),n(new Ar(x,E.clarifyTimeoutError?Ar.ETIMEDOUT:Ar.ECONNABORTED,e,m)),m=null},o===void 0&&s.setContentType(null),"setRequestHeader"in m&&je.forEach(s.toJSON(),function(x,E){m.setRequestHeader(E,x)}),je.isUndefined(i.withCredentials)||(m.withCredentials=!!i.withCredentials),a&&a!=="json"&&(m.responseType=i.responseType),c&&([h,f]=iM(c,!0),m.addEventListener("progress",h)),l&&m.upload&&([d,p]=iM(l),m.upload.addEventListener("progress",d),m.upload.addEventListener("loadend",p)),(i.cancelToken||i.signal)&&(u=S=>{m&&(n(!S||S.type?new Px(null,e,m):S),m.abort(),m=null)},i.cancelToken&&i.cancelToken.subscribe(u),i.signal&&(i.signal.aborted?u():i.signal.addEventListener("abort",u)));const b=FMe(i.url);if(b&&ss.protocols.indexOf(b)===-1){n(new Ar("Unsupported protocol "+b+":",Ar.ERR_BAD_REQUEST,e));return}m.send(o||null)})},VMe=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,i;const o=function(c){if(!i){i=!0,a();const u=c instanceof Error?c:this.reason;n.abort(u instanceof Ar?u:new Px(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,o(new Ar(`timeout of ${t}ms exceeded`,Ar.ETIMEDOUT))},t);const a=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=n;return l.unsubscribe=()=>je.asap(a),l}},zMe=function*(e,t){let r=e.byteLength;if(r{const i=HMe(e,t);let o=0,s,a=l=>{s||(s=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await i.next();if(c){a(),l.close();return}let d=u.byteLength;if(r){let h=o+=d;r(h)}l.enqueue(new Uint8Array(u))}catch(c){throw a(c),c}},cancel(l){return a(l),i.return()}},{highWaterMark:2})},mj=64*1024,{isFunction:UE}=je,UMe=(({Request:e,Response:t})=>({Request:e,Response:t}))(je.global),{ReadableStream:vj,TextEncoder:yj}=je.global,Cj=(e,...t)=>{try{return!!e(...t)}catch{return!1}},jMe=e=>{e=je.merge.call({skipUndefined:!0},UMe,e);const{fetch:t,Request:r,Response:n}=e,i=t?UE(t):typeof fetch=="function",o=UE(r),s=UE(n);if(!i)return!1;const a=i&&UE(vj),l=i&&(typeof yj=="function"?(f=>g=>f.encode(g))(new yj):async f=>new Uint8Array(await new r(f).arrayBuffer())),c=o&&a&&Cj(()=>{let f=!1;const g=new r(ss.origin,{body:new vj,method:"POST",get duplex(){return f=!0,"half"}}).headers.has("Content-Type");return f&&!g}),u=s&&a&&Cj(()=>je.isReadableStream(new n("").body)),d={stream:u&&(f=>f.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(f=>{!d[f]&&(d[f]=(g,m)=>{let v=g&&g[f];if(v)return v.call(g);throw new Ar(`Response type '${f}' is not supported`,Ar.ERR_NOT_SUPPORT,m)})});const h=async f=>{if(f==null)return 0;if(je.isBlob(f))return f.size;if(je.isSpecCompliantForm(f))return(await new r(ss.origin,{method:"POST",body:f}).arrayBuffer()).byteLength;if(je.isArrayBufferView(f)||je.isArrayBuffer(f))return f.byteLength;if(je.isURLSearchParams(f)&&(f=f+""),je.isString(f))return(await l(f)).byteLength},p=async(f,g)=>{const m=je.toFiniteNumber(f.getContentLength());return m??h(g)};return async f=>{let{url:g,method:m,data:v,signal:b,cancelToken:S,timeout:x,onDownloadProgress:E,onUploadProgress:R,responseType:T,headers:M,withCredentials:D="same-origin",fetchOptions:A}=Nse(f),I=t||fetch;T=T?(T+"").toLowerCase():"text";let L=VMe([b,S&&S.toAbortSignal()],x),F=null;const k=L&&L.unsubscribe&&(()=>{L.unsubscribe()});let O;try{if(R&&c&&m!=="get"&&m!=="head"&&(O=await p(M,v))!==0){let V=new r(g,{method:"POST",body:v,duplex:"half"}),$;if(je.isFormData(v)&&($=V.headers.get("content-type"))&&M.setContentType($),V.body){const[K,q]=hj(O,iM(pj(R)));v=gj(V.body,mj,K,q)}}je.isString(D)||(D=D?"include":"omit");const B=o&&"credentials"in r.prototype,H={...A,signal:L,method:m.toUpperCase(),headers:M.normalize().toJSON(),body:v,duplex:"half",credentials:B?D:void 0};F=o&&new r(g,H);let N=await(o?I(F,A):I(g,H));const z=u&&(T==="stream"||T==="response");if(u&&(E||z&&k)){const V={};["status","statusText","headers"].forEach(X=>{V[X]=N[X]});const $=je.toFiniteNumber(N.headers.get("content-length")),[K,q]=E&&hj($,iM(pj(E),!0))||[];N=new n(gj(N.body,mj,K,()=>{q&&q(),k&&k()}),V)}T=T||"text";let W=await d[je.findKey(d,T)||"text"](N,f);return!z&&k&&k(),await new Promise((V,$)=>{Ose(V,$,{data:W,headers:ea.from(N.headers),status:N.status,statusText:N.statusText,config:f,request:F})})}catch(B){throw k&&k(),B&&B.name==="TypeError"&&/Load failed|fetch/i.test(B.message)?Object.assign(new Ar("Network Error",Ar.ERR_NETWORK,f,F,B&&B.response),{cause:B.cause||B}):Ar.from(B,B&&B.code,f,F,B&&B.response)}}},KMe=new Map,Bse=e=>{let t=e&&e.env||{};const{fetch:r,Request:n,Response:i}=t,o=[n,i,r];let s=o.length,a=s,l,c,u=KMe;for(;a--;)l=o[a],c=u.get(l),c===void 0&&u.set(l,c=a?new Map:jMe(t)),u=c;return c};Bse();const y3={http:uMe,xhr:GMe,fetch:{get:Bse}};je.forEach(y3,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const bj=e=>`- ${e}`,qMe=e=>je.isFunction(e)||e===null||e===!1;function XMe(e,t){e=je.isArray(e)?e:[e];const{length:r}=e;let n,i;const o={};for(let s=0;s`adapter ${l} `+(c===!1?"is not supported by the environment":"is not available in the build"));let a=r?s.length>1?`since : `+s.map(bj).join(` `):" "+bj(s[0]):"as no adapter specified";throw new Ar("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return i}const $se={getAdapter:XMe,adapters:y3};function S_(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Px(null,e)}function Sj(e){return S_(e),e.headers=ea.from(e.headers),e.data=b_.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),$se.getAdapter(e.adapter||Rx.adapter,e)(e).then(function(n){return S_(e),n.data=b_.call(e,e.transformResponse,n),n.headers=ea.from(n.headers),n},function(n){return _se(n)||(S_(e),n&&n.response&&(n.response.data=b_.call(e,e.transformResponse,n.response),n.response.headers=ea.from(n.response.headers))),Promise.reject(n)})}const Gse="1.13.6",FD={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{FD[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const wj={};FD.transitional=function(t,r,n){function i(o,s){return"[Axios v"+Gse+"] Transitional option '"+o+"'"+s+(n?". "+n:"")}return(o,s,a)=>{if(t===!1)throw new Ar(i(s," has been removed"+(r?" in "+r:"")),Ar.ERR_DEPRECATED);return r&&!wj[s]&&(wj[s]=!0,console.warn(i(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(o,s,a):!0}};FD.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function YMe(e,t,r){if(typeof e!="object")throw new Ar("options must be an object",Ar.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const o=n[i],s=t[o];if(s){const a=e[o],l=a===void 0||s(a,o,e);if(l!==!0)throw new Ar("option "+o+" must be "+l,Ar.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Ar("Unknown option "+o,Ar.ERR_BAD_OPTION)}}const nP={assertOptions:YMe,validators:FD},Ya=nP.validators;let Lg=class{constructor(t){this.defaults=t||{},this.interceptors={request:new uj,response:new uj}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const o=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?o&&!String(n.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(n.stack+=` `+o):n.stack=o}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Jg(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:o}=r;n!==void 0&&nP.assertOptions(n,{silentJSONParsing:Ya.transitional(Ya.boolean),forcedJSONParsing:Ya.transitional(Ya.boolean),clarifyTimeoutError:Ya.transitional(Ya.boolean),legacyInterceptorReqResOrdering:Ya.transitional(Ya.boolean)},!1),i!=null&&(je.isFunction(i)?r.paramsSerializer={serialize:i}:nP.assertOptions(i,{encode:Ya.function,serialize:Ya.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),nP.assertOptions(r,{baseUrl:Ya.spelling("baseURL"),withXsrfToken:Ya.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=o&&je.merge(o.common,o[r.method]);o&&je.forEach(["delete","get","head","post","put","patch","common"],f=>{delete o[f]}),r.headers=ea.concat(s,o);const a=[];let l=!0;this.interceptors.request.forEach(function(g){if(typeof g.runWhen=="function"&&g.runWhen(r)===!1)return;l=l&&g.synchronous;const m=r.transitional||m3;m&&m.legacyInterceptorReqResOrdering?a.unshift(g.fulfilled,g.rejected):a.push(g.fulfilled,g.rejected)});const c=[];this.interceptors.response.forEach(function(g){c.push(g.fulfilled,g.rejected)});let u,d=0,h;if(!l){const f=[Sj.bind(this),void 0];for(f.unshift(...a),f.push(...c),h=f.length,u=Promise.resolve(r);d{if(!n._listeners)return;let o=n._listeners.length;for(;o-- >0;)n._listeners[o](i);n._listeners=null}),this.promise.then=i=>{let o;const s=new Promise(a=>{n.subscribe(a),o=a}).then(i);return s.cancel=function(){n.unsubscribe(o)},s},t(function(o,s,a){n.reason||(n.reason=new Px(o,s,a),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Vse(function(i){t=i}),cancel:t}}};function QMe(e){return function(r){return e.apply(null,r)}}function JMe(e){return je.isObject(e)&&e.isAxiosError===!0}const tB={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(tB).forEach(([e,t])=>{tB[t]=e});function zse(e){const t=new Lg(e),r=Sse(Lg.prototype.request,t);return je.extend(r,Lg.prototype,t,{allOwnKeys:!0}),je.extend(r,t,null,{allOwnKeys:!0}),r.create=function(i){return zse(Jg(e,i))},r}const Ki=zse(Rx);Ki.Axios=Lg;Ki.CanceledError=Px;Ki.CancelToken=ZMe;Ki.isCancel=_se;Ki.VERSION=Gse;Ki.toFormData=AD;Ki.AxiosError=Ar;Ki.Cancel=Ki.CanceledError;Ki.all=function(t){return Promise.all(t)};Ki.spread=QMe;Ki.isAxiosError=JMe;Ki.mergeConfig=Jg;Ki.AxiosHeaders=ea;Ki.formToJSON=e=>Lse(je.isHTMLForm(e)?new FormData(e):e);Ki.getAdapter=$se.getAdapter;Ki.HttpStatusCode=tB;Ki.default=Ki;const{Axios:yBt,AxiosError:CBt,CanceledError:bBt,isCancel:SBt,CancelToken:wBt,VERSION:xBt,all:EBt,Cancel:TBt,isAxiosError:RBt,spread:PBt,toFormData:MBt,AxiosHeaders:IBt,HttpStatusCode:DBt,formToJSON:ABt,getAdapter:FBt,mergeConfig:LBt}=Ki;function br(e){const t=y.useRef(e);return t.current=e,y.useCallback((...n)=>{var i;return(i=t.current)==null?void 0:i.call(t,...n)},[])}function To(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}const xj=To()?y.useLayoutEffect:y.useEffect,jr=(e,t)=>{const r=y.useRef(!0);xj(()=>e(r.current),t),xj(()=>(r.current=!1,()=>{r.current=!0}),[])},iP=(e,t)=>{jr(r=>{if(!r)return e()},t)},v0=e=>{const t=y.useRef(!1),[r,n]=y.useState(e);y.useEffect(()=>(t.current=!1,()=>{t.current=!0}),[]);function i(o,s){s&&t.current||n(o)}return[r,i]};function An(e,t){const[r,n]=y.useState(e),i=t!==void 0?t:r;return jr(o=>{o||n(t)},[t]),[i,n]}var w_={exports:{}},In={};/** * @license React * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Ej;function eIe(){if(Ej)return In;Ej=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),f;f=Symbol.for("react.module.reference");function g(m){if(typeof m=="object"&&m!==null){var v=m.$$typeof;switch(v){case e:switch(m=m.type,m){case r:case i:case n:case c:case u:return m;default:switch(m=m&&m.$$typeof,m){case a:case s:case l:case h:case d:case o:return m;default:return v}}case t:return v}}}return In.ContextConsumer=s,In.ContextProvider=o,In.Element=e,In.ForwardRef=l,In.Fragment=r,In.Lazy=h,In.Memo=d,In.Portal=t,In.Profiler=i,In.StrictMode=n,In.Suspense=c,In.SuspenseList=u,In.isAsyncMode=function(){return!1},In.isConcurrentMode=function(){return!1},In.isContextConsumer=function(m){return g(m)===s},In.isContextProvider=function(m){return g(m)===o},In.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},In.isForwardRef=function(m){return g(m)===l},In.isFragment=function(m){return g(m)===r},In.isLazy=function(m){return g(m)===h},In.isMemo=function(m){return g(m)===d},In.isPortal=function(m){return g(m)===t},In.isProfiler=function(m){return g(m)===i},In.isStrictMode=function(m){return g(m)===n},In.isSuspense=function(m){return g(m)===c},In.isSuspenseList=function(m){return g(m)===u},In.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===i||m===n||m===c||m===u||m===p||typeof m=="object"&&m!==null&&(m.$$typeof===h||m.$$typeof===d||m.$$typeof===o||m.$$typeof===s||m.$$typeof===l||m.$$typeof===f||m.getModuleId!==void 0)},In.typeOf=g,In}var Tj;function tIe(){return Tj||(Tj=1,w_.exports=eIe()),w_.exports}var x_=tIe();function Pm(e,t,r){const n=y.useRef({});return(!("value"in n.current)||r(n.current.condition,t))&&(n.current.value=e(),n.current.condition=t),n.current.value}const rIe=Symbol.for("react.element"),nIe=Symbol.for("react.transitional.element"),iIe=Symbol.for("react.fragment");function Hse(e){return e&&typeof e=="object"&&(e.$$typeof===rIe||e.$$typeof===nIe)&&e.type===iIe}const oIe=Number(y.version.split(".")[0]),rB=(e,t)=>{typeof e=="function"?e(t):typeof e=="object"&&e&&"current"in e&&(e.current=t)},Wo=(...e)=>{const t=e.filter(Boolean);return t.length<=1?t[0]:r=>{e.forEach(n=>{rB(n,r)})}},Pu=(...e)=>Pm(()=>Wo(...e),e,(t,r)=>t.length!==r.length||t.every((n,i)=>n!==r[i])),pu=e=>{var r,n;if(!e)return!1;if(C3(e)&&oIe>=19)return!0;const t=x_.isMemo(e)?e.type.type:e.type;return!(typeof t=="function"&&!((r=t.prototype)!=null&&r.render)&&t.$$typeof!==x_.ForwardRef||typeof e=="function"&&!((n=e.prototype)!=null&&n.render)&&e.$$typeof!==x_.ForwardRef)};function C3(e){return y.isValidElement(e)&&!Hse(e)}const sIe=e=>C3(e)&&pu(e),jd=e=>{if(e&&C3(e)){const t=e;return t.props.propertyIsEnumerable("ref")?t.props.ref:t.ref}return null};function Zs(e,t){let r=e;for(let n=0;n"u"?Object.keys:Reflect.ownKeys;function Use(e,t={}){const{prepareArray:r}=t,n=r||(()=>[]);let i=Rj(e[0]);return e.forEach(o=>{function s(a,l){const c=new Set(l),u=Zs(o,a),d=Array.isArray(u);if(d||aIe(u)){if(!c.has(u)){c.add(u);const h=Zs(i,a);d?i=sl(i,a,n(h,u)):(!h||typeof h!="object")&&(i=sl(i,a,Rj(u))),lIe(u).forEach(p=>{Object.getOwnPropertyDescriptor(u,p).enumerable&&s([...a,p],c)})}}else i=sl(i,a,u)}s([])}),i}function ry(...e){return Use(e)}let nB={};const cIe=e=>{};function uIe(e,t){}function dIe(e,t){}function hIe(){nB={}}function jse(e,t,r){!t&&!nB[r]&&(e(!1,r),nB[r]=!0)}function Vn(e,t){jse(uIe,e,t)}function pIe(e,t){jse(dIe,e,t)}Vn.preMessage=cIe;Vn.resetWarned=hIe;Vn.noteOnce=pIe;function fn(e,t){const r=Object.assign({},e);return Array.isArray(t)&&t.forEach(n=>{delete r[n]}),r}function Li(e,t={}){let r=[];return Z.Children.forEach(e,n=>{n==null&&!t.keepEmpty||(Array.isArray(n)?r=r.concat(Li(n)):Hse(n)&&n.props?r=r.concat(Li(n.props.children,t)):r.push(n))}),r}function fIe(){}const gIe=y.createContext({}),MC=()=>{const e=()=>{};return e.deprecated=fIe,e};function By(e){return e instanceof HTMLElement||e instanceof SVGElement}function pc(e){return e&&typeof e=="object"&&By(e.nativeElement)?e.nativeElement:By(e)?e:null}const iB=y.createContext(null);function mIe({children:e,onBatchResize:t}){const r=y.useRef(0),n=y.useRef([]),i=y.useContext(iB),o=y.useCallback((s,a,l)=>{r.current+=1;const c=r.current;n.current.push({size:s,element:a,data:l}),Promise.resolve().then(()=>{c===r.current&&(t==null||t(n.current),n.current=[])}),i==null||i(s,a,l)},[t,i]);return y.createElement(iB.Provider,{value:o},e)}const ep=new Map;function vIe(e){e.forEach(t=>{var n;const{target:r}=t;(n=ep.get(r))==null||n.forEach(i=>i(r))})}let E_;function Kse(){return E_||(E_=new ResizeObserver(vIe)),E_}function yIe(e,t){ep.has(e)||(ep.set(e,new Set),Kse().observe(e)),ep.get(e).add(t)}function CIe(e,t){ep.has(e)&&(ep.get(e).delete(t),ep.get(e).size||(Kse().unobserve(e),ep.delete(e)))}function qse(e,t,r,n){const i=y.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),o=br(a=>{const{width:l,height:c}=a.getBoundingClientRect(),{offsetWidth:u,offsetHeight:d}=a,h=Math.floor(l),p=Math.floor(c);if(i.current.width!==h||i.current.height!==p||i.current.offsetWidth!==u||i.current.offsetHeight!==d){const f={width:h,height:p,offsetWidth:u,offsetHeight:d};i.current=f;const g=u===Math.round(l)?l:u,m=d===Math.round(c)?c:d,v={...f,offsetWidth:g,offsetHeight:m};n==null||n(v,a),Promise.resolve().then(()=>{r==null||r(v,a)})}}),s=typeof t=="function";y.useEffect(()=>{const a=s?t():t;return a&&e&&yIe(a,o),()=>{a&&CIe(a,o)}},[e,s?0:t])}function bIe(e,t){const{children:r,disabled:n,onResize:i,data:o}=e,s=y.useRef(null),a=y.useContext(iB),l=typeof r=="function",c=l?r(s):r,u=!l&&y.isValidElement(c)&&pu(c),d=u?jd(c):null,h=Pu(d,s),p=()=>pc(s.current);return y.useImperativeHandle(t,()=>p()),qse(!n,p,i,(f,g)=>{a==null||a(f,g,o)}),u?y.cloneElement(c,{ref:h}):c}const SIe=y.forwardRef(bIe);function oB(){return oB=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const s=(i==null?void 0:i.key)||`${wIe}-${o}`;return y.createElement(SIe,oB({},e,{key:s,ref:o===0?t:void 0}),i)})}const ta=y.forwardRef(xIe);ta.Collection=mIe;function Xse(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;te.length)&&(t=e.length);for(var r=0,n=Array(t);r+setTimeout(e,16),Qse=e=>clearTimeout(e);typeof window<"u"&&"requestAnimationFrame"in window&&(Zse=e=>window.requestAnimationFrame(e),Qse=e=>window.cancelAnimationFrame(e));let Pj=0;const b3=new Map;function Jse(e){b3.delete(e)}const Or=(e,t=1)=>{Pj+=1;const r=Pj;function n(i){if(i===0)Jse(r),e();else{const o=Zse(()=>{n(i-1)});b3.set(r,o)}}return n(t),r};Or.cancel=e=>{const t=b3.get(e);return Jse(e),Qse(t)};function PIe(e){let t=null;const r=i=>()=>{t=null,e.apply(void 0,Pr(i))},n=(...i)=>{t===null&&(t=Or(r(i)))};return n.cancel=()=>{Or.cancel(t),t=null},n}const y0="ant",LD="anticon",MIe=["outlined","borderless","filled","underlined"],IIe=(e,t)=>t||(e?`${y0}-${e}`:y0),ir=y.createContext({getPrefixCls:IIe,iconPrefixCls:LD}),{Consumer:_Bt}=ir,Mj={};function Nr(e){const t=y.useContext(ir),{getPrefixCls:r,direction:n,getPopupContainer:i,renderEmpty:o}=t,s=t[e];return{classNames:Mj,styles:Mj,...s,getPrefixCls:r,direction:n,getPopupContainer:i,renderEmpty:o}}function C0(e){for(var t=0,r,n=0,i=e.length;i>=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}function aB(e,t){if(!e)return!1;if(e.contains)return e.contains(t);let r=t;for(;r;){if(r===e)return!0;r=r.parentNode}return!1}const Ij="data-rc-order",Dj="data-rc-priority",DIe="rc-util-key",lB=new Map;function eae({mark:e}={}){return e?e.startsWith("data-")?e:`data-${e}`:DIe}function _D(e){return e.attachTo?e.attachTo:document.querySelector("head")||document.body}function AIe(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function S3(e){return Array.from((lB.get(e)||e).children).filter(t=>t.tagName==="STYLE")}function tae(e,t={}){if(!To())return null;const{csp:r,prepend:n,priority:i=0}=t,o=AIe(n),s=o==="prependQueue",a=document.createElement("style");a.setAttribute(Ij,o),s&&i&&a.setAttribute(Dj,`${i}`),r!=null&&r.nonce&&(a.nonce=r==null?void 0:r.nonce),a.innerHTML=e;const l=_D(t),{firstChild:c}=l;if(n){if(s){const u=(t.styles||S3(l)).filter(d=>{if(!["prepend","prependQueue"].includes(d.getAttribute(Ij)))return!1;const h=Number(d.getAttribute(Dj)||0);return i>=h});if(u.length)return l.insertBefore(a,u[u.length-1].nextSibling),a}l.insertBefore(a,c)}else l.appendChild(a);return a}function rae(e,t={}){let{styles:r}=t;return r||(r=S3(_D(t))),r.find(n=>n.getAttribute(eae(t))===e)}function b0(e,t={}){const r=rae(e,t);r&&_D(t).removeChild(r)}function FIe(e,t){const r=lB.get(e);if(!r||!aB(document,r)){const n=tae("",t),{parentNode:i}=n;lB.set(e,i),e.removeChild(n)}}function hp(e,t,r={}){var l,c,u;const n=_D(r),i=S3(n),o={...r,styles:i};FIe(n,o);const s=rae(t,o);if(s)return(l=o.csp)!=null&&l.nonce&&s.nonce!==((c=o.csp)==null?void 0:c.nonce)&&(s.nonce=(u=o.csp)==null?void 0:u.nonce),s.innerHTML!==e&&(s.innerHTML=e),s;const a=tae(e,o);return a.setAttribute(eae(o),t),a}function fc(e,t,r=!1){const n=new Set;function i(o,s,a=1){const l=n.has(o);if(Vn(!l,"Warning: There may be circular references"),l)return!1;if(o===s)return!0;if(r&&a>1)return!1;n.add(o);const c=a+1;if(Array.isArray(o)){if(!Array.isArray(s)||o.length!==s.length)return!1;for(let u=0;ui(o[d],s[d],c))}return!1}return i(e,t)}const LIe="%";function cB(e){return e.join(LIe)}let Aj=0;class _Ie{constructor(t){Ie(this,"instanceId");Ie(this,"cache",new Map);Ie(this,"updateTimes",new Map);Ie(this,"extracted",new Set);this.instanceId=t}get(t){return this.opGet(cB(t))}opGet(t){return this.cache.get(t)||null}update(t,r){return this.opUpdate(cB(t),r)}opUpdate(t,r){const n=this.cache.get(t),i=r(n);i===null?(this.cache.delete(t),this.updateTimes.delete(t)):(this.cache.set(t,i),this.updateTimes.set(t,Aj),Aj+=1)}}const w3="data-token-hash",Cd="data-css-hash",sd="__cssinjs_instance__";function OIe(){const e=Math.random().toString(12).slice(2);if(typeof document<"u"&&document.head&&document.body){const t=document.body.querySelectorAll(`style[${Cd}]`)||[],{firstChild:r}=document.head;Array.from(t).forEach(i=>{i[sd]||(i[sd]=e),i[sd]===e&&document.head.insertBefore(i,r)});const n={};Array.from(document.querySelectorAll(`style[${Cd}]`)).forEach(i=>{var s;const o=i.getAttribute(Cd);n[o]?i[sd]===e&&((s=i.parentNode)==null||s.removeChild(i)):n[o]=!0})}return new _Ie(e)}const Mx=y.createContext({hashPriority:"low",cache:OIe(),defaultCache:!0,autoPrefix:!1});function kIe(e,t){if(e.length!==t.length)return!1;for(let r=0;r{var o;n?n=(o=n==null?void 0:n.map)==null?void 0:o.get(i):n=void 0}),n!=null&&n.value&&r&&(n.value[1]=this.cacheCallTimes++),n==null?void 0:n.value}get(t){var r;return(r=this.internalGet(t,!0))==null?void 0:r[0]}has(t){return!!this.internalGet(t)}set(t,r){if(!this.has(t)){if(this.size()+1>vy.MAX_CACHE_SIZE+vy.MAX_CACHE_OFFSET){const[i]=this.keys.reduce((o,s)=>{const[,a]=o;return this.internalGet(s)[1]{if(o===t.length-1)n.set(i,{value:[r,this.cacheCallTimes++]});else{const s=n.get(i);s?s.map||(s.map=new Map):n.set(i,{map:new Map}),n=n.get(i).map}})}deleteByPath(t,r){var o;const n=t.get(r[0]);if(r.length===1)return n.map?t.set(r[0],{map:n.map}):t.delete(r[0]),(o=n.value)==null?void 0:o[0];const i=this.deleteByPath(n.map,r.slice(1));return(!n.map||n.map.size===0)&&!n.value&&t.delete(r[0]),i}delete(t){if(this.has(t))return this.keys=this.keys.filter(r=>!kIe(r,t)),this.deleteByPath(this.cache,t)}};Ie(vy,"MAX_CACHE_SIZE",20),Ie(vy,"MAX_CACHE_OFFSET",5);let uB=vy,Fj=0;class nae{constructor(t){Ie(this,"derivatives");Ie(this,"id");this.derivatives=Array.isArray(t)?t:[t],this.id=Fj,t.length===0&&(t.length>0,void 0),Fj+=1}getDerivativeToken(t){return this.derivatives.reduce((r,n)=>n(t,r),void 0)}}const T_=new uB;function dB(e){const t=Array.isArray(e)?e:[e];return T_.has(t)||T_.set(t,new nae(t)),T_.get(t)}const NIe=new WeakMap,R_={};function BIe(e,t){let r=NIe;for(let n=0;n{const n=e[r];t+=r,n instanceof nae?t+=n.id:n&&typeof n=="object"?t+=Rw(n):t+=n}),t=C0(t),Lj.set(e,t)),t}function $Ie(e,t){return C0(`${t}_${Rw(e)}`)}const hB=To();function ae(e){return typeof e=="number"?`${e}px`:e}function iae(e){const{hashCls:t,hashPriority:r="low"}=e||{};if(!t)return"";const n=`.${t}`;return r==="low"?`:where(${n})`:n}const GIe=e=>e!=null;function x3(e,t){const r=typeof t=="function"?t():t;return r?{...e,csp:{...e.csp,nonce:r}}:e}const oP=(e,t="")=>`--${t?`${t}-`:""}${e}`.replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g,"$1-$2").replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase(),VIe=(e,t,r)=>{const{hashCls:n,hashPriority:i="low",scope:o}=r||{};if(!Object.keys(e).length)return"";const s=`${iae({hashCls:n,hashPriority:i})}.${t}`,a=[o].flat().filter(Boolean);return`${a.length?a.map(c=>`${s}.${c}`).join(", "):s}{${Object.entries(e).map(([c,u])=>`${c}:${u};`).join("")}}`},oae=(e,t,r)=>{const{hashCls:n,hashPriority:i="low",prefix:o,unitless:s,ignore:a,preserve:l}=r||{},c={},u={};return Object.entries(e).forEach(([d,h])=>{if(l!=null&&l[d])u[d]=h;else if((typeof h=="string"||typeof h=="number")&&!(a!=null&&a[d])){const p=oP(d,o);c[p]=typeof h=="number"&&!(s!=null&&s[d])?`${h}px`:String(h),u[d]=`var(${p})`}}),[u,VIe(c,t,{scope:r==null?void 0:r.scope,hashCls:n,hashPriority:i})]},jE=new Map;function E3(e,t,r,n,i){const{cache:o}=y.useContext(Mx),s=[e,...t],a=cB(s),l=d=>{o.opUpdate(a,h=>{const[p=0,f]=h||[void 0,void 0],m=f||r(),v=[p,m];return d?d(v):v})};y.useMemo(()=>{l()},[a]);const u=o.opGet(a)[1];return y.useInsertionEffect(()=>(l(([d,h])=>[d+1,h]),jE.has(a)||(i==null||i(u),jE.set(a,!0),Promise.resolve().then(()=>{jE.delete(a)})),()=>{o.opUpdate(a,d=>{const[h=0,p]=d||[];return h-1===0?(n==null||n(p,!1),jE.delete(a),null):[h-1,p]})}),[a]),u}const zIe={},HIe="css",og=new Map;function WIe(e){og.set(e,(og.get(e)||0)+1)}function UIe(e,t){typeof document<"u"&&document.querySelectorAll(`style[${w3}="${e}"]`).forEach(n=>{var i;n[sd]===t&&((i=n.parentNode)==null||i.removeChild(n))})}const jIe=-1;function KIe(e,t){og.set(e,(og.get(e)||0)-1);const r=new Set;og.forEach((n,i)=>{n<=0&&r.add(i)}),og.size-r.size>jIe&&r.forEach(n=>{UIe(n,t),og.delete(n)})}const qIe=(e,t,r,n)=>{let o={...r.getDerivativeToken(e),...t};return n&&(o=n(o)),o},XIe="token";function YIe(e,t,r){const{cache:{instanceId:n},container:i,hashPriority:o}=y.useContext(Mx),{salt:s="",override:a=zIe,formatToken:l,getComputedToken:c,cssVar:u,nonce:d}=r,h=BIe(()=>Object.assign({},...t),t),p=Rw(h),f=Rw(a),g=Rw(u);return E3(XIe,[s,e.id,p,f,g],()=>{const v=c?c(h,a,e):qIe(h,a,e,l),b={...v},S=`${s}_${u.prefix}`,x=C0(S),E=`${HIe}-${x}`;b._tokenKey=$Ie(b,S);const[R,T]=oae(v,u.key,{prefix:u.prefix,ignore:u.ignore,unitless:u.unitless,preserve:u.preserve,hashPriority:o,hashCls:u.hashed?E:void 0});return R._hashId=x,WIe(u.key),[R,E,b,T,u.key]},([,,,,v])=>{KIe(v,n)},([,,,v,b])=>{if(!v)return;let S={mark:Cd,prepend:"queue",attachTo:i,priority:-999};S=x3(S,d);const x=hp(v,C0(`css-var-${b}`),S);x[sd]=n,x.setAttribute(w3,b)})}var ZIe={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Yn="-ms-",Pw="-moz-",xn="-webkit-",sae="comm",T3="rule",R3="decl",QIe="@import",JIe="@namespace",aae="@keyframes",eDe="@layer",lae=Math.abs,P3=String.fromCharCode,pB=Object.assign;function tDe(e,t){return to(e,0)^45?(((t<<2^to(e,0))<<2^to(e,1))<<2^to(e,2))<<2^to(e,3):0}function cae(e){return e.trim()}function td(e,t){return(e=t.exec(e))?e[0]:e}function Zr(e,t,r){return e.replace(t,r)}function sP(e,t,r){return e.indexOf(t,r)}function to(e,t){return e.charCodeAt(t)|0}function em(e,t,r){return e.slice(t,r)}function Zl(e){return e.length}function uae(e){return e.length}function ew(e,t){return t.push(e),e}function rDe(e,t){return e.map(t).join("")}function _j(e,t){return e.filter(function(r){return!td(r,t)})}var OD=1,$y=1,dae=0,Sl=0,Wi=0,IC="";function kD(e,t,r,n,i,o,s,a){return{value:e,root:t,parent:r,type:n,props:i,children:o,line:OD,column:$y,length:s,return:"",siblings:a}}function _h(e,t){return pB(kD("",null,null,"",null,null,0,e.siblings),e,{length:-e.length},t)}function uv(e){for(;e.root;)e=_h(e.root,{children:[e]});ew(e,e.siblings)}function nDe(){return Wi}function iDe(){return Wi=Sl>0?to(IC,--Sl):0,$y--,Wi===10&&($y=1,OD--),Wi}function oc(){return Wi=Sl2||S0(Wi)>3?"":" "}function lDe(e,t){for(;--t&&oc()&&!(Wi<48||Wi>102||Wi>57&&Wi<65||Wi>70&&Wi<97););return ND(e,aP()+(t<6&&tp()==32&&oc()==32))}function fB(e){for(;oc();)switch(Wi){case e:return Sl;case 34:case 39:e!==34&&e!==39&&fB(Wi);break;case 40:e===41&&fB(e);break;case 92:oc();break}return Sl}function cDe(e,t){for(;oc()&&e+Wi!==57;)if(e+Wi===84&&tp()===47)break;return"/*"+ND(t,Sl-1)+"*"+P3(e===47?e:oc())}function uDe(e){for(;!S0(tp());)oc();return ND(e,Sl)}function Oj(e){return sDe(lP("",null,null,null,[""],e=oDe(e),0,[0],e))}function lP(e,t,r,n,i,o,s,a,l){for(var c=0,u=0,d=s,h=0,p=0,f=0,g=1,m=1,v=1,b=0,S="",x=i,E=o,R=n,T=S;m;)switch(f=b,b=oc()){case 40:if(f!=108&&to(T,d-1)==58){sP(T+=Zr(P_(b),"&","&\f"),"&\f",lae(c?a[c-1]:0))!=-1&&(v=-1);break}case 34:case 39:case 91:T+=P_(b);break;case 9:case 10:case 13:case 32:T+=aDe(f);break;case 92:T+=lDe(aP()-1,7);continue;case 47:switch(tp()){case 42:case 47:ew(dDe(cDe(oc(),aP()),t,r,l),l),(S0(f||1)==5||S0(tp()||1)==5)&&Zl(T)&&em(T,-1,void 0)!==" "&&(T+=" ");break;default:T+="/"}break;case 123*g:a[c++]=Zl(T)*v;case 125*g:case 59:case 0:switch(b){case 0:case 125:m=0;case 59+u:v==-1&&(T=Zr(T,/\f/g,"")),p>0&&(Zl(T)-d||g===0&&f===47)&&ew(p>32?Nj(T+";",n,r,d-1,l):Nj(Zr(T," ","")+";",n,r,d-2,l),l);break;case 59:T+=";";default:if(ew(R=kj(T,t,r,c,u,i,a,S,x=[],E=[],d,o),o),b===123)if(u===0)lP(T,t,R,R,x,o,d,a,E);else{switch(h){case 99:if(to(T,3)===110)break;case 108:if(to(T,2)===97)break;default:u=0;case 100:case 109:case 115:}u?lP(e,R,R,n&&ew(kj(e,R,R,0,0,i,a,S,i,x=[],d,E),E),i,E,d,a,n?x:E):lP(T,R,R,R,[""],E,0,a,E)}}c=u=p=0,g=v=1,S=T="",d=s;break;case 58:d=1+Zl(T),p=f;default:if(g<1){if(b==123)--g;else if(b==125&&g++==0&&iDe()==125)continue}switch(T+=P3(b),b*g){case 38:v=u>0?1:(T+="\f",-1);break;case 44:a[c++]=(Zl(T)-1)*v,v=1;break;case 64:tp()===45&&(T+=P_(oc())),h=tp(),u=d=Zl(S=T+=uDe(aP())),b++;break;case 45:f===45&&Zl(T)==2&&(g=0)}}return o}function kj(e,t,r,n,i,o,s,a,l,c,u,d){for(var h=i-1,p=i===0?o:[""],f=uae(p),g=0,m=0,v=0;g0?p[b]+" "+S:Zr(S,/&\f/g,p[b])))&&(l[v++]=x);return kD(e,t,r,i===0?T3:a,l,c,u,d)}function dDe(e,t,r,n){return kD(e,t,r,sae,P3(nDe()),em(e,2,-2),0,n)}function Nj(e,t,r,n,i){return kD(e,t,r,R3,em(e,0,n),em(e,n+1,-1),n,i)}function hae(e,t,r){switch(tDe(e,t)){case 5103:return xn+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:case 6391:case 5879:case 5623:case 6135:case 4599:return xn+e+e;case 4855:return xn+e.replace("add","source-over").replace("substract","source-out").replace("intersect","source-in").replace("exclude","xor")+e;case 4789:return Pw+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return xn+e+Pw+e+Yn+e+e;case 5936:switch(to(e,t+11)){case 114:return xn+e+Yn+Zr(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return xn+e+Yn+Zr(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return xn+e+Yn+Zr(e,/[svh]\w+-[tblr]{2}/,"lr")+e}case 6828:case 4268:case 2903:return xn+e+Yn+e+e;case 6165:return xn+e+Yn+"flex-"+e+e;case 5187:return xn+e+Zr(e,/(\w+).+(:[^]+)/,xn+"box-$1$2"+Yn+"flex-$1$2")+e;case 5443:return xn+e+Yn+"flex-item-"+Zr(e,/flex-|-self/g,"")+(td(e,/flex-|baseline/)?"":Yn+"grid-row-"+Zr(e,/flex-|-self/g,""))+e;case 4675:return xn+e+Yn+"flex-line-pack"+Zr(e,/align-content|flex-|-self/g,"")+e;case 5548:return xn+e+Yn+Zr(e,"shrink","negative")+e;case 5292:return xn+e+Yn+Zr(e,"basis","preferred-size")+e;case 6060:return xn+"box-"+Zr(e,"-grow","")+xn+e+Yn+Zr(e,"grow","positive")+e;case 4554:return xn+Zr(e,/([^-])(transform)/g,"$1"+xn+"$2")+e;case 6187:return Zr(Zr(Zr(e,/(zoom-|grab)/,xn+"$1"),/(image-set)/,xn+"$1"),e,"")+e;case 5495:case 3959:return Zr(e,/(image-set\([^]*)/,xn+"$1$`$1");case 4968:return Zr(Zr(e,/(.+:)(flex-)?(.*)/,xn+"box-pack:$3"+Yn+"flex-pack:$3"),/space-between/,"justify")+xn+e+e;case 4200:if(!td(e,/flex-|baseline/))return Yn+"grid-column-align"+em(e,t)+e;break;case 2592:case 3360:return Yn+Zr(e,"template-","")+e;case 4384:case 3616:return r&&r.some(function(n,i){return t=i,td(n.props,/grid-\w+-end/)})?~sP(e+(r=r[t].value),"span",0)?e:Yn+Zr(e,"-start","")+e+Yn+"grid-row-span:"+(~sP(r,"span",0)?td(r,/\d+/):+td(r,/\d+/)-+td(e,/\d+/))+";":Yn+Zr(e,"-start","")+e;case 4896:case 4128:return r&&r.some(function(n){return td(n.props,/grid-\w+-start/)})?e:Yn+Zr(Zr(e,"-end","-span"),"span ","")+e;case 4095:case 3583:case 4068:case 2532:return Zr(e,/(.+)-inline(.+)/,xn+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Zl(e)-1-t>6)switch(to(e,t+1)){case 109:if(to(e,t+4)!==45)break;case 102:return Zr(e,/(.+:)(.+)-([^]+)/,"$1"+xn+"$2-$3$1"+Pw+(to(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~sP(e,"stretch",0)?hae(Zr(e,"stretch","fill-available"),t,r)+e:e}break;case 5152:case 5920:return Zr(e,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,i,o,s,a,l,c){return Yn+i+":"+o+c+(s?Yn+i+"-span:"+(a?l:+l-+o)+c:"")+e});case 4949:if(to(e,t+6)===121)return Zr(e,":",":"+xn)+e;break;case 6444:switch(to(e,to(e,14)===45?18:11)){case 120:return Zr(e,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+xn+(to(e,14)===45?"inline-":"")+"box$3$1"+xn+"$2$3$1"+Yn+"$2box$3")+e;case 100:return Zr(e,":",":"+Yn)+e}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Zr(e,"scroll-","scroll-snap-")+e}return e}function w0(e,t){for(var r="",n=0;n-1&&!e.return)switch(e.type){case R3:e.return=hae(e.value,e.length,r);return;case aae:return w0([_h(e,{value:Zr(e.value,"@","@"+xn)})],n);case T3:if(e.length)return rDe(r=e.props,function(i){switch(td(i,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":uv(_h(e,{props:[Zr(i,/:(read-\w+)/,":"+Pw+"$1")]})),uv(_h(e,{props:[i]})),pB(e,{props:_j(r,n)});break;case"::placeholder":uv(_h(e,{props:[Zr(i,/:(plac\w+)/,":"+xn+"input-$1")]})),uv(_h(e,{props:[Zr(i,/:(plac\w+)/,":"+Pw+"$1")]})),uv(_h(e,{props:[Zr(i,/:(plac\w+)/,Yn+"input-$1")]})),uv(_h(e,{props:[i]})),pB(e,{props:_j(r,n)});break}return""})}}const $j="data-ant-cssinjs-cache-path",pae="_FILE_STYLE__";let _g,fae=!0;function fDe(){var e;if(!_g&&(_g={},To())){const t=document.createElement("div");t.className=$j,t.style.position="fixed",t.style.visibility="hidden",t.style.top="-9999px",document.body.appendChild(t);let r=getComputedStyle(t).content||"";r=r.replace(/^"/,"").replace(/"$/,""),r.split(";").forEach(i=>{const[o,s]=i.split(":");_g[o]=s});const n=document.querySelector(`style[${$j}]`);n&&(fae=!1,(e=n.parentNode)==null||e.removeChild(n)),document.body.removeChild(t)}}function gDe(e){return fDe(),!!_g[e]}function mDe(e){const t=_g[e];let r=null;if(t&&To())if(fae)r=pae;else{const n=document.querySelector(`style[${Cd}="${_g[e]}"]`);n?r=n.innerHTML:delete _g[e]}return[r,t]}const vDe="_skip_check_",gae="_multi_value_";function M_(e,t){return(t?w0(Oj(e),hDe([pDe,Bj])):w0(Oj(e),Bj)).replace(/\{%%%\:[^;];}/g,";")}function yDe(e){return typeof e=="object"&&e&&(vDe in e||gae in e)}function Gj(e,t,r="high"){if(!t)return e;const n=iae({hashCls:t,hashPriority:r});return e.split(",").map(o=>{var c;const s=o.trim().split(/\s+/);let a=s[0]||"";const l=((c=a.match(/^\w+/))==null?void 0:c[0])||"";return a=`${l}${n}${a.slice(l.length)}`,[a,...s.slice(1)].join(" ")}).join(",")}const gB=(e,t={},{root:r,injectHash:n,parentSelectors:i}={root:!0,parentSelectors:[]})=>{const{hashId:o,layer:s,path:a,hashPriority:l,transformers:c=[],linters:u=[]}=t;let d="",h={};function p(m){const v=m.getName(o);if(!h[v]){const[b]=gB(m.style,t,{root:!1,parentSelectors:i});h[v]=`@keyframes ${m.getName(o)}${b}`}}function f(m,v=[]){return m.forEach(b=>{Array.isArray(b)?f(b,v):b&&v.push(b)}),v}return f(Array.isArray(e)?e:[e]).forEach(m=>{const v=typeof m=="string"&&!r?{}:m;if(typeof v=="string")d+=`${v} `;else if(v._keyframe)p(v);else{const b=c.reduce((S,x)=>{var E;return((E=x==null?void 0:x.visit)==null?void 0:E.call(x,S))||S},v);Object.keys(b).forEach(S=>{const x=b[S];if(typeof x=="object"&&x&&(S!=="animationName"||!x._keyframe)&&!yDe(x)){let E=!1,R=S.trim(),T=!1;(r||n)&&o?R.startsWith("@")?E=!0:R==="&"?R=Gj("",o,l):R=Gj(S,o,l):r&&!o&&(R==="&"||R==="")&&(R="",T=!0);const[M,D]=gB(x,t,{root:T,injectHash:E,parentSelectors:[...i,R]});h={...h,...D},d+=`${R}${M}`}else{let E=function(T,M){const D=T.replace(/[A-Z]/g,I=>`-${I.toLowerCase()}`);let A=M;!ZIe[T]&&typeof A=="number"&&A!==0&&(A=`${A}px`),T==="animationName"&&(M!=null&&M._keyframe)&&(p(M),A=M.getName(o)),d+=`${D}:${A};`};const R=(x==null?void 0:x.value)??x;typeof x=="object"&&(x!=null&&x[gae])&&Array.isArray(R)?R.forEach(T=>{E(S,T)}):GIe(R)&&E(S,R)}})}}),r?s&&(d&&(d=`@layer ${s.name} {${d}}`),s.dependencies&&(h[`@layer ${s.name}`]=s.dependencies.map(m=>`@layer ${m}, ${s.name};`).join(` `))):d=`{${d}}`,[d,h]};function mae(e,t){return C0(`${e.join("%")}${t}`)}const CDe="style";function mB(e,t){const{path:r,hashId:n,layer:i,nonce:o,clientOnly:s,order:a=0}=e,{mock:l,hashPriority:c,container:u,transformers:d,linters:h,cache:p,layer:f,autoPrefix:g}=y.useContext(Mx),m=[n||""];f&&m.push("layer"),m.push(...r);let v=hB;E3(CDe,m,()=>{const b=m.join("|");if(gDe(b)){const[M,D]=mDe(b);if(M)return[M,D,{},s,a]}const S=t(),[x,E]=gB(S,{hashId:n,hashPriority:c,layer:f?i:void 0,path:r.join("-"),transformers:d,linters:h}),R=M_(x,g||!1),T=mae(m,R);return[R,T,E,s,a]},(b,S)=>{const[,x]=b;S&&hB&&b0(x,{mark:Cd,attachTo:u})},b=>{const[S,x,E,,R]=b;if(v&&S!==pae){let T={mark:Cd,prepend:f?!1:"queue",attachTo:u,priority:R};T=x3(T,o);const M=[],D=[];Object.keys(E).forEach(I=>{I.startsWith("@layer")?M.push(I):D.push(I)}),M.forEach(I=>{hp(M_(E[I],g||!1),`_layer-${I}`,{...T,prepend:!0})});const A=hp(S,x,T);A[sd]=p.instanceId,D.forEach(I=>{hp(M_(E[I],g||!1),`_effect-${I}`,T)})}})}const bDe="cssVar",SDe=(e,t)=>{const{key:r,prefix:n,unitless:i,ignore:o,token:s,hashId:a,scope:l,nonce:c}=e,{cache:{instanceId:u},container:d,hashPriority:h}=y.useContext(Mx),{_tokenKey:p}=s,f=Array.isArray(l)?l.join("@@"):l,g=[...e.path,r,f,p];return E3(bDe,g,()=>{const v=t(),[b,S]=oae(v,r,{prefix:n,unitless:i,ignore:o,scope:l,hashPriority:h,hashCls:a}),x=mae(g,S);return[b,S,x,r]},([,,v])=>{hB&&b0(v,{mark:Cd,attachTo:d})},([,v,b])=>{if(!v)return;let S={mark:Cd,prepend:"queue",attachTo:d,priority:-999};S=x3(S,c);const x=hp(v,b,S);x[sd]=u,x.setAttribute(w3,r)})};class qr{constructor(t,r){Ie(this,"name");Ie(this,"style");Ie(this,"_keyframe",!0);this.name=t,this.style=r}getName(t=""){return t?`${t}-${this.name}`:this.name}}function dv(e){return e.notSplit=!0,e}dv(["borderTop","borderBottom"]),dv(["borderTop"]),dv(["borderBottom"]),dv(["borderLeft","borderRight"]),dv(["borderLeft"]),dv(["borderRight"]);function Ui(e){"@babel/helpers - typeof";return Ui=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ui(e)}function wDe(e){if(Array.isArray(e))return e}function xDe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function EDe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vae(e,t){return wDe(e)||xDe(e,t)||Yse(e,t)||EDe()}function TDe(e,t){if(Ui(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Ui(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function yae(e){var t=TDe(e,"string");return Ui(t)=="symbol"?t:t+""}function Bn(e,t,r){return(t=yae(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Vj(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ci(e){for(var t=1;t1e4){var n=Date.now();this.lastAccessBeat.forEach(function(i,o){n-i>_De&&(r.map.delete(o),r.lastAccessBeat.delete(o))}),this.accessBeat=0}}}]),e})(),jj=new ODe;function kDe(e,t){return Z.useMemo(function(){var r=jj.get(t);if(r)return r;var n=e();return jj.set(t,n),n},t)}var NDe=function(){return{}};function BDe(e){var t=e.useCSP,r=t===void 0?NDe:t,n=e.useToken,i=e.usePrefix,o=e.getResetStyles,s=e.getCommonStyle,a=e.getCompUnitless;function l(h,p,f,g){var m=Array.isArray(h)?h[0]:h;function v(M){return"".concat(String(m)).concat(M.slice(0,1).toUpperCase()).concat(M.slice(1))}var b=(g==null?void 0:g.unitless)||{},S=typeof a=="function"?a(h):{},x=Ci(Ci({},S),{},Bn({},v("zIndexPopup"),!0));Object.keys(b).forEach(function(M){x[v(M)]=b[M]});var E=Ci(Ci({},g),{},{unitless:x,prefixToken:v}),R=u(h,p,f,E),T=c(m,f,E);return function(M){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:M,A=R(M,D),I=g==null?void 0:g.extraCssVarPrefixCls,L=typeof I=="function"?I({prefixCls:M,rootCls:D}):I,F=T(L!=null&&L.length?[D].concat(Pr(L)):D);return[A,F]}}function c(h,p,f){var g=f.unitless,m=f.prefixToken,v=f.ignore;return function(b){var S=n(),x=S.cssVar,E=S.realToken,R=r();return SDe({path:[h],prefix:x.prefix,key:x.key,unitless:g,ignore:v,token:E,scope:b,nonce:function(){return R.nonce}},function(){var T=Uj(h,E,p),M=Hj(h,E,T,{deprecatedTokens:f==null?void 0:f.deprecatedTokens});return T&&Object.keys(T).forEach(function(D){M[m(D)]=M[D],delete M[D]}),M}),x==null?void 0:x.key}}function u(h,p,f){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},m=Array.isArray(h)?h:[h,h],v=vae(m,1),b=v[0],S=m.join("-"),x=e.layer||{name:"antd"};return function(E){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:E,T=n(),M=T.theme,D=T.realToken,A=T.hashId,I=T.token,L=T.cssVar,F=T.zeroRuntime,k=y.useMemo(function(){return F},[]);if(k)return A;var O=i(),B=O.rootPrefixCls,H=O.iconPrefixCls,N=r(),z="css",W=kDe(function(){var X=new Set;return Object.keys(g.unitless||{}).forEach(function(Y){X.add(oP(Y,L.prefix)),X.add(oP(Y,zj(b,L.prefix)))}),DDe(z,X)},[z,b,L==null?void 0:L.prefix]),V=LDe(),$=V.max,K=V.min,q={theme:M,token:I,hashId:A,nonce:function(){return N.nonce},clientOnly:g.clientOnly,layer:x,order:g.order||-999};return typeof o=="function"&&mB(Ci(Ci({},q),{},{clientOnly:!1,path:["Shared",B]}),function(){return o(I,{prefix:{rootPrefixCls:B,iconPrefixCls:H},csp:N})}),mB(Ci(Ci({},q),{},{path:[S,E,H]}),function(){if(g.injectStyle===!1)return[];var X=FDe(I),Y=X.token,oe=X.flush,ee=Uj(b,D,f),ne=".".concat(E),le=Hj(b,D,ee,{deprecatedTokens:g.deprecatedTokens});ee&&Ui(ee)==="object"&&Object.keys(ee).forEach(function(de){ee[de]="var(".concat(oP(de,zj(b,L.prefix)),")")});var he=$r(Y,{componentCls:ne,prefixCls:E,iconCls:".".concat(H),antCls:".".concat(B),calc:W,max:$,min:K},ee),re=p(he,{hashId:A,prefixCls:E,rootPrefixCls:B,iconPrefixCls:H});oe(b,le);var ie=typeof s=="function"?s(he,E,R,g.resetFont):null;return[g.resetStyle===!1?null:ie,re]}),A}}function d(h,p,f){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},m=u(h,p,f,Ci({resetStyle:!1,order:-998},g)),v=function(S){var x=S.prefixCls,E=S.rootCls,R=E===void 0?x:E;return m(x,R),null};return v}return{genStyleHooks:l,genSubStyleComponent:d,genComponentStyleHook:u}}const Ad=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"];function cP(e){return(e+8)/e}function $De(e){const t=Array.from({length:10}).map((r,n)=>{const i=n-1,o=e*Math.E**(i/5),s=n>1?Math.floor(o):Math.ceil(o);return Math.floor(s/2)*2});return t[1]=e,t.map(r=>({size:r,lineHeight:cP(r)}))}const GDe="6.3.2",xae={blue:"#1677FF",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#EB2F96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},E0={...xae,colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'`,fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:!1,motion:!0},VDe={aliceblue:"9ehhb",antiquewhite:"9sgk7",aqua:"1ekf",aquamarine:"4zsno",azure:"9eiv3",beige:"9lhp8",bisque:"9zg04",black:"0",blanchedalmond:"9zhe5",blue:"73",blueviolet:"5e31e",brown:"6g016",burlywood:"8ouiv",cadetblue:"3qba8",chartreuse:"4zshs",chocolate:"87k0u",coral:"9yvyo",cornflowerblue:"3xael",cornsilk:"9zjz0",crimson:"8l4xo",cyan:"1ekf",darkblue:"3v",darkcyan:"rkb",darkgoldenrod:"776yz",darkgray:"6mbhl",darkgreen:"jr4",darkgrey:"6mbhl",darkkhaki:"7ehkb",darkmagenta:"5f91n",darkolivegreen:"3bzfz",darkorange:"9yygw",darkorchid:"5z6x8",darkred:"5f8xs",darksalmon:"9441m",darkseagreen:"5lwgf",darkslateblue:"2th1n",darkslategray:"1ugcv",darkslategrey:"1ugcv",darkturquoise:"14up",darkviolet:"5rw7n",deeppink:"9yavn",deepskyblue:"11xb",dimgray:"442g9",dimgrey:"442g9",dodgerblue:"16xof",firebrick:"6y7tu",floralwhite:"9zkds",forestgreen:"1cisi",fuchsia:"9y70f",gainsboro:"8m8kc",ghostwhite:"9pq0v",goldenrod:"8j4f4",gold:"9zda8",gray:"50i2o",green:"pa8",greenyellow:"6senj",grey:"50i2o",honeydew:"9eiuo",hotpink:"9yrp0",indianred:"80gnw",indigo:"2xcoy",ivory:"9zldc",khaki:"9edu4",lavenderblush:"9ziet",lavender:"90c8q",lawngreen:"4vk74",lemonchiffon:"9zkct",lightblue:"6s73a",lightcoral:"9dtog",lightcyan:"8s1rz",lightgoldenrodyellow:"9sjiq",lightgray:"89jo3",lightgreen:"5nkwg",lightgrey:"89jo3",lightpink:"9z6wx",lightsalmon:"9z2ii",lightseagreen:"19xgq",lightskyblue:"5arju",lightslategray:"4nwk9",lightslategrey:"4nwk9",lightsteelblue:"6wau6",lightyellow:"9zlcw",lime:"1edc",limegreen:"1zcxe",linen:"9shk6",magenta:"9y70f",maroon:"4zsow",mediumaquamarine:"40eju",mediumblue:"5p",mediumorchid:"79qkz",mediumpurple:"5r3rv",mediumseagreen:"2d9ip",mediumslateblue:"4tcku",mediumspringgreen:"1di2",mediumturquoise:"2uabw",mediumvioletred:"7rn9h",midnightblue:"z980",mintcream:"9ljp6",mistyrose:"9zg0x",moccasin:"9zfzp",navajowhite:"9zest",navy:"3k",oldlace:"9wq92",olive:"50hz4",olivedrab:"472ub",orange:"9z3eo",orangered:"9ykg0",orchid:"8iu3a",palegoldenrod:"9bl4a",palegreen:"5yw0o",paleturquoise:"6v4ku",palevioletred:"8k8lv",papayawhip:"9zi6t",peachpuff:"9ze0p",peru:"80oqn",pink:"9z8wb",plum:"8nba5",powderblue:"6wgdi",purple:"4zssg",rebeccapurple:"3zk49",red:"9y6tc",rosybrown:"7cv4f",royalblue:"2jvtt",saddlebrown:"5fmkz",salmon:"9rvci",sandybrown:"9jn1c",seagreen:"1tdnb",seashell:"9zje6",sienna:"6973h",silver:"7ir40",skyblue:"5arjf",slateblue:"45e4t",slategray:"4e100",slategrey:"4e100",snow:"9zke2",springgreen:"1egv",steelblue:"2r1kk",tan:"87yx8",teal:"pds",thistle:"8ggk8",tomato:"9yqfb",turquoise:"2j4r4",violet:"9b10u",wheat:"9ld4j",white:"9zldr",whitesmoke:"9lhpx",yellow:"9zl6o",yellowgreen:"61fzm"},yo=Math.round;function D_(e,t){const r=e.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],n=r.map(i=>parseFloat(i));for(let i=0;i<3;i+=1)n[i]=t(n[i]||0,r[i]||"",i);return r[3]?n[3]=r[3].includes("%")?n[3]/100:n[3]:n[3]=1,n}const Kj=(e,t,r)=>r===0?e:e/100;function rS(e,t){const r=t||255;return e>r?r:e<0?0:e}class cn{constructor(t){Ie(this,"isValid",!0);Ie(this,"r",0);Ie(this,"g",0);Ie(this,"b",0);Ie(this,"a",1);Ie(this,"_h");Ie(this,"_hsl_s");Ie(this,"_hsv_s");Ie(this,"_l");Ie(this,"_v");Ie(this,"_max");Ie(this,"_min");Ie(this,"_brightness");function r(n){return n[0]in t&&n[1]in t&&n[2]in t}if(t)if(typeof t=="string"){let i=function(o){return n.startsWith(o)};const n=t.trim();if(/^#?[A-F\d]{3,8}$/i.test(n))this.fromHexString(n);else if(i("rgb"))this.fromRgbString(n);else if(i("hsl"))this.fromHslString(n);else if(i("hsv")||i("hsb"))this.fromHsvString(n);else{const o=VDe[n.toLowerCase()];o&&this.fromHexString(parseInt(o,36).toString(16).padStart(6,"0"))}}else if(t instanceof cn)this.r=t.r,this.g=t.g,this.b=t.b,this.a=t.a,this._h=t._h,this._hsl_s=t._hsl_s,this._hsv_s=t._hsv_s,this._l=t._l,this._v=t._v;else if(r("rgb"))this.r=rS(t.r),this.g=rS(t.g),this.b=rS(t.b),this.a=typeof t.a=="number"?rS(t.a,1):1;else if(r("hsl"))this.fromHsl(t);else if(r("hsv"))this.fromHsv(t);else throw new Error("@ant-design/fast-color: unsupported input "+JSON.stringify(t))}setR(t){return this._sc("r",t)}setG(t){return this._sc("g",t)}setB(t){return this._sc("b",t)}setA(t){return this._sc("a",t,1)}setHue(t){const r=this.toHsv();return r.h=t,this._c(r)}getLuminance(){function t(o){const s=o/255;return s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4)}const r=t(this.r),n=t(this.g),i=t(this.b);return .2126*r+.7152*n+.0722*i}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=yo(60*(this.r===this.getMax()?(this.g-this.b)/t+(this.g"u"){const t=this.getMax()-this.getMin();t===0?this._hsv_s=0:this._hsv_s=t/this.getMax()}return this._hsv_s}getHSLSaturation(){if(typeof this._hsl_s>"u"){const t=this.getMax()-this.getMin();if(t===0)this._hsl_s=0;else{const r=this.getLightness();this._hsl_s=t/255/(1-Math.abs(2*r-1))}}return this._hsl_s}getLightness(){return typeof this._l>"u"&&(this._l=(this.getMax()+this.getMin())/510),this._l}getValue(){return typeof this._v>"u"&&(this._v=this.getMax()/255),this._v}getBrightness(){return typeof this._brightness>"u"&&(this._brightness=(this.r*299+this.g*587+this.b*114)/1e3),this._brightness}darken(t=10){const r=this.getHue(),n=this.getSaturation();let i=this.getLightness()-t/100;return i<0&&(i=0),this._c({h:r,s:n,l:i,a:this.a})}lighten(t=10){const r=this.getHue(),n=this.getSaturation();let i=this.getLightness()+t/100;return i>1&&(i=1),this._c({h:r,s:n,l:i,a:this.a})}mix(t,r=50){const n=this._c(t),i=r/100,o=a=>(n[a]-this[a])*i+this[a],s={r:yo(o("r")),g:yo(o("g")),b:yo(o("b")),a:yo(o("a")*100)/100};return this._c(s)}tint(t=10){return this.mix({r:255,g:255,b:255,a:1},t)}shade(t=10){return this.mix({r:0,g:0,b:0,a:1},t)}onBackground(t){const r=this._c(t),n=this.a+r.a*(1-this.a),i=o=>yo((this[o]*this.a+r[o]*r.a*(1-this.a))/n);return this._c({r:i("r"),g:i("g"),b:i("b"),a:n})}isDark(){return this.getBrightness()<128}isLight(){return this.getBrightness()>=128}equals(t){return this.r===t.r&&this.g===t.g&&this.b===t.b&&this.a===t.a}clone(){return this._c(this)}toHexString(){let t="#";const r=(this.r||0).toString(16);t+=r.length===2?r:"0"+r;const n=(this.g||0).toString(16);t+=n.length===2?n:"0"+n;const i=(this.b||0).toString(16);if(t+=i.length===2?i:"0"+i,typeof this.a=="number"&&this.a>=0&&this.a<1){const o=yo(this.a*255).toString(16);t+=o.length===2?o:"0"+o}return t}toHsl(){return{h:this.getHue(),s:this.getHSLSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),r=yo(this.getHSLSaturation()*100),n=yo(this.getLightness()*100);return this.a!==1?`hsla(${t},${r}%,${n}%,${this.a})`:`hsl(${t},${r}%,${n}%)`}toHsv(){return{h:this.getHue(),s:this.getHSVSaturation(),v:this.getValue(),a:this.a}}toRgb(){return{r:this.r,g:this.g,b:this.b,a:this.a}}toRgbString(){return this.a!==1?`rgba(${this.r},${this.g},${this.b},${this.a})`:`rgb(${this.r},${this.g},${this.b})`}toString(){return this.toRgbString()}_sc(t,r,n){const i=this.clone();return i[t]=rS(r,n),i}_c(t){return new this.constructor(t)}getMax(){return typeof this._max>"u"&&(this._max=Math.max(this.r,this.g,this.b)),this._max}getMin(){return typeof this._min>"u"&&(this._min=Math.min(this.r,this.g,this.b)),this._min}fromHexString(t){const r=t.replace("#","");function n(i,o){return parseInt(r[i]+r[o||i],16)}r.length<6?(this.r=n(0),this.g=n(1),this.b=n(2),this.a=r[3]?n(3)/255:1):(this.r=n(0,1),this.g=n(2,3),this.b=n(4,5),this.a=r[6]?n(6,7)/255:1)}fromHsl({h:t,s:r,l:n,a:i}){const o=(t%360+360)%360;if(this._h=o,this._hsl_s=r,this._l=n,this.a=typeof i=="number"?i:1,r<=0){const p=yo(n*255);this.r=p,this.g=p,this.b=p;return}let s=0,a=0,l=0;const c=o/60,u=(1-Math.abs(2*n-1))*r,d=u*(1-Math.abs(c%2-1));c>=0&&c<1?(s=u,a=d):c>=1&&c<2?(s=d,a=u):c>=2&&c<3?(a=u,l=d):c>=3&&c<4?(a=d,l=u):c>=4&&c<5?(s=d,l=u):c>=5&&c<6&&(s=u,l=d);const h=n-u/2;this.r=yo((s+h)*255),this.g=yo((a+h)*255),this.b=yo((l+h)*255)}fromHsv({h:t,s:r,v:n,a:i}){const o=(t%360+360)%360;this._h=o,this._hsv_s=r,this._v=n,this.a=typeof i=="number"?i:1;const s=yo(n*255);if(this.r=s,this.g=s,this.b=s,r<=0)return;const a=o/60,l=Math.floor(a),c=a-l,u=yo(n*(1-r)*255),d=yo(n*(1-r*c)*255),h=yo(n*(1-r*(1-c))*255);switch(l){case 0:this.g=h,this.b=u;break;case 1:this.r=d,this.b=u;break;case 2:this.r=u,this.b=h;break;case 3:this.r=u,this.g=d;break;case 4:this.r=h,this.g=u;break;case 5:default:this.g=u,this.b=d;break}}fromHsvString(t){const r=D_(t,Kj);this.fromHsv({h:r[0],s:r[1],v:r[2],a:r[3]})}fromHslString(t){const r=D_(t,Kj);this.fromHsl({h:r[0],s:r[1],l:r[2],a:r[3]})}fromRgbString(t){const r=D_(t,(n,i)=>i.includes("%")?yo(n/100*255):n);this.r=r[0],this.g=r[1],this.b=r[2],this.a=r[3]}}const KE=2,qj=.16,zDe=.05,HDe=.05,WDe=.15,Eae=5,Tae=4,UDe=[{index:7,amount:15},{index:6,amount:25},{index:5,amount:30},{index:5,amount:45},{index:5,amount:65},{index:5,amount:85},{index:4,amount:90},{index:3,amount:95},{index:2,amount:97},{index:1,amount:98}];function Xj(e,t,r){let n;return Math.round(e.h)>=60&&Math.round(e.h)<=240?n=r?Math.round(e.h)-KE*t:Math.round(e.h)+KE*t:n=r?Math.round(e.h)+KE*t:Math.round(e.h)-KE*t,n<0?n+=360:n>=360&&(n-=360),n}function Yj(e,t,r){if(e.h===0&&e.s===0)return e.s;let n;return r?n=e.s-qj*t:t===Tae?n=e.s+qj:n=e.s+zDe*t,n>1&&(n=1),r&&t===Eae&&n>.1&&(n=.1),n<.06&&(n=.06),Math.round(n*100)/100}function Zj(e,t,r){let n;return r?n=e.v+HDe*t:n=e.v-WDe*t,n=Math.max(0,Math.min(1,n)),Math.round(n*100)/100}function I3(e,t={}){const r=[],n=new cn(e),i=n.toHsv();for(let o=Eae;o>0;o-=1){const s=new cn({h:Xj(i,o,!0),s:Yj(i,o,!0),v:Zj(i,o,!0)});r.push(s)}r.push(n);for(let o=1;o<=Tae;o+=1){const s=new cn({h:Xj(i,o),s:Yj(i,o),v:Zj(i,o)});r.push(s)}return t.theme==="dark"?UDe.map(({index:o,amount:s})=>new cn(t.backgroundColor||"#141414").mix(r[o],s).toHexString()):r.map(o=>o.toHexString())}const Cy={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},yB=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];yB.primary=yB[5];const CB=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];CB.primary=CB[5];const bB=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];bB.primary=bB[5];const oM=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];oM.primary=oM[5];const SB=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];SB.primary=SB[5];const wB=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];wB.primary=wB[5];const xB=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];xB.primary=xB[5];const EB=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];EB.primary=EB[5];const Gy=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];Gy.primary=Gy[5];const TB=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];TB.primary=TB[5];const RB=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];RB.primary=RB[5];const PB=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];PB.primary=PB[5];const MB=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];MB.primary=MB[5];const A_={red:yB,volcano:CB,orange:bB,gold:oM,yellow:SB,lime:wB,green:xB,cyan:EB,blue:Gy,geekblue:TB,purple:RB,magenta:PB,grey:MB};function jDe(e,{generateColorPalettes:t,generateNeutralColorPalettes:r}){const{colorSuccess:n,colorWarning:i,colorError:o,colorInfo:s,colorPrimary:a,colorBgBase:l,colorTextBase:c}=e,u=t(a),d=t(n),h=t(i),p=t(o),f=t(s),g=r(l,c),m=e.colorLink||e.colorInfo,v=t(m),b=new cn(p[1]).mix(new cn(p[3]),50).toHexString(),S={};return Ad.forEach(x=>{const E=e[x];if(E){const R=t(E);S[`${x}Hover`]=R[5],S[`${x}Active`]=R[7]}}),{...g,colorPrimaryBg:u[1],colorPrimaryBgHover:u[2],colorPrimaryBorder:u[3],colorPrimaryBorderHover:u[4],colorPrimaryHover:u[5],colorPrimary:u[6],colorPrimaryActive:u[7],colorPrimaryTextHover:u[8],colorPrimaryText:u[9],colorPrimaryTextActive:u[10],colorSuccessBg:d[1],colorSuccessBgHover:d[2],colorSuccessBorder:d[3],colorSuccessBorderHover:d[4],colorSuccessHover:d[4],colorSuccess:d[6],colorSuccessActive:d[7],colorSuccessTextHover:d[8],colorSuccessText:d[9],colorSuccessTextActive:d[10],colorErrorBg:p[1],colorErrorBgHover:p[2],colorErrorBgFilledHover:b,colorErrorBgActive:p[3],colorErrorBorder:p[3],colorErrorBorderHover:p[4],colorErrorHover:p[5],colorError:p[6],colorErrorActive:p[7],colorErrorTextHover:p[8],colorErrorText:p[9],colorErrorTextActive:p[10],colorWarningBg:h[1],colorWarningBgHover:h[2],colorWarningBorder:h[3],colorWarningBorderHover:h[4],colorWarningHover:h[4],colorWarning:h[6],colorWarningActive:h[7],colorWarningTextHover:h[8],colorWarningText:h[9],colorWarningTextActive:h[10],colorInfoBg:f[1],colorInfoBgHover:f[2],colorInfoBorder:f[3],colorInfoBorderHover:f[4],colorInfoHover:f[4],colorInfo:f[6],colorInfoActive:f[7],colorInfoTextHover:f[8],colorInfoText:f[9],colorInfoTextActive:f[10],colorLinkHover:v[4],colorLink:v[6],colorLinkActive:v[7],...S,colorBgMask:new cn("#000").setA(.45).toRgbString(),colorWhite:"#fff"}}const KDe=e=>{let t=e,r=e,n=e,i=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?r=4:e<8&&e>=7?r=5:e<14&&e>=8?r=6:e<16&&e>=14?r=7:e>=16&&(r=8),e<6&&e>=2?n=1:e>=6&&(n=2),e>4&&e<8?i=4:e>=8&&(i=6),{borderRadius:e,borderRadiusXS:n,borderRadiusSM:r,borderRadiusLG:t,borderRadiusOuter:i}};function qDe(e){const{motionUnit:t,motionBase:r,borderRadius:n,lineWidth:i}=e;return{motionDurationFast:`${(r+t).toFixed(1)}s`,motionDurationMid:`${(r+t*2).toFixed(1)}s`,motionDurationSlow:`${(r+t*3).toFixed(1)}s`,lineWidthBold:i+1,...KDe(n)}}const XDe=e=>{const{controlHeight:t}=e;return{controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}},YDe=e=>{const t=$De(e),r=t.map(u=>u.size),n=t.map(u=>u.lineHeight),i=r[1],o=r[0],s=r[2],a=n[1],l=n[0],c=n[2];return{fontSizeSM:o,fontSize:i,fontSizeLG:s,fontSizeXL:r[3],fontSizeHeading1:r[6],fontSizeHeading2:r[5],fontSizeHeading3:r[4],fontSizeHeading4:r[3],fontSizeHeading5:r[2],lineHeight:a,lineHeightLG:c,lineHeightSM:l,fontHeight:Math.round(a*i),fontHeightLG:Math.round(c*s),fontHeightSM:Math.round(l*o),lineHeightHeading1:n[6],lineHeightHeading2:n[5],lineHeightHeading3:n[4],lineHeightHeading4:n[3],lineHeightHeading5:n[2]}};function ZDe(e){const{sizeUnit:t,sizeStep:r}=e;return{sizeXXL:t*(r+8),sizeXL:t*(r+4),sizeLG:t*(r+2),sizeMD:t*(r+1),sizeMS:t*r,size:t*r,sizeSM:t*(r-1),sizeXS:t*(r-2),sizeXXS:t*(r-3)}}const Za=(e,t)=>new cn(e).setA(t).toRgbString(),hv=(e,t)=>new cn(e).darken(t).toHexString(),QDe=e=>{const t=I3(e);return{1:t[0],2:t[1],3:t[2],4:t[3],5:t[4],6:t[5],7:t[6],8:t[4],9:t[5],10:t[6]}},JDe=(e,t)=>{const r=e||"#fff",n=t||"#000";return{colorBgBase:r,colorTextBase:n,colorText:Za(n,.88),colorTextSecondary:Za(n,.65),colorTextTertiary:Za(n,.45),colorTextQuaternary:Za(n,.25),colorFill:Za(n,.15),colorFillSecondary:Za(n,.06),colorFillTertiary:Za(n,.04),colorFillQuaternary:Za(n,.02),colorBgSolid:Za(n,1),colorBgSolidHover:Za(n,.75),colorBgSolidActive:Za(n,.95),colorBgLayout:hv(r,4),colorBgContainer:hv(r,0),colorBgElevated:hv(r,0),colorBgSpotlight:Za(n,.85),colorBgBlur:"transparent",colorBorder:hv(r,15),colorBorderDisabled:hv(r,15),colorBorderSecondary:hv(r,6)}};function eAe(e){Cy.pink=Cy.magenta,A_.pink=A_.magenta;const t=Object.keys(xae).map(r=>{const n=e[r]===Cy[r]?A_[r]:I3(e[r]);return Array.from({length:10},()=>1).reduce((i,o,s)=>(i[`${r}-${s+1}`]=n[s],i[`${r}${s+1}`]=n[s],i),{})}).reduce((r,n)=>(r={...r,...n},r),{});return{...e,...t,...jDe(e,{generateColorPalettes:QDe,generateNeutralColorPalettes:JDe}),...YDe(e.fontSize),...ZDe(e),...XDe(e),...qDe(e)}}const Rae=dB(eAe),IB={token:E0,override:{override:E0},hashed:!0},Pae=Z.createContext(IB);function F_(e){return e>=0&&e<=255}function tw(e,t){const{r,g:n,b:i,a:o}=new cn(e).toRgb();if(o<1)return e;const{r:s,g:a,b:l}=new cn(t).toRgb();for(let c=.01;c<=1;c+=.01){const u=Math.round((r-s*(1-c))/c),d=Math.round((n-a*(1-c))/c),h=Math.round((i-l*(1-c))/c);if(F_(u)&&F_(d)&&F_(h))return new cn({r:u,g:d,b:h,a:Math.round(c*100)/100}).toRgbString()}return new cn({r,g:n,b:i,a:1}).toRgbString()}function tAe(e){const{override:t,...r}=e,n={...t};Object.keys(E0).forEach(p=>{delete n[p]});const i={...r,...n},o=480,s=576,a=768,l=992,c=1200,u=1600,d=1920;return i.motion===!1&&(i.motionDurationFast="0s",i.motionDurationMid="0s",i.motionDurationSlow="0s"),{...i,colorFillContent:i.colorFillSecondary,colorFillContentHover:i.colorFill,colorFillAlter:i.colorFillQuaternary,colorBgContainerDisabled:i.colorFillTertiary,colorBorderBg:i.colorBgContainer,colorSplit:tw(i.colorBorderSecondary,i.colorBgContainer),colorTextPlaceholder:i.colorTextQuaternary,colorTextDisabled:i.colorTextQuaternary,colorTextHeading:i.colorText,colorTextLabel:i.colorTextSecondary,colorTextDescription:i.colorTextTertiary,colorTextLightSolid:i.colorWhite,colorHighlight:i.colorError,colorBgTextHover:i.colorFillSecondary,colorBgTextActive:i.colorFill,colorIcon:i.colorTextTertiary,colorIconHover:i.colorText,colorErrorOutline:tw(i.colorErrorBg,i.colorBgContainer),colorWarningOutline:tw(i.colorWarningBg,i.colorBgContainer),fontSizeIcon:i.fontSizeSM,lineWidthFocus:i.lineWidth*3,lineWidth:i.lineWidth,controlOutlineWidth:i.lineWidth*2,controlInteractiveSize:i.controlHeight/2,controlItemBgHover:i.colorFillTertiary,controlItemBgActive:i.colorPrimaryBg,controlItemBgActiveHover:i.colorPrimaryBgHover,controlItemBgActiveDisabled:i.colorFill,controlTmpOutline:i.colorFillQuaternary,controlOutline:tw(i.colorPrimaryBg,i.colorBgContainer),lineType:i.lineType,borderRadius:i.borderRadius,borderRadiusXS:i.borderRadiusXS,borderRadiusSM:i.borderRadiusSM,borderRadiusLG:i.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:i.sizeXXS,paddingXS:i.sizeXS,paddingSM:i.sizeSM,padding:i.size,paddingMD:i.sizeMD,paddingLG:i.sizeLG,paddingXL:i.sizeXL,paddingContentHorizontalLG:i.sizeLG,paddingContentVerticalLG:i.sizeMS,paddingContentHorizontal:i.sizeMS,paddingContentVertical:i.sizeSM,paddingContentHorizontalSM:i.size,paddingContentVerticalSM:i.sizeXS,marginXXS:i.sizeXXS,marginXS:i.sizeXS,marginSM:i.sizeSM,margin:i.size,marginMD:i.sizeMD,marginLG:i.sizeLG,marginXL:i.sizeXL,marginXXL:i.sizeXXL,boxShadow:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowSecondary:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTertiary:` 0 1px 2px 0 rgba(0, 0, 0, 0.03), 0 1px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px 0 rgba(0, 0, 0, 0.02) `,screenXS:o,screenXSMin:o,screenXSMax:s-1,screenSM:s,screenSMMin:s,screenSMMax:a-1,screenMD:a,screenMDMin:a,screenMDMax:l-1,screenLG:l,screenLGMin:l,screenLGMax:c-1,screenXL:c,screenXLMin:c,screenXLMax:u-1,screenXXL:u,screenXXLMin:u,screenXXLMax:d-1,screenXXXL:d,screenXXXLMin:d,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:` 0 1px 2px -2px ${new cn("rgba(0, 0, 0, 0.16)").toRgbString()}, 0 3px 6px 0 ${new cn("rgba(0, 0, 0, 0.12)").toRgbString()}, 0 5px 12px 4px ${new cn("rgba(0, 0, 0, 0.09)").toRgbString()} `,boxShadowDrawerRight:` -6px 0 16px 0 rgba(0, 0, 0, 0.08), -3px 0 6px -4px rgba(0, 0, 0, 0.12), -9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerLeft:` 6px 0 16px 0 rgba(0, 0, 0, 0.08), 3px 0 6px -4px rgba(0, 0, 0, 0.12), 9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerUp:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerDown:` 0 -6px 16px 0 rgba(0, 0, 0, 0.08), 0 -3px 6px -4px rgba(0, 0, 0, 0.12), 0 -9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)",...n}}const Mae={lineHeight:!0,lineHeightSM:!0,lineHeightLG:!0,lineHeightHeading1:!0,lineHeightHeading2:!0,lineHeightHeading3:!0,lineHeightHeading4:!0,lineHeightHeading5:!0,opacityLoading:!0,fontWeightStrong:!0,zIndexPopupBase:!0,zIndexBase:!0,opacityImage:!0},rAe={motionBase:!0,motionUnit:!0},nAe={screenXS:!0,screenXSMin:!0,screenXSMax:!0,screenSM:!0,screenSMMin:!0,screenSMMax:!0,screenMD:!0,screenMDMin:!0,screenMDMax:!0,screenLG:!0,screenLGMin:!0,screenLGMax:!0,screenXL:!0,screenXLMin:!0,screenXLMax:!0,screenXXL:!0,screenXXLMin:!0},Iae=(e,t,r)=>{const n=r.getDerivativeToken(e),{override:i,...o}=t;let s={...n,override:i};return s=tAe(s),o&&Object.entries(o).forEach(([a,l])=>{const{theme:c,...u}=l;let d=u;c&&(d=Iae({...s,...u},{override:u},c)),s[a]=d}),s};function fs(){const{token:e,hashed:t,theme:r,override:n,cssVar:i,zeroRuntime:o}=Z.useContext(Pae),{csp:s}=Z.useContext(ir),a={prefix:(i==null?void 0:i.prefix)??"ant",key:(i==null?void 0:i.key)??"css-var-root"},l=`${GDe}-${t||""}`,c=r||Rae,[u,d,h]=YIe(c,[E0,e],{salt:l,override:n,getComputedToken:Iae,cssVar:{...a,unitless:Mae,ignore:rAe,preserve:nAe},nonce:s==null?void 0:s.nonce});return[c,h,t?d:"",u,a,!!o]}const Ps={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},on=(e,t=!1)=>({boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:t?"inherit":e.fontFamily}),Ix=()=>({display:"inline-flex",alignItems:"center",color:"inherit",fontStyle:"normal",lineHeight:0,textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizeLegibility","-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale","> *":{lineHeight:1},svg:{display:"inline-block"}}),fu=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),iAe=e=>({a:{color:e.colorLink,textDecoration:e.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:`color ${e.motionDurationSlow}`,"-webkit-text-decoration-skip":"objects","&:hover":{color:e.colorLinkHover},"&:active":{color:e.colorLinkActive},"&:active, &:hover":{textDecoration:e.linkHoverDecoration,outline:0},"&:focus":{textDecoration:e.linkFocusDecoration,outline:0},"&[disabled]":{color:e.colorTextDisabled,cursor:"not-allowed"}}}),oAe=(e,t,r,n)=>{const i=`[class^="${t}"], [class*=" ${t}"]`,o=r?`.${r}`:i,s={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let a={};return n!==!1&&(a={fontFamily:e.fontFamily,fontSize:e.fontSize}),{[o]:{...a,...s,[i]:s}}},gc=(e,t)=>({outline:`${ae(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`,outlineOffset:t??1,transition:["outline-offset","outline"].map(r=>`${r} 0s`).join(", ")}),wl=(e,t)=>({"&:focus-visible":gc(e,t)}),Dae=e=>({[`.${e}`]:{...Ix(),[`.${e} .${e}-icon`]:{display:"block"}}}),D3=e=>({color:e.colorLink,textDecoration:e.linkDecoration,outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,border:0,padding:0,background:"none",userSelect:"none",...wl(e),"&:hover":{color:e.colorLinkHover,textDecoration:e.linkHoverDecoration},"&:focus":{color:e.colorLinkHover,textDecoration:e.linkFocusDecoration},"&:active":{color:e.colorLinkActive,textDecoration:e.linkHoverDecoration}}),{genStyleHooks:Wr,genComponentStyleHook:sAe,genSubStyleComponent:Dx}=BDe({usePrefix:()=>{const{getPrefixCls:e,iconPrefixCls:t}=y.useContext(ir);return{rootPrefixCls:e(),iconPrefixCls:t}},useToken:()=>{const[e,t,r,n,i,o]=fs();return{theme:e,realToken:t,hashId:r,token:n,cssVar:i,zeroRuntime:o}},useCSP:()=>{const{csp:e}=y.useContext(ir);return e??{}},getResetStyles:(e,t)=>{const r=iAe(e);return[r,{"&":r},Dae((t==null?void 0:t.prefix.iconPrefixCls)??LD)]},getCommonStyle:oAe,getCompUnitless:()=>Mae}),Jn=(e,t)=>{const r=`--${e.replace(/\./g,"")}-${t}-`;return[o=>`${r}${o}`,(o,s)=>s?`var(${r}${o}, ${s})`:`var(${r}${o})`]};function $D(e,t){return Ad.reduce((r,n)=>{const i=e[`${n}1`],o=e[`${n}3`],s=e[`${n}6`],a=e[`${n}7`];return{...r,...t(n,{lightColor:i,lightBorderColor:o,darkColor:s,textColor:a})}},{})}const aAe=(e,t)=>(fs(),mB({hashId:"",path:["ant-design-icons",e],nonce:()=>t==null?void 0:t.nonce,layer:{name:"antd"}},()=>Dae(e)));var lAe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"};const A3=y.createContext({});function Aae(e){var t;return(t=e==null?void 0:e.getRootNode)==null?void 0:t.call(e)}function cAe(e){return Aae(e)instanceof ShadowRoot}function sM(e){return cAe(e)?Aae(e):null}function uAe(e){return e.replace(/-(.)/g,(t,r)=>r.toUpperCase())}function dAe(e,t){Vn(e,`[@ant-design/icons] ${t}`)}function Qj(e){return typeof e=="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(typeof e.icon=="object"||typeof e.icon=="function")}function Jj(e={}){return Object.keys(e).reduce((t,r)=>{const n=e[r];switch(r){case"class":t.className=n,delete t.class;break;default:delete t[r],t[uAe(r)]=n}return t},{})}function DB(e,t,r){return r?Z.createElement(e.tag,{key:t,...Jj(e.attrs),...r},(e.children||[]).map((n,i)=>DB(n,`${t}-${e.tag}-${i}`))):Z.createElement(e.tag,{key:t,...Jj(e.attrs)},(e.children||[]).map((n,i)=>DB(n,`${t}-${e.tag}-${i}`)))}function Fae(e){return I3(e)[0]}function Lae(e){return e?Array.isArray(e)?e:[e]:[]}const hAe=` .anticon { display: inline-flex; align-items: center; color: inherit; font-style: normal; line-height: 0; text-align: center; text-transform: none; vertical-align: -0.125em; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } .anticon > * { line-height: 1; } .anticon svg { display: inline-block; vertical-align: inherit; } .anticon::before { display: none; } .anticon .anticon-icon { display: block; } .anticon[tabindex] { cursor: pointer; } .anticon-spin::before, .anticon-spin { display: inline-block; -webkit-animation: loadingCircle 1s infinite linear; animation: loadingCircle 1s infinite linear; } @-webkit-keyframes loadingCircle { 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } @keyframes loadingCircle { 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } `,pAe=e=>{const{csp:t,prefixCls:r,layer:n}=y.useContext(A3);let i=hAe;r&&(i=i.replace(/anticon/g,r)),n&&(i=`@layer ${n} { ${i} }`),y.useEffect(()=>{const o=e.current,s=sM(o);hp(i,"@ant-design-icons",{prepend:!n,csp:t,attachTo:s})},[])},Mw={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function fAe({primaryColor:e,secondaryColor:t}){Mw.primaryColor=e,Mw.secondaryColor=t||Fae(e),Mw.calculated=!!t}function gAe(){return{...Mw}}const DC=e=>{const{icon:t,className:r,onClick:n,style:i,primaryColor:o,secondaryColor:s,...a}=e,l=y.useRef(null);let c=Mw;if(o&&(c={primaryColor:o,secondaryColor:s||Fae(o)}),pAe(l),dAe(Qj(t),`icon should be icon definiton, but got ${t}`),!Qj(t))return null;let u=t;return u&&typeof u.icon=="function"&&(u={...u,icon:u.icon(c.primaryColor,c.secondaryColor)}),DB(u.icon,`svg-${u.name}`,{className:r,onClick:n,style:i,"data-icon":u.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",...a,ref:l})};DC.displayName="IconReact";DC.getTwoToneColors=gAe;DC.setTwoToneColors=fAe;function _ae(e){const[t,r]=Lae(e);return DC.setTwoToneColors({primaryColor:t,secondaryColor:r})}function mAe(){const e=DC.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor}function AB(){return AB=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{className:r,icon:n,spin:i,rotate:o,tabIndex:s,onClick:a,twoToneColor:l,...c}=e,{prefixCls:u="anticon",rootClassName:d}=y.useContext(A3),h=Q(d,u,{[`${u}-${n.name}`]:!!n.name,[`${u}-spin`]:!!i||n.name==="loading"},r);let p=s;p===void 0&&a&&(p=-1);const f=o?{msTransform:`rotate(${o}deg)`,transform:`rotate(${o}deg)`}:void 0,[g,m]=Lae(l);return y.createElement("span",AB({role:"img","aria-label":n.name},c,{ref:t,tabIndex:p,onClick:a,className:h}),y.createElement(DC,{icon:n,primaryColor:g,secondaryColor:m,style:f}))});Sr.getTwoToneColor=mAe;Sr.setTwoToneColor=_ae;function FB(){return FB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,FB({},e,{ref:t,icon:lAe})),F3=y.forwardRef(vAe);var yAe={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"}}]},name:"close-circle",theme:"filled"};function LB(){return LB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,LB({},e,{ref:t,icon:yAe})),Ax=y.forwardRef(CAe);var bAe={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"};function _B(){return _B=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,_B({},e,{ref:t,icon:bAe})),Xd=y.forwardRef(SAe);var wAe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"};function OB(){return OB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,OB({},e,{ref:t,icon:wAe})),GD=y.forwardRef(xAe);var EAe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"};function kB(){return kB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,kB({},e,{ref:t,icon:EAe})),Oae=y.forwardRef(TAe),kae=y.createContext({}),RAe=e=>{const{children:t,...r}=e,n=y.useMemo(()=>({motion:r.motion}),[r.motion]);return y.createElement(kae.Provider,{value:n},t)};function Nae(e){const[,t]=y.useReducer(o=>o+1,0),r=y.useRef(e),n=br(()=>r.current),i=br(o=>{r.current=typeof o=="function"?o(r.current):o,t()});return[n,i]}const Kc="none",qE="appear",XE="enter",YE="leave",eK="none",Ql="prepare",sg="start",ag="active",L3="end",Bae="prepared";function tK(e,t){const r={};return r[e.toLowerCase()]=t.toLowerCase(),r[`Webkit${e}`]=`webkit${t}`,r[`Moz${e}`]=`moz${t}`,r[`ms${e}`]=`MS${t}`,r[`O${e}`]=`o${t.toLowerCase()}`,r}function PAe(e,t){const r={animationend:tK("Animation","AnimationEnd"),transitionend:tK("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete r.animationend.animation,"TransitionEvent"in t||delete r.transitionend.transition),r}const MAe=PAe(To(),typeof window<"u"?window:{});let $ae={};To()&&({style:$ae}=document.createElement("div"));const ZE={};function Gae(e){if(ZE[e])return ZE[e];const t=MAe[e];if(t){const r=Object.keys(t),n=r.length;for(let i=0;in[1].toUpperCase());return e[r]}return`${e}-${t}`}const DAe=(e=>{const t=y.useRef();function r(i){i&&(i.removeEventListener(nK,e),i.removeEventListener(rK,e))}function n(i){t.current&&t.current!==i&&r(t.current),i&&i!==t.current&&(i.addEventListener(nK,e),i.addEventListener(rK,e),t.current=i)}return y.useEffect(()=>()=>{r(t.current),t.current=null},[]),[n,r]}),Hae=To()?y.useLayoutEffect:y.useEffect,AAe=(()=>{const e=y.useRef(null);function t(){Or.cancel(e.current)}function r(n,i=2){t();const o=Or(()=>{i<=1?n({isCanceled:()=>o!==e.current}):r(n,i-1)});e.current=o}return y.useEffect(()=>()=>{t()},[]),[r,t]}),FAe=[Ql,sg,ag,L3],LAe=[Ql,Bae],Wae=!1,_Ae=!0;function Uae(e){return e===ag||e===L3}const OAe=((e,t,r)=>{const[n,i]=v0(eK),[o,s]=AAe();function a(){i(Ql,!0)}const l=t?LAe:FAe;return Hae(()=>{if(n!==eK&&n!==L3){const c=l.indexOf(n),u=l[c+1],d=r(n);d===Wae?i(u,!0):u&&o(h=>{function p(){h.isCanceled()||i(u,!0)}d===!0?p():Promise.resolve(d).then(p)})}},[e,n]),y.useEffect(()=>()=>{s()},[]),[a,n]});function kAe(e,t,r,{motionEnter:n=!0,motionAppear:i=!0,motionLeave:o=!0,motionDeadline:s,motionLeaveImmediately:a,onAppearPrepare:l,onEnterPrepare:c,onLeavePrepare:u,onAppearStart:d,onEnterStart:h,onLeaveStart:p,onAppearActive:f,onEnterActive:g,onLeaveActive:m,onAppearEnd:v,onEnterEnd:b,onLeaveEnd:S,onVisibleChanged:x}){const[E,R]=y.useState(),[T,M]=Nae(Kc),[D,A]=y.useState([null,null]),I=T(),L=y.useRef(!1),F=y.useRef(null);function k(){return r()}const O=y.useRef(!1);function B(){M(Kc),A([null,null])}const H=br(ee=>{const ne=T();if(ne===Kc)return;const le=k();if(ee&&!ee.deadline&&ee.target!==le)return;const he=O.current;let re;ne===qE&&he?re=v==null?void 0:v(le,ee):ne===XE&&he?re=b==null?void 0:b(le,ee):ne===YE&&he&&(re=S==null?void 0:S(le,ee)),he&&re!==!1&&B()}),[N]=DAe(H),z=ee=>{switch(ee){case qE:return{[Ql]:l,[sg]:d,[ag]:f};case XE:return{[Ql]:c,[sg]:h,[ag]:g};case YE:return{[Ql]:u,[sg]:p,[ag]:m};default:return{}}},W=y.useMemo(()=>z(I),[I]),[V,$]=OAe(I,!e,ee=>{var ne;if(ee===Ql){const le=W[Ql];return le?le(k()):Wae}return ee in W&&A([((ne=W[ee])==null?void 0:ne.call(W,k(),null))||null,ee]),ee===ag&&I!==Kc&&(N(k()),s>0&&(clearTimeout(F.current),F.current=setTimeout(()=>{H({deadline:!0})},s))),ee===Bae&&B(),_Ae}),K=Uae($);O.current=K;const q=y.useRef(null);Hae(()=>{if(L.current&&q.current===t)return;R(t);const ee=L.current;L.current=!0;let ne;!ee&&t&&i&&(ne=qE),ee&&t&&n&&(ne=XE),(ee&&!t&&o||!ee&&a&&!t&&o)&&(ne=YE);const le=z(ne);ne&&(e||le[Ql])?(M(ne),V()):M(Kc),q.current=t},[t]),y.useEffect(()=>{(I===qE&&!i||I===XE&&!n||I===YE&&!o)&&M(Kc)},[i,n,o]),y.useEffect(()=>()=>{L.current=!1,clearTimeout(F.current)},[]);const X=y.useRef(!1);y.useEffect(()=>{E&&(X.current=!0),E!==void 0&&I===Kc&&((X.current||E)&&(x==null||x(E)),X.current=!0)},[E,I]);let Y=D[0];W[Ql]&&$===sg&&(Y={transition:"none",...Y});const oe=D[1];return[T,$,Y,E??t,!L.current&&I===Kc&&e&&i?"NONE":$===sg||$===ag?oe===$:!0]}function NAe(e){let t=e;typeof e=="object"&&({transitionSupport:t}=e);function r(i,o){return!!(i.motionName&&t&&o!==!1)}const n=y.forwardRef((i,o)=>{const{visible:s=!0,removeOnLeave:a=!0,forceRender:l,children:c,motionName:u,leavedClassName:d,eventProps:h}=i,{motion:p}=y.useContext(kae),f=r(i,p),g=y.useRef();function m(){return pc(g.current)}const[v,b,S,x,E]=kAe(f,s,m,i),R=v(),T=y.useRef(x);x&&(T.current=!0);const M=y.useMemo(()=>{const A={};return Object.defineProperties(A,{nativeElement:{enumerable:!0,get:m},inMotion:{enumerable:!0,get:()=>()=>v()!==Kc},enableMotion:{enumerable:!0,get:()=>()=>f}}),A},[]);y.useImperativeHandle(o,()=>M,[]);const D=y.useRef(0);return E&&(D.current+=1),y.useMemo(()=>{if(E==="NONE")return null;let A;const I={...h,visible:s};if(!c)A=null;else if(R===Kc)x?A=c({...I},g):!a&&T.current&&d?A=c({...I,className:d},g):l||!a&&!d?A=c({...I,style:{display:"none"}},g):A=null;else{let L;b===Ql?L="prepare":Uae(b)?L="active":b===sg&&(L="start");const F=iK(u,`${R}-${L}`);A=c({...I,className:Q(iK(u,R),{[F]:F&&L,[u]:typeof u=="string"}),style:S},g)}return y.isValidElement(A)&&pu(A)&&(jd(A)||(A=y.cloneElement(A,{ref:g}))),A},[D.current])});return n.displayName="CSSMotion",n}const Mu=NAe(IAe),NB="add",BB="keep",$B="remove",L_="removed";function BAe(e){let t;return e&&typeof e=="object"&&"key"in e?t=e:t={key:e},{...t,key:String(t.key)}}function GB(e=[]){return e.map(BAe)}function $Ae(e=[],t=[]){let r=[],n=0;const i=t.length,o=GB(e),s=GB(t);o.forEach(c=>{let u=!1;for(let d=n;d({...p,status:NB}))),n=d),r.push({...h,status:BB}),n+=1,u=!0;break}}u||r.push({...c,status:$B})}),n({...c,status:NB}))));const a={};return r.forEach(({key:c})=>{a[c]=(a[c]||0)+1}),Object.keys(a).filter(c=>a[c]>1).forEach(c=>{r=r.filter(({key:u,status:d})=>u!==c||d!==$B),r.forEach(u=>{u.key===c&&(u.status=BB)})}),r}function VB(){return VB=Object.assign?Object.assign.bind():function(e){for(var t=1;t{this.setState(s=>({keyEntities:s.keyEntities.map(l=>l.key!==o?l:{...l,status:L_})}),()=>{const{keyEntities:s}=this.state;s.filter(({status:l})=>l!==L_).length===0&&this.props.onAllRemoved&&this.props.onAllRemoved()})})}static getDerivedStateFromProps({keys:o},{keyEntities:s}){const a=GB(o);return{keyEntities:$Ae(s,a).filter(c=>{const u=s.find(({key:d})=>c.key===d);return!(u&&u.status===L_&&c.status===$B)})}}render(){const{keyEntities:o}=this.state,{component:s,children:a,onVisibleChanged:l,onAllRemoved:c,...u}=this.props,d=s||y.Fragment,h={};return GAe.forEach(p=>{h[p]=u[p],delete u[p]}),delete u.keys,y.createElement(d,u,o.map(({status:p,...f},g)=>{const m=p===NB||p===BB;return y.createElement(t,VB({},h,{key:f.key,visible:m,eventProps:f,onVisibleChanged:v=>{l==null||l(v,{key:f.key}),v||this.removeKey(f.key)}}),(v,b)=>a({...v,index:g},b))}))}}return Ie(r,"defaultProps",{component:"div"}),r}const zAe=VAe(),HAe=`accept acceptCharset accessKey action allowFullScreen allowTransparency alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge charSet checked classID className colSpan cols content contentEditable contextMenu controls coords crossOrigin data dateTime default defer dir disabled download draggable encType form formAction formEncType formMethod formNoValidate formTarget frameBorder headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media mediaGroup method min minLength multiple muted name noValidate nonce open optimum pattern placeholder poster preload radioGroup readOnly rel required reversed role rowSpan rows sandbox scope scoped scrolling seamless selected shape size sizes span spellCheck src srcDoc srcLang srcSet start step style summary tabIndex target title type useMap value width wmode wrap`,WAe=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,UAe=`${HAe} ${WAe}`.split(/[\s\n]+/),jAe="aria-",KAe="data-";function oK(e,t){return e.indexOf(t)===0}function ai(e,t=!1){let r;t===!1?r={aria:!0,data:!0,attr:!0}:t===!0?r={aria:!0}:r={...t};const n={};return Object.keys(e).forEach(i=>{(r.aria&&(i==="role"||oK(i,jAe))||r.data&&oK(i,KAe)||r.attr&&UAe.includes(i))&&(n[i]=e[i])}),n}const jae={items_per_page:"/ page",jump_to:"Go to",jump_to_confirm:"confirm",page:"Page",prev_page:"Previous Page",next_page:"Next Page",prev_5:"Previous 5 Pages",next_5:"Next 5 Pages",prev_3:"Previous 3 Pages",next_3:"Next 3 Pages",page_size:"Page Size"};var qAe={yearFormat:"YYYY",dayFormat:"D",cellMeridiemFormat:"A",monthBeforeYear:!0};function T0(e){"@babel/helpers - typeof";return T0=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},T0(e)}function sK(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function aK(e){for(var t=1;tdP.reduce((e,t)=>({...e,...t}),xl.Modal);function JAe(e){if(e){const t={...e};return dP.push(t),uP=cK(),()=>{dP=dP.filter(r=>r!==t),uP=cK()}}uP={...xl.Modal}}function qae(){return uP}const _3=y.createContext(void 0),Dl=(e,t)=>{const r=y.useContext(_3),n=y.useMemo(()=>{const o=t||xl[e],s=(r==null?void 0:r[e])??{};return{...typeof o=="function"?o():o,...s||{}}},[e,t,r]),i=y.useMemo(()=>{const o=r==null?void 0:r.locale;return r!=null&&r.exist&&!o?xl.locale:o},[r]);return[n,i]},eFe="internalMark",tFe=e=>{const{locale:t={},children:r,_ANT_MARK__:n}=e;y.useEffect(()=>JAe(t==null?void 0:t.Modal),[t]);const i=y.useMemo(()=>({...t,exist:!0}),[t]);return y.createElement(_3.Provider,{value:i},r)};function R0(...e){const t={};return e.forEach(r=>{r&&Object.keys(r).forEach(n=>{r[n]!==void 0&&(t[n]=r[n])})}),t}const Tn=e=>e!=null,Vy=e=>{if(!e)return;const{closable:t,closeIcon:r}=e;return{closable:t,closeIcon:r}},Xae={},uK=(e,t)=>{if(!e&&(e===!1||t===!1||t===null))return!1;if(e===void 0&&t===void 0)return null;let r={closeIcon:typeof t!="boolean"&&t!==null?t:void 0};return e&&typeof e=="object"&&(r={...r,...e}),r},rFe=(e,t,r)=>e===!1?!1:e?R0(r,t,e):t===!1?!1:t?R0(r,t):r.closable?r:!1,nFe=(e,t,r)=>{const{closeIconRender:n}=t,{closeIcon:i,...o}=e;let s=i;const a=ai(o,!0);return Tn(s)&&(n&&(s=n(s)),s=Z.isValidElement(s)?Z.cloneElement(s,{"aria-label":r,...s.props,...a}):Z.createElement("span",{"aria-label":r,...a},s)),[s,a]},iFe=(e,t,r=Xae,n="Close")=>{const i=uK(e==null?void 0:e.closable,e==null?void 0:e.closeIcon),o=uK(t==null?void 0:t.closable,t==null?void 0:t.closeIcon),s={closeIcon:Z.createElement(Xd,null),...r},a=rFe(i,o,s),l=typeof a!="boolean"?!!(a!=null&&a.disabled):!1;if(a===!1)return[!1,null,l,{}];const[c,u]=nFe(a,s,n);return[!0,c,l,u]},O3=(e,t,r=Xae)=>{const[n]=Dl("global",xl.global);return Z.useMemo(()=>iFe(e,t,{closeIcon:Z.createElement(Xd,null),...r},n.close),[e,t,r,n.close])},k3=()=>Z.useReducer(e=>e+1,0),zB=(e,t)=>{let r={};return e&&typeof e=="object"&&(r=e),typeof e=="boolean"&&(r={enabled:e}),r.closable===void 0&&t!==void 0&&(r.closable=t),r},Yae=(e,t,r,n)=>y.useMemo(()=>{const i=zB(e,n),o=zB(t),s={blur:!1,...o,...i,closable:i.closable??n??o.closable??!0},a=s.blur?`${r}-mask-blur`:void 0;return[s.enabled!==!1,{mask:a},!!s.closable]},[e,t,r,n]),Zae=(e,...t)=>{const r=e||{};return t.filter(Boolean).reduce((n,i)=>(Object.keys(i||{}).forEach(o=>{const s=r[o],a=i[o];if(s&&typeof s=="object")if(a&&typeof a=="object")n[o]=Zae(s,n[o],a);else{const{_default:l}=s;l&&(n[o]=n[o]||{},n[o][l]=Q(n[o][l],a))}else n[o]=Q(n[o],a)}),n),{})},oFe=(e,...t)=>y.useMemo(()=>Zae.apply(void 0,[e].concat(t)),[e].concat(t)),sFe=(...e)=>e.filter(Boolean).reduce((t,r={})=>(Object.keys(r).forEach(n=>{t[n]={...t[n],...r[n]}}),t),{}),aFe=(...e)=>y.useMemo(()=>sFe.apply(void 0,e),[].concat(e)),HB=(e,t)=>{const r={...e};return Object.keys(t).forEach(n=>{if(n!=="_default"){const i=t[n],o=r[n]||{};r[n]=i?HB(o,i):o}}),r},dK=(e,t)=>typeof e=="function"?e(t):e,Vr=(e,t,r,n)=>{const i=e.map(l=>l?dK(l,r):void 0),o=t.map(l=>l?dK(l,r):void 0),s=oFe.apply(void 0,[n].concat(Pr(i))),a=aFe.apply(void 0,Pr(o));return y.useMemo(()=>n?[HB(s,n),HB(a,n)]:[s,a],[s,a,n])},lFe=e=>{const[t,r]=y.useState(null);return[y.useCallback((i,o,s)=>{const a=t??i,l=Math.min(a||0,i),c=Math.max(a||0,i),u=o.slice(l,c+1).map(e),d=u.some(p=>!s.has(p)),h=[];return u.forEach(p=>{d?(s.has(p)||h.push(p),s.add(p)):(s.delete(p),h.push(p))}),r(d?c:null),h},[t]),r]},hK=e=>e==="horizontal"||e==="vertical",Fx=(e,t,r)=>y.useMemo(()=>{const n=hK(e);let i;return n?i=e:typeof t=="boolean"?i=t?"vertical":"horizontal":i=hK(r)?r:"horizontal",[i,i==="vertical"]},[r,e,t]),cFe=()=>{const[e,t]=y.useState([]),r=y.useCallback(n=>(t(i=>[].concat(Pr(i),[n])),()=>{t(i=>i.filter(o=>o!==n))}),[]);return[e,r]},uFe=(e,t)=>(e._antProxy=e._antProxy||{},Object.keys(t).forEach(r=>{if(!(r in e._antProxy)){const n=e[r];e._antProxy[r]=n,e[r]=t[r]}}),e),dFe=(e,t)=>y.useImperativeHandle(e,()=>{const r=t(),{nativeElement:n}=r;return typeof Proxy<"u"?new Proxy(n,{get(i,o){return r[o]?r[o]:Reflect.get(i,o)}}):uFe(n,r)}),hFe=e=>{const t=y.useRef(e),[,r]=k3();return[()=>t.current,n=>{t.current=n,r()}]},Lx=Z.createContext(void 0),Oh=100,pFe=10,fFe=Oh*pFe,Qae={Modal:Oh,Drawer:Oh,Popover:Oh,Popconfirm:Oh,Tooltip:Oh,Tour:Oh,FloatButton:Oh},gFe={SelectLike:50,Dropdown:50,DatePicker:50,Menu:50,ImagePreview:1},mFe=e=>e in Qae,Hp=(e,t)=>{const[,r]=fs(),n=Z.useContext(Lx),i=mFe(e);let o;if(t!==void 0)o=[t,t];else{let s=n??0;i?s+=(n?0:r.zIndexPopupBase)+Qae[e]:s+=gFe[e],o=[n===void 0?t:s,s]}return o},QE=(e,t,r,n,i)=>({background:e,border:`${ae(n.lineWidth)} ${n.lineType} ${t}`,[`${i}-icon`]:{color:r}}),vFe=e=>{const{componentCls:t,motionDurationSlow:r,marginXS:n,marginSM:i,fontSize:o,fontSizeLG:s,lineHeight:a,borderRadiusLG:l,motionEaseInOutCirc:c,withDescriptionIconSize:u,colorText:d,colorTextHeading:h,withDescriptionPadding:p,defaultPadding:f}=e;return{[t]:{...on(e),position:"relative",display:"flex",alignItems:"center",padding:f,wordWrap:"break-word",borderRadius:l,[`&${t}-rtl`]:{direction:"rtl"},[`${t}-section`]:{flex:1,minWidth:0},[`${t}-icon`]:{marginInlineEnd:n,lineHeight:0},"&-description":{display:"none",fontSize:o,lineHeight:a},"&-title":{color:h},[`&${t}-motion-leave`]:{overflow:"hidden",opacity:1,transition:["max-height","opacity","padding-top","padding-bottom","margin-bottom"].map(g=>`${g} ${r} ${c}`).join(", ")},[`&${t}-motion-leave-active`]:{maxHeight:0,marginBottom:"0 !important",paddingTop:0,paddingBottom:0,opacity:0}},[`${t}-with-description`]:{alignItems:"flex-start",padding:p,[`${t}-icon`]:{marginInlineEnd:i,fontSize:u,lineHeight:0},[`${t}-title`]:{display:"block",marginBottom:n,color:h,fontSize:s},[`${t}-description`]:{display:"block",color:d}},[`${t}-banner`]:{marginBottom:0,border:"0 !important",borderRadius:0}}},yFe=e=>{const{componentCls:t,colorSuccess:r,colorSuccessBorder:n,colorSuccessBg:i,colorWarning:o,colorWarningBorder:s,colorWarningBg:a,colorError:l,colorErrorBorder:c,colorErrorBg:u,colorInfo:d,colorInfoBorder:h,colorInfoBg:p}=e;return{[t]:{"&-success":QE(i,n,r,e,t),"&-info":QE(p,h,d,e,t),"&-warning":QE(a,s,o,e,t),"&-error":{...QE(u,c,l,e,t),[`${t}-description > pre`]:{margin:0,padding:0}}}}},CFe=e=>{const{componentCls:t,iconCls:r,motionDurationMid:n,marginXS:i,fontSizeIcon:o,colorIcon:s,colorIconHover:a}=e;return{[t]:{"&-actions":{marginInlineStart:i},[`${t}-close-icon`]:{marginInlineStart:i,padding:0,overflow:"hidden",fontSize:o,lineHeight:ae(o),backgroundColor:"transparent",border:"none",outline:"none",cursor:"pointer",[`${r}-close`]:{color:s,transition:`color ${n}`,"&:hover":{color:a}}},"&-close-text":{color:s,transition:`color ${n}`,"&:hover":{color:a}}}}},bFe=e=>({withDescriptionIconSize:e.fontSizeHeading3,defaultPadding:`${e.paddingContentVerticalSM}px 12px`,withDescriptionPadding:`${e.paddingMD}px ${e.paddingContentHorizontalLG}px`}),SFe=Wr("Alert",e=>[vFe(e),yFe(e),CFe(e)],bFe),wFe=e=>{const{icon:t,type:r,className:n,style:i,successIcon:o,infoIcon:s,warningIcon:a,errorIcon:l}=e,c={success:o??y.createElement(F3,null),info:s??y.createElement(Oae,null),error:l??y.createElement(Ax,null),warning:a??y.createElement(GD,null)};return y.createElement("span",{className:n,style:i},t??c[r])},xFe=e=>{const{isClosable:t,prefixCls:r,closeIcon:n,handleClose:i,ariaProps:o,className:s,style:a}=e,l=n===!0||n===void 0?y.createElement(Xd,null):n;return t?y.createElement("button",{type:"button",onClick:i,className:Q(`${r}-close-icon`,s),tabIndex:0,style:a,...o},l):null},Jae=y.forwardRef((e,t)=>{const{description:r,prefixCls:n,message:i,title:o,banner:s,className:a,rootClassName:l,style:c,onMouseEnter:u,onMouseLeave:d,onClick:h,afterClose:p,showIcon:f,closable:g,closeText:m,closeIcon:v,action:b,id:S,styles:x,classNames:E,...R}=e,T=o??i,[M,D]=y.useState(!1),A=y.useRef(null);y.useImperativeHandle(t,()=>({nativeElement:A.current}));const{getPrefixCls:I,direction:L,closable:F,closeIcon:k,className:O,style:B,classNames:H,styles:N,successIcon:z,infoIcon:W,warningIcon:V,errorIcon:$}=Nr("alert"),K=I("alert",n),[q,X]=SFe(K),{onClose:Y,afterClose:oe}=g&&typeof g=="object"?g:{},ee=me=>{var ke;D(!0),(ke=Y??e.onClose)==null||ke(me)},ne=y.useMemo(()=>e.type!==void 0?e.type:s?"warning":"info",[e.type,s]),le=y.useMemo(()=>typeof g=="object"&&g.closeIcon||m?!0:typeof g=="boolean"?g:v!==!1&&Tn(v)?!0:!!F,[m,v,g,F]),he=s&&f===void 0?!0:f,re={...e,prefixCls:K,type:ne,showIcon:he,closable:le},[ie,de]=Vr([H,E],[N,x],{props:re}),J=Q(K,`${K}-${ne}`,{[`${K}-with-description`]:!!r,[`${K}-no-icon`]:!he,[`${K}-banner`]:!!s,[`${K}-rtl`]:L==="rtl"},O,a,l,ie.root,X,q),ue=ai(R,{aria:!0,data:!0}),ve=y.useMemo(()=>typeof g=="object"&&g.closeIcon?g.closeIcon:m||(v!==void 0?v:typeof F=="object"&&F.closeIcon?F.closeIcon:k),[v,g,F,m,k]),pe=y.useMemo(()=>{const me=g??F;return typeof me=="object"?ai(me,{data:!0,aria:!0}):{}},[g,F]);return y.createElement(Mu,{visible:!M,motionName:`${K}-motion`,motionAppear:!1,motionEnter:!1,onLeaveStart:me=>({maxHeight:me.offsetHeight}),onLeaveEnd:oe??p},({className:me,style:ke},De)=>y.createElement("div",{id:S,ref:Wo(A,De),"data-show":!M,className:Q(J,me),style:{...de.root,...B,...c,...ke},onMouseEnter:u,onMouseLeave:d,onClick:h,role:"alert",...ue},he?y.createElement(wFe,{className:Q(`${K}-icon`,ie.icon),style:de.icon,description:r,icon:e.icon,prefixCls:K,type:ne,successIcon:z,infoIcon:W,warningIcon:V,errorIcon:$}):null,y.createElement("div",{className:Q(`${K}-section`,ie.section),style:de.section},T?y.createElement("div",{className:Q(`${K}-title`,ie.title),style:de.title},T):null,r?y.createElement("div",{className:Q(`${K}-description`,ie.description),style:de.description},r):null),b?y.createElement("div",{className:Q(`${K}-actions`,ie.actions),style:de.actions},b):null,y.createElement(xFe,{className:ie.close,style:de.close,isClosable:le,prefixCls:K,closeIcon:ve,handleClose:ee,ariaProps:pe})))});function EFe(e,t,r){return t=tm(t),Cae(e,BD()?Reflect.construct(t,r||[],tm(e).constructor):t.apply(e,r))}let TFe=(function(e){function t(){var r;return Kd(this,t),r=EFe(this,t,arguments),r.state={error:void 0,info:{}},r}return M3(t,e),qd(t,[{key:"componentDidCatch",value:function(n,i){this.setState({error:n,info:i})}},{key:"render",value:function(){const{message:n,title:i,description:o,id:s,children:a}=this.props,{error:l,info:c}=this.state,u=i??n,d=(c==null?void 0:c.componentStack)||null,h=Tn(u)?u:l==null?void 0:l.toString(),p=Tn(o)?o:d;return l?y.createElement(Jae,{id:s,type:"error",title:h,description:y.createElement("pre",{style:{fontSize:"0.9em",overflowX:"auto"}},p)}):a}}])})(y.PureComponent);const RFe=Jae;RFe.ErrorBoundary=TFe;function WB(e){return Tn(e)&&e===e.window}const ele=e=>{var r;if(typeof window>"u")return 0;let t=0;return WB(e)?t=e.pageYOffset:e instanceof Document?t=e.documentElement.scrollTop:(e instanceof HTMLElement||e)&&(t=e.scrollTop),e&&!WB(e)&&typeof t!="number"&&(t=(r=(e.ownerDocument??e).documentElement)==null?void 0:r.scrollTop),t};function PFe(e,t,r,n){const i=r-t;return e/=n/2,e<1?i/2*e*e*e+t:i/2*((e-=2)*e*e+2)+t}function tle(e,t={}){const{getContainer:r=()=>window,callback:n,duration:i=450}=t,o=r(),s=ele(o),a=Date.now();let l;const c=()=>{const d=Date.now()-a,h=PFe(d>i?i:d,s,e,i);WB(o)?o.scrollTo(window.pageXOffset,h):o instanceof Document||o.constructor.name==="HTMLDocument"?o.documentElement.scrollTop=h:o.scrollTop=h,d{Or.cancel(l)}}const ho=e=>`${e}-css-var`,MFe=y.createContext(void 0),rle=y.createContext(null);let IFe=!1;function DFe(e){return IFe}const pK=[];function AFe(e,t){const[r]=y.useState(()=>To()?document.createElement("div"):null),n=y.useRef(!1),i=y.useContext(rle),[o,s]=y.useState(pK),a=i||(n.current?void 0:u=>{s(d=>[u,...d])});function l(){r.parentElement||document.body.appendChild(r),n.current=!0}function c(){var u;(u=r.parentElement)==null||u.removeChild(r),n.current=!1}return jr(()=>(e?i?i(l):l():c(),c),[e]),jr(()=>{o.length&&(o.forEach(u=>u()),s(pK))},[o]),[r,a]}let __;function nle(e){const t=`rc-scrollbar-measure-${Math.random().toString(36).substring(7)}`,r=document.createElement("div");r.id=t;const n=r.style;n.position="absolute",n.left="0",n.top="0",n.width="100px",n.height="100px",n.overflow="scroll";let i,o;if(e){const l=getComputedStyle(e);n.scrollbarColor=l.scrollbarColor,n.scrollbarWidth=l.scrollbarWidth;const c=getComputedStyle(e,"::-webkit-scrollbar"),u=parseInt(c.width,10),d=parseInt(c.height,10);try{const h=u?`width: ${c.width};`:"",p=d?`height: ${c.height};`:"";hp(` #${t}::-webkit-scrollbar { ${h} ${p} }`,t)}catch(h){console.error(h),i=u,o=d}}document.body.appendChild(r);const s=e&&i&&!isNaN(i)?i:r.offsetWidth-r.clientWidth,a=e&&o&&!isNaN(o)?o:r.offsetHeight-r.clientHeight;return document.body.removeChild(r),b0(t),{width:s,height:a}}function fK(e){return typeof document>"u"?0:(__===void 0&&(__=nle()),__.width)}function UB(e){return typeof document>"u"||!e||!(e instanceof Element)?{width:0,height:0}:nle(e)}function FFe(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}const LFe=`rc-util-locker-${Date.now()}`;let gK=0;function _Fe(e){const t=!!e,[r]=y.useState(()=>(gK+=1,`${LFe}_${gK}`));jr(()=>{if(t){const n=UB(document.body).width,i=FFe();hp(` html body { overflow-y: hidden; ${i?`width: calc(100% - ${n}px);`:""} }`,r)}else b0(r);return()=>{b0(r)}},[t,r])}function OFe(){return{...tse}.useId}let mK=0;function ile(e,t){const n=String(t).replace(/[^a-zA-Z0-9_.:-]/g,"-");return`${e}-${n}`}const vK=OFe(),xc=vK?(function(t){const r=vK();return t||r}):(function(t){const[r,n]=y.useState("ssr-id");return y.useEffect(()=>{const i=mK;mK+=1,n(`rc_unique_${i}`)},[]),t||r});let vg=[];const kFe=200;let ole=0;const sle=e=>{if(e.key==="Escape"&&!e.isComposing){if(Date.now()-ole=0;n-=1)vg[n].onEsc({top:n===r-1,event:e})}},ale=()=>{ole=Date.now()};function NFe(){window.addEventListener("keydown",sle),window.addEventListener("compositionend",ale)}function BFe(){vg.length===0&&(window.removeEventListener("keydown",sle),window.removeEventListener("compositionend",ale))}function $Fe(e,t){const r=xc(),n=br(t),i=()=>{vg.find(s=>s.id===r)||vg.push({id:r,onEsc:n})},o=()=>{vg=vg.filter(s=>s.id!==r)};y.useMemo(()=>{e?i():e||o()},[e]),y.useEffect(()=>{if(e)return i(),NFe(),()=>{o(),BFe()}},[e])}const yK=e=>e===!1?!1:!To()||!e?null:typeof e=="string"?document.querySelector(e):typeof e=="function"?e():e,_x=y.forwardRef((e,t)=>{const{open:r,autoLock:n,getContainer:i,debug:o,autoDestroy:s=!0,children:a,onEsc:l}=e,[c,u]=y.useState(r),d=c||r;y.useEffect(()=>{(s||r)&&u(r)},[r,s]);const[h,p]=y.useState(()=>yK(i));y.useEffect(()=>{const E=yK(i);p(()=>E??null)});const[f,g]=AFe(d&&!h),m=h??f;_Fe(n&&r&&To()&&(m===f||m===document.body)),$Fe(r,l);let v=null;a&&pu(a)&&t&&(v=jd(a));const b=Pu(v,t);if(!d||!To()||h===void 0)return null;const S=m===!1||DFe();let x=a;return t&&(x=y.cloneElement(a,{ref:b})),y.createElement(rle.Provider,{value:g},S?x:$a.createPortal(x,m))}),GFe=y.createContext({}),rd="none",JE="appear",eT="enter",tT="leave",CK="none",Jl="prepare",ny="start",iy="active",N3="end",lle="prepared";function bK(e,t){const r={};return r[e.toLowerCase()]=t.toLowerCase(),r[`Webkit${e}`]=`webkit${t}`,r[`Moz${e}`]=`moz${t}`,r[`ms${e}`]=`MS${t}`,r[`O${e}`]=`o${t.toLowerCase()}`,r}function VFe(e,t){const r={animationend:bK("Animation","AnimationEnd"),transitionend:bK("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete r.animationend.animation,"TransitionEvent"in t||delete r.transitionend.transition),r}const zFe=VFe(To(),typeof window<"u"?window:{});let cle={};To()&&({style:cle}=document.createElement("div"));const rT={};function ule(e){if(rT[e])return rT[e];const t=zFe[e];if(t){const r=Object.keys(t),n=r.length;for(let i=0;in[1].toUpperCase());return e[r]}return`${e}-${t}`}const WFe=(e=>{const t=y.useRef();function r(i){i&&(i.removeEventListener(wK,e),i.removeEventListener(SK,e))}function n(i){t.current&&t.current!==i&&r(t.current),i&&i!==t.current&&(i.addEventListener(wK,e),i.addEventListener(SK,e),t.current=i)}return y.useEffect(()=>()=>{r(t.current),t.current=null},[]),[n,r]}),ple=To()?y.useLayoutEffect:y.useEffect,UFe=(()=>{const e=y.useRef(null);function t(){Or.cancel(e.current)}function r(n,i=2){t();const o=Or(()=>{i<=1?n({isCanceled:()=>o!==e.current}):r(n,i-1)});e.current=o}return y.useEffect(()=>()=>{t()},[]),[r,t]}),jFe=[Jl,ny,iy,N3],KFe=[Jl,lle],fle=!1,qFe=!0;function gle(e){return e===iy||e===N3}const XFe=((e,t,r)=>{const[n,i]=v0(CK),[o,s]=UFe();function a(){i(Jl,!0)}const l=t?KFe:jFe;return ple(()=>{if(n!==CK&&n!==N3){const c=l.indexOf(n),u=l[c+1],d=r(n);d===fle?i(u,!0):u&&o(h=>{function p(){h.isCanceled()||i(u,!0)}d===!0?p():Promise.resolve(d).then(p)})}},[e,n]),y.useEffect(()=>()=>{s()},[]),[a,n]});function YFe(e,t,r,{motionEnter:n=!0,motionAppear:i=!0,motionLeave:o=!0,motionDeadline:s,motionLeaveImmediately:a,onAppearPrepare:l,onEnterPrepare:c,onLeavePrepare:u,onAppearStart:d,onEnterStart:h,onLeaveStart:p,onAppearActive:f,onEnterActive:g,onLeaveActive:m,onAppearEnd:v,onEnterEnd:b,onLeaveEnd:S,onVisibleChanged:x}){const[E,R]=v0(),[T,M]=Nae(rd),[D,A]=v0(null),I=T(),L=y.useRef(!1),F=y.useRef(null);function k(){return r()}const O=y.useRef(!1);function B(){M(rd),A(null,!0)}const H=br(oe=>{const ee=T();if(ee===rd)return;const ne=k();if(oe&&!oe.deadline&&oe.target!==ne)return;const le=O.current;let he;ee===JE&&le?he=v==null?void 0:v(ne,oe):ee===eT&&le?he=b==null?void 0:b(ne,oe):ee===tT&&le&&(he=S==null?void 0:S(ne,oe)),le&&he!==!1&&B()}),[N]=WFe(H),z=oe=>{switch(oe){case JE:return{[Jl]:l,[ny]:d,[iy]:f};case eT:return{[Jl]:c,[ny]:h,[iy]:g};case tT:return{[Jl]:u,[ny]:p,[iy]:m};default:return{}}},W=y.useMemo(()=>z(I),[I]),[V,$]=XFe(I,!e,oe=>{var ee;if(oe===Jl){const ne=W[Jl];return ne?ne(k()):fle}return $ in W&&A(((ee=W[$])==null?void 0:ee.call(W,k(),null))||null),$===iy&&I!==rd&&(N(k()),s>0&&(clearTimeout(F.current),F.current=setTimeout(()=>{H({deadline:!0})},s))),$===lle&&B(),qFe}),K=gle($);O.current=K;const q=y.useRef(null);ple(()=>{if(L.current&&q.current===t)return;R(t);const oe=L.current;L.current=!0;let ee;!oe&&t&&i&&(ee=JE),oe&&t&&n&&(ee=eT),(oe&&!t&&o||!oe&&a&&!t&&o)&&(ee=tT);const ne=z(ee);ee&&(e||ne[Jl])?(M(ee),V()):M(rd),q.current=t},[t]),y.useEffect(()=>{(I===JE&&!i||I===eT&&!n||I===tT&&!o)&&M(rd)},[i,n,o]),y.useEffect(()=>()=>{L.current=!1,clearTimeout(F.current)},[]);const X=y.useRef(!1);y.useEffect(()=>{E&&(X.current=!0),E!==void 0&&I===rd&&((X.current||E)&&(x==null||x(E)),X.current=!0)},[E,I]);let Y=D;return W[Jl]&&$===ny&&(Y={transition:"none",...Y}),[T,$,Y,E??t]}function ZFe(e){let t=e;typeof e=="object"&&({transitionSupport:t}=e);function r(i,o){return!!(i.motionName&&t&&o!==!1)}const n=y.forwardRef((i,o)=>{const{visible:s=!0,removeOnLeave:a=!0,forceRender:l,children:c,motionName:u,leavedClassName:d,eventProps:h}=i,{motion:p}=y.useContext(GFe),f=r(i,p),g=y.useRef();function m(){return pc(g.current)}const[v,b,S,x]=YFe(f,s,m,i),E=v(),R=y.useRef(x);x&&(R.current=!0);const T=y.useMemo(()=>{const A={};return Object.defineProperties(A,{nativeElement:{enumerable:!0,get:m},inMotion:{enumerable:!0,get:()=>()=>v()!==rd},enableMotion:{enumerable:!0,get:()=>()=>f}}),A},[]);y.useImperativeHandle(o,()=>T,[]);let M;const D={...h,visible:s};if(!c)M=null;else if(E===rd)x?M=c({...D},g):!a&&R.current&&d?M=c({...D,className:d},g):l||!a&&!d?M=c({...D,style:{display:"none"}},g):M=null;else{let A;b===Jl?A="prepare":gle(b)?A="active":b===ny&&(A="start");const I=xK(u,`${E}-${A}`);M=c({...D,className:Q(xK(u,E),{[I]:I&&A,[u]:typeof u=="string"}),style:S},g)}return y.isValidElement(M)&&pu(M)&&(jd(M)||(M=y.cloneElement(M,{ref:g}))),M});return n.displayName="CSSMotion",n}const gu=ZFe(HFe);function QFe(e){const{prefixCls:t,align:r,arrow:n,arrowPos:i}=e,{className:o,content:s,style:a}=n||{},{x:l=0,y:c=0}=i,u=y.useRef(null);if(!r||!r.points)return null;const d={position:"absolute"};if(r.autoArrow!==!1){const h=r.points[0],p=r.points[1],f=h[0],g=h[1],m=p[0],v=p[1];f===m||!["t","b"].includes(f)?d.top=c:f==="t"?d.top=0:d.bottom=0,g===v||!["l","r"].includes(g)?d.left=l:g==="l"?d.left=0:d.right=0}return y.createElement("div",{ref:u,className:Q(`${t}-arrow`,o),style:{...d,...a}},s)}function jB(){return jB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement("div",{style:{zIndex:n},className:Q(`${t}-mask`,s&&`${t}-mobile-mask`,a)})):null}const eLe=y.memo(({children:e})=>e,(e,t)=>t.cache);function mle(e,t,r,n,i,o,s,a){var u;const l="auto",c=e?{}:{left:"-1000vw",top:"-1000vh",right:l,bottom:l};if(!e&&(t||!r)){const{points:d}=n,h=n.dynamicInset||((u=n._experimental)==null?void 0:u.dynamicInset),p=h&&d[0][1]==="r",f=h&&d[0][0]==="b";p?(c.right=i,c.left=l):(c.left=s,c.right=l),f?(c.bottom=o,c.top=l):(c.top=a,c.bottom=l)}return c}function KB(){return KB=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{onEsc:r,popup:n,className:i,prefixCls:o,style:s,target:a,onVisibleChanged:l,open:c,keepDom:u,fresh:d,onClick:h,mask:p,arrow:f,arrowPos:g,align:m,motion:v,maskMotion:b,mobile:S,forceRender:x,getPopupContainer:E,autoDestroy:R,portal:T,children:M,zIndex:D,onMouseEnter:A,onMouseLeave:I,onPointerEnter:L,onPointerDownCapture:F,ready:k,offsetX:O,offsetY:B,offsetR:H,offsetB:N,onAlign:z,onPrepare:W,onResize:V,stretch:$,targetWidth:K,targetHeight:q}=e,X=typeof n=="function"?n():n,Y=c||u,oe=!!S,[ee,ne,le]=y.useMemo(()=>S?[S.mask,S.maskMotion,S.motion]:[p,b,v],[S,p,b,v]),he=(E==null?void 0:E.length)>0,[re,ie]=y.useState(!E||!he);jr(()=>{!re&&he&&a&&ie(!0)},[re,he,a]);const de=br((ve,pe)=>{V==null||V(ve,pe),z()}),J=mle(oe,k,c,m,H,N,O,B);if(!re)return null;const ue={};return $&&($.includes("height")&&q?ue.height=q:$.includes("minHeight")&&q&&(ue.minHeight=q),$.includes("width")&&K?ue.width=K:$.includes("minWidth")&&K&&(ue.minWidth=K)),c||(ue.pointerEvents="none"),y.createElement(T,{open:x||Y,getContainer:E&&(()=>E(a)),autoDestroy:R,onEsc:r},y.createElement(JFe,{prefixCls:o,open:c,zIndex:D,mask:ee,motion:ne,mobile:oe}),y.createElement(ta,{onResize:de,disabled:!c},ve=>y.createElement(gu,KB({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:x,leavedClassName:`${o}-hidden`},le,{onAppearPrepare:W,onEnterPrepare:W,visible:c,onVisibleChanged:pe=>{var me;(me=v==null?void 0:v.onVisibleChanged)==null||me.call(v,pe),l(pe)}}),({className:pe,style:me},ke)=>{const De=Q(o,pe,i,{[`${o}-mobile`]:oe});return y.createElement("div",{ref:Wo(ve,t,ke),className:De,style:{"--arrow-x":`${g.x||0}px`,"--arrow-y":`${g.y||0}px`,...J,...ue,...me,boxSizing:"border-box",zIndex:D,...s},onMouseEnter:A,onMouseLeave:I,onPointerEnter:L,onClick:h,onPointerDownCapture:F},f&&y.createElement(QFe,{prefixCls:o,arrow:f,arrowPos:g,align:m}),y.createElement(eLe,{cache:!c&&!d},X))})),M)}),aM=y.createContext(null),yle=y.createContext(null);function EK(e){return e?Array.isArray(e)?e:[e]:[]}function tLe(e,t,r){return y.useMemo(()=>{const n=EK(t??e),i=EK(r??e),o=new Set(n),s=new Set(i);return o.has("hover")&&!o.has("click")&&o.add("touch"),s.has("hover")&&!s.has("click")&&s.add("touch"),[o,s]},[e,t,r])}const VD=(e=>{if(!e)return!1;if(e instanceof Element){if(e.offsetParent)return!0;if(e.getBBox){const{width:t,height:r}=e.getBBox();if(t||r)return!0}if(e.getBoundingClientRect){const{width:t,height:r}=e.getBoundingClientRect();if(t||r)return!0}}return!1});function rLe(e=[],t=[],r){const n=(i,o)=>i[o]||"";return r?n(e,0)===n(t,0):n(e,0)===n(t,0)&&n(e,1)===n(t,1)}function Cle(e,t,r,n){var s;const{points:i}=r,o=Object.keys(e);for(let a=0;an.includes(a))&&t.push(r),r=r.parentElement}return t}function P0(e,t=1){return Number.isNaN(e)?t:e}function nS(e){return P0(parseFloat(e),0)}function TK(e,t){const r={...e};return(t||[]).forEach(n=>{if(n instanceof HTMLBodyElement||n instanceof HTMLHtmlElement)return;const{overflow:i,overflowClipMargin:o,borderTopWidth:s,borderBottomWidth:a,borderLeftWidth:l,borderRightWidth:c}=Ox(n).getComputedStyle(n),u=n.getBoundingClientRect(),{offsetHeight:d,clientHeight:h,offsetWidth:p,clientWidth:f}=n,g=nS(s),m=nS(a),v=nS(l),b=nS(c),S=P0(Math.round(u.width/p*1e3)/1e3),x=P0(Math.round(u.height/d*1e3)/1e3),E=(p-f-v-b)*S,R=(d-h-g-m)*x,T=g*x,M=m*x,D=v*S,A=b*S;let I=0,L=0;if(i==="clip"){const H=nS(o);I=H*S,L=H*x}const F=u.x+D-I,k=u.y+T-L,O=F+u.width+2*I-D-A-E,B=k+u.height+2*L-T-M-R;r.left=Math.max(r.left,F),r.top=Math.max(r.top,k),r.right=Math.min(r.right,O),r.bottom=Math.min(r.bottom,B)}),r}function RK(e,t=0){const r=`${t}`,n=r.match(/^(.*)\%$/);return n?e*(parseFloat(n[1])/100):parseFloat(r)}function PK(e,t){const[r,n]=t||[];return[RK(e.width,r),RK(e.height,n)]}function MK(e=""){return[e[0],e[1]]}function pv(e,t){const r=t[0],n=t[1];let i,o;return r==="t"?o=e.y:r==="b"?o=e.y+e.height:o=e.y+e.height/2,n==="l"?i=e.x:n==="r"?i=e.x+e.width:i=e.x+e.width/2,{x:i,y:o}}function bh(e,t){const r={t:"b",b:"t",l:"r",r:"l"},n=[...e];return n[t]=r[e[t]]||"c",n}function IK(e){return e.join("")}function ble(e,t,r,n,i,o,s,a){const[l,c]=y.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:i[n]||{}}),u=y.useRef(0),d=y.useMemo(()=>!t||a?[]:qB(t),[t]),h=y.useRef({});e||(()=>{h.current={}})();const f=br(()=>{var v,b;if(t&&r&&e&&!a){let Et=function(mr,Ct,vr=ue){const wn=O.x+mr,ri=O.y+Ct,Ni=wn+X,Ha=ri+q,Uo=Math.max(wn,vr.left),ks=Math.max(ri,vr.top),fa=Math.min(Ni,vr.right),Bt=Math.min(Ha,vr.bottom);return Math.max(0,(fa-Uo)*(Bt-ks))},Te=function(){Oe=O.y+nt,se=Oe+q,ce=O.x+Ae,fe=ce+X};const S=t,x=S.ownerDocument,E=Ox(S),{position:R}=E.getComputedStyle(S),T=S.style.left,M=S.style.top,D=S.style.right,A=S.style.bottom,I=S.style.overflow,L={...i[n],...o},F=x.createElement("div");(v=S.parentElement)==null||v.appendChild(F),F.style.left=`${S.offsetLeft}px`,F.style.top=`${S.offsetTop}px`,F.style.position=R,F.style.height=`${S.offsetHeight}px`,F.style.width=`${S.offsetWidth}px`,S.style.left="0",S.style.top="0",S.style.right="auto",S.style.bottom="auto",S.style.overflow="hidden";let k;if(Array.isArray(r))k={x:r[0],y:r[1],width:0,height:0};else{const mr=r.getBoundingClientRect();mr.x=mr.x??mr.left,mr.y=mr.y??mr.top,k={x:mr.x,y:mr.y,width:mr.width,height:mr.height}}const O=S.getBoundingClientRect(),{height:B,width:H}=E.getComputedStyle(S);O.x=O.x??O.left,O.y=O.y??O.top;const{clientWidth:N,clientHeight:z,scrollWidth:W,scrollHeight:V,scrollTop:$,scrollLeft:K}=x.documentElement,q=O.height,X=O.width,Y=k.height,oe=k.width,ee={left:0,top:0,right:N,bottom:z},ne={left:-K,top:-$,right:W-K,bottom:V-$};let{htmlRegion:le}=L;const he="visible",re="visibleFirst";le!=="scroll"&&le!==re&&(le=he);const ie=le===re,de=TK(ne,d),J=TK(ee,d),ue=le===he?J:de,ve=ie?J:ue;S.style.left="auto",S.style.top="auto",S.style.right="0",S.style.bottom="0";const pe=S.getBoundingClientRect();S.style.left=T,S.style.top=M,S.style.right=D,S.style.bottom=A,S.style.overflow=I,(b=S.parentElement)==null||b.removeChild(F);const me=P0(Math.round(X/parseFloat(H)*1e3)/1e3),ke=P0(Math.round(q/parseFloat(B)*1e3)/1e3);if(me===0||ke===0||By(r)&&!VD(r))return;const{offset:De,targetOffset:Ee}=L;let[We,ze]=PK(O,De);const[mt,Nt]=PK(k,Ee);k.x-=mt,k.y-=Nt;const[St,Ze]=L.points||[],Fe=MK(Ze),tt=MK(St),Ne=pv(k,Fe),rt=pv(O,tt),ot={...L};let Ye=[tt,Fe],Ae=Ne.x-rt.x+We,nt=Ne.y-rt.y+ze;const Tt=Et(Ae,nt),kt=Et(Ae,nt,J),Wt=pv(k,["t","l"]),at=pv(O,["t","l"]),lt=pv(k,["b","r"]),Ut=pv(O,["b","r"]),cr=L.overflow||{},{adjustX:_e,adjustY:qe,shiftX:Re,shiftY:it}=cr,Ve=mr=>typeof mr=="boolean"?mr:mr>=0;let Oe,se,ce,fe;Te();const $e=Ve(qe),et=tt[0]===Fe[0];if($e&&tt[0]==="t"&&(se>ve.bottom||h.current.bt)){let mr=nt;et?mr-=q-Y:mr=Wt.y-Ut.y-ze;const Ct=Et(Ae,mr),vr=Et(Ae,mr,J);Ct>Tt||Ct===Tt&&(!ie||vr>=kt)?(h.current.bt=!0,nt=mr,ze=-ze,Ye=[bh(Ye[0],0),bh(Ye[1],0)]):h.current.bt=!1}if($e&&tt[0]==="b"&&(OeTt||Ct===Tt&&(!ie||vr>=kt)?(h.current.tb=!0,nt=mr,ze=-ze,Ye=[bh(Ye[0],0),bh(Ye[1],0)]):h.current.tb=!1}const Dt=Ve(_e),ct=tt[1]===Fe[1];if(Dt&&tt[1]==="l"&&(fe>ve.right||h.current.rl)){let mr=Ae;ct?mr-=X-oe:mr=Wt.x-Ut.x-We;const Ct=Et(mr,nt),vr=Et(mr,nt,J);Ct>Tt||Ct===Tt&&(!ie||vr>=kt)?(h.current.rl=!0,Ae=mr,We=-We,Ye=[bh(Ye[0],1),bh(Ye[1],1)]):h.current.rl=!1}if(Dt&&tt[1]==="r"&&(ceTt||Ct===Tt&&(!ie||vr>=kt)?(h.current.lr=!0,Ae=mr,We=-We,Ye=[bh(Ye[0],1),bh(Ye[1],1)]):h.current.lr=!1}ot.points=[IK(Ye[0]),IK(Ye[1])],Te();const st=Re===!0?0:Re;typeof st=="number"&&(ceJ.right&&(Ae-=fe-J.right-We,k.x>J.right-st&&(Ae+=k.x-J.right+st)));const wt=it===!0?0:it;typeof wt=="number"&&(OeJ.bottom&&(nt-=se-J.bottom-ze,k.y>J.bottom-wt&&(nt+=k.y-J.bottom+wt)));const Mt=O.x+Ae,_t=Mt+X,At=O.y+nt,pt=At+q,yt=k.x,It=yt+oe,Qt=k.y,Ft=Qt+Y,ur=Math.max(Mt,yt),fr=Math.min(_t,It),yn=(ur+fr)/2-Mt,dn=Math.max(At,Qt),hn=Math.min(pt,Ft),fo=(dn+hn)/2-At;s==null||s(t,ot);let Dr=pe.right-O.x-(Ae+O.width),sn=pe.bottom-O.y-(nt+O.height);me===1&&(Ae=Math.floor(Ae),Dr=Math.floor(Dr)),ke===1&&(nt=Math.floor(nt),sn=Math.floor(sn));const ti={ready:!0,offsetX:Ae/me,offsetY:nt/ke,offsetR:Dr/me,offsetB:sn/ke,arrowX:yn/me,arrowY:fo/ke,scaleX:me,scaleY:ke,align:ot};c(ti)}}),g=()=>{u.current+=1;const v=u.current;Promise.resolve().then(()=>{u.current===v&&f()})},m=()=>{c(v=>({...v,ready:!1}))};return jr(m,[n]),jr(()=>{e||m()},[e]),[l.ready,l.offsetX,l.offsetY,l.offsetR,l.offsetB,l.arrowX,l.arrowY,l.scaleX,l.scaleY,l.align,g]}function Sle(){const e=y.useRef(null),t=()=>{e.current&&(clearTimeout(e.current),e.current=null)},r=(n,i)=>{t(),i===0?n():e.current=setTimeout(()=>{n()},i*1e3)};return y.useEffect(()=>()=>{t()},[]),r}function nLe(e,t,r,n,i){jr(()=>{if(e&&t&&r){let d=function(){n(),i()};const o=t,s=r,a=qB(o),l=qB(s),c=Ox(s),u=new Set([c,...a,...l]);return u.forEach(h=>{h.addEventListener("scroll",d,{passive:!0})}),c.addEventListener("resize",d,{passive:!0}),n(),()=>{u.forEach(h=>{h.removeEventListener("scroll",d),c.removeEventListener("resize",d)})}}},[e,t,r])}function iLe(e,t,r,n,i,o,s,a){const l=y.useRef(e);l.current=e;const c=y.useRef(!1);y.useEffect(()=>{if(t&&n&&(!i||o)){const d=()=>{c.current=!1},h=g=>{var m,v;l.current&&!s(((v=(m=g.composedPath)==null?void 0:m.call(g))==null?void 0:v[0])||g.target)&&!c.current&&a(!1)},p=Ox(n);p.addEventListener("pointerdown",d,!0),p.addEventListener("mousedown",h,!0),p.addEventListener("contextmenu",h,!0);const f=sM(r);return f&&(f.addEventListener("mousedown",h,!0),f.addEventListener("contextmenu",h,!0)),()=>{p.removeEventListener("pointerdown",d,!0),p.removeEventListener("mousedown",h,!0),p.removeEventListener("contextmenu",h,!0),f&&(f.removeEventListener("mousedown",h,!0),f.removeEventListener("contextmenu",h,!0))}}},[t,r,n,i,o]);function u(){c.current=!0}return u}function oLe(){const[e,t]=Z.useState(null),[r,n]=Z.useState(!1),[i,o]=Z.useState(!1),s=Z.useRef(null),a=br(c=>{c===!1?(s.current=null,n(!1)):i&&r?s.current=c:(n(!0),t(c),s.current=null,r||o(!0))}),l=br(c=>{c?(o(!1),s.current&&(t(s.current),s.current=null)):(o(!1),s.current=null)});return[a,r,e,l]}function XB(){return XB=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:t,isMobile:r,ready:n,open:i,align:o,offsetR:s,offsetB:a,offsetX:l,offsetY:c,arrowPos:u,popupSize:d,motion:h,uniqueContainerClassName:p,uniqueContainerStyle:f}=e,g=`${t}-unique-container`,[m,v]=Z.useState(!1),b=mle(r,n,i,o,s,a,l,c),S=Z.useRef(b);n&&(S.current=b);const x={};return d&&(x.width=d.width,x.height=d.height),Z.createElement(gu,XB({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,leavedClassName:`${g}-hidden`},h,{visible:i,onVisibleChanged:E=>{v(E)}}),({className:E,style:R})=>{const T=Q(g,E,p,{[`${g}-visible`]:m});return Z.createElement("div",{className:T,style:{"--arrow-x":`${(u==null?void 0:u.x)||0}px`,"--arrow-y":`${(u==null?void 0:u.y)||0}px`,...S.current,...x,...R,...f}})})},aLe=({children:e,postTriggerProps:t})=>{const[r,n,i,o]=oLe(),s=y.useMemo(()=>!i||!t?i:t(i),[i,t]),[a,l]=y.useState(null),[c,u]=y.useState(null),d=y.useRef(null),h=br(N=>{d.current=N,By(N)&&a!==N&&l(N)}),p=y.useRef(null),f=Sle(),g=br((N,z)=>{p.current=z,f(()=>{r(N)},N.delay)}),m=N=>{f(()=>{var z;(z=p.current)!=null&&z.call(p)||r(!1)},N)},v=br(N=>{o(N)}),[b,S,x,E,R,T,M,,,D,A]=ble(n,a,s==null?void 0:s.target,s==null?void 0:s.popupPlacement,(s==null?void 0:s.builtinPlacements)||{},s==null?void 0:s.popupAlign,void 0,!1),I=y.useMemo(()=>{var z;if(!s)return"";const N=Cle(s.builtinPlacements||{},s.prefixCls||"",D,!1);return Q(N,(z=s.getPopupClassNameFromAlign)==null?void 0:z.call(s,D))},[D,s==null?void 0:s.getPopupClassNameFromAlign,s==null?void 0:s.builtinPlacements,s==null?void 0:s.prefixCls]),L=y.useMemo(()=>({show:g,hide:m}),[]);y.useEffect(()=>{A()},[s==null?void 0:s.target]);const F=br(()=>(A(),Promise.resolve())),k=y.useRef({}),O=y.useContext(aM),B=y.useMemo(()=>({registerSubPopup:(N,z)=>{k.current[N]=z,O==null||O.registerSubPopup(N,z)}}),[O]),H=s==null?void 0:s.prefixCls;return y.createElement(yle.Provider,{value:L},e,s&&y.createElement(aM.Provider,{value:B},y.createElement(vle,{ref:h,portal:_x,onEsc:s.onEsc,prefixCls:H,popup:s.popup,className:Q(s.popupClassName,I,`${H}-unique-controlled`),style:s.popupStyle,target:s.target,open:n,keepDom:!0,fresh:!0,autoDestroy:!1,onVisibleChanged:v,ready:b,offsetX:S,offsetY:x,offsetR:E,offsetB:R,onAlign:A,onPrepare:F,onResize:N=>u({width:N.offsetWidth,height:N.offsetHeight}),arrowPos:{x:T,y:M},align:D,zIndex:s.zIndex,mask:s.mask,arrow:s.arrow,motion:s.popupMotion,maskMotion:s.maskMotion,getPopupContainer:s.getPopupContainer},y.createElement(sLe,{prefixCls:H,isMobile:!1,ready:b,open:n,align:D,offsetR:E,offsetB:R,offsetX:S,offsetY:x,arrowPos:{x:T,y:M},popupSize:c,motion:s.popupMotion,uniqueContainerClassName:Q(s.uniqueContainerClassName,I),uniqueContainerStyle:s.uniqueContainerStyle}))))};function lLe(e=_x){return y.forwardRef((r,n)=>{const{prefixCls:i="rc-trigger-popup",children:o,action:s="hover",showAction:a,hideAction:l,popupVisible:c,defaultPopupVisible:u,onOpenChange:d,afterOpenChange:h,onPopupVisibleChange:p,afterPopupVisibleChange:f,mouseEnterDelay:g,mouseLeaveDelay:m=.1,focusDelay:v,blurDelay:b,mask:S,maskClosable:x=!0,getPopupContainer:E,forceRender:R,autoDestroy:T,popup:M,popupClassName:D,uniqueContainerClassName:A,uniqueContainerStyle:I,popupStyle:L,popupPlacement:F,builtinPlacements:k={},popupAlign:O,zIndex:B,stretch:H,getPopupClassNameFromAlign:N,fresh:z,unique:W,alignPoint:V,onPopupClick:$,onPopupAlign:K,arrow:q,popupMotion:X,maskMotion:Y,mobile:oe,...ee}=r,ne=T||!1,le=c===void 0,he=!!oe,re=y.useRef({}),ie=y.useContext(aM),de=y.useMemo(()=>({registerSubPopup:(Bt,Ur)=>{re.current[Bt]=Ur,ie==null||ie.registerSubPopup(Bt,Ur)}}),[ie]),J=y.useContext(yle),ue=xc(),[ve,pe]=y.useState(null),me=y.useRef(null),ke=br(Bt=>{me.current=Bt,By(Bt)&&ve!==Bt&&pe(Bt),ie==null||ie.registerSubPopup(ue,Bt)}),[De,Ee]=y.useState(null),We=y.useRef(null),ze=br(Bt=>{const Ur=pc(Bt);By(Ur)&&De!==Ur&&(Ee(Ur),We.current=Ur)}),mt={},Nt=br(Bt=>{var Zi,Dc;const Ur=De;return(Ur==null?void 0:Ur.contains(Bt))||((Zi=sM(Ur))==null?void 0:Zi.host)===Bt||Bt===Ur||(ve==null?void 0:ve.contains(Bt))||((Dc=sM(ve))==null?void 0:Dc.host)===Bt||Bt===ve||Object.values(re.current).some(ga=>(ga==null?void 0:ga.contains(Bt))||Bt===ga)}),St=q?{...q!==!0?q:{}}:null,[Ze,Fe]=An(u||!1,c),tt=Ze||!1,Ne=y.useMemo(()=>{const Bt=typeof o=="function"?o({open:tt}):o;return y.Children.only(Bt)},[o,tt]),rt=(Ne==null?void 0:Ne.props)||{},ot=br(()=>tt),Ye=br((Bt=0)=>({popup:M,target:De,delay:Bt,prefixCls:i,popupClassName:D,uniqueContainerClassName:A,uniqueContainerStyle:I,popupStyle:L,popupPlacement:F,builtinPlacements:k,popupAlign:O,zIndex:B,mask:S,maskClosable:x,popupMotion:X,maskMotion:Y,arrow:St,getPopupContainer:E,getPopupClassNameFromAlign:N,id:ue,onEsc:kt}));jr(()=>{J&&W&&De&&!le&&!ie&&(tt?J.show(Ye(g),ot):J.hide(m))},[tt,De]);const Ae=y.useRef(tt);Ae.current=tt;const nt=br(Bt=>{$a.flushSync(()=>{tt!==Bt&&(Fe(Bt),d==null||d(Bt),p==null||p(Bt))})}),Et=Sle(),Tt=(Bt,Ur=0)=>{if(c!==void 0){Et(()=>{nt(Bt)},Ur);return}if(J&&W&&le&&!ie){Bt?J.show(Ye(Ur),ot):J.hide(Ur);return}Et(()=>{nt(Bt)},Ur)};function kt({top:Bt}){Bt&&Tt(!1)}const[Wt,at]=y.useState(!1);jr(Bt=>{(!Bt||tt)&&at(!0)},[tt]);const[lt,Ut]=y.useState(null),[cr,_e]=y.useState(null),qe=Bt=>{_e([Bt.clientX,Bt.clientY])},[Re,it,Ve,Oe,se,ce,fe,Te,$e,et,Dt]=ble(tt,ve,V&&cr!==null?cr:De,F,k,O,K,he),[ct,st]=tLe(s,a,l),wt=ct.has("click"),Mt=st.has("click")||st.has("contextMenu"),_t=br(()=>{Wt||Dt()});nLe(tt,De,ve,_t,()=>{Ae.current&&V&&Mt&&Tt(!1)}),jr(()=>{_t()},[cr,F]),jr(()=>{tt&&!(k!=null&&k[F])&&_t()},[JSON.stringify(O)]);const pt=y.useMemo(()=>{const Bt=Cle(k,i,et,V);return Q(Bt,N==null?void 0:N(et))},[et,N,k,i,V]);y.useImperativeHandle(n,()=>({nativeElement:We.current,popupElement:me.current,forceAlign:_t}));const[yt,It]=y.useState(0),[Qt,Ft]=y.useState(0),ur=()=>{if(H&&De){const Bt=De.getBoundingClientRect();It(Bt.width),Ft(Bt.height)}},fr=()=>{ur(),_t()},rr=Bt=>{at(!1),Dt(),h==null||h(Bt),f==null||f(Bt)},yn=()=>new Promise(Bt=>{ur(),Ut(()=>Bt)});jr(()=>{lt&&(Dt(),lt(),Ut(null))},[lt]);function dn(Bt,Ur,Zi,Dc,ga){mt[Bt]=(z1,...Cb)=>{var Cn;(!ga||!ga())&&(Dc==null||Dc(z1),Tt(Ur,Zi)),(Cn=rt[Bt])==null||Cn.call(rt,z1,...Cb)}}const hn=ct.has("touch"),en=st.has("touch"),fo=y.useRef(!1);(hn||en)&&(mt.onTouchStart=(...Bt)=>{var Ur;fo.current=!0,Ae.current&&en?Tt(!1):!Ae.current&&hn&&Tt(!0),(Ur=rt.onTouchStart)==null||Ur.call(rt,...Bt)}),(wt||Mt)&&(mt.onClick=(Bt,...Ur)=>{var Zi;Ae.current&&Mt?Tt(!1):!Ae.current&&wt&&(qe(Bt),Tt(!0)),(Zi=rt.onClick)==null||Zi.call(rt,Bt,...Ur),fo.current=!1});const Dr=iLe(tt,Mt||en,De,ve,S,x,Nt,Tt),sn=ct.has("hover"),ti=st.has("hover");let mr,Ct;const vr=()=>fo.current;if(sn){const Bt=Ur=>{qe(Ur)};dn("onMouseEnter",!0,g,Bt,vr),dn("onPointerEnter",!0,g,Bt,vr),mr=Ur=>{(tt||Wt)&&(ve!=null&&ve.contains(Ur.target))&&Tt(!0,g)},V&&(mt.onMouseMove=Ur=>{var Zi;(Zi=rt.onMouseMove)==null||Zi.call(rt,Ur)})}ti&&(dn("onMouseLeave",!1,m,void 0,vr),dn("onPointerLeave",!1,m,void 0,vr),Ct=()=>{Tt(!1,m)}),ct.has("focus")&&dn("onFocus",!0,v),st.has("focus")&&dn("onBlur",!1,b),ct.has("contextMenu")&&(mt.onContextMenu=(Bt,...Ur)=>{var Zi;Ae.current&&st.has("contextMenu")?Tt(!1):(qe(Bt),Tt(!0)),Bt.preventDefault(),(Zi=rt.onContextMenu)==null||Zi.call(rt,Bt,...Ur)});const wn=y.useRef(!1);wn.current||(wn.current=R||tt||Wt);const ri={...rt,...mt},Ni={};["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"].forEach(Bt=>{ee[Bt]&&(Ni[Bt]=(...Ur)=>{var Zi;(Zi=ri[Bt])==null||Zi.call(ri,...Ur),ee[Bt](...Ur)})});const Uo={x:ce,y:fe};qse(tt,De,fr);const ks=Pu(ze,jd(Ne)),fa=y.cloneElement(Ne,{...ri,...Ni,ref:ks});return y.createElement(y.Fragment,null,fa,wn.current&&(!J||!W)&&y.createElement(aM.Provider,{value:de},y.createElement(vle,{portal:e,ref:ke,prefixCls:i,popup:M,className:Q(D,!he&&pt),style:L,target:De,onMouseEnter:mr,onMouseLeave:Ct,onPointerEnter:mr,zIndex:B,open:tt,keepDom:Wt,fresh:z,onClick:$,onPointerDownCapture:Dr,mask:S,motion:X,maskMotion:Y,onVisibleChanged:rr,onPrepare:yn,forceRender:R,autoDestroy:ne,getPopupContainer:E,onEsc:kt,align:et,arrow:St,arrowPos:Uo,ready:Re,offsetX:it,offsetY:Ve,offsetR:Oe,offsetB:se,onAlign:_t,stretch:H,targetWidth:yt/Te,targetHeight:Qt/$e,mobile:oe})))})}const zD=lLe(_x);function wle(e){return e&&Z.isValidElement(e)&&e.type===Z.Fragment}const xle=(e,t,r)=>Z.isValidElement(e)?Z.cloneElement(e,typeof r=="function"?r(e.props||{}):r):t;function Ei(e,t){return xle(e,e,t)}const cLe=({children:e})=>{const{getPrefixCls:t}=Z.useContext(ir),r=t();return Z.isValidElement(e)?Z.createElement(Mu,{visible:!0,motionName:`${r}-fade`,motionAppear:!0,motionEnter:!0,motionLeave:!1,removeOnLeave:!1},({style:n,className:i})=>Ei(e,o=>({className:Q(o.className,i),style:{...o.style,...n}}))):e},nT=[null,null];function uLe(e){if(nT[0]!==e){const t={};Object.keys(e).forEach(r=>{t[r]={...e[r],dynamicInset:!1}}),nT[0]=e,nT[1]=t}return nT[1]}const Ele=({children:e})=>{const t=r=>{const{id:n,builtinPlacements:i,popup:o}=r,s=typeof o=="function"?o():o,a=uLe(i);return{...r,getPopupContainer:null,arrow:!1,popup:Z.createElement(cLe,{key:n},s),builtinPlacements:a}};return Z.createElement(aLe,{postTriggerProps:t},e)},hs=y.createContext(!1),Tle=({children:e,disabled:t})=>{const r=y.useContext(hs);return y.createElement(hs.Provider,{value:t??r},e)},zy=y.createContext(void 0),dLe=({children:e,size:t})=>{const r=y.useContext(zy);return y.createElement(zy.Provider,{value:t||r},e)};function hLe(){const e=y.useContext(hs),t=y.useContext(zy);return{componentDisabled:e,componentSize:t}}function pLe(e,t,r){MC();const n=e||{},i=n.inherit===!1||!t?{...IB,hashed:(t==null?void 0:t.hashed)??IB.hashed,cssVar:t==null?void 0:t.cssVar}:t,o=y.useId();return Pm(()=>{var c;if(!e)return t;const s={...i.components};Object.keys(e.components||{}).forEach(u=>{s[u]={...s[u],...e.components[u]}});const a=`css-var-${o.replace(/:/g,"")}`,l={prefix:r==null?void 0:r.prefixCls,...i.cssVar,...n.cssVar,key:((c=n.cssVar)==null?void 0:c.key)||a};return{...i,...n,token:{...i.token,...n.token},components:s,cssVar:l}},[n,i],(s,a)=>s.some((l,c)=>{const u=a[c];return!fc(l,u,!0)}))}const DK=y.createContext(!0);function fLe(e){const t=y.useContext(DK),{children:r}=e,[,n]=fs(),{motion:i}=n,o=y.useRef(!1);return o.current||(o.current=t!==i),o.current?y.createElement(DK.Provider,{value:i},y.createElement(RAe,{motion:i},r)):r}const gLe=()=>null,mLe=({iconPrefixCls:e,csp:t})=>(aAe(e,t),null),vLe=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let lM,Rle,Ple,Mle;function O_(){return lM||y0}function yLe(){return Rle||LD}const CLe=e=>{const{prefixCls:t,iconPrefixCls:r,theme:n,holderRender:i}=e;t!==void 0&&(lM=t),r!==void 0&&(Rle=r),"holderRender"in e&&(Mle=i),n&&(Ple=n)},bLe=()=>({getPrefixCls:(e,t)=>t||(e?`${O_()}-${e}`:O_()),getIconPrefixCls:yLe,getRootPrefixCls:()=>lM||O_(),getTheme:()=>Ple,holderRender:Mle}),SLe=e=>{const{children:t,csp:r,autoInsertSpaceInButton:n,alert:i,affix:o,anchor:s,app:a,form:l,locale:c,componentSize:u,direction:d,space:h,splitter:p,virtual:f,dropdownMatchSelectWidth:g,popupMatchSelectWidth:m,popupOverflow:v,legacyLocale:b,parentContext:S,iconPrefixCls:x,theme:E,componentDisabled:R,segmented:T,statistic:M,spin:D,calendar:A,carousel:I,cascader:L,collapse:F,typography:k,checkbox:O,descriptions:B,divider:H,drawer:N,skeleton:z,steps:W,image:V,layout:$,list:K,mentions:q,modal:X,progress:Y,result:oe,slider:ee,breadcrumb:ne,masonry:le,menu:he,pagination:re,input:ie,textArea:de,otp:J,empty:ue,badge:ve,radio:pe,rate:me,ribbon:ke,switch:De,transfer:Ee,avatar:We,message:ze,tag:mt,table:Nt,card:St,cardMeta:Ze,tabs:Fe,timeline:tt,timePicker:Ne,upload:rt,notification:ot,tree:Ye,colorPicker:Ae,datePicker:nt,rangePicker:Et,flex:Tt,wave:kt,dropdown:Wt,warning:at,tour:lt,tooltip:Ut,popover:cr,popconfirm:_e,qrcode:qe,floatButton:Re,floatButtonGroup:it,variant:Ve,inputNumber:Oe,treeSelect:se,watermark:ce}=e,fe=y.useCallback((yt,It)=>{const{prefixCls:Qt}=e;if(It)return It;const Ft=Qt||S.getPrefixCls("");return yt?`${Ft}-${yt}`:Ft},[S.getPrefixCls,e.prefixCls]),Te=x||S.iconPrefixCls||LD,$e=r||S.csp,et=pLe(E,S.theme,{prefixCls:fe("")}),Dt={csp:$e,autoInsertSpaceInButton:n,alert:i,affix:o,anchor:s,app:a,locale:c||b,direction:d,space:h,splitter:p,virtual:f,popupMatchSelectWidth:m??g,popupOverflow:v,getPrefixCls:fe,iconPrefixCls:Te,theme:et,segmented:T,statistic:M,spin:D,calendar:A,carousel:I,cascader:L,collapse:F,typography:k,checkbox:O,descriptions:B,divider:H,drawer:N,skeleton:z,steps:W,image:V,input:ie,textArea:de,otp:J,layout:$,list:K,mentions:q,modal:X,progress:Y,result:oe,slider:ee,breadcrumb:ne,masonry:le,menu:he,pagination:re,empty:ue,badge:ve,radio:pe,rate:me,ribbon:ke,switch:De,transfer:Ee,avatar:We,message:ze,tag:mt,table:Nt,card:St,cardMeta:Ze,tabs:Fe,timeline:tt,timePicker:Ne,upload:rt,notification:ot,tree:Ye,colorPicker:Ae,datePicker:nt,rangePicker:Et,flex:Tt,wave:kt,dropdown:Wt,warning:at,tour:lt,tooltip:Ut,popover:cr,popconfirm:_e,qrcode:qe,floatButton:Re,floatButtonGroup:it,variant:Ve,inputNumber:Oe,treeSelect:se,watermark:ce},ct={...S};Object.keys(Dt).forEach(yt=>{Dt[yt]!==void 0&&(ct[yt]=Dt[yt])}),vLe.forEach(yt=>{const It=e[yt];It&&(ct[yt]=It)}),typeof n<"u"&&(ct.button={autoInsertSpace:n,...ct.button});const st=Pm(()=>ct,ct,(yt,It)=>{const Qt=Object.keys(yt),Ft=Object.keys(It);return Qt.length!==Ft.length||Qt.some(ur=>yt[ur]!==It[ur])}),{layer:wt}=y.useContext(Mx),Mt=y.useMemo(()=>({prefixCls:Te,csp:$e,layer:wt?"antd":void 0}),[Te,$e,wt]);let _t=y.createElement(y.Fragment,null,y.createElement(mLe,{iconPrefixCls:Te,csp:$e}),y.createElement(gLe,{dropdownMatchSelectWidth:g}),t);const At=y.useMemo(()=>{var yt,It,Qt,Ft;return ry(((yt=xl.Form)==null?void 0:yt.defaultValidateMessages)||{},((Qt=(It=st.locale)==null?void 0:It.Form)==null?void 0:Qt.defaultValidateMessages)||{},((Ft=st.form)==null?void 0:Ft.validateMessages)||{},(l==null?void 0:l.validateMessages)||{})},[st,l==null?void 0:l.validateMessages]);Object.keys(At).length>0&&(_t=y.createElement(MFe.Provider,{value:At},_t)),c&&(_t=y.createElement(tFe,{locale:c,_ANT_MARK__:eFe},_t)),_t=y.createElement(A3.Provider,{value:Mt},_t),u&&(_t=y.createElement(dLe,{size:u},_t)),_t=y.createElement(fLe,null,_t),Ut!=null&&Ut.unique&&(_t=y.createElement(Ele,null,_t));const pt=y.useMemo(()=>{const{algorithm:yt,token:It,components:Qt,cssVar:Ft,...ur}=et||{},fr=yt&&(!Array.isArray(yt)||yt.length>0)?dB(yt):Rae,rr={};Object.entries(Qt||{}).forEach(([dn,hn])=>{const en={...hn};"algorithm"in en&&(en.algorithm===!0?en.theme=fr:(Array.isArray(en.algorithm)||typeof en.algorithm=="function")&&(en.theme=dB(en.algorithm)),delete en.algorithm),rr[dn]=en});const yn={...E0,...It};return{...ur,theme:fr,token:yn,components:rr,override:{override:yn,...rr},cssVar:Ft}},[et]);return E&&(_t=y.createElement(Pae.Provider,{value:pt},_t)),st.warning&&(_t=y.createElement(gIe.Provider,{value:st.warning},_t)),R!==void 0&&(_t=y.createElement(Tle,{disabled:R},_t)),y.createElement(ir.Provider,{value:st},_t)},Iu=e=>{const t=y.useContext(ir),r=y.useContext(_3);return y.createElement(SLe,{parentContext:t,legacyLocale:r,...e})};Iu.ConfigContext=ir;Iu.SizeContext=zy;Iu.config=CLe;Iu.useConfig=hLe;Object.defineProperty(Iu,"SizeContext",{get:()=>zy});const Zt={BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,CAPS_LOCK:20,ESC:27,SPACE:32,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,N:78,P:80,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,SEMICOLON:186,EQUALS:187,WIN_KEY:224};var wLe={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};function YB(){return YB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,YB({},e,{ref:t,icon:wLe})),rm=y.forwardRef(xLe),cM="__rc_react_root__";function Ile(e,t){const r=t[cM]||nse.createRoot(t);r.render(e),t[cM]=r}async function Dle(e){return Promise.resolve().then(()=>{var t;(t=e[cM])==null||t.unmount(),delete e[cM]})}const k_=()=>({height:0,opacity:0}),AK=e=>{const{scrollHeight:t}=e;return{height:t,opacity:1}},ELe=e=>({height:e?e.offsetHeight:0}),N_=(e,t)=>(t==null?void 0:t.deadline)===!0||t.propertyName==="height",B3=(e=y0)=>({motionName:`${e}-motion-collapse`,onAppearStart:k_,onEnterStart:k_,onAppearActive:AK,onEnterActive:AK,onLeaveStart:ELe,onLeaveActive:k_,onAppearEnd:N_,onEnterEnd:N_,onLeaveEnd:N_,motionDeadline:500}),mu=(e,t,r)=>r!==void 0?r:`${e}-${t}`,TLe=e=>{const{componentCls:t,colorPrimary:r,motionDurationSlow:n,motionEaseInOut:i,motionEaseOutCirc:o,antCls:s}=e,[,a]=Jn(s,"wave");return{[t]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:a("color",r),boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:["box-shadow 0.4s","opacity 2s"].map(l=>`${l} ${o}`).join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0},"&.wave-quick":{transition:["box-shadow","opacity"].map(l=>`${l} ${n} ${i}`).join(",")}}}}},RLe=sAe("Wave",TLe),HD=`${y0}-wave-target`;function FK(e){return e&&typeof e=="string"&&e!=="#fff"&&e!=="#ffffff"&&e!=="rgb(255, 255, 255)"&&e!=="rgba(255, 255, 255, 1)"&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&e!=="transparent"&&e!=="canvastext"}function PLe(e,t=null){const r=getComputedStyle(e),{borderTopColor:n,borderColor:i,backgroundColor:o}=r;return t&&FK(r[t])?r[t]:[n,i,o].find(FK)??null}function B_(e){return Number.isNaN(e)?0:e}const MLe=e=>{const{className:t,target:r,component:n,colorSource:i}=e,o=y.useRef(null),{getPrefixCls:s}=y.useContext(ir),a=s(),[l]=Jn(a,"wave"),[c,u]=y.useState(null),[d,h]=y.useState([]),[p,f]=y.useState(0),[g,m]=y.useState(0),[v,b]=y.useState(0),[S,x]=y.useState(0),[E,R]=y.useState(!1),T={left:p,top:g,width:v,height:S,borderRadius:d.map(A=>`${A}px`).join(" ")};c&&(T[l("color")]=c);function M(){const A=getComputedStyle(r);u(PLe(r,i));const I=A.position==="static",{borderLeftWidth:L,borderTopWidth:F}=A;f(I?r.offsetLeft:B_(-Number.parseFloat(L))),m(I?r.offsetTop:B_(-Number.parseFloat(F))),b(r.offsetWidth),x(r.offsetHeight);const{borderTopLeftRadius:k,borderTopRightRadius:O,borderBottomLeftRadius:B,borderBottomRightRadius:H}=A;h([k,O,H,B].map(N=>B_(Number.parseFloat(N))))}if(y.useEffect(()=>{if(r){const A=Or(()=>{M(),R(!0)});let I;return typeof ResizeObserver<"u"&&(I=new ResizeObserver(M),I.observe(r)),()=>{Or.cancel(A),I==null||I.disconnect()}}},[r]),!E)return null;const D=(n==="Checkbox"||n==="Radio")&&(r==null?void 0:r.classList.contains(HD));return y.createElement(Mu,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(A,I)=>{var L;if(I.deadline||I.propertyName==="opacity"){const F=(L=o.current)==null?void 0:L.parentElement;Dle(F).then(()=>{F==null||F.remove()})}return!1}},({className:A},I)=>y.createElement("div",{ref:Wo(o,I),className:Q(t,A,{"wave-quick":D}),style:T}))},ILe=(e,t)=>{var i;const{component:r}=t;if(r==="Checkbox"&&!((i=e.querySelector("input"))!=null&&i.checked))return;const n=document.createElement("div");n.style.position="absolute",n.style.left="0px",n.style.top="0px",e==null||e.insertBefore(n,e==null?void 0:e.firstChild),Ile(y.createElement(MLe,{...t,target:e}),n)},DLe=(e,t,r,n)=>{const{wave:i}=y.useContext(ir),[,o,s]=fs(),a=br(u=>{const d=e.current;if(i!=null&&i.disabled||!d)return;const h=d.querySelector(`.${HD}`)||d,{showEffect:p}=i||{};(p||ILe)(h,{className:t,token:o,component:r,event:u,hashId:s,colorSource:n})}),l=y.useRef(null);return y.useEffect(()=>()=>{Or.cancel(l.current)},[]),u=>{Or.cancel(l.current),l.current=Or(()=>{a(u)})}},kx=e=>{const{children:t,disabled:r,component:n,colorSource:i}=e,{getPrefixCls:o}=y.useContext(ir),s=y.useRef(null),a=o("wave"),l=RLe(a),c=DLe(s,Q(a,l),n,i);if(Z.useEffect(()=>{const d=s.current;if(!d||d.nodeType!==window.Node.ELEMENT_NODE||r)return;const h=p=>{!VD(p.target)||!d.getAttribute||d.getAttribute("disabled")||d.disabled||d.className.includes("disabled")&&!d.className.includes("disabled:")||d.getAttribute("aria-disabled")==="true"||d.className.includes("-leave")||c(p)};return d.addEventListener("click",h,!0),()=>{d.removeEventListener("click",h,!0)}},[r]),!Z.isValidElement(t))return t??null;const u=pu(t)?Wo(jd(t),s):s;return Ei(t,{ref:u})},ki=e=>{const t=Z.useContext(zy);return Z.useMemo(()=>e?typeof e=="string"?e??t:typeof e=="function"?e(t):t:t,[e,t])},ALe=e=>{const{componentCls:t}=e;return{[t]:{display:"inline-flex","&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"},"&-rtl":{direction:"rtl"}}}},FLe=Wr(["Space","Compact"],ALe,()=>({}),{resetStyle:!1}),WD=y.createContext(null),Wp=(e,t)=>{const r=y.useContext(WD),n=y.useMemo(()=>{if(!r)return"";const{compactDirection:i,isFirstItem:o,isLastItem:s}=r,a=i==="vertical"?"-vertical-":"-";return Q(`${e}-compact${a}item`,{[`${e}-compact${a}first-item`]:o,[`${e}-compact${a}last-item`]:s,[`${e}-compact${a}item-rtl`]:t==="rtl"})},[e,t,r]);return{compactSize:r==null?void 0:r.compactSize,compactDirection:r==null?void 0:r.compactDirection,compactItemClassnames:n}},LLe=e=>{const{children:t}=e;return y.createElement(WD.Provider,{value:null},t)},_Le=e=>{const{children:t,...r}=e;return y.createElement(WD.Provider,{value:y.useMemo(()=>r,[r])},t)},$3=e=>{const{getPrefixCls:t,direction:r}=y.useContext(ir),{size:n,direction:i,orientation:o,block:s,prefixCls:a,className:l,rootClassName:c,children:u,vertical:d,...h}=e,[p,f]=Fx(o,d,i),g=ki(R=>n??R),m=t("space-compact",a),[v]=FLe(m),b=Q(m,v,{[`${m}-rtl`]:r==="rtl",[`${m}-block`]:s,[`${m}-vertical`]:f},l,c),S=y.useContext(WD),x=Li(u),E=y.useMemo(()=>x.map((R,T)=>{const M=(R==null?void 0:R.key)||`${m}-item-${T}`;return y.createElement(_Le,{key:M,compactSize:g,compactDirection:p,isFirstItem:T===0&&(!S||(S==null?void 0:S.isFirstItem)),isLastItem:T===x.length-1&&(!S||(S==null?void 0:S.isLastItem))},R)}),[x,S,p,g,m]);return x.length===0?null:y.createElement("div",{className:b,...h},E)},Ale=y.createContext(void 0),OLe=e=>{const{getPrefixCls:t,direction:r}=y.useContext(ir),{prefixCls:n,size:i,className:o,...s}=e,a=t("btn-group",n),[,,l]=fs(),c=y.useMemo(()=>{switch(i){case"large":return"lg";case"small":return"sm";default:return""}},[i]),u=Q(a,{[`${a}-${c}`]:c,[`${a}-rtl`]:r==="rtl"},o,l);return y.createElement(Ale.Provider,{value:i},y.createElement("div",{...s,className:u}))},LK=/^[\u4E00-\u9FA5]{2}$/,ZB=LK.test.bind(LK);function G3(e){return e==="danger"?{danger:!0}:{type:e}}function _K(e){return typeof e=="string"}function $_(e){return e==="text"||e==="link"}function kLe(e,t,r,n){if(!Tn(e)||e==="")return;const i=t?" ":"";return typeof e!="string"&&typeof e!="number"&&_K(e.type)&&ZB(e.props.children)?Ei(e,o=>{const s=Q(o.className,n)||void 0,a={...r,...o.style};return{...o,children:o.children.split("").join(i),className:s,style:a}}):_K(e)?Z.createElement("span",{className:n,style:r},ZB(e)?e.split("").join(i):e):wle(e)?Z.createElement("span",{className:n,style:r},e):Ei(e,o=>({...o,className:Q(o.className,n)||void 0,style:{...o.style,...r}}))}function NLe(e,t,r,n){let i=!1;const o=[];return Z.Children.forEach(e,s=>{const a=typeof s,l=a==="string"||a==="number";if(i&&l){const c=o.length-1,u=o[c];o[c]=`${u}${s}`}else o.push(s);i=l}),Z.Children.map(o,s=>kLe(s,t,r,n))}["default","primary","danger"].concat(Pr(Ad));const Fle=y.forwardRef((e,t)=>{const{className:r,style:n,children:i,prefixCls:o}=e,s=Q(`${o}-icon`,r);return Z.createElement("span",{ref:t,className:s,style:n},i)}),OK=y.forwardRef((e,t)=>{const{prefixCls:r,className:n,style:i,iconClassName:o}=e,s=Q(`${r}-loading-icon`,n);return Z.createElement(Fle,{prefixCls:r,className:s,style:i,ref:t},Z.createElement(rm,{className:o}))}),G_=()=>({width:0,opacity:0,transform:"scale(0)"}),V_=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"}),BLe=e=>{const{prefixCls:t,loading:r,existIcon:n,className:i,style:o,mount:s}=e,a=!!r;return n?Z.createElement(OK,{prefixCls:t,className:i,style:o}):Z.createElement(Mu,{visible:a,motionName:`${t}-loading-icon-motion`,motionAppear:!s,motionEnter:!s,motionLeave:!s,removeOnLeave:!0,onAppearStart:G_,onAppearActive:V_,onEnterStart:G_,onEnterActive:V_,onLeaveStart:V_,onLeaveActive:G_},({className:l,style:c},u)=>{const d={...o,...c};return Z.createElement(OK,{prefixCls:t,className:Q(i,l),style:d,ref:u})})},V3=e=>{const{componentCls:t,antCls:r,motionDurationMid:n,motionEaseInOut:i}=e;return{[t]:{[`${r}-motion-collapse-legacy`]:{overflow:"hidden","&-active":{transition:`${["height","opacity"].map(o=>`${o} ${n} ${i}`).join(", ")} !important`}},[`${r}-motion-collapse`]:{overflow:"hidden",transition:`${["height","opacity"].map(o=>`${o} ${n} ${i}`).join(", ")} !important`}}}},kK=e=>({animationDuration:e,animationFillMode:"both"}),UD=(e,t,r,n,i=!1)=>{const o=i?"&":"";return{[` ${o}${e}-enter, ${o}${e}-appear `]:{...kK(n),animationPlayState:"paused"},[`${o}${e}-leave`]:{...kK(n),animationPlayState:"paused"},[` ${o}${e}-enter${e}-enter-active, ${o}${e}-appear${e}-appear-active `]:{animationName:t,animationPlayState:"running"},[`${o}${e}-leave${e}-leave-active`]:{animationName:r,animationPlayState:"running",pointerEvents:"none"}}},$Le=new qr("antFadeIn",{"0%":{opacity:0},"100%":{opacity:1}}),GLe=new qr("antFadeOut",{"0%":{opacity:1},"100%":{opacity:0}}),jD=(e,t=!1)=>{const{antCls:r}=e,n=`${r}-fade`,i=t?"&":"";return[UD(n,$Le,GLe,e.motionDurationMid,t),{[` ${i}${n}-enter, ${i}${n}-appear `]:{opacity:0,animationTimingFunction:"linear"},[`${i}${n}-leave`]:{animationTimingFunction:"linear"}}]},VLe=new qr("antMoveDownIn",{"0%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),zLe=new qr("antMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0}}),HLe=new qr("antMoveLeftIn",{"0%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),WLe=new qr("antMoveLeftOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),ULe=new qr("antMoveRightIn",{"0%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),jLe=new qr("antMoveRightOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),KLe=new qr("antMoveUpIn",{"0%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),qLe=new qr("antMoveUpOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0}}),XLe={"move-up":{inKeyframes:KLe,outKeyframes:qLe},"move-down":{inKeyframes:VLe,outKeyframes:zLe},"move-left":{inKeyframes:HLe,outKeyframes:WLe},"move-right":{inKeyframes:ULe,outKeyframes:jLe}},uM=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:i,outKeyframes:o}=XLe[t];return[UD(n,i,o,e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{opacity:0,animationTimingFunction:e.motionEaseOutCirc},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},z3=new qr("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),H3=new qr("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),W3=new qr("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),U3=new qr("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),YLe=new qr("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),ZLe=new qr("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}}),QLe=new qr("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),JLe=new qr("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}}),e_e={"slide-up":{inKeyframes:z3,outKeyframes:H3},"slide-down":{inKeyframes:W3,outKeyframes:U3},"slide-left":{inKeyframes:YLe,outKeyframes:ZLe},"slide-right":{inKeyframes:QLe,outKeyframes:JLe}},Tp=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:i,outKeyframes:o}=e_e[t];return[UD(n,i,o,e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:e.motionEaseOutQuint,"&-prepare":{transform:"scale(1)"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInQuint}}]},bd=()=>({"@media (prefers-reduced-motion: reduce)":{transition:"none",animation:"none"}}),t_e=new qr("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),r_e=new qr("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),NK=new qr("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),BK=new qr("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),n_e=new qr("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),i_e=new qr("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),o_e=new qr("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),s_e=new qr("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),a_e=new qr("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),l_e=new qr("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),c_e=new qr("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),u_e=new qr("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),d_e={zoom:{inKeyframes:t_e,outKeyframes:r_e},"zoom-big":{inKeyframes:NK,outKeyframes:BK},"zoom-big-fast":{inKeyframes:NK,outKeyframes:BK},"zoom-left":{inKeyframes:o_e,outKeyframes:s_e},"zoom-right":{inKeyframes:a_e,outKeyframes:l_e},"zoom-up":{inKeyframes:n_e,outKeyframes:i_e},"zoom-down":{inKeyframes:c_e,outKeyframes:u_e}},Nx=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:i,outKeyframes:o}=d_e[t];return[UD(n,i,o,t==="zoom-big-fast"?e.motionDurationFast:e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},$K=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}}),h_e=e=>{const{componentCls:t,fontSize:r,lineWidth:n,groupBorderColor:i,colorErrorHover:o}=e;return{[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:e.calc(n).mul(-1).equal(),[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,"&:hover, &:focus, &:active":{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:r}},$K(`${t}-primary`,i),$K(`${t}-danger`,o)]}},z_=e=>Math.round(Number(e||0)),p_e=e=>{if(e instanceof cn)return e;if(e&&typeof e=="object"&&"h"in e&&"b"in e){const{b:t,...r}=e;return{...r,v:t}}return typeof e=="string"&&/hsb/.test(e)?e.replace(/hsb/,"hsv"):e};class M0 extends cn{constructor(t){super(p_e(t))}toHsbString(){const t=this.toHsb(),r=z_(t.s*100),n=z_(t.b*100),i=z_(t.h),o=t.a,s=`hsb(${i}, ${r}%, ${n}%)`,a=`hsba(${i}, ${r}%, ${n}%, ${o.toFixed(o===0?0:2)})`;return o===1?s:a}toHsb(){const{v:t,...r}=this.toHsv();return{...r,b:t,a:this.a}}}const f_e=e=>e instanceof M0?e:new M0(e);f_e("#1677ff");const g_e=(e,t)=>(e==null?void 0:e.replace(/[^0-9a-f]/gi,"").slice(0,t?8:6))||"",m_e=(e,t)=>e?g_e(e,t):"";let dM=(function(){function e(t){var n;if(Kd(this,e),this.cleared=!1,t instanceof e){this.metaColor=t.metaColor.clone(),this.colors=(n=t.colors)==null?void 0:n.map(i=>({color:new e(i.color),percent:i.percent})),this.cleared=t.cleared;return}const r=Array.isArray(t);r&&t.length?(this.colors=t.map(({color:i,percent:o})=>({color:new e(i),percent:o})),this.metaColor=new M0(this.colors[0].color.metaColor)):this.metaColor=new M0(r?"":t),(!t||r&&!this.colors)&&(this.metaColor=this.metaColor.setA(0),this.cleared=!0)}return qd(e,[{key:"toHsb",value:function(){return this.metaColor.toHsb()}},{key:"toHsbString",value:function(){return this.metaColor.toHsbString()}},{key:"toHex",value:function(){return m_e(this.toHexString(),this.metaColor.a<1)}},{key:"toHexString",value:function(){return this.metaColor.toHexString()}},{key:"toRgb",value:function(){return this.metaColor.toRgb()}},{key:"toRgbString",value:function(){return this.metaColor.toRgbString()}},{key:"isGradient",value:function(){return!!this.colors&&!this.cleared}},{key:"getColors",value:function(){return this.colors||[{color:this,percent:0}]}},{key:"toCssString",value:function(){const{colors:r}=this;return r?`linear-gradient(90deg, ${r.map(i=>`${i.color.toRgbString()} ${i.percent}%`).join(", ")})`:this.metaColor.toRgbString()}},{key:"equals",value:function(r){return!r||this.isGradient()!==r.isGradient()?!1:this.isGradient()?this.colors.length===r.colors.length&&this.colors.every((n,i)=>{const o=r.colors[i];return n.percent===o.percent&&n.color.equals(o.color)}):this.toHexString()===r.toHexString()}}])})();var v_e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"};function QB(){return QB=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,QB({},e,{ref:t,icon:v_e})),JB=y.forwardRef(y_e);function hl(){return hl=Object.assign?Object.assign.bind():function(e){for(var t=1;te instanceof dM?e:new dM(e),Lle=(e,t)=>{const{r,g:n,b:i,a:o}=e.toRgb(),s=new M0(e.toRgbString()).onBackground(t).toHsv();return o<=.5?s.v>.5:r*.299+n*.587+i*.114>192},_le=e=>{const{paddingInline:t,onlyIconSize:r,borderColorDisabled:n}=e;return $r(e,{buttonPaddingHorizontal:t,buttonPaddingVertical:0,buttonIconOnlyFontSize:r,colorBorderDisabled:n})},Ole=e=>{const t=e.contentFontSize??e.fontSize,r=e.contentFontSizeSM??e.fontSize,n=e.contentFontSizeLG??e.fontSizeLG,i=e.contentLineHeight??cP(t),o=e.contentLineHeightSM??cP(r),s=e.contentLineHeightLG??cP(n),a=Lle(new dM(e.colorBgSolid),"#fff")?"#000":"#fff",l=Ad.reduce((d,h)=>({...d,[`${h}ShadowColor`]:`0 ${ae(e.controlOutlineWidth)} 0 ${tw(e[`${h}1`],e.colorBgContainer)}`}),{}),c=e.colorBgContainerDisabled,u=e.colorBgContainerDisabled;return{...l,fontWeight:400,iconGap:e.marginXS,defaultShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`,primaryShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`,dangerShadow:`0 ${e.controlOutlineWidth}px 0 ${e.colorErrorOutline}`,primaryColor:e.colorTextLightSolid,dangerColor:e.colorTextLightSolid,borderColorDisabled:e.colorBorderDisabled,defaultGhostColor:e.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:e.colorBgContainer,paddingInline:e.paddingContentHorizontal-e.lineWidth,paddingInlineLG:e.paddingContentHorizontal-e.lineWidth,paddingInlineSM:8-e.lineWidth,onlyIconSize:"inherit",onlyIconSizeSM:"inherit",onlyIconSizeLG:"inherit",groupBorderColor:e.colorPrimaryHover,linkHoverBg:"transparent",textTextColor:e.colorText,textTextHoverColor:e.colorText,textTextActiveColor:e.colorText,textHoverBg:e.colorFillTertiary,defaultColor:e.colorText,defaultBg:e.colorBgContainer,defaultBorderColor:e.colorBorder,defaultBorderColorDisabled:e.colorBorder,defaultHoverBg:e.colorBgContainer,defaultHoverColor:e.colorPrimaryHover,defaultHoverBorderColor:e.colorPrimaryHover,defaultActiveBg:e.colorBgContainer,defaultActiveColor:e.colorPrimaryActive,defaultActiveBorderColor:e.colorPrimaryActive,solidTextColor:a,contentFontSize:t,contentFontSizeSM:r,contentFontSizeLG:n,contentLineHeight:i,contentLineHeightSM:o,contentLineHeightLG:s,paddingBlock:Math.max((e.controlHeight-t*i)/2-e.lineWidth,0),paddingBlockSM:Math.max((e.controlHeightSM-r*o)/2-e.lineWidth,0),paddingBlockLG:Math.max((e.controlHeightLG-n*s)/2-e.lineWidth,0),defaultBgDisabled:c,dashedBgDisabled:u}},b_e=e=>{const{componentCls:t,antCls:r,lineWidth:n}=e,[i,o]=Jn(r,"btn");return{[t]:[{[i("border-width")]:n,[i("border-color")]:"#000",[i("border-color-hover")]:o("border-color"),[i("border-color-active")]:o("border-color"),[i("border-color-disabled")]:o("border-color"),[i("border-style")]:"solid",[i("text-color")]:"#000",[i("text-color-hover")]:o("text-color"),[i("text-color-active")]:o("text-color"),[i("text-color-disabled")]:o("text-color"),[i("bg-color")]:"#ddd",[i("bg-color-hover")]:o("bg-color"),[i("bg-color-active")]:o("bg-color"),[i("bg-color-disabled")]:e.colorBgContainerDisabled,[i("bg-color-container")]:e.colorBgContainer,[i("shadow")]:"none"},{border:[o("border-width"),o("border-style"),o("border-color")].join(" "),color:o("text-color"),backgroundColor:o("bg-color"),[`&:not(:disabled):not(${t}-disabled)`]:{"&:hover":{border:[o("border-width"),o("border-style"),o("border-color-hover")].join(" "),color:o("text-color-hover"),backgroundColor:o("bg-color-hover")},"&:active":{border:[o("border-width"),o("border-style"),o("border-color-active")].join(" "),color:o("text-color-active"),backgroundColor:o("bg-color-active")}}},{[`&${t}-variant-solid`]:{[i("solid-bg-color")]:o("color-base"),[i("solid-bg-color-hover")]:o("color-hover"),[i("solid-bg-color-active")]:o("color-active"),[i("border-color")]:"transparent",[i("text-color")]:e.colorTextLightSolid,[i("bg-color")]:o("solid-bg-color"),[i("bg-color-hover")]:o("solid-bg-color-hover"),[i("bg-color-active")]:o("solid-bg-color-active"),boxShadow:o("shadow")},[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[i("border-color")]:o("color-base"),[i("border-color-hover")]:o("color-hover"),[i("border-color-active")]:o("color-active"),[i("bg-color")]:o("bg-color-container"),[i("text-color")]:o("color-base"),[i("text-color-hover")]:o("color-hover"),[i("text-color-active")]:o("color-active"),boxShadow:o("shadow")},[`&${t}-variant-dashed`]:{[i("border-style")]:"dashed",[i("bg-color-disabled")]:e.dashedBgDisabled},[`&${t}-variant-filled`]:{[i("border-color")]:"transparent",[i("text-color")]:o("color-base"),[i("bg-color")]:o("color-light"),[i("bg-color-hover")]:o("color-light-hover"),[i("bg-color-active")]:o("color-light-active")},[`&${t}-variant-text, &${t}-variant-link`]:{[i("border-color")]:"transparent",[i("text-color")]:o("color-base"),[i("text-color-hover")]:o("color-hover"),[i("text-color-active")]:o("color-active"),[i("bg-color")]:"transparent",[i("bg-color-hover")]:"transparent",[i("bg-color-active")]:"transparent",[`&:disabled, &${e.componentCls}-disabled`]:{background:"transparent",borderColor:"transparent"}},[`&${t}-variant-text`]:{[i("bg-color-hover")]:o("color-light"),[i("bg-color-active")]:o("color-light-active")}},{[`&${t}-variant-link`]:{[i("color-base")]:e.colorLink,[i("color-hover")]:e.colorLinkHover,[i("color-active")]:e.colorLinkActive,[i("bg-color-hover")]:e.linkHoverBg},[`&${t}-color-primary`]:{[i("color-base")]:e.colorPrimary,[i("color-hover")]:e.colorPrimaryHover,[i("color-active")]:e.colorPrimaryActive,[i("color-light")]:e.colorPrimaryBg,[i("color-light-hover")]:e.colorPrimaryBgHover,[i("color-light-active")]:e.colorPrimaryBorder,[i("shadow")]:e.primaryShadow,[`&${t}-variant-solid`]:{[i("text-color")]:e.primaryColor,[i("text-color-hover")]:o("text-color"),[i("text-color-active")]:o("text-color")}},[`&${t}-color-dangerous`]:{[i("color-base")]:e.colorError,[i("color-hover")]:e.colorErrorHover,[i("color-active")]:e.colorErrorActive,[i("color-light")]:e.colorErrorBg,[i("color-light-hover")]:e.colorErrorBgFilledHover,[i("color-light-active")]:e.colorErrorBgActive,[i("shadow")]:e.dangerShadow,[`&${t}-variant-solid`]:{[i("text-color")]:e.dangerColor,[i("text-color-hover")]:o("text-color"),[i("text-color-active")]:o("text-color")}},[`&${t}-color-default`]:{[i("solid-bg-color")]:e.colorBgSolid,[i("solid-bg-color-hover")]:e.colorBgSolidHover,[i("solid-bg-color-active")]:e.colorBgSolidActive,[i("color-base")]:e.defaultBorderColor,[i("color-hover")]:e.defaultHoverBorderColor,[i("color-active")]:e.defaultActiveBorderColor,[i("color-light")]:e.colorFillTertiary,[i("color-light-hover")]:e.colorFillSecondary,[i("color-light-active")]:e.colorFill,[i("text-color")]:e.defaultColor,[i("text-color-hover")]:e.defaultHoverColor,[i("text-color-active")]:e.defaultActiveColor,[i("shadow")]:e.defaultShadow,[`&${t}-variant-outlined`]:{[i("bg-color-disabled")]:e.defaultBgDisabled},[`&${t}-variant-solid`]:{[i("text-color")]:e.solidTextColor,[i("text-color-hover")]:o("text-color"),[i("text-color-active")]:o("text-color")},[`&${t}-variant-filled, &${t}-variant-text`]:{[i("text-color-hover")]:o("text-color"),[i("text-color-active")]:o("text-color")},[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[i("text-color")]:e.defaultColor,[i("text-color-hover")]:e.defaultHoverColor,[i("text-color-active")]:e.defaultActiveColor,[i("bg-color-container")]:e.defaultBg,[i("bg-color-hover")]:e.defaultHoverBg,[i("bg-color-active")]:e.defaultActiveBg},[`&${t}-variant-text`]:{[i("text-color")]:e.textTextColor,[i("text-color-hover")]:e.textTextHoverColor,[i("text-color-active")]:e.textTextActiveColor,[i("bg-color-hover")]:e.textHoverBg},[`&${t}-background-ghost`]:{[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[i("text-color")]:e.defaultGhostColor,[i("border-color")]:e.defaultGhostBorderColor}}}},Ad.map(s=>{const a=e[`${s}6`],l=e[`${s}1`],c=e[`${s}Hover`],u=e[`${s}2`],d=e[`${s}3`],h=e[`${s}Active`],p=e[`${s}ShadowColor`];return{[`&${t}-color-${s}`]:{[i("color-base")]:a,[i("color-hover")]:c,[i("color-active")]:h,[i("color-light")]:l,[i("color-light-hover")]:u,[i("color-light-active")]:d,[i("shadow")]:p}}}),{[`&:disabled, &${e.componentCls}-disabled`]:{cursor:"not-allowed",borderColor:e.colorBorderDisabled,background:o("bg-color-disabled"),color:e.colorTextDisabled,boxShadow:"none"}},{[`&${t}-background-ghost`]:{[i("bg-color")]:e.ghostBg,[i("bg-color-hover")]:e.ghostBg,[i("bg-color-active")]:e.ghostBg,[i("shadow")]:"none",[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[i("bg-color-hover")]:e.ghostBg,[i("bg-color-active")]:e.ghostBg}}}]}},S_e=e=>{const{componentCls:t,iconCls:r,fontWeight:n,opacityLoading:i,motionDurationSlow:o,motionEaseInOut:s,iconGap:a,calc:l}=e;return{[t]:{outline:"none",position:"relative",display:"inline-flex",gap:a,alignItems:"center",justifyContent:"center",fontWeight:n,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",cursor:"pointer",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation",...bd(),"&:disabled > *":{pointerEvents:"none"},[`${t}-icon > svg`]:Ix(),"> a":{color:"currentColor"},"&:not(:disabled)":wl(e),[`&${t}-two-chinese-chars::first-letter`]:{letterSpacing:"0.34em"},[`&${t}-two-chinese-chars > *:not(${r})`]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},[`&${t}-icon-only`]:{paddingInline:0,[`&${t}-compact-item`]:{flex:"none"}},[`&${t}-loading`]:{opacity:i,cursor:"default"},[`${t}-loading-icon`]:{transition:["width","opacity","margin"].map(c=>`${c} ${o} ${s}`).join(",")},[`&:not(${t}-icon-end)`]:{[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineEnd:l(a).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineEnd:0},"&-leave-start":{marginInlineEnd:0},"&-leave-active":{marginInlineEnd:l(a).mul(-1).equal()}}},"&-icon-end":{flexDirection:"row-reverse",[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineStart:l(a).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineStart:0},"&-leave-start":{marginInlineStart:0},"&-leave-active":{marginInlineStart:l(a).mul(-1).equal()}}}}}},w_e=e=>({minWidth:e.controlHeight,paddingInline:0,borderRadius:"50%"}),j3=(e,t="")=>{const{componentCls:r,controlHeight:n,fontSize:i,borderRadius:o,buttonPaddingHorizontal:s,iconCls:a,buttonPaddingVertical:l,buttonIconOnlyFontSize:c}=e;return[{[t]:{fontSize:i,height:n,padding:`${ae(l)} ${ae(s)}`,borderRadius:o,[`&${r}-icon-only`]:{width:n,[a]:{fontSize:c}}}},{[`${r}${r}-circle${t}`]:w_e(e)},{[`${r}${r}-round${t}`]:{borderRadius:e.controlHeight,[`&:not(${r}-icon-only)`]:{paddingInline:e.buttonPaddingHorizontal}}}]},x_e=e=>{const t=$r(e,{fontSize:e.contentFontSize});return j3(t,e.componentCls)},E_e=e=>{const t=$r(e,{controlHeight:e.controlHeightSM,fontSize:e.contentFontSizeSM,padding:e.paddingXS,buttonPaddingHorizontal:e.paddingInlineSM,buttonPaddingVertical:0,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.onlyIconSizeSM});return j3(t,`${e.componentCls}-sm`)},T_e=e=>{const t=$r(e,{controlHeight:e.controlHeightLG,fontSize:e.contentFontSizeLG,buttonPaddingHorizontal:e.paddingInlineLG,buttonPaddingVertical:0,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.onlyIconSizeLG});return j3(t,`${e.componentCls}-lg`)},R_e=e=>{const{componentCls:t}=e;return{[t]:{[`&${t}-block`]:{width:"100%"}}}},P_e=Wr("Button",e=>{const t=_le(e);return[S_e(t),x_e(t),E_e(t),T_e(t),R_e(t),b_e(t),h_e(t)]},Ole,{unitless:{fontWeight:!0,contentLineHeight:!0,contentLineHeightSM:!0,contentLineHeightLG:!0}});function M_e(e,t,r,n){const{focusElCls:i,focus:o,borderElCls:s}=r,a=s?"> *":"",l=["hover",o?"focus":null,"active"].filter(Boolean).map(c=>`&:${c} ${a}`).join(",");return{[`&-item:not(${t}-last-item)`]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${n}-status-success)`]:{zIndex:2},"&-item":{[l]:{zIndex:3},...i?{[`&${i}`]:{zIndex:3}}:{},[`&[disabled] ${a}`]:{zIndex:0}}}}function I_e(e,t,r){const{borderElCls:n}=r,i=n?`> ${n}`:"";return{[`&-item:not(${t}-first-item):not(${t}-last-item) ${i}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${i}, &${e}-sm ${i}, &${e}-lg ${i}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${i}, &${e}-sm ${i}, &${e}-lg ${i}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function Bx(e,t={focus:!0}){const{componentCls:r}=e,{componentCls:n}=t,i=n||r,o=`${i}-compact`;return{[o]:{...M_e(e,o,t,i),...I_e(i,o,t)}}}function D_e(e,t,r){return{[`&-item:not(${t}-last-item)`]:{marginBottom:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${r}-status-success)`]:{zIndex:2},"&-item":{"&:hover,&:focus,&:active":{zIndex:3},"&[disabled]":{zIndex:0}}}}function A_e(e,t){return{[`&-item:not(${t}-first-item):not(${t}-last-item)`]:{borderRadius:0},[`&-item${t}-first-item:not(${t}-last-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${t}-last-item:not(${t}-first-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}}}function F_e(e){const t=`${e.componentCls}-compact-vertical`;return{[t]:{...D_e(e,t,e.componentCls),...A_e(e.componentCls,t)}}}const L_e=e=>{const{antCls:t,componentCls:r,lineWidth:n,calc:i,colorBgContainer:o}=e,s=`${r}-variant-solid:not([disabled])`,a=i(n).mul(-1).equal(),[l,c]=Jn(t,"btn"),u=d=>({[`${r}-compact${d?"-vertical":""}-item`]:{[l("compact-connect-border-color")]:c("bg-color-hover"),[`&${s}`]:{transition:"none",[`& + ${s}:before`]:[{position:"absolute",backgroundColor:c("compact-connect-border-color"),content:'""'},d?{top:a,insetInline:a,height:n}:{insetBlock:a,insetInlineStart:a,width:n}],"&:hover:before":{display:"none"}}}});return[u(),u(!0),{[`${s}${r}-color-default`]:{[l("compact-connect-border-color")]:`color-mix(in srgb, ${c("bg-color-hover")} 75%, ${o})`}}]},__e=Dx(["Button","compact"],e=>{const t=_le(e);return[Bx(t),F_e(t),L_e(t)]},Ole);function O_e(e){if(typeof e=="object"&&e){let t=e==null?void 0:e.delay;return t=!Number.isNaN(t)&&typeof t=="number"?t:0,{loading:t<=0,delay:t}}return{loading:!!e,delay:0}}const k_e={default:["default","outlined"],primary:["primary","solid"],dashed:["default","dashed"],link:["link","link"],text:["default","text"]},N_e=Z.forwardRef((e,t)=>{const{_skipSemantic:r,loading:n=!1,prefixCls:i,color:o,variant:s,type:a,danger:l=!1,shape:c,size:u,disabled:d,className:h,rootClassName:p,children:f,icon:g,iconPosition:m,iconPlacement:v,ghost:b=!1,block:S=!1,htmlType:x="button",classNames:E,styles:R,style:T,autoInsertSpace:M,autoFocus:D,...A}=e,I=Li(f),L=a||"default",{getPrefixCls:F,direction:k,autoInsertSpace:O,className:B,style:H,classNames:N,styles:z,loadingIcon:W,shape:V,color:$,variant:K}=Nr("button"),q=c||V||"default",[X,Y]=y.useMemo(()=>{if(o&&s)return[o,s];if(a||l){const qe=k_e[L]||[];return l?["danger",qe[1]]:qe}return $&&K?[$,K]:["default","outlined"]},[o,s,a,l,$,K,L]),[oe,ee]=y.useMemo(()=>b&&Y==="solid"?[X,"outlined"]:[X,Y],[X,Y,b]),ne=oe==="danger",le=ne?"dangerous":oe,he=M??O??!0,re=F("btn",i),[ie,de]=P_e(re),J=y.useContext(hs),ue=d??J,ve=y.useContext(Ale),pe=y.useMemo(()=>O_e(n),[n]),[me,ke]=y.useState(pe.loading),[De,Ee]=y.useState(!1),We=y.useRef(null),ze=Pu(t,We),mt=I.length===1&&!g&&!$_(ee),Nt=y.useRef(!0);Z.useEffect(()=>(Nt.current=!1,()=>{Nt.current=!0}),[]),jr(()=>{let qe=null;pe.delay>0?qe=setTimeout(()=>{qe=null,ke(!0)},pe.delay):ke(pe.loading);function Re(){qe&&(clearTimeout(qe),qe=null)}return Re},[pe.delay,pe.loading]),y.useEffect(()=>{if(!We.current||!he)return;const qe=We.current.textContent||"";mt&&ZB(qe)?De||Ee(!0):De&&Ee(!1)}),y.useEffect(()=>{D&&We.current&&We.current.focus()},[]);const St=Z.useCallback(qe=>{var Re;if(me||ue){qe.preventDefault();return}(Re=e.onClick)==null||Re.call(e,("href"in e,qe))},[e.onClick,me,ue]),{compactSize:Ze,compactItemClassnames:Fe}=Wp(re,k),tt=ki(qe=>u??Ze??ve??qe),Ne=me?"loading":g,rt=v??m??"start",ot=fn(A,["navigate"]),Ye={...e,type:L,color:oe,variant:ee,danger:ne,shape:q,size:tt,disabled:ue,loading:me,iconPlacement:rt},[Ae,nt]=Vr([r?void 0:N,E],[r?void 0:z,R],{props:Ye}),Et=Q(re,ie,de,{[`${re}-${q}`]:q!=="default"&&q!=="square"&&q,[`${re}-${L}`]:L,[`${re}-dangerous`]:l,[`${re}-color-${le}`]:le,[`${re}-variant-${ee}`]:ee,[`${re}-lg`]:tt==="large",[`${re}-sm`]:tt==="small",[`${re}-icon-only`]:!f&&f!==0&&!!Ne,[`${re}-background-ghost`]:b&&!$_(ee),[`${re}-loading`]:me,[`${re}-two-chinese-chars`]:De&&he&&!me,[`${re}-block`]:S,[`${re}-rtl`]:k==="rtl",[`${re}-icon-end`]:rt==="end"},Fe,h,p,B,Ae.root),Tt={...nt.root,...H,...T},kt={className:Ae.icon,style:nt.icon},Wt=qe=>Z.createElement(Fle,{prefixCls:re,...kt},qe),at=Z.createElement(BLe,{existIcon:!!g,prefixCls:re,loading:me,mount:Nt.current,...kt}),lt=n&&typeof n=="object"&&n.icon||W;let Ut;g&&!me?Ut=Wt(g):n&<?Ut=Wt(lt):Ut=at;const cr=Tn(f)?NLe(f,mt&&he,nt.content,Ae.content):null;if(ot.href!==void 0)return Z.createElement("a",{...ot,className:Q(Et,{[`${re}-disabled`]:ue}),href:ue?void 0:ot.href,style:Tt,onClick:St,ref:ze,tabIndex:ue?-1:0,"aria-disabled":ue},Ut,cr);let _e=Z.createElement("button",{...A,type:x,className:Et,style:Tt,onClick:St,disabled:ue,ref:ze},Ut,cr,Fe&&Z.createElement(__e,{prefixCls:re}));return $_(ee)||(_e=Z.createElement(kx,{component:"Button",disabled:me},_e)),_e}),ca=N_e;ca.Group=OLe;ca.__ANT_BUTTON=!0;const H_=e=>typeof(e==null?void 0:e.then)=="function",K3=e=>{const{type:t,children:r,prefixCls:n,buttonProps:i,close:o,autoFocus:s,emitEvent:a,isSilent:l,quitOnNullishReturnValue:c,actionFn:u}=e,d=y.useRef(!1),h=y.useRef(null),[p,f]=v0(!1),g=(...b)=>{o==null||o(...b)};y.useEffect(()=>{let b=null;return s&&(b=setTimeout(()=>{var S;(S=h.current)==null||S.focus({preventScroll:!0})})),()=>{b&&clearTimeout(b)}},[s]);const m=b=>{H_(b)&&(f(!0),b.then((...S)=>{f(!1,!0),g.apply(void 0,S),d.current=!1},S=>{if(f(!1,!0),d.current=!1,!(l!=null&&l()))return Promise.reject(S)}))},v=b=>{if(d.current)return;if(d.current=!0,!u){g();return}let S;if(a){if(S=u(b),c&&!H_(S)){d.current=!1,g(b);return}}else if(u.length)S=u(o),d.current=!1;else if(S=u(),!H_(S)){g();return}m(S)};return y.createElement(ca,{...G3(t),onClick:v,loading:p,prefixCls:n,...i,ref:h},r)},$x=Z.createContext({}),{Provider:kle}=$x,GK=()=>{const{autoFocusButton:e,cancelButtonProps:t,cancelTextLocale:r,isSilent:n,mergedOkCancel:i,rootPrefixCls:o,close:s,onCancel:a,onConfirm:l,onClose:c}=y.useContext($x);return i?Z.createElement(K3,{isSilent:n,actionFn:a,close:(...u)=>{s==null||s(...u),l==null||l(!1),c==null||c()},autoFocus:e==="cancel",buttonProps:t,prefixCls:`${o}-btn`},r):null},VK=()=>{const{autoFocusButton:e,close:t,isSilent:r,okButtonProps:n,rootPrefixCls:i,okTextLocale:o,okType:s,onConfirm:a,onOk:l,onClose:c}=y.useContext($x);return Z.createElement(K3,{isSilent:r,type:s||"primary",actionFn:l,close:(...u)=>{t==null||t(...u),a==null||a(!0),c==null||c()},autoFocus:e==="ok",buttonProps:n,prefixCls:`${i}-btn`},o)},Nle=y.createContext({});function zK(e,t,r){let n=t;return!n&&r&&(n=`${e}-${r}`),n}function HK(e,t){let r=e[`page${t?"Y":"X"}Offset`];const n=`scroll${t?"Top":"Left"}`;if(typeof r!="number"){const i=e.document;r=i.documentElement[n],typeof r!="number"&&(r=i.body[n])}return r}function B_e(e){const t=e.getBoundingClientRect(),r={left:t.left,top:t.top},n=e.ownerDocument,i=n.defaultView||n.parentWindow;return r.left+=HK(i),r.top+=HK(i,!0),r}function WK(e,t=!1){if(VD(e)){const r=e.nodeName.toLowerCase(),n=["input","select","textarea","button"].includes(r)||e.isContentEditable||r==="a"&&!!e.getAttribute("href"),i=e.getAttribute("tabindex"),o=Number(i);let s=null;return i&&!Number.isNaN(o)?s=o:n&&s===null&&(s=0),n&&e.disabled&&(s=null),s!==null&&(s>=0||t&&s<0)}return!1}function q3(e,t=!1){const r=[...e.querySelectorAll("*")].filter(n=>WK(n,t));return WK(e,t)&&r.unshift(e),r}function X3(e,t){if(!e)return;e.focus(t);const{cursor:r}=t||{};if(r&&(e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement)){const n=e.value.length;switch(r){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(n,n);break;default:e.setSelectionRange(0,n)}}}let by=null,$h=[];const e$=new Map,Y3=new Map;function Z3(){return $h[$h.length-1]}function $_e(e){const t=Z3();if(e&&t){let r;for(const[i,o]of e$.entries())if(o===t){r=i;break}const n=Y3.get(r);return!!n&&(n===e||n.contains(e))}return!1}function G_e(e){const{activeElement:t}=document;return e===t||e.contains(t)}function W_(){const e=Z3(),{activeElement:t}=document;if(!$_e(t))if(e&&!G_e(e)){const r=q3(e),n=r.includes(by)?by:r[0];n==null||n.focus({preventScroll:!0})}else by=t}function UK(e){if(e.key==="Tab"){const{activeElement:t}=document,r=Z3(),n=q3(r),i=n[n.length-1];e.shiftKey&&t===n[0]?by=i:!e.shiftKey&&t===i&&(by=n[0])}}function V_e(e,t){return e&&(e$.set(t,e),$h=$h.filter(r=>r!==e),$h.push(e),window.addEventListener("focusin",W_),window.addEventListener("keydown",UK,!0),W_()),()=>{by=null,$h=$h.filter(r=>r!==e),e$.delete(t),Y3.delete(t),$h.length===0&&(window.removeEventListener("focusin",W_),window.removeEventListener("keydown",UK,!0))}}function Ble(e,t){const r=xc();return y.useEffect(()=>{if(e){const i=t();if(i)return V_e(i,r)}},[e,r]),[i=>{i&&Y3.set(r,i)}]}const z_e=y.memo(({children:e})=>e,(e,{shouldUpdate:t})=>!t);function hM(){return hM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,className:n,style:i,title:o,ariaId:s,footer:a,closable:l,closeIcon:c,onClose:u,children:d,bodyStyle:h,bodyProps:p,modalRender:f,onMouseDown:g,onMouseUp:m,holderRef:v,visible:b,forceRender:S,width:x,height:E,classNames:R,styles:T,isFixedPos:M,focusTrap:D}=e,{panel:A}=Z.useContext(Nle),I=y.useRef(null),L=Pu(v,A,I),[F]=Ble(b&&M&&D!==!1,()=>I.current);Z.useImperativeHandle(t,()=>({focus:()=>{var $;($=I.current)==null||$.focus({preventScroll:!0})}}));const k={};x!==void 0&&(k.width=x),E!==void 0&&(k.height=E);const O=a?Z.createElement("div",{className:Q(`${r}-footer`,R==null?void 0:R.footer),style:{...T==null?void 0:T.footer}},a):null,B=o?Z.createElement("div",{className:Q(`${r}-header`,R==null?void 0:R.header),style:{...T==null?void 0:T.header}},Z.createElement("div",{className:Q(`${r}-title`,R==null?void 0:R.title),id:s,style:{...T==null?void 0:T.title}},o)):null,H=y.useMemo(()=>typeof l=="object"&&l!==null?l:l?{closeIcon:c??Z.createElement("span",{className:`${r}-close-x`})}:{},[l,c,r]),N=ai(H,!0),z=typeof l=="object"&&l.disabled,W=l?Z.createElement("button",hM({type:"button",onClick:u,"aria-label":"Close"},N,{className:`${r}-close`,disabled:z}),H.closeIcon):null,V=Z.createElement("div",{className:Q(`${r}-container`,R==null?void 0:R.container),style:T==null?void 0:T.container},W,B,Z.createElement("div",hM({className:Q(`${r}-body`,R==null?void 0:R.body),style:{...h,...T==null?void 0:T.body}},p),d),O);return Z.createElement("div",{key:"dialog-element",role:"dialog","aria-labelledby":o?s:null,"aria-modal":"true",ref:L,style:{...i,...k},className:Q(r,n),onMouseDown:g,onMouseUp:m,tabIndex:-1,onFocus:$=>{F($.target)}},Z.createElement(z_e,{shouldUpdate:b||S},f?f(V):V))});function t$(){return t$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,title:n,style:i,className:o,visible:s,forceRender:a,destroyOnHidden:l,motionName:c,ariaId:u,onVisibleChanged:d,mousePosition:h}=e,p=y.useRef(null),f=y.useRef(null);y.useImperativeHandle(t,()=>({...f.current,inMotion:p.current.inMotion,enableMotion:p.current.enableMotion}));const[g,m]=y.useState(),v={};g&&(v.transformOrigin=g);function b(){var x;if(!((x=p.current)!=null&&x.nativeElement))return;const S=B_e(p.current.nativeElement);m(h&&(h.x||h.y)?`${h.x-S.left}px ${h.y-S.top}px`:"")}return y.createElement(gu,{visible:s,onVisibleChanged:d,onAppearPrepare:b,onEnterPrepare:b,forceRender:a,motionName:c,removeOnLeave:l,ref:p},({className:S,style:x},E)=>y.createElement($le,t$({},e,{ref:f,title:n,ariaId:u,prefixCls:r,holderRef:E,style:{...x,...i,...v},className:Q(o,S)})))});function r$(){return r$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:t,style:r,visible:n,maskProps:i,motionName:o,className:s}=e;return y.createElement(gu,{key:"mask",visible:n,motionName:o,leavedClassName:`${t}-mask-hidden`},({className:a,style:l},c)=>y.createElement("div",r$({ref:c,style:{...l,...r},className:Q(`${t}-mask`,a,s)},i)))};function Iw(){return Iw=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:t="rc-dialog",zIndex:r,visible:n=!1,focusTriggerAfterClose:i=!0,wrapStyle:o,wrapClassName:s,wrapProps:a,onClose:l,afterOpenChange:c,afterClose:u,transitionName:d,animation:h,closable:p=!0,mask:f=!0,maskTransitionName:g,maskAnimation:m,maskClosable:v=!0,maskStyle:b,maskProps:S,rootClassName:x,rootStyle:E,classNames:R,styles:T}=e,M=y.useRef(null),D=y.useRef(null),A=y.useRef(null),[I,L]=y.useState(n),[F,k]=y.useState(!1),O=xc();function B(){aB(D.current,document.activeElement)||(M.current=document.activeElement)}function H(){var X;aB(D.current,document.activeElement)||(X=A.current)==null||X.focus()}function N(){if(L(!1),f&&M.current&&i){try{M.current.focus({preventScroll:!0})}catch{}M.current=null}I&&(u==null||u())}function z(X){X?H():N(),c==null||c(X)}function W(X){l==null||l(X)}const V=y.useRef(!1);let $=null;v&&($=X=>{D.current===X.target&&V.current&&W(X)});function K(X){V.current=X.target===D.current}y.useEffect(()=>{if(n){if(V.current=!1,L(!0),B(),D.current){const X=getComputedStyle(D.current);k(X.position==="fixed")}}else I&&A.current.enableMotion()&&!A.current.inMotion()&&N()},[n]);const q={zIndex:r,...o,...T==null?void 0:T.wrapper,display:I?null:"none"};return y.createElement("div",Iw({className:Q(`${t}-root`,x),style:E},ai(e,{data:!0})),y.createElement(W_e,{prefixCls:t,visible:f&&n,motionName:zK(t,g,m),style:{zIndex:r,...b,...T==null?void 0:T.mask},maskProps:S,className:R==null?void 0:R.mask}),y.createElement("div",Iw({className:Q(`${t}-wrap`,s,R==null?void 0:R.wrapper),ref:D,onClick:$,onMouseDown:K,style:q},a),y.createElement(H_e,Iw({},e,{isFixedPos:F,ref:A,closable:p,ariaId:O,prefixCls:t,visible:n&&I,onClose:W,onVisibleChanged:z,motionName:zK(t,d,h)}))))};function n$(){return n$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{visible:t,getContainer:r,forceRender:n,destroyOnHidden:i=!1,afterClose:o,closable:s,panelRef:a,keyboard:l=!0,onClose:c}=e,[u,d]=y.useState(t),h=y.useMemo(()=>({panel:a}),[a]),p=({top:f,event:g})=>{if(f&&l){g.stopPropagation(),c==null||c(g);return}};return y.useEffect(()=>{t&&d(!0)},[t]),!n&&i&&!u?null:y.createElement(Nle.Provider,{value:h},y.createElement(_x,{open:t||n||u,onEsc:p,autoDestroy:!1,getContainer:r,autoLock:t||u},y.createElement(U_e,n$({},e,{destroyOnHidden:i,afterClose:()=>{const f=s&&typeof s=="object"?s:{},{afterClose:g}=f||{};g==null||g(),o==null||o(),d(!1)}}))))},yg="RC_FORM_INTERNAL_HOOKS",kn=()=>{Vn(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},Hy=y.createContext({getFieldValue:kn,getFieldsValue:kn,getFieldError:kn,getFieldWarning:kn,getFieldsError:kn,isFieldsTouched:kn,isFieldTouched:kn,isFieldValidating:kn,isFieldsValidating:kn,resetFields:kn,setFields:kn,setFieldValue:kn,setFieldsValue:kn,validateFields:kn,submit:kn,getInternalHooks:()=>(kn(),{dispatch:kn,initEntityValue:kn,registerField:kn,useSubscribe:kn,setInitialValues:kn,destroyForm:kn,setCallbacks:kn,registerWatch:kn,getFields:kn,setValidateMessages:kn,setPreserve:kn,getInitialValue:kn})}),pM=y.createContext(null);function i$(e){return e==null?[]:Array.isArray(e)?e:[e]}function K_e(e){return e&&!!e._init}function o$(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",tel:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var t=JSON.parse(JSON.stringify(this));return t.clone=this.clone,t}}}var s$=o$();function q_e(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function X_e(e,t,r){if(BD())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var i=new(e.bind.apply(e,n));return r&&x0(i,r.prototype),i}function a$(e){var t=typeof Map=="function"?new Map:void 0;return a$=function(n){if(n===null||!q_e(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(t!==void 0){if(t.has(n))return t.get(n);t.set(n,i)}function i(){return X_e(n,arguments,tm(this).constructor)}return i.prototype=Object.create(n.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),x0(i,n)},a$(e)}var Y_e=/%[sdj%]/g,Z_e=function(){};function l$(e){if(!e||!e.length)return null;var t={};return e.forEach(function(r){var n=r.field;t[n]=t[n]||[],t[n].push(r)}),t}function Aa(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=o)return a;switch(a){case"%s":return String(r[i++]);case"%d":return Number(r[i++]);case"%j":try{return JSON.stringify(r[i++])}catch{return"[Circular]"}break;default:return a}});return s}return e}function Q_e(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"||e==="tel"}function ao(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||Q_e(t)&&typeof e=="string"&&!e)}function J_e(e,t,r){var n=[],i=0,o=e.length;function s(a){n.push.apply(n,Pr(a||[])),i++,i===o&&r(n)}e.forEach(function(a){t(a,s)})}function jK(e,t,r){var n=0,i=e.length;function o(s){if(s&&s.length){r(s);return}var a=n;n=n+1,at.max?i.push(Aa(o.messages[d].max,t.fullField,t.max)):a&&l&&(ut.max)&&i.push(Aa(o.messages[d].range,t.fullField,t.min,t.max))},Gle=function(t,r,n,i,o,s){t.required&&(!n.hasOwnProperty(t.field)||ao(r,s||t.type))&&i.push(Aa(o.messages.required,t.fullField))},iT;const aOe=(function(){if(iT)return iT;var e="[a-fA-F\\d:]",t=function(R){return R&&R.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(e,")|(?<=").concat(e,")(?=\\s|$))"):""},r="(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}",n="[a-fA-F\\d]{1,4}",i=["(?:".concat(n,":){7}(?:").concat(n,"|:)"),"(?:".concat(n,":){6}(?:").concat(r,"|:").concat(n,"|:)"),"(?:".concat(n,":){5}(?::").concat(r,"|(?::").concat(n,"){1,2}|:)"),"(?:".concat(n,":){4}(?:(?::").concat(n,"){0,1}:").concat(r,"|(?::").concat(n,"){1,3}|:)"),"(?:".concat(n,":){3}(?:(?::").concat(n,"){0,2}:").concat(r,"|(?::").concat(n,"){1,4}|:)"),"(?:".concat(n,":){2}(?:(?::").concat(n,"){0,3}:").concat(r,"|(?::").concat(n,"){1,5}|:)"),"(?:".concat(n,":){1}(?:(?::").concat(n,"){0,4}:").concat(r,"|(?::").concat(n,"){1,6}|:)"),"(?::(?:(?::".concat(n,"){0,5}:").concat(r,"|(?::").concat(n,"){1,7}|:))")],o="(?:%[0-9a-zA-Z]{1,})?",s="(?:".concat(i.join("|"),")").concat(o),a=new RegExp("(?:^".concat(r,"$)|(?:^").concat(s,"$)")),l=new RegExp("^".concat(r,"$")),c=new RegExp("^".concat(s,"$")),u=function(R){return R&&R.exact?a:new RegExp("(?:".concat(t(R)).concat(r).concat(t(R),")|(?:").concat(t(R)).concat(s).concat(t(R),")"),"g")};u.v4=function(E){return E&&E.exact?l:new RegExp("".concat(t(E)).concat(r).concat(t(E)),"g")},u.v6=function(E){return E&&E.exact?c:new RegExp("".concat(t(E)).concat(s).concat(t(E)),"g")};var d="(?:(?:[a-z]+:)?//)",h="(?:\\S+(?::\\S*)?@)?",p=u.v4().source,f=u.v6().source,g="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",m="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",v="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",b="(?::\\d{2,5})?",S='(?:[/?#][^\\s"]*)?',x="(?:".concat(d,"|www\\.)").concat(h,"(?:localhost|").concat(p,"|").concat(f,"|").concat(g).concat(m).concat(v,")").concat(b).concat(S);return iT=new RegExp("(?:^".concat(x,"$)"),"i"),iT});var U_={email:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,tel:/^(\+[0-9]{1,3}[-\s\u2011]?)?(\([0-9]{1,4}\)[-\s\u2011]?)?([0-9]+[-\s\u2011]?)*[0-9]+$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},rw={integer:function(t){return rw.number(t)&&parseInt(t,10)===t},float:function(t){return rw.number(t)&&!rw.integer(t)},array:function(t){return Array.isArray(t)},regexp:function(t){if(t instanceof RegExp)return!0;try{return!!new RegExp(t)}catch{return!1}},date:function(t){return typeof t.getTime=="function"&&typeof t.getMonth=="function"&&typeof t.getYear=="function"&&!isNaN(t.getTime())},number:function(t){return isNaN(t)?!1:typeof t=="number"},object:function(t){return Ui(t)==="object"&&!rw.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(U_.email)},tel:function(t){return typeof t=="string"&&t.length<=32&&!!t.match(U_.tel)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(aOe())},hex:function(t){return typeof t=="string"&&!!t.match(U_.hex)}},lOe=function(t,r,n,i,o){if(t.required&&r===void 0){Gle(t,r,n,i,o);return}var s=["integer","float","array","regexp","object","method","email","tel","number","date","url","hex"],a=t.type;s.indexOf(a)>-1?rw[a](r)||i.push(Aa(o.messages.types[a],t.fullField,t.type)):a&&Ui(r)!==t.type&&i.push(Aa(o.messages.types[a],t.fullField,t.type))},cOe=function(t,r,n,i,o){(/^\s+$/.test(r)||r==="")&&i.push(Aa(o.messages.whitespace,t.fullField))};const un={required:Gle,whitespace:cOe,type:lOe,range:sOe,enum:iOe,pattern:oOe};var uOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o)}n(s)},dOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(r==null&&!t.required)return n();un.required(t,r,i,s,o,"array"),r!=null&&(un.type(t,r,i,s,o),un.range(t,r,i,s,o))}n(s)},hOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&un.type(t,r,i,s,o)}n(s)},pOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r,"date")&&!t.required)return n();if(un.required(t,r,i,s,o),!ao(r,"date")){var l;r instanceof Date?l=r:l=new Date(r),un.type(t,l,i,s,o),l&&un.range(t,l.getTime(),i,s,o)}}n(s)},fOe="enum",gOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&un[fOe](t,r,i,s,o)}n(s)},mOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&(un.type(t,r,i,s,o),un.range(t,r,i,s,o))}n(s)},vOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&(un.type(t,r,i,s,o),un.range(t,r,i,s,o))}n(s)},yOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&un.type(t,r,i,s,o)}n(s)},COe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(r===""&&(r=void 0),ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&(un.type(t,r,i,s,o),un.range(t,r,i,s,o))}n(s)},bOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),r!==void 0&&un.type(t,r,i,s,o)}n(s)},SOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r,"string")&&!t.required)return n();un.required(t,r,i,s,o),ao(r,"string")||un.pattern(t,r,i,s,o)}n(s)},wOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r)&&!t.required)return n();un.required(t,r,i,s,o),ao(r)||un.type(t,r,i,s,o)}n(s)},xOe=function(t,r,n,i,o){var s=[],a=Array.isArray(r)?"array":Ui(r);un.required(t,r,i,s,o,a),n(s)},EOe=function(t,r,n,i,o){var s=[],a=t.required||!t.required&&i.hasOwnProperty(t.field);if(a){if(ao(r,"string")&&!t.required)return n();un.required(t,r,i,s,o,"string"),ao(r,"string")||(un.type(t,r,i,s,o),un.range(t,r,i,s,o),un.pattern(t,r,i,s,o),t.whitespace===!0&&un.whitespace(t,r,i,s,o))}n(s)},oT=function(t,r,n,i,o){var s=t.type,a=[],l=t.required||!t.required&&i.hasOwnProperty(t.field);if(l){if(ao(r,s)&&!t.required)return n();un.required(t,r,i,a,o,s),ao(r,s)||un.type(t,r,i,a,o)}n(a)};const Dw={string:EOe,method:yOe,number:COe,boolean:hOe,regexp:wOe,integer:vOe,float:mOe,array:dOe,object:bOe,enum:gOe,pattern:SOe,date:pOe,url:oT,hex:oT,email:oT,tel:oT,required:xOe,any:uOe};var Gx=(function(){function e(t){Kd(this,e),Bn(this,"rules",null),Bn(this,"_messages",s$),this.define(t)}return qd(e,[{key:"define",value:function(r){var n=this;if(!r)throw new Error("Cannot configure a schema with no rules");if(Ui(r)!=="object"||Array.isArray(r))throw new Error("Rules must be an object");this.rules={},Object.keys(r).forEach(function(i){var o=r[i];n.rules[i]=Array.isArray(o)?o:[o]})}},{key:"messages",value:function(r){return r&&(this._messages=XK(o$(),r)),this._messages}},{key:"validate",value:function(r){var n=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},s=r,a=i,l=o;if(typeof a=="function"&&(l=a,a={}),!this.rules||Object.keys(this.rules).length===0)return l&&l(null,s),Promise.resolve(s);function c(f){var g=[],m={};function v(S){if(Array.isArray(S)){var x;g=(x=g).concat.apply(x,Pr(S))}else g.push(S)}for(var b=0;b0&&arguments[0]!==void 0?arguments[0]:[],M=Array.isArray(T)?T:[T];!a.suppressWarning&&M.length&&e.warning("async-validator:",M),M.length&&m.message!==void 0&&m.message!==null&&(M=[].concat(m.message));var D=M.map(qK(m,s));if(a.first&&D.length)return p[m.field]=1,g(D);if(!v)g(D);else{if(m.required&&!f.value)return m.message!==void 0?D=[].concat(m.message).map(qK(m,s)):a.error&&(D=[a.error(m,Aa(a.messages.required,m.field))]),g(D);var A={};m.defaultField&&Object.keys(f.value).map(function(F){A[F]=m.defaultField}),A=Ci(Ci({},A),f.rule.fields);var I={};Object.keys(A).forEach(function(F){var k=A[F],O=Array.isArray(k)?k:[k];I[F]=O.map(b.bind(null,F))});var L=new e(I);L.messages(a.messages),f.rule.options&&(f.rule.options.messages=a.messages,f.rule.options.error=a.error),L.validate(f.value,f.rule.options||a,function(F){var k=[];D&&D.length&&k.push.apply(k,Pr(D)),F&&F.length&&k.push.apply(k,Pr(F)),g(k.length?k:null)})}}var x;if(m.asyncValidator)x=m.asyncValidator(m,f.value,S,f.source,a);else if(m.validator){try{x=m.validator(m,f.value,S,f.source,a)}catch(T){var E,R;(E=(R=console).error)===null||E===void 0||E.call(R,T),a.suppressValidatorError||setTimeout(function(){throw T},0),S(T.message)}x===!0?S():x===!1?S(typeof m.message=="function"?m.message(m.fullField||m.field):m.message||"".concat(m.fullField||m.field," fails")):x instanceof Array?S(x):x instanceof Error&&S(x.message)}x&&x.then&&x.then(function(){return S()},function(T){return S(T)})},function(f){c(f)},s)}},{key:"getType",value:function(r){if(r.type===void 0&&r.pattern instanceof RegExp&&(r.type="pattern"),typeof r.validator!="function"&&r.type&&!Dw.hasOwnProperty(r.type))throw new Error(Aa("Unknown rule type %s",r.type));return r.type||"string"}},{key:"getValidationMethod",value:function(r){if(typeof r.validator=="function")return r.validator;var n=Object.keys(r),i=n.indexOf("message");return i!==-1&&n.splice(i,1),n.length===1&&n[0]==="required"?Dw.required:Dw[this.getType(r)]||void 0}}]),e})();Bn(Gx,"register",function(t,r){if(typeof r!="function")throw new Error("Cannot register a validator by type, validator is not a function");Dw[t]=r});Bn(Gx,"warning",Z_e);Bn(Gx,"messages",s$);Bn(Gx,"validators",Dw);const Hs="'${name}' is not a valid ${type}",Vle={default:"Validation error on field '${name}'",required:"'${name}' is required",enum:"'${name}' must be one of [${enum}]",whitespace:"'${name}' cannot be empty",date:{format:"'${name}' is invalid for format date",parse:"'${name}' could not be parsed as date",invalid:"'${name}' is invalid date"},types:{string:Hs,method:Hs,array:Hs,object:Hs,number:Hs,date:Hs,boolean:Hs,integer:Hs,float:Hs,regexp:Hs,email:Hs,tel:Hs,url:Hs,hex:Hs},string:{len:"'${name}' must be exactly ${len} characters",min:"'${name}' must be at least ${min} characters",max:"'${name}' cannot be longer than ${max} characters",range:"'${name}' must be between ${min} and ${max} characters"},number:{len:"'${name}' must equal ${len}",min:"'${name}' cannot be less than ${min}",max:"'${name}' cannot be greater than ${max}",range:"'${name}' must be between ${min} and ${max}"},array:{len:"'${name}' must be exactly ${len} in length",min:"'${name}' cannot be less than ${min} in length",max:"'${name}' cannot be greater than ${max} in length",range:"'${name}' must be between ${min} and ${max} in length"},pattern:{mismatch:"'${name}' does not match pattern ${pattern}"}},YK=Gx;function TOe(e,t){return e.replace(/\\?\$\{\w+\}/g,r=>{if(r.startsWith("\\"))return r.slice(1);const n=r.slice(2,-1);return t[n]})}const ZK="CODE_LOGIC_ERROR";async function c$(e,t,r,n,i){const o={...r};if(delete o.ruleIndex,YK.warning=()=>{},o.validator){const h=o.validator;o.validator=(...p)=>{try{return h(...p)}catch(f){return console.error(f),Promise.reject(ZK)}}}let s=null;o&&o.type==="array"&&o.defaultField&&(s=o.defaultField,delete o.defaultField);const a=new YK({[e]:[o]}),l=ry(Vle,n.validateMessages);a.messages(l);let c=[];try{await Promise.resolve(a.validate({[e]:t},{...n}))}catch(h){h.errors&&(c=h.errors.map(({message:p},f)=>{const g=p===ZK?l.default:p;return y.isValidElement(g)?y.cloneElement(g,{key:`error_${f}`}):g}))}if(!c.length&&s&&Array.isArray(t)&&t.length>0)return(await Promise.all(t.map((p,f)=>c$(`${e}.${f}`,p,s,n,i)))).reduce((p,f)=>[...p,...f],[]);const u={...r,name:e,enum:(r.enum||[]).join(", "),...i};return c.map(h=>typeof h=="string"?TOe(h,u):h)}function ROe(e,t,r,n,i,o){const s=e.join("."),a=r.map((c,u)=>{const d=c.validator,h={...c,ruleIndex:u};return d&&(h.validator=(p,f,g)=>{let m=!1;const b=d(p,f,(...S)=>{Promise.resolve().then(()=>{Vn(!m,"Your validator function has already return a promise. `callback` will be ignored."),m||g(...S)})});m=b&&typeof b.then=="function"&&typeof b.catch=="function",Vn(m,"`callback` is deprecated. Please return a promise instead."),m&&b.then(()=>{g()}).catch(S=>{g(S||" ")})}),h}).sort(({warningOnly:c,ruleIndex:u},{warningOnly:d,ruleIndex:h})=>!!c==!!d?u-h:c?1:-1);let l;if(i===!0)l=new Promise(async(c,u)=>{for(let d=0;dc$(s,t,u,n,o).then(d=>({errors:d,rule:u})));l=(i?MOe(c):POe(c)).then(u=>Promise.reject(u))}return l.catch(c=>c),l}async function POe(e){return Promise.all(e).then(t=>[].concat(...t))}async function MOe(e){let t=0;return new Promise(r=>{e.forEach(n=>{n.then(i=>{i.errors.length&&r([i]),t+=1,t===e.length&&r([])})})})}function yi(e){return i$(e)}function QK(e,t){let r={};return t.forEach(n=>{const i=Zs(e,n);r=sl(r,n,i)}),r}function Sy(e,t,r=!1){return e&&e.some(n=>fM(t,n,r))}function fM(e,t,r=!1){return!e||!t||!r&&e.length!==t.length?!1:t.every((n,i)=>e[i]===n)}function IOe(e,t){if(e===t)return!0;if(!e&&t||e&&!t||!e||!t||typeof e!="object"||typeof t!="object")return!1;const r=Object.keys(e),n=Object.keys(t);return[...new Set([...r,...n])].every(o=>{const s=e[o],a=t[o];return typeof s=="function"&&typeof a=="function"?!0:s===a})}function DOe(e,...t){const r=t[0];return r&&r.target&&typeof r.target=="object"&&e in r.target?r.target[e]:r}function JK(e,t,r){const{length:n}=e;if(t<0||t>=n||r<0||r>=n)return e;const i=e[t],o=t-r;return o>0?[...e.slice(0,r),i,...e.slice(r,t),...e.slice(t+1,n)]:o<0?[...e.slice(0,t),...e.slice(t+1,r+1),i,...e.slice(r+1,n)]:e}async function AOe(){return new Promise(e=>{Or(()=>{e()})})}function u$(){return u$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{preserve:r,isListField:n,name:i}=this.props;this.cancelRegisterFunc&&this.cancelRegisterFunc(n,r,yi(i)),this.cancelRegisterFunc=null});Ie(this,"getNamePath",()=>{const{name:r,fieldContext:n}=this.props,{prefixName:i=[]}=n;return r!==void 0?[...i,...r]:[]});Ie(this,"getRules",()=>{const{rules:r=[],fieldContext:n}=this.props;return r.map(i=>typeof i=="function"?i(n):i)});Ie(this,"refresh",()=>{this.mounted&&this.setState(({resetCount:r})=>({resetCount:r+1}))});Ie(this,"metaCache",null);Ie(this,"triggerMetaEvent",r=>{const{onMetaChange:n}=this.props;if(n){const i={...this.getMeta(),destroy:r};fc(this.metaCache,i)||n(i),this.metaCache=i}else this.metaCache=null});Ie(this,"onStoreChange",(r,n,i)=>{const{shouldUpdate:o,dependencies:s=[],onReset:a}=this.props,{store:l}=i,c=this.getNamePath(),u=this.getValue(r),d=this.getValue(l),h=n&&Sy(n,c);switch(i.type==="valueUpdate"&&i.source==="external"&&!fc(u,d)&&(this.touched=!0,this.dirty=!0,this.validatePromise=null,this.errors=yf,this.warnings=iS,this.triggerMetaEvent()),i.type){case"reset":if(!n||h){this.touched=!1,this.dirty=!1,this.validatePromise=void 0,this.errors=yf,this.warnings=iS,this.triggerMetaEvent(),a==null||a(),this.refresh();return}break;case"remove":{if(o&&j_(o,r,l,u,d,i)){this.reRender();return}break}case"setField":{const{data:p}=i;if(h){"touched"in p&&(this.touched=p.touched),"validating"in p&&!("originRCField"in p)&&(this.validatePromise=p.validating?Promise.resolve([]):null),"errors"in p&&(this.errors=p.errors||yf),"warnings"in p&&(this.warnings=p.warnings||iS),this.dirty=!0,this.triggerMetaEvent(),this.reRender();return}else if("value"in p&&Sy(n,c,!0)){this.reRender();return}if(o&&!c.length&&j_(o,r,l,u,d,i)){this.reRender();return}break}case"dependenciesUpdate":{if(s.map(yi).some(f=>Sy(i.relatedFields,f))){this.reRender();return}break}default:if(h||(!s.length||c.length||o)&&j_(o,r,l,u,d,i)){this.reRender();return}break}o===!0&&this.reRender()});Ie(this,"validateRules",r=>{const n=this.getNamePath(),i=this.getValue(),{triggerName:o,validateOnly:s=!1,delayFrame:a}=r||{},l=Promise.resolve().then(async()=>{if(!this.mounted)return[];const{validateFirst:c=!1,messageVariables:u,validateDebounce:d}=this.props;a&&await AOe();let h=this.getRules();if(o&&(h=h.filter(f=>f).filter(f=>{const{validateTrigger:g}=f;return g?i$(g).includes(o):!0})),d&&o&&(await new Promise(f=>{setTimeout(f,d)}),this.validatePromise!==l))return[];const p=ROe(n,i,h,r,c,u);return p.catch(f=>f).then((f=yf)=>{var g;if(this.validatePromise===l){this.validatePromise=null;const m=[],v=[];(g=f.forEach)==null||g.call(f,({rule:{warningOnly:b},errors:S=yf})=>{b?v.push(...S):m.push(...S)}),this.errors=m,this.warnings=v,this.triggerMetaEvent(),this.reRender()}}),p});return s||(this.validatePromise=l,this.dirty=!0,this.errors=yf,this.warnings=iS,this.triggerMetaEvent(),this.reRender()),l});Ie(this,"isFieldValidating",()=>!!this.validatePromise);Ie(this,"isFieldTouched",()=>this.touched);Ie(this,"isFieldDirty",()=>{if(this.dirty||this.props.initialValue!==void 0)return!0;const{fieldContext:r}=this.props,{getInitialValue:n}=r.getInternalHooks(yg);return n(this.getNamePath())!==void 0});Ie(this,"getErrors",()=>this.errors);Ie(this,"getWarnings",()=>this.warnings);Ie(this,"isListField",()=>this.props.isListField);Ie(this,"isList",()=>this.props.isList);Ie(this,"isPreserve",()=>this.props.preserve);Ie(this,"getMeta",()=>(this.prevValidating=this.isFieldValidating(),{touched:this.isFieldTouched(),validating:this.prevValidating,errors:this.errors,warnings:this.warnings,name:this.getNamePath(),validated:this.validatePromise===null}));Ie(this,"getOnlyChild",r=>{if(typeof r=="function"){const i=this.getMeta();return{...this.getOnlyChild(r(this.getControlled(),i,this.props.fieldContext)),isFunction:!0}}const n=Li(r);return n.length!==1||!y.isValidElement(n[0])?{child:n,isFunction:!1}:{child:n[0],isFunction:!1}});Ie(this,"getValue",r=>{const{getFieldsValue:n}=this.props.fieldContext,i=this.getNamePath();return Zs(r||n(!0),i)});Ie(this,"getControlled",(r={})=>{const{name:n,trigger:i="onChange",validateTrigger:o,getValueFromEvent:s,normalize:a,valuePropName:l="value",getValueProps:c,fieldContext:u}=this.props,d=o!==void 0?o:u.validateTrigger,h=this.getNamePath(),{getInternalHooks:p,getFieldsValue:f}=u,{dispatch:g}=p(yg),m=this.getValue(),v=c||(R=>({[l]:R})),b=r[i],S=n!==void 0?v(m):{},x={...r,...S};return x[i]=(...R)=>{this.touched=!0,this.dirty=!0,this.triggerMetaEvent();let T;s?T=s(...R):T=DOe(l,...R),a&&(T=a(T,m,f(!0))),T!==m&&g({type:"updateValue",namePath:h,value:T}),b&&b(...R)},i$(d||[]).forEach(R=>{const T=x[R];x[R]=(...M)=>{T&&T(...M);const{rules:D}=this.props;D&&D.length&&g({type:"validateField",namePath:h,triggerName:R})}}),x});if(r.fieldContext){const{getInternalHooks:n}=r.fieldContext,{initEntityValue:i}=n(yg);i(this)}}componentDidMount(){const{shouldUpdate:r,fieldContext:n}=this.props;if(this.mounted=!0,n){const{getInternalHooks:i}=n,{registerField:o}=i(yg);this.cancelRegisterFunc=o(this)}r===!0&&this.reRender()}componentWillUnmount(){this.cancelRegister(),this.triggerMetaEvent(!0),this.mounted=!1}reRender(){this.mounted&&this.forceUpdate()}render(){const{resetCount:r}=this.state,{children:n}=this.props,{child:i,isFunction:o}=this.getOnlyChild(n);let s;return o?s=i:y.isValidElement(i)?s=y.cloneElement(i,this.getControlled(i.props)):(Vn(!i,"`children` of Field is not validate ReactElement."),s=i),y.createElement(y.Fragment,{key:r},s)}}Ie(zle,"contextType",Hy);function Hle({name:e,...t}){const r=y.useContext(Hy),n=y.useContext(pM),i=e!==void 0?yi(e):void 0,o=t.isListField??!!n;let s="keep";return o||(s=`_${(i||[]).join("_")}`),y.createElement(zle,u$({key:s,name:i,isListField:o},t,{fieldContext:r}))}function FOe({name:e,initialValue:t,children:r,rules:n,validateTrigger:i,isListField:o}){const s=y.useContext(Hy),a=y.useContext(pM),c=y.useRef({keys:[],id:0}).current,u=y.useMemo(()=>[...yi(s.prefixName)||[],...yi(e)],[s.prefixName,e]),d=y.useMemo(()=>({...s,prefixName:u}),[s,u]),h=y.useMemo(()=>({getKey:f=>{const g=u.length,m=f[g];return[c.keys[m],f.slice(g+1)]}}),[c,u]);if(typeof r!="function")return Vn(!1,"Form.List only accepts function as children."),null;const p=(f,g,{source:m})=>m==="internal"?!1:f!==g;return y.createElement(pM.Provider,{value:h},y.createElement(Hy.Provider,{value:d},y.createElement(Hle,{name:[],shouldUpdate:p,rules:n,validateTrigger:i,initialValue:t,isList:!0,isListField:o??!!a},({value:f=[],onChange:g},m)=>{const{getFieldValue:v}=s,b=()=>v(u||[])||[],S={add:(E,R)=>{const T=b();R>=0&&R<=T.length?(c.keys=[...c.keys.slice(0,R),c.id,...c.keys.slice(R)],g([...T.slice(0,R),E,...T.slice(R)])):(c.keys=[...c.keys,c.id],g([...T,E])),c.id+=1},remove:E=>{const R=b(),T=new Set(Array.isArray(E)?E:[E]);T.size<=0||(c.keys=c.keys.filter((M,D)=>!T.has(D)),g(R.filter((M,D)=>!T.has(D))))},move(E,R){if(E===R)return;const T=b();E<0||E>=T.length||R<0||R>=T.length||(c.keys=JK(c.keys,E,R),g(JK(T,E,R)))}};let x=f||[];return Array.isArray(x)||(x=[]),r(x.map((E,R)=>{let T=c.keys[R];return T===void 0&&(c.keys[R]=c.id,T=c.keys[R],c.id+=1),{name:R,key:T,isListField:!0}}),S,m)})))}function LOe(e){let t=!1,r=e.length;const n=[];return e.length?new Promise((i,o)=>{e.forEach((s,a)=>{s.catch(l=>(t=!0,l)).then(l=>{r-=1,n[a]=l,!(r>0)&&(t&&o(n),i(n))})})}):Promise.resolve([])}const d$="__@field_split__";function sT(e){return e.map(t=>`${typeof t}:${t}`).join(d$)}class gv{constructor(){Ie(this,"kvs",new Map)}set(t,r){this.kvs.set(sT(t),r)}get(t){return this.kvs.get(sT(t))}getAsPrefix(t){const r=sT(t),n=r+d$,i=[],o=this.kvs.get(r);return o!==void 0&&i.push(o),this.kvs.forEach((s,a)=>{a.startsWith(n)&&i.push(s)}),i}update(t,r){const n=this.get(t),i=r(n);i?this.set(t,i):this.delete(t)}delete(t){this.kvs.delete(sT(t))}map(t){return[...this.kvs.entries()].map(([r,n])=>{const i=r.split(d$);return t({key:i.map(o=>{const[,s,a]=o.match(/^([^:]*):(.*)$/);return s==="number"?Number(a):a}),value:n})})}toJSON(){const t={};return this.map(({key:r,value:n})=>(t[r.join(".")]=n,null)),t}}const _Oe=e=>{const t=new MessageChannel;t.port1.onmessage=e,t.port2.postMessage(null)};class OOe{constructor(t){Ie(this,"namePathList",[]);Ie(this,"taskId",0);Ie(this,"watcherList",new Set);Ie(this,"form");this.form=t}register(t){return this.watcherList.add(t),()=>{this.watcherList.delete(t)}}notify(t){t.forEach(r=>{this.namePathList.every(n=>!fM(n,r))&&this.namePathList.push(r)}),this.doBatch()}doBatch(){this.taskId+=1;const t=this.taskId;_Oe(()=>{if(t===this.taskId&&this.watcherList.size){const r=this.form.getForm(),n=r.getFieldsValue(),i=r.getFieldsValue(!0);this.watcherList.forEach(o=>{o(n,i,this.namePathList)}),this.namePathList=[]}})}}class kOe{constructor(t){Ie(this,"formHooked",!1);Ie(this,"forceRootUpdate");Ie(this,"subscribable",!0);Ie(this,"store",{});Ie(this,"fieldEntities",[]);Ie(this,"initialValues",{});Ie(this,"callbacks",{});Ie(this,"validateMessages",null);Ie(this,"preserve",null);Ie(this,"lastValidatePromise",null);Ie(this,"watcherCenter",new OOe(this));Ie(this,"getForm",()=>({getFieldValue:this.getFieldValue,getFieldsValue:this.getFieldsValue,getFieldError:this.getFieldError,getFieldWarning:this.getFieldWarning,getFieldsError:this.getFieldsError,isFieldsTouched:this.isFieldsTouched,isFieldTouched:this.isFieldTouched,isFieldValidating:this.isFieldValidating,isFieldsValidating:this.isFieldsValidating,resetFields:this.resetFields,setFields:this.setFields,setFieldValue:this.setFieldValue,setFieldsValue:this.setFieldsValue,validateFields:this.validateFields,submit:this.submit,_init:!0,getInternalHooks:this.getInternalHooks}));Ie(this,"getInternalHooks",t=>t===yg?(this.formHooked=!0,{dispatch:this.dispatch,initEntityValue:this.initEntityValue,registerField:this.registerField,useSubscribe:this.useSubscribe,setInitialValues:this.setInitialValues,destroyForm:this.destroyForm,setCallbacks:this.setCallbacks,setValidateMessages:this.setValidateMessages,getFields:this.getFields,setPreserve:this.setPreserve,getInitialValue:this.getInitialValue,registerWatch:this.registerWatch}):(Vn(!1,"`getInternalHooks` is internal usage. Should not call directly."),null));Ie(this,"useSubscribe",t=>{this.subscribable=t});Ie(this,"prevWithoutPreserves",null);Ie(this,"setInitialValues",(t,r)=>{var n;if(this.initialValues=t||{},r){let i=ry(t,this.store);(n=this.prevWithoutPreserves)==null||n.map(({key:o})=>{i=sl(i,o,Zs(t,o))}),this.prevWithoutPreserves=null,this.updateStore(i)}});Ie(this,"destroyForm",t=>{if(t)this.updateStore({});else{const r=new gv;this.getFieldEntities(!0).forEach(n=>{this.isMergedPreserve(n.isPreserve())||r.set(n.getNamePath(),!0)}),this.prevWithoutPreserves=r}});Ie(this,"getInitialValue",t=>{const r=Zs(this.initialValues,t);return t.length?ry(r):r});Ie(this,"setCallbacks",t=>{this.callbacks=t});Ie(this,"setValidateMessages",t=>{this.validateMessages=t});Ie(this,"setPreserve",t=>{this.preserve=t});Ie(this,"registerWatch",t=>this.watcherCenter.register(t));Ie(this,"notifyWatch",(t=[])=>{this.watcherCenter.notify(t)});Ie(this,"timeoutId",null);Ie(this,"warningUnhooked",()=>{});Ie(this,"updateStore",t=>{this.store=t});Ie(this,"getFieldEntities",(t=!1)=>t?this.fieldEntities.filter(r=>r.getNamePath().length):this.fieldEntities);Ie(this,"getFieldsMap",(t=!1)=>{const r=new gv;return this.getFieldEntities(t).forEach(n=>{const i=n.getNamePath();r.set(i,n)}),r});Ie(this,"getFieldEntitiesForNamePathList",(t,r=!1)=>{if(!t)return this.getFieldEntities(!0);const n=this.getFieldsMap(!0);return r?t.flatMap(i=>{const o=yi(i),s=n.getAsPrefix(o);return s.length?s:[{INVALIDATE_NAME_PATH:o}]}):t.map(i=>{const o=yi(i);return n.get(o)||{INVALIDATE_NAME_PATH:yi(i)}})});Ie(this,"getFieldsValue",(t,r)=>{this.warningUnhooked();let n,i;if(t===!0||Array.isArray(t)?(n=t,i=r):t&&typeof t=="object"&&(i=t.filter),n===!0&&!i)return this.store;const o=this.getFieldEntitiesForNamePathList(Array.isArray(n)?n:null,!0),s=[],a=[];o.forEach(c=>{var d;const u=c.INVALIDATE_NAME_PATH||c.getNamePath();if((d=c.isList)!=null&&d.call(c)){a.push(u);return}if(!i)s.push(u);else{const h="getMeta"in c?c.getMeta():null;i(h)&&s.push(u)}});let l=QK(this.store,s.map(yi));return a.forEach(c=>{Zs(l,c)||(l=sl(l,c,[]))}),l});Ie(this,"getFieldValue",t=>{this.warningUnhooked();const r=yi(t);return Zs(this.store,r)});Ie(this,"getFieldsError",t=>(this.warningUnhooked(),this.getFieldEntitiesForNamePathList(t).map((n,i)=>n&&!n.INVALIDATE_NAME_PATH?{name:n.getNamePath(),errors:n.getErrors(),warnings:n.getWarnings()}:{name:yi(t[i]),errors:[],warnings:[]})));Ie(this,"getFieldError",t=>{this.warningUnhooked();const r=yi(t);return this.getFieldsError([r])[0].errors});Ie(this,"getFieldWarning",t=>{this.warningUnhooked();const r=yi(t);return this.getFieldsError([r])[0].warnings});Ie(this,"isFieldsTouched",(...t)=>{this.warningUnhooked();const[r,n]=t;let i,o=!1;t.length===0?i=null:t.length===1?Array.isArray(r)?(i=r.map(yi),o=!1):(i=null,o=r):(i=r.map(yi),o=n);const s=this.getFieldEntities(!0),a=d=>d.isFieldTouched();if(!i)return o?s.every(d=>a(d)||d.isList()):s.some(a);const l=new gv;i.forEach(d=>{l.set(d,[])}),s.forEach(d=>{const h=d.getNamePath();i.forEach(p=>{p.every((f,g)=>h[g]===f)&&l.update(p,f=>[...f,d])})});const c=d=>d.some(a),u=l.map(({value:d})=>d);return o?u.every(c):u.some(c)});Ie(this,"isFieldTouched",t=>(this.warningUnhooked(),this.isFieldsTouched([t])));Ie(this,"isFieldsValidating",t=>{this.warningUnhooked();const r=this.getFieldEntities();if(!t)return r.some(i=>i.isFieldValidating());const n=t.map(yi);return r.some(i=>{const o=i.getNamePath();return Sy(n,o)&&i.isFieldValidating()})});Ie(this,"isFieldValidating",t=>(this.warningUnhooked(),this.isFieldsValidating([t])));Ie(this,"resetWithFieldInitialValue",(t={})=>{const r=new gv,n=this.getFieldEntities(!0);n.forEach(s=>{const{initialValue:a}=s.props,l=s.getNamePath();if(a!==void 0){const c=r.get(l)||new Set;c.add({entity:s,value:a}),r.set(l,c)}});const i=s=>{s.forEach(a=>{const{initialValue:l}=a.props;if(l!==void 0){const c=a.getNamePath();if(this.getInitialValue(c)!==void 0)Vn(!1,`Form already set 'initialValues' with path '${c.join(".")}'. Field can not overwrite it.`);else{const d=r.get(c);if(d&&d.size>1)Vn(!1,`Multiple Field with path '${c.join(".")}' set 'initialValue'. Can not decide which one to pick.`);else if(d){const h=this.getFieldValue(c);!a.isListField()&&(!t.skipExist||h===void 0)&&this.updateStore(sl(this.store,c,[...d][0].value))}}}})};let o;t.entities?o=t.entities:t.namePathList?(o=[],t.namePathList.forEach(s=>{const a=r.get(s);a&&o.push(...[...a].map(l=>l.entity))})):o=n,i(o)});Ie(this,"resetFields",t=>{this.warningUnhooked();const r=this.store;if(!t){this.updateStore(ry(this.initialValues)),this.resetWithFieldInitialValue(),this.notifyObservers(r,null,{type:"reset"}),this.notifyWatch();return}const n=t.map(yi);n.forEach(i=>{const o=this.getInitialValue(i);this.updateStore(sl(this.store,i,o))}),this.resetWithFieldInitialValue({namePathList:n}),this.notifyObservers(r,n,{type:"reset"}),this.notifyWatch(n)});Ie(this,"setFields",t=>{this.warningUnhooked();const r=this.store,n=[];t.forEach(i=>{const{name:o,...s}=i,a=yi(o);n.push(a),"value"in s&&this.updateStore(sl(this.store,a,s.value)),this.notifyObservers(r,[a],{type:"setField",data:i})}),this.notifyWatch(n)});Ie(this,"getFields",()=>this.getFieldEntities(!0).map(n=>{const i=n.getNamePath(),s={...n.getMeta(),name:i,value:this.getFieldValue(i)};return Object.defineProperty(s,"originRCField",{value:!0}),s}));Ie(this,"initEntityValue",t=>{const{initialValue:r}=t.props;if(r!==void 0){const n=t.getNamePath();Zs(this.store,n)===void 0&&this.updateStore(sl(this.store,n,r))}});Ie(this,"isMergedPreserve",t=>(t!==void 0?t:this.preserve)??!0);Ie(this,"registerField",t=>{this.fieldEntities.push(t);const r=t.getNamePath();if(this.notifyWatch([r]),t.props.initialValue!==void 0){const n=this.store;this.resetWithFieldInitialValue({entities:[t],skipExist:!0}),this.notifyObservers(n,[t.getNamePath()],{type:"valueUpdate",source:"internal"})}return(n,i,o=[])=>{if(this.fieldEntities=this.fieldEntities.filter(s=>s!==t),!this.isMergedPreserve(i)&&(!n||o.length>1)){const s=n?void 0:this.getInitialValue(r);if(r.length&&this.getFieldValue(r)!==s&&this.fieldEntities.every(a=>!fM(a.getNamePath(),r))){const a=this.store;this.updateStore(sl(a,r,s,!0)),this.notifyObservers(a,[r],{type:"remove"}),this.triggerDependenciesUpdate(a,r)}}this.notifyWatch([r])}});Ie(this,"dispatch",t=>{switch(t.type){case"updateValue":{const{namePath:r,value:n}=t;this.updateValue(r,n);break}case"validateField":{const{namePath:r,triggerName:n}=t;this.validateFields([r],{triggerName:n});break}}});Ie(this,"notifyObservers",(t,r,n)=>{if(this.subscribable){const i={...n,store:this.getFieldsValue(!0)};this.getFieldEntities().forEach(({onStoreChange:o})=>{o(t,r,i)})}else this.forceRootUpdate()});Ie(this,"triggerDependenciesUpdate",(t,r)=>{const n=this.getDependencyChildrenFields(r);return n.length&&this.validateFields(n,{delayFrame:!0}),this.notifyObservers(t,n,{type:"dependenciesUpdate",relatedFields:[r,...n]}),n});Ie(this,"updateValue",(t,r)=>{const n=yi(t),i=this.store;this.updateStore(sl(this.store,n,r)),this.notifyObservers(i,[n],{type:"valueUpdate",source:"internal"}),this.notifyWatch([n]);const o=this.triggerDependenciesUpdate(i,n),{onValuesChange:s}=this.callbacks;if(s){const a=this.getFieldsMap(!0).get(n),l=QK(this.store,[n]),c=this.getFieldsValue(),u=Use([c,l],{prepareArray:d=>a!=null&&a.isList()?[]:[...d||[]]});s(l,u)}this.triggerOnFieldsChange([n,...o])});Ie(this,"setFieldsValue",t=>{this.warningUnhooked();const r=this.store;if(t){const n=ry(this.store,t);this.updateStore(n)}this.notifyObservers(r,null,{type:"valueUpdate",source:"external"}),this.notifyWatch()});Ie(this,"setFieldValue",(t,r)=>{this.setFields([{name:t,value:r,errors:[],warnings:[],touched:!0}])});Ie(this,"getDependencyChildrenFields",t=>{const r=new Set,n=[],i=new gv;this.getFieldEntities().forEach(s=>{const{dependencies:a}=s.props;(a||[]).forEach(l=>{const c=yi(l);i.update(c,(u=new Set)=>(u.add(s),u))})});const o=s=>{(i.get(s)||new Set).forEach(l=>{if(!r.has(l)){r.add(l);const c=l.getNamePath();l.isFieldDirty()&&c.length&&(n.push(c),o(c))}})};return o(t),n});Ie(this,"triggerOnFieldsChange",(t,r)=>{const{onFieldsChange:n}=this.callbacks;if(n){const i=this.getFields();if(r){const s=new gv;r.forEach(({name:a,errors:l})=>{s.set(a,l)}),i.forEach(a=>{a.errors=s.get(a.name)||a.errors})}const o=i.filter(({name:s})=>Sy(t,s));o.length&&n(o,i)}});Ie(this,"validateFields",(t,r)=>{this.warningUnhooked();let n,i;Array.isArray(t)||typeof t=="string"||typeof r=="string"?(n=t,i=r):i=t;const o=!!n,s=o?n.map(yi):[],a=[...s],l=[],c=String(Date.now()),u=new Set,{recursive:d,dirty:h}=i||{};this.getFieldEntities(!0).forEach(m=>{const v=m.getNamePath();if(o||((!m.isList()||!s.some(b=>fM(b,v,!0)))&&a.push(v),s.push(v)),!(!m.props.rules||!m.props.rules.length)&&!(h&&!m.isFieldDirty())&&(u.add(v.join(c)),!o||Sy(s,v,d))){const b=m.validateRules({validateMessages:{...Vle,...this.validateMessages},...i});l.push(b.then(()=>({name:v,errors:[],warnings:[]})).catch(S=>{var R;const x=[],E=[];return(R=S.forEach)==null||R.call(S,({rule:{warningOnly:T},errors:M})=>{T?E.push(...M):x.push(...M)}),x.length?Promise.reject({name:v,errors:x,warnings:E}):{name:v,errors:x,warnings:E}}))}});const p=LOe(l);this.lastValidatePromise=p,p.catch(m=>m).then(m=>{const v=m.map(({name:b})=>b);this.notifyObservers(this.store,v,{type:"validateFinish"}),this.triggerOnFieldsChange(v,m)});const f=p.then(()=>this.lastValidatePromise===p?Promise.resolve(this.getFieldsValue(a)):Promise.reject([])).catch(m=>{var S,x;const v=m.filter(E=>E&&E.errors.length),b=(x=(S=v[0])==null?void 0:S.errors)==null?void 0:x[0];return Promise.reject({message:b,values:this.getFieldsValue(s),errorFields:v,outOfDate:this.lastValidatePromise!==p})});f.catch(m=>m);const g=s.filter(m=>u.has(m.join(c)));return this.triggerOnFieldsChange(g),f});Ie(this,"submit",()=>{this.warningUnhooked(),this.validateFields().then(t=>{const{onFinish:r}=this.callbacks;if(r)try{r(t)}catch(n){console.error(n)}}).catch(t=>{const{onFinishFailed:r}=this.callbacks;r&&r(t)})});this.forceRootUpdate=t}}function Wle(e){const t=y.useRef(null),[,r]=y.useState({});if(!t.current)if(e)t.current=e;else{const n=()=>{r({})},i=new kOe(n);t.current=i.getForm()}return[t.current]}const h$=y.createContext({triggerFormChange:()=>{},triggerFormFinish:()=>{},registerForm:()=>{},unregisterForm:()=>{}}),NOe=({validateMessages:e,onFormChange:t,onFormFinish:r,children:n})=>{const i=y.useContext(h$),o=y.useRef({});return y.createElement(h$.Provider,{value:{...i,validateMessages:{...i.validateMessages,...e},triggerFormChange:(s,a)=>{t&&t(s,{changedFields:a,forms:o.current}),i.triggerFormChange(s,a)},triggerFormFinish:(s,a)=>{r&&r(s,{values:a,forms:o.current}),i.triggerFormFinish(s,a)},registerForm:(s,a)=>{s&&(o.current={...o.current,[s]:a}),i.registerForm(s,a)},unregisterForm:s=>{const a={...o.current};delete a[s],o.current=a,i.unregisterForm(s)}}},n)};function p$(){return p$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const m=y.useRef(null),v=y.useContext(h$),[b]=Wle(n),{useSubscribe:S,setInitialValues:x,setCallbacks:E,setValidateMessages:R,setPreserve:T,destroyForm:M}=b.getInternalHooks(yg);y.useImperativeHandle(g,()=>({...b,nativeElement:m.current})),y.useEffect(()=>(v.registerForm(e,b),()=>{v.unregisterForm(e)}),[v,b,e]),R({...v.validateMessages,...a}),E({onValuesChange:c,onFieldsChange:(O,...B)=>{v.triggerFormChange(e,O),u&&u(O,...B)},onFinish:O=>{v.triggerFormFinish(e,O),d&&d(O)},onFinishFailed:h}),T(i);const D=y.useRef(null);x(t,!D.current),D.current||(D.current=!0),y.useEffect(()=>()=>M(p),[]);let A;const I=typeof o=="function";if(I){const O=b.getFieldsValue(!0);A=o(O,b)}else A=o;S(!I);const L=y.useRef(null);y.useEffect(()=>{IOe(L.current||[],r||[])||b.setFields(r||[]),L.current=r},[r,b]);const F=y.useMemo(()=>({...b,validateTrigger:l}),[b,l]),k=y.createElement(pM.Provider,{value:null},y.createElement(Hy.Provider,{value:F},A));return s===!1?k:y.createElement(s,p$({},f,{ref:m,onSubmit:O=>{O.preventDefault(),O.stopPropagation(),b.submit()},onReset:O=>{var B;O.preventDefault(),b.resetFields(),(B=f.onReset)==null||B.call(f,O)}}),k)};function K_(e){try{return JSON.stringify(e)}catch{return Math.random()}}function $Oe(...e){const[t,r={}]=e,n=K_e(r)?{form:r}:r,i=n.form,[o,s]=y.useState(()=>typeof t=="function"?t({}):void 0),a=y.useMemo(()=>K_(o),[o]),l=y.useRef(a);l.current=a;const c=y.useContext(Hy),u=i||c,d=u&&u._init,{getFieldsValue:h,getInternalHooks:p}=u,{registerWatch:f}=p(yg),g=br((v,b)=>{const S=n.preserve?b??h(!0):v??h(),x=typeof t=="function"?t(S):Zs(S,yi(t));K_(o)!==K_(x)&&s(x)}),m=typeof t=="function"?t:JSON.stringify(t);return y.useEffect(()=>{d&&g()},[d,m]),y.useEffect(()=>d?f((b,S)=>{g(b,S)}):void 0,[d]),o}const GOe=y.forwardRef(BOe),Vx=GOe;Vx.FormProvider=NOe;Vx.Field=Hle;Vx.List=FOe;Vx.useForm=Wle;Vx.useWatch=$Oe;const ua=y.createContext({}),VOe=({children:e,status:t,override:r})=>{const n=y.useContext(ua),i=y.useMemo(()=>{const o={...n};return r&&delete o.isFormItemInput,t&&(delete o.status,delete o.hasFeedback,delete o.feedbackIcon),o},[t,r,n]);return y.createElement(ua.Provider,{value:i},e)},zOe=y.createContext(void 0),Rp=e=>{const{space:t,form:r,children:n}=e;if(!Tn(n))return null;let i=n;return r&&(i=Z.createElement(VOe,{override:!0,status:!0},i)),t&&(i=Z.createElement(LLe,null,i)),i},HOe=e=>{if(To()&&window.document.documentElement){const t=Array.isArray(e)?e:[e],{documentElement:r}=window.document;return t.some(n=>n in r.style)}return!1};function eq(e,t){return HOe(e)}const WOe=()=>To()&&window.document.documentElement;function Ule(e,t,r){return y.useMemo(()=>({...{trap:t??!0,focusTriggerAfterClose:r??!0},...e}),[e,t,r])}const KD=e=>{const{prefixCls:t,className:r,style:n,size:i,shape:o}=e,s=Q({[`${t}-lg`]:i==="large",[`${t}-sm`]:i==="small"}),a=Q({[`${t}-circle`]:o==="circle",[`${t}-square`]:o==="square",[`${t}-round`]:o==="round"}),l=y.useMemo(()=>typeof i=="number"?{width:i,height:i,lineHeight:`${i}px`}:{},[i]);return y.createElement("span",{className:Q(t,s,a,r),style:{...l,...n}})},UOe=new qr("ant-skeleton-loading",{"0%":{backgroundPosition:"100% 50%"},"100%":{backgroundPosition:"0 50%"}}),Q3=e=>({height:e,lineHeight:ae(e)}),pp=e=>({width:e,...Q3(e)}),jOe=e=>({background:e.skeletonLoadingBackground,backgroundSize:"400% 100%",animationName:UOe,animationDuration:e.skeletonLoadingMotionDuration,animationTimingFunction:"ease",animationIterationCount:"infinite"}),q_=(e,t)=>({width:t(e).mul(5).equal(),minWidth:t(e).mul(5).equal(),...Q3(e)}),KOe=e=>{const{skeletonAvatarCls:t,gradientFromColor:r,controlHeight:n,controlHeightLG:i,controlHeightSM:o}=e;return{[t]:{display:"inline-block",verticalAlign:"top",background:r,...pp(n)},[`${t}${t}-circle`]:{borderRadius:"50%"},[`${t}${t}-lg`]:{...pp(i)},[`${t}${t}-sm`]:{...pp(o)}}},qOe=e=>{const{controlHeight:t,borderRadiusSM:r,skeletonInputCls:n,controlHeightLG:i,controlHeightSM:o,gradientFromColor:s,calc:a}=e;return{[n]:{display:"inline-block",verticalAlign:"top",background:s,borderRadius:r,...q_(t,a)},[`${n}-lg`]:{...q_(i,a)},[`${n}-sm`]:{...q_(o,a)}}},jle=e=>{const{gradientFromColor:t,borderRadiusSM:r,imageSizeBase:n,calc:i}=e;return{display:"inline-flex",alignItems:"center",justifyContent:"center",verticalAlign:"middle",background:t,borderRadius:r,...pp(i(n).mul(2).equal())}},XOe=e=>({[e.skeletonNodeCls]:{...jle(e)}}),YOe=e=>{const{skeletonImageCls:t,imageSizeBase:r,calc:n}=e;return{[t]:{...jle(e),[`${t}-path`]:{fill:"#bfbfbf"},[`${t}-svg`]:{...pp(r),maxWidth:n(r).mul(4).equal(),maxHeight:n(r).mul(4).equal()},[`${t}-svg${t}-svg-circle`]:{borderRadius:"50%"}},[`${t}${t}-circle`]:{borderRadius:"50%"}}},X_=(e,t,r)=>{const{skeletonButtonCls:n}=e;return{[`${r}${n}-circle`]:{width:t,minWidth:t,borderRadius:"50%"},[`${r}${n}-round`]:{borderRadius:t}}},Y_=(e,t)=>({width:t(e).mul(2).equal(),minWidth:t(e).mul(2).equal(),...Q3(e)}),ZOe=e=>{const{borderRadiusSM:t,skeletonButtonCls:r,controlHeight:n,controlHeightLG:i,controlHeightSM:o,gradientFromColor:s,calc:a}=e;return{[r]:{display:"inline-block",verticalAlign:"top",background:s,borderRadius:t,width:a(n).mul(2).equal(),minWidth:a(n).mul(2).equal(),...Y_(n,a)},...X_(e,n,r),[`${r}-lg`]:{...Y_(i,a)},...X_(e,i,`${r}-lg`),[`${r}-sm`]:{...Y_(o,a)},...X_(e,o,`${r}-sm`)}},QOe=e=>{const{componentCls:t,skeletonAvatarCls:r,skeletonTitleCls:n,skeletonParagraphCls:i,skeletonButtonCls:o,skeletonInputCls:s,skeletonNodeCls:a,skeletonImageCls:l,controlHeight:c,controlHeightLG:u,controlHeightSM:d,gradientFromColor:h,padding:p,marginSM:f,borderRadius:g,titleHeight:m,blockRadius:v,paragraphLiHeight:b,controlHeightXS:S,paragraphMarginTop:x}=e;return{[t]:{display:"table",width:"100%",[`${t}-header`]:{display:"table-cell",paddingInlineEnd:p,verticalAlign:"top",[r]:{display:"inline-block",verticalAlign:"top",background:h,...pp(c)},[`${r}-circle`]:{borderRadius:"50%"},[`${r}-lg`]:{...pp(u)},[`${r}-sm`]:{...pp(d)}},[`${t}-section`]:{display:"table-cell",width:"100%",verticalAlign:"top",[n]:{width:"100%",height:m,background:h,borderRadius:v,[`+ ${i}`]:{marginBlockStart:d}},[i]:{padding:0,"> li":{width:"100%",height:b,listStyle:"none",background:h,borderRadius:v,"+ li":{marginBlockStart:S}}},[`${i}> li:last-child:not(:first-child):not(:nth-child(2))`]:{width:"61%"}},[`&-round ${t}-section`]:{[`${n}, ${i} > li`]:{borderRadius:g}}},[`${t}-with-avatar ${t}-section`]:{[n]:{marginBlockStart:f,[`+ ${i}`]:{marginBlockStart:x}}},[`${t}${t}-element`]:{display:"inline-block",width:"auto",...ZOe(e),...KOe(e),...qOe(e),...XOe(e),...YOe(e)},[`${t}${t}-block`]:{width:"100%",[o]:{width:"100%"},[s]:{width:"100%"}},[`${t}${t}-active`]:{[` ${n}, ${i} > li, ${r}, ${o}, ${s}, ${a}, ${l} `]:{...jOe(e)}}}},JOe=e=>{const{colorFillContent:t,colorFill:r}=e,n=t,i=r;return{color:n,colorGradientEnd:i,gradientFromColor:n,gradientToColor:i,titleHeight:e.controlHeight/2,blockRadius:e.borderRadiusSM,paragraphMarginTop:e.marginLG+e.marginXXS,paragraphLiHeight:e.controlHeight/2}},zx=Wr("Skeleton",e=>{const{componentCls:t,calc:r}=e,n=$r(e,{skeletonAvatarCls:`${t}-avatar`,skeletonTitleCls:`${t}-title`,skeletonParagraphCls:`${t}-paragraph`,skeletonButtonCls:`${t}-button`,skeletonInputCls:`${t}-input`,skeletonNodeCls:`${t}-node`,skeletonImageCls:`${t}-image`,imageSizeBase:r(e.controlHeight).mul(1.5).equal(),borderRadius:100,skeletonLoadingBackground:`linear-gradient(90deg, ${e.gradientFromColor} 25%, ${e.gradientToColor} 37%, ${e.gradientFromColor} 63%)`,skeletonLoadingMotionDuration:"1.4s"});return QOe(n)},JOe,{deprecatedTokens:[["color","gradientFromColor"],["colorGradientEnd","gradientToColor"]]}),eke=e=>{const{prefixCls:t,className:r,classNames:n,rootClassName:i,active:o,style:s,styles:a,shape:l="circle",size:c,...u}=e,{getPrefixCls:d}=y.useContext(ir),h=d("skeleton",t),[p,f]=zx(h),g=ki(v=>c??v),m=Q(h,`${h}-element`,{[`${h}-active`]:o},n==null?void 0:n.root,r,i,p,f);return y.createElement("div",{className:m,style:a==null?void 0:a.root},y.createElement(KD,{prefixCls:`${h}-avatar`,className:n==null?void 0:n.content,style:{...a==null?void 0:a.content,...s},shape:l,size:g,...u}))},tke=e=>{const{prefixCls:t,className:r,rootClassName:n,classNames:i,active:o,style:s,styles:a,block:l=!1,size:c,...u}=e,{getPrefixCls:d}=y.useContext(ir),h=d("skeleton",t),[p,f]=zx(h),g=ki(v=>c??v),m=Q(h,`${h}-element`,{[`${h}-active`]:o,[`${h}-block`]:l},i==null?void 0:i.root,r,n,p,f);return y.createElement("div",{className:m,style:a==null?void 0:a.root},y.createElement(KD,{prefixCls:`${h}-button`,className:i==null?void 0:i.content,style:{...a==null?void 0:a.content,...s},size:g,...u}))},Kle=e=>{const{prefixCls:t,className:r,classNames:n,rootClassName:i,internalClassName:o,style:s,styles:a,active:l,children:c}=e,{getPrefixCls:u}=y.useContext(ir),d=u("skeleton",t),[h,p]=zx(d),f=Q(d,`${d}-element`,{[`${d}-active`]:l},h,n==null?void 0:n.root,r,i,p);return y.createElement("div",{className:f,style:a==null?void 0:a.root},y.createElement("div",{className:Q(n==null?void 0:n.content,o||`${d}-node`),style:{...a==null?void 0:a.content,...s}},c))},rke=e=>{const{getPrefixCls:t}=y.useContext(ir),r=t("skeleton",e.prefixCls);return y.createElement(Kle,{...e,internalClassName:`${r}-image`},y.createElement("svg",{viewBox:"0 0 1098 1024",xmlns:"http://www.w3.org/2000/svg",className:`${r}-image-svg`},y.createElement("title",null,"Image placeholder"),y.createElement("path",{d:"M365.7 329.1q0 45.8-32 77.7t-77.7 32-77.7-32-32-77.7 32-77.6 77.7-32 77.7 32 32 77.6M951 548.6v256H146.3V694.9L329 512l91.5 91.4L713 311zm54.8-402.3H91.4q-7.4 0-12.8 5.4T73 164.6v694.8q0 7.5 5.5 12.9t12.8 5.4h914.3q7.5 0 12.9-5.4t5.4-12.9V164.6q0-7.5-5.4-12.9t-12.9-5.4m91.4 18.3v694.8q0 37.8-26.8 64.6t-64.6 26.9H91.4q-37.7 0-64.6-26.9T0 859.4V164.6q0-37.8 26.8-64.6T91.4 73h914.3q37.8 0 64.6 26.9t26.8 64.6",className:`${r}-image-path`})))},nke=e=>{const{prefixCls:t,className:r,classNames:n,rootClassName:i,active:o,block:s,style:a,styles:l,size:c,...u}=e,{getPrefixCls:d}=y.useContext(ir),h=d("skeleton",t),[p,f]=zx(h),g=ki(v=>c??v),m=Q(h,`${h}-element`,{[`${h}-active`]:o,[`${h}-block`]:s},n==null?void 0:n.root,r,i,p,f);return y.createElement("div",{className:m,style:l==null?void 0:l.root},y.createElement(KD,{prefixCls:`${h}-input`,className:n==null?void 0:n.content,style:{...l==null?void 0:l.content,...a},size:g,...u}))},ike=(e,t)=>{const{width:r,rows:n=2}=t;if(Array.isArray(r))return r[e];if(n-1===e)return r},oke=e=>{const{prefixCls:t,className:r,style:n,rows:i=0}=e,o=Array.from({length:i}).map((s,a)=>y.createElement("li",{key:a,style:{width:ike(a,e)}}));return y.createElement("ul",{className:Q(t,r),style:n},o)},ske=({prefixCls:e,className:t,width:r,style:n})=>y.createElement("h3",{className:Q(e,t),style:{width:r,...n}});function Z_(e){return e&&typeof e=="object"?e:{}}function ake(e,t){return e&&!t?{size:"large",shape:"square"}:{size:"large",shape:"circle"}}function lke(e,t){return!e&&t?{width:"38%"}:e&&t?{width:"50%"}:{}}function cke(e,t){const r={};return(!e||!t)&&(r.width="61%"),!e&&t?r.rows=3:r.rows=2,r}const Up=e=>{const{prefixCls:t,loading:r,className:n,rootClassName:i,classNames:o,style:s,styles:a,children:l,avatar:c=!1,title:u=!0,paragraph:d=!0,active:h,round:p}=e,{getPrefixCls:f,direction:g,className:m,style:v,classNames:b,styles:S}=Nr("skeleton"),x=f("skeleton",t),[E,R]=zx(x),T={...e,avatar:c,title:u,paragraph:d},[M,D]=Vr([b,o],[S,a],{props:T});if(r||!("loading"in e)){const A=!!c,I=!!u,L=!!d;let F;if(A){const B={className:M.avatar,prefixCls:`${x}-avatar`,...ake(I,L),...Z_(c),style:D.avatar};F=y.createElement("div",{className:Q(M.header,`${x}-header`),style:D.header},y.createElement(KD,{...B}))}let k;if(I||L){let B;if(I){const N={className:M.title,prefixCls:`${x}-title`,...lke(A,L),...Z_(u),style:D.title};B=y.createElement(ske,{...N})}let H;if(L){const N={className:M.paragraph,prefixCls:`${x}-paragraph`,...cke(A,I),...Z_(d),style:D.paragraph};H=y.createElement(oke,{...N})}k=y.createElement("div",{className:Q(M.section,`${x}-section`),style:D.section},B,H)}const O=Q(x,{[`${x}-with-avatar`]:A,[`${x}-active`]:h,[`${x}-rtl`]:g==="rtl",[`${x}-round`]:p},M.root,m,n,i,E,R);return y.createElement("div",{className:O,style:{...D.root,...v,...s}},F,k)}return l??null};Up.Button=tke;Up.Avatar=eke;Up.Input=nke;Up.Image=rke;Up.Node=Kle;function tq(){}const uke=y.createContext({add:tq,remove:tq});function qle(e){const t=y.useContext(uke),r=y.useRef(null);return br(i=>{if(i){const o=e?i.querySelector(e):i;o&&(t.add(o),r.current=o)}else t.remove(r.current)})}const rq=()=>{const{cancelButtonProps:e,cancelTextLocale:t,onCancel:r}=y.useContext($x);return Z.createElement(ca,{onClick:r,...e},t)},nq=()=>{const{confirmLoading:e,okButtonProps:t,okType:r,okTextLocale:n,onOk:i}=y.useContext($x);return Z.createElement(ca,{...G3(r),loading:e,onClick:i,...t},n)};function Xle(e,t){return Z.createElement("span",{className:`${e}-close-x`},t||Z.createElement(Xd,{className:`${e}-close-icon`}))}const Yle=e=>{const{okText:t,okType:r="primary",cancelText:n,confirmLoading:i,onOk:o,onCancel:s,okButtonProps:a,cancelButtonProps:l,footer:c}=e,[u]=Dl("Modal",qae()),d=t||(u==null?void 0:u.okText),h=n||(u==null?void 0:u.cancelText),p=Z.useMemo(()=>({confirmLoading:i,okButtonProps:a,cancelButtonProps:l,okTextLocale:d,cancelTextLocale:h,okType:r,onOk:o,onCancel:s}),[i,a,l,d,h,r,o,s]);let f;return typeof c=="function"||typeof c>"u"?(f=Z.createElement(Z.Fragment,null,Z.createElement(rq,null),Z.createElement(nq,null)),typeof c=="function"&&(f=c(f,{OkBtn:nq,CancelBtn:rq})),f=Z.createElement(kle,{value:p},f)):f=c,Z.createElement(Tle,{disabled:!1},f)},dke=e=>{const{componentCls:t}=e;return{[t]:{display:"flex",flexFlow:"row wrap",minWidth:0,"&::before, &::after":{display:"flex"},"&-no-wrap":{flexWrap:"nowrap"},"&-start":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"flex-end"},"&-space-between":{justifyContent:"space-between"},"&-space-around":{justifyContent:"space-around"},"&-space-evenly":{justifyContent:"space-evenly"},"&-top":{alignItems:"flex-start"},"&-middle":{alignItems:"center"},"&-bottom":{alignItems:"flex-end"}}}},hke=e=>{const{componentCls:t}=e;return{[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},pke=(e,t)=>{const{componentCls:r,gridColumns:n,antCls:i}=e,[o,s]=Jn(i,"grid"),[,a]=Jn(i,"col"),l={};for(let c=n;c>=0;c--)c===0?(l[`${r}${t}-${c}`]={display:"none"},l[`${r}-push-${c}`]={insetInlineStart:"auto"},l[`${r}-pull-${c}`]={insetInlineEnd:"auto"},l[`${r}${t}-push-${c}`]={insetInlineStart:"auto"},l[`${r}${t}-pull-${c}`]={insetInlineEnd:"auto"},l[`${r}${t}-offset-${c}`]={marginInlineStart:0},l[`${r}${t}-order-${c}`]={order:0}):(l[`${r}${t}-${c}`]=[{[o("display")]:"block",display:"block"},{display:s("display"),flex:`0 0 ${c/n*100}%`,maxWidth:`${c/n*100}%`}],l[`${r}${t}-push-${c}`]={insetInlineStart:`${c/n*100}%`},l[`${r}${t}-pull-${c}`]={insetInlineEnd:`${c/n*100}%`},l[`${r}${t}-offset-${c}`]={marginInlineStart:`${c/n*100}%`},l[`${r}${t}-order-${c}`]={order:c});return l[`${r}${t}-flex`]={flex:a(`${t.replace(/-/,"")}-flex`)},l},f$=(e,t)=>pke(e,t),fke=(e,t,r)=>({[`@media (min-width: ${ae(t)})`]:{...f$(e,r)}}),gke=()=>({}),mke=()=>({}),vke=Wr("Grid",dke,gke),Zle=e=>({xs:e.screenXSMin,sm:e.screenSMMin,md:e.screenMDMin,lg:e.screenLGMin,xl:e.screenXLMin,xxl:e.screenXXLMin}),yke=Wr("Grid",e=>{const t=$r(e,{gridColumns:24}),r=Zle(t);return delete r.xs,[hke(t),f$(t,""),f$(t,"-xs"),Object.keys(r).map(n=>fke(t,r[n],`-${n}`)).reduce((n,i)=>({...n,...i}),{})]},mke);function iq(e){return{position:e,inset:0}}const Cke=e=>{const{componentCls:t,antCls:r}=e;return[{[`${t}-root`]:{[`${t}${r}-zoom-enter, ${t}${r}-zoom-appear`]:{transform:"none",opacity:0,animationDuration:e.motionDurationSlow,userSelect:"none"},[`${t}${r}-zoom-leave ${t}-container`]:{pointerEvents:"none"},[`${t}-mask`]:{...iq("fixed"),zIndex:e.zIndexPopupBase,height:"100%",backgroundColor:e.colorBgMask,pointerEvents:"none",[`&${t}-mask-blur`]:{backdropFilter:"blur(4px)"},[`${t}-hidden`]:{display:"none"}},[`${t}-wrap`]:{...iq("fixed"),zIndex:e.zIndexPopupBase,overflow:"auto",outline:0,WebkitOverflowScrolling:"touch"}}},{[`${t}-root`]:jD(e)}]},bke=e=>{const{componentCls:t,motionDurationMid:r}=e;return[{[`${t}-root`]:{[`${t}-wrap-rtl`]:{direction:"rtl"},[`${t}-centered`]:{textAlign:"center","&::before":{display:"inline-block",width:0,height:"100%",verticalAlign:"middle",content:'""'},[t]:{top:0,display:"inline-block",paddingBottom:0,textAlign:"start",verticalAlign:"middle"}},[`@media (max-width: ${e.screenSMMax}px)`]:{[t]:{maxWidth:"calc(100vw - 16px)",margin:`${ae(e.marginXS)} auto`},[`${t}-centered`]:{[t]:{flex:1}}}}},{[t]:{...on(e),pointerEvents:"none",position:"relative",top:100,width:"auto",maxWidth:`calc(100vw - ${ae(e.calc(e.margin).mul(2).equal())})`,margin:"0 auto","&:focus-visible":{borderRadius:e.borderRadiusLG,...gc(e)},[`${t}-title`]:{margin:0,color:e.titleColor,fontWeight:e.fontWeightStrong,fontSize:e.titleFontSize,lineHeight:e.titleLineHeight,wordWrap:"break-word"},[`${t}-container`]:{position:"relative",backgroundColor:e.contentBg,backgroundClip:"padding-box",border:0,borderRadius:e.borderRadiusLG,boxShadow:e.boxShadow,pointerEvents:"auto",padding:e.contentPadding},[`${t}-close`]:{position:"absolute",top:e.calc(e.modalHeaderHeight).sub(e.modalCloseBtnSize).div(2).equal(),insetInlineEnd:e.calc(e.modalHeaderHeight).sub(e.modalCloseBtnSize).div(2).equal(),zIndex:e.calc(e.zIndexPopupBase).add(10).equal(),padding:0,color:e.modalCloseIconColor,fontWeight:e.fontWeightStrong,lineHeight:1,textDecoration:"none",background:"transparent",borderRadius:e.borderRadiusSM,width:e.modalCloseBtnSize,height:e.modalCloseBtnSize,border:0,outline:0,cursor:"pointer",transition:["color","background-color"].map(n=>`${n} ${r}`).join(", "),"&-x":{display:"flex",fontSize:e.fontSizeLG,fontStyle:"normal",lineHeight:ae(e.modalCloseBtnSize),justifyContent:"center",textTransform:"none",textRendering:"auto"},"&:disabled":{pointerEvents:"none"},"&:hover":{color:e.modalCloseIconHoverColor,backgroundColor:e.colorBgTextHover,textDecoration:"none"},"&:active":{backgroundColor:e.colorBgTextActive},...wl(e)},[`${t}-header`]:{color:e.colorText,background:e.headerBg,borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0`,marginBottom:e.headerMarginBottom,padding:e.headerPadding,borderBottom:e.headerBorderBottom},[`${t}-body`]:{fontSize:e.fontSize,lineHeight:e.lineHeight,wordWrap:"break-word",padding:e.bodyPadding,[`${t}-body-skeleton`]:{width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",margin:`${ae(e.margin)} auto`}},[`${t}-footer`]:{textAlign:"end",background:e.footerBg,marginTop:e.footerMarginTop,padding:e.footerPadding,borderTop:e.footerBorderTop,borderRadius:e.footerBorderRadius,[`> ${e.antCls}-btn + ${e.antCls}-btn`]:{marginInlineStart:e.marginXS}},[`${t}-open`]:{overflow:"hidden"}}},{[`${t}-pure-panel`]:{top:"auto",padding:0,display:"flex",flexDirection:"column",[`${t}-container, ${t}-body, ${t}-confirm-body-wrapper`]:{display:"flex",flexDirection:"column",flex:"auto"},[`${t}-confirm-body`]:{marginBottom:"auto"}}}]},Ske=e=>{const{componentCls:t}=e;return{[`${t}-root`]:{[`${t}-wrap-rtl`]:{direction:"rtl",[`${t}-confirm-body`]:{direction:"rtl"}}}}},wke=e=>{const{componentCls:t}=e,r=Zle(e),n={...r};delete n.xs;const i=`--${t.replace(".","")}-`,o=Object.keys(n).map(s=>({[`@media (min-width: ${ae(n[s])})`]:{width:`var(${i}${s}-width)`}}));return{[`${t}-root`]:{[t]:[].concat(Pr(Object.keys(r).map((s,a)=>{const l=Object.keys(r)[a-1];return l?{[`${i}${s}-width`]:`var(${i}${l}-width)`}:null})),[{width:`var(${i}xs-width)`}],Pr(o))}}},Qle=e=>{const t=e.padding,r=e.fontSizeHeading5,n=e.lineHeightHeading5;return $r(e,{modalHeaderHeight:e.calc(e.calc(n).mul(r).equal()).add(e.calc(t).mul(2).equal()).equal(),modalFooterBorderColorSplit:e.colorSplit,modalFooterBorderStyle:e.lineType,modalFooterBorderWidth:e.lineWidth,modalCloseIconColor:e.colorIcon,modalCloseIconHoverColor:e.colorIconHover,modalCloseBtnSize:e.controlHeight,modalConfirmIconSize:e.fontHeight,modalTitleHeight:e.calc(e.titleFontSize).mul(e.titleLineHeight).equal()})},Jle=e=>({footerBg:"transparent",headerBg:"transparent",titleLineHeight:e.lineHeightHeading5,titleFontSize:e.fontSizeHeading5,contentBg:e.colorBgElevated,titleColor:e.colorTextHeading,contentPadding:e.wireframe?0:`${ae(e.paddingMD)} ${ae(e.paddingContentHorizontalLG)}`,headerPadding:e.wireframe?`${ae(e.padding)} ${ae(e.paddingLG)}`:0,headerBorderBottom:e.wireframe?`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`:"none",headerMarginBottom:e.wireframe?0:e.marginXS,bodyPadding:e.wireframe?e.paddingLG:0,footerPadding:e.wireframe?`${ae(e.paddingXS)} ${ae(e.padding)}`:0,footerBorderTop:e.wireframe?`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`:"none",footerBorderRadius:e.wireframe?`0 0 ${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)}`:0,footerMarginTop:e.wireframe?0:e.marginSM,confirmBodyPadding:e.wireframe?`${ae(e.padding*2)} ${ae(e.padding*2)} ${ae(e.paddingLG)}`:0,confirmIconMarginInlineEnd:e.wireframe?e.margin:e.marginSM,confirmBtnsMarginTop:e.wireframe?e.marginLG:e.marginSM,mask:!0}),ece=Wr("Modal",e=>{const t=Qle(e);return[bke(t),Ske(t),Cke(t),Nx(t,"zoom"),wke(t)]},Jle,{unitless:{titleLineHeight:!0}});let g$;const xke=e=>{g$={x:e.pageX,y:e.pageY},setTimeout(()=>{g$=null},100)};WOe()&&document.documentElement.addEventListener("click",xke,!0);const tce=e=>{const{prefixCls:t,className:r,rootClassName:n,open:i,wrapClassName:o,centered:s,getContainer:a,style:l,width:c=520,footer:u,classNames:d,styles:h,children:p,loading:f,confirmLoading:g,zIndex:m,mousePosition:v,onOk:b,onCancel:S,okButtonProps:x,cancelButtonProps:E,destroyOnHidden:R,destroyOnClose:T,panelRef:M=null,closable:D,mask:A,modalRender:I,maskClosable:L,focusTriggerAfterClose:F,focusable:k,...O}=e,{getPopupContainer:B,getPrefixCls:H,direction:N,className:z,style:W,classNames:V,styles:$,centered:K,cancelButtonProps:q,okButtonProps:X,mask:Y}=Nr("modal"),{modal:oe}=y.useContext(ir),[ee,ne]=y.useMemo(()=>typeof D=="boolean"?[void 0,void 0]:[D==null?void 0:D.afterClose,D==null?void 0:D.onClose],[D]),le=H("modal",t),he=H(),[re,ie,de]=Yae(A,Y,le,L),J=Ule(k,re,F),ue=Wt=>{g||(S==null||S(Wt),ne==null||ne())},ve=Wt=>{b==null||b(Wt),ne==null||ne()},pe=ho(le),[me,ke]=ece(le,pe),De=Q(o,{[`${le}-centered`]:s??K,[`${le}-wrap-rtl`]:N==="rtl"}),Ee=u!==null&&!f?y.createElement(Yle,{...e,okButtonProps:{...X,...x},onOk:ve,cancelButtonProps:{...q,...E},onCancel:ue}):null,[We,ze,mt,Nt]=O3(Vy(e),Vy(oe),{closable:!0,closeIcon:y.createElement(Xd,{className:`${le}-close-icon`}),closeIconRender:Wt=>Xle(le,Wt)}),St=We?{disabled:mt,closeIcon:ze,afterClose:ee,...Nt}:!1,Ze=I?Wt=>y.createElement("div",{className:`${le}-render`},I(Wt)):void 0,Fe=`.${le}-${I?"render":"container"}`,tt=qle(Fe),Ne=Wo(M,tt),[rt,ot]=Hp("Modal",m),Ye={...e,width:c,panelRef:M,focusTriggerAfterClose:J.focusTriggerAfterClose,focusable:J,mask:re,maskClosable:de,zIndex:rt},[Ae,nt]=Vr([V,d,ie],[$,h],{props:Ye}),[Et,Tt]=y.useMemo(()=>c&&typeof c=="object"?[void 0,c]:[c,void 0],[c]),kt=y.useMemo(()=>{const Wt={};return Tt&&Object.keys(Tt).forEach(at=>{const lt=Tt[at];lt!==void 0&&(Wt[`--${le}-${at}-width`]=typeof lt=="number"?`${lt}px`:lt)}),Wt},[le,Tt]);return y.createElement(Rp,{form:!0,space:!0},y.createElement(Lx.Provider,{value:ot},y.createElement(j_e,{width:Et,...O,zIndex:rt,getContainer:a===void 0?B:a,prefixCls:le,rootClassName:Q(me,n,ke,pe,Ae.root),rootStyle:nt.root,footer:Ee,visible:i,mousePosition:v??g$,onClose:ue,closable:St,closeIcon:ze,transitionName:mu(he,"zoom",e.transitionName),maskTransitionName:mu(he,"fade",e.maskTransitionName),mask:re,maskClosable:de,className:Q(me,r,z),style:{...W,...l,...kt},classNames:{...Ae,wrapper:Q(Ae.wrapper,De)},styles:nt,panelRef:Ne,destroyOnHidden:R??T,modalRender:Ze,focusTriggerAfterClose:J.focusTriggerAfterClose,focusTrap:J.trap},f?y.createElement(Up,{active:!0,title:!1,paragraph:{rows:4},className:`${le}-body-skeleton`}):p)))},Eke=e=>{const{componentCls:t,titleFontSize:r,titleLineHeight:n,modalConfirmIconSize:i,fontSize:o,lineHeight:s,modalTitleHeight:a,fontHeight:l,confirmBodyPadding:c}=e,u=`${t}-confirm`;return{[u]:{"&-rtl":{direction:"rtl"},[`${e.antCls}-modal-header`]:{display:"none"},[`${u}-body-wrapper`]:{...fu()},[`&${t} ${t}-body`]:{padding:c},[`${u}-body`]:{display:"flex",flexWrap:"nowrap",alignItems:"start",[`> ${e.iconCls}`]:{flex:"none",fontSize:i,marginInlineEnd:e.confirmIconMarginInlineEnd,marginTop:e.calc(e.calc(l).sub(i).equal()).div(2).equal()},[`&-has-title > ${e.iconCls}`]:{marginTop:e.calc(e.calc(a).sub(i).equal()).div(2).equal()}},[`${u}-paragraph`]:{display:"flex",flexDirection:"column",flex:"auto",rowGap:e.marginXS,maxWidth:`calc(100% - ${ae(e.marginSM)})`},[`${u}-body-no-icon ${u}-paragraph`]:{maxWidth:"100%"},[`${e.iconCls} + ${u}-paragraph`]:{maxWidth:`calc(100% - ${ae(e.calc(e.modalConfirmIconSize).add(e.marginSM).equal())})`},[`${u}-title`]:{color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:r,lineHeight:n},[`${u}-container`]:{color:e.colorText,fontSize:o,lineHeight:s},[`${u}-btns`]:{textAlign:"end",marginTop:e.confirmBtnsMarginTop,[`${e.antCls}-btn + ${e.antCls}-btn`]:{marginBottom:0,marginInlineStart:e.marginXS}}},[`${u}-error ${u}-body > ${e.iconCls}`]:{color:e.colorError},[`${u}-warning ${u}-body > ${e.iconCls}, ${u}-confirm ${u}-body > ${e.iconCls}`]:{color:e.colorWarning},[`${u}-info ${u}-body > ${e.iconCls}`]:{color:e.colorInfo},[`${u}-success ${u}-body > ${e.iconCls}`]:{color:e.colorSuccess}}},Tke=Dx(["Modal","confirm"],e=>{const t=Qle(e);return Eke(t)},Jle,{order:-1e3}),rce=e=>{const{prefixCls:t,icon:r,okText:n,cancelText:i,confirmPrefixCls:o,type:s,okCancel:a,footer:l,locale:c,autoFocusButton:u,focusable:d,...h}=e;let p=r;if(!r&&r!==null)switch(s){case"info":p=y.createElement(Oae,null);break;case"success":p=y.createElement(F3,null);break;case"error":p=y.createElement(Ax,null);break;default:p=y.createElement(GD,null)}const f=a??s==="confirm",g=y.useMemo(()=>{const I=(d==null?void 0:d.autoFocusButton)||u;return I||I===null?I:"ok"},[u,d==null?void 0:d.autoFocusButton]),[m]=Dl("Modal"),v=c||m,b=n||(f?v==null?void 0:v.okText:v==null?void 0:v.justOkText),S=i||(v==null?void 0:v.cancelText),{closable:x}=h,{onClose:E}=x&&typeof x=="object"?x:{},R=y.useMemo(()=>({autoFocusButton:g,cancelTextLocale:S,okTextLocale:b,mergedOkCancel:f,onClose:E,...h}),[g,S,b,f,E,h]),T=y.createElement(y.Fragment,null,y.createElement(GK,null),y.createElement(VK,null)),M=Tn(e.title)&&e.title!=="",D=Tn(p),A=`${o}-body`;return y.createElement("div",{className:`${o}-body-wrapper`},y.createElement("div",{className:Q(A,{[`${A}-has-title`]:M,[`${A}-no-icon`]:!D})},p,y.createElement("div",{className:`${o}-paragraph`},M&&y.createElement("span",{className:`${o}-title`},e.title),y.createElement("div",{className:`${o}-content`},e.content))),l===void 0||typeof l=="function"?y.createElement(kle,{value:R},y.createElement("div",{className:`${o}-btns`},typeof l=="function"?l(T,{OkBtn:VK,CancelBtn:GK}):T)):l,y.createElement(Tke,{prefixCls:t}))},Rke=e=>{const{close:t,zIndex:r,maskStyle:n,direction:i,prefixCls:o,wrapClassName:s,rootPrefixCls:a,bodyStyle:l,closable:c=!1,onConfirm:u,styles:d,title:h,mask:p,maskClosable:f,okButtonProps:g,cancelButtonProps:m}=e,{cancelButtonProps:v,okButtonProps:b}=Nr("modal"),S=`${o}-confirm`,x=e.width||416,E=e.style||{},R=Q(S,`${S}-${e.type}`,{[`${S}-rtl`]:i==="rtl"},e.className),T=y.useMemo(()=>{const A=zB(p,f);return A.closable??(A.closable=!1),A},[p,f]),[,M]=fs(),D=y.useMemo(()=>r!==void 0?r:M.zIndexPopupBase+fFe,[r,M]);return y.createElement(tce,{...e,className:R,wrapClassName:Q({[`${S}-centered`]:!!e.centered},s),onCancel:()=>{t==null||t({triggerCancel:!0}),u==null||u(!1)},title:h,footer:null,transitionName:mu(a||"","zoom",e.transitionName),maskTransitionName:mu(a||"","fade",e.maskTransitionName),mask:T,style:E,styles:{body:l,mask:n,...d},width:x,zIndex:D,closable:c},y.createElement(rce,{...e,confirmPrefixCls:S,okButtonProps:{...b,...g},cancelButtonProps:{...v,...m}}))},nce=e=>{const{rootPrefixCls:t,iconPrefixCls:r,direction:n,theme:i}=e;return y.createElement(Iu,{prefixCls:t,iconPrefixCls:r,direction:n,theme:i},y.createElement(Rke,{...e}))},Cg=[];let ice="";function oce(){return ice}const Pke=e=>{var c;const{prefixCls:t,getContainer:r,direction:n}=e,i=qae(),o=y.useContext(ir),s=oce()||o.getPrefixCls(),a=t||`${s}-modal`;let l=r;return l===!1&&(l=void 0),Z.createElement(nce,{...e,rootPrefixCls:s,prefixCls:a,iconPrefixCls:o.iconPrefixCls,theme:o.theme,direction:n??o.direction,locale:((c=o.locale)==null?void 0:c.Modal)??i,getContainer:l})};function Hx(e){const t=bLe(),r=document.createDocumentFragment();let n={...e,close:a,open:!0},i;function o(...c){var d;c.some(h=>h==null?void 0:h.triggerCancel)&&((d=e.onCancel)==null||d.call(e,()=>{},...c.slice(1)));for(let h=0;h{})}const s=c=>{clearTimeout(i),i=setTimeout(()=>{const u=t.getPrefixCls(void 0,oce()),d=t.getIconPrefixCls(),h=t.getTheme(),p=Z.createElement(Pke,{...c});Ile(Z.createElement(Iu,{prefixCls:u,iconPrefixCls:d,theme:h},typeof t.holderRender=="function"?t.holderRender(p):p),r)})};function a(...c){n={...n,open:!1,afterClose:()=>{typeof e.afterClose=="function"&&e.afterClose(),o.apply(this,c)}},s(n)}function l(c){typeof c=="function"?n=c(n):n={...n,...c},s(n)}return s(n),Cg.push(a),{destroy:a,update:l}}function sce(e){return{...e,type:"warning"}}function ace(e){return{...e,type:"info"}}function lce(e){return{...e,type:"success"}}function cce(e){return{...e,type:"error"}}function uce(e){return{...e,type:"confirm"}}function Mke({rootPrefixCls:e}){ice=e}const Ike=y.forwardRef((e,t)=>{const{afterClose:r,config:n,...i}=e,[o,s]=y.useState(!0),[a,l]=y.useState(n),{direction:c,getPrefixCls:u}=y.useContext(ir),d=u("modal"),h=u(),p=()=>{var v;r(),(v=a.afterClose)==null||v.call(a)},f=(...v)=>{var S;s(!1),v.some(x=>x==null?void 0:x.triggerCancel)&&((S=a.onCancel)==null||S.call(a,()=>{},...v.slice(1)))};y.useImperativeHandle(t,()=>({destroy:f,update:v=>{l(b=>{const S=typeof v=="function"?v(b):v;return{...b,...S}})}}));const g=a.okCancel??a.type==="confirm",[m]=Dl("Modal",xl.Modal);return y.createElement(nce,{prefixCls:d,rootPrefixCls:h,...a,close:f,open:o,afterClose:p,okText:a.okText||(g?m==null?void 0:m.okText:m==null?void 0:m.justOkText),direction:a.direction||c,cancelText:a.cancelText||(m==null?void 0:m.cancelText),...i})});let oq=0;const Dke=y.memo(y.forwardRef((e,t)=>{const[r,n]=cFe();return y.useImperativeHandle(t,()=>({patchElement:n}),[n]),y.createElement(y.Fragment,null,r)}));function Ake(){const e=y.useRef(null),[t,r]=y.useState([]);y.useEffect(()=>{t.length&&(Pr(t).forEach(s=>{s()}),r([]))},[t]);const n=y.useCallback(o=>function(a){var g;oq+=1;const l=y.createRef();let c;const u=new Promise(m=>{c=m});let d=!1,h;const p=y.createElement(Ike,{key:`modal-${oq}`,config:o(a),ref:l,afterClose:()=>{h==null||h()},isSilent:()=>d,onConfirm:m=>{c(m)}});return h=(g=e.current)==null?void 0:g.patchElement(p),h&&Cg.push(h),{destroy:()=>{function m(){var v;(v=l.current)==null||v.destroy()}l.current?m():r(v=>[].concat(Pr(v),[m]))},update:m=>{function v(){var b;(b=l.current)==null||b.update(m)}l.current?v():r(b=>[].concat(Pr(b),[v]))},then:m=>(d=!0,u.then(m))}},[]);return[y.useMemo(()=>({info:n(ace),success:n(lce),error:n(cce),warning:n(sce),confirm:n(uce)}),[n]),y.createElement(Dke,{key:"modal-holder",ref:e})]}function dce(e){return t=>y.createElement(Iu,{theme:{token:{motion:!1,zIndexPopupBase:0}}},y.createElement(e,{...t}))}const J3=(e,t,r,n,i)=>dce(s=>{const{prefixCls:a,style:l}=s,c=y.useRef(null),[u,d]=y.useState(0),[h,p]=y.useState(0),[f,g]=An(!1,s.open),{getPrefixCls:m}=y.useContext(ir),v=m(n||"select",a);y.useEffect(()=>{if(g(!0),typeof ResizeObserver<"u"){const x=new ResizeObserver(R=>{const T=R[0].target;d(T.offsetHeight+8),p(T.offsetWidth)}),E=setInterval(()=>{var M;const R=i?`.${i(v)}`:`.${v}-dropdown`,T=(M=c.current)==null?void 0:M.querySelector(R);T&&(clearInterval(E),x.observe(T))},10);return()=>{clearInterval(E),x.disconnect()}}},[v]);let b={...s,style:{...l,margin:0},open:f,getPopupContainer:()=>c.current};r&&(b=r(b)),t&&Object.assign(b,{[t]:{overflow:{adjustX:!1,adjustY:!1}}});const S={paddingBottom:u,position:"relative",minWidth:h};return y.createElement("div",{ref:c,style:S},y.createElement(e,{...b}))}),Fke=(e,t,r,n,i=!1,o,s)=>{const a=y.useMemo(()=>typeof r=="boolean"?{allowClear:r}:r&&typeof r=="object"?r:{allowClear:!1},[r]);return y.useMemo(()=>{const l=!i&&a.allowClear!==!1&&(t.length||o)&&!(s==="combobox"&&o==="");return{allowClear:l,clearIcon:l?a.clearIcon||n||"×":null}},[a,n,i,t.length,o,s])},hce=y.createContext(null);function Mm(){return y.useContext(hce)}function Lke(e=250){const t=y.useRef(null),r=y.useRef(null);y.useEffect(()=>()=>{window.clearTimeout(r.current)},[]);function n(i){(i||t.current===null)&&(t.current=i),window.clearTimeout(r.current),r.current=window.setTimeout(()=>{t.current=null},e)}return[()=>t.current,n]}function pce(e,t){return e.filter(r=>r).some(r=>r.contains(t)||r===t)}function _ke(e,t,r,n){const i=br(o=>{if(n)return;let s=o.target;s.shadowRoot&&o.composed&&(s=o.composedPath()[0]||s),o._ori_target&&(s=o._ori_target),t&&!pce(e(),s)&&r(!1)});y.useEffect(()=>(window.addEventListener("mousedown",i),()=>window.removeEventListener("mousedown",i)),[i])}function m$(){return m$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const t=e===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"}}},kke=(e,t)=>{const{prefixCls:r,disabled:n,visible:i,children:o,popupElement:s,animation:a,transitionName:l,popupStyle:c,popupClassName:u,direction:d="ltr",placement:h,builtinPlacements:p,popupMatchSelectWidth:f,popupRender:g,popupAlign:m,getPopupContainer:v,empty:b,onPopupVisibleChange:S,onPopupMouseEnter:x,onPopupMouseDown:E,onPopupBlur:R,...T}=e,M=`${r}-dropdown`;let D=s;g&&(D=g(s));const A=y.useMemo(()=>p||Oke(f),[p,f]),I=a?`${M}-${a}`:l,L=typeof f=="number",F=y.useMemo(()=>L?null:f===!1?"minWidth":"width",[f,L]);let k=c;L&&(k={...c,width:f});const O=y.useRef(null);return y.useImperativeHandle(t,()=>({getPopupElement:()=>{var B;return(B=O.current)==null?void 0:B.popupElement}})),y.createElement(zD,m$({},T,{showAction:S?["click"]:[],hideAction:S?["click"]:[],popupPlacement:h||(d==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:A,prefixCls:M,popupMotion:{motionName:I},popup:y.createElement("div",{onMouseEnter:x,onMouseDown:E,onBlur:R},D),ref:O,stretch:F,popupAlign:m,popupVisible:i,getPopupContainer:v,popupClassName:Q(u,{[`${M}-empty`]:b}),popupStyle:k,onPopupVisibleChange:S}),o)},Nke=y.forwardRef(kke);function sq(e,t){const{key:r}=e;let n;return"value"in e&&({value:n}=e),r??(n!==void 0?n:`rc-index-key-${t}`)}function v$(e){return typeof e<"u"&&!Number.isNaN(e)}function fce(e,t){const{label:r,value:n,options:i,groupLabel:o}=e||{},s=r||(t?"children":"label");return{label:s,value:n||"value",options:i||"options",groupLabel:o||s}}function Bke(e,{fieldNames:t,childrenAsData:r}={}){const n=[],{label:i,value:o,options:s,groupLabel:a}=fce(t,!1);function l(c,u){Array.isArray(c)&&c.forEach(d=>{if(u||!(s in d)){const h=d[o];n.push({key:sq(d,n.length),groupOption:u,data:d,label:d[i],value:h})}else{let h=d[a];h===void 0&&r&&(h=d.label),n.push({key:sq(d,n.length),group:!0,data:d,label:h}),l(d[s],!0)}})}return l(e,!1),n}function y$(e){const t={...e};return"props"in t||Object.defineProperty(t,"props",{get(){return Vn(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}const $ke=(e,t,r)=>{if(!t||!t.length)return null;let n=!1;const i=(s,[a,...l])=>{if(!a)return[s];const c=s.split(a);return n=n||c.length>1,c.reduce((u,d)=>[...u,...i(d,l)],[]).filter(Boolean)},o=i(e,t);return n?typeof r<"u"?o.slice(0,r):o:null};function Gke(e){const{visible:t,values:r}=e;if(!t)return null;const n=50;return y.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},`${r.slice(0,n).map(({label:i,value:o})=>["number","string"].includes(typeof i)?i:o).join(", ")}`,r.length>n?", ...":null)}const Vke=e=>{const t=new MessageChannel;t.port1.onmessage=e,t.port2.postMessage(null)},e4=(e,t=1)=>{if(t<=0){e();return}Vke(()=>{e4(e,t-1)})};function zke(e,t,r,n){const[i,o]=y.useState(!1);y.useEffect(()=>{o(!0)},[]);const[s,a]=An(e,t),[l,c]=y.useState(!1),u=i?s:!1,d=n(u),h=y.useRef(0),p=br(g=>{r&&d!==g&&r(g),a(g)}),f=br((g,m={})=>{const{cancelFun:v}=m;h.current+=1;const b=h.current,S=typeof g=="boolean"?g:!d;c(!S);function x(){b===h.current&&!(v!=null&&v())&&(p(S),c(!1))}S?x():e4(()=>{x()})});return[u,d,f,l]}function Q_(e){const{children:t,...r}=e;return t?y.createElement("div",r,t):null}const gce=y.createContext(null);function Wx(){return y.useContext(gce)}const mce=y.forwardRef((e,t)=>{const{onChange:r,onKeyDown:n,onBlur:i,style:o,syncWidth:s,value:a,className:l,autoComplete:c,...u}=e,{prefixCls:d,mode:h,onSearch:p,onSearchSubmit:f,onInputBlur:g,autoFocus:m,tokenWithEnter:v,placeholder:b,components:{input:S="input"}}=Wx(),{id:x,classNames:E,styles:R,open:T,activeDescendantId:M,role:D,disabled:A}=Mm()||{},I=Q(`${d}-input`,E==null?void 0:E.input,l),L=y.useRef(!1),F=y.useRef(null),k=y.useRef(null);y.useImperativeHandle(t,()=>k.current);const O=X=>{let{value:Y}=X.target;if(v&&F.current&&/[\r\n]/.test(F.current)){const oe=F.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");Y=Y.replace(oe,F.current)}F.current=null,p&&p(Y,!0,L.current),r==null||r(X)},B=X=>{const{key:Y}=X,{value:oe}=X.currentTarget;Y==="Enter"&&h==="tags"&&!L.current&&f&&f(oe),n==null||n(X)},H=X=>{g==null||g(),i==null||i(X)},N=()=>{L.current=!0},z=X=>{if(L.current=!1,h!=="combobox"){const{value:Y}=X.currentTarget;p==null||p(Y,!0,!1)}},W=X=>{const{clipboardData:Y}=X,oe=Y==null?void 0:Y.getData("text");F.current=oe||""},[V,$]=y.useState(void 0);jr(()=>{const X=k.current;if(s&&X){X.style.width="0px";const Y=X.scrollWidth;$(Y),X.style.width=""}},[s,a]);const K={id:x,type:h==="combobox"?"text":"search",...u,ref:k,style:{...R==null?void 0:R.input,...o,"--select-input-width":V},autoFocus:m,autoComplete:c||"off",className:I,disabled:A,value:a||"",onChange:O,onKeyDown:B,onBlur:H,onPaste:W,onCompositionStart:N,onCompositionEnd:z,role:D||"combobox","aria-expanded":T||!1,"aria-haspopup":"listbox","aria-owns":T?`${x}_list`:void 0,"aria-autocomplete":"list","aria-controls":T?`${x}_list`:void 0,"aria-activedescendant":T?M:void 0};if(y.isValidElement(S)){const X=S.props||{},Y={placeholder:e.placeholder||b,...K,...X};return Object.keys(X).forEach(oe=>{const ee=X[oe];typeof ee=="function"&&(Y[oe]=(...ne)=>{var le;ee(...ne),(le=K[oe])==null||le.call(K,...ne)})}),Y.ref=Wo(S.ref,K.ref),y.cloneElement(S,Y)}const q=S;return y.createElement(q,K)});function vce(e){const{prefixCls:t,placeholder:r,displayValues:n}=Wx(),{classNames:i,styles:o}=Mm(),{show:s=!0}=e;return n.length?null:y.createElement("div",{className:Q(`${t}-placeholder`,i==null?void 0:i.placeholder),style:{visibility:s?"visible":"hidden",...o==null?void 0:o.placeholder}},r)}const t4=y.createContext(null);function yce(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}function Hke(e){return e!=null}function Wke(e){return!e&&e!==0}function aq(e){return["string","number"].includes(typeof e)}function C$(e){let t;return e&&(aq(e.title)?t=e.title.toString():aq(e.label)&&(t=e.label.toString())),t}function b$(){return b$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,searchValue:n,activeValue:i,displayValues:o,maxLength:s,mode:a,components:l}=Wx(),{triggerOpen:c,title:u,showSearch:d,classNames:h,styles:p}=Mm(),f=y.useContext(t4),[g,m]=y.useState(!1),v=a==="combobox",b=o[0],S=y.useMemo(()=>v&&i&&!g&&c?i:d?n:"",[v,i,g,c,n,d]),[x,E,R,T]=y.useMemo(()=>{let I,L,F;if(b&&(f!=null&&f.flattenOptions)){const O=f.flattenOptions.find(B=>B.value===b.value);O!=null&&O.data&&(I=O.data.className,L=O.data.style,F=C$(O.data))}return b&&!F&&(F=C$(b)),u!==void 0&&(F=u),[I,L,F,!!I||!!L]},[b,f==null?void 0:f.flattenOptions,u]);y.useEffect(()=>{v&&m(!1)},[v,i]);const M=b&&b.label!==null&&b.label!==void 0&&String(b.label).trim()!=="",A=!(v&&(l!=null&&l.input))?b?T?y.createElement("div",{className:Q(`${r}-content-value`,x),style:{...S?{visibility:"hidden"}:{},...E},title:R},b.label):b.label:y.createElement(vce,{show:!S}):null;return y.createElement("div",{className:Q(`${r}-content`,M&&`${r}-content-has-value`,S&&`${r}-content-has-search-value`,T&&`${r}-content-has-option-style`,h==null?void 0:h.content),style:p==null?void 0:p.content,title:T?void 0:R},A,y.createElement(mce,b$({ref:t},e,{value:S,maxLength:a==="combobox"?s:void 0,onChange:I=>{var L;m(!0),(L=e.onChange)==null||L.call(e,I)}})))}),mv=void 0;function jke(e,t){const{prefixCls:r,invalidate:n,item:i,renderItem:o,responsive:s,responsiveDisabled:a,registerSize:l,itemKey:c,className:u,style:d,children:h,display:p,order:f,component:g="div",...m}=e,v=s&&!p;function b(T){l(c,T)}y.useEffect(()=>()=>{b(null)},[]);const S=o&&i!==mv?o(i,{index:f}):h;let x;n||(x={opacity:v?0:1,height:v?0:mv,overflowY:v?"hidden":mv,order:s?f:mv,pointerEvents:v?"none":mv,position:v?"absolute":mv});const E={};v&&(E["aria-hidden"]=!0);let R=y.createElement(g,hl({className:Q(!n&&r,u),style:{...x,...d}},E,m,{ref:t}),S);return s&&(R=y.createElement(ta,{onResize:({offsetWidth:T})=>{b(T)},disabled:a},R)),R}const nw=y.forwardRef(jke);function Kke(e){if(typeof MessageChannel>"u")Or(e);else{const t=new MessageChannel;t.port1.onmessage=()=>e(),t.port2.postMessage(void 0)}}function qke(){const e=y.useRef(null);return r=>{e.current||(e.current=[],Kke(()=>{$a.unstable_batchedUpdates(()=>{e.current.forEach(n=>{n()}),e.current=null})})),e.current.push(r)}}function vv(e,t){const[r,n]=y.useState(t),i=br(o=>{e(()=>{n(o)})});return[r,i]}const gM=Z.createContext(null),Xke=(e,t)=>{const r=y.useContext(gM);if(!r){const{component:a="div",...l}=e;return y.createElement(a,hl({},l,{ref:t}))}const{className:n,...i}=r,{className:o,...s}=e;return y.createElement(gM.Provider,{value:null},y.createElement(nw,hl({ref:t,className:Q(n,o)},i,s)))},Yke=y.forwardRef(Xke),Cce="responsive",bce="invalidate";function Zke(e){return`+ ${e.length} ...`}function Qke(e,t){const{prefixCls:r="rc-overflow",data:n=[],renderItem:i,renderRawItem:o,itemKey:s,itemWidth:a=10,ssr:l,style:c,className:u,maxCount:d,renderRest:h,renderRawRest:p,prefix:f,suffix:g,component:m="div",itemComponent:v,onVisibleChange:b,...S}=e,x=l==="full",E=qke(),[R,T]=vv(E,null),M=R||0,[D,A]=vv(E,new Map),[I,L]=vv(E,0),[F,k]=vv(E,0),[O,B]=vv(E,0),[H,N]=vv(E,0),[z,W]=y.useState(null),[V,$]=y.useState(null),K=y.useMemo(()=>V===null&&x?Number.MAX_SAFE_INTEGER:V||0,[V,R]),[q,X]=y.useState(!1),Y=`${r}-item`,oe=Math.max(I,F),ee=d===Cce,ne=n.length&&ee,le=d===bce,he=ne||typeof d=="number"&&n.length>d,re=y.useMemo(()=>{let Ne=n;return ne?R===null&&x?Ne=n:Ne=n.slice(0,Math.min(n.length,M/a)):typeof d=="number"&&(Ne=n.slice(0,d)),Ne},[n,a,R,d,ne]),ie=y.useMemo(()=>ne?n.slice(K+1):n.slice(re.length),[n,re,ne,K]),de=y.useCallback((Ne,rt)=>typeof s=="function"?s(Ne):(s&&(Ne==null?void 0:Ne[s]))??rt,[s]),J=y.useCallback(i||(Ne=>Ne),[i]);function ue(Ne,rt,ot){V===Ne&&(rt===void 0||rt===z)||($(Ne),ot||(X(Ne{const Ye=new Map(ot);return rt===null?Ye.delete(Ne):Ye.set(Ne,rt),Ye})}function me(Ne,rt){k(rt),L(F)}function ke(Ne,rt){B(rt)}function De(Ne,rt){N(rt)}function Ee(Ne){return D.get(de(re[Ne],Ne))}jr(()=>{if(M&&typeof oe=="number"&&re){let Ne=O+H;const rt=re.length,ot=rt-1;if(!rt){ue(0,null);return}for(let Ye=0;YeM){ue(Ye-1,Ne-Ae-H+F);break}}g&&Ee(0)+H>M&&W(null)}},[M,D,F,O,H,de,re]);const We=q&&!!ie.length;let ze={};z!==null&&ne&&(ze={position:"absolute",left:z,top:0});const mt={prefixCls:Y,responsive:ne,component:v,invalidate:le},Nt=o?(Ne,rt)=>{const ot=de(Ne,rt);return y.createElement(gM.Provider,{key:ot,value:{...mt,order:rt,item:Ne,itemKey:ot,registerSize:pe,display:rt<=K}},o(Ne,rt))}:(Ne,rt)=>{const ot=de(Ne,rt);return y.createElement(nw,hl({},mt,{order:rt,key:ot,item:Ne,renderItem:J,itemKey:ot,registerSize:pe,display:rt<=K}))},St={order:We?K:Number.MAX_SAFE_INTEGER,className:`${Y}-rest`,registerSize:me,display:We},Ze=h||Zke,Fe=p?y.createElement(gM.Provider,{value:{...mt,...St}},p(ie)):y.createElement(nw,hl({},mt,St),typeof Ze=="function"?Ze(ie):Ze),tt=y.createElement(m,hl({className:Q(!le&&r,u),style:c,ref:t},S),f&&y.createElement(nw,hl({},mt,{responsive:ee,responsiveDisabled:!ne,order:-1,className:`${Y}-prefix`,registerSize:ke,display:!0}),f),re.map(Nt),he?Fe:null,g&&y.createElement(nw,hl({},mt,{responsive:ee,responsiveDisabled:!ne,order:K,className:`${Y}-suffix`,registerSize:De,display:!0,style:ze}),g));return ee?y.createElement(ta,{onResize:ve,disabled:!ne},tt):tt}const Sd=y.forwardRef(Qke);Sd.Item=Yke;Sd.RESPONSIVE=Cce;Sd.INVALIDATE=bce;const Sce=e=>{const{className:t,style:r,customizeIcon:n,customizeIconProps:i,children:o,onMouseDown:s,onClick:a}=e,l=typeof n=="function"?n(i):n;return y.createElement("span",{className:t,onMouseDown:c=>{c.preventDefault(),s==null||s(c)},style:{userSelect:"none",WebkitUserSelect:"none",...r},unselectable:"on",onClick:a,"aria-hidden":!0},l!==void 0?l:y.createElement("span",{className:Q(t.split(/\s+/).map(c=>`${c}-icon`))},o))};function S$(){return S$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{e.preventDefault(),e.stopPropagation()},eNe=y.forwardRef(function({inputProps:t},r){const{prefixCls:n,displayValues:i,searchValue:o,mode:s,onSelectorRemove:a,removeIcon:l}=Wx(),{disabled:c,showSearch:u,triggerOpen:d,rawOpen:h,toggleOpen:p,autoClearSearchValue:f,tagRender:g,maxTagPlaceholder:m,maxTagTextLength:v,maxTagCount:b,classNames:S,styles:x}=Mm(),E=`${n}-selection-item`;let R=o;!h&&s==="multiple"&&f!==!1&&(R="");const T=u&&R||"",M=u&&!c,D=l??"×",A=m??(N=>`+ ${N.length} ...`),I=g,L=N=>{p(N)},F=N=>{a==null||a(N)},k=(N,z,W,V,$)=>y.createElement("span",{title:C$(N),className:Q(E,{[`${E}-disabled`]:W},S==null?void 0:S.item),style:x==null?void 0:x.item},y.createElement("span",{className:Q(`${E}-content`,S==null?void 0:S.itemContent),style:x==null?void 0:x.itemContent},z),V&&y.createElement(Sce,{className:Q(`${E}-remove`,S==null?void 0:S.itemRemove),style:x==null?void 0:x.itemRemove,onMouseDown:lq,onClick:$,customizeIcon:D},"×")),O=(N,z,W,V,$,K,q)=>{const X=Y=>{lq(Y),L(!d)};return y.createElement("span",{onMouseDown:X},I({label:z,value:N,index:q==null?void 0:q.index,disabled:W,closable:V,onClose:$,isMaxTag:!!K}))},B=(N,z)=>{const{disabled:W,label:V,value:$}=N,K=!c&&!W;let q=V;if(typeof v=="number"&&(typeof V=="string"||typeof V=="number")){const Y=String(q);Y.length>v&&(q=`${Y.slice(0,v)}...`)}const X=Y=>{Y&&Y.stopPropagation(),F(N)};return typeof I=="function"?O($,q,W,K,X,void 0,z):k(N,q,W,K,X)},H=N=>{if(!i.length)return null;const z=typeof A=="function"?A(N):A;return typeof I=="function"?O(void 0,z,!1,!1,void 0,!0):k({title:z},z,!1)};return y.createElement(Sd,{prefixCls:`${n}-content`,className:S==null?void 0:S.content,style:x==null?void 0:x.content,prefix:!i.length&&!T&&y.createElement(vce,null),data:i,renderItem:B,renderRest:H,suffix:y.createElement(mce,S$({ref:r,disabled:c,readOnly:!M},t,{value:T||"",syncWidth:!0})),itemKey:Jke,maxCount:b})}),tNe=y.forwardRef(function(t,r){const{multiple:n,onInputKeyDown:i,tabIndex:o}=Wx(),s=Mm(),{showSearch:a}=s,c={...ai(s,{aria:!0}),onKeyDown:i,readOnly:!a,tabIndex:o};return n?y.createElement(eNe,{ref:r,inputProps:c}):y.createElement(Uke,{ref:r,inputProps:c})});function rNe(e){return e&&![Zt.ESC,Zt.SHIFT,Zt.BACKSPACE,Zt.TAB,Zt.WIN_KEY,Zt.ALT,Zt.META,Zt.WIN_KEY_RIGHT,Zt.CTRL,Zt.SEMICOLON,Zt.EQUALS,Zt.CAPS_LOCK,Zt.CONTEXT_MENU,Zt.UP,Zt.LEFT,Zt.RIGHT,Zt.F1,Zt.F2,Zt.F3,Zt.F4,Zt.F5,Zt.F6,Zt.F7,Zt.F8,Zt.F9,Zt.F10,Zt.F11,Zt.F12].includes(e)}function mM(){return mM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{which:ee}=oe,ne=z.current instanceof HTMLTextAreaElement;if(!ne&&I&&(ee===Zt.UP||ee===Zt.DOWN)&&oe.preventDefault(),R&&R(oe),ne&&!I&&~[Zt.UP,Zt.DOWN,Zt.LEFT,Zt.RIGHT].indexOf(ee))return;!(oe.ctrlKey||oe.altKey||oe.metaKey)&&rNe(ee)&&L(!0)});y.useImperativeHandle(r,()=>({focus:oe=>{var ee,ne;(ne=(ee=z.current||N.current).focus)==null||ne.call(ee,oe)},blur:()=>{var oe,ee;(ee=(oe=z.current||N.current).blur)==null||ee.call(oe)},nativeElement:pc(N.current)}));const V=br(oe=>{var ee;if(!k){const ne=pc(z.current);oe.nativeEvent._ori_target=ne;const le=ne===oe.target||(ne==null?void 0:ne.contains(oe.target));ne&&!le&&oe.preventDefault();const ie=I&&!u&&(p==="combobox"||F)||I&&u&≤oe.nativeEvent._select_lazy?I&&L(!1):((ee=z.current)==null||ee.focus(),ie||L())}x==null||x(oe)}),{root:$}=D,K=fn(A,nNe),q=ai(K,{aria:!0}),X=Object.keys(q),Y={...t,onInputKeyDown:W};if($){const oe=$.props||{},ee={...oe,...K};return Object.keys(oe).forEach(ne=>{const le=oe[ne],he=K[ne];typeof le=="function"&&typeof he=="function"&&(ee[ne]=(...re)=>{he(...re),le(...re)})}),y.isValidElement($)?y.cloneElement($,{...ee,ref:Wo($.ref,N)}):y.createElement($,mM({},ee,{ref:N}))}return y.createElement(gce.Provider,{value:Y},y.createElement("div",mM({},fn(K,X),{ref:N,className:i,style:o,onMouseDown:V}),y.createElement(Q_,{className:Q(`${n}-prefix`,B==null?void 0:B.prefix),style:H==null?void 0:H.prefix},s),y.createElement(tNe,{ref:z}),y.createElement(Q_,{className:Q(`${n}-suffix`,{[`${n}-suffix-loading`]:O},B==null?void 0:B.suffix),style:H==null?void 0:H.suffix},a),l&&y.createElement(Q_,{className:Q(`${n}-clear`,B==null?void 0:B.clear),style:H==null?void 0:H.clear,onMouseDown:oe=>{oe.nativeEvent._select_lazy=!0,E==null||E(oe)}},l),c))});function oNe(e,t,r){return y.useMemo(()=>{let{root:n,input:i}=e||{};return r&&(n=r()),t&&(i=t()),{root:n,input:i}},[e,t,r])}function w$(){return w$=Object.assign?Object.assign.bind():function(e){for(var t=1;te==="tags"||e==="multiple",sNe=y.forwardRef((e,t)=>{const{id:r,prefixCls:n,className:i,styles:o,classNames:s,showSearch:a,tagRender:l,showScrollBar:c="optional",direction:u,omitDomProps:d,displayValues:h,onDisplayValuesChange:p,emptyOptions:f,notFoundContent:g="Not Found",onClear:m,maxCount:v,placeholder:b,mode:S,disabled:x,loading:E,getInputElement:R,getRawInputElement:T,open:M,defaultOpen:D,onPopupVisibleChange:A,activeValue:I,onActiveValueChange:L,activeDescendantId:F,searchValue:k,autoClearSearchValue:O,onSearch:B,onSearchSplit:H,tokenSeparators:N,allowClear:z,prefix:W,suffix:V,suffixIcon:$,clearIcon:K,OptionList:q,animation:X,transitionName:Y,popupStyle:oe,popupClassName:ee,popupMatchSelectWidth:ne,popupRender:le,popupAlign:he,placement:re,builtinPlacements:ie,getPopupContainer:de,showAction:J=[],onFocus:ue,onBlur:ve,onKeyUp:pe,onKeyDown:me,onMouseDown:ke,components:De,...Ee}=e,We=x$(S),ze=y.useRef(null),mt=y.useRef(null),Nt=y.useRef(null),[St,Ze]=y.useState(!1);y.useImperativeHandle(t,()=>{var pt,yt;return{focus:(pt=ze.current)==null?void 0:pt.focus,blur:(yt=ze.current)==null?void 0:yt.blur,scrollTo:It=>{var Qt;return(Qt=Nt.current)==null?void 0:Qt.scrollTo(It)},nativeElement:pc(ze.current)}});const Fe=oNe(De,R,T),tt=y.useMemo(()=>{var yt;if(S!=="combobox")return k;const pt=(yt=h[0])==null?void 0:yt.value;return typeof pt=="string"||typeof pt=="number"?String(pt):""},[k,S,h]),Ne=S==="combobox"&&typeof R=="function"&&R()||null,rt=!g&&f,[ot,Ye,Ae,nt]=zke(D||!1,M,A,pt=>x||rt?!1:pt),Et=y.useMemo(()=>(N||[]).some(pt=>[` `,`\r `].includes(pt)),[N]),Tt=(pt,yt,It)=>{if(We&&v$(v)&&h.length>=v)return;let Qt=!0,Ft=pt;L==null||L(null);const ur=$ke(pt,N,v$(v)?v-h.length:void 0),fr=It?null:ur;return S!=="combobox"&&fr&&(Ft="",H==null||H(fr),Ae(!1),Qt=!1),B&&tt!==Ft&&B(Ft,{source:yt?"typing":"effect"}),pt&&yt&&Qt&&Ae(!0),Qt},kt=pt=>{!pt||!pt.trim()||B(pt,{source:"submit"})};y.useEffect(()=>{!ot&&!We&&S!=="combobox"&&Tt("",!1,!1)},[ot]),y.useEffect(()=>{x&&(Ae(!1),Ze(!1))},[x,Ye]);const[Wt,at]=Lke(),lt=y.useRef(!1),Ut=pt=>{var ur;const yt=Wt(),{key:It}=pt,Qt=It==="Enter",Ft=It===" ";if(Qt||Ft){const fr=S==="combobox";(Ft&&!(fr||a)||Qt&&!fr)&&pt.preventDefault(),Ye||Ae(!0)}if(at(!!tt),It==="Backspace"&&!yt&&We&&!tt&&h.length){const fr=[...h];let rr=null;for(let yn=fr.length-1;yn>=0;yn-=1){const dn=fr[yn];if(!dn.disabled){fr.splice(yn,1),rr=dn;break}}rr&&p(fr,{type:"remove",values:[rr]})}Ye&&(!Qt||!lt.current)&&!Ft&&(Qt&&(lt.current=!0),(ur=Nt.current)==null||ur.onKeyDown(pt)),me==null||me(pt)},cr=(pt,...yt)=>{var It;Ye&&((It=Nt.current)==null||It.onKeyUp(pt,...yt)),pt.key==="Enter"&&(lt.current=!1),pe==null||pe(pt,...yt)},_e=br(pt=>{const yt=h.filter(It=>It!==pt);p(yt,{type:"remove",values:[pt]})}),qe=()=>{lt.current=!1},Re=()=>{var pt;return[pc(ze.current),(pt=mt.current)==null?void 0:pt.getPopupElement()]};_ke(Re,Ye,Ae,!!Fe.root);const it=y.useRef(!1),Ve=pt=>{Ze(!0),x||(J.includes("focus")&&Ae(!0),ue==null||ue(pt))},Oe=()=>{Ye&&!it.current&&Ae(!1,{cancelFun:()=>pce(Re(),document.activeElement)})},se=pt=>{Ze(!1),tt&&(S==="tags"?B(tt,{source:"submit"}):S==="multiple"&&B("",{source:"blur"})),Oe(),x||ve==null||ve(pt)},ce=(pt,...yt)=>{var Ft;const{target:It}=pt,Qt=(Ft=mt.current)==null?void 0:Ft.getPopupElement();Qt!=null&&Qt.contains(It)&&Ae&&Ae(!0),ke==null||ke(pt,...yt),it.current=!0,e4(()=>{it.current=!1})},[,fe]=y.useState({});function Te(){fe({})}let $e;Fe.root&&($e=pt=>{Ae(pt)});const et=y.useMemo(()=>({...e,notFoundContent:g,open:Ye,triggerOpen:Ye,rawOpen:ot,id:r,showSearch:a,multiple:We,toggleOpen:Ae,showScrollBar:c,styles:o,classNames:s,lockOptions:nt}),[e,g,Ae,r,a,We,Ye,ot,c,o,s,nt]),Dt=y.useMemo(()=>{const pt=V??$;return typeof pt=="function"?pt({searchValue:tt,open:Ye,focused:St,showSearch:a,loading:E}):pt},[V,$,tt,Ye,St,a,E]),ct=()=>{var pt;m==null||m(),(pt=ze.current)==null||pt.focus(),p([],{type:"clear",values:h}),Tt("",!1,!1)},{allowClear:st,clearIcon:wt}=Fke(n,h,z,K,x,tt,S),Mt=y.createElement(q,{ref:Nt}),_t=Q(n,i,{[`${n}-focused`]:St,[`${n}-multiple`]:We,[`${n}-single`]:!We,[`${n}-allow-clear`]:st,[`${n}-show-arrow`]:Dt!=null,[`${n}-disabled`]:x,[`${n}-loading`]:E,[`${n}-open`]:Ye,[`${n}-customize-input`]:Ne,[`${n}-show-search`]:a});let At=y.createElement(iNe,w$({},Ee,{ref:ze,prefixCls:n,className:_t,focused:St,prefix:W,suffix:Dt,clearIcon:wt,multiple:We,mode:S,displayValues:h,placeholder:b,searchValue:tt,activeValue:I,onSearch:Tt,onSearchSubmit:kt,onInputBlur:qe,onFocus:Ve,onBlur:se,onClearMouseDown:ct,onKeyDown:Ut,onKeyUp:cr,onSelectorRemove:_e,tokenWithEnter:Et,onMouseDown:ce,components:Fe}));return At=y.createElement(Nke,{ref:mt,disabled:x,prefixCls:n,visible:Ye,popupElement:Mt,animation:X,transitionName:Y,popupStyle:oe,popupClassName:ee,direction:u,popupMatchSelectWidth:ne,popupRender:le,popupAlign:he,placement:re,builtinPlacements:ie,getPopupContainer:de,empty:f,onPopupVisibleChange:$e,onPopupMouseEnter:Te,onPopupMouseDown:ce,onPopupBlur:Oe},At),y.createElement(hce.Provider,{value:et},y.createElement(Gke,{visible:St&&!Ye,values:h}),At)}),r4=()=>null;r4.isSelectOptGroup=!0;const n4=()=>null;n4.isSelectOption=!0;const wce=y.forwardRef(({height:e,offsetY:t,offsetX:r,children:n,prefixCls:i,onInnerResize:o,innerProps:s,rtl:a,extra:l},c)=>{let u={},d={display:"flex",flexDirection:"column"};return t!==void 0&&(u={height:e,position:"relative",overflow:"hidden"},d={...d,transform:`translateY(${t}px)`,[a?"marginRight":"marginLeft"]:-r,position:"absolute",left:0,right:0,top:0}),y.createElement("div",{style:u},y.createElement(ta,{onResize:({offsetHeight:h})=>{h&&o&&o()}},y.createElement("div",hl({style:d,className:Q({[`${i}-holder-inner`]:i}),ref:c},s),n,l)))});wce.displayName="Filler";function aNe({children:e,setRef:t}){const r=y.useCallback(n=>{t(n)},[]);return y.cloneElement(e,{ref:r})}function lNe(e,t,r,n,i,o,s,{getKey:a}){return e.slice(t,r+1).map((l,c)=>{const u=t+c,d=s(l,u,{style:{width:n},offsetX:i}),h=a(l);return y.createElement(aNe,{key:h,setRef:p=>o(l,p)},d)})}function cNe(e,t,r){const n=e.length,i=t.length;let o,s;if(n===0&&i===0)return null;n{const a=cNe(n||[],e||[],t);(a==null?void 0:a.index)!==void 0&&s(e[a.index]),i(e)},[e]),[o]}const cq=typeof navigator=="object"&&/Firefox/i.test(navigator.userAgent),xce=((e,t,r,n)=>{const i=y.useRef(!1),o=y.useRef(null);function s(){clearTimeout(o.current),i.current=!0,o.current=setTimeout(()=>{i.current=!1},50)}const a=y.useRef({top:e,bottom:t,left:r,right:n});return a.current.top=e,a.current.bottom=t,a.current.left=r,a.current.right=n,(l,c,u=!1)=>{const d=l?c<0&&a.current.left||c>0&&a.current.right:c<0&&a.current.top||c>0&&a.current.bottom;return u&&d?(clearTimeout(o.current),i.current=!1):(!d||i.current)&&s(),!i.current&&d}});function dNe(e,t,r,n,i,o,s){const a=y.useRef(0),l=y.useRef(null),c=y.useRef(null),u=y.useRef(!1),d=xce(t,r,n,i);function h(b,S){if(Or.cancel(l.current),d(!1,S))return;const x=b;if(!x._virtualHandled)x._virtualHandled=!0;else return;a.current+=S,c.current=S,cq||x.preventDefault(),l.current=Or(()=>{const E=u.current?10:1;s(a.current*E,!1),a.current=0})}function p(b,S){s(S,!0),cq||b.preventDefault()}const f=y.useRef(null),g=y.useRef(null);function m(b){if(!e)return;Or.cancel(g.current),g.current=Or(()=>{f.current=null},2);const{deltaX:S,deltaY:x,shiftKey:E}=b;let R=S,T=x;(f.current==="sx"||!f.current&&E&&x&&!S)&&(R=x,T=0,f.current="sx");const M=Math.abs(R),D=Math.abs(T);f.current===null&&(f.current=o&&M>D?"x":"y"),f.current==="y"?h(b,T):p(b,R)}function v(b){e&&(u.current=b.detail===c.current)}return[m,v]}function hNe(e,t,r,n){const[i,o]=y.useMemo(()=>[new Map,[]],[e,r.id,n]);return(a,l=a)=>{let c=i.get(a),u=i.get(l);if(c===void 0||u===void 0){const d=e.length;for(let h=o.length;h{let p=!1;o.current.forEach((f,g)=>{if(f&&f.offsetParent){const{offsetHeight:m}=f,{marginTop:v,marginBottom:b}=getComputedStyle(f),S=uq(v),x=uq(b),E=m+S+x;s.current.get(g)!==E&&(s.current.set(g,E),p=!0)}}),p&&i(f=>f+1)};if(d)h();else{a.current+=1;const p=a.current;Promise.resolve().then(()=>{p===a.current&&h()})}}function u(d,h){const p=e(d);o.current.get(p),h?(o.current.set(p,h),c()):o.current.delete(p)}return y.useEffect(()=>l,[]),[u,c,s.current,n]}const dq=14/15;function gNe(e,t,r){const n=y.useRef(!1),i=y.useRef(0),o=y.useRef(0),s=y.useRef(null),a=y.useRef(null);let l;const c=h=>{if(n.current){const p=Math.ceil(h.touches[0].pageX),f=Math.ceil(h.touches[0].pageY);let g=i.current-p,m=o.current-f;const v=Math.abs(g)>Math.abs(m);v?i.current=p:o.current=f;const b=r(v,v?g:m,!1,h);b&&h.preventDefault(),clearInterval(a.current),b&&(a.current=setInterval(()=>{v?g*=dq:m*=dq;const S=Math.floor(v?g:m);(!r(v,S,!0)||Math.abs(S)<=.1)&&clearInterval(a.current)},16))}},u=()=>{n.current=!1,l()},d=h=>{l(),h.touches.length===1&&!n.current&&(n.current=!0,i.current=Math.ceil(h.touches[0].pageX),o.current=Math.ceil(h.touches[0].pageY),s.current=h.target,s.current.addEventListener("touchmove",c,{passive:!1}),s.current.addEventListener("touchend",u,{passive:!0}))};l=()=>{s.current&&(s.current.removeEventListener("touchmove",c),s.current.removeEventListener("touchend",u))},jr(()=>(e&&t.current.addEventListener("touchstart",d,{passive:!0}),()=>{var h;(h=t.current)==null||h.removeEventListener("touchstart",d),l(),clearInterval(a.current)}),[e])}function hq(e){return Math.floor(e**.5)}function E$(e,t){return("touches"in e?e.touches[0]:e)[t?"pageX":"pageY"]-window[t?"scrollX":"scrollY"]}function mNe(e,t,r){y.useEffect(()=>{const n=t.current;if(e&&n){let i=!1,o,s;const a=()=>{Or.cancel(o)},l=()=>{a(),o=Or(()=>{r(s),l()})},c=()=>{i=!1,a()},u=h=>{if(h.target.draggable||h.button!==0)return;const p=h;p._virtualHandled||(p._virtualHandled=!0,i=!0)},d=h=>{if(i){const p=E$(h,!1),{top:f,bottom:g}=n.getBoundingClientRect();if(p<=f){const m=f-p;s=-hq(m),l()}else if(p>=g){const m=p-g;s=hq(m),l()}else a()}};return n.addEventListener("mousedown",u),n.ownerDocument.addEventListener("mouseup",c),n.ownerDocument.addEventListener("mousemove",d),n.ownerDocument.addEventListener("dragend",c),()=>{n.removeEventListener("mousedown",u),n.ownerDocument.removeEventListener("mouseup",c),n.ownerDocument.removeEventListener("mousemove",d),n.ownerDocument.removeEventListener("dragend",c),a()}}},[e])}const vNe=10;function yNe(e,t,r,n,i,o,s,a){const l=y.useRef(),[c,u]=y.useState(null);return jr(()=>{if(c&&c.times({...S}));return}o();const{targetAlign:d,originAlign:h,index:p,offset:f}=c,g=e.current.clientHeight;let m=!1,v=d,b=null;if(g){const S=d||h;let x=0,E=0,R=0;const T=Math.min(t.length-1,p);for(let D=0;D<=T;D+=1){const A=i(t[D]);E=x;const I=r.get(A);R=E+(I===void 0?n:I),x=R}let M=S==="top"?f:g-f;for(let D=T;D>=0;D-=1){const A=i(t[D]),I=r.get(A);if(I===void 0){m=!0;break}if(M-=I,M<=0)break}switch(S){case"top":b=E-f;break;case"bottom":b=R-g+f;break;default:{const{scrollTop:D}=e.current,A=D+g;EA&&(v="bottom")}}b!==null&&s(b),b!==c.lastTop&&(m=!0)}m&&u({...c,times:c.times+1,targetAlign:v,lastTop:b})}},[c,e.current]),d=>{if(d==null){a();return}if(Or.cancel(l.current),typeof d=="number")s(d);else if(d&&typeof d=="object"){let h;const{align:p}=d;"index"in d?{index:h}=d:h=t.findIndex(g=>i(g)===d.key);const{offset:f=0}=d;u({times:0,index:h,offset:f,originAlign:p})}}}const pq=y.forwardRef((e,t)=>{const{prefixCls:r,rtl:n,scrollOffset:i,scrollRange:o,onStartMove:s,onStopMove:a,onScroll:l,horizontal:c,spinSize:u,containerSize:d,style:h,thumbStyle:p,showScrollBar:f}=e,[g,m]=y.useState(!1),[v,b]=y.useState(null),[S,x]=y.useState(null),E=!n,R=y.useRef(),T=y.useRef(),[M,D]=y.useState(f),A=y.useRef(),I=()=>{f===!0||f===!1||(clearTimeout(A.current),D(!0),A.current=setTimeout(()=>{D(!1)},3e3))},L=o-d||0,F=d-u||0,k=y.useMemo(()=>i===0||L===0?0:i/L*F,[i,L,F]),O=K=>{K.stopPropagation(),K.preventDefault()},B=y.useRef({top:k,dragging:g,pageY:v,startTop:S});B.current={top:k,dragging:g,pageY:v,startTop:S};const H=K=>{m(!0),b(E$(K,c)),x(B.current.top),s(),K.stopPropagation(),K.preventDefault()};y.useEffect(()=>{const K=Y=>{Y.preventDefault()},q=R.current,X=T.current;return q.addEventListener("touchstart",K,{passive:!1}),X.addEventListener("touchstart",H,{passive:!1}),()=>{q.removeEventListener("touchstart",K),X.removeEventListener("touchstart",H)}},[]);const N=y.useRef();N.current=L;const z=y.useRef();z.current=F,y.useEffect(()=>{if(g){let K;const q=Y=>{const{dragging:oe,pageY:ee,startTop:ne}=B.current;Or.cancel(K);const le=R.current.getBoundingClientRect(),he=d/(c?le.width:le.height);if(oe){const re=(E$(Y,c)-ee)*he;let ie=ne;!E&&c?ie-=re:ie+=re;const de=N.current,J=z.current,ue=J?ie/J:0;let ve=Math.ceil(ue*de);ve=Math.max(ve,0),ve=Math.min(ve,de),K=Or(()=>{l(ve,c)})}},X=()=>{m(!1),a()};return window.addEventListener("mousemove",q,{passive:!0}),window.addEventListener("touchmove",q,{passive:!0}),window.addEventListener("mouseup",X,{passive:!0}),window.addEventListener("touchend",X,{passive:!0}),()=>{window.removeEventListener("mousemove",q),window.removeEventListener("touchmove",q),window.removeEventListener("mouseup",X),window.removeEventListener("touchend",X),Or.cancel(K)}}},[g]),y.useEffect(()=>(I(),()=>{clearTimeout(A.current)}),[i]),y.useImperativeHandle(t,()=>({delayHidden:I}));const W=`${r}-scrollbar`,V={position:"absolute",visibility:M?null:"hidden"},$={position:"absolute",borderRadius:99,background:"var(--rc-virtual-list-scrollbar-bg, rgba(0, 0, 0, 0.5))",cursor:"pointer",userSelect:"none"};return c?(Object.assign(V,{height:8,left:0,right:0,bottom:0}),Object.assign($,{height:"100%",width:u,[E?"left":"right"]:k})):(Object.assign(V,{width:8,top:0,bottom:0,[E?"right":"left"]:0}),Object.assign($,{width:"100%",height:u,top:k})),y.createElement("div",{ref:R,className:Q(W,{[`${W}-horizontal`]:c,[`${W}-vertical`]:!c,[`${W}-visible`]:M}),style:{...V,...h},onMouseDown:O,onMouseMove:I},y.createElement("div",{ref:T,className:Q(`${W}-thumb`,{[`${W}-thumb-moving`]:g}),style:{...$,...p},onMouseDown:H}))}),CNe=20;function fq(e=0,t=0){let r=e/t*e;return isNaN(r)&&(r=0),r=Math.max(r,CNe),Math.floor(r)}const bNe=[],SNe={overflowY:"auto",overflowAnchor:"none"};function wNe(e,t){const{prefixCls:r="rc-virtual-list",className:n,height:i,itemHeight:o,fullHeight:s=!0,style:a,data:l,children:c,itemKey:u,virtual:d,direction:h,scrollWidth:p,component:f="div",onScroll:g,onVirtualScroll:m,onVisibleChange:v,innerProps:b,extraRender:S,styles:x,showScrollBar:E="optional",...R}=e,T=y.useCallback(Ve=>typeof u=="function"?u(Ve):Ve==null?void 0:Ve[u],[u]),[M,D,A,I]=fNe(T),L=!!(d!==!1&&i&&o),F=y.useMemo(()=>Object.values(A.maps).reduce((Ve,Oe)=>Ve+Oe,0),[A.id,A.maps]),k=L&&l&&(Math.max(o*l.length,F)>i||!!p),O=h==="rtl",B=Q(r,{[`${r}-rtl`]:O},n),H=l||bNe,N=y.useRef(),z=y.useRef(),W=y.useRef(),[V,$]=y.useState(0),[K,q]=y.useState(0),[X,Y]=y.useState(!1),oe=()=>{Y(!0)},ee=()=>{Y(!1)},ne={getKey:T};function le(Ve){$(Oe=>{let se;typeof Ve=="function"?se=Ve(Oe):se=Ve;const ce=St(se);return N.current.scrollTop=ce,ce})}const he=y.useRef({start:0,end:H.length}),re=y.useRef(),[ie]=uNe(H,T);re.current=ie;const{scrollHeight:de,start:J,end:ue,offset:ve}=y.useMemo(()=>{var Te;if(!L)return{scrollHeight:void 0,start:0,end:H.length-1,offset:void 0};if(!k)return{scrollHeight:((Te=z.current)==null?void 0:Te.offsetHeight)||0,start:0,end:H.length-1,offset:void 0};let Ve=0,Oe,se,ce;const fe=H.length;for(let $e=0;$e=V&&Oe===void 0&&(Oe=$e,se=Ve),st>V+i&&ce===void 0&&(ce=$e),Ve=st}return Oe===void 0&&(Oe=0,se=0,ce=Math.ceil(i/o)),ce===void 0&&(ce=H.length-1),ce=Math.min(ce+1,H.length-1),{scrollHeight:Ve,start:Oe,end:ce,offset:se}},[k,L,V,H,I,i]);he.current.start=J,he.current.end=ue,y.useLayoutEffect(()=>{const Ve=A.getRecord();if(Ve.size===1){const Oe=Array.from(Ve.keys())[0],se=Ve.get(Oe),ce=H[J];if(ce&&se===void 0&&T(ce)===Oe){const $e=A.get(Oe)-o;le(et=>et+$e)}}A.resetRecord()},[de]);const[pe,me]=y.useState({width:0,height:i}),ke=Ve=>{me({width:Ve.offsetWidth,height:Ve.offsetHeight})},De=y.useRef(),Ee=y.useRef(),We=y.useMemo(()=>fq(pe.width,p),[pe.width,p]),ze=y.useMemo(()=>fq(pe.height,de),[pe.height,de]),mt=de-i,Nt=y.useRef(mt);Nt.current=mt;function St(Ve){let Oe=Ve;return Number.isNaN(Nt.current)||(Oe=Math.min(Oe,Nt.current)),Oe=Math.max(Oe,0),Oe}const Ze=V<=0,Fe=V>=mt,tt=K<=0,Ne=K>=p,rt=xce(Ze,Fe,tt,Ne),ot=()=>({x:O?-K:K,y:V}),Ye=y.useRef(ot()),Ae=br(Ve=>{if(m){const Oe={...ot(),...Ve};(Ye.current.x!==Oe.x||Ye.current.y!==Oe.y)&&(m(Oe),Ye.current=Oe)}});function nt(Ve,Oe){const se=Ve;Oe?($a.flushSync(()=>{q(se)}),Ae()):le(se)}function Et(Ve){const{scrollTop:Oe}=Ve.currentTarget;Oe!==V&&le(Oe),g==null||g(Ve),Ae()}const Tt=Ve=>{let Oe=Ve;const se=p?p-pe.width:0;return Oe=Math.max(Oe,0),Oe=Math.min(Oe,se),Oe},kt=br((Ve,Oe)=>{Oe?($a.flushSync(()=>{q(se=>{const ce=se+(O?-Ve:Ve);return Tt(ce)})}),Ae()):le(se=>se+Ve)}),[Wt,at]=dNe(L,Ze,Fe,tt,Ne,!!p,kt);gNe(L,N,(Ve,Oe,se,ce)=>{const fe=ce;return rt(Ve,Oe,se)?!1:!fe||!fe._virtualHandled?(fe&&(fe._virtualHandled=!0),Wt({preventDefault(){},deltaX:Ve?Oe:0,deltaY:Ve?0:Oe}),!0):!1}),mNe(k,N,Ve=>{le(Oe=>Oe+Ve)}),jr(()=>{function Ve(se){const ce=Ze&&se.detail<0,fe=Fe&&se.detail>0;L&&!ce&&!fe&&se.preventDefault()}const Oe=N.current;return Oe.addEventListener("wheel",Wt,{passive:!1}),Oe.addEventListener("DOMMouseScroll",at,{passive:!0}),Oe.addEventListener("MozMousePixelScroll",Ve,{passive:!1}),()=>{Oe.removeEventListener("wheel",Wt),Oe.removeEventListener("DOMMouseScroll",at),Oe.removeEventListener("MozMousePixelScroll",Ve)}},[L,Ze,Fe]),jr(()=>{if(p){const Ve=Tt(K);q(Ve),Ae({x:Ve})}},[pe.width,p]);const lt=()=>{var Ve,Oe;(Ve=De.current)==null||Ve.delayHidden(),(Oe=Ee.current)==null||Oe.delayHidden()},Ut=yNe(N,H,A,o,T,()=>D(!0),le,lt);y.useImperativeHandle(t,()=>({nativeElement:W.current,getScrollInfo:ot,scrollTo:Ve=>{function Oe(se){return se&&typeof se=="object"&&("left"in se||"top"in se)}Oe(Ve)?(Ve.left!==void 0&&q(Tt(Ve.left)),Ut(Ve.top)):Ut(Ve)}})),jr(()=>{if(v){const Ve=H.slice(J,ue+1);v(Ve,H)}},[J,ue,H]);const cr=hNe(H,T,A,o),_e=S==null?void 0:S({start:J,end:ue,virtual:k,offsetX:K,offsetY:ve,rtl:O,getSize:cr}),qe=lNe(H,J,ue,p,K,M,c,ne);let Re=null;i&&(Re={[s?"height":"maxHeight"]:i,...SNe},L&&(Re.overflowY="hidden",p&&(Re.overflowX="hidden"),X&&(Re.pointerEvents="none")));const it={};return O&&(it.dir="rtl"),y.createElement("div",hl({ref:W,style:{...a,position:"relative"},className:B},it,R),y.createElement(ta,{onResize:ke},y.createElement(f,{className:`${r}-holder`,style:Re,ref:N,onScroll:Et,onMouseEnter:lt},y.createElement(wce,{prefixCls:r,height:de,offsetX:K,offsetY:ve,scrollWidth:p,onInnerResize:D,ref:z,innerProps:b,rtl:O,extra:_e},qe))),k&&de>i&&y.createElement(pq,{ref:De,prefixCls:r,scrollOffset:V,scrollRange:de,rtl:O,onScroll:nt,onStartMove:oe,onStopMove:ee,spinSize:ze,containerSize:pe.height,style:x==null?void 0:x.verticalScrollBar,thumbStyle:x==null?void 0:x.verticalScrollBarThumb,showScrollBar:E}),k&&p>pe.width&&y.createElement(pq,{ref:Ee,prefixCls:r,scrollOffset:K,scrollRange:p,rtl:O,onScroll:nt,onStartMove:oe,onStopMove:ee,spinSize:We,containerSize:pe.width,horizontal:!0,style:x==null?void 0:x.horizontalScrollBar,thumbStyle:x==null?void 0:x.horizontalScrollBarThumb,showScrollBar:E}))}const qD=y.forwardRef(wNe);qD.displayName="List";function xNe(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}function Aw(){return Aw=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var le,he;const{prefixCls:r,id:n,open:i,multiple:o,mode:s,searchValue:a,toggleOpen:l,notFoundContent:c,onPopupScroll:u,showScrollBar:d,lockOptions:h}=Mm(),{maxCount:p,flattenOptions:f,onActiveValue:g,defaultActiveFirstOption:m,onSelect:v,menuItemSelectedIcon:b,rawValues:S,fieldNames:x,virtual:E,direction:R,listHeight:T,listItemHeight:M,optionRender:D,classNames:A,styles:I}=y.useContext(t4),L=`${r}-item`,F=Pm(()=>f,[i,h],(re,ie)=>ie[0]&&!ie[1]),k=y.useRef(null),O=y.useMemo(()=>o&&v$(p)&&(S==null?void 0:S.size)>=p,[o,p,S==null?void 0:S.size]),B=re=>{re.preventDefault()},H=re=>{var ie;(ie=k.current)==null||ie.scrollTo(typeof re=="number"?{index:re}:re)},N=y.useCallback(re=>s==="combobox"?!1:S.has(re),[s,[...S].toString(),S.size]),z=(re,ie=1)=>{const de=F.length;for(let J=0;Jz(0)),$=(re,ie=!1)=>{V(re);const de={source:ie?"keyboard":"mouse"},J=F[re];if(!J){g(null,-1,de);return}g(J.value,re,de)};y.useEffect(()=>{$(m!==!1?z(0):-1)},[F.length,a]);const K=y.useCallback(re=>s==="combobox"?String(re).toLowerCase()===a.toLowerCase():S.has(re),[s,a,[...S].toString(),S.size]);y.useEffect(()=>{var ie;let re;if(!o&&i&&S.size===1){const de=Array.from(S)[0],J=F.findIndex(({data:ue})=>a?String(ue.value).startsWith(a):ue.value===de);J!==-1&&($(J),re=setTimeout(()=>{H(J)}))}return i&&((ie=k.current)==null||ie.scrollTo(void 0)),()=>clearTimeout(re)},[i,a]);const q=re=>{re!==void 0&&v(re,{selected:!S.has(re)}),o||l(!1)};if(y.useImperativeHandle(t,()=>({onKeyDown:re=>{const{which:ie,ctrlKey:de}=re;switch(ie){case Zt.N:case Zt.P:case Zt.UP:case Zt.DOWN:{let J=0;if(ie===Zt.UP?J=-1:ie===Zt.DOWN?J=1:xNe()&&de&&(ie===Zt.N?J=1:ie===Zt.P&&(J=-1)),J!==0){const ue=z(W+J,J);H(ue),$(ue,!0)}break}case Zt.TAB:case Zt.ENTER:{const J=F[W];if(!J||J.data.disabled)return q(void 0);!O||S.has(J.value)?q(J.value):q(void 0),i&&re.preventDefault();break}case Zt.ESC:l(!1),i&&re.stopPropagation()}},onKeyUp:()=>{},scrollTo:re=>{H(re)}})),F.length===0)return y.createElement("div",{role:"listbox",id:`${n}_list`,className:`${L}-empty`,onMouseDown:B},c);const X=Object.keys(x).map(re=>x[re]),Y=re=>re.label;function oe(re,ie){const{group:de}=re;return{role:de?"presentation":"option",id:`${n}_list_${ie}`}}const ee=re=>{const ie=F[re];if(!ie)return null;const de=ie.data||{},{value:J,disabled:ue}=de,{group:ve}=ie,pe=ai(de,!0),me=Y(ie);return ie?y.createElement("div",Aw({"aria-label":typeof me=="string"&&!ve?me:null},pe,{key:re},oe(ie,re),{"aria-selected":K(J),"aria-disabled":ue}),J):null},ne={role:"listbox",id:`${n}_list`};return y.createElement(y.Fragment,null,E&&y.createElement("div",Aw({},ne,{style:{height:0,width:0,overflow:"hidden"}}),ee(W-1),ee(W),ee(W+1)),y.createElement(qD,{itemKey:"key",ref:k,data:F,height:T,itemHeight:M,fullHeight:!1,onMouseDown:B,onScroll:u,virtual:E,direction:R,innerProps:E?null:ne,showScrollBar:d,className:(le=A==null?void 0:A.popup)==null?void 0:le.list,style:(he=I==null?void 0:I.popup)==null?void 0:he.list},(re,ie)=>{var Ae,nt;const{group:de,groupOption:J,data:ue,label:ve,value:pe}=re,{key:me}=ue;if(de){const Et=ue.title??(gq(ve)?ve.toString():void 0);return y.createElement("div",{className:Q(L,`${L}-group`,ue.className),title:Et},ve!==void 0?ve:me)}const{disabled:ke,title:De,children:Ee,style:We,className:ze,...mt}=ue,Nt=fn(mt,X),St=N(pe),Ze=ke||!St&&O,Fe=`${L}-option`,tt=Q(L,Fe,ze,(Ae=A==null?void 0:A.popup)==null?void 0:Ae.listItem,{[`${Fe}-grouped`]:J,[`${Fe}-active`]:W===ie&&!Ze,[`${Fe}-disabled`]:Ze,[`${Fe}-selected`]:St}),Ne=Y(re),rt=!b||typeof b=="function"||St,ot=typeof Ne=="number"?Ne:Ne||pe;let Ye=gq(ot)?ot.toString():void 0;return De!==void 0&&(Ye=De),y.createElement("div",Aw({},ai(Nt),E?{}:oe(re,ie),{"aria-selected":E?void 0:K(pe),"aria-disabled":Ze,className:tt,title:Ye,onMouseMove:()=>{W===ie||Ze||$(ie)},onClick:()=>{Ze||q(pe)},style:{...(nt=I==null?void 0:I.popup)==null?void 0:nt.listItem,...We}}),y.createElement("div",{className:`${Fe}-content`},typeof D=="function"?D(re,{index:ie}):ot),y.isValidElement(b)||St,rt&&y.createElement(Sce,{className:`${L}-option-state`,customizeIcon:b,customizeIconProps:{value:pe,disabled:Ze,isSelected:St}},St?"✓":null))}))},TNe=y.forwardRef(ENe),RNe=((e,t)=>{const r=y.useRef({values:new Map,options:new Map}),n=y.useMemo(()=>{const{values:o,options:s}=r.current,a=e.map(u=>{var d;return u.label===void 0?{...u,label:(d=o.get(u.value))==null?void 0:d.label}:u}),l=new Map,c=new Map;return a.forEach(u=>{l.set(u.value,u),c.set(u.value,t.get(u.value)||s.get(u.value))}),r.current.values=l,r.current.options=c,a},[e,t]),i=y.useCallback(o=>t.get(o)||r.current.options.get(o),[t]);return[n,i]});function J_(e,t){return yce(e).join("").toUpperCase().includes(t)}const PNe=((e,t,r,n,i)=>y.useMemo(()=>{if(!r||n===!1)return e;const{options:o,label:s,value:a}=t,l=[],c=typeof n=="function",u=r.toUpperCase(),d=c?n:(p,f)=>i&&i.length?i.some(g=>J_(f[g],u)):f[o]?J_(f[s!=="children"?s:"label"],u):J_(f[a],u),h=c?p=>y$(p):p=>p;return e.forEach(p=>{if(p[o]){if(d(r,h(p)))l.push(p);else{const g=p[o].filter(m=>d(r,h(m)));g.length&&l.push({...p,[o]:g})}return}d(r,h(p))&&l.push(p)}),l},[e,n,i,r,t]));function MNe(e){const{key:t,props:{children:r,value:n,...i}}=e;return{key:t,value:n!==void 0?n:t,children:r,...i}}function Ece(e,t=!1){return Li(e).map((r,n)=>{if(!y.isValidElement(r)||!r.type)return null;const{type:{isSelectOptGroup:i},key:o,props:{children:s,...a}}=r;return t||!i?MNe(r):{key:`__RC_SELECT_GRP__${o===null?n:o}__`,label:o,...a,options:Ece(s)}}).filter(r=>r)}const INe=(e,t,r,n,i)=>y.useMemo(()=>{let o=e;!e&&(o=Ece(t));const a=new Map,l=new Map,c=(d,h,p)=>{p&&typeof p=="string"&&d.set(h[p],h)},u=(d,h=!1)=>{for(let p=0;p{c(l,f,g)}),c(l,f,i)):u(f[r.options],!0)}};return u(o),{options:o,valueOptions:a,labelOptions:l}},[e,t,r,n,i]);function mq(e){const t=y.useRef();return t.current=e,y.useCallback((...n)=>t.current(...n),[])}function DNe(e,t,r){const{filterOption:n,searchValue:i,optionFilterProp:o,filterSort:s,onSearch:a,autoClearSearchValue:l}=t;return y.useMemo(()=>{const c=typeof e=="object",u={filterOption:n,searchValue:i,optionFilterProp:o,filterSort:s,onSearch:a,autoClearSearchValue:l,...c?e:{}};return[c||r==="combobox"||r==="tags"||r==="multiple"&&e===void 0?!0:e,u]},[r,e,n,i,o,s,a,l])}function T$(){return T$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{id:r,mode:n,prefixCls:i="rc-select",backfill:o,fieldNames:s,showSearch:a,searchValue:l,onSearch:c,autoClearSearchValue:u,filterOption:d,optionFilterProp:h,filterSort:p,onSelect:f,onDeselect:g,onActive:m,popupMatchSelectWidth:v=!0,optionLabelProp:b,options:S,optionRender:x,children:E,defaultActiveFirstOption:R,menuItemSelectedIcon:T,virtual:M,direction:D,listHeight:A=200,listItemHeight:I=20,labelRender:L,value:F,defaultValue:k,labelInValue:O,onChange:B,maxCount:H,classNames:N,styles:z,...W}=e,V={searchValue:l,onSearch:c,autoClearSearchValue:u,filterOption:d,optionFilterProp:h,filterSort:p},[$,K]=DNe(a,V,n),{filterOption:q,searchValue:X,optionFilterProp:Y,filterSort:oe,onSearch:ee,autoClearSearchValue:ne=!0}=K,le=y.useMemo(()=>Y?Array.isArray(Y)?Y:[Y]:[],[Y]),he=xc(r),re=x$(n),ie=!!(!S&&E),de=y.useMemo(()=>q===void 0&&n==="combobox"?!1:q,[q,n]),J=y.useMemo(()=>fce(s,ie),[JSON.stringify(s),ie]),[ue,ve]=An("",X),pe=ue||"",me=INe(S,E,J,le,b),{valueOptions:ke,labelOptions:De,options:Ee}=me,We=y.useCallback(ce=>yce(ce).map(Te=>{let $e,et,Dt,ct;FNe(Te)?$e=Te:(et=Te.label,$e=Te.value);const st=ke.get($e);return st&&(et===void 0&&(et=st==null?void 0:st[b||J.label]),Dt=st==null?void 0:st.disabled,ct=st==null?void 0:st.title),{label:et,value:$e,key:$e,disabled:Dt,title:ct}}),[J,b,ke]),[ze,mt]=An(k,F),Nt=y.useMemo(()=>{var Te;const fe=We(re&&ze===null?[]:ze);return n==="combobox"&&Wke((Te=fe[0])==null?void 0:Te.value)?[]:fe},[ze,We,n,re]),[St,Ze]=RNe(Nt,ke),Fe=y.useMemo(()=>{if(!n&&St.length===1){const ce=St[0];if(ce.value===null&&(ce.label===null||ce.label===void 0))return[]}return St.map(ce=>({...ce,label:(typeof L=="function"?L(ce):ce.label)??ce.value}))},[n,St,L]),tt=y.useMemo(()=>new Set(St.map(ce=>ce.value)),[St]);y.useEffect(()=>{var ce;if(n==="combobox"){const fe=(ce=St[0])==null?void 0:ce.value;ve(Hke(fe)?String(fe):"")}},[St]);const Ne=mq((ce,fe)=>{const Te=fe??ce;return{[J.value]:ce,[J.label]:Te}}),rt=y.useMemo(()=>{if(n!=="tags")return Ee;const ce=[...Ee],fe=Te=>ke.has(Te);return[...St].sort((Te,$e)=>Te.value<$e.value?-1:1).forEach(Te=>{const $e=Te.value;fe($e)||ce.push(Ne($e,Te.label))}),ce},[Ne,Ee,ke,St,n]),ot=PNe(rt,J,pe,de,le),Ye=y.useMemo(()=>{const ce=fe=>le.length?le.some(Te=>(fe==null?void 0:fe[Te])===pe):(fe==null?void 0:fe.value)===pe;return n!=="tags"||!pe||ot.some(fe=>ce(fe))||ot.some(fe=>fe[J.value]===pe)?ot:[Ne(pe),...ot]},[Ne,le,n,ot,pe,J]),Ae=ce=>[...ce].sort((Te,$e)=>oe(Te,$e,{searchValue:pe})).map(Te=>Array.isArray(Te.options)?{...Te,options:Te.options.length>0?Ae(Te.options):Te.options}:Te),nt=y.useMemo(()=>oe?Ae(Ye):Ye,[Ye,oe,pe]),Et=y.useMemo(()=>Bke(nt,{fieldNames:J,childrenAsData:ie}),[nt,J,ie]),Tt=ce=>{const fe=We(ce);if(mt(fe),B&&(fe.length!==St.length||fe.some((Te,$e)=>{var et;return((et=St[$e])==null?void 0:et.value)!==(Te==null?void 0:Te.value)}))){const Te=O?fe.map(({label:et,value:Dt})=>({label:et,value:Dt})):fe.map(et=>et.value),$e=fe.map(et=>y$(Ze(et.value)));B(re?Te:Te[0],re?$e:$e[0])}},[kt,Wt]=y.useState(null),[at,lt]=y.useState(0),Ut=R!==void 0?R:n!=="combobox",cr=y.useRef(),_e=y.useCallback((ce,fe,{source:Te="keyboard"}={})=>{lt(fe),o&&n==="combobox"&&ce!==null&&Te==="keyboard"&&Wt(String(ce));const $e=Promise.resolve().then(()=>{cr.current===$e&&(m==null||m(ce))});cr.current=$e},[o,n,m]),qe=(ce,fe,Te)=>{const $e=()=>{const et=Ze(ce);return[O?{label:et==null?void 0:et[J.label],value:ce}:ce,y$(et)]};if(fe&&f){const[et,Dt]=$e();f(et,Dt)}else if(!fe&&g&&Te!=="clear"){const[et,Dt]=$e();g(et,Dt)}},Re=mq((ce,fe)=>{let Te;const $e=re?fe.selected:!0;$e?Te=re?[...St,ce]:[ce]:Te=St.filter(et=>et.value!==ce),Tt(Te),qe(ce,$e),n==="combobox"?Wt(""):(!x$||ne)&&(ve(""),Wt(""))}),it=(ce,fe)=>{Tt(ce);const{type:Te,values:$e}=fe;(Te==="remove"||Te==="clear")&&$e.forEach(et=>{qe(et.value,!1,Te)})},Ve=(ce,fe)=>{if(ve(ce),Wt(null),fe.source==="submit"){const Te=(ce||"").trim();if(Te){const $e=Array.from(new Set([...tt,Te]));Tt($e),qe(Te,!0),ve("")}return}fe.source!=="blur"&&(n==="combobox"&&Tt(ce),ee==null||ee(ce))},Oe=ce=>{let fe=ce;n!=="tags"&&(fe=ce.map($e=>{const et=De.get($e);return et==null?void 0:et.value}).filter($e=>$e!==void 0));const Te=Array.from(new Set([...tt,...fe]));Tt(Te),Te.forEach($e=>{qe($e,!0)})},se=y.useMemo(()=>({...me,flattenOptions:Et,onActiveValue:_e,defaultActiveFirstOption:Ut,onSelect:Re,menuItemSelectedIcon:T,rawValues:tt,fieldNames:J,virtual:M!==!1&&v!==!1,direction:D,listHeight:A,listItemHeight:I,childrenAsData:ie,maxCount:H,optionRender:x,classNames:N,styles:z}),[H,me,Et,_e,Ut,Re,T,tt,J,M,v,D,A,I,ie,x,N,z]);return y.createElement(t4.Provider,{value:se},y.createElement(sNe,T$({},W,{id:he,prefixCls:i,ref:t,omitDomProps:ANe,mode:n,classNames:N,styles:z,displayValues:Fe,onDisplayValuesChange:it,maxCount:H,direction:D,showSearch:$,searchValue:pe,onSearch:Ve,autoClearSearchValue:ne,onSearchSplit:Oe,popupMatchSelectWidth:v,OptionList:TNe,emptyOptions:!Et.length,activeValue:kt,activeDescendantId:`${he}_list_${at}`})))}),i4=LNe;i4.Option=n4;i4.OptGroup=r4;const Wy=(e,t,r)=>Q({[`${e}-status-success`]:t==="success",[`${e}-status-warning`]:t==="warning",[`${e}-status-error`]:t==="error",[`${e}-status-validating`]:t==="validating",[`${e}-has-feedback`]:r}),Ux=(e,t)=>t||e,_Ne=()=>{const[,e]=fs(),[t]=Dl("Empty"),n=new cn(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return y.createElement("svg",{style:n,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},y.createElement("title",null,(t==null?void 0:t.description)||"Empty"),y.createElement("g",{fill:"none",fillRule:"evenodd"},y.createElement("g",{transform:"translate(24 31.7)"},y.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.8",cy:"106.9",rx:"67.8",ry:"12.7"}),y.createElement("path",{fill:"#aeb8c2",d:"M122 69.7 98.1 40.2a6 6 0 0 0-4.6-2.2H42.1a6 6 0 0 0-4.6 2.2l-24 29.5V85H122z"}),y.createElement("path",{fill:"#f5f5f7",d:"M33.8 0h68a4 4 0 0 1 4 4v93.3a4 4 0 0 1-4 4h-68a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4"}),y.createElement("path",{fill:"#dce0e6",d:"M42.7 10h50.2a2 2 0 0 1 2 2v25a2 2 0 0 1-2 2H42.7a2 2 0 0 1-2-2V12a2 2 0 0 1 2-2m.2 39.8h49.8a2.3 2.3 0 1 1 0 4.5H42.9a2.3 2.3 0 0 1 0-4.5m0 11.7h49.8a2.3 2.3 0 1 1 0 4.6H42.9a2.3 2.3 0 0 1 0-4.6m79 43.5a7 7 0 0 1-6.8 5.4H20.5a7 7 0 0 1-6.7-5.4l-.2-1.8V69.7h26.3c2.9 0 5.2 2.4 5.2 5.4s2.4 5.4 5.3 5.4h34.8c2.9 0 5.3-2.4 5.3-5.4s2.3-5.4 5.2-5.4H122v33.5q0 1-.2 1.8"})),y.createElement("path",{fill:"#dce0e6",d:"m149.1 33.3-6.8 2.6a1 1 0 0 1-1.3-1.2l2-6.2q-4.1-4.5-4.2-10.4c0-10 10.1-18.1 22.6-18.1S184 8.1 184 18.1s-10.1 18-22.6 18q-6.8 0-12.3-2.8"}),y.createElement("g",{fill:"#fff",transform:"translate(149.7 15.4)"},y.createElement("circle",{cx:"20.7",cy:"3.2",r:"2.8"}),y.createElement("path",{d:"M5.7 5.6H0L2.9.7zM9.3.7h5v5h-5z"}))))},ONe=()=>{const[,e]=fs(),[t]=Dl("Empty"),{colorFill:r,colorFillTertiary:n,colorFillQuaternary:i,colorBgContainer:o}=e,{borderColor:s,shadowColor:a,contentColor:l}=y.useMemo(()=>({borderColor:new cn(r).onBackground(o).toHexString(),shadowColor:new cn(n).onBackground(o).toHexString(),contentColor:new cn(i).onBackground(o).toHexString()}),[r,n,i,o]);return y.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},y.createElement("title",null,(t==null?void 0:t.description)||"Empty"),y.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},y.createElement("ellipse",{fill:a,cx:"32",cy:"33",rx:"32",ry:"7"}),y.createElement("g",{fillRule:"nonzero",stroke:s},y.createElement("path",{d:"M55 12.8 44.9 1.3Q44 0 42.9 0H21.1q-1.2 0-2 1.3L9 12.8V22h46z"}),y.createElement("path",{d:"M41.6 16c0-1.7 1-3 2.2-3H55v18.1c0 2.2-1.3 3.9-3 3.9H12c-1.7 0-3-1.7-3-3.9V13h11.2c1.2 0 2.2 1.3 2.2 3s1 2.9 2.2 2.9h14.8c1.2 0 2.2-1.4 2.2-3",fill:l}))))},kNe=e=>{const{componentCls:t,margin:r,marginXS:n,marginXL:i,fontSize:o,lineHeight:s}=e;return{[t]:{marginInline:n,fontSize:o,lineHeight:s,textAlign:"center",[`${t}-image`]:{height:e.emptyImgHeight,marginBottom:n,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${t}-description`]:{color:e.colorTextDescription},[`${t}-footer`]:{marginTop:r},"&-normal":{marginBlock:i,color:e.colorTextDescription,[`${t}-description`]:{color:e.colorTextDescription},[`${t}-image`]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:n,color:e.colorTextDescription,[`${t}-image`]:{height:e.emptyImgHeightSM}}}}},NNe=Wr("Empty",e=>{const{componentCls:t,controlHeightLG:r,calc:n}=e,i=$r(e,{emptyImgCls:`${t}-img`,emptyImgHeight:n(r).mul(2.5).equal(),emptyImgHeightMD:r,emptyImgHeightSM:n(r).mul(.875).equal()});return kNe(i)}),Tce=y.createElement(_Ne,null),Rce=y.createElement(ONe,null),ad=e=>{const{className:t,rootClassName:r,prefixCls:n,image:i,description:o,children:s,imageStyle:a,style:l,classNames:c,styles:u,...d}=e,{getPrefixCls:h,direction:p,className:f,style:g,classNames:m,styles:v,image:b}=Nr("empty"),S=h("empty",n),[x,E]=NNe(S),[R,T]=Vr([m,c],[v,u],{props:e}),[M]=Dl("Empty"),D=typeof o<"u"?o:M==null?void 0:M.description,A=typeof D=="string"?D:"empty",I=i??b??Tce;let L=null;return typeof I=="string"?L=y.createElement("img",{draggable:!1,alt:A,src:I}):L=I,y.createElement("div",{className:Q(x,E,S,f,{[`${S}-normal`]:I===Rce,[`${S}-rtl`]:p==="rtl"},t,r,R.root),style:{...T.root,...g,...l},...d},y.createElement("div",{className:Q(`${S}-image`,R.image),style:{...a,...T.image}},L),D&&y.createElement("div",{className:Q(`${S}-description`,R.description),style:T.description},D),s&&y.createElement("div",{className:Q(`${S}-footer`,R.footer),style:T.footer},s))};ad.PRESENTED_IMAGE_DEFAULT=Tce;ad.PRESENTED_IMAGE_SIMPLE=Rce;const o4=e=>{const{componentName:t}=e,{getPrefixCls:r}=y.useContext(ir),n=r("empty");switch(t){case"Table":case"List":return Z.createElement(ad,{image:ad.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return Z.createElement(ad,{image:ad.PRESENTED_IMAGE_SIMPLE,className:`${n}-small`});case"Table.filter":return null;default:return Z.createElement(ad,null)}},jx=(e,t,r)=>{const{variant:n,[e]:i}=y.useContext(ir),o=y.useContext(zOe),s=i==null?void 0:i.variant;let a;typeof t<"u"?a=t:r===!1?a="borderless":a=o??s??n??"outlined";const l=MIe.includes(a);return[a,l]},BNe=e=>{const r={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:e==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:{...r,points:["tl","bl"],offset:[0,4]},bottomRight:{...r,points:["tr","br"],offset:[0,4]},topLeft:{...r,points:["bl","tl"],offset:[0,-4]},topRight:{...r,points:["br","tr"],offset:[0,-4]}}};function $Ne(e,t){return e||BNe(t)}const vq=e=>{const{optionHeight:t,optionFontSize:r,optionLineHeight:n,optionPadding:i}=e;return{position:"relative",display:"block",minHeight:t,padding:i,color:e.colorText,fontWeight:"normal",fontSize:r,lineHeight:n,boxSizing:"border-box"}},GNe=e=>{const{antCls:t,componentCls:r}=e,n=`${r}-item`,i=`&${t}-slide-up-enter${t}-slide-up-enter-active`,o=`&${t}-slide-up-appear${t}-slide-up-appear-active`,s=`&${t}-slide-up-leave${t}-slide-up-leave-active`,a=`${r}-dropdown-placement-`,l=`${n}-option-selected`;return[{[`${r}-dropdown`]:{...on(e),position:"absolute",top:-9999,zIndex:e.zIndexPopup,boxSizing:"border-box",padding:e.paddingXXS,overflow:"hidden",fontSize:e.fontSize,fontVariant:"initial",backgroundColor:e.colorBgElevated,borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,[` ${i}${a}bottomLeft, ${o}${a}bottomLeft `]:{animationName:z3},[` ${i}${a}topLeft, ${o}${a}topLeft, ${i}${a}topRight, ${o}${a}topRight `]:{animationName:W3},[`${s}${a}bottomLeft`]:{animationName:H3},[` ${s}${a}topLeft, ${s}${a}topRight `]:{animationName:U3},"&-hidden":{display:"none"},[n]:{...vq(e),cursor:"pointer",transition:`background-color ${e.motionDurationSlow} ease`,borderRadius:e.borderRadiusSM,"&-group":{color:e.colorTextDescription,fontSize:e.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":{flex:"auto",...Ps},"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${n}-option-disabled)`]:{backgroundColor:e.optionActiveBg},[`&-selected:not(${n}-option-disabled)`]:{color:e.optionSelectedColor,fontWeight:e.optionSelectedFontWeight,backgroundColor:e.optionSelectedBg,[`${n}-option-state`]:{color:e.colorPrimary}},"&-disabled":{[`&${n}-option-selected`]:{backgroundColor:e.colorBgContainerDisabled},color:e.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:e.calc(e.controlPaddingHorizontal).mul(2).equal()}},"&-empty":{...vq(e),color:e.colorTextDisabled}},[`${l}:has(+ ${l})`]:{borderEndStartRadius:0,borderEndEndRadius:0,[`& + ${l}`]:{borderStartStartRadius:0,borderStartEndRadius:0}},"&-rtl":{direction:"rtl"}}},Tp(e,"slide-up"),Tp(e,"slide-down"),uM(e,"move-up"),uM(e,"move-down")]},VNe=e=>{const{componentCls:t}=e;return{[`&${t}-customize`]:{border:0,padding:0,fontSize:"inherit",lineHeight:"inherit",[`${t}-placeholder`]:{display:"none"},[`${t}-content`]:{margin:0,padding:0,"&-value":{display:"none"}}}}},yq=4,zNe=e=>{const{componentCls:t,calc:r,iconCls:n,paddingXS:i,paddingXXS:o,INTERNAL_FIXED_ITEM_MARGIN:s,lineWidth:a,colorIcon:l,colorIconHover:c,inputPaddingHorizontalBase:u,antCls:d}=e,[h,p]=Jn(d,"select");return{"&-multiple":{[h("multi-item-background")]:e.multipleItemBg,[h("multi-item-border-color")]:"transparent",[h("multi-item-border-radius")]:e.borderRadiusSM,[h("multi-item-height")]:e.multipleItemHeight,[h("multi-padding-base")]:`calc((${p("height")} - ${p("multi-item-height")}) / 2)`,[h("multi-padding-vertical")]:`calc(${p("multi-padding-base")} - ${s} - ${a})`,[h("multi-item-padding-horizontal")]:`calc(${u} - ${p("multi-padding-vertical")} - ${a} * 2)`,paddingBlock:p("multi-padding-vertical"),paddingInlineStart:`calc(${p("multi-padding-base")} - ${a})`,[`${t}-prefix`]:{marginInlineStart:p("multi-item-padding-horizontal")},[`${t}-prefix + ${t}-content`]:{[`${t}-placeholder`]:{insetInlineStart:0},[`${t}-content-item${t}-content-item-suffix`]:{marginInlineStart:0}},[`${t}-placeholder`]:{position:"absolute",lineHeight:p("line-height"),insetInlineStart:p("multi-item-padding-horizontal"),width:`calc(100% - ${p("multi-item-padding-horizontal")})`,top:"50%",transform:"translateY(-50%)"},[`${t}-content`]:{flexWrap:"wrap",alignItems:"center",lineHeight:1,"&-item-prefix":{height:p("font-size")},"&-item":{lineHeight:1,maxWidth:`calc(100% - ${yq}px)`},[`${t}-content-item-prefix + ${t}-content-item-suffix, ${t}-content-item-suffix:first-child`]:{marginInlineStart:p("multi-item-padding-horizontal")},[`${t}-selection-item`]:{lineHeight:`calc(${p("multi-item-height")} - ${a} * 2)`,border:`${a} solid ${p("multi-item-border-color")}`,display:"flex",marginBlock:s,marginInlineEnd:r(s).mul(2).equal(),background:p("multi-item-background"),borderRadius:p("multi-item-border-radius"),paddingInlineStart:i,paddingInlineEnd:o,transition:["height","line-height","padding"].map(f=>`${f} ${e.motionDurationSlow}`).join(","),"&-content":{...Ps,marginInlineEnd:o},"&-remove":{...Ix(),display:"inline-flex",alignItems:"center",color:l,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${n}`]:{verticalAlign:"-0.2em"},"&:hover":{color:c}}},[`${t}-input`]:{lineHeight:r(s).mul(2).add(p("multi-item-height")).equal(),width:"calc(var(--select-input-width, 0) * 1px)",minWidth:yq,maxWidth:"100%",transition:`line-height ${e.motionDurationSlow}`}},[`&${t}-sm`]:{[h("multi-item-height")]:e.multipleItemHeightSM,[h("multi-item-border-radius")]:e.borderRadiusXS},[`&${t}-lg`]:{[h("multi-item-height")]:e.multipleItemHeightLG,[h("multi-item-border-radius")]:e.borderRadius},[`&${t}-filled`]:{[h("multi-item-border-color")]:e.colorSplit,[h("multi-item-background")]:e.colorBgContainer,[`&${t}-disabled`]:{[h("multi-item-border-color")]:"transparent"}}}}},eO=(e,t)=>{const{componentCls:r,antCls:n}=e,[i]=Jn(n,"select"),{border:o,borderHover:s,borderActive:a,borderOutline:l}=t,c=t.background||e.selectorBg||e.colorBgContainer;return{[i("border-color")]:o,[i("background-color")]:c,[i("color")]:t.color||e.colorText,[`&:not(${r}-disabled)`]:{"&:hover":{[i("border-color")]:s,[i("background-color")]:t.backgroundHover||c},[`&${r}-focused`]:{[i("border-color")]:a,[i("background-color")]:t.backgroundActive||c,boxShadow:`0 0 0 ${ae(e.controlOutlineWidth)} ${l}`}},[`&${r}-disabled`]:{[i("border-color")]:t.borderDisabled||t.border,[i("background-color")]:t.backgroundDisabled||t.background}}},aT=(e,t,r,n={},i={},o)=>{const{componentCls:s}=e;return{[`&${s}-${t}`]:[eO(e,r),{[`&${s}-status-error`]:eO(e,{...r,color:n.color||e.colorError,...n}),[`&${s}-status-warning`]:eO(e,{...r,color:i.color||e.colorWarning,...i})},o]}},HNe=e=>{const{componentCls:t,fontHeight:r,controlHeight:n,iconCls:i,antCls:o,calc:s}=e,[a,l]=Jn(o,"select");return{[t]:[{[a("border-radius")]:e.borderRadius,[a("border-color")]:"#000",[a("border-size")]:e.lineWidth,[a("background-color")]:e.colorBgContainer,[a("font-size")]:e.fontSize,[a("line-height")]:e.lineHeight,[a("font-height")]:r,[a("color")]:e.colorText,[a("height")]:n,[a("padding-horizontal")]:s(e.paddingSM).sub(e.lineWidth).equal(),[a("padding-vertical")]:`calc((${l("height")} - ${l("font-height")}) / 2 - ${l("border-size")})`,...on(e,!0),display:"inline-flex",flexWrap:"nowrap",position:"relative",transition:`all ${e.motionDurationSlow}`,alignItems:"flex-start",outline:0,cursor:"pointer",borderRadius:l("border-radius"),borderWidth:l("border-size"),borderStyle:e.lineType,borderColor:l("border-color"),background:l("background-color"),fontSize:l("font-size"),lineHeight:l("line-height"),color:l("color"),paddingInline:l("padding-horizontal"),paddingBlock:l("padding-vertical"),[`${t}-prefix`]:{flex:"none",lineHeight:1},[`${t}-placeholder`]:{...Ps,color:e.colorTextPlaceholder,pointerEvents:"none",zIndex:1},[`${t}-content`]:{flex:"auto",minWidth:0,position:"relative",display:"flex",marginInlineEnd:s(e.paddingXXS).mul(1.5).equal(),"&:before":{content:'"\\a0"',width:0,overflow:"hidden"},"&-value":{visibility:"inherit"},"input[readonly]":{cursor:"inherit",caretColor:"transparent"}},[`${t}-suffix`]:{flex:"none",color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,"> :not(:last-child)":{marginInlineEnd:e.marginXS}},[`${t}-prefix, ${t}-suffix`]:{alignSelf:"center",[i]:{verticalAlign:"top"}},"&-disabled":{background:e.colorBgContainerDisabled,color:e.colorTextDisabled,cursor:"not-allowed",input:{cursor:"not-allowed"}},"&-sm":{[a("height")]:e.controlHeightSM,[a("padding-horizontal")]:s(e.paddingXS).sub(e.lineWidth).equal(),[a("border-radius")]:e.borderRadiusSM,[`${t}-clear`]:{insetInlineEnd:l("padding-horizontal")}},"&-lg":{[a("height")]:e.controlHeightLG,[a("font-size")]:e.fontSizeLG,[a("line-height")]:e.lineHeightLG,[a("font-height")]:e.fontHeightLG,[a("border-radius")]:e.borderRadiusLG}},{[`&:not(${t}-customize)`]:{[`${t}-input`]:{outline:"none",background:"transparent",appearance:"none",border:0,margin:0,padding:0,color:l("color"),"&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},{[`&-single:not(${t}-customize)`]:{[`${t}-input`]:{position:"absolute",inset:0,lineHeight:`calc(${l("font-height")} + ${l("padding-vertical")} * 2)`},[`${t}-content`]:{...Ps,alignSelf:"center","&-has-value":{display:"block","&:before":{display:"none"}},"&-has-search-value":{color:"transparent"},"&-value":{transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,zIndex:1}},[`&${t}-open ${t}-content`]:{color:e.colorTextPlaceholder,"&-has-search-value":{color:"transparent"}}}},{[`&-show-search:not(${t}-customize-input):not(${t}-disabled)`]:{cursor:"text"}},zNe(e),aT(e,"outlined",{border:e.colorBorder,borderHover:e.hoverBorderColor,borderActive:e.activeBorderColor,borderOutline:e.activeOutlineColor,borderDisabled:e.colorBorderDisabled},{border:e.colorError,borderHover:e.colorErrorHover,borderActive:e.colorError,borderOutline:e.colorErrorOutline},{border:e.colorWarning,borderHover:e.colorWarningHover,borderActive:e.colorWarning,borderOutline:e.colorWarningOutline}),aT(e,"filled",{border:"transparent",borderHover:"transparent",borderActive:e.activeBorderColor,borderOutline:"transparent",borderDisabled:e.colorBorderDisabled,background:e.colorFillTertiary,backgroundHover:e.colorFillSecondary,backgroundActive:e.colorBgContainer},{background:e.colorErrorBg,backgroundHover:e.colorErrorBgHover,borderActive:e.colorError},{background:e.colorWarningBg,backgroundHover:e.colorWarningBgHover,borderActive:e.colorWarning}),aT(e,"borderless",{border:"transparent",borderHover:"transparent",borderActive:"transparent",borderOutline:"transparent",background:"transparent"}),aT(e,"underlined",{border:e.colorBorder,borderHover:e.hoverBorderColor,borderActive:e.activeBorderColor,borderOutline:"transparent"},{border:e.colorError,borderHover:e.colorErrorHover,borderActive:e.colorError},{border:e.colorWarning,borderHover:e.colorWarningHover,borderActive:e.colorWarning},{borderRadius:0,borderTopColor:"transparent",borderRightColor:"transparent",borderLeftColor:"transparent"}),VNe(e)]}},WNe=e=>{const{fontSize:t,lineHeight:r,lineWidth:n,controlHeight:i,controlHeightSM:o,controlHeightLG:s,paddingXXS:a,controlPaddingHorizontal:l,zIndexPopupBase:c,colorText:u,fontWeightStrong:d,controlItemBgActive:h,controlItemBgHover:p,colorBgContainer:f,colorFillSecondary:g,colorBgContainerDisabled:m,colorTextDisabled:v,colorPrimaryHover:b,colorPrimary:S,controlOutline:x}=e,E=a*2,R=n*2,T=Math.min(i-E,i-R),M=Math.min(o-E,o-R),D=Math.min(s-E,s-R);return{INTERNAL_FIXED_ITEM_MARGIN:Math.floor(a/2),zIndexPopup:c+50,optionSelectedColor:u,optionSelectedFontWeight:d,optionSelectedBg:h,optionActiveBg:p,optionPadding:`${(i-t*r)/2}px ${l}px`,optionFontSize:t,optionLineHeight:r,optionHeight:i,selectorBg:f,clearBg:f,singleItemHeightLG:s,multipleItemBg:g,multipleItemBorderColor:"transparent",multipleItemHeight:T,multipleItemHeightSM:M,multipleItemHeightLG:D,multipleSelectorBgDisabled:m,multipleItemColorDisabled:v,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(e.fontSize*1.25),hoverBorderColor:b,activeBorderColor:S,activeOutlineColor:x,selectAffixPadding:a}},UNe=e=>{const{antCls:t,componentCls:r,motionDurationMid:n,inputPaddingHorizontalBase:i}=e,o={[`${r}-clear`]:{opacity:1,background:e.colorBgBase,borderRadius:"50%"}};return{[r]:{...on(e),[`${r}-selection-item`]:{flex:1,fontWeight:"normal",position:"relative",userSelect:"none",...Ps,[`> ${t}-typography`]:{display:"inline"}},[`${r}-prefix`]:{flex:"none",marginInlineEnd:e.selectAffixPadding},[`${r}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:i,zIndex:1,display:"inline-block",width:e.fontSizeIcon,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:["color","opacity"].map(s=>`${s} ${n} ease`).join(", "),textRendering:"auto",transform:"translateZ(0)","&:before":{display:"block"},"&:hover":{color:e.colorIcon}},"@media(hover:none)":o,"&:hover":o},[`${r}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${r}-has-feedback`]:{[`${r}-clear`]:{insetInlineEnd:e.calc(i).add(e.fontSize).add(e.paddingXS).equal()}}}}}},jNe=e=>{const{componentCls:t}=e;return[{[t]:{[`&${t}-in-form-item`]:{width:"100%"}}},UNe(e),GNe(e),{[`${t}-rtl`]:{direction:"rtl"}},Bx(e,{focusElCls:`${t}-focused`})]},KNe=Wr("Select",(e,{rootPrefixCls:t})=>{const r=$r(e,{rootPrefixCls:t,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(e.lineWidth).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[jNe(r),HNe(r)]},WNe,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}});var qNe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"};function R$(){return R$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,R$({},e,{ref:t,icon:qNe})),s4=y.forwardRef(XNe);var YNe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};function P$(){return P$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,P$({},e,{ref:t,icon:YNe})),XD=y.forwardRef(ZNe);var QNe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"};function M$(){return M$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,M$({},e,{ref:t,icon:QNe})),a4=y.forwardRef(JNe);function e2e({suffixIcon:e,clearIcon:t,menuItemSelectedIcon:r,removeIcon:n,loading:i,loadingIcon:o,multiple:s,hasFeedback:a,showSuffixIcon:l,feedbackIcon:c,showArrow:u,componentName:d}){const h=t??y.createElement(Ax,null),p=v=>e===null&&!a&&!u?null:y.createElement(y.Fragment,null,l!==!1&&v,a&&c);let f=null;e!==void 0?f=p(e):i?f=p(o??y.createElement(rm,{spin:!0})):f=({open:v,showSearch:b})=>p(v&&b?y.createElement(a4,null):y.createElement(XD,null));let g=null;r!==void 0?g=r:s?g=y.createElement(s4,null):g=null;let m=null;return n!==void 0?m=n:m=y.createElement(Xd,null),{clearIcon:h,suffixIcon:f,itemIcon:g,removeIcon:m}}function t2e(e){return Z.useMemo(()=>{if(e)return(...t)=>Z.createElement(Rp,{space:!0},e.apply(void 0,t))},[e])}function r2e(e,t){return t!==void 0?t:e!==null}const Pce="SECRET_COMBOBOX_MODE_DO_NOT_USE",n2e=(e,t)=>{var fe,Te,$e,et,Dt;const{prefixCls:r,bordered:n,className:i,rootClassName:o,getPopupContainer:s,popupClassName:a,dropdownClassName:l,listHeight:c=256,placement:u,listItemHeight:d,size:h,disabled:p,notFoundContent:f,status:g,builtinPlacements:m,dropdownMatchSelectWidth:v,popupMatchSelectWidth:b,direction:S,style:x,allowClear:E,variant:R,popupStyle:T,dropdownStyle:M,transitionName:D,tagRender:A,maxCount:I,prefix:L,dropdownRender:F,popupRender:k,onDropdownVisibleChange:O,onOpenChange:B,styles:H,classNames:N,...z}=e,{getPopupContainer:W,getPrefixCls:V,renderEmpty:$,direction:K,virtual:q,popupMatchSelectWidth:X,popupOverflow:Y}=y.useContext(ir),{showSearch:oe,style:ee,styles:ne,className:le,classNames:he}=Nr("select"),[,re]=fs(),ie=d??(re==null?void 0:re.controlHeight),de=V("select",r),J=V(),ue=S??K,{compactSize:ve,compactItemClassnames:pe}=Wp(de,ue),[me,ke]=jx("select",R,n),De=ho(de),[Ee,We]=KNe(de,De),ze=y.useMemo(()=>{const{mode:ct}=e;if(ct!=="combobox")return ct===Pce?"combobox":ct},[e.mode]),mt=ze==="multiple"||ze==="tags",Nt=r2e(e.suffixIcon,e.showArrow),St=b??v??X,Ze=t2e(k||F),Fe=B||O,{status:tt,hasFeedback:Ne,isFormItemInput:rt,feedbackIcon:ot}=y.useContext(ua),Ye=Ux(tt,g);let Ae;f!==void 0?Ae=f:ze==="combobox"?Ae=null:Ae=($==null?void 0:$("Select"))||y.createElement(o4,{componentName:"Select"});const{suffixIcon:nt,itemIcon:Et,removeIcon:Tt,clearIcon:kt}=e2e({...z,multiple:mt,hasFeedback:Ne,feedbackIcon:ot,showSuffixIcon:Nt,componentName:"Select"}),Wt=E===!0?{clearIcon:kt}:E,at=fn(z,["suffixIcon","itemIcon"]),lt=ki(ct=>h??ve??ct),Ut=y.useContext(hs),cr=p??Ut,_e={...e,variant:me,status:Ye,disabled:cr,size:lt},[qe,Re]=Vr([he,N],[ne,H],{props:_e},{popup:{_default:"root"}}),it=Q((fe=qe.popup)==null?void 0:fe.root,a,l,{[`${de}-dropdown-${ue}`]:ue==="rtl"},o,We,De,Ee),Ve={...(Te=Re.popup)==null?void 0:Te.root,...T??M},Oe=Q({[`${de}-lg`]:lt==="large",[`${de}-sm`]:lt==="small",[`${de}-rtl`]:ue==="rtl",[`${de}-${me}`]:ke,[`${de}-in-form-item`]:rt},Wy(de,Ye,Ne),pe,le,i,qe.root,o,We,De,Ee),se=y.useMemo(()=>u!==void 0?u:ue==="rtl"?"bottomRight":"bottomLeft",[u,ue]),[ce]=Hp("SelectLike",((et=($e=Re.popup)==null?void 0:$e.root)==null?void 0:et.zIndex)??(Ve==null?void 0:Ve.zIndex));return y.createElement(i4,{ref:t,virtual:q,classNames:qe,styles:Re,showSearch:oe,...at,style:{...Re.root,...ee,...x},popupMatchSelectWidth:St,transitionName:mu(J,"slide-up",D),builtinPlacements:$Ne(m,Y),listHeight:c,listItemHeight:ie,mode:ze,prefixCls:de,placement:se,direction:ue,prefix:L,suffixIcon:nt,menuItemSelectedIcon:Et,removeIcon:Tt,allowClear:Wt,notFoundContent:Ae,className:Oe,getPopupContainer:s||W,popupClassName:it,disabled:cr,popupStyle:{...(Dt=Re.popup)==null?void 0:Dt.root,...Ve,zIndex:ce},maxCount:mt?I:void 0,tagRender:mt?A:void 0,popupRender:Ze,onPopupVisibleChange:Fe})},vu=y.forwardRef(n2e),i2e=J3(vu,"popupAlign");vu.SECRET_COMBOBOX_MODE_DO_NOT_USE=Pce;vu.Option=n4;vu.OptGroup=r4;vu._InternalPanelDoNotUseOrYouWillBeFired=i2e;const{Option:Cq}=vu;function bq(e){return(e==null?void 0:e.type)&&(e.type.isSelectOption||e.type.isSelectOptGroup)}const o2e=(e,t)=>{const{prefixCls:r,className:n,style:i,popupClassName:o,dropdownClassName:s,children:a,dataSource:l,rootClassName:c,dropdownStyle:u,dropdownRender:d,popupRender:h,onDropdownVisibleChange:p,onOpenChange:f,styles:g,classNames:m}=e,v=Li(a),b=h||d,S=f||p;let x;v.length===1&&y.isValidElement(v[0])&&!bq(v[0])&&([x]=v);const E=x?()=>x:void 0;let R;v.length&&bq(v[0])?R=a:R=l?l.map(k=>{if(y.isValidElement(k))return k;switch(typeof k){case"string":return y.createElement(Cq,{key:k,value:k},k);case"object":{const{value:O}=k;return y.createElement(Cq,{key:O,value:O},k.text)}default:return}}):[];const{getPrefixCls:T}=y.useContext(ir),M=T("select",r),D={...e,dataSource:l,status:e.status,popupMatchSelectWidth:e.popupMatchSelectWidth||e.dropdownMatchSelectWidth,popupRender:b,onOpenChange:S},[A,I]=Vr([m],[g],{props:D},{popup:{_default:"root"}}),L=y.useMemo(()=>{var k,O,B;return{root:Q(`${M}-auto-complete`,n,c,A.root,{[`${M}-customize`]:x}),prefix:A.prefix,input:A.input,placeholder:A.placeholder,content:A.content,popup:{root:Q(o,s,(k=A.popup)==null?void 0:k.root),list:(O=A.popup)==null?void 0:O.list,listItem:(B=A.popup)==null?void 0:B.listItem}}},[M,n,c,A,o,s]),F=y.useMemo(()=>{var k,O,B;return{root:{...I.root,...i},input:I.input,prefix:I.prefix,placeholder:I.placeholder,content:I.content,popup:{root:{...u,...(k=I.popup)==null?void 0:k.root},list:(O=I.popup)==null?void 0:O.list,listItem:(B=I.popup)==null?void 0:B.listItem}}},[I,i,u]);return y.createElement(vu,{ref:t,suffixIcon:null,...fn(e,["dataSource","dropdownClassName","popupClassName"]),prefixCls:M,classNames:L,styles:F,mode:vu.SECRET_COMBOBOX_MODE_DO_NOT_USE,popupRender:b,onPopupVisibleChange:S,getInputElement:E},R)},Mce=y.forwardRef(o2e),{Option:s2e}=vu,a2e=J3(Mce,"popupAlign",e=>fn(e,["visible"])),Ice=Mce;Ice.Option=s2e;Ice._InternalPanelDoNotUseOrYouWillBeFired=a2e;const su=["xxxl","xxl","xl","lg","md","sm","xs"],l2e=[].concat(su).reverse(),c2e=e=>({xs:`(max-width: ${e.screenXSMax}px)`,sm:`(min-width: ${e.screenSM}px)`,md:`(min-width: ${e.screenMD}px)`,lg:`(min-width: ${e.screenLG}px)`,xl:`(min-width: ${e.screenXL}px)`,xxl:`(min-width: ${e.screenXXL}px)`,xxxl:`(min-width: ${e.screenXXXL}px)`}),u2e=e=>{const t=e,r=[].concat(su).reverse();return r.forEach((n,i)=>{const o=n.toUpperCase(),s=`screen${o}Min`,a=`screen${o}`;if(!(t[s]<=t[a]))throw new Error(`${s}<=${a} fails : !(${t[s]}<=${t[a]})`);if(i{if(t){for(const r of su)if(e[r]&&(t==null?void 0:t[r])!==void 0)return t[r]}},d2e=()=>{const[,e]=fs(),t=c2e(u2e(e));return Z.useMemo(()=>{const r=new Map;let n=-1,i={};return{responsiveMap:t,matchHandlers:{},dispatch(o){return i=o,r.forEach(s=>s(i)),r.size>=1},subscribe(o){return r.size||this.register(),n+=1,r.set(n,o),o(i),n},unsubscribe(o){r.delete(o),r.size||this.unregister()},register(){Object.entries(t).forEach(([o,s])=>{const a=({matches:c})=>{this.dispatch({...i,[o]:c})},l=window.matchMedia(s);typeof(l==null?void 0:l.addEventListener)=="function"&&l.addEventListener("change",a),this.matchHandlers[s]={mql:l,listener:a},a(l)})},unregister(){Object.values(t).forEach(o=>{var a;const s=this.matchHandlers[o];typeof((a=s==null?void 0:s.mql)==null?void 0:a.removeEventListener)=="function"&&s.mql.removeEventListener("change",s==null?void 0:s.listener)}),r.clear()}}},[t])};function Kx(e=!0,t={}){const r=y.useRef(t),[,n]=k3(),i=d2e();return jr(()=>{const o=i.subscribe(s=>{r.current=s,e&&n()});return()=>i.unsubscribe(o)},[]),r.current}const Uy=e=>e?typeof e=="function"?e():e:null,l4=e=>{const{children:t,prefixCls:r,id:n,classNames:i,styles:o,className:s,style:a}=e;return y.createElement("div",{id:n,className:Q(`${r}-container`,i==null?void 0:i.container,s),style:{...o==null?void 0:o.container,...a},role:"tooltip"},typeof t=="function"?t():t)},yv={shiftX:64,adjustY:1},Cv={adjustX:1,shiftY:!0},Qa=[0,0],h2e={left:{points:["cr","cl"],overflow:Cv,offset:[-4,0],targetOffset:Qa},right:{points:["cl","cr"],overflow:Cv,offset:[4,0],targetOffset:Qa},top:{points:["bc","tc"],overflow:yv,offset:[0,-4],targetOffset:Qa},bottom:{points:["tc","bc"],overflow:yv,offset:[0,4],targetOffset:Qa},topLeft:{points:["bl","tl"],overflow:yv,offset:[0,-4],targetOffset:Qa},leftTop:{points:["tr","tl"],overflow:Cv,offset:[-4,0],targetOffset:Qa},topRight:{points:["br","tr"],overflow:yv,offset:[0,-4],targetOffset:Qa},rightTop:{points:["tl","tr"],overflow:Cv,offset:[4,0],targetOffset:Qa},bottomRight:{points:["tr","br"],overflow:yv,offset:[0,4],targetOffset:Qa},rightBottom:{points:["bl","br"],overflow:Cv,offset:[4,0],targetOffset:Qa},bottomLeft:{points:["tl","bl"],overflow:yv,offset:[0,4],targetOffset:Qa},leftBottom:{points:["br","bl"],overflow:Cv,offset:[-4,0],targetOffset:Qa}};function I$(){return I$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{trigger:r=["hover"],mouseEnterDelay:n=0,mouseLeaveDelay:i=.1,prefixCls:o="rc-tooltip",children:s,onVisibleChange:a,afterVisibleChange:l,motion:c,placement:u="right",align:d={},destroyOnHidden:h=!1,defaultVisible:p,getTooltipContainer:f,arrowContent:g,overlay:m,id:v,showArrow:b=!0,classNames:S,styles:x,...E}=e,R=xc(v),T=y.useRef(null);y.useImperativeHandle(t,()=>T.current);const M={...E};"visible"in e&&(M.popupVisible=e.visible);const D=y.useMemo(()=>{if(!b)return!1;const I=b===!0?{}:b;return{...I,className:Q(I.className,S==null?void 0:S.arrow),style:{...I.style,...x==null?void 0:x.arrow},content:I.content??g}},[b,S==null?void 0:S.arrow,x==null?void 0:x.arrow,g]),A=({open:I})=>{const L=y.Children.only(s),F={"aria-describedby":m&&I?R:void 0};return y.cloneElement(L,F)};return y.createElement(zD,I$({popupClassName:S==null?void 0:S.root,prefixCls:o,popup:y.createElement(l4,{key:"content",prefixCls:o,id:R,classNames:S,styles:x},m),action:r,builtinPlacements:h2e,popupPlacement:u,ref:T,popupAlign:d,getPopupContainer:f,onOpenChange:a,afterOpenChange:l,popupMotion:c,defaultPopupVisible:p,autoDestroy:h,mouseLeaveDelay:i,popupStyle:x==null?void 0:x.root,mouseEnterDelay:n,arrow:D,uniqueContainerClassName:S==null?void 0:S.uniqueContainer,uniqueContainerStyle:x==null?void 0:x.uniqueContainer},M),A)});function c4(e){const{sizePopupArrow:t,borderRadiusXS:r,borderRadiusOuter:n}=e,i=t/2,o=0,s=i,a=n*1/Math.sqrt(2),l=i-n*(1-1/Math.sqrt(2)),c=i-r*(1/Math.sqrt(2)),u=n*(Math.sqrt(2)-1)+r*(1/Math.sqrt(2)),d=2*i-c,h=u,p=2*i-a,f=l,g=2*i-o,m=s,v=i*Math.sqrt(2)+n*(Math.sqrt(2)-2),b=n*(Math.sqrt(2)-1),S=`polygon(${b}px 100%, 50% ${b}px, ${2*i-b}px 100%, ${b}px 100%)`,x=`path('M ${o} ${s} A ${n} ${n} 0 0 0 ${a} ${l} L ${c} ${u} A ${r} ${r} 0 0 1 ${d} ${h} L ${p} ${f} A ${n} ${n} 0 0 0 ${g} ${m} Z')`;return{arrowShadowWidth:v,arrowPath:x,arrowPolygon:S}}const f2e=(e,t,r)=>{const{sizePopupArrow:n,arrowPolygon:i,arrowPath:o,arrowShadowWidth:s,borderRadiusXS:a,calc:l}=e;return{pointerEvents:"none",width:n,height:n,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:n,height:l(n).div(2).equal(),background:t,clipPath:{_multi_value_:!0,value:[i,o]},content:'""'},"&::after":{content:'""',position:"absolute",width:s,height:s,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${ae(a)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:r,zIndex:0,background:"transparent"}}},Ace=8;function YD(e){const{contentRadius:t,limitVerticalRadius:r}=e,n=t>12?t+2:12;return{arrowOffsetHorizontal:n,arrowOffsetVertical:r?Ace:n}}function lT(e,t){return e?t:{}}const u4=(e,t,r)=>{const{componentCls:n,boxShadowPopoverArrow:i,arrowOffsetVertical:o,arrowOffsetHorizontal:s,antCls:a}=e,[l]=Jn(a,"tooltip"),{arrowDistance:c=0,arrowPlacement:u={left:!0,right:!0,top:!0,bottom:!0}}=r||{};return{[n]:{[`${n}-arrow`]:[{position:"absolute",zIndex:1,display:"block",...f2e(e,t,i),"&:before":{background:t}}],...lT(!!u.top,{[[`&-placement-top > ${n}-arrow`,`&-placement-topLeft > ${n}-arrow`,`&-placement-topRight > ${n}-arrow`].join(",")]:{bottom:c,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${n}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},"&-placement-topLeft":{[l("arrow-offset-x")]:s,[`> ${n}-arrow`]:{left:{_skip_check_:!0,value:s}}},"&-placement-topRight":{[l("arrow-offset-x")]:`calc(100% - ${ae(s)})`,[`> ${n}-arrow`]:{right:{_skip_check_:!0,value:s}}}}),...lT(!!u.bottom,{[[`&-placement-bottom > ${n}-arrow`,`&-placement-bottomLeft > ${n}-arrow`,`&-placement-bottomRight > ${n}-arrow`].join(",")]:{top:c,transform:"translateY(-100%)"},[`&-placement-bottom > ${n}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},"&-placement-bottomLeft":{[l("arrow-offset-x")]:s,[`> ${n}-arrow`]:{left:{_skip_check_:!0,value:s}}},"&-placement-bottomRight":{[l("arrow-offset-x")]:`calc(100% - ${ae(s)})`,[`> ${n}-arrow`]:{right:{_skip_check_:!0,value:s}}}}),...lT(!!u.left,{[[`&-placement-left > ${n}-arrow`,`&-placement-leftTop > ${n}-arrow`,`&-placement-leftBottom > ${n}-arrow`].join(",")]:{right:{_skip_check_:!0,value:c},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${n}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${n}-arrow`]:{top:o},[`&-placement-leftBottom > ${n}-arrow`]:{bottom:o}}),...lT(!!u.right,{[[`&-placement-right > ${n}-arrow`,`&-placement-rightTop > ${n}-arrow`,`&-placement-rightBottom > ${n}-arrow`].join(",")]:{left:{_skip_check_:!0,value:c},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${n}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${n}-arrow`]:{top:o},[`&-placement-rightBottom > ${n}-arrow`]:{bottom:o}})}}};function g2e(e,t,r,n){if(n===!1)return{adjustX:!1,adjustY:!1};const i=n&&typeof n=="object"?n:{},o={};switch(e){case"top":case"bottom":o.shiftX=t.arrowOffsetHorizontal*2+r,o.shiftY=!0,o.adjustY=!0;break;case"left":case"right":o.shiftY=t.arrowOffsetVertical*2+r,o.shiftX=!0,o.adjustX=!0;break}const s={...o,...i};return s.shiftX||(s.adjustX=!0),s.shiftY||(s.adjustY=!0),s}const Sq={left:{points:["cr","cl"]},right:{points:["cl","cr"]},top:{points:["bc","tc"]},bottom:{points:["tc","bc"]},topLeft:{points:["bl","tl"]},leftTop:{points:["tr","tl"]},topRight:{points:["br","tr"]},rightTop:{points:["tl","tr"]},bottomRight:{points:["tr","br"]},rightBottom:{points:["bl","br"]},bottomLeft:{points:["tl","bl"]},leftBottom:{points:["br","bl"]}},m2e={topLeft:{points:["bl","tc"]},leftTop:{points:["tr","cl"]},topRight:{points:["br","tc"]},rightTop:{points:["tl","cr"]},bottomRight:{points:["tr","bc"]},rightBottom:{points:["bl","cr"]},bottomLeft:{points:["tl","bc"]},leftBottom:{points:["br","cl"]}},v2e=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function Fce(e){const{arrowWidth:t,autoAdjustOverflow:r,arrowPointAtCenter:n,offset:i,borderRadius:o,visibleFirst:s}=e,a=t/2,l={},c=YD({contentRadius:o,limitVerticalRadius:!0});return Object.keys(Sq).forEach(u=>{const h={...n&&m2e[u]||Sq[u],offset:[0,0],dynamicInset:!0};switch(l[u]=h,v2e.has(u)&&(h.autoArrow=!1),u){case"top":case"topLeft":case"topRight":h.offset[1]=-a-i;break;case"bottom":case"bottomLeft":case"bottomRight":h.offset[1]=a+i;break;case"left":case"leftTop":case"leftBottom":h.offset[0]=-a-i;break;case"right":case"rightTop":case"rightBottom":h.offset[0]=a+i;break}if(n)switch(u){case"topLeft":case"bottomLeft":h.offset[0]=-c.arrowOffsetHorizontal-a;break;case"topRight":case"bottomRight":h.offset[0]=c.arrowOffsetHorizontal+a;break;case"leftTop":case"rightTop":h.offset[1]=-c.arrowOffsetHorizontal*2+a;break;case"leftBottom":case"rightBottom":h.offset[1]=c.arrowOffsetHorizontal*2-a;break}h.overflow=g2e(u,c,t,r),s&&(h.htmlRegion="visibleFirst")}),l}const d4=(e,t)=>{const r=n=>typeof n=="boolean"?{show:n}:n||{};return Z.useMemo(()=>{const n=r(e),i=r(t);return{...i,...n,show:n.show??i.show??!0}},[e,t])},wq="50%",y2e=e=>{const{calc:t,componentCls:r,tooltipMaxWidth:n,tooltipColor:i,tooltipBg:o,tooltipBorderRadius:s,zIndexPopup:a,controlHeight:l,boxShadowSecondary:c,paddingSM:u,paddingXS:d,arrowOffsetHorizontal:h,sizePopupArrow:p,antCls:f}=e,[g,m]=Jn(f,"tooltip"),v=t(s).add(p).add(h).equal(),S={minWidth:t(s).mul(2).add(p).equal(),minHeight:l,padding:`${ae(e.calc(u).div(2).equal())} ${ae(d)}`,color:m("overlay-color",i),textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:o,borderRadius:s,boxShadow:c,boxSizing:"border-box"},x={[g("valid-offset-x")]:m("arrow-offset-x","var(--arrow-x)"),transformOrigin:[m("valid-offset-x",wq),`var(--arrow-y, ${wq})`].join(" ")};return[{[r]:{...on(e),position:"absolute",zIndex:a,display:"block",width:"max-content",maxWidth:n,visibility:"visible",...x,"&-hidden":{display:"none"},[g("arrow-background-color")]:o,[`${r}-container`]:[S,jD(e,!0)],[`&:has(~ ${r}-unique-container)`]:{[`${r}-container`]:{border:"none",background:"transparent",boxShadow:"none"}},[["&-placement-topLeft","&-placement-topRight","&-placement-bottomLeft","&-placement-bottomRight"].join(",")]:{minWidth:v},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${r}-inner`]:{borderRadius:e.min(s,Ace)}},[`${r}-content`]:{position:"relative"},...$D(e,(E,{darkColor:R})=>({[`&${r}-${E}`]:{[`${r}-container`]:{backgroundColor:R},[`${r}-arrow`]:{[g("arrow-background-color")]:R}}})),"&-rtl":{direction:"rtl"}}},u4(e,m("arrow-background-color")),{[`${r}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}},{[`${r}-unique-container`]:{...S,...x,position:"absolute",zIndex:t(a).sub(1).equal(),"&-hidden":{display:"none"},"&-visible":{transition:`all ${e.motionDurationSlow}`}}}]},C2e=e=>({zIndexPopup:e.zIndexPopupBase+70,maxWidth:250,...YD({contentRadius:e.borderRadius,limitVerticalRadius:!0}),...c4($r(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)}))}),Lce=(e,t,r=!0)=>Wr("Tooltip",i=>{const{borderRadius:o,colorTextLightSolid:s,colorBgSpotlight:a,maxWidth:l}=i,c=$r(i,{tooltipMaxWidth:l,tooltipColor:s,tooltipBorderRadius:o,tooltipBg:a});return[y2e(c),Nx(i,"zoom-big-fast")]},C2e,{resetStyle:!1,injectStyle:r})(e,t),b2e=Ad.map(e=>`${e}-inverse`),S2e=["success","processing","error","default","warning"];function ZD(e,t=!0){return t?[].concat(Pr(b2e),Pr(Ad)).includes(e):Ad.includes(e)}function w2e(e){return S2e.includes(e)}const _ce=(e,t,r)=>{const n=ZD(r),[i]=Jn(e,"tooltip"),o=Q({[`${t}-${r}`]:r&&n}),s={},a={},l=C_e(r).toRgb(),u=(.299*l.r+.587*l.g+.114*l.b)/255<.5?"#FFF":"#000";return r&&!n&&(s.background=r,s[i("overlay-color")]=u,a[i("arrow-background-color")]=r),{className:o,overlayStyle:s,arrowStyle:a}},x2e=e=>{const{prefixCls:t,className:r,placement:n="top",title:i,color:o,overlayInnerStyle:s,classNames:a,styles:l}=e,{getPrefixCls:c}=y.useContext(ir),u=c("tooltip",t),d=c(),h=ho(u),[p,f]=Lce(u,h),g=_ce(d,u,o),m=g.arrowStyle,v=y.useMemo(()=>({container:{...s,...g.overlayStyle}}),[s,g.overlayStyle]),b={...e,placement:n},[S,x]=Vr([a],[v,l],{props:b}),E=Q(h,p,f,u,`${u}-pure`,`${u}-placement-${n}`,r,g.className);return y.createElement("div",{className:E,style:m},y.createElement("div",{className:`${u}-arrow`}),y.createElement(l4,{...e,className:p,prefixCls:u,classNames:S,styles:x},i))},E2e=y.forwardRef((e,t)=>{const{prefixCls:r,openClassName:n,getTooltipContainer:i,color:o,children:s,afterOpenChange:a,arrow:l,destroyTooltipOnHide:c,destroyOnHidden:u,title:d,overlay:h,trigger:p,builtinPlacements:f,autoAdjustOverflow:g=!0,motion:m,getPopupContainer:v,placement:b="top",mouseEnterDelay:S=.1,mouseLeaveDelay:x=.1,rootClassName:E,styles:R,classNames:T,onOpenChange:M,overlayInnerStyle:D,overlayStyle:A,overlayClassName:I,...L}=e,[,F]=fs(),{getPopupContainer:k,getPrefixCls:O,direction:B,className:H,style:N,classNames:z,styles:W,arrow:V,trigger:$}=Nr("tooltip"),K=d4(l,V),q=K.show,X=p||$||"hover";MC();const Y=y.useRef(null),oe=()=>{var nt;(nt=Y.current)==null||nt.forceAlign()};y.useImperativeHandle(t,()=>{var nt,Et;return{forceAlign:oe,nativeElement:(nt=Y.current)==null?void 0:nt.nativeElement,popupElement:(Et=Y.current)==null?void 0:Et.popupElement}});const[ee,ne]=An(e.defaultOpen??!1,e.open),le=!d&&!h&&d!==0,he=nt=>{ne(le?!1:nt),!le&&M&&M(nt)},re=y.useMemo(()=>f||Fce({arrowPointAtCenter:(K==null?void 0:K.pointAtCenter)??!1,autoAdjustOverflow:g,arrowWidth:q?F.sizePopupArrow:0,borderRadius:F.borderRadius,offset:F.marginXXS,visibleFirst:!0}),[K,f,F,q,g]),ie=y.useMemo(()=>d===0?d:h||d||"",[h,d]),de=y.createElement(Rp,{space:!0,form:!0},typeof ie=="function"?ie():ie),J={...e,trigger:X,color:o,placement:b,builtinPlacements:f,openClassName:n,arrow:l,autoAdjustOverflow:g,getPopupContainer:v,children:s,destroyTooltipOnHide:c,destroyOnHidden:u},[ue,ve]=Vr([z,T],[W,R],{props:J}),pe=O("tooltip",r),me=O(),ke=e["data-popover-inject"];let De=ee;!("open"in e)&&le&&(De=!1);const Ee=y.isValidElement(s)&&!wle(s)?s:y.createElement("span",null,s),We=Ee.props,ze=!We.className||typeof We.className=="string"?Q(We.className,n||`${pe}-open`):We.className,mt=ho(pe),[Nt,St]=Lce(pe,mt,!ke),Ze=_ce(me,pe,o),Fe=Ze.arrowStyle,tt=Q(mt,Nt,St),Ne=Q(I,{[`${pe}-rtl`]:B==="rtl"},Ze.className,E,tt,H,ue.root),[rt,ot]=Hp("Tooltip",L.zIndex),Ye={...ve.container,...D,...Ze.overlayStyle},Ae=y.createElement(p2e,{unique:!0,...L,trigger:X,zIndex:rt,showArrow:q,placement:b,mouseEnterDelay:S,mouseLeaveDelay:x,prefixCls:pe,classNames:{root:Ne,container:ue.container,arrow:ue.arrow,uniqueContainer:Q(tt,ue.container)},styles:{root:{...Fe,...ve.root,...N,...A},container:Ye,uniqueContainer:Ye,arrow:ve.arrow},getTooltipContainer:v||i||k,ref:Y,builtinPlacements:re,overlay:de,visible:De,onVisibleChange:he,afterVisibleChange:a,arrowContent:y.createElement("span",{className:`${pe}-arrow-content`}),motion:{motionName:mu(me,"zoom-big-fast",typeof(m==null?void 0:m.motionName)=="string"?m==null?void 0:m.motionName:void 0),motionDeadline:1e3},destroyOnHidden:u??!!c},De?Ei(Ee,{className:ze}):Ee);return y.createElement(Lx.Provider,{value:ot},Ae)}),El=E2e;El._InternalPanelDoNotUseOrYouWillBeFired=x2e;El.UniqueProvider=Ele;const xq="50%",T2e=e=>{const{componentCls:t,popoverColor:r,titleMinWidth:n,fontWeightStrong:i,innerPadding:o,boxShadowSecondary:s,colorTextHeading:a,borderRadiusLG:l,zIndexPopup:c,titleMarginBottom:u,colorBgElevated:d,popoverBg:h,titleBorderBottom:p,innerContentPadding:f,titlePadding:g,antCls:m}=e,[v,b]=Jn(m,"tooltip");return[{[t]:{...on(e),position:"absolute",top:0,left:{_skip_check_:!0,value:0},zIndex:c,fontWeight:"normal",whiteSpace:"normal",textAlign:"start",cursor:"auto",userSelect:"text",[v("valid-offset-x")]:b("arrow-offset-x","var(--arrow-x)"),transformOrigin:[b("valid-offset-x",xq),`var(--arrow-y, ${xq})`].join(" "),[v("arrow-background-color")]:d,width:"max-content",maxWidth:"100vw","&-rtl":{direction:"rtl"},"&-hidden":{display:"none"},[`${t}-content`]:{position:"relative"},[`${t}-container`]:{backgroundColor:h,backgroundClip:"padding-box",borderRadius:l,boxShadow:s,padding:o},[`${t}-title`]:{minWidth:n,marginBottom:u,color:a,fontWeight:i,borderBottom:p,padding:g},[`${t}-content`]:{color:r,padding:f}}},u4(e,b("arrow-background-color")),{[`${t}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow,display:"inline-block"}}]},R2e=e=>{const{componentCls:t,antCls:r}=e,[n]=Jn(r,"tooltip");return{[t]:Ad.map(i=>{const o=e[`${i}6`];return{[`&${t}-${i}`]:{[n("arrow-background-color")]:o,[`${t}-inner`]:{backgroundColor:o},[`${t}-arrow`]:{background:"transparent"}}}})}},P2e=e=>{const{lineWidth:t,controlHeight:r,fontHeight:n,padding:i,wireframe:o,zIndexPopupBase:s,borderRadiusLG:a,marginXS:l,lineType:c,colorSplit:u,paddingSM:d}=e,h=r-n,p=h/2,f=h/2-t,g=i;return{titleMinWidth:177,zIndexPopup:s+30,...c4(e),...YD({contentRadius:a,limitVerticalRadius:!0}),innerPadding:o?0:12,titleMarginBottom:o?0:l,titlePadding:o?`${p}px ${g}px ${f}px`:0,titleBorderBottom:o?`${t}px ${c} ${u}`:"none",innerContentPadding:o?`${d}px ${g}px`:0}},Oce=Wr("Popover",e=>{const{colorBgElevated:t,colorText:r}=e,n=$r(e,{popoverBg:t,popoverColor:r});return[T2e(n),R2e(n),Nx(n,"zoom-big")]},P2e,{resetStyle:!1,deprecatedTokens:[["width","titleMinWidth"],["minWidth","titleMinWidth"]]}),kce=e=>{const{title:t,content:r,prefixCls:n,classNames:i,styles:o}=e;return!t&&!r?null:y.createElement(y.Fragment,null,t&&y.createElement("div",{className:Q(`${n}-title`,i==null?void 0:i.title),style:o==null?void 0:o.title},t),r&&y.createElement("div",{className:Q(`${n}-content`,i==null?void 0:i.content),style:o==null?void 0:o.content},r))},M2e=e=>{const{hashId:t,prefixCls:r,className:n,style:i,placement:o="top",title:s,content:a,children:l,classNames:c,styles:u}=e,d=Uy(s),h=Uy(a),p={...e,placement:o},[f,g]=Vr([c],[u],{props:p}),m=Q(t,r,`${r}-pure`,`${r}-placement-${o}`,n);return y.createElement("div",{className:m,style:i},y.createElement("div",{className:`${r}-arrow`}),y.createElement(l4,{...e,className:t,prefixCls:r,classNames:f,styles:g},l||y.createElement(kce,{prefixCls:r,title:d,content:h,classNames:f,styles:g})))},Nce=e=>{const{prefixCls:t,className:r,...n}=e,{getPrefixCls:i}=y.useContext(ir),o=i("popover",t),[s,a]=Oce(o);return y.createElement(M2e,{...n,prefixCls:o,hashId:s,className:Q(r,a)})},I2e=y.forwardRef((e,t)=>{const{prefixCls:r,title:n,content:i,overlayClassName:o,placement:s="top",trigger:a,children:l,mouseEnterDelay:c=.1,mouseLeaveDelay:u=.1,onOpenChange:d,overlayStyle:h={},styles:p,classNames:f,motion:g,arrow:m,...v}=e,{getPrefixCls:b,className:S,style:x,classNames:E,styles:R,arrow:T,trigger:M}=Nr("popover"),D=b("popover",r),[A,I]=Oce(D),L=b(),F=d4(m,T),k=a||M||"hover",O={...e,placement:s,trigger:k,mouseEnterDelay:c,mouseLeaveDelay:u,overlayStyle:h,styles:p,classNames:f},[B,H]=Vr([E,f],[R,p],{props:O}),N=Q(o,A,I,S,B.root),[z,W]=An(e.defaultOpen??!1,e.open),V=q=>{W(q),d==null||d(q)},$=Uy(n),K=Uy(i);return y.createElement(El,{unique:!1,arrow:F,placement:s,trigger:k,mouseEnterDelay:c,mouseLeaveDelay:u,...v,prefixCls:D,classNames:{root:N,container:B.container,arrow:B.arrow},styles:{root:{...H.root,...x,...h},container:H.container,arrow:H.arrow},ref:t,open:z,onOpenChange:V,overlay:$||K?y.createElement(kce,{prefixCls:D,title:$,content:K,classNames:B,styles:H}):null,motion:{motionName:mu(L,"zoom-big",typeof(g==null?void 0:g.motionName)=="string"?g==null?void 0:g.motionName:void 0)},"data-popover-inject":!0},l)}),Bce=I2e;Bce._InternalPanelDoNotUseOrYouWillBeFired=Nce;var D2e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M859.9 168H164.1c-4.5 0-8.1 3.6-8.1 8v60c0 4.4 3.6 8 8.1 8h695.8c4.5 0 8.1-3.6 8.1-8v-60c0-4.4-3.6-8-8.1-8zM518.3 355a8 8 0 00-12.6 0l-112 141.7a7.98 7.98 0 006.3 12.9h73.9V848c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V509.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 355z"}}]},name:"vertical-align-top",theme:"outlined"};function D$(){return D$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,D$({},e,{ref:t,icon:D2e})),F2e=y.forwardRef(A2e),Eq=e=>{const{prefixCls:t,value:r,current:n,offset:i=0}=e;let o;return i&&(o={position:"absolute",top:`${i}00%`,left:0}),y.createElement("span",{style:o,className:Q(`${t}-only-unit`,{current:n})},r)};function L2e(e,t,r){let n=e,i=0;for(;(n+10)%10!==t;)n+=r,i+=r;return i}const _2e=e=>{const{prefixCls:t,count:r,value:n}=e,i=Number(n),o=Math.abs(r),[s,a]=y.useState(i),[l,c]=y.useState(o),u=()=>{a(i),c(o)};y.useEffect(()=>{const p=setTimeout(u,1e3);return()=>clearTimeout(p)},[i]);let d,h;if(s===i||Number.isNaN(i)||Number.isNaN(s))d=[y.createElement(Eq,{...e,key:i,current:!0})],h={transition:"none"};else{d=[];const p=i+10,f=[];for(let b=i;b<=p;b+=1)f.push(b);const g=lb%10===s);d=(g<0?f.slice(0,m+1):f.slice(m)).map((b,S)=>{const x=b%10;return y.createElement(Eq,{...e,key:b,value:x,offset:g<0?S-m:S,current:S===m})}),h={transform:`translateY(${-L2e(s,i,g)}00%)`}}return y.createElement("span",{className:`${t}-only`,style:h,onTransitionEnd:u},d)},O2e=y.forwardRef((e,t)=>{const{prefixCls:r,count:n,className:i,motionClassName:o,style:s,title:a,show:l,component:c="sup",children:u,...d}=e,{getPrefixCls:h}=y.useContext(ir),p=h("scroll-number",r),f={...d,"data-show":l,style:s,className:Q(p,i,o),title:a};let g=n;if(n&&Number(n)%1===0){const m=String(n).split("");g=y.createElement("bdi",null,m.map((v,b)=>y.createElement(_2e,{prefixCls:p,count:Number(n),value:v,key:m.length-b})))}return s!=null&&s.borderColor&&(f.style={...s,boxShadow:`0 0 0 1px ${s.borderColor} inset`}),u?Ei(u,m=>({className:Q(`${p}-custom-component`,m==null?void 0:m.className,o)})):y.createElement(c,{...f,ref:t},g)}),k2e=new qr("antStatusProcessing",{"0%":{transform:"scale(0.8)",opacity:.5},"100%":{transform:"scale(2.4)",opacity:0}}),N2e=new qr("antZoomBadgeIn",{"0%":{transform:"scale(0) translate(50%, -50%)",opacity:0},"100%":{transform:"scale(1) translate(50%, -50%)"}}),B2e=new qr("antZoomBadgeOut",{"0%":{transform:"scale(1) translate(50%, -50%)"},"100%":{transform:"scale(0) translate(50%, -50%)",opacity:0}}),$2e=new qr("antNoWrapperZoomBadgeIn",{"0%":{transform:"scale(0)",opacity:0},"100%":{transform:"scale(1)"}}),G2e=new qr("antNoWrapperZoomBadgeOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0)",opacity:0}}),V2e=new qr("antBadgeLoadingCircle",{"0%":{transformOrigin:"50%"},"100%":{transform:"translate(50%, -50%) rotate(360deg)",transformOrigin:"50%"}}),z2e=e=>{const{componentCls:t,iconCls:r,antCls:n,badgeShadowSize:i,textFontSize:o,textFontSizeSM:s,statusSize:a,dotSize:l,textFontWeight:c,indicatorHeight:u,indicatorHeightSM:d,marginXS:h,calc:p}=e,f=`${n}-scroll-number`,g=$D(e,(m,{darkColor:v})=>({[`&${t} ${t}-color-${m}`]:{background:v,[`&:not(${t}-count)`]:{color:v},"a:hover &":{background:v}}}));return{[t]:{...on(e),position:"relative",display:"inline-block",width:"fit-content",lineHeight:1,[`${t}-count`]:{display:"inline-flex",justifyContent:"center",zIndex:e.indicatorZIndex,minWidth:u,height:u,color:e.badgeTextColor,fontWeight:c,fontSize:o,lineHeight:ae(u),whiteSpace:"nowrap",textAlign:"center",background:e.badgeColor,borderRadius:p(u).div(2).equal(),boxShadow:`0 0 0 ${ae(i)} ${e.badgeShadowColor}`,transition:`background-color ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:d,height:d,fontSize:s,lineHeight:ae(d),borderRadius:p(d).div(2).equal()},[`${t}-multiple-words`]:{padding:`0 ${ae(e.paddingXS)}`,bdi:{unicodeBidi:"plaintext"}},[`${t}-dot`]:{zIndex:e.indicatorZIndex,width:l,minWidth:l,height:l,background:e.badgeColor,borderRadius:"100%",boxShadow:`0 0 0 ${ae(i)} ${e.badgeShadowColor}`},[`${t}-count, ${t}-dot, ${f}-custom-component`]:{position:"absolute",top:0,insetInlineEnd:0,transform:"translate(50%, -50%)",transformOrigin:"100% 0%",[`&${r}-spin`]:{animationName:V2e,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear"}},[`&${t}-status`]:{lineHeight:"inherit",verticalAlign:"baseline",[`${t}-status-dot`]:{position:"relative",top:-1,display:"inline-block",width:a,height:a,verticalAlign:"middle",borderRadius:"50%"},[`${t}-status-success`]:{backgroundColor:e.colorSuccess},[`${t}-status-processing`]:{overflow:"visible",color:e.colorInfo,backgroundColor:e.colorInfo,borderColor:"currentcolor","&::after":{position:"absolute",top:0,insetInlineStart:0,width:"100%",height:"100%",borderWidth:i,borderStyle:"solid",borderColor:"inherit",borderRadius:"50%",animationName:k2e,animationDuration:e.badgeProcessingDuration,animationIterationCount:"infinite",animationTimingFunction:"ease-in-out",content:'""'}},[`${t}-status-default`]:{backgroundColor:e.colorTextPlaceholder},[`${t}-status-error`]:{backgroundColor:e.colorError},[`${t}-status-warning`]:{backgroundColor:e.colorWarning},[`${t}-status-text`]:{marginInlineStart:h,color:e.colorText,fontSize:e.fontSize}},...g,[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:N2e,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`${t}-zoom-leave`]:{animationName:B2e,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:$2e,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:G2e,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:"middle"},[`${f}-custom-component, ${t}-count`]:{transform:"none"},[`${f}-custom-component, ${f}`]:{position:"relative",top:"auto",display:"block",transformOrigin:"50% 50%"}},[f]:{overflow:"hidden",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack}`,[`${f}-only`]:{position:"relative",display:"inline-block",height:u,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden",[`> p${f}-only-unit`]:{height:u,margin:0,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden"}},[`${f}-symbol`]:{verticalAlign:"top"}},"&-rtl":{direction:"rtl",[`${t}-count, ${t}-dot, ${f}-custom-component`]:{transform:"translate(-50%, -50%)"}}}}},$ce=e=>{const{fontHeight:t,lineWidth:r,marginXS:n,colorBorderBg:i}=e,o=t,s=r,a=e.colorTextLightSolid,l=e.colorError,c=e.colorErrorHover;return $r(e,{badgeFontHeight:o,badgeShadowSize:s,badgeTextColor:a,badgeColor:l,badgeColorHover:c,badgeShadowColor:i,badgeProcessingDuration:"1.2s",badgeRibbonOffset:n,badgeRibbonCornerTransform:"scaleY(0.75)",badgeRibbonCornerFilter:"brightness(75%)"})},Gce=e=>{const{fontSize:t,lineHeight:r,fontSizeSM:n,lineWidth:i}=e;return{indicatorZIndex:"auto",indicatorHeight:Math.round(t*r)-2*i,indicatorHeightSM:t,dotSize:n/2,textFontSize:n,textFontSizeSM:n,textFontWeight:"normal",statusSize:n/2}},H2e=Wr("Badge",e=>{const t=$ce(e);return z2e(t)},Gce),W2e=y.forwardRef((e,t)=>{const{prefixCls:r,scrollNumberPrefixCls:n,children:i,status:o,text:s,color:a,count:l=null,overflowCount:c=99,dot:u=!1,size:d="medium",title:h,offset:p,style:f,className:g,rootClassName:m,classNames:v,styles:b,showZero:S=!1,...x}=e,{getPrefixCls:E,direction:R,className:T,style:M,classNames:D,styles:A}=Nr("badge"),I=E("badge",r),[L,F]=H2e(I),k={...e,overflowCount:c,size:d,dot:u,showZero:S},[O,B]=Vr([D,v],[A,b],{props:k}),H=l>c?`${c}+`:l,N=H==="0"||H===0||s==="0"||s===0,z=l===null||N&&!S,W=(Tn(o)||Tn(a))&&z,V=Tn(o)||!N,$=u&&!N,K=$?"":H,q=y.useMemo(()=>((!Tn(K)||K==="")&&(!Tn(s)||s==="")||N&&!S)&&!$,[K,N,S,$,s]),X=y.useRef(l);q||(X.current=l);const Y=X.current,oe=y.useRef(K);q||(oe.current=K);const ee=oe.current,ne=y.useRef($);q||(ne.current=$);const le=y.useMemo(()=>{if(!p)return{...M,...f};const me=Number.parseInt(p[0],10);return{...{marginTop:p[1],insetInlineEnd:-me},...M,...f}},[p,f,M]),he=h??(typeof Y=="string"||typeof Y=="number"?Y:void 0),re=!q&&(s===0?S:!!s&&s!==!0),ie=re?y.createElement("span",{className:`${I}-status-text`},s):null,de=!Y||typeof Y!="object"?void 0:Ei(Y,me=>({style:{...le,...me.style}})),J=ZD(a,!1),ue=Q(O.indicator,{[`${I}-status-dot`]:W,[`${I}-status-${o}`]:!!o,[`${I}-color-${a}`]:J}),ve={};a&&!J&&(ve.color=a,ve.background=a);const pe=Q(I,{[`${I}-status`]:W,[`${I}-not-a-wrapper`]:!i,[`${I}-rtl`]:R==="rtl"},g,m,T,O.root,L,F);if(!i&&W&&(s||V||!z)){const me=le.color;return y.createElement("span",{ref:t,...x,className:pe,style:{...B.root,...le}},y.createElement("span",{className:ue,style:{...B.indicator,...ve}}),re&&y.createElement("span",{style:{color:me},className:`${I}-status-text`},s))}return y.createElement("span",{ref:t,...x,className:pe,style:B.root},i,y.createElement(Mu,{visible:!q,motionName:`${I}-zoom`,motionAppear:!1,motionDeadline:1e3},({className:me})=>{const ke=E("scroll-number",n),De=ne.current,Ee=Q(O.indicator,{[`${I}-dot`]:De,[`${I}-count`]:!De,[`${I}-count-sm`]:d==="small",[`${I}-multiple-words`]:!De&&ee&&ee.toString().length>1,[`${I}-status-${o}`]:!!o,[`${I}-color-${a}`]:J});let We={...B.indicator,...le};return a&&!J&&(We=We||{},We.background=a),y.createElement(O2e,{prefixCls:ke,show:!q,motionClassName:me,className:Ee,count:ee,title:he,style:We,key:"scrollNumber"},de)}),ie)}),U2e=e=>{const{antCls:t,badgeFontHeight:r,marginXS:n,badgeRibbonOffset:i,calc:o}=e,s=`${t}-ribbon`,a=`${t}-ribbon-wrapper`,l=$D(e,(c,{darkColor:u})=>({[`&${s}-color-${c}`]:{background:u,color:u}}));return{[a]:{position:"relative"},[s]:{...on(e),position:"absolute",top:n,padding:`0 ${ae(e.paddingXS)}`,color:e.colorPrimary,lineHeight:ae(r),whiteSpace:"nowrap",backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${s}-content`]:{color:e.badgeTextColor},[`${s}-corner`]:{position:"absolute",top:"100%",width:i,height:i,color:"currentcolor",border:`${ae(o(i).div(2).equal())} solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:"top",filter:e.badgeRibbonCornerFilter},...l,[`&${s}-placement-end`]:{insetInlineEnd:o(i).mul(-1).equal(),borderEndEndRadius:0,[`${s}-corner`]:{insetInlineEnd:0,borderInlineEndColor:"transparent",borderBlockEndColor:"transparent"}},[`&${s}-placement-start`]:{insetInlineStart:o(i).mul(-1).equal(),borderEndStartRadius:0,[`${s}-corner`]:{insetInlineStart:0,borderBlockEndColor:"transparent",borderInlineStartColor:"transparent"}},"&-rtl":{direction:"rtl"}}}},j2e=Wr(["Badge","Ribbon"],e=>{const t=$ce(e);return U2e(t)},Gce),K2e=e=>{const{className:t,prefixCls:r,style:n,color:i,children:o,text:s,placement:a="end",rootClassName:l,styles:c,classNames:u}=e,{getPrefixCls:d,direction:h,className:p,style:f,classNames:g,styles:m}=Nr("ribbon"),v=d("ribbon",r),b=`${v}-wrapper`,[S,x]=j2e(v,b),E={...e,placement:a},[R,T]=Vr([g,u],[m,c],{props:E}),M=ZD(i,!1),D=Q(v,`${v}-placement-${a}`,{[`${v}-rtl`]:h==="rtl",[`${v}-color-${i}`]:M},t,p,R.indicator),A={},I={};return i&&!M&&(A.background=i,I.color=i),y.createElement("div",{className:Q(b,l,S,x,R.root),style:T.root},o,y.createElement("div",{className:Q(D,S),style:{...A,...T.indicator,...f,...n}},y.createElement("span",{className:Q(`${v}-content`,R.content),style:T.content},s),y.createElement("div",{className:`${v}-corner`,style:I})))},Vce=W2e;Vce.Ribbon=K2e;const h4=Z.createContext({});var q2e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"};function A$(){return A$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,A$({},e,{ref:t,icon:q2e})),F$=y.forwardRef(X2e),{ESC:Y2e,TAB:Z2e}=Zt;function Q2e({visible:e,triggerRef:t,onVisibleChange:r,autoFocus:n,overlayRef:i}){const o=y.useRef(!1),s=()=>{var c,u;e&&((u=(c=t.current)==null?void 0:c.focus)==null||u.call(c),r==null||r(!1))},a=()=>{var c;return(c=i.current)!=null&&c.focus?(i.current.focus(),o.current=!0,!0):!1},l=c=>{switch(c.keyCode){case Y2e:s();break;case Z2e:{let u=!1;o.current||(u=a()),u?c.preventDefault():s();break}}};y.useEffect(()=>e?(window.addEventListener("keydown",l),n&&Or(a,3),()=>{window.removeEventListener("keydown",l),o.current=!1}):()=>{o.current=!1},[e])}const J2e=y.forwardRef((e,t)=>{const{overlay:r,arrow:n,prefixCls:i}=e,o=y.useMemo(()=>{let a;return typeof r=="function"?a=r():a=r,a},[r]),s=Wo(t,jd(o));return Z.createElement(Z.Fragment,null,n&&Z.createElement("div",{className:`${i}-arrow`}),Z.cloneElement(o,{ref:pu(o)?s:void 0}))}),bv={adjustX:1,adjustY:1},Sv=[0,0],eBe={topLeft:{points:["bl","tl"],overflow:bv,offset:[0,-4],targetOffset:Sv},top:{points:["bc","tc"],overflow:bv,offset:[0,-4],targetOffset:Sv},topRight:{points:["br","tr"],overflow:bv,offset:[0,-4],targetOffset:Sv},bottomLeft:{points:["tl","bl"],overflow:bv,offset:[0,4],targetOffset:Sv},bottom:{points:["tc","bc"],overflow:bv,offset:[0,4],targetOffset:Sv},bottomRight:{points:["tr","br"],overflow:bv,offset:[0,4],targetOffset:Sv}};function L$(){return L$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var W;const{arrow:r=!1,prefixCls:n="rc-dropdown",transitionName:i,animation:o,align:s,placement:a="bottomLeft",placements:l=eBe,getPopupContainer:c,showAction:u,hideAction:d,overlayClassName:h,overlayStyle:p,visible:f,trigger:g=["hover"],autoFocus:m,overlay:v,children:b,onVisibleChange:S,...x}=e,[E,R]=Z.useState(),T="visible"in e?f:E,M=o?`${n}-${o}`:i,D=Z.useRef(null),A=Z.useRef(null),I=Z.useRef(null);Z.useImperativeHandle(t,()=>D.current);const L=V=>{R(V),S==null||S(V)};Q2e({visible:T,triggerRef:I,onVisibleChange:L,autoFocus:m,overlayRef:A});const F=V=>{const{onOverlayClick:$}=e;R(!1),$&&$(V)},k=()=>Z.createElement(J2e,{ref:A,overlay:v,prefixCls:n,arrow:r}),O=()=>typeof v=="function"?k:k(),B=()=>{const{minOverlayWidthMatchTrigger:V,alignPoint:$}=e;return"minOverlayWidthMatchTrigger"in e?V:!$},H=()=>{const{openClassName:V}=e;return V!==void 0?V:`${n}-open`},N=Z.cloneElement(b,{className:Q((W=b.props)==null?void 0:W.className,T&&H()),ref:pu(b)?Wo(I,jd(b)):void 0});let z=d;return!z&&g.indexOf("contextMenu")!==-1&&(z=["click"]),Z.createElement(zD,L$({builtinPlacements:l},x,{prefixCls:n,ref:D,popupClassName:Q(h,{[`${n}-show-arrow`]:r}),popupStyle:p,action:g,showAction:u,hideAction:z,popupPlacement:a,popupAlign:s,popupMotion:{motionName:M},popupVisible:T,stretch:B()?"minWidth":"",popup:O(),onOpenChange:L,onPopupClick:F,getPopupContainer:c}),N)}),tBe=e=>typeof e!="object"&&typeof e!="function"||e===null,Hce=y.createContext(null);function Wce(e,t){return`${e}-${t}`}function Uce(e){const t=y.useContext(Hce);return Wce(t,e)}const mc=y.createContext(null);function rBe(e,t){const r={...e};return Object.keys(t).forEach(n=>{const i=t[n];i!==void 0&&(r[n]=i)}),r}function I0({children:e,locked:t,...r}){const n=y.useContext(mc),i=Pm(()=>rBe(n,r),[n,r],(o,s)=>!t&&(o[0]!==s[0]||!fc(o[1],s[1],!0)));return y.createElement(mc.Provider,{value:i},e)}const nBe=[],jce=y.createContext(null);function QD(){return y.useContext(jce)}const Kce=y.createContext(nBe);function AC(e){const t=y.useContext(Kce);return y.useMemo(()=>e!==void 0?[...t,e]:t,[t,e])}const qce=y.createContext(null),p4=y.createContext({}),{LEFT:_$,RIGHT:O$,UP:k$,DOWN:hP,ENTER:pP,ESC:Xce,HOME:oS,END:sS}=Zt,Tq=[k$,hP,_$,O$];function iBe(e,t,r,n){var p;const i="prev",o="next",s="children",a="parent";if(e==="inline"&&n===pP)return{inlineTrigger:!0};const l={[k$]:i,[hP]:o},c={[_$]:r?o:i,[O$]:r?i:o,[hP]:s,[pP]:s},u={[k$]:i,[hP]:o,[pP]:s,[Xce]:a,[_$]:r?s:a,[O$]:r?a:s};switch((p={inline:l,horizontal:c,vertical:u,inlineSub:l,horizontalSub:u,verticalSub:u}[`${e}${t?"":"Sub"}`])==null?void 0:p[n]){case i:return{offset:-1,sibling:!0};case o:return{offset:1,sibling:!0};case a:return{offset:-1,sibling:!1};case s:return{offset:1,sibling:!1};default:return null}}function oBe(e){let t=e;for(;t;){if(t.getAttribute("data-menu-list"))return t;t=t.parentElement}return null}function sBe(e,t){let r=e||document.activeElement;for(;r;){if(t.has(r))return r;r=r.parentElement}return null}function f4(e,t){return q3(e,!0).filter(n=>t.has(n))}function Rq(e,t,r,n=1){if(!e)return null;const i=f4(e,t),o=i.length;let s=i.findIndex(a=>r===a);return n<0?s===-1?s=o-1:s-=1:n>0&&(s+=1),s=(s+o)%o,i[s]}const vM=(e,t)=>{const r=new Set,n=new Map,i=new Map;return e.forEach(o=>{const s=document.querySelector(`[data-menu-id='${Wce(t,o)}']`);s&&(r.add(s),i.set(s,o),n.set(o,s))}),{elements:r,key2element:n,element2key:i}};function aBe(e,t,r,n,i,o,s,a,l,c){const u=y.useRef(),d=y.useRef();d.current=t;const h=()=>{Or.cancel(u.current)};return y.useEffect(()=>()=>{h()},[]),p=>{const{which:f}=p;if([...Tq,pP,Xce,oS,sS].includes(f)){const g=o();let m=vM(g,n);const{elements:v,key2element:b,element2key:S}=m,x=b.get(t),E=sBe(x,v),R=S.get(E),T=iBe(e,s(R,!0).length===1,r,f);if(!T&&f!==oS&&f!==sS)return;(Tq.includes(f)||[oS,sS].includes(f))&&p.preventDefault();const M=D=>{if(D){let A=D;const I=D.querySelector("a");I!=null&&I.getAttribute("href")&&(A=I);const L=S.get(D);a(L),h(),u.current=Or(()=>{d.current===L&&A.focus()})}};if([oS,sS].includes(f)||T.sibling||!E){let D;!E||e==="inline"?D=i.current:D=oBe(E);let A;const I=f4(D,v);f===oS?A=I[0]:f===sS?A=I[I.length-1]:A=Rq(D,v,E,T.offset),M(A)}else if(T.inlineTrigger)l(R);else if(T.offset>0)l(R,!0),h(),u.current=Or(()=>{m=vM(g,n);const D=E.getAttribute("aria-controls"),A=document.getElementById(D),I=Rq(A,m.elements);M(I)},5);else if(T.offset<0){const D=s(R,!0),A=D[D.length-2],I=b.get(A);l(A,!1),M(I)}}c==null||c(p)}}function lBe(e){Promise.resolve().then(e)}const g4="__RC_UTIL_PATH_SPLIT__",Pq=e=>e.join(g4),cBe=e=>e.split(g4),N$="rc-menu-more";function uBe(){const[,e]=y.useState({}),t=y.useRef(new Map),r=y.useRef(new Map),[n,i]=y.useState([]),o=y.useRef(0),s=y.useRef(!1),a=()=>{s.current||e({})},l=y.useCallback((g,m)=>{const v=Pq(m);r.current.set(v,g),t.current.set(g,v),o.current+=1;const b=o.current;lBe(()=>{b===o.current&&a()})},[]),c=y.useCallback((g,m)=>{const v=Pq(m);r.current.delete(v),t.current.delete(g)},[]),u=y.useCallback(g=>{i(g)},[]),d=y.useCallback((g,m)=>{const v=t.current.get(g)||"",b=cBe(v);return m&&n.includes(b[0])&&b.unshift(N$),b},[n]),h=y.useCallback((g,m)=>g.filter(v=>v!==void 0).some(v=>d(v,!0).includes(m)),[d]),p=()=>{const g=[...t.current.keys()];return n.length&&g.push(N$),g},f=y.useCallback(g=>{const m=`${t.current.get(g)}${g4}`,v=new Set;return[...r.current.keys()].forEach(b=>{b.startsWith(m)&&v.add(r.current.get(b))}),v},[]);return y.useEffect(()=>()=>{s.current=!0},[]),{registerPath:l,unregisterPath:c,refreshOverflowKeys:u,isSubPathKey:h,getKeyPath:d,getKeys:p,getSubPathKeys:f}}function iw(e){const t=y.useRef(e);t.current=e;const r=y.useCallback((...n)=>{var i;return(i=t.current)==null?void 0:i.call(t,...n)},[]);return e?r:void 0}function Yce(e,t,r,n){const{activeKey:i,onActive:o,onInactive:s}=y.useContext(mc),a={active:i===e};return t||(a.onMouseEnter=l=>{r==null||r({key:e,domEvent:l}),o(e)},a.onMouseLeave=l=>{n==null||n({key:e,domEvent:l}),s(e)}),a}function Zce(e){const{mode:t,rtl:r,inlineIndent:n}=y.useContext(mc);if(t!=="inline")return null;const i=e;return r?{paddingRight:i*n}:{paddingLeft:i*n}}function Qce({icon:e,props:t,children:r}){let n;return e===null||e===!1?null:(typeof e=="function"?n=y.createElement(e,{...t}):typeof e!="boolean"&&(n=e),n||r||null)}function yM({item:e,...t}){return Object.defineProperty(t,"item",{get:()=>(Vn(!1,"`info.item` is deprecated since we will move to function component that not provides React Node instance in future."),e)}),t}function D0(){return D0=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{style:r,className:n,eventKey:i,warnKey:o,disabled:s,itemIcon:a,children:l,role:c,onMouseEnter:u,onMouseLeave:d,onClick:h,onKeyDown:p,onFocus:f,...g}=e,m=Uce(i),{prefixCls:v,onItemClick:b,disabled:S,overflowDisabled:x,itemIcon:E,selectedKeys:R,onActive:T}=y.useContext(mc),{_internalRenderMenuItem:M}=y.useContext(p4),D=`${v}-item`,A=y.useRef(),I=y.useRef(),L=S||s,F=Pu(t,I),k=AC(i),O=Y=>({key:i,keyPath:[...k].reverse(),item:A.current,domEvent:Y}),B=a||E,{active:H,...N}=Yce(i,L,u,d),z=R.includes(i),W=Zce(k.length),V=Y=>{if(L)return;const oe=O(Y);h==null||h(yM(oe)),b(oe)},$=Y=>{if(p==null||p(Y),Y.which===Zt.ENTER){const oe=O(Y);h==null||h(yM(oe)),b(oe)}},K=Y=>{T(i),f==null||f(Y)},q={};e.role==="option"&&(q["aria-selected"]=z);let X=y.createElement(dBe,D0({ref:A,elementRef:F,role:c===null?"none":c||"menuitem",tabIndex:s?null:-1,"data-menu-id":x&&m?null:m},fn(g,["extra"]),N,q,{component:"li","aria-disabled":s,style:{...W,...r},className:Q(D,{[`${D}-active`]:H,[`${D}-selected`]:z,[`${D}-disabled`]:L},n),onClick:V,onKeyDown:$,onFocus:K}),l,y.createElement(Qce,{props:{...e,isSelected:z},icon:B}));return M&&(X=M(X,e,{selected:z})),X});function pBe(e,t){const{eventKey:r}=e,n=QD(),i=AC(r);return y.useEffect(()=>{if(n)return n.registerPath(r,i),()=>{n.unregisterPath(r,i)}},[i]),n?null:y.createElement(hBe,D0({},e,{ref:t}))}const qx=y.forwardRef(pBe);function B$(){return B$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:i,mode:o,rtl:s}=y.useContext(mc);return y.createElement("ul",B$({className:Q(i,s&&`${i}-rtl`,`${i}-sub`,`${i}-${o==="inline"?"inline":"vertical"}`,e),role:"menu"},r,{"data-menu-list":!0,ref:n}),t)},Jce=y.forwardRef(fBe);function m4(e,t){return Li(e).map((r,n)=>{var i;if(y.isValidElement(r)){const{key:o}=r;let s=((i=r.props)==null?void 0:i.eventKey)??o;s==null&&(s=`tmp_key-${[...t,n].join("-")}`);const l={key:s,eventKey:s};return y.cloneElement(r,l)}return r})}const rs={adjustX:1,adjustY:1},gBe={topLeft:{points:["bl","tl"],overflow:rs},topRight:{points:["br","tr"],overflow:rs},bottomLeft:{points:["tl","bl"],overflow:rs},bottomRight:{points:["tr","br"],overflow:rs},leftTop:{points:["tr","tl"],overflow:rs},leftBottom:{points:["br","bl"],overflow:rs},rightTop:{points:["tl","tr"],overflow:rs},rightBottom:{points:["bl","br"],overflow:rs}},mBe={topLeft:{points:["bl","tl"],overflow:rs},topRight:{points:["br","tr"],overflow:rs},bottomLeft:{points:["tl","bl"],overflow:rs},bottomRight:{points:["tr","br"],overflow:rs},rightTop:{points:["tr","tl"],overflow:rs},rightBottom:{points:["br","bl"],overflow:rs},leftTop:{points:["tl","tr"],overflow:rs},leftBottom:{points:["bl","br"],overflow:rs}};function eue(e,t,r){if(t)return t;if(r)return r[e]||r.other}const vBe={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"};function yBe({prefixCls:e,visible:t,children:r,popup:n,popupStyle:i,popupClassName:o,popupOffset:s,disabled:a,mode:l,onVisibleChange:c}){const{getPopupContainer:u,rtl:d,subMenuOpenDelay:h,subMenuCloseDelay:p,builtinPlacements:f,triggerSubMenuAction:g,forceSubMenuRender:m,rootClassName:v,motion:b,defaultMotions:S}=y.useContext(mc),[x,E]=y.useState(!1),R=d?{...mBe,...f}:{...gBe,...f},T=vBe[l],M=eue(l,b,S),D=y.useRef(M);l!=="inline"&&(D.current=M);const A={...D.current,leavedClassName:`${e}-hidden`,removeOnLeave:!1,motionAppear:!0},I=y.useRef();return y.useEffect(()=>(I.current=Or(()=>{E(t)}),()=>{Or.cancel(I.current)}),[t]),y.createElement(zD,{prefixCls:e,popupClassName:Q(`${e}-popup`,{[`${e}-rtl`]:d},o,v),stretch:l==="horizontal"?"minWidth":null,getPopupContainer:u,builtinPlacements:R,popupPlacement:T,popupVisible:x,popup:n,popupStyle:i,popupAlign:s&&{offset:s},action:a?[]:[g],mouseEnterDelay:h,mouseLeaveDelay:p,onPopupVisibleChange:c,forceRender:m,popupMotion:A,fresh:!0},r)}function $$(){return $$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{u.current&&h(!1)},[c]);const f={...eue(i,a,l)};r.length>1&&(f.motionAppear=!1);const g=f.onVisibleChanged;return f.onVisibleChanged=m=>(!u.current&&!m&&h(!0),g==null?void 0:g(m)),d?null:y.createElement(I0,{mode:i,locked:!u.current},y.createElement(gu,$$({visible:p},f,{forceRender:s,removeOnLeave:!1,leavedClassName:`${o}-hidden`}),({className:m,style:v})=>y.createElement(Jce,{id:e,className:m,style:v},n)))}function A0(){return A0=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{style:r,className:n,styles:i,classNames:o,title:s,eventKey:a,warnKey:l,disabled:c,internalPopupClose:u,children:d,itemIcon:h,expandIcon:p,popupClassName:f,popupOffset:g,popupStyle:m,onClick:v,onMouseEnter:b,onMouseLeave:S,onTitleClick:x,onTitleMouseEnter:E,onTitleMouseLeave:R,popupRender:T,...M}=e,D=Uce(a),{prefixCls:A,mode:I,openKeys:L,disabled:F,overflowDisabled:k,activeKey:O,selectedKeys:B,itemIcon:H,expandIcon:N,onItemClick:z,onOpenChange:W,onActive:V,popupRender:$}=y.useContext(mc),{_internalRenderSubMenuItem:K}=y.useContext(p4),{isSubPathKey:q}=y.useContext(qce),X=AC(),Y=`${A}-submenu`,oe=F||c,ee=y.useRef(),ne=y.useRef(),le=h??H,he=p??N,re=L.includes(a),ie=!k&&re,de=q(B,a),{active:J,...ue}=Yce(a,oe,E,R),[ve,pe]=y.useState(!1),me=Ae=>{oe||pe(Ae)},ke=Ae=>{me(!0),b==null||b({key:a,domEvent:Ae})},De=Ae=>{me(!1),S==null||S({key:a,domEvent:Ae})},Ee=y.useMemo(()=>J||(I!=="inline"?ve||q([O],a):!1),[I,J,O,ve,a,q]),We=Zce(X.length),ze=Ae=>{oe||(x==null||x({key:a,domEvent:Ae}),I==="inline"&&W(a,!re))},mt=iw(Ae=>{v==null||v(yM(Ae)),z(Ae)}),Nt=Ae=>{I!=="inline"&&W(a,Ae)},St=()=>{V(a)},Ze=D&&`${D}-popup`,Fe=y.useMemo(()=>y.createElement(Qce,{icon:I!=="horizontal"?he:void 0,props:{...e,isOpen:ie,isSubMenu:!0}},y.createElement("i",{className:`${Y}-arrow`})),[I,he,e,ie,Y]);let tt=y.createElement("div",A0({role:"menuitem",style:We,className:`${Y}-title`,tabIndex:oe?null:-1,ref:ee,title:typeof s=="string"?s:null,"data-menu-id":k&&D?null:D,"aria-expanded":ie,"aria-haspopup":!0,"aria-controls":Ze,"aria-disabled":oe,onClick:ze,onFocus:St},ue),s,Fe);const Ne=y.useRef(I);I!=="inline"&&X.length>1?Ne.current="vertical":Ne.current=I;const rt=Ne.current,ot=y.useMemo(()=>{const Ae=y.createElement(I0,{classNames:o,styles:i,mode:rt==="horizontal"?"vertical":rt},y.createElement(Jce,{id:Ze,ref:ne},d)),nt=T||$;return nt?nt(Ae,{item:e,keys:X}):Ae},[T,$,X,Ze,d,e,rt]);if(!k){const Ae=Ne.current;tt=y.createElement(yBe,{mode:Ae,prefixCls:Y,visible:!u&&ie&&I!=="inline",popupClassName:f,popupOffset:g,popupStyle:m,popup:ot,disabled:oe,onVisibleChange:Nt},tt)}let Ye=y.createElement(Sd.Item,A0({ref:t,role:"none"},M,{component:"li",style:r,className:Q(Y,`${Y}-${I}`,n,{[`${Y}-open`]:ie,[`${Y}-active`]:Ee,[`${Y}-selected`]:de,[`${Y}-disabled`]:oe}),onMouseEnter:ke,onMouseLeave:De}),tt,!k&&y.createElement(CBe,{id:Ze,open:ie,keyPath:X},d));return K&&(Ye=K(Ye,e,{selected:de,active:Ee,open:ie,disabled:oe})),y.createElement(I0,{classNames:o,styles:i,onItemClick:mt,mode:I==="horizontal"?"vertical":I,itemIcon:le,expandIcon:he},Ye)}),JD=y.forwardRef((e,t)=>{const{eventKey:r,children:n}=e,i=AC(r),o=m4(n,i),s=QD();y.useEffect(()=>{if(s)return s.registerPath(r,i),()=>{s.unregisterPath(r,i)}},[i]);let a;return s?a=o:a=y.createElement(bBe,A0({ref:t},e),o),y.createElement(Kce.Provider,{value:i},a)});function v4({className:e,style:t}){const{prefixCls:r}=y.useContext(mc);return QD()?null:y.createElement("li",{role:"separator",className:Q(`${r}-item-divider`,e),style:t})}function CM(){return CM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{className:r,title:n,eventKey:i,children:o,...s}=e,{prefixCls:a,classNames:l,styles:c}=y.useContext(mc),u=`${a}-item-group`;return y.createElement("li",CM({ref:t,role:"presentation"},s,{onClick:d=>d.stopPropagation(),className:Q(u,r)}),y.createElement("div",{role:"presentation",className:Q(`${u}-title`,l==null?void 0:l.listTitle),style:c==null?void 0:c.listTitle,title:typeof n=="string"?n:void 0},n),y.createElement("ul",{role:"group",className:Q(`${u}-list`,l==null?void 0:l.list),style:c==null?void 0:c.list},o))}),y4=y.forwardRef((e,t)=>{const{eventKey:r,children:n}=e,i=AC(r),o=m4(n,i);return QD()?o:y.createElement(SBe,CM({ref:t},fn(e,["warnKey"])),o)});function oy(){return oy=Object.assign?Object.assign.bind():function(e){for(var t=1;t{if(a&&typeof a=="object"){const{label:c,children:u,key:d,type:h,extra:p,...f}=a,g=d??`tmp-${l}`;return u||h==="group"?h==="group"?y.createElement(i,oy({key:g},f,{title:c}),G$(u,t,r)):y.createElement(o,oy({key:g},f,{title:c}),G$(u,t,r)):h==="divider"?y.createElement(s,oy({key:g},f)):y.createElement(n,oy({key:g},f,{extra:p}),c,(!!p||p===0)&&y.createElement("span",{className:`${r}-item-extra`},p))}return null}).filter(a=>a)}function Mq(e,t,r,n,i){let o=e;const s={divider:v4,item:qx,group:y4,submenu:JD,...n};return t&&(o=G$(t,s,i)),m4(o,r)}function V$(){return V$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var _t;const{prefixCls:r="rc-menu",rootClassName:n,style:i,className:o,styles:s,classNames:a,tabIndex:l=0,items:c,children:u,direction:d,id:h,mode:p="vertical",inlineCollapsed:f,disabled:g,disabledOverflow:m,subMenuOpenDelay:v=.1,subMenuCloseDelay:b=.1,forceSubMenuRender:S,defaultOpenKeys:x,openKeys:E,activeKey:R,defaultActiveFirst:T,selectable:M=!0,multiple:D=!1,defaultSelectedKeys:A,selectedKeys:I,onSelect:L,onDeselect:F,inlineIndent:k=24,motion:O,defaultMotions:B,triggerSubMenuAction:H="hover",builtinPlacements:N,itemIcon:z,expandIcon:W,overflowedIndicator:V="...",overflowedIndicatorPopupClassName:$,getPopupContainer:K,onClick:q,onOpenChange:X,onKeyDown:Y,openAnimation:oe,openTransitionName:ee,_internalRenderMenuItem:ne,_internalRenderSubMenuItem:le,_internalComponents:he,popupRender:re,...ie}=e,[de,J]=y.useMemo(()=>[Mq(u,c,Cf,he,r),Mq(u,c,Cf,{},r)],[u,c,he]),[ue,ve]=y.useState(!1),pe=y.useRef(),me=xc(h?`rc-menu-uuid-${h}`:"rc-menu-uuid"),ke=d==="rtl",[De,Ee]=An(x,E),We=De||Cf,ze=(At,pt=!1)=>{function yt(){Ee(At),X==null||X(At)}pt?$a.flushSync(yt):yt()},[mt,Nt]=y.useState(We),St=y.useRef(!1),[Ze,Fe]=y.useMemo(()=>(p==="inline"||p==="vertical")&&f?["vertical",f]:[p,!1],[p,f]),tt=Ze==="inline",[Ne,rt]=y.useState(Ze),[ot,Ye]=y.useState(Fe);y.useEffect(()=>{rt(Ze),Ye(Fe),St.current&&(tt?Ee(mt):ze(Cf))},[Ze,Fe]);const[Ae,nt]=y.useState(0),Et=Ae>=de.length-1||Ne!=="horizontal"||m;y.useEffect(()=>{tt&&Nt(We)},[We]),y.useEffect(()=>(St.current=!0,()=>{St.current=!1}),[]);const{registerPath:Tt,unregisterPath:kt,refreshOverflowKeys:Wt,isSubPathKey:at,getKeyPath:lt,getKeys:Ut,getSubPathKeys:cr}=uBe(),_e=y.useMemo(()=>({registerPath:Tt,unregisterPath:kt}),[Tt,kt]),qe=y.useMemo(()=>({isSubPathKey:at}),[at]);y.useEffect(()=>{Wt(Et?Cf:de.slice(Ae+1).map(At=>At.key))},[Ae,Et]);const[Re,it]=An(R||T&&((_t=de[0])==null?void 0:_t.key),R),Ve=iw(At=>{it(At)}),Oe=iw(()=>{it(void 0)});y.useImperativeHandle(t,()=>({list:pe.current,focus:At=>{var rr,yn;const pt=Ut(),{elements:yt,key2element:It,element2key:Qt}=vM(pt,me),Ft=f4(pe.current,yt);let ur;Re&&pt.includes(Re)?ur=Re:ur=Ft[0]?Qt.get(Ft[0]):(rr=de.find(dn=>!dn.props.disabled))==null?void 0:rr.key;const fr=It.get(ur);ur&&fr&&((yn=fr==null?void 0:fr.focus)==null||yn.call(fr,At))},findItem:({key:At})=>{const pt=Ut(),{key2element:yt}=vM(pt,me);return yt.get(At)||null}}));const[se,ce]=An(A||[],I),fe=y.useMemo(()=>Array.isArray(se)?se:se==null?Cf:[se],[se]),Te=At=>{if(M){const{key:pt}=At,yt=fe.includes(pt);let It;D?yt?It=fe.filter(Ft=>Ft!==pt):It=[...fe,pt]:It=[pt],ce(It);const Qt={...At,selectedKeys:It};yt?F==null||F(Qt):L==null||L(Qt)}!D&&We.length&&Ne!=="inline"&&ze(Cf)},$e=iw(At=>{q==null||q(yM(At)),Te(At)}),et=iw((At,pt)=>{let yt=We.filter(It=>It!==At);if(pt)yt.push(At);else if(Ne!=="inline"){const It=cr(At);yt=yt.filter(Qt=>!It.has(Qt))}fc(We,yt,!0)||ze(yt,!0)}),ct=aBe(Ne,Re,ke,me,pe,Ut,lt,it,(At,pt)=>{const yt=pt??!We.includes(At);et(At,yt)},Y);y.useEffect(()=>{ve(!0)},[]);const st=y.useMemo(()=>({_internalRenderMenuItem:ne,_internalRenderSubMenuItem:le}),[ne,le]),wt=Ne!=="horizontal"||m?de:de.map((At,pt)=>y.createElement(I0,{key:At.key,overflowDisabled:pt>Ae,classNames:a,styles:s},At)),Mt=y.createElement(Sd,V$({id:h,ref:pe,prefixCls:`${r}-overflow`,component:"ul",itemComponent:qx,className:Q(r,`${r}-root`,`${r}-${Ne}`,o,{[`${r}-inline-collapsed`]:ot,[`${r}-rtl`]:ke},n),dir:d,style:i,role:"menu",tabIndex:l,data:wt,renderRawItem:At=>At,renderRawRest:At=>{const pt=At.length,yt=pt?de.slice(-pt):null;return y.createElement(JD,{eventKey:N$,title:V,disabled:Et,internalPopupClose:pt===0,popupClassName:$},yt)},maxCount:Ne!=="horizontal"||m?Sd.INVALIDATE:Sd.RESPONSIVE,ssr:"full","data-menu-list":!0,onVisibleChange:At=>{nt(At)},onKeyDown:ct},ie));return y.createElement(p4.Provider,{value:st},y.createElement(Hce.Provider,{value:me},y.createElement(I0,{prefixCls:r,rootClassName:n,classNames:a,styles:s,mode:Ne,openKeys:We,rtl:ke,disabled:g,motion:ue?O:null,defaultMotions:ue?B:null,activeKey:Re,onActive:Ve,onInactive:Oe,selectedKeys:fe,inlineIndent:k,subMenuOpenDelay:v,subMenuCloseDelay:b,forceSubMenuRender:S,builtinPlacements:N,triggerSubMenuAction:H,getPopupContainer:K,itemIcon:z,expandIcon:W,onItemClick:$e,onOpenChange:et,popupRender:re},y.createElement(qce.Provider,{value:qe},Mt),y.createElement("div",{style:{display:"none"},"aria-hidden":!0},y.createElement(jce.Provider,{value:_e},J)))))}),FC=wBe;FC.Item=qx;FC.SubMenu=JD;FC.ItemGroup=y4;FC.Divider=v4;const tue=y.createContext({});var xBe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"};function z$(){return z$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,z$({},e,{ref:t,icon:xBe})),C4=y.forwardRef(EBe),bM=y.createContext({prefixCls:"",firstLevel:!0,inlineCollapsed:!1,styles:null,classNames:null}),rue=e=>{const{prefixCls:t,className:r,dashed:n,...i}=e,{getPrefixCls:o}=y.useContext(ir),s=o("menu",t),a=Q({[`${s}-item-divider-dashed`]:!!n},r);return y.createElement(v4,{className:a,...i})},nue=e=>{var T,M;const{className:t,children:r,icon:n,title:i,danger:o,extra:s}=e,{prefixCls:a,firstLevel:l,direction:c,disableMenuItemTitleTooltip:u,tooltip:d,inlineCollapsed:h,styles:p,classNames:f}=y.useContext(bM),g=D=>{var L,F;const A=r==null?void 0:r[0],I=y.createElement("span",{className:Q(`${a}-title-content`,l?f==null?void 0:f.itemContent:(L=f==null?void 0:f.subMenu)==null?void 0:L.itemContent,{[`${a}-title-content-with-extra`]:!!s||s===0}),style:l?p==null?void 0:p.itemContent:(F=p==null?void 0:p.subMenu)==null?void 0:F.itemContent},r);return(!n||y.isValidElement(r)&&r.type==="span")&&r&&D&&l&&typeof A=="string"?y.createElement("div",{className:`${a}-inline-collapsed-noicon`},A.charAt(0)):I},{siderCollapsed:m}=y.useContext(tue);let v=i;typeof i>"u"?v=l?r:"":i===!1&&(v="");const b=d===!1?void 0:d,S=b&&b.title!==void 0?b.title:v,x={...b??null,title:S};!m&&!h&&(x.title=null,x.open=!1);const E=Li(r).length;let R=y.createElement(qx,{...fn(e,["title","icon","danger"]),className:Q(l?f==null?void 0:f.item:(T=f==null?void 0:f.subMenu)==null?void 0:T.item,{[`${a}-item-danger`]:o,[`${a}-item-only-child`]:(n?E+1:E)===1},t),style:{...l?p==null?void 0:p.item:(M=p==null?void 0:p.subMenu)==null?void 0:M.item,...e.style},title:typeof i=="string"?i:void 0},Ei(n,D=>{var A,I;return{className:Q(`${a}-item-icon`,l?f==null?void 0:f.itemIcon:(A=f==null?void 0:f.subMenu)==null?void 0:A.itemIcon,D.className),style:{...l?p==null?void 0:p.itemIcon:(I=p==null?void 0:p.subMenu)==null?void 0:I.itemIcon,...D.style}}}),g(h));if(!u&&d!==!1){const D=b&&b.placement?b.placement:c==="rtl"?"left":"right",A=`${a}-inline-collapsed-tooltip`,I=F=>({...F,root:Q(A,F==null?void 0:F.root)}),L=b&&typeof b.classNames=="function"?F=>{const k=b.classNames(F);return I(k)}:I(b==null?void 0:b.classNames);R=y.createElement(El,{...x,placement:D,classNames:L},R)}return R},SM=y.createContext(null),iue=y.forwardRef((e,t)=>{const{children:r,...n}=e,i=y.useContext(SM),o=y.useMemo(()=>({...i,...n}),[i,n.prefixCls,n.mode,n.selectable,n.rootClassName]),s=sIe(r),a=Pu(t,s?jd(r):null);return y.createElement(SM.Provider,{value:o},y.createElement(Rp,{space:!0},s?y.cloneElement(r,{ref:a}):r))}),TBe=e=>{const{componentCls:t,motionDurationSlow:r,horizontalLineHeight:n,colorSplit:i,lineWidth:o,lineType:s,itemPaddingInline:a}=e;return{[`${t}-horizontal`]:{lineHeight:n,border:0,borderBottom:`${ae(o)} ${s} ${i}`,boxShadow:"none","&::after":{display:"block",clear:"both",height:0,content:'"\\20"'},[`${t}-item, ${t}-submenu`]:{position:"relative",display:"inline-block",verticalAlign:"bottom",paddingInline:a},[`> ${t}-item:hover, > ${t}-item-active, > ${t}-submenu ${t}-submenu-title:hover`]:{backgroundColor:"transparent"},[`${t}-item, ${t}-submenu-title`]:{transition:["border-color","background-color"].map(l=>`${l} ${r}`).join(",")},[`${t}-submenu-arrow`]:{display:"none"}}}},RBe=({componentCls:e,menuArrowOffset:t,calc:r})=>({[`${e}-rtl`]:{direction:"rtl"},[`${e}-submenu-rtl`]:{transformOrigin:"100% 0"},[`${e}-rtl${e}-vertical, ${e}-submenu-rtl ${e}-vertical`]:{[`${e}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateY(${ae(r(t).mul(-1).equal())})`},"&::after":{transform:`rotate(45deg) translateY(${ae(t)})`}}}}),Iq=e=>gc(e),Dq=(e,t)=>{const{componentCls:r,itemColor:n,itemSelectedColor:i,subMenuItemSelectedColor:o,groupTitleColor:s,itemBg:a,subMenuItemBg:l,itemSelectedBg:c,activeBarHeight:u,activeBarWidth:d,activeBarBorderWidth:h,motionDurationSlow:p,motionEaseInOut:f,motionEaseOut:g,itemPaddingInline:m,motionDurationMid:v,itemHoverColor:b,lineType:S,colorSplit:x,itemDisabledColor:E,dangerItemColor:R,dangerItemHoverColor:T,dangerItemSelectedColor:M,dangerItemActiveBg:D,dangerItemSelectedBg:A,popupBg:I,itemHoverBg:L,itemActiveBg:F,menuSubMenuBg:k,horizontalItemSelectedColor:O,horizontalItemSelectedBg:B,horizontalItemBorderRadius:H,horizontalItemHoverBg:N}=e;return{[`${r}-${t}, ${r}-${t} > ${r}`]:{color:n,background:a,[`&${r}-root:focus-visible`]:{...Iq(e)},[`${r}-item`]:{"&-group-title, &-extra":{color:s}},[`${r}-submenu-selected > ${r}-submenu-title`]:{color:o},[`${r}-item, ${r}-submenu-title`]:{color:n,[`&:not(${r}-item-disabled):focus-visible`]:{...Iq(e)}},[`${r}-item-disabled, ${r}-submenu-disabled`]:{color:`${E} !important`},[`${r}-item:not(${r}-item-selected):not(${r}-submenu-selected)`]:{[`&:hover, > ${r}-submenu-title:hover`]:{color:b}},[`&:not(${r}-horizontal)`]:{[`${r}-item:not(${r}-item-selected)`]:{"&:hover":{backgroundColor:L},"&:active":{backgroundColor:F}},[`${r}-submenu-title`]:{"&:hover":{backgroundColor:L},"&:active":{backgroundColor:F}}},[`${r}-item-danger`]:{color:R,[`&${r}-item:hover`]:{[`&:not(${r}-item-selected):not(${r}-submenu-selected)`]:{color:T}},[`&${r}-item:active`]:{background:D}},[`${r}-item a`]:{"&, &:hover":{color:"inherit"}},[`${r}-item-selected`]:{color:i,[`&${r}-item-danger`]:{color:M},"a, a:hover":{color:"inherit"}},[`& ${r}-item-selected`]:{backgroundColor:c,[`&${r}-item-danger`]:{backgroundColor:A}},[`&${r}-submenu > ${r}`]:{backgroundColor:k},[`&${r}-popup > ${r}`]:{backgroundColor:I},[`&${r}-submenu-popup > ${r}`]:{backgroundColor:I},[`&${r}-horizontal`]:{...t==="dark"?{borderBottom:0}:{},[`> ${r}-item, > ${r}-submenu`]:{top:h,marginTop:e.calc(h).mul(-1).equal(),marginBottom:0,borderRadius:H,"&::after":{position:"absolute",insetInline:m,bottom:0,borderBottom:`${ae(u)} solid transparent`,transition:`border-color ${p} ${f}`,content:'""'},"&:hover, &-active, &-open":{background:N,"&::after":{borderBottomWidth:u,borderBottomColor:O}},"&-selected":{color:O,backgroundColor:B,"&:hover":{backgroundColor:B},"&::after":{borderBottomWidth:u,borderBottomColor:O}}}},[`&${r}-root`]:{[`&${r}-inline, &${r}-vertical`]:{borderInlineEnd:`${ae(h)} ${S} ${x}`}},[`&${r}-inline`]:{[`${r}-sub${r}-inline`]:{background:l},[`${r}-item`]:{position:"relative","&::after":{position:"absolute",insetBlock:0,insetInlineEnd:0,borderInlineEnd:`${ae(d)} solid ${i}`,transform:"scaleY(0.0001)",opacity:0,transition:["transform","opacity"].map(z=>`${z} ${v} ${g}`).join(","),content:'""'},[`&${r}-item-danger`]:{"&::after":{borderInlineEndColor:M}}},[`${r}-selected, ${r}-item-selected`]:{"&::after":{transform:"scaleY(1)",opacity:1,transition:["transform","opacity"].map(z=>`${z} ${v} ${f}`).join(",")}}}}}},Aq=e=>{const{componentCls:t,itemHeight:r,itemMarginInline:n,padding:i,menuArrowSize:o,marginXS:s,itemMarginBlock:a,itemWidth:l,itemPaddingInline:c}=e,u=e.calc(o).add(i).add(s).equal();return{[`${t}-item`]:{position:"relative",overflow:"hidden"},[`${t}-item, ${t}-submenu-title`]:{height:r,lineHeight:ae(r),paddingInline:c,overflow:"hidden",textOverflow:"ellipsis",marginInline:n,marginBlock:a,width:l},[`> ${t}-item, > ${t}-submenu > ${t}-submenu-title`]:{height:r,lineHeight:ae(r)},[`${t}-item-group-list ${t}-submenu-title, ${t}-submenu-title`]:{paddingInlineEnd:u}}},PBe=e=>{const{componentCls:t,iconCls:r,itemHeight:n,colorTextLightSolid:i,dropdownWidth:o,controlHeightLG:s,motionEaseOut:a,paddingXL:l,itemMarginInline:c,fontSizeLG:u,motionDurationFast:d,motionDurationSlow:h,paddingXS:p,boxShadowSecondary:f,collapsedWidth:g,collapsedIconSize:m}=e,v={height:n,lineHeight:ae(n),listStylePosition:"inside",listStyleType:"disc"};return[{[t]:{"&-inline, &-vertical":{[`&${t}-root`]:{boxShadow:"none"},...Aq(e)}},[`${t}-submenu-popup`]:{[`${t}-vertical`]:{...Aq(e),boxShadow:f}}},{[`${t}-submenu-popup ${t}-vertical${t}-sub`]:{minWidth:o,maxHeight:`calc(100vh - ${ae(e.calc(s).mul(2.5).equal())})`,padding:"0",overflow:"hidden",borderInlineEnd:0,"&:not([class*='-active'])":{overflowX:"hidden",overflowY:"auto"}}},{[`${t}-inline`]:{width:"100%",[`&${t}-root`]:{[`${t}-item, ${t}-submenu-title`]:{display:"flex",alignItems:"center",transition:[`border-color ${h}`,`background-color ${h}`,`padding ${d} ${a}`].join(","),[`> ${t}-title-content`]:{flex:"auto",minWidth:0,overflow:"hidden",textOverflow:"ellipsis"},"> *":{flex:"none"}}},[`${t}-sub${t}-inline`]:{padding:0,border:0,borderRadius:0,boxShadow:"none",[`& > ${t}-submenu > ${t}-submenu-title`]:v,[`& ${t}-item-group-title`]:{paddingInlineStart:l}},[`${t}-item`]:v}},{[`${t}-inline-collapsed`]:{width:g,[`&${t}-root`]:{[`${t}-item, ${t}-submenu ${t}-submenu-title`]:{[`> ${t}-inline-collapsed-noicon`]:{fontSize:u,textAlign:"center"}}},[`> ${t}-item, > ${t}-item-group > ${t}-item-group-list > ${t}-item, > ${t}-item-group > ${t}-item-group-list > ${t}-submenu > ${t}-submenu-title, > ${t}-submenu > ${t}-submenu-title`]:{insetInlineStart:0,paddingInline:`calc(50% - ${ae(e.calc(m).div(2).equal())} - ${ae(c)})`,textOverflow:"clip",[` ${t}-submenu-arrow, ${t}-submenu-expand-icon `]:{opacity:0},[`${t}-item-icon, ${r}`]:{margin:0,fontSize:m,lineHeight:ae(n),"+ span":{display:"inline-block",opacity:0}}},[`${t}-item-icon, ${r}`]:{display:"inline-block"},"&-tooltip":{pointerEvents:"none",[`${t}-item-icon, ${r}`]:{display:"none"},"a, a:hover":{color:i}},[`${t}-item-group-title`]:{...Ps,paddingInline:p}}}]},Fq=e=>{const{componentCls:t,motionDurationSlow:r,motionDurationMid:n,motionEaseInOut:i,motionEaseOut:o,iconCls:s,iconSize:a,iconMarginInlineEnd:l}=e;return{[`${t}-item, ${t}-submenu-title`]:{position:"relative",display:"block",margin:0,whiteSpace:"nowrap",cursor:"pointer",transition:[`border-color ${r}`,`background-color ${r}`,`padding calc(${r} + 0.1s) ${i}`].join(","),[`${t}-item-icon, ${s}`]:{minWidth:a,fontSize:a,transition:[`font-size ${n} ${o}`,`margin ${r} ${i}`,`color ${r}`].join(","),"+ span":{marginInlineStart:l,opacity:1,transition:[`opacity ${r} ${i}`,`margin ${r}`,`color ${r}`].join(",")}},[`${t}-item-icon`]:{...Ix()},[`&${t}-item-only-child`]:{[`> ${s}, > ${t}-item-icon`]:{marginInlineEnd:0}}},[`${t}-item-disabled, ${t}-submenu-disabled`]:{background:"none !important",cursor:"not-allowed","&::after":{borderColor:"transparent !important"},a:{color:"inherit !important",cursor:"not-allowed",pointerEvents:"none"},[`> ${t}-submenu-title`]:{color:"inherit !important",cursor:"not-allowed"}}}},Lq=e=>{const{componentCls:t,motionDurationSlow:r,motionEaseInOut:n,borderRadius:i,menuArrowSize:o,menuArrowOffset:s}=e;return{[`${t}-submenu`]:{"&-expand-icon, &-arrow":{position:"absolute",top:"50%",insetInlineEnd:e.margin,width:o,color:"currentcolor",transform:"translateY(-50%)",transition:["transform","opacity"].map(a=>`${a} ${r}`).join(",")},"&-arrow":{"&::before, &::after":{position:"absolute",width:e.calc(o).mul(.6).equal(),height:e.calc(o).mul(.15).equal(),backgroundColor:"currentcolor",borderRadius:i,transition:["background-color","transform","top","color"].map(a=>`${a} ${r} ${n}`).join(","),content:'""'},"&::before":{transform:`rotate(45deg) translateY(${ae(e.calc(s).mul(-1).equal())})`},"&::after":{transform:`rotate(-45deg) translateY(${ae(s)})`}}}}},MBe=e=>{const{antCls:t,componentCls:r,fontSize:n,motionDurationSlow:i,motionDurationMid:o,motionEaseInOut:s,paddingXS:a,padding:l,colorSplit:c,lineWidth:u,zIndexPopup:d,borderRadiusLG:h,subMenuItemBorderRadius:p,menuArrowSize:f,menuArrowOffset:g,lineType:m,groupTitleLineHeight:v,groupTitleFontSize:b}=e;return[{"":{[r]:{...fu(),"&-hidden":{display:"none"}}},[`${r}-submenu-hidden`]:{display:"none"}},{[r]:{...on(e),...fu(),marginBottom:0,paddingInlineStart:0,fontSize:n,lineHeight:0,listStyle:"none",outline:"none",transition:`width ${i} cubic-bezier(0.2, 0, 0, 1) 0s`,"ul, ol":{margin:0,padding:0,listStyle:"none"},"&-overflow":{display:"flex",[`${r}-item`]:{flex:"none"}},[`${r}-item, ${r}-submenu, ${r}-submenu-title`]:{borderRadius:e.itemBorderRadius},[`${r}-item-group-title`]:{padding:`${ae(a)} ${ae(l)}`,fontSize:b,lineHeight:v,transition:`all ${i}`},[`&-horizontal ${r}-submenu`]:{transition:["border-color","background-color"].map(S=>`${S} ${i} ${s}`).join(",")},[`${r}-submenu, ${r}-submenu-inline`]:{transition:[`border-color ${i}`,`background-color ${i}`,`padding ${o}`].map(S=>`${S} ${s}`).join(",")},[`${r}-submenu ${r}-sub`]:{cursor:"initial",transition:["background-color","padding"].map(S=>`${S} ${i} ${s}`).join(",")},[`${r}-title-content`]:{transition:`color ${i}`,"&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},[`> ${t}-typography-ellipsis-single-line`]:{display:"inline",verticalAlign:"unset"},[`${r}-item-extra`]:{marginInlineStart:"auto",paddingInlineStart:e.padding}},[`${r}-item a`]:{"&::before":{position:"absolute",inset:0,backgroundColor:"transparent",content:'""'}},[`${r}-item-divider`]:{overflow:"hidden",lineHeight:0,borderColor:c,borderStyle:m,borderWidth:0,borderTopWidth:u,marginBlock:u,padding:0,"&-dashed":{borderStyle:"dashed"}},...Fq(e),[`${r}-item-group`]:{[`${r}-item-group-list`]:{margin:0,padding:0,[`${r}-item, ${r}-submenu-title`]:{paddingInline:`${ae(e.calc(n).mul(2).equal())} ${ae(l)}`}}},"&-submenu":{"&-popup":{position:"absolute",zIndex:d,borderRadius:h,boxShadow:"none",transformOrigin:"0 0",[`&${r}-submenu`]:{background:"transparent"},"&::before":{position:"absolute",inset:0,zIndex:-1,width:"100%",height:"100%",opacity:0,content:'""'},[`> ${r}`]:{borderRadius:h,...Fq(e),...Lq(e),[`${r}-item, ${r}-submenu > ${r}-submenu-title`]:{borderRadius:p},[`${r}-submenu-title::after`]:{transition:`transform ${i} ${s}`}}},"\n &-placement-leftTop,\n &-placement-bottomRight,\n ":{transformOrigin:"100% 0"},"\n &-placement-leftBottom,\n &-placement-topRight,\n ":{transformOrigin:"100% 100%"},"\n &-placement-rightBottom,\n &-placement-topLeft,\n ":{transformOrigin:"0 100%"},"\n &-placement-bottomLeft,\n &-placement-rightTop,\n ":{transformOrigin:"0 0"},"\n &-placement-leftTop,\n &-placement-leftBottom\n ":{paddingInlineEnd:e.paddingXS},"\n &-placement-rightTop,\n &-placement-rightBottom\n ":{paddingInlineStart:e.paddingXS},"\n &-placement-topRight,\n &-placement-topLeft\n ":{paddingBottom:e.paddingXS},"\n &-placement-bottomRight,\n &-placement-bottomLeft\n ":{paddingTop:e.paddingXS}},...Lq(e),[`&-inline-collapsed ${r}-submenu-arrow, &-inline ${r}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateX(${ae(g)})`},"&::after":{transform:`rotate(45deg) translateX(${ae(e.calc(g).mul(-1).equal())})`}},[`${r}-submenu-open${r}-submenu-inline > ${r}-submenu-title > ${r}-submenu-arrow`]:{transform:`translateY(${ae(e.calc(f).mul(.2).mul(-1).equal())})`,"&::after":{transform:`rotate(-45deg) translateX(${ae(e.calc(g).mul(-1).equal())})`},"&::before":{transform:`rotate(45deg) translateX(${ae(g)})`}}}},{[`${t}-layout-header`]:{[r]:{lineHeight:"inherit"}}}]},IBe=e=>{const{colorPrimary:t,colorError:r,colorTextDisabled:n,colorErrorBg:i,colorText:o,colorTextDescription:s,colorBgContainer:a,colorFillAlter:l,colorFillContent:c,lineWidth:u,lineWidthBold:d,controlItemBgActive:h,colorBgTextHover:p,controlHeightLG:f,lineHeight:g,colorBgElevated:m,marginXXS:v,padding:b,fontSize:S,controlHeightSM:x,fontSizeLG:E,colorTextLightSolid:R,colorErrorHover:T}=e,M=e.activeBarWidth??0,D=e.activeBarBorderWidth??u,A=e.itemMarginInline??e.marginXXS,I=new cn(R).setA(.65).toRgbString();return{dropdownWidth:160,zIndexPopup:e.zIndexPopupBase+50,radiusItem:e.borderRadiusLG,itemBorderRadius:e.borderRadiusLG,radiusSubMenuItem:e.borderRadiusSM,subMenuItemBorderRadius:e.borderRadiusSM,colorItemText:o,itemColor:o,colorItemTextHover:o,itemHoverColor:o,colorItemTextHoverHorizontal:t,horizontalItemHoverColor:t,colorGroupTitle:s,groupTitleColor:s,colorItemTextSelected:t,itemSelectedColor:t,subMenuItemSelectedColor:t,colorItemTextSelectedHorizontal:t,horizontalItemSelectedColor:t,colorItemBg:a,itemBg:a,colorItemBgHover:p,itemHoverBg:p,colorItemBgActive:c,itemActiveBg:h,colorSubItemBg:l,subMenuItemBg:l,colorItemBgSelected:h,itemSelectedBg:h,colorItemBgSelectedHorizontal:"transparent",horizontalItemSelectedBg:"transparent",colorActiveBarWidth:0,activeBarWidth:M,colorActiveBarHeight:d,activeBarHeight:d,colorActiveBarBorderSize:u,activeBarBorderWidth:D,colorItemTextDisabled:n,itemDisabledColor:n,colorDangerItemText:r,dangerItemColor:r,colorDangerItemTextHover:r,dangerItemHoverColor:r,colorDangerItemTextSelected:r,dangerItemSelectedColor:r,colorDangerItemBgActive:i,dangerItemActiveBg:i,colorDangerItemBgSelected:i,dangerItemSelectedBg:i,itemMarginInline:A,horizontalItemBorderRadius:0,horizontalItemHoverBg:"transparent",itemHeight:f,groupTitleLineHeight:g,collapsedWidth:f*2,popupBg:m,itemMarginBlock:v,itemPaddingInline:b,horizontalLineHeight:`${f*1.15}px`,iconSize:S,iconMarginInlineEnd:x-S,collapsedIconSize:E,groupTitleFontSize:S,darkItemDisabledColor:new cn(R).setA(.25).toRgbString(),darkItemColor:I,darkDangerItemColor:r,darkItemBg:"#001529",darkPopupBg:"#001529",darkSubMenuItemBg:"#000c17",darkItemSelectedColor:R,darkItemSelectedBg:t,darkDangerItemSelectedBg:r,darkItemHoverBg:"transparent",darkGroupTitleColor:I,darkItemHoverColor:R,darkDangerItemHoverColor:T,darkDangerItemSelectedColor:R,darkDangerItemActiveBg:r,itemWidth:M?`calc(100% + ${D}px)`:`calc(100% - ${A*2}px)`}},DBe=(e,t=e,r=!0)=>Wr("Menu",i=>{const{colorBgElevated:o,controlHeightLG:s,fontSize:a,darkItemColor:l,darkDangerItemColor:c,darkItemBg:u,darkSubMenuItemBg:d,darkItemSelectedColor:h,darkItemSelectedBg:p,darkDangerItemSelectedBg:f,darkItemHoverBg:g,darkGroupTitleColor:m,darkItemHoverColor:v,darkItemDisabledColor:b,darkDangerItemHoverColor:S,darkDangerItemSelectedColor:x,darkDangerItemActiveBg:E,popupBg:R,darkPopupBg:T}=i,M=i.calc(a).div(7).mul(5).equal(),D=$r(i,{menuArrowSize:M,menuHorizontalHeight:i.calc(s).mul(1.15).equal(),menuArrowOffset:i.calc(M).mul(.25).equal(),menuSubMenuBg:o,calc:i.calc,popupBg:R}),A=$r(D,{itemColor:l,itemHoverColor:v,groupTitleColor:m,itemSelectedColor:h,subMenuItemSelectedColor:h,itemBg:u,popupBg:T,subMenuItemBg:d,itemActiveBg:"transparent",itemSelectedBg:p,activeBarHeight:0,activeBarBorderWidth:0,itemHoverBg:g,itemDisabledColor:b,dangerItemColor:c,dangerItemHoverColor:S,dangerItemSelectedColor:x,dangerItemActiveBg:E,dangerItemSelectedBg:f,menuSubMenuBg:d,horizontalItemSelectedColor:h,horizontalItemSelectedBg:p});return[MBe(D),TBe(D),PBe(D),Dq(D,"light"),Dq(A,"dark"),RBe(D),V3(D),Tp(D,"slide-up"),Tp(D,"slide-down"),Nx(D,"zoom-big")]},IBe,{deprecatedTokens:[["colorGroupTitle","groupTitleColor"],["radiusItem","itemBorderRadius"],["radiusSubMenuItem","subMenuItemBorderRadius"],["colorItemText","itemColor"],["colorItemTextHover","itemHoverColor"],["colorItemTextHoverHorizontal","horizontalItemHoverColor"],["colorItemTextSelected","itemSelectedColor"],["colorItemTextSelectedHorizontal","horizontalItemSelectedColor"],["colorItemTextDisabled","itemDisabledColor"],["colorDangerItemText","dangerItemColor"],["colorDangerItemTextHover","dangerItemHoverColor"],["colorDangerItemTextSelected","dangerItemSelectedColor"],["colorDangerItemBgActive","dangerItemActiveBg"],["colorDangerItemBgSelected","dangerItemSelectedBg"],["colorItemBg","itemBg"],["colorItemBgHover","itemHoverBg"],["colorSubItemBg","subMenuItemBg"],["colorItemBgActive","itemActiveBg"],["colorItemBgSelectedHorizontal","horizontalItemSelectedBg"],["colorActiveBarWidth","activeBarWidth"],["colorActiveBarHeight","activeBarHeight"],["colorActiveBarBorderSize","activeBarBorderWidth"],["colorItemBgSelected","itemSelectedBg"]],injectStyle:r,unitless:{groupTitleLineHeight:!0}})(e,t),oue=e=>{var g,m,v,b,S,x;const{popupClassName:t,icon:r,title:n,theme:i}=e,o=y.useContext(bM),{prefixCls:s,inlineCollapsed:a,theme:l,classNames:c,styles:u}=o,d=AC();let h;if(!r)h=a&&!d.length&&n&&typeof n=="string"?y.createElement("div",{className:`${s}-inline-collapsed-noicon`},n.charAt(0)):y.createElement("span",{className:`${s}-title-content`},n);else{const E=y.isValidElement(n)&&n.type==="span";h=y.createElement(y.Fragment,null,Ei(r,R=>({className:Q(R.className,`${s}-item-icon`,c==null?void 0:c.itemIcon),style:{...R.style,...u==null?void 0:u.itemIcon}})),E?n:y.createElement("span",{className:`${s}-title-content`},n))}const p=y.useMemo(()=>({...o,firstLevel:!1}),[o]),[f]=Hp("Menu");return y.createElement(bM.Provider,{value:p},y.createElement(JD,{...fn(e,["icon"]),title:h,classNames:{list:(g=c==null?void 0:c.subMenu)==null?void 0:g.list,listTitle:(m=c==null?void 0:c.subMenu)==null?void 0:m.itemTitle},styles:{list:(v=u==null?void 0:u.subMenu)==null?void 0:v.list,listTitle:(b=u==null?void 0:u.subMenu)==null?void 0:b.itemTitle},popupClassName:Q(s,t,(S=c==null?void 0:c.popup)==null?void 0:S.root,`${s}-${i||l}`),popupStyle:{zIndex:f,...e.popupStyle,...(x=u==null?void 0:u.popup)==null?void 0:x.root}}))};function tO(e){return e===null||e===!1}const ABe={item:nue,submenu:oue,divider:rue},FBe=y.forwardRef((e,t)=>{var le;const r=y.useContext(SM),n=r||{},{prefixCls:i,className:o,style:s,theme:a="light",expandIcon:l,_internalDisableMenuItemTitleTooltip:c,tooltip:u,inlineCollapsed:d,siderCollapsed:h,rootClassName:p,mode:f,selectable:g,onClick:m,overflowedIndicatorPopupClassName:v,classNames:b,styles:S,...x}=e,{menu:E}=y.useContext(ir),{getPrefixCls:R,getPopupContainer:T,direction:M,className:D,style:A,classNames:I,styles:L}=Nr("menu"),F=R(),k=fn(x,["collapsedWidth"]);(le=n.validator)==null||le.call(n,{mode:f});const O=br((...he)=>{var re;m==null||m(...he),(re=n.onClick)==null||re.call(n)}),B=n.mode||f,H=g??n.selectable,N=d??h,z={...e,mode:B,inlineCollapsed:N,selectable:H,theme:a},[W,V]=Vr([I,b],[L,S],{props:z},{popup:{_default:"root"},subMenu:{_default:"item"}}),$={horizontal:{motionName:`${F}-slide-up`},inline:B3(F),other:{motionName:`${F}-zoom-big`}},K=R("menu",i||n.prefixCls),q=ho(K),[X,Y]=DBe(K,q,!r),oe=Q(`${K}-${a}`,D,o),ee=y.useMemo(()=>{var re;if(typeof l=="function"||tO(l))return l||null;if(typeof n.expandIcon=="function"||tO(n.expandIcon))return n.expandIcon||null;if(typeof(E==null?void 0:E.expandIcon)=="function"||tO(E==null?void 0:E.expandIcon))return(E==null?void 0:E.expandIcon)||null;const he=l??(n==null?void 0:n.expandIcon)??(E==null?void 0:E.expandIcon);return Ei(he,{className:Q(`${K}-submenu-expand-icon`,y.isValidElement(he)?(re=he.props)==null?void 0:re.className:void 0)})},[l,n==null?void 0:n.expandIcon,E==null?void 0:E.expandIcon,K]),ne=y.useMemo(()=>({prefixCls:K,inlineCollapsed:N||!1,direction:M,firstLevel:!0,theme:a,mode:B,disableMenuItemTitleTooltip:c,tooltip:u,classNames:W,styles:V}),[K,N,M,c,a,B,W,V,u]);return y.createElement(SM.Provider,{value:null},y.createElement(bM.Provider,{value:ne},y.createElement(FC,{getPopupContainer:T,overflowedIndicator:y.createElement(C4,null),overflowedIndicatorPopupClassName:Q(K,`${K}-${a}`,v),classNames:{list:W.list,listTitle:W.itemTitle},styles:{list:V.list,listTitle:V.itemTitle},mode:B,selectable:H,onClick:O,...k,inlineCollapsed:N,style:{...V.root,...A,...s},className:oe,prefixCls:K,direction:M,defaultMotions:$,expandIcon:ee,ref:t,rootClassName:Q(p,X,n.rootClassName,Y,q,W.root),_internalComponents:ABe})))}),LC=y.forwardRef((e,t)=>{const r=y.useRef(null),n=y.useContext(tue);return y.useImperativeHandle(t,()=>({menu:r.current,focus:i=>{var o;(o=r.current)==null||o.focus(i)}})),y.createElement(FBe,{ref:r,...e,...n})});LC.Item=nue;LC.SubMenu=oue;LC.Divider=rue;LC.ItemGroup=y4;const LBe=e=>{const{componentCls:t,menuCls:r,colorError:n,colorTextLightSolid:i}=e,o=`${r}-item`;return{[`${t}, ${t}-menu-submenu`]:{[`${r} ${o}`]:{[`&${o}-danger:not(${o}-disabled)`]:{color:n,"&:hover":{color:i,backgroundColor:n}}}}}},_Be=e=>{const{componentCls:t,menuCls:r,zIndexPopup:n,dropdownArrowDistance:i,sizePopupArrow:o,antCls:s,iconCls:a,motionDurationMid:l,paddingBlock:c,fontSize:u,dropdownEdgeChildPadding:d,colorTextDisabled:h,fontSizeIcon:p,controlPaddingHorizontal:f,colorBgElevated:g}=e;return[{[t]:{position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:n,display:"block","&::before":{position:"absolute",insetBlock:e.calc(o).div(2).sub(i).equal(),zIndex:-9999,opacity:1e-4,content:'""'},"&-menu-vertical":{maxHeight:"100vh",overflowY:"auto"},[`&-trigger${s}-btn`]:{[`& > ${a}-down, & > ${s}-btn-icon > ${a}-down`]:{fontSize:p}},[`${t}-wrap`]:{position:"relative",[`${s}-btn > ${a}-down`]:{fontSize:p},[`${a}-down::before`]:{transition:`transform ${l}`}},[`${t}-wrap-open`]:{[`${a}-down::before`]:{transform:"rotate(180deg)"}},"\n &-hidden,\n &-menu-hidden,\n &-menu-submenu-hidden\n ":{display:"none"},[`&${s}-slide-down-enter${s}-slide-down-enter-active${t}-placement-bottomLeft, &${s}-slide-down-appear${s}-slide-down-appear-active${t}-placement-bottomLeft, &${s}-slide-down-enter${s}-slide-down-enter-active${t}-placement-bottom, &${s}-slide-down-appear${s}-slide-down-appear-active${t}-placement-bottom, &${s}-slide-down-enter${s}-slide-down-enter-active${t}-placement-bottomRight, &${s}-slide-down-appear${s}-slide-down-appear-active${t}-placement-bottomRight`]:{animationName:z3},[`&${s}-slide-up-enter${s}-slide-up-enter-active${t}-placement-topLeft, &${s}-slide-up-appear${s}-slide-up-appear-active${t}-placement-topLeft, &${s}-slide-up-enter${s}-slide-up-enter-active${t}-placement-top, &${s}-slide-up-appear${s}-slide-up-appear-active${t}-placement-top, &${s}-slide-up-enter${s}-slide-up-enter-active${t}-placement-topRight, &${s}-slide-up-appear${s}-slide-up-appear-active${t}-placement-topRight`]:{animationName:W3},[`&${s}-slide-down-leave${s}-slide-down-leave-active${t}-placement-bottomLeft, &${s}-slide-down-leave${s}-slide-down-leave-active${t}-placement-bottom, &${s}-slide-down-leave${s}-slide-down-leave-active${t}-placement-bottomRight`]:{animationName:H3},[`&${s}-slide-up-leave${s}-slide-up-leave-active${t}-placement-topLeft, &${s}-slide-up-leave${s}-slide-up-leave-active${t}-placement-top, &${s}-slide-up-leave${s}-slide-up-leave-active${t}-placement-topRight`]:{animationName:U3}}},u4(e,g,{arrowPlacement:{top:!0,bottom:!0}}),{[`${t} ${r}`]:{position:"relative",margin:0},[`${r}-submenu-popup`]:{position:"absolute",zIndex:n,background:"transparent",boxShadow:"none",transformOrigin:"0 0","ul, li":{listStyle:"none",margin:0}},[`${t}, ${t}-menu-submenu`]:{...on(e),[r]:{padding:d,listStyleType:"none",backgroundColor:g,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,...wl(e),"&:empty":{padding:0,boxShadow:"none"},[`${r}-item-group-title`]:{padding:`${ae(c)} ${ae(f)}`,color:e.colorTextDescription,transition:`all ${l}`},[`${r}-item`]:{position:"relative",display:"flex",alignItems:"center"},[`${r}-item-icon`]:{minWidth:u,marginInlineEnd:e.marginXS,fontSize:e.fontSizeSM},[`${r}-title-content`]:{flex:"auto","&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},"> a":{color:"inherit",transition:`all ${l}`,"&:hover":{color:"inherit"},"&::after":{position:"absolute",inset:0,content:'""'}},[`${r}-item-extra`]:{paddingInlineStart:e.padding,marginInlineStart:"auto",fontSize:e.fontSizeSM,color:e.colorTextDescription}},[`${r}-item, ${r}-submenu-title`]:{display:"flex",margin:0,padding:`${ae(c)} ${ae(f)}`,color:e.colorText,fontWeight:"normal",fontSize:u,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${l}`,borderRadius:e.borderRadiusSM,"&:hover, &-active":{backgroundColor:e.controlItemBgHover},...wl(e),"&-selected":{color:e.colorPrimary,backgroundColor:e.controlItemBgActive,"&:hover, &-active":{backgroundColor:e.controlItemBgActiveHover}},"&-disabled":{color:h,cursor:"not-allowed","&:hover":{color:h,backgroundColor:g,cursor:"not-allowed"},a:{pointerEvents:"none"}},"&-divider":{height:1,margin:`${ae(e.marginXXS)} 0`,overflow:"hidden",lineHeight:0,backgroundColor:e.colorSplit},[`${t}-menu-submenu-expand-icon`]:{position:"absolute",insetInlineEnd:e.paddingXS,[`${t}-menu-submenu-arrow-icon`]:{marginInlineEnd:"0 !important",color:e.colorIcon,fontSize:p,fontStyle:"normal"}}},[`${r}-item-group-list`]:{margin:`0 ${ae(e.marginXS)}`,padding:0,listStyle:"none"},[`${r}-submenu-title`]:{paddingInlineEnd:e.calc(f).add(e.fontSizeSM).equal()},[`${r}-submenu-vertical`]:{position:"relative"},[`${r}-submenu${r}-submenu-disabled ${t}-menu-submenu-title`]:{[`&, ${t}-menu-submenu-arrow-icon`]:{color:h,backgroundColor:g,cursor:"not-allowed"}},[`${r}-submenu-selected ${t}-menu-submenu-title`]:{color:e.colorPrimary}}}},[Tp(e,"slide-up"),Tp(e,"slide-down"),uM(e,"move-up"),uM(e,"move-down"),Nx(e,"zoom-big")]]},OBe=e=>({zIndexPopup:e.zIndexPopupBase+50,paddingBlock:(e.controlHeight-e.fontSize*e.lineHeight)/2,...YD({contentRadius:e.borderRadiusLG,limitVerticalRadius:!0}),...c4(e)}),kBe=Wr("Dropdown",e=>{const{marginXXS:t,sizePopupArrow:r,paddingXXS:n,componentCls:i}=e,o=$r(e,{menuCls:`${i}-menu`,dropdownArrowDistance:e.calc(r).div(2).add(t).equal(),dropdownEdgeChildPadding:n});return[_Be(o),LBe(o)]},OBe,{resetStyle:!1}),Xx=e=>{const{menu:t,arrow:r,prefixCls:n,children:i,trigger:o,disabled:s,dropdownRender:a,popupRender:l,getPopupContainer:c,overlayClassName:u,rootClassName:d,overlayStyle:h,open:p,onOpenChange:f,mouseEnterDelay:g=.15,mouseLeaveDelay:m=.1,autoAdjustOverflow:v=!0,placement:b="",transitionName:S,classNames:x,styles:E,destroyPopupOnHide:R,destroyOnHidden:T}=e,{getPrefixCls:M,direction:D,getPopupContainer:A,className:I,style:L,classNames:F,styles:k}=Nr("dropdown"),O={...e,mouseEnterDelay:g,mouseLeaveDelay:m,autoAdjustOverflow:v},[B,H]=Vr([F,x],[k,E],{props:O}),N={...L,...h,...H.root},z=l||a;MC();const W=y.useMemo(()=>{const De=M();return S!==void 0?S:b.includes("top")?`${De}-slide-down`:`${De}-slide-up`},[M,b,S]),V=y.useMemo(()=>b?b.includes("Center")?b.slice(0,b.indexOf("Center")):b:D==="rtl"?"bottomRight":"bottomLeft",[b,D]),$=M("dropdown",n),K=ho($),[q,X]=kBe($,K),[,Y]=fs(),oe=y.Children.only(tBe(i)?y.createElement("span",null,i):i),ee=Ei(oe,{className:Q(`${$}-trigger`,{[`${$}-rtl`]:D==="rtl"},oe.props.className),disabled:oe.props.disabled??s}),ne=s?[]:o,le=!!(ne!=null&&ne.includes("contextMenu")),[he,re]=An(!1,p),ie=br(De=>{f==null||f(De,{source:"trigger"}),re(De)}),de=Q(u,d,q,X,K,I,B.root,{[`${$}-rtl`]:D==="rtl"}),J=Fce({arrowPointAtCenter:typeof r=="object"&&r.pointAtCenter,autoAdjustOverflow:v,offset:Y.marginXXS,arrowWidth:r?Y.sizePopupArrow:0,borderRadius:Y.borderRadius}),ue=br(()=>{t!=null&&t.selectable&&(t!=null&&t.multiple)||(f==null||f(!1,{source:"menu"}),re(!1))}),ve=()=>{const De=fn(B,["root"]),Ee=fn(H,["root"]);let We;return t!=null&&t.items&&(We=y.createElement(LC,{...t,classNames:{...De,subMenu:{...De}},styles:{...Ee,subMenu:{...Ee}}})),z&&(We=z(We)),We=y.Children.only(typeof We=="string"?y.createElement("span",null,We):We),y.createElement(iue,{prefixCls:`${$}-menu`,rootClassName:Q(X,K),expandIcon:y.createElement("span",{className:`${$}-menu-submenu-arrow`},D==="rtl"?y.createElement(F$,{className:`${$}-menu-submenu-arrow-icon`}):y.createElement(JB,{className:`${$}-menu-submenu-arrow-icon`})),mode:"vertical",selectable:!1,onClick:ue,validator:({mode:ze})=>{}},We)},[pe,me]=Hp("Dropdown",N.zIndex);let ke=y.createElement(zce,{alignPoint:le,...fn(e,["rootClassName","onOpenChange"]),mouseEnterDelay:g,mouseLeaveDelay:m,visible:he,builtinPlacements:J,arrow:!!r,overlayClassName:de,prefixCls:$,getPopupContainer:c||A,transitionName:W,trigger:ne,overlay:ve,placement:V,onVisibleChange:ie,overlayStyle:{...N,zIndex:pe},autoDestroy:T??R},ee);return pe&&(ke=y.createElement(Lx.Provider,{value:me},ke)),ke},NBe=J3(Xx,"align",void 0,"dropdown",e=>e),BBe=e=>y.createElement(NBe,{...e},y.createElement("span",null));Xx._InternalPanelDoNotUseOrYouWillBeFired=BBe;const eA=({children:e})=>{const{getPrefixCls:t}=y.useContext(ir),r=t("breadcrumb"),n=y.useContext(h4),{classNames:i,styles:o}=n;return y.createElement("li",{className:Q(`${r}-separator`,i==null?void 0:i.separator),style:o==null?void 0:o.separator,"aria-hidden":"true"},e===""?e:e||"/")};eA.__ANT_BREADCRUMB_SEPARATOR=!0;function $Be(e,t){if(!Tn(e.title))return null;const r=Object.keys(t).join("|");return typeof e.title=="object"?e.title:String(e.title).replace(new RegExp(`:(${r})`,"g"),(n,i)=>t[i]||n)}function sue(e,t,r,n){if(!Tn(r))return null;const{className:i,onClick:o,...s}=t,a={...ai(s,{data:!0,aria:!0}),onClick:o};return n!==void 0?y.createElement("a",{...a,className:Q(`${e}-link`,i),href:n},r):y.createElement("span",{...a,className:Q(`${e}-link`,i)},r)}function GBe(e,t){return(n,i,o,s,a)=>{if(t)return t(n,i,o,s);const l=$Be(n,i);return sue(e,n,l,a)}}const aue=e=>{const{prefixCls:t,separator:r="/",children:n,menu:i,dropdownProps:o,href:s,dropdownIcon:a}=e,l=y.useContext(h4),{classNames:c,styles:u}=l,h=(p=>{if(i){const f={...o};if(i){const{items:g,...m}=i||{};f.menu={...m,items:g==null?void 0:g.map(({key:v,title:b,label:S,path:x,...E},R)=>{let T=S??b;return x&&(T=y.createElement("a",{href:`${s}${x}`},T)),{...E,key:v??R,label:T}})}}return y.createElement(Xx,{placement:"bottom",...f},y.createElement("span",{className:`${t}-overlay-link`},p,a))}return p})(n);return Tn(h)?y.createElement(y.Fragment,null,y.createElement("li",{className:Q(`${t}-item`,c==null?void 0:c.item),style:u==null?void 0:u.item},h),r&&y.createElement(eA,null,r)):null},lue=e=>{const{prefixCls:t,children:r,href:n,...i}=e,{getPrefixCls:o}=y.useContext(ir),s=o("breadcrumb",t);return y.createElement(aue,{...i,prefixCls:s},sue(s,i,r,n))};lue.__ANT_BREADCRUMB_ITEM=!0;const VBe=e=>{const{componentCls:t,iconCls:r,calc:n}=e;return{[t]:{...on(e),color:e.itemColor,fontSize:e.fontSize,[r]:{fontSize:e.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},[`${t}-item a`]:{color:e.linkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${ae(e.paddingXXS)}`,borderRadius:e.borderRadiusSM,height:e.fontHeight,display:"inline-block",marginInline:n(e.marginXXS).mul(-1).equal(),"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover},...wl(e)},[`${t}-item:last-child`]:{color:e.lastItemColor},[`${t}-separator`]:{marginInline:e.separatorMargin,color:e.separatorColor},[`${t}-link`]:{[` > ${r} + span, > ${r} + a `]:{marginInlineStart:e.marginXXS}},[`${t}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.fontHeight,display:"inline-block",padding:`0 ${ae(e.paddingXXS)}`,marginInline:n(e.marginXXS).mul(-1).equal(),[`> ${r}`]:{marginInlineStart:e.marginXXS,fontSize:e.fontSizeIcon},"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover,a:{color:e.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}}}},zBe=e=>({itemColor:e.colorTextDescription,lastItemColor:e.colorText,iconFontSize:e.fontSize,linkColor:e.colorTextDescription,linkHoverColor:e.colorText,separatorColor:e.colorTextDescription,separatorMargin:e.marginXS}),HBe=Wr("Breadcrumb",e=>{const t=$r(e,{});return VBe(t)},zBe);function WBe(e){const{breadcrumbName:t,children:r,...n}=e,i={title:t,...n};return r&&(i.menu={items:r.map(({breadcrumbName:o,...s})=>({...s,title:o}))}),i}function UBe(e,t){return y.useMemo(()=>e||(t?t.map(WBe):null),[e,t])}const jBe=(e,t)=>{if(t===void 0)return t;let r=(t||"").replace(/^\//,"");return Object.keys(e).forEach(n=>{r=r.replace(`:${n}`,e[n])}),r},KBe=e=>{const{prefixCls:t,separator:r,style:n,className:i,rootClassName:o,routes:s,items:a,children:l,itemRender:c,params:u={},classNames:d,styles:h,dropdownIcon:p,...f}=e,{getPrefixCls:g,direction:m,className:v,style:b,classNames:S,styles:x,separator:E,dropdownIcon:R}=Nr("breadcrumb"),T=r??E??"/",M=p??R??y.createElement(XD,null);let D;const A=g("breadcrumb",t),[I,L]=HBe(A),F=UBe(a,s),k=y.useMemo(()=>({...e,separator:T}),[e,T]),[O,B]=Vr([S,d],[x,h],{props:k}),H=GBe(A,c);if(F&&F.length>0){const V=[],$=a||s;D=F.map((K,q)=>{const{path:X,key:Y,type:oe,menu:ee,onClick:ne,className:le,style:he,separator:re,dropdownProps:ie}=K,de=jBe(u,X);de!==void 0&&V.push(de);const J=Y??q;if(oe==="separator")return y.createElement(eA,{key:J},re);const ue={},ve=q===F.length-1;ee&&(ue.menu=ee);let{href:pe}=K;return V.length&&de!==void 0&&(pe=`#/${V.join("/")}`),y.createElement(aue,{key:J,...ue,...ai(K,{data:!0,aria:!0}),className:le,style:he,dropdownProps:ie,dropdownIcon:M,href:pe,separator:ve?"":T,onClick:ne,prefixCls:A},H(K,u,$,V,pe))})}else if(l){const V=Li(l).length;D=Li(l).map(($,K)=>{if(!$)return $;const q=K===V-1;return Ei($,{separator:q?"":T,key:K})})}const N=Q(A,v,{[`${A}-rtl`]:m==="rtl"},i,o,O.root,I,L),z={...B.root,...b,...n},W=y.useMemo(()=>({classNames:O,styles:B}),[O,B]);return y.createElement(h4.Provider,{value:W},y.createElement("nav",{className:N,style:z,...f},y.createElement("ol",null,D)))},cue=KBe;cue.Item=lue;cue.Separator=eA;function qBe(e){return e===void 0||e===!1?[]:Array.isArray(e)?e:[e]}function XBe(e){return qBe(e).join("_")}const uue=y.createContext(void 0),YBe=uue.Provider,due=y.createContext(void 0),ZBe=due.Provider;function H$(){return H$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r="rc-checkbox",className:n,style:i,checked:o,disabled:s,defaultChecked:a=!1,type:l="checkbox",title:c,onChange:u,...d}=e,h=y.useRef(null),p=y.useRef(null),[f,g]=An(a,o);y.useImperativeHandle(t,()=>({focus:b=>{var S;(S=h.current)==null||S.focus(b)},blur:()=>{var b;(b=h.current)==null||b.blur()},input:h.current,nativeElement:p.current}));const m=Q(r,n,{[`${r}-checked`]:f,[`${r}-disabled`]:s}),v=b=>{s||("checked"in e||g(b.target.checked),u==null||u({target:{...e,type:l,checked:b.target.checked},stopPropagation(){b.stopPropagation()},preventDefault(){b.preventDefault()},nativeEvent:b.nativeEvent}))};return y.createElement("span",{className:m,title:c,style:i,ref:p},y.createElement("input",H$({},d,{className:`${r}-input`,ref:h,onChange:v,disabled:s,checked:!!f,type:l})))});function pue(e){const t=Z.useRef(null),r=()=>{Or.cancel(t.current),t.current=null};return[()=>{r(),t.current=Or(()=>{t.current=null})},o=>{t.current&&(o.stopPropagation(),r()),e==null||e(o)}]}const QBe=e=>{const{componentCls:t,antCls:r}=e,n=`${t}-group`;return{[n]:{...on(e),display:"inline-block",fontSize:0,[`&${n}-rtl`]:{direction:"rtl"},[`&${n}-block`]:{display:"flex"},[`${r}-badge ${r}-badge-count`]:{zIndex:1},[`> ${r}-badge:not(:first-child) > ${r}-button-wrapper`]:{borderInlineStart:"none"},"&-vertical":{display:"flex",flexDirection:"column",rowGap:e.marginXS,[`${t}-wrapper`]:{marginInlineEnd:0}}}}},JBe=e=>{const{componentCls:t,wrapperMarginInlineEnd:r,colorPrimary:n,colorPrimaryHover:i,radioSize:o,motionDurationSlow:s,motionDurationMid:a,motionEaseInOutCirc:l,colorBgContainer:c,colorBorder:u,lineWidth:d,colorBgContainerDisabled:h,colorTextDisabled:p,paddingXS:f,dotColorDisabled:g,dotSize:m,lineType:v,radioColor:b,radioBgColor:S}=e;return{[`${t}-wrapper`]:{...on(e),display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:r,cursor:"pointer","&:last-child":{marginInlineEnd:0},[`&${t}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:e.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},"&-block":{flex:1,justifyContent:"center"},[t]:{...on(e),position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",boxSizing:"border-box",display:"block",width:`calc(${o} * 1px)`,height:`calc(${o} * 1px)`,backgroundColor:c,border:`${ae(d)} ${v} ${u}`,borderRadius:"50%",transition:`all ${a}`,flex:"none","&:after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%) scale(0)",width:`calc(${m} * 1px)`,height:`calc(${m} * 1px)`,backgroundColor:b,borderRadius:"50%",transformOrigin:"50% 50%",opacity:0,transition:`all ${s} ${l}`},[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0},[`&:has(${t}-input:focus-visible)`]:gc(e)},[`&:hover ${t}`]:{borderColor:n},[`&:hover ${t}-checked:not(${t}-disabled)`]:{backgroundColor:i,borderColor:"transparent"},[`${t}-checked`]:{backgroundColor:S,borderColor:n,"&::after":{transform:"translate(-50%, -50%)",opacity:1}},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},background:h,borderColor:u,"&::after":{backgroundColor:g}},[`${t}-disabled + span`]:{color:p,cursor:"not-allowed"},[`span${t} + *`]:{paddingInlineStart:f,paddingInlineEnd:f}}}},e$e=e=>{const{buttonColor:t,controlHeight:r,componentCls:n,lineWidth:i,lineType:o,colorBorder:s,motionDurationMid:a,buttonPaddingInline:l,fontSize:c,buttonBg:u,fontSizeLG:d,controlHeightLG:h,controlHeightSM:p,paddingXS:f,borderRadius:g,borderRadiusSM:m,borderRadiusLG:v,buttonCheckedBg:b,buttonSolidCheckedColor:S,colorTextDisabled:x,colorBgContainerDisabled:E,buttonCheckedBgDisabled:R,buttonCheckedColorDisabled:T,colorPrimary:M,colorPrimaryHover:D,colorPrimaryActive:A,buttonSolidCheckedBg:I,buttonSolidCheckedHoverBg:L,buttonSolidCheckedActiveBg:F,calc:k}=e;return{[`${n}-button-wrapper`]:{position:"relative",display:"inline-block",height:r,margin:0,paddingInline:l,paddingBlock:0,color:t,fontSize:c,lineHeight:ae(k(r).sub(k(i).mul(2)).equal()),background:u,border:`${ae(i)} ${o} ${s}`,borderBlockStartWidth:k(i).add(.02).equal(),borderInlineEndWidth:i,cursor:"pointer",transition:["color","background-color","box-shadow"].map(O=>`${O} ${a}`).join(","),a:{color:t},[`> ${n}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:last-child)":{marginInlineEnd:k(i).mul(-1).equal()},"&:first-child":{borderInlineStart:`${ae(i)} ${o} ${s}`,borderStartStartRadius:g,borderEndStartRadius:g},"&:last-child":{borderStartEndRadius:g,borderEndEndRadius:g},"&:first-child:last-child":{borderRadius:g},[`${n}-group-large &`]:{height:h,fontSize:d,lineHeight:ae(k(h).sub(k(i).mul(2)).equal()),"&:first-child":{borderStartStartRadius:v,borderEndStartRadius:v},"&:last-child":{borderStartEndRadius:v,borderEndEndRadius:v}},[`${n}-group-small &`]:{height:p,paddingInline:k(f).sub(i).equal(),paddingBlock:0,lineHeight:ae(k(p).sub(k(i).mul(2)).equal()),"&:first-child":{borderStartStartRadius:m,borderEndStartRadius:m},"&:last-child":{borderStartEndRadius:m,borderEndEndRadius:m}},"&:hover":{position:"relative",color:M},"&:has(:focus-visible)":gc(e),[`${n}, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${n}-button-wrapper-disabled)`]:{zIndex:1,color:M,background:b,borderColor:M,"&::before":{backgroundColor:M},"&:first-child":{borderColor:M},"&:hover":{color:D,borderColor:D,"&::before":{backgroundColor:D}},"&:active":{color:A,borderColor:A,"&::before":{backgroundColor:A}}},[`${n}-group-solid &-checked:not(${n}-button-wrapper-disabled)`]:{color:S,background:I,borderColor:I,"&:hover":{color:S,background:L,borderColor:L},"&:active":{color:S,background:F,borderColor:F}},"&-disabled":{color:x,backgroundColor:E,borderColor:s,cursor:"not-allowed","&:first-child, &:hover":{color:x,backgroundColor:E,borderColor:s}},[`&-disabled${n}-button-wrapper-checked`]:{color:T,backgroundColor:R,borderColor:s,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},t$e=e=>{const{wireframe:t,padding:r,marginXS:n,lineWidth:i,fontSizeLG:o,colorText:s,colorBgContainer:a,colorTextDisabled:l,controlItemBgActiveDisabled:c,colorTextLightSolid:u,colorPrimary:d,colorPrimaryHover:h,colorPrimaryActive:p,colorWhite:f}=e,g=4,m=o,v=t?m-g*2:m-(g+i)*2;return{radioSize:m,dotSize:v,dotColorDisabled:l,buttonSolidCheckedColor:u,buttonSolidCheckedBg:d,buttonSolidCheckedHoverBg:h,buttonSolidCheckedActiveBg:p,buttonBg:a,buttonCheckedBg:a,buttonColor:s,buttonCheckedBgDisabled:c,buttonCheckedColorDisabled:l,buttonPaddingInline:r-i,wrapperMarginInlineEnd:n,radioColor:t?d:f,radioBgColor:t?a:d}},fue=Wr("Radio",e=>{const{controlOutline:t,controlOutlineWidth:r}=e,n=`0 0 0 ${ae(r)} ${t}`,o=$r(e,{radioFocusShadow:n,radioButtonFocusShadow:n});return[QBe(o),JBe(o),e$e(o)]},t$e,{unitless:{radioSize:!0,dotSize:!0}}),r$e=(e,t)=>{const r=y.useContext(uue),n=y.useContext(due),{getPrefixCls:i,direction:o,className:s,style:a,classNames:l,styles:c}=Nr("radio"),u=y.useRef(null),d=Wo(t,u),{isFormItemInput:h}=y.useContext(ua),p=$=>{var K,q;(K=e.onChange)==null||K.call(e,$),(q=r==null?void 0:r.onChange)==null||q.call(r,$)},{prefixCls:f,className:g,rootClassName:m,children:v,style:b,title:S,classNames:x,styles:E,...R}=e,T=i("radio",f),M=((r==null?void 0:r.optionType)||n)==="button",D=M?`${T}-button`:T,A=ho(T),[I,L]=fue(T,A),F={...R},k=y.useContext(hs);let O=F.checked;r&&(F.name=r.name,F.onChange=p,O=e.value===r.value,F.disabled=F.disabled??r.disabled),F.disabled=F.disabled??k;const B={...e,...F,checked:O},[H,N]=Vr([l,x],[c,E],{props:B}),z=Q(`${D}-wrapper`,{[`${D}-wrapper-checked`]:O,[`${D}-wrapper-disabled`]:F.disabled,[`${D}-wrapper-rtl`]:o==="rtl",[`${D}-wrapper-in-form-item`]:h,[`${D}-wrapper-block`]:!!(r!=null&&r.block)},s,g,m,H.root,I,L,A),[W,V]=pue(F.onClick);return y.createElement(kx,{component:"Radio",disabled:F.disabled},y.createElement("label",{className:z,style:{...N.root,...a,...b},onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:S,onClick:W},y.createElement(hue,{...F,checked:O,className:Q(H.icon,{[HD]:!M}),style:N.icon,type:"radio",prefixCls:D,ref:d,onClick:V}),v!==void 0?y.createElement("span",{className:Q(`${D}-label`,H.label),style:N.label},v):null))},wM=y.forwardRef(r$e),n$e=y.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n}=y.useContext(ir),{name:i}=y.useContext(ua),o=xc(XBe(i)),{prefixCls:s,className:a,rootClassName:l,options:c,buttonStyle:u="outline",disabled:d,children:h,size:p,style:f,id:g,optionType:m,name:v=o,defaultValue:b,value:S,block:x=!1,onChange:E,onMouseEnter:R,onMouseLeave:T,onFocus:M,onBlur:D,orientation:A,vertical:I,role:L="radiogroup"}=e,[F,k]=An(b,S),O=y.useCallback(Y=>{const oe=F,ee=Y.target.value;"value"in e||k(ee),ee!==oe&&(E==null||E(Y))},[F,k,E]),B=r("radio",s),H=`${B}-group`,N=ho(B),[z,W]=fue(B,N);let V=h;c&&c.length>0&&(V=c.map(Y=>typeof Y=="string"||typeof Y=="number"?y.createElement(wM,{key:Y.toString(),prefixCls:B,disabled:d,value:Y,checked:F===Y},Y):y.createElement(wM,{key:`radio-group-value-options-${Y.value}`,prefixCls:B,disabled:Y.disabled||d,value:Y.value,checked:F===Y.value,title:Y.title,style:Y.style,className:Y.className,id:Y.id,required:Y.required},Y.label)));const $=ki(p),[,K]=Fx(A,I),q=Q(H,`${H}-${u}`,{[`${H}-large`]:$==="large",[`${H}-small`]:$==="small",[`${H}-rtl`]:n==="rtl",[`${H}-block`]:x},a,l,z,W,N),X=y.useMemo(()=>({onChange:O,value:F,disabled:d,name:v,optionType:m,block:x}),[O,F,d,v,m,x]);return y.createElement("div",{...ai(e,{aria:!0,data:!0}),role:L,className:Q(q,{[`${B}-group-vertical`]:K}),style:f,onMouseEnter:R,onMouseLeave:T,onFocus:M,onBlur:D,id:g,ref:t},y.createElement(YBe,{value:X},V))}),i$e=y.memo(n$e),o$e=(e,t)=>{const{getPrefixCls:r}=y.useContext(ir),{prefixCls:n,...i}=e,o=r("radio",n);return y.createElement(ZBe,{value:"button"},y.createElement(wM,{prefixCls:o,...i,type:"radio",ref:t}))},s$e=y.forwardRef(o$e),Yx=wM;Yx.Button=s$e;Yx.Group=i$e;Yx.__ANT_RADIO=!0;function _C(e){return $r(e,{inputAffixPadding:e.paddingXXS})}const OC=e=>{const{controlHeight:t,fontSize:r,lineHeight:n,lineWidth:i,controlHeightSM:o,controlHeightLG:s,fontSizeLG:a,lineHeightLG:l,paddingSM:c,controlPaddingHorizontalSM:u,controlPaddingHorizontal:d,colorFillAlter:h,colorPrimaryHover:p,colorPrimary:f,controlOutlineWidth:g,controlOutline:m,colorErrorOutline:v,colorWarningOutline:b,colorBgContainer:S,inputFontSize:x,inputFontSizeLG:E,inputFontSizeSM:R}=e,T=x||r,M=R||T,D=E||a,A=Math.round((t-T*n)/2*10)/10-i,I=Math.round((o-M*n)/2*10)/10-i,L=Math.ceil((s-D*l)/2*10)/10-i;return{paddingBlock:Math.max(A,0),paddingBlockSM:Math.max(I,0),paddingBlockLG:Math.max(L,0),paddingInline:c-i,paddingInlineSM:u-i,paddingInlineLG:d-i,addonBg:h,activeBorderColor:f,hoverBorderColor:p,activeShadow:`0 0 0 ${g}px ${m}`,errorActiveShadow:`0 0 0 ${g}px ${v}`,warningActiveShadow:`0 0 0 ${g}px ${b}`,hoverBg:S,activeBg:S,inputFontSize:T,inputFontSizeLG:D,inputFontSizeSM:M}},a$e=e=>({borderColor:e.hoverBorderColor,backgroundColor:e.hoverBg}),tA=e=>({color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,boxShadow:"none",cursor:"not-allowed",opacity:1,"input[disabled], textarea[disabled]":{cursor:"not-allowed"},"&:hover:not([disabled])":{...a$e($r(e,{hoverBorderColor:e.colorBorder,hoverBg:e.colorBgContainerDisabled}))}}),b4=(e,t)=>({background:e.colorBgContainer,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:t.borderColor,"&:hover":{borderColor:t.hoverBorderColor,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:t.activeBorderColor,boxShadow:t.activeShadow,outline:0,backgroundColor:e.activeBg}}),_q=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...b4(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}},[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:t.borderColor}}),gue=(e,t)=>({"&-outlined":{...b4(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow}),[`&${e.componentCls}-disabled, &[disabled]`]:{...tA(e)},..._q(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError}),..._q(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning}),...t}}),Oq=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{borderColor:t.addonBorderColor,color:t.addonColor}}}),l$e=e=>({"&-outlined":{[`${e.componentCls}-group`]:{"&-addon":{background:e.addonBg,border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}},...Oq(e,{status:"error",addonBorderColor:e.colorError,addonColor:e.colorErrorText}),...Oq(e,{status:"warning",addonBorderColor:e.colorWarning,addonColor:e.colorWarningText}),[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group-addon`]:{...tA(e)}}}}),mue=(e,t)=>{const{componentCls:r}=e;return{"&-borderless":{background:"transparent",border:"none",paddingBlock:e.calc(e.paddingBlock).add(e.lineWidth).equal(),[`&${r}-sm, &${r}-affix-wrapper-sm`]:{paddingBlock:e.calc(e.paddingBlockSM).add(e.lineWidth).equal()},[`&${r}-lg, &${r}-affix-wrapper-lg`]:{paddingBlock:e.calc(e.paddingBlockLG).add(e.lineWidth).equal()},"&:focus, &:focus-within":{outline:"none"},[`&${r}-disabled, &[disabled]`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${r}-status-error`]:{"&, & input, & textarea":{color:e.colorError}},[`&${r}-status-warning`]:{"&, & input, & textarea":{color:e.colorWarning}},...t}}},vue=(e,t)=>({background:t.bg,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:"transparent","input&, & input, textarea&, & textarea":{color:(t==null?void 0:t.inputColor)??"unset"},"&:hover":{background:t.hoverBg},"&:focus, &:focus-within":{outline:0,borderColor:t.activeBorderColor,backgroundColor:e.activeBg}}),kq=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...vue(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}}}),yue=(e,t)=>({"&-filled":{...vue(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor,inputColor:e.colorText}),[`&${e.componentCls}-disabled, &[disabled]`]:{...tA(e)},...kq(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,inputColor:e.colorErrorText,affixColor:e.colorError}),...kq(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,inputColor:e.colorWarningText,affixColor:e.colorWarning}),...t}}),Nq=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{background:t.addonBg,color:t.addonColor}}}),c$e=e=>({"&-filled":{[`${e.componentCls}-group-addon`]:{background:e.colorFillTertiary,"&:last-child":{position:"static"}},...Nq(e,{status:"error",addonBg:e.colorErrorBg,addonColor:e.colorErrorText}),...Nq(e,{status:"warning",addonBg:e.colorWarningBg,addonColor:e.colorWarningText}),[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group`]:{"&-addon":{background:e.colorFillTertiary,color:e.colorTextDisabled},"&-addon:first-child":{borderInlineStart:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:last-child":{borderInlineEnd:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`}}}}}),Cue=(e,t)=>({background:e.colorBgContainer,borderWidth:`${ae(e.lineWidth)} 0`,borderStyle:`${e.lineType} none`,borderColor:`transparent transparent ${t.borderColor} transparent`,borderRadius:0,"&:hover":{borderColor:`transparent transparent ${t.hoverBorderColor} transparent`,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:`transparent transparent ${t.activeBorderColor} transparent`,outline:0,backgroundColor:e.activeBg}}),Bq=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...Cue(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}},[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:`transparent transparent ${t.borderColor} transparent`}}),bue=(e,t)=>({"&-underlined":{...Cue(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow}),[`&${e.componentCls}-disabled, &[disabled]`]:{color:e.colorTextDisabled,boxShadow:"none",cursor:"not-allowed","&:hover":{borderColor:`transparent transparent ${e.colorBorder} transparent`}},"input[disabled], textarea[disabled]":{cursor:"not-allowed"},...Bq(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError}),...Bq(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning}),...t}}),Sue=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),S4=e=>{const{paddingBlockLG:t,lineHeightLG:r,borderRadiusLG:n,paddingInlineLG:i}=e;return{padding:`${ae(t)} ${ae(i)}`,fontSize:e.inputFontSizeLG,lineHeight:r,borderRadius:n}},w4=e=>({padding:`${ae(e.paddingBlockSM)} ${ae(e.paddingInlineSM)}`,fontSize:e.inputFontSizeSM,borderRadius:e.borderRadiusSM}),rA=(e,t={})=>({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:`${ae(e.paddingBlock)} ${ae(e.paddingInline)}`,color:e.colorText,fontSize:e.inputFontSize,lineHeight:e.lineHeight,borderRadius:e.borderRadius,transition:`all ${e.motionDurationMid}`,...Sue(e.colorTextPlaceholder),"&-lg":{...S4(e),...t.largeStyle},"&-sm":{...w4(e),...t.smallStyle},"&-rtl, &-textarea-rtl":{direction:"rtl"}}),u$e=e=>{const{componentCls:t,antCls:r}=e;return{position:"relative",display:"table",width:"100%",borderCollapse:"separate",borderSpacing:0,"&[class*='col-']":{paddingInlineEnd:e.paddingXS,"&:last-child":{paddingInlineEnd:0}},[`&-lg ${t}, &-lg > ${t}-group-addon`]:{...S4(e)},[`&-sm ${t}, &-sm > ${t}-group-addon`]:{...w4(e)},[`&-lg ${r}-select-single`]:{height:e.controlHeightLG},[`&-sm ${r}-select-single`]:{height:e.controlHeightSM},[`> ${t}`]:{display:"table-cell","&:not(:first-child):not(:last-child)":{borderRadius:0}},[`${t}-group`]:{"&-addon, &-wrap":{display:"table-cell",width:1,whiteSpace:"nowrap",verticalAlign:"middle","&:not(:first-child):not(:last-child)":{borderRadius:0}},"&-wrap > *":{display:"block !important"},"&-addon":{position:"relative",padding:`0 ${ae(e.paddingInline)}`,color:e.colorText,fontWeight:"normal",fontSize:e.inputFontSize,textAlign:"center",borderRadius:e.borderRadius,transition:`all ${e.motionDurationSlow}`,lineHeight:1,[`${r}-select`]:{margin:`${ae(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${ae(e.calc(e.paddingInline).mul(-1).equal())}`,[`&${r}-select-single:not(${r}-select-customize-input):not(${r}-pagination-size-changer)`]:{backgroundColor:"inherit",border:`${ae(e.lineWidth)} ${e.lineType} transparent`,boxShadow:"none"}},[`${r}-cascader-picker`]:{margin:`-9px ${ae(e.calc(e.paddingInline).mul(-1).equal())}`,backgroundColor:"transparent",[`${r}-cascader-input`]:{textAlign:"start",border:0,boxShadow:"none"}}}},[t]:{width:"100%",marginBottom:0,textAlign:"inherit","&:focus":{zIndex:1,borderInlineEndWidth:1},"&:hover":{zIndex:1,borderInlineEndWidth:1}},[`> ${t}:first-child, ${t}-group-addon:first-child`]:{borderStartEndRadius:0,borderEndEndRadius:0,[`${r}-select`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}-affix-wrapper`]:{[`&:not(:first-child) ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0},[`&:not(:last-child) ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}:last-child, ${t}-group-addon:last-child`]:{borderStartStartRadius:0,borderEndStartRadius:0,[`${r}-select`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`${t}-affix-wrapper`]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0},"&:not(:first-child)":{borderStartStartRadius:0,borderEndStartRadius:0}},[`&${t}-group-compact`]:{display:"block",...fu(),[`${t}-group-addon, ${t}-group-wrap, > ${t}`]:{"&:not(:first-child):not(:last-child)":{borderInlineEndWidth:e.lineWidth,"&:hover, &:focus":{zIndex:1}}},"& > *":{display:"inline-flex",float:"none",verticalAlign:"top",borderRadius:0},[` & > ${t}-affix-wrapper, & > ${t}-number-affix-wrapper, & > ${r}-picker-range `]:{display:"inline-flex"},"& > *:not(:last-child)":{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderInlineEndWidth:e.lineWidth},[t]:{float:"none"},[`& > ${r}-select, & > ${r}-select-auto-complete ${t}, & > ${r}-cascader-picker ${t}, & > ${t}-group-wrapper ${t}`]:{borderInlineEndWidth:e.lineWidth,borderRadius:0,"&:hover, &:focus":{zIndex:1}},[`& > ${r}-select-focused`]:{zIndex:1},[`& > ${r}-select > ${r}-select-arrow`]:{zIndex:1},[`& > *:first-child, & > ${r}-select:first-child, & > ${r}-select-auto-complete:first-child ${t}, & > ${r}-cascader-picker:first-child ${t}`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius},[`& > *:last-child, & > ${r}-select:last-child, & > ${r}-cascader-picker:last-child ${t}, & > ${r}-cascader-picker-focused:last-child ${t}`]:{borderInlineEndWidth:e.lineWidth,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius},[`& > ${r}-select-auto-complete ${t}`]:{verticalAlign:"top"},[`${t}-group-wrapper + ${t}-group-wrapper`]:{marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),[`${t}-affix-wrapper`]:{}}}}},d$e=e=>{const{componentCls:t,controlHeightSM:r,lineWidth:n,calc:i}=e,s=i(r).sub(i(n).mul(2)).sub(16).div(2).equal();return{[t]:{...on(e),...rA(e),...gue(e),...yue(e),...mue(e),...bue(e),'&[type="color"]':{height:e.controlHeight,[`&${t}-lg`]:{height:e.controlHeightLG},[`&${t}-sm`]:{height:r,paddingTop:s,paddingBottom:s}},'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration':{appearance:"none"}}}},h$e=e=>{const{componentCls:t}=e;return{[`${t}-clear-icon`]:{margin:0,padding:0,lineHeight:0,color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,verticalAlign:-1,cursor:"pointer",transition:`color ${e.motionDurationSlow}`,border:"none",outline:"none",backgroundColor:"transparent","&:hover":{color:e.colorIcon},"&:active":{color:e.colorText},"&-hidden":{visibility:"hidden"},"&-has-suffix":{margin:`0 ${ae(e.inputAffixPadding)}`}}}},p$e=e=>{const{componentCls:t,inputAffixPadding:r,colorTextDescription:n,motionDurationSlow:i,colorIcon:o,colorIconHover:s,iconCls:a}=e,l=`${t}-affix-wrapper`,c=`${t}-affix-wrapper-disabled`;return{[l]:{...rA(e),display:"inline-flex","&-focused, &:focus":{zIndex:1},[`> input${t}`]:{padding:0},[`> input${t}, > textarea${t}`]:{fontSize:"inherit",border:"none",borderRadius:0,outline:"none",background:"transparent",color:"inherit","&::-ms-reveal":{display:"none"},"&:focus":{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[t]:{"&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center","> *:not(:last-child)":{marginInlineEnd:e.paddingXS}},"&-show-count-suffix":{color:n,direction:"ltr"},"&-show-count-has-suffix":{marginInlineEnd:e.paddingXXS},"&-prefix":{marginInlineEnd:r},"&-suffix":{marginInlineStart:r}},...h$e(e),[`${a}${t}-password-icon`]:{color:o,cursor:"pointer",transition:`all ${i}`,"&:hover":{color:s}}},[`${t}-underlined`]:{borderRadius:0},[c]:{[`${a}${t}-password-icon`]:{color:o,cursor:"not-allowed","&:hover":{color:o}}}}},f$e=e=>{const{componentCls:t,borderRadiusLG:r,borderRadiusSM:n}=e;return{[`${t}-group`]:{...on(e),...u$e(e),"&-rtl":{direction:"rtl"},"&-wrapper":{display:"inline-block",width:"100%",textAlign:"start",verticalAlign:"top","&-rtl":{direction:"rtl"},"&-lg":{[`${t}-group-addon`]:{borderRadius:r,fontSize:e.inputFontSizeLG}},"&-sm":{[`${t}-group-addon`]:{borderRadius:n}},...l$e(e),...c$e(e),[`&:not(${t}-compact-first-item):not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}, ${t}-group-addon`]:{borderRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-first-item`]:{[`${t}, ${t}-group-addon`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-last-item`]:{[`${t}, ${t}-group-addon`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}}},g$e=e=>{const{componentCls:t}=e;return{[`${t}-out-of-range`]:{[`&, & input, & textarea, ${t}-show-count-suffix, ${t}-data-count`]:{color:e.colorError}}}},wue=Wr(["Input","Shared"],e=>{const t=$r(e,_C(e));return[d$e(t),p$e(t)]},OC,{resetFont:!1}),xue=Wr(["Input","Component"],e=>{const t=$r(e,_C(e));return[f$e(t),g$e(t),Bx(t,{focus:!0,focusElCls:`${t.componentCls}-affix-wrapper-focused`})]},OC,{resetFont:!1});var m$e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"};function W$(){return W$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,W$({},e,{ref:t,icon:m$e})),Eue=y.forwardRef(v$e);var aS={exports:{}},$q;function y$e(){if($q)return aS.exports;$q=1,aS.exports=n,aS.exports.isMobile=n,aS.exports.default=n;const e=/(android|bb\d+|meego).+mobile|armv7l|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|redmi|series[46]0|samsungbrowser.*mobile|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i,t=/CrOS/,r=/android|ipad|playbook|silk/i;function n(i){i||(i={});let o=i.ua;if(!o&&typeof navigator<"u"&&(o=navigator.userAgent),o&&o.headers&&typeof o.headers["user-agent"]=="string"&&(o=o.headers["user-agent"]),typeof o!="string")return!1;let s=e.test(o)&&!t.test(o)||!!i.tablet&&r.test(o);return!s&&i.tablet&&i.featureDetect&&navigator&&navigator.maxTouchPoints>1&&o.indexOf("Macintosh")!==-1&&o.indexOf("Safari")!==-1&&(s=!0),s}return aS.exports}var C$e=y$e();const b$e=Sx(C$e);let rO;const S$e=(()=>(typeof rO>"u"&&(rO=b$e()),rO)),x4=y.createContext(null),w$e=e=>{const{activeTabOffset:t,horizontal:r,rtl:n,indicator:i={}}=e,{size:o,align:s="center"}=i,[a,l]=y.useState(),c=y.useRef(),u=Z.useCallback(h=>typeof o=="function"?o(h):typeof o=="number"?o:h,[o]);function d(){Or.cancel(c.current)}return y.useEffect(()=>{const h={};if(t)if(r){h.width=u(t.width);const p=n?"right":"left";s==="start"&&(h[p]=t[p]),s==="center"&&(h[p]=t[p]+t.width/2,h.transform=n?"translateX(50%)":"translateX(-50%)"),s==="end"&&(h[p]=t[p]+t.width,h.transform="translateX(-100%)")}else h.height=u(t.height),s==="start"&&(h.top=t.top),s==="center"&&(h.top=t.top+t.height/2,h.transform="translateY(-50%)"),s==="end"&&(h.top=t.top+t.height,h.transform="translateY(-100%)");return d(),c.current=Or(()=>{a&&h&&Object.keys(h).every(f=>{const g=h[f],m=a[f];return typeof g=="number"&&typeof m=="number"?Math.round(g)===Math.round(m):g===m})||l(h)}),d},[JSON.stringify(t),r,n,s,u]),{style:a}},Gq={width:0,height:0,left:0,top:0};function x$e(e,t,r){return y.useMemo(()=>{var s,a;const n=new Map,i=t.get((s=e[0])==null?void 0:s.key)||Gq,o=i.left+i.width;for(let l=0;ln.key).join("_"),t,r])}function Vq(e,t){const r=y.useRef(e),[,n]=y.useState({});function i(o){const s=typeof o=="function"?o(r.current):o;s!==r.current&&t(s,r.current),r.current=s,n({})}return[r.current,i]}const E$e=.1,zq=.01,fP=20,Hq=.995**fP;function T$e(e,t){const[r,n]=y.useState(),[i,o]=y.useState(0),[s,a]=y.useState(0),[l,c]=y.useState(),u=y.useRef();function d(v){const{screenX:b,screenY:S}=v.touches[0];n({x:b,y:S}),window.clearInterval(u.current)}function h(v){if(!r)return;const{screenX:b,screenY:S}=v.touches[0];n({x:b,y:S});const x=b-r.x,E=S-r.y;t(x,E);const R=Date.now();o(R),a(R-i),c({x,y:E})}function p(){if(r&&(n(null),c(null),l)){const v=l.x/s,b=l.y/s,S=Math.abs(v),x=Math.abs(b);if(Math.max(S,x){if(Math.abs(E)R?(x=b,f.current="x"):(x=S,f.current="y"),t(-x,-x)&&v.preventDefault()}const m=y.useRef(null);m.current={onTouchStart:d,onTouchMove:h,onTouchEnd:p,onWheel:g},y.useEffect(()=>{function v(E){m.current.onTouchStart(E)}function b(E){m.current.onTouchMove(E)}function S(E){m.current.onTouchEnd(E)}function x(E){m.current.onWheel(E)}return document.addEventListener("touchmove",b,{passive:!1}),document.addEventListener("touchend",S,{passive:!0}),e.current.addEventListener("touchstart",v,{passive:!0}),e.current.addEventListener("wheel",x,{passive:!1}),()=>{document.removeEventListener("touchmove",b),document.removeEventListener("touchend",S)}},[])}function Tue(e){const[t,r]=y.useState(0),n=y.useRef(0),i=y.useRef();return i.current=e,iP(()=>{var o;(o=i.current)==null||o.call(i)},[t]),()=>{n.current===t&&(n.current+=1,r(n.current))}}function R$e(e){const t=y.useRef([]),[,r]=y.useState({}),n=y.useRef(typeof e=="function"?e():e),i=Tue(()=>{let s=n.current;t.current.forEach(a=>{s=a(s)}),t.current=[],n.current=s,r({})});function o(s){t.current.push(s),i()}return[n.current,o]}const Wq={width:0,height:0,left:0,top:0,right:0};function P$e(e,t,r,n,i,o,{tabs:s,tabPosition:a,rtl:l}){let c,u,d;return["top","bottom"].includes(a)?(c="width",u=l?"right":"left",d=Math.abs(r)):(c="height",u="top",d=-r),y.useMemo(()=>{if(!s.length)return[0,0];const h=s.length;let p=h;for(let g=0;gMath.floor(d+t)){p=g-1;break}}let f=0;for(let g=h-1;g>=0;g-=1)if((e.get(s[g].key)||Wq)[u]p?[0,-1]:[f,p]},[e,t,n,i,o,d,a,s.map(h=>h.key).join("_"),l])}function Uq(e){let t;return e instanceof Map?(t={},e.forEach((r,n)=>{t[n]=r})):t=e,JSON.stringify(t)}const M$e="TABS_DQ";function Rue(e){return String(e).replace(/"/g,M$e)}function E4(e,t,r,n){return!(!r||n||e===!1||e===void 0&&(t===!1||t===null))}const Pue=y.forwardRef((e,t)=>{const{prefixCls:r,editable:n,locale:i,style:o}=e;return!n||n.showAdd===!1?null:y.createElement("button",{ref:t,type:"button",className:`${r}-nav-add`,style:o,"aria-label":(i==null?void 0:i.addAriaLabel)||"Add tab",onClick:s=>{n.onEdit("add",{event:s})}},n.addIcon||"+")}),jq=y.forwardRef((e,t)=>{const{position:r,prefixCls:n,extra:i}=e;if(!i)return null;let o,s={};return typeof i=="object"&&!y.isValidElement(i)?s=i:s.right=i,r==="right"&&(o=s.right),r==="left"&&(o=s.left),o?y.createElement("div",{className:`${n}-extra-content`,ref:t},o):null});function U$(){return U$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,id:n,tabs:i,locale:o,mobile:s,more:a={},style:l,className:c,editable:u,tabBarGutter:d,rtl:h,removeAriaLabel:p,onTabClick:f,getPopupContainer:g,popupClassName:m,popupStyle:v}=e,[b,S]=y.useState(!1),[x,E]=y.useState(null),{icon:R="More"}=a,T=`${n}-more-popup`,M=`${r}-dropdown`,D=x!==null?`${T}-${x}`:null,A=o==null?void 0:o.dropdownAriaLabel;function I(N,z){N.preventDefault(),N.stopPropagation(),u.onEdit("remove",{key:z,event:N})}const L=y.createElement(FC,{onClick:({key:N,domEvent:z})=>{f(N,z),S(!1)},prefixCls:`${M}-menu`,id:T,tabIndex:-1,role:"listbox","aria-activedescendant":D,selectedKeys:[x],"aria-label":A!==void 0?A:"expanded dropdown"},i.map(N=>{const{closable:z,disabled:W,closeIcon:V,key:$,label:K}=N,q=E4(z,V,u,W);return y.createElement(qx,{key:$,id:`${T}-${$}`,role:"option","aria-controls":n&&`${n}-panel-${$}`,disabled:W},y.createElement("span",null,K),q&&y.createElement("button",{type:"button","aria-label":p||"remove",tabIndex:0,className:`${M}-menu-item-remove`,onClick:X=>{X.stopPropagation(),I(X,$)}},V||u.removeIcon||"×"))}));function F(N){const z=i.filter($=>!$.disabled);let W=z.findIndex($=>$.key===x)||0;const V=z.length;for(let $=0;${const N=document.getElementById(D);N!=null&&N.scrollIntoView&&N.scrollIntoView(!1)},[D,x]),y.useEffect(()=>{b||E(null)},[b]);const O={marginInlineStart:d};i.length||(O.visibility="hidden",O.order=1);const B=Q(m,{[`${M}-rtl`]:h}),H=s?null:y.createElement(zce,U$({prefixCls:M,overlay:L,visible:i.length?b:!1,onVisibleChange:S,overlayClassName:B,overlayStyle:v,mouseEnterDelay:.1,mouseLeaveDelay:.1,getPopupContainer:g},a),y.createElement("button",{type:"button",className:`${r}-nav-more`,style:O,"aria-haspopup":"listbox","aria-controls":T,id:`${n}-more`,"aria-expanded":b,onKeyDown:k},R));return y.createElement("div",{className:Q(`${r}-nav-operations`,c),style:l,ref:t},H,y.createElement(Pue,{prefixCls:r,locale:o,editable:u}))}),D$e=y.memo(I$e,(e,t)=>t.tabMoving),A$e=e=>{const{prefixCls:t,id:r,active:n,focus:i,tab:{key:o,label:s,disabled:a,closeIcon:l,icon:c},closable:u,renderWrapper:d,removeAriaLabel:h,editable:p,onClick:f,onFocus:g,onBlur:m,onKeyDown:v,onMouseDown:b,onMouseUp:S,style:x,className:E,tabCount:R,currentPosition:T}=e,M=`${t}-tab`,D=E4(u,l,p,a);function A(O){a||f(O)}function I(O){O.preventDefault(),O.stopPropagation(),p.onEdit("remove",{key:o,event:O})}const L=y.useMemo(()=>c&&typeof s=="string"?y.createElement("span",null,s):s,[s,c]),F=y.useRef(null);y.useEffect(()=>{i&&F.current&&F.current.focus()},[i]);const k=y.createElement("div",{key:o,"data-node-key":Rue(o),className:Q(M,E,{[`${M}-with-remove`]:D,[`${M}-active`]:n,[`${M}-disabled`]:a,[`${M}-focus`]:i}),style:x,onClick:A},y.createElement("div",{ref:F,role:"tab","aria-selected":n,id:r&&`${r}-tab-${o}`,className:`${M}-btn`,"aria-controls":r&&`${r}-panel-${o}`,"aria-disabled":a,tabIndex:a?null:n?0:-1,onClick:O=>{O.stopPropagation(),A(O)},onKeyDown:v,onMouseDown:b,onMouseUp:S,onFocus:g,onBlur:m},i&&y.createElement("div",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},`Tab ${T} of ${R}`),c&&y.createElement("span",{className:`${M}-icon`},c),s&&L),D&&y.createElement("button",{type:"button","aria-label":h||"remove",tabIndex:n?0:-1,className:`${M}-remove`,onClick:O=>{O.stopPropagation(),I(O)}},l||p.removeIcon||"×"));return d?d(k):k};function j$(){return j$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{offsetWidth:r,offsetHeight:n,offsetTop:i,offsetLeft:o}=e,{width:s,height:a,left:l,top:c}=e.getBoundingClientRect();return Math.abs(s-r)<1?[s,a,l-t.left,c-t.top]:[r,n,o,i]},wv=e=>{const{offsetWidth:t=0,offsetHeight:r=0}=e.current||{};if(e.current){const{width:n,height:i}=e.current.getBoundingClientRect();if(Math.abs(n-t)<1)return[n,i]}return[t,r]},cT=(e,t)=>e[t?0:1],Kq=y.forwardRef((e,t)=>{const{className:r,style:n,id:i,animated:o,activeKey:s,rtl:a,extra:l,editable:c,locale:u,tabPosition:d,tabBarGutter:h,children:p,onTabClick:f,onTabScroll:g,indicator:m,classNames:v,styles:b}=e,{prefixCls:S,tabs:x}=y.useContext(x4),E=y.useRef(null),R=y.useRef(null),T=y.useRef(null),M=y.useRef(null),D=y.useRef(null),A=y.useRef(null),I=y.useRef(null),L=d==="top"||d==="bottom",[F,k]=Vq(0,(Oe,se)=>{L&&g&&g({direction:Oe>se?"left":"right"})}),[O,B]=Vq(0,(Oe,se)=>{!L&&g&&g({direction:Oe>se?"top":"bottom"})}),[H,N]=y.useState([0,0]),[z,W]=y.useState([0,0]),[V,$]=y.useState([0,0]),[K,q]=y.useState([0,0]),[X,Y]=R$e(new Map),oe=x$e(x,X,z[0]),ee=cT(H,L),ne=cT(z,L),le=cT(V,L),he=cT(K,L),re=Math.floor(ee)ue?ue:Oe}const pe=y.useRef(null),[me,ke]=y.useState();function De(){ke(Date.now())}function Ee(){pe.current&&clearTimeout(pe.current)}T$e(M,(Oe,se)=>{function ce(fe,Te){fe($e=>ve($e+Te))}return re?(L?ce(k,Oe):ce(B,se),Ee(),De(),!0):!1}),y.useEffect(()=>(Ee(),me&&(pe.current=setTimeout(()=>{ke(0)},100)),Ee),[me]);const[We,ze]=P$e(oe,ie,L?F:O,ne,le,he,{...e,tabs:x}),mt=br((Oe=s)=>{const se=oe.get(Oe)||{width:0,height:0,left:0,right:0,top:0};if(L){let ce=F;a?se.rightF+ie&&(ce=se.right+se.width-ie):se.left<-F?ce=-se.left:se.left+se.width>-F+ie&&(ce=-(se.left+se.width-ie)),B(0),k(ve(ce))}else{let ce=O;se.top<-O?ce=-se.top:se.top+se.height>-O+ie&&(ce=-(se.top+se.height-ie)),k(0),B(ve(ce))}}),[Nt,St]=y.useState(),[Ze,Fe]=y.useState(!1),tt=x.filter(Oe=>!Oe.disabled).map(Oe=>Oe.key),Ne=Oe=>{const se=tt.indexOf(Nt||s),ce=tt.length,fe=(se+Oe+ce)%ce,Te=tt[fe];St(Te)},rt=(Oe,se)=>{const ce=tt.indexOf(Oe),fe=x.find($e=>$e.key===Oe);E4(fe==null?void 0:fe.closable,fe==null?void 0:fe.closeIcon,c,fe==null?void 0:fe.disabled)&&(se.preventDefault(),se.stopPropagation(),c.onEdit("remove",{key:Oe,event:se}),ce===tt.length-1?Ne(-1):Ne(1))},ot=(Oe,se)=>{Fe(!0),se.button===1&&rt(Oe,se)},Ye=Oe=>{const{code:se}=Oe,ce=a&&L,fe=tt[0],Te=tt[tt.length-1];switch(se){case"ArrowLeft":{L&&Ne(ce?1:-1);break}case"ArrowRight":{L&&Ne(ce?-1:1);break}case"ArrowUp":{Oe.preventDefault(),L||Ne(-1);break}case"ArrowDown":{Oe.preventDefault(),L||Ne(1);break}case"Home":{Oe.preventDefault(),St(fe);break}case"End":{Oe.preventDefault(),St(Te);break}case"Enter":case"Space":{Oe.preventDefault(),f(Nt??s,Oe);break}case"Backspace":case"Delete":{rt(Nt,Oe);break}}},Ae={};L?Ae.marginInlineStart=h:Ae.marginTop=h;const nt=x.map((Oe,se)=>{const{key:ce}=Oe;return y.createElement(A$e,{id:i,prefixCls:S,key:ce,tab:Oe,className:v==null?void 0:v.item,style:se===0?b==null?void 0:b.item:{...Ae,...b==null?void 0:b.item},closable:Oe.closable,editable:c,active:ce===s,focus:ce===Nt,renderWrapper:p,removeAriaLabel:u==null?void 0:u.removeAriaLabel,tabCount:tt.length,currentPosition:se+1,onClick:fe=>{f(ce,fe)},onKeyDown:Ye,onFocus:()=>{Ze||St(ce),mt(ce),De(),M.current&&(a||(M.current.scrollLeft=0),M.current.scrollTop=0)},onBlur:()=>{St(void 0)},onMouseDown:fe=>ot(ce,fe),onMouseUp:()=>{Fe(!1)}})}),Et=()=>Y(()=>{var ce;const Oe=new Map,se=(ce=D.current)==null?void 0:ce.getBoundingClientRect();return x.forEach(({key:fe})=>{var $e;const Te=($e=D.current)==null?void 0:$e.querySelector(`[data-node-key="${Rue(fe)}"]`);if(Te){const[et,Dt,ct,st]=F$e(Te,se);Oe.set(fe,{width:et,height:Dt,left:ct,top:st})}}),Oe});y.useEffect(()=>{Et()},[x.map(Oe=>Oe.key).join("_")]);const Tt=Tue(()=>{const Oe=wv(E),se=wv(R),ce=wv(T);N([Oe[0]-se[0]-ce[0],Oe[1]-se[1]-ce[1]]);const fe=wv(I);$(fe);const Te=wv(A);q(Te);const $e=wv(D);W([$e[0]-fe[0],$e[1]-fe[1]]),Et()}),kt=x.slice(0,We),Wt=x.slice(ze+1),at=[...kt,...Wt],lt=oe.get(s),{style:Ut}=w$e({activeTabOffset:lt,horizontal:L,indicator:m,rtl:a});y.useEffect(()=>{mt()},[s,J,ue,Uq(lt),Uq(oe),L]),y.useEffect(()=>{Tt()},[a]);const cr=!!at.length,_e=`${S}-nav-wrap`;let qe,Re,it,Ve;return L?a?(Re=F>0,qe=F!==ue):(qe=F<0,Re=F!==J):(it=O<0,Ve=O!==J),y.createElement(ta,{onResize:Tt},y.createElement("div",{ref:Pu(t,E),role:"tablist","aria-orientation":L?"horizontal":"vertical",className:Q(`${S}-nav`,r,v==null?void 0:v.header),style:{...b==null?void 0:b.header,...n},onKeyDown:()=>{De()}},y.createElement(jq,{ref:R,position:"left",extra:l,prefixCls:S}),y.createElement(ta,{onResize:Tt},y.createElement("div",{className:Q(_e,{[`${_e}-ping-left`]:qe,[`${_e}-ping-right`]:Re,[`${_e}-ping-top`]:it,[`${_e}-ping-bottom`]:Ve}),ref:M},y.createElement(ta,{onResize:Tt},y.createElement("div",{ref:D,className:`${S}-nav-list`,style:{transform:`translate(${F}px, ${O}px)`,transition:me?"none":void 0}},nt,y.createElement(Pue,{ref:I,prefixCls:S,locale:u,editable:c,style:{...nt.length===0?void 0:Ae,visibility:cr?"hidden":null}}),y.createElement("div",{className:Q(`${S}-ink-bar`,v==null?void 0:v.indicator,{[`${S}-ink-bar-animated`]:o.inkBar}),style:{...Ut,...b==null?void 0:b.indicator}}))))),y.createElement(D$e,j$({},e,{removeAriaLabel:u==null?void 0:u.removeAriaLabel,ref:A,prefixCls:S,tabs:at,className:!cr&&de,popupStyle:b==null?void 0:b.popup,tabMoving:!!me})),y.createElement(jq,{ref:T,position:"right",extra:l,prefixCls:S})))}),L$e=({renderTabBar:e,...t})=>e?e(t,Kq):y.createElement(Kq,t),_$e=y.forwardRef((e,t)=>{const{prefixCls:r,className:n,style:i,id:o,active:s,tabKey:a,children:l}=e,c=y.Children.count(l)>0;return y.createElement("div",{id:o&&`${o}-panel-${a}`,role:"tabpanel",tabIndex:s&&c?0:-1,"aria-labelledby":o&&`${o}-tab-${a}`,"aria-hidden":!s,style:i,className:Q(r,s&&`${r}-active`,n),ref:t},l)});function xM(){return xM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{id:t,activeKey:r,animated:n,tabPosition:i,destroyOnHidden:o,contentStyle:s,contentClassName:a}=e,{prefixCls:l,tabs:c}=y.useContext(x4),u=n.tabPane,d=`${l}-tabpane`;return y.createElement("div",{className:Q(`${l}-content-holder`)},y.createElement("div",{className:Q(`${l}-content`,`${l}-content-${i}`,{[`${l}-content-animated`]:u})},c.map(h=>{const{key:p,forceRender:f,style:g,className:m,destroyOnHidden:v,...b}=h,S=p===r;return y.createElement(gu,xM({key:p,visible:S,forceRender:f,removeOnLeave:!!(o??v),leavedClassName:`${d}-hidden`},n.tabPaneMotion),({style:x,className:E},R)=>y.createElement(_$e,xM({},b,{prefixCls:d,id:t,tabKey:p,animated:u,active:S,style:{...s,...g,...x},className:Q(a,m,E),ref:R})))})))};function k$e(e={inkBar:!0,tabPane:!1}){let t;return e===!1?t={inkBar:!1,tabPane:!1}:e===!0?t={inkBar:!0,tabPane:!1}:t={inkBar:!0,...typeof e=="object"?e:{}},t.tabPaneMotion&&t.tabPane===void 0&&(t.tabPane=!0),!t.tabPaneMotion&&t.tabPane&&(t.tabPane=!1),t}function Fw(){return Fw=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var oe;const{id:r,prefixCls:n="rc-tabs",className:i,items:o,direction:s,activeKey:a,defaultActiveKey:l,editable:c,animated:u,tabPosition:d="top",tabBarGutter:h,tabBarStyle:p,tabBarExtraContent:f,locale:g,more:m,destroyOnHidden:v,renderTabBar:b,onChange:S,onTabClick:x,onTabScroll:E,getPopupContainer:R,popupClassName:T,indicator:M,classNames:D,styles:A,...I}=e,L=y.useMemo(()=>(o||[]).filter(ee=>ee&&typeof ee=="object"&&"key"in ee),[o]),F=s==="rtl",k=k$e(u),[O,B]=y.useState(!1);y.useEffect(()=>{B(S$e())},[]);const[H,N]=An(l??((oe=L[0])==null?void 0:oe.key),a),[z,W]=y.useState(()=>L.findIndex(ee=>ee.key===H));y.useEffect(()=>{var ne;let ee=L.findIndex(le=>le.key===H);ee===-1&&(ee=Math.max(0,Math.min(z,L.length-1)),N((ne=L[ee])==null?void 0:ne.key)),W(ee)},[L.map(ee=>ee.key).join("_"),H,z]);const[V,$]=An(null,r);y.useEffect(()=>{r||($(`rc-tabs-${qq}`),qq+=1)},[]);function K(ee,ne){x==null||x(ee,ne);const le=ee!==H;N(ee),le&&(S==null||S(ee))}const q={id:V,activeKey:H,animated:k,tabPosition:d,rtl:F,mobile:O},X={...q,editable:c,locale:g,more:m,tabBarGutter:h,onTabClick:K,onTabScroll:E,extra:f,style:p,getPopupContainer:R,popupClassName:Q(T,D==null?void 0:D.popup),indicator:M,styles:A,classNames:D},Y=y.useMemo(()=>({tabs:L,prefixCls:n}),[L,n]);return y.createElement(x4.Provider,{value:Y},y.createElement("div",Fw({ref:t,id:r,className:Q(n,`${n}-${d}`,{[`${n}-mobile`]:O,[`${n}-editable`]:c,[`${n}-rtl`]:F},i)},I),y.createElement(L$e,Fw({},X,{renderTabBar:b})),y.createElement(O$e,Fw({destroyOnHidden:v},q,{contentStyle:A==null?void 0:A.content,contentClassName:D==null?void 0:D.content,animated:k}))))}),B$e={motionAppear:!1,motionEnter:!0,motionLeave:!0};function $$e(e,t={inkBar:!0,tabPane:!1}){let r;return t===!1?r={inkBar:!1,tabPane:!1}:t===!0?r={inkBar:!0,tabPane:!0}:r={inkBar:!0,...typeof t=="object"?t:{}},r.tabPane&&(r.tabPaneMotion={...B$e,motionName:mu(e,"switch")}),r}function G$e(e){return e.filter(t=>t)}function V$e(e,t){if(e)return e.map(n=>({...n,destroyOnHidden:n.destroyOnHidden??n.destroyInactiveTabPane}));const r=Li(t).map(n=>{if(y.isValidElement(n)){const{key:i,props:o}=n,{tab:s,...a}=o||{};return{key:String(i),...a,label:s}}return null});return G$e(r)}const z$e=e=>{const{componentCls:t,motionDurationSlow:r}=e;return[{[t]:{[`${t}-switch`]:{"&-appear, &-enter":{transition:"none","&-start":{opacity:0},"&-active":{opacity:1,transition:`opacity ${r}`}},"&-leave":{position:"absolute",transition:"none",inset:0,"&-start":{opacity:1},"&-active":{opacity:0,transition:`opacity ${r}`}}}}},[Tp(e,"slide-up"),Tp(e,"slide-down")]]},H$e=e=>{const{componentCls:t,tabsCardPadding:r,cardBg:n,cardGutter:i,colorBorderSecondary:o,itemSelectedColor:s}=e;return{[`${t}-card`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{margin:0,padding:r,background:n,border:`${ae(e.lineWidth)} ${e.lineType} ${o}`,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`},[`${t}-tab-active`]:{color:s,background:e.colorBgContainer},[`${t}-tab-focus:has(${t}-tab-btn:focus-visible)`]:gc(e,-3),[`& ${t}-tab${t}-tab-focus ${t}-tab-btn:focus-visible`]:{outline:"none"},[`${t}-ink-bar`]:{visibility:"hidden"}},[`&${t}-top, &${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginLeft:{_skip_check_:!0,value:ae(i)}}}},[`&${t}-top`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0`},[`${t}-tab-active`]:{borderBottomColor:e.colorBgContainer}}},[`&${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`0 0 ${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)}`},[`${t}-tab-active`]:{borderTopColor:e.colorBgContainer}}},[`&${t}-left, &${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginTop:ae(i)}}},[`&${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`${ae(e.borderRadiusLG)} 0 0 ${ae(e.borderRadiusLG)}`}},[`${t}-tab-active`]:{borderRightColor:{_skip_check_:!0,value:e.colorBgContainer}}}},[`&${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`0 ${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0`}},[`${t}-tab-active`]:{borderLeftColor:{_skip_check_:!0,value:e.colorBgContainer}}}}}}},W$e=e=>{const{componentCls:t,itemHoverColor:r,dropdownEdgeChildVerticalPadding:n}=e;return{[`${t}-dropdown`]:{...on(e),position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:e.zIndexPopup,display:"block","&-hidden":{display:"none"},[`${t}-dropdown-menu`]:{maxHeight:e.tabsDropdownHeight,margin:0,padding:`${ae(n)} 0`,overflowX:"hidden",overflowY:"auto",textAlign:{_skip_check_:!0,value:"left"},listStyleType:"none",backgroundColor:e.colorBgContainer,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,"&-item":{...Ps,display:"flex",alignItems:"center",minWidth:e.tabsDropdownWidth,margin:0,padding:`${ae(e.paddingXXS)} ${ae(e.paddingSM)}`,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"> span":{flex:1,whiteSpace:"nowrap"},"&-remove":{flex:"none",marginLeft:{_skip_check_:!0,value:e.marginSM},color:e.colorIcon,fontSize:e.fontSizeSM,background:"transparent",border:0,cursor:"pointer","&:hover":{color:r}},"&:hover":{background:e.controlItemBgHover},"&-disabled":{"&, &:hover":{color:e.colorTextDisabled,background:"transparent",cursor:"not-allowed"}}}}}}},U$e=e=>{const{componentCls:t,margin:r,colorBorderSecondary:n,horizontalMargin:i,verticalItemPadding:o,verticalItemMargin:s,motionDurationSlow:a,calc:l}=e;return{[`${t}-top, ${t}-bottom`]:{flexDirection:"column",[`> ${t}-nav, > div > ${t}-nav`]:{margin:i,"&::before":{position:"absolute",right:{_skip_check_:!0,value:0},left:{_skip_check_:!0,value:0},borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${n}`,content:"''"},[`${t}-ink-bar`]:{height:e.lineWidthBold,"&-animated":{transition:["width","left","right"].map(c=>`${c} ${a}`).join(", ")}},[`${t}-nav-wrap`]:{"&::before, &::after":{top:0,bottom:0,width:e.controlHeight},"&::before":{left:{_skip_check_:!0,value:0},boxShadow:e.boxShadowTabsOverflowLeft},"&::after":{right:{_skip_check_:!0,value:0},boxShadow:e.boxShadowTabsOverflowRight},[`&${t}-nav-wrap-ping-left::before`]:{opacity:1},[`&${t}-nav-wrap-ping-right::after`]:{opacity:1}}}},[`${t}-top`]:{[`> ${t}-nav, > div > ${t}-nav`]:{"&::before":{bottom:0},[`${t}-ink-bar`]:{bottom:0}}},[`${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,marginTop:r,marginBottom:0,"&::before":{top:0},[`${t}-ink-bar`]:{top:0}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0}},[`${t}-left, ${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{flexDirection:"column",minWidth:l(e.controlHeight).mul(1.25).equal(),[`${t}-tab`]:{padding:o,textAlign:"center"},[`${t}-tab + ${t}-tab`]:{margin:s},[`${t}-nav-wrap`]:{flexDirection:"column","&::before, &::after":{right:{_skip_check_:!0,value:0},left:{_skip_check_:!0,value:0},height:e.controlHeight},"&::before":{top:0,boxShadow:e.boxShadowTabsOverflowTop},"&::after":{bottom:0,boxShadow:e.boxShadowTabsOverflowBottom},[`&${t}-nav-wrap-ping-top::before`]:{opacity:1},[`&${t}-nav-wrap-ping-bottom::after`]:{opacity:1}},[`${t}-ink-bar`]:{width:e.lineWidthBold,"&-animated":{transition:["height","top"].map(c=>`${c} ${a}`).join(", ")}},[`${t}-nav-list, ${t}-nav-operations`]:{flex:"1 0 auto",flexDirection:"column"}}},[`${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-ink-bar`]:{right:{_skip_check_:!0,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{marginLeft:{_skip_check_:!0,value:ae(l(e.lineWidth).mul(-1).equal())},borderLeft:{_skip_check_:!0,value:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingLeft:{_skip_check_:!0,value:e.paddingLG}}}},[`${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,[`${t}-ink-bar`]:{left:{_skip_check_:!0,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0,marginRight:{_skip_check_:!0,value:l(e.lineWidth).mul(-1).equal()},borderRight:{_skip_check_:!0,value:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingRight:{_skip_check_:!0,value:e.paddingLG}}}}}},j$e=e=>{const{componentCls:t,cardPaddingSM:r,cardPaddingLG:n,cardHeightSM:i,cardHeightLG:o,horizontalItemPaddingSM:s,horizontalItemPaddingLG:a}=e;return{[t]:{"&-small":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:s,fontSize:e.titleFontSizeSM}}},"&-large":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:a,fontSize:e.titleFontSizeLG,lineHeight:e.lineHeightLG}}}},[`${t}-card`]:{[`&${t}-small`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:r},[`${t}-nav-add`]:{minWidth:i,minHeight:i}},[`&${t}-bottom`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`0 0 ${ae(e.borderRadius)} ${ae(e.borderRadius)}`}},[`&${t}-top`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`${ae(e.borderRadius)} ${ae(e.borderRadius)} 0 0`}},[`&${t}-right`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`0 ${ae(e.borderRadius)} ${ae(e.borderRadius)} 0`}}},[`&${t}-left`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`${ae(e.borderRadius)} 0 0 ${ae(e.borderRadius)}`}}}},[`&${t}-large`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:n},[`${t}-nav-add`]:{minWidth:o,minHeight:o}}}}}},K$e=e=>{const{componentCls:t,itemActiveColor:r,itemHoverColor:n,iconCls:i,tabsHorizontalItemMargin:o,horizontalItemPadding:s,itemSelectedColor:a,itemColor:l}=e,c=`${t}-tab`;return{[c]:{position:"relative",WebkitTouchCallout:"none",WebkitTapHighlightColor:"transparent",display:"inline-flex",alignItems:"center",padding:s,fontSize:e.titleFontSize,background:"transparent",border:0,outline:"none",cursor:"pointer",color:l,"&-btn, &-remove":{"&:focus:not(:focus-visible), &:active":{color:r}},"&-btn":{outline:"none",transition:`all ${e.motionDurationSlow}`,[`${c}-icon:not(:last-child)`]:{marginInlineEnd:e.marginSM}},"&-remove":{flex:"none",lineHeight:1,marginRight:{_skip_check_:!0,value:e.calc(e.marginXXS).mul(-1).equal()},marginLeft:{_skip_check_:!0,value:e.marginXS},color:e.colorIcon,fontSize:e.fontSizeSM,background:"transparent",border:"none",outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"&:hover":{color:e.colorTextHeading},...wl(e)},"&:hover":{color:n},[`&${c}-active ${c}-btn`]:{color:a},[`&${c}-focus ${c}-btn:focus-visible`]:gc(e),[`&${c}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${c}-disabled ${c}-btn, &${c}-disabled ${t}-remove`]:{"&:focus, &:active":{color:e.colorTextDisabled}},[`& ${c}-remove ${i}`]:{margin:0,verticalAlign:"middle"},[`${i}:not(:last-child)`]:{marginRight:{_skip_check_:!0,value:e.marginSM}}},[`${c} + ${c}`]:{margin:{_skip_check_:!0,value:o}}}},q$e=e=>{const{componentCls:t,tabsHorizontalItemMarginRTL:r,iconCls:n,cardGutter:i,calc:o}=e;return{[`${t}-rtl`]:{direction:"rtl",[`${t}-nav`]:{[`${t}-tab`]:{margin:{_skip_check_:!0,value:r},[`${t}-tab:last-of-type`]:{marginLeft:{_skip_check_:!0,value:0}},[n]:{marginRight:{_skip_check_:!0,value:0},marginLeft:{_skip_check_:!0,value:ae(e.marginSM)}},[`${t}-tab-remove`]:{marginRight:{_skip_check_:!0,value:ae(e.marginXS)},marginLeft:{_skip_check_:!0,value:ae(o(e.marginXXS).mul(-1).equal())},[n]:{margin:0}}}},[`&${t}-left`]:{[`> ${t}-nav`]:{order:1},[`> ${t}-content-holder`]:{order:0}},[`&${t}-right`]:{[`> ${t}-nav`]:{order:0},[`> ${t}-content-holder`]:{order:1}},[`&${t}-card${t}-top, &${t}-card${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginRight:{_skip_check_:!0,value:i},marginLeft:{_skip_check_:!0,value:0}}}}},[`${t}-dropdown-rtl`]:{direction:"rtl"},[`${t}-menu-item`]:{[`${t}-dropdown-rtl`]:{textAlign:{_skip_check_:!0,value:"right"}}}}},X$e=e=>{const{componentCls:t,tabsCardPadding:r,cardHeight:n,cardGutter:i,itemHoverColor:o,itemActiveColor:s,colorBorderSecondary:a}=e;return{[t]:{...on(e),display:"flex",[`> ${t}-nav, > div > ${t}-nav`]:{position:"relative",display:"flex",flex:"none",alignItems:"center",[`${t}-nav-wrap`]:{position:"relative",display:"flex",flex:"auto",alignSelf:"stretch",overflow:"hidden",whiteSpace:"nowrap",transform:"translate(0)","&::before, &::after":{position:"absolute",zIndex:1,opacity:0,transition:`opacity ${e.motionDurationSlow}`,content:"''",pointerEvents:"none"}},[`${t}-nav-list`]:{position:"relative",display:"flex",transition:`opacity ${e.motionDurationSlow}`},[`${t}-nav-operations`]:{display:"flex",alignSelf:"stretch"},[`${t}-nav-operations-hidden`]:{position:"absolute",visibility:"hidden",pointerEvents:"none"},[`${t}-nav-more`]:{position:"relative",padding:r,background:"transparent",border:0,color:e.colorText,"&::after":{position:"absolute",right:{_skip_check_:!0,value:0},bottom:0,left:{_skip_check_:!0,value:0},height:e.calc(e.controlHeightLG).div(8).equal(),transform:"translateY(100%)",content:"''"}},[`${t}-nav-add`]:{minWidth:n,minHeight:n,marginLeft:{_skip_check_:!0,value:i},background:"transparent",border:`${ae(e.lineWidth)} ${e.lineType} ${a}`,borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0`,outline:"none",cursor:"pointer",color:e.colorText,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`,"&:hover":{color:o},"&:active, &:focus:not(:focus-visible)":{color:s},...wl(e,-3)}},[`${t}-extra-content`]:{flex:"none"},[`${t}-ink-bar`]:{position:"absolute",background:e.inkBarColor,pointerEvents:"none"},...K$e(e),[`${t}-content`]:{position:"relative",width:"100%"},[`${t}-content-holder`]:{flex:"auto",minWidth:0,minHeight:0},[`${t}-tabpane`]:{...wl(e),"&-hidden":{display:"none"}}},[`${t}-centered`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-nav-wrap`]:{[`&:not([class*='${t}-nav-wrap-ping']) > ${t}-nav-list`]:{margin:"auto"}}}}}},Y$e=e=>{const{cardHeight:t,cardHeightSM:r,cardHeightLG:n,controlHeight:i,controlHeightLG:o}=e,s=t||o,a=r||i,l=n||o+8;return{zIndexPopup:e.zIndexPopupBase+50,cardBg:e.colorFillAlter,cardHeight:s,cardHeightSM:a,cardHeightLG:l,cardPadding:`${(s-e.fontHeight)/2-e.lineWidth}px ${e.padding}px`,cardPaddingSM:`${(a-e.fontHeight)/2-e.lineWidth}px ${e.paddingXS}px`,cardPaddingLG:`${(l-e.fontHeightLG)/2-e.lineWidth}px ${e.padding}px`,titleFontSize:e.fontSize,titleFontSizeLG:e.fontSizeLG,titleFontSizeSM:e.fontSize,inkBarColor:e.colorPrimary,horizontalMargin:`0 0 ${e.margin}px 0`,horizontalItemGutter:32,horizontalItemMargin:"",horizontalItemMarginRTL:"",horizontalItemPadding:`${e.paddingSM}px 0`,horizontalItemPaddingSM:`${e.paddingXS}px 0`,horizontalItemPaddingLG:`${e.padding}px 0`,verticalItemPadding:`${e.paddingXS}px ${e.paddingLG}px`,verticalItemMargin:`${e.margin}px 0 0 0`,itemColor:e.colorText,itemSelectedColor:e.colorPrimary,itemHoverColor:e.colorPrimaryHover,itemActiveColor:e.colorPrimaryActive,cardGutter:e.marginXXS/2}},Z$e=Wr("Tabs",e=>{const t=$r(e,{tabsCardPadding:e.cardPadding,dropdownEdgeChildVerticalPadding:e.paddingXXS,tabsDropdownHeight:200,tabsDropdownWidth:120,tabsHorizontalItemMargin:`0 0 0 ${ae(e.horizontalItemGutter)}`,tabsHorizontalItemMarginRTL:`0 0 0 ${ae(e.horizontalItemGutter)}`});return[j$e(t),q$e(t),U$e(t),W$e(t),H$e(t),X$e(t),z$e(t)]},Y$e),Q$e=()=>null,J$e=y.forwardRef((e,t)=>{var J,ue,ve,pe;const{type:r,className:n,rootClassName:i,size:o,onEdit:s,hideAdd:a,centered:l,addIcon:c,removeIcon:u,moreIcon:d,more:h,popupClassName:p,children:f,items:g,animated:m,style:v,indicatorSize:b,indicator:S,classNames:x,styles:E,destroyInactiveTabPane:R,destroyOnHidden:T,tabPlacement:M,tabPosition:D,...A}=e,{prefixCls:I}=A,{getPrefixCls:L,direction:F,getPopupContainer:k,className:O,style:B,classNames:H,styles:N}=Nr("tabs"),{tabs:z}=y.useContext(ir),W=L("tabs",I),V=ho(W),[$,K]=Z$e(W,V),q=y.useRef(null);y.useImperativeHandle(t,()=>({nativeElement:q.current}));let X;r==="editable-card"&&(X={onEdit:(me,{key:ke,event:De})=>{s==null||s(me==="add"?De:ke,me)},removeIcon:u??(z==null?void 0:z.removeIcon)??y.createElement(Xd,null),addIcon:(c??(z==null?void 0:z.addIcon))||y.createElement(Eue,null),showAdd:a!==!0});const Y=L(),oe=ki(o),ee=V$e(g,f),ne=$$e(W,m),le={align:(S==null?void 0:S.align)??((J=z==null?void 0:z.indicator)==null?void 0:J.align),size:(S==null?void 0:S.size)??b??((ue=z==null?void 0:z.indicator)==null?void 0:ue.size)??(z==null?void 0:z.indicatorSize)},he=y.useMemo(()=>{const me=M??D??void 0,ke=F==="rtl";switch(me){case"start":return ke?"right":"left";case"end":return ke?"left":"right";default:return me}},[M,D,F]),re={...e,size:oe,tabPlacement:he,items:ee},[ie,de]=Vr([H,x],[N,E],{props:re},{popup:{_default:"root"}});return y.createElement(N$e,{ref:q,direction:F,getPopupContainer:k,...A,items:ee,className:Q({[`${W}-large`]:oe==="large",[`${W}-small`]:oe==="small",[`${W}-card`]:["card","editable-card"].includes(r),[`${W}-editable-card`]:r==="editable-card",[`${W}-centered`]:l},O,n,i,ie.root,$,K,V),classNames:{...ie,popup:Q(p,$,K,V,(ve=ie.popup)==null?void 0:ve.root)},styles:de,style:{...de.root,...B,...v},editable:X,more:{icon:((pe=z==null?void 0:z.more)==null?void 0:pe.icon)??(z==null?void 0:z.moreIcon)??d??y.createElement(C4,null),transitionName:`${Y}-slide-up`,...h},prefixCls:W,animated:ne,indicator:le,destroyOnHidden:T??R,tabPosition:he})}),Mue=J$e;Mue.TabPane=Q$e;const Iue=({prefixCls:e,className:t,hoverable:r=!0,...n})=>{const{getPrefixCls:i}=y.useContext(ir),o=i("card",e),s=Q(`${o}-grid`,t,{[`${o}-grid-hoverable`]:r});return y.createElement("div",{...n,className:s})},eGe=e=>{const{antCls:t,componentCls:r,headerHeight:n,headerPadding:i,tabsMarginBottom:o}=e;return{display:"flex",justifyContent:"center",flexDirection:"column",minHeight:n,marginBottom:-1,padding:`0 ${ae(i)}`,color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.headerFontSize,background:e.headerBg,borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorderSecondary}`,borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0`,...fu(),"&-wrapper":{width:"100%",display:"flex",alignItems:"center"},"&-title":{display:"inline-block",flex:1,...Ps,[` > ${r}-typography, > ${r}-typography-edit-content `]:{insetInlineStart:0,marginTop:0,marginBottom:0}},[`${t}-tabs-top`]:{clear:"both",marginBottom:o,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,"&-bar":{borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorderSecondary}`}}}},tGe=e=>{const{cardPaddingBase:t,colorBorderSecondary:r,cardShadow:n,lineWidth:i}=e;return{width:"33.33%",padding:t,border:0,borderRadius:0,boxShadow:` ${ae(i)} 0 0 0 ${r}, 0 ${ae(i)} 0 0 ${r}, ${ae(i)} ${ae(i)} 0 0 ${r}, ${ae(i)} 0 0 0 ${r} inset, 0 ${ae(i)} 0 0 ${r} inset; `,transition:`all ${e.motionDurationMid}`,"&-hoverable:hover":{position:"relative",zIndex:1,boxShadow:n}}},rGe=e=>{const{componentCls:t,iconCls:r,actionsLiMargin:n,cardActionsIconSize:i,colorBorderSecondary:o,actionsBg:s}=e;return{margin:0,padding:0,listStyle:"none",background:s,borderTop:`${ae(e.lineWidth)} ${e.lineType} ${o}`,display:"flex",borderRadius:`0 0 ${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)}`,...fu(),"& > li":{margin:n,color:e.colorTextDescription,textAlign:"center","> span":{position:"relative",display:"block",minWidth:e.calc(e.cardActionsIconSize).mul(2).equal(),fontSize:e.fontSize,lineHeight:e.lineHeight,cursor:"pointer","&:hover":{color:e.colorPrimary,transition:`color ${e.motionDurationMid}`},[`a:not(${t}-btn), > ${r}`]:{display:"inline-block",width:"100%",color:e.colorIcon,lineHeight:ae(e.fontHeight),transition:`color ${e.motionDurationMid}`,"&:hover":{color:e.colorPrimary}},[`> ${r}`]:{fontSize:i,lineHeight:ae(e.calc(i).mul(e.lineHeight).equal())}},"&:not(:last-child)":{borderInlineEnd:`${ae(e.lineWidth)} ${e.lineType} ${o}`}}}},nGe=e=>({margin:`${ae(e.calc(e.marginXXS).mul(-1).equal())} 0`,display:"flex",...fu(),"&-avatar":{paddingInlineEnd:e.padding},"&-section":{overflow:"hidden",flex:1,"> div:not(:last-child)":{marginBottom:e.marginXS}},"&-title":{color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.fontSizeLG,...Ps},"&-description":{color:e.colorTextDescription}}),iGe=e=>{const{componentCls:t,colorFillAlter:r,headerPadding:n,bodyPadding:i}=e;return{[`${t}-head`]:{padding:`0 ${ae(n)}`,background:r,"&-title":{fontSize:e.fontSize}},[`${t}-body`]:{padding:`${ae(e.padding)} ${ae(i)}`}}},oGe=e=>{const{componentCls:t}=e;return{overflow:"hidden",[`${t}-body`]:{userSelect:"none"}}},sGe=e=>{const{componentCls:t,cardShadow:r,cardHeadPadding:n,colorBorderSecondary:i,boxShadowTertiary:o,bodyPadding:s,extraColor:a,motionDurationMid:l}=e;return{[t]:{...on(e),position:"relative",background:e.colorBgContainer,borderRadius:e.borderRadiusLG,[`&:not(${t}-bordered)`]:{boxShadow:o},[`${t}-head`]:eGe(e),[`${t}-extra`]:{marginInlineStart:"auto",color:a,fontWeight:"normal",fontSize:e.fontSize},[`${t}-body`]:{padding:s,borderRadius:`0 0 ${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)}`,"&:first-child":{borderStartStartRadius:e.borderRadiusLG,borderStartEndRadius:e.borderRadiusLG},"&:not(:last-child)":{borderEndStartRadius:0,borderEndEndRadius:0}},[`${t}-grid`]:tGe(e),[`${t}-cover`]:{"> *":{display:"block",width:"100%",borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0`}},[`${t}-actions`]:rGe(e),[`${t}-meta`]:nGe(e)},[`${t}-bordered`]:{border:`${ae(e.lineWidth)} ${e.lineType} ${i}`,[`${t}-cover`]:{marginTop:-1,marginInlineStart:-1,marginInlineEnd:-1}},[`${t}-hoverable`]:{cursor:"pointer",transition:["box-shadow","border-color"].map(c=>`${c} ${l}`).join(", "),"&:hover":{borderColor:"transparent",boxShadow:r}},[`${t}-contain-grid`]:{borderRadius:`${ae(e.borderRadiusLG)} ${ae(e.borderRadiusLG)} 0 0 `,[`&:not(:has(> ${t}-head))`]:{borderRadius:0},[`${t}-body`]:{display:"flex",flexWrap:"wrap"},[`&:not(${t}-loading) ${t}-body`]:{marginBlockStart:e.calc(e.lineWidth).mul(-1).equal(),marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),padding:0}},[`${t}-contain-tabs`]:{[`> div${t}-head`]:{minHeight:0,[`${t}-head-title, ${t}-extra`]:{paddingTop:n}}},[`${t}-type-inner`]:iGe(e),[`${t}-loading`]:oGe(e),[`${t}-rtl`]:{direction:"rtl"}}},aGe=e=>{const{componentCls:t,bodyPaddingSM:r,headerPaddingSM:n,headerHeightSM:i,headerFontSizeSM:o}=e;return{[`${t}-small`]:{[`> ${t}-head`]:{minHeight:i,padding:`0 ${ae(n)}`,fontSize:o,[`> ${t}-head-wrapper`]:{[`> ${t}-extra`]:{fontSize:e.fontSize}}},[`> ${t}-body`]:{padding:r}},[`${t}-small${t}-contain-tabs`]:{[`> ${t}-head`]:{[`${t}-head-title, ${t}-extra`]:{paddingTop:0,display:"flex",alignItems:"center"}}}}},lGe=e=>({headerBg:"transparent",headerFontSize:e.fontSizeLG,headerFontSizeSM:e.fontSize,headerHeight:e.fontSizeLG*e.lineHeightLG+e.padding*2,headerHeightSM:e.fontSize*e.lineHeight+e.paddingXS*2,actionsBg:e.colorBgContainer,actionsLiMargin:`${e.paddingSM}px 0`,tabsMarginBottom:-e.padding-e.lineWidth,extraColor:e.colorText,bodyPaddingSM:12,headerPaddingSM:12,bodyPadding:e.bodyPadding??e.paddingLG,headerPadding:e.headerPadding??e.paddingLG}),cGe=Wr("Card",e=>{const t=$r(e,{cardShadow:e.boxShadowCard,cardHeadPadding:e.padding,cardPaddingBase:e.paddingLG,cardActionsIconSize:e.fontSize});return[sGe(t),aGe(t)]},lGe),uGe=e=>{const{actionClasses:t,actions:r=[],actionStyle:n}=e;return y.createElement("ul",{className:t,style:n},r.map((i,o)=>{const s=`action-${o}`;return y.createElement("li",{style:{width:`${100/r.length}%`},key:s},y.createElement("span",null,i))}))},dGe=y.forwardRef((e,t)=>{const{prefixCls:r,className:n,rootClassName:i,style:o,extra:s,headStyle:a={},bodyStyle:l={},title:c,loading:u,bordered:d,variant:h,size:p,type:f,cover:g,actions:m,tabList:v,children:b,activeTabKey:S,defaultActiveTabKey:x,tabBarExtraContent:E,hoverable:R,tabProps:T={},classNames:M,styles:D,...A}=e,{getPrefixCls:I,direction:L,className:F,style:k,classNames:O,styles:B}=Nr("card"),[H]=jx("card",h,d),N=ki(p),z={...e,size:N,variant:H,loading:u},[W,V]=Vr([O,M],[B,D],{props:z}),$=We=>{var ze;(ze=e.onTabChange)==null||ze.call(e,We)},K=y.useMemo(()=>Li(b).some(ze=>y.isValidElement(ze)&&ze.type===Iue),[b]),q=I("card",r),[X,Y]=cGe(q),oe=y.createElement(Up,{loading:!0,active:!0,paragraph:{rows:4},title:!1},b),ee=S!==void 0,ne={...T,[ee?"activeKey":"defaultActiveKey"]:ee?S:x,tabBarExtraContent:E};let le;const he=N!=="small"?"large":N,re=v?y.createElement(Mue,{size:he,...ne,className:`${q}-head-tabs`,onChange:$,items:v.map(({tab:We,...ze})=>({label:We,...ze}))}):null;if(c||s||re){const We=Q(`${q}-head`,W.header),ze=Q(`${q}-head-title`,W.title),mt=Q(`${q}-extra`,W.extra),Nt={...a,...V.header};le=y.createElement("div",{className:We,style:Nt},y.createElement("div",{className:`${q}-head-wrapper`},c&&y.createElement("div",{className:ze,style:V.title},c),s&&y.createElement("div",{className:mt,style:V.extra},s)),re)}const ie=Q(`${q}-cover`,W.cover),de=g?y.createElement("div",{className:ie,style:V.cover},g):null,J=Q(`${q}-body`,W.body),ue={...l,...V.body},ve=y.createElement("div",{className:J,style:ue},u?oe:b),pe=Q(`${q}-actions`,W.actions),me=m!=null&&m.length?y.createElement(uGe,{actionClasses:pe,actionStyle:V.actions,actions:m}):null,ke=fn(A,["onTabChange"]),De=Q(q,F,{[`${q}-loading`]:u,[`${q}-bordered`]:H!=="borderless",[`${q}-hoverable`]:R,[`${q}-contain-grid`]:K,[`${q}-contain-tabs`]:v==null?void 0:v.length,[`${q}-small`]:N==="small",[`${q}-type-${f}`]:!!f,[`${q}-rtl`]:L==="rtl"},n,i,X,Y,W.root),Ee={...V.root,...k,...o};return y.createElement("div",{ref:t,...ke,className:De,style:Ee},le,de,ve,me)}),hGe=e=>{const{prefixCls:t,className:r,avatar:n,title:i,description:o,style:s,classNames:a,styles:l,...c}=e,{getPrefixCls:u,className:d,style:h,classNames:p,styles:f}=Nr("cardMeta"),m=`${u("card",t)}-meta`,[v,b]=Vr([p,a],[f,l],{props:e}),S=Q(m,r,d,v.root),x={...h,...b.root,...s},E=Q(`${m}-avatar`,v.avatar),R=Q(`${m}-title`,v.title),T=Q(`${m}-description`,v.description),M=Q(`${m}-section`,v.section),D=n?y.createElement("div",{className:E,style:b.avatar},n):null,A=i?y.createElement("div",{className:R,style:b.title},i):null,I=o?y.createElement("div",{className:T,style:b.description},o):null,L=A||I?y.createElement("div",{className:M,style:b.section},A,I):null;return y.createElement("div",{...c,className:S,style:x},D,L)},Due=dGe;Due.Grid=Iue;Due.Meta=hGe;function pGe(e,t,r){var n=r||{},i=n.noTrailing,o=i===void 0?!1:i,s=n.noLeading,a=s===void 0?!1:s,l=n.debounceMode,c=l===void 0?void 0:l,u,d=!1,h=0;function p(){u&&clearTimeout(u)}function f(m){var v=m||{},b=v.upcomingOnly,S=b===void 0?!1:b;p(),d=!S}function g(){for(var m=arguments.length,v=new Array(m),b=0;be?a?(h=Date.now(),o||(u=setTimeout(c?R:E,e))):E():o!==!0&&(u=setTimeout(c?R:E,c===void 0?e-x:e))}return g.cancel=f,g}function fGe(e,t,r){var n={},i=n.atBegin,o=i===void 0?!1:i;return pGe(e,t,{debounceMode:o!==!1})}function Es(e,t){return e[t]}function Aue(e,t){return`${e}-${t}`}function gGe(e){return e&&e.type&&e.type.isTreeNode}function Zx(e,t){return e??t}function jy(e){const{title:t,_title:r,key:n,children:i}=e||{},o=t||"title";return{title:o,_title:r||[o],key:n||"key",children:i||"children"}}function Fue(e){function t(r){return Li(r).map(i=>{if(!gGe(i))return Vn(!i,"Tree/TreeNode can only accept TreeNode as children."),null;const{key:o}=i,{children:s,...a}=i.props,l={key:o,...a},c=t(s);return c.length&&(l.children=c),l}).filter(i=>i)}return t(e)}function nO(e,t,r){const{_title:n,key:i,children:o}=jy(r),s=new Set(t===!0?[]:t),a=[];function l(c,u=null){return c.map((d,h)=>{const p=Aue(u?u.pos:"0",h),f=Zx(d[i],p);let g;for(let v=0;vh[o]:typeof o=="function"&&(u=h=>o(h)):u=(h,p)=>Zx(h[a],p);function d(h,p,f,g){const m=h?h[c]:e,v=h?Aue(f.pos,p):"0",b=h?[...g,h]:[];if(h){const S=u(h,v),x={node:h,index:p,pos:v,key:S,parentPos:f.node?f.pos:null,level:f.level+1,nodes:b};t(x)}m&&m.forEach((S,x)=>{d(S,x,{node:h,pos:v,level:f?f.level+1:-1},b)})}d(null)}function T4(e,{initWrapper:t,processEntity:r,onProcessFinished:n,externalGetKey:i,childrenPropName:o,fieldNames:s}={},a){const l=i||a,c={},u={};let d={posEntities:c,keyEntities:u};return t&&(d=t(d)||d),mGe(e,h=>{const{node:p,index:f,pos:g,key:m,parentPos:v,level:b,nodes:S}=h,x={node:p,nodes:S,index:f,key:m,pos:g,level:b},E=Zx(m,g);c[g]=x,u[E]=x,x.parent=c[v],x.parent&&(x.parent.children=x.parent.children||[],x.parent.children.push(x)),r&&r(x,d)},{externalGetKey:l,childrenPropName:o,fieldNames:s}),n&&n(d),d}function Lue(e,t,r,n){return e===!1?!1:e||!t&&!r||t&&n&&!r}function Lw(e,{expandedKeys:t,selectedKeys:r,loadedKeys:n,loadingKeys:i,checkedKeys:o,halfCheckedKeys:s,dragOverNodeKey:a,dropPosition:l,keyEntities:c}){const u=Es(c,e);return{eventKey:e,expanded:t.indexOf(e)!==-1,selected:r.indexOf(e)!==-1,loaded:n.indexOf(e)!==-1,loading:i.indexOf(e)!==-1,checked:o.indexOf(e)!==-1,halfChecked:s.indexOf(e)!==-1,pos:String(u?u.pos:""),dragOver:a===e&&l===0,dragOverGapTop:a===e&&l===-1,dragOverGapBottom:a===e&&l===1}}function Hi(e){const{data:t,expanded:r,selected:n,checked:i,loaded:o,loading:s,halfChecked:a,dragOver:l,dragOverGapTop:c,dragOverGapBottom:u,pos:d,active:h,eventKey:p}=e,f={...t,expanded:r,selected:n,checked:i,loaded:o,loading:s,halfChecked:a,dragOver:l,dragOverGapTop:c,dragOverGapBottom:u,pos:d,active:h,key:p};return"props"in f||Object.defineProperty(f,"props",{get(){return Vn(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),e}}),f}function _ue(e,t){const r=new Set;return e.forEach(n=>{t.has(n)||r.add(n)}),r}function vGe(e){const{disabled:t,disableCheckbox:r,checkable:n}=e||{};return!!(t||r)||n===!1}function yGe(e,t,r,n){const i=new Set(e),o=new Set;for(let a=0;a<=r;a+=1)(t.get(a)||new Set).forEach(c=>{const{key:u,node:d,children:h=[]}=c;i.has(u)&&!n(d)&&h.filter(p=>!n(p.node)).forEach(p=>{i.add(p.key)})});const s=new Set;for(let a=r;a>=0;a-=1)(t.get(a)||new Set).forEach(c=>{const{parent:u,node:d}=c;if(n(d)||!c.parent||s.has(c.parent.key))return;if(n(c.parent.node)){s.add(u.key);return}let h=!0,p=!1;(u.children||[]).filter(f=>!n(f.node)).forEach(({key:f})=>{const g=i.has(f);h&&!g&&(h=!1),!p&&(g||o.has(f))&&(p=!0)}),h&&i.add(u.key),p&&o.add(u.key),s.add(u.key)});return{checkedKeys:Array.from(i),halfCheckedKeys:Array.from(_ue(o,i))}}function CGe(e,t,r,n,i){const o=new Set(e);let s=new Set(t);for(let l=0;l<=n;l+=1)(r.get(l)||new Set).forEach(u=>{const{key:d,node:h,children:p=[]}=u;!o.has(d)&&!s.has(d)&&!i(h)&&p.filter(f=>!i(f.node)).forEach(f=>{o.delete(f.key)})});s=new Set;const a=new Set;for(let l=n;l>=0;l-=1)(r.get(l)||new Set).forEach(u=>{const{parent:d,node:h}=u;if(i(h)||!u.parent||a.has(u.parent.key))return;if(i(u.parent.node)){a.add(d.key);return}let p=!0,f=!1;(d.children||[]).filter(g=>!i(g.node)).forEach(({key:g})=>{const m=o.has(g);p&&!m&&(p=!1),!f&&(m||s.has(g))&&(f=!0)}),p||o.delete(d.key),f&&s.add(d.key),a.add(d.key)});return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(_ue(s,o))}}function wy(e,t,r,n){const i=[];let o;n?o=n:o=vGe;const s=new Set(e.filter(u=>{const d=!!Es(r,u);return d||i.push(u),d})),a=new Map;let l=0;Object.keys(r).forEach(u=>{const d=r[u],{level:h}=d;let p=a.get(h);p||(p=new Set,a.set(h,p)),p.add(d),l=Math.max(l,h)}),Vn(!i.length,`Tree missing follow keys: ${i.slice(0,100).map(u=>`'${u}'`).join(", ")}`);let c;return t===!0?c=yGe(s,a,l,o):c=CGe(s,t.halfCheckedKeys,a,l,o),c}const bGe=e=>{const{checkboxCls:t,checkboxSize:r,lineWidth:n}=e,i=`${t}-wrapper`;return[{[`${t}-group`]:{...on(e),display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}},[i]:{...on(e),display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${i}`]:{marginInlineStart:0},[`&${i}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}},[t]:{...on(e),position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",boxSizing:"border-box",display:"block",width:r,height:r,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${ae(n)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,flex:"none",...bd(),"&:after":{boxSizing:"border-box",position:"absolute",top:`calc(${r} / 2 - ${n})`,insetInlineStart:`calc(${r} / 4 - ${n})`,display:"table",width:e.calc(r).div(14).mul(5).equal(),height:e.calc(r).div(14).mul(8).equal(),border:`${ae(e.lineWidthBold)} solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`,...bd()},[`${t}-input`]:{position:"absolute",inset:`calc(-1 * (${n}))`,zIndex:1,cursor:"pointer",opacity:0,margin:0},[`&:has(${t}-input:focus-visible)`]:gc(e),"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}}},{[` ${i}:not(${i}-disabled), ${t}:not(${t}-disabled) `]:{[`&:hover ${t}`]:{borderColor:e.colorPrimary}},[`${i}:not(${i}-disabled)`]:{[`&:hover ${t}-checked:not(${t}-disabled)`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[`${t}-checked`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`,...bd()},[`&:not(${t}-disabled):hover`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[t]:{"&-indeterminate":{backgroundColor:e.colorBgContainer,borderColor:e.colorBorder,"&:after":{top:"50%",insetInlineStart:"50%",width:e.calc(e.fontSizeLG).div(2).equal(),height:e.calc(e.fontSizeLG).div(2).equal(),backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'},"&:hover":{backgroundColor:e.colorBgContainer,borderColor:e.colorPrimary}}}},{[`${i}-disabled`]:{cursor:"not-allowed"},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},background:e.colorBgContainerDisabled,borderColor:e.colorBorder,"&:after":{borderColor:e.colorTextDisabled},"& + span":{color:e.colorTextDisabled},[`&${t}-indeterminate::after`]:{background:e.colorTextDisabled}}}]};function Oue(e,t){const r=$r(t,{checkboxCls:`.${e}`,checkboxSize:t.controlInteractiveSize});return bGe(r)}const kue=Wr("Checkbox",(e,{prefixCls:t})=>[Oue(t,e)]),Nue=Z.createContext(null),SGe=(e,t)=>{const{prefixCls:r,children:n,indeterminate:i=!1,onMouseEnter:o,onMouseLeave:s,skipGroup:a=!1,disabled:l,rootClassName:c,className:u,style:d,classNames:h,styles:p,name:f,value:g,checked:m,defaultChecked:v,onChange:b,...S}=e,{getPrefixCls:x,direction:E,className:R,style:T,classNames:M,styles:D}=Nr("checkbox"),A=y.useContext(Nue),{isFormItemInput:I}=y.useContext(ua),L=y.useContext(hs),F=((A==null?void 0:A.disabled)||l)??L,[k,O]=An(v,m);let B=k;const H=br(re=>{O(re.target.checked),b==null||b(re),!a&&(A!=null&&A.toggleOption)&&A.toggleOption({label:n,value:g})});A&&!a&&(B=A.value.includes(g));const N=y.useRef(null),z=Pu(t,N);y.useEffect(()=>{if(!(a||!A))return A.registerValue(g),()=>{A.cancelValue(g)}},[g,a]),y.useEffect(()=>{var re;(re=N.current)!=null&&re.input&&(N.current.input.indeterminate=i)},[i]);const W=x("checkbox",r),V=ho(W),[$,K]=kue(W,V),q={...S},X={...e,indeterminate:i,disabled:F,checked:B},[Y,oe]=Vr([M,h],[D,p],{props:X}),ee=Q(`${W}-wrapper`,{[`${W}-rtl`]:E==="rtl",[`${W}-wrapper-checked`]:B,[`${W}-wrapper-disabled`]:F,[`${W}-wrapper-in-form-item`]:I},R,u,Y.root,c,K,V,$),ne=Q(Y.icon,{[`${W}-indeterminate`]:i},HD,$),[le,he]=pue(q.onClick);return y.createElement(kx,{component:"Checkbox",disabled:F},y.createElement("label",{className:ee,style:{...oe.root,...T,...d},onMouseEnter:o,onMouseLeave:s,onClick:le},y.createElement(hue,{...q,name:!a&&A?A.name:f,checked:B,onClick:he,onChange:H,prefixCls:W,className:ne,style:oe.icon,disabled:F,ref:z,value:g}),Tn(n)&&y.createElement("span",{className:Q(`${W}-label`,Y.label),style:oe.label},n)))},Bue=y.forwardRef(SGe),wGe=y.forwardRef((e,t)=>{const{defaultValue:r,children:n,options:i=[],prefixCls:o,className:s,rootClassName:a,style:l,onChange:c,role:u="group",...d}=e,{getPrefixCls:h,direction:p}=y.useContext(ir),[f,g]=y.useState(d.value||r||[]),[m,v]=y.useState([]);y.useEffect(()=>{"value"in d&&g(d.value||[])},[d.value]);const b=y.useMemo(()=>i.map(O=>typeof O=="string"||typeof O=="number"?{label:O,value:O}:O),[i]),S=O=>{v(B=>B.filter(H=>H!==O))},x=O=>{v(B=>[].concat(Pr(B),[O]))},E=O=>{const B=f.indexOf(O.value),H=Pr(f);B===-1?H.push(O.value):H.splice(B,1),"value"in d||g(H),c==null||c(H.filter(N=>m.includes(N)).sort((N,z)=>{const W=b.findIndex($=>$.value===N),V=b.findIndex($=>$.value===z);return W-V}))},R=h("checkbox",o),T=`${R}-group`,M=ho(R),[D,A]=kue(R,M),I=fn(d,["value","disabled"]),L=i.length?b.map(O=>y.createElement(Bue,{prefixCls:R,key:O.value.toString(),disabled:"disabled"in O?O.disabled:d.disabled,value:O.value,checked:f.includes(O.value),onChange:O.onChange,className:Q(`${T}-item`,O.className),style:O.style,title:O.title,id:O.id,required:O.required},O.label)):n,F=y.useMemo(()=>({toggleOption:E,value:f,disabled:d.disabled,name:d.name,registerValue:x,cancelValue:S}),[E,f,d.disabled,d.name,x,S]),k=Q(T,{[`${T}-rtl`]:p==="rtl"},s,a,A,M,D);return y.createElement("div",{className:k,style:l,role:u,...I,ref:t},y.createElement(Nue.Provider,{value:F},L))}),Ky=Bue;Ky.Group=wGe;Ky.__ANT_CHECKBOX=!0;const $ue=y.createContext({}),xGe=e=>typeof e=="number"&&!Number.isNaN(e);function Xq(e){return e==="auto"?"1 1 auto":xGe(e)?`${e} ${e} auto`:/^\d+(\.\d+)?(px|em|rem|%)$/.test(e)?`0 0 ${e}`:e}const EGe=y.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n}=y.useContext(ir),{gutter:i,wrap:o}=y.useContext($ue),{prefixCls:s,span:a,order:l,offset:c,push:u,pull:d,className:h,children:p,flex:f,style:g,...m}=e,v=r("col",s),b=r(),[S,x]=yke(v),[E]=Jn(b,"col"),R={};let T={};l2e.forEach(A=>{let I={};const L=e[A];typeof L=="number"?I.span=L:typeof L=="object"&&(I=L||{}),delete m[A],T={...T,[`${v}-${A}-${I.span}`]:I.span!==void 0,[`${v}-${A}-order-${I.order}`]:I.order||I.order===0,[`${v}-${A}-offset-${I.offset}`]:I.offset||I.offset===0,[`${v}-${A}-push-${I.push}`]:I.push||I.push===0,[`${v}-${A}-pull-${I.pull}`]:I.pull||I.pull===0,[`${v}-rtl`]:n==="rtl"},I.flex&&(T[`${v}-${A}-flex`]=!0,R[E(`${A}-flex`)]=Xq(I.flex))});const M=Q(v,{[`${v}-${a}`]:a!==void 0,[`${v}-order-${l}`]:l,[`${v}-offset-${c}`]:c,[`${v}-push-${u}`]:u,[`${v}-pull-${d}`]:d},h,T,S,x),D={};if(i!=null&&i[0]){const A=typeof i[0]=="number"?`${i[0]/2}px`:`calc(${i[0]} / 2)`;D.paddingInline=A}return f&&(D.flex=Xq(f),o===!1&&!D.minWidth&&(D.minWidth=0)),y.createElement("div",{...m,style:{...D,...g,...R},className:M,ref:t},p)});function TGe(e,t){const r=[void 0,void 0],n=Array.isArray(e)?e:[e,void 0],i=t||{xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0,xxxl:!0};return n.forEach((o,s)=>{if(typeof o=="object"&&o!==null)for(let a=0;a{if(typeof e=="string"&&n(e),typeof e=="object")for(let o=0;o{i()},[JSON.stringify(e),t]),r}const RGe=y.forwardRef((e,t)=>{const{prefixCls:r,justify:n,align:i,className:o,style:s,children:a,gutter:l=0,wrap:c,...u}=e,{getPrefixCls:d,direction:h}=y.useContext(ir),p=Kx(!0,null),f=Yq(i,p),g=Yq(n,p),m=d("row",r),[v,b]=vke(m),S=TGe(l,p),x=Q(m,{[`${m}-no-wrap`]:c===!1,[`${m}-${g}`]:g,[`${m}-${f}`]:f,[`${m}-rtl`]:h==="rtl"},o,v,b),E={};if(S!=null&&S[0]){const D=typeof S[0]=="number"?`${S[0]/-2}px`:`calc(${S[0]} / -2)`;E.marginInline=D}const[R,T]=S;E.rowGap=T;const M=y.useMemo(()=>({gutter:[R,T],wrap:c}),[R,T,c]);return y.createElement($ue.Provider,{value:M},y.createElement("div",{...u,className:x,style:{...E,...s},ref:t},a))}),PGe=e=>{const{componentCls:t}=e;return{[t]:{"&-horizontal":{[`&${t}`]:{"&-sm":{marginBlock:e.marginXS},"&-md":{marginBlock:e.margin}}}}}},MGe=e=>{const{componentCls:t,sizePaddingEdgeHorizontal:r,colorSplit:n,lineWidth:i,textPaddingInline:o,orientationMargin:s,verticalMarginInline:a}=e,l=`${t}-rail`;return{[t]:{...on(e),borderBlockStart:`${ae(i)} solid ${n}`,[l]:{borderBlockStart:`${ae(i)} solid ${n}`},"&-vertical":{position:"relative",top:"-0.06em",display:"inline-block",height:"0.9em",marginInline:a,marginBlock:0,verticalAlign:"middle",borderTop:0,borderInlineStart:`${ae(i)} solid ${n}`},"&-horizontal":{display:"flex",clear:"both",width:"100%",minWidth:"100%",margin:`${ae(e.marginLG)} 0`},[`&-horizontal${t}-with-text`]:{display:"flex",alignItems:"center",margin:`${ae(e.dividerHorizontalWithTextGutterMargin)} 0`,color:e.colorTextHeading,fontWeight:500,fontSize:e.fontSizeLG,whiteSpace:"nowrap",textAlign:"center",borderBlockStart:`0 ${n}`,[`${l}-start, ${l}-end`]:{width:"50%",borderBlockStartColor:"inherit",borderBlockEnd:0,content:"''"}},[`&-horizontal${t}-with-text-start`]:{[`${l}-start`]:{width:`calc(${s} * 100%)`},[`${l}-end`]:{width:`calc(100% - ${s} * 100%)`}},[`&-horizontal${t}-with-text-end`]:{[`${l}-start`]:{width:`calc(100% - ${s} * 100%)`},[`${l}-end`]:{width:`calc(${s} * 100%)`}},[`${t}-inner-text`]:{display:"inline-block",paddingBlock:0,paddingInline:o},"&-dashed":{background:"none",borderColor:n,borderStyle:"dashed",borderWidth:`${ae(i)} 0 0`,[l]:{borderBlockStart:`${ae(i)} dashed ${n}`}},[`&-horizontal${t}-with-text${t}-dashed`]:{[`${l}-start, ${l}-end`]:{borderStyle:"dashed none none"}},[`&-vertical${t}-dashed`]:{borderInlineStartWidth:i,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},"&-dotted":{background:"none",borderColor:n,borderStyle:"dotted",borderWidth:`${ae(i)} 0 0`,[l]:{borderBlockStart:`${ae(i)} dotted ${n}`}},[`&-horizontal${t}-with-text${t}-dotted`]:{"&::before, &::after":{borderStyle:"dotted none none"}},[`&-vertical${t}-dotted`]:{borderInlineStartWidth:i,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},[`&-plain${t}-with-text`]:{color:e.colorText,fontWeight:"normal",fontSize:e.fontSize},[`&-horizontal${t}-with-text-start${t}-no-default-orientation-margin-start`]:{[`${l}-start`]:{width:0},[`${l}-end`]:{width:"100%"},[`${t}-inner-text`]:{paddingInlineStart:r}},[`&-horizontal${t}-with-text-end${t}-no-default-orientation-margin-end`]:{[`${l}-start`]:{width:"100%"},[`${l}-end`]:{width:0},[`${t}-inner-text`]:{paddingInlineEnd:r}}}}},IGe=e=>({textPaddingInline:"1em",orientationMargin:.05,verticalMarginInline:e.marginXS}),DGe=Wr("Divider",e=>{const t=$r(e,{dividerHorizontalWithTextGutterMargin:e.margin,sizePaddingEdgeHorizontal:0});return[MGe(t),PGe(t)]},IGe,{unitless:{orientationMargin:!0}}),AGe=["left","right","center","start","end"],OBt=e=>{const{getPrefixCls:t,direction:r,className:n,style:i,classNames:o,styles:s}=Nr("divider"),{prefixCls:a,type:l,orientation:c,vertical:u,titlePlacement:d,orientationMargin:h,className:p,rootClassName:f,children:g,dashed:m,variant:v="solid",plain:b,style:S,size:x,classNames:E,styles:R,...T}=e,M=t("divider",a),D=`${M}-rail`,[A,I]=DGe(M),L=ki(x),F=!!g,k=AGe.includes(c||""),O=y.useMemo(()=>{const Y=d??(k?c:"center");return Y==="left"?r==="rtl"?"end":"start":Y==="right"?r==="rtl"?"start":"end":Y},[r,c,d,k]),B=O==="start"&&h!=null,H=O==="end"&&h!=null,[N,z]=Fx(c,u,l),W={...e,orientation:N,titlePlacement:O,size:L},[V,$]=Vr([o,E],[s,R],{props:W}),K=Q(M,n,A,I,`${M}-${N}`,{[`${M}-with-text`]:F,[`${M}-with-text-${O}`]:F,[`${M}-dashed`]:!!m,[`${M}-${v}`]:v!=="solid",[`${M}-plain`]:!!b,[`${M}-rtl`]:r==="rtl",[`${M}-no-default-orientation-margin-start`]:B,[`${M}-no-default-orientation-margin-end`]:H,[`${M}-md`]:L==="medium"||L==="middle",[`${M}-sm`]:L==="small",[D]:!g,[V.rail]:V.rail&&!g},p,f,V.root),q=y.useMemo(()=>typeof h=="number"?h:/^\d+$/.test(h)?Number(h):h,[h]),X={marginInlineStart:B?q:void 0,marginInlineEnd:H?q:void 0};return y.createElement("div",{className:K,style:{...i,...$.root,...g?{}:$.rail,...S},...T,role:"separator"},g&&!z&&y.createElement(y.Fragment,null,y.createElement("div",{className:Q(D,`${D}-start`,V.rail),style:$.rail}),y.createElement("span",{className:Q(`${M}-inner-text`,V.content),style:{...X,...$.content}},g),y.createElement("div",{className:Q(D,`${D}-end`,V.rail),style:$.rail})))};var FGe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H152c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h720c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"minus",theme:"outlined"};function K$(){return K$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,K$({},e,{ref:t,icon:FGe})),_Ge=y.forwardRef(LGe);var OGe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z"}}]},name:"up",theme:"outlined"};function q$(){return q$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,q$({},e,{ref:t,icon:OGe})),NGe=y.forwardRef(kGe);function X$(){return typeof BigInt=="function"}function Gue(e){return!e&&e!==0&&!Number.isNaN(e)||!String(e).trim()}function Og(e){var t=e.trim(),r=t.startsWith("-");r&&(t=t.slice(1)),t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),t.startsWith(".")&&(t="0".concat(t));var n=t||"0",i=n.split("."),o=i[0]||"0",s=i[1]||"0";o==="0"&&s==="0"&&(r=!1);var a=r?"-":"";return{negative:r,negativeStr:a,trimStr:n,integerStr:o,decimalStr:s,fullStr:"".concat(a).concat(n)}}function R4(e){var t=String(e);return!Number.isNaN(Number(t))&&t.includes("e")}function bg(e){var t=String(e);if(R4(e)){var r=Number(t.slice(t.indexOf("e-")+2)),n=t.match(/\.(\d+)/);return n!=null&&n[1]&&(r+=n[1].length),r}return t.includes(".")&&P4(t)?t.length-t.indexOf(".")-1:0}function nA(e){var t=String(e);if(R4(e)){if(e>Number.MAX_SAFE_INTEGER)return String(X$()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(e0&&arguments[0]!==void 0?arguments[0]:!0;return r?this.isInvalidate()?"":Og("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e})(),$Ge=(function(){function e(t){if(Kd(this,e),Bn(this,"origin",""),Bn(this,"number",void 0),Bn(this,"empty",void 0),Gue(t)){this.empty=!0;return}this.origin=String(t),this.number=Number(t)}return qd(e,[{key:"negate",value:function(){return new e(-this.toNumber())}},{key:"add",value:function(r){if(this.isInvalidate())return new e(r);var n=Number(r);if(Number.isNaN(n))return this;var i=this.number+n;if(i>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(iNumber.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(i0&&arguments[0]!==void 0?arguments[0]:!0;return r?this.isInvalidate()?"":nA(this.number):this.origin}}]),e})();function jl(e){return X$()?new BGe(e):new $Ge(e)}function gP(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(e==="")return"";var i=Og(e),o=i.negativeStr,s=i.integerStr,a=i.decimalStr,l="".concat(t).concat(a),c="".concat(o).concat(s);if(r>=0){var u=Number(a[r]);if(u>=5&&!n){var d=jl(e).add("".concat(o,"0.").concat("0".repeat(r)).concat(10-u));return gP(d.toString(),t,r,n)}return r===0?c:"".concat(c).concat(t).concat(a.padEnd(r,"0").slice(0,r))}return l===".0"?c:"".concat(c).concat(l)}function GGe(e,t){return typeof Proxy<"u"&&e?new Proxy(e,{get(r,n){if(t[n])return t[n];const i=r[n];return typeof i=="function"?i.bind(r):i}}):e}function VGe(e,t){const r=y.useRef(null);function n(){try{const{selectionStart:o,selectionEnd:s,value:a}=e,l=a.substring(0,o),c=a.substring(s);r.current={start:o,end:s,value:a,beforeTxt:l,afterTxt:c}}catch{}}function i(){if(e&&r.current&&t)try{const{value:o}=e,{beforeTxt:s,afterTxt:a,start:l}=r.current;let c=o.length;if(o.startsWith(s))c=s.length;else if(o.endsWith(a))c=o.length-r.current.afterTxt.length;else{const u=s[l-1],d=o.indexOf(u,l-1);d!==-1&&(c=d+1)}e.setSelectionRange(c,c)}catch(o){Vn(!1,`Something warning of cursor restore. Please fire issue about this: ${o.message}`)}}return[n,i]}const zGe=200,HGe=600;function Zq({prefixCls:e,action:t,children:r,disabled:n,className:i,style:o,onStep:s}){const a=t==="up",l=y.useRef(),c=y.useRef([]),u=()=>{clearTimeout(l.current)},d=g=>{g.preventDefault(),u(),s(a,"handler");function m(){s(a,"handler"),l.current=setTimeout(m,zGe)}l.current=setTimeout(m,HGe)};y.useEffect(()=>()=>{u(),c.current.forEach(g=>{Or.cancel(g)})},[]);const h=`${e}-action`,p=Q(h,`${h}-${t}`,{[`${h}-${t}-disabled`]:n},i),f=()=>c.current.push(Or(u));return y.createElement("span",{unselectable:"on",role:"button",onMouseUp:f,onMouseLeave:f,onMouseDown:g=>{d(g)},"aria-label":a?"Increase Value":"Decrease Value","aria-disabled":n,className:p,style:o},r||y.createElement("span",{unselectable:"on",className:`${e}-action-${t}-inner`}))}function Qq(e){const t=typeof e=="number"?nA(e):Og(e).fullStr;return t.includes(".")?Og(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}const WGe=(()=>{const e=y.useRef(0),t=()=>{Or.cancel(e.current)};return y.useEffect(()=>t,[]),r=>{t(),e.current=Or(()=>{r()})}});function _w(){return _w=Object.assign?Object.assign.bind():function(e){for(var t=1;te||t.isEmpty()?t.toString():t.toNumber(),eX=e=>{const t=jl(e);return t.isInvalidate()?null:t},UGe=y.forwardRef((e,t)=>{const{mode:r="input",prefixCls:n="rc-input-number",className:i,style:o,classNames:s,styles:a,min:l,max:c,step:u=1,defaultValue:d,value:h,disabled:p,readOnly:f,upHandler:g,downHandler:m,keyboard:v,changeOnWheel:b=!1,controls:S=!0,prefix:x,suffix:E,stringMode:R,parser:T,formatter:M,precision:D,decimalSeparator:A,onChange:I,onInput:L,onPressEnter:F,onStep:k,onMouseDown:O,onClick:B,onMouseUp:H,onMouseLeave:N,onMouseMove:z,onMouseEnter:W,onMouseOut:V,changeOnBlur:$=!0,...K}=e,[q,X]=y.useState(!1),Y=y.useRef(!1),oe=y.useRef(!1),ee=y.useRef(!1),ne=y.useRef(null),le=y.useRef(null);y.useImperativeHandle(t,()=>GGe(le.current,{focus:_e=>{X3(le.current,_e)},blur:()=>{var _e;(_e=le.current)==null||_e.blur()},nativeElement:ne.current}));const[he,re]=y.useState(()=>jl(h??d));function ie(_e){h===void 0&&re(_e)}const de=y.useCallback((_e,qe)=>{if(!qe)return D>=0?D:Math.max(bg(_e),bg(u))},[D,u]),J=y.useCallback(_e=>{const qe=String(_e);if(T)return T(qe);let Re=qe;return A&&(Re=Re.replace(A,".")),Re.replace(/[^\w.-]+/g,"")},[T,A]),ue=y.useRef(""),ve=y.useCallback((_e,qe)=>{if(M)return M(_e,{userTyping:qe,input:String(ue.current)});let Re=typeof _e=="number"?nA(_e):_e;if(!qe){const it=de(Re,qe);P4(Re)&&(A||it>=0)&&(Re=gP(Re,A||".",it))}return Re},[M,de,A]),[pe,me]=y.useState(()=>{const _e=d??h;return he.isInvalidate()&&["string","number"].includes(typeof _e)?Number.isNaN(_e)?"":_e:ve(he.toString(),!1)});ue.current=pe;function ke(_e,qe){me(ve(_e.isInvalidate()?_e.toString(!1):_e.toString(!qe),qe))}const De=y.useMemo(()=>eX(c),[c,D]),Ee=y.useMemo(()=>eX(l),[l,D]),We=y.useMemo(()=>!De||!he||he.isInvalidate()?!1:De.lessEquals(he),[De,he]),ze=y.useMemo(()=>!Ee||!he||he.isInvalidate()?!1:he.lessEquals(Ee),[Ee,he]),[mt,Nt]=VGe(le.current,q),St=_e=>De&&!_e.lessEquals(De)?De:Ee&&!Ee.lessEquals(_e)?Ee:null,Ze=_e=>!St(_e),Fe=(_e,qe)=>{let Re=_e,it=Ze(Re)||Re.isEmpty();if(!Re.isEmpty()&&!qe&&(Re=St(Re)||Re,it=!0),!f&&!p&&it){const Ve=Re.toString(),Oe=de(Ve,qe);return Oe>=0&&(Re=jl(gP(Ve,".",Oe)),Ze(Re)||(Re=jl(gP(Ve,".",Oe,!0)))),Re.equals(he)||(ie(Re),I==null||I(Re.isEmpty()?null:Jq(R,Re)),h===void 0&&ke(Re,qe)),Re}return he},tt=WGe(),Ne=_e=>{if(mt(),ue.current=_e,me(_e),!oe.current){const qe=J(_e),Re=jl(qe);Re.isNaN()||Fe(Re,!0)}L==null||L(_e),tt(()=>{let qe=_e;T||(qe=_e.replace(/。/g,".")),qe!==_e&&Ne(qe)})},rt=()=>{oe.current=!0},ot=()=>{oe.current=!1,Ne(le.current.value)},Ye=_e=>{Ne(_e.target.value)},Ae=br((_e,qe)=>{var Oe;if(_e&&We||!_e&&ze)return;Y.current=!1;let Re=jl(ee.current?Qq(u):u);_e||(Re=Re.negate());const it=(he||jl(0)).add(Re.toString()),Ve=Fe(it,!1);k==null||k(Jq(R,Ve),{offset:ee.current?Qq(u):u,type:_e?"up":"down",emitter:qe}),(Oe=le.current)==null||Oe.focus()}),nt=_e=>{const qe=jl(J(pe));let Re;qe.isNaN()?Re=Fe(he,_e):Re=Fe(qe,_e),h!==void 0?ke(he,!1):Re.isNaN()||ke(Re,!1)},Et=()=>{Y.current=!0},Tt=_e=>{const{key:qe,shiftKey:Re}=_e;Y.current=!0,ee.current=Re,qe==="Enter"&&(oe.current||(Y.current=!1),nt(!1),F==null||F(_e)),v!==!1&&!oe.current&&["Up","ArrowUp","Down","ArrowDown"].includes(qe)&&(Ae(qe==="Up"||qe==="ArrowUp","keyboard"),_e.preventDefault())},kt=()=>{Y.current=!1,ee.current=!1};y.useEffect(()=>{if(b&&q){const _e=Re=>{Ae(Re.deltaY<0,"wheel"),Re.preventDefault()},qe=le.current;if(qe)return qe.addEventListener("wheel",_e,{passive:!1}),()=>qe.removeEventListener("wheel",_e)}});const Wt=()=>{$&&nt(!1),X(!1),Y.current=!1},at=_e=>{le.current&&_e.target!==le.current&&(le.current.focus(),_e.preventDefault()),O==null||O(_e)};iP(()=>{he.isInvalidate()||ke(he,!1)},[D,M]),iP(()=>{const _e=jl(h);re(_e);const qe=jl(J(pe));(!_e.equals(qe)||!Y.current||M)&&ke(_e,Y.current)},[h]),iP(()=>{M&&Nt()},[pe]);const lt={prefixCls:n,onStep:Ae,className:s==null?void 0:s.action,style:a==null?void 0:a.action},Ut=y.createElement(Zq,_w({},lt,{action:"up",disabled:We}),g),cr=y.createElement(Zq,_w({},lt,{action:"down",disabled:ze}),m);return y.createElement("div",{ref:ne,className:Q(n,`${n}-mode-${r}`,i,s==null?void 0:s.root,{[`${n}-focused`]:q,[`${n}-disabled`]:p,[`${n}-readonly`]:f,[`${n}-not-a-number`]:he.isNaN(),[`${n}-out-of-range`]:!he.isInvalidate()&&!Ze(he)}),style:{...a==null?void 0:a.root,...o},onMouseDown:at,onMouseUp:H,onMouseLeave:N,onMouseMove:z,onMouseEnter:W,onMouseOut:V,onClick:B,onFocus:()=>{X(!0)},onBlur:Wt,onKeyDown:Tt,onKeyUp:kt,onCompositionStart:rt,onCompositionEnd:ot,onBeforeInput:Et},r==="spinner"&&S&&cr,x!==void 0&&y.createElement("div",{className:Q(`${n}-prefix`,s==null?void 0:s.prefix),style:a==null?void 0:a.prefix},x),y.createElement("input",_w({autoComplete:"off",role:"spinbutton","aria-valuemin":l,"aria-valuemax":c,"aria-valuenow":he.isInvalidate()?null:he.toString(),step:u,ref:le,className:Q(`${n}-input`,s==null?void 0:s.input),style:a==null?void 0:a.input,value:pe,onChange:Ye,disabled:p,readOnly:f},K)),E!==void 0&&y.createElement("div",{className:Q(`${n}-suffix`,s==null?void 0:s.suffix),style:a==null?void 0:a.suffix},E),r==="spinner"&&S&&Ut,r==="input"&&S&&y.createElement("div",{className:Q(`${n}-actions`,s==null?void 0:s.actions),style:a==null?void 0:a.actions},Ut,cr))}),jGe=e=>{const{componentCls:t,borderRadius:r,paddingSM:n,colorBorder:i,paddingXS:o,fontSizeLG:s,fontSizeSM:a,borderRadiusLG:l,borderRadiusSM:c,colorBgContainerDisabled:u,lineWidth:d,antCls:h}=e,[p,f]=Jn(h,"space");return{[t]:[{display:"inline-flex",alignItems:"center",gap:0,paddingInline:n,margin:0,borderWidth:d,borderStyle:"solid",borderRadius:r,"&:hover":{zIndex:0},[`&${t}-disabled`]:{color:e.colorTextDisabled},"&-large":{fontSize:s,borderRadius:l},"&-small":{paddingInline:o,borderRadius:c,fontSize:a},"&-compact-last-item":{borderEndStartRadius:0,borderStartStartRadius:0},"&-compact-first-item":{borderEndEndRadius:0,borderStartEndRadius:0},"&-compact-item:not(:first-child):not(:last-child)":{borderRadius:0},"&-compact-item:not(:last-child)":{borderInlineEndWidth:0},"&-compact-item:not(:first-child)":{borderInlineStartWidth:0}},{[p("addon-border-color")]:i,[p("addon-background")]:u,[p("addon-border-color-outlined")]:i,[p("addon-background-filled")]:u,borderColor:f("addon-border-color"),background:f("addon-background"),"&-variant-outlined":{[p("addon-border-color")]:f("addon-border-color-outlined")},"&-variant-filled":{[p("addon-border-color")]:"transparent",[p("addon-background")]:f("addon-background-filled"),[`&${t}-disabled`]:{[p("addon-border-color")]:i,[p("addon-background")]:u}},"&-variant-borderless":{border:"none",background:"transparent"},"&-variant-underlined":{border:"none",background:"transparent"}},{"&-status-error":{[p("addon-border-color-outlined")]:e.colorError,[p("addon-background-filled")]:e.colorErrorBg,color:e.colorError},"&-status-warning":{[p("addon-border-color-outlined")]:e.colorWarning,[p("addon-background-filled")]:e.colorWarningBg,color:e.colorWarning}}]}},KGe=Wr(["Space","Addon"],e=>[jGe(e),Bx(e,{focus:!1})]),Vue=Z.forwardRef((e,t)=>{const{className:r,children:n,style:i,prefixCls:o,variant:s="outlined",disabled:a,status:l,...c}=e,{getPrefixCls:u,direction:d}=Z.useContext(ir),h=u("space-addon",o),[p,f]=KGe(h),{compactItemClassnames:g,compactSize:m}=Wp(h,d),v=Wy(h,l),b=Q(h,p,g,f,`${h}-variant-${s}`,v,{[`${h}-${m}`]:m,[`${h}-disabled`]:a},r);return Z.createElement("div",{ref:t,className:b,style:i,...c},n)}),qGe=e=>{const t=e.handleVisible??"auto",r=e.controlHeightSM-e.lineWidth*2;return{...OC(e),controlWidth:90,handleWidth:r,handleFontSize:e.fontSize/2,handleVisible:t,handleActiveBg:e.colorFillAlter,handleBg:e.colorBgContainer,filledHandleBg:new cn(e.colorFillSecondary).onBackground(e.colorBgContainer).toHexString(),handleHoverColor:e.colorPrimary,handleBorderColor:e.colorBorder,handleOpacity:t===!0?1:0,handleVisibleWidth:t===!0?r:0}},XGe=e=>{const{componentCls:t,lineWidth:r,lineType:n,borderRadius:i,inputFontSizeSM:o,inputFontSizeLG:s,colorError:a,paddingInlineSM:l,paddingBlockSM:c,paddingBlockLG:u,paddingInlineLG:d,colorIcon:h,motionDurationMid:p,handleHoverColor:f,handleOpacity:g,paddingInline:m,paddingBlock:v,handleBg:b,handleActiveBg:S,inputAffixPadding:x,borderRadiusSM:E,controlWidth:R,handleBorderColor:T,filledHandleBg:M,lineHeightLG:D,antCls:A}=e,I=`${ae(r)} ${n} ${T}`,[L,F]=Jn(A,"input-number");return[{[t]:{...on(e),...rA(e),[L("input-padding-block")]:ae(v),[L("input-padding-inline")]:ae(m),display:"inline-flex",width:R,margin:0,paddingBlock:0,borderRadius:i,...gue(e,{[`${t}-actions`]:{background:b,[`${t}-action-down`]:{borderBlockStart:I}}}),...yue(e,{[`${t}-actions`]:{background:M,[`${t}-action-down`]:{borderBlockStart:I}},"&:focus-within":{[`${t}-actions`]:{background:b}}}),...bue(e,{[`${t}-actions`]:{background:b,[`${t}-action-down`]:{borderBlockStart:I}}}),...mue(e),[`&${t}-borderless`]:{paddingBlock:0,[L("input-padding-block")]:ae(e.calc(v).add(r).equal())},[`&${t}-borderless${t}-sm`]:{paddingBlock:0,[L("input-padding-block")]:ae(e.calc(c).add(r).equal())},[`&${t}-borderless${t}-lg`]:{paddingBlock:0,[L("input-padding-block")]:ae(e.calc(u).add(r).equal())},"&-rtl":{direction:"rtl",[`${t}-input`]:{direction:"rtl"}},[`&${t}-out-of-range`]:{[`${t}-input`]:{color:a}},[`${t}-input`]:{...on(e),width:"100%",paddingBlock:F("input-padding-block"),textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:i,outline:0,transition:`all ${p} linear`,appearance:"textfield",fontSize:"inherit",lineHeight:"inherit",...Sue(e.colorTextPlaceholder),'&[type="number"]::-webkit-inner-spin-button, &[type="number"]::-webkit-outer-spin-button':{margin:0,appearance:"none"}},[`&:hover ${t}-handler-wrap, &-focused ${t}-handler-wrap`]:{width:e.handleWidth,opacity:1},[`&-disabled ${t}-input`]:{cursor:"not-allowed",color:e.colorTextDisabled}}},{[t]:{[` ${t}-action-up-disabled, ${t}-action-down-disabled `]:{cursor:"not-allowed"},[`${t}-action`]:{...Ix(),userSelect:"none",overflow:"hidden",fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",transition:`all ${p} linear`,"&:active":{background:S},"&:hover":{color:f}},"&-mode-input":{overflow:"hidden",[`${t}-actions`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleVisibleWidth,opacity:g,height:"100%",borderRadius:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`all ${p}`,overflow:"hidden",[`${t}-action`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",marginInlineEnd:0,fontSize:e.handleFontSize}},[`&:hover ${t}-actions, &-focused ${t}-actions`]:{width:e.handleWidth,opacity:1},[`${t}-action`]:{color:h,height:"50%",borderInlineStart:I,"&:hover":{height:"60%"}},[`&${t}-disabled, &${t}-readonly`]:{[`${t}-actions`]:{display:"none"}}},[`&${t}-mode-spinner`]:{padding:0,width:"auto",[`${t}-action`]:{flex:"none",paddingInline:F("input-padding-inline"),"&-up":{borderInlineStart:I},"&-down":{borderInlineEnd:I}},[`${t}-input`]:{textAlign:"center",paddingInline:F("input-padding-inline")}}}},{[t]:{"&-lg":{[L("input-padding-block")]:ae(u),[L("input-padding-inline")]:ae(d),paddingBlock:0,fontSize:s,lineHeight:D},"&-sm":{[L("input-padding-block")]:ae(c),[L("input-padding-inline")]:ae(l),paddingBlock:0,fontSize:o,borderRadius:E}}},{[t]:{[`${t}-prefix, ${t}-suffix`]:{display:"flex",flex:"none",alignItems:"center",alignSelf:"center",pointerEvents:"none"},[`${t}-prefix`]:{marginInlineEnd:x},[`${t}-suffix`]:{height:"100%",marginInlineStart:x,transition:`margin ${p}`},[`&:hover:not(${t}-without-controls)`]:{[`${t}-suffix`]:{marginInlineEnd:e.handleWidth}}}}]},YGe=e=>{const{componentCls:t,antCls:r}=e;return{[`${t}-addon`]:{[`&:has(${r}-select)`]:{border:0,padding:0}}}},ZGe=Wr("InputNumber",e=>{const t=$r(e,_C(e));return[XGe(t),YGe(t),Bx(t)]},qGe,{unitless:{handleOpacity:!0},resetFont:!1}),QGe=y.forwardRef((e,t)=>{const r=y.useRef(null);y.useImperativeHandle(t,()=>r.current);const{rootClassName:n,size:i,disabled:o,prefixCls:s,addonBefore:a,addonAfter:l,prefix:c,suffix:u,bordered:d,readOnly:h,status:p,controls:f=!0,variant:g,className:m,style:v,classNames:b,styles:S,mode:x,...E}=e,{direction:R,className:T,style:M,styles:D,classNames:A}=Nr("inputNumber"),I=y.useContext(hs),L=o??I,F=y.useMemo(()=>!f||L||h?!1:f,[f,L,h]),{compactSize:k,compactItemClassnames:O}=Wp(s,R);let B=x==="spinner"?y.createElement(Eue,null):y.createElement(NGe,null),H=x==="spinner"?y.createElement(_Ge,null):y.createElement(XD,null);const N=typeof F=="boolean"?F:void 0;typeof F=="object"&&(B=F.upIcon||B,H=F.downIcon||H);const{hasFeedback:z,isFormItemInput:W,feedbackIcon:V}=y.useContext(ua),$=ki(ne=>i??k??ne),[K,q]=jx("inputNumber",g,d),X=z&&y.createElement(y.Fragment,null,V),Y={...e,size:$,disabled:L,controls:F},[oe,ee]=Vr([A,b],[D,S],{props:Y});return y.createElement(UGe,{ref:r,mode:x,disabled:L,className:Q(m,n,oe.root,T,O,Wy(s,p,z),{[`${s}-${K}`]:q,[`${s}-lg`]:$==="large",[`${s}-sm`]:$==="small",[`${s}-rtl`]:R==="rtl",[`${s}-in-form-item`]:W,[`${s}-without-controls`]:!F}),style:{...ee.root,...M,...v},upHandler:B,downHandler:H,prefixCls:s,readOnly:h,controls:N,prefix:c,suffix:X||u,classNames:oe,styles:ee,...E})}),zue=y.forwardRef((e,t)=>{const{addonBefore:r,addonAfter:n,prefixCls:i,className:o,status:s,rootClassName:a,...l}=e,{getPrefixCls:c}=Nr("inputNumber"),u=c("input-number",i),{status:d}=y.useContext(ua),h=Ux(d,s),p=ho(u),[f,g]=ZGe(u,p),m=r||n,v=y.createElement(QGe,{ref:t,...l,prefixCls:u,status:h,className:Q(g,p,f,o),rootClassName:m?void 0:a});if(m){const b=E=>E?y.createElement(Vue,{className:Q(`${u}-addon`,g,f),variant:e.variant,disabled:e.disabled,status:h},y.createElement(Rp,{form:!0},E)):null,S=b(r),x=b(n);return y.createElement($3,{rootClassName:a},S,v,x)}return v}),JGe=zue,eVe=e=>y.createElement(Iu,{theme:{components:{InputNumber:{handleVisible:!0}}}},y.createElement(zue,{...e}));JGe._InternalPanelDoNotUseOrYouWillBeFired=eVe;function tVe(e){return!!(e.addonBefore||e.addonAfter)}function rVe(e){return!!(e.prefix||e.suffix||e.allowClear)}function tX(e,t,r){const n=t.cloneNode(!0),i=Object.create(e,{target:{value:n},currentTarget:{value:n}});return n.value=r,typeof t.selectionStart=="number"&&typeof t.selectionEnd=="number"&&(n.selectionStart=t.selectionStart,n.selectionEnd=t.selectionEnd),n.setSelectionRange=(...o)=>{t.setSelectionRange(...o)},i}function EM(e,t,r,n){if(!r)return;let i=t;if(t.type==="click"){i=tX(t,e,""),r(i);return}if(e.type!=="file"&&n!==void 0){i=tX(t,e,n),r(i);return}r(i)}function Y$(){return Y$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var z,W,V;const{inputElement:r,children:n,prefixCls:i,prefix:o,suffix:s,addonBefore:a,addonAfter:l,className:c,style:u,disabled:d,readOnly:h,focused:p,triggerFocus:f,allowClear:g,value:m,handleReset:v,hidden:b,classes:S,classNames:x,dataAttrs:E,styles:R,components:T,onClear:M}=e,D=n??r,A=(T==null?void 0:T.affixWrapper)||"span",I=(T==null?void 0:T.groupWrapper)||"span",L=(T==null?void 0:T.wrapper)||"span",F=(T==null?void 0:T.groupAddon)||"span",k=y.useRef(null),O=$=>{var K;(K=k.current)!=null&&K.contains($.target)&&(f==null||f())},B=rVe(e);let H=y.cloneElement(D,{value:m,className:Q((z=D.props)==null?void 0:z.className,!B&&(x==null?void 0:x.variant))||null});const N=y.useRef(null);if(Z.useImperativeHandle(t,()=>({nativeElement:N.current||k.current})),B){let $=null;if(g){const Y=!d&&!h&&m,oe=`${i}-clear-icon`,ee=typeof g=="object"&&(g!=null&&g.clearIcon)?g.clearIcon:"✖";$=Z.createElement("button",{type:"button",tabIndex:-1,onClick:ne=>{v==null||v(ne),M==null||M()},onMouseDown:ne=>ne.preventDefault(),className:Q(oe,{[`${oe}-hidden`]:!Y,[`${oe}-has-suffix`]:!!s})},ee)}const K=`${i}-affix-wrapper`,q=Q(K,{[`${i}-disabled`]:d,[`${K}-disabled`]:d,[`${K}-focused`]:p,[`${K}-readonly`]:h,[`${K}-input-with-clear-btn`]:s&&g&&m},S==null?void 0:S.affixWrapper,x==null?void 0:x.affixWrapper,x==null?void 0:x.variant),X=(s||g)&&Z.createElement("span",{className:Q(`${i}-suffix`,x==null?void 0:x.suffix),style:R==null?void 0:R.suffix},$,s);H=Z.createElement(A,Y$({className:q,style:R==null?void 0:R.affixWrapper,onClick:O},E==null?void 0:E.affixWrapper,{ref:k}),o&&Z.createElement("span",{className:Q(`${i}-prefix`,x==null?void 0:x.prefix),style:R==null?void 0:R.prefix},o),H,X)}if(tVe(e)){const $=`${i}-group`,K=`${$}-addon`,q=`${$}-wrapper`,X=Q(`${i}-wrapper`,$,S==null?void 0:S.wrapper,x==null?void 0:x.wrapper),Y=Q(q,{[`${q}-disabled`]:d},S==null?void 0:S.group,x==null?void 0:x.groupWrapper);H=Z.createElement(I,{className:Y,ref:N},Z.createElement(L,{className:X},a&&Z.createElement(F,{className:K},a),H,l&&Z.createElement(F,{className:K},l)))}return Z.cloneElement(H,{className:Q((W=H.props)==null?void 0:W.className,c)||null,style:{...(V=H.props)==null?void 0:V.style,...u},hidden:b})});function Wue(e,t){return y.useMemo(()=>{let r={};t&&(r.show=typeof t=="object"&&t.formatter?t.formatter:!!t),r={...r,...e};const{show:n,...i}=r;return{...i,show:!!n,showFormatter:typeof n=="function"?n:void 0,strategy:i.strategy||(o=>o.length)}},[e,t])}function TM(){return TM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{autoComplete:r,onChange:n,onFocus:i,onBlur:o,onPressEnter:s,onKeyDown:a,onKeyUp:l,prefixCls:c="rc-input",disabled:u,htmlSize:d,className:h,maxLength:p,suffix:f,showCount:g,count:m,type:v="text",classes:b,classNames:S,styles:x,onCompositionStart:E,onCompositionEnd:R,...T}=e,[M,D]=y.useState(!1),A=y.useRef(!1),I=y.useRef(!1),L=y.useRef(null),F=y.useRef(null),k=J=>{L.current&&X3(L.current,J)},[O,B]=An(e.defaultValue,e.value),H=O==null?"":String(O),[N,z]=y.useState(null),W=Wue(m,g),V=W.max||p,$=W.strategy(H),K=!!V&&$>V;y.useImperativeHandle(t,()=>{var J;return{focus:k,blur:()=>{var ue;(ue=L.current)==null||ue.blur()},setSelectionRange:(ue,ve,pe)=>{var me;(me=L.current)==null||me.setSelectionRange(ue,ve,pe)},select:()=>{var ue;(ue=L.current)==null||ue.select()},input:L.current,nativeElement:((J=F.current)==null?void 0:J.nativeElement)||L.current}}),y.useEffect(()=>{I.current&&(I.current=!1),D(J=>J&&u?!1:J)},[u]);const q=(J,ue,ve)=>{var me,ke;let pe=ue;if(!A.current&&W.exceedFormatter&&W.max&&W.strategy(ue)>W.max)pe=W.exceedFormatter(ue,{max:W.max}),ue!==pe&&z([((me=L.current)==null?void 0:me.selectionStart)||0,((ke=L.current)==null?void 0:ke.selectionEnd)||0]);else if(ve.source==="compositionEnd")return;B(pe),L.current&&EM(L.current,J,n,pe)};y.useEffect(()=>{var J;N&&((J=L.current)==null||J.setSelectionRange(...N))},[N]);const X=J=>{q(J,J.target.value,{source:"change"})},Y=J=>{A.current=!1,q(J,J.currentTarget.value,{source:"compositionEnd"}),R==null||R(J)},oe=J=>{s&&J.key==="Enter"&&!I.current&&!J.nativeEvent.isComposing&&(I.current=!0,s(J)),a==null||a(J)},ee=J=>{J.key==="Enter"&&(I.current=!1),l==null||l(J)},ne=J=>{D(!0),i==null||i(J)},le=J=>{I.current&&(I.current=!1),D(!1),o==null||o(J)},he=J=>{B(""),k(),L.current&&EM(L.current,J,n)},re=K&&`${c}-out-of-range`,ie=()=>{const J=fn(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames","onClear"]);return Z.createElement("input",TM({autoComplete:r},J,{onChange:X,onFocus:ne,onBlur:le,onKeyDown:oe,onKeyUp:ee,className:Q(c,{[`${c}-disabled`]:u},S==null?void 0:S.input),style:x==null?void 0:x.input,ref:L,size:d,type:v,onCompositionStart:ue=>{A.current=!0,E==null||E(ue)},onCompositionEnd:Y}))},de=()=>{const J=Number(V)>0;if(f||W.show){const ue=W.showFormatter?W.showFormatter({value:H,count:$,maxLength:V}):`${$}${J?` / ${V}`:""}`;return Z.createElement(Z.Fragment,null,W.show&&Z.createElement("span",{className:Q(`${c}-show-count-suffix`,{[`${c}-show-count-has-suffix`]:!!f},S==null?void 0:S.count),style:{...x==null?void 0:x.count}},ue),f)}return null};return Z.createElement(Hue,TM({},T,{prefixCls:c,className:Q(h,re),handleReset:he,value:H,focused:M,triggerFocus:k,suffix:de(),disabled:u,classes:b,classNames:S,styles:x,ref:F}),ie())}),Uue=e=>{let t;return typeof e=="object"&&(e!=null&&e.clearIcon)?t=e:e&&(t={clearIcon:Z.createElement(Ax,null)}),t};function jue(e,t){const r=y.useRef([]),n=()=>{r.current.push(setTimeout(()=>{var i,o,s,a;(i=e.current)!=null&&i.input&&((o=e.current)==null?void 0:o.input.getAttribute("type"))==="password"&&((s=e.current)!=null&&s.input.hasAttribute("value"))&&((a=e.current)==null||a.input.removeAttribute("value"))}))};return y.useEffect(()=>(t&&n(),()=>r.current.forEach(i=>{i&&clearTimeout(i)})),[]),n}function iVe(e){return!!(e.prefix||e.suffix||e.allowClear||e.showCount)}const Qx=y.forwardRef((e,t)=>{const{prefixCls:r,bordered:n=!0,status:i,size:o,disabled:s,onBlur:a,onFocus:l,suffix:c,allowClear:u,addonAfter:d,addonBefore:h,className:p,style:f,styles:g,rootClassName:m,onChange:v,classNames:b,variant:S,...x}=e,{getPrefixCls:E,direction:R,allowClear:T,autoComplete:M,className:D,style:A,classNames:I,styles:L}=Nr("input"),F=E("input",r),k=y.useRef(null),O=ho(F),[B,H]=wue(F,m);xue(F,O);const{compactSize:N,compactItemClassnames:z}=Wp(F,R),W=ki(me=>o??N??me),V=Z.useContext(hs),$=s??V,K={...e,size:W,disabled:$},[q,X]=Vr([I,b],[L,g],{props:K}),{status:Y,hasFeedback:oe,feedbackIcon:ee}=y.useContext(ua),ne=Ux(Y,i),le=iVe(e)||!!oe;y.useRef(le);const he=jue(k,!0),re=me=>{he(),a==null||a(me)},ie=me=>{he(),l==null||l(me)},de=me=>{he(),v==null||v(me)},J=(oe||c)&&Z.createElement(Z.Fragment,null,c,oe&&ee),ue=Uue(u??T),[ve,pe]=jx("input",S,n);return Z.createElement(nVe,{ref:Wo(t,k),prefixCls:F,autoComplete:M,...x,disabled:$,onBlur:re,onFocus:ie,style:{...X.root,...A,...f},styles:X,suffix:J,allowClear:ue,className:Q(p,m,H,O,z,D,q.root),onChange:de,addonBefore:h&&Z.createElement(Rp,{form:!0,space:!0},h),addonAfter:d&&Z.createElement(Rp,{form:!0,space:!0},d),classNames:{...q,input:Q({[`${F}-sm`]:W==="small",[`${F}-lg`]:W==="large",[`${F}-rtl`]:R==="rtl"},q.input,B),variant:Q({[`${F}-${ve}`]:pe},Wy(F,ne)),affixWrapper:Q({[`${F}-affix-wrapper-sm`]:W==="small",[`${F}-affix-wrapper-lg`]:W==="large",[`${F}-affix-wrapper-rtl`]:R==="rtl"},B),wrapper:Q({[`${F}-group-rtl`]:R==="rtl"},B),groupWrapper:Q({[`${F}-group-wrapper-sm`]:W==="small",[`${F}-group-wrapper-lg`]:W==="large",[`${F}-group-wrapper-rtl`]:R==="rtl",[`${F}-group-wrapper-${ve}`]:pe},Wy(`${F}-group-wrapper`,ne,oe),B)}})}),oVe={xxxl:4,xxl:3,xl:3,lg:3,md:3,sm:2,xs:1},M4=Z.createContext(null),sVe=e=>Li(e).map(t=>({...t==null?void 0:t.props,key:t.key}));function aVe(e,t,r){const n=y.useMemo(()=>t||sVe(r),[t,r]);return y.useMemo(()=>n.map(({span:o,...s})=>o==="filled"?{...s,filled:!0}:{...s,span:typeof o=="number"?o:Dce(e,o)}),[n,e])}function lVe(e,t){let r=[],n=[],i=!1,o=0;return e.filter(s=>s).forEach(s=>{const{filled:a,...l}=s;if(a){n.push(l),r.push(n),n=[],o=0;return}const c=t-o;o+=s.span||1,o>=t?(o>t?(i=!0,n.push({...l,span:c})):n.push(l),r.push(n),n=[],o=0):n.push(l)}),n.length>0&&r.push(n),r=r.map(s=>{const a=s.reduce((l,c)=>l+(c.span||1),0);if(a{const[r,n]=y.useMemo(()=>lVe(t,e),[t,e]);return r},uVe=e=>e.children,iO=e=>{const{itemPrefixCls:t,component:r,span:n,className:i,style:o,labelStyle:s,contentStyle:a,bordered:l,label:c,content:u,colon:d,type:h,styles:p,classNames:f}=e,g=r,{classNames:m,styles:v}=Z.useContext(M4),[b,S]=Vr([m,f],[v,p],{props:e}),x={...s,...S.label},E={...a,...S.content};return l?Z.createElement(g,{colSpan:n,style:o,className:Q(i,{[`${t}-item-${h}`]:h==="label"||h==="content",[b.label]:b.label&&h==="label",[b.content]:b.content&&h==="content"})},Tn(c)&&Z.createElement("span",{style:x},c),Tn(u)&&Z.createElement("span",{style:E},u)):Z.createElement(g,{className:Q(`${t}-item`,i),style:o,colSpan:n},Z.createElement("div",{className:`${t}-item-container`},Tn(c)&&Z.createElement("span",{style:x,className:Q(`${t}-item-label`,b.label,{[`${t}-item-no-colon`]:!d})},c),Tn(u)&&Z.createElement("span",{style:E,className:Q(`${t}-item-content`,b.content)},u)))};function oO(e,{colon:t,prefixCls:r,bordered:n},{component:i,type:o,showLabel:s,showContent:a,labelStyle:l,contentStyle:c,styles:u}){return e.map(({label:d,children:h,prefixCls:p=r,className:f,style:g,labelStyle:m,contentStyle:v,span:b=1,key:S,styles:x,classNames:E},R)=>typeof i=="string"?y.createElement(iO,{key:`${o}-${S||R}`,className:f,style:g,classNames:E,styles:{label:{...l,...u==null?void 0:u.label,...m,...x==null?void 0:x.label},content:{...c,...u==null?void 0:u.content,...v,...x==null?void 0:x.content}},span:b,colon:t,component:i,itemPrefixCls:p,bordered:n,label:s?d:null,content:a?h:null,type:o}):[y.createElement(iO,{key:`label-${S||R}`,className:f,style:{...l,...u==null?void 0:u.label,...g,...m,...x==null?void 0:x.label},span:1,colon:t,component:i[0],itemPrefixCls:p,bordered:n,label:d,type:"label"}),y.createElement(iO,{key:`content-${S||R}`,className:f,style:{...c,...u==null?void 0:u.content,...g,...v,...x==null?void 0:x.content},span:b*2-1,component:i[1],itemPrefixCls:p,bordered:n,content:h,type:"content"})])}const dVe=e=>{const t=y.useContext(M4),{prefixCls:r,vertical:n,row:i,index:o,bordered:s}=e;return n?y.createElement(y.Fragment,null,y.createElement("tr",{key:`label-${o}`,className:`${r}-row`},oO(i,e,{component:"th",type:"label",showLabel:!0,...t})),y.createElement("tr",{key:`content-${o}`,className:`${r}-row`},oO(i,e,{component:"td",type:"content",showContent:!0,...t}))):y.createElement("tr",{key:o,className:`${r}-row`},oO(i,e,{component:s?["th","td"]:"td",type:"item",showLabel:!0,showContent:!0,...t}))},hVe=e=>{const{componentCls:t,labelBg:r}=e;return{[`&${t}-bordered`]:{[`> ${t}-view`]:{border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`,"> table":{tableLayout:"auto"},[`${t}-row`]:{borderBottom:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`,"&:first-child":{"> th:first-child, > td:first-child":{borderStartStartRadius:e.borderRadiusLG}},"&:last-child":{borderBottom:"none","> th:first-child, > td:first-child":{borderEndStartRadius:e.borderRadiusLG}},[`> ${t}-item-label, > ${t}-item-content`]:{padding:`${ae(e.padding)} ${ae(e.paddingLG)}`,borderInlineEnd:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`,"&:last-child":{borderInlineEnd:"none"}},[`> ${t}-item-label`]:{color:e.colorTextSecondary,backgroundColor:r,"&::after":{display:"none"}}}},[`&${t}-medium`]:{[`${t}-row`]:{[`> ${t}-item-label, > ${t}-item-content`]:{padding:`${ae(e.paddingSM)} ${ae(e.paddingLG)}`}}},[`&${t}-small`]:{[`${t}-row`]:{[`> ${t}-item-label, > ${t}-item-content`]:{padding:`${ae(e.paddingXS)} ${ae(e.padding)}`}}}}}},pVe=e=>{const{componentCls:t,extraColor:r,itemPaddingBottom:n,itemPaddingEnd:i,colonMarginRight:o,colonMarginLeft:s,titleMarginBottom:a}=e;return{[t]:{...on(e),...hVe(e),"&-rtl":{direction:"rtl"},[`${t}-header`]:{display:"flex",alignItems:"center",marginBottom:a},[`${t}-title`]:{...Ps,flex:"auto",color:e.titleColor,fontWeight:e.fontWeightStrong,fontSize:e.fontSizeLG,lineHeight:e.lineHeightLG},[`${t}-extra`]:{marginInlineStart:"auto",color:r,fontSize:e.fontSize},[`${t}-view`]:{width:"100%",borderRadius:e.borderRadiusLG,table:{width:"100%",tableLayout:"fixed",borderCollapse:"collapse"}},[`${t}-row`]:{"> th, > td":{paddingBottom:n,paddingInlineEnd:i},"> th:last-child, > td:last-child":{paddingInlineEnd:0},"&:last-child":{borderBottom:"none","> th, > td":{paddingBottom:0}}},[`${t}-item-label`]:{color:e.labelColor,fontWeight:"normal",fontSize:e.fontSize,lineHeight:e.lineHeight,textAlign:"start","&::after":{content:'":"',position:"relative",top:-.5,marginInline:`${ae(s)} ${ae(o)}`},[`&${t}-item-no-colon::after`]:{content:'""'}},[`${t}-item-no-label`]:{"&::after":{margin:0,content:'""'}},[`${t}-item-content`]:{display:"table-cell",flex:1,color:e.contentColor,fontSize:e.fontSize,lineHeight:e.lineHeight,wordBreak:"break-word",overflowWrap:"break-word"},[`${t}-item`]:{paddingBottom:0,verticalAlign:"top","&-container":{display:"flex",[`${t}-item-label`]:{display:"inline-flex",alignItems:"baseline"},[`${t}-item-content`]:{display:"inline-flex",alignItems:"baseline",minWidth:"1em"}}},"&-medium":{[`${t}-row`]:{"> th, > td":{paddingBottom:e.paddingSM}}},"&-small":{[`${t}-row`]:{"> th, > td":{paddingBottom:e.paddingXS}}}}}},fVe=e=>({labelBg:e.colorFillAlter,labelColor:e.colorTextTertiary,titleColor:e.colorText,titleMarginBottom:e.fontSizeSM*e.lineHeightSM,itemPaddingBottom:e.padding,itemPaddingEnd:e.padding,colonMarginRight:e.marginXS,colonMarginLeft:e.marginXXS/2,contentColor:e.colorText,extraColor:e.colorText}),gVe=Wr("Descriptions",e=>{const t=$r(e,{});return pVe(t)},fVe),mVe=e=>{const{prefixCls:t,title:r,extra:n,column:i,colon:o=!0,bordered:s,layout:a,children:l,className:c,rootClassName:u,style:d,size:h,labelStyle:p,contentStyle:f,styles:g,items:m,classNames:v,...b}=e,{getPrefixCls:S,direction:x,className:E,style:R,classNames:T,styles:M}=Nr("descriptions"),D=S("descriptions",t),A=Kx(),I=y.useMemo(()=>typeof i=="number"?i:Dce(A,{...oVe,...i})??3,[A,i]),L=aVe(A,m,l),F=ki(h),k=cVe(I,L),[O,B]=gVe(D),H={...e,column:I,items:L,size:F},[N,z]=Vr([T,v],[M,g],{props:H}),W=y.useMemo(()=>({labelStyle:p,contentStyle:f,styles:{label:z.label,content:z.content},classNames:{label:N.label,content:N.content}}),[p,f,z.label,z.content,N.label,N.content]);return y.createElement(M4.Provider,{value:W},y.createElement("div",{className:Q(D,E,N.root,{[`${D}-medium`]:F==="medium"||F==="middle",[`${D}-small`]:F==="small",[`${D}-bordered`]:!!s,[`${D}-rtl`]:x==="rtl"},c,u,O,B),style:{...R,...z.root,...d},...b},(r||n)&&y.createElement("div",{className:Q(`${D}-header`,N.header),style:z.header},r&&y.createElement("div",{className:Q(`${D}-title`,N.title),style:z.title},r),n&&y.createElement("div",{className:Q(`${D}-extra`,N.extra),style:z.extra},n)),y.createElement("div",{className:`${D}-view`},y.createElement("table",null,y.createElement("tbody",null,k.map((V,$)=>y.createElement(dVe,{key:$,index:$,colon:o,prefixCls:D,vertical:a==="vertical",bordered:s,row:V})))))))};mVe.Item=uVe;const rX=y.createContext(null),Kue=y.createContext({});function Z$(){return Z$=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:t,className:r,containerRef:n,...i}=e,{panel:o}=y.useContext(Kue),s=Pu(o,n);return y.createElement("div",Z$({className:Q(`${t}-section`,r),role:"dialog",ref:s},ai(e,{aria:!0}),{"aria-modal":"true"},i))};function yVe(e){const{prefixCls:t,direction:r,className:n,style:i,maxSize:o,containerRef:s,currentSize:a,onResize:l,onResizeEnd:c,onResizeStart:u}=e,[d,h]=y.useState(!1),[p,f]=y.useState(0),[g,m]=y.useState(0),v=r==="left"||r==="right",b=br(R=>{R.preventDefault(),R.stopPropagation(),h(!0),f(v?R.clientX:R.clientY);let T;if(typeof a=="number")T=a;else if(s!=null&&s.current){const M=s.current.getBoundingClientRect();T=v?M.width:M.height}m(T),u==null||u(T)}),S=br(R=>{if(!d)return;let M=(v?R.clientX:R.clientY)-p;(r==="right"||r==="bottom")&&(M=-M);let D=g+M;D<0&&(D=0),o&&D>o&&(D=o),l==null||l(D)}),x=y.useCallback(()=>{if(d&&(h(!1),s!=null&&s.current)){const R=s.current.getBoundingClientRect(),T=v?R.width:R.height;c==null||c(T)}},[d,s,c,v]);return y.useEffect(()=>{if(d)return document.addEventListener("mousemove",S),document.addEventListener("mouseup",x),()=>{document.removeEventListener("mousemove",S),document.removeEventListener("mouseup",x)}},[d,S,x]),{dragElementProps:{className:Q(`${t}-dragger`,`${t}-dragger-${r}`,{[`${t}-dragger-dragging`]:d,[`${t}-dragger-horizontal`]:v,[`${t}-dragger-vertical`]:!v},n),style:i,onMouseDown:b},isDragging:d}}function sO(e){if(typeof e=="string"){const t=Number(e.replace(/px$/i,""));if(parseFloat(e)===t&&Vn(!1,"Invalid value type of `width` or `height` which should be number type instead."),!Number.isNaN(t))return t}return e}function CVe(e,t,r,n,i){const o=n??i!==!1,[s]=Ble(t&&o,e);return Z.useEffect(()=>{var a;t&&r===!0&&((a=e())==null||a.focus({preventScroll:!0}))},[t]),s}function sy(){return sy=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,open:n,placement:i,inline:o,push:s,forceRender:a,autoFocus:l,focusTrap:c,classNames:u,rootClassName:d,rootStyle:h,zIndex:p,className:f,id:g,style:m,motion:v,width:b,height:S,size:x,maxSize:E,children:R,mask:T,maskClosable:M,maskMotion:D,maskClassName:A,maskStyle:I,afterOpenChange:L,onClose:F,onMouseEnter:k,onMouseOver:O,onMouseLeave:B,onClick:H,onKeyDown:N,onKeyUp:z,styles:W,drawerRender:V,resizable:$,defaultSize:K}=e,q=y.useRef(null);y.useImperativeHandle(t,()=>q.current);const X=CVe(()=>q.current,n,l,c,T),[Y,oe]=y.useState(!1),ee=y.useContext(rX);let ne;typeof s=="boolean"?ne=s?{}:{distance:0}:ne=s||{};const le=(ne==null?void 0:ne.distance)??(ee==null?void 0:ee.pushDistance)??180,he=y.useMemo(()=>({pushDistance:le,push:()=>{oe(!0)},pull:()=>{oe(!1)}}),[le]);y.useEffect(()=>{var Ze,Fe;n?(Ze=ee==null?void 0:ee.push)==null||Ze.call(ee):(Fe=ee==null?void 0:ee.pull)==null||Fe.call(ee)},[n]),y.useEffect(()=>()=>{var Ze;(Ze=ee==null?void 0:ee.pull)==null||Ze.call(ee)},[]);const re=y.createElement(gu,sy({key:"mask"},D,{visible:T&&n}),({className:Ze,style:Fe},tt)=>y.createElement("div",{className:Q(`${r}-mask`,Ze,u==null?void 0:u.mask,A),style:{...Fe,...I,...W==null?void 0:W.mask},onClick:M&&n?F:void 0,ref:tt})),ie=typeof v=="function"?v(i):v,[de,J]=y.useState(),ue=i==="left"||i==="right",ve=y.useMemo(()=>sO(x??(ue?b:S)??de??K??(ue?378:void 0)),[x,b,S,K,ue,de]),pe=y.useMemo(()=>{const Ze={};if(Y&&le)switch(i){case"top":Ze.transform=`translateY(${le}px)`;break;case"bottom":Ze.transform=`translateY(${-le}px)`;break;case"left":Ze.transform=`translateX(${le}px)`;break;default:Ze.transform=`translateX(${-le}px)`;break}return ue?Ze.width=sO(ve):Ze.height=sO(ve),Ze},[Y,le,i,ue,ve]),me=y.useRef(null),ke=!!$,De=typeof $=="object"&&$||{},Ee=br(Ze=>{var Fe;J(Ze),(Fe=De.onResize)==null||Fe.call(De,Ze)}),{dragElementProps:We,isDragging:ze}=yVe({prefixCls:`${r}-resizable`,direction:i,className:u==null?void 0:u.dragger,style:W==null?void 0:W.dragger,maxSize:E,containerRef:me,currentSize:ve,onResize:Ee,onResizeStart:De.onResizeStart,onResizeEnd:De.onResizeEnd}),mt={onMouseEnter:k,onMouseOver:O,onMouseLeave:B,onClick:H,onKeyDown:N,onKeyUp:z,onFocus:Ze=>{X(Ze.target)}},Nt=y.createElement(gu,sy({key:"panel"},ie,{visible:n,forceRender:a,onVisibleChanged:L,removeOnLeave:!1,leavedClassName:`${r}-content-wrapper-hidden`}),({className:Ze,style:Fe},tt)=>{const Ne=y.createElement(vVe,sy({id:g,containerRef:tt,prefixCls:r,className:Q(f,u==null?void 0:u.section),style:{...m,...W==null?void 0:W.section}},ai(e,{aria:!0}),mt),R);return y.createElement("div",sy({ref:me,className:Q(`${r}-content-wrapper`,ze&&`${r}-content-wrapper-dragging`,u==null?void 0:u.wrapper,!ze&&Ze),style:{...Fe,...pe,...W==null?void 0:W.wrapper}},ai(e,{data:!0})),ke&&y.createElement("div",We),V?V(Ne):Ne)}),St={...h};return p&&(St.zIndex=p),y.createElement(rX.Provider,{value:he},y.createElement("div",{className:Q(r,`${r}-${i}`,d,{[`${r}-open`]:n,[`${r}-inline`]:o}),style:St,tabIndex:-1,ref:q},re,Nt))},SVe=y.forwardRef(bVe),wVe=e=>{const{open:t=!1,prefixCls:r="rc-drawer",placement:n="right",autoFocus:i=!0,keyboard:o=!0,width:s,height:a,size:l,maxSize:c,mask:u=!0,maskClosable:d=!0,getContainer:h,forceRender:p,afterOpenChange:f,destroyOnHidden:g,onMouseEnter:m,onMouseOver:v,onMouseLeave:b,onClick:S,onKeyDown:x,onKeyUp:E,onClose:R,resizable:T,defaultSize:M,focusTriggerAfterClose:D,panelRef:A}=e,[I,L]=y.useState(!1),[F,k]=y.useState(!1);jr(()=>{k(!0)},[]);const O=F?t:!1,B=y.useRef(null),H=y.useRef(null);jr(()=>{O&&(H.current=document.activeElement)},[O]);const N=K=>{var q,X;L(K),f==null||f(K),!K&&D!==!1&&H.current&&!((q=B.current)!=null&&q.contains(H.current))&&((X=H.current)==null||X.focus({preventScroll:!0}))},z=y.useMemo(()=>({panel:A}),[A]);if(!p&&!I&&!O&&g)return null;const V={...e,open:O,prefixCls:r,placement:n,autoFocus:i,keyboard:o,width:s,height:a,size:l,maxSize:c,defaultSize:M,mask:u,maskClosable:d,inline:h===!1,afterOpenChange:N,ref:B,resizable:T,...{onMouseEnter:m,onMouseOver:v,onMouseLeave:b,onClick:S,onKeyDown:x,onKeyUp:E}},$=({top:K,event:q})=>{K&&o&&(q.stopPropagation(),R==null||R(q))};return y.createElement(Kue.Provider,{value:z},y.createElement(_x,{open:O||p||I,autoDestroy:!1,getContainer:h,autoLock:u&&(O||I),onEsc:$},y.createElement(SVe,V)))},que=e=>{const{prefixCls:t,ariaId:r,title:n,footer:i,extra:o,closable:s,loading:a,onClose:l,headerStyle:c,bodyStyle:u,footerStyle:d,children:h,classNames:p,styles:f}=e,g=Nr("drawer"),{classNames:m,styles:v,closable:b}=g,[S,x]=Vr([m,p],[v,f],{props:{...e,closable:s??b}}),E=y.useMemo(()=>{const I=s??b;if(I!==!1)return typeof I=="object"&&(I==null?void 0:I.placement)==="end"?"end":"start"},[s,b]),R=y.useCallback(I=>y.createElement("button",{type:"button",onClick:l,className:Q(`${t}-close`,{[`${t}-close-${E}`]:E==="end"},S.close),style:x.close},I),[l,t,E,S.close,x.close]),[T,M]=O3(Vy(e),Vy(g),{closable:!0,closeIconRender:R}),D=()=>!n&&!T?null:y.createElement("div",{style:{...x.header,...c},className:Q(`${t}-header`,S.header,{[`${t}-header-close-only`]:T&&!n&&!o})},y.createElement("div",{className:`${t}-header-title`},E==="start"&&M,n&&y.createElement("div",{className:Q(`${t}-title`,S.title),style:x.title,id:r},n)),o&&y.createElement("div",{className:Q(`${t}-extra`,S.extra),style:x.extra},o),E==="end"&&M),A=()=>i?y.createElement("div",{className:Q(`${t}-footer`,S.footer),style:{...x.footer,...d}},i):null;return y.createElement(y.Fragment,null,D(),y.createElement("div",{className:Q(`${t}-body`,S.body),style:{...x.body,...u}},a?y.createElement(Up,{active:!0,title:!1,paragraph:{rows:5},className:`${t}-body-skeleton`}):h),A())},xVe=e=>{const t="100%";return{left:`translateX(-${t})`,right:`translateX(${t})`,top:`translateY(-${t})`,bottom:`translateY(${t})`}[e]},Xue=(e,t)=>({"&-enter, &-appear":{...e,"&-active":t},"&-leave":{...t,"&-active":e}}),Yue=(e,t)=>({"&-enter, &-appear, &-leave":{"&-start":{transition:"none"},"&-active":{transition:`all ${t}`}},...Xue({opacity:e},{opacity:1})}),EVe=(e,t)=>[Yue(.7,t),Xue({transform:xVe(e)},{transform:"none"})],TVe=e=>{const{componentCls:t,motionDurationSlow:r}=e;return{[t]:{[`${t}-mask-motion`]:Yue(0,r),[`${t}-panel-motion`]:["left","right","top","bottom"].reduce((n,i)=>({...n,[`&-${i}`]:EVe(i,r)}),{})}}},RVe=e=>{const{borderRadiusSM:t,componentCls:r,zIndexPopup:n,colorBgMask:i,colorBgElevated:o,motionDurationSlow:s,motionDurationMid:a,paddingXS:l,padding:c,paddingLG:u,fontSizeLG:d,lineHeightLG:h,lineWidth:p,lineType:f,colorSplit:g,marginXS:m,colorIcon:v,colorIconHover:b,colorBgTextHover:S,colorBgTextActive:x,colorText:E,fontWeightStrong:R,footerPaddingBlock:T,footerPaddingInline:M,draggerSize:D,calc:A}=e,I=`${r}-content-wrapper`,L=`${r}-resizable-dragger`;return{[r]:{position:"fixed",inset:0,zIndex:n,pointerEvents:"none",color:E,"&-pure":{position:"relative",background:o,display:"flex",flexDirection:"column",pointerEvents:"auto",[`&${r}-left`]:{boxShadow:e.boxShadowDrawerLeft},[`&${r}-right`]:{boxShadow:e.boxShadowDrawerRight},[`&${r}-top`]:{boxShadow:e.boxShadowDrawerUp},[`&${r}-bottom`]:{boxShadow:e.boxShadowDrawerDown}},"&-inline":{position:"absolute"},[`${r}-mask`]:{position:"absolute",inset:0,zIndex:n,background:i,pointerEvents:"auto",[`&${r}-mask-blur`]:{backdropFilter:"blur(4px)"}},[I]:{position:"absolute",zIndex:n,maxWidth:"100vw",transition:`all ${s}`,"&-hidden":{display:"none"}},[`&-left > ${I}`]:{top:0,bottom:0,left:{_skip_check_:!0,value:0},boxShadow:e.boxShadowDrawerLeft},[`&-right > ${I}`]:{top:0,right:{_skip_check_:!0,value:0},bottom:0,boxShadow:e.boxShadowDrawerRight},[`&-top > ${I}`]:{top:0,insetInline:0,boxShadow:e.boxShadowDrawerUp},[`&-bottom > ${I}`]:{bottom:0,insetInline:0,boxShadow:e.boxShadowDrawerDown},[`${r}-section`]:{display:"flex",flexDirection:"column",width:"100%",height:"100%",overflow:"auto",background:o,pointerEvents:"auto"},[`${r}-header`]:{display:"flex",flex:0,alignItems:"center",padding:`${ae(c)} ${ae(u)}`,fontSize:d,lineHeight:h,borderBottom:`${ae(p)} ${f} ${g}`,"&-title":{display:"flex",flex:1,alignItems:"center",minWidth:0,minHeight:0}},[`${r}-extra`]:{flex:"none"},[`${r}-close`]:{display:"inline-flex",width:A(d).add(l).equal(),height:A(d).add(l).equal(),borderRadius:t,justifyContent:"center",alignItems:"center",color:v,fontWeight:R,fontSize:d,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",textDecoration:"none",background:"transparent",border:0,cursor:"pointer",transition:`all ${a}`,textRendering:"auto",[`&${r}-close-end`]:{marginInlineStart:m},[`&:not(${r}-close-end)`]:{marginInlineEnd:m},"&:hover":{color:b,backgroundColor:S,textDecoration:"none"},"&:active":{backgroundColor:x},...wl(e)},[`${r}-title`]:{flex:1,margin:0,fontWeight:e.fontWeightStrong,fontSize:d,lineHeight:h},[`${r}-body`]:{flex:1,minWidth:0,minHeight:0,padding:u,overflow:"auto",[`${r}-body-skeleton`]:{width:"100%",height:"100%",display:"flex",justifyContent:"center"}},[`${r}-footer`]:{flexShrink:0,padding:`${ae(T)} ${ae(M)}`,borderTop:`${ae(p)} ${f} ${g}`},[L]:{position:"absolute",zIndex:1,backgroundColor:"transparent",userSelect:"none",pointerEvents:"auto","&:hover":{backgroundColor:e.colorPrimary,opacity:.2},"&-dragging":{backgroundColor:e.colorPrimary,opacity:.3}},[`${L}-left`]:{top:0,bottom:0,right:{_skip_check_:!0,value:0},width:D,cursor:"col-resize"},[`${L}-right`]:{top:0,bottom:0,left:{_skip_check_:!0,value:0},width:D,cursor:"col-resize"},[`${L}-top`]:{insetInline:0,bottom:0,height:D,cursor:"row-resize"},[`${L}-bottom`]:{insetInline:0,top:0,height:D,cursor:"row-resize"},[`${I}-dragging`]:{userSelect:"none",transition:"none",willChange:"width, height",[`${r}-content`]:{pointerEvents:"none"},[`${r}-section`]:{pointerEvents:"none"}},"&-rtl":{direction:"rtl"}}}},PVe=e=>({zIndexPopup:e.zIndexPopupBase,footerPaddingBlock:e.paddingXS,footerPaddingInline:e.padding,draggerSize:4}),Zue=Wr("Drawer",e=>{const t=$r(e,{});return[RVe(t),TVe(t)]},PVe),MVe={distance:180},nX=378,iX={motionAppear:!0,motionEnter:!0,motionLeave:!0,motionDeadline:500},IVe=e=>{const{rootClassName:t,size:r,defaultSize:n=nX,height:i,width:o,mask:s,push:a=MVe,open:l,afterOpenChange:c,onClose:u,prefixCls:d,getContainer:h,panelRef:p=null,style:f,className:g,resizable:m,"aria-labelledby":v,focusable:b,maskClosable:S,maskStyle:x,drawerStyle:E,contentWrapperStyle:R,destroyOnClose:T,destroyOnHidden:M,...D}=e,{placement:A}=D,I=xc(),L=D.title?I:void 0,{getPopupContainer:F,getPrefixCls:k,direction:O,className:B,style:H,classNames:N,styles:z,mask:W}=Nr("drawer"),V=k("drawer",d),[$,K]=Zue(V),q=h===void 0&&F?()=>F(document.body):h,X=y.useMemo(()=>typeof r=="number"?r:r==="large"?736:r==="default"?nX:typeof r=="string"?/^\d+(\.\d+)?$/.test(r)?Number(r):r:!A||A==="left"||A==="right"?o:i,[r,A,o,i]),Y={motionName:mu(V,"mask-motion"),...iX},oe=We=>({motionName:mu(V,`panel-motion-${We}`),...iX}),ee=qle(),ne=Wo(p,ee),[le,he]=Hp("Drawer",D.zIndex),[re,ie,de]=Yae(s,W,V,S),J=Ule(b,q!==!1&&re),{classNames:ue,styles:ve,rootStyle:pe}=D,me={...e,zIndex:le,panelRef:p,mask:re,maskClosable:de,defaultSize:n,push:a,focusable:J},[ke,De]=Vr([N,ue],[z,ve],{props:me}),Ee=Q({"no-mask":!re,[`${V}-rtl`]:O==="rtl"},t,$,K,ke.root);return y.createElement(Rp,{form:!0,space:!0},y.createElement(Lx.Provider,{value:he},y.createElement(wVe,{prefixCls:V,onClose:u,maskMotion:Y,motion:oe,...D,classNames:{mask:Q(ke.mask,ie.mask),section:ke.section,wrapper:ke.wrapper,dragger:ke.dragger},styles:{mask:{...De.mask,...x},section:{...De.section,...E},wrapper:{...De.wrapper,...R},dragger:De.dragger},open:l,mask:re,maskClosable:de,push:a,size:X,defaultSize:n,style:{...H,...f},rootStyle:{...pe,...De.root},className:Q(B,g),rootClassName:Ee,getContainer:q,afterOpenChange:c,panelRef:ne,zIndex:le,...m?{resizable:m}:{},"aria-labelledby":v??L,destroyOnHidden:M??T,focusTriggerAfterClose:J.focusTriggerAfterClose,focusTrap:J.trap},y.createElement(que,{prefixCls:V,size:r,...D,ariaId:L,onClose:u}))))},DVe=e=>{const{prefixCls:t,style:r,className:n,placement:i="right",...o}=e,{getPrefixCls:s}=y.useContext(ir),a=s("drawer",t),[l,c]=Zue(a),u=Q(a,`${a}-pure`,`${a}-${i}`,l,c,n);return y.createElement("div",{className:u,style:r},y.createElement(que,{prefixCls:a,...o}))};IVe._InternalPanelDoNotUseOrYouWillBeFired=DVe;function RM(e){return["small","middle","medium","large"].includes(e)}function oX(e){return e?typeof e=="number"&&!Number.isNaN(e):!1}const Que=Z.createContext({latestIndex:0}),AVe=Que.Provider,FVe=e=>{const{className:t,prefix:r,index:n,children:i,separator:o,style:s,classNames:a,styles:l}=e,{latestIndex:c}=y.useContext(Que);return Tn(i)?y.createElement(y.Fragment,null,y.createElement("div",{className:t,style:s},i),n{const{componentCls:t,antCls:r}=e;return{[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},[`${t}-item:empty`]:{display:"none"},[`${t}-item > ${r}-badge-not-a-wrapper:only-child`]:{display:"block"}}}},_Ve=e=>{const{componentCls:t}=e;return{[t]:{"&-gap-row-small":{rowGap:e.spaceGapSmallSize},"&-gap-row-medium, &-gap-row-middle":{rowGap:e.spaceGapMiddleSize},"&-gap-row-large":{rowGap:e.spaceGapLargeSize},"&-gap-col-small":{columnGap:e.spaceGapSmallSize},"&-gap-col-medium, &-gap-col-middle":{columnGap:e.spaceGapMiddleSize},"&-gap-col-large":{columnGap:e.spaceGapLargeSize}}}},OVe=Wr("Space",e=>{const t=$r(e,{spaceGapSmallSize:e.paddingXS,spaceGapMiddleSize:e.padding,spaceGapLargeSize:e.paddingLG});return[LVe(t),_Ve(t)]},()=>({}),{resetStyle:!1}),kVe=y.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n,size:i,className:o,style:s,classNames:a,styles:l}=Nr("space"),{size:c=i??"small",align:u,className:d,rootClassName:h,children:p,direction:f,orientation:g,prefixCls:m,split:v,separator:b,style:S,vertical:x,wrap:E=!1,classNames:R,styles:T,...M}=e,[D,A]=Array.isArray(c)?c:[c,c],I=RM(A),L=RM(D),F=oX(A),k=oX(D),O=Li(p,{keepEmpty:!0}),[B,H]=Fx(g,x,f),N=u===void 0&&!H?"center":u,z=b??v,W=r("space",m),[V,$]=OVe(W),K={...e,size:c,orientation:B,align:N},[q,X]=Vr([a,R],[l,T],{props:K}),Y=Q(W,o,V,`${W}-${B}`,{[`${W}-rtl`]:n==="rtl",[`${W}-align-${N}`]:N,[`${W}-gap-row-${A}`]:I,[`${W}-gap-col-${D}`]:L},d,h,$,q.root),oe=Q(`${W}-item`,q.item),ee=O.map((he,re)=>{const ie=(he==null?void 0:he.key)||`${oe}-${re}`;return y.createElement(FVe,{prefix:W,classNames:q,styles:X,className:oe,key:ie,index:re,separator:z,style:X.item},he)}),ne=y.useMemo(()=>({latestIndex:O.reduce((re,ie,de)=>Tn(ie)?de:re,0)}),[O]);if(O.length===0)return null;const le={};return E&&(le.flexWrap="wrap"),!L&&k&&(le.columnGap=D),!I&&F&&(le.rowGap=A),y.createElement("div",{ref:t,className:Y,style:{...le,...X.root,...s,...S},...M},y.createElement(AVe,{value:ne},ee))}),Jx=kVe;Jx.Compact=$3;Jx.Addon=Vue;const Jue=e=>{const{getPopupContainer:t,getPrefixCls:r,direction:n}=y.useContext(ir),{prefixCls:i,type:o="default",danger:s,disabled:a,loading:l,onClick:c,htmlType:u,children:d,className:h,menu:p,arrow:f,autoFocus:g,trigger:m,align:v,open:b,onOpenChange:S,placement:x,getPopupContainer:E,href:R,icon:T=y.createElement(C4,null),title:M,buttonsRender:D=le=>le,mouseEnterDelay:A,mouseLeaveDelay:I,overlayClassName:L,overlayStyle:F,destroyOnHidden:k,destroyPopupOnHide:O,dropdownRender:B,popupRender:H,...N}=e,z=r("dropdown",i),W=`${z}-button`,$={menu:p,arrow:f,autoFocus:g,align:v,disabled:a,trigger:a?[]:m,onOpenChange:S,getPopupContainer:E||t,mouseEnterDelay:A,mouseLeaveDelay:I,classNames:{root:L},styles:{root:F},destroyOnHidden:k,popupRender:H||B},{compactSize:K,compactItemClassnames:q}=Wp(z,n),X=Q(W,q,h);"destroyPopupOnHide"in e&&($.destroyPopupOnHide=O),"open"in e&&($.open=b),"placement"in e?$.placement=x:$.placement=n==="rtl"?"bottomLeft":"bottomRight";const Y=y.createElement(ca,{type:o,danger:s,disabled:a,loading:l,onClick:c,htmlType:u,href:R,title:M},d),oe=y.createElement(ca,{type:o,danger:s,icon:T}),[ee,ne]=D([Y,oe]);return y.createElement(Jx.Compact,{className:X,size:K,block:!0,...N},ee,y.createElement(Xx,{...$},ne))};Jue.__ANT_BUTTON=!0;const I4=Xx;I4.Button=Jue;const ede=["wrap","nowrap","wrap-reverse"],tde=["flex-start","flex-end","start","end","center","space-between","space-around","space-evenly","stretch","normal","left","right"],rde=["center","start","end","flex-start","flex-end","self-start","self-end","baseline","normal","stretch"],NVe=(e,t)=>{const r=t.wrap===!0?"wrap":t.wrap;return{[`${e}-wrap-${r}`]:r&&ede.includes(r)}},BVe=(e,t)=>{const r={};return rde.forEach(n=>{r[`${e}-align-${n}`]=t.align===n}),r[`${e}-align-stretch`]=!t.align&&!!t.vertical,r},$Ve=(e,t)=>{const r={};return tde.forEach(n=>{r[`${e}-justify-${n}`]=t.justify===n}),r},GVe=(e,t)=>Q({...NVe(e,t),...BVe(e,t),...$Ve(e,t)}),VVe=e=>{const{componentCls:t}=e;return{[t]:{display:"flex",margin:0,padding:0,"&-vertical":{flexDirection:"column"},"&-rtl":{direction:"rtl"},"&:empty":{display:"none"}}}},zVe=e=>{const{componentCls:t}=e;return{[t]:{"&-gap-small":{gap:e.flexGapSM},"&-gap-medium, &-gap-middle":{gap:e.flexGap},"&-gap-large":{gap:e.flexGapLG}}}},HVe=e=>{const{componentCls:t}=e,r={};return ede.forEach(n=>{r[`${t}-wrap-${n}`]={flexWrap:n}}),r},WVe=e=>{const{componentCls:t}=e,r={};return rde.forEach(n=>{r[`${t}-align-${n}`]={alignItems:n}}),r},UVe=e=>{const{componentCls:t}=e,r={};return tde.forEach(n=>{r[`${t}-justify-${n}`]={justifyContent:n}}),r},jVe=()=>({}),KVe=Wr("Flex",e=>{const{paddingXS:t,padding:r,paddingLG:n}=e,i=$r(e,{flexGapSM:t,flexGap:r,flexGapLG:n});return[VVe(i),zVe(i),HVe(i),WVe(i),UVe(i)]},jVe,{resetStyle:!1}),qVe=Z.forwardRef((e,t)=>{const{prefixCls:r,rootClassName:n,className:i,style:o,flex:s,gap:a,vertical:l,orientation:c,component:u="div",children:d,...h}=e,{flex:p,direction:f,getPrefixCls:g}=Z.useContext(ir),m=g("flex",r),[v,b]=KVe(m),[,S]=Fx(c,l??(p==null?void 0:p.vertical)),x=Q(i,n,p==null?void 0:p.className,m,v,b,GVe(m,{...e,vertical:S}),{[`${m}-rtl`]:f==="rtl",[`${m}-gap-${a}`]:RM(a),[`${m}-vertical`]:S}),E={...p==null?void 0:p.style,...o};return Tn(s)&&(E.flex=s),Tn(a)&&!RM(a)&&(E.gap=a),Z.createElement(u,{ref:t,className:x,style:E,...fn(h,["justify","wrap","align"])},d)}),PM=Z.createContext(null);var XVe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494zM504 618H320c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM312 490v48c0 4.4 3.6 8 8 8h384c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H320c-4.4 0-8 3.6-8 8z"}}]},name:"file-text",theme:"outlined"};function Q$(){return Q$=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,Q$({},e,{ref:t,icon:XVe})),nde=y.forwardRef(YVe),ZVe=(e,t)=>Tn(e)?typeof e=="object"&&!y.isValidElement(e)?{...t,...e}:{...t,title:e}:null,QVe=e=>{const{componentCls:t,floatButtonSize:r,iconCls:n,antCls:i,floatButtonIconSize:o}=e,[s,a]=Jn(i,"float-btn"),l=`${t}-badge`,c=Math.SQRT2,u=(c-1)/c,d=e.calc(e.borderRadius).mul(u).equal(),h=e.calc(e.controlHeight).div(2).mul(u).equal();return{[t]:[{[s("size")]:ae(r)},{flexDirection:"column",margin:0,padding:`${ae(e.paddingXXS)} 0`,width:a("size"),minHeight:a("size"),height:"auto",wordBreak:"break-word",whiteSpace:"normal",gap:e.calc(e.paddingXXS).div(2).equal(),"&-rtl":{direction:"rtl"},[`&${t}-individual`]:{position:"fixed",zIndex:e.zIndexPopupBase,insetInlineEnd:e.floatButtonInsetInlineEnd,bottom:e.floatButtonInsetBlockEnd,boxShadow:e.boxShadowSecondary},[`&${t}-pure`]:{position:"relative",inset:"auto"},"&:empty":{display:"none"},[`${t}-icon`]:{lineHeight:1},[`&${t}-icon-only`]:{[n]:{fontSize:o}},[`${t}-content`]:{fontSize:e.fontSizeSM},[l]:{position:"absolute",top:0,insetInlineEnd:0,[`&:not(${l}-dot)`]:{transform:"translate(50%, -50%)"}},[`&-rtl ${l}:not(${l}-dot)`]:{transform:"translate(-50%, -50%)"},"&-square":{[`${l}-dot`]:{marginTop:d,marginInlineEnd:d}},"&-circle":{[l]:{marginTop:h,marginInlineEnd:h}}}]}},JVe=e=>{const{componentCls:t,antCls:r,floatButtonSize:n,padding:i}=e,o=`${t}-group`,s=`${o}-list`,[a,l]=Jn(r,"float-btn");return{[o]:[{[a("list-transform-start")]:`translate(0,${ae(n)})`,[a("list-trigger-offset")]:`calc(${ae(n)} + ${ae(i)})`},{...on(e),position:"fixed",zIndex:e.zIndexPopupBase,insetInlineEnd:e.floatButtonInsetInlineEnd,bottom:e.floatButtonInsetBlockEnd,gap:i,"&-rtl":{direction:"rtl"},[`&${t}-pure`]:{position:"relative",inset:"auto"},[t]:{position:"relative",inset:"auto"}},{[`&:not(${o}-individual) ${s}`]:{boxShadow:e.boxShadowSecondary},[`&${o}-individual ${s}`]:{gap:i},[`&-menu-mode ${s}`]:{position:"absolute"},[s]:{borderRadius:e.borderRadiusLG,"&-motion":{transition:`all ${e.motionDurationSlow}`,"&-enter, &-appear":{opacity:0,transform:l("list-transform-start"),"&-active":{opacity:1,transform:"translate(0, 0)"}},"&-leave":{"&-active":{opacity:0,transform:l("list-transform-start")}}}},"&-top":{[s]:{bottom:l("list-trigger-offset")}},"&-bottom":{[s]:{[a("list-transform-start")]:`translate(0, calc(${ae(n)} * -1))`,top:l("list-trigger-offset")}},"&-left":{[s]:{[a("list-transform-start")]:`translate(${ae(n)}, 0)`,right:l("list-trigger-offset")}},"&-right":{[s]:{[a("list-transform-start")]:`translate(calc(${ae(n)} * -1), 0)`,left:l("list-trigger-offset")}}}]}},eze=()=>({}),ide=Wr("FloatButton",e=>{const{controlHeightLG:t,marginXXL:r,marginLG:n,fontSizeIcon:i,calc:o}=e,s=$r(e,{floatButtonIconSize:o(i).mul(1.5).equal(),floatButtonSize:t,floatButtonInsetBlockEnd:r,floatButtonInsetInlineEnd:n});return[QVe(s),JVe(s),jD(e)]},eze,{order:-998}),iA="float-btn",tze=Z.forwardRef((e,t)=>{const{prefixCls:r,className:n,rootClassName:i,style:o,type:s="default",shape:a="circle",icon:l,description:c,content:u,tooltip:d,badge:h={},classNames:p,styles:f,...g}=e,{getPrefixCls:m,direction:v}=Z.useContext(ir),b=Z.useContext(PM),S=m(iA,r),x=ho(S),{shape:E,individual:R,classNames:T,styles:M}=b||{},D=E||a,A=R??!0,I=u??c,L={...e,type:s,shape:D},[F,k]=ide(S,x),O=Z.useMemo(()=>({icon:`${S}-icon`,content:`${S}-content`}),[S]),[B,H]=Vr([O,T,p],[M,f],{props:L}),N=!I&&!l?Z.createElement(nde,null):l,[z]=Hp("FloatButton",o==null?void 0:o.zIndex),W={...o,zIndex:z},V=fn(h,["title","children","status","text"]),$="badge"in e&&Z.createElement(Vce,{...V,className:Q(V.className,`${S}-badge`,{[`${S}-badge-dot`]:V.dot})}),K=ZVe(d);let q=Z.createElement(ca,{...g,ref:t,className:Q(F,k,x,S,n,i,`${S}-${s}`,`${S}-${D}`,{[`${S}-rtl`]:v==="rtl",[`${S}-individual`]:A,[`${S}-icon-only`]:!I}),classNames:B,styles:H,style:W,shape:D,type:s,size:"large",icon:N,_skipSemantic:!0},I,$);return K&&(q=Z.createElement(El,{...K},q)),q}),kC=tze,rze=Z.createElement(F2e,null),ode=Z.forwardRef((e,t)=>{var A;const{backTopIcon:r}=Nr("floatButton"),{prefixCls:n,className:i,type:o="default",shape:s="circle",visibilityHeight:a=400,icon:l,target:c,onClick:u,duration:d=450,...h}=e,p=l??r??rze,[f,g]=y.useState(a===0),m=Z.useRef(null);Z.useImperativeHandle(t,()=>({nativeElement:m.current}));const v=()=>{var I;return((I=m.current)==null?void 0:I.ownerDocument)||window},b=PIe(I=>{const L=ele(I.target);g(L>=a)});y.useEffect(()=>{const L=(c||v)();return b({target:L}),L==null||L.addEventListener("scroll",b),()=>{b.cancel(),L==null||L.removeEventListener("scroll",b)}},[c]);const S=I=>{tle(0,{getContainer:c||v,duration:d}),u==null||u(I)},{getPrefixCls:x}=y.useContext(ir),E=x(iA,n),R=x(),M=((A=y.useContext(PM))==null?void 0:A.shape)||s,D={prefixCls:E,icon:p,type:o,shape:M,...h};return Z.createElement(Mu,{visible:f,motionName:`${R}-fade`},({className:I},L)=>Z.createElement(kC,{ref:Wo(m,L),...D,onClick:S,className:Q(i,I)}))}),sde=e=>{const{prefixCls:t,className:r,style:n,classNames:i,styles:o,rootClassName:s,shape:a="circle",type:l="default",placement:c,icon:u=Z.createElement(nde,null),closeIcon:d,trigger:h,children:p,onOpenChange:f,open:g,onClick:m,...v}=e,{direction:b,getPrefixCls:S,closeIcon:x,classNames:E,styles:R,className:T,style:M}=Nr("floatButtonGroup"),D=d??x??Z.createElement(Xd,null),A=S(iA,t),I=ho(A),[L,F]=ide(A,I),k=`${A}-group`,O=h&&["click","hover"].includes(h),[B]=Hp("FloatButton",n==null?void 0:n.zIndex),H=Z.useRef(null),N=["top","left","right","bottom"].includes(c)?c:"top",[z,W]=An(!1,g),V=h==="hover",$=h==="click",K=br(ue=>{z!==ue&&(W(ue),f==null||f(ue))}),q=()=>{V&&K(!0)},X=()=>{V&&K(!1)},Y=ue=>{$&&K(!z),m==null||m(ue)};Z.useEffect(()=>{if($){const ue=ve=>{var pe;(pe=H.current)!=null&&pe.contains(ve.target)||K(!1)};return document.addEventListener("click",ue,{capture:!0}),()=>document.removeEventListener("click",ue,{capture:!0})}},[$]);const oe=a==="circle",ee={...e,shape:a,type:l,placement:N},[ne,le]=Vr([E,i],[R,o],{props:ee}),he=Z.useMemo(()=>({shape:a,individual:oe,classNames:{root:ne.item,icon:ne.itemIcon,content:ne.itemContent},styles:{root:le.item,icon:le.itemIcon,content:le.itemContent}}),[a,oe,ne,le]),re=Z.useMemo(()=>({...he,individual:!0,classNames:{root:ne.trigger,icon:ne.triggerIcon,content:ne.triggerContent},styles:{root:le.trigger,icon:le.triggerIcon,content:le.triggerContent}}),[he,ne,le]);let ie;const de=`${k}-list`,J=ue=>{const ve=N==="top"||N==="bottom",pe={className:Q(de,ne.list,ue),style:le.list};return oe?ie=Z.createElement(qVe,{vertical:ve,...pe},p):ie=Z.createElement(Jx.Compact,{vertical:ve,...pe},p),ie};return Z.createElement(PM.Provider,{value:he},Z.createElement("div",{className:Q(k,L,F,I,T,ne.root,r,s,{[`${k}-rtl`]:b==="rtl",[`${k}-individual`]:oe,[`${k}-${N}`]:O,[`${k}-menu-mode`]:O}),style:{...M,zIndex:B,...le.root,...n},ref:H,onMouseEnter:q,onMouseLeave:X},O?Z.createElement(Mu,{visible:z,motionName:`${de}-motion`},({className:ue})=>J(ue)):J(),O&&Z.createElement(PM.Provider,{value:re},Z.createElement(kC,{type:l,icon:z?D:u,"aria-label":e["aria-label"],className:`${k}-trigger`,onClick:Y,...v}))))},sX=({backTop:e,...t})=>e?y.createElement(ode,{...t,visibilityHeight:0}):y.createElement(kC,{...t}),nze=({className:e,items:t,classNames:r,styles:n,prefixCls:i,...o})=>{const{getPrefixCls:s}=y.useContext(ir),l=`${s(iA,i)}-pure`;return t?y.createElement(sde,{className:Q(e,l),classNames:r,styles:n,...o},t.map((c,u)=>y.createElement(sX,{key:u,...c}))):y.createElement(sX,{className:Q(e,l),classNames:r,styles:n,...o})};kC.BackTop=ode;kC.Group=sde;kC._InternalPanelDoNotUseOrYouWillBeFired=nze;const ize=e=>{const{getPrefixCls:t,direction:r}=y.useContext(ir),{prefixCls:n,className:i}=e,o=t("input-group",n),s=t("input"),[a,l]=xue(s),c=Q(o,l,{[`${o}-lg`]:e.size==="large",[`${o}-sm`]:e.size==="small",[`${o}-compact`]:e.compact,[`${o}-rtl`]:r==="rtl"},a,i),u=y.useContext(ua),d=y.useMemo(()=>({...u,isFormItemInput:!1}),[u]);return y.createElement(ua.Provider,{value:d},y.createElement(Jx.Compact,{className:c,style:e.style,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,onFocus:e.onFocus,onBlur:e.onBlur},e.children))},oze=e=>{const{componentCls:t,paddingXS:r}=e;return{[t]:{display:"inline-flex",alignItems:"center",flexWrap:"nowrap",columnGap:r,[`${t}-input-wrapper`]:{position:"relative",[`${t}-mask-icon`]:{position:"absolute",zIndex:"1",top:"50%",right:"50%",transform:"translate(50%, -50%)",pointerEvents:"none"},[`${t}-mask-input`]:{color:"transparent",caretColor:e.colorText},[`${t}-mask-input[type=number]::-webkit-inner-spin-button`]:{"-webkit-appearance":"none",margin:0},[`${t}-mask-input[type=number]`]:{"-moz-appearance":"textfield"}},"&-rtl":{direction:"rtl"},[`${t}-input`]:{textAlign:"center",paddingInline:e.paddingXXS},[`&${t}-sm ${t}-input`]:{paddingInline:e.calc(e.paddingXXS).div(2).equal()},[`&${t}-lg ${t}-input`]:{paddingInline:e.paddingXS}}}},sze=Wr(["Input","OTP"],e=>{const t=$r(e,_C(e));return oze(t)},OC),aze=y.forwardRef((e,t)=>{const{className:r,value:n,onChange:i,onActiveChange:o,index:s,mask:a,onFocus:l,...c}=e,{getPrefixCls:u}=y.useContext(ir),d=u("otp"),h=typeof a=="string"?a:n,p=y.useRef(null);y.useImperativeHandle(t,()=>p.current);const f=b=>{i(s,b.target.value)},g=()=>{Or(()=>{var S;const b=(S=p.current)==null?void 0:S.input;document.activeElement===b&&b&&b.select()})},m=b=>{l==null||l(b),g()},v=b=>{const{key:S,ctrlKey:x,metaKey:E}=b;S==="ArrowLeft"?o(s-1):S==="ArrowRight"?o(s+1):S==="z"&&(x||E)?b.preventDefault():S==="Backspace"&&!n&&o(s-1),g()};return y.createElement("span",{className:`${d}-input-wrapper`,role:"presentation"},a&&n!==""&&n!==void 0&&y.createElement("span",{className:`${d}-mask-icon`,"aria-hidden":"true"},h),y.createElement(Qx,{"aria-label":`OTP Input ${s+1}`,type:a===!0?"password":"text",...c,ref:p,value:n,onInput:f,onFocus:m,onKeyDown:v,onMouseDown:g,onMouseUp:g,className:Q(r,{[`${d}-mask-input`]:a})}))});function uT(e){return(e||"").split("")}const lze=e=>{const{index:t,prefixCls:r,separator:n,className:i,style:o}=e,s=typeof n=="function"?n(t):n;return s?y.createElement("span",{className:Q(`${r}-separator`,i),style:o},s):null},cze=y.forwardRef((e,t)=>{const{prefixCls:r,length:n=6,size:i,defaultValue:o,value:s,onChange:a,formatter:l,separator:c,variant:u,disabled:d,status:h,autoFocus:p,mask:f,type:g,autoComplete:m,onInput:v,onFocus:b,inputMode:S,classNames:x,styles:E,className:R,style:T,...M}=e,{classNames:D,styles:A,getPrefixCls:I,direction:L,style:F,className:k}=Nr("otp"),O=I("otp",r),B={...e,length:n},[H,N]=Vr([D,x],[A,E],{props:B}),z=ai(M,{aria:!0,data:!0,attr:!0}),[W,V]=sze(O),$=ki(ve=>i??ve),K=y.useContext(ua),q=Ux(K.status,h),X=y.useMemo(()=>({...K,status:q,hasFeedback:!1,feedbackIcon:null}),[K,q]),Y=y.useRef(null),oe=y.useRef({});y.useImperativeHandle(t,()=>({focus:()=>{var ve;(ve=oe.current[0])==null||ve.focus()},blur:()=>{var ve;for(let pe=0;pel?l(ve):ve,[ne,le]=y.useState(()=>uT(ee(o||"")));y.useEffect(()=>{s!==void 0&&le(uT(s))},[s]);const he=br(ve=>{le(ve),v&&v(ve),a&&ve.length===n&&ve.every(pe=>pe)&&ve.some((pe,me)=>ne[me]!==pe)&&a(ve.join(""))}),re=br((ve,pe)=>{let me=Pr(ne);for(let De=0;De=0&&!me[De];De-=1)me.pop();const ke=ee(me.map(De=>De||" ").join(""));return me=uT(ke).map((De,Ee)=>De===" "&&!me[Ee]?me[Ee]:De),me}),ie=(ve,pe)=>{var De;const me=re(ve,pe),ke=Math.min(ve+pe.length,n-1);ke!==ve&&me[ve]!==void 0&&((De=oe.current[ke])==null||De.focus()),he(me)},de=ve=>{var pe;(pe=oe.current[ve])==null||pe.focus()},J=(ve,pe)=>{var me,ke,De;for(let Ee=0;Ee{const me=`otp-${pe}`,ke=ne[pe]||"";return y.createElement(y.Fragment,{key:me},y.createElement(aze,{ref:De=>{oe.current[pe]=De},index:pe,size:$,htmlSize:1,className:Q(H.input,`${O}-input`),style:N.input,onChange:ie,value:ke,onActiveChange:de,autoFocus:pe===0&&p,onFocus:De=>J(De,pe),...ue}),pey.createElement(Sr,J$({},e,{ref:t,icon:uze})),hze=y.forwardRef(dze);var pze={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"};function eG(){return eG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,eG({},e,{ref:t,icon:pze})),ade=y.forwardRef(fze),gze=e=>e?y.createElement(ade,null):y.createElement(hze,null),mze={click:"onClick",hover:"onMouseOver"},vze=y.forwardRef((e,t)=>{const{disabled:r,action:n="click",visibilityToggle:i=!0,iconRender:o=gze,suffix:s}=e,a=y.useContext(hs),l=r??a,c=typeof i=="object"&&i.visible!==void 0,[u,d]=y.useState(()=>c?i.visible:!1),h=y.useRef(null);y.useEffect(()=>{c&&d(i.visible)},[c,i]);const p=jue(h),f=()=>{var L;if(l)return;u&&p();const I=!u;d(I),typeof i=="object"&&((L=i.onVisibleChange)==null||L.call(i,I))},g=I=>{const L=mze[n]||"",F=o(u),k={[L]:f,className:`${I}-icon`,key:"passwordIcon",onMouseDown:O=>{O.preventDefault()},onMouseUp:O=>{O.preventDefault()}};return y.cloneElement(y.isValidElement(F)?F:y.createElement("span",null,F),k)},{className:m,prefixCls:v,inputPrefixCls:b,size:S,...x}=e,{getPrefixCls:E}=y.useContext(ir),R=E("input",b),T=E("input-password",v),M=i&&g(T),D=Q(T,m,{[`${T}-${S}`]:!!S}),A={...fn(x,["suffix","iconRender","visibilityToggle"]),type:u?"text":"password",className:D,prefixCls:R,suffix:y.createElement(y.Fragment,null,M,s)};return S&&(A.size=S),y.createElement(Qx,{ref:Wo(t,h),...A})}),yze=e=>{const{componentCls:t}=e,r=`${t}-btn`;return{[t]:{width:"100%",[r]:{"&-filled":{background:e.colorFillTertiary,"&:not(:disabled)":{"&:hover":{background:e.colorFillSecondary},"&:active":{background:e.colorFill}}}}}}},Cze=Wr(["Input","Search"],yze),bze=y.forwardRef((e,t)=>{const{prefixCls:r,inputPrefixCls:n,className:i,size:o,style:s,enterButton:a=!1,addonAfter:l,loading:c,disabled:u,onSearch:d,onChange:h,onCompositionStart:p,onCompositionEnd:f,variant:g,onPressEnter:m,classNames:v,styles:b,hidden:S,...x}=e,{direction:E,getPrefixCls:R,classNames:T,styles:M}=Nr("inputSearch"),D={...e,enterButton:a},[A,I]=Vr([T,v],[M,b],{props:D},{button:{_default:"root"}}),L=y.useRef(!1),F=R("input-search",r),k=R("input",n),[O,B]=Cze(F),{compactSize:H}=Wp(F,E),N=ki(J=>o??H??J),z=y.useRef(null),W=J=>{J!=null&&J.target&&J.type==="click"&&d&&d(J.target.value,J,{source:"clear"}),h==null||h(J)},V=J=>{var ue;document.activeElement===((ue=z.current)==null?void 0:ue.input)&&J.preventDefault()},$=J=>{var ue,ve;d&&d((ve=(ue=z.current)==null?void 0:ue.input)==null?void 0:ve.value,J,{source:"input"})},K=J=>{L.current||c||(m==null||m(J),$(J))},q=typeof a=="boolean"?y.createElement(a4,null):null,X=`${F}-btn`,Y=Q(X,{[`${X}-${g}`]:g});let oe;const ee=a||{},ne=ee.type&&ee.type.__ANT_BUTTON===!0;ne||ee.type==="button"?oe=Ei(ee,{onMouseDown:V,onClick:J=>{var ue,ve;(ve=(ue=ee==null?void 0:ee.props)==null?void 0:ue.onClick)==null||ve.call(ue,J),$(J)},key:"enterButton",...ne?{className:Y,size:N}:{}}):oe=y.createElement(ca,{classNames:A.button,styles:I.button,className:Y,color:a?"primary":"default",size:N,disabled:u,key:"enterButton",onMouseDown:V,onClick:$,loading:c,icon:q,variant:g==="borderless"||g==="filled"||g==="underlined"?"text":a?"solid":void 0},a),l&&(oe=[oe,Ei(l,{key:"addonAfter"})]);const le=Q(F,B,{[`${F}-rtl`]:E==="rtl",[`${F}-${N}`]:!!N,[`${F}-with-button`]:!!a},i,O,A.root),he=J=>{L.current=!0,p==null||p(J)},re=J=>{L.current=!1,f==null||f(J)},ie=ai(x,{data:!0}),de=fn({...x,classNames:fn(A,["button","root"]),styles:fn(I,["button","root"]),prefixCls:k,type:"search",size:N,variant:g,onPressEnter:K,onCompositionStart:he,onCompositionEnd:re,onChange:W,disabled:u},Object.keys(ie));return y.createElement($3,{className:le,style:{...s,...I.root},...ie,hidden:S},y.createElement(Qx,{ref:Wo(z,t),...de}),oe)}),Sze=` min-height:0 !important; max-height:none !important; height:0 !important; visibility:hidden !important; overflow:hidden !important; position:absolute !important; z-index:-1000 !important; top:0 !important; right:0 !important; pointer-events: none !important; `,wze=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break","white-space"],aO={};let Sa;function xze(e,t=!1){const r=e.getAttribute("id")||e.getAttribute("data-reactid")||e.getAttribute("name");if(t&&aO[r])return aO[r];const n=window.getComputedStyle(e),i=n.getPropertyValue("box-sizing")||n.getPropertyValue("-moz-box-sizing")||n.getPropertyValue("-webkit-box-sizing"),o=parseFloat(n.getPropertyValue("padding-bottom"))+parseFloat(n.getPropertyValue("padding-top")),s=parseFloat(n.getPropertyValue("border-bottom-width"))+parseFloat(n.getPropertyValue("border-top-width")),l={sizingStyle:wze.map(c=>`${c}:${n.getPropertyValue(c)}`).join(";"),paddingSize:o,borderSize:s,boxSizing:i};return t&&r&&(aO[r]=l),l}function Eze(e,t=!1,r=null,n=null){Sa||(Sa=document.createElement("textarea"),Sa.setAttribute("tab-index","-1"),Sa.setAttribute("aria-hidden","true"),Sa.setAttribute("name","hiddenTextarea"),document.body.appendChild(Sa)),e.getAttribute("wrap")?Sa.setAttribute("wrap",e.getAttribute("wrap")):Sa.removeAttribute("wrap");const{paddingSize:i,borderSize:o,boxSizing:s,sizingStyle:a}=xze(e,t);Sa.setAttribute("style",`${a};${Sze}`),Sa.value=e.value||e.placeholder||"";let l,c,u,d=Sa.scrollHeight;if(s==="border-box"?d+=o:s==="content-box"&&(d-=i),r!==null||n!==null){Sa.value=" ";const p=Sa.scrollHeight-i;r!==null&&(l=p*r,s==="border-box"&&(l=l+i+o),d=Math.max(l,d)),n!==null&&(c=p*n,s==="border-box"&&(c=c+i+o),u=d>c?"":"hidden",d=Math.min(c,d))}const h={height:d,overflowY:u,resize:"none"};return l&&(h.minHeight=l),c&&(h.maxHeight=c),h}function tG(){return tG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,defaultValue:n,value:i,autoSize:o,onResize:s,className:a,style:l,disabled:c,onChange:u,onInternalAutoSize:d,...h}=e,[p,f]=An(n,i),g=p??"",m=O=>{f(O.target.value),u==null||u(O)},v=y.useRef();y.useImperativeHandle(t,()=>({textArea:v.current}));const[b,S]=y.useMemo(()=>o&&typeof o=="object"?[o.minRows,o.maxRows]:[],[o]),x=!!o,[E,R]=y.useState(uO),[T,M]=y.useState(),D=()=>{R(lO)};jr(()=>{x&&D()},[i,b,S,x]),jr(()=>{if(E===lO)R(cO);else if(E===cO){const O=Eze(v.current,!1,b,S);R(uO),M(O)}},[E]);const A=y.useRef(),I=()=>{Or.cancel(A.current)},L=O=>{E===uO&&(s==null||s(O),o&&(I(),A.current=Or(()=>{D()})))};y.useEffect(()=>I,[]);const k={...l,...x?T:null};return(E===lO||E===cO)&&(k.overflowY="hidden",k.overflowX="hidden"),y.createElement(ta,{onResize:L,disabled:!(o||s)},y.createElement("textarea",tG({},h,{ref:v,style:k,className:Q(r,a,{[`${r}-disabled`]:c}),disabled:c,value:g,onChange:m})))});function rG(){return rG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const[I,L]=An(e,t),F=I==null?"":String(I),[k,O]=Z.useState(!1),B=Z.useRef(!1),[H,N]=Z.useState(null),z=y.useRef(null),W=y.useRef(null),V=()=>{var Ee;return(Ee=W.current)==null?void 0:Ee.textArea},$=()=>{V().focus()};y.useImperativeHandle(A,()=>{var Ee;return{resizableTextArea:W.current,focus:$,blur:()=>{V().blur()},nativeElement:((Ee=z.current)==null?void 0:Ee.nativeElement)||V()}}),y.useEffect(()=>{O(Ee=>!g&&Ee)},[g]);const[K,q]=Z.useState(null);Z.useEffect(()=>{K&&V().setSelectionRange(...K)},[K]);const X=Wue(h,d),Y=X.max??s,oe=Number(Y)>0,ee=X.strategy(F),ne=!!Y&&ee>Y,le=(Ee,We)=>{let ze=We;!B.current&&X.exceedFormatter&&X.max&&X.strategy(We)>X.max&&(ze=X.exceedFormatter(We,{max:X.max}),We!==ze&&q([V().selectionStart||0,V().selectionEnd||0])),L(ze),EM(Ee.currentTarget,Ee,i,ze)},he=Ee=>{B.current=!0,a==null||a(Ee)},re=Ee=>{B.current=!1,le(Ee,Ee.currentTarget.value),l==null||l(Ee)},ie=Ee=>{le(Ee,Ee.target.value)},de=Ee=>{Ee.key==="Enter"&&E&&!Ee.nativeEvent.isComposing&&E(Ee),M==null||M(Ee)},J=Ee=>{O(!0),r==null||r(Ee)},ue=Ee=>{O(!1),n==null||n(Ee)},ve=Ee=>{L(""),$(),EM(V(),Ee,i)};let pe=c,me;X.show&&(X.showFormatter?me=X.showFormatter({value:F,count:ee,maxLength:Y}):me=`${ee}${oe?` / ${Y}`:""}`,pe=Z.createElement(Z.Fragment,null,pe,Z.createElement("span",{className:Q(`${u}-data-count`,v==null?void 0:v.count),style:b==null?void 0:b.count},me)));const ke=Ee=>{var We;S==null||S(Ee),(We=V())!=null&&We.style.height&&N(!0)},De=!T&&!d&&!o;return Z.createElement(Hue,{ref:z,value:F,allowClear:o,handleReset:ve,suffix:pe,prefixCls:u,classNames:{...v,affixWrapper:Q(v==null?void 0:v.affixWrapper,{[`${u}-show-count`]:d,[`${u}-textarea-allow-clear`]:o})},disabled:g,focused:k,className:Q(p,ne&&`${u}-out-of-range`),style:{...f,...H&&!De?{height:"auto"}:{}},dataAttrs:{affixWrapper:{"data-count":typeof me=="string"?me:void 0}},hidden:m,readOnly:R,onClear:x},Z.createElement(Tze,rG({},D,{autoSize:T,maxLength:s,onKeyDown:de,onChange:ie,onFocus:J,onBlur:ue,onCompositionStart:he,onCompositionEnd:re,className:Q(v==null?void 0:v.textarea),style:{resize:f==null?void 0:f.resize,...b==null?void 0:b.textarea},disabled:g,prefixCls:u,onResize:ke,ref:W,readOnly:R})))}),Pze=e=>{const{componentCls:t,paddingLG:r}=e,n=`${t}-textarea`;return{[`textarea${t}`]:{maxWidth:"100%",height:"auto",minHeight:e.controlHeight,lineHeight:e.lineHeight,verticalAlign:"bottom",transition:`all ${e.motionDurationSlow}`,resize:"vertical",[`&${t}-mouse-active`]:{transition:`all ${e.motionDurationSlow}, height 0s, width 0s`}},[`${t}-textarea-affix-wrapper-resize-dirty`]:{width:"auto"},[n]:{position:"relative","&-show-count":{[`${t}-data-count`]:{position:"absolute",bottom:e.calc(e.fontSize).mul(e.lineHeight).mul(-1).equal(),insetInlineEnd:0,color:e.colorTextDescription,whiteSpace:"nowrap",pointerEvents:"none"}},[` &-allow-clear > ${t}, &-affix-wrapper${n}-has-feedback ${t} `]:{paddingInlineEnd:r},[`&-affix-wrapper${t}-affix-wrapper`]:{padding:0,[`> textarea${t}`]:{fontSize:"inherit",border:"none",outline:"none",background:"transparent",minHeight:e.calc(e.controlHeight).sub(e.calc(e.lineWidth).mul(2)).equal(),"&:focus":{boxShadow:"none !important"}},[`${t}-suffix`]:{margin:0,"> *:not(:last-child)":{marginInline:0},[`${t}-clear-icon`]:{position:"absolute",insetInlineEnd:e.paddingInline,insetBlockStart:e.paddingXS},[`${n}-suffix`]:{position:"absolute",top:0,insetInlineEnd:e.paddingInline,bottom:0,zIndex:1,display:"inline-flex",alignItems:"center",margin:"auto",pointerEvents:"none"}}},[`&-affix-wrapper${t}-affix-wrapper-rtl`]:{[`${t}-suffix`]:{[`${t}-data-count`]:{direction:"ltr",insetInlineStart:0}}},[`&-affix-wrapper${t}-affix-wrapper-sm`]:{[`${t}-suffix`]:{[`${t}-clear-icon`]:{insetInlineEnd:e.paddingInlineSM}}}}}},Mze=Wr(["Input","TextArea"],e=>{const t=$r(e,_C(e));return Pze(t)},OC,{resetFont:!1}),lde=y.forwardRef((e,t)=>{var J;const{prefixCls:r,bordered:n=!0,size:i,disabled:o,status:s,allowClear:a,classNames:l,rootClassName:c,className:u,style:d,styles:h,variant:p,showCount:f,onMouseDown:g,onResize:m,...v}=e,{getPrefixCls:b,direction:S,allowClear:x,autoComplete:E,className:R,style:T,classNames:M,styles:D}=Nr("textArea"),A=y.useContext(hs),I=o??A,{status:L,hasFeedback:F,feedbackIcon:k}=y.useContext(ua),O=Ux(L,s),[B,H]=Vr([M,l],[D,h],{props:e}),N=y.useRef(null);y.useImperativeHandle(t,()=>{var ue,ve;return{resizableTextArea:(ue=N.current)==null?void 0:ue.resizableTextArea,focus:pe=>{var me,ke;X3((ke=(me=N.current)==null?void 0:me.resizableTextArea)==null?void 0:ke.textArea,pe)},blur:()=>{var pe;return(pe=N.current)==null?void 0:pe.blur()},nativeElement:((ve=N.current)==null?void 0:ve.nativeElement)||null}});const z=b("input",r),W=ho(z),[V,$]=wue(z,c);Mze(z,W);const{compactSize:K,compactItemClassnames:q}=Wp(z,S),X=ki(ue=>i??K??ue),[Y,oe]=jx("textArea",p,n),ee=Uue(a??x),[ne,le]=y.useState(!1),[he,re]=y.useState(!1),ie=ue=>{le(!0),g==null||g(ue);const ve=()=>{le(!1),document.removeEventListener("mouseup",ve)};document.addEventListener("mouseup",ve)},de=ue=>{var ve,pe;if(m==null||m(ue),ne&&typeof getComputedStyle=="function"){const me=(pe=(ve=N.current)==null?void 0:ve.nativeElement)==null?void 0:pe.querySelector("textarea");me&&getComputedStyle(me).resize==="both"&&re(!0)}};return y.createElement(Rze,{autoComplete:E,...v,style:{...H.root,...T,...d},styles:H,disabled:I,allowClear:ee,className:Q($,W,u,c,q,R,B.root,{[`${z}-textarea-affix-wrapper-resize-dirty`]:he}),classNames:{...B,textarea:Q({[`${z}-sm`]:X==="small",[`${z}-lg`]:X==="large"},V,B.textarea,ne&&`${z}-mouse-active`),variant:Q({[`${z}-${Y}`]:oe},Wy(z,O)),affixWrapper:Q(`${z}-textarea-affix-wrapper`,{[`${z}-affix-wrapper-rtl`]:S==="rtl",[`${z}-affix-wrapper-sm`]:X==="small",[`${z}-affix-wrapper-lg`]:X==="large",[`${z}-textarea-show-count`]:f||((J=e.count)==null?void 0:J.show)},V)},prefixCls:z,suffix:F&&y.createElement("span",{className:`${z}-textarea-suffix`},k),showCount:f,ref:N,onResize:de,onMouseDown:ie})}),e1=Qx;e1.Group=ize;e1.Search=bze;e1.TextArea=lde;e1.Password=vze;e1.OTP=cze;var Ize={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z"}}]},name:"double-left",theme:"outlined"};function nG(){return nG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,nG({},e,{ref:t,icon:Ize})),aX=y.forwardRef(Dze);var Aze={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"};function iG(){return iG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,iG({},e,{ref:t,icon:Aze})),lX=y.forwardRef(Fze),Lze={items_per_page:"条/页",jump_to:"跳至",jump_to_confirm:"确定",page:"页",prev_page:"上一页",next_page:"下一页",prev_5:"向前 5 页",next_5:"向后 5 页",prev_3:"向前 3 页",next_3:"向后 3 页",page_size:"页码"},_ze=[10,20,50,100],Oze=e=>{const{pageSizeOptions:t=_ze,locale:r,changeSize:n,pageSize:i,goButton:o,quickGo:s,rootPrefixCls:a,disabled:l,buildOptionText:c,showSizeChanger:u,sizeChangerRender:d}=e,[h,p]=Z.useState(""),f=Z.useMemo(()=>!h||Number.isNaN(h)?void 0:Number(h),[h]),g=typeof c=="function"?c:M=>`${M} ${r.items_per_page}`,m=M=>{const D=M.target.value;/^\d*$/.test(D)&&p(D)},v=M=>{o||h===""||(p(""),!(M.relatedTarget&&(M.relatedTarget.className.includes(`${a}-item-link`)||M.relatedTarget.className.includes(`${a}-item`)))&&(s==null||s(f)))},b=M=>{h!==""&&(M.keyCode===Zt.ENTER||M.type==="click")&&(p(""),s==null||s(f))},S=()=>t.some(M=>M.toString()===i.toString())?t:t.concat([i]).sort((M,D)=>{const A=Number.isNaN(Number(M))?0:Number(M),I=Number.isNaN(Number(D))?0:Number(D);return A-I}),x=`${a}-options`;if(!u&&!s)return null;let E=null,R=null,T=null;return u&&d&&(E=d({disabled:l,size:i,onSizeChange:M=>{n==null||n(Number(M))},"aria-label":r.page_size,className:`${x}-size-changer`,options:S().map(M=>({label:g(M),value:M}))})),s&&(o&&(T=typeof o=="boolean"?Z.createElement("button",{type:"button",onClick:b,onKeyUp:b,disabled:l,className:`${x}-quick-jumper-button`},r.jump_to_confirm):Z.createElement("span",{onClick:b,onKeyUp:b},o)),R=Z.createElement("div",{className:`${x}-quick-jumper`},r.jump_to,Z.createElement("input",{disabled:l,type:"text",value:h,onChange:m,onKeyUp:b,onBlur:v,"aria-label":r.page}),r.page,T)),Z.createElement("li",{className:x},E,R)},lS=e=>{const{rootPrefixCls:t,page:r,active:n,className:i,style:o,showTitle:s,onClick:a,onKeyPress:l,itemRender:c}=e,u=`${t}-item`,d=Q(u,`${u}-${r}`,{[`${u}-active`]:n,[`${u}-disabled`]:!r},i),h=()=>{a(r)},p=g=>{l(g,a,r)},f=c(r,"page",Z.createElement("a",{rel:"nofollow"},r));return f?Z.createElement("li",{title:s?String(r):null,className:d,style:o,onClick:h,onKeyDown:p,tabIndex:0},f):null};function Gh(){return Gh=Object.assign?Object.assign.bind():function(e){for(var t=1;tr;function cX(){}function uX(e){const t=Number(e);return typeof t=="number"&&!Number.isNaN(t)&&isFinite(t)&&Math.floor(t)===t}function bf(e,t,r){const n=typeof e>"u"?t:e;return Math.floor((r-1)/n)+1}const Nze=e=>{const{prefixCls:t="rc-pagination",selectPrefixCls:r="rc-select",className:n,classNames:i,styles:o,current:s,defaultCurrent:a=1,total:l=0,pageSize:c,defaultPageSize:u=10,onChange:d=cX,hideOnSinglePage:h,align:p,showPrevNextJumpers:f=!0,showQuickJumper:g,showLessItems:m,showTitle:v=!0,onShowSizeChange:b=cX,locale:S=Lze,style:x,totalBoundaryShowSizeChanger:E=50,disabled:R,simple:T,showTotal:M,showSizeChanger:D=l>E,sizeChangerRender:A,pageSizeOptions:I,itemRender:L=kze,jumpPrevIcon:F,jumpNextIcon:k,prevIcon:O,nextIcon:B}=e,H=Z.useRef(null),[N,z]=An(u,c),[W,V]=An(a,s),$=Math.max(1,Math.min(W,bf(void 0,N,l))),[K,q]=Z.useState($);y.useEffect(()=>{q($)},[$]);const X=Math.max(1,$-(m?3:5)),Y=Math.min(bf(void 0,N,l),$+(m?3:5));function oe(Re,it){let Ve=Re||Z.createElement("button",{type:"button","aria-label":it,className:`${t}-item-link`});return typeof Re=="function"&&(Ve=Z.createElement(Re,e)),Ve}function ee(Re){const it=Re.target.value,Ve=bf(void 0,N,l);let Oe;return it===""?Oe=it:Number.isNaN(Number(it))?Oe=K:it>=Ve?Oe=Ve:Oe=Number(it),Oe}function ne(Re){return uX(Re)&&Re!==$&&uX(l)&&l>0}const le=l>N?g:!1;function he(Re){(Re.keyCode===Zt.UP||Re.keyCode===Zt.DOWN)&&Re.preventDefault()}function re(Re){const it=ee(Re);switch(it!==K&&q(it),Re.keyCode){case Zt.ENTER:J(it);break;case Zt.UP:J(it-1);break;case Zt.DOWN:J(it+1);break}}function ie(Re){J(ee(Re))}function de(Re){const it=bf(Re,N,l),Ve=$>it&&it!==0?it:$;z(Re),q(Ve),b==null||b($,Re),V(Ve),d==null||d(Ve,Re)}function J(Re){if(ne(Re)&&!R){const it=bf(void 0,N,l);let Ve=Re;return Re>it?Ve=it:Re<1&&(Ve=1),Ve!==K&&q(Ve),V(Ve),d==null||d(Ve,N),Ve}return $}const ue=$>1,ve=$l?l:$*N]));let ot=null;const Ye=bf(void 0,N,l);if(h&&l<=N)return null;const Ae=[],nt={rootPrefixCls:t,onClick:J,onKeyPress:Ee,showTitle:v,itemRender:L,page:-1,className:i==null?void 0:i.item,style:o==null?void 0:o.item},Et=$-1>0?$-1:0,Tt=$+1=Ut*2&&$!==3&&(Ae[0]=Z.cloneElement(Ae[0],{className:Q(`${t}-item-after-jump-prev`,Ae[0].props.className)}),Ae.unshift(tt)),Ye-$>=Ut*2&&$!==Ye-2){const fe=Ae[Ae.length-1];Ae[Ae.length-1]=Z.cloneElement(fe,{className:Q(`${t}-item-before-jump-next`,fe.props.className)}),Ae.push(ot)}se!==1&&Ae.unshift(Z.createElement(lS,Gh({},nt,{key:1,page:1}))),ce!==Ye&&Ae.push(Z.createElement(lS,Gh({},nt,{key:Ye,page:Ye})))}let cr=St(Et);if(cr){const Re=!ue||!Ye;cr=Z.createElement("li",{title:v?S.prev_page:null,onClick:pe,tabIndex:Re?null:0,onKeyDown:We,className:Q(`${t}-prev`,i==null?void 0:i.item,{[`${t}-disabled`]:Re}),style:o==null?void 0:o.item,"aria-disabled":Re},cr)}let _e=Ze(Tt);if(_e){let Re,it;T?(Re=!ve,it=ue?0:null):(Re=!ve||!Ye,it=Re?null:0),_e=Z.createElement("li",{title:v?S.next_page:null,onClick:me,tabIndex:it,onKeyDown:ze,className:Q(`${t}-next`,i==null?void 0:i.item,{[`${t}-disabled`]:Re}),style:o==null?void 0:o.item,"aria-disabled":Re},_e)}const qe=Q(t,n,{[`${t}-start`]:p==="start",[`${t}-center`]:p==="center",[`${t}-end`]:p==="end",[`${t}-simple`]:T,[`${t}-disabled`]:R});return Z.createElement("ul",Gh({className:qe,style:x,ref:H},Ne),rt,cr,T?lt:Ae,_e,Z.createElement(Oze,{locale:S,rootPrefixCls:t,disabled:R,selectPrefixCls:r,changeSize:de,pageSize:N,pageSizeOptions:I,quickGo:le?J:null,goButton:at,showSizeChanger:D,sizeChangerRender:A}))},Bze=e=>{const{componentCls:t}=e;return{[`${t}-disabled`]:{"&, &:hover":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}},"&:focus-visible":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-item`]:{cursor:"not-allowed",backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"},a:{color:e.colorTextDisabled,backgroundColor:"transparent",border:"none",cursor:"not-allowed"},"&-active":{borderColor:e.colorBorder,backgroundColor:e.itemActiveBgDisabled,"&:hover, &:active":{backgroundColor:e.itemActiveBgDisabled},a:{color:e.itemActiveColorDisabled}}},[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed","&:hover, &:active":{backgroundColor:"transparent"},[`${t}-simple&`]:{backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"}}},[`${t}-simple-pager`]:{color:e.colorTextDisabled},[`${t}-jump-prev, ${t}-jump-next`]:{[`${t}-item-link-icon`]:{opacity:0},[`${t}-item-ellipsis`]:{opacity:1}}}}},$ze=e=>{const{componentCls:t}=e;return{[`&${t}-small ${t}-options`]:{marginInlineStart:e.paginationMiniOptionsMarginInlineStart,"&-quick-jumper":{input:{...w4(e),width:e.paginationMiniQuickJumperInputWidth}}}}},Gze=e=>{const{componentCls:t}=e;return{[`&${t}-large ${t}-options`]:{"&-quick-jumper":{input:{...S4(e)}}}}},Vze=e=>{const{componentCls:t,antCls:r}=e,[,n]=Jn(r,"pagination");return{[`&${t}-simple`]:{[`${t}-prev, ${t}-next`]:{height:n("item-size-actual"),lineHeight:n("item-size-actual"),verticalAlign:"top",[`${t}-item-link`]:{height:n("item-size-actual"),backgroundColor:"transparent",border:0,"&:hover":{backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive},"&::after":{height:n("item-size-actual"),lineHeight:n("item-size-actual")}}},[`${t}-simple-pager`]:{display:"inline-flex",alignItems:"center",height:n("item-size-actual"),marginInlineEnd:n("item-spacing-actual"),input:{boxSizing:"border-box",height:"100%",width:e.quickJumperInputWidth,padding:`0 ${ae(e.paginationItemPaddingInline)}`,textAlign:"center",backgroundColor:e.itemInputBg,border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadius,outline:"none",transition:`border-color ${e.motionDurationMid}`,color:"inherit","&:hover":{borderColor:e.colorPrimary},"&:focus":{borderColor:e.colorPrimaryHover,boxShadow:`${ae(e.inputOutlineOffset)} 0 ${ae(e.controlOutlineWidth)} ${e.controlOutline}`},"&[disabled]":{color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,cursor:"not-allowed"}}},[`&${t}-disabled`]:{[`${t}-prev, ${t}-next`]:{[`${t}-item-link`]:{"&:hover, &:active":{backgroundColor:"transparent"}}}},[`&${t}-small`]:{[`${t}-simple-pager`]:{input:{width:e.paginationMiniQuickJumperInputWidth}}}}}},zze=e=>{const{componentCls:t,antCls:r}=e,[,n]=Jn(r,"pagination");return{[`${t}-jump-prev, ${t}-jump-next`]:{outline:0,[`${t}-item-container`]:{position:"relative",[`${t}-item-link-icon`]:{color:e.colorPrimary,fontSize:e.fontSizeSM,opacity:0,transition:`all ${e.motionDurationMid}`,"&-svg":{top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,margin:"auto"}},[`${t}-item-ellipsis`]:{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,display:"block",margin:"auto",color:e.colorTextDisabled,letterSpacing:e.paginationEllipsisLetterSpacing,textAlign:"center",textIndent:e.paginationEllipsisTextIndent,opacity:1,transition:`all ${e.motionDurationMid}`}},"&:hover":{[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0}}},[` ${t}-prev, ${t}-jump-prev, ${t}-jump-next `]:{marginInlineEnd:n("item-spacing-actual")},[` ${t}-prev, ${t}-next, ${t}-jump-prev, ${t}-jump-next `]:{display:"inline-block",minWidth:n("item-size-actual"),height:n("item-size-actual"),color:e.colorText,fontFamily:e.fontFamily,lineHeight:n("item-size-actual"),textAlign:"center",verticalAlign:"middle",listStyle:"none",borderRadius:e.borderRadius,cursor:"pointer",transition:`all ${e.motionDurationMid}`},[`${t}-prev, ${t}-next`]:{outline:0,button:{color:e.colorText,cursor:"pointer",userSelect:"none"},[`${t}-item-link`]:{display:"block",width:"100%",height:"100%",padding:0,fontSize:e.fontSizeSM,textAlign:"center",backgroundColor:"transparent",border:`${ae(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:"none",transition:`all ${e.motionDurationMid}`},[`&:hover ${t}-item-link`]:{backgroundColor:e.colorBgTextHover},[`&:active ${t}-item-link`]:{backgroundColor:e.colorBgTextActive},[`&${t}-disabled:hover`]:{[`${t}-item-link`]:{backgroundColor:"transparent"}}},[`${t}-slash`]:{marginInlineEnd:e.paginationSlashMarginInlineEnd,marginInlineStart:e.paginationSlashMarginInlineStart},[`${t}-options`]:{display:"inline-block",marginInlineStart:e.margin,verticalAlign:"middle","&-size-changer":{width:"auto"},"&-quick-jumper":{display:"inline-block",height:n("item-size-actual"),marginInlineStart:e.marginXS,lineHeight:n("item-size-actual"),verticalAlign:"baseline",input:{...rA(e),...b4(e,{borderColor:e.colorBorder,hoverBorderColor:e.colorPrimaryHover,activeBorderColor:e.colorPrimary,activeShadow:e.activeShadow}),"&[disabled]":{...tA(e)},width:e.quickJumperInputWidth,height:n("item-size-actual"),boxSizing:"border-box",margin:0,marginInlineStart:n("item-spacing-actual"),marginInlineEnd:n("item-spacing-actual")}}}}},Hze=e=>{const{componentCls:t,antCls:r}=e,[,n]=Jn(r,"pagination");return{[`${t}-item`]:{display:"inline-block",minWidth:n("item-size-actual"),height:n("item-size-actual"),marginInlineEnd:n("item-spacing-actual"),fontFamily:e.fontFamily,lineHeight:ae(e.calc(n("item-size-actual")).sub(2).equal()),textAlign:"center",verticalAlign:"middle",listStyle:"none",backgroundColor:e.itemBg,border:`${ae(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:0,cursor:"pointer",userSelect:"none",a:{display:"block",padding:`0 ${ae(e.paginationItemPaddingInline)}`,color:e.colorText,"&:hover":{textDecoration:"none"}},[`&:not(${t}-item-active)`]:{"&:hover":{transition:`all ${e.motionDurationMid}`,backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive}},"&-active":{fontWeight:e.fontWeightStrong,backgroundColor:e.itemActiveBg,borderColor:e.colorPrimary,a:{color:e.itemActiveColor},"&:hover":{borderColor:e.colorPrimaryHover},"&:hover a":{color:e.itemActiveColorHover}}}}},Wze=e=>{const{componentCls:t,antCls:r}=e,[n,i]=Jn(r,"pagination");return{[t]:{[n("item-size-actual")]:ae(e.itemSize),[n("item-spacing-actual")]:ae(e.marginXS),"&-small":{[n("item-size-actual")]:ae(e.itemSizeSM),[n("item-spacing-actual")]:ae(e.marginXXS)},"&-large":{[n("item-size-actual")]:ae(e.itemSizeLG),[n("item-spacing-actual")]:ae(e.marginSM)},...on(e),display:"flex",alignItems:"center","&-start":{justifyContent:"start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"end"},"ul, ol":{margin:0,padding:0,listStyle:"none"},"&::after":{display:"block",clear:"both",height:0,overflow:"hidden",visibility:"hidden",content:'""'},[`${t}-total-text`]:{display:"inline-block",height:i("item-size-actual"),marginInlineEnd:i("item-spacing-actual"),lineHeight:ae(e.calc(i("item-size-actual")).sub(2).equal()),verticalAlign:"middle"},...Hze(e),...zze(e),...Vze(e),...$ze(e),...Gze(e),...Bze(e),[`@media only screen and (max-width: ${e.screenLG}px)`]:{[`${t}-item`]:{"&-after-jump-prev, &-before-jump-next":{display:"none"}}},[`@media only screen and (max-width: ${e.screenSM}px)`]:{[`${t}-options`]:{display:"none"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}}},Uze=e=>{const{componentCls:t}=e;return{[`${t}:not(${t}-disabled)`]:{[`${t}-item`]:{...wl(e)},[`${t}-jump-prev, ${t}-jump-next`]:{"&:focus-visible":{[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0},...gc(e)}},[`${t}-prev, ${t}-next`]:{[`&:focus-visible ${t}-item-link`]:gc(e)}}}},cde=e=>({itemBg:e.colorBgContainer,itemSize:e.controlHeight,itemSizeSM:e.controlHeightSM,itemSizeLG:e.controlHeightLG,itemActiveBg:e.colorBgContainer,itemActiveColor:e.colorPrimary,itemActiveColorHover:e.colorPrimaryHover,itemLinkBg:e.colorBgContainer,itemActiveColorDisabled:e.colorTextDisabled,itemActiveBgDisabled:e.controlItemBgActiveDisabled,itemInputBg:e.colorBgContainer,miniOptionsSizeChangerTop:0,...OC(e)}),ude=e=>$r(e,{inputOutlineOffset:0,quickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.25).equal(),paginationMiniOptionsMarginInlineStart:e.calc(e.marginXXS).div(2).equal(),paginationMiniQuickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.1).equal(),paginationItemPaddingInline:e.calc(e.marginXXS).mul(1.5).equal(),paginationEllipsisLetterSpacing:e.calc(e.marginXXS).div(2).equal(),paginationSlashMarginInlineStart:e.marginSM,paginationSlashMarginInlineEnd:e.marginSM,paginationEllipsisTextIndent:"0.13em"},_C(e)),jze=Wr("Pagination",e=>{const t=ude(e);return[Wze(t),Uze(t)]},cde),Kze=e=>{const{componentCls:t}=e;return{[`${t}${t}-bordered${t}-disabled`]:{"&, &:hover":{[`${t}-item-link`]:{borderColor:e.colorBorder}},"&:focus-visible":{[`${t}-item-link`]:{borderColor:e.colorBorder}},[`${t}-item, ${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,[`&:hover:not(${t}-item-active)`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,a:{color:e.colorTextDisabled}},[`&${t}-item-active`]:{backgroundColor:e.itemActiveBgDisabled}},[`${t}-prev, ${t}-next`]:{"&:hover button":{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,color:e.colorTextDisabled},[`${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder}}},[`${t}${t}-bordered`]:{[`${t}-prev, ${t}-next`]:{"&:hover button":{borderColor:e.colorPrimaryHover,backgroundColor:e.itemBg},[`${t}-item-link`]:{backgroundColor:e.itemLinkBg,borderColor:e.colorBorder},[`&:hover ${t}-item-link`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,color:e.colorPrimary},[`&${t}-disabled`]:{[`${t}-item-link`]:{borderColor:e.colorBorder,color:e.colorTextDisabled}}},[`${t}-item`]:{backgroundColor:e.itemBg,border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,[`&:hover:not(${t}-item-active)`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,a:{color:e.colorPrimary}},"&-active":{borderColor:e.colorPrimary}}}}},qze=Dx(["Pagination","bordered"],e=>{const t=ude(e);return Kze(t)},cde);function dX(e){return y.useMemo(()=>typeof e=="boolean"?[e,{}]:e&&typeof e=="object"?[!0,e]:[void 0,void 0],[e])}const dde=e=>{const{align:t,prefixCls:r,selectPrefixCls:n,className:i,rootClassName:o,style:s,size:a,locale:l,responsive:c,showSizeChanger:u,selectComponentClass:d,pageSizeOptions:h,styles:p,classNames:f,...g}=e,{xs:m}=Kx(c),[,v]=fs(),{getPrefixCls:b,direction:S,showSizeChanger:x,className:E,style:R,classNames:T,styles:M,totalBoundaryShowSizeChanger:D}=Nr("pagination"),A=b("pagination",r),[I,L]=jze(A),F=ki(a),k=F==="small"||!!(m&&!F&&c),O={...e,size:F},[B,H]=Vr([T,f],[M,p],{props:O}),[N]=Dl("Pagination",jae),z={...N,...l},[W,V]=dX(u),[$,K]=dX(x),q=W??$,X=V??K,Y=d||vu,oe=y.useMemo(()=>h?h.map(Number):void 0,[h]),ee=ie=>{var We;const{disabled:de,size:J,onSizeChange:ue,"aria-label":ve,className:pe,options:me}=ie,{className:ke,onChange:De}=X||{},Ee=(We=me.find(ze=>String(ze.value)===String(J)))==null?void 0:We.value;return y.createElement(Y,{disabled:de,showSearch:!0,popupMatchSelectWidth:!1,getPopupContainer:ze=>ze.parentNode,"aria-label":ve,options:me,...X,value:Ee,onChange:(ze,mt)=>{ue==null||ue(ze),De==null||De(ze,mt)},size:F,className:Q(pe,ke)})},ne=y.useMemo(()=>{const ie=y.createElement("span",{className:`${A}-item-ellipsis`},"•••"),de=y.createElement("button",{className:`${A}-item-link`,type:"button",tabIndex:-1},S==="rtl"?y.createElement(JB,null):y.createElement(F$,null)),J=y.createElement("button",{className:`${A}-item-link`,type:"button",tabIndex:-1},S==="rtl"?y.createElement(F$,null):y.createElement(JB,null)),ue=y.createElement("a",{className:`${A}-item-link`},y.createElement("div",{className:`${A}-item-container`},S==="rtl"?y.createElement(lX,{className:`${A}-item-link-icon`}):y.createElement(aX,{className:`${A}-item-link-icon`}),ie)),ve=y.createElement("a",{className:`${A}-item-link`},y.createElement("div",{className:`${A}-item-container`},S==="rtl"?y.createElement(aX,{className:`${A}-item-link-icon`}):y.createElement(lX,{className:`${A}-item-link-icon`}),ie));return{prevIcon:de,nextIcon:J,jumpPrevIcon:ue,jumpNextIcon:ve}},[S,A]),le=b("select",n),he=Q({[`${A}-${t}`]:!!t,[`${A}-${F}`]:F,[`${A}-mini`]:k,[`${A}-rtl`]:S==="rtl",[`${A}-bordered`]:v.wireframe},E,i,o,B.root,I,L),re={...H.root,...R,...s};return y.createElement(y.Fragment,null,v.wireframe&&y.createElement(qze,{prefixCls:A}),y.createElement(Nze,{...ne,...g,styles:H,classNames:B,style:re,prefixCls:A,selectPrefixCls:le,className:he,locale:z,pageSizeOptions:oe,showSizeChanger:q,totalBoundaryShowSizeChanger:g.totalBoundaryShowSizeChanger??D,sizeChangerRender:ee}))},MM=100,hde=MM/5,pde=MM/2-hde/2,dO=pde*2*Math.PI,hX=50,pX=e=>{const{dotClassName:t,style:r,hasCircleCls:n}=e;return y.createElement("circle",{className:Q(`${t}-circle`,{[`${t}-circle-bg`]:n}),r:pde,cx:hX,cy:hX,strokeWidth:hde,style:r})},Xze=({percent:e,prefixCls:t})=>{const r=`${t}-dot`,n=`${r}-holder`,i=`${n}-hidden`,[o,s]=y.useState(!1);jr(()=>{e!==0&&s(!0)},[e!==0]);const a=Math.max(Math.min(e,100),0);if(!o)return null;const l={strokeDashoffset:`${dO/4}`,strokeDasharray:`${dO*a/100} ${dO*(100-a)/100}`};return y.createElement("span",{className:Q(n,`${r}-progress`,a<=0&&i)},y.createElement("svg",{viewBox:`0 0 ${MM} ${MM}`,role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":a},y.createElement(pX,{dotClassName:r,hasCircleCls:!0}),y.createElement(pX,{dotClassName:r,style:l})))};function Yze(e){const{prefixCls:t,percent:r=0,className:n,style:i}=e,o=`${t}-dot`,s=`${o}-holder`,a=`${s}-hidden`;return y.createElement(y.Fragment,null,y.createElement("span",{className:Q(s,n,r>0&&a),style:i},y.createElement("span",{className:Q(o,`${t}-dot-spin`)},[1,2,3,4].map(l=>y.createElement("i",{className:`${t}-dot-item`,key:l})))),y.createElement(Xze,{prefixCls:t,percent:r}))}function Zze(e){const{prefixCls:t,indicator:r,percent:n,className:i,style:o}=e,s=`${t}-dot`;return r&&y.isValidElement(r)?Ei(r,a=>({className:Q(a.className,s,i),style:{...a.style,...o},percent:n})):y.createElement(Yze,{prefixCls:t,percent:n,className:i,style:o})}const Qze=new qr("antSpinMove",{to:{opacity:1}}),Jze=new qr("antRotate",{to:{transform:"rotate(405deg)"}}),eHe=e=>{const{componentCls:t}=e,r=`${t}-section`;return{[t]:{...on(e),position:"relative","&-rtl":{direction:"rtl"},[`&${r}, ${r}`]:{display:"flex",alignItems:"center",flexDirection:"column",gap:e.paddingSM,color:e.colorPrimary},[`&${r}`]:{display:"inline-flex"},[r]:{position:"absolute",top:"50%",left:{_skip_check_:!0,value:"50%"},transform:"translate(-50%, -50%)",zIndex:1},[`${t}-description`]:{fontSize:e.fontSize,lineHeight:1},[`${t}-container`]:{position:"relative",transition:`opacity ${e.motionDurationSlow}`,"&::after":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,zIndex:10,width:"100%",height:"100%",background:e.colorBgContainer,opacity:0,transition:`all ${e.motionDurationSlow}`,content:'""',pointerEvents:"none"}},"&-spinning":{[`${t}-description`]:{textShadow:`0 0px 5px ${e.colorBgContainer}`},[`${t}-container`]:{clear:"both",opacity:.5,userSelect:"none",pointerEvents:"none","&::after":{opacity:.4,pointerEvents:"auto"}}},"&-fullscreen":{position:"fixed",inset:0,backgroundColor:e.colorBgMask,zIndex:e.zIndexPopupBase,opacity:0,pointerEvents:"none",transition:`all ${e.motionDurationMid}`,[`&${t}-spinning`]:{opacity:1,pointerEvents:"auto"},[r]:{color:e.colorWhite,[`${t}-description`]:{color:e.colorTextLightSolid}}}}}},tHe=e=>{const{componentCls:t,antCls:r,motionDurationSlow:n}=e,[i,o]=Jn(r,"spin");return{[t]:{[i("dot-holder-size")]:e.dotSize,[i("dot-item-size")]:`calc((${o("dot-holder-size")} - ${e.marginXXS} / 2) / 2)`,[`${t}-dot`]:{"&-holder":{width:"1em",height:"1em",fontSize:o("dot-holder-size"),display:"inline-block",transition:["transform","opacity"].map(s=>`${s} ${n} ease`).join(", "),transformOrigin:"50% 50%",lineHeight:1,"&-hidden":{transform:"scale(0.3)",opacity:0}},position:"relative",display:"inline-block",fontSize:o("dot-holder-size"),width:"1em",height:"1em","&-spin":{transform:"rotate(45deg)",animationName:Jze,animationDuration:"1.2s",animationIterationCount:"infinite",animationTimingFunction:"linear"},"&-item":{position:"absolute",display:"block",width:o("dot-item-size"),height:o("dot-item-size"),background:"currentColor",borderRadius:"100%",transform:"scale(0.75)",transformOrigin:"50% 50%",opacity:.3,animationName:Qze,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear",animationDirection:"alternate","&:nth-child(1)":{top:0,insetInlineStart:0,animationDelay:"0s"},"&:nth-child(2)":{top:0,insetInlineEnd:0,animationDelay:"0.4s"},"&:nth-child(3)":{insetInlineEnd:0,bottom:0,animationDelay:"0.8s"},"&:nth-child(4)":{bottom:0,insetInlineStart:0,animationDelay:"1.2s"}},"&-progress":{position:"absolute",left:"50%",top:0,transform:"translateX(-50%)"},"&-circle":{strokeLinecap:"round",transition:["stroke-dashoffset","stroke-dasharray","stroke","stroke-width","opacity"].map(s=>`${s} ${n} ease`).join(","),fillOpacity:0,stroke:"currentcolor"},"&-circle-bg":{stroke:e.colorFillSecondary}}}}},rHe=e=>{const{componentCls:t}=e,[r]=Jn(e.antCls,"spin");return{[t]:{"&-sm":{[r("dot-holder-size")]:e.dotSizeSM},"&-lg":{[r("dot-holder-size")]:e.dotSizeLG}}}},nHe=e=>{const{controlHeightLG:t,controlHeight:r}=e;return{contentHeight:400,dotSize:t/2,dotSizeSM:t*.35,dotSizeLG:r}},iHe=Wr("Spin",e=>{const t=$r(e,{spinDotDefault:e.colorTextDescription});return[eHe(t),tHe(t),rHe(t)]},nHe),oHe=200,fX=[[30,.05],[70,.03],[96,.01]];function sHe(e,t){const[r,n]=y.useState(0),i=y.useRef(null),o=t==="auto";return y.useEffect(()=>(o&&e&&(n(0),i.current=setInterval(()=>{n(s=>{const a=100-s;for(let l=0;l{i.current&&(clearInterval(i.current),i.current=null)}),[o,e]),o?r:t}let fde;function aHe(e,t){return!!e&&!!t&&!Number.isNaN(Number(t))}const D4=e=>{const{prefixCls:t,spinning:r=!0,delay:n=0,className:i,rootClassName:o,size:s,tip:a,description:l,wrapperClassName:c,style:u,children:d,fullscreen:h=!1,indicator:p,percent:f,classNames:g,styles:m,...v}=e,{getPrefixCls:b,direction:S,indicator:x,className:E,style:R,classNames:T,styles:M}=Nr("spin"),D=b("spin",t),[A,I]=iHe(D),[L,F]=y.useState(()=>r&&!aHe(r,n)),k=sHe(L,f);y.useEffect(()=>{if(r){const q=fGe(n,()=>{F(!0)});return q(),()=>{var X;(X=q==null?void 0:q.cancel)==null||X.call(q)}}F(!1)},[n,r]);const O=ki(q=>s??q),B=l??a,H={...e,size:O,spinning:L,tip:B,description:B,fullscreen:h,children:d,percent:k},[N,z]=Vr([T,g],[M,m],{props:H}),W=p??x??fde,V=typeof d<"u",$=V||h,K=y.createElement(y.Fragment,null,y.createElement(Zze,{className:Q(N.indicator),style:z.indicator,prefixCls:D,indicator:W,percent:k}),B&&y.createElement("div",{className:Q(`${D}-description`,N.tip,N.description),style:{...z.tip,...z.description}},B));return y.createElement("div",{className:Q(D,{[`${D}-sm`]:O==="small",[`${D}-lg`]:O==="large",[`${D}-spinning`]:L,[`${D}-rtl`]:S==="rtl",[`${D}-fullscreen`]:h},o,N.root,h&&N.mask,$?c:[`${D}-section`,N.section],E,i,A,I),style:{...z.root,...$?{}:z.section,...h?z.mask:{},...R,...u},"aria-live":"polite","aria-busy":L,...v},L&&($?y.createElement("div",{className:Q(`${D}-section`,N.section),style:z.section},K):K),V&&y.createElement("div",{className:Q(`${D}-container`,N.container),style:z.container},d))};D4.setDefaultIndicator=e=>{fde=e};const A4=Z.createContext({});A4.Consumer;const lHe=({prefixCls:e,className:t,avatar:r,title:n,description:i,...o})=>{const{getPrefixCls:s}=y.useContext(ir),a=s("list",e),l=Q(`${a}-item-meta`,t),c=Z.createElement("div",{className:`${a}-item-meta-content`},n&&Z.createElement("h4",{className:`${a}-item-meta-title`},n),i&&Z.createElement("div",{className:`${a}-item-meta-description`},i));return Z.createElement("div",{...o,className:l},r&&Z.createElement("div",{className:`${a}-item-meta-avatar`},r),(n||i)&&c)},cHe=Z.forwardRef((e,t)=>{const{prefixCls:r,children:n,actions:i,extra:o,styles:s,className:a,classNames:l,colStyle:c,...u}=e,{grid:d,itemLayout:h}=y.useContext(A4),{getPrefixCls:p,list:f}=y.useContext(ir),g=T=>{var M,D;return Q((D=(M=f==null?void 0:f.item)==null?void 0:M.classNames)==null?void 0:D[T],l==null?void 0:l[T])},m=T=>{var M,D;return{...(D=(M=f==null?void 0:f.item)==null?void 0:M.styles)==null?void 0:D[T],...s==null?void 0:s[T]}},v=()=>{const T=Li(n);return T.some(D=>typeof D=="string")&&T.length>1},b=()=>h==="vertical"?!!o:!v(),S=p("list",r),x=i&&i.length>0&&Z.createElement("ul",{className:Q(`${S}-item-action`,g("actions")),key:"actions",style:m("actions")},i.map((T,M)=>Z.createElement("li",{key:`${S}-item-action-${M}`},T,M!==i.length-1&&Z.createElement("em",{className:`${S}-item-action-split`})))),E=d?"div":"li",R=Z.createElement(E,{...u,...d?{}:{ref:t},className:Q(`${S}-item`,{[`${S}-item-no-flex`]:!b()},a)},h==="vertical"&&o?[Z.createElement("div",{className:`${S}-item-main`,key:"content"},n,x),Z.createElement("div",{className:Q(`${S}-item-extra`,g("extra")),key:"extra",style:m("extra")},o)]:[n,x,Ei(o,{key:"extra"})]);return d?Z.createElement(EGe,{ref:t,flex:1,style:c},R):R}),gde=cHe;gde.Meta=lHe;const uHe=e=>{const{listBorderedCls:t,componentCls:r,paddingLG:n,margin:i,itemPaddingSM:o,itemPaddingLG:s,marginLG:a,borderRadiusLG:l}=e,c=ae(e.calc(l).sub(e.lineWidth).equal());return{[t]:{border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:l,[`${r}-header`]:{borderRadius:`${c} ${c} 0 0`},[`${r}-footer`]:{borderRadius:`0 0 ${c} ${c}`},[`${r}-header,${r}-footer,${r}-item`]:{paddingInline:n},[`${r}-pagination`]:{margin:`${ae(i)} ${ae(a)}`}},[`${t}${r}-sm`]:{[`${r}-item,${r}-header,${r}-footer`]:{padding:o}},[`${t}${r}-lg`]:{[`${r}-item,${r}-header,${r}-footer`]:{padding:s}}}},dHe=e=>{const{componentCls:t,screenSM:r,screenMD:n,marginLG:i,marginSM:o,margin:s}=e;return{[`@media screen and (max-width:${n}px)`]:{[t]:{[`${t}-item`]:{[`${t}-item-action`]:{marginInlineStart:i}}},[`${t}-vertical`]:{[`${t}-item`]:{[`${t}-item-extra`]:{marginInlineStart:i}}}},[`@media screen and (max-width: ${r}px)`]:{[t]:{[`${t}-item`]:{flexWrap:"wrap",[`${t}-action`]:{marginInlineStart:o}}},[`${t}-vertical`]:{[`${t}-item`]:{flexWrap:"wrap-reverse",[`${t}-item-main`]:{minWidth:e.contentWidth},[`${t}-item-extra`]:{margin:`auto auto ${ae(s)}`}}}}}},hHe=e=>{const{componentCls:t,antCls:r,controlHeight:n,minHeight:i,paddingSM:o,marginLG:s,padding:a,itemPadding:l,colorPrimary:c,itemPaddingSM:u,itemPaddingLG:d,paddingXS:h,margin:p,colorText:f,colorTextDescription:g,motionDurationSlow:m,lineWidth:v,headerBg:b,footerBg:S,emptyTextPadding:x,metaMarginBottom:E,avatarMarginRight:R,titleMarginBottom:T,descriptionFontSize:M}=e;return{[t]:{...on(e),position:"relative","--rc-virtual-list-scrollbar-bg":e.colorSplit,"*":{outline:"none"},[`${t}-header`]:{background:b},[`${t}-footer`]:{background:S},[`${t}-header, ${t}-footer`]:{paddingBlock:o},[`${t}-pagination`]:{marginBlockStart:s,[`${r}-pagination-options`]:{textAlign:"start"}},[`${t}-spin`]:{minHeight:i,textAlign:"center"},[`${t}-items`]:{margin:0,padding:0,listStyle:"none"},[`${t}-item`]:{display:"flex",alignItems:"center",justifyContent:"space-between",padding:l,color:f,[`${t}-item-meta`]:{display:"flex",flex:1,alignItems:"flex-start",maxWidth:"100%",[`${t}-item-meta-avatar`]:{marginInlineEnd:R},[`${t}-item-meta-content`]:{flex:"1 0",width:0,color:f},[`${t}-item-meta-title`]:{margin:`0 0 ${ae(e.marginXXS)} 0`,color:f,fontSize:e.fontSize,lineHeight:e.lineHeight,"> a":{color:f,transition:`all ${m}`,"&:hover":{color:c}}},[`${t}-item-meta-description`]:{color:g,fontSize:M,lineHeight:e.lineHeight}},[`${t}-item-action`]:{flex:"0 0 auto",marginInlineStart:e.marginXXL,padding:0,fontSize:0,listStyle:"none","& > li":{position:"relative",display:"inline-block",padding:`0 ${ae(h)}`,color:g,fontSize:e.fontSize,lineHeight:e.lineHeight,textAlign:"center","&:first-child":{paddingInlineStart:0}},[`${t}-item-action-split`]:{position:"absolute",insetBlockStart:"50%",insetInlineEnd:0,width:v,height:e.calc(e.fontHeight).sub(e.calc(e.marginXXS).mul(2)).equal(),transform:"translateY(-50%)",backgroundColor:e.colorSplit}}},[`${t}-empty`]:{padding:`${ae(a)} 0`,color:g,fontSize:e.fontSizeSM,textAlign:"center"},[`${t}-empty-text`]:{padding:x,color:e.colorTextDisabled,fontSize:e.fontSize,textAlign:"center"},[`${t}-item-no-flex`]:{display:"block"}},[`${t}-grid ${r}-col > ${t}-item`]:{display:"block",maxWidth:"100%",marginBlockEnd:p,paddingBlock:0,borderBlockEnd:"none"},[`${t}-vertical ${t}-item`]:{alignItems:"initial",[`${t}-item-main`]:{display:"block",flex:1},[`${t}-item-extra`]:{marginInlineStart:s},[`${t}-item-meta`]:{marginBlockEnd:E,[`${t}-item-meta-title`]:{marginBlockStart:0,marginBlockEnd:T,color:f,fontSize:e.fontSizeLG,lineHeight:e.lineHeightLG}},[`${t}-item-action`]:{marginBlockStart:a,marginInlineStart:"auto","> li":{padding:`0 ${ae(a)}`,"&:first-child":{paddingInlineStart:0}}}},[`${t}-split ${t}-item`]:{borderBlockEnd:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`,"&:last-child":{borderBlockEnd:"none"}},[`${t}-split ${t}-header`]:{borderBlockEnd:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`},[`${t}-split${t}-empty ${t}-footer`]:{borderTop:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`},[`${t}-loading ${t}-spin-nested-loading`]:{minHeight:n},[`${t}-split${t}-something-after-last-item ${r}-spin-container > ${t}-items > ${t}-item:last-child`]:{borderBlockEnd:`${ae(e.lineWidth)} ${e.lineType} ${e.colorSplit}`},[`${t}-lg ${t}-item`]:{padding:d},[`${t}-sm ${t}-item`]:{padding:u},[`${t}:not(${t}-vertical)`]:{[`${t}-item-no-flex`]:{[`${t}-item-action`]:{float:"right"}}}}},pHe=e=>({contentWidth:220,itemPadding:`${ae(e.paddingContentVertical)} 0`,itemPaddingSM:`${ae(e.paddingContentVerticalSM)} ${ae(e.paddingContentHorizontal)}`,itemPaddingLG:`${ae(e.paddingContentVerticalLG)} ${ae(e.paddingContentHorizontalLG)}`,headerBg:"transparent",footerBg:"transparent",emptyTextPadding:e.padding,metaMarginBottom:e.padding,avatarMarginRight:e.padding,titleMarginBottom:e.paddingSM,descriptionFontSize:e.fontSize}),fHe=Wr("List",e=>{const t=$r(e,{listBorderedCls:`${e.componentCls}-bordered`,minHeight:e.controlHeightLG});return[hHe(t),uHe(t),dHe(t)]},pHe,{extraCssVarPrefixCls:({prefixCls:e})=>[`${e}-container`]}),gHe=(e,t)=>{const{pagination:r=!1,prefixCls:n,bordered:i=!1,split:o=!0,className:s,rootClassName:a,style:l,children:c,itemLayout:u,loadMore:d,grid:h,dataSource:p=[],size:f,header:g,footer:m,loading:v=!1,rowKey:b,renderItem:S,locale:x,...E}=e,R=r&&typeof r=="object"?r:{},[T,M]=y.useState(R.defaultCurrent||1),[D,A]=y.useState(R.defaultPageSize||10),{getPrefixCls:I,direction:L,className:F,style:k}=Nr("list"),{renderEmpty:O}=y.useContext(ir),B={current:1,total:0,position:"bottom"},H=Ee=>(We,ze)=>{var mt;M(We),A(ze),r&&((mt=r==null?void 0:r[Ee])==null||mt.call(r,We,ze))},N=H("onChange"),z=H("onShowSizeChange"),W=(Ee,We)=>{if(!S)return null;let ze;return typeof b=="function"?ze=b(Ee):b?ze=Ee[b]:ze=Ee.key,ze||(ze=`list-item-${We}`),y.createElement(y.Fragment,{key:ze},S(Ee,We))},V=!!(d||r||m),$=I("list",n),[K,q]=fHe($);let X=v;typeof X=="boolean"&&(X={spinning:X});const Y=!!(X!=null&&X.spinning),oe=ki(f);let ee="";switch(oe){case"large":ee="lg";break;case"small":ee="sm";break}const ne=Q($,{[`${$}-vertical`]:u==="vertical",[`${$}-${ee}`]:ee,[`${$}-split`]:o,[`${$}-bordered`]:i,[`${$}-loading`]:Y,[`${$}-grid`]:!!h,[`${$}-something-after-last-item`]:V,[`${$}-rtl`]:L==="rtl"},F,s,a,K,q),le=`${$}-container`,he=R0(B,{total:p.length,current:T,pageSize:D},r||{}),re=Math.ceil(he.total/he.pageSize);he.current=Math.min(he.current,re);const ie=r&&y.createElement("div",{className:Q(`${$}-pagination`)},y.createElement(dde,{align:"end",...he,onChange:N,onShowSizeChange:z}));let de=Pr(p);r&&p.length>(he.current-1)*he.pageSize&&(de=Pr(p).splice((he.current-1)*he.pageSize,he.pageSize));const J=Object.keys(h||{}).some(Ee=>su.includes(Ee)),ue=Kx(J),ve=y.useMemo(()=>{for(let Ee=0;Ee{if(!h)return;const Ee=ve&&h[ve]?h[ve]:h.column;if(Ee)return{width:`${100/Ee}%`,maxWidth:`${100/Ee}%`}},[JSON.stringify(h),ve]);let me=Y&&y.createElement("div",{style:{minHeight:53}});if(de.length>0){const Ee=de.map(W);me=h?y.createElement(RGe,{className:Q(le,q),gutter:h.gutter},y.Children.map(Ee,We=>y.createElement("div",{key:We==null?void 0:We.key,style:pe},We))):y.createElement("ul",{className:Q(`${$}-items`,le,q)},Ee)}else!c&&!Y&&(me=y.createElement("div",{className:`${$}-empty-text`},(x==null?void 0:x.emptyText)||(O==null?void 0:O("List"))||y.createElement(o4,{componentName:"List"})));const ke=he.position,De=y.useMemo(()=>({grid:h,itemLayout:u}),[JSON.stringify(h),u]);return y.createElement(A4.Provider,{value:De},y.createElement("div",{ref:t,style:{...k,...l},className:ne,...E},(ke==="top"||ke==="both")&&ie,g&&y.createElement("div",{className:`${$}-header`},g),y.createElement(D4,{...X},me,c),m&&y.createElement("div",{className:`${$}-footer`},m),d||(ke==="bottom"||ke==="both")&&ie))},mHe=y.forwardRef(gHe),vHe=mHe;vHe.Item=gde;const mde=(e,t={})=>!Tn(e)&&(t!=null&&t.skipEmpty)?[]:Array.isArray(e)?e:[e],yHe=e=>{const{prefixCls:t,className:r,closeIcon:n,closable:i,type:o,title:s,children:a,footer:l,classNames:c,styles:u,...d}=e,{getPrefixCls:h}=y.useContext(ir),{className:p,style:f,classNames:g,styles:m}=Nr("modal"),v=h(),b=t||h("modal"),S=ho(v),[x,E]=ece(b,S),[R,T]=Vr([g,c],[m,u],{props:e}),M=`${b}-confirm`;let D={};return o?D={closable:i??!1,title:"",footer:"",children:y.createElement(rce,{...e,prefixCls:b,confirmPrefixCls:M,rootPrefixCls:v,content:a})}:D={closable:i??!0,title:s,footer:l!==null&&y.createElement(Yle,{...e}),children:a},y.createElement($le,{prefixCls:b,className:Q(x,`${b}-pure-panel`,o&&M,o&&`${M}-${o}`,r,p,E,S,R.root),style:{...f,...T.root},...d,closeIcon:Xle(b,n),closable:i,classNames:R,styles:T,...D})},CHe=dce(yHe);function vde(e){return Hx(sce(e))}const Du=tce;Du.useModal=Ake;Du.info=function(t){return Hx(ace(t))};Du.success=function(t){return Hx(lce(t))};Du.error=function(t){return Hx(cce(t))};Du.warning=vde;Du.warn=vde;Du.confirm=function(t){return Hx(uce(t))};Du.destroyAll=function(){for(;Cg.length;){const t=Cg.pop();t&&t()}};Du.config=Mke;Du._InternalPanelDoNotUseOrYouWillBeFired=CHe;const bHe=e=>{const{componentCls:t,iconCls:r,antCls:n,zIndexPopup:i,colorText:o,colorWarning:s,marginXXS:a,marginXS:l,fontSize:c,fontWeightStrong:u,colorTextHeading:d}=e;return{[t]:{zIndex:i,[`&${n}-popover`]:{fontSize:c},[`${t}-message`]:{marginBottom:l,display:"flex",flexWrap:"nowrap",alignItems:"start",[`> ${t}-message-icon ${r}`]:{color:s,fontSize:c,lineHeight:1,marginInlineEnd:l},[`${t}-title`]:{fontWeight:u,color:d,"&:only-child":{fontWeight:"normal"}},[`${t}-description`]:{marginTop:a,color:o}},[`${t}-buttons`]:{textAlign:"end",whiteSpace:"nowrap",button:{marginInlineStart:l}}}}},SHe=e=>{const{zIndexPopupBase:t}=e;return{zIndexPopup:t+60}},yde=Wr("Popconfirm",bHe,SHe,{resetStyle:!1}),Cde=e=>{const{prefixCls:t,okButtonProps:r,cancelButtonProps:n,title:i,description:o,cancelText:s,okText:a,okType:l="primary",icon:c=y.createElement(GD,null),showCancel:u=!0,close:d,onConfirm:h,onCancel:p,onPopupClick:f,classNames:g,styles:m}=e,{getPrefixCls:v}=y.useContext(ir),[b]=Dl("Popconfirm",xl.Popconfirm),S=Uy(i),x=Uy(o);return y.createElement("div",{className:`${t}-inner-content`,onClick:f},y.createElement("div",{className:`${t}-message`},c&&y.createElement("span",{className:`${t}-message-icon`},c),y.createElement("div",{className:`${t}-message-text`},S&&y.createElement("div",{className:Q(`${t}-title`,g==null?void 0:g.title),style:m==null?void 0:m.title},S),x&&y.createElement("div",{className:Q(`${t}-description`,g==null?void 0:g.content),style:m==null?void 0:m.content},x))),y.createElement("div",{className:`${t}-buttons`},u&&y.createElement(ca,{onClick:p,size:"small",...n},s||(b==null?void 0:b.cancelText)),y.createElement(K3,{buttonProps:{size:"small",...G3(l),...r},actionFn:h,close:d,prefixCls:v("btn"),quitOnNullishReturnValue:!0,emitEvent:!0},a||(b==null?void 0:b.okText))))},wHe=e=>{const{prefixCls:t,placement:r,className:n,style:i,...o}=e,{getPrefixCls:s}=y.useContext(ir),a=s("popconfirm",t);return yde(a),y.createElement(Nce,{placement:r,className:Q(a,n),style:i,content:y.createElement(Cde,{prefixCls:a,...o})})},xHe=y.forwardRef((e,t)=>{const{prefixCls:r,placement:n="top",trigger:i,okType:o="primary",icon:s=y.createElement(GD,null),children:a,overlayClassName:l,onOpenChange:c,overlayStyle:u,styles:d,arrow:h,classNames:p,...f}=e,{getPrefixCls:g,className:m,style:v,classNames:b,styles:S,arrow:x,trigger:E}=Nr("popconfirm"),[R,T]=An(e.defaultOpen??!1,e.open),M=d4(h,x),D=i||E||"click",A=W=>{T(W),c==null||c(W)},I=()=>{A(!1)},L=W=>{var V;return(V=e.onConfirm)==null?void 0:V.call(void 0,W)},F=W=>{var V;A(!1),(V=e.onCancel)==null||V.call(void 0,W)},k=W=>{const{disabled:V=!1}=e;V||A(W)},O=g("popconfirm",r),B={...e,placement:n,trigger:D,okType:o,overlayStyle:u,styles:d,classNames:p},[H,N]=Vr([b,p],[S,d],{props:B}),z=Q(O,m,l,H.root);return yde(O),y.createElement(Bce,{arrow:M,...fn(f,["title"]),trigger:D,placement:n,onOpenChange:k,open:R,ref:t,classNames:{root:z,container:H.container,arrow:H.arrow},styles:{root:{...v,...N.root,...u},container:N.container,arrow:N.arrow},content:y.createElement(Cde,{okType:o,icon:s,...e,prefixCls:O,close:I,onConfirm:L,onCancel:F,classNames:H,styles:N}),"data-popover-inject":!0},a)}),EHe=xHe;EHe._InternalPanelDoNotUseOrYouWillBeFired=wHe;const THe={percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,railColor:"#D9D9D9",railWidth:1,gapPosition:"bottom",loading:!1},RHe=()=>{const e=y.useRef([]),t=y.useRef(null);return y.useEffect(()=>{const r=Date.now();let n=!1;e.current.forEach(i=>{if(!i)return;n=!0;const o=i.style;o.transitionDuration=".3s, .3s, .3s, .06s",t.current&&r-t.current<100&&(o.transitionDuration="0s, 0s")}),n&&(t.current=Date.now())}),e.current},gX=({bg:e,children:t})=>y.createElement("div",{style:{width:"100%",height:"100%",background:e}},t);function mX(e,t){return Object.keys(e).map(r=>{const n=parseFloat(r),i=`${Math.floor(n*t)}%`;return`${e[r]} ${i}`})}const PHe=y.forwardRef((e,t)=>{const{prefixCls:r,color:n,gradientId:i,radius:o,className:s,style:a,ptg:l,strokeLinecap:c,strokeWidth:u,size:d,gapDegree:h}=e,p=n&&typeof n=="object",f=p?"#FFF":void 0,g=d/2,m=y.createElement("circle",{className:Q(`${r}-circle-path`,s),r:o,cx:g,cy:g,stroke:f,strokeLinecap:c,strokeWidth:u,opacity:l===0?0:1,style:a,ref:t});if(!p)return m;const v=`${i}-conic`,b=h?`${180+h/2}deg`:"0deg",S=mX(n,(360-h)/360),x=mX(n,1),E=`conic-gradient(from ${b}, ${S.join(", ")})`,R=`linear-gradient(to ${h?"bottom":"top"}, ${x.join(", ")})`;return y.createElement(y.Fragment,null,y.createElement("mask",{id:v},m),y.createElement("foreignObject",{x:0,y:0,width:d,height:d,mask:`url(#${v})`},y.createElement(gX,{bg:R},y.createElement(gX,{bg:E}))))}),ow=100,hO=(e,t,r,n,i,o,s,a,l,c,u=0)=>{const d=r/100*360*((360-o)/360),h=o===0?0:{bottom:0,top:180,left:90,right:-90}[s];let p=(100-n)/100*t;l==="round"&&n!==100&&(p+=c/2,p>=t&&(p=t-.01));const f=ow/2;return{stroke:typeof a=="string"?a:void 0,strokeDasharray:`${t}px ${e}`,strokeDashoffset:p+u,transform:`rotate(${i+d+h}deg)`,transformOrigin:`${f}px ${f}px`,transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s, opacity .3s ease 0s",fillOpacity:0}},MHe=(({id:e,loading:t})=>{if(!t)return{indeterminateStyleProps:{},indeterminateStyleAnimation:null};const r=`${e}-indeterminate-animate`;return{indeterminateStyleProps:{transform:"rotate(0deg)",animation:`${r} 1s linear infinite`},indeterminateStyleAnimation:Z.createElement("style",null,`@keyframes ${r} { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }`)}});function oG(){return oG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{id:t,prefixCls:r,classNames:n={},styles:i={},steps:o,strokeWidth:s,railWidth:a,gapDegree:l=0,gapPosition:c,railColor:u,strokeLinecap:d,style:h,className:p,strokeColor:f,percent:g,loading:m,...v}={...THe,...e},b=ow/2,S=xc(t),x=`${S}-gradient`,E=b-s/2,R=Math.PI*2*E,T=l>0?90+l/2:-90,M=R*((360-l)/360),{count:D,gap:A}=typeof o=="object"?o:{count:o,gap:2},I=vX(g),L=vX(f),F=L.find($=>$&&typeof $=="object"),O=F&&typeof F=="object"?"butt":d,{indeterminateStyleProps:B,indeterminateStyleAnimation:H}=MHe({id:S,loading:m}),N=hO(R,M,0,100,T,l,c,u,O,s),z=RHe(),W=()=>{let $=0;return I.map((K,q)=>{const X=L[q]||L[L.length-1],Y=hO(R,M,$,K,T,l,c,X,O,s);return $+=K,y.createElement(PHe,{key:q,color:X,ptg:K,radius:E,prefixCls:r,gradientId:x,className:n.track,style:{...Y,...B,...i.track},strokeLinecap:O,strokeWidth:s,gapDegree:l,ref:oe=>{z[q]=oe},size:ow})}).reverse()},V=()=>{const $=Math.round(D*(I[0]/100)),K=100/D;let q=0;return new Array(D).fill(null).map((X,Y)=>{const oe=Y<=$-1?L[0]:u,ee=oe&&typeof oe=="object"?`url(#${x})`:void 0,ne=hO(R,M,q,K,T,l,c,oe,"butt",s,A);return q+=(M-ne.strokeDashoffset+A)*100/M,y.createElement("circle",{key:Y,className:Q(`${r}-circle-path`,n.track),r:E,cx:b,cy:b,stroke:ee,strokeWidth:s,opacity:1,style:{...ne,...i.track},ref:le=>{z[Y]=le}})})};return y.createElement("svg",oG({className:Q(`${r}-circle`,n.root,p),viewBox:`0 0 ${ow} ${ow}`,style:{...i.root,...h},id:t,role:"presentation"},v),!D&&y.createElement("circle",{className:Q(`${r}-circle-rail`,n.rail),r:E,cx:b,cy:b,stroke:u,strokeLinecap:O,strokeWidth:a||s,style:{...N,...i.rail}}),D?V():W(),H)};function kg(e){return!e||e<0?0:e>100?100:e}function IM({success:e}){let t;return e&&"percent"in e&&(t=e.percent),t}const DHe=({percent:e,success:t})=>{const r=kg(IM({success:t}));return[r,kg(kg(e)-r)]},AHe=({success:e={},strokeColor:t})=>{const{strokeColor:r}=e;return[r||Cy.green,t||null]},oA=(e,t,r)=>{let n=-1,i=-1;if(t==="step"){const o=r.steps,s=r.strokeWidth;typeof e=="string"||typeof e>"u"?(n=e==="small"?2:14,i=s??8):typeof e=="number"?[n,i]=[e,e]:[n=14,i=8]=Array.isArray(e)?e:[e.width,e.height],n*=o}else if(t==="line"){const o=r==null?void 0:r.strokeWidth;typeof e=="string"||typeof e>"u"?i=o||(e==="small"?6:8):typeof e=="number"?[n,i]=[e,e]:[n=-1,i=8]=Array.isArray(e)?e:[e.width,e.height]}else(t==="circle"||t==="dashboard")&&(typeof e=="string"||typeof e>"u"?[n,i]=e==="small"?[60,60]:[120,120]:typeof e=="number"?[n,i]=[e,e]:Array.isArray(e)&&(n=e[0]??e[1]??120,i=e[0]??e[1]??120));return[n,i]},FHe=3,LHe=e=>FHe/e*100,yX=["root","body","indicator"],_He=e=>{const{prefixCls:t,classNames:r,styles:n,railColor:i,trailColor:o,strokeLinecap:s="round",gapPosition:a,gapPlacement:l,gapDegree:c,width:u=120,type:d,children:h,success:p,size:f=u,steps:g}=e,{direction:m}=Nr("progress"),v=i??o,[b,S]=oA(f,"circle");let{strokeWidth:x}=e;x===void 0&&(x=Math.max(LHe(b),6));const E={width:b,height:S,fontSize:b*.15+6},R=y.useMemo(()=>{if(c||c===0)return c;if(d==="dashboard")return 75},[c,d]),T=DHe(e),M=y.useMemo(()=>{const O=(l??a)||d==="dashboard"&&"bottom"||void 0,B=m==="rtl";switch(O){case"start":return B?"right":"left";case"end":return B?"left":"right";default:return O}},[m,l,a,d]),D=Object.prototype.toString.call(e.strokeColor)==="[object Object]",A=AHe({success:p,strokeColor:e.strokeColor}),I=Q(`${t}-body`,{[`${t}-circle-gradient`]:D},r.body),L=y.createElement(IHe,{steps:g,percent:g?T[1]:T,strokeWidth:x,railWidth:x,strokeColor:g?A[1]:A,strokeLinecap:s,railColor:v,prefixCls:t,gapDegree:R,gapPosition:M,classNames:fn(r,yX),styles:fn(n,yX)}),F=b<=20,k=y.createElement("div",{className:I,style:{...E,...n.body}},L,!F&&h);return F?y.createElement(El,{title:h},k):k},sG="--progress-line-stroke-color",OHe=e=>{const t="-100%";return new qr("antProgressLTRActive",{"0%":{transform:`translateX(${t}) scaleX(0)`,opacity:.1},"20%":{transform:`translateX(${t}) scaleX(0)`,opacity:.5},to:{transform:"translateX(0) scaleX(1)",opacity:0}})},kHe=e=>{const{componentCls:t,iconCls:r}=e;return{[t]:{...on(e),display:"inline-flex","&-rtl":{direction:"rtl"},[`${t}-indicator`]:{color:e.colorText,lineHeight:1,whiteSpace:"nowrap",verticalAlign:"middle",wordBreak:"normal",[r]:{fontSize:e.fontSize}},[`&${t}-status-exception`]:{[`${t}-indicator`]:{color:e.colorError}},[`&${t}-status-success`]:{[`${t}-indicator`]:{color:e.colorSuccess}}}}},NHe=e=>{const{componentCls:t}=e;return{[`${t}-line`]:{position:"relative",width:"100%",fontSize:e.fontSize,[`${t}-body`]:{display:"inline-flex",alignItems:"center",width:"100%",gap:e.marginXS},[`${t}-rail`]:{flex:"auto",background:e.remainingColor,borderRadius:e.lineBorderRadius,position:"relative",width:"100%",overflow:"hidden"},[`&${t}-status-active`]:{[`${t}-track:after`]:{content:'""',position:"absolute",inset:0,backgroundColor:e.colorBgContainer,borderRadius:"inherit",opacity:0,animationName:OHe(),animationDuration:e.progressActiveMotionDuration,animationTimingFunction:e.motionEaseOutQuint,animationIterationCount:"infinite"}},[`${t}-track`]:{position:"absolute",insetInlineStart:0,insetBlock:0,borderRadius:"inherit",background:e.defaultColor,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOutCirc}`,minWidth:"max-content",display:"flex",alignItems:"center","&-success":{background:e.colorSuccess}},[`&${t}-status-exception`]:{[`${t}-track`]:{background:e.colorError}},[`&${t}-status-success`]:{[`${t}-track`]:{background:e.colorSuccess}},[`${t}-indicator-outer`]:{[`&${t}-indicator-start`]:{order:-1}},[`${t}-body-layout-bottom`]:{flexDirection:"column",alignItems:"center",gap:e.marginXXS},[`${t}-indicator${t}-indicator-inner`]:{color:e.colorWhite,paddingInline:e.paddingXXS,width:"100%",display:"flex",justifyContent:"center",[`&${t}-indicator-end`]:{justifyContent:"end"},[`&${t}-indicator-start`]:{justifyContent:"start"},[`&${t}-indicator-bright`]:{color:"rgba(0, 0, 0, 0.45)"}}}}},BHe=e=>{const{componentCls:t,iconCls:r}=e;return{[`${t}-circle`]:{[`${t}-circle-rail`]:{stroke:e.remainingColor},[`${t}-body:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.defaultColor}},[`${t}-body`]:{position:"relative",lineHeight:1,backgroundColor:"transparent"},[`${t}-indicator`]:{position:"absolute",insetBlockStart:"50%",insetInlineStart:0,width:"100%",margin:0,padding:0,color:e.circleTextColor,fontSize:e.circleTextFontSize,lineHeight:1,whiteSpace:"normal",textAlign:"center",transform:"translateY(-50%)",[r]:{fontSize:e.circleIconFontSize}},[`&${t}-status-exception`]:{[`${t}-body:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.colorError}}},[`&${t}-status-success`]:{[`${t}-body:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.colorSuccess}}}},[`${t}-inline-circle`]:{lineHeight:1,[`${t}-inner`]:{verticalAlign:"bottom"}}}},$He=e=>{const{componentCls:t}=e;return{[t]:{[`${t}-steps`]:{display:"inline-block","&-body":{display:"flex",flexDirection:"row",alignItems:"center",gap:e.progressStepMarginInlineEnd,[`${t}-indicator`]:{marginInlineStart:e.marginXS}},"&-item":{flexShrink:0,minWidth:e.progressStepMinWidth,backgroundColor:e.remainingColor,transition:`all ${e.motionDurationSlow}`,"&-active":{backgroundColor:e.defaultColor}}}}}},GHe=e=>{const{componentCls:t,iconCls:r}=e;return{[t]:{[`${t}-small&-line, ${t}-small&-line ${t}-indicator ${r}`]:{fontSize:e.fontSizeSM}}}},VHe=e=>({circleTextColor:e.colorText,defaultColor:e.colorInfo,remainingColor:e.colorFillSecondary,lineBorderRadius:100,circleTextFontSize:"1em",circleIconFontSize:`${e.fontSize/e.fontSizeSM}em`}),zHe=Wr("Progress",e=>{const t=e.calc(e.marginXXS).div(2).equal(),r=$r(e,{progressStepMarginInlineEnd:t,progressStepMinWidth:t,progressActiveMotionDuration:"2.4s"});return[kHe(r),NHe(r),BHe(r),$He(r),GHe(r)]},VHe),HHe=e=>{let t=[];return Object.keys(e).forEach(r=>{const n=Number.parseFloat(r.replace(/%/g,""));Number.isNaN(n)||t.push({key:n,value:e[r]})}),t=t.sort((r,n)=>r.key-n.key),t.map(({key:r,value:n})=>`${n} ${r}%`).join(", ")},WHe=(e,t)=>{const{from:r=Cy.blue,to:n=Cy.blue,direction:i=t==="rtl"?"to left":"to right",...o}=e;if(Object.keys(o).length!==0){const a=HHe(o),l=`linear-gradient(${i}, ${a})`;return{background:l,[sG]:l}}const s=`linear-gradient(${i}, ${r}, ${n})`;return{background:s,[sG]:s}},UHe=e=>{const{prefixCls:t,classNames:r,styles:n,direction:i,percent:o,size:s,strokeWidth:a,strokeColor:l,strokeLinecap:c="round",children:u,railColor:d,trailColor:h,percentPosition:p,success:f}=e,{align:g,type:m}=p,v=d??h,b=c==="square"||c==="butt"?0:void 0,S=s??[-1,a||(s==="small"?6:8)],[x,E]=oA(S,"line",{strokeWidth:a}),R={backgroundColor:v||void 0,borderRadius:b,height:E},T=`${t}-track`,M=l&&typeof l!="string"?WHe(l,i):{[sG]:l,background:l},D={width:`${kg(o)}%`,height:E,borderRadius:b,...M},A=IM(e),I={width:`${kg(A)}%`,height:E,borderRadius:b,backgroundColor:f==null?void 0:f.strokeColor};return y.createElement("div",{className:Q(`${t}-body`,r.body,{[`${t}-body-layout-bottom`]:g==="center"&&m==="outer"}),style:{width:x>0?x:"100%",...n.body}},y.createElement("div",{className:Q(`${t}-rail`,r.rail),style:{...R,...n.rail}},y.createElement("div",{className:Q(T,r.track),style:{...D,...n.track}},m==="inner"&&u),A!==void 0&&y.createElement("div",{className:Q(T,`${T}-success`,r.track),style:{...I,...n.track}})),m==="outer"&&u)},jHe=e=>{const{classNames:t,styles:r,size:n,steps:i,rounding:o=Math.round,percent:s=0,strokeWidth:a=8,strokeColor:l,railColor:c,trailColor:u,prefixCls:d,children:h}=e,p=o(i*(s/100)),g=n??[n==="small"?2:14,a],[m,v]=oA(g,"step",{steps:i,strokeWidth:a}),b=m/i,S=Array.from({length:i}),x=c??u;for(let E=0;E{const{prefixCls:r,className:n,rootClassName:i,classNames:o,styles:s,steps:a,strokeColor:l,percent:c=0,size:u="medium",showInfo:d=!0,type:h="line",status:p,format:f,style:g,percentPosition:m={},...v}=e,{align:b="end",type:S="outer"}=m,x=Array.isArray(l)?l[0]:l,E=typeof l=="string"||Array.isArray(l)?l:void 0,R=y.useMemo(()=>{if(x){const oe=typeof x=="string"?x:Object.values(x)[0];return new cn(oe).isLight()}return!1},[l]),T=y.useMemo(()=>{var ee,ne;const oe=IM(e);return Number.parseInt(oe!==void 0?(ee=oe??0)==null?void 0:ee.toString():(ne=c??0)==null?void 0:ne.toString(),10)},[c,e.success]),M=y.useMemo(()=>!KHe.includes(p)&&T>=100?"success":p||"normal",[p,T]),{getPrefixCls:D,direction:A,className:I,style:L,classNames:F,styles:k}=Nr("progress"),O=D("progress",r),[B,H]=zHe(O),N={...e,percent:c,type:h,size:u,showInfo:d,percentPosition:m},[z,W]=Vr([F,o],[k,s],{props:N}),V=h==="line",$=V&&!a,K=y.useMemo(()=>{if(!d)return null;const oe=IM(e);let ee;const ne=f||(he=>`${he}%`),le=V&&R&&S==="inner";return S==="inner"||f||M!=="exception"&&M!=="success"?ee=ne(kg(c),kg(oe)):M==="exception"?ee=V?y.createElement(Ax,null):y.createElement(Xd,null):M==="success"&&(ee=V?y.createElement(F3,null):y.createElement(s4,null)),y.createElement("span",{className:Q(`${O}-indicator`,{[`${O}-indicator-bright`]:le,[`${O}-indicator-${b}`]:$,[`${O}-indicator-${S}`]:$},z.indicator),style:W.indicator,title:typeof ee=="string"?ee:void 0},ee)},[d,c,T,M,h,O,f,V,R,S,b,$,z.indicator,W.indicator]),q={...e,classNames:z,styles:W};let X;h==="line"?X=a?y.createElement(jHe,{...q,strokeColor:E,prefixCls:O,steps:typeof a=="object"?a.count:a},K):y.createElement(UHe,{...q,strokeColor:x,prefixCls:O,direction:A,percentPosition:{align:b,type:S}},K):(h==="circle"||h==="dashboard")&&(X=y.createElement(_He,{...q,strokeColor:x,prefixCls:O,progressStatus:M},K));const Y=Q(O,`${O}-status-${M}`,{[`${O}-${h==="dashboard"&&"circle"||h}`]:h!=="line",[`${O}-inline-circle`]:h==="circle"&&oA(u,"circle")[0]<=20,[`${O}-line`]:$,[`${O}-line-align-${b}`]:$,[`${O}-line-position-${S}`]:$,[`${O}-steps`]:a,[`${O}-show-info`]:d,[`${O}-small`]:u==="small",[`${O}-rtl`]:A==="rtl"},I,n,i,z.root,B,H);return y.createElement("div",{ref:t,style:{...L,...W.root,...g},className:Y,role:"progressbar","aria-valuenow":T,"aria-valuemin":0,"aria-valuemax":100,...fn(v,["railColor","trailColor","strokeWidth","width","gapDegree","gapPosition","gapPlacement","strokeLinecap","success"])},X)});var XHe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M908.1 353.1l-253.9-36.9L540.7 86.1c-3.1-6.3-8.2-11.4-14.5-14.5-15.8-7.8-35-1.3-42.9 14.5L369.8 316.2l-253.9 36.9c-7 1-13.4 4.3-18.3 9.3a32.05 32.05 0 00.6 45.3l183.7 179.1-43.4 252.9a31.95 31.95 0 0046.4 33.7L512 754l227.1 119.4c6.2 3.3 13.4 4.4 20.3 3.2 17.4-3 29.1-19.5 26.1-36.9l-43.4-252.9 183.7-179.1c5-4.9 8.3-11.3 9.3-18.3 2.7-17.5-9.5-33.7-27-36.3z"}}]},name:"star",theme:"filled"};function aG(){return aG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,aG({},e,{ref:t,icon:XHe})),kBt=y.forwardRef(YHe);function lG(){return lG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const[g,m]=An(n??!1,r);function v(E,R){let T=g;return i||(T=E,m(T),c==null||c(T,R)),T}function b(E){E.which===Zt.LEFT?v(!1,E):E.which===Zt.RIGHT&&v(!0,E),u==null||u(E)}function S(E){const R=v(!g,E);l==null||l(R,E)}const x=Q(e,t,{[`${e}-checked`]:g,[`${e}-disabled`]:i});return y.createElement("button",lG({},p,{type:"button",role:"switch","aria-checked":g,disabled:i,className:x,ref:f,onKeyDown:b,onClick:S}),o,y.createElement("span",{className:`${e}-inner`},y.createElement("span",{className:Q(`${e}-inner-checked`,h==null?void 0:h.content),style:d==null?void 0:d.content},s),y.createElement("span",{className:Q(`${e}-inner-unchecked`,h==null?void 0:h.content),style:d==null?void 0:d.content},a)))});bde.displayName="Switch";const ZHe=e=>{const{componentCls:t,trackHeightSM:r,trackPadding:n,trackMinWidthSM:i,innerMinMarginSM:o,innerMaxMarginSM:s,handleSizeSM:a,calc:l}=e,c=`${t}-inner`,u=ae(l(a).add(l(n).mul(2)).equal()),d=ae(l(s).mul(2).equal());return{[t]:{[`&${t}-small`]:{minWidth:i,height:r,lineHeight:ae(r),[`${t}-inner`]:{paddingInlineStart:s,paddingInlineEnd:o,[`${c}-checked, ${c}-unchecked`]:{minHeight:r},[`${c}-checked`]:{marginInlineStart:`calc(-100% + ${u} - ${d})`,marginInlineEnd:`calc(100% - ${u} + ${d})`},[`${c}-unchecked`]:{marginTop:l(r).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`${t}-handle`]:{width:a,height:a},[`${t}-loading-icon`]:{top:l(l(a).sub(e.switchLoadingIconSize)).div(2).equal(),fontSize:e.switchLoadingIconSize},[`&${t}-checked`]:{[`${t}-inner`]:{paddingInlineStart:o,paddingInlineEnd:s,[`${c}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${c}-unchecked`]:{marginInlineStart:`calc(100% - ${u} + ${d})`,marginInlineEnd:`calc(-100% + ${u} - ${d})`}},[`${t}-handle`]:{insetInlineStart:`calc(100% - ${ae(l(a).add(n).equal())})`}},[`&:not(${t}-disabled):active`]:{[`&:not(${t}-checked) ${c}`]:{[`${c}-unchecked`]:{marginInlineStart:l(e.marginXXS).div(2).equal(),marginInlineEnd:l(e.marginXXS).mul(-1).div(2).equal()}},[`&${t}-checked ${c}`]:{[`${c}-checked`]:{marginInlineStart:l(e.marginXXS).mul(-1).div(2).equal(),marginInlineEnd:l(e.marginXXS).div(2).equal()}}}}}}},QHe=e=>{const{componentCls:t,handleSize:r,calc:n}=e;return{[t]:{[`${t}-loading-icon${e.iconCls}`]:{position:"relative",top:n(n(r).sub(e.fontSize)).div(2).equal(),color:e.switchLoadingIconColor,verticalAlign:"top"},[`&${t}-checked ${t}-loading-icon`]:{color:e.switchColor}}}},JHe=e=>{const{componentCls:t,trackPadding:r,handleBg:n,handleShadow:i,handleSize:o,calc:s}=e,a=`${t}-handle`;return{[t]:{[a]:{position:"absolute",top:r,insetInlineStart:r,width:o,height:o,transition:`all ${e.switchDuration} ease-in-out`,...bd(),"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:n,borderRadius:s(o).div(2).equal(),boxShadow:i,transition:`all ${e.switchDuration} ease-in-out`,content:'""',...bd()}},[`&${t}-checked ${a}`]:{insetInlineStart:`calc(100% - ${ae(s(o).add(r).equal())})`},[`&:not(${t}-disabled):active`]:{[`${a}::before`]:{insetInlineEnd:e.switchHandleActiveInset,insetInlineStart:0},[`&${t}-checked ${a}::before`]:{insetInlineEnd:0,insetInlineStart:e.switchHandleActiveInset}}}}},e3e=e=>{const{componentCls:t,trackHeight:r,trackPadding:n,innerMinMargin:i,innerMaxMargin:o,handleSize:s,switchDuration:a,calc:l}=e,c=`${t}-inner`,u=ae(l(s).add(l(n).mul(2)).equal()),d=ae(l(o).mul(2).equal());return{[t]:{[c]:{display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:o,paddingInlineEnd:i,transition:["padding-inline-start","padding-inline-end"].map(h=>`${h} ${a} ease-in-out`).join(", "),...bd(),[`${c}-checked, ${c}-unchecked`]:{display:"block",color:e.colorTextLightSolid,fontSize:e.fontSizeSM,pointerEvents:"none",minHeight:r,transition:["margin-inline-start","margin-inline-end"].map(h=>`${h} ${a} ease-in-out`).join(", "),...bd()},[`${c}-checked`]:{marginInlineStart:`calc(-100% + ${u} - ${d})`,marginInlineEnd:`calc(100% - ${u} + ${d})`},[`${c}-unchecked`]:{marginTop:l(r).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`&${t}-checked ${c}`]:{paddingInlineStart:i,paddingInlineEnd:o,[`${c}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${c}-unchecked`]:{marginInlineStart:`calc(100% - ${u} + ${d})`,marginInlineEnd:`calc(-100% + ${u} - ${d})`}},[`&:not(${t}-disabled):active`]:{[`&:not(${t}-checked) ${c}`]:{[`${c}-unchecked`]:{marginInlineStart:l(n).mul(2).equal(),marginInlineEnd:l(n).mul(-1).mul(2).equal()}},[`&${t}-checked ${c}`]:{[`${c}-checked`]:{marginInlineStart:l(n).mul(-1).mul(2).equal(),marginInlineEnd:l(n).mul(2).equal()}}}}}},t3e=e=>{const{componentCls:t,trackHeight:r,trackMinWidth:n}=e;return{[t]:{...on(e),position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:n,height:r,lineHeight:ae(r),verticalAlign:"middle",background:e.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:`all ${e.motionDurationMid}`,userSelect:"none",...bd(),[`&:hover:not(${t}-disabled)`]:{background:e.colorTextTertiary},...wl(e),[`&${t}-checked`]:{background:e.switchColor,[`&:hover:not(${t}-disabled)`]:{background:e.colorPrimaryHover}},[`&${t}-loading, &${t}-disabled`]:{cursor:"not-allowed",opacity:e.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}},[`&${t}-rtl`]:{direction:"rtl"}}}},r3e=e=>{const{fontSize:t,lineHeight:r,controlHeight:n,colorWhite:i}=e,o=t*r,s=n/2,a=2,l=o-a*2,c=s-a*2;return{trackHeight:o,trackHeightSM:s,trackMinWidth:l*2+a*4,trackMinWidthSM:c*2+a*2,trackPadding:a,handleBg:i,handleSize:l,handleSizeSM:c,handleShadow:`0 2px 4px 0 ${new cn("#00230b").setA(.2).toRgbString()}`,innerMinMargin:l/2,innerMaxMargin:l+a+a*2,innerMinMarginSM:c/2,innerMaxMarginSM:c+a+a*2}},n3e=Wr("Switch",e=>{const t=$r(e,{switchDuration:e.motionDurationMid,switchColor:e.colorPrimary,switchDisabledOpacity:e.opacityLoading,switchLoadingIconSize:e.calc(e.fontSizeIcon).mul(.75).equal(),switchLoadingIconColor:`rgba(0, 0, 0, ${e.opacityLoading})`,switchHandleActiveInset:"-30%"});return[t3e(t),e3e(t),JHe(t),QHe(t),ZHe(t)]},r3e),i3e=y.forwardRef((e,t)=>{const{prefixCls:r,size:n,disabled:i,loading:o,className:s,rootClassName:a,style:l,checked:c,value:u,defaultChecked:d,defaultValue:h,onChange:p,styles:f,classNames:g,...m}=e,[v,b]=An(d??h??!1,c??u),{getPrefixCls:S,direction:x,className:E,style:R,classNames:T,styles:M}=Nr("switch"),D=y.useContext(hs),A=(i??D)||o,I=S("switch",r),[L,F]=n3e(I),k=ki(n),O={...e,size:k,disabled:A},[B,H]=Vr([T,g],[M,f],{props:O}),N=y.createElement("div",{className:Q(`${I}-handle`,B.indicator),style:H.indicator},o&&y.createElement(rm,{className:`${I}-loading-icon`})),z=Q(E,{[`${I}-small`]:k==="small",[`${I}-loading`]:o,[`${I}-rtl`]:x==="rtl"},s,a,B.root,L,F),W={...H.root,...R,...l},V=(...$)=>{b($[0]),p==null||p(...$)};return y.createElement(kx,{component:"Switch",disabled:A},y.createElement(bde,{...m,classNames:B,styles:H,checked:v,onChange:V,prefixCls:I,className:z,style:W,disabled:A,ref:t,loadingIcon:N}))}),o3e=i3e;o3e.__ANT_SWITCH=!0;const Vh={},t1="rc-table-internal-hook";function F4(e){const t=y.createContext(void 0);return{Context:t,Provider:({value:n,children:i})=>{const o=y.useRef(n);o.current=n;const[s]=y.useState(()=>({getValue:()=>o.current,listeners:new Set}));return jr(()=>{$a.unstable_batchedUpdates(()=>{s.listeners.forEach(a=>{a(n)})})},[n]),y.createElement(t.Provider,{value:s},i)},defaultValue:e}}function lo(e,t){const r=br(typeof t=="function"?t:l=>{if(t===void 0)return l;if(!Array.isArray(t))return l[t];const c={};return t.forEach(u=>{c[u]=l[u]}),c}),n=y.useContext(e==null?void 0:e.Context),{listeners:i,getValue:o}=n||{},s=y.useRef();s.current=r(n?o():e==null?void 0:e.defaultValue);const[,a]=y.useState({});return jr(()=>{if(!n)return;function l(c){const u=r(c);fc(s.current,u,!0)||a({})}return i.add(l),()=>{i.delete(l)}},[n]),s.current}function Ow(){return Ow=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const u=s?{ref:c}:{},d=y.useRef(0),h=y.useRef(l);return t()!==null?y.createElement(i,Ow({},l,u)):((!o||o(h.current,l))&&(d.current+=1),h.current=l,y.createElement(e.Provider,{value:d.current},y.createElement(i,Ow({},l,u))))};return s?y.forwardRef(a):a}function n(i,o){const s=pu(i),a=(l,c)=>{const u=s?{ref:c}:{};return t(),y.createElement(i,Ow({},l,u))};return y.memo(s?y.forwardRef(a):a,o)}return{makeImmutable:r,responseImmutable:n,useImmutableMark:t}}const{makeImmutable:Sde,responseImmutable:NC,useImmutableMark:a3e}=s3e(),$o=F4(),wde=y.createContext({renderWithProps:!1}),l3e="RC_TABLE_KEY";function c3e(e){return e==null?[]:Array.isArray(e)?e:[e]}function sA(e){const t=[],r={};return e.forEach(n=>{const{key:i,dataIndex:o}=n||{};let s=i||c3e(o).join("-")||l3e;for(;r[s];)s=`${s}_next`;r[s]=!0,t.push(s)}),t}function cG(e){return e!=null}function u3e(e){return typeof e=="number"&&!Number.isNaN(e)}function d3e(e){return e&&typeof e=="object"&&!Array.isArray(e)&&!y.isValidElement(e)}function h3e(e,t,r,n,i,o){const s=y.useContext(wde),a=a3e();return Pm(()=>{if(cG(n))return[n];const c=t==null||t===""?[]:Array.isArray(t)?t:[t],u=Zs(e,c);let d=u,h;if(i){const p=i(u,e,r);d3e(p)?(d=p.children,h=p.props,s.renderWithProps=!0):d=p}return[d,h]},[a,e,n,t,i,r],(c,u)=>{if(o){const[,d]=c,[,h]=u;return o(h,d)}return s.renderWithProps?!0:!fc(c,u,!0)})}function p3e(e,t,r,n){const i=e+t-1;return e<=n&&i>=r}function f3e(e,t){return lo($o,r=>[p3e(e,t||1,r.hoverStartRow,r.hoverEndRow),r.onHover])}function uG(){return uG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var o,s;let n;const i=e===!0?{showTitle:!0}:e;return i&&(i.showTitle||t==="header")&&(typeof r=="string"||typeof r=="number"?n=r.toString():y.isValidElement(r)&&typeof((o=r.props)==null?void 0:o.children)=="string"&&(n=(s=r.props)==null?void 0:s.children)),n},m3e=e=>{const{component:t,children:r,ellipsis:n,scope:i,prefixCls:o,className:s,style:a,align:l,record:c,render:u,dataIndex:d,renderIndex:h,shouldCellUpdate:p,index:f,rowType:g,colSpan:m,rowSpan:v,fixStart:b,fixEnd:S,fixedStartShadow:x,fixedEndShadow:E,offsetFixedStartShadow:R,offsetFixedEndShadow:T,zIndex:M,zIndexReverse:D,appendNode:A,additionalProps:I={},isSticky:L}=e,F=`${o}-cell`,{allColumnsFixedLeft:k,rowHoverable:O}=lo($o,["allColumnsFixedLeft","rowHoverable"]),[B,H]=h3e(c,d,h,r,u,p),N={},z=typeof b=="number"&&!k,W=typeof S=="number"&&!k,[V,$]=lo($o,({scrollInfo:de})=>{if(!z&&!W)return[!1,!1];const[J,ue]=de,ve=(z&&x&&J)-R>=1,pe=(W&&E&&ue-J)-T>1;return[ve,pe]});z&&(N.insetInlineStart=b,N["--z-offset"]=M,N["--z-offset-reverse"]=D),W&&(N.insetInlineEnd=S,N["--z-offset"]=M,N["--z-offset-reverse"]=D);const K=(H==null?void 0:H.colSpan)??I.colSpan??m??1,q=(H==null?void 0:H.rowSpan)??I.rowSpan??v??1,[X,Y]=f3e(f,q),oe=br(de=>{var J;c&&Y(f,f+q-1),(J=I==null?void 0:I.onMouseEnter)==null||J.call(I,de)}),ee=br(de=>{var J;c&&Y(-1,-1),(J=I==null?void 0:I.onMouseLeave)==null||J.call(I,de)});if(K===0||q===0)return null;const ne=I.title??g3e({rowType:g,ellipsis:n,children:B}),le=Q(F,s,{[`${F}-fix`]:z||W,[`${F}-fix-start`]:z,[`${F}-fix-end`]:W,[`${F}-fix-start-shadow`]:x,[`${F}-fix-start-shadow-show`]:x&&V,[`${F}-fix-end-shadow`]:E,[`${F}-fix-end-shadow-show`]:E&&$,[`${F}-ellipsis`]:n,[`${F}-with-append`]:A,[`${F}-fix-sticky`]:(z||W)&&L,[`${F}-row-hover`]:!H&&X},I.className,H==null?void 0:H.className),he={};l&&(he.textAlign=l);const re={...H==null?void 0:H.style,...N,...he,...I.style,...a};let ie=B;return typeof ie=="object"&&!Array.isArray(ie)&&!y.isValidElement(ie)&&(ie=null),n&&(x||E)&&(ie=y.createElement("span",{className:`${F}-content`},ie)),y.createElement(t,uG({},H,I,{className:le,style:re,title:ne,scope:i,onMouseEnter:O?oe:void 0,onMouseLeave:O?ee:void 0,colSpan:K!==1?K:null,rowSpan:q!==1?q:null}),A,ie)},BC=y.memo(m3e);function dT(e){return e.fixed==="start"}function hT(e){return e.fixed==="end"}function L4(e,t,r,n){const i=r[e]||{},o=r[t]||{};let s=null,a=null;dT(i)&&dT(o)?s=n.start[e]:hT(o)&&hT(i)&&(a=n.end[t]);let l=!1,c=!1,u=0,d=0;s!==null&&(l=!r[t+1]||!dT(r[t+1]),u=r.length*2-e,d=r.length+e),a!==null&&(c=!r[e-1]||!hT(r[e-1]),u=t,d=r.length-t);let h=0,p=0;if(l)for(let f=0;ft;f-=1)hT(r[f])||(p+=n.widths[f]||0);return{fixStart:s,fixEnd:a,fixedStartShadow:l,fixedEndShadow:c,offsetFixedStartShadow:h,offsetFixedEndShadow:p,isSticky:n.isSticky,zIndex:u,zIndexReverse:d}}const xde=y.createContext({});function dG(){return dG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{className:t,index:r,children:n,colSpan:i=1,rowSpan:o,align:s}=e,{prefixCls:a}=lo($o,["prefixCls"]),{scrollColumnIndex:l,stickyOffsets:c,flattenColumns:u}=y.useContext(xde),h=r+i-1+1===l?i+1:i,p=y.useMemo(()=>L4(r,r+h-1,u,c),[r,h,u,c]);return y.createElement(BC,dG({className:t,index:r,component:"td",prefixCls:a,record:null,dataIndex:null,align:s,colSpan:h,rowSpan:o,render:()=>n},p))},y3e=e=>{const{children:t,...r}=e;return y.createElement("tr",r,t)},aA=e=>{const{children:t}=e;return t};aA.Row=y3e;aA.Cell=v3e;const C3e=e=>{const{children:t,stickyOffsets:r,flattenColumns:n}=e,i=lo($o,"prefixCls"),o=n.length-1,s=n[o],a=y.useMemo(()=>({stickyOffsets:r,flattenColumns:n,scrollColumnIndex:s!=null&&s.scrollbar?o:null}),[s,n,o,r]);return y.createElement(xde.Provider,{value:a},y.createElement("tfoot",{className:`${i}-summary`},t))},pT=NC(C3e),Ede=aA;function b3e(e){return null}function S3e(e){return null}function Tde(e,t,r,n,i,o,s){const a=o(t,s);e.push({record:t,indent:r,index:s,rowKey:a});const l=i==null?void 0:i.has(a);if(t&&Array.isArray(t[n])&&l)for(let c=0;c{if(r!=null&&r.size){const o=[];for(let s=0;s<(e==null?void 0:e.length);s+=1){const a=e[s];Tde(o,a,0,t,r,n,s)}return o}return e==null?void 0:e.map((o,s)=>({record:o,indent:0,index:s,rowKey:n(o,s)}))},[e,t,r,n])}function Pde(e,t,r,n){const i=lo($o,["prefixCls","fixedInfoList","flattenColumns","expandableType","expandRowByClick","onTriggerExpand","rowClassName","expandedRowClassName","indentSize","expandIcon","expandedRowRender","expandIconColumnIndex","expandedKeys","childrenColumnName","rowExpandable","onRow"]),{flattenColumns:o,expandableType:s,expandedKeys:a,childrenColumnName:l,onTriggerExpand:c,rowExpandable:u,onRow:d,expandRowByClick:h,rowClassName:p}=i,f=s==="nest",g=s==="row"&&(!u||u(e)),m=g||f,v=a&&a.has(t),b=l&&e&&e[l],S=br(c),x=d==null?void 0:d(e,r),E=x==null?void 0:x.onClick,R=(D,...A)=>{h&&m&&c(e,D),E==null||E(D,...A)};let T;typeof p=="string"?T=p:typeof p=="function"&&(T=p(e,r,n));const M=sA(o);return{...i,columnsKey:M,nestExpandable:f,expanded:v,hasNestChildren:b,record:e,onTriggerExpand:S,rowSupportExpand:g,expandable:m,rowProps:{...x,className:Q(T,x==null?void 0:x.className),onClick:R}}}const Mde=e=>{const{prefixCls:t,children:r,component:n,cellComponent:i,className:o,expanded:s,colSpan:a,isEmpty:l,stickyOffset:c=0}=e,{scrollbarSize:u,fixHeader:d,fixColumn:h,componentWidth:p,horizonScroll:f}=lo($o,["scrollbarSize","fixHeader","fixColumn","componentWidth","horizonScroll"]);let g=r;return(l?f&&p:h)&&(g=y.createElement("div",{style:{width:p-c-(d&&!l?u:0),position:"sticky",left:c,overflow:"hidden"},className:`${t}-expanded-row-fixed`},g)),y.createElement(n,{className:o,style:{display:s?null:"none"}},y.createElement(BC,{component:i,prefixCls:t,colSpan:a},g))};function w3e({prefixCls:e,record:t,onExpand:r,expanded:n,expandable:i}){const o=`${e}-row-expand-icon`;if(!i)return y.createElement("span",{className:Q(o,`${e}-row-spaced`)});const s=a=>{r(t,a),a.stopPropagation()};return y.createElement("span",{className:Q(o,{[`${e}-row-expanded`]:n,[`${e}-row-collapsed`]:!n}),onClick:s})}function x3e(e,t,r){const n=[];function i(o){(o||[]).forEach((s,a)=>{n.push(t(s,a)),i(s[r])})}return i(e),n}function Ide(e,t,r,n){return typeof e=="string"?e:typeof e=="function"?e(t,r,n):""}function DM(){return DM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{className:t,style:r,classNames:n,styles:i,record:o,index:s,renderIndex:a,rowKey:l,rowKeys:c,indent:u=0,rowComponent:d,cellComponent:h,scopeCellComponent:p,expandedRowInfo:f}=e,g=Pde(o,l,s,u),{prefixCls:m,flattenColumns:v,expandedRowClassName:b,expandedRowRender:S,rowProps:x,expanded:E,rowSupportExpand:R}=g,T=y.useRef(!1);T.current||(T.current=E);const M=Ide(b,o,s,u),D=y.createElement(d,DM({},x,{"data-row-key":l,className:Q(t,`${m}-row`,`${m}-row-level-${u}`,x==null?void 0:x.className,n.row,{[M]:u>=1}),style:{...r,...x==null?void 0:x.style,...i.row}}),v.map((I,L)=>{const{render:F,dataIndex:k,className:O}=I,{key:B,fixedInfo:H,appendCellNode:N,additionalCellProps:z}=Dde(g,I,L,u,s,c,f==null?void 0:f.offset);return y.createElement(BC,DM({className:Q(O,n.cell),style:i.cell,ellipsis:I.ellipsis,align:I.align,scope:I.rowScope,component:I.rowScope?p:h,prefixCls:m,key:B,record:o,index:s,renderIndex:a,dataIndex:k,render:F,shouldCellUpdate:I.shouldCellUpdate},H,{appendNode:N,additionalProps:z}))}));let A;if(R&&(T.current||E)){const I=S(o,s,u+1,E);A=y.createElement(Mde,{expanded:E,className:Q(`${m}-expanded-row`,`${m}-expanded-row-level-${u+1}`,M),prefixCls:m,component:d,cellComponent:h,colSpan:f?f.colSpan:v.length,isEmpty:!1,stickyOffset:f==null?void 0:f.sticky},I)}return y.createElement(y.Fragment,null,D,A)},T3e=NC(E3e),R3e=e=>{const{columnKey:t,onColumnResize:r,title:n}=e,i=y.useRef(null);return jr(()=>{i.current&&r(t,i.current.offsetWidth)},[]),y.createElement(ta,{data:t},y.createElement("td",{ref:i,style:{paddingTop:0,paddingBottom:0,borderTop:0,borderBottom:0,height:0}},y.createElement("div",{style:{height:0,overflow:"hidden",fontWeight:"bold"}},n||" ")))},P3e=({prefixCls:e,columnsKey:t,onColumnResize:r,columns:n})=>{const i=y.useRef(null),{measureRowRender:o}=lo($o,["measureRowRender"]),s=y.createElement("tr",{"aria-hidden":"true",className:`${e}-measure-row`,style:{height:0},ref:i},y.createElement(ta.Collection,{onBatchResize:a=>{VD(i.current)&&a.forEach(({data:l,size:c})=>{r(l,c.offsetWidth)})}},t.map(a=>{const l=n.find(d=>d.key===a),c=l==null?void 0:l.title,u=y.isValidElement(c)?y.cloneElement(c,{ref:null}):c;return y.createElement(R3e,{key:a,columnKey:a,onColumnResize:r,title:u})})));return typeof o=="function"?o(s):s},M3e=e=>{const{data:t,measureColumnWidth:r}=e,{prefixCls:n,getComponent:i,onColumnResize:o,flattenColumns:s,getRowKey:a,expandedKeys:l,childrenColumnName:c,emptyNode:u,classNames:d,styles:h,expandedRowOffset:p=0,colWidths:f}=lo($o,["prefixCls","getComponent","onColumnResize","flattenColumns","getRowKey","expandedKeys","childrenColumnName","emptyNode","classNames","styles","expandedRowOffset","fixedInfoList","colWidths"]),{body:g={}}=d||{},{body:m={}}=h||{},v=Rde(t,c,l,a),b=y.useMemo(()=>v.map(I=>I.rowKey),[v]),S=y.useRef({renderWithProps:!1}),x=y.useMemo(()=>{const I=s.length-p;let L=0;for(let F=0;F{const{record:F,indent:k,index:O,rowKey:B}=I;return y.createElement(T3e,{classNames:g,styles:m,key:B,rowKey:B,rowKeys:b,record:F,index:L,renderIndex:O,rowComponent:R,cellComponent:T,scopeCellComponent:M,indent:k,expandedRowInfo:x})}):D=y.createElement(Mde,{expanded:!0,className:`${n}-placeholder`,prefixCls:n,component:R,cellComponent:T,colSpan:s.length,isEmpty:!0},u);const A=sA(s);return y.createElement(wde.Provider,{value:S.current},y.createElement(E,{style:m.wrapper,className:Q(`${n}-tbody`,g.wrapper)},r&&y.createElement(P3e,{prefixCls:n,columnsKey:A,onColumnResize:o,columns:s}),D))},I3e=NC(M3e),kw="RC_TABLE_INTERNAL_COL_DEFINE";function D3e(e){const{expandable:t,...r}=e;let n;return"expandable"in e?n={...r,...t}:n=r,n.showExpandColumn===!1&&(n.expandIconColumnIndex=-1),n}function hG(){return hG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{colWidths:t,columns:r,columCount:n}=e,{tableLayout:i}=lo($o,["tableLayout"]),o=[],s=n||r.length;let a=!1;for(let l=s-1;l>=0;l-=1){const c=t[l],u=r&&r[l];let d,h;if(u&&(d=u[kw],i==="auto"&&(h=u.minWidth)),c||h||d||a){const{columnType:p,...f}=d||{};o.unshift(y.createElement("col",hG({key:l,style:{width:c,minWidth:h}},f))),a=!0}}return o.length>0?y.createElement("colgroup",null,o):null};function A3e(e,t){return y.useMemo(()=>{const r=[];for(let n=0;n{const{className:r,style:n,noData:i,columns:o,flattenColumns:s,colWidths:a,colGroup:l,columCount:c,stickyOffsets:u,direction:d,fixHeader:h,stickyTopOffset:p,stickyBottomOffset:f,stickyClassName:g,scrollX:m,tableLayout:v="fixed",onScroll:b,maxContentScroll:S,children:x,...E}=e,{prefixCls:R,scrollbarSize:T,isSticky:M,getComponent:D}=lo($o,["prefixCls","scrollbarSize","isSticky","getComponent"]),A=D(["header","table"],"table"),I=M&&!h?0:T,L=y.useRef(null),F=y.useCallback(V=>{rB(t,V),rB(L,V)},[]);y.useEffect(()=>{function V(K){const{currentTarget:q,deltaX:X}=K;if(X){const{scrollLeft:Y,scrollWidth:oe,clientWidth:ee}=q,ne=oe-ee;let le=Y+X;d==="rtl"?(le=Math.max(-ne,le),le=Math.min(0,le)):(le=Math.min(ne,le),le=Math.max(0,le)),b({currentTarget:q,scrollLeft:le}),K.preventDefault()}}const $=L.current;return $==null||$.addEventListener("wheel",V,{passive:!1}),()=>{$==null||$.removeEventListener("wheel",V)}},[]);const k=s[s.length-1],O={fixed:k?k.fixed:null,scrollbar:!0,onHeaderCell:()=>({className:`${R}-cell-scrollbar`})},B=y.useMemo(()=>I?[...o,O]:o,[I,o]),H=y.useMemo(()=>I?[...s,O]:s,[I,s]),N=y.useMemo(()=>{const{start:V,end:$}=u;return{...u,start:V,end:[...$.map(K=>K+I),0],isSticky:M}},[I,u,M]),z=A3e(a,c),W=y.useMemo(()=>{const V=!z||!z.length||z.every($=>!$);return i||V},[i,z]);return y.createElement("div",{style:{overflow:"hidden",...M?{top:p,bottom:f}:{},...n},ref:F,className:Q(r,{[g]:!!g})},y.createElement(A,{style:{tableLayout:v,minWidth:"100%",width:m}},W?l:y.createElement(Ade,{colWidths:[...z,I],columCount:c+1,columns:H}),x({...E,stickyOffsets:N,columns:B,flattenColumns:H})))}),CX=y.memo(F3e);function AM(){return AM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{cells:t,stickyOffsets:r,flattenColumns:n,rowComponent:i,cellComponent:o,onHeaderRow:s,index:a,classNames:l,styles:c}=e,{prefixCls:u}=lo($o,["prefixCls"]);let d;s&&(d=s(t.map(p=>p.column),a));const h=sA(t.map(p=>p.column));return y.createElement(i,AM({},d,{className:l.row,style:c.row}),t.map((p,f)=>{var E;const{column:g,colStart:m,colEnd:v,colSpan:b}=p,S=L4(m,v,n,r),x=((E=g==null?void 0:g.onHeaderCell)==null?void 0:E.call(g,g))||{};return y.createElement(BC,AM({},p,{scope:g.title?b>1?"colgroup":"col":null,ellipsis:g.ellipsis,align:g.align,component:o,prefixCls:u,key:h[f]},S,{additionalProps:x,rowType:"header"}))}))};function _3e(e,t,r){const n=[];function i(s,a,l=0){n[l]=n[l]||[];let c=a;return s.filter(Boolean).map(d=>{const h={key:d.key,className:Q(d.className,t.cell)||"",style:r.cell,children:d.title,column:d,colStart:c};let p=1;const f=d.children;return f&&f.length>0&&(p=i(f,c,l+1).reduce((g,m)=>g+m,0),h.hasSubColumns=!0),"colSpan"in d&&({colSpan:p}=d),"rowSpan"in d&&(h.rowSpan=d.rowSpan),h.colSpan=p,h.colEnd=h.colStart+p-1,n[l].push(h),c+=p,p})}i(e,0);const o=n.length;for(let s=0;s{!("rowSpan"in a)&&!a.hasSubColumns&&(a.rowSpan=o-s)});return n}const O3e=e=>{const{stickyOffsets:t,columns:r,flattenColumns:n,onHeaderRow:i}=e,{prefixCls:o,getComponent:s,classNames:a,styles:l}=lo($o,["prefixCls","getComponent","classNames","styles"]),{header:c={}}=a||{},{header:u={}}=l||{},d=y.useMemo(()=>_3e(r,c,u),[r,c,u]),h=s(["header","wrapper"],"thead"),p=s(["header","row"],"tr"),f=s(["header","cell"],"th");return y.createElement(h,{className:Q(`${o}-thead`,c.wrapper),style:u.wrapper},d.map((g,m)=>y.createElement(L3e,{classNames:c,styles:u,key:m,flattenColumns:n,cells:g,stickyOffsets:t,rowComponent:p,cellComponent:f,onHeaderRow:i,index:m})))},bX=NC(O3e);function SX(e,t=""){return typeof t=="number"?t:t.endsWith("%")?e*parseFloat(t)/100:null}function k3e(e,t,r){return y.useMemo(()=>{if(t&&t>0){let n=0,i=0;e.forEach(d=>{const h=SX(t,d.width);h?n+=h:i+=1});const o=Math.max(t,r);let s=Math.max(o-n,i),a=i;const l=s/i;let c=0;const u=e.map(d=>{const h={...d},p=SX(t,h.width);if(p)h.width=p;else{const f=Math.floor(l);h.width=a===1?s:f,s-=f,a-=1}return c+=h.width,h});if(c{const f=Math.floor(h.width*d);h.width=p===u.length-1?s:f,s-=f})}return[u,Math.max(c,o)]}return[e,t]},[e,t,r])}function _4(e){return Li(e).filter(t=>y.isValidElement(t)).map(t=>{const{key:r,props:n}=t,{children:i,...o}=n,s={key:r,...o};return i&&(s.children=_4(i)),s})}function Fde(e){return e.filter(t=>t&&typeof t=="object"&&!t.hidden).map(t=>{const r=t.children;return r&&r.length>0?{...t,children:Fde(r)}:t})}function Lde(e,t="key"){return e.filter(r=>r&&typeof r=="object").reduce((r,n,i)=>{const{fixed:o}=n,s=o===!0||o==="left"?"start":o==="right"?"end":o,a=`${t}-${i}`,l=n.children;return l&&l.length>0?[...r,...Lde(l,a).map(c=>({...c,fixed:c.fixed??s}))]:[...r,{key:a,...n,fixed:s}]},[])}function N3e({prefixCls:e,columns:t,children:r,expandable:n,expandedKeys:i,columnTitle:o,getRowKey:s,onTriggerExpand:a,expandIcon:l,rowExpandable:c,expandIconColumnIndex:u,expandedRowOffset:d=0,direction:h,expandRowByClick:p,columnWidth:f,fixed:g,scrollWidth:m,clientWidth:v},b){const S=y.useMemo(()=>{const D=t||_4(r)||[];return Fde(D.slice())},[t,r]),x=y.useMemo(()=>{if(n){let D=S.slice();if(!D.includes(Vh)){const k=u||0,O=k===0&&(g==="right"||g==="end")?S.length:k;O>=0&&D.splice(O,0,Vh)}const A=D.indexOf(Vh);D=D.filter((k,O)=>k!==Vh||O===A);const I=S[A];let L;g?L=g:L=I?I.fixed:null;const F={[kw]:{className:`${e}-expand-icon-col`,columnType:"EXPAND_COLUMN"},title:o,fixed:L,className:`${e}-row-expand-icon-cell`,width:f,render:(k,O,B)=>{const H=s(O,B),N=i.has(H),z=c?c(O):!0,W=l({prefixCls:e,expanded:N,expandable:z,record:O,onExpand:a});return p?y.createElement("span",{onClick:V=>V.stopPropagation()},W):W}};return D.map((k,O)=>{const B=k===Vh?F:k;return OD!==Vh)},[n,S,s,i,l,h,d]),E=y.useMemo(()=>{let D=x;return b&&(D=b(D)),D.length||(D=[{render:()=>null}]),D},[b,x,h]),R=y.useMemo(()=>Lde(E),[E,h,m]),[T,M]=k3e(R,m,v);return[E,T,M]}function B3e(e,t,r){const n=D3e(e),{expandIcon:i,expandedRowKeys:o,defaultExpandedRowKeys:s,defaultExpandAllRows:a,expandedRowRender:l,onExpand:c,onExpandedRowsChange:u,childrenColumnName:d}=n,h=i||w3e,p=d||"children",f=y.useMemo(()=>l?"row":e.expandable&&e.internalHooks===t1&&e.expandable.__PARENT_RENDER_ICON__||t.some(S=>S&&typeof S=="object"&&S[p])?"nest":!1,[!!l,t]),[g,m]=y.useState(()=>s||(a?x3e(t,r,p):[])),v=y.useMemo(()=>new Set(o||g||[]),[o,g]),b=y.useCallback(S=>{const x=r(S,t.indexOf(S));let E;const R=v.has(x);R?(v.delete(x),E=[...v]):E=[...v,x],m(E),c&&c(!R,S),u&&u(E)},[r,v,t,c,u]);return[n,f,v,h,p,b]}function $3e(e,t){const r=y.useMemo(()=>e.map((n,i)=>L4(i,i,e,t)),[e,t]);return Pm(()=>r,[r],(n,i)=>!fc(n,i))}function G3e(e){const t=y.useRef(e),[,r]=y.useState({}),n=y.useRef(null),i=y.useRef([]);function o(s){i.current.push(s);const a=Promise.resolve();n.current=a,a.then(()=>{if(n.current===a){const l=i.current,c=t.current;i.current=[],l.forEach(u=>{t.current=u(t.current)}),n.current=null,c!==t.current&&r({})}})}return y.useEffect(()=>()=>{n.current=null},[]),[t.current,o]}function V3e(e){const t=y.useRef(null),r=y.useRef(null);function n(){clearTimeout(r.current)}function i(s){t.current=s,n(),r.current=setTimeout(()=>{t.current=null,r.current=void 0},100)}function o(){return t.current}return y.useEffect(()=>n,[]),[i,o]}function z3e(){const[e,t]=y.useState(-1),[r,n]=y.useState(-1),i=y.useCallback((o,s)=>{t(o),n(s)},[]);return[e,r,i]}const wX=To()?window:null;function H3e(e,t){const{offsetHeader:r=0,offsetSummary:n=0,offsetScroll:i=0,getContainer:o=()=>wX}=typeof e=="object"?e:{},s=o()||wX,a=!!e;return y.useMemo(()=>({isSticky:a,stickyClassName:a?`${t}-sticky-holder`:"",offsetHeader:r,offsetSummary:n,offsetScroll:i,container:s}),[a,i,r,n,t,s])}function W3e(e,t){return y.useMemo(()=>{const n=t.length,i=(a,l,c)=>{const u=[];let d=0;for(let h=a;h!==l;h+=c)u.push(d),t[h].fixed&&(d+=e[h]||0);return u},o=i(0,n,1),s=i(n-1,-1,-1).reverse();return{start:o,end:s,widths:e}},[e,t])}const xX=e=>{const{children:t,className:r,style:n}=e;return y.createElement("div",{className:r,style:n},t)};function EX(e){const r=pc(e).getBoundingClientRect(),n=document.documentElement;return{left:r.left+(window.pageXOffset||n.scrollLeft)-(n.clientLeft||document.body.clientLeft||0),top:r.top+(window.pageYOffset||n.scrollTop)-(n.clientTop||document.body.clientTop||0)}}const TX="mouseup",RX="mousemove",xv="scroll",PX="resize",U3e=(e,t)=>{var T,M;const{scrollBodyRef:r,onScroll:n,offsetScroll:i,container:o,direction:s}=e,a=lo($o,"prefixCls"),l=((T=r.current)==null?void 0:T.scrollWidth)||0,c=((M=r.current)==null?void 0:M.clientWidth)||0,u=l&&c*(c/l),d=y.useRef(null),[h,p]=G3e({scrollLeft:0,isHiddenScrollBar:!0}),f=y.useRef({delta:0,x:0}),[g,m]=y.useState(!1),v=y.useRef(null);y.useEffect(()=>()=>{Or.cancel(v.current)},[]);const b=()=>{m(!1)},S=D=>{D.persist(),f.current.delta=D.pageX-h.scrollLeft,f.current.x=0,m(!0),D.preventDefault()},x=D=>{const{buttons:A}=D||(window==null?void 0:window.event);if(!g||A===0){g&&m(!1);return}let I=f.current.x+D.pageX-f.current.x-f.current.delta;const L=s==="rtl";I=Math.max(L?u-c:0,Math.min(L?0:c-u,I)),(!L||Math.abs(I)+Math.abs(u){Or.cancel(v.current),v.current=Or(()=>{if(!r.current)return;const D=EX(r.current).top,A=D+r.current.offsetHeight,I=o===window?document.documentElement.scrollTop+window.innerHeight:EX(o).top+o.clientHeight;A-fK()<=I||D>=I-i?p(L=>({...L,isHiddenScrollBar:!0})):p(L=>({...L,isHiddenScrollBar:!1}))})},R=D=>{p(A=>({...A,scrollLeft:D/l*c||0}))};return y.useImperativeHandle(t,()=>({setScrollLeft:R,checkScrollBarVisible:E})),y.useEffect(()=>(document.body.addEventListener(TX,b,!1),document.body.addEventListener(RX,x,!1),E(),()=>{document.body.removeEventListener(TX,b),document.body.removeEventListener(RX,x)}),[u,g]),y.useEffect(()=>{if(r.current){const D=[];let A=pc(r.current);for(;A;)D.push(A),A=A.parentElement;return D.forEach(I=>{I.addEventListener(xv,E,!1)}),window.addEventListener(PX,E,!1),window.addEventListener(xv,E,!1),o.addEventListener(xv,E,!1),()=>{D.forEach(I=>{I.removeEventListener(xv,E)}),window.removeEventListener(PX,E),window.removeEventListener(xv,E),o.removeEventListener(xv,E)}}},[o]),y.useEffect(()=>{h.isHiddenScrollBar||p(D=>{const A=r.current;return A?{...D,scrollLeft:A.scrollLeft/A.scrollWidth*A.clientWidth}:D})},[h.isHiddenScrollBar]),l<=c||!u||h.isHiddenScrollBar?null:y.createElement("div",{style:{height:fK(),width:c,bottom:i},className:`${a}-sticky-scroll`},y.createElement("div",{onMouseDown:S,ref:d,className:Q(`${a}-sticky-scroll-bar`,{[`${a}-sticky-scroll-bar-active`]:g}),style:{width:`${u}px`,transform:`translate3d(${h.scrollLeft}px, 0, 0)`}}))},j3e=y.forwardRef(U3e);function zh(){return zh=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var ti,mr;const r={rowKey:"key",prefixCls:_de,emptyText:X3e,...e},{prefixCls:n,className:i,rowClassName:o,style:s,classNames:a,styles:l,data:c,rowKey:u,scroll:d,tableLayout:h,direction:p,title:f,footer:g,summary:m,caption:v,id:b,showHeader:S,components:x,emptyText:E,onRow:R,onHeaderRow:T,measureRowRender:M,onScroll:D,internalHooks:A,transformColumns:I,internalRefs:L,tailor:F,getContainerWidth:k,sticky:O,rowHoverable:B=!0}=r,H=c||K3e,N=!!H.length,z=A===t1,W=y.useCallback((Ct,vr)=>Zs(x,Ct)||vr,[x]),V=y.useMemo(()=>typeof u=="function"?u:Ct=>Ct&&Ct[u],[u]),$=W(["body"]),[K,q,X]=z3e(),[Y,oe,ee,ne,le,he]=B3e(r,H,V),re=d==null?void 0:d.x,[ie,de]=y.useState(0),[J,ue,ve]=N3e({...r,...Y,expandable:!!Y.expandedRowRender,columnTitle:Y.columnTitle,expandedKeys:ee,getRowKey:V,onTriggerExpand:he,expandIcon:ne,expandIconColumnIndex:Y.expandIconColumnIndex,direction:p,scrollWidth:z&&F&&typeof re=="number"?re:null,clientWidth:ie},z?I:null),pe=ve??re,me=y.useMemo(()=>({columns:J,flattenColumns:ue}),[J,ue]),ke=y.useRef(null),De=y.useRef(null),Ee=y.useRef(null),We=y.useRef(null);y.useImperativeHandle(t,()=>({nativeElement:ke.current,scrollTo:Ct=>{var vr,wn;if(Ee.current instanceof HTMLElement){const{index:ri,top:Ni,key:Ha,offset:Uo}=Ct;if(u3e(Ni))(vr=Ee.current)==null||vr.scrollTo({top:Ni});else{const ks=Ha??V(H[ri]),fa=Ee.current.querySelector(`[data-row-key="${ks}"]`);if(fa)if(!Uo)fa.scrollIntoView();else{const Bt=fa.offsetTop;Ee.current.scrollTo({top:Bt+Uo})}}}else(wn=Ee.current)!=null&&wn.scrollTo&&Ee.current.scrollTo(Ct)}}));const ze=y.useRef(null),[mt,Nt]=y.useState(!1),[St,Ze]=y.useState(!1),[Fe,tt]=y.useState(new Map),rt=sA(ue).map(Ct=>Fe.get(Ct)),ot=y.useMemo(()=>rt,[rt.join("_")]),Ye=W3e(ot,ue),Ae=d&&cG(d.y),nt=d&&cG(pe)||!!Y.fixed,Et=nt&&ue.some(({fixed:Ct})=>Ct),Tt=y.useRef(null),{isSticky:kt,offsetHeader:Wt,offsetSummary:at,offsetScroll:lt,stickyClassName:Ut,container:cr}=H3e(O,n),_e=y.useMemo(()=>m==null?void 0:m(H),[m,H]),qe=(Ae||kt)&&y.isValidElement(_e)&&_e.type===aA&&_e.props.fixed;let Re,it,Ve;Ae&&(it={overflowY:N?"scroll":"auto",maxHeight:d.y}),nt&&(Re={overflowX:"auto"},Ae||(it={overflowY:"hidden"}),Ve={width:pe===!0?"auto":pe,minWidth:"100%"});const Oe=y.useCallback((Ct,vr)=>{tt(wn=>{if(wn.get(Ct)!==vr){const ri=new Map(wn);return ri.set(Ct,vr),ri}return wn})},[]),[se,ce]=V3e();function fe(Ct,vr){vr&&(typeof vr=="function"?vr(Ct):vr.scrollLeft!==Ct&&(vr.scrollLeft=Ct,vr.scrollLeft!==Ct&&setTimeout(()=>{vr.scrollLeft=Ct},0)))}const[Te,$e]=y.useState([0,0]),et=br(({currentTarget:Ct,scrollLeft:vr})=>{var Ha;const wn=typeof vr=="number"?vr:Ct.scrollLeft,ri=Ct||q3e;(!ce()||ce()===ri)&&(se(ri),fe(wn,De.current),fe(wn,Ee.current),fe(wn,ze.current),fe(wn,(Ha=Tt.current)==null?void 0:Ha.setScrollLeft));const Ni=Ct||De.current;if(Ni){const Uo=z&&F&&typeof pe=="number"?pe:Ni.scrollWidth,ks=Ni.clientWidth,fa=Math.abs(wn);if($e(Bt=>{const Ur=[fa,Uo-ks];return fc(Bt,Ur)?Bt:Ur}),Uo===ks){Nt(!1),Ze(!1);return}Nt(fa>0),Ze(fa{et(Ct),D==null||D(Ct)}),ct=()=>{var Ct;nt&&Ee.current?et({currentTarget:pc(Ee.current),scrollLeft:(Ct=Ee.current)==null?void 0:Ct.scrollLeft}):(Nt(!1),Ze(!1))},st=Ct=>{var wn,ri;(wn=Tt.current)==null||wn.checkScrollBarVisible();let vr=Ct??((ri=ke.current)==null?void 0:ri.offsetWidth)??0;z&&k&&ke.current&&(vr=k(ke.current,vr)||vr),vr!==ie&&(ct(),de(vr))};jr(()=>{nt&&st()},[nt]);const wt=y.useRef(!1);y.useEffect(()=>{wt.current&&ct()},[nt,c,J.length]),y.useEffect(()=>{wt.current=!0},[]);const[Mt,_t]=y.useState(0);jr(()=>{(!F||!z)&&(Ee.current instanceof Element?_t(UB(Ee.current).width):_t(UB(We.current).width))},[]),y.useEffect(()=>{z&&L&&(L.body.current=Ee.current)});const At=y.useCallback(Ct=>y.createElement(y.Fragment,null,y.createElement(bX,Ct),qe==="top"&&y.createElement(pT,Ct,_e)),[qe,_e]),pt=y.useCallback(Ct=>y.createElement(pT,Ct,_e),[_e]),yt=W(["table"],"table"),It=y.useMemo(()=>h||(Et?pe==="max-content"?"auto":"fixed":Ae||kt||ue.some(({ellipsis:Ct})=>Ct)?"fixed":"auto"),[Ae,Et,ue,h,kt]);let Qt;const Ft={colWidths:ot,columCount:ue.length,stickyOffsets:Ye,onHeaderRow:T,fixHeader:Ae,scroll:d},ur=y.useMemo(()=>N?null:typeof E=="function"?E():E,[N,E]),fr=y.createElement(I3e,{data:H,measureColumnWidth:Ae||nt||kt}),rr=y.createElement(Ade,{colWidths:ue.map(({width:Ct})=>Ct),columns:ue}),yn=v!=null?y.createElement("caption",{className:`${n}-caption`},v):void 0,dn=ai(r,{data:!0}),hn=ai(r,{aria:!0});if(Ae||kt){let Ct;typeof $=="function"?(Ct=$(H,{scrollbarSize:Mt,ref:Ee,onScroll:et}),Ft.colWidths=ue.map(({width:wn},ri)=>{const Ni=ri===ue.length-1?wn-Mt:wn;return typeof Ni=="number"&&!Number.isNaN(Ni)?Ni:0})):Ct=y.createElement("div",{style:{...Re,...it},onScroll:Dt,ref:Ee,className:`${n}-body`},y.createElement(yt,zh({style:{...Ve,tableLayout:It}},hn),yn,rr,fr,!qe&&_e&&y.createElement(pT,{stickyOffsets:Ye,flattenColumns:ue},_e)));const vr={noData:!H.length,maxContentScroll:nt&&pe==="max-content",...Ft,...me,direction:p,stickyClassName:Ut,scrollX:pe,tableLayout:It,onScroll:et};Qt=y.createElement(y.Fragment,null,S!==!1&&y.createElement(CX,zh({},vr,{stickyTopOffset:Wt,className:`${n}-header`,ref:De,colGroup:rr}),At),Ct,qe&&qe!=="top"&&y.createElement(CX,zh({},vr,{stickyBottomOffset:at,className:`${n}-summary`,ref:ze,colGroup:rr}),pt),kt&&Ee.current&&Ee.current instanceof Element&&y.createElement(j3e,{ref:Tt,offsetScroll:lt,scrollBodyRef:Ee,onScroll:et,container:cr,direction:p}))}else Qt=y.createElement("div",{style:{...Re,...it,...l==null?void 0:l.content},className:Q(`${n}-content`,a==null?void 0:a.content),onScroll:et,ref:Ee},y.createElement(yt,zh({style:{...Ve,tableLayout:It}},hn),yn,rr,S!==!1&&y.createElement(bX,zh({},Ft,me)),fr,_e&&y.createElement(pT,{stickyOffsets:Ye,flattenColumns:ue},_e)));const en={...s};kt&&(en["--columns-count"]=ue.length);let fo=y.createElement("div",zh({className:Q(n,i,{[`${n}-rtl`]:p==="rtl",[`${n}-fix-start-shadow`]:nt,[`${n}-fix-end-shadow`]:nt,[`${n}-fix-start-shadow-show`]:nt&&mt,[`${n}-fix-end-shadow-show`]:nt&&St,[`${n}-layout-fixed`]:h==="fixed",[`${n}-fixed-header`]:Ae,[`${n}-fixed-column`]:Et,[`${n}-scroll-horizontal`]:nt,[`${n}-has-fix-start`]:(ti=ue[0])==null?void 0:ti.fixed,[`${n}-has-fix-end`]:((mr=ue[ue.length-1])==null?void 0:mr.fixed)==="end"}),style:en,id:b,ref:ke},dn),f&&y.createElement(xX,{className:Q(`${n}-title`,a==null?void 0:a.title),style:l==null?void 0:l.title},f(H)),y.createElement("div",{ref:We,className:Q(`${n}-container`,a==null?void 0:a.section),style:l==null?void 0:l.section},Qt),g&&y.createElement(xX,{className:Q(`${n}-footer`,a==null?void 0:a.footer),style:l==null?void 0:l.footer},g(H)));nt&&(fo=y.createElement(ta,{onResize:({offsetWidth:Ct})=>st(Ct)},fo));const Dr=$3e(ue,Ye),sn=y.useMemo(()=>({scrollX:pe,scrollInfo:Te,classNames:a,styles:l,prefixCls:n,getComponent:W,scrollbarSize:Mt,direction:p,fixedInfoList:Dr,isSticky:kt,componentWidth:ie,fixHeader:Ae,fixColumn:Et,horizonScroll:nt,tableLayout:It,rowClassName:o,expandedRowClassName:Y.expandedRowClassName,expandIcon:ne,expandableType:oe,expandRowByClick:Y.expandRowByClick,expandedRowRender:Y.expandedRowRender,expandedRowOffset:Y.expandedRowOffset,onTriggerExpand:he,expandIconColumnIndex:Y.expandIconColumnIndex,indentSize:Y.indentSize,allColumnsFixedLeft:ue.every(Ct=>Ct.fixed==="start"),emptyNode:ur,columns:J,flattenColumns:ue,onColumnResize:Oe,colWidths:ot,hoverStartRow:K,hoverEndRow:q,onHover:X,rowExpandable:Y.rowExpandable,onRow:R,getRowKey:V,expandedKeys:ee,childrenColumnName:le,rowHoverable:B,measureRowRender:M}),[pe,Te,a,l,n,W,Mt,p,Dr,kt,ie,Ae,Et,nt,It,o,Y.expandedRowClassName,ne,oe,Y.expandRowByClick,Y.expandedRowRender,Y.expandedRowOffset,he,Y.expandIconColumnIndex,Y.indentSize,ur,J,ue,Oe,ot,K,q,X,Y.rowExpandable,R,V,ee,le,B,M]);return y.createElement($o.Provider,{value:sn},fo)},Z3e=y.forwardRef(Y3e),Ode=e=>Sde(Z3e,e),$C=Ode();$C.EXPAND_COLUMN=Vh;$C.INTERNAL_HOOKS=t1;$C.Column=b3e;$C.ColumnGroup=S3e;$C.Summary=Ede;const O4=F4(null),kde=F4(null);function pG(){return pG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{rowInfo:t,column:r,colIndex:n,indent:i,index:o,component:s,renderIndex:a,record:l,style:c,className:u,inverse:d,getHeight:h}=e,{render:p,dataIndex:f,className:g,width:m}=r,{columnsOffset:v}=lo(kde,["columnsOffset"]),{key:b,fixedInfo:S,appendCellNode:x,additionalCellProps:E}=Dde(t,r,n,i,o),{style:R,colSpan:T=1,rowSpan:M=1}=E,D=n-1,A=Q3e(D,T,v),I=T>1?m-A:0,L={...R,...c,flex:`0 0 ${A}px`,width:`${A}px`,marginRight:I,pointerEvents:"auto"},F=y.useMemo(()=>d?M<=1:T===0||M===0||M>1,[M,T,d]);F?L.visibility="hidden":d&&(L.height=h==null?void 0:h(M));const k=F?()=>null:p,O={};return(M===0||T===0)&&(O.rowSpan=1,O.colSpan=1),y.createElement(BC,pG({className:Q(g,u),ellipsis:r.ellipsis,align:r.align,scope:r.rowScope,component:s,prefixCls:t.prefixCls,key:b,record:l,index:o,renderIndex:a,dataIndex:f,render:k,shouldCellUpdate:r.shouldCellUpdate},S,{appendNode:x,additionalProps:{...E,style:L,...O}}))};function fG(){return fG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:r,index:n,className:i,rowKey:o,style:s,extra:a,getHeight:l,...c}=e,{record:u,indent:d,index:h}=r,{scrollX:p,flattenColumns:f,prefixCls:g,fixColumn:m,componentWidth:v}=lo($o,["prefixCls","flattenColumns","fixColumn","componentWidth","scrollX"]),{getComponent:b}=lo(O4,["getComponent"]),S=Pde(u,o,n,d),x=b(["body","row"],"div"),E=b(["body","cell"],"div"),{rowSupportExpand:R,expanded:T,rowProps:M,expandedRowRender:D,expandedRowClassName:A}=S;let I;if(R&&T){const k=D(u,n,d+1,T),O=Ide(A,u,n,d);let B={};m&&(B={style:{"--virtual-width":`${v}px`}});const H=`${g}-expanded-row-cell`;I=y.createElement(x,{className:Q(`${g}-expanded-row`,`${g}-expanded-row-level-${d+1}`,O)},y.createElement(BC,{component:E,prefixCls:g,className:Q(H,{[`${H}-fixed`]:m}),additionalProps:B},k))}const L={...s,width:p};a&&(L.position="absolute",L.pointerEvents="none");const F=y.createElement(x,fG({},M,c,{"data-row-key":o,ref:R?null:t,className:Q(i,`${g}-row`,M==null?void 0:M.className,{[`${g}-row-extra`]:a}),style:{...L,...M==null?void 0:M.style}}),f.map((k,O)=>y.createElement(J3e,{key:O,component:E,rowInfo:S,column:k,colIndex:O,indent:d,index:n,renderIndex:h,record:u,inverse:a,getHeight:l})));return R?y.createElement("div",{ref:t},F,I):F}),MX=NC(e4e),t4e=y.forwardRef((e,t)=>{const{data:r,onScroll:n}=e,{flattenColumns:i,onColumnResize:o,getRowKey:s,expandedKeys:a,prefixCls:l,childrenColumnName:c,scrollX:u,direction:d}=lo($o,["flattenColumns","onColumnResize","getRowKey","prefixCls","expandedKeys","childrenColumnName","scrollX","direction"]),{sticky:h,scrollY:p,listItemHeight:f,getComponent:g,onScroll:m}=lo(O4),v=y.useRef(null),b=Rde(r,c,a,s),S=y.useMemo(()=>{let I=0;return i.map(({width:L,minWidth:F,key:k})=>{const O=Math.max(L||0,F||0);return I+=O,[k,O,I]})},[i]),x=y.useMemo(()=>S.map(I=>I[2]),[S]);y.useEffect(()=>{S.forEach(([I,L])=>{o(I,L)})},[S]),y.useImperativeHandle(t,()=>{var L;const I={scrollTo:F=>{var B,H;const{offset:k,...O}=F;k?(B=v.current)==null||B.scrollTo({...O,offset:k,align:"top"}):(H=v.current)==null||H.scrollTo(F)},nativeElement:(L=v.current)==null?void 0:L.nativeElement};return Object.defineProperty(I,"scrollLeft",{get:()=>{var F;return((F=v.current)==null?void 0:F.getScrollInfo().x)||0},set:F=>{var k;(k=v.current)==null||k.scrollTo({left:F})}}),Object.defineProperty(I,"scrollTop",{get:()=>{var F;return((F=v.current)==null?void 0:F.getScrollInfo().y)||0},set:F=>{var k;(k=v.current)==null||k.scrollTo({top:F})}}),I});const E=(I,L)=>{var O;const F=(O=b[L])==null?void 0:O.record,{onCell:k}=I;if(k){const B=k(F,L);return(B==null?void 0:B.rowSpan)??1}return 1},R=I=>{const{start:L,end:F,getSize:k,offsetY:O}=I;if(F<0)return null;let B=i.filter($=>E($,L)===0),H=L;for(let $=L;$>=0;$-=1)if(B=B.filter(K=>E(K,$)===0),!B.length){H=$;break}let N=i.filter($=>E($,F)!==1),z=F;for(let $=F;$E(K,$)!==1),!N.length){z=Math.max($-1,F);break}const W=[];for(let $=H;$<=z;$+=1)b[$]&&i.some(q=>E(q,$)>1)&&W.push($);return W.map($=>{const K=b[$],q=s(K.record,$),X=oe=>{const ee=$+oe-1,ne=b[ee];if(!ne||!ne.record){const re=Math.min(ee,b.length-1),ie=b[re],de=s(ie.record,re),J=k(q,de);return J.bottom-J.top}const le=s(ne.record,ee),he=k(q,le);return he.bottom-he.top},Y=k(q);return y.createElement(MX,{key:$,data:K,rowKey:q,index:$,style:{top:-O+Y.top},extra:!0,getHeight:X})})},T=y.useMemo(()=>({columnsOffset:x}),[x]),M=`${l}-tbody`,D=g(["body","wrapper"]),A={};return h&&(A.position="sticky",A.bottom=0,typeof h=="object"&&h.offsetScroll&&(A.bottom=h.offsetScroll)),y.createElement(kde.Provider,{value:T},y.createElement(qD,{fullHeight:!1,ref:v,prefixCls:`${M}-virtual`,styles:{horizontalScrollBar:A},className:M,height:p,itemHeight:f||24,data:b,itemKey:I=>s(I.record),component:D,scrollWidth:u,direction:d,onVirtualScroll:({x:I})=>{var L;n({currentTarget:(L=v.current)==null?void 0:L.nativeElement,scrollLeft:I})},onScroll:m,extraRender:R},(I,L,F)=>{const k=s(I.record,L);return y.createElement(MX,{data:I,rowKey:k,index:L,style:F.style})}))}),r4e=NC(t4e);function gG(){return gG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{ref:r,onScroll:n}=t;return y.createElement(r4e,{ref:r,data:e,onScroll:n})},i4e=(e,t)=>{const{data:r,columns:n,scroll:i,sticky:o,prefixCls:s=_de,className:a,listItemHeight:l,components:c,onScroll:u}=e;let{x:d,y:h}=i||{};typeof d!="number"&&(d=1),typeof h!="number"&&(h=500);const p=br((m,v)=>Zs(c,m)||v),f=br(u),g=y.useMemo(()=>({sticky:o,scrollY:h,listItemHeight:l,getComponent:p,onScroll:f}),[o,h,l,p,f]);return y.createElement(O4.Provider,{value:g},y.createElement($C,gG({},e,{className:Q(a,`${s}-virtual`),scroll:{...i,x:d},components:{...c,body:r!=null&&r.length?n4e:void 0},columns:n,internalHooks:t1,tailor:!0,ref:t})))},o4e=y.forwardRef(i4e),Nde=e=>Sde(o4e,e);Nde();const s4e=e=>null,a4e=e=>null,k4=y.createContext(null),l4e=y.createContext({}),c4e=({prefixCls:e,level:t,isStart:r,isEnd:n})=>{const i=`${e}-indent-unit`,o=[];for(let s=0;s{var St,Ze;const{eventKey:t,className:r,style:n,dragOver:i,dragOverGapTop:o,dragOverGapBottom:s,isLeaf:a,isStart:l,isEnd:c,expanded:u,selected:d,checked:h,halfChecked:p,loading:f,domRef:g,active:m,data:v,onMouseMove:b,selectable:S,treeId:x,...E}=e,R=ile(x,t),T=Z.useContext(k4),{classNames:M,styles:D}=T||{},A=Z.useContext(l4e),I=Z.useRef(null),[L,F]=Z.useState(!1),k=!!(T.disabled||e.disabled||(St=A.nodeDisabled)!=null&&St.call(A,v)),O=Z.useMemo(()=>!T.checkable||e.checkable===!1?!1:T.checkable,[T.checkable,e.checkable]),B=Fe=>{k||T.onNodeSelect(Fe,Hi(e))},H=Fe=>{k||!O||e.disableCheckbox||T.onNodeCheck(Fe,Hi(e),!h)},N=Z.useMemo(()=>typeof S=="boolean"?S:T.selectable,[S,T.selectable]),z=Fe=>{T.onNodeClick(Fe,Hi(e)),N?B(Fe):H(Fe)},W=Fe=>{T.onNodeDoubleClick(Fe,Hi(e))},V=Fe=>{T.onNodeMouseEnter(Fe,Hi(e))},$=Fe=>{T.onNodeMouseLeave(Fe,Hi(e))},K=Fe=>{T.onNodeContextMenu(Fe,Hi(e))},q=Z.useMemo(()=>!!(T.draggable&&(!T.draggable.nodeDraggable||T.draggable.nodeDraggable(v))),[T.draggable,v]),X=Fe=>{Fe.stopPropagation(),F(!0),T.onNodeDragStart(Fe,e);try{Fe.dataTransfer.setData("text/plain","")}catch{}},Y=Fe=>{Fe.preventDefault(),Fe.stopPropagation(),T.onNodeDragEnter(Fe,e)},oe=Fe=>{Fe.preventDefault(),Fe.stopPropagation(),T.onNodeDragOver(Fe,e)},ee=Fe=>{Fe.stopPropagation(),T.onNodeDragLeave(Fe,e)},ne=Fe=>{Fe.stopPropagation(),F(!1),T.onNodeDragEnd(Fe,e)},le=Fe=>{Fe.preventDefault(),Fe.stopPropagation(),F(!1),T.onNodeDrop(Fe,e)},he=Fe=>{f||T.onNodeExpand(Fe,Hi(e))},re=Z.useMemo(()=>{const{children:Fe}=Es(T.keyEntities,t)||{};return!!(Fe||[]).length},[T.keyEntities,t]),ie=Z.useMemo(()=>Lue(a,T.loadData,re,e.loaded),[a,T.loadData,re,e.loaded]);Z.useEffect(()=>{f||typeof T.loadData=="function"&&u&&!ie&&!e.loaded&&T.onNodeLoad(Hi(e))},[f,T.loadData,T.onNodeLoad,u,ie,e]);const de=Z.useMemo(()=>{var Fe;return(Fe=T.draggable)!=null&&Fe.icon?Z.createElement("span",{className:`${T.prefixCls}-draggable-icon`},T.draggable.icon):null},[T.draggable]),J=Fe=>{const tt=e.switcherIcon||T.switcherIcon;return typeof tt=="function"?tt({...e,isLeaf:Fe}):tt},ue=()=>{if(ie){const tt=J(!0);return tt!==!1?Z.createElement("span",{className:Q(`${T.prefixCls}-switcher`,`${T.prefixCls}-switcher-noop`)},tt):null}const Fe=J(!1);return Fe!==!1?Z.createElement("span",{onClick:he,className:Q(`${T.prefixCls}-switcher`,`${T.prefixCls}-switcher_${u?IX:DX}`)},Fe):null},ve=Z.useMemo(()=>{if(!O)return null;const Fe=typeof O!="boolean"?O:null;return Z.createElement("span",{className:Q(`${T.prefixCls}-checkbox`,{[`${T.prefixCls}-checkbox-checked`]:h,[`${T.prefixCls}-checkbox-indeterminate`]:!h&&p,[`${T.prefixCls}-checkbox-disabled`]:k||e.disableCheckbox}),onClick:H,role:"checkbox","aria-checked":p?"mixed":h,"aria-disabled":k||e.disableCheckbox,"aria-labelledby":R},Fe)},[O,h,p,k,e.disableCheckbox,R]),pe=Z.useMemo(()=>ie?null:u?IX:DX,[ie,u]),me=Z.useMemo(()=>Z.createElement("span",{className:Q(M==null?void 0:M.itemIcon,`${T.prefixCls}-iconEle`,`${T.prefixCls}-icon__${pe||"docu"}`,{[`${T.prefixCls}-icon_loading`]:f}),style:D==null?void 0:D.itemIcon}),[T.prefixCls,pe,f]),ke=Z.useMemo(()=>{const Fe=!!T.draggable;return!e.disabled&&Fe&&T.dragOverNodeKey===t?T.dropIndicatorRender({dropPosition:T.dropPosition,dropLevelOffset:T.dropLevelOffset,indent:T.indent,prefixCls:T.prefixCls,direction:T.direction}):null},[T.dropPosition,T.dropLevelOffset,T.indent,T.prefixCls,T.direction,T.draggable,T.dragOverNodeKey,T.dropIndicatorRender]),De=Z.useMemo(()=>{const{title:Fe=d4e}=e,tt=`${T.prefixCls}-node-content-wrapper`;let Ne;if(T.showIcon){const ot=e.icon||T.icon;Ne=ot?Z.createElement("span",{className:Q(M==null?void 0:M.itemIcon,`${T.prefixCls}-iconEle`,`${T.prefixCls}-icon__customize`),style:D==null?void 0:D.itemIcon},typeof ot=="function"?ot(e):ot):me}else T.loadData&&f&&(Ne=me);let rt;return typeof Fe=="function"?rt=Fe(v):T.titleRender?rt=T.titleRender(v):rt=Fe,Z.createElement("span",{ref:I,title:typeof Fe=="string"?Fe:"",className:Q(tt,`${tt}-${pe||"normal"}`,{[`${T.prefixCls}-node-selected`]:!k&&(d||L)}),onMouseEnter:V,onMouseLeave:$,onContextMenu:K,onClick:z,onDoubleClick:W},Ne,Z.createElement("span",{className:Q(`${T.prefixCls}-title`,M==null?void 0:M.itemTitle),style:D==null?void 0:D.itemTitle},rt),ke)},[T.prefixCls,T.showIcon,e,T.icon,me,T.titleRender,v,pe,V,$,K,z,W]),Ee=ai(E,{aria:!0,data:!0}),{level:We}=Es(T.keyEntities,t)||{},ze=c[c.length-1],mt=!k&&q,Nt=T.draggingNodeKey===t;return Z.createElement("div",mG({ref:g,role:"treeitem",id:R,"aria-expanded":ie?void 0:u,"aria-selected":N&&!k?d:void 0,"aria-checked":O&&!k?p?"mixed":h:void 0,"aria-disabled":k,className:Q(r,`${T.prefixCls}-treenode`,M==null?void 0:M.item,{[`${T.prefixCls}-treenode-disabled`]:k,[`${T.prefixCls}-treenode-switcher-${u?"open":"close"}`]:!a,[`${T.prefixCls}-treenode-checkbox-checked`]:h,[`${T.prefixCls}-treenode-checkbox-indeterminate`]:p,[`${T.prefixCls}-treenode-selected`]:d,[`${T.prefixCls}-treenode-loading`]:f,[`${T.prefixCls}-treenode-active`]:m,[`${T.prefixCls}-treenode-leaf-last`]:ze,[`${T.prefixCls}-treenode-draggable`]:q,dragging:Nt,"drop-target":T.dropTargetKey===t,"drop-container":T.dropContainerKey===t,"drag-over":!k&&i,"drag-over-gap-top":!k&&o,"drag-over-gap-bottom":!k&&s,"filter-node":(Ze=T.filterTreeNode)==null?void 0:Ze.call(T,Hi(e)),[`${T.prefixCls}-treenode-leaf`]:ie}),style:{...n,...D==null?void 0:D.item},draggable:mt,onDragStart:mt?X:void 0,onDragEnter:q?Y:void 0,onDragOver:q?oe:void 0,onDragLeave:q?ee:void 0,onDrop:q?le:void 0,onDragEnd:q?ne:void 0,onMouseMove:b},Ee),Z.createElement(u4e,{prefixCls:T.prefixCls,level:We,isStart:l,isEnd:c}),de,ue(),ve,De)};F0.isTreeNode=1;function Wc(e,t){if(!e)return[];const r=e.slice(),n=r.indexOf(t);return n>=0&&r.splice(n,1),r}function ed(e,t){const r=(e||[]).slice();return r.indexOf(t)===-1&&r.push(t),r}function N4(e){return e.split("-")}function h4e(e,t){const r=[],n=Es(t,e);function i(o=[]){o.forEach(({key:s,children:a})=>{r.push(s),i(a)})}return i(n.children),r}function p4e(e){if(e.parent){const t=N4(e.pos);return Number(t[t.length-1])===e.parent.children.length-1}return!1}function f4e(e){const t=N4(e.pos);return Number(t[t.length-1])===0}function AX(e,t,r,n,i,o,s,a,l,c){var A;const{clientX:u,clientY:d}=e,{top:h,height:p}=e.target.getBoundingClientRect(),g=((c==="rtl"?-1:1)*(((i==null?void 0:i.x)||0)-u)-12)/n,m=l.filter(I=>{var L,F;return(F=(L=a[I])==null?void 0:L.children)==null?void 0:F.length});let v=Es(a,r.eventKey);if(dk.key===v.key),L=I<=0?0:I-1,F=s[L].key;v=Es(a,F)}const b=v.key,S=v,x=v.key;let E=0,R=0;if(!m.includes(b))for(let I=0;I-1.5?o({dragNode:T,dropNode:M,dropPosition:1})?E=1:D=!1:o({dragNode:T,dropNode:M,dropPosition:0})?E=0:o({dragNode:T,dropNode:M,dropPosition:1})?E=1:D=!1:o({dragNode:T,dropNode:M,dropPosition:1})?E=1:D=!1,{dropPosition:E,dropLevelOffset:R,dropTargetKey:v.key,dropTargetPos:v.pos,dragOverNodeKey:x,dropContainerKey:E===0?null:((A=v.parent)==null?void 0:A.key)||null,dropAllowed:D}}function FX(e,t){if(!e)return;const{multiple:r}=t;return r?e.slice():e.length?[e[0]]:e}function pO(e){if(!e)return null;let t;if(Array.isArray(e))t={checkedKeys:e,halfCheckedKeys:void 0};else if(typeof e=="object")t={checkedKeys:e.checked||void 0,halfCheckedKeys:e.halfChecked||void 0};else return Vn(!1,"`checkedKeys` is not an array or an object"),null;return t}function vG(e,t){const r=new Set;function n(i){if(r.has(i))return;const o=Es(t,i);if(!o)return;r.add(i);const{parent:s,node:a}=o;a.disabled||s&&n(s.key)}return(e||[]).forEach(i=>{n(i)}),[...r]}const kh={},yG="SELECT_ALL",CG="SELECT_INVERT",bG="SELECT_NONE",LX=[],Bde=(e,t,r=[])=>((t||[]).forEach(n=>{r.push(n),n&&typeof n=="object"&&e in n&&Bde(e,n[e],r)}),r),g4e=(e,t)=>{const{preserveSelectedRowKeys:r,selectedRowKeys:n,defaultSelectedRowKeys:i,getCheckboxProps:o,getTitleCheckboxProps:s,onChange:a,onSelect:l,onSelectAll:c,onSelectInvert:u,onSelectNone:d,onSelectMultiple:h,columnWidth:p,type:f,selections:g,fixed:m,renderCell:v,hideSelectAll:b,checkStrictly:S=!0}=t||{},{prefixCls:x,data:E,pageData:R,getRecordByKey:T,getRowKey:M,expandType:D,childrenColumnName:A,locale:I,getPopupContainer:L}=e,F=MC(),[k,O]=lFe(re=>re),[B,H]=An(i||LX,n),N=y.useRef(new Map),z=y.useCallback(re=>{if(r){const ie=new Map;re.forEach(de=>{let J=T(de);!J&&N.current.has(de)&&(J=N.current.get(de)),ie.set(de,J)}),N.current=ie}},[T,r]);y.useEffect(()=>{z(B)},[B]);const W=y.useMemo(()=>Bde(A,R),[A,R]),{keyEntities:V}=y.useMemo(()=>{if(S)return{keyEntities:null};let re=E;if(r){const ie=new Set(W.map(M)),de=Array.from(N.current).reduce((J,[ue,ve])=>ie.has(ue)?J:J.concat(ve),[]);re=[].concat(Pr(re),Pr(de))}return T4(re,{externalGetKey:M,childrenPropName:A})},[E,M,S,A,r,W]),$=y.useMemo(()=>{const re=new Map;return W.forEach((ie,de)=>{const J=M(ie,de),ue=(o?o(ie):null)||{};re.set(J,ue)}),re},[W,M,o]),K=y.useCallback(re=>{const ie=M(re);let de;return $.has(ie)?de=$.get(M(re)):de=o?o(re):void 0,!!(de!=null&&de.disabled)},[$,M]),[q,X]=y.useMemo(()=>{if(S)return[B||[],[]];const{checkedKeys:re,halfCheckedKeys:ie}=wy(B,!0,V,K);return[re||[],ie]},[B,S,V,K]),Y=y.useMemo(()=>{const re=f==="radio"?q.slice(0,1):q;return new Set(re)},[q,f]),oe=y.useMemo(()=>f==="radio"?new Set:new Set(X),[X,f]);y.useEffect(()=>{t||H(LX)},[!!t]);const ee=y.useCallback((re,ie)=>{let de,J;z(re),r?(de=re,J=re.map(ue=>N.current.get(ue))):(de=[],J=[],re.forEach(ue=>{const ve=T(ue);ve!==void 0&&(de.push(ue),J.push(ve))})),H(de),a==null||a(de,J,{type:ie})},[H,T,a,r]),ne=y.useCallback((re,ie,de,J)=>{if(l){const ue=de.map(T);l(T(re),ie,ue,J)}ee(de,"single")},[l,T,ee]),le=y.useMemo(()=>!g||b?null:(g===!0?[yG,CG,bG]:g).map(ie=>ie===yG?{key:"all",text:I.selectionAll,onSelect(){ee(E.map((de,J)=>M(de,J)).filter(de=>{const J=$.get(de);return!(J!=null&&J.disabled)||Y.has(de)}),"all")}}:ie===CG?{key:"invert",text:I.selectInvert,onSelect(){const de=new Set(Y);R.forEach((ue,ve)=>{const pe=M(ue,ve),me=$.get(pe);me!=null&&me.disabled||(de.has(pe)?de.delete(pe):de.add(pe))});const J=Array.from(de);u&&(F.deprecated(!1,"onSelectInvert","onChange"),u(J)),ee(J,"invert")}}:ie===bG?{key:"none",text:I.selectNone,onSelect(){d==null||d(),ee(Array.from(Y).filter(de=>{const J=$.get(de);return J==null?void 0:J.disabled}),"none")}}:ie).map(ie=>({...ie,onSelect:(...de)=>{var J;(J=ie.onSelect)==null||J.call(ie,...de),O(null)}})),[g,b,I.selectionAll,I.selectInvert,I.selectNone,$,Y,E,R,M,u,ee]);return[y.useCallback(re=>{var tt;if(!t)return re.filter(Ne=>Ne!==kh);let ie=Pr(re);const de=new Set(Y),J=W.map(M).filter(Ne=>!$.get(Ne).disabled),ue=J.every(Ne=>de.has(Ne)),ve=J.some(Ne=>de.has(Ne)),pe=()=>{const Ne=[];ue?J.forEach(ot=>{de.delete(ot),Ne.push(ot)}):J.forEach(ot=>{de.has(ot)||(de.add(ot),Ne.push(ot))});const rt=Array.from(de);c==null||c(!ue,rt.map(T),Ne.map(T)),ee(rt,"all"),O(null)};let me,ke;if(f!=="radio"){let Ne;if(le){const kt={getPopupContainer:L,items:le.map((Wt,at)=>{const{key:lt,text:Ut,onSelect:cr}=Wt;return{key:lt??at,onClick:()=>{cr==null||cr(J)},label:Ut}})};Ne=y.createElement("div",{className:`${x}-selection-extra`},y.createElement(I4,{menu:kt,getPopupContainer:L},y.createElement("span",null,y.createElement(XD,null))))}const rt=W.map((kt,Wt)=>{const at=M(kt,Wt),lt=$.get(at)||{};return{checked:de.has(at),...lt}}).filter(({disabled:kt})=>kt),ot=!!rt.length&&rt.length===W.length,Ye=ot&&rt.every(({checked:kt})=>kt),Ae=ot&&rt.some(({checked:kt})=>kt),nt=(s==null?void 0:s())||{},{onChange:Et,disabled:Tt}=nt;ke=y.createElement(Ky,{"aria-label":Ne?"Custom selection":"Select all",...nt,checked:ot?Ye:!!W.length&&ue,indeterminate:ot?!Ye&&Ae:!ue&&ve,onChange:kt=>{pe(),Et==null||Et(kt)},disabled:Tt??(W.length===0||ot),skipGroup:!0}),me=!b&&y.createElement("div",{className:`${x}-selection`},ke,Ne)}let De;f==="radio"?De=(Ne,rt,ot)=>{const Ye=M(rt,ot),Ae=de.has(Ye),nt=$.get(Ye);return{node:y.createElement(Yx,{...nt,checked:Ae,onClick:Et=>{var Tt;Et.stopPropagation(),(Tt=nt==null?void 0:nt.onClick)==null||Tt.call(nt,Et)},onChange:Et=>{var Tt;de.has(Ye)||ne(Ye,!0,[Ye],Et.nativeEvent),(Tt=nt==null?void 0:nt.onChange)==null||Tt.call(nt,Et)}}),checked:Ae}}:De=(Ne,rt,ot)=>{const Ye=M(rt,ot),Ae=de.has(Ye),nt=oe.has(Ye),Et=$.get(Ye);let Tt;return D==="nest"?Tt=nt:Tt=(Et==null?void 0:Et.indeterminate)??nt,{node:y.createElement(Ky,{...Et,indeterminate:Tt,checked:Ae,skipGroup:!0,onClick:kt=>{var Wt;kt.stopPropagation(),(Wt=Et==null?void 0:Et.onClick)==null||Wt.call(Et,kt)},onChange:kt=>{var cr;const{nativeEvent:Wt}=kt,{shiftKey:at}=Wt,lt=J.indexOf(Ye),Ut=q.some(_e=>J.includes(_e));if(at&&S&&Ut){const _e=k(lt,J,de),qe=Array.from(de);h==null||h(!Ae,qe.map(T),_e.map(T)),ee(qe,"multiple")}else{const _e=q;if(S){const qe=Ae?Wc(_e,Ye):ed(_e,Ye);ne(Ye,!Ae,qe,Wt)}else{const qe=wy([].concat(Pr(_e),[Ye]),!0,V,K),{checkedKeys:Re,halfCheckedKeys:it}=qe;let Ve=Re;if(Ae){const Oe=new Set(Re);Oe.delete(Ye),Ve=wy(Array.from(Oe),{halfCheckedKeys:it},V,K).checkedKeys}ne(Ye,!Ae,Ve,Wt)}}O(Ae?null:lt),(cr=Et==null?void 0:Et.onChange)==null||cr.call(Et,kt)}}),checked:Ae}};const Ee=(Ne,rt,ot)=>{const{node:Ye,checked:Ae}=De(Ne,rt,ot);return v?v(Ae,rt,ot,Ye):Ye};if(!ie.includes(kh))if(ie.findIndex(Ne=>{var rt;return((rt=Ne[kw])==null?void 0:rt.columnType)==="EXPAND_COLUMN"})===0){const[Ne,...rt]=ie;ie=[Ne,kh].concat(Pr(rt))}else ie=[kh].concat(Pr(ie));const We=ie.indexOf(kh);ie=ie.filter((Ne,rt)=>Ne!==kh||rt===We);const ze=ie[We-1],mt=ie[We+1];let Nt=m;Nt===void 0&&((mt==null?void 0:mt.fixed)!==void 0?Nt=mt.fixed:(ze==null?void 0:ze.fixed)!==void 0&&(Nt=ze.fixed)),Nt&&ze&&((tt=ze[kw])==null?void 0:tt.columnType)==="EXPAND_COLUMN"&&ze.fixed===void 0&&(ze.fixed=Nt);const St=Q(`${x}-selection-col`,{[`${x}-selection-col-with-dropdown`]:g&&f==="checkbox"}),Ze=()=>t!=null&&t.columnTitle?typeof t.columnTitle=="function"?t.columnTitle(ke):t.columnTitle:me,Fe={fixed:Nt,width:p,className:`${x}-selection-column`,title:Ze(),render:Ee,onCell:t.onCell,align:t.align,[kw]:{className:St}};return ie.map(Ne=>Ne===kh?Fe:Ne)},[M,W,t,q,Y,oe,p,le,D,$,h,ne,K]),Y]};function m4e(e){return t=>{const{prefixCls:r,onExpand:n,record:i,expanded:o,expandable:s}=t,a=`${r}-row-expand-icon`;return y.createElement("button",{type:"button",onClick:l=>{n(i,l),l.stopPropagation()},className:Q(a,{[`${a}-spaced`]:!s,[`${a}-expanded`]:s&&o,[`${a}-collapsed`]:s&&!o}),"aria-label":o?e.collapse:e.expand,"aria-expanded":o})}}function v4e(e){return(r,n)=>{const i=r.querySelector(`.${e}-container`);let o=n;if(i){const s=getComputedStyle(i),a=Number.parseInt(s.borderLeftWidth,10),l=Number.parseInt(s.borderRightWidth,10);o=n-a-l}return o}}const Pp=(e,t)=>"key"in e&&Tn(e.key)?e.key:e.dataIndex?Array.isArray(e.dataIndex)?e.dataIndex.join("."):e.dataIndex:t;function GC(e,t){return t?`${t}-${e}`:`${e}`}const lA=(e,t)=>typeof e=="function"?e(t):e,y4e=(e,t)=>{const r=lA(e,t);return Object.prototype.toString.call(r)==="[object Object]"?"":r};var C4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M349 838c0 17.7 14.2 32 31.8 32h262.4c17.6 0 31.8-14.3 31.8-32V642H349v196zm531.1-684H143.9c-24.5 0-39.8 26.7-27.5 48l221.3 376h348.8l221.3-376c12.1-21.3-3.2-48-27.7-48z"}}]},name:"filter",theme:"filled"};function SG(){return SG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,SG({},e,{ref:t,icon:C4e})),S4e=y.forwardRef(b4e),w4e=e=>{const{dropPosition:t,dropLevelOffset:r,indent:n}=e,i={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(t){case-1:i.top=0,i.left=-r*n;break;case 1:i.bottom=0,i.left=-r*n;break;case 0:i.bottom=0,i.left=n;break}return Z.createElement("div",{style:i})};function x4e(e,t){const[r,n]=y.useState(!1);jr(()=>{if(r)return e(),()=>{t()}},[r]),jr(()=>(n(!0),()=>{n(!1)}),[])}function Nw(){return Nw=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{className:r,style:n,motion:i,motionNodes:o,motionType:s,onMotionStart:a,onMotionEnd:l,active:c,treeNodeRequiredProps:u,...d}=e,[h,p]=y.useState(!0),{prefixCls:f}=y.useContext(k4),g=o&&s!=="hide";jr(()=>{o&&g!==h&&p(g)},[o]);const m=()=>{o&&a()},v=y.useRef(!1),b=()=>{o&&!v.current&&(v.current=!0,l())};x4e(m,b);const S=x=>{g===x&&b()};return o?y.createElement(gu,Nw({ref:t,visible:h},i,{motionAppear:s==="show",onVisibleChanged:S}),({className:x,style:E},R)=>y.createElement("div",{ref:R,className:Q(`${f}-treenode-motion`,x),style:E},o.map(T=>{const{data:{...M},title:D,key:A,isStart:I,isEnd:L}=T;delete M.children;const F=Lw(A,u);return y.createElement(F0,Nw({},M,F,{title:D,active:c,data:T.data,key:A,isStart:I,isEnd:L}))}))):y.createElement(F0,Nw({domRef:t,className:r,style:n},d,{active:c}))});function T4e(e=[],t=[]){const r=e.length,n=t.length;if(Math.abs(r-n)!==1)return{add:!1,key:null};function i(o,s){const a=new Map;o.forEach(c=>{a.set(c,!0)});const l=s.filter(c=>!a.has(c));return l.length===1?l[0]:null}return rs.key===r),i=e[n+1],o=t.findIndex(s=>s.key===r);if(i){const s=t.findIndex(a=>a.key===i.key);return t.slice(o+1,s)}return t.slice(o+1)}function FM(){return FM=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{prefixCls:r,data:n,selectable:i,checkable:o,expandedKeys:s,selectedKeys:a,checkedKeys:l,loadedKeys:c,loadingKeys:u,halfCheckedKeys:d,keyEntities:h,disabled:p,dragging:f,dragOverNodeKey:g,dropPosition:m,motion:v,height:b,itemHeight:S,virtual:x,scrollWidth:E,focusable:R,activeItem:T,tabIndex:M,onKeyDown:D,onFocus:A,onBlur:I,onActiveChange:L,onListChangeStart:F,onListChangeEnd:k,...O}=e,B=xc(),H=y.useRef(null),N=y.useRef(null);y.useImperativeHandle(t,()=>({scrollTo:ie=>{H.current.scrollTo(ie)},getIndentWidth:()=>N.current.offsetWidth}));const[z,W]=y.useState(s),[V,$]=y.useState(n),[K,q]=y.useState(n),[X,Y]=y.useState([]),[oe,ee]=y.useState(null),ne=y.useRef(n);ne.current=n;function le(){const ie=ne.current;$(ie),q(ie),Y([]),ee(null),k()}jr(()=>{W(s);const ie=T4e(z,s);if(ie.key!==null)if(ie.add){const de=V.findIndex(({key:ve})=>ve===ie.key),J=kX(_X(V,n,ie.key),x,b,S),ue=V.slice();ue.splice(de+1,0,OX),q(ue),Y(J),ee("show")}else{const de=n.findIndex(({key:ve})=>ve===ie.key),J=kX(_X(n,V,ie.key),x,b,S),ue=n.slice();ue.splice(de+1,0,OX),q(ue),Y(J),ee("hide")}else V!==n&&($(n),q(n))},[s,n]),y.useEffect(()=>{f||le()},[f]);const he=v?K:n,re={expandedKeys:s,selectedKeys:a,loadedKeys:c,loadingKeys:u,checkedKeys:l,halfCheckedKeys:d,dragOverNodeKey:g,dropPosition:m,keyEntities:h};return y.createElement(y.Fragment,null,y.createElement("div",{className:`${r}-treenode`,"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},y.createElement("div",{className:`${r}-indent`},y.createElement("div",{ref:N,className:`${r}-indent-unit`}))),y.createElement(qD,FM({},O,{data:he,itemKey:NX,height:b,fullHeight:!1,virtual:x,itemHeight:S,scrollWidth:E,prefixCls:`${r}-list`,ref:H,role:"tree",tabIndex:R!==!1&&!p?M:void 0,"aria-activedescendant":T?ile(B,T.key):void 0,onKeyDown:D,onFocus:A,onBlur:I,onVisibleChange:ie=>{ie.every(de=>NX(de)!==nm)&&le()}}),ie=>{const{pos:de,data:{...J},title:ue,key:ve,isStart:pe,isEnd:me}=ie,ke=Zx(ve,de);delete J.key,delete J.children;const De=Lw(ke,re);return y.createElement(E4e,FM({},J,De,{title:ue,active:!!T&&ve===T.key,pos:de,data:ie.data,isStart:pe,isEnd:me,motion:v,motionNodes:ve===nm?X:null,motionType:oe,onMotionStart:F,onMotionEnd:le,treeNodeRequiredProps:re,treeId:B,onMouseMove:()=>{L(null)}}))}))});function xG(){return xG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{expandedKeys:i,keyEntities:o}=this.state,{onDragStart:s}=this.props,{eventKey:a}=n;this.dragNodeProps=n,this.dragStartMousePosition={x:r.clientX,y:r.clientY};const l=Wc(i,a);this.setState({draggingNodeKey:a,dragChildrenKeys:h4e(a,o),indent:this.listRef.current.getIndentWidth()}),this.setExpandedKeys(l),window.addEventListener("dragend",this.onWindowDragEnd),s==null||s({event:r,node:Hi(n)})});Ie(this,"onNodeDragEnter",(r,n)=>{const{expandedKeys:i,keyEntities:o,dragChildrenKeys:s,flattenNodes:a,indent:l}=this.state,{onDragEnter:c,onExpand:u,allowDrop:d,direction:h}=this.props,{pos:p,eventKey:f}=n;if(this.currentMouseOverDroppableNodeKey!==f&&(this.currentMouseOverDroppableNodeKey=f),!this.dragNodeProps){this.resetDragState();return}const{dropPosition:g,dropLevelOffset:m,dropTargetKey:v,dropContainerKey:b,dropTargetPos:S,dropAllowed:x,dragOverNodeKey:E}=AX(r,this.dragNodeProps,n,l,this.dragStartMousePosition,d,a,o,i,h);if(s.includes(v)||!x){this.resetDragState();return}if(this.delayedDragEnterLogic||(this.delayedDragEnterLogic={}),Object.keys(this.delayedDragEnterLogic).forEach(R=>{clearTimeout(this.delayedDragEnterLogic[R])}),this.dragNodeProps.eventKey!==n.eventKey&&(r.persist(),this.delayedDragEnterLogic[p]=window.setTimeout(()=>{if(this.state.draggingNodeKey===null)return;let R=[...i];const T=Es(o,n.eventKey);T&&(T.children||[]).length&&(R=ed(i,n.eventKey)),this.props.hasOwnProperty("expandedKeys")||this.setExpandedKeys(R),u==null||u(R,{node:Hi(n),expanded:!0,nativeEvent:r.nativeEvent})},800)),this.dragNodeProps.eventKey===v&&m===0){this.resetDragState();return}this.setState({dragOverNodeKey:E,dropPosition:g,dropLevelOffset:m,dropTargetKey:v,dropContainerKey:b,dropTargetPos:S,dropAllowed:x}),c==null||c({event:r,node:Hi(n),expandedKeys:i})});Ie(this,"onNodeDragOver",(r,n)=>{const{dragChildrenKeys:i,flattenNodes:o,keyEntities:s,expandedKeys:a,indent:l}=this.state,{onDragOver:c,allowDrop:u,direction:d}=this.props;if(!this.dragNodeProps)return;const{dropPosition:h,dropLevelOffset:p,dropTargetKey:f,dropContainerKey:g,dropTargetPos:m,dropAllowed:v,dragOverNodeKey:b}=AX(r,this.dragNodeProps,n,l,this.dragStartMousePosition,u,o,s,a,d);i.includes(f)||!v||(this.dragNodeProps.eventKey===f&&p===0?this.state.dropPosition===null&&this.state.dropLevelOffset===null&&this.state.dropTargetKey===null&&this.state.dropContainerKey===null&&this.state.dropTargetPos===null&&this.state.dropAllowed===!1&&this.state.dragOverNodeKey===null||this.resetDragState():h===this.state.dropPosition&&p===this.state.dropLevelOffset&&f===this.state.dropTargetKey&&g===this.state.dropContainerKey&&m===this.state.dropTargetPos&&v===this.state.dropAllowed&&b===this.state.dragOverNodeKey||this.setState({dropPosition:h,dropLevelOffset:p,dropTargetKey:f,dropContainerKey:g,dropTargetPos:m,dropAllowed:v,dragOverNodeKey:b}),c==null||c({event:r,node:Hi(n)}))});Ie(this,"onNodeDragLeave",(r,n)=>{this.currentMouseOverDroppableNodeKey===n.eventKey&&!r.currentTarget.contains(r.relatedTarget)&&(this.resetDragState(),this.currentMouseOverDroppableNodeKey=null);const{onDragLeave:i}=this.props;i==null||i({event:r,node:Hi(n)})});Ie(this,"onWindowDragEnd",r=>{this.onNodeDragEnd(r,null,!0),window.removeEventListener("dragend",this.onWindowDragEnd)});Ie(this,"onNodeDragEnd",(r,n)=>{const{onDragEnd:i}=this.props;this.setState({dragOverNodeKey:null}),this.cleanDragState(),i==null||i({event:r,node:Hi(n)}),this.dragNodeProps=null,window.removeEventListener("dragend",this.onWindowDragEnd)});Ie(this,"onNodeDrop",(r,n,i=!1)=>{var g;const{dragChildrenKeys:o,dropPosition:s,dropTargetKey:a,dropTargetPos:l,dropAllowed:c}=this.state;if(!c)return;const{onDrop:u}=this.props;if(this.setState({dragOverNodeKey:null}),this.cleanDragState(),a===null)return;const d={...Lw(a,this.getTreeNodeRequiredProps()),active:((g=this.getActiveItem())==null?void 0:g.key)===a,data:Es(this.state.keyEntities,a).node},h=o.includes(a);Vn(!h,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");const p=N4(l),f={event:r,node:Hi(d),dragNode:this.dragNodeProps?Hi(this.dragNodeProps):null,dragNodesKeys:[this.dragNodeProps.eventKey].concat(o),dropToGap:s!==0,dropPosition:s+Number(p[p.length-1])};i||u==null||u(f),this.dragNodeProps=null});Ie(this,"cleanDragState",()=>{const{draggingNodeKey:r}=this.state;r!==null&&this.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),this.dragStartMousePosition=null,this.currentMouseOverDroppableNodeKey=null});Ie(this,"triggerExpandActionExpand",(r,n)=>{const{expandedKeys:i,flattenNodes:o}=this.state,{expanded:s,key:a,isLeaf:l}=n;if(l||r.shiftKey||r.metaKey||r.ctrlKey)return;const c=o.filter(d=>d.key===a)[0],u=Hi({...Lw(a,this.getTreeNodeRequiredProps()),data:c.data});this.setExpandedKeys(s?Wc(i,a):ed(i,a)),this.onNodeExpand(r,u)});Ie(this,"onNodeClick",(r,n)=>{const{onClick:i,expandAction:o}=this.props;o==="click"&&this.triggerExpandActionExpand(r,n),i==null||i(r,n)});Ie(this,"onNodeDoubleClick",(r,n)=>{const{onDoubleClick:i,expandAction:o}=this.props;o==="doubleClick"&&this.triggerExpandActionExpand(r,n),i==null||i(r,n)});Ie(this,"onNodeSelect",(r,n)=>{let{selectedKeys:i}=this.state;const{keyEntities:o,fieldNames:s}=this.state,{onSelect:a,multiple:l}=this.props,{selected:c}=n,u=n[s.key],d=!c;d?l?i=ed(i,u):i=[u]:i=Wc(i,u);const h=i.map(p=>{const f=Es(o,p);return f?f.node:null}).filter(Boolean);this.setUncontrolledState({selectedKeys:i}),a==null||a(i,{event:"select",selected:d,node:n,selectedNodes:h,nativeEvent:r.nativeEvent})});Ie(this,"onNodeCheck",(r,n,i)=>{const{keyEntities:o,checkedKeys:s,halfCheckedKeys:a}=this.state,{checkStrictly:l,onCheck:c}=this.props,{key:u}=n;let d;const h={event:"check",node:n,checked:i,nativeEvent:r.nativeEvent};if(l){const p=i?ed(s,u):Wc(s,u),f=Wc(a,u);d={checked:p,halfChecked:f},h.checkedNodes=p.map(g=>Es(o,g)).filter(Boolean).map(g=>g.node),this.setUncontrolledState({checkedKeys:p})}else{let{checkedKeys:p,halfCheckedKeys:f}=wy([...s,u],!0,o);if(!i){const g=new Set(p);g.delete(u),{checkedKeys:p,halfCheckedKeys:f}=wy(Array.from(g),{halfCheckedKeys:f},o)}d=p,h.checkedNodes=[],h.checkedNodesPositions=[],h.halfCheckedKeys=f,p.forEach(g=>{const m=Es(o,g);if(!m)return;const{node:v,pos:b}=m;h.checkedNodes.push(v),h.checkedNodesPositions.push({node:v,pos:b})}),this.setUncontrolledState({checkedKeys:p},!1,{halfCheckedKeys:f})}c==null||c(d,h)});Ie(this,"onNodeLoad",r=>{var a;const{key:n}=r,{keyEntities:i}=this.state,o=Es(i,n);if((a=o==null?void 0:o.children)!=null&&a.length)return;const s=new Promise((l,c)=>{this.setState(({loadedKeys:u=[],loadingKeys:d=[]})=>{const{loadData:h,onLoad:p}=this.props;return!h||u.includes(n)||d.includes(n)?null:(h(r).then(()=>{const{loadedKeys:g}=this.state,m=ed(g,n);p==null||p(m,{event:"load",node:r}),this.setUncontrolledState({loadedKeys:m}),this.setState(v=>({loadingKeys:Wc(v.loadingKeys,n)})),l()}).catch(g=>{if(this.setState(m=>({loadingKeys:Wc(m.loadingKeys,n)})),this.loadingRetryTimes[n]=(this.loadingRetryTimes[n]||0)+1,this.loadingRetryTimes[n]>=P4e){const{loadedKeys:m}=this.state;Vn(!1,"Retry for `loadData` many times but still failed. No more retry."),this.setUncontrolledState({loadedKeys:ed(m,n)}),l()}c(g)}),{loadingKeys:ed(d,n)})})});return s.catch(()=>{}),s});Ie(this,"onNodeMouseEnter",(r,n)=>{const{onMouseEnter:i}=this.props;i==null||i({event:r,node:n})});Ie(this,"onNodeMouseLeave",(r,n)=>{const{onMouseLeave:i}=this.props;i==null||i({event:r,node:n})});Ie(this,"onNodeContextMenu",(r,n)=>{const{onRightClick:i}=this.props;i&&(r.preventDefault(),i({event:r,node:n}))});Ie(this,"onFocus",(...r)=>{var l;const{onFocus:n,disabled:i}=this.props,{activeKey:o,selectedKeys:s,flattenNodes:a}=this.state;if(!i&&o===null){const c=s.find(u=>a.some(d=>d.key===u));c!==void 0?this.onActiveChange(c):this.onActiveChange(((l=a==null?void 0:a[0])==null?void 0:l.key)||null)}n==null||n(...r)});Ie(this,"onBlur",(...r)=>{const{onBlur:n}=this.props;this.onActiveChange(null),n==null||n(...r)});Ie(this,"getTreeNodeRequiredProps",()=>{const{expandedKeys:r,selectedKeys:n,loadedKeys:i,loadingKeys:o,checkedKeys:s,halfCheckedKeys:a,dragOverNodeKey:l,dropPosition:c,keyEntities:u}=this.state;return{expandedKeys:r||[],selectedKeys:n||[],loadedKeys:i||[],loadingKeys:o||[],checkedKeys:s||[],halfCheckedKeys:a||[],dragOverNodeKey:l,dropPosition:c,keyEntities:u}});Ie(this,"setExpandedKeys",r=>{const{treeData:n,fieldNames:i}=this.state,o=nO(n,r,i);this.setUncontrolledState({expandedKeys:r,flattenNodes:o},!0)});Ie(this,"onNodeExpand",(r,n)=>{let{expandedKeys:i}=this.state;const{listChanging:o,fieldNames:s}=this.state,{onExpand:a,loadData:l}=this.props,{expanded:c}=n,u=n[s.key];if(o)return;const d=i.includes(u),h=!c;if(Vn(c&&d||!c&&!d,"Expand state not sync with index check"),i=h?ed(i,u):Wc(i,u),this.setExpandedKeys(i),a==null||a(i,{node:n,expanded:h,nativeEvent:r.nativeEvent}),h&&l){const p=this.onNodeLoad(n);p&&p.then(()=>{const f=nO(this.state.treeData,i,s);this.setUncontrolledState({flattenNodes:f})}).catch(()=>{const{expandedKeys:f}=this.state,g=Wc(f,u);this.setExpandedKeys(g)})}});Ie(this,"onListChangeStart",()=>{this.setUncontrolledState({listChanging:!0})});Ie(this,"onListChangeEnd",()=>{setTimeout(()=>{this.setUncontrolledState({listChanging:!1})})});Ie(this,"onActiveChange",r=>{const{activeKey:n}=this.state,{onActiveChange:i,itemScrollOffset:o=0}=this.props;n!==r&&(this.setState({activeKey:r}),r!==null&&this.scrollTo({key:r,offset:o}),i==null||i(r))});Ie(this,"getActiveItem",()=>{const{activeKey:r,flattenNodes:n}=this.state;return r===null?null:n.find(({key:i})=>i===r)||null});Ie(this,"offsetActiveKey",r=>{const{flattenNodes:n,activeKey:i}=this.state;let o=n.findIndex(({key:a})=>a===i);o===-1&&r<0&&(o=n.length),o=(o+r+n.length)%n.length;const s=n[o];if(s){const{key:a}=s;this.onActiveChange(a)}else this.onActiveChange(null)});Ie(this,"onKeyDown",r=>{var f,g,m;const{activeKey:n,expandedKeys:i,checkedKeys:o,flattenNodes:s,keyEntities:a}=this.state,{onKeyDown:l,checkable:c,selectable:u,disabled:d,loadData:h}=this.props;if(d)return;switch(r.key){case"ArrowUp":{this.offsetActiveKey(-1),r.preventDefault();break}case"ArrowDown":{this.offsetActiveKey(1),r.preventDefault();break}case"Home":{this.onActiveChange((f=s==null?void 0:s[0])==null?void 0:f.key),r.preventDefault();break}case"End":{this.onActiveChange((g=s==null?void 0:s[s.length-1])==null?void 0:g.key),r.preventDefault();break}}const p=this.getActiveItem();if(p&&p.data){const v=this.getTreeNodeRequiredProps(),b=Hi({...Lw(n,v),data:p.data,active:!0}),S=Es(a,n),x=!!((m=S==null?void 0:S.children)!=null&&m.length),E=!Lue(p.data.isLeaf,h,x,b.loaded),R=c&&!b.disabled&&b.checkable!==!1&&!b.disableCheckbox,T=!c&&u&&!b.disabled&&b.selectable!==!1;switch(r.key){case"ArrowLeft":{E&&i.includes(n)?this.onNodeExpand({},b):p.parent&&this.onActiveChange(p.parent.key),r.preventDefault();break}case"ArrowRight":{E&&!i.includes(n)?this.onNodeExpand({},b):p.children&&p.children.length&&this.onActiveChange(p.children[0].key),r.preventDefault();break}case"Enter":{E?(r.preventDefault(),this.onNodeExpand({},b)):R?o.includes(n)||(r.preventDefault(),this.onNodeCheck({},b,!0)):T&&!b.selected&&(r.preventDefault(),this.onNodeSelect({},b));break}case" ":{R?(r.preventDefault(),this.onNodeCheck({},b,!o.includes(n))):T&&(r.preventDefault(),this.onNodeSelect({},b));break}}}l==null||l(r)});Ie(this,"setUncontrolledState",(r,n=!1,i=null)=>{if(!this.destroyed){let o=!1,s=!0;const a={};Object.keys(r).forEach(l=>{if(this.props.hasOwnProperty(l)){s=!1;return}o=!0,a[l]=r[l]}),o&&(!n||s)&&this.setState({...a,...i})}});Ie(this,"scrollTo",r=>{this.listRef.current.scrollTo(r)})}componentDidMount(){this.destroyed=!1,this.onUpdated()}componentDidUpdate(){this.onUpdated()}onUpdated(){const{activeKey:r,itemScrollOffset:n=0}=this.props;r!==void 0&&r!==this.state.activeKey&&(this.setState({activeKey:r}),r!==null&&this.scrollTo({key:r,offset:n}))}componentWillUnmount(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}static getDerivedStateFromProps(r,n){const{prevProps:i}=n,o={prevProps:r};function s(u){return!i&&r.hasOwnProperty(u)||i&&i[u]!==r[u]}let a,{fieldNames:l}=n;if(s("fieldNames")&&(l=jy(r.fieldNames),o.fieldNames=l),s("treeData")?{treeData:a}=r:s("children")&&(Vn(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),a=Fue(r.children)),a){o.treeData=a;const u=T4(a,{fieldNames:l});o.keyEntities={[nm]:$de,...u.keyEntities}}const c=o.keyEntities||n.keyEntities;if(s("expandedKeys")||i&&s("autoExpandParent"))o.expandedKeys=r.autoExpandParent||!i&&r.defaultExpandParent?vG(r.expandedKeys,c):r.expandedKeys;else if(!i&&r.defaultExpandAll){const u={...c};delete u[nm];const d=[];Object.keys(u).forEach(h=>{const p=u[h];p.children&&p.children.length&&d.push(p.key)}),o.expandedKeys=d}else!i&&r.defaultExpandedKeys&&(o.expandedKeys=r.autoExpandParent||r.defaultExpandParent?vG(r.defaultExpandedKeys,c):r.defaultExpandedKeys);if(o.expandedKeys||delete o.expandedKeys,a||o.expandedKeys){const u=nO(a||n.treeData,o.expandedKeys||n.expandedKeys,l);o.flattenNodes=u}if(r.selectable&&(s("selectedKeys")?o.selectedKeys=FX(r.selectedKeys,r):!i&&r.defaultSelectedKeys&&(o.selectedKeys=FX(r.defaultSelectedKeys,r))),r.checkable){let u;if(s("checkedKeys")?u=pO(r.checkedKeys)||{}:!i&&r.defaultCheckedKeys?u=pO(r.defaultCheckedKeys)||{}:a&&(u=pO(r.checkedKeys)||{checkedKeys:n.checkedKeys,halfCheckedKeys:n.halfCheckedKeys}),u){let{checkedKeys:d=[],halfCheckedKeys:h=[]}=u;r.checkStrictly||({checkedKeys:d,halfCheckedKeys:h}=wy(d,!0,c)),o.checkedKeys=d,o.halfCheckedKeys=h}}return s("loadedKeys")&&(o.loadedKeys=r.loadedKeys),o}resetDragState(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}render(){const{flattenNodes:r,keyEntities:n,draggingNodeKey:i,dropLevelOffset:o,dropContainerKey:s,dropTargetKey:a,dropPosition:l,dragOverNodeKey:c,indent:u}=this.state,{prefixCls:d,className:h,style:p,styles:f,classNames:g,showLine:m,focusable:v,tabIndex:b=0,selectable:S,showIcon:x,icon:E,switcherIcon:R,draggable:T,checkable:M,checkStrictly:D,disabled:A,motion:I,loadData:L,filterTreeNode:F,height:k,itemHeight:O,scrollWidth:B,virtual:H,titleRender:N,dropIndicatorRender:z,onContextMenu:W,onScroll:V,direction:$,rootClassName:K,rootStyle:q}=this.props,X=ai(this.props,{aria:!0,data:!0});let Y;T&&(typeof T=="object"?Y=T:typeof T=="function"?Y={nodeDraggable:T}:Y={});const oe={styles:f,classNames:g,prefixCls:d,selectable:S,showIcon:x,icon:E,switcherIcon:R,draggable:Y,draggingNodeKey:i,checkable:M,checkStrictly:D,disabled:A,keyEntities:n,dropLevelOffset:o,dropContainerKey:s,dropTargetKey:a,dropPosition:l,dragOverNodeKey:c,indent:u,direction:$,dropIndicatorRender:z,loadData:L,filterTreeNode:F,titleRender:N,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop};return y.createElement(k4.Provider,{value:oe},y.createElement("div",{className:Q(d,h,K,{[`${d}-show-line`]:m}),style:q},y.createElement(R4e,xG({ref:this.listRef,prefixCls:d,style:p,data:r,disabled:A,selectable:S,checkable:!!M,motion:I,dragging:i!==null,height:k,itemHeight:O,virtual:H,focusable:v,tabIndex:b,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:W,onScroll:V,scrollWidth:B},this.getTreeNodeRequiredProps(),X))))}},Ie(JR,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:w4e,allowDrop:()=>!0,expandAction:!1}),Ie(JR,"TreeNode",F0),JR);var I4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494z"}}]},name:"file",theme:"outlined"};function EG(){return EG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,EG({},e,{ref:t,icon:I4e})),Gde=y.forwardRef(D4e);var A4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 444H820V330.4c0-17.7-14.3-32-32-32H473L355.7 186.2a8.15 8.15 0 00-5.5-2.2H96c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h698c13 0 24.8-7.9 29.7-20l134-332c1.5-3.8 2.3-7.9 2.3-12 0-17.7-14.3-32-32-32zM136 256h188.5l119.6 114.4H748V444H238c-13 0-24.8 7.9-29.7 20L136 643.2V256zm635.3 512H159l103.3-256h612.4L771.3 768z"}}]},name:"folder-open",theme:"outlined"};function TG(){return TG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,TG({},e,{ref:t,icon:A4e})),L4e=y.forwardRef(F4e);var _4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 298.4H521L403.7 186.2a8.15 8.15 0 00-5.5-2.2H144c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V330.4c0-17.7-14.3-32-32-32zM840 768H184V256h188.5l119.6 114.4H840V768z"}}]},name:"folder",theme:"outlined"};function RG(){return RG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,RG({},e,{ref:t,icon:_4e})),k4e=y.forwardRef(O4e);var N4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M300 276.5a56 56 0 1056-97 56 56 0 00-56 97zm0 284a56 56 0 1056-97 56 56 0 00-56 97zM640 228a56 56 0 10112 0 56 56 0 00-112 0zm0 284a56 56 0 10112 0 56 56 0 00-112 0zM300 844.5a56 56 0 1056-97 56 56 0 00-56 97zM640 796a56 56 0 10112 0 56 56 0 00-112 0z"}}]},name:"holder",theme:"outlined"};function PG(){return PG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,PG({},e,{ref:t,icon:N4e})),$4e=y.forwardRef(B4e),G4e=({treeCls:e,treeNodeCls:t,directoryNodeSelectedBg:r,directoryNodeSelectedColor:n,motionDurationMid:i,borderRadius:o,controlItemBgHover:s})=>({[`${e}${e}-directory ${t}`]:{[`${e}-node-content-wrapper`]:{position:"static",[`&:has(${e}-drop-indicator)`]:{position:"relative"},[`> *:not(${e}-drop-indicator)`]:{position:"relative"},"&:hover":{background:"transparent"},"&:before":{position:"absolute",inset:0,transition:`background-color ${i}`,content:'""',borderRadius:o},"&:hover:before":{background:s}},[`${e}-switcher, ${e}-checkbox, ${e}-draggable-icon`]:{zIndex:1},"&-selected":{background:r,borderRadius:o,[`${e}-switcher, ${e}-draggable-icon`]:{color:n},[`${e}-node-content-wrapper`]:{color:n,background:"transparent","&, &:hover":{color:n},"&:before, &:hover:before":{background:r}}}}}),V4e=new qr("ant-tree-node-fx-do-not-use",{"0%":{opacity:0},"100%":{opacity:1}}),z4e=(e,t)=>({[`.${e}-switcher-icon`]:{display:"inline-block",fontSize:10,verticalAlign:"baseline",svg:{transition:`transform ${t.motionDurationSlow}`}}}),H4e=(e,t)=>({[`.${e}-drop-indicator`]:{position:"absolute",zIndex:1,height:2,backgroundColor:t.colorPrimary,borderRadius:1,pointerEvents:"none","&:after":{position:"absolute",top:-3,insetInlineStart:-6,width:8,height:8,backgroundColor:"transparent",border:`${ae(t.lineWidthBold)} solid ${t.colorPrimary}`,borderRadius:"50%",content:'""'}}}),W4e=(e,t)=>{const{treeCls:r,treeNodeCls:n,treeNodePadding:i,titleHeight:o,indentSize:s,switcherSize:a,motionDurationMid:l,nodeSelectedBg:c,nodeHoverBg:u,colorTextQuaternary:d,controlItemBgActiveDisabled:h}=t;return{[r]:{...on(t),"--rc-virtual-list-scrollbar-bg":t.colorSplit,background:t.colorBgContainer,borderRadius:t.borderRadius,transition:`background-color ${t.motionDurationSlow}`,"&-rtl":{direction:"rtl"},[`&${r}-rtl ${r}-switcher_close ${r}-switcher-icon svg`]:{transform:"rotate(90deg)"},[`${r}-list`]:{"&:focus-visible":{outline:"none",[`${n}-active ${r}-node-content-wrapper`]:{...gc(t)}}},[`${r}-list-holder-inner`]:{alignItems:"flex-start"},[`&${r}-block-node`]:{[`${r}-list-holder-inner`]:{alignItems:"stretch",[`${r}-node-content-wrapper`]:{flex:"auto"},[`${n}.dragging:after`]:{position:"absolute",inset:0,border:`1px solid ${t.colorPrimary}`,opacity:0,animationName:V4e,animationDuration:t.motionDurationSlow,animationPlayState:"running",animationFillMode:"forwards",content:'""',pointerEvents:"none",borderRadius:t.borderRadius}}},[n]:{display:"flex",alignItems:"flex-start",marginBottom:i,lineHeight:ae(o),position:"relative","&:before":{content:'""',position:"absolute",zIndex:1,insetInlineStart:0,width:"100%",top:"100%",height:i},[`&-disabled ${r}-node-content-wrapper`]:{color:t.colorTextDisabled,cursor:"not-allowed","&:hover":{background:"transparent"}},[`${r}-checkbox-disabled + ${r}-node-selected,&${n}-disabled${n}-selected ${r}-node-content-wrapper`]:{backgroundColor:h},[`${r}-checkbox-disabled`]:{pointerEvents:"unset"},[`&:not(${n}-disabled)`]:{[`${r}-node-content-wrapper`]:{"&:hover":{color:t.nodeHoverColor}}},[`&-active ${r}-node-content-wrapper`]:{background:t.controlItemBgHover},[`&:not(${n}-disabled).filter-node ${r}-title`]:{color:t.colorPrimary,fontWeight:t.fontWeightStrong},"&-draggable":{cursor:"grab",[`${r}-draggable-icon`]:{flexShrink:0,width:a,textAlign:"center",visibility:"visible",color:d},[`&${n}-disabled ${r}-draggable-icon`]:{visibility:"hidden"}}},[`${r}-indent`]:{alignSelf:"stretch",whiteSpace:"nowrap",userSelect:"none","&-unit":{display:"inline-block",width:s}},[`${r}-draggable-icon`]:{visibility:"hidden"},[`${r}-switcher, ${r}-checkbox`]:{marginInlineEnd:t.calc(t.calc(a).sub(t.controlInteractiveSize)).div(2).equal()},[`${r}-checkbox`]:{flexShrink:0},[`${r}-switcher`]:{...z4e(e,t),position:"relative",flex:"none",alignSelf:"stretch",width:a,textAlign:"center",cursor:"pointer",userSelect:"none",transition:`all ${t.motionDurationSlow}`,"&-noop":{cursor:"unset"},"&:before":{pointerEvents:"none",content:'""',width:a,height:o,position:"absolute",left:{_skip_check_:!0,value:0},top:0,borderRadius:t.borderRadius,transition:`all ${t.motionDurationSlow}`},[`&:not(${r}-switcher-noop):hover:before`]:{backgroundColor:t.colorBgTextHover},[`&_close ${r}-switcher-icon svg`]:{transform:"rotate(-90deg)"},"&-loading-icon":{color:t.colorPrimary},"&-leaf-line":{position:"relative",zIndex:1,display:"inline-block",width:"100%",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:t.calc(a).div(2).equal(),bottom:t.calc(i).mul(-1).equal(),marginInlineStart:-1,borderInlineEnd:`1px solid ${t.colorBorder}`,content:'""'},"&:after":{position:"absolute",width:t.calc(t.calc(a).div(2).equal()).mul(.8).equal(),height:t.calc(o).div(2).equal(),borderBottom:`1px solid ${t.colorBorder}`,content:'""'}}},[`${r}-node-content-wrapper`]:{position:"relative",minHeight:o,paddingBlock:0,paddingInline:t.paddingXS,background:"transparent",borderRadius:t.borderRadius,cursor:"pointer",transition:[`all ${l}`,"border 0s","line-height 0s","box-shadow 0s"].join(", "),...H4e(e,t),"&:hover":{backgroundColor:u},[`&${r}-node-selected`]:{color:t.nodeSelectedColor,backgroundColor:c},[`${r}-iconEle`]:{display:"inline-block",width:a,height:o,textAlign:"center",verticalAlign:"top","&:empty":{display:"none"}}},[`${r}-unselectable ${r}-node-content-wrapper:hover`]:{backgroundColor:"transparent"},[`${n}.drop-container > [draggable]`]:{boxShadow:`0 0 0 2px ${t.colorPrimary}`},"&-show-line":{[`${r}-indent-unit`]:{position:"relative",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:t.calc(a).div(2).equal(),bottom:t.calc(i).mul(-1).equal(),borderInlineEnd:`1px solid ${t.colorBorder}`,content:'""'},"&-end:before":{display:"none"}},[`${r}-switcher`]:{background:"transparent","&-line-icon":{verticalAlign:"-0.15em"}}},[`${n}-leaf-last ${r}-switcher-leaf-line:before`]:{top:"auto !important",bottom:"auto !important",height:`${ae(t.calc(o).div(2).equal())} !important`}}}},U4e=(e,t,r=!0)=>{const n=`.${e}`,i=`${n}-treenode`,o=t.calc(t.paddingXS).div(2).equal(),s=$r(t,{treeCls:n,treeNodeCls:i,treeNodePadding:o});return[W4e(e,s),r&&G4e(s)].filter(Boolean)},j4e=e=>{const{controlHeightSM:t,controlItemBgHover:r,controlItemBgActive:n}=e,i=t;return{titleHeight:i,switcherSize:i,indentSize:i,nodeHoverBg:r,nodeHoverColor:e.colorText,nodeSelectedBg:n,nodeSelectedColor:e.colorText}},K4e=e=>{const{colorTextLightSolid:t,colorPrimary:r}=e;return{...j4e(e),directoryNodeSelectedColor:t,directoryNodeSelectedBg:r}},q4e=Wr("Tree",(e,{prefixCls:t})=>[{[e.componentCls]:Oue(`${t}-checkbox`,e)},U4e(t,e),V3(e)],K4e),BX=4;function X4e(e){const{dropPosition:t,dropLevelOffset:r,prefixCls:n,indent:i,direction:o="ltr"}=e,s=o==="ltr"?"left":"right",a=o==="ltr"?"right":"left",l={[s]:-r*i+BX,[a]:0};switch(t){case-1:l.top=-3;break;case 1:l.bottom=-3;break;default:l.bottom=-3,l[s]=i+BX;break}return Z.createElement("div",{style:l,className:`${n}-drop-indicator`})}var Y4e={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"filled"};function MG(){return MG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,MG({},e,{ref:t,icon:Y4e})),Q4e=y.forwardRef(Z4e);var J4e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"minus-square",theme:"outlined"};function IG(){return IG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,IG({},e,{ref:t,icon:J4e})),t5e=y.forwardRef(e5e);var r5e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"plus-square",theme:"outlined"};function DG(){return DG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,DG({},e,{ref:t,icon:r5e})),i5e=y.forwardRef(n5e),o5e=e=>{var h,p;const{prefixCls:t,switcherIcon:r,treeNodeProps:n,showLine:i,switcherLoadingIcon:o}=e,{isLeaf:s,expanded:a,loading:l}=n;if(l)return y.isValidElement(o)?o:y.createElement(rm,{className:`${t}-switcher-loading-icon`});let c;if(i&&typeof i=="object"&&(c=i.showLeafIcon),s){if(!i)return null;if(typeof c!="boolean"&&c){const f=typeof c=="function"?c(n):c,g=`${t}-switcher-line-custom-icon`;return y.isValidElement(f)?Ei(f,{className:Q((h=f.props)==null?void 0:h.className,g)}):f}return c?y.createElement(Gde,{className:`${t}-switcher-line-icon`}):y.createElement("span",{className:`${t}-switcher-leaf-line`})}const u=`${t}-switcher-icon`,d=typeof r=="function"?r(n):r;return y.isValidElement(d)?Ei(d,{className:Q((p=d.props)==null?void 0:p.className,u)}):d!==void 0?d:i?a?y.createElement(t5e,{className:`${t}-switcher-line-icon`}):y.createElement(i5e,{className:`${t}-switcher-line-icon`}):y.createElement(Q4e,{className:u})},Vde=Z.forwardRef((e,t)=>{var X;const{getPrefixCls:r,direction:n,className:i,style:o,classNames:s,styles:a}=Nr("tree"),{virtual:l}=Z.useContext(ir),{prefixCls:c,className:u,showIcon:d=!1,showLine:h,switcherIcon:p,switcherLoadingIcon:f,blockNode:g=!1,children:m,checkable:v=!1,selectable:b=!0,draggable:S,disabled:x,motion:E,style:R,rootClassName:T,classNames:M,styles:D}=e,A=Z.useContext(hs),I=x??A,L=r("tree",c),F=r(),k=E??{...B3(F),motionAppear:!1},O={...e,showIcon:d,blockNode:g,checkable:v,selectable:b,disabled:I,motion:k},[B,H]=Vr([s,M],[a,D],{props:O}),N={...O,showLine:!!h,dropIndicatorRender:X4e},[z,W]=q4e(L),[,V]=fs(),$=V.paddingXS/2+(((X=V.Tree)==null?void 0:X.titleHeight)||V.controlHeightSM),K=Z.useMemo(()=>{if(!S)return!1;let Y={};switch(typeof S){case"function":Y.nodeDraggable=S;break;case"object":Y={...S};break}return Y.icon!==!1&&(Y.icon=Y.icon||Z.createElement($4e,null)),Y},[S]),q=Y=>Z.createElement(o5e,{prefixCls:L,switcherIcon:p,switcherLoadingIcon:f,treeNodeProps:Y,showLine:h});return Z.createElement(M4e,{itemHeight:$,ref:t,virtual:l,...N,prefixCls:L,className:Q({[`${L}-icon-hide`]:!d,[`${L}-block-node`]:g,[`${L}-unselectable`]:!b,[`${L}-rtl`]:n==="rtl",[`${L}-disabled`]:I},i,u,z,W),style:{...o,...R},rootClassName:Q(B==null?void 0:B.root,T),rootStyle:H==null?void 0:H.root,classNames:B,styles:H,direction:n,checkable:v&&Z.createElement("span",{className:`${L}-checkbox-inner`}),selectable:b,switcherIcon:q,draggable:K},m)}),$X=0,fO=1,GX=2;function B4(e,t,r){const{key:n,children:i}=r;function o(s){const a=s[n],l=s[i];t(a,s)!==!1&&B4(l||[],t,r)}e.forEach(o)}function s5e({treeData:e,expandedKeys:t,startKey:r,endKey:n,fieldNames:i}){const o=[];let s=$X;if(r&&r===n)return[r];if(!r||!n)return[];function a(l){return l===r||l===n}return B4(e,l=>{if(s===GX)return!1;if(a(l)){if(o.push(l),s===$X)s=fO;else if(s===fO)return s=GX,!1}else s===fO&&o.push(l);return t.includes(l)},jy(i)),o}function gO(e,t,r){const n=Pr(t),i=[];return B4(e,(o,s)=>{const a=n.indexOf(o);return a!==-1&&(i.push(s),n.splice(a,1)),!!n.length},jy(r)),i}function a5e(e){const{isLeaf:t,expanded:r}=e;return t?y.createElement(Gde,null):r?y.createElement(L4e,null):y.createElement(k4e,null)}function VX({treeData:e,children:t}){return e||Fue(t)}const l5e=y.forwardRef((e,t)=>{const{defaultExpandAll:r,defaultExpandParent:n,defaultExpandedKeys:i,...o}=e,s=y.useRef(null),a=y.useRef(null),l=()=>{const{keyEntities:M}=T4(VX(o),{fieldNames:o.fieldNames});let D;const A=o.expandedKeys||i||[];return r?D=Object.keys(M):n?D=vG(A,M):D=A,D},[c,u]=y.useState(o.selectedKeys||o.defaultSelectedKeys||[]),[d,h]=y.useState(()=>l());y.useEffect(()=>{"selectedKeys"in o&&u(o.selectedKeys)},[o.selectedKeys]),y.useEffect(()=>{"expandedKeys"in o&&h(o.expandedKeys)},[o.expandedKeys]);const p=(M,D)=>{var A;return"expandedKeys"in o||h(M),(A=o.onExpand)==null?void 0:A.call(o,M,D)},f=(M,D)=>{var W;const{multiple:A,fieldNames:I}=o,{node:L,nativeEvent:F}=D,{key:k=""}=L,O=VX(o),B={...D,selected:!0},H=(F==null?void 0:F.ctrlKey)||(F==null?void 0:F.metaKey),N=F==null?void 0:F.shiftKey;let z;A&&H?(z=M,s.current=k,a.current=z,B.selectedNodes=gO(O,z,I)):A&&N?(z=Array.from(new Set([].concat(Pr(a.current||[]),Pr(s5e({treeData:O,expandedKeys:d,startKey:k,endKey:s.current,fieldNames:I}))))),B.selectedNodes=gO(O,z,I)):(z=[k],s.current=k,a.current=z,B.selectedNodes=gO(O,z,I)),(W=o.onSelect)==null||W.call(o,z,B),"selectedKeys"in o||u(z)},{getPrefixCls:g,direction:m}=y.useContext(ir),{prefixCls:v,className:b,showIcon:S=!0,expandAction:x="click",...E}=o,R=g("tree",v),T=Q(`${R}-directory`,{[`${R}-directory-rtl`]:m==="rtl"},b);return y.createElement(Vde,{icon:a5e,ref:t,blockNode:!0,...E,showIcon:S,expandAction:x,prefixCls:R,className:T,expandedKeys:d,selectedKeys:c,onSelect:f,onExpand:p})}),$4=Vde;$4.DirectoryTree=l5e;$4.TreeNode=F0;const zde=Z.createContext(!1),zX=e=>{const{value:t,filterSearch:r,tablePrefixCls:n,locale:i,onChange:o}=e;return r?y.createElement("div",{className:`${n}-filter-dropdown-search`},y.createElement(Qx,{prefix:y.createElement(a4,null),placeholder:i.filterSearchPlaceholder,onChange:o,value:t,htmlSize:1,className:`${n}-filter-dropdown-search-input`})):null},c5e=e=>{const{keyCode:t}=e;t===Zt.ENTER&&e.stopPropagation()},u5e=y.forwardRef((e,t)=>y.createElement("div",{className:e.className,onClick:r=>r.stopPropagation(),onKeyDown:c5e,ref:t},e.children));function xy(e){let t=[];return(e||[]).forEach(({value:r,children:n})=>{t.push(r),n&&(t=[].concat(Pr(t),Pr(xy(n))))}),t}function d5e(e){return e.some(({children:t})=>t)}function Hde(e,t){return typeof t=="string"||typeof t=="number"?t==null?void 0:t.toString().toLowerCase().includes(e.trim().toLowerCase()):!1}function Wde({filters:e,prefixCls:t,filteredKeys:r,filterMultiple:n,searchValue:i,filterSearch:o}){return e.map((s,a)=>{const l=String(s.value);if(s.children)return{key:l||a,label:s.text,popupClassName:`${t}-dropdown-submenu`,children:Wde({filters:s.children,prefixCls:t,filteredKeys:r,filterMultiple:n,searchValue:i,filterSearch:o})};const c=n?Ky:Yx,u={key:s.value!==void 0?l:a,label:y.createElement(y.Fragment,null,y.createElement(c,{checked:r.includes(l)}),y.createElement("span",null,s.text))};return i.trim()?typeof o=="function"?o(i,s)?u:null:Hde(i,s.text)?u:null:u})}function mO(e){return e||[]}const h5e=e=>{var ve;const{tablePrefixCls:t,prefixCls:r,column:n,dropdownPrefixCls:i,columnKey:o,filterOnClose:s,filterMultiple:a,filterMode:l="menu",filterSearch:c=!1,filterState:u,triggerFilter:d,locale:h,children:p,getPopupContainer:f,rootClassName:g}=e,{filterResetToDefaultFilteredValue:m,defaultFilteredValue:v,filterDropdownProps:b={},filterDropdownOpen:S,onFilterDropdownOpenChange:x}=n,[E,R]=y.useState(!1),T=y.useContext(zde),M=!!(u&&((ve=u.filteredKeys)!=null&&ve.length||u.forceFiltered)),D=pe=>{var me;R(pe),(me=b.onOpenChange)==null||me.call(b,pe),x==null||x(pe)},A=b.open??S??E,I=u==null?void 0:u.filteredKeys,[L,F]=hFe(mO(I)),k=({selectedKeys:pe})=>{F(pe)},O=(pe,{node:me,checked:ke})=>{k(a?{selectedKeys:pe}:{selectedKeys:ke&&me.key?[me.key]:[]})};y.useEffect(()=>{E&&k({selectedKeys:mO(I)})},[I]);const[B,H]=y.useState([]),N=pe=>{H(pe)},[z,W]=y.useState(""),V=pe=>{const{value:me}=pe.target;W(me)};y.useEffect(()=>{E||W("")},[E]);const $=pe=>{const me=pe!=null&&pe.length?pe:null;if(me===null&&(!u||!u.filteredKeys)||fc(me,u==null?void 0:u.filteredKeys,!0))return null;d({column:n,key:o,filteredKeys:me})},K=()=>{D(!1),$(L())},q=({confirm:pe,closeDropdown:me}={confirm:!1,closeDropdown:!1})=>{pe&&$([]),me&&D(!1),W(""),F(m?(v||[]).map(String):[])},X=({closeDropdown:pe}={closeDropdown:!0})=>{pe&&D(!1),$(L())},Y=(pe,me)=>{me.source==="trigger"&&(pe&&I!==void 0&&F(mO(I)),D(pe),!pe&&!n.filterDropdown&&s&&K())},oe=Q({[`${i}-menu-without-submenu`]:!d5e(n.filters||[])}),ee=pe=>{if(pe.target.checked){const me=xy(n==null?void 0:n.filters).map(String);F(me)}else F([])},ne=({filters:pe})=>(pe||[]).map((me,ke)=>{const De=String(me.value),Ee={title:me.text,key:me.value!==void 0?De:String(ke)};return me.children&&(Ee.children=ne({filters:me.children})),Ee}),le=pe=>{var me;return{...pe,text:pe.title,value:pe.key,children:((me=pe.children)==null?void 0:me.map(le))||[]}};let he;const{direction:re,renderEmpty:ie}=y.useContext(ir);if(typeof n.filterDropdown=="function")he=n.filterDropdown({prefixCls:`${i}-custom`,setSelectedKeys:pe=>k({selectedKeys:pe}),selectedKeys:L(),confirm:X,clearFilters:q,filters:n.filters,visible:A,close:()=>{D(!1)}});else if(n.filterDropdown)he=n.filterDropdown;else{const pe=L()||[],me=()=>{const De=(ie==null?void 0:ie("Table.filter"))??y.createElement(ad,{image:ad.PRESENTED_IMAGE_SIMPLE,description:h.filterEmptyText,styles:{image:{height:24}},style:{margin:0,padding:"16px 0"}});if((n.filters||[]).length===0)return De;if(l==="tree")return y.createElement(y.Fragment,null,y.createElement(zX,{filterSearch:c,value:z,onChange:V,tablePrefixCls:t,locale:h}),y.createElement("div",{className:`${t}-filter-dropdown-tree`},a?y.createElement(Ky,{checked:pe.length===xy(n.filters).length,indeterminate:pe.length>0&&pe.lengthtypeof c=="function"?c(z,le(ze)):Hde(z,ze.title):void 0})));const Ee=Wde({filters:n.filters||[],filterSearch:c,prefixCls:r,filteredKeys:L(),filterMultiple:a,searchValue:z}),We=Ee.every(ze=>ze===null);return y.createElement(y.Fragment,null,y.createElement(zX,{filterSearch:c,value:z,onChange:V,tablePrefixCls:t,locale:h}),We?De:y.createElement(LC,{selectable:!0,multiple:a,prefixCls:`${i}-menu`,className:oe,onSelect:k,onDeselect:k,selectedKeys:pe,getPopupContainer:f,openKeys:B,onOpenChange:N,items:Ee}))},ke=()=>m?fc((v||[]).map(String),pe,!0):pe.length===0;he=y.createElement(y.Fragment,null,me(),y.createElement("div",{className:`${r}-dropdown-btns`},y.createElement(ca,{type:"link",size:"small",disabled:ke(),onClick:()=>q()},h.filterReset),y.createElement(ca,{type:"primary",size:"small",onClick:K},h.filterConfirm)))}n.filterDropdown&&(he=y.createElement(iue,{selectable:void 0},he)),he=y.createElement(u5e,{className:`${r}-dropdown`},he);const J=(()=>{let pe;return typeof n.filterIcon=="function"?pe=n.filterIcon(M):n.filterIcon?pe=n.filterIcon:pe=y.createElement(S4e,null),y.createElement("span",{role:"button",tabIndex:-1,className:Q(`${r}-trigger`,{active:M}),onClick:me=>{me.stopPropagation()}},pe)})();if(T)return y.createElement("div",{className:`${r}-column`},y.createElement("span",{className:`${t}-column-title`},p),J);const ue=R0({trigger:["click"],placement:re==="rtl"?"bottomLeft":"bottomRight",children:J,getPopupContainer:f},{...b,rootClassName:Q(g,b.rootClassName),open:A,onOpenChange:Y,popupRender:()=>typeof(b==null?void 0:b.dropdownRender)=="function"?b.dropdownRender(he):he});return y.createElement("div",{className:`${r}-column`},y.createElement("span",{className:`${t}-column-title`},p),y.createElement(I4,{...ue}))},AG=(e,t,r)=>{let n=[];return(e||[]).forEach((i,o)=>{const s=GC(o,r),a=i.filterDropdown!==void 0;if(i.filters||a||"onFilter"in i)if("filteredValue"in i){let l=i.filteredValue;a||(l=(l==null?void 0:l.map(String))??l),n.push({column:i,key:Pp(i,s),filteredKeys:l,forceFiltered:i.filtered})}else n.push({column:i,key:Pp(i,s),filteredKeys:t&&i.defaultFilteredValue?i.defaultFilteredValue:void 0,forceFiltered:i.filtered});"children"in i&&(n=[].concat(Pr(n),Pr(AG(i.children,t,s))))}),n};function Ude(e,t,r,n,i,o,s,a,l){return r.map((c,u)=>{const d=GC(u,a),{filterOnClose:h=!0,filterMultiple:p=!0,filterMode:f,filterSearch:g}=c;let m=c;if(m.filters||m.filterDropdown){const v=Pp(m,d),b=n.find(({key:S})=>v===S);m={...m,title:S=>y.createElement(h5e,{tablePrefixCls:e,prefixCls:`${e}-filter`,dropdownPrefixCls:t,column:m,columnKey:v,filterState:b,filterOnClose:h,filterMultiple:p,filterMode:f,filterSearch:g,triggerFilter:o,locale:i,getPopupContainer:s,rootClassName:l},lA(c.title,S))}}return"children"in m&&(m={...m,children:Ude(e,t,m.children,n,i,o,s,d,l)}),m})}const HX=e=>{const t={};return e.forEach(({key:r,filteredKeys:n,column:i})=>{const o=r,{filters:s,filterDropdown:a}=i;if(a)t[o]=n||null;else if(Array.isArray(n)){const l=xy(s);t[o]=l.filter(c=>n.includes(String(c)))}else t[o]=null}),t},FG=(e,t,r)=>t.reduce((i,o)=>{const{column:{onFilter:s,filters:a},filteredKeys:l}=o;return s&&l&&l.length?i.map(c=>({...c})).filter(c=>l.some(u=>{const d=xy(a),h=d.findIndex(f=>String(f)===String(u)),p=h!==-1?d[h]:u;return c[r]&&(c[r]=FG(c[r],t,r)),s(p,c)})):i},e),jde=e=>e.flatMap(t=>"children"in t?[t].concat(Pr(jde(t.children||[]))):[t]),p5e=e=>{const{prefixCls:t,dropdownPrefixCls:r,mergedColumns:n,onFilterChange:i,getPopupContainer:o,locale:s,rootClassName:a}=e;MC();const l=y.useMemo(()=>jde(n||[]),[n]),[c,u]=y.useState(()=>AG(l,!0)),d=y.useMemo(()=>{const g=AG(l,!1);if(g.length===0)return g;let m=!0;if(g.forEach(({filteredKeys:v})=>{v!==void 0&&(m=!1)}),m){const v=(l||[]).map((b,S)=>Pp(b,GC(S)));return c.filter(({key:b})=>v.includes(b)).map(b=>{const S=l[v.indexOf(b.key)];return{...b,column:{...b.column,...S},forceFiltered:S.filtered}})}return g},[l,c]),h=y.useMemo(()=>HX(d),[d]),p=g=>{const m=d.filter(({key:v})=>v!==g.key);m.push(g),u(m),i(HX(m),m)};return[g=>Ude(t,r,g,d,s,p,o,void 0,a),d,h]},f5e=(e,t,r)=>{const n=y.useRef({});function i(o){var s;if(!n.current||n.current.data!==e||n.current.childrenColumnName!==t||n.current.getRowKey!==r){let l=function(c){c.forEach((u,d)=>{const h=r(u,d);a.set(h,u),u&&typeof u=="object"&&t in u&&l(u[t]||[])})};const a=new Map;l(e),n.current={data:e,childrenColumnName:t,kvMap:a,getRowKey:r}}return(s=n.current.kvMap)==null?void 0:s.get(o)}return[i]},Kde=10;function g5e(e,t){const r={current:e.current,pageSize:e.pageSize};return Object.keys(t&&typeof t=="object"?t:{}).forEach(i=>{const o=e[i];typeof o!="function"&&(r[i]=o)}),r}function m5e(e,t,r){const{total:n=0,...i}=r&&typeof r=="object"?r:{},[o,s]=y.useState(()=>({current:"defaultCurrent"in i?i.defaultCurrent:1,pageSize:"defaultPageSize"in i?i.defaultPageSize:Kde})),a=R0(o,i,{total:n>0?n:e}),l=Math.ceil((n||e)/a.pageSize);a.current>l&&(a.current=l||1);const c=(d,h)=>{s({current:d??1,pageSize:h||a.pageSize})},u=(d,h)=>{var p;r&&((p=r.onChange)==null||p.call(r,d,h)),c(d,h),t(d,h||(a==null?void 0:a.pageSize))};return r===!1?[{},()=>{}]:[{...a,onChange:u},c]}var v5e={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"outlined"};function LG(){return LG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,LG({},e,{ref:t,icon:v5e})),C5e=y.forwardRef(y5e);var b5e={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M858.9 689L530.5 308.2c-9.4-10.9-27.5-10.9-37 0L165.1 689c-12.2 14.2-1.2 35 18.5 35h656.8c19.7 0 30.7-20.8 18.5-35z"}}]},name:"caret-up",theme:"outlined"};function _G(){return _G=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,_G({},e,{ref:t,icon:b5e})),w5e=y.forwardRef(S5e),mP="ascend",vO="descend",LM=e=>typeof e.sorter=="object"&&typeof e.sorter.multiple=="number"?e.sorter.multiple:!1,WX=e=>typeof e=="function"?e:e&&typeof e=="object"&&e.compare?e.compare:!1,x5e=(e,t)=>t?e[e.indexOf(t)+1]:e[0],OG=(e,t,r)=>{let n=[];const i=(o,s)=>{n.push({column:o,key:Pp(o,s),multiplePriority:LM(o),sortOrder:o.sortOrder})};return(e||[]).forEach((o,s)=>{const a=GC(s,r);o.children?("sortOrder"in o&&i(o,a),n=[].concat(Pr(n),Pr(OG(o.children,t,a)))):o.sorter&&("sortOrder"in o?i(o,a):t&&o.defaultSortOrder&&n.push({column:o,key:Pp(o,a),multiplePriority:LM(o),sortOrder:o.defaultSortOrder}))}),n},qde=(e,t,r,n,i,o,s,a,l)=>(t||[]).map((u,d)=>{const h=GC(d,a);let p=u;if(p.sorter){const f=p.sortDirections||i,g=p.showSorterTooltip===void 0?s:p.showSorterTooltip,m=Pp(p,h),v=r.find(({key:A})=>A===m),b=v?v.sortOrder:null,S=x5e(f,b);let x;if(u.sortIcon)x=u.sortIcon({sortOrder:b});else{const A=f.includes(mP)&&y.createElement(w5e,{className:Q(`${e}-column-sorter-up`,{active:b===mP})}),I=f.includes(vO)&&y.createElement(C5e,{className:Q(`${e}-column-sorter-down`,{active:b===vO})});x=y.createElement("span",{className:Q(`${e}-column-sorter`,{[`${e}-column-sorter-full`]:!!(A&&I)})},y.createElement("span",{className:`${e}-column-sorter-inner`,"aria-hidden":"true"},A,I))}const{cancelSort:E,triggerAsc:R,triggerDesc:T}=o||{};let M=E;S===vO?M=T:S===mP&&(M=R);const D=typeof g=="object"?{title:M,...g}:{title:M};p={...p,className:Q(p.className,{[`${e}-column-sort`]:b}),title:A=>{const I=`${e}-column-sorters`,L=y.createElement("span",{className:`${e}-column-title`},lA(u.title,A)),F=y.createElement("div",{className:I},L,x);return g?typeof g!="boolean"&&(g==null?void 0:g.target)==="sorter-icon"?y.createElement("div",{className:Q(I,`${I}-tooltip-target-sorter`)},L,y.createElement(El,{...D},x)):y.createElement(El,{...D},F):F},onHeaderCell:A=>{var B;const I=((B=u.onHeaderCell)==null?void 0:B.call(u,A))||{},L=I.onClick,F=I.onKeyDown;I.onClick=H=>{n({column:u,key:m,sortOrder:S,multiplePriority:LM(u)}),L==null||L(H)},I.onKeyDown=H=>{H.keyCode===Zt.ENTER&&(n({column:u,key:m,sortOrder:S,multiplePriority:LM(u)}),F==null||F(H))};const k=y4e(u.title,{}),O=k==null?void 0:k.toString();return b&&(I["aria-sort"]=b==="ascend"?"ascending":"descending"),I["aria-description"]=l==null?void 0:l.sortable,I["aria-label"]=O||"",I.className=Q(I.className,`${e}-column-has-sorters`),I.tabIndex=0,u.ellipsis&&(I.title=(k??"").toString()),I}}}return"children"in p&&(p={...p,children:qde(e,p.children,r,n,i,o,s,h,l)}),p}),UX=e=>{const{column:t,sortOrder:r}=e;return{column:t,order:r,field:t.dataIndex,columnKey:t.key}},jX=e=>{const t=e.filter(({sortOrder:r})=>r).map(UX);if(t.length===0&&e.length){const r=e.length-1;return{...UX(e[r]),column:void 0,order:void 0,field:void 0,columnKey:void 0}}return t.length<=1?t[0]||{}:t},kG=(e,t,r)=>{const n=t.slice().sort((s,a)=>a.multiplePriority-s.multiplePriority),i=e.slice(),o=n.filter(({column:{sorter:s},sortOrder:a})=>WX(s)&&a);return o.length?i.sort((s,a)=>{for(let l=0;l{const a=s[r];return a?{...s,[r]:kG(a,t,r)}:s}):i},E5e=e=>{const{prefixCls:t,mergedColumns:r,sortDirections:n,tableLocale:i,showSorterTooltip:o,onSorterChange:s,globalLocale:a}=e,[l,c]=y.useState(()=>OG(r,!0)),u=(m,v)=>{const b=[];return m.forEach((S,x)=>{const E=GC(x,v);if(b.push(Pp(S,E)),Array.isArray(S.children)){const R=u(S.children,E);b.push.apply(b,Pr(R))}}),b},d=y.useMemo(()=>{let m=!0;const v=OG(r,!1);if(!v.length){const E=u(r);return l.filter(({key:R})=>E.includes(R))}const b=[];function S(E){m?b.push(E):b.push({...E,sortOrder:null})}let x=null;return v.forEach(E=>{x===null?(S(E),E.sortOrder&&(E.multiplePriority===!1?m=!1:x=!0)):(x&&E.multiplePriority!==!1||(m=!1),S(E))}),b},[r,l]),h=y.useMemo(()=>{var v,b;const m=d.map(({column:S,sortOrder:x})=>({column:S,order:x}));return{sortColumns:m,sortColumn:(v=m[0])==null?void 0:v.column,sortOrder:(b=m[0])==null?void 0:b.order}},[d]),p=m=>{let v;m.multiplePriority===!1||!d.length||d[0].multiplePriority===!1?v=[m]:v=[].concat(Pr(d.filter(({key:b})=>b!==m.key)),[m]),c(v),s(jX(v),v)};return[m=>qde(t,m,d,p,n,i,o,void 0,a),d,h,()=>jX(d)]},Xde=(e,t)=>e.map(n=>{const i={...n};return i.title=lA(n.title,t),"children"in i&&(i.children=Xde(i.children,t)),i}),T5e=e=>[y.useCallback(r=>Xde(r,e),[e])],R5e=Ode((e,t)=>{const{_renderTimes:r}=e,{_renderTimes:n}=t;return r!==n}),P5e=Nde((e,t)=>{const{_renderTimes:r}=e,{_renderTimes:n}=t;return r!==n}),M5e=e=>{const{componentCls:t,lineWidth:r,lineType:n,tableBorderColor:i,tableHeaderBg:o,tablePaddingVertical:s,tablePaddingHorizontal:a,calc:l}=e,c=`${ae(r)} ${n} ${i}`,u=(d,h,p)=>({[`&${t}-${d}`]:{[`> ${t}-container`]:{[`> ${t}-content, > ${t}-body`]:{"\n > table > tbody > tr > th,\n > table > tbody > tr > td\n ":{[`> ${t}-expanded-row-fixed`]:{margin:`${ae(l(h).mul(-1).equal())} ${ae(l(l(p).add(r)).mul(-1).equal())}`}}}}}});return{[`${t}-wrapper`]:{[`${t}${t}-bordered`]:{[`> ${t}-title`]:{border:c,borderBottom:0},[`> ${t}-container`]:{borderInlineStart:c,borderTop:c,[` > ${t}-content, > ${t}-header, > ${t}-body, > ${t}-summary `]:{"> table":{"\n > thead > tr > th,\n > thead > tr > td,\n > tbody > tr > th,\n > tbody > tr > td,\n > tfoot > tr > th,\n > tfoot > tr > td\n ":{borderInlineEnd:c},"> thead":{"> tr:not(:last-child) > th":{borderBottom:c},"> tr > th::before":{backgroundColor:"transparent !important"}},"\n > thead > tr,\n > tbody > tr,\n > tfoot > tr\n ":{[`> ${t}-cell-fix-right-first::after`]:{borderInlineEnd:c}},"\n > tbody > tr > th,\n > tbody > tr > td\n ":{[`> ${t}-expanded-row-fixed`]:{margin:`${ae(l(s).mul(-1).equal())} ${ae(l(l(a).add(r)).mul(-1).equal())}`,"&::after":{position:"absolute",top:0,insetInlineEnd:r,bottom:0,borderInlineEnd:c,content:'""'}}}}}},[`&${t}-scroll-horizontal`]:{[`> ${t}-container > ${t}-body`]:{"> table > tbody":{[` > tr${t}-expanded-row, > tr${t}-placeholder `]:{"> th, > td":{borderInlineEnd:0}}}}},...u("medium",e.tablePaddingVerticalMiddle,e.tablePaddingHorizontalMiddle),...u("small",e.tablePaddingVerticalSmall,e.tablePaddingHorizontalSmall),[`> ${t}-footer`]:{border:c,borderTop:0}},[`${t}-cell`]:{[`${t}-container:first-child`]:{borderTop:0},"&-scrollbar:not([rowspan])":{boxShadow:`0 ${ae(r)} 0 ${ae(r)} ${o}`}},[`${t}-bordered ${t}-cell-scrollbar`]:{borderInlineEnd:c}}}},I5e=e=>{const{componentCls:t}=e;return{[`${t}-wrapper`]:{[`${t}-cell-ellipsis`]:{...Ps,wordBreak:"keep-all",[` &${t}-cell-fix-start-shadow, &${t}-cell-fix-end-shadow `]:{overflow:"visible",[`${t}-cell-content`]:{...Ps,display:"block"}},[`${t}-column-title`]:{...Ps,wordBreak:"keep-all"}}}}},D5e=e=>{const{componentCls:t}=e;return{[`${t}-wrapper`]:{[`${t}-tbody > tr${t}-placeholder`]:{textAlign:"center",color:e.colorTextDisabled,"\n &:hover > th,\n &:hover > td,\n ":{background:e.colorBgContainer}}}}},A5e=e=>{const{componentCls:t,antCls:r,motionDurationSlow:n,lineWidth:i,paddingXS:o,lineType:s,tableBorderColor:a,tableExpandIconBg:l,tableExpandColumnWidth:c,borderRadius:u,tablePaddingVertical:d,tablePaddingHorizontal:h,tableExpandedRowBg:p,paddingXXS:f,expandIconMarginTop:g,expandIconSize:m,expandIconHalfInner:v,expandIconScale:b,calc:S}=e,x=`${ae(i)} ${s} ${a}`,E=S(f).sub(i).equal();return{[`${t}-wrapper`]:{[`${t}-expand-icon-col`]:{width:c},[`${t}-row-expand-icon-cell`]:{textAlign:"center",[`${t}-row-expand-icon`]:{display:"inline-flex",float:"none",verticalAlign:"sub"}},[`${t}-row-indent`]:{height:1,float:"left"},[`${t}-row-expand-icon`]:{...D3(e),position:"relative",float:"left",width:m,height:m,color:"inherit",lineHeight:ae(m),background:l,border:x,borderRadius:u,transform:`scale(${b})`,"&:focus, &:hover, &:active":{borderColor:"currentcolor"},"&::before, &::after":{position:"absolute",background:"currentcolor",transition:`transform ${n} ease-out`,content:'""'},"&::before":{top:v,insetInlineEnd:E,insetInlineStart:E,height:i},"&::after":{top:E,bottom:E,insetInlineStart:v,width:i,transform:"rotate(90deg)"},"&-collapsed::before":{transform:"rotate(-180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"},"&-spaced":{"&::before, &::after":{display:"none",content:"none"},background:"transparent",border:0,visibility:"hidden"}},[`${t}-row-indent + ${t}-row-expand-icon`]:{marginTop:g,marginInlineEnd:o},[`tr${t}-expanded-row`]:{"&, &:hover":{"> th, > td":{background:p}},[`${r}-descriptions-view`]:{display:"flex",table:{flex:"auto",width:"100%"}}},[`${t}-expanded-row-fixed`]:{position:"relative",margin:`${ae(S(d).mul(-1).equal())} ${ae(S(h).mul(-1).equal())}`,padding:`${ae(d)} ${ae(h)}`}}}},F5e=e=>{const{componentCls:t,antCls:r,iconCls:n,tableFilterDropdownWidth:i,tableFilterDropdownSearchWidth:o,paddingXXS:s,paddingXS:a,colorText:l,lineWidth:c,lineType:u,tableBorderColor:d,headerIconColor:h,fontSizeSM:p,tablePaddingHorizontal:f,borderRadius:g,motionDurationSlow:m,colorIcon:v,colorPrimary:b,tableHeaderFilterActiveBg:S,colorTextDisabled:x,tableFilterDropdownBg:E,tableFilterDropdownHeight:R,controlItemBgHover:T,controlItemBgActive:M,boxShadowSecondary:D,filterDropdownMenuBg:A,calc:I}=e,L=`${r}-dropdown`,F=`${t}-filter-dropdown`,k=`${r}-tree`,O=`${ae(c)} ${u} ${d}`;return[{[`${t}-wrapper`]:{[`${t}-filter-column`]:{display:"flex",justifyContent:"space-between"},[`${t}-filter-trigger`]:{position:"relative",display:"flex",alignItems:"center",marginBlock:I(s).mul(-1).equal(),marginInline:`${ae(s)} ${ae(I(f).div(2).mul(-1).equal())}`,padding:`0 ${ae(s)}`,color:h,fontSize:p,borderRadius:g,cursor:"pointer",transition:`all ${m}`,"&:hover":{color:v,background:S},"&.active":{color:b}}}},{[`${r}-dropdown`]:{[F]:{...on(e),minWidth:i,backgroundColor:E,borderRadius:g,boxShadow:D,overflow:"hidden",[`${L}-menu`]:{maxHeight:R,overflowX:"hidden",border:0,boxShadow:"none",borderRadius:"unset",backgroundColor:A,"&:empty::after":{display:"block",padding:`${ae(a)} 0`,color:x,fontSize:p,textAlign:"center",content:'"Not Found"'}},[`${F}-tree`]:{paddingBlock:`${ae(a)} 0`,paddingInline:a,[k]:{padding:0},[`${k}-treenode ${k}-node-content-wrapper:hover`]:{backgroundColor:T},[`${k}-treenode-checkbox-checked ${k}-node-content-wrapper`]:{"&, &:hover":{backgroundColor:M}}},[`${F}-search`]:{padding:a,borderBottom:O,"&-input":{input:{minWidth:o},[n]:{color:x}}},[`${F}-checkall`]:{width:"100%",marginBottom:s,marginInlineStart:s},[`${F}-btns`]:{display:"flex",justifyContent:"space-between",padding:`${ae(I(a).sub(c).equal())} ${ae(a)}`,overflow:"hidden",borderTop:O}}}},{[`${r}-dropdown ${F}, ${F}-submenu`]:{[`${r}-checkbox-wrapper + span`]:{paddingInlineStart:a,color:l},"> ul":{maxHeight:"calc(100vh - 130px)",overflowX:"hidden",overflowY:"auto"}}}]};function Yde({colorSplit:e}){const t={boxShadow:`inset 10px 0 8px -8px ${e}`},r={boxShadow:`inset -10px 0 8px -8px ${e}`};return[t,r]}const L5e=e=>{const{componentCls:t,lineWidth:r,motionDurationSlow:n,zIndexTableFixed:i,tableBg:o,calc:s}=e,a=`${t}-cell`,l=`${a}-fix`,c={position:"absolute",top:0,bottom:s(r).mul(-1).equal(),width:30,transition:`box-shadow ${n}`,content:'""',pointerEvents:"none"},[u,d]=Yde(e);return{[`${t}-wrapper`]:{[`${a}${l}`]:{position:"sticky"},[l]:{zIndex:`calc(var(--z-offset-reverse) + ${i})`,background:o,"&:after":c,"&-start:after":{insetInlineStart:"100%"},"&-end:after":{insetInlineEnd:"100%"},"&-start-shadow-show:after":u,"&-end-shadow-show:after":d},[`${t}-container`]:{position:"relative","&:before, &:after":{...c,zIndex:`calc(var(--columns-count) * 2 + ${i} + 1)`},"&:before":{insetInlineStart:0},"&:after":{insetInlineEnd:0}},[`${t}-has-fix-start ${t}-container:before`]:{display:"none"},[`${t}-has-fix-end ${t}-container:after`]:{display:"none"},[`${t}-fix-start-shadow-show ${t}-container:before`]:u,[`${t}-fix-end-shadow-show ${t}-container:after`]:d}}},_5e=e=>{const{componentCls:t,antCls:r,margin:n}=e;return{[`${t}-wrapper`]:{[`${t}-pagination${r}-pagination`]:{margin:`${ae(n)} 0`},[`${t}-pagination`]:{display:"flex",flexWrap:"wrap",rowGap:e.paddingXS,"> *":{flex:"none"},"&-start":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"flex-end"}}}}},O5e=e=>{const{componentCls:t,tableRadius:r}=e;return{[`${t}-wrapper`]:{[t]:{[`${t}-title, ${t}-header`]:{borderRadius:`${ae(r)} ${ae(r)} 0 0`},[`${t}-title + ${t}-container`]:{borderStartStartRadius:0,borderStartEndRadius:0,[`${t}-header, table`]:{borderRadius:0},"table > thead > tr:first-child":{"th:first-child, th:last-child, td:first-child, td:last-child":{borderRadius:0}}},"&-container":{borderStartStartRadius:r,borderStartEndRadius:r,"&::before":{borderStartStartRadius:r},"&::after":{borderStartEndRadius:r},[`> ${t}-content`]:{borderStartStartRadius:r,borderStartEndRadius:r},"table > thead > tr:first-child":{"> *:first-child":{borderStartStartRadius:r},"> *:last-child":{borderStartEndRadius:r}}},"&-footer":{borderRadius:`0 0 ${ae(r)} ${ae(r)}`}}}}},k5e=e=>{const{componentCls:t}=e,[r,n]=Yde(e);return{[`${t}-wrapper-rtl`]:{direction:"rtl",table:{direction:"rtl"},[`${t}-row-expand-icon`]:{float:"right","&::after":{transform:"rotate(-90deg)"},"&-collapsed::before":{transform:"rotate(180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"}},[`${t}-cell-fix`]:{"&-start-shadow-show:after":n,"&-end-shadow-show:after":r},[`${t}-container`]:{[`${t}-row-indent`]:{float:"right"}},[`${t}-fix-start-shadow-show ${t}-container:before`]:n,[`${t}-fix-end-shadow-show ${t}-container:after`]:r}}},N5e=e=>{const{componentCls:t,antCls:r,iconCls:n,fontSizeIcon:i,padding:o,paddingXS:s,headerIconColor:a,headerIconHoverColor:l,tableSelectionColumnWidth:c,tableSelectedRowBg:u,tableSelectedRowHoverBg:d,tableRowHoverBg:h,tablePaddingHorizontal:p,calc:f}=e;return{[`${t}-wrapper`]:{[`${t}-selection-col`]:{width:c,[`&${t}-selection-col-with-dropdown`]:{width:f(c).add(i).add(f(o).div(4)).equal()}},[`${t}-bordered ${t}-selection-col`]:{width:f(c).add(f(s).mul(2)).equal(),[`&${t}-selection-col-with-dropdown`]:{width:f(c).add(i).add(f(o).div(4)).add(f(s).mul(2)).equal()}},[` table tr th${t}-selection-column, table tr td${t}-selection-column, ${t}-selection-column `]:{paddingInlineEnd:e.paddingXS,paddingInlineStart:e.paddingXS,textAlign:"center",[`${r}-radio-wrapper`]:{marginInlineEnd:0}},[`table tr th${t}-selection-column${t}-cell-fix-left`]:{zIndex:f(e.zIndexTableFixed).add(1).equal({unit:!1})},[`table tr th${t}-selection-column::after`]:{backgroundColor:"transparent !important"},[`${t}-selection`]:{position:"relative",display:"inline-flex",flexDirection:"column"},[`${t}-selection-extra`]:{position:"absolute",top:0,zIndex:1,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,marginInlineStart:"100%",paddingInlineStart:ae(f(p).div(4).equal()),[n]:{color:a,fontSize:i,verticalAlign:"baseline","&:hover":{color:l}}},[`${t}-tbody`]:{[`${t}-row`]:{[`&${t}-row-selected`]:{[`> ${t}-cell`]:{background:u,"&-row-hover":{background:d}}},[`> ${t}-cell-row-hover`]:{background:h}}}}}},B5e=e=>{const{componentCls:t,tableExpandColumnWidth:r,calc:n}=e,i=(o,s,a,l)=>({[`${t}${t}-${o}`]:{fontSize:l,[` ${t}-title, ${t}-footer, ${t}-cell, ${t}-thead > tr > th, ${t}-tbody > tr > th, ${t}-tbody > tr > td, tfoot > tr > th, tfoot > tr > td `]:{padding:`${ae(s)} ${ae(a)}`},[`${t}-filter-trigger`]:{marginInlineEnd:ae(n(a).div(2).mul(-1).equal())},[`${t}-expanded-row-fixed`]:{margin:`${ae(n(s).mul(-1).equal())} ${ae(n(a).mul(-1).equal())}`},[`${t}-tbody`]:{[`${t}-wrapper:only-child ${t}`]:{marginBlock:ae(n(s).mul(-1).equal()),marginInline:`${ae(n(r).sub(a).equal())} ${ae(n(a).mul(-1).equal())}`}},[`${t}-selection-extra`]:{paddingInlineStart:ae(n(a).div(4).equal())}}});return{[`${t}-wrapper`]:{...i("medium",e.tablePaddingVerticalMiddle,e.tablePaddingHorizontalMiddle,e.tableFontSizeMiddle),...i("small",e.tablePaddingVerticalSmall,e.tablePaddingHorizontalSmall,e.tableFontSizeSmall)}}},$5e=e=>{const{componentCls:t,marginXXS:r,fontSizeIcon:n,headerIconColor:i,headerIconHoverColor:o}=e;return{[`${t}-wrapper`]:{[`${t}-thead th${t}-column-has-sorters`]:{outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}, left 0s`,"&:hover":{background:e.tableHeaderSortHoverBg,"&::before":{backgroundColor:"transparent !important"}},"&:focus-visible":{color:e.colorPrimary},[` &${t}-cell-fix-left:hover, &${t}-cell-fix-right:hover `]:{background:e.tableFixedHeaderSortActiveBg}},[`${t}-thead th${t}-column-sort`]:{background:e.tableHeaderSortBg,"&::before":{backgroundColor:"transparent !important"}},[`td${t}-column-sort`]:{background:e.tableBodySortBg},[`${t}-column-title`]:{position:"relative",zIndex:1,flex:1,minWidth:0},[`${t}-column-sorters`]:{display:"flex",flex:"auto",alignItems:"center",justifyContent:"space-between","&::after":{position:"absolute",inset:0,width:"100%",height:"100%",content:'""'}},[`${t}-column-sorters-tooltip-target-sorter`]:{"&::after":{content:"none"}},[`${t}-column-sorter`]:{marginInlineStart:r,color:i,fontSize:0,transition:`color ${e.motionDurationSlow}`,"&-inner":{display:"inline-flex",flexDirection:"column",alignItems:"center"},"&-up, &-down":{fontSize:n,"&.active":{color:e.colorPrimary}},[`${t}-column-sorter-up + ${t}-column-sorter-down`]:{marginTop:"-0.3em"}},[`${t}-column-sorters:hover ${t}-column-sorter`]:{color:o}}}},G5e=e=>{const{componentCls:t,opacityLoading:r,tableScrollThumbBg:n,tableScrollThumbBgHover:i,tableScrollThumbSize:o,tableScrollBg:s,stickyScrollBarBorderRadius:a,lineWidth:l,lineType:c,tableBorderColor:u,zIndexTableFixed:d}=e,h=`${ae(l)} ${c} ${u}`;return{[`${t}-wrapper`]:{[`${t}-sticky`]:{"&-holder":{position:"sticky",zIndex:`calc(var(--columns-count) * 2 + ${d} + 1)`,background:e.colorBgContainer},"&-scroll":{position:"sticky",bottom:0,height:`${ae(o)} !important`,zIndex:`calc(var(--columns-count) * 2 + ${d} + 1)`,display:"flex",alignItems:"center",background:s,borderTop:h,opacity:r,"&:hover":{transformOrigin:"center bottom"},"&-bar":{height:o,backgroundColor:n,borderRadius:a,transition:`all ${e.motionDurationSlow}, transform 0s`,position:"absolute",bottom:0,"&:hover, &-active":{backgroundColor:i}}}}}}},KX=e=>{const{componentCls:t,lineWidth:r,tableBorderColor:n,calc:i}=e,o=`${ae(r)} ${e.lineType} ${n}`;return{[`${t}-wrapper`]:{[`${t}-summary`]:{position:"relative",zIndex:e.zIndexTableFixed,background:e.tableBg,"> tr":{"> th, > td":{borderBottom:o}}},[`div${t}-summary`]:{boxShadow:`0 ${ae(i(r).mul(-1).equal())} 0 ${n}`}}}},V5e=e=>{const{componentCls:t,motionDurationMid:r,lineWidth:n,lineType:i,tableBorderColor:o,calc:s}=e,a=`${ae(n)} ${i} ${o}`,l=`${t}-expanded-row-cell`;return{[`${t}-wrapper`]:{[`${t}-tbody-virtual`]:{[`${t}-tbody-virtual-holder-inner`]:{[` & > ${t}-row, & > div:not(${t}-row) > ${t}-row `]:{display:"flex",boxSizing:"border-box",width:"100%"}},[`${t}-cell`]:{borderBottom:a,transition:`background-color ${r}`},[`${t}-expanded-row`]:{[`${l}${l}-fixed`]:{position:"sticky",insetInlineStart:0,overflow:"hidden",width:`calc(var(--virtual-width) - ${ae(n)})`,borderInlineEnd:"none"}}},[`${t}-bordered`]:{[`${t}-tbody-virtual`]:{"&:after":{content:'""',insetInline:0,bottom:0,borderBottom:a,position:"absolute"},[`${t}-cell`]:{borderInlineEnd:a,[`&${t}-cell-fix-right-first:before`]:{content:'""',position:"absolute",insetBlock:0,insetInlineStart:s(n).mul(-1).equal(),borderInlineStart:a}}},[`&${t}-virtual`]:{[`${t}-placeholder ${t}-cell`]:{borderInlineEnd:a,borderBottom:a}}}}}},z5e=e=>{const{componentCls:t,fontWeightStrong:r,tablePaddingVertical:n,tablePaddingHorizontal:i,tableExpandColumnWidth:o,lineWidth:s,lineType:a,tableBorderColor:l,tableFontSize:c,tableBg:u,tableRadius:d,tableHeaderTextColor:h,motionDurationMid:p,tableHeaderBg:f,tableHeaderCellSplitColor:g,tableFooterTextColor:m,tableFooterBg:v,calc:b}=e,S=`${ae(s)} ${a} ${l}`;return{[`${t}-wrapper`]:{clear:"both",maxWidth:"100%","--rc-virtual-list-scrollbar-bg":e.tableScrollBg,...fu(),[t]:{...on(e),fontSize:c,background:u,borderRadius:`${ae(d)} ${ae(d)} 0 0`,scrollbarColor:`${e.tableScrollThumbBg} ${e.tableScrollBg}`},table:{width:"100%",textAlign:"start",borderRadius:`${ae(d)} ${ae(d)} 0 0`,borderCollapse:"separate",borderSpacing:0},[` ${t}-cell, ${t}-thead > tr > th, ${t}-tbody > tr > th, ${t}-tbody > tr > td, tfoot > tr > th, tfoot > tr > td `]:{position:"relative",padding:`${ae(n)} ${ae(i)}`,overflowWrap:"break-word"},[`${t}-title`]:{padding:`${ae(n)} ${ae(i)}`},[`${t}-thead`]:{"\n > tr > th,\n > tr > td\n ":{position:"relative",color:h,fontWeight:r,textAlign:"start",background:f,borderBottom:S,transition:`background-color ${p} ease`,"&[colspan]:not([colspan='1'])":{textAlign:"center"},[`&:not(:last-child):not(${t}-selection-column):not(${t}-row-expand-icon-cell):not([colspan])::before`]:{position:"absolute",top:"50%",insetInlineEnd:0,width:1,height:"1.6em",backgroundColor:g,transform:"translateY(-50%)",transition:`background-color ${p}`,content:'""'}},"> tr:not(:last-child) > th[colspan]":{borderBottom:0}},[`${t}-tbody`]:{"> tr":{"> th, > td":{borderBottom:S,transition:["background-color","border-color"].map(x=>`${x} ${p}`).join(", "),[` > ${t}-wrapper:only-child, > ${t}-expanded-row-fixed > ${t}-wrapper:only-child `]:{[t]:{marginBlock:ae(b(n).mul(-1).equal()),marginInline:`${ae(b(o).sub(i).equal())} ${ae(b(i).mul(-1).equal())}`,[`${t}-tbody > tr:last-child > td`]:{borderBottomWidth:0,"&:first-child, &:last-child":{borderRadius:0}}}}},"> th":{position:"relative",color:h,fontWeight:r,textAlign:"start",background:f,borderBottom:S,transition:`background-color ${p} ease`},[`& > ${t}-measure-cell`]:{paddingBlock:"0 !important",borderBlock:"0 !important",[`${t}-measure-cell-content`]:{height:0,overflow:"hidden",pointerEvents:"none"}}}},[`${t}-footer`]:{padding:`${ae(n)} ${ae(i)}`,color:m,background:v}}}},H5e=e=>{const{colorFillAlter:t,colorBgContainer:r,colorTextHeading:n,colorFillSecondary:i,colorFillContent:o,controlItemBgActive:s,controlItemBgActiveHover:a,padding:l,paddingSM:c,paddingXS:u,colorBorderSecondary:d,borderRadiusLG:h,controlHeight:p,colorTextPlaceholder:f,fontSize:g,fontSizeSM:m,lineHeight:v,lineWidth:b,colorIcon:S,colorIconHover:x,opacityLoading:E,controlInteractiveSize:R}=e,T=new cn(i).onBackground(r).toHexString(),M=new cn(o).onBackground(r).toHexString(),D=new cn(t).onBackground(r).toHexString(),A=new cn(S),I=new cn(x),L=R/2-b,F=L*2+b*3;return{headerBg:D,headerColor:n,headerSortActiveBg:T,headerSortHoverBg:M,bodySortBg:D,rowHoverBg:D,rowSelectedBg:s,rowSelectedHoverBg:a,rowExpandedBg:t,cellPaddingBlock:l,cellPaddingInline:l,cellPaddingBlockMD:c,cellPaddingInlineMD:u,cellPaddingBlockSM:u,cellPaddingInlineSM:u,borderColor:d,headerBorderRadius:h,footerBg:D,footerColor:n,cellFontSize:g,cellFontSizeMD:g,cellFontSizeSM:g,headerSplitColor:d,fixedHeaderSortActiveBg:T,headerFilterHoverBg:o,filterDropdownMenuBg:r,filterDropdownBg:r,expandIconBg:r,selectionColumnWidth:p,stickyScrollBarBg:f,stickyScrollBarBorderRadius:100,expandIconMarginTop:(g*v-b*3)/2-Math.ceil((m*1.4-b*3)/2),headerIconColor:A.clone().setA(A.a*E).toRgbString(),headerIconHoverColor:I.clone().setA(I.a*E).toRgbString(),expandIconHalfInner:L,expandIconSize:F,expandIconScale:R/F}},W5e=2,U5e=Wr("Table",e=>{const{colorTextHeading:t,colorSplit:r,colorBgContainer:n,controlInteractiveSize:i,headerBg:o,headerColor:s,headerSortActiveBg:a,headerSortHoverBg:l,bodySortBg:c,rowHoverBg:u,rowSelectedBg:d,rowSelectedHoverBg:h,rowExpandedBg:p,cellPaddingBlock:f,cellPaddingInline:g,cellPaddingBlockMD:m,cellPaddingInlineMD:v,cellPaddingBlockSM:b,cellPaddingInlineSM:S,borderColor:x,footerBg:E,footerColor:R,headerBorderRadius:T,cellFontSize:M,cellFontSizeMD:D,cellFontSizeSM:A,headerSplitColor:I,fixedHeaderSortActiveBg:L,headerFilterHoverBg:F,filterDropdownBg:k,expandIconBg:O,selectionColumnWidth:B,stickyScrollBarBg:H,calc:N}=e,z=$r(e,{tableFontSize:M,tableBg:n,tableRadius:T,tablePaddingVertical:f,tablePaddingHorizontal:g,tablePaddingVerticalMiddle:m,tablePaddingHorizontalMiddle:v,tablePaddingVerticalSmall:b,tablePaddingHorizontalSmall:S,tableBorderColor:x,tableHeaderTextColor:s,tableHeaderBg:o,tableFooterTextColor:R,tableFooterBg:E,tableHeaderCellSplitColor:I,tableHeaderSortBg:a,tableHeaderSortHoverBg:l,tableBodySortBg:c,tableFixedHeaderSortActiveBg:L,tableHeaderFilterActiveBg:F,tableFilterDropdownBg:k,tableRowHoverBg:u,tableSelectedRowBg:d,tableSelectedRowHoverBg:h,zIndexTableFixed:W5e,tableFontSizeMiddle:D,tableFontSizeSmall:A,tableSelectionColumnWidth:B,tableExpandIconBg:O,tableExpandColumnWidth:N(i).add(N(e.padding).mul(2)).equal(),tableExpandedRowBg:p,tableFilterDropdownWidth:120,tableFilterDropdownHeight:264,tableFilterDropdownSearchWidth:140,tableScrollThumbSize:8,tableScrollThumbBg:H,tableScrollThumbBgHover:t,tableScrollBg:r});return[z5e(z),_5e(z),KX(z),$5e(z),F5e(z),M5e(z),O5e(z),A5e(z),KX(z),D5e(z),N5e(z),L5e(z),G5e(z),I5e(z),B5e(z),k5e(z),V5e(z)]},H5e,{resetFont:!1,unitless:{expandIconScale:!0}}),qX=[],j5e=(e,t)=>{var Qt;const{prefixCls:r,className:n,rootClassName:i,style:o,classNames:s,styles:a,size:l,bordered:c,dropdownPrefixCls:u,dataSource:d,pagination:h,rowSelection:p,rowKey:f,rowClassName:g,columns:m,children:v,childrenColumnName:b,onChange:S,getPopupContainer:x,loading:E,expandIcon:R,expandable:T,expandedRowRender:M,expandIconColumnIndex:D,indentSize:A,scroll:I,sortDirections:L,locale:F,showSorterTooltip:k={target:"full-header"},virtual:O}=e;MC();const B=y.useMemo(()=>m||_4(v),[m,v]),H=y.useMemo(()=>B.some(Ft=>Ft.responsive),[B]),N=Kx(H),z=y.useMemo(()=>{const Ft=new Set(Object.keys(N).filter(ur=>N[ur]));return B.filter(ur=>!ur.responsive||ur.responsive.some(fr=>Ft.has(fr)))},[B,N]),W=fn(e,["className","style","columns"]),{locale:V=xl,table:$}=y.useContext(ir),{getPrefixCls:K,direction:q,renderEmpty:X,getPopupContainer:Y,className:oe,style:ee,classNames:ne,styles:le}=Nr("table"),he=ki(Ft=>l==="middle"?"medium":l??Ft),re={...e,size:he,bordered:c},[ie,de]=Vr([ne,s],[le,a],{props:re},{pagination:{_default:"root"},header:{_default:"wrapper"},body:{_default:"wrapper"}}),J={...V.Table,...F},[ue]=Dl("global",xl.global),ve=d||qX,pe=K("table",r),me=K("dropdown",u),[,ke]=fs(),De=ho(pe),[Ee,We]=U5e(pe,De),ze={childrenColumnName:b,expandIconColumnIndex:D,...T,expandIcon:(T==null?void 0:T.expandIcon)??((Qt=$==null?void 0:$.expandable)==null?void 0:Qt.expandIcon)},{childrenColumnName:mt="children"}=ze,Nt=y.useMemo(()=>ve.some(Ft=>Ft==null?void 0:Ft[mt])?"nest":M||T!=null&&T.expandedRowRender?"row":null,[mt,ve]),St={body:y.useRef(null)},Ze=v4e(pe),Fe=y.useRef(null),tt=y.useRef(null);dFe(t,()=>({...tt.current,nativeElement:Fe.current}));const Ne=f||($==null?void 0:$.rowKey)||"key",rt=I??($==null?void 0:$.scroll),ot=y.useMemo(()=>typeof Ne=="function"?Ne:Ft=>Ft==null?void 0:Ft[Ne],[Ne]),[Ye]=f5e(ve,mt,ot),Ae={},nt=(Ft,ur,fr=!1)=>{var yn,dn,hn,en;const rr={...Ae,...Ft};fr&&((yn=Ae.resetPagination)==null||yn.call(Ae),(dn=rr.pagination)!=null&&dn.current&&(rr.pagination.current=1),h&&((en=h.onChange)==null||en.call(h,1,(hn=rr.pagination)==null?void 0:hn.pageSize))),I&&I.scrollToFirstRowOnChange!==!1&&St.body.current&&tle(0,{getContainer:()=>St.body.current}),S==null||S(rr.pagination,rr.filters,rr.sorter,{currentDataSource:FG(kG(ve,rr.sorterStates,mt),rr.filterStates,mt),action:ur})},Et=(Ft,ur)=>{nt({sorter:Ft,sorterStates:ur},"sort",!1)},[Tt,kt,Wt,at]=E5e({prefixCls:pe,mergedColumns:z,onSorterChange:Et,sortDirections:L||["ascend","descend"],tableLocale:J,showSorterTooltip:k,globalLocale:ue}),lt=y.useMemo(()=>kG(ve,kt,mt),[mt,ve,kt]);Ae.sorter=at(),Ae.sorterStates=kt;const Ut=(Ft,ur)=>{nt({filters:Ft,filterStates:ur},"filter",!0)},[cr,_e,qe]=p5e({prefixCls:pe,locale:J,dropdownPrefixCls:me,mergedColumns:z,onFilterChange:Ut,getPopupContainer:x||Y,rootClassName:Q(i,De)}),Re=FG(lt,_e,mt);Ae.filters=qe,Ae.filterStates=_e;const it=y.useMemo(()=>{const Ft={};return Object.keys(qe).forEach(ur=>{qe[ur]!==null&&(Ft[ur]=qe[ur])}),{...Wt,filters:Ft}},[Wt,qe]),[Ve]=T5e(it),Oe=(Ft,ur)=>{nt({pagination:{...Ae.pagination,current:Ft,pageSize:ur}},"paginate")},[se,ce]=m5e(Re.length,Oe,h);Ae.pagination=h===!1?{}:g5e(se,h),Ae.resetPagination=ce;const fe=y.useMemo(()=>{if(h===!1||!se.pageSize)return Re;const{current:Ft=1,total:ur,pageSize:fr=Kde}=se;return Re.lengthfr?Re.slice((Ft-1)*fr,Ft*fr):Re:Re.slice((Ft-1)*fr,Ft*fr)},[!!h,Re,se==null?void 0:se.current,se==null?void 0:se.pageSize,se==null?void 0:se.total]),[Te,$e]=g4e({prefixCls:pe,data:Re,pageData:fe,getRowKey:ot,getRecordByKey:Ye,expandType:Nt,childrenColumnName:mt,locale:J,getPopupContainer:x||Y},p),et=(Ft,ur,fr)=>{const rr=typeof g=="function"?g(Ft,ur,fr):g;return Q({[`${pe}-row-selected`]:$e.has(ot(Ft,ur))},rr)};ze.__PARENT_RENDER_ICON__=ze.expandIcon,ze.expandIcon=ze.expandIcon||R||m4e(J),Nt==="nest"&&ze.expandIconColumnIndex===void 0?ze.expandIconColumnIndex=p?1:0:ze.expandIconColumnIndex>0&&p&&(ze.expandIconColumnIndex-=1),typeof ze.indentSize!="number"&&(ze.indentSize=typeof A=="number"?A:15);const Dt=y.useCallback(Ft=>Ve(Te(cr(Tt(Ft)))),[Tt,cr,Te]);let ct,st;if(h!==!1&&(se!=null&&se.total)){let Ft;se.size?Ft=se.size:Ft=he==="small"||he==="medium"?"small":void 0;const ur=(hn="end")=>y.createElement(dde,{...se,classNames:ie.pagination,styles:de.pagination,className:Q(`${pe}-pagination ${pe}-pagination-${hn}`,se.className),size:Ft}),{placement:fr,position:rr}=se,yn=fr??rr,dn=hn=>{const en=hn.toLowerCase();return en.includes("center")?"center":en.includes("left")||en.includes("start")?"start":"end"};if(Array.isArray(yn)){const[hn,en]=["top","bottom"].map(Dr=>yn.find(sn=>sn.includes(Dr))),fo=yn.every(Dr=>`${Dr}`=="none");!hn&&!en&&!fo&&(st=ur()),hn&&(ct=ur(dn(hn))),en&&(st=ur(dn(en)))}else st=ur()}const wt=y.useMemo(()=>typeof E=="boolean"?{spinning:E}:typeof E=="object"&&E!==null?{spinning:!0,...E}:void 0,[E]),Mt=Q(We,De,`${pe}-wrapper`,oe,{[`${pe}-wrapper-rtl`]:q==="rtl"},n,i,ie.root,Ee),_t={...de.root,...ee,...o},At=y.useMemo(()=>wt!=null&&wt.spinning&&ve===qX?null:typeof(F==null?void 0:F.emptyText)<"u"?F.emptyText:(X==null?void 0:X("Table"))||y.createElement(o4,{componentName:"Table"}),[wt==null?void 0:wt.spinning,ve,F==null?void 0:F.emptyText,X]),pt=O?P5e:R5e,yt={},It=y.useMemo(()=>{const{fontSize:Ft,lineHeight:ur,lineWidth:fr,padding:rr,paddingXS:yn,paddingSM:dn}=ke,hn=Math.floor(Ft*ur);switch(he){case"medium":return dn*2+hn+fr;case"small":return yn*2+hn+fr;default:return rr*2+hn+fr}},[ke,he]);return O&&(yt.listItemHeight=It),y.createElement("div",{ref:Fe,className:Mt,style:_t},y.createElement(D4,{spinning:!1,...wt},ct,y.createElement(pt,{...yt,...W,scroll:rt,classNames:ie,styles:de,ref:tt,columns:z,direction:q,expandable:ze,prefixCls:pe,className:Q({[`${pe}-medium`]:he==="medium",[`${pe}-small`]:he==="small",[`${pe}-bordered`]:c,[`${pe}-empty`]:ve.length===0},We,De,Ee),data:fe,rowKey:ot,rowClassName:et,emptyText:At,internalHooks:t1,internalRefs:St,transformColumns:Dt,getContainerWidth:Ze,measureRowRender:Ft=>y.createElement(zde.Provider,{value:!0},y.createElement(Iu,{getPopupContainer:ur=>ur},Ft))}),st))},K5e=y.forwardRef(j5e),q5e=(e,t)=>{const r=y.useRef(0);return r.current+=1,y.createElement(K5e,{...e,ref:t,_renderTimes:r.current})},jp=y.forwardRef(q5e);jp.SELECTION_COLUMN=kh;jp.EXPAND_COLUMN=Vh;jp.SELECTION_ALL=yG;jp.SELECTION_INVERT=CG;jp.SELECTION_NONE=bG;jp.Column=s4e;jp.ColumnGroup=a4e;jp.Summary=Ede;const X5e=e=>{const{paddingXXS:t,lineWidth:r,tagPaddingHorizontal:n,componentCls:i,calc:o}=e,s=o(n).sub(r).equal(),a=o(t).sub(r).equal();return{[i]:{...on(e),display:"inline-block",height:"auto",paddingInline:s,fontSize:e.tagFontSize,lineHeight:e.tagLineHeight,whiteSpace:"nowrap",backgroundColor:e.defaultBg,border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,opacity:1,transition:`all ${e.motionDurationMid}`,textAlign:"start",position:"relative",[`&${i}-rtl`]:{direction:"rtl"},"&, a, a:hover":{color:e.defaultColor},[`${i}-close-icon`]:{marginInlineStart:a,fontSize:e.tagIconSize,color:e.colorIcon,cursor:"pointer",transition:`all ${e.motionDurationMid}`,"&:hover":{color:e.colorTextHeading}},"&-checkable":{backgroundColor:"transparent",borderColor:"transparent",cursor:"pointer",[`&:not(${i}-checkable-checked):hover`]:{color:e.colorPrimary,backgroundColor:e.colorFillSecondary},"&:active, &-checked":{color:e.colorTextLightSolid},"&-checked":{backgroundColor:e.colorPrimary,"&:hover":{backgroundColor:e.colorPrimaryHover}},"&:active":{backgroundColor:e.colorPrimaryActive},"&-disabled":{cursor:"not-allowed",[`&:not(${i}-checkable-checked)`]:{color:e.colorTextDisabled,"&:hover":{backgroundColor:"transparent"}},[`&${i}-checkable-checked`]:{color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled},"&:hover, &:active":{backgroundColor:e.colorBgContainerDisabled,color:e.colorTextDisabled},[`&:not(${i}-checkable-checked):hover`]:{color:e.colorTextDisabled}},"&-group":{display:"flex",flexWrap:"wrap",gap:e.paddingXS}},"&-hidden":{display:"none"},[`> ${e.iconCls} + span, > span + ${e.iconCls}`]:{marginInlineStart:s}},[`&${e.componentCls}-solid`]:{borderColor:"transparent",color:e.colorTextLightSolid,backgroundColor:e.colorBgSolid,[`&${i}-default`]:{color:e.solidTextColor}},[`${i}-filled`]:{borderColor:"transparent",backgroundColor:e.tagBorderlessBg},[`&${i}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed",backgroundColor:e.colorBgContainerDisabled,a:{cursor:"not-allowed",pointerEvents:"none",color:e.colorTextDisabled,"&:hover":{color:e.colorTextDisabled}},"a&":{"&:hover, &:active":{color:e.colorTextDisabled}},[`&${i}-outlined`]:{borderColor:e.colorBorderDisabled},[`&${i}-solid, &${i}-filled`]:{color:e.colorTextDisabled,[`${i}-close-icon`]:{color:e.colorTextDisabled}},[`${i}-close-icon`]:{cursor:"not-allowed",color:e.colorTextDisabled,"&:hover":{color:e.colorTextDisabled}}}}},G4=e=>{const{lineWidth:t,fontSizeIcon:r,calc:n}=e,i=e.fontSizeSM;return $r(e,{tagFontSize:i,tagLineHeight:ae(n(e.lineHeightSM).mul(i).equal()),tagIconSize:n(r).sub(n(t).mul(2)).equal(),tagPaddingHorizontal:8,tagBorderlessBg:e.defaultBg})},V4=e=>{const t=Lle(new dM(e.colorBgSolid),"#fff")?"#000":"#fff";return{defaultBg:new cn(e.colorFillTertiary).onBackground(e.colorBgContainer).toHexString(),defaultColor:e.colorText,solidTextColor:t}},z4=Wr("Tag",e=>{const t=G4(e);return X5e(t)},V4),Zde=y.forwardRef((e,t)=>{const{prefixCls:r,style:n,className:i,checked:o,children:s,icon:a,onChange:l,onClick:c,disabled:u,...d}=e,{getPrefixCls:h,tag:p}=y.useContext(ir),f=y.useContext(hs),g=u??f,m=E=>{g||(l==null||l(!o),c==null||c(E))},v=h("tag",r),[b,S]=z4(v),x=Q(v,`${v}-checkable`,{[`${v}-checkable-checked`]:o,[`${v}-checkable-disabled`]:g},p==null?void 0:p.className,i,b,S);return y.createElement("span",{...d,ref:t,style:{...n,...p==null?void 0:p.style},className:x,onClick:m},a,y.createElement("span",null,s))}),Y5e=Z.forwardRef((e,t)=>{const{id:r,prefixCls:n,rootClassName:i,className:o,style:s,classNames:a,styles:l,disabled:c,options:u,value:d,defaultValue:h,onChange:p,multiple:f,...g}=e,{getPrefixCls:m,direction:v,className:b,style:S,classNames:x,styles:E}=Nr("tag"),R=m("tag",n),T=`${R}-checkable-group`,M=ho(R),[D,A]=z4(R,M),[I,L]=Vr([x,a],[E,l],{props:e}),F=y.useMemo(()=>Array.isArray(u)?u.map(z=>z&&typeof z=="object"?z:{value:z,label:z}):[],[u]),[k,O]=An(h,d),B=(z,W)=>{let V=null;if(f){const $=k||[];V=z?[].concat(Pr($),[W.value]):$.filter(K=>K!==W.value)}else V=z?W.value:null;O(V),p==null||p(V)},H=Z.useRef(null);y.useImperativeHandle(t,()=>({nativeElement:H.current}));const N=ai(g,{aria:!0,data:!0});return Z.createElement("div",{...N,className:Q(T,b,i,{[`${T}-disabled`]:c,[`${T}-rtl`]:v==="rtl"},D,A,o,I.root),style:{...S,...L.root,...s},id:r,ref:H},F.map(z=>Z.createElement(Zde,{key:z.value,className:Q(`${T}-item`,I.item),style:L.item,checked:f?(k||[]).includes(z.value):k===z.value,onChange:W=>B(W,z),disabled:c},z.label)))});function Z5e(e,t){const{color:r,variant:n,bordered:i}=e;return y.useMemo(()=>{const o=r==null?void 0:r.endsWith("-inverse");let s;n?s=n:o?s="solid":i===!1?s="filled":s=t||"filled";const a=o?r==null?void 0:r.replace("-inverse",""):r,l=ZD(r),c=w2e(r),u={};if(!l&&!c&&a)if(s==="solid")u.backgroundColor=r;else{const d=new cn(a).toHsl();d.l=.95,u.backgroundColor=new cn(d).toHexString(),u.color=r,s==="outlined"&&(u.borderColor=r)}return[s,a,l,c,u]},[r,n,i,t])}const Q5e=e=>$D(e,(t,{textColor:r,lightBorderColor:n,lightColor:i,darkColor:o})=>({[`${e.componentCls}${e.componentCls}-${t}:not(${e.componentCls}-disabled)`]:{[`&${e.componentCls}-outlined`]:{backgroundColor:i,borderColor:n,color:r},[`&${e.componentCls}-solid`]:{backgroundColor:o,borderColor:o,color:e.colorTextLightSolid},[`&${e.componentCls}-filled`]:{backgroundColor:i,color:r}}})),J5e=Dx(["Tag","preset"],e=>{const t=G4(e);return Q5e(t)},V4);function eWe(e){return typeof e!="string"?e:e.charAt(0).toUpperCase()+e.slice(1)}const fT=(e,t,r)=>{const n=eWe(r);return{[`${e.componentCls}${e.componentCls}-${t}:not(${e.componentCls}-disabled)`]:{[`&${e.componentCls}-outlined`]:{backgroundColor:e[`color${n}Bg`],borderColor:e[`color${n}Border`],color:e[`color${r}`]},[`&${e.componentCls}-solid`]:{backgroundColor:e[`color${r}`],borderColor:e[`color${r}`]},[`&${e.componentCls}-filled`]:{backgroundColor:e[`color${n}Bg`],color:e[`color${r}`]}}}},tWe=Dx(["Tag","status"],e=>{const t=G4(e);return[fT(t,"success","Success"),fT(t,"processing","Info"),fT(t,"error","Error"),fT(t,"warning","Warning")]},V4),rWe=y.forwardRef((e,t)=>{var ue;const{prefixCls:r,className:n,rootClassName:i,style:o,children:s,icon:a,color:l,variant:c,onClose:u,bordered:d,disabled:h,href:p,target:f,styles:g,classNames:m,...v}=e,{getPrefixCls:b,direction:S,className:x,variant:E,style:R,classNames:T,styles:M}=Nr("tag"),[D,A,I,L,F]=Z5e(e,E),k=I||L,O=y.useContext(hs),B=h??O,{tag:H}=y.useContext(ir),[N,z]=y.useState(!0),W=fn(v,["closeIcon","closable"]),V={...e,color:A,variant:D,disabled:B,href:p,target:f,icon:a},[$,K]=Vr([T,m],[M,g],{props:V}),q=y.useMemo(()=>{let ve={...K.root,...R,...o};return B||(ve={...F,...ve}),ve},[K.root,R,o,F,B]),X=b("tag",r),[Y,oe]=z4(X),ee=Q(X,x,$.root,`${X}-${D}`,{[`${X}-${A}`]:k,[`${X}-hidden`]:!N,[`${X}-rtl`]:S==="rtl",[`${X}-disabled`]:B},n,i,Y,oe),ne=ve=>{B||(ve.stopPropagation(),u==null||u(ve),!ve.defaultPrevented&&z(!1))},[,le]=O3(Vy(e),Vy(H),{closable:!1,closeIconRender:ve=>{const pe=y.createElement("span",{className:`${X}-close-icon`,onClick:ne},ve);return xle(ve,pe,me=>({onClick:ke=>{var De;(De=me==null?void 0:me.onClick)==null||De.call(me,ke),ne(ke)},className:Q(me==null?void 0:me.className,`${X}-close-icon`)}))}}),he=typeof v.onClick=="function"||s&&s.type==="a",re=Ei(a,{className:Q(y.isValidElement(a)?(ue=a.props)==null?void 0:ue.className:void 0,$.icon),style:K.icon}),ie=re?y.createElement(y.Fragment,null,re,s&&y.createElement("span",{className:$.content,style:K.content},s)):s,de=p?"a":"span",J=y.createElement(de,{...W,ref:t,className:ee,style:q,href:B?void 0:p,target:f,onClick:B?void 0:W.onClick,...p&&B?{"aria-disabled":!0}:{}},ie,le,I&&y.createElement(J5e,{key:"preset",prefixCls:X}),L&&y.createElement(tWe,{key:"status",prefixCls:X}));return he?y.createElement(kx,{component:"Tag"},J):J}),Qde=rWe;Qde.CheckableTag=Zde;Qde.CheckableTagGroup=Y5e;var nWe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};function NG(){return NG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,NG({},e,{ref:t,icon:nWe})),oWe=y.forwardRef(iWe);var sWe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M257.7 752c2 0 4-.2 6-.5L431.9 722c2-.4 3.9-1.3 5.3-2.8l423.9-423.9a9.96 9.96 0 000-14.1L694.9 114.9c-1.9-1.9-4.4-2.9-7.1-2.9s-5.2 1-7.1 2.9L256.8 538.8c-1.5 1.5-2.4 3.3-2.8 5.3l-29.5 168.2a33.5 33.5 0 009.4 29.8c6.6 6.4 14.9 9.9 23.8 9.9zm67.4-174.4L687.8 215l73.3 73.3-362.7 362.6-88.9 15.7 15.6-89zM880 836H144c-17.7 0-32 14.3-32 32v36c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-36c0-17.7-14.3-32-32-32z"}}]},name:"edit",theme:"outlined"};function BG(){return BG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,BG({},e,{ref:t,icon:sWe})),lWe=y.forwardRef(aWe);var cWe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 170h-60c-4.4 0-8 3.6-8 8v518H310v-73c0-6.7-7.8-10.5-13-6.3l-141.9 112a8 8 0 000 12.6l141.9 112c5.3 4.2 13 .4 13-6.3v-75h498c35.3 0 64-28.7 64-64V178c0-4.4-3.6-8-8-8z"}}]},name:"enter",theme:"outlined"};function $G(){return $G=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,$G({},e,{ref:t,icon:cWe})),dWe=y.forwardRef(uWe),hWe=(e,t,r,n)=>{const{titleMarginBottom:i,fontWeightStrong:o}=n;return{marginBottom:i,color:r,fontWeight:o,fontSize:e,lineHeight:t}},pWe=e=>{const t=[1,2,3,4,5],r={};return t.forEach(n=>{r[` h${n}&, div&-h${n}, div&-h${n} > textarea, h${n} `]=hWe(e[`fontSizeHeading${n}`],e[`lineHeightHeading${n}`],e.colorTextHeading,e)}),r},fWe=e=>{const{componentCls:t}=e;return{[`&${`${t}-link`}`]:{...D3(e),userSelect:"text",[`&[disabled], &${t}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed","&:active, &:hover":{color:e.colorTextDisabled},"&:active":{pointerEvents:"none"}}}}},gWe=e=>({code:{margin:"0 0.2em",paddingInline:"0.4em",paddingBlock:"0.2em 0.1em",fontSize:"85%",fontFamily:e.fontFamilyCode,background:"rgba(150, 150, 150, 0.1)",border:"1px solid rgba(100, 100, 100, 0.2)",borderRadius:3},kbd:{margin:"0 0.2em",paddingInline:"0.4em",paddingBlock:"0.15em 0.1em",fontSize:"90%",fontFamily:e.fontFamilyCode,background:"rgba(150, 150, 150, 0.06)",border:"1px solid rgba(100, 100, 100, 0.2)",borderBottomWidth:2,borderRadius:3},mark:{padding:0,backgroundColor:oM[2]},"u, ins":{textDecoration:"underline",textDecorationSkipInk:"auto"},"s, del":{textDecoration:"line-through"},strong:{fontWeight:e.fontWeightStrong},"ul, ol":{marginInline:0,marginBlock:"0 1em",padding:0,li:{marginInline:"20px 0",marginBlock:0,paddingInline:"4px 0",paddingBlock:0}},ul:{listStyleType:"circle",ul:{listStyleType:"disc"}},ol:{listStyleType:"decimal"},"pre, blockquote":{margin:"1em 0"},pre:{padding:"0.4em 0.6em",whiteSpace:"pre-wrap",wordWrap:"break-word",background:"rgba(150, 150, 150, 0.1)",border:"1px solid rgba(100, 100, 100, 0.2)",borderRadius:3,fontFamily:e.fontFamilyCode,code:{display:"inline",margin:0,padding:0,fontSize:"inherit",fontFamily:"inherit",background:"transparent",border:0}},blockquote:{paddingInline:"0.6em 0",paddingBlock:0,borderInlineStart:"4px solid rgba(100, 100, 100, 0.2)",opacity:.85}}),mWe=e=>{const{componentCls:t,paddingSM:r}=e,n=r;return{"&-edit-content":{position:"relative","div&":{insetInlineStart:e.calc(e.paddingSM).mul(-1).equal(),insetBlockStart:e.calc(n).div(-2).add(1).equal(),marginBottom:e.calc(n).div(2).sub(2).equal()},[`${t}-edit-content-confirm`]:{position:"absolute",insetInlineEnd:e.calc(e.marginXS).add(2).equal(),insetBlockEnd:e.marginXS,color:e.colorIcon,fontWeight:"normal",fontSize:e.fontSize,fontStyle:"normal",pointerEvents:"none"},textarea:{margin:"0!important",MozTransition:"none",height:"1em"}}}},vWe=e=>({[`${e.componentCls}-copy-success`]:{"\n &,\n &:hover,\n &:focus":{color:e.colorSuccess}},[`${e.componentCls}-copy-icon-only`]:{marginInlineStart:0}}),yWe=()=>({"\n a&-ellipsis,\n span&-ellipsis\n ":{display:"inline-block",maxWidth:"100%"},"&-ellipsis-single-line":{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis","a&, span&":{verticalAlign:"bottom"},"> code":{paddingBlock:0,maxWidth:"calc(100% - 1.2em)",display:"inline-block",overflow:"hidden",textOverflow:"ellipsis",verticalAlign:"bottom",boxSizing:"content-box"}},"&-ellipsis-multiple-line":{display:"-webkit-box",overflow:"hidden",WebkitLineClamp:3,WebkitBoxOrient:"vertical"}}),CWe=e=>{const{componentCls:t,titleMarginTop:r}=e;return{[t]:{color:e.colorText,wordBreak:"break-word",lineHeight:e.lineHeight,[`&${t}-secondary, &${t}-link${t}-secondary`]:{color:e.colorTextDescription},[`&${t}-success, &${t}-link${t}-success`]:{color:e.colorSuccessText},[`&${t}-warning, &${t}-link${t}-warning`]:{color:e.colorWarningText},[`&${t}-danger, &${t}-link${t}-danger`]:{color:e.colorErrorText,[`&${t}-link:active, &${t}-link:focus`]:{color:e.colorErrorTextActive},[`&${t}-link:hover`]:{color:e.colorErrorTextHover}},[`&${t}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed",userSelect:"none"},"\n div&,\n p\n ":{marginBottom:"1em"},...pWe(e),[` & + h1${t}, & + h2${t}, & + h3${t}, & + h4${t}, & + h5${t} `]:{marginTop:r},"\n div,\n ul,\n li,\n p,\n h1,\n h2,\n h3,\n h4,\n h5":{"\n + h1,\n + h2,\n + h3,\n + h4,\n + h5\n ":{marginTop:r}},...gWe(e),...fWe(e),[`${t}-actions`]:{display:"inline"},[` ${t}-expand, ${t}-collapse, ${t}-edit, ${t}-copy `]:{...D3(e),marginInlineStart:e.marginXXS},...mWe(e),...vWe(e),...yWe(),"&-rtl":{direction:"rtl"}}}},bWe=()=>({titleMarginTop:"1.2em",titleMarginBottom:"0.5em"}),Jde=Wr("Typography",CWe,bWe),SWe=e=>{const{prefixCls:t,"aria-label":r,className:n,style:i,direction:o,maxLength:s,autoSize:a=!0,value:l,onSave:c,onCancel:u,onEnd:d,component:h,enterIcon:p=y.createElement(dWe,null)}=e,f=y.useRef(null),g=y.useRef(!1),m=y.useRef(null),[v,b]=y.useState(l);y.useEffect(()=>{b(l)},[l]),y.useEffect(()=>{var F;if((F=f.current)!=null&&F.resizableTextArea){const{textArea:k}=f.current.resizableTextArea;k.focus();const{length:O}=k.value;k.setSelectionRange(O,O)}},[]);const S=({target:F})=>{b(F.value.replace(/[\n\r]/g,""))},x=()=>{g.current=!0},E=()=>{g.current=!1},R=({keyCode:F})=>{g.current||(m.current=F)},T=()=>{c(v.trim())},M=({keyCode:F,ctrlKey:k,altKey:O,metaKey:B,shiftKey:H})=>{m.current!==F||g.current||k||O||B||H||(F===Zt.ENTER?(T(),d==null||d()):F===Zt.ESC&&u())},D=()=>{T()},[A,I]=Jde(t),L=Q(t,`${t}-edit-content`,{[`${t}-rtl`]:o==="rtl",[`${t}-${h}`]:!!h},n,A,I);return y.createElement("div",{className:L,style:i},y.createElement(lde,{ref:f,maxLength:s,value:v,onChange:S,onKeyDown:R,onKeyUp:M,onCompositionStart:x,onCompositionEnd:E,onBlur:D,"aria-label":r,rows:1,autoSize:a}),p!==null?Ei(p,{className:`${t}-edit-content-confirm`}):null)},wWe=(e,t)=>{let r=!1;const n=i=>{var o,s,a;i.stopPropagation(),i.preventDefault(),(o=i.clipboardData)==null||o.clearData(),(s=i.clipboardData)==null||s.setData("text/plain",e),t&&((a=i.clipboardData)==null||a.setData("text/html",e)),r=!0};try{return document.addEventListener("copy",n,{capture:!0}),document.execCommand("copy"),r}catch{return!1}finally{document.removeEventListener("copy",n,{capture:!0})}},xWe=async(e,t)=>{try{return t?await navigator.clipboard.write([new ClipboardItem({"text/html":new Blob([e],{type:"text/html"}),"text/plain":new Blob([e],{type:"text/plain"})})]):await navigator.clipboard.writeText(e),!0}catch{return!1}};async function EWe(e,t){if(typeof e!="string")return!1;const r=(t==null?void 0:t.format)==="text/html";return!!(await xWe(e,r)||wWe(e,r))}const TWe=({copyConfig:e,children:t})=>{const[r,n]=y.useState(!1),[i,o]=y.useState(!1),s=y.useRef(null),a=()=>{s.current&&clearTimeout(s.current)},l={};e.format&&(l.format=e.format),y.useEffect(()=>a,[]);const c=br(async u=>{var d;u==null||u.preventDefault(),u==null||u.stopPropagation(),o(!0);try{const h=typeof e.text=="function"?await e.text():e.text;await EWe(h||mde(t,{skipEmpty:!0}).join("")||"",l),o(!1),n(!0),a(),s.current=setTimeout(()=>{n(!1)},3e3),(d=e.onCopy)==null||d.call(e,u)}catch(h){throw o(!1),h}});return{copied:r,copyLoading:i,onClick:c}};function yO(e,t){return y.useMemo(()=>{const r=!!e;return[r,{...t,...r&&typeof e=="object"?e:null}]},[e])}const RWe=e=>{const t=y.useRef(void 0);return y.useEffect(()=>{t.current=e}),t.current},PWe=(e,t,r)=>y.useMemo(()=>e===!0?{title:t??r}:y.isValidElement(e)?{title:e}:typeof e=="object"?{title:t??r,...e}:{title:e},[e,t,r]),ehe=y.forwardRef((e,t)=>{const{prefixCls:r,component:n="article",className:i,rootClassName:o,children:s,direction:a,style:l,...c}=e,{getPrefixCls:u,direction:d,className:h,style:p}=Nr("typography"),f=a??d,g=u("typography",r),[m,v]=Jde(g),b=Q(g,h,{[`${g}-rtl`]:f==="rtl"},i,o,m,v),S={...p,...l};return y.createElement(n,{className:b,style:S,ref:t,...c},s)});var MWe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M832 64H296c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h496v688c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V96c0-17.7-14.3-32-32-32zM704 192H192c-17.7 0-32 14.3-32 32v530.7c0 8.5 3.4 16.6 9.4 22.6l173.3 173.3c2.2 2.2 4.7 4 7.4 5.5v1.9h4.2c3.5 1.3 7.2 2 11 2H704c17.7 0 32-14.3 32-32V224c0-17.7-14.3-32-32-32zM350 856.2L263.9 770H350v86.2zM664 888H414V746c0-22.1-17.9-40-40-40H232V264h432v624z"}}]},name:"copy",theme:"outlined"};function GG(){return GG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,GG({},e,{ref:t,icon:MWe})),DWe=y.forwardRef(IWe),XX=e=>e===!1?[!1,!1]:mde(e);function CO(e,t,r){return e===!0||e===void 0?t:e||r&&t}function AWe(e){const t=document.createElement("em");e.appendChild(t);const r=e.getBoundingClientRect(),n=t.getBoundingClientRect();return e.removeChild(t),r.left>n.left||n.right>r.right||r.top>n.top||n.bottom>r.bottom}const H4=e=>["string","number"].includes(typeof e),FWe=e=>{const{prefixCls:t,copied:r,locale:n,iconOnly:i,tooltips:o,icon:s,tabIndex:a,onCopy:l,loading:c}=e,u=XX(o),d=XX(s),{copied:h,copy:p}=n??{},f=r?h:p,g=CO(u[r?1:0],f),m=typeof g=="string"?g:f;return y.createElement(El,{title:g},y.createElement("button",{type:"button",className:Q(`${t}-copy`,{[`${t}-copy-success`]:r,[`${t}-copy-icon-only`]:i}),onClick:l,"aria-label":m,tabIndex:a},r?CO(d[1],y.createElement(s4,null),!0):CO(d[0],c?y.createElement(rm,null):y.createElement(DWe,null),!0)))},gT=y.forwardRef(({style:e,children:t},r)=>{const n=y.useRef(null);return y.useImperativeHandle(r,()=>({isExceed:()=>{const i=n.current;return i.scrollHeight>i.clientHeight},getHeight:()=>n.current.clientHeight})),y.createElement("span",{"aria-hidden":!0,ref:n,style:{position:"fixed",display:"block",left:0,top:0,pointerEvents:"none",backgroundColor:"rgba(255, 0, 0, 0.65)",...e}},t)}),LWe=e=>e.reduce((t,r)=>t+(H4(r)?String(r).length:1),0);function YX(e,t){let r=0;const n=[];for(let i=0;it){const c=t-r;return n.push(String(o).slice(0,c)),n}n.push(o),r=l}return e}const bO=0,SO=1,wO=2,xO=3,ZX=4,mT={display:"-webkit-box",overflow:"hidden",WebkitBoxOrient:"vertical"};function _We(e){const{enableMeasure:t,width:r,text:n,children:i,rows:o,expanded:s,miscDeps:a,onEllipsis:l}=e,c=y.useMemo(()=>Li(n),[n]),u=y.useMemo(()=>LWe(c),[n]),d=y.useMemo(()=>i(c,!1),[n]),[h,p]=y.useState(null),f=y.useRef(null),g=y.useRef(null),m=y.useRef(null),v=y.useRef(null),b=y.useRef(null),[S,x]=y.useState(!1),[E,R]=y.useState(bO),[T,M]=y.useState(0),[D,A]=y.useState(null);jr(()=>{R(t&&r&&u?SO:bO)},[r,n,o,t,c]),jr(()=>{var k,O,B,H;if(E===SO){R(wO);const N=g.current&&getComputedStyle(g.current).whiteSpace;A(N)}else if(E===wO){const N=!!((k=m.current)!=null&&k.isExceed());R(N?xO:ZX),p(N?[0,u]:null),x(N);const z=((O=m.current)==null?void 0:O.getHeight())||0,W=o===1?0:((B=v.current)==null?void 0:B.getHeight())||0,V=((H=b.current)==null?void 0:H.getHeight())||0,$=Math.max(z,W+V);M($+1),l(N)}},[E]);const I=h?Math.ceil((h[0]+h[1])/2):0;jr(()=>{var B;const[k,O]=h||[0,0];if(k!==O){const N=(((B=f.current)==null?void 0:B.getHeight())||0)>T;let z=I;O-k===1&&(z=N?k:O),p(N?[k,z]:[z,O])}},[h,I]);const L=y.useMemo(()=>{if(!t)return i(c,!1);if(E!==xO||!h||h[0]!==h[1]){const k=i(c,!1);return[ZX,bO].includes(E)?k:y.createElement("span",{style:{...mT,WebkitLineClamp:o}},k)}return i(s?c:YX(c,h[0]),S)},[s,E,h,c].concat(Pr(a))),F={width:r,margin:0,padding:0,whiteSpace:D==="nowrap"?"normal":"inherit"};return y.createElement(y.Fragment,null,L,E===wO&&y.createElement(y.Fragment,null,y.createElement(gT,{style:{...F,...mT,WebkitLineClamp:o},ref:m},d),y.createElement(gT,{style:{...F,...mT,WebkitLineClamp:o-1},ref:v},d),y.createElement(gT,{style:{...F,...mT,WebkitLineClamp:1},ref:b},i([],!0))),E===xO&&h&&h[0]!==h[1]&&y.createElement(gT,{style:{...F,top:400},ref:f},i(YX(c,I),!0)),E===SO&&y.createElement("span",{style:{whiteSpace:"inherit"},ref:g}))}const OWe=({enableEllipsis:e,isEllipsis:t,open:r,children:n,tooltipProps:i})=>{if(!(i!=null&&i.title)||!e)return n;const o=r&&t;return y.createElement(El,{open:o,...i},n)};function kWe({mark:e,code:t,underline:r,delete:n,strong:i,keyboard:o,italic:s},a){let l=a;function c(u,d){d&&(l=y.createElement(u,{},l))}return c("strong",i),c("u",r),c("del",n),c("code",t),c("mark",e),c("kbd",o),c("i",s),l}const NWe="...",QX=["delete","mark","code","underline","strong","keyboard","italic"],cA=y.forwardRef((e,t)=>{const{prefixCls:r,className:n,style:i,type:o,disabled:s,children:a,ellipsis:l,editable:c,copyable:u,component:d,title:h,onMouseEnter:p,onMouseLeave:f,...g}=e,{getPrefixCls:m,direction:v}=y.useContext(ir),[b]=Dl("Text"),S=y.useRef(null),x=y.useRef(null),E=m("typography",r),R=fn(g,QX),[T,M]=yO(c),[D,A]=An(!1,M.editing),{triggerType:I=["icon"]}=M,L=at=>{var lt;at&&((lt=M.onStart)==null||lt.call(M)),A(at)},F=RWe(D);jr(()=>{var at;!D&&F&&((at=x.current)==null||at.focus())},[D]);const k=at=>{at==null||at.preventDefault(),L(!0)},O=at=>{var lt;(lt=M.onChange)==null||lt.call(M,at),L(!1)},B=()=>{var at;(at=M.onCancel)==null||at.call(M),L(!1)},[H,N]=yO(u),{copied:z,copyLoading:W,onClick:V}=TWe({copyConfig:N,children:a}),[$,K]=y.useState(!1),[q,X]=y.useState(!1),[Y,oe]=y.useState(!1),[ee,ne]=y.useState(!1),[le,he]=y.useState(!0),[re,ie]=yO(l,{expandable:!1,symbol:at=>at?b==null?void 0:b.collapse:b==null?void 0:b.expand}),[de,J]=An(ie.defaultExpanded||!1,ie.expanded),ue=re&&(!de||ie.expandable==="collapsible"),{rows:ve=1}=ie,pe=y.useMemo(()=>ue&&(ie.suffix!==void 0||ie.onEllipsis||ie.expandable||T||H),[ue,ie,T,H]);jr(()=>{re&&!pe&&(K(eq("webkitLineClamp")),X(eq("textOverflow")))},[pe,re]);const[me,ke]=y.useState(ue),De=y.useMemo(()=>pe?!1:ve===1?q:$,[pe,q,$]);jr(()=>{ke(De&&ue)},[De,ue]);const Ee=ue&&(me?ee:Y),We=ue&&ve===1&&me,ze=ue&&ve>1&&me,mt=(at,lt)=>{var Ut;J(lt.expanded),(Ut=ie.onExpand)==null||Ut.call(ie,at,lt)},[Nt,St]=y.useState(0),[Ze,Fe]=y.useState(!1),[tt,Ne]=y.useState(!1),rt=({offsetWidth:at})=>{St(at)},ot=at=>{var lt;oe(at),Y!==at&&((lt=ie.onEllipsis)==null||lt.call(ie,at))};y.useEffect(()=>{const at=S.current;if(re&&me&&at){const lt=AWe(at);ee!==lt&&ne(lt)}},[re,me,a,ze,le,Nt]),y.useEffect(()=>{const at=S.current;if(typeof IntersectionObserver>"u"||!at||!me||!ue)return;const lt=new IntersectionObserver(()=>{he(!!at.offsetParent)});return lt.observe(at),()=>{lt.disconnect()}},[me,ue]);const Ye=PWe(ie.tooltip,M.text,a),Ae=y.useMemo(()=>{if(!(!re||me))return[M.text,a,h,Ye.title].find(H4)},[re,me,h,Ye.title,Ee]);if(D)return y.createElement(SWe,{value:M.text??(typeof a=="string"?a:""),onSave:O,onCancel:B,onEnd:M.onEnd,prefixCls:E,className:n,style:i,direction:v,component:d,maxLength:M.maxLength,autoSize:M.autoSize,enterIcon:M.enterIcon});const nt=()=>{const{expandable:at,symbol:lt}=ie;return at?y.createElement("button",{type:"button",key:"expand",className:`${E}-${de?"collapse":"expand"}`,onClick:Ut=>mt(Ut,{expanded:!de}),"aria-label":de?b.collapse:b==null?void 0:b.expand},typeof lt=="function"?lt(de):lt):null},Et=()=>{if(!T)return;const{icon:at,tooltip:lt,tabIndex:Ut}=M,cr=Li(lt)[0]||(b==null?void 0:b.edit),_e=typeof cr=="string"?cr:"";return I.includes("icon")?y.createElement(El,{key:"edit",title:lt===!1?"":cr},y.createElement("button",{type:"button",ref:x,className:`${E}-edit`,onClick:k,"aria-label":_e,tabIndex:Ut},at||y.createElement(lWe,{role:"button"}))):null},Tt=()=>H?y.createElement(FWe,{key:"copy",...N,prefixCls:E,copied:z,locale:b,onCopy:V,loading:W,iconOnly:!Tn(a)}):null,kt=at=>{const lt=at&&nt(),Ut=Et(),cr=Tt();return!lt&&!Ut&&!cr?null:y.createElement("span",{key:"operations",className:`${E}-actions`,onMouseEnter:()=>Fe(!0),onMouseLeave:()=>Fe(!1)},lt,Ut,cr)},Wt=at=>[at&&!de&&y.createElement("span",{"aria-hidden":!0,key:"ellipsis"},NWe),ie.suffix,kt(at)];return y.createElement(ta,{onResize:rt,disabled:!ue},at=>y.createElement(OWe,{tooltipProps:Ye,enableEllipsis:ue,isEllipsis:Ee,open:tt&&!Ze},y.createElement(ehe,{onMouseEnter:lt=>{Ne(!0),p==null||p(lt)},onMouseLeave:lt=>{Ne(!1),f==null||f(lt)},className:Q({[`${E}-${o}`]:o,[`${E}-disabled`]:s,[`${E}-ellipsis`]:re,[`${E}-ellipsis-single-line`]:We,[`${E}-ellipsis-multiple-line`]:ze,[`${E}-link`]:d==="a"},n),prefixCls:r,style:{...i,WebkitLineClamp:ze?ve:void 0},component:d,ref:Wo(at,S,t),direction:v,onClick:I.includes("text")?k:void 0,"aria-label":Ae==null?void 0:Ae.toString(),title:h,...R},y.createElement(_We,{enableMeasure:ue&&!me,text:a,rows:ve,width:Nt,onEllipsis:ot,expanded:de,miscDeps:[z,de,W,T,H,b].concat(Pr(QX.map(lt=>e[lt])))},(lt,Ut)=>kWe(e,y.createElement(y.Fragment,null,lt.length>0&&Ut&&!de&&Ae?y.createElement("span",{key:"show-content","aria-hidden":!0},lt):lt,Wt(Ut)))))))}),BWe=y.forwardRef((e,t)=>{const{ellipsis:r,rel:n,children:i,navigate:o,...s}=e,a={...s,rel:n===void 0&&s.target==="_blank"?"noopener noreferrer":n};return y.createElement(cA,{...a,ref:t,ellipsis:!!r,component:"a"},i)}),$We=y.forwardRef((e,t)=>{const{children:r,...n}=e;return y.createElement(cA,{ref:t,...n,component:"div"},r)}),GWe=y.forwardRef((e,t)=>{const{ellipsis:r,children:n,...i}=e,o=y.useMemo(()=>r&&typeof r=="object"?fn(r,["expandable","rows"]):r,[r]);return y.createElement(cA,{ref:t,...i,ellipsis:o,component:"span"},n)}),VWe=[1,2,3,4,5],zWe=y.forwardRef((e,t)=>{const{level:r=1,children:n,...i}=e,o=VWe.includes(r)?`h${r}`:"h1";return y.createElement(cA,{ref:t,...i,component:o},n)}),uA=ehe;uA.Text=GWe;uA.Link=BWe;uA.Title=zWe;uA.Paragraph=$We;const HWe=((e,t)=>{if(e&&t){const r=Array.isArray(t)?t:t.split(","),n=e.name||"",i=e.type||"",o=i.replace(/\/.*$/,"");return r.some(s=>{const a=s.trim();if(/^\*(\/\*)?$/.test(s))return!0;if(a.charAt(0)==="."){const l=n.toLowerCase(),c=a.toLowerCase();let u=[c];return(c===".jpg"||c===".jpeg")&&(u=[".jpg",".jpeg"]),u.some(d=>l.endsWith(d))}return/\/\*$/.test(a)?o===a.replace(/\/.*$/,""):i===a?!0:/^\w+$/.test(a)?(Vn(!1,`Upload takes an invalidate 'accept' type '${a}'.Skip for check.`),!0):!1})}return!0});function WWe(e,t){const r=`cannot ${e.method} ${e.action} ${t.status}'`,n=new Error(r);return n.status=t.status,n.method=e.method,n.url=e.action,n}function JX(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}function eY(e){const t=new XMLHttpRequest;e.onProgress&&t.upload&&(t.upload.onprogress=function(o){o.total>0&&(o.percent=o.loaded/o.total*100),e.onProgress(o)});const r=new FormData;e.data&&Object.keys(e.data).forEach(i=>{const o=e.data[i];if(Array.isArray(o)){o.forEach(s=>{r.append(`${i}[]`,s)});return}r.append(i,o)}),e.file instanceof Blob?r.append(e.filename,e.file,e.file.name):r.append(e.filename,e.file),t.onerror=function(o){e.onError(o)},t.onload=function(){return t.status<200||t.status>=300?e.onError(WWe(e,t),JX(t)):e.onSuccess(JX(t),t)},t.open(e.method,e.action,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);const n=e.headers||{};return n["X-Requested-With"]!==null&&t.setRequestHeader("X-Requested-With","XMLHttpRequest"),Object.keys(n).forEach(i=>{n[i]!==null&&t.setRequestHeader(i,n[i])}),t.send(r),{abort(){t.abort()}}}const UWe=async(e,t)=>{const r=[],n=[];e.forEach(l=>n.push(l.webkitGetAsEntry()));async function i(l){const c=l.createReader(),u=[];for(;;){const d=await new Promise(p=>{c.readEntries(p,()=>p([]))}),h=d.length;if(!h)break;for(let p=0;p{l.file(u=>{t(u)?(l.fullPath&&!u.webkitRelativePath&&(Object.defineProperties(u,{webkitRelativePath:{writable:!0}}),u.webkitRelativePath=l.fullPath.replace(/^\//,""),Object.defineProperties(u,{webkitRelativePath:{writable:!1}})),c(u)):c(null)})})}const s=async(l,c)=>{if(l){if(l.path="",l.isFile){const u=await o(l);u&&r.push(u)}else if(l.isDirectory){const u=await i(l);n.push(...u)}}};let a=0;for(;a{const{accept:i,directory:o}=this.props;let s,a;if(typeof i=="string")a=i;else{const{filter:c,format:u}=i||{};a=u,c==="native"?s=()=>!0:s=c}return(s||(o||n?c=>HWe(c,a):()=>!0))(r)});Ie(this,"onChange",r=>{const{files:n}=r.target,i=[...n].filter(o=>this.filterFile(o));this.uploadFiles(i),this.reset()});Ie(this,"onClick",r=>{const n=this.fileInput;if(!n)return;const i=r.target,{onClick:o}=this.props;i&&i.tagName==="BUTTON"&&(n.parentNode.focus(),i.blur()),n.click(),o&&o(r)});Ie(this,"onKeyDown",r=>{r.key==="Enter"&&this.onClick(r)});Ie(this,"onDataTransferFiles",async(r,n)=>{const{multiple:i,directory:o}=this.props,s=[...r.items||[]];let a=[...r.files||[]];if((a.length>0||s.some(l=>l.kind==="file"))&&(n==null||n()),o)a=await UWe(Array.prototype.slice.call(s),this.filterFile),this.uploadFiles(a);else{let l=[...a].filter(c=>this.filterFile(c,!0));i===!1&&(l=a.slice(0,1)),this.uploadFiles(l)}});Ie(this,"onFilePaste",async r=>{const{pastable:n}=this.props;if(n&&r.type==="paste"){const i=r.clipboardData;return this.onDataTransferFiles(i,()=>{r.preventDefault()})}});Ie(this,"onFileDragOver",r=>{r.preventDefault()});Ie(this,"onFileDrop",async r=>{if(r.preventDefault(),r.type==="drop"){const n=r.dataTransfer;return this.onDataTransferFiles(n)}});Ie(this,"uploadFiles",r=>{const n=[...r],i=n.map(o=>(o.uid=EO(),this.processFile(o,n)));Promise.all(i).then(o=>{const{onBatchStart:s}=this.props;s==null||s(o.map(({origin:a,parsedFile:l})=>({file:a,parsedFile:l}))),o.filter(a=>a.parsedFile!==null).forEach(a=>{this.post(a)})})});Ie(this,"processFile",async(r,n)=>{const{beforeUpload:i}=this.props;let o=r;if(i){try{o=await i(r,n)}catch{o=!1}if(o===!1)return{origin:r,parsedFile:null,action:null,data:null}}const{action:s}=this.props;let a;typeof s=="function"?a=await s(r):a=s;const{data:l}=this.props;let c;typeof l=="function"?c=await l(r):c=l;const u=(typeof o=="object"||typeof o=="string")&&o?o:r;let d;u instanceof File?d=u:d=new File([u],r.name,{type:r.type});const h=d;return h.uid=r.uid,{origin:r,data:c,parsedFile:h,action:a}});Ie(this,"saveFileInput",r=>{this.fileInput=r})}componentDidMount(){this._isMounted=!0;const{pastable:r}=this.props;r&&document.addEventListener("paste",this.onFilePaste)}componentWillUnmount(){this._isMounted=!1,this.abort(),document.removeEventListener("paste",this.onFilePaste)}componentDidUpdate(r){const{pastable:n}=this.props;n&&!r.pastable?document.addEventListener("paste",this.onFilePaste):!n&&r.pastable&&document.removeEventListener("paste",this.onFilePaste)}post({data:r,origin:n,action:i,parsedFile:o}){if(!this._isMounted)return;const{onStart:s,customRequest:a,name:l,headers:c,withCredentials:u,method:d}=this.props,{uid:h}=n,p=a||eY,f={action:i,filename:l,data:r,file:o,headers:c,withCredentials:u,method:d||"post",onProgress:g=>{const{onProgress:m}=this.props;m==null||m(g,o)},onSuccess:(g,m)=>{const{onSuccess:v}=this.props;v==null||v(g,o,m),delete this.reqs[h]},onError:(g,m)=>{const{onError:v}=this.props;v==null||v(g,m,o),delete this.reqs[h]}};s(n),this.reqs[h]=p(f,{defaultRequest:eY})}reset(){this.setState({uid:EO()})}abort(r){const{reqs:n}=this;if(r){const i=r.uid?r.uid:r;n[i]&&n[i].abort&&n[i].abort(),delete n[i]}else Object.keys(n).forEach(i=>{n[i]&&n[i].abort&&n[i].abort(),delete n[i]})}render(){const{component:r,prefixCls:n,className:i,classNames:o={},disabled:s,id:a,name:l,style:c,styles:u={},multiple:d,accept:h,capture:p,children:f,directory:g,openFileDialogOnClick:m,onMouseEnter:v,onMouseLeave:b,hasControlInside:S,...x}=this.props,E=typeof h=="string"?h:h==null?void 0:h.format,R=Q(n,{[`${n}-disabled`]:s,[i]:i}),T=g?{directory:"directory",webkitdirectory:"webkitdirectory"}:{},M=s?{}:{onClick:m?this.onClick:()=>{},onKeyDown:m?this.onKeyDown:()=>{},onMouseEnter:v,onMouseLeave:b,onDrop:this.onFileDrop,onDragOver:this.onFileDragOver,tabIndex:S?void 0:"0"};return Z.createElement(r,_M({},M,{className:R,role:S?void 0:"button",style:c}),Z.createElement("input",_M({},ai(x,{aria:!0,data:!0}),{id:a,name:l,disabled:s,type:"file",ref:this.saveFileInput,onClick:D=>D.stopPropagation(),key:this.state.uid,style:{display:"none",...u.input},className:o.input,accept:E},T,{multiple:d,onChange:this.onChange},p!=null?{capture:p}:{})),f)}}function VG(){return VG=Object.assign?Object.assign.bind():function(e){for(var t=1;t{this.uploader=r})}abort(r){this.uploader.abort(r)}render(){return Z.createElement(qWe,VG({},this.props,{ref:this.saveUploader}))}},Ie(K2,"defaultProps",{component:"span",prefixCls:"rc-upload",data:{},headers:{},name:"file",multipart:!1,onStart:TO,onError:TO,onSuccess:TO,multiple:!1,beforeUpload:null,customRequest:null,withCredentials:!1,openFileDialogOnClick:!0,hasControlInside:!1}),K2);const XWe=e=>{const{componentCls:t,iconCls:r}=e;return{[`${t}-wrapper`]:{[`${t}-drag`]:{position:"relative",width:"100%",height:"100%",textAlign:"center",background:e.colorFillAlter,border:`${ae(e.lineWidth)} dashed ${e.colorBorder}`,borderRadius:e.borderRadiusLG,cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,[t]:{padding:e.padding},[`${t}-btn`]:{display:"table",width:"100%",height:"100%",outline:"none",borderRadius:e.borderRadiusLG,"&:focus-visible":{outline:`${ae(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`}},[`${t}-drag-container`]:{display:"table-cell",verticalAlign:"middle"},[` &:not(${t}-disabled):hover, &-hover:not(${t}-disabled) `]:{borderColor:e.colorPrimaryHover},[`p${t}-drag-icon`]:{marginBottom:e.margin,[r]:{color:e.colorPrimary,fontSize:e.uploadThumbnailSize}},[`p${t}-text`]:{margin:`0 0 ${ae(e.marginXXS)}`,color:e.colorTextHeading,fontSize:e.fontSizeLG},[`p${t}-hint`]:{color:e.colorTextDescription,fontSize:e.fontSize},[`&${t}-disabled`]:{[`p${t}-drag-icon ${r}, p${t}-text, p${t}-hint `]:{color:e.colorTextDisabled}}}}}},YWe=e=>{const{componentCls:t,iconCls:r,fontSize:n,lineHeight:i,motionDurationSlow:o,calc:s}=e,a=`${t}-list-item`,l=`${a}-actions`,c=`${a}-action`;return{[`${t}-wrapper`]:{[`${t}-list`]:{...fu(),lineHeight:e.lineHeight,[a]:{position:"relative",height:s(e.lineHeight).mul(n).equal(),marginTop:e.marginXS,fontSize:n,display:"flex",alignItems:"center",transition:`background-color ${o}`,borderRadius:e.borderRadiusSM,"&:hover":{backgroundColor:e.controlItemBgHover},[`${a}-name`]:{...Ps,padding:`0 ${ae(e.paddingXS)}`,lineHeight:i,flex:"auto",transition:`all ${o}`},[l]:{whiteSpace:"nowrap",[c]:{opacity:0},"@media (hover: none), (pointer: coarse)":{[c]:{opacity:1}},[r]:{color:e.actionsColor,transition:`all ${o}`},[` ${c}:focus-visible, &.picture ${c} `]:{opacity:1}},[`${t}-icon ${r}`]:{color:e.colorIcon,fontSize:n},[`${a}-progress`]:{position:"absolute",bottom:e.calc(e.uploadProgressOffset).mul(-1).equal(),width:"100%",paddingInlineStart:s(n).add(e.paddingXS).equal(),fontSize:n,lineHeight:0,pointerEvents:"none","> div":{margin:0}}},[`${a}:hover ${c}`]:{opacity:1},[`${a}-error`]:{color:e.colorError,[`${a}-name, ${t}-icon ${r}`]:{color:e.colorError},[l]:{[`${r}, ${r}:hover`]:{color:e.colorError},[c]:{opacity:1}}},[`${t}-list-item-container`]:{transition:["opacity","height"].map(u=>`${u} ${o}`).join(", "),"&::before":{display:"table",width:0,height:0,content:'""'}}}}}},ZWe=e=>{const{componentCls:t}=e,r=new qr("uploadAnimateInlineIn",{from:{width:0,height:0,padding:0,opacity:0,margin:e.calc(e.marginXS).div(-2).equal()}}),n=new qr("uploadAnimateInlineOut",{to:{width:0,height:0,padding:0,opacity:0,margin:e.calc(e.marginXS).div(-2).equal()}}),i=`${t}-animate-inline`;return[{[`${t}-wrapper`]:{[`${i}-appear, ${i}-enter, ${i}-leave`]:{animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseInOutCirc,animationFillMode:"forwards"},[`${i}-appear, ${i}-enter`]:{animationName:r},[`${i}-leave`]:{animationName:n}}},{[`${t}-wrapper`]:jD(e)},r,n]},QWe=e=>{const{componentCls:t,iconCls:r,uploadThumbnailSize:n,uploadProgressOffset:i,calc:o}=e,s=`${t}-list`,a=`${s}-item`;return{[`${t}-wrapper`]:{[` ${s}${s}-picture, ${s}${s}-picture-card, ${s}${s}-picture-circle `]:{[a]:{position:"relative",height:o(n).add(o(e.lineWidth).mul(2)).add(o(e.paddingXS).mul(2)).equal(),padding:e.paddingXS,border:`${ae(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusLG,"&:hover":{background:"transparent"},[`${a}-thumbnail`]:{...Ps,width:n,height:n,lineHeight:ae(o(n).add(e.paddingSM).equal()),textAlign:"center",flex:"none",[r]:{fontSize:e.fontSizeHeading2,color:e.colorPrimary},img:{display:"block",width:"100%",height:"100%",overflow:"hidden"}},[`${a}-progress`]:{bottom:o(e.fontSize).mul(e.lineHeight).div(2).add(i).equal(),width:`calc(100% - ${ae(o(e.paddingSM).mul(2).equal())})`,marginTop:0,paddingInlineStart:o(n).add(e.paddingXS).equal()}},[`${a}-error`]:{borderColor:e.colorError,[`${a}-thumbnail ${r}`]:{[`svg path[fill='${Gy[0]}']`]:{fill:e.colorErrorBg},[`svg path[fill='${Gy.primary}']`]:{fill:e.colorError}}},[`${a}-uploading`]:{borderStyle:"dashed",[`${a}-name`]:{marginBottom:i}}},[`${s}${s}-picture-circle ${a}`]:{[`&, &::before, ${a}-thumbnail`]:{borderRadius:"50%"}}}}},JWe=e=>{const{componentCls:t,iconCls:r,fontSizeLG:n,colorTextLightSolid:i,calc:o}=e,s=`${t}-list`,a=`${s}-item`,l=e.uploadPicCardSize;return{[` ${t}-wrapper${t}-picture-card-wrapper, ${t}-wrapper${t}-picture-circle-wrapper `]:{...fu(),display:"block",[`${t}${t}-select`]:{width:l,height:l,textAlign:"center",verticalAlign:"top",backgroundColor:e.colorFillAlter,border:`${ae(e.lineWidth)} dashed ${e.colorBorder}`,borderRadius:e.borderRadiusLG,cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,[`> ${t}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",textAlign:"center"},[`&:not(${t}-disabled):hover`]:{borderColor:e.colorPrimary}},[`${s}${s}-picture-card, ${s}${s}-picture-circle`]:{display:"flex",flexWrap:"wrap","&:not(:empty)":{minHeight:l},"@supports not (gap: 1px)":{"& > *":{marginBlockEnd:e.marginXS,marginInlineEnd:e.marginXS}},"@supports (gap: 1px)":{gap:e.marginXS},[`${s}-item-container`]:{display:"inline-block",width:l,height:l,verticalAlign:"top"},"&::after":{display:"none"},"&::before":{display:"none"},[a]:{height:"100%",margin:0,"&::before":{position:"absolute",zIndex:1,width:`calc(100% - ${ae(o(e.paddingXS).mul(2).equal())})`,height:`calc(100% - ${ae(o(e.paddingXS).mul(2).equal())})`,backgroundColor:e.colorBgMask,opacity:0,transition:`all ${e.motionDurationSlow}`,content:'" "'}},[`${a}:hover`]:{[`&::before, ${a}-actions`]:{opacity:1}},[`${a}-actions`]:{position:"absolute",insetInlineStart:0,zIndex:10,width:"100%",whiteSpace:"nowrap",textAlign:"center",opacity:0,transition:`all ${e.motionDurationSlow}`,[` ${r}-eye, ${r}-download, ${r}-delete `]:{zIndex:10,width:n,margin:`0 ${ae(e.marginXXS)}`,fontSize:n,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,color:i,"&:hover":{color:i},svg:{verticalAlign:"baseline"}}},[`${a}-thumbnail, ${a}-thumbnail img`]:{position:"static",display:"block",width:"100%",height:"100%",objectFit:"contain"},[`${a}-name`]:{display:"none",textAlign:"center"},[`${a}-file + ${a}-name`]:{position:"absolute",bottom:e.margin,display:"block",width:`calc(100% - ${ae(o(e.paddingXS).mul(2).equal())})`},[`${a}-uploading`]:{[`&${a}`]:{backgroundColor:e.colorFillAlter},[`&::before, ${r}-eye, ${r}-download, ${r}-delete`]:{display:"none"}},[`${a}-progress`]:{bottom:e.marginXL,width:`calc(100% - ${ae(o(e.paddingXS).mul(2).equal())})`,paddingInlineStart:0}}},[`${t}-wrapper${t}-picture-circle-wrapper`]:{[`${t}${t}-select`]:{borderRadius:"50%"}}}},e6e=e=>{const{componentCls:t}=e;return{[`${t}-rtl`]:{direction:"rtl"}}},t6e=e=>{const{componentCls:t,colorTextDisabled:r}=e;return{[`${t}-wrapper`]:{...on(e),[t]:{outline:0,"input[type='file']":{cursor:"pointer"}},[`${t}-select`]:{display:"inline-block"},[`${t}-hidden`]:{display:"none"},[`${t}-disabled`]:{color:r,cursor:"not-allowed"}}}},r6e=e=>({actionsColor:e.colorIcon,pictureCardSize:e.controlHeightLG*2.55}),n6e=Wr("Upload",e=>{const{fontSizeHeading3:t,marginXS:r,lineWidth:n,pictureCardSize:i,calc:o}=e,s=$r(e,{uploadThumbnailSize:o(t).mul(2).equal(),uploadProgressOffset:o(o(r).div(2)).add(n).equal(),uploadPicCardSize:i});return[t6e(s),XWe(s),QWe(s),JWe(s),YWe(s),ZWe(s),e6e(s),V3(s)]},r6e);var i6e={icon:function(t,r){return{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M534 352V136H232v752h560V394H576a42 42 0 01-42-42z",fill:r}},{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM602 137.8L790.2 326H602V137.8zM792 888H232V136h302v216a42 42 0 0042 42h216v494z",fill:t}}]}},name:"file",theme:"twotone"};function zG(){return zG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,zG({},e,{ref:t,icon:i6e})),s6e=y.forwardRef(o6e);var a6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M779.3 196.6c-94.2-94.2-247.6-94.2-341.7 0l-261 260.8c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l261-260.8c32.4-32.4 75.5-50.2 121.3-50.2s88.9 17.8 121.2 50.2c32.4 32.4 50.2 75.5 50.2 121.2 0 45.8-17.8 88.8-50.2 121.2l-266 265.9-43.1 43.1c-40.3 40.3-105.8 40.3-146.1 0-19.5-19.5-30.2-45.4-30.2-73s10.7-53.5 30.2-73l263.9-263.8c6.7-6.6 15.5-10.3 24.9-10.3h.1c9.4 0 18.1 3.7 24.7 10.3 6.7 6.7 10.3 15.5 10.3 24.9 0 9.3-3.7 18.1-10.3 24.7L372.4 653c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l215.6-215.6c19.9-19.9 30.8-46.3 30.8-74.4s-11-54.6-30.8-74.4c-41.1-41.1-107.9-41-149 0L463 364 224.8 602.1A172.22 172.22 0 00174 724.8c0 46.3 18.1 89.8 50.8 122.5 33.9 33.8 78.3 50.7 122.7 50.7 44.4 0 88.8-16.9 122.6-50.7l309.2-309C824.8 492.7 850 432 850 367.5c.1-64.6-25.1-125.3-70.7-170.9z"}}]},name:"paper-clip",theme:"outlined"};function HG(){return HG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,HG({},e,{ref:t,icon:a6e})),c6e=y.forwardRef(l6e);var u6e={icon:function(t,r){return{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 632H136v-39.9l138.5-164.3 150.1 178L658.1 489 888 761.6V792zm0-129.8L664.2 396.8c-3.2-3.8-9-3.8-12.2 0L424.6 666.4l-144-170.7c-3.2-3.8-9-3.8-12.2 0L136 652.7V232h752v430.2z",fill:t}},{tag:"path",attrs:{d:"M424.6 765.8l-150.1-178L136 752.1V792h752v-30.4L658.1 489z",fill:r}},{tag:"path",attrs:{d:"M136 652.7l132.4-157c3.2-3.8 9-3.8 12.2 0l144 170.7L652 396.8c3.2-3.8 9-3.8 12.2 0L888 662.2V232H136v420.7zM304 280a88 88 0 110 176 88 88 0 010-176z",fill:r}},{tag:"path",attrs:{d:"M276 368a28 28 0 1056 0 28 28 0 10-56 0z",fill:r}},{tag:"path",attrs:{d:"M304 456a88 88 0 100-176 88 88 0 000 176zm0-116c15.5 0 28 12.5 28 28s-12.5 28-28 28-28-12.5-28-28 12.5-28 28-28z",fill:t}}]}},name:"picture",theme:"twotone"};function WG(){return WG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,WG({},e,{ref:t,icon:u6e})),h6e=y.forwardRef(d6e);function vT(e){return{...e,lastModified:e.lastModified,lastModifiedDate:e.lastModifiedDate,name:e.name,size:e.size,type:e.type,uid:e.uid,percent:0,originFileObj:e}}function yT(e,t){const r=Pr(t),n=r.findIndex(({uid:i})=>i===e.uid);return n===-1?r.push(e):r[n]=e,r}function RO(e,t){const r=e.uid!==void 0?"uid":"name";return t.filter(n=>n[r]===e[r])[0]}function p6e(e,t){const r=e.uid!==void 0?"uid":"name",n=t.filter(i=>i[r]!==e[r]);return n.length===t.length?null:n}const f6e=(e="")=>{const t=e.split("/"),n=t[t.length-1].split(/#|\?/)[0];return(/\.[^./\\]*$/.exec(n)||[""])[0]},the=e=>e.indexOf("image/")===0,g6e=e=>{if(e.type&&!e.thumbUrl)return the(e.type);const t=e.thumbUrl||e.url||"",r=f6e(t);return/^data:image\//.test(t)||/(webp|svg|png|gif|jpg|jpeg|jfif|bmp|dpg|ico|heic|heif)$/i.test(r)?!0:!(/^data:/.test(t)||r)},Sh=200;function m6e(e){return new Promise(t=>{if(!e.type||!the(e.type)){t("");return}const r=document.createElement("canvas");r.width=Sh,r.height=Sh,r.style.cssText=`position: fixed; left: 0; top: 0; width: ${Sh}px; height: ${Sh}px; z-index: 9999; display: none;`,document.body.appendChild(r);const n=r.getContext("2d"),i=new Image;if(i.onload=()=>{const{width:o,height:s}=i;let a=Sh,l=Sh,c=0,u=0;o>s?(l=s*(Sh/o),u=-(l-a)/2):(a=o*(Sh/s),c=-(a-l)/2),n.drawImage(i,c,u,a,l);const d=r.toDataURL();document.body.removeChild(r),window.URL.revokeObjectURL(i.src),t(d)},i.crossOrigin="anonymous",e.type.startsWith("image/svg+xml")){const o=new FileReader;o.onload=()=>{o.result&&typeof o.result=="string"&&(i.src=o.result)},o.readAsDataURL(e)}else if(e.type.startsWith("image/gif")){const o=new FileReader;o.onload=()=>{o.result&&t(o.result)},o.readAsDataURL(e)}else i.src=window.URL.createObjectURL(e)})}var v6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M505.7 661a8 8 0 0012.6 0l112-141.7c4.1-5.2.4-12.9-6.3-12.9h-74.1V168c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v338.3H400c-6.7 0-10.4 7.7-6.3 12.9l112 141.8zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"download",theme:"outlined"};function UG(){return UG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,UG({},e,{ref:t,icon:v6e})),C6e=y.forwardRef(y6e),b6e=y.forwardRef(({prefixCls:e,className:t,style:r,classNames:n,styles:i,locale:o,listType:s,file:a,items:l,progress:c,iconRender:u,actionIconRender:d,itemRender:h,isImgUrl:p,showPreviewIcon:f,showRemoveIcon:g,showDownloadIcon:m,previewIcon:v,removeIcon:b,downloadIcon:S,extra:x,onPreview:E,onDownload:R,onClose:T},M)=>{var re,ie;const{status:D}=a,[A,I]=y.useState(D);y.useEffect(()=>{D!=="removed"&&I(D)},[D]);const[L,F]=y.useState(!1);y.useEffect(()=>{const de=setTimeout(()=>{F(!0)},300);return()=>{clearTimeout(de)}},[]);const k=u(a);let O=y.createElement("div",{className:`${e}-icon`},k);if(s==="picture"||s==="picture-card"||s==="picture-circle")if(A==="uploading"||!a.thumbUrl&&!a.url){const de=Q(`${e}-list-item-thumbnail`,{[`${e}-list-item-file`]:A!=="uploading"});O=y.createElement("div",{className:de},k)}else{const de=p!=null&&p(a)?y.createElement("img",{src:a.thumbUrl||a.url,alt:a.name,className:`${e}-list-item-image`,crossOrigin:a.crossOrigin}):k,J=Q(`${e}-list-item-thumbnail`,{[`${e}-list-item-file`]:p&&!p(a)});O=y.createElement("a",{className:J,onClick:ue=>E(a,ue),href:a.url||a.thumbUrl,target:"_blank",rel:"noopener noreferrer"},de)}const B=Q(`${e}-list-item`,`${e}-list-item-${A}`,n==null?void 0:n.item),H=typeof a.linkProps=="string"?JSON.parse(a.linkProps):a.linkProps,N=(typeof g=="function"?g(a):g)?d((typeof b=="function"?b(a):b)||y.createElement(oWe,null),()=>T(a),e,o.removeFile,!0):null,z=(typeof m=="function"?m(a):m)&&A==="done"?d((typeof S=="function"?S(a):S)||y.createElement(C6e,null),()=>R(a),e,o.downloadFile):null,W=s!=="picture-card"&&s!=="picture-circle"&&y.createElement("span",{key:"download-delete",className:Q(`${e}-list-item-actions`,{picture:s==="picture"})},z,N),V=typeof x=="function"?x(a):x,$=V&&y.createElement("span",{className:`${e}-list-item-extra`},V),K=Q(`${e}-list-item-name`),q=a.url?y.createElement("a",{key:"view",target:"_blank",rel:"noopener noreferrer",className:K,title:a.name,...H,href:a.url,onClick:de=>E(a,de)},a.name,$):y.createElement("span",{key:"view",className:K,onClick:de=>E(a,de),title:a.name},a.name,$),X=(typeof f=="function"?f(a):f)&&(a.url||a.thumbUrl)?y.createElement("a",{href:a.url||a.thumbUrl,target:"_blank",rel:"noopener noreferrer",onClick:de=>E(a,de),title:o.previewFile},typeof v=="function"?v(a):v||y.createElement(ade,null)):null,Y=(s==="picture-card"||s==="picture-circle")&&A!=="uploading"&&y.createElement("span",{className:`${e}-list-item-actions`},X,A==="done"&&z,N),{getPrefixCls:oe}=y.useContext(ir),ee=oe(),ne=y.createElement("div",{className:B,style:i==null?void 0:i.item},O,q,W,Y,L&&y.createElement(Mu,{motionName:`${ee}-fade`,visible:A==="uploading",motionDeadline:2e3},({className:de})=>{const J="percent"in a?y.createElement(qHe,{type:"line",percent:a.percent,"aria-label":a["aria-label"],"aria-labelledby":a["aria-labelledby"],...c}):null;return y.createElement("div",{className:Q(`${e}-list-item-progress`,de)},J)})),le=a.response&&typeof a.response=="string"?a.response:((re=a.error)==null?void 0:re.statusText)||((ie=a.error)==null?void 0:ie.message)||o.uploadError,he=A==="error"?y.createElement(El,{title:le,getPopupContainer:de=>de.parentNode},ne):ne;return y.createElement("div",{className:Q(`${e}-list-item-container`,t),style:r,ref:M},h?h(he,a,l,{download:R.bind(null,a),preview:E.bind(null,a),remove:T.bind(null,a)}):he)}),S6e=(e,t)=>{const{listType:r="text",previewFile:n=m6e,onPreview:i,onDownload:o,onRemove:s,locale:a,iconRender:l,isImageUrl:c=g6e,prefixCls:u,items:d=[],showPreviewIcon:h=!0,showRemoveIcon:p=!0,showDownloadIcon:f=!1,removeIcon:g,previewIcon:m,downloadIcon:v,extra:b,progress:S={size:[-1,2],showInfo:!1},appendAction:x,appendActionVisible:E=!0,itemRender:R,disabled:T,classNames:M,styles:D}=e,[,A]=k3(),[I,L]=y.useState(!1),F=["picture-card","picture-circle"].includes(r);y.useEffect(()=>{r.startsWith("picture")&&(d||[]).forEach(X=>{!(X.originFileObj instanceof File||X.originFileObj instanceof Blob)||X.thumbUrl!==void 0||(X.thumbUrl="",n==null||n(X.originFileObj).then(Y=>{X.thumbUrl=Y||"",A()}))})},[r,d,n]),y.useEffect(()=>{L(!0)},[]);const k=(X,Y)=>{if(i)return Y==null||Y.preventDefault(),i(X)},O=X=>{typeof o=="function"?o(X):X.url&&window.open(X.url)},B=X=>{s==null||s(X)},H=X=>{if(l)return l(X,r);const Y=X.status==="uploading";if(r.startsWith("picture")){const oe=r==="picture"?y.createElement(rm,null):a.uploading,ee=c!=null&&c(X)?y.createElement(h6e,null):y.createElement(s6e,null);return Y?oe:ee}return Y?y.createElement(rm,null):y.createElement(c6e,null)},N=(X,Y,oe,ee,ne)=>{const le={type:"text",size:"small",title:ee,onClick:he=>{var re,ie;Y(),y.isValidElement(X)&&((ie=(re=X.props).onClick)==null||ie.call(re,he))},className:`${oe}-list-item-action`,disabled:ne?T:!1};return y.isValidElement(X)?y.createElement(ca,{...le,icon:Ei(X,{...X.props,onClick:()=>{}})}):y.createElement(ca,{...le},y.createElement("span",null,X))};y.useImperativeHandle(t,()=>({handlePreview:k,handleDownload:O}));const{getPrefixCls:z}=y.useContext(ir),W=z("upload",u),V=z(),$=Q(`${W}-list`,`${W}-list-${r}`,M==null?void 0:M.list),K=y.useMemo(()=>fn(B3(V),["onAppearEnd","onEnterEnd","onLeaveEnd"]),[V]),q={...F?{}:K,motionDeadline:2e3,motionName:`${W}-${F?"animate-inline":"animate"}`,keys:Pr(d.map(X=>({key:X.uid,file:X}))),motionAppear:I};return y.createElement("div",{className:$,style:D==null?void 0:D.list},y.createElement(zAe,{...q,component:!1},({key:X,file:Y,className:oe,style:ee})=>y.createElement(b6e,{key:X,locale:a,prefixCls:W,className:oe,style:ee,classNames:M,styles:D,file:Y,items:d,progress:S,listType:r,isImgUrl:c,showPreviewIcon:h,showRemoveIcon:p,showDownloadIcon:f,removeIcon:g,previewIcon:m,downloadIcon:v,extra:b,iconRender:H,actionIconRender:N,itemRender:R,onPreview:k,onDownload:O,onClose:B})),x&&y.createElement(Mu,{...q,visible:E,forceRender:!0},({className:X,style:Y})=>Ei(x,oe=>({className:Q(oe.className,X),style:{...Y,pointerEvents:X?"none":void 0,...oe.style}}))))},w6e=y.forwardRef(S6e),sw=`__LIST_IGNORE_${Date.now()}__`,x6e=(e,t)=>{const r=Nr("upload"),{fileList:n,defaultFileList:i,onRemove:o,showUploadList:s=!0,listType:a="text",onPreview:l,onDownload:c,onChange:u,onDrop:d,previewFile:h,disabled:p,locale:f,iconRender:g,isImageUrl:m,progress:v,prefixCls:b,className:S,type:x="select",children:E,style:R,itemRender:T,maxCount:M,data:D={},multiple:A=!1,hasControlInside:I=!0,action:L="",accept:F="",supportServerRender:k=!0,rootClassName:O,styles:B,classNames:H}=e,N=y.useContext(hs),z=p??N,W=e.customRequest||r.customRequest,[V,$]=An(i,n),K=V||[],[q,X]=y.useState("drop"),Y=y.useRef(null),oe=y.useRef(null);y.useMemo(()=>{const _e=Date.now();(n||[]).forEach((qe,Re)=>{!qe.uid&&!Object.isFrozen(qe)&&(qe.uid=`__AUTO__${_e}_${Re}__`)})},[n]);const ee=(_e,qe,Re)=>{let it=Pr(qe),Ve=!1;M===1?it=it.slice(-1):M&&(Ve=it.length>M,it=it.slice(0,M)),$a.flushSync(()=>{$(it)});const Oe={file:_e,fileList:it};Re&&(Oe.event=Re),(!Ve||_e.status==="removed"||it.some(se=>se.uid===_e.uid))&&$a.flushSync(()=>{u==null||u(Oe)})},ne=async(_e,qe)=>{const{beforeUpload:Re}=e;let it=_e;if(Re){const Ve=await Re(_e,qe);if(Ve===!1)return!1;if(delete _e[sw],Ve===sw)return Object.defineProperty(_e,sw,{value:!0,configurable:!0}),!1;typeof Ve=="object"&&Ve&&(it=Ve)}return it},le=_e=>{const qe=_e.filter(Ve=>!Ve.file[sw]);if(!qe.length)return;const Re=qe.map(Ve=>vT(Ve.file));let it=Pr(K);Re.forEach(Ve=>{it=yT(Ve,it)}),Re.forEach((Ve,Oe)=>{let se=Ve;if(qe[Oe].parsedFile)Ve.status="uploading";else{const{originFileObj:ce}=Ve;let fe;try{fe=new File([ce],ce.name,{type:ce.type})}catch{fe=new Blob([ce],{type:ce.type}),fe.name=ce.name,fe.lastModifiedDate=new Date,fe.lastModified=new Date().getTime()}fe.uid=Ve.uid,se=fe}ee(se,it)})},he=(_e,qe,Re)=>{try{typeof _e=="string"&&(_e=JSON.parse(_e))}catch{}if(!RO(qe,K))return;const it=vT(qe);it.status="done",it.percent=100,it.response=_e,it.xhr=Re;const Ve=yT(it,K);ee(it,Ve)},re=(_e,qe)=>{if(!RO(qe,K))return;const Re=vT(qe);Re.status="uploading",Re.percent=_e.percent;const it=yT(Re,K);ee(Re,it,_e)},ie=(_e,qe,Re)=>{if(!RO(Re,K))return;const it=vT(Re);it.error=_e,it.response=qe,it.status="error";const Ve=yT(it,K);ee(it,Ve)},de=_e=>{let qe;Promise.resolve(typeof o=="function"?o(_e):o).then(Re=>{var Ve;if(Re===!1)return;const it=p6e(_e,K);it&&(qe={..._e,status:"removed"},K==null||K.forEach(Oe=>{const se=qe.uid!==void 0?"uid":"name";Oe[se]===qe[se]&&!Object.isFrozen(Oe)&&(Oe.status="removed")}),(Ve=Y.current)==null||Ve.abort(qe),ee(qe,it))})},J=_e=>{X(_e.type),_e.type==="drop"&&(d==null||d(_e))};y.useImperativeHandle(t,()=>({onBatchStart:le,onSuccess:he,onProgress:re,onError:ie,fileList:K,upload:Y.current,nativeElement:oe.current}));const{getPrefixCls:ue,direction:ve,className:pe,style:me,classNames:ke,styles:De}=Nr("upload"),Ee=ue("upload",b),We={...e,listType:a,showUploadList:s,type:x,multiple:A,hasControlInside:I,supportServerRender:k,disabled:z},[ze,mt]=Vr([ke,H],[De,B],{props:We}),Nt={onBatchStart:le,onError:ie,onProgress:re,onSuccess:he,...e,customRequest:W,data:D,multiple:A,action:L,accept:F,supportServerRender:k,prefixCls:Ee,disabled:z,beforeUpload:ne,onChange:void 0,hasControlInside:I};delete Nt.className,delete Nt.style,(!E||z)&&delete Nt.id;const St=`${Ee}-wrapper`,[Ze,Fe]=n6e(Ee,St),[tt]=Dl("Upload",xl.Upload),{showRemoveIcon:Ne,showPreviewIcon:rt,showDownloadIcon:ot,removeIcon:Ye,previewIcon:Ae,downloadIcon:nt,extra:Et}=typeof s=="boolean"?{}:s,Tt=typeof Ne>"u"?!z:Ne,kt=(_e,qe)=>s?y.createElement(w6e,{classNames:ze,styles:mt,prefixCls:Ee,listType:a,items:K,previewFile:h,onPreview:l,onDownload:c,onRemove:de,showRemoveIcon:Tt,showPreviewIcon:rt,showDownloadIcon:ot,removeIcon:Ye,previewIcon:Ae,downloadIcon:nt,iconRender:g,extra:Et,locale:{...tt,...f},isImageUrl:m,progress:v,appendAction:_e,appendActionVisible:qe,itemRender:T,disabled:z}):_e,Wt=Q(St,S,O,Ze,Fe,pe,ze.root,{[`${Ee}-rtl`]:ve==="rtl",[`${Ee}-picture-card-wrapper`]:a==="picture-card",[`${Ee}-picture-circle-wrapper`]:a==="picture-circle"}),at={...mt.root},lt={...me,...R};if(x==="drag"){const _e=Q(Ze,Ee,`${Ee}-drag`,{[`${Ee}-drag-uploading`]:K.some(qe=>qe.status==="uploading"),[`${Ee}-drag-hover`]:q==="dragover",[`${Ee}-disabled`]:z,[`${Ee}-rtl`]:ve==="rtl"},ze.trigger);return y.createElement("span",{className:Wt,ref:oe,style:at},y.createElement("div",{className:_e,style:{...lt,...mt.trigger},onDrop:J,onDragOver:J,onDragLeave:J},y.createElement(tY,{...Nt,ref:Y,className:`${Ee}-btn`},y.createElement("div",{className:`${Ee}-drag-container`},E))),kt())}const Ut=Q(Ee,`${Ee}-select`,{[`${Ee}-disabled`]:z,[`${Ee}-hidden`]:!E},ze.trigger),cr=y.createElement("div",{className:Ut,style:{...lt,...mt.trigger}},y.createElement(tY,{...Nt,ref:Y}));return a==="picture-card"||a==="picture-circle"?y.createElement("span",{className:Wt,ref:oe,style:at},kt(cr,!!E)):y.createElement("span",{className:Wt,ref:oe,style:at},cr,kt())},rhe=y.forwardRef(x6e),E6e=y.forwardRef((e,t)=>{const{style:r,height:n,hasControlInside:i=!1,children:o,...s}=e,a={...r,height:n};return y.createElement(rhe,{ref:t,hasControlInside:i,...s,style:a,type:"drag"},o)}),nhe=rhe;nhe.Dragger=E6e;nhe.LIST_IGNORE=sw;var T6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M862 465.3h-81c-4.6 0-9 2-12.1 5.5L550 723.1V160c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v563.1L255.1 470.8c-3-3.5-7.4-5.5-12.1-5.5h-81c-6.8 0-10.5 8.1-6 13.2L487.9 861a31.96 31.96 0 0048.3 0L868 478.5c4.5-5.2.8-13.2-6-13.2z"}}]},name:"arrow-down",theme:"outlined"};function jG(){return jG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,jG({},e,{ref:t,icon:T6e})),$Bt=y.forwardRef(R6e);var P6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"arrow-left",theme:"outlined"};function KG(){return KG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,KG({},e,{ref:t,icon:P6e})),GBt=y.forwardRef(M6e);var I6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M868 545.5L536.1 163a31.96 31.96 0 00-48.3 0L156 545.5a7.97 7.97 0 006 13.2h81c4.6 0 9-2 12.1-5.5L474 300.9V864c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V300.9l218.9 252.3c3 3.5 7.4 5.5 12.1 5.5h81c6.8 0 10.5-8 6-13.2z"}}]},name:"arrow-up",theme:"outlined"};function qG(){return qG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,qG({},e,{ref:t,icon:I6e})),VBt=y.forwardRef(D6e);var A6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M632 888H392c-4.4 0-8 3.6-8 8v32c0 17.7 14.3 32 32 32h192c17.7 0 32-14.3 32-32v-32c0-4.4-3.6-8-8-8zM512 64c-181.1 0-328 146.9-328 328 0 121.4 66 227.4 164 284.1V792c0 17.7 14.3 32 32 32h264c17.7 0 32-14.3 32-32V676.1c98-56.7 164-162.7 164-284.1 0-181.1-146.9-328-328-328zm127.9 549.8L604 634.6V752H420V634.6l-35.9-20.8C305.4 568.3 256 484.5 256 392c0-141.4 114.6-256 256-256s256 114.6 256 256c0 92.5-49.4 176.3-128.1 221.8z"}}]},name:"bulb",theme:"outlined"};function XG(){return XG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,XG({},e,{ref:t,icon:A6e})),zBt=y.forwardRef(F6e);var L6e={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm0 76c-205.4 0-372 166.6-372 372s166.6 372 372 372 372-166.6 372-372-166.6-372-372-372zm128.01 198.83c.03 0 .05.01.09.06l45.02 45.01a.2.2 0 01.05.09.12.12 0 010 .07c0 .02-.01.04-.05.08L557.25 512l127.87 127.86a.27.27 0 01.05.06v.02a.12.12 0 010 .07c0 .03-.01.05-.05.09l-45.02 45.02a.2.2 0 01-.09.05.12.12 0 01-.07 0c-.02 0-.04-.01-.08-.05L512 557.25 384.14 685.12c-.04.04-.06.05-.08.05a.12.12 0 01-.07 0c-.03 0-.05-.01-.09-.05l-45.02-45.02a.2.2 0 01-.05-.09.12.12 0 010-.07c0-.02.01-.04.06-.08L466.75 512 338.88 384.14a.27.27 0 01-.05-.06l-.01-.02a.12.12 0 010-.07c0-.03.01-.05.05-.09l45.02-45.02a.2.2 0 01.09-.05.12.12 0 01.07 0c.02 0 .04.01.08.06L512 466.75l127.86-127.86c.04-.05.06-.06.08-.06a.12.12 0 01.07 0z"}}]},name:"close-circle",theme:"outlined"};function YG(){return YG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,YG({},e,{ref:t,icon:L6e})),HBt=y.forwardRef(_6e);var O6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 128c-212.1 0-384 171.9-384 384v360c0 13.3 10.7 24 24 24h184c35.3 0 64-28.7 64-64V624c0-35.3-28.7-64-64-64H200v-48c0-172.3 139.7-312 312-312s312 139.7 312 312v48H688c-35.3 0-64 28.7-64 64v208c0 35.3 28.7 64 64 64h184c13.3 0 24-10.7 24-24V512c0-212.1-171.9-384-384-384zM328 632v192H200V632h128zm496 192H696V632h128v192z"}}]},name:"customer-service",theme:"outlined"};function ZG(){return ZG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,ZG({},e,{ref:t,icon:O6e})),WBt=y.forwardRef(k6e);var N6e={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M885.2 446.3l-.2-.8-112.2-285.1c-5-16.1-19.9-27.2-36.8-27.2H281.2c-17 0-32.1 11.3-36.9 27.6L139.4 443l-.3.7-.2.8c-1.3 4.9-1.7 9.9-1 14.8-.1 1.6-.2 3.2-.2 4.8V830a60.9 60.9 0 0060.8 60.8h627.2c33.5 0 60.8-27.3 60.9-60.8V464.1c0-1.3 0-2.6-.1-3.7.4-4.9 0-9.6-1.3-14.1zm-295.8-43l-.3 15.7c-.8 44.9-31.8 75.1-77.1 75.1-22.1 0-41.1-7.1-54.8-20.6S436 441.2 435.6 419l-.3-15.7H229.5L309 210h399.2l81.7 193.3H589.4zm-375 76.8h157.3c24.3 57.1 76 90.8 140.4 90.8 33.7 0 65-9.4 90.3-27.2 22.2-15.6 39.5-37.4 50.7-63.6h156.5V814H214.4V480.1z"}}]},name:"inbox",theme:"outlined"};function QG(){return QG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,QG({},e,{ref:t,icon:N6e})),UBt=y.forwardRef(B6e);var $6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M885.9 533.7c16.8-22.2 26.1-49.4 26.1-77.7 0-44.9-25.1-87.4-65.5-111.1a67.67 67.67 0 00-34.3-9.3H572.4l6-122.9c1.4-29.7-9.1-57.9-29.5-79.4A106.62 106.62 0 00471 99.9c-52 0-98 35-111.8 85.1l-85.9 311h-.3v428h472.3c9.2 0 18.2-1.8 26.5-5.4 47.6-20.3 78.3-66.8 78.3-118.4 0-12.6-1.8-25-5.4-37 16.8-22.2 26.1-49.4 26.1-77.7 0-12.6-1.8-25-5.4-37 16.8-22.2 26.1-49.4 26.1-77.7-.2-12.6-2-25.1-5.6-37.1zM112 528v364c0 17.7 14.3 32 32 32h65V496h-65c-17.7 0-32 14.3-32 32z"}}]},name:"like",theme:"filled"};function JG(){return JG=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,JG({},e,{ref:t,icon:$6e})),jBt=y.forwardRef(G6e);var V6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.3 338.4a447.57 447.57 0 00-96.1-143.3 443.09 443.09 0 00-143-96.3A443.91 443.91 0 00512 64h-2c-60.5.3-119 12.3-174.1 35.9a444.08 444.08 0 00-141.7 96.5 445 445 0 00-95 142.8A449.89 449.89 0 0065 514.1c.3 69.4 16.9 138.3 47.9 199.9v152c0 25.4 20.6 46 45.9 46h151.8a447.72 447.72 0 00199.5 48h2.1c59.8 0 117.7-11.6 172.3-34.3A443.2 443.2 0 00827 830.5c41.2-40.9 73.6-88.7 96.3-142 23.5-55.2 35.5-113.9 35.8-174.5.2-60.9-11.6-120-34.8-175.6zM312.4 560c-26.4 0-47.9-21.5-47.9-48s21.5-48 47.9-48 47.9 21.5 47.9 48-21.4 48-47.9 48zm199.6 0c-26.4 0-47.9-21.5-47.9-48s21.5-48 47.9-48 47.9 21.5 47.9 48-21.5 48-47.9 48zm199.6 0c-26.4 0-47.9-21.5-47.9-48s21.5-48 47.9-48 47.9 21.5 47.9 48-21.5 48-47.9 48z"}}]},name:"message",theme:"filled"};function eV(){return eV=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,eV({},e,{ref:t,icon:V6e})),KBt=y.forwardRef(z6e);var H6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M931.4 498.9L94.9 79.5c-3.4-1.7-7.3-2.1-11-1.2a15.99 15.99 0 00-11.7 19.3l86.2 352.2c1.3 5.3 5.2 9.6 10.4 11.3l147.7 50.7-147.6 50.7c-5.2 1.8-9.1 6-10.3 11.3L72.2 926.5c-.9 3.7-.5 7.6 1.2 10.9 3.9 7.9 13.5 11.1 21.5 7.2l836.5-417c3.1-1.5 5.6-4.1 7.2-7.1 3.9-8 .7-17.6-7.2-21.6zM170.8 826.3l50.3-205.6 295.2-101.3c2.3-.8 4.2-2.6 5-5 1.4-4.2-.8-8.7-5-10.2L221.1 403 171 198.2l628 314.9-628.2 313.2z"}}]},name:"send",theme:"outlined"};function tV(){return tV=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,tV({},e,{ref:t,icon:H6e})),qBt=y.forwardRef(W6e);var U6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z"}}]},name:"setting",theme:"outlined"};function rV(){return rV=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,rV({},e,{ref:t,icon:U6e})),XBt=y.forwardRef(j6e);var K6e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M858.5 763.6a374 374 0 00-80.6-119.5 375.63 375.63 0 00-119.5-80.6c-.4-.2-.8-.3-1.2-.5C719.5 518 760 444.7 760 362c0-137-111-248-248-248S264 225 264 362c0 82.7 40.5 156 102.8 201.1-.4.2-.8.3-1.2.5-44.8 18.9-85 46-119.5 80.6a375.63 375.63 0 00-80.6 119.5A371.7 371.7 0 00136 901.8a8 8 0 008 8.2h60c4.4 0 7.9-3.5 8-7.8 2-77.2 33-149.5 87.8-204.3 56.7-56.7 132-87.9 212.2-87.9s155.5 31.2 212.2 87.9C779 752.7 810 825 812 902.2c.1 4.4 3.6 7.8 8 7.8h60a8 8 0 008-8.2c-1-47.8-10.9-94.3-29.5-138.2zM512 534c-45.9 0-89.1-17.9-121.6-50.4S340 407.9 340 362c0-45.9 17.9-89.1 50.4-121.6S466.1 190 512 190s89.1 17.9 121.6 50.4S684 316.1 684 362c0 45.9-17.9 89.1-50.4 121.6S557.9 534 512 534z"}}]},name:"user",theme:"outlined"};function nV(){return nV=Object.assign?Object.assign.bind():function(e){for(var t=1;ty.createElement(Sr,nV({},e,{ref:t,icon:K6e})),YBt=y.forwardRef(q6e),X6e=e=>{const t=y.useRef(e);return y.useEffect(()=>{t.current=e}),t},Y6e=(e,t=100,r=!1)=>{const n=X6e(e),i=y.useRef(),o=[t,r,n];function s(){i.current&&clearTimeout(i.current),i.current=void 0}y.useEffect(()=>s,o);function a(){i.current=void 0}return y.useCallback(function(){const l=arguments,{current:c}=i;if(c===void 0&&r)return i.current=setTimeout(a,t),n.current.apply(null,l);c&&clearTimeout(c),i.current=setTimeout(()=>{i.current=void 0,n.current.apply(null,l)},t)},o)},ZBt=(e,t,r)=>{const n=y.useState(e);return[n[0],Y6e(n[1],t,r),n[1]]},Z6e="modulepreload",Q6e=function(e){return"/"+e},rY={},J6e=function(t,r,n){let i=Promise.resolve();if(r&&r.length>0){let s=function(c){return Promise.all(c.map(u=>Promise.resolve(u).then(d=>({status:"fulfilled",value:d}),d=>({status:"rejected",reason:d}))))};document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),l=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));i=s(r.map(c=>{if(c=Q6e(c),c in rY)return;rY[c]=!0;const u=c.endsWith(".css"),d=u?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${d}`))return;const h=document.createElement("link");if(h.rel=u?"stylesheet":Z6e,u||(h.as="script"),h.crossOrigin="",h.href=c,l&&h.setAttribute("nonce",l),document.head.appendChild(h),u)return new Promise((p,f)=>{h.addEventListener("load",p),h.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${c}`)))})}))}function o(s){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=s,window.dispatchEvent(a),!a.defaultPrevented)throw s}return i.then(s=>{for(const a of s||[])a.status==="rejected"&&o(a.reason);return t().catch(o)})};var Bw=(e=>(e.DEV="dev",e.STAGE="stage",e.PROD="prod",e))(Bw||{});const wa={code:"code",error:"error",state:"state",clientId:"client_id",audience:"audience",prompt:"prompt",redirectUri:"redirect_uri",scope:"scope",responseType:"response_type",codeChallengeMethod:"code_challenge_method",codeChallenge:"code_challenge",phone:"phone"},e8e={consent:"consent"},t8e={code:"code"},r8e={S256:"S256"};function ihe(e,t){return function(){return e.apply(t,arguments)}}const{toString:n8e}=Object.prototype,{getPrototypeOf:W4}=Object,{iterator:dA,toStringTag:ohe}=Symbol,hA=(e=>t=>{const r=n8e.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Ec=e=>(e=e.toLowerCase(),t=>hA(t)===e),pA=e=>t=>typeof t===e,{isArray:VC}=Array,qy=pA("undefined");function r1(e){return e!==null&&!qy(e)&&e.constructor!==null&&!qy(e.constructor)&&ra(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const she=Ec("ArrayBuffer");function i8e(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&she(e.buffer),t}const o8e=pA("string"),ra=pA("function"),ahe=pA("number"),n1=e=>e!==null&&typeof e=="object",s8e=e=>e===!0||e===!1,vP=e=>{if(hA(e)!=="object")return!1;const t=W4(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(ohe in e)&&!(dA in e)},a8e=e=>{if(!n1(e)||r1(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},l8e=Ec("Date"),c8e=Ec("File"),u8e=Ec("Blob"),d8e=Ec("FileList"),h8e=e=>n1(e)&&ra(e.pipe),p8e=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||ra(e.append)&&((t=hA(e))==="formdata"||t==="object"&&ra(e.toString)&&e.toString()==="[object FormData]"))},f8e=Ec("URLSearchParams"),[g8e,m8e,v8e,y8e]=["ReadableStream","Request","Response","Headers"].map(Ec),C8e=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function i1(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,i;if(typeof e!="object"&&(e=[e]),VC(e))for(n=0,i=e.length;n0;)if(i=r[n],t===i.toLowerCase())return i;return null}const Sg=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,che=e=>!qy(e)&&e!==Sg;function iV(){const{caseless:e,skipUndefined:t}=che(this)&&this||{},r={},n=(i,o)=>{const s=e&&lhe(r,o)||o;vP(r[s])&&vP(i)?r[s]=iV(r[s],i):vP(i)?r[s]=iV({},i):VC(i)?r[s]=i.slice():(!t||!qy(i))&&(r[s]=i)};for(let i=0,o=arguments.length;i(i1(t,(i,o)=>{r&&ra(i)?e[o]=ihe(i,r):e[o]=i},{allOwnKeys:n}),e),S8e=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),w8e=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},x8e=(e,t,r,n)=>{let i,o,s;const a={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)s=i[o],(!n||n(s,e,t))&&!a[s]&&(t[s]=e[s],a[s]=!0);e=r!==!1&&W4(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},E8e=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},T8e=e=>{if(!e)return null;if(VC(e))return e;let t=e.length;if(!ahe(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},R8e=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&W4(Uint8Array)),P8e=(e,t)=>{const n=(e&&e[dA]).call(e);let i;for(;(i=n.next())&&!i.done;){const o=i.value;t.call(e,o[0],o[1])}},M8e=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},I8e=Ec("HTMLFormElement"),D8e=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,i){return n.toUpperCase()+i}),nY=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),A8e=Ec("RegExp"),uhe=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};i1(r,(i,o)=>{let s;(s=t(i,o,e))!==!1&&(n[o]=s||i)}),Object.defineProperties(e,n)},F8e=e=>{uhe(e,(t,r)=>{if(ra(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(ra(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},L8e=(e,t)=>{const r={},n=i=>{i.forEach(o=>{r[o]=!0})};return VC(e)?n(e):n(String(e).split(t)),r},_8e=()=>{},O8e=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function k8e(e){return!!(e&&ra(e.append)&&e[ohe]==="FormData"&&e[dA])}const N8e=e=>{const t=new Array(10),r=(n,i)=>{if(n1(n)){if(t.indexOf(n)>=0)return;if(r1(n))return n;if(!("toJSON"in n)){t[i]=n;const o=VC(n)?[]:{};return i1(n,(s,a)=>{const l=r(s,i+1);!qy(l)&&(o[a]=l)}),t[i]=void 0,o}}return n};return r(e,0)},B8e=Ec("AsyncFunction"),$8e=e=>e&&(n1(e)||ra(e))&&ra(e.then)&&ra(e.catch),dhe=((e,t)=>e?setImmediate:t?((r,n)=>(Sg.addEventListener("message",({source:i,data:o})=>{i===Sg&&o===r&&n.length&&n.shift()()},!1),i=>{n.push(i),Sg.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",ra(Sg.postMessage)),G8e=typeof queueMicrotask<"u"?queueMicrotask.bind(Sg):typeof process<"u"&&process.nextTick||dhe,V8e=e=>e!=null&&ra(e[dA]),Ke={isArray:VC,isArrayBuffer:she,isBuffer:r1,isFormData:p8e,isArrayBufferView:i8e,isString:o8e,isNumber:ahe,isBoolean:s8e,isObject:n1,isPlainObject:vP,isEmptyObject:a8e,isReadableStream:g8e,isRequest:m8e,isResponse:v8e,isHeaders:y8e,isUndefined:qy,isDate:l8e,isFile:c8e,isBlob:u8e,isRegExp:A8e,isFunction:ra,isStream:h8e,isURLSearchParams:f8e,isTypedArray:R8e,isFileList:d8e,forEach:i1,merge:iV,extend:b8e,trim:C8e,stripBOM:S8e,inherits:w8e,toFlatObject:x8e,kindOf:hA,kindOfTest:Ec,endsWith:E8e,toArray:T8e,forEachEntry:P8e,matchAll:M8e,isHTMLForm:I8e,hasOwnProperty:nY,hasOwnProp:nY,reduceDescriptors:uhe,freezeMethods:F8e,toObjectSet:L8e,toCamelCase:D8e,noop:_8e,toFiniteNumber:O8e,findKey:lhe,global:Sg,isContextDefined:che,isSpecCompliantForm:k8e,toJSONObject:N8e,isAsyncFn:B8e,isThenable:$8e,setImmediate:dhe,asap:G8e,isIterable:V8e};function Xr(e,t,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i,this.status=i.status?i.status:null)}Ke.inherits(Xr,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Ke.toJSONObject(this.config),code:this.code,status:this.status}}});const hhe=Xr.prototype,phe={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{phe[e]={value:e}});Object.defineProperties(Xr,phe);Object.defineProperty(hhe,"isAxiosError",{value:!0});Xr.from=(e,t,r,n,i,o)=>{const s=Object.create(hhe);Ke.toFlatObject(e,s,function(u){return u!==Error.prototype},c=>c!=="isAxiosError");const a=e&&e.message?e.message:"Error",l=t==null&&e?e.code:t;return Xr.call(s,a,l,r,n,i),e&&s.cause==null&&Object.defineProperty(s,"cause",{value:e,configurable:!0}),s.name=e&&e.name||"Error",o&&Object.assign(s,o),s};const z8e=null;function oV(e){return Ke.isPlainObject(e)||Ke.isArray(e)}function fhe(e){return Ke.endsWith(e,"[]")?e.slice(0,-2):e}function iY(e,t,r){return e?e.concat(t).map(function(i,o){return i=fhe(i),!r&&o?"["+i+"]":i}).join(r?".":""):t}function H8e(e){return Ke.isArray(e)&&!e.some(oV)}const W8e=Ke.toFlatObject(Ke,{},null,function(t){return/^is[A-Z]/.test(t)});function fA(e,t,r){if(!Ke.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=Ke.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(g,m){return!Ke.isUndefined(m[g])});const n=r.metaTokens,i=r.visitor||u,o=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&Ke.isSpecCompliantForm(t);if(!Ke.isFunction(i))throw new TypeError("visitor must be a function");function c(f){if(f===null)return"";if(Ke.isDate(f))return f.toISOString();if(Ke.isBoolean(f))return f.toString();if(!l&&Ke.isBlob(f))throw new Xr("Blob is not supported. Use a Buffer instead.");return Ke.isArrayBuffer(f)||Ke.isTypedArray(f)?l&&typeof Blob=="function"?new Blob([f]):Buffer.from(f):f}function u(f,g,m){let v=f;if(f&&!m&&typeof f=="object"){if(Ke.endsWith(g,"{}"))g=n?g:g.slice(0,-2),f=JSON.stringify(f);else if(Ke.isArray(f)&&H8e(f)||(Ke.isFileList(f)||Ke.endsWith(g,"[]"))&&(v=Ke.toArray(f)))return g=fhe(g),v.forEach(function(S,x){!(Ke.isUndefined(S)||S===null)&&t.append(s===!0?iY([g],x,o):s===null?g:g+"[]",c(S))}),!1}return oV(f)?!0:(t.append(iY(m,g,o),c(f)),!1)}const d=[],h=Object.assign(W8e,{defaultVisitor:u,convertValue:c,isVisitable:oV});function p(f,g){if(!Ke.isUndefined(f)){if(d.indexOf(f)!==-1)throw Error("Circular reference detected in "+g.join("."));d.push(f),Ke.forEach(f,function(v,b){(!(Ke.isUndefined(v)||v===null)&&i.call(t,v,Ke.isString(b)?b.trim():b,g,h))===!0&&p(v,g?g.concat(b):[b])}),d.pop()}}if(!Ke.isObject(e))throw new TypeError("data must be an object");return p(e),t}function oY(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function U4(e,t){this._pairs=[],e&&fA(e,this,t)}const ghe=U4.prototype;ghe.append=function(t,r){this._pairs.push([t,r])};ghe.toString=function(t){const r=t?function(n){return t.call(this,n,oY)}:oY;return this._pairs.map(function(i){return r(i[0])+"="+r(i[1])},"").join("&")};function U8e(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function mhe(e,t,r){if(!t)return e;const n=r&&r.encode||U8e;Ke.isFunction(r)&&(r={serialize:r});const i=r&&r.serialize;let o;if(i?o=i(t,r):o=Ke.isURLSearchParams(t)?t.toString():new U4(t,r).toString(n),o){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class sY{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){Ke.forEach(this.handlers,function(n){n!==null&&t(n)})}}const vhe={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},j8e=typeof URLSearchParams<"u"?URLSearchParams:U4,K8e=typeof FormData<"u"?FormData:null,q8e=typeof Blob<"u"?Blob:null,X8e={isBrowser:!0,classes:{URLSearchParams:j8e,FormData:K8e,Blob:q8e},protocols:["http","https","file","blob","url","data"]},j4=typeof window<"u"&&typeof document<"u",sV=typeof navigator=="object"&&navigator||void 0,Y8e=j4&&(!sV||["ReactNative","NativeScript","NS"].indexOf(sV.product)<0),Z8e=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Q8e=j4&&window.location.href||"http://localhost",J8e=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:j4,hasStandardBrowserEnv:Y8e,hasStandardBrowserWebWorkerEnv:Z8e,navigator:sV,origin:Q8e},Symbol.toStringTag,{value:"Module"})),as={...J8e,...X8e};function eUe(e,t){return fA(e,new as.classes.URLSearchParams,{visitor:function(r,n,i,o){return as.isNode&&Ke.isBuffer(r)?(this.append(n,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...t})}function tUe(e){return Ke.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function rUe(e){const t={},r=Object.keys(e);let n;const i=r.length;let o;for(n=0;n=r.length;return s=!s&&Ke.isArray(i)?i.length:s,l?(Ke.hasOwnProp(i,s)?i[s]=[i[s],n]:i[s]=n,!a):((!i[s]||!Ke.isObject(i[s]))&&(i[s]=[]),t(r,n,i[s],o)&&Ke.isArray(i[s])&&(i[s]=rUe(i[s])),!a)}if(Ke.isFormData(e)&&Ke.isFunction(e.entries)){const r={};return Ke.forEachEntry(e,(n,i)=>{t(tUe(n),i,r,0)}),r}return null}function nUe(e,t,r){if(Ke.isString(e))try{return(t||JSON.parse)(e),Ke.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const o1={transitional:vhe,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",i=n.indexOf("application/json")>-1,o=Ke.isObject(t);if(o&&Ke.isHTMLForm(t)&&(t=new FormData(t)),Ke.isFormData(t))return i?JSON.stringify(yhe(t)):t;if(Ke.isArrayBuffer(t)||Ke.isBuffer(t)||Ke.isStream(t)||Ke.isFile(t)||Ke.isBlob(t)||Ke.isReadableStream(t))return t;if(Ke.isArrayBufferView(t))return t.buffer;if(Ke.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return eUe(t,this.formSerializer).toString();if((a=Ke.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return fA(a?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||i?(r.setContentType("application/json",!1),nUe(t)):t}],transformResponse:[function(t){const r=this.transitional||o1.transitional,n=r&&r.forcedJSONParsing,i=this.responseType==="json";if(Ke.isResponse(t)||Ke.isReadableStream(t))return t;if(t&&Ke.isString(t)&&(n&&!this.responseType||i)){const s=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(t,this.parseReviver)}catch(a){if(s)throw a.name==="SyntaxError"?Xr.from(a,Xr.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:as.classes.FormData,Blob:as.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Ke.forEach(["delete","get","head","post","put","patch"],e=>{o1.headers[e]={}});const iUe=Ke.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),oUe=e=>{const t={};let r,n,i;return e&&e.split(` `).forEach(function(s){i=s.indexOf(":"),r=s.substring(0,i).trim().toLowerCase(),n=s.substring(i+1).trim(),!(!r||t[r]&&iUe[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},aY=Symbol("internals");function cS(e){return e&&String(e).trim().toLowerCase()}function yP(e){return e===!1||e==null?e:Ke.isArray(e)?e.map(yP):String(e)}function sUe(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const aUe=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function PO(e,t,r,n,i){if(Ke.isFunction(n))return n.call(this,t,r);if(i&&(t=r),!!Ke.isString(t)){if(Ke.isString(n))return t.indexOf(n)!==-1;if(Ke.isRegExp(n))return n.test(t)}}function lUe(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function cUe(e,t){const r=Ke.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(i,o,s){return this[n].call(this,t,i,o,s)},configurable:!0})})}let na=class{constructor(t){t&&this.set(t)}set(t,r,n){const i=this;function o(a,l,c){const u=cS(l);if(!u)throw new Error("header name must be a non-empty string");const d=Ke.findKey(i,u);(!d||i[d]===void 0||c===!0||c===void 0&&i[d]!==!1)&&(i[d||l]=yP(a))}const s=(a,l)=>Ke.forEach(a,(c,u)=>o(c,u,l));if(Ke.isPlainObject(t)||t instanceof this.constructor)s(t,r);else if(Ke.isString(t)&&(t=t.trim())&&!aUe(t))s(oUe(t),r);else if(Ke.isObject(t)&&Ke.isIterable(t)){let a={},l,c;for(const u of t){if(!Ke.isArray(u))throw TypeError("Object iterator must return a key-value pair");a[c=u[0]]=(l=a[c])?Ke.isArray(l)?[...l,u[1]]:[l,u[1]]:u[1]}s(a,r)}else t!=null&&o(r,t,n);return this}get(t,r){if(t=cS(t),t){const n=Ke.findKey(this,t);if(n){const i=this[n];if(!r)return i;if(r===!0)return sUe(i);if(Ke.isFunction(r))return r.call(this,i,n);if(Ke.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=cS(t),t){const n=Ke.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||PO(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let i=!1;function o(s){if(s=cS(s),s){const a=Ke.findKey(n,s);a&&(!r||PO(n,n[a],a,r))&&(delete n[a],i=!0)}}return Ke.isArray(t)?t.forEach(o):o(t),i}clear(t){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const o=r[n];(!t||PO(this,this[o],o,t,!0))&&(delete this[o],i=!0)}return i}normalize(t){const r=this,n={};return Ke.forEach(this,(i,o)=>{const s=Ke.findKey(n,o);if(s){r[s]=yP(i),delete r[o];return}const a=t?lUe(o):String(o).trim();a!==o&&delete r[o],r[a]=yP(i),n[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return Ke.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=t&&Ke.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(` `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(i=>n.set(i)),n}static accessor(t){const n=(this[aY]=this[aY]={accessors:{}}).accessors,i=this.prototype;function o(s){const a=cS(s);n[a]||(cUe(i,s),n[a]=!0)}return Ke.isArray(t)?t.forEach(o):o(t),this}};na.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);Ke.reduceDescriptors(na.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});Ke.freezeMethods(na);function MO(e,t){const r=this||o1,n=t||r,i=na.from(n.headers);let o=n.data;return Ke.forEach(e,function(a){o=a.call(r,o,i.normalize(),t?t.status:void 0)}),i.normalize(),o}function Che(e){return!!(e&&e.__CANCEL__)}function zC(e,t,r){Xr.call(this,e??"canceled",Xr.ERR_CANCELED,t,r),this.name="CanceledError"}Ke.inherits(zC,Xr,{__CANCEL__:!0});function bhe(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new Xr("Request failed with status code "+r.status,[Xr.ERR_BAD_REQUEST,Xr.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function uUe(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function dUe(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i=0,o=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=n[o];s||(s=c),r[i]=l,n[i]=c;let d=o,h=0;for(;d!==i;)h+=r[d++],d=d%e;if(i=(i+1)%e,i===o&&(o=(o+1)%e),c-s{r=u,i=null,o&&(clearTimeout(o),o=null),e(...c)};return[(...c)=>{const u=Date.now(),d=u-r;d>=n?s(c,u):(i=c,o||(o=setTimeout(()=>{o=null,s(i)},n-d)))},()=>i&&s(i)]}const OM=(e,t,r=3)=>{let n=0;const i=dUe(50,250);return hUe(o=>{const s=o.loaded,a=o.lengthComputable?o.total:void 0,l=s-n,c=i(l),u=s<=a;n=s;const d={loaded:s,total:a,progress:a?s/a:void 0,bytes:l,rate:c||void 0,estimated:c&&a&&u?(a-s)/c:void 0,event:o,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(d)},r)},lY=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},cY=e=>(...t)=>Ke.asap(()=>e(...t)),pUe=as.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,as.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(as.origin),as.navigator&&/(msie|trident)/i.test(as.navigator.userAgent)):()=>!0,fUe=as.hasStandardBrowserEnv?{write(e,t,r,n,i,o,s){if(typeof document>"u")return;const a=[`${e}=${encodeURIComponent(t)}`];Ke.isNumber(r)&&a.push(`expires=${new Date(r).toUTCString()}`),Ke.isString(n)&&a.push(`path=${n}`),Ke.isString(i)&&a.push(`domain=${i}`),o===!0&&a.push("secure"),Ke.isString(s)&&a.push(`SameSite=${s}`),document.cookie=a.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function gUe(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function mUe(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function She(e,t,r){let n=!gUe(t);return e&&(n||r==!1)?mUe(e,t):t}const uY=e=>e instanceof na?{...e}:e;function im(e,t){t=t||{};const r={};function n(c,u,d,h){return Ke.isPlainObject(c)&&Ke.isPlainObject(u)?Ke.merge.call({caseless:h},c,u):Ke.isPlainObject(u)?Ke.merge({},u):Ke.isArray(u)?u.slice():u}function i(c,u,d,h){if(Ke.isUndefined(u)){if(!Ke.isUndefined(c))return n(void 0,c,d,h)}else return n(c,u,d,h)}function o(c,u){if(!Ke.isUndefined(u))return n(void 0,u)}function s(c,u){if(Ke.isUndefined(u)){if(!Ke.isUndefined(c))return n(void 0,c)}else return n(void 0,u)}function a(c,u,d){if(d in t)return n(c,u);if(d in e)return n(void 0,c)}const l={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:a,headers:(c,u,d)=>i(uY(c),uY(u),d,!0)};return Ke.forEach(Object.keys({...e,...t}),function(u){const d=l[u]||i,h=d(e[u],t[u],u);Ke.isUndefined(h)&&d!==a||(r[u]=h)}),r}const whe=e=>{const t=im({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:o,headers:s,auth:a}=t;if(t.headers=s=na.from(s),t.url=mhe(She(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),a&&s.set("Authorization","Basic "+btoa((a.username||"")+":"+(a.password?unescape(encodeURIComponent(a.password)):""))),Ke.isFormData(r)){if(as.hasStandardBrowserEnv||as.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(Ke.isFunction(r.getHeaders)){const l=r.getHeaders(),c=["content-type","content-length"];Object.entries(l).forEach(([u,d])=>{c.includes(u.toLowerCase())&&s.set(u,d)})}}if(as.hasStandardBrowserEnv&&(n&&Ke.isFunction(n)&&(n=n(t)),n||n!==!1&&pUe(t.url))){const l=i&&o&&fUe.read(o);l&&s.set(i,l)}return t},vUe=typeof XMLHttpRequest<"u",yUe=vUe&&function(e){return new Promise(function(r,n){const i=whe(e);let o=i.data;const s=na.from(i.headers).normalize();let{responseType:a,onUploadProgress:l,onDownloadProgress:c}=i,u,d,h,p,f;function g(){p&&p(),f&&f(),i.cancelToken&&i.cancelToken.unsubscribe(u),i.signal&&i.signal.removeEventListener("abort",u)}let m=new XMLHttpRequest;m.open(i.method.toUpperCase(),i.url,!0),m.timeout=i.timeout;function v(){if(!m)return;const S=na.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),E={data:!a||a==="text"||a==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:S,config:e,request:m};bhe(function(T){r(T),g()},function(T){n(T),g()},E),m=null}"onloadend"in m?m.onloadend=v:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(v)},m.onabort=function(){m&&(n(new Xr("Request aborted",Xr.ECONNABORTED,e,m)),m=null)},m.onerror=function(x){const E=x&&x.message?x.message:"Network Error",R=new Xr(E,Xr.ERR_NETWORK,e,m);R.event=x||null,n(R),m=null},m.ontimeout=function(){let x=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const E=i.transitional||vhe;i.timeoutErrorMessage&&(x=i.timeoutErrorMessage),n(new Xr(x,E.clarifyTimeoutError?Xr.ETIMEDOUT:Xr.ECONNABORTED,e,m)),m=null},o===void 0&&s.setContentType(null),"setRequestHeader"in m&&Ke.forEach(s.toJSON(),function(x,E){m.setRequestHeader(E,x)}),Ke.isUndefined(i.withCredentials)||(m.withCredentials=!!i.withCredentials),a&&a!=="json"&&(m.responseType=i.responseType),c&&([h,f]=OM(c,!0),m.addEventListener("progress",h)),l&&m.upload&&([d,p]=OM(l),m.upload.addEventListener("progress",d),m.upload.addEventListener("loadend",p)),(i.cancelToken||i.signal)&&(u=S=>{m&&(n(!S||S.type?new zC(null,e,m):S),m.abort(),m=null)},i.cancelToken&&i.cancelToken.subscribe(u),i.signal&&(i.signal.aborted?u():i.signal.addEventListener("abort",u)));const b=uUe(i.url);if(b&&as.protocols.indexOf(b)===-1){n(new Xr("Unsupported protocol "+b+":",Xr.ERR_BAD_REQUEST,e));return}m.send(o||null)})},CUe=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,i;const o=function(c){if(!i){i=!0,a();const u=c instanceof Error?c:this.reason;n.abort(u instanceof Xr?u:new zC(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,o(new Xr(`timeout ${t} of ms exceeded`,Xr.ETIMEDOUT))},t);const a=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=n;return l.unsubscribe=()=>Ke.asap(a),l}},bUe=function*(e,t){let r=e.byteLength;if(r{const i=SUe(e,t);let o=0,s,a=l=>{s||(s=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await i.next();if(c){a(),l.close();return}let d=u.byteLength;if(r){let h=o+=d;r(h)}l.enqueue(new Uint8Array(u))}catch(c){throw a(c),c}},cancel(l){return a(l),i.return()}},{highWaterMark:2})},hY=64*1024,{isFunction:CT}=Ke,xUe=(({Request:e,Response:t})=>({Request:e,Response:t}))(Ke.global),{ReadableStream:pY,TextEncoder:fY}=Ke.global,gY=(e,...t)=>{try{return!!e(...t)}catch{return!1}},EUe=e=>{e=Ke.merge.call({skipUndefined:!0},xUe,e);const{fetch:t,Request:r,Response:n}=e,i=t?CT(t):typeof fetch=="function",o=CT(r),s=CT(n);if(!i)return!1;const a=i&&CT(pY),l=i&&(typeof fY=="function"?(f=>g=>f.encode(g))(new fY):async f=>new Uint8Array(await new r(f).arrayBuffer())),c=o&&a&&gY(()=>{let f=!1;const g=new r(as.origin,{body:new pY,method:"POST",get duplex(){return f=!0,"half"}}).headers.has("Content-Type");return f&&!g}),u=s&&a&&gY(()=>Ke.isReadableStream(new n("").body)),d={stream:u&&(f=>f.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(f=>{!d[f]&&(d[f]=(g,m)=>{let v=g&&g[f];if(v)return v.call(g);throw new Xr(`Response type '${f}' is not supported`,Xr.ERR_NOT_SUPPORT,m)})});const h=async f=>{if(f==null)return 0;if(Ke.isBlob(f))return f.size;if(Ke.isSpecCompliantForm(f))return(await new r(as.origin,{method:"POST",body:f}).arrayBuffer()).byteLength;if(Ke.isArrayBufferView(f)||Ke.isArrayBuffer(f))return f.byteLength;if(Ke.isURLSearchParams(f)&&(f=f+""),Ke.isString(f))return(await l(f)).byteLength},p=async(f,g)=>{const m=Ke.toFiniteNumber(f.getContentLength());return m??h(g)};return async f=>{let{url:g,method:m,data:v,signal:b,cancelToken:S,timeout:x,onDownloadProgress:E,onUploadProgress:R,responseType:T,headers:M,withCredentials:D="same-origin",fetchOptions:A}=whe(f),I=t||fetch;T=T?(T+"").toLowerCase():"text";let L=CUe([b,S&&S.toAbortSignal()],x),F=null;const k=L&&L.unsubscribe&&(()=>{L.unsubscribe()});let O;try{if(R&&c&&m!=="get"&&m!=="head"&&(O=await p(M,v))!==0){let V=new r(g,{method:"POST",body:v,duplex:"half"}),$;if(Ke.isFormData(v)&&($=V.headers.get("content-type"))&&M.setContentType($),V.body){const[K,q]=lY(O,OM(cY(R)));v=dY(V.body,hY,K,q)}}Ke.isString(D)||(D=D?"include":"omit");const B=o&&"credentials"in r.prototype,H={...A,signal:L,method:m.toUpperCase(),headers:M.normalize().toJSON(),body:v,duplex:"half",credentials:B?D:void 0};F=o&&new r(g,H);let N=await(o?I(F,A):I(g,H));const z=u&&(T==="stream"||T==="response");if(u&&(E||z&&k)){const V={};["status","statusText","headers"].forEach(X=>{V[X]=N[X]});const $=Ke.toFiniteNumber(N.headers.get("content-length")),[K,q]=E&&lY($,OM(cY(E),!0))||[];N=new n(dY(N.body,hY,K,()=>{q&&q(),k&&k()}),V)}T=T||"text";let W=await d[Ke.findKey(d,T)||"text"](N,f);return!z&&k&&k(),await new Promise((V,$)=>{bhe(V,$,{data:W,headers:na.from(N.headers),status:N.status,statusText:N.statusText,config:f,request:F})})}catch(B){throw k&&k(),B&&B.name==="TypeError"&&/Load failed|fetch/i.test(B.message)?Object.assign(new Xr("Network Error",Xr.ERR_NETWORK,f,F),{cause:B.cause||B}):Xr.from(B,B&&B.code,f,F)}}},TUe=new Map,xhe=e=>{let t=e&&e.env||{};const{fetch:r,Request:n,Response:i}=t,o=[n,i,r];let s=o.length,a=s,l,c,u=TUe;for(;a--;)l=o[a],c=u.get(l),c===void 0&&u.set(l,c=a?new Map:EUe(t)),u=c;return c};xhe();const K4={http:z8e,xhr:yUe,fetch:{get:xhe}};Ke.forEach(K4,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const mY=e=>`- ${e}`,RUe=e=>Ke.isFunction(e)||e===null||e===!1;function PUe(e,t){e=Ke.isArray(e)?e:[e];const{length:r}=e;let n,i;const o={};for(let s=0;s`adapter ${l} `+(c===!1?"is not supported by the environment":"is not available in the build"));let a=r?s.length>1?`since : `+s.map(mY).join(` `):" "+mY(s[0]):"as no adapter specified";throw new Xr("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return i}const Ehe={getAdapter:PUe,adapters:K4};function IO(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new zC(null,e)}function vY(e){return IO(e),e.headers=na.from(e.headers),e.data=MO.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Ehe.getAdapter(e.adapter||o1.adapter,e)(e).then(function(n){return IO(e),n.data=MO.call(e,e.transformResponse,n),n.headers=na.from(n.headers),n},function(n){return Che(n)||(IO(e),n&&n.response&&(n.response.data=MO.call(e,e.transformResponse,n.response),n.response.headers=na.from(n.response.headers))),Promise.reject(n)})}const The="1.13.2",gA={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{gA[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const yY={};gA.transitional=function(t,r,n){function i(o,s){return"[Axios v"+The+"] Transitional option '"+o+"'"+s+(n?". "+n:"")}return(o,s,a)=>{if(t===!1)throw new Xr(i(s," has been removed"+(r?" in "+r:"")),Xr.ERR_DEPRECATED);return r&&!yY[s]&&(yY[s]=!0,console.warn(i(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(o,s,a):!0}};gA.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function MUe(e,t,r){if(typeof e!="object")throw new Xr("options must be an object",Xr.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const o=n[i],s=t[o];if(s){const a=e[o],l=a===void 0||s(a,o,e);if(l!==!0)throw new Xr("option "+o+" must be "+l,Xr.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Xr("Unknown option "+o,Xr.ERR_BAD_OPTION)}}const CP={assertOptions:MUe,validators:gA},Oc=CP.validators;let Ng=class{constructor(t){this.defaults=t||{},this.interceptors={request:new sY,response:new sY}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const o=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?o&&!String(n.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(n.stack+=` `+o):n.stack=o}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=im(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:o}=r;n!==void 0&&CP.assertOptions(n,{silentJSONParsing:Oc.transitional(Oc.boolean),forcedJSONParsing:Oc.transitional(Oc.boolean),clarifyTimeoutError:Oc.transitional(Oc.boolean)},!1),i!=null&&(Ke.isFunction(i)?r.paramsSerializer={serialize:i}:CP.assertOptions(i,{encode:Oc.function,serialize:Oc.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),CP.assertOptions(r,{baseUrl:Oc.spelling("baseURL"),withXsrfToken:Oc.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=o&&Ke.merge(o.common,o[r.method]);o&&Ke.forEach(["delete","get","head","post","put","patch","common"],f=>{delete o[f]}),r.headers=na.concat(s,o);const a=[];let l=!0;this.interceptors.request.forEach(function(g){typeof g.runWhen=="function"&&g.runWhen(r)===!1||(l=l&&g.synchronous,a.unshift(g.fulfilled,g.rejected))});const c=[];this.interceptors.response.forEach(function(g){c.push(g.fulfilled,g.rejected)});let u,d=0,h;if(!l){const f=[vY.bind(this),void 0];for(f.unshift(...a),f.push(...c),h=f.length,u=Promise.resolve(r);d{if(!n._listeners)return;let o=n._listeners.length;for(;o-- >0;)n._listeners[o](i);n._listeners=null}),this.promise.then=i=>{let o;const s=new Promise(a=>{n.subscribe(a),o=a}).then(i);return s.cancel=function(){n.unsubscribe(o)},s},t(function(o,s,a){n.reason||(n.reason=new zC(o,s,a),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Rhe(function(i){t=i}),cancel:t}}};function DUe(e){return function(r){return e.apply(null,r)}}function AUe(e){return Ke.isObject(e)&&e.isAxiosError===!0}const aV={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(aV).forEach(([e,t])=>{aV[t]=e});function Phe(e){const t=new Ng(e),r=ihe(Ng.prototype.request,t);return Ke.extend(r,Ng.prototype,t,{allOwnKeys:!0}),Ke.extend(r,t,null,{allOwnKeys:!0}),r.create=function(i){return Phe(im(e,i))},r}const _i=Phe(o1);_i.Axios=Ng;_i.CanceledError=zC;_i.CancelToken=IUe;_i.isCancel=Che;_i.VERSION=The;_i.toFormData=fA;_i.AxiosError=Xr;_i.Cancel=_i.CanceledError;_i.all=function(t){return Promise.all(t)};_i.spread=DUe;_i.isAxiosError=AUe;_i.mergeConfig=im;_i.AxiosHeaders=na;_i.formToJSON=e=>yhe(Ke.isHTMLForm(e)?new FormData(e):e);_i.getAdapter=Ehe.getAdapter;_i.HttpStatusCode=aV;_i.default=_i;const{Axios:e$t,AxiosError:t$t,CanceledError:r$t,isCancel:n$t,CancelToken:i$t,VERSION:o$t,all:s$t,Cancel:a$t,isAxiosError:l$t,spread:c$t,toFormData:u$t,AxiosHeaders:d$t,HttpStatusCode:h$t,formToJSON:p$t,getAdapter:f$t,mergeConfig:g$t}=_i;class aw extends Error{}aw.prototype.name="InvalidTokenError";function FUe(e){return decodeURIComponent(atob(e).replace(/(.)/g,(t,r)=>{let n=r.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n}))}function LUe(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return FUe(t)}catch{return atob(t)}}function _Ue(e,t){if(typeof e!="string")throw new aw("Invalid token specified: must be a string");t||(t={});const r=t.header===!0?0:1,n=e.split(".")[r];if(typeof n!="string")throw new aw(`Invalid token specified: missing part #${r+1}`);let i;try{i=LUe(n)}catch(o){throw new aw(`Invalid token specified: invalid base64 for part #${r+1} (${o.message})`)}try{return JSON.parse(i)}catch(o){throw new aw(`Invalid token specified: invalid json for part #${r+1} (${o.message})`)}}/*! js-cookie v3.0.5 | MIT */function bT(e){for(var t=1;t"u")){s=bT({},t,s),typeof s.expires=="number"&&(s.expires=new Date(Date.now()+s.expires*864e5)),s.expires&&(s.expires=s.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var l in s)s[l]&&(a+="; "+l,s[l]!==!0&&(a+="="+s[l].split(";")[0]));return document.cookie=i+"="+e.write(o,i)+a}}function n(i){if(!(typeof document>"u"||arguments.length&&!i)){for(var o=document.cookie?document.cookie.split("; "):[],s={},a=0;akUe.get(e)},NUe="refresh_token",BUe="authorization_code",$Ue="wbid-sdk-access-token",Ihe="wbid-oauth-sdk-access-token",GUe={[Bw.DEV]:"https://stage-id.wb.ru",[Bw.STAGE]:"https://stage-id.wb.ru",[Bw.PROD]:"https://id.wb.ru"};class VUe{constructor(){Ie(this,"_accessToken");Ie(this,"axios");this.axios=_i.create(),this._accessToken="",typeof localStorage<"u"&&(this._accessToken=localStorage.getItem(Ihe)??"")}async setAccessToken(t){return this._accessToken=t,this}get accessToken(){return this._accessToken}get isAccessTokenExpired(){return this.accessToken?(_Ue(this.accessToken).exp||0)crypto.getRandomValues(new Uint8Array(e)).reduce((t,r)=>(r&=63,r<36?t+=r.toString(36):r<62?t+=(r-26).toString(36).toUpperCase():r>62?t+="-":t+="_",t),"");const CY=(e=22)=>zUe(e),HUe=e=>e.replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/m,""),WUe=async e=>{let t;return crypto.subtle?t=await crypto.subtle.digest("SHA-256",new TextEncoder().encode(e)):t=(await J6e(()=>import("./sha256-CBw6sojz-PkoITTVd.js"),[]).then(n=>n.s)).sha256.create().update(e).arrayBuffer(),HUe(btoa(String.fromCharCode(...new Uint8Array(t))))};var lw=(e=>(e.AUTHORIZATION_REJECTED="AUTHORIZATION_REJECTED",e.INVALID_CALLBACK_PARAMS="INVALID_CALLBACK_PARAMS",e.TOKEN_NOT_RECEIVED="TOKEN_NOT_RECEIVED",e.LOGIN_FAILED="LOGIN_FAILED",e))(lw||{});class m$t extends VUe{constructor(r){super();Ie(this,"params");Ie(this,"_validationKey");this.params={clientId:r.clientId,scope:r.scope,redirectUri:r.redirectUri,debug:r.debug??ST.debug,audience:r.audience??ST.audience,endpoints:{...ST.endpoints??{},...r.endpoints??{}},getCookie:r.getCookie??ST.getCookie,environment:r.environment}}async setAccessToken(r){return await super.setAccessToken(r),typeof localStorage<"u"&&localStorage.setItem(Ihe,r),this}get validationKey(){return this._validationKey??""}get accessTokenHeader(){return"Authorization"}get accessTokenHeaderValue(){return`Bearer ${this.accessToken}`}get isUserLoggedIn(){return!!this.accessToken}async getCurrentUser(){return this.axios.post(this.params.endpoints.user,{clientId:this.params.clientId}).then(r=>r.data).catch(r=>(this.params.debug&&console.error(r),null))}async initializeWithSSR(){const r=await this.params.getCookie($Ue)??"";return r&&await this.setAccessToken(r),this}async login({prompt:r=e8e.consent,phone:n}={}){if(typeof document>"u"||typeof sessionStorage>"u"||typeof URLSearchParams>"u")return;const i=this.params.endpoints.authorize,o=CY(64),s=await WUe(o),a=CY(32);sessionStorage.setItem(a,o);const l=new URLSearchParams;l.set(wa.clientId,this.params.clientId),l.set(wa.audience,this.params.audience),l.set(wa.prompt,r),l.set(wa.redirectUri,this.params.redirectUri),l.set(wa.scope,this.params.scope),l.set(wa.state,a),l.set(wa.codeChallengeMethod,r8e.S256),l.set(wa.responseType,t8e.code),l.set(wa.codeChallenge,s),n&&l.set(wa.phone,n),document.location=`${i}?${l.toString()}`}async handleCallback(){if(typeof window>"u"||typeof sessionStorage>"u"||typeof URLSearchParams>"u")return null;const r=new URLSearchParams(window.location.search),n=r.get(wa.code),i=r.get(wa.error),o=r.get(wa.state),s=sessionStorage.getItem(o??"");return i==="consent_rejected"?(o&&sessionStorage.removeItem(o),{code:lw.AUTHORIZATION_REJECTED}):!n||!o||!s?(o&&sessionStorage.removeItem(o),{code:lw.INVALID_CALLBACK_PARAMS}):this.axios.post(this.params.endpoints.token,{clientId:this.params.clientId,code:n,grantType:BUe,codeVerifier:s,redirectUri:this.params.redirectUri,state:o}).then(a=>{var l;return(l=a.data)==null?void 0:l.accessToken}).then(a=>a?this.setAccessToken(a).then(()=>null):{code:lw.TOKEN_NOT_RECEIVED}).catch(a=>this.params.debug?(console.error(a),{code:lw.LOGIN_FAILED}):null).finally(()=>{sessionStorage.removeItem(o)})}async logout(){return this.axios.post(this.params.endpoints.revoke,{clientId:this.params.clientId,accessToken:this.accessToken}).then(({status:r})=>{const n=[200,204].includes(r);return n&&this.setAccessToken("").then(()=>n)}).catch(r=>(this.params.debug&&console.error(r),!1))}async refresh(){return this.axios.post(this.params.endpoints.token,{grantType:NUe,clientId:this.params.clientId}).then(r=>{if([200,204].includes(r.status)){const{accessToken:i,validationKey:o}=r.data;return this._validationKey=o,this.setAccessToken(i).then(()=>({accessToken:i,validationKey:o}))}return null}).catch(r=>(this.params.debug&&console.error(r),null))}goToProfile(){const r=this.params.environment??Bw.PROD,n=GUe[r];typeof window<"u"&&window.open(n,"_blank")}}function is(e,t,r,n){function i(o){return o instanceof r?o:new r(function(s){s(o)})}return new(r||(r=Promise))(function(o,s){function a(u){try{c(n.next(u))}catch(d){s(d)}}function l(u){try{c(n.throw(u))}catch(d){s(d)}}function c(u){u.done?o(u.value):i(u.value).then(a,l)}c((n=n.apply(e,[])).next())})}function UUe(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var q4={exports:{}},Ey=typeof Reflect=="object"?Reflect:null,bY=Ey&&typeof Ey.apply=="function"?Ey.apply:function(t,r,n){return Function.prototype.apply.call(t,r,n)},bP;Ey&&typeof Ey.ownKeys=="function"?bP=Ey.ownKeys:Object.getOwnPropertySymbols?bP=function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:bP=function(t){return Object.getOwnPropertyNames(t)};function jUe(e){console&&console.warn&&console.warn(e)}var Dhe=Number.isNaN||function(t){return t!==t};function $n(){$n.init.call(this)}q4.exports=$n;q4.exports.once=YUe;$n.EventEmitter=$n;$n.prototype._events=void 0;$n.prototype._eventsCount=0;$n.prototype._maxListeners=void 0;var SY=10;function mA(e){if(typeof e!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}Object.defineProperty($n,"defaultMaxListeners",{enumerable:!0,get:function(){return SY},set:function(e){if(typeof e!="number"||e<0||Dhe(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");SY=e}});$n.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};$n.prototype.setMaxListeners=function(t){if(typeof t!="number"||t<0||Dhe(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this};function Ahe(e){return e._maxListeners===void 0?$n.defaultMaxListeners:e._maxListeners}$n.prototype.getMaxListeners=function(){return Ahe(this)};$n.prototype.emit=function(t){for(var r=[],n=1;n0&&(s=r[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var l=o[t];if(l===void 0)return!1;if(typeof l=="function")bY(l,this,r);else for(var c=l.length,u=khe(l,c),n=0;n0&&s.length>i&&!s.warned){s.warned=!0;var a=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");a.name="MaxListenersExceededWarning",a.emitter=e,a.type=t,a.count=s.length,jUe(a)}return e}$n.prototype.addListener=function(t,r){return Fhe(this,t,r,!1)};$n.prototype.on=$n.prototype.addListener;$n.prototype.prependListener=function(t,r){return Fhe(this,t,r,!0)};function KUe(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function Lhe(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=KUe.bind(n);return i.listener=r,n.wrapFn=i,i}$n.prototype.once=function(t,r){return mA(r),this.on(t,Lhe(this,t,r)),this};$n.prototype.prependOnceListener=function(t,r){return mA(r),this.prependListener(t,Lhe(this,t,r)),this};$n.prototype.removeListener=function(t,r){var n,i,o,s,a;if(mA(r),i=this._events,i===void 0)return this;if(n=i[t],n===void 0)return this;if(n===r||n.listener===r)--this._eventsCount===0?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit("removeListener",t,n.listener||r));else if(typeof n!="function"){for(o=-1,s=n.length-1;s>=0;s--)if(n[s]===r||n[s].listener===r){a=n[s].listener,o=s;break}if(o<0)return this;o===0?n.shift():qUe(n,o),n.length===1&&(i[t]=n[0]),i.removeListener!==void 0&&this.emit("removeListener",t,a||r)}return this};$n.prototype.off=$n.prototype.removeListener;$n.prototype.removeAllListeners=function(t){var r,n,i;if(n=this._events,n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[t]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[t]),this;if(arguments.length===0){var o=Object.keys(n),s;for(i=0;i=0;i--)this.removeListener(t,r[i]);return this};function _he(e,t,r){var n=e._events;if(n===void 0)return[];var i=n[t];return i===void 0?[]:typeof i=="function"?r?[i.listener||i]:[i]:r?XUe(i):khe(i,i.length)}$n.prototype.listeners=function(t){return _he(this,t,!0)};$n.prototype.rawListeners=function(t){return _he(this,t,!1)};$n.listenerCount=function(e,t){return typeof e.listenerCount=="function"?e.listenerCount(t):Ohe.call(e,t)};$n.prototype.listenerCount=Ohe;function Ohe(e){var t=this._events;if(t!==void 0){var r=t[e];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}$n.prototype.eventNames=function(){return this._eventsCount>0?bP(this._events):[]};function khe(e,t){for(var r=new Array(t),n=0;n31&&(e=31);const n=t7e(0,Math.min(r,t*Math.pow(2,e)));return Math.min(r,t+n)}function r7e(e){return"error"in e&&e.error!==null}function $M(e){return Math.min(e*1e3,2147483647)}class n7e extends Bhe{constructor(t,r,n){super(),this._resubscribeTimeout=null,this._refreshTimeout=null,this.channel=r,this.state=bs.Unsubscribed,this._centrifuge=t,this._token="",this._getToken=null,this._data=null,this._getData=null,this._recover=!1,this._offset=null,this._epoch=null,this._id=0,this._recoverable=!1,this._positioned=!1,this._joinLeave=!1,this._minResubscribeDelay=500,this._maxResubscribeDelay=2e4,this._resubscribeTimeout=null,this._resubscribeAttempts=0,this._promises={},this._promiseId=0,this._inflight=!1,this._refreshTimeout=null,this._delta="",this._delta_negotiated=!1,this._tagsFilter=null,this._prevValue=null,this._unsubPromise=Promise.resolve(),this._setOptions(n),this._centrifuge._debugEnabled?(this.on("state",i=>{this._debug("subscription state",r,i.oldState,"->",i.newState)}),this.on("error",i=>{this._debug("subscription error",r,i)})):this.on("error",function(){Function.prototype()})}ready(t){return this.state===bs.Unsubscribed?Promise.reject({code:Zn.subscriptionUnsubscribed,message:this.state}):this.state===bs.Subscribed?Promise.resolve():new Promise((r,n)=>{const i={resolve:r,reject:n};t&&(i.timeout=setTimeout(function(){n({code:Zn.timeout,message:"timeout"})},t)),this._promises[this._nextPromiseId()]=i})}subscribe(){this._isSubscribed()||(this._resubscribeAttempts=0,this._setSubscribing(kM.subscribeCalled,"subscribe called"))}unsubscribe(){this._unsubPromise=this._setUnsubscribed(NM.unsubscribeCalled,"unsubscribe called",!0)}publish(t){return is(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.publish(this.channel,t)})}presence(){return is(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presence(this.channel)})}presenceStats(){return is(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presenceStats(this.channel)})}history(t){return is(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.history(this.channel,t)})}setTagsFilter(t){if(t&&this._delta)throw new Error("cannot use delta and tagsFilter together");this._tagsFilter=t}setData(t){this._data=t}_methodCall(){return this._isSubscribed()?Promise.resolve():this._isUnsubscribed()?Promise.reject({code:Zn.subscriptionUnsubscribed,message:this.state}):new Promise((t,r)=>{const n=this._centrifuge._config.timeout,i=setTimeout(()=>{r({code:Zn.timeout,message:"timeout"})},n);this._promises[this._nextPromiseId()]={timeout:i,resolve:t,reject:r}})}_nextPromiseId(){return++this._promiseId}_needRecover(){return this._recover===!0}_isUnsubscribed(){return this.state===bs.Unsubscribed}_isSubscribing(){return this.state===bs.Subscribing}_isSubscribed(){return this.state===bs.Subscribed}_setState(t){if(this.state!==t){const r=this.state;return this.state=t,this.emit("state",{newState:t,oldState:r,channel:this.channel}),!0}return!1}_usesToken(){return this._token!==""||this._getToken!==null}_clearSubscribingState(){this._resubscribeAttempts=0,this._clearResubscribeTimeout()}_clearSubscribedState(){this._clearRefreshTimeout()}_setSubscribed(t){if(!this._isSubscribing())return;this._clearSubscribingState(),t.id&&(this._id=t.id),t.recoverable&&(this._recover=!0,this._offset=t.offset||0,this._epoch=t.epoch||""),t.delta?this._delta_negotiated=!0:this._delta_negotiated=!1,this._setState(bs.Subscribed);const r=this._centrifuge._getSubscribeContext(this.channel,t);this.emit("subscribed",r),this._resolvePromises();const n=t.publications;if(n&&n.length>0)for(const i in n)n.hasOwnProperty(i)&&this._handlePublication(n[i]);t.expires===!0&&(this._refreshTimeout=setTimeout(()=>this._refresh(),$M(t.ttl)))}_setSubscribing(t,r){return is(this,void 0,void 0,function*(){this._isSubscribing()||(this._isSubscribed()&&this._clearSubscribedState(),this._setState(bs.Subscribing)&&this.emit("subscribing",{channel:this.channel,code:t,reason:r}),this._centrifuge._transport&&this._centrifuge._transport.emulation()&&(yield this._unsubPromise),this._isSubscribing()&&this._subscribe())})}_subscribe(){return this._debug("subscribing on",this.channel),this._isTransportOpen()?this._inflight?null:(this._inflight=!0,this._canSubscribeWithoutGettingToken()?this._subscribeWithoutToken():(this._getSubscriptionToken().then(t=>this._handleTokenResponse(t)).catch(t=>this._handleTokenError(t)),null)):(this._debug("delay subscribe on",this.channel,"till connected"),null)}_isTransportOpen(){return this._centrifuge._transportIsOpen}_canSubscribeWithoutGettingToken(){return!this._usesToken()||!!this._token}_subscribeWithoutToken(){return this._getData?(this._getDataAndSubscribe(this._token),null):this._sendSubscribe(this._token)}_getDataAndSubscribe(t){if(!this._getData){this._inflight=!1;return}this._getData({channel:this.channel}).then(r=>{if(!this._isSubscribing()){this._inflight=!1;return}this._data=r,this._sendSubscribe(t)}).catch(r=>this._handleGetDataError(r))}_handleGetDataError(t){if(!this._isSubscribing()){this._inflight=!1;return}if(t instanceof ud){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeData",channel:this.channel,error:{code:Zn.badConfiguration,message:(t==null?void 0:t.toString())||""}}),this._inflight=!1,this._scheduleResubscribe()}_handleTokenResponse(t){if(!this._isSubscribing()){this._inflight=!1;return}if(!t){this._inflight=!1,this._failUnauthorized();return}this._token=t,this._getData?this._getDataAndSubscribe(t):this._sendSubscribe(t)}_handleTokenError(t){if(!this._isSubscribing()){this._inflight=!1;return}if(t instanceof ud){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeToken",channel:this.channel,error:{code:Zn.subscriptionSubscribeToken,message:(t==null?void 0:t.toString())||""}}),this._inflight=!1,this._scheduleResubscribe()}_sendSubscribe(t){if(!this._isTransportOpen())return this._inflight=!1,null;const r=this._buildSubscribeCommand(t);return this._centrifuge._call(r).then(n=>{this._inflight=!1;const i=n.reply.subscribe;this._handleSubscribeResponse(i),n.next&&n.next()},n=>{this._inflight=!1,this._handleSubscribeError(n.error),n.next&&n.next()}),r}_buildSubscribeCommand(t){const r={channel:this.channel};if(t&&(r.token=t),this._data&&(r.data=this._data),this._positioned&&(r.positioned=!0),this._recoverable&&(r.recoverable=!0),this._joinLeave&&(r.join_leave=!0),r.flag=cV.channelCompaction,this._needRecover()){r.recover=!0;const n=this._getOffset();n&&(r.offset=n);const i=this._getEpoch();i&&(r.epoch=i)}return this._delta&&(r.delta=this._delta),this._tagsFilter&&(r.tf=this._tagsFilter),{subscribe:r}}_debug(...t){this._centrifuge._debug(...t)}_handleSubscribeError(t){if(this._isSubscribing()){if(t.code===Zn.timeout){this._centrifuge._disconnect(Zh.subscribeTimeout,"subscribe timeout",!0);return}this._subscribeError(t)}}_handleSubscribeResponse(t){this._isSubscribing()&&this._setSubscribed(t)}_setUnsubscribed(t,r,n){if(this._isUnsubscribed())return Promise.resolve();let i=Promise.resolve();return this._isSubscribed()?(n&&(i=this._centrifuge._unsubscribe(this)),this._clearSubscribedState()):this._isSubscribing()&&(this._inflight&&n&&(i=this._centrifuge._unsubscribe(this)),this._clearSubscribingState()),this._inflight=!1,this._setState(bs.Unsubscribed)&&this.emit("unsubscribed",{channel:this.channel,code:t,reason:r}),this._rejectPromises({code:Zn.subscriptionUnsubscribed,message:this.state}),i}_handlePublication(t){if(this._delta&&this._delta_negotiated){const{newData:n,newPrevValue:i}=this._centrifuge._codec.applyDeltaIfNeeded(t,this._prevValue);t.data=n,this._prevValue=i}const r=this._centrifuge._getPublicationContext(this.channel,t);this.emit("publication",r),t.offset&&(this._offset=t.offset)}_handleJoin(t){const r=this._centrifuge._getJoinLeaveContext(t.info);this.emit("join",{channel:this.channel,info:r})}_handleLeave(t){const r=this._centrifuge._getJoinLeaveContext(t.info);this.emit("leave",{channel:this.channel,info:r})}_resolvePromises(){for(const t in this._promises)this._promises.hasOwnProperty(t)&&(this._promises[t].timeout&&clearTimeout(this._promises[t].timeout),this._promises[t].resolve(),delete this._promises[t])}_rejectPromises(t){for(const r in this._promises)this._promises.hasOwnProperty(r)&&(this._promises[r].timeout&&clearTimeout(this._promises[r].timeout),this._promises[r].reject(t),delete this._promises[r])}_scheduleResubscribe(){if(!this._isSubscribing()){this._debug("not in subscribing state, skip resubscribe scheduling",this.channel);return}const t=this,r=this._getResubscribeDelay();this._resubscribeTimeout=setTimeout(function(){t._isSubscribing()&&t._subscribe()},r),this._debug("resubscribe scheduled after "+r,this.channel)}_subscribeError(t){if(this._isSubscribing())if(t.code<100||t.code===109||t.temporary===!0){t.code===109&&(this._token="");const r={channel:this.channel,type:"subscribe",error:t};this._centrifuge.state===Gi.Connected&&this.emit("error",r),this._scheduleResubscribe()}else this._setUnsubscribed(t.code,t.message,!1)}_getResubscribeDelay(){const t=BM(this._resubscribeAttempts,this._minResubscribeDelay,this._maxResubscribeDelay);return this._resubscribeAttempts++,t}_setOptions(t){if(t){if(t.since&&(this._offset=t.since.offset||0,this._epoch=t.since.epoch||"",this._recover=!0),t.data&&(this._data=t.data),t.getData&&(this._getData=t.getData),t.minResubscribeDelay!==void 0&&(this._minResubscribeDelay=t.minResubscribeDelay),t.maxResubscribeDelay!==void 0&&(this._maxResubscribeDelay=t.maxResubscribeDelay),t.token&&(this._token=t.token),t.getToken&&(this._getToken=t.getToken),t.positioned===!0&&(this._positioned=!0),t.recoverable===!0&&(this._recoverable=!0),t.joinLeave===!0&&(this._joinLeave=!0),t.delta){if(t.delta!=="fossil")throw new Error("unsupported delta format");this._delta=t.delta}if(t.tagsFilter&&(this._tagsFilter=t.tagsFilter),this._tagsFilter&&this._delta)throw new Error("cannot use delta and tagsFilter together")}}_getOffset(){const t=this._offset;return t!==null?t:0}_getEpoch(){const t=this._epoch;return t!==null?t:""}_clearRefreshTimeout(){this._refreshTimeout!==null&&(clearTimeout(this._refreshTimeout),this._refreshTimeout=null)}_clearResubscribeTimeout(){this._resubscribeTimeout!==null&&(clearTimeout(this._resubscribeTimeout),this._resubscribeTimeout=null)}_getSubscriptionToken(){this._debug("get subscription token for channel",this.channel);const t={channel:this.channel},r=this._getToken;return r===null?(this.emit("error",{type:"configuration",channel:this.channel,error:{code:Zn.badConfiguration,message:"provide a function to get channel subscription token"}}),Promise.reject(new ud(""))):r(t)}_refresh(){this._clearRefreshTimeout();const t=this;this._getSubscriptionToken().then(function(r){if(!t._isSubscribed())return;if(!r){t._failUnauthorized();return}t._token=r;const i={sub_refresh:{channel:t.channel,token:r}};t._centrifuge._call(i).then(o=>{const s=o.reply.sub_refresh;t._refreshResponse(s),o.next&&o.next()},o=>{t._refreshError(o.error),o.next&&o.next()})}).catch(function(r){if(r instanceof ud){t._failUnauthorized();return}t.emit("error",{type:"refreshToken",channel:t.channel,error:{code:Zn.subscriptionRefreshToken,message:r!==void 0?r.toString():""}}),t._refreshTimeout=setTimeout(()=>t._refresh(),t._getRefreshRetryDelay())})}_refreshResponse(t){this._isSubscribed()&&(this._debug("subscription token refreshed, channel",this.channel),this._clearRefreshTimeout(),t.expires===!0&&(this._refreshTimeout=setTimeout(()=>this._refresh(),$M(t.ttl))))}_refreshError(t){this._isSubscribed()&&(t.code<100||t.temporary===!0?(this.emit("error",{type:"refresh",channel:this.channel,error:t}),this._refreshTimeout=setTimeout(()=>this._refresh(),this._getRefreshRetryDelay())):this._setUnsubscribed(t.code,t.message,!0))}_getRefreshRetryDelay(){return BM(0,1e4,2e4)}_failUnauthorized(){this._setUnsubscribed(NM.unauthorized,"unauthorized",!0)}}class i7e{constructor(t,r){this.endpoint=t,this.options=r,this._transport=null}name(){return"sockjs"}subName(){return"sockjs-"+this._transport.transport}emulation(){return!1}supported(){return this.options.sockjs!==null}initialize(t,r){this._transport=new this.options.sockjs(this.endpoint,null,this.options.sockjsOptions),this._transport.onopen=()=>{r.onOpen()},this._transport.onerror=n=>{r.onError(n)},this._transport.onclose=n=>{r.onClose(n)},this._transport.onmessage=n=>{r.onMessage(n.data)}}close(){this._transport.close()}send(t){this._transport.send(t)}}class wY{constructor(t,r){this.endpoint=t,this.options=r,this._transport=null}name(){return"websocket"}subName(){return"websocket"}emulation(){return!1}supported(){return this.options.websocket!==void 0&&this.options.websocket!==null}initialize(t,r){let n="";t==="protobuf"&&(n="centrifuge-protobuf"),n!==""?this._transport=new this.options.websocket(this.endpoint,n):this._transport=new this.options.websocket(this.endpoint),t==="protobuf"&&(this._transport.binaryType="arraybuffer"),this._transport.onopen=()=>{r.onOpen()},this._transport.onerror=i=>{r.onError(i)},this._transport.onclose=i=>{r.onClose(i)},this._transport.onmessage=i=>{r.onMessage(i.data)}}close(){this._transport.close()}send(t){this._transport.send(t)}}class o7e{constructor(t,r){this.endpoint=t,this.options=r,this._abortController=null,this._utf8decoder=new TextDecoder,this._protocol="json"}name(){return"http_stream"}subName(){return"http_stream"}emulation(){return!0}_handleErrors(t){if(!t.ok)throw new Error(t.status);return t}_fetchEventTarget(t,r,n){const i=new EventTarget,o=t.options.fetch;return o(r,n).then(t._handleErrors).then(s=>{i.dispatchEvent(new Event("open"));let a="",l=0,c=new Uint8Array;const u=s.body.getReader();return new t.options.readableStream({start(d){function h(){return u.read().then(({done:p,value:f})=>{if(p){i.dispatchEvent(new Event("close")),d.close();return}try{if(t._protocol==="json")for(a+=t._utf8decoder.decode(f);l{i.dispatchEvent(new Event("error",{detail:s})),i.dispatchEvent(new Event("close"))}),i}supported(){return this.options.fetch!==null&&this.options.readableStream!==null&&typeof TextDecoder<"u"&&typeof AbortController<"u"&&typeof EventTarget<"u"&&typeof Event<"u"&&typeof MessageEvent<"u"&&typeof Error<"u"}initialize(t,r,n){this._protocol=t,this._abortController=new AbortController;let i,o;t==="json"?(i={Accept:"application/json","Content-Type":"application/json"},o=n):(i={Accept:"application/octet-stream","Content-Type":"application/octet-stream"},o=n);const s={method:"POST",headers:i,body:o,mode:"cors",credentials:"same-origin",signal:this._abortController.signal},a=this._fetchEventTarget(this,this.endpoint,s);a.addEventListener("open",()=>{r.onOpen()}),a.addEventListener("error",l=>{this._abortController.abort(),r.onError(l)}),a.addEventListener("close",()=>{this._abortController.abort(),r.onClose({code:4,reason:"connection closed"})}),a.addEventListener("message",l=>{r.onMessage(l.data)})}close(){this._abortController.abort()}send(t,r,n){let i,o;const s={session:r,node:n,data:t};this._protocol==="json"?(i={"Content-Type":"application/json"},o=JSON.stringify(s)):(i={"Content-Type":"application/octet-stream"},o=this.options.encoder.encodeEmulationRequest(s));const a=this.options.fetch,l={method:"POST",headers:i,body:o,mode:"cors",credentials:"same-origin"};a(this.options.emulationEndpoint,l)}}class s7e{constructor(t,r){this.endpoint=t,this.options=r,this._protocol="json",this._transport=null,this._onClose=null}name(){return"sse"}subName(){return"sse"}emulation(){return!0}supported(){return this.options.eventsource!==null&&this.options.fetch!==null}initialize(t,r,n){let i;globalThis&&globalThis.document&&globalThis.document.baseURI?i=new URL(this.endpoint,globalThis.document.baseURI):i=new URL(this.endpoint),i.searchParams.append("cf_connect",n);const o={},s=new this.options.eventsource(i.toString(),o);this._transport=s;const a=this;s.onopen=function(){r.onOpen()},s.onerror=function(l){s.close(),r.onError(l),r.onClose({code:4,reason:"connection closed"})},s.onmessage=function(l){r.onMessage(l.data)},a._onClose=function(){r.onClose({code:4,reason:"connection closed"})}}close(){this._transport.close(),this._onClose!==null&&this._onClose()}send(t,r,n){const i={session:r,node:n,data:t},o={"Content-Type":"application/json"},s=JSON.stringify(i),a=this.options.fetch,l={method:"POST",headers:o,body:s,mode:"cors",credentials:"same-origin"};a(this.options.emulationEndpoint,l)}}class a7e{constructor(t,r){this.endpoint=t,this.options=r,this._transport=null,this._stream=null,this._writer=null,this._utf8decoder=new TextDecoder,this._protocol="json"}name(){return"webtransport"}subName(){return"webtransport"}emulation(){return!1}supported(){return this.options.webtransport!==void 0&&this.options.webtransport!==null}initialize(t,r){return is(this,void 0,void 0,function*(){let n;globalThis&&globalThis.document&&globalThis.document.baseURI?n=new URL(this.endpoint,globalThis.document.baseURI):n=new URL(this.endpoint),t==="protobuf"&&n.searchParams.append("cf_protocol","protobuf"),this._protocol=t;const i=new EventTarget;this._transport=new this.options.webtransport(n.toString()),this._transport.closed.then(()=>{r.onClose({code:4,reason:"connection closed"})}).catch(()=>{r.onClose({code:4,reason:"connection closed"})});try{yield this._transport.ready}catch{this.close();return}let o;try{o=yield this._transport.createBidirectionalStream()}catch{this.close();return}this._stream=o,this._writer=this._stream.writable.getWriter(),i.addEventListener("close",()=>{r.onClose({code:4,reason:"connection closed"})}),i.addEventListener("message",s=>{r.onMessage(s.data)}),this._startReading(i),r.onOpen()})}_startReading(t){return is(this,void 0,void 0,function*(){const r=this._stream.readable.getReader();let n="",i=0,o=new Uint8Array;try{for(;;){const{done:s,value:a}=yield r.read();if(a.length>0)if(this._protocol==="json")for(n+=this._utf8decoder.decode(a);ithis.a.length)throw new RangeError("out of bounds");return t}getChar(){return String.fromCharCode(this.getByte())}getInt(){let t=0,r;for(;this.haveBytes()&&(r=l7e[127&this.getByte()])>=0;)t=(t<<6)+r;return this.pos--,t>>>0}}class u7e{constructor(){this.a=[]}toByteArray(t){return Array.isArray(t)?this.a:new Uint8Array(this.a)}putArray(t,r,n){for(let i=r;i=16;)t=t+e[o+0]|0,r=r+e[o+1]|0,n=n+e[o+2]|0,i=i+e[o+3]|0,t=t+e[o+4]|0,r=r+e[o+5]|0,n=n+e[o+6]|0,i=i+e[o+7]|0,t=t+e[o+8]|0,r=r+e[o+9]|0,n=n+e[o+10]|0,i=i+e[o+11]|0,t=t+e[o+12]|0,r=r+e[o+13]|0,n=n+e[o+14]|0,i=i+e[o+15]|0,o+=16,s-=16;for(;s>=4;)t=t+e[o+0]|0,r=r+e[o+1]|0,n=n+e[o+2]|0,i=i+e[o+3]|0,o+=4,s-=4;switch(i=((i+(n<<8)|0)+(r<<16)|0)+(t<<24)|0,s){case 3:i=i+(e[o+2]<<8)|0;case 2:i=i+(e[o+1]<<16)|0;case 1:i=i+(e[o+0]<<24)|0}return i>>>0}function h7e(e,t){let r=0;const n=new c7e(t),i=e.length,o=t.length,s=n.getInt();if(n.getChar()!==` `)throw new Error("size integer not terminated by '\\n'");const a=new u7e;for(;n.haveBytes();){const l=n.getInt();let c;switch(n.getChar()){case"@":if(c=n.getInt(),n.haveBytes()&&n.getChar()!==",")throw new Error("copy command not terminated by ','");if(r+=l,r>s)throw new Error("copy exceeds output file size");if(c+l>i)throw new Error("copy extends past end of input");a.putArray(e,c,c+l);break;case":":if(r+=l,r>s)throw new Error("insert command gives an output larger than predicted");if(l>o)throw new Error("insert count exceeds size of delta");a.putArray(n.a,n.pos,n.pos+l),n.pos+=l;break;case";":{const u=a.toByteArray(e);if(l!==d7e(u))throw new Error("bad checksum");if(r!==s)throw new Error("generated size does not match predicted size");return u}default:throw new Error("unknown delta operator")}}throw new Error("unterminated delta")}class xY{name(){return"json"}encodeCommands(t){return t.map(r=>JSON.stringify(r)).join(` `)}decodeReplies(t){return t.trim().split(` `).map(r=>JSON.parse(r))}applyDeltaIfNeeded(t,r){let n,i;if(t.delta){const o=h7e(r,new TextEncoder().encode(t.data));n=JSON.parse(new TextDecoder().decode(o)),i=o}else n=JSON.parse(t.data),i=new TextEncoder().encode(t.data);return{newData:n,newPrevValue:i}}}const p7e={headers:{},token:"",getToken:null,data:null,getData:null,debug:!1,name:"js",version:"",fetch:null,readableStream:null,websocket:null,eventsource:null,sockjs:null,sockjsOptions:{},emulationEndpoint:"/emulation",minReconnectDelay:500,maxReconnectDelay:2e4,timeout:5e3,maxServerPingDelay:1e4,networkEventTarget:null};class ud extends Error{constructor(t){super(t),this.name=this.constructor.name}}class X4 extends Bhe{constructor(t,r){super(),this._reconnectTimeout=null,this._refreshTimeout=null,this._serverPingTimeout=null,this.state=Gi.Disconnected,this._transportIsOpen=!1,this._endpoint=t,this._emulation=!1,this._transports=[],this._currentTransportIndex=0,this._triedAllTransports=!1,this._transportWasOpen=!1,this._transport=null,this._transportId=0,this._deviceWentOffline=!1,this._transportClosed=!0,this._codec=new xY,this._reconnecting=!1,this._reconnectTimeout=null,this._reconnectAttempts=0,this._client=null,this._session="",this._node="",this._subs={},this._serverSubs={},this._commandId=0,this._commands=[],this._batching=!1,this._refreshRequired=!1,this._refreshTimeout=null,this._callbacks={},this._token="",this._data=null,this._dispatchPromise=Promise.resolve(),this._serverPing=0,this._serverPingTimeout=null,this._sendPong=!1,this._promises={},this._promiseId=0,this._debugEnabled=!1,this._networkEventsSet=!1,this._config=Object.assign(Object.assign({},p7e),r),this._configure(),this._debugEnabled?(this.on("state",n=>{this._debug("client state",n.oldState,"->",n.newState)}),this.on("error",n=>{this._debug("client error",n)})):this.on("error",function(){Function.prototype()})}newSubscription(t,r){if(this.getSubscription(t)!==null)throw new Error("Subscription to the channel "+t+" already exists");const n=new n7e(this,t,r);return this._subs[t]=n,n}getSubscription(t){return this._getSub(t)}removeSubscription(t){t&&(t.state!==bs.Unsubscribed&&t.unsubscribe(),this._removeSubscription(t))}subscriptions(){return this._subs}ready(t){return is(this,void 0,void 0,function*(){switch(this.state){case Gi.Disconnected:throw{code:Zn.clientDisconnected,message:"client disconnected"};case Gi.Connected:return;default:return new Promise((r,n)=>{const i={resolve:r,reject:n};t&&(i.timeout=setTimeout(()=>{n({code:Zn.timeout,message:"timeout"})},t)),this._promises[this._nextPromiseId()]=i})}})}connect(){if(this._isConnected()){this._debug("connect called when already connected");return}if(this._isConnecting()){this._debug("connect called when already connecting");return}this._debug("connect called"),this._reconnectAttempts=0,this._startConnecting()}disconnect(){this._disconnect($w.disconnectCalled,"disconnect called",!1)}setToken(t){this._token=t}setData(t){this._data=t}setHeaders(t){this._config.headers=t}send(t){return is(this,void 0,void 0,function*(){const r={send:{data:t}};if(yield this._methodCall(),!this._transportSendCommands([r]))throw this._createErrorObject(Zn.transportWriteError,"transport write error")})}rpc(t,r){return is(this,void 0,void 0,function*(){const n={rpc:{method:t,data:r}};return yield this._methodCall(),{data:(yield this._callPromise(n,o=>o.rpc)).data}})}publish(t,r){return is(this,void 0,void 0,function*(){const n={publish:{channel:t,data:r}};return yield this._methodCall(),yield this._callPromise(n,()=>({})),{}})}history(t,r){return is(this,void 0,void 0,function*(){const n={history:this._getHistoryRequest(t,r)};yield this._methodCall();const i=yield this._callPromise(n,s=>s.history),o=[];if(i.publications)for(let s=0;so.presence)).presence;for(const o in i)if(Object.prototype.hasOwnProperty.call(i,o)){const s=i[o],a=s.conn_info,l=s.chan_info;a&&(s.connInfo=a),l&&(s.chanInfo=l)}return{clients:i}})}presenceStats(t){return is(this,void 0,void 0,function*(){const r={presence_stats:{channel:t}};yield this._methodCall();const n=yield this._callPromise(r,i=>i.presence_stats);return{numUsers:n.num_users,numClients:n.num_clients}})}startBatching(){this._batching=!0}stopBatching(){const t=this;Promise.resolve().then(function(){Promise.resolve().then(function(){t._batching=!1,t._flush()})})}_debug(...t){this._debugEnabled&&e7e("debug",t)}_codecName(){return this._codec.name()}_formatOverride(){}_configure(){if(!("Promise"in globalThis))throw new Error("Promise polyfill required");if(!this._endpoint)throw new Error("endpoint configuration required");if(this._config.token!==null&&(this._token=this._config.token),this._config.data!==null&&(this._data=this._config.data),this._codec=new xY,this._formatOverride(),(this._config.debug===!0||typeof localStorage<"u"&&typeof localStorage.getItem=="function"&&localStorage.getItem("centrifuge.debug"))&&(this._debugEnabled=!0),this._debug("config",this._config),typeof this._endpoint!="string")if(Array.isArray(this._endpoint)){this._transports=this._endpoint,this._emulation=!0;for(const t in this._transports)if(this._transports.hasOwnProperty(t)){const r=this._transports[t];if(!r.endpoint||!r.transport)throw new Error("malformed transport configuration");const n=r.transport;if(["websocket","http_stream","sse","sockjs","webtransport"].indexOf(n)<0)throw new Error("unsupported transport name: "+n)}}else throw new Error("unsupported url configuration type: only string or array of objects are supported")}_setState(t){if(this.state!==t){this._reconnecting=!1;const r=this.state;return this.state=t,this.emit("state",{newState:t,oldState:r}),!0}return!1}_isDisconnected(){return this.state===Gi.Disconnected}_isConnecting(){return this.state===Gi.Connecting}_isConnected(){return this.state===Gi.Connected}_nextCommandId(){return++this._commandId}_setNetworkEvents(){if(this._networkEventsSet)return;let t=null;this._config.networkEventTarget!==null?t=this._config.networkEventTarget:typeof globalThis.addEventListener<"u"&&(t=globalThis),t&&(t.addEventListener("offline",()=>{this._debug("offline event triggered"),(this.state===Gi.Connected||this.state===Gi.Connecting)&&(this._disconnect(Zh.transportClosed,"transport closed",!0),this._deviceWentOffline=!0)}),t.addEventListener("online",()=>{this._debug("online event triggered"),this.state===Gi.Connecting&&(this._deviceWentOffline&&!this._transportClosed&&(this._deviceWentOffline=!1,this._transportClosed=!0),this._clearReconnectTimeout(),this._startReconnecting())}),this._networkEventsSet=!0)}_getReconnectDelay(){const t=BM(this._reconnectAttempts,this._config.minReconnectDelay,this._config.maxReconnectDelay);return this._reconnectAttempts+=1,t}_clearOutgoingRequests(){for(const t in this._callbacks)if(this._callbacks.hasOwnProperty(t)){const r=this._callbacks[t];clearTimeout(r.timeout);const n=r.errback;if(!n)continue;n({error:this._createErrorObject(Zn.connectionClosed,"connection closed")})}this._callbacks={}}_clearConnectedState(){this._client=null,this._clearServerPingTimeout(),this._clearRefreshTimeout();for(const t in this._subs){if(!this._subs.hasOwnProperty(t))continue;const r=this._subs[t];r.state===bs.Subscribed&&r._setSubscribing(kM.transportClosed,"transport closed")}for(const t in this._serverSubs)this._serverSubs.hasOwnProperty(t)&&this.emit("subscribing",{channel:t})}_handleWriteError(t){for(const r of t){const n=r.id;if(!(n in this._callbacks))continue;const i=this._callbacks[n];clearTimeout(this._callbacks[n].timeout),delete this._callbacks[n];const o=i.errback;o({error:this._createErrorObject(Zn.transportWriteError,"transport write error")})}}_transportSendCommands(t){if(!t.length)return!0;if(!this._transport)return!1;try{this._transport.send(this._codec.encodeCommands(t),this._session,this._node)}catch(r){return this._debug("error writing commands",r),this._handleWriteError(t),!1}return!0}_initializeTransport(){let t;this._config.websocket!==null?t=this._config.websocket:typeof globalThis.WebSocket!="function"&&typeof globalThis.WebSocket!="object"||(t=globalThis.WebSocket);let r=null;this._config.sockjs!==null?r=this._config.sockjs:typeof globalThis.SockJS<"u"&&(r=globalThis.SockJS);let n=null;this._config.eventsource!==null?n=this._config.eventsource:typeof globalThis.EventSource<"u"&&(n=globalThis.EventSource);let i=null;this._config.fetch!==null?i=this._config.fetch:typeof globalThis.fetch<"u"&&(i=globalThis.fetch);let o=null;if(this._config.readableStream!==null?o=this._config.readableStream:typeof globalThis.ReadableStream<"u"&&(o=globalThis.ReadableStream),this._emulation){this._currentTransportIndex>=this._transports.length&&(this._triedAllTransports=!0,this._currentTransportIndex=0);let p=0;for(;;){if(p>=this._transports.length)throw new Error("no supported transport found");const f=this._transports[this._currentTransportIndex],g=f.transport,m=f.endpoint;if(g==="websocket"){if(this._debug("trying websocket transport"),this._transport=new wY(m,{websocket:t}),!this._transport.supported()){this._debug("websocket transport not available"),this._currentTransportIndex++,p++;continue}}else if(g==="webtransport"){if(this._debug("trying webtransport transport"),this._transport=new a7e(m,{webtransport:globalThis.WebTransport,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("webtransport transport not available"),this._currentTransportIndex++,p++;continue}}else if(g==="http_stream"){if(this._debug("trying http_stream transport"),this._transport=new o7e(m,{fetch:i,readableStream:o,emulationEndpoint:this._config.emulationEndpoint,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("http_stream transport not available"),this._currentTransportIndex++,p++;continue}}else if(g==="sse"){if(this._debug("trying sse transport"),this._transport=new s7e(m,{eventsource:n,fetch:i,emulationEndpoint:this._config.emulationEndpoint}),!this._transport.supported()){this._debug("sse transport not available"),this._currentTransportIndex++,p++;continue}}else if(g==="sockjs"){if(this._debug("trying sockjs"),this._transport=new i7e(m,{sockjs:r,sockjsOptions:this._config.sockjsOptions}),!this._transport.supported()){this._debug("sockjs transport not available"),this._currentTransportIndex++,p++;continue}}else throw new Error("unknown transport "+g);break}}else{if(JUe(this._endpoint,"http"))throw new Error("Provide explicit transport endpoints configuration in case of using HTTP (i.e. using array of TransportEndpoint instead of a single string), or use ws(s):// scheme in an endpoint if you aimed using WebSocket transport");if(this._debug("client will use websocket"),this._transport=new wY(this._endpoint,{websocket:t}),!this._transport.supported())throw new Error("WebSocket constructor not found, make sure it is available globally or passed as a dependency in Centrifuge options")}const s=this,a=this._transport,l=this._nextTransportId();s._debug("id of transport",l);let c=!1;const u=[];if(this._transport.emulation()){const p=s._sendConnect(!0);u.push(p)}this._setNetworkEvents();const d=this._codec.encodeCommands(u);this._transportClosed=!1;let h;h=setTimeout(function(){a.close()},this._config.timeout),this._transport.initialize(this._codecName(),{onOpen:function(){if(h&&(clearTimeout(h),h=null),s._transportId!=l){s._debug("open callback from non-actual transport"),a.close();return}c=!0,s._debug(a.subName(),"transport open"),!a.emulation()&&(s._transportIsOpen=!0,s._transportWasOpen=!0,s.startBatching(),s._sendConnect(!1),s._sendSubscribeCommands(),s.stopBatching(),s.emit("__centrifuge_debug:connect_frame_sent",{}))},onError:function(p){if(s._transportId!=l){s._debug("error callback from non-actual transport");return}s._debug("transport level error",p)},onClose:function(p){if(h&&(clearTimeout(h),h=null),s._transportId!=l){s._debug("close callback from non-actual transport");return}s._debug(a.subName(),"transport closed"),s._transportClosed=!0,s._transportIsOpen=!1;let f="connection closed",g=!0,m=0;if(p&&"code"in p&&p.code&&(m=p.code),p&&p.reason)try{const v=JSON.parse(p.reason);f=v.reason,g=v.reconnect}catch{f=p.reason,(m>=3500&&m<4e3||m>=4500&&m<5e3)&&(g=!1)}m<3e3?(m===1009?(m=$w.messageSizeLimit,f="message size limit exceeded",g=!1):(m=Zh.transportClosed,f="transport closed"),s._emulation&&!s._transportWasOpen&&(s._currentTransportIndex++,s._currentTransportIndex>=s._transports.length&&(s._triedAllTransports=!0,s._currentTransportIndex=0))):s._transportWasOpen=!0,s._isConnecting()&&!c&&s.emit("error",{type:"transport",error:{code:Zn.transportClosed,message:"transport closed"},transport:a.name()}),s._reconnecting=!1,s._disconnect(m,f,g)},onMessage:function(p){s._dataReceived(p)}},d),s.emit("__centrifuge_debug:transport_initialized",{})}_sendConnect(t){const r=this._constructConnectCommand(),n=this;return this._call(r,t).then(i=>{const o=i.reply.connect;n._connectResponse(o),i.next&&i.next()},i=>{n._connectError(i.error),i.next&&i.next()}),r}_startReconnecting(){if(this._debug("start reconnecting"),!this._isConnecting()){this._debug("stop reconnecting: client not in connecting state");return}if(this._reconnecting){this._debug("reconnect already in progress, return from reconnect routine");return}if(this._transportClosed===!1){this._debug("waiting for transport close");return}this._reconnecting=!0;const t=this._token==="";if(!(this._refreshRequired||t&&this._config.getToken!==null)){this._config.getData?this._config.getData().then(i=>{this._isConnecting()&&(this._data=i,this._initializeTransport())}).catch(i=>this._handleGetDataError(i)):this._initializeTransport();return}const n=this;this._getToken().then(function(i){if(n._isConnecting()){if(i==null||i==null){n._failUnauthorized();return}n._token=i,n._debug("connection token refreshed"),n._config.getData?n._config.getData().then(function(o){n._isConnecting()&&(n._data=o,n._initializeTransport())}).catch(o=>n._handleGetDataError(o)):n._initializeTransport()}}).catch(function(i){if(!n._isConnecting())return;if(i instanceof ud){n._failUnauthorized();return}n.emit("error",{type:"connectToken",error:{code:Zn.clientConnectToken,message:i!==void 0?i.toString():""}});const o=n._getReconnectDelay();n._debug("error on getting connection token, reconnect after "+o+" milliseconds",i),n._reconnecting=!1,n._reconnectTimeout=setTimeout(()=>{n._startReconnecting()},o)})}_handleGetDataError(t){if(t instanceof ud){this._failUnauthorized();return}this.emit("error",{type:"connectData",error:{code:Zn.badConfiguration,message:(t==null?void 0:t.toString())||""}});const r=this._getReconnectDelay();this._debug("error on getting connect data, reconnect after "+r+" milliseconds",t),this._reconnecting=!1,this._reconnectTimeout=setTimeout(()=>{this._startReconnecting()},r)}_connectError(t){this.state===Gi.Connecting&&(t.code===109&&(this._refreshRequired=!0),t.code<100||t.temporary===!0||t.code===109?(this.emit("error",{type:"connect",error:t}),this._debug("closing transport due to connect error"),this._disconnect(t.code,t.message,!0)):this._disconnect(t.code,t.message,!1))}_scheduleReconnect(){if(!this._isConnecting())return;let t=!1;this._emulation&&!this._transportWasOpen&&!this._triedAllTransports&&(t=!0);let r=this._getReconnectDelay();t&&(r=0),this._debug("reconnect after "+r+" milliseconds"),this._clearReconnectTimeout(),this._reconnectTimeout=setTimeout(()=>{this._startReconnecting()},r)}_constructConnectCommand(){const t={};this._token&&(t.token=this._token),this._data&&(t.data=this._data),this._config.name&&(t.name=this._config.name),this._config.version&&(t.version=this._config.version),Object.keys(this._config.headers).length>0&&(t.headers=this._config.headers);const r={};let n=!1;for(const i in this._serverSubs)if(this._serverSubs.hasOwnProperty(i)&&this._serverSubs[i].recoverable){n=!0;const o={recover:!0};this._serverSubs[i].offset&&(o.offset=this._serverSubs[i].offset),this._serverSubs[i].epoch&&(o.epoch=this._serverSubs[i].epoch),r[i]=o}return n&&(t.subs=r),{connect:t}}_getHistoryRequest(t,r){const n={channel:t};return r!==void 0&&(r.since&&(n.since={offset:r.since.offset},r.since.epoch&&(n.since.epoch=r.since.epoch)),r.limit!==void 0&&(n.limit=r.limit),r.reverse===!0&&(n.reverse=!0)),n}_methodCall(){return this._isConnected()?Promise.resolve():new Promise((t,r)=>{const n=setTimeout(function(){r({code:Zn.timeout,message:"timeout"})},this._config.timeout);this._promises[this._nextPromiseId()]={timeout:n,resolve:t,reject:r}})}_callPromise(t,r){return new Promise((n,i)=>{this._call(t,!1).then(o=>{var s;const a=r(o.reply);n(a),(s=o.next)===null||s===void 0||s.call(o)},o=>{var s;i(o.error),(s=o.next)===null||s===void 0||s.call(o)})})}_dataReceived(t){this._serverPing>0&&this._waitServerPing();const r=this._codec.decodeReplies(t);this._dispatchPromise=this._dispatchPromise.then(()=>{let n;this._dispatchPromise=new Promise(i=>{n=i}),this._dispatchSynchronized(r,n)})}_dispatchSynchronized(t,r){let n=Promise.resolve();for(const i in t)t.hasOwnProperty(i)&&(n=n.then(()=>this._dispatchReply(t[i])));n=n.then(()=>{r()})}_dispatchReply(t){let r;const n=new Promise(o=>{r=o});if(t==null)return this._debug("dispatch: got undefined or null reply"),r(),n;const i=t.id;return i&&i>0?this._handleReply(t,r):t.push?this._handlePush(t.push,r):this._handleServerPing(r),n}_call(t,r){return new Promise((n,i)=>{t.id=this._nextCommandId(),this._registerCall(t.id,n,i),r||this._addCommand(t)})}_startConnecting(){this._debug("start connecting"),this._setState(Gi.Connecting)&&this.emit("connecting",{code:Zh.connectCalled,reason:"connect called"}),this._client=null,this._startReconnecting()}_disconnect(t,r,n){if(this._isDisconnected())return;this._transportIsOpen=!1;const i=this.state;this._reconnecting=!1;const o={code:t,reason:r};let s=!1;if(n?s=this._setState(Gi.Connecting):(s=this._setState(Gi.Disconnected),this._rejectPromises({code:Zn.clientDisconnected,message:"disconnected"})),this._clearOutgoingRequests(),i===Gi.Connecting&&this._clearReconnectTimeout(),i===Gi.Connected&&this._clearConnectedState(),s&&(this._isConnecting()?this.emit("connecting",o):this.emit("disconnected",o)),this._transport){this._debug("closing existing transport");const a=this._transport;this._transport=null,a.close(),this._transportClosed=!0,this._nextTransportId()}else this._debug("no transport to close");this._scheduleReconnect()}_failUnauthorized(){this._disconnect($w.unauthorized,"unauthorized",!1)}_getToken(){return this._debug("get connection token"),this._config.getToken?this._config.getToken({}):(this.emit("error",{type:"configuration",error:{code:Zn.badConfiguration,message:"token expired but no getToken function set in the configuration"}}),Promise.reject(new ud("")))}_refresh(){const t=this._client,r=this;this._getToken().then(function(n){if(t!==r._client)return;if(!n){r._failUnauthorized();return}if(r._token=n,r._debug("connection token refreshed"),!r._isConnected())return;const i={refresh:{token:r._token}};r._call(i,!1).then(o=>{const s=o.reply.refresh;r._refreshResponse(s),o.next&&o.next()},o=>{r._refreshError(o.error),o.next&&o.next()})}).catch(function(n){if(r._isConnected()){if(n instanceof ud){r._failUnauthorized();return}r.emit("error",{type:"refreshToken",error:{code:Zn.clientRefreshToken,message:n!==void 0?n.toString():""}}),r._refreshTimeout=setTimeout(()=>r._refresh(),r._getRefreshRetryDelay())}})}_refreshError(t){t.code<100||t.temporary===!0?(this.emit("error",{type:"refresh",error:t}),this._refreshTimeout=setTimeout(()=>this._refresh(),this._getRefreshRetryDelay())):this._disconnect(t.code,t.message,!1)}_getRefreshRetryDelay(){return BM(0,5e3,1e4)}_refreshResponse(t){this._refreshTimeout&&(clearTimeout(this._refreshTimeout),this._refreshTimeout=null),t.expires&&(this._client=t.client,this._refreshTimeout=setTimeout(()=>this._refresh(),$M(t.ttl)))}_removeSubscription(t){t!==null&&delete this._subs[t.channel]}_unsubscribe(t){if(!this._transportIsOpen)return Promise.resolve();const n={unsubscribe:{channel:t.channel}},i=this;return new Promise((s,a)=>{this._call(n,!1).then(l=>{s(),l.next&&l.next()},l=>{s(),l.next&&l.next(),i._disconnect(Zh.unsubscribeError,"unsubscribe error",!0)})})}_getSub(t,r){if(r&&r>0){for(const i in this._subs)if(this._subs.hasOwnProperty(i)){const o=this._subs[i];if(o._id===r)return o}return null}const n=this._subs[t];return n||null}_isServerSub(t){return this._serverSubs[t]!==void 0}_sendSubscribeCommands(){const t=[];for(const r in this._subs){if(!this._subs.hasOwnProperty(r))continue;const n=this._subs[r];if(n._inflight!==!0&&n.state===bs.Subscribing){const i=n._subscribe();i&&t.push(i)}}return t}_connectResponse(t){if(this._transportIsOpen=!0,this._transportWasOpen=!0,this._reconnectAttempts=0,this._refreshRequired=!1,this._isConnected())return;this._client=t.client,this._setState(Gi.Connected),this._refreshTimeout&&clearTimeout(this._refreshTimeout),t.expires&&(this._refreshTimeout=setTimeout(()=>this._refresh(),$M(t.ttl))),this._session=t.session,this._node=t.node,this.startBatching(),this._sendSubscribeCommands(),this.stopBatching();const r={client:t.client,transport:this._transport.subName()};t.data&&(r.data=t.data),this.emit("connected",r),this._resolvePromises(),this._processServerSubs(t.subs||{}),t.ping&&t.ping>0?(this._serverPing=t.ping*1e3,this._sendPong=t.pong===!0,this._waitServerPing()):this._serverPing=0}_processServerSubs(t){for(const r in t){if(!t.hasOwnProperty(r))continue;const n=t[r];this._serverSubs[r]={offset:n.offset,epoch:n.epoch,recoverable:n.recoverable||!1};const i=this._getSubscribeContext(r,n);this.emit("subscribed",i)}for(const r in t){if(!t.hasOwnProperty(r))continue;const n=t[r];if(n.recovered){const i=n.publications;if(i&&i.length>0)for(const o in i)i.hasOwnProperty(o)&&this._handlePublication(r,i[o])}}for(const r in this._serverSubs)this._serverSubs.hasOwnProperty(r)&&(t[r]||(this.emit("unsubscribed",{channel:r}),delete this._serverSubs[r]))}_clearRefreshTimeout(){this._refreshTimeout!==null&&(clearTimeout(this._refreshTimeout),this._refreshTimeout=null)}_clearReconnectTimeout(){this._reconnectTimeout!==null&&(clearTimeout(this._reconnectTimeout),this._reconnectTimeout=null)}_clearServerPingTimeout(){this._serverPingTimeout!==null&&(clearTimeout(this._serverPingTimeout),this._serverPingTimeout=null)}_waitServerPing(){this._config.maxServerPingDelay!==0&&this._isConnected()&&(this._clearServerPingTimeout(),this._serverPingTimeout=setTimeout(()=>{this._isConnected()&&this._disconnect(Zh.noPing,"no ping",!0)},this._serverPing+this._config.maxServerPingDelay))}_getSubscribeContext(t,r){const n={channel:t,positioned:!1,recoverable:!1,wasRecovering:!1,recovered:!1,hasRecoveredPublications:!1};r.recovered&&(n.recovered=!0),r.positioned&&(n.positioned=!0),r.recoverable&&(n.recoverable=!0),r.was_recovering&&(n.wasRecovering=!0);let i="";"epoch"in r&&(i=r.epoch);let o=0;return"offset"in r&&(o=r.offset),(n.positioned||n.recoverable)&&(n.streamPosition={offset:o,epoch:i}),Array.isArray(r.publications)&&r.publications.length>0&&(n.hasRecoveredPublications=!0),r.data&&(n.data=r.data),n}_handleReply(t,r){const n=t.id;if(!(n in this._callbacks)){r();return}const i=this._callbacks[n];if(clearTimeout(this._callbacks[n].timeout),delete this._callbacks[n],r7e(t)){const o=i.errback;if(!o){r();return}const s={code:t.error.code,message:t.error.message||"",temporary:t.error.temporary||!1};o({error:s,next:r})}else{const o=i.callback;if(!o)return;o({reply:t,next:r})}}_handleJoin(t,r,n){const i=this._getSub(t,n);if(!i&&t){if(this._isServerSub(t)){const o={channel:t,info:this._getJoinLeaveContext(r.info)};this.emit("join",o)}return}i._handleJoin(r)}_handleLeave(t,r,n){const i=this._getSub(t,n);if(!i&&t){if(this._isServerSub(t)){const o={channel:t,info:this._getJoinLeaveContext(r.info)};this.emit("leave",o)}return}i._handleLeave(r)}_handleUnsubscribe(t,r){const n=this._getSub(t,0);if(!n&&t){this._isServerSub(t)&&(delete this._serverSubs[t],this.emit("unsubscribed",{channel:t}));return}r.code<2500?n._setUnsubscribed(r.code,r.reason,!1):n._setSubscribing(r.code,r.reason)}_handleSubscribe(t,r){this._serverSubs[t]={offset:r.offset,epoch:r.epoch,recoverable:r.recoverable||!1},this.emit("subscribed",this._getSubscribeContext(t,r))}_handleDisconnect(t){const r=t.code;let n=!0;(r>=3500&&r<4e3||r>=4500&&r<5e3)&&(n=!1),this._disconnect(r,t.reason,n)}_getPublicationContext(t,r){const n={channel:t,data:r.data};return r.offset&&(n.offset=r.offset),r.info&&(n.info=this._getJoinLeaveContext(r.info)),r.tags&&(n.tags=r.tags),n}_getJoinLeaveContext(t){const r={client:t.client,user:t.user},n=t.conn_info;n&&(r.connInfo=n);const i=t.chan_info;return i&&(r.chanInfo=i),r}_handlePublication(t,r,n){const i=this._getSub(t,n);if(!i&&t){if(this._isServerSub(t)){const o=this._getPublicationContext(t,r);this.emit("publication",o),r.offset!==void 0&&(this._serverSubs[t].offset=r.offset)}return}i._handlePublication(r)}_handleMessage(t){this.emit("message",{data:t.data})}_handleServerPing(t){if(this._sendPong){const r={};this._transportSendCommands([r])}t()}_handlePush(t,r){const n=t.channel,i=t.id;t.pub?this._handlePublication(n,t.pub,i):t.message?this._handleMessage(t.message):t.join?this._handleJoin(n,t.join,i):t.leave?this._handleLeave(n,t.leave,i):t.unsubscribe?this._handleUnsubscribe(n,t.unsubscribe):t.subscribe?this._handleSubscribe(n,t.subscribe):t.disconnect&&this._handleDisconnect(t.disconnect),r()}_flush(){const t=this._commands.slice(0);this._commands=[],this._transportSendCommands(t)}_createErrorObject(t,r,n){const i={code:t,message:r};return n&&(i.temporary=!0),i}_registerCall(t,r,n){this._callbacks[t]={callback:r,errback:n,timeout:null},this._callbacks[t].timeout=setTimeout(()=>{delete this._callbacks[t],$he(n)&&n({error:this._createErrorObject(Zn.timeout,"timeout")})},this._config.timeout)}_addCommand(t){this._batching?this._commands.push(t):this._transportSendCommands([t])}_nextPromiseId(){return++this._promiseId}_nextTransportId(){return++this._transportId}_resolvePromises(){for(const t in this._promises)this._promises.hasOwnProperty(t)&&(this._promises[t].timeout&&clearTimeout(this._promises[t].timeout),this._promises[t].resolve(),delete this._promises[t])}_rejectPromises(t){for(const r in this._promises)this._promises.hasOwnProperty(r)&&(this._promises[r].timeout&&clearTimeout(this._promises[r].timeout),this._promises[r].reject(t),delete this._promises[r])}}X4.SubscriptionState=bs;X4.State=Gi;X4.UnauthorizedError=ud;/** * React Router v6.30.3 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */const f7e=y.createContext({outlet:null,matches:[],isDataRoute:!1});function v$t(){let{matches:e}=y.useContext(f7e),t=e[e.length-1];return t?t.params:{}}new Promise(()=>{});var g7e=Object.defineProperty,GM=Object.getOwnPropertySymbols,Ghe=Object.prototype.hasOwnProperty,Vhe=Object.prototype.propertyIsEnumerable,EY=(e,t,r)=>t in e?g7e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,uV=(e,t)=>{for(var r in t||(t={}))Ghe.call(t,r)&&EY(e,r,t[r]);if(GM)for(var r of GM(t))Vhe.call(t,r)&&EY(e,r,t[r]);return e},dV=(e,t)=>{var r={};for(var n in e)Ghe.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&GM)for(var n of GM(e))t.indexOf(n)<0&&Vhe.call(e,n)&&(r[n]=e[n]);return r};/** * @license QR Code generator library (TypeScript) * Copyright (c) Project Nayuki. * SPDX-License-Identifier: MIT */var om;(e=>{const t=class an{constructor(l,c,u,d){if(this.version=l,this.errorCorrectionLevel=c,this.modules=[],this.isFunction=[],lan.MAX_VERSION)throw new RangeError("Version value out of range");if(d<-1||d>7)throw new RangeError("Mask value out of range");this.size=l*4+17;let h=[];for(let f=0;f7)throw new RangeError("Invalid value");let f,g;for(f=u;;f++){const S=an.getNumDataCodewords(f,c)*8,x=s.getTotalBits(l,f);if(x<=S){g=x;break}if(f>=d)throw new RangeError("Data too long")}for(const S of[an.Ecc.MEDIUM,an.Ecc.QUARTILE,an.Ecc.HIGH])p&&g<=an.getNumDataCodewords(f,S)*8&&(c=S);let m=[];for(const S of l){r(S.mode.modeBits,4,m),r(S.numChars,S.mode.numCharCountBits(f),m);for(const x of S.getData())m.push(x)}i(m.length==g);const v=an.getNumDataCodewords(f,c)*8;i(m.length<=v),r(0,Math.min(4,v-m.length),m),r(0,(8-m.length%8)%8,m),i(m.length%8==0);for(let S=236;m.lengthb[x>>>3]|=S<<7-(x&7)),new an(f,c,b,h)}getModule(l,c){return 0<=l&&l>>9)*1335;const d=(c<<10|u)^21522;i(d>>>15==0);for(let h=0;h<=5;h++)this.setFunctionModule(8,h,n(d,h));this.setFunctionModule(8,7,n(d,6)),this.setFunctionModule(8,8,n(d,7)),this.setFunctionModule(7,8,n(d,8));for(let h=9;h<15;h++)this.setFunctionModule(14-h,8,n(d,h));for(let h=0;h<8;h++)this.setFunctionModule(this.size-1-h,8,n(d,h));for(let h=8;h<15;h++)this.setFunctionModule(8,this.size-15+h,n(d,h));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let l=this.version;for(let u=0;u<12;u++)l=l<<1^(l>>>11)*7973;const c=this.version<<12|l;i(c>>>18==0);for(let u=0;u<18;u++){const d=n(c,u),h=this.size-11+u%3,p=Math.floor(u/3);this.setFunctionModule(h,p,d),this.setFunctionModule(p,h,d)}}drawFinderPattern(l,c){for(let u=-4;u<=4;u++)for(let d=-4;d<=4;d++){const h=Math.max(Math.abs(d),Math.abs(u)),p=l+d,f=c+u;0<=p&&p{(S!=g-h||E>=f)&&b.push(x[S])});return i(b.length==p),b}drawCodewords(l){if(l.length!=Math.floor(an.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");let c=0;for(let u=this.size-1;u>=1;u-=2){u==6&&(u=5);for(let d=0;d>>3],7-(c&7)),c++)}}i(c==l.length*8)}applyMask(l){if(l<0||l>7)throw new RangeError("Mask value out of range");for(let c=0;c5&&l++):(this.finderPenaltyAddHistory(f,g),p||(l+=this.finderPenaltyCountPatterns(g)*an.PENALTY_N3),p=this.modules[h][m],f=1);l+=this.finderPenaltyTerminateAndCount(p,f,g)*an.PENALTY_N3}for(let h=0;h5&&l++):(this.finderPenaltyAddHistory(f,g),p||(l+=this.finderPenaltyCountPatterns(g)*an.PENALTY_N3),p=this.modules[m][h],f=1);l+=this.finderPenaltyTerminateAndCount(p,f,g)*an.PENALTY_N3}for(let h=0;hp+(f?1:0),c);const u=this.size*this.size,d=Math.ceil(Math.abs(c*20-u*10)/u)-1;return i(0<=d&&d<=9),l+=d*an.PENALTY_N4,i(0<=l&&l<=2568888),l}getAlignmentPatternPositions(){if(this.version==1)return[];{const l=Math.floor(this.version/7)+2,c=this.version==32?26:Math.ceil((this.version*4+4)/(l*2-2))*2;let u=[6];for(let d=this.size-7;u.lengthan.MAX_VERSION)throw new RangeError("Version number out of range");let c=(16*l+128)*l+64;if(l>=2){const u=Math.floor(l/7)+2;c-=(25*u-10)*u-55,l>=7&&(c-=36)}return i(208<=c&&c<=29648),c}static getNumDataCodewords(l,c){return Math.floor(an.getNumRawDataModules(l)/8)-an.ECC_CODEWORDS_PER_BLOCK[c.ordinal][l]*an.NUM_ERROR_CORRECTION_BLOCKS[c.ordinal][l]}static reedSolomonComputeDivisor(l){if(l<1||l>255)throw new RangeError("Degree out of range");let c=[];for(let d=0;d0);for(const d of l){const h=d^u.shift();u.push(0),c.forEach((p,f)=>u[f]^=an.reedSolomonMultiply(p,h))}return u}static reedSolomonMultiply(l,c){if(l>>>8||c>>>8)throw new RangeError("Byte out of range");let u=0;for(let d=7;d>=0;d--)u=u<<1^(u>>>7)*285,u^=(c>>>d&1)*l;return i(u>>>8==0),u}finderPenaltyCountPatterns(l){const c=l[1];i(c<=this.size*3);const u=c>0&&l[2]==c&&l[3]==c*3&&l[4]==c&&l[5]==c;return(u&&l[0]>=c*4&&l[6]>=c?1:0)+(u&&l[6]>=c*4&&l[0]>=c?1:0)}finderPenaltyTerminateAndCount(l,c,u){return l&&(this.finderPenaltyAddHistory(c,u),c=0),c+=this.size,this.finderPenaltyAddHistory(c,u),this.finderPenaltyCountPatterns(u)}finderPenaltyAddHistory(l,c){c[0]==0&&(l+=this.size),c.pop(),c.unshift(l)}};t.MIN_VERSION=1,t.MAX_VERSION=40,t.PENALTY_N1=3,t.PENALTY_N2=3,t.PENALTY_N3=40,t.PENALTY_N4=10,t.ECC_CODEWORDS_PER_BLOCK=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],t.NUM_ERROR_CORRECTION_BLOCKS=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],e.QrCode=t;function r(a,l,c){if(l<0||l>31||a>>>l)throw new RangeError("Value out of range");for(let u=l-1;u>=0;u--)c.push(a>>>u&1)}function n(a,l){return(a>>>l&1)!=0}function i(a){if(!a)throw new Error("Assertion error")}const o=class mi{constructor(l,c,u){if(this.mode=l,this.numChars=c,this.bitData=u,c<0)throw new RangeError("Invalid argument");this.bitData=u.slice()}static makeBytes(l){let c=[];for(const u of l)r(u,8,c);return new mi(mi.Mode.BYTE,l.length,c)}static makeNumeric(l){if(!mi.isNumeric(l))throw new RangeError("String contains non-numeric characters");let c=[];for(let u=0;u=1<{(t=>{const r=class{constructor(i,o){this.ordinal=i,this.formatBits=o}};r.LOW=new r(0,1),r.MEDIUM=new r(1,0),r.QUARTILE=new r(2,3),r.HIGH=new r(3,2),t.Ecc=r})(e.QrCode||(e.QrCode={}))})(om||(om={}));(e=>{(t=>{const r=class{constructor(i,o){this.modeBits=i,this.numBitsCharCount=o}numCharCountBits(i){return this.numBitsCharCount[Math.floor((i+7)/17)]}};r.NUMERIC=new r(1,[10,12,14]),r.ALPHANUMERIC=new r(2,[9,11,13]),r.BYTE=new r(4,[8,16,16]),r.KANJI=new r(8,[8,10,12]),r.ECI=new r(7,[0,0,0]),t.Mode=r})(e.QrSegment||(e.QrSegment={}))})(om||(om={}));var ay=om;/** * @license qrcode.react * Copyright (c) Paul O'Shannessy * SPDX-License-Identifier: ISC */var m7e={L:ay.QrCode.Ecc.LOW,M:ay.QrCode.Ecc.MEDIUM,Q:ay.QrCode.Ecc.QUARTILE,H:ay.QrCode.Ecc.HIGH},zhe=128,Hhe="L",Whe="#FFFFFF",Uhe="#000000",jhe=!1,Khe=1,v7e=4,y7e=0,C7e=.1;function qhe(e,t=0){const r=[];return e.forEach(function(n,i){let o=null;n.forEach(function(s,a){if(!s&&o!==null){r.push(`M${o+t} ${i+t}h${a-o}v1H${o+t}z`),o=null;return}if(a===n.length-1){if(!s)return;o===null?r.push(`M${a+t},${i+t} h1v1H${a+t}z`):r.push(`M${o+t},${i+t} h${a+1-o}v1H${o+t}z`);return}s&&o===null&&(o=a)})}),r.join("")}function Xhe(e,t){return e.slice().map((r,n)=>n=t.y+t.h?r:r.map((i,o)=>o=t.x+t.w?i:!1))}function b7e(e,t,r,n){if(n==null)return null;const i=e.length+r*2,o=Math.floor(t*C7e),s=i/t,a=(n.width||o)*s,l=(n.height||o)*s,c=n.x==null?e.length/2-a/2:n.x*s,u=n.y==null?e.length/2-l/2:n.y*s,d=n.opacity==null?1:n.opacity;let h=null;if(n.excavate){let f=Math.floor(c),g=Math.floor(u),m=Math.ceil(a+c-f),v=Math.ceil(l+u-g);h={x:f,y:g,w:m,h:v}}const p=n.crossOrigin;return{x:c,y:u,h:l,w:a,excavation:h,opacity:d,crossOrigin:p}}function S7e(e,t){return t!=null?Math.max(Math.floor(t),0):e?v7e:y7e}function Yhe({value:e,level:t,minVersion:r,includeMargin:n,marginSize:i,imageSettings:o,size:s,boostLevel:a}){let l=Z.useMemo(()=>{const f=(Array.isArray(e)?e:[e]).reduce((g,m)=>(g.push(...ay.QrSegment.makeSegments(m)),g),[]);return ay.QrCode.encodeSegments(f,m7e[t],r,void 0,void 0,a)},[e,t,r,a]);const{cells:c,margin:u,numCells:d,calculatedImageSettings:h}=Z.useMemo(()=>{let p=l.getModules();const f=S7e(n,i),g=p.length+f*2,m=b7e(p,s,f,o);return{cells:p,margin:f,numCells:g,calculatedImageSettings:m}},[l,s,o,n,i]);return{qrcode:l,margin:u,cells:c,numCells:d,calculatedImageSettings:h}}var w7e=(function(){try{new Path2D().addPath(new Path2D)}catch{return!1}return!0})(),x7e=Z.forwardRef(function(t,r){const n=t,{value:i,size:o=zhe,level:s=Hhe,bgColor:a=Whe,fgColor:l=Uhe,includeMargin:c=jhe,minVersion:u=Khe,boostLevel:d,marginSize:h,imageSettings:p}=n,g=dV(n,["value","size","level","bgColor","fgColor","includeMargin","minVersion","boostLevel","marginSize","imageSettings"]),{style:m}=g,v=dV(g,["style"]),b=p==null?void 0:p.src,S=Z.useRef(null),x=Z.useRef(null),E=Z.useCallback(k=>{S.current=k,typeof r=="function"?r(k):r&&(r.current=k)},[r]),[R,T]=Z.useState(!1),{margin:M,cells:D,numCells:A,calculatedImageSettings:I}=Yhe({value:i,level:s,minVersion:u,boostLevel:d,includeMargin:c,marginSize:h,imageSettings:p,size:o});Z.useEffect(()=>{if(S.current!=null){const k=S.current,O=k.getContext("2d");if(!O)return;let B=D;const H=x.current,N=I!=null&&H!==null&&H.complete&&H.naturalHeight!==0&&H.naturalWidth!==0;N&&I.excavation!=null&&(B=Xhe(D,I.excavation));const z=window.devicePixelRatio||1;k.height=k.width=o*z;const W=o/A*z;O.scale(W,W),O.fillStyle=a,O.fillRect(0,0,A,A),O.fillStyle=l,w7e?O.fill(new Path2D(qhe(B,M))):D.forEach(function(V,$){V.forEach(function(K,q){K&&O.fillRect(q+M,$+M,1,1)})}),I&&(O.globalAlpha=I.opacity),N&&O.drawImage(H,I.x+M,I.y+M,I.w,I.h)}}),Z.useEffect(()=>{T(!1)},[b]);const L=uV({height:o,width:o},m);let F=null;return b!=null&&(F=Z.createElement("img",{src:b,key:b,style:{display:"none"},onLoad:()=>{T(!0)},ref:x,crossOrigin:I==null?void 0:I.crossOrigin})),Z.createElement(Z.Fragment,null,Z.createElement("canvas",uV({style:L,height:o,width:o,ref:E,role:"img"},v)),F)});x7e.displayName="QRCodeCanvas";var E7e=Z.forwardRef(function(t,r){const n=t,{value:i,size:o=zhe,level:s=Hhe,bgColor:a=Whe,fgColor:l=Uhe,includeMargin:c=jhe,minVersion:u=Khe,boostLevel:d,title:h,marginSize:p,imageSettings:f}=n,g=dV(n,["value","size","level","bgColor","fgColor","includeMargin","minVersion","boostLevel","title","marginSize","imageSettings"]),{margin:m,cells:v,numCells:b,calculatedImageSettings:S}=Yhe({value:i,level:s,minVersion:u,boostLevel:d,includeMargin:c,marginSize:p,imageSettings:f,size:o});let x=v,E=null;f!=null&&S!=null&&(S.excavation!=null&&(x=Xhe(v,S.excavation)),E=Z.createElement("image",{href:f.src,height:S.h,width:S.w,x:S.x+m,y:S.y+m,preserveAspectRatio:"none",opacity:S.opacity,crossOrigin:S.crossOrigin}));const R=qhe(x,m);return Z.createElement("svg",uV({height:o,width:o,viewBox:`0 0 ${b} ${b}`,ref:r,role:"img"},g),!!h&&Z.createElement("title",null,h),Z.createElement("path",{fill:a,d:`M0,0 h${b}v${b}H0z`,shapeRendering:"crispEdges"}),Z.createElement("path",{fill:l,d:R,shapeRendering:"crispEdges"}),E)});E7e.displayName="QRCodeSVG";var Kp=class{constructor(){this.allSyncListeners=new Map,this.allAsyncListeners=new Map,this.globalSyncListeners=new Set,this.globalAsyncListeners=new Set,this.asyncFunctionsQueue=[],this.scheduled=!1,this.firedEvents={}}setFrameworkOverrides(e){this.frameworkOverrides=e}getListeners(e,t,r){const n=t?this.allAsyncListeners:this.allSyncListeners;let i=n.get(e);return!i&&r&&(i=new Set,n.set(e,i)),i}noRegisteredListenersExist(){return this.allSyncListeners.size===0&&this.allAsyncListeners.size===0&&this.globalSyncListeners.size===0&&this.globalAsyncListeners.size===0}addEventListener(e,t,r=!1){this.getListeners(e,r,!0).add(t)}removeEventListener(e,t,r=!1){const n=this.getListeners(e,r,!1);n&&(n.delete(t),n.size===0&&(r?this.allAsyncListeners:this.allSyncListeners).delete(e))}addGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).add(e)}removeGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).delete(e)}dispatchEvent(e){const t=e;this.dispatchToListeners(t,!0),this.dispatchToListeners(t,!1),this.firedEvents[t.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){const r=e.type;if(t&&"event"in e){const a=e.event;a instanceof Event&&(e.eventPath=a.composedPath())}const n=(a,l)=>a.forEach(c=>{if(!l.has(c))return;const u=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>c(e)):()=>c(e);t?this.dispatchAsync(u):u()}),i=this.getListeners(r,t,!1)??new Set,o=new Set(i);o.size>0&&n(o,i),new Set(t?this.globalAsyncListeners:this.globalSyncListeners).forEach(a=>{const l=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>a(r,e)):()=>a(r,e);t?this.dispatchAsync(l):l()})}dispatchAsync(e){if(this.asyncFunctionsQueue.push(e),!this.scheduled){const t=()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)};this.frameworkOverrides?this.frameworkOverrides.wrapIncoming(t):t(),this.scheduled=!0}}flushAsyncQueue(){this.scheduled=!1;const e=this.asyncFunctionsQueue.slice();this.asyncFunctionsQueue=[],e.forEach(t=>t())}};function T7e(e,t){return t}function Y4(e){return(e==null?void 0:e.getLocaleTextFunc())??T7e}function Al(e,t,r){r==null||typeof r=="string"&&r==""?Z4(e,t):Fl(e,t,r)}function Fl(e,t,r){e.setAttribute(Zhe(t),r.toString())}function Z4(e,t){e.removeAttribute(Zhe(t))}function Zhe(e){return`aria-${e}`}function Un(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function R7e(e){let t;return e==="asc"?t="ascending":e==="desc"?t="descending":e==="mixed"?t="other":t="none",t}function P7e(e){return parseInt(e.getAttribute("aria-posinset"),10)}function M7e(e){return e.getAttribute("aria-label")}function jn(e,t){Al(e,"label",t)}function Mp(e,t){Al(e,"labelledby",t)}function vA(e,t){Al(e,"describedby",t)}function Qhe(e,t){Al(e,"live",t)}function I7e(e,t){Al(e,"atomic",t)}function D7e(e,t){Al(e,"relevant",t)}function s1(e,t){Al(e,"level",t)}function VM(e,t){Al(e,"disabled",t)}function Q4(e,t){Al(e,"hidden",t)}function Jhe(e,t){Al(e,"activedescendant",t)}function Ds(e,t){Fl(e,"expanded",t)}function epe(e){Z4(e,"expanded")}function yA(e,t){Fl(e,"setsize",t)}function CA(e,t){Fl(e,"posinset",t)}function A7e(e,t){Fl(e,"multiselectable",t)}function tpe(e,t){Fl(e,"rowcount",t)}function J4(e,t){Fl(e,"rowindex",t)}function rpe(e,t){Fl(e,"colcount",t)}function e5(e,t){Fl(e,"colindex",t)}function npe(e,t){Fl(e,"colspan",t)}function ipe(e,t){Fl(e,"sort",t)}function ope(e){Z4(e,"sort")}function L0(e,t){Al(e,"selected",t)}function spe(e,t){Fl(e,"checked",t===void 0?"mixed":t)}function t5(e,t){Al(e,"controls",t.id),Mp(t,e.id)}function r5(e,t){return t===void 0?e("ariaIndeterminate","indeterminate"):t===!0?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}var DO,AO,FO,LO,_O,hV,pV,OO;function Im(){return DO===void 0&&(DO=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),DO}function ape(){if(AO===void 0){const e=window;AO=!!e.chrome&&(!!e.chrome.webstore||!!e.chrome.runtime)||/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor)}return AO}function lpe(){return FO===void 0&&(FO=/(firefox)/i.test(navigator.userAgent)),FO}function cpe(){return LO===void 0&&(LO=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),LO}function fp(){return _O===void 0&&(_O=/iPad|iPhone|iPod/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1),_O}function fV(e){if(!e)return null;const t=e.tabIndex,r=e.getAttribute("tabIndex");return t===-1&&(r===null||r===""&&!lpe())?null:t.toString()}function F7e(){if(OO!==void 0)return OO;if(!document.body)return-1;let e=1e6;const t=lpe()?6e6:1e9,r=document.createElement("div");for(document.body.appendChild(r);;){const n=e*2;if(r.style.height=n+"px",n>t||r.clientHeight!==n)break;e=n}return document.body.removeChild(r),OO=e,e}function L7e(){return pV==null&&upe(),pV}function upe(){const e=document.body,t=document.createElement("div");t.style.width=t.style.height="100px",t.style.opacity="0",t.style.overflow="scroll",t.style.msOverflowStyle="scrollbar",t.style.position="absolute",e.appendChild(t);let r=t.offsetWidth-t.clientWidth;r===0&&t.clientWidth===0&&(r=null),t.parentNode&&t.parentNode.removeChild(t),r!=null&&(pV=r,hV=r===0)}function dpe(){return hV==null&&upe(),hV}var wT;function zM(e,t,r){const n=e.parentElement;let i=n&&n.firstChild;for(;i;)t&&i.classList.toggle(t,i===e),r&&i.classList.toggle(r,i!==e),i=i.nextSibling}var _7e="[tabindex], input, select, button, textarea, [href]",hpe="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function n5(e){const t=Element.prototype.matches||Element.prototype.msMatchesSelector,n=t.call(e,"input, select, button, textarea"),i=t.call(e,hpe),o=ps(e);return n&&!i&&o}function Pt(e,t,r={}){const{skipAriaHidden:n}=r;e.classList.toggle("ag-hidden",!t),n||Q4(e,!t)}function ppe(e,t,r={}){const{skipAriaHidden:n}=r;e.classList.toggle("ag-invisible",!t),n||Q4(e,!t)}function cl(e,t){const r="disabled",n=t?i=>i.setAttribute(r,""):i=>i.removeAttribute(r);n(e),Cpe(e.querySelectorAll("input"),i=>n(i))}function Bg(e,t,r){let n=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,typeof r=="number"){if(++n>r)break}else if(e===r)break}return!1}function Dm(e){const{height:t,width:r,borderTopWidth:n,borderRightWidth:i,borderBottomWidth:o,borderLeftWidth:s,paddingTop:a,paddingRight:l,paddingBottom:c,paddingLeft:u,marginTop:d,marginRight:h,marginBottom:p,marginLeft:f,boxSizing:g}=window.getComputedStyle(e);return{height:parseFloat(t||"0"),width:parseFloat(r||"0"),borderTopWidth:parseFloat(n||"0"),borderRightWidth:parseFloat(i||"0"),borderBottomWidth:parseFloat(o||"0"),borderLeftWidth:parseFloat(s||"0"),paddingTop:parseFloat(a||"0"),paddingRight:parseFloat(l||"0"),paddingBottom:parseFloat(c||"0"),paddingLeft:parseFloat(u||"0"),marginTop:parseFloat(d||"0"),marginRight:parseFloat(h||"0"),marginBottom:parseFloat(p||"0"),marginLeft:parseFloat(f||"0"),boxSizing:g}}function bA(e){const t=Dm(e);return t.boxSizing==="border-box"?t.height-t.paddingTop-t.paddingBottom:t.height}function Xy(e){const t=Dm(e);return t.boxSizing==="border-box"?t.width-t.paddingLeft-t.paddingRight:t.width}function SA(e){const{height:t,marginBottom:r,marginTop:n}=Dm(e);return Math.floor(t+r+n)}function sm(e){const{width:t,marginLeft:r,marginRight:n}=Dm(e);return Math.floor(t+r+n)}function fpe(e){const t=e.getBoundingClientRect(),{borderTopWidth:r,borderLeftWidth:n,borderRightWidth:i,borderBottomWidth:o}=Dm(e);return{top:t.top+(r||0),left:t.left+(n||0),right:t.right+(i||0),bottom:t.bottom+(o||0)}}function HM(){if(typeof wT=="boolean")return wT;const e=document.createElement("div");return e.style.direction="rtl",e.style.width="1px",e.style.height="1px",e.style.position="fixed",e.style.top="0px",e.style.overflow="hidden",e.dir="rtl",e.innerHTML=`
`,document.body.appendChild(e),e.scrollLeft=1,wT=Math.floor(e.scrollLeft)===0,document.body.removeChild(e),wT}function WM(e,t){let r=e.scrollLeft;return t&&(r=Math.abs(r),ape()&&!HM()&&(r=e.scrollWidth-e.getBoundingClientRect().width-r)),r}function UM(e,t,r){r&&(HM()?t*=-1:(Im()||ape())&&(t=e.scrollWidth-e.getBoundingClientRect().width-t)),e.scrollLeft=t}function Jr(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}function si(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function gpe(e){return!!e.offsetParent}function ps(e){const t=e;return t.checkVisibility?t.checkVisibility({checkVisibilityCSS:!0}):!(!gpe(e)||window.getComputedStyle(e).visibility!=="visible")}function Ts(e){const t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function mpe(e,t,r){r&&r.nextSibling===t||(r?r.nextSibling?e.insertBefore(t,r.nextSibling):e.appendChild(t):e.firstChild&&e.firstChild!==t&&e.insertAdjacentElement("afterbegin",t))}function vpe(e,t){for(let r=0;r`-${t.toLocaleLowerCase()}`)}function ype(e,t){if(t)for(const[r,n]of Object.entries(t)){if(!r||!r.length||n==null)continue;const i=k7e(r),o=n.toString(),s=o.replace(/\s*!important/g,""),a=s.length!=o.length?"important":void 0;e.style.setProperty(i,s,a)}}function N7e(e){return e.clientWidtht.push(r)),t}function G7e(e,t){if(e)for(let r=0;r{const n=r.getGui();n!=null&&(typeof n=="object"?t.appendChild(n):t.innerHTML=n)})}function Ga(e,t,r){const i=Ipe(e).ResizeObserver,o=i?new i(r):null;return o==null||o.observe(t),()=>o==null?void 0:o.disconnect()}function Ai(e){return e==null||e===""?null:e}function Qe(e){return e!=null&&e!==""}function Kr(e){return!Qe(e)}function ia(e){return e!=null&&typeof e.toString=="function"?e.toString():null}function Yy(e,t){const r=e?JSON.stringify(e):null,n=t?JSON.stringify(t):null;return r===n}function SP(e,t,r=!1){const n=e==null,i=t==null;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),n&&i)return 0;if(n)return-1;if(i)return 1;function o(s,a){return s>a?1:sconsole.warn("AG Grid: "+e,...t),e+(t==null?void 0:t.join("")))}function Ty(e,...t){o5(()=>console.error("AG Grid: "+e,...t),e+(t==null?void 0:t.join("")))}var kO=[],NO=!1;function RY(e){kO.push(e),!NO&&(NO=!0,window.setTimeout(()=>{const t=kO.slice();kO.length=0,NO=!1,t.forEach(r=>r())},0))}function no(e,t,r){let n;return function(...i){const o=this;window.clearTimeout(n),n=window.setTimeout(function(){e.isAlive()&&t.apply(o,i)},r)}}function PY(e,t){let r=0;return function(...n){const i=this,o=new Date().getTime();o-r{const l=new Date().getTime()-i>r;(e()||l)&&(t(),s=!0,o!=null&&(window.clearInterval(o),o=null))};a(),s||(o=window.setInterval(a,10))}var $t="33.0.4",MY=2e3,IY=100,xpe="_version_",wP=null,Zy=`${Spe}/javascript-data-grid`;function V7e(e){wP=e}function z7e(e){Zy=e}function Epe(e,t,r){return(wP==null?void 0:wP.getConsoleMessage(e,t))??[j7e(e,t,r)]}function s5(e,t,r,n){e(`error #${t}`,...Epe(t,r,n))}function H7e(e){if(!e)return String(e);const t={};for(const r of Object.keys(e))typeof e[r]!="object"&&typeof e[r]!="function"&&(t[r]=e[r]);return JSON.stringify(t)}function W7e(e){let t=e;return e instanceof Error?t=e.toString():typeof e=="object"&&(t=H7e(e)),t}function KM(e){return e===void 0?"undefined":e===null?"null":e}function gV(e,t){return`${e}?${t.toString()}`}function U7e(e,t,r){const n=Array.from(t.entries()).sort((o,s)=>s[1].length-o[1].length);let i=gV(e,t);for(const[o,s]of n){if(o===xpe)continue;const a=i.length-r;if(a<=0)break;const l="...",c=a+l.length,u=s.length-c>IY?s.slice(0,s.length-c)+l:s.slice(0,IY)+l;t.set(o,u),i=gV(e,t)}return i}function Tpe(e,t){const r=new URLSearchParams;r.append(xpe,$t),t&&Object.entries(t).forEach(([o,s])=>{r.append(o,W7e(s))});const n=`${Zy}/errors/${e}`,i=gV(n,r);return i.length<=MY?i:U7e(n,r,MY)}var j7e=(e,t,r)=>{const n=Tpe(e,t);return`${r?r+` `:""}Visit ${n}${r?"":` Alternatively register the ValidationModule to see the full message in the console.`}`};function we(...e){s5(au,e[0],e[1])}function yr(...e){s5(Ty,e[0],e[1])}function mV(e,t,r){s5(Ty,e,t,r)}function Rpe(e,t){const r=t[0];return`error #${r} `+Epe(r,t[1],e).join(" ")}function yl(...e){return Rpe(void 0,e)}function Ppe(...e){return Rpe(` `,e)}function Mpe(e,t){return e.get("rowModelType")===t}function En(e,t){return Mpe(e,"clientSide")}function Ro(e,t){return Mpe(e,"serverSide")}function Eo(e,t){return e.get("domLayout")===t}function Fa(e){return eC(e)!==void 0}function a5(e){return typeof e.get("getRowHeight")=="function"}function K7e(e,t){return t?!e.get("enableStrictPivotColumnOrder"):e.get("maintainColumnOrder")}function ls(e,t,r=!1,n){const{gos:i,environment:o}=e;if(n==null&&(n=o.getDefaultRowHeight()),a5(i)){if(r)return{height:n,estimated:!0};const l={node:t,data:t.data},c=i.getCallback("getRowHeight")(l);if(vV(c))return c===0&&we(23),{height:Math.max(1,c),estimated:!1}}if(t.detail&&i.get("masterDetail"))return q7e(i);const s=i.get("rowHeight");return{height:s&&vV(s)?s:n,estimated:!1}}function q7e(e){if(e.get("detailRowAutoHeight"))return{height:1,estimated:!1};const t=e.get("detailRowHeight");return vV(t)?{height:t,estimated:!1}:{height:300,estimated:!1}}function oa(e){const{environment:t,gos:r}=e,n=r.get("rowHeight");if(!n||Kr(n))return t.getDefaultRowHeight();const i=t.refreshRowHeightVariable();return i!==-1?i:(we(24),t.getDefaultRowHeight())}function vV(e){return!isNaN(e)&&typeof e=="number"&&isFinite(e)}function qM(e,t,r){const n=t[e.getDomDataKey()];return n?n[r]:void 0}function am(e,t,r,n){const i=e.getDomDataKey();let o=t[i];Kr(o)&&(o={},t[i]=o),o[r]=n}function pn(e){const{gos:t,eGridDiv:r}=e;let n=null;const i=t.get("getDocument");return i&&Qe(i)?n=i():r&&(n=r.ownerDocument),n&&Qe(n)?n:document}function Ipe(e){return pn(e).defaultView||window}function Qy(e){return e.eGridDiv.getRootNode()}function Gr(e){return Qy(e).activeElement}function xA(e){let t=null,r=null;try{t=pn(e).fullscreenElement}catch{}finally{t||(t=Qy(e));const n=t.querySelector("body");n?r=n:t instanceof ShadowRoot?r=t:t instanceof Document?r=t==null?void 0:t.documentElement:r=t}return r}function X7e(e){const t=xA(e);return(t==null?void 0:t.clientWidth)??(window.innerHeight||-1)}function Y7e(e){const t=xA(e);return(t==null?void 0:t.clientHeight)??(window.innerHeight||-1)}function yV(e,t,r){const i=e.getBoundingClientRect().height,o=X7e(r)-2,s=Y7e(r)-2;if(!e.offsetParent)return;const l=fpe(e.offsetParent),{clientY:c,clientX:u}=t;let d=c-l.top-i/2,h=u-l.left-10;const p=pn(r),f=p.defaultView||window,g=f.pageYOffset||p.documentElement.scrollTop,m=f.pageXOffset||p.documentElement.scrollLeft;o>0&&h+e.clientWidth>o+m&&(h=o+m-e.clientWidth),h<0&&(h=0),s>0&&d+e.clientHeight>s+g&&(d=s+g-e.clientHeight),d<0&&(d=0),e.style.left=`${h}px`,e.style.top=`${d}px`}function Dp(e){const t=pn(e),r=Gr(e);return r===null||r===t.body}function Ry(e){return e.get("ensureDomOrder")?!1:e.get("animateRows")}function EA(e){return!(e.get("paginateChildRows")||e.get("groupHideOpenParents")||Eo(e,"print"))}function rc(e){const t=e.get("autoGroupColumnDef");return!(t!=null&&t.comparator)&&!e.get("treeData")}function _0(e){const t=e.get("groupAggFiltering");if(typeof t=="function")return e.getCallback("groupAggFiltering");if(t===!0)return()=>!0}function TA(e){return e.get("grandTotalRow")}function Jy(e){const t=e.get("groupTotalRow");return typeof t=="function"?e.getCallback("groupTotalRow"):()=>t??void 0}function l5(e){return e.exists("groupDisplayType")?e.get("groupDisplayType")==="multipleColumns":e.get("groupHideOpenParents")}function RA(e,t){return t?!1:e.get("groupDisplayType")==="groupRows"}function Fd(e){const t=e.getCallback("getRowId");return t===void 0?t:r=>{let n=t(r);return typeof n!="string"&&(we(25,{id:n}),n=String(n)),n}}function Z7e(e,t){const r=e.get("groupHideParentOfSingleChild");return!!(r===!0||r==="leafGroupsOnly"&&t.leafGroup||e.get("groupRemoveSingleChildren")||e.get("groupRemoveLowestSingleChildren")&&t.leafGroup)}function Dpe(e){const t=e.get("maxConcurrentDatasourceRequests");return t>0?t:void 0}function Ape(e,t){const r=e.get("suppressGroupChangesColumnVisibility");if(r===!0||t&&r==="suppressHideOnGroup"||!t&&r==="suppressShowOnUngroup")return!1;const n=e.get("suppressRowGroupHidesColumns");if(t&&n===!0)return!1;const i=e.get("suppressMakeColumnVisibleAfterUnGroup");return!(!t&&i===!0)}function $g(e){return(e==null?void 0:e.checkboxes)??!0}function xP(e){return(e==null?void 0:e.mode)==="multiRow"&&(e.headerCheckbox??!0)}function XM(e){if(typeof e=="object")return e.checkboxLocation??"selectionColumn"}function BO(e){return(e==null?void 0:e.hideDisabledCheckboxes)??!1}function c5(e){return typeof e.get("rowSelection")!="string"}function Q7e(e){return e.get("cellSelection")!==void 0}function xT(e){const t=e.get("cellSelection");return t!==void 0?typeof t!="boolean"?(t==null?void 0:t.suppressMultiRanges)??!1:!1:e.get("suppressMultiRangeSelection")}function Rs(e){const t=e.get("cellSelection");return t!==void 0?!!t:e.get("enableRangeSelection")}function $O(e){var n;const t=e.get("cellSelection");return t!==void 0?typeof t!="boolean"&&((n=t.handle)==null?void 0:n.mode)==="fill"?t.handle:void 0:{mode:"fill",setFillValue:e.get("fillOperation"),direction:e.get("fillHandleDirection"),suppressClearOnFillReduction:e.get("suppressClearOnFillReduction")}}function Fpe(e){const t=e.get("rowSelection")??"single";if(typeof t=="string"){const r=e.get("suppressRowClickSelection"),n=e.get("suppressRowDeselection");return r&&n?!1:r?"enableDeselection":n?"enableSelection":!0}return t.mode==="singleRow"||t.mode==="multiRow"?t.enableClickSelection??!1:!1}function J7e(e){const t=Fpe(e);return t===!0||t==="enableSelection"}function DY(e){const t=Fpe(e);return t===!0||t==="enableDeselection"}function CV(e){const t=e.get("rowSelection");return typeof t=="string"?e.get("isRowSelectable"):t==null?void 0:t.isRowSelectable}function eC(e){const t=e.get("rowSelection");if(typeof t=="string")switch(t){case"multiple":return"multiRow";case"single":return"singleRow";default:return}switch(t==null?void 0:t.mode){case"multiRow":case"singleRow":return t.mode;default:return}}function Ap(e){return eC(e)==="multiRow"}function e9e(e){const t=e.get("rowSelection");return typeof t=="string"?e.get("rowMultiSelectWithClick"):(t==null?void 0:t.enableSelectionWithoutKeys)??!1}function YM(e){const t=e.get("rowSelection");if(typeof t=="string"){const r=e.get("groupSelectsChildren"),n=e.get("groupSelectsFiltered");return r&&n?"filteredDescendants":r?"descendants":"self"}return(t==null?void 0:t.mode)==="multiRow"?t.groupSelects:void 0}function Lpe(e,t=!0){const r=e.get("rowSelection");return typeof r!="object"?t?"all":void 0:r.mode==="multiRow"?r.selectAll:"all"}function lm(e){const t=YM(e);return t==="descendants"||t==="filteredDescendants"}function GO(e){return e.isModuleRegistered("SetFilter")&&!e.get("suppressSetFilterByDefault")}function wo(e){return e.get("columnMenu")==="legacy"}function _pe(e){return!wo(e)}function Ope(e){return!e||e.length<2?e:"on"+e[0].toUpperCase()+e.substring(1)}function t9e(e,t,r){typeof e!="object"&&(e={});const n={...e};return r.forEach(i=>{const o=t[i];typeof o<"u"&&(n[i]=o)}),n}function r9e(e,t){if(!e)return;const r={};let n=!1;if(Object.keys(e).forEach(s=>{r[s]=e[s],n=!0}),!n)return;const i={type:"gridOptionsChanged",options:r};t.dispatchEvent(i);const o={type:"componentStateChanged",...r};t.dispatchEvent(o)}var kpe="__ag_Grid_Stop_Propagation",n9e=["touchstart","touchend","touchmove","touchcancel","scroll"],i9e=["wheel"],VO={};function di(e){e[kpe]=!0}function Na(e){return e[kpe]===!0}var Npe=(()=>{const e={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return r=>{if(typeof VO[r]=="boolean")return VO[r];const n=document.createElement(e[r]||"div");return r="on"+r,VO[r]=r in n}})();function Bpe(e,t,r){let n=t;for(;n;){const i=qM(e,n,r);if(i)return i;n=n.parentElement}return null}function bV(e,t){return!t||!e?!1:s9e(t).indexOf(e)>=0}function o9e(e){const t=[];let r=e.target;for(;r;)t.push(r),r=r.parentElement;return t}function s9e(e){const t=e;return t.path?t.path:t.composedPath?t.composedPath():o9e(t)}function a9e(e,t,r,n){const i=$pe(r);let o;i!=null&&(o={passive:i}),e&&e.addEventListener&&e.addEventListener(t,r,n,o)}var $pe=e=>{const t=n9e.includes(e),r=i9e.includes(e);if(t)return!0;if(r)return!1},xe=class{constructor(){this.destroyFunctions=[],this.destroyed=!1,this.__v_skip=!0,this.propertyListenerId=0,this.lastChangeSetIdLookup={},this.isAlive=()=>!this.destroyed}preWireBeans(e){this.beans=e,this.stubContext=e.context,this.eventSvc=e.eventSvc,this.gos=e.gos}destroy(){const{destroyFunctions:e}=this;for(let t=0;tnull;e instanceof HTMLElement?a9e(this.beans.frameworkOverrides,e,t,r):e.addEventListener(t,r);const n=()=>(e.removeEventListener(t,r),null);return this.destroyFunctions.push(n),()=>(n(),this.destroyFunctions=this.destroyFunctions.filter(i=>i!==n),null)}setupGridOptionListener(e,t){const{gos:r}=this;r.addPropertyEventListener(e,t);const n=()=>(r.removePropertyEventListener(e,t),null);return this.destroyFunctions.push(n),()=>(n(),this.destroyFunctions=this.destroyFunctions.filter(i=>i!==n),null)}addManagedPropertyListener(e,t){return this.destroyed?()=>null:this.setupGridOptionListener(e,t)}addManagedPropertyListeners(e,t){if(this.destroyed)return;const r=e.join("-")+this.propertyListenerId++,n=i=>{if(i.changeSet){if(i.changeSet&&i.changeSet.id===this.lastChangeSetIdLookup[r])return;this.lastChangeSetIdLookup[r]=i.changeSet.id}const o={type:"gridPropertyChanged",changeSet:i.changeSet,source:i.source};t(o)};e.forEach(i=>this.setupGridOptionListener(i,n))}getLocaleTextFunc(){return Y4(this.beans.localeSvc)}addDestroyFunc(e){this.isAlive()?this.destroyFunctions.push(e):e()}createOptionalManagedBean(e,t){return e?this.createManagedBean(e,t):void 0}createManagedBean(e,t){const r=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),r}createBean(e,t,r){return(t||this.stubContext).createBean(e,r)}destroyBean(e,t){return(t||this.stubContext).destroyBean(e)}destroyBeans(e,t){return(t||this.stubContext).destroyBeans(e)}},Gpe=new Set(["__proto__","constructor","prototype"]);function l9e(e,t){if(e!=null){if(Array.isArray(e)){for(let r=0;r{if(Gpe.has(i))return;let s=e[i];s!==o&&(n&&s==null&&o!=null&&typeof o=="object"&&o.constructor===Object&&(s={},e[i]=s),AY(o)&&AY(s)&&!Array.isArray(s)?Ii(s,o,r,n):(r||o!==void 0)&&(e[i]=o))})}function Vw(e,t,r){if(!t||!e)return;if(!r)return e[t];const n=t.split(".");let i=e;for(let o=0;o=0&&!n,this.tooltipFieldContainsDots=Qe(r)&&r.indexOf(".")>=0&&!n}initMinAndMaxWidths(){const e=this.colDef;this.minWidth=e.minWidth??this.beans.environment.getDefaultColumnMinWidth(),this.maxWidth=e.maxWidth??Number.MAX_SAFE_INTEGER}initTooltip(){var e;(e=this.beans.tooltipSvc)==null||e.initCol(this)}resetActualWidth(e){const t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){let t;const r=e.width,n=e.initialWidth;return r!=null?t=r:n!=null?t=n:t=200,Math.max(Math.min(t,this.maxWidth),this.minWidth)}isEmptyGroup(){return!1}isRowGroupDisplayed(e){var t;return((t=this.beans.showRowGroupCols)==null?void 0:t.isRowGroupDisplayed(this,e))??!1}isPrimary(){return this.primary}isFilterAllowed(){return!!this.colDef.filter}isFieldContainsDots(){return this.fieldContainsDots}isTooltipEnabled(){return this.tooltipEnabled}isTooltipFieldContainsDots(){return this.tooltipFieldContainsDots}getHighlighted(){return this.highlighted}addEventListener(e,t){var n,i,o;this.frameworkEventListenerService=(i=(n=this.beans.frameworkOverrides).createLocalEventListenerWrapper)==null?void 0:i.call(n,this.frameworkEventListenerService,this.colEventSvc);const r=((o=this.frameworkEventListenerService)==null?void 0:o.wrap(t))??t;this.colEventSvc.addEventListener(e,r)}removeEventListener(e,t){var n;const r=((n=this.frameworkEventListenerService)==null?void 0:n.unwrap(t))??t;this.colEventSvc.removeEventListener(e,r)}createColumnFunctionCallbackParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,column:this,colDef:this.colDef})}isSuppressNavigable(e){var t;return((t=this.beans.cellNavigation)==null?void 0:t.isSuppressNavigable(this,e))??!1}isCellEditable(e){var t;return((t=this.beans.editSvc)==null?void 0:t.isCellEditable(this,e))??!1}isSuppressFillHandle(){return!!this.colDef.suppressFillHandle}isAutoHeight(){return!!this.colDef.autoHeight}isAutoHeaderHeight(){return!!this.colDef.autoHeaderHeight}isRowDrag(e){return this.isColumnFunc(e,this.colDef.rowDrag)}isDndSource(e){return this.isColumnFunc(e,this.colDef.dndSource)}isCellCheckboxSelection(e){var t;return((t=this.beans.selectionSvc)==null?void 0:t.isCellCheckboxSelection(this,e))??!1}isSuppressPaste(e){var t;return this.isColumnFunc(e,((t=this.colDef)==null?void 0:t.suppressPaste)??null)}isResizable(){return!!this.getColDefValue("resizable")}getColDefValue(e){return this.colDef[e]??c9e[e]}isColumnFunc(e,t){if(typeof t=="boolean")return t;if(typeof t=="function"){const r=this.createColumnFunctionCallbackParams(e);return t(r)}return!1}createColumnEvent(e,t){return this.gos.addGridCommonParams({type:e,column:this,columns:[this],source:t})}isMoving(){return this.moving}getSort(){return this.sort}isSortable(){return!!this.getColDefValue("sortable")}isSortAscending(){return this.sort==="asc"}isSortDescending(){return this.sort==="desc"}isSortNone(){return Kr(this.sort)}isSorting(){return Qe(this.sort)}getSortIndex(){return this.sortIndex}isMenuVisible(){return this.menuVisible}getAggFunc(){return this.aggFunc}getLeft(){return this.left}getOldLeft(){return this.oldLeft}getRight(){return this.left+this.actualWidth}setLeft(e,t){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchColEvent("leftChanged",t))}isFilterActive(){return this.filterActive}isHovered(){var e;return we(261),!!((e=this.beans.colHover)!=null&&e.isHovered(this))}setFirstRightPinned(e,t){this.firstRightPinned!==e&&(this.firstRightPinned=e,this.dispatchColEvent("firstRightPinnedChanged",t))}setLastLeftPinned(e,t){this.lastLeftPinned!==e&&(this.lastLeftPinned=e,this.dispatchColEvent("lastLeftPinnedChanged",t))}isFirstRightPinned(){return this.firstRightPinned}isLastLeftPinned(){return this.lastLeftPinned}isPinned(){return this.pinned==="left"||this.pinned==="right"}isPinnedLeft(){return this.pinned==="left"}isPinnedRight(){return this.pinned==="right"}getPinned(){return this.pinned}setVisible(e,t){const r=e===!0;this.visible!==r&&(this.visible=r,this.dispatchColEvent("visibleChanged",t)),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}isSpanHeaderHeight(){return!this.getColDef().suppressSpanHeaderHeight}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e||!e.isPadding())return{numberOfParents:0,isSpanningTotal:!1};const t=e.getPaddingLevel()+1;let r=!0;for(;e;){if(!e.isPadding()){r=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:r}}getColDef(){return this.colDef}getDefinition(){return this.colDef}getColumnGroupShow(){return this.colDef.columnGroupShow}getColId(){return this.colId}getId(){return this.colId}getUniqueId(){return this.colId}getActualWidth(){return this.actualWidth}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(Kr(this.colDef.colSpan))return 1;const t=this.createBaseColDefParams(e),r=this.colDef.colSpan(t);return Math.max(r,1)}getRowSpan(e){if(Kr(this.colDef.rowSpan))return 1;const t=this.createBaseColDefParams(e),r=this.colDef.rowSpan(t);return Math.max(r,1)}setActualWidth(e,t,r=!1){e=Math.max(e,this.minWidth),e=Math.min(e,this.maxWidth),this.actualWidth!==e&&(this.actualWidth=e,this.flex&&t!=="flex"&&t!=="gridInitializing"&&(this.flex=null),r||this.fireColumnWidthChangedEvent(t)),this.dispatchStateUpdatedEvent("width")}fireColumnWidthChangedEvent(e){this.dispatchColEvent("widthChanged",e)}isGreaterThanMax(e){return e>this.maxWidth}getMinWidth(){return this.minWidth}getMaxWidth(){return this.maxWidth}getFlex(){return this.flex}isRowGroupActive(){return this.rowGroupActive}isPivotActive(){return this.pivotActive}isAnyFunctionActive(){return this.isPivotActive()||this.isRowGroupActive()||this.isValueActive()}isAnyFunctionAllowed(){return this.isAllowPivot()||this.isAllowRowGroup()||this.isAllowValue()}isValueActive(){return this.aggregationActive}isAllowPivot(){return this.colDef.enablePivot===!0}isAllowValue(){return this.colDef.enableValue===!0}isAllowRowGroup(){return this.colDef.enableRowGroup===!0}dispatchColEvent(e,t,r){const n=this.createColumnEvent(e,t);r&&Ii(n,r),this.colEventSvc.dispatchEvent(n)}dispatchStateUpdatedEvent(e){this.colEventSvc.dispatchEvent({type:"columnStateUpdated",key:e})}};function Qn(e){return e instanceof zw}var zw=class extends xe{constructor(e,t,r,n){super(),this.colGroupDef=e,this.groupId=t,this.padding=r,this.level=n,this.isColumn=!1,this.expandable=!1,this.instanceId=Vpe(),this.expandableListenerRemoveCallback=null,this.expanded=!!(e!=null&&e.openByDefault)}destroy(){this.expandableListenerRemoveCallback&&this.reset(null,void 0),super.destroy()}reset(e,t){this.colGroupDef=e,this.level=t,this.originalParent=null,this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback(),this.children=void 0,this.expandable=void 0}getInstanceId(){return this.instanceId}getOriginalParent(){return this.originalParent}getLevel(){return this.level}isVisible(){return this.children?this.children.some(e=>e.isVisible()):!1}isPadding(){return this.padding}setExpanded(e){this.expanded=e===void 0?!1:e,this.dispatchLocalEvent({type:"expandedChanged"})}isExpandable(){return this.expandable}isExpanded(){return this.expanded}getGroupId(){return this.groupId}getId(){return this.getGroupId()}setChildren(e){this.children=e}getChildren(){return this.children}getColGroupDef(){return this.colGroupDef}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}addLeafColumns(e){this.children&&this.children.forEach(t=>{yu(t)?e.push(t):Qn(t)&&t.addLeafColumns(e)})}getColumnGroupShow(){const e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();const e=this.onColumnVisibilityChanged.bind(this);this.getLeafColumns().forEach(t=>t.addEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=()=>{this.getLeafColumns().forEach(t=>t.removeEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let e=!1,t=!1,r=!1;const n=this.findChildrenRemovingPadding();for(let o=0,s=n.length;o{r.forEach(n=>{Qn(n)&&n.isPadding()?t(n.children):e.push(n)})};return t(this.children),e}onColumnVisibilityChanged(){this.setExpandable()}},d9e={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}},h9e=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;tr?r(n,t[i]):t[i]===n)}function p9e(e){return e.sort((t,r)=>t-r)}function Po(e,t){const r=e.indexOf(t);r>=0&&e.splice(r,1)}function FY(e,t,r){for(let n=0;n=0;n--)e.splice(r,0,t[n])}function zpe(e,t){const r=[],n=[],i=[];return e.forEach(s=>{const a=s.getColDef().lockPosition;a==="right"?i.push(s):a==="left"||a===!0?r.push(s):n.push(s)}),t.get("enableRtl")?[...i,...n,...r]:[...r,...n,...i]}function Hpe(e,t){let r=!0;return wd(null,t,n=>{if(!Qn(n))return;const i=n,o=i.getColGroupDef();if(!(o&&o.marryChildren))return;const a=[];i.getLeafColumns().forEach(h=>{const p=e.indexOf(h);a.push(p)});const l=Math.max.apply(Math,a),c=Math.min.apply(Math,a),u=l-c,d=i.getLeafColumns().length-1;u>d&&(r=!1)}),r}function Wpe(e,t){if(!e||e.length==0)return;const r=t(e[0]);for(let n=1;no.getPinned());e.dispatchEvent({type:"columnPinned",pinned:i??null,columns:t,column:n,source:r})}function f9e(e,t,r){if(!t.length)return;const n=t.length===1?t[0]:null,i=Wpe(t,o=>o.isVisible());e.dispatchEvent({type:"columnVisible",visible:i,columns:t,column:n,source:r})}function jpe(e,t,r,n){e.dispatchEvent({type:t,columns:r,column:r&&r.length==1?r[0]:null,source:n})}function tC(e,t,r,n,i=null){t!=null&&t.length&&e.dispatchEvent({type:"columnResized",columns:t,column:t.length===1?t[0]:null,flexColumns:i,finished:r,source:n})}function sa(e,t,r){var x;const{colModel:n,rowGroupColsSvc:i,pivotColsSvc:o,autoColSvc:s,selectionColSvc:a,colAnimation:l,visibleCols:c,pivotResultCols:u,environment:d,valueColsSvc:h,eventSvc:p,gos:f}=e,g=n.getColDefCols()||[];if(!(g!=null&&g.length))return!1;if(t!=null&&t.state&&!t.state.forEach)return we(32),!1;const m=(E,R,T,M,D)=>{if(!E)return;const A=C9e(R,t.defaultState),I=A("flex").value1;if(nfe(e,E,A("hide").value1,A("sort").value1,A("sortIndex").value1,A("pinned").value1,I,r),I==null){const L=A("width").value1;if(L!=null){const F=E.getColDef().minWidth??d.getDefaultColumnMinWidth();F!=null&&L>=F&&E.setActualWidth(L,r)}}D||!E.isPrimary()||(h==null||h.syncColumnWithState(E,r,A),i==null||i.syncColumnWithState(E,r,A,T),o==null||o.syncColumnWithState(E,r,A,M))},v=(E,R,T)=>{var W,V;const M=qpe(e,r),D=R.slice(),A={},I={},L=[],F=[],k=[];let O=0;const B=(i==null?void 0:i.columns.slice())??[],H=(o==null?void 0:o.columns.slice())??[];E.forEach($=>{const K=$.colId;if(K.startsWith(Fp)){L.push($),k.push($);return}if(lu(K)){F.push($),k.push($);return}const X=T(K);X?(m(X,$,A,I,!1),Po(D,X)):(k.push($),O+=1)});const N=$=>m($,null,A,I,!1);D.forEach(N),i==null||i.sortColumns(LY.bind(i,A,B)),o==null||o.sortColumns(LY.bind(o,I,H)),n.refreshCols(!1);const z=($,K,q=[])=>{K.forEach(X=>{const Y=$(X.colId);Po(q,Y),m(Y,X,null,null,!0)}),q.forEach(N)};return z($=>(s==null?void 0:s.getAutoCol($))??null,L,(W=s==null?void 0:s.getAutoCols())==null?void 0:W.slice()),z($=>(a==null?void 0:a.getSelectionCol($))??null,F,(V=a==null?void 0:a.getSelectionCols())==null?void 0:V.slice()),g9e(t,n,f),c.refresh(r),p.dispatchEvent({type:"columnEverythingChanged",source:r}),M(),{unmatchedAndAutoStates:k,unmatchedCount:O}};l==null||l.start();let{unmatchedAndAutoStates:b,unmatchedCount:S}=v(t.state||[],g,E=>n.getColDefCol(E));if(b.length>0||Qe(t.defaultState)){const E=((x=u==null?void 0:u.getPivotResultCols())==null?void 0:x.list)??[];S=v(b,E,R=>(u==null?void 0:u.getPivotResultCol(R))??null).unmatchedCount}return l==null||l.finish(),S===0}function Kpe(e,t){const{colModel:r,autoColSvc:n}=e,i=r.getColDefCols();if(!(i!=null&&i.length))return;const o=r.getColDefColTree(),s=u5(o),a=[];let l=1e3,c=1e3,u=[];const d=n==null?void 0:n.getAutoCols();d&&(u=u.concat(d)),s&&(u=u.concat(s)),u.forEach(h=>{const p=Xpe(h);Kr(p.rowGroupIndex)&&p.rowGroup&&(p.rowGroupIndex=l++),Kr(p.pivotIndex)&&p.pivot&&(p.pivotIndex=c++),a.push(p)}),sa(e,{state:a,applyOrder:!0},t)}function qpe(e,t){const{rowGroupColsSvc:r,pivotColsSvc:n,valueColsSvc:i,colModel:o,sortSvc:s,eventSvc:a}=e,l={rowGroupColumns:(r==null?void 0:r.columns.slice())??[],pivotColumns:(n==null?void 0:n.columns.slice())??[],valueColumns:(i==null?void 0:i.columns.slice())??[]},c=O0(e),u={};return c.forEach(d=>{u[d.colId]=d}),()=>{const d=o.getAllCols(),h=(T,M,D,A)=>{const I=M.map(A),L=D.map(A);if(ko(I,L))return;const k=new Set(M);D.forEach(B=>{k.delete(B)||k.add(B)});const O=[...k];a.dispatchEvent({type:T,columns:O,column:O.length===1?O[0]:null,source:t})},p=T=>{const M=[];return d.forEach(D=>{const A=u[D.getColId()];A&&T(A,D)&&M.push(D)}),M},f=T=>T.getColId();h("columnRowGroupChanged",l.rowGroupColumns,(r==null?void 0:r.columns)??[],f),h("columnPivotChanged",l.pivotColumns,(n==null?void 0:n.columns)??[],f);const m=p((T,M)=>{const D=T.aggFunc!=null,A=D!=M.isValueActive(),I=D&&T.aggFunc!=M.getAggFunc();return A||I});m.length>0&&jpe(a,"columnValueChanged",m,t),tC(a,p((T,M)=>T.width!=M.getActualWidth()),!0,t),Upe(a,p((T,M)=>T.pinned!=M.getPinned()),t),f9e(a,p((T,M)=>T.hide==M.isVisible()),t);const E=p((T,M)=>T.sort!=M.getSort()||T.sortIndex!=M.getSortIndex());E.length>0&&(s==null||s.dispatchSortChangedEvents(t,E));const R=O0(e);v9e(c,R,t,o,a)}}function O0(e){const{colModel:t,rowGroupColsSvc:r,pivotColsSvc:n}=e,i=t.getColDefCols();if(Kr(i)||!t.isAlive())return[];const o=t.getAllCols(),s=r==null?void 0:r.columns,a=n==null?void 0:n.columns,l=d=>{const h=d.isRowGroupActive()&&s?s.indexOf(d):null,p=d.isPivotActive()&&a?a.indexOf(d):null,f=d.isValueActive()?d.getAggFunc():null,g=d.getSort()!=null?d.getSort():null,m=d.getSortIndex()!=null?d.getSortIndex():null;return{colId:d.getColId(),width:d.getActualWidth(),hide:!d.isVisible(),pinned:d.getPinned(),sort:g,sortIndex:m,aggFunc:f,rowGroup:d.isRowGroupActive(),rowGroupIndex:h,pivot:d.isPivotActive(),pivotIndex:p,flex:d.getFlex()??null}},c=o.map(d=>l(d)),u=new Map(t.getCols().map((d,h)=>[d.getColId(),h]));return c.sort((d,h)=>{const p=u.has(d.colId)?u.get(d.colId):-1,f=u.has(h.colId)?u.get(h.colId):-1;return p-f}),c}function Xpe(e){const t=(f,g)=>f??g??null,r=e.getColDef(),n=t(r.sort,r.initialSort),i=t(r.sortIndex,r.initialSortIndex),o=t(r.hide,r.initialHide),s=t(r.pinned,r.initialPinned),a=t(r.width,r.initialWidth),l=t(r.flex,r.initialFlex);let c=t(r.rowGroupIndex,r.initialRowGroupIndex),u=t(r.rowGroup,r.initialRowGroup);c==null&&(u==null||u==!1)&&(c=null,u=null);let d=t(r.pivotIndex,r.initialPivotIndex),h=t(r.pivot,r.initialPivot);d==null&&(h==null||h==!1)&&(d=null,h=null);const p=t(r.aggFunc,r.initialAggFunc);return{colId:e.getColId(),sort:n,sortIndex:i,hide:o,pinned:s,width:a,flex:l,rowGroup:u,rowGroupIndex:c,pivot:h,pivotIndex:d,aggFunc:p}}function g9e(e,t,r){if(!e.applyOrder||!e.state)return;const n=[];e.state.forEach(i=>{i.colId!=null&&n.push(i.colId)}),m9e(t.cols,n,t,r)}function m9e(e,t,r,n){if(e==null)return;let i=[];const o={};t.forEach(a=>{if(o[a])return;const l=e.map[a];l&&(i.push(l),o[a]=!0)});let s=0;if(e.list.forEach(a=>{const l=a.getColId();if(o[l]!=null)return;l.startsWith(Fp)?i.splice(s++,0,a):i.push(a)}),i=zpe(i,n),!Hpe(i,r.getColTree())){we(39);return}e.list=i}function v9e(e,t,r,n,i){const o={};t.forEach(u=>o[u.colId]=u);const s={};e.forEach(u=>{o[u.colId]&&(s[u.colId]=!0)});const a=e.filter(u=>s[u.colId]),l=t.filter(u=>s[u.colId]),c=[];l.forEach((u,d)=>{const h=a&&a[d];if(h&&h.colId!==u.colId){const p=n.getCol(h.colId);p&&c.push(p)}}),c.length&&i.dispatchEvent({type:"columnMoved",columns:c,column:c.length===1?c[0]:null,finished:!0,source:r})}var LY=(e,t,r,n)=>{const i=e[r.getId()],o=e[n.getId()],s=i!=null,a=o!=null;if(s&&a)return i-o;if(s)return-1;if(a)return 1;const l=t.indexOf(r),c=t.indexOf(n),u=l>=0,d=c>=0;return u&&d?l-c:u?-1:1},Ype="ag-Grid-SelectionColumn",y9e=class extends xe{constructor(){super(...arguments),this.beanName="selectionColSvc"}postConstruct(){this.addManagedPropertyListener("rowSelection",e=>{this.onSelectionOptionsChanged(e.currentValue,e.previousValue,Gg(e.source))})}addSelectionCols(e){const t=this.selectionCols;t!=null&&(e.list=t.list.concat(e.list),e.tree=t.tree.concat(e.tree),efe(e))}createSelectionCols(e,t){var h,p;const r=()=>{var f;Lp(this.beans,(f=this.selectionCols)==null?void 0:f.tree),this.selectionCols=null},n=e.treeDepth,o=(((h=this.selectionCols)==null?void 0:h.treeDepth)??-1)==n,s=this.generateSelectionCols();if(Jpe(s,((p=this.selectionCols)==null?void 0:p.list)??[])&&o)return;r();const{colGroupSvc:l}=this.beans,c=(l==null?void 0:l.findDepth(e.tree))??0,u=(l==null?void 0:l.balanceTreeForAutoCols(s,c))??[];this.selectionCols={list:s,tree:u,treeDepth:c,map:{}},t(f=>{if(!f)return null;const g=f.filter(m=>!lu(m));return[...s,...g]})}isSelectionColumnEnabled(){var s,a;const{gos:e,beans:t}=this,r=e.get("rowSelection");if(typeof r!="object"||!Fa(e))return!1;const n=(((a=(s=t.autoColSvc)==null?void 0:s.getAutoCols())==null?void 0:a.length)??0)>0;if(r.checkboxLocation==="autoGroupColumn"&&n)return!1;const i=!!$g(r),o=xP(r);return i||o}generateSelectionCols(){if(!this.isSelectionColumnEnabled())return[];const{gos:e,validation:t}=this.beans,r=e.get("selectionColumnDef"),i={width:50,resizable:!1,suppressHeaderMenuButton:!0,sortable:!1,suppressMovable:!0,lockPosition:e.get("enableRtl")?"right":"left",comparator(a,l,c,u){const d=c.isSelected(),h=u.isSelected();return d===h?0:d?1:-1},editable:!1,suppressFillHandle:!0,...r,colId:Ype},o=i.colId;t==null||t.validateColDef(i,o,!0);const s=new PA(i,null,o,!1);return this.createBean(s),[s]}putSelectionColsFirstInList(e,t){if(!t)return null;const r=t.filter(n=>!lu(n));return[...e,...r]}getSelectionCol(e){var t;return((t=this.selectionCols)==null?void 0:t.list.find(r=>d5(r,e)))??null}getSelectionCols(){var e;return((e=this.selectionCols)==null?void 0:e.list)??null}onSelectionOptionsChanged(e,t,r){const n=t&&typeof t!="string"?$g(t):void 0,i=e&&typeof e!="string"?$g(e):void 0,o=n!==i,s=t&&typeof t!="string"?xP(t):void 0,a=e&&typeof e!="string"?xP(e):void 0,l=s!==a,c=XM(e),u=XM(t);(o||l||c!==u)&&this.beans.colModel.refreshAll(r)}destroy(){var e;Lp(this.beans,(e=this.selectionCols)==null?void 0:e.tree),super.destroy()}refreshVisibility(e){if(!this.isSelectionColumnEnabled())return;const t=this.beans,r=t.visibleCols.getAllTrees()??[];if(r.length!==0){if(!r.some(Zpe)){const n=O0(t).find(i=>lu(i.colId));n&&sa(t,{state:[{colId:n.colId,hide:!n.hide}]},e)}if(r.length===1){const n=r[0],i=Qpe(n);if(!i)return;sa(t,{state:[{colId:i.getColId(),hide:!0}]},e)}}}},Zpe=e=>{var t;return e.isColumn?lu(e):((t=e.getChildren())==null?void 0:t.some(Zpe))??!1};function Qpe(e){if(e.isColumn)return lu(e)?e:null;const t=e.getChildren()??[];for(const r of t){const n=Qpe(r);if(n)return n}return null}var Fp="ag-Grid-AutoColumn";function u5(e){const t=[],r=n=>{for(let i=0;it+r.getActualWidth(),0)}function Lp(e,t,r){const n={};if(!t)return;wd(null,t,o=>{n[o.getInstanceId()]=o}),r&&wd(null,r,o=>{n[o.getInstanceId()]=null});const i=Object.values(n).filter(o=>o!=null);e.context.destroyBeans(i)}function MA(e){return e.getId().startsWith(Fp)}function lu(e){const t=typeof e=="string"?e:"getColId"in e?e.getColId():e.colId;return(t==null?void 0:t.startsWith(Ype))??!1}function ZM(e){let t=[];return e instanceof Array?t=e:typeof e=="string"&&(t=e.split(",")),t}function Jpe(e,t){return ko(e,t,(r,n)=>r.getColId()===n.getColId())}function efe(e){e.map={},e.list.forEach(t=>e.map[t.getId()]=t)}function Gg(e){return e==="gridOptionsUpdated"?"gridOptionsChanged":e}function d5(e,t){const r=e===t,n=e.getColDef()===t,i=e.getColId()==t;return r||n||i}var C9e=(e,t)=>(r,n)=>{const i={value1:void 0,value2:void 0};let o=!1;return e&&(e[r]!==void 0&&(i.value1=e[r],o=!0),Qe(n)&&e[n]!==void 0&&(i.value2=e[n],o=!0)),!o&&t&&(t[r]!==void 0&&(i.value1=t[r]),Qe(n)&&t[n]!==void 0&&(i.value2=t[n])),i};function tfe(e,t=null,r,n,i){const o=new h9e,{existingCols:s,existingGroups:a,existingColKeys:l}=b9e(n);o.addExistingKeys(l);const c=rfe(e,t,0,r,s,o,a,i),{colGroupSvc:u}=e,d=(u==null?void 0:u.findMaxDepth(c,0))??0,h=u?u.balanceColumnTree(c,0,d,o):c;return wd(null,h,(f,g)=>{Qn(f)&&f.setupExpandable(),f.originalParent=g}),{columnTree:h,treeDept:d}}function b9e(e){const t=[],r=[],n=[];return e&&wd(null,e,i=>{if(Qn(i)){const o=i;r.push(o)}else{const o=i;n.push(o.getId()),t.push(o)}}),{existingCols:t,existingGroups:r,existingColKeys:n}}function rfe(e,t,r,n,i,o,s,a){if(!t)return[];const{colGroupSvc:l}=e,c=new Array(t.length);for(let u=0;u0))if(r.width!=null)t.setActualWidth(r.width,n);else{const o=t.getActualWidth();t.setActualWidth(o,n)}}function w9e(e,t){if(t)for(let r=0;r{const s=n[o.trim()];s?Ii(r,s,!1,!0):we(36,{t:o})})}function T9e(e){return e.children!==void 0}function wd(e,t,r){if(t)for(let n=0;nthis.refreshAll(Gg(e.source))),this.addManagedPropertyListeners(["defaultColDef","defaultColGroupDef","columnTypes","suppressFieldDotNotation"],e=>this.recreateColumnDefs(Gg(e.source))),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),Gg(e.source)))}createColsFromColDefs(e){var b,S,x;const{beans:t}=this,{valueCache:r,colAutosize:n,rowGroupColsSvc:i,pivotColsSvc:o,valueColsSvc:s,visibleCols:a,colViewport:l,eventSvc:c}=t,u=this.colDefs?qpe(t,e):void 0;r==null||r.expire();const d=(b=this.colDefCols)==null?void 0:b.list,h=(S=this.colDefCols)==null?void 0:S.tree,p=tfe(t,this.colDefs,!0,h,e);Lp(t,(x=this.colDefCols)==null?void 0:x.tree,p.columnTree);const f=p.columnTree,g=p.treeDept,m=u5(f),v={};m.forEach(E=>v[E.getId()]=E),this.colDefCols={tree:f,treeDepth:g,list:m,map:v},i==null||i.extractCols(e,d),o==null||o.extractCols(e,d),s==null||s.extractCols(e,d),this.ready=!0,this.refreshCols(!0),a.refresh(e),l.checkViewportColumns(),c.dispatchEvent({type:"columnEverythingChanged",source:e}),u&&(this.changeEventsDispatching=!0,u(),this.changeEventsDispatching=!1),c.dispatchEvent({type:"newColumnsLoaded",source:e}),e==="gridInitializing"&&(n==null||n.applyAutosizeStrategy())}refreshCols(e){var f;if(!this.colDefCols)return;const t=(f=this.cols)==null?void 0:f.tree;this.saveColOrder();const{autoColSvc:r,selectionColSvc:n,quickFilter:i,pivotResultCols:o,showRowGroupCols:s,rowAutoHeight:a,visibleCols:l,colViewport:c,eventSvc:u}=this.beans,d=this.selectCols(o,this.colDefCols);r==null||r.createAutoCols(d,g=>{this.lastOrder=g(this.lastOrder),this.lastPivotOrder=g(this.lastPivotOrder)}),r==null||r.addAutoCols(d),n==null||n.createSelectionCols(d,g=>{this.lastOrder=g(this.lastOrder)??null,this.lastPivotOrder=g(this.lastPivotOrder)??null}),n==null||n.addSelectionCols(d);const h=K7e(this.gos,this.showingPivotResult);(!e||h)&&this.restoreColOrder(d),this.positionLockedCols(d),s==null||s.refresh(),i==null||i.refreshCols(),this.setColSpanActive(),a==null||a.setAutoHeightActive(d),l.clear(),c.clear(),!ko(t,this.cols.tree)&&u.dispatchEvent({type:"gridColumnsChanged"})}selectCols(e,t){const r=(e==null?void 0:e.getPivotResultCols())??null;this.showingPivotResult=r!=null;const{map:n,list:i,tree:o,treeDepth:s}=r??t;return this.cols={list:i.slice(),map:{...n},tree:o.slice(),treeDepth:s},r&&(r.list.some(l=>{var c;return((c=this.cols)==null?void 0:c.map[l.getColId()])!==void 0})||(this.lastPivotOrder=null)),this.cols}getColsToShow(){var n;if(!this.cols)return[];const e=this.isPivotMode()&&!this.showingPivotResult,t=(n=this.beans.valueColsSvc)==null?void 0:n.columns;return this.cols.list.filter(i=>{const o=MA(i);if(e){const s=t==null?void 0:t.includes(i);return o||s}else return o||i.isVisible()})}refreshAll(e){this.ready&&(this.refreshCols(!1),this.beans.visibleCols.refresh(e))}setColsVisible(e,t=!1,r){sa(this.beans,{state:e.map(n=>({colId:typeof n=="string"?n:n.getColId(),hide:!t}))},r)}restoreColOrder(e){const t=this.showingPivotResult?this.lastPivotOrder:this.lastOrder;if(!t)return;const r=new Map(t.map((c,u)=>[c,u]));if(!e.list.some(c=>r.has(c)))return;const i=new Map(e.list.map(c=>[c,!0])),o=t.filter(c=>i.has(c)),s=new Map(o.map(c=>[c,!0])),a=e.list.filter(c=>!s.has(c)),l=o.slice();a.forEach(c=>{let u=c.getOriginalParent();if(!u){l.push(c);return}const d=[];for(;!d.length&&u;)u.getLeafColumns().forEach(g=>{const m=l.indexOf(g)>=0,v=d.indexOf(g)<0;m&&v&&d.push(g)}),u=u.getOriginalParent();if(!d.length){l.push(c);return}const h=d.map(f=>l.indexOf(f)),p=Math.max(...h);l.splice(p+1,0,c)}),e.list=l}positionLockedCols(e){e.list=zpe(e.list,this.gos)}saveColOrder(){var e,t;this.showingPivotResult?this.lastPivotOrder=((e=this.cols)==null?void 0:e.list)??null:this.lastOrder=((t=this.cols)==null?void 0:t.list)??null}getColumnDefs(){var e,t;return this.colDefCols?(t=this.beans.colDefFactory)==null?void 0:t.getColumnDefs(this.colDefCols.list,this.showingPivotResult,this.lastOrder,((e=this.cols)==null?void 0:e.list)??[]):void 0}setColSpanActive(){var e;this.colSpanActive=!!((e=this.cols)!=null&&e.list.some(t=>t.getColDef().colSpan!=null))}isPivotMode(){return this.pivotMode}setPivotMode(e,t){if(e===this.pivotMode||(this.pivotMode=e,!this.ready))return;this.refreshCols(!1);const{visibleCols:r,eventSvc:n}=this.beans;r.refresh(t),n.dispatchEvent({type:"columnPivotModeChanged"})}isPivotActive(){var t;const e=(t=this.beans.pivotColsSvc)==null?void 0:t.columns;return this.pivotMode&&!!(e!=null&&e.length)}recreateColumnDefs(e){var t;this.cols&&((t=this.beans.autoColSvc)==null||t.updateAutoCols(e),this.createColsFromColDefs(e))}setColumnDefs(e,t){this.colDefs=e,this.createColsFromColDefs(t)}destroy(){var e;Lp(this.beans,(e=this.colDefCols)==null?void 0:e.tree),super.destroy()}getColTree(){var e;return((e=this.cols)==null?void 0:e.tree)??[]}getColDefColTree(){var e;return((e=this.colDefCols)==null?void 0:e.tree)??[]}getColDefCols(){var e;return((e=this.colDefCols)==null?void 0:e.list)??null}getCols(){var e;return((e=this.cols)==null?void 0:e.list)??[]}getAllCols(){var i,o,s,a;const{pivotResultCols:e,autoColSvc:t,selectionColSvc:r}=this.beans,n=(i=e==null?void 0:e.getPivotResultCols())==null?void 0:i.list;return[((o=this.colDefCols)==null?void 0:o.list)??[],((s=t==null?void 0:t.autoCols)==null?void 0:s.list)??[],((a=r==null?void 0:r.selectionCols)==null?void 0:a.list)??[],n??[]].flat()}getColsForKeys(e){return e?e.map(t=>this.getCol(t)).filter(t=>t!=null):[]}getColDefCol(e){var t;return(t=this.colDefCols)!=null&&t.list?this.getColFromCollection(e,this.colDefCols):null}getCol(e){return e==null?null:this.getColFromCollection(e,this.cols)}getColFromCollection(e,t){var i;if(t==null)return null;const{map:r,list:n}=t;if(typeof e=="string"&&r[e])return r[e];for(let o=0;ol.set(u,d)),t.length=0,Qe(e)&&e.forEach(u=>{const d=this.colModel.getColDefCol(u);d&&t.push(d)}),t.forEach((u,d)=>{const h=l.get(u);if(h===void 0){l.set(u,0);return}n&&h!==d||l.delete(u)}),(this.colModel.getColDefCols()||[]).forEach(u=>{const d=t.indexOf(u)>=0;o(u,d,s)}),i&&this.colModel.refreshCols(!1),this.visibleCols.refresh(s),this.dispatchColumnChangedEvent(this.eventSvc,r,[...l.keys()],s)}updateColList(e=[],t,r,n,i,o,s){if(!e||e.length===0)return;let a=!1;const l=new Set;if(e.forEach(u=>{if(!u)return;const d=this.colModel.getColDefCol(u);if(d){if(l.add(d),r){if(t.indexOf(d)>=0)return;t.push(d)}else{const h=t.indexOf(d);if(h<0)return;for(let p=h+1;p{const f=t.indexOf(p)<0,g=p.getColDef(),m=l(g),v=c(g),b=s(g),S=a(g);let x;m!==void 0?x=m:b!==void 0?b===null?x=!1:x=b>=0:f?v!==void 0?x=v:S!==void 0?x=S!=null&&S>=0:x=!1:x=r.indexOf(p)>=0,x&&((f?b!=null||S!=null:b!=null)?n.push(p):i.push(p))});const d=p=>{const f=s(p.getColDef()),g=a(p.getColDef());return f??g};n.sort((p,f)=>{const g=d(p),m=d(f);return g===m?0:g{i.indexOf(p)>=0&&h.push(p)}),i.forEach(p=>{h.indexOf(p)<0&&h.push(p)}),r.forEach(p=>{h.indexOf(p)<0&&o(p,!1,e)}),h.forEach(p=>{r.indexOf(p)<0&&o(p,!0,e)}),this.columns=h}restoreColumnOrder(e,t){const r=this.columns,n=this.colModel.getColDefCols();if(!r.length||!n)return e;const i=Object.keys(t),o=new Set(i),s=new Set(i),a=new Set(r.map(S=>{const x=S.getColId();return s.delete(x),x}).concat(i)),l=[],c={};let u=0;for(let S=0;S{const x=c[S];for(let E=p;E{const x=S.getColId();if(o.has(x))b(x),t[x][m]=d++;else{const E=S.getColDef();(E[m]===null||E[m]===void 0&&E[v]==null)&&(h||(E[f]||E[f]===void 0&&E[g]?b(x):(s.forEach(M=>{t[M][m]=d+c[M]}),d+=l.length,h=!0)),e[x]||(e[x]={colId:x}),e[x][m]=d++)}}),e}},ofe=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){const t=this.existingIds[e];let r;return typeof t!="number"?r=0:r=t+1,this.existingIds[e]=r,r}},HC=class extends xe{};function a1(e,t,r){return r&&e.addDestroyFunc(()=>t.destroyBean(r)),r??e}var l1=class{constructor(e){this.cssClassStates={},this.getGui=e}addCssClass(e){this.addOrRemoveCssClass(e,!0)}removeCssClass(e){this.addOrRemoveCssClass(e,!1)}containsCssClass(e){const t=this.getGui();return t?t.classList.contains(e):!1}addOrRemoveCssClass(e,t){if(!e)return;if(e.indexOf(" ")>=0){const n=(e||"").split(" ");if(n.length>1){n.forEach(i=>this.addOrRemoveCssClass(i,t));return}}if(this.cssClassStates[e]!==t&&e.length){const n=this.getGui();n&&n.classList.toggle(e,t),this.cssClassStates[e]=t}}},P9e=0,Ce=null,Je=class extends xe{constructor(e,t){super(),this.suppressDataRefValidation=!1,this.displayed=!0,this.visible=!0,this.compId=P9e++,this.cssClassManager=new l1(()=>this.eGui),this.componentSelectors=new Map((t??[]).map(r=>[r.selector,r])),e&&this.setTemplate(e)}preConstruct(){var t,r,n;this.wireTemplate(this.getGui());const e="component-"+((r=(t=Object.getPrototypeOf(this))==null?void 0:t.constructor)==null?void 0:r.name);(n=this.css)==null||n.forEach(i=>this.beans.environment.addGlobalCSS(i,e))}wireTemplate(e,t){e&&this.gos&&(this.applyElementsToComponent(e),this.createChildComponentsFromTags(e,t))}getCompId(){return this.compId}getDataRefAttribute(e){return e.getAttribute?e.getAttribute("data-ref"):null}applyElementsToComponent(e,t,r,n=null){if(t===void 0&&(t=this.getDataRefAttribute(e)),t){const i=this[t];if(i===Ce)this[t]=n??e;else{const o=r&&r[t];if(!this.suppressDataRefValidation&&!o)throw new Error(`data-ref: ${t} on ${this.constructor.name} with ${i}`)}}}createChildComponentsFromTags(e,t){$7e(e.childNodes).forEach(n=>{if(!(n instanceof HTMLElement))return;const i=this.createComponentFromElement(n,o=>{o.getGui()&&this.copyAttributesFromNode(n,o.getGui())},t);if(i){if(i.addItems&&n.children.length){this.createChildComponentsFromTags(n,t);const o=Array.prototype.slice.call(n.children);i.addItems(o)}this.swapComponentForNode(i,e,n)}else n.childNodes&&this.createChildComponentsFromTags(n,t)})}createComponentFromElement(e,t,r){const n=e.nodeName,i=this.getDataRefAttribute(e),o=n.indexOf("AG-")===0,s=o?this.componentSelectors.get(n):null;let a=null;if(s){const l=r&&i?r[i]:void 0;a=new s.component(l),a.setParentComponent(this),this.createBean(a,null,t)}else if(o)throw new Error(`selector: ${n}`);return this.applyElementsToComponent(e,i,r,a),a}copyAttributesFromNode(e,t){G7e(e.attributes,(r,n)=>t.setAttribute(r,n))}swapComponentForNode(e,t,r){const n=e.getGui();t.replaceChild(n,r),t.insertBefore(document.createComment(r.nodeName),n),this.addDestroyFunc(this.destroyBean.bind(this,e))}activateTabIndex(e){const t=this.gos.get("tabIndex");e||(e=[]),e.length||e.push(this.getGui()),e.forEach(r=>r.setAttribute("tabindex",t.toString()))}setTemplate(e,t,r){const n=Ts(e);this.setTemplateFromElement(n,t,r)}setTemplateFromElement(e,t,r,n=!1){if(this.eGui=e,this.suppressDataRefValidation=n,t)for(let i=0;ithis.eGui.removeEventListener(e,t))}addCssClass(e){this.cssClassManager.addCssClass(e)}removeCssClass(e){this.cssClassManager.removeCssClass(e)}containsCssClass(e){return this.cssClassManager.containsCssClass(e)}addOrRemoveCssClass(e,t){this.cssClassManager.addOrRemoveCssClass(e,t)}registerCSS(e){this.css||(this.css=[]),this.css.push(e)}};function M9e(e){return typeof e.then=="function"}var lr=class cw{constructor(t){this.status=0,this.resolution=null,this.waiters=[],t(r=>this.onDone(r),r=>this.onReject(r))}static all(t){return t.length?new cw(r=>{let n=t.length;const i=new Array(n);t.forEach((o,s)=>{o.then(a=>{i[s]=a,n--,n===0&&r(i)})})}):cw.resolve()}static resolve(t=null){return new cw(r=>r(t))}then(t){return new cw(r=>{this.status===1?r(t(this.resolution)):this.waiters.push(n=>r(t(n)))})}onDone(t){this.status=1,this.resolution=t,this.waiters.forEach(r=>r(t))}onReject(t){}};function I9e(e){return e?e.prototype&&"getGui"in e.prototype:!1}function sfe(e,t,r,n){const{name:i}=r;let o,s,a,l,c,u;if(t){const d=t,h=d[i+"Selector"],p=h?h(n):null,f=g=>{typeof g=="string"?o=g:g!=null&&g!==!0&&(e.isFrameworkComponent(g)?a=g:s=g)};p?(f(p.component),l=p.params,c=p.popup,u=p.popupPosition):f(d[i])}return{compName:o,jsComp:s,fwComp:a,paramsFromSelector:l,popupFromSelector:c,popupPositionFromSelector:u}}var D9e=class extends xe{constructor(){super(...arguments),this.beanName="userCompFactory"}wireBeans(e){this.agCompUtils=e.agCompUtils,this.registry=e.registry,this.frameworkCompWrapper=e.frameworkCompWrapper,this.gridOptions=e.gridOptions}getCompDetailsFromGridOptions(e,t,r,n=!1){return this.getCompDetails(this.gridOptions,e,t,r,n)}getCompDetails(e,t,r,n,i=!1){var b;const{name:o,cellRenderer:s}=t;let{compName:a,jsComp:l,fwComp:c,paramsFromSelector:u,popupFromSelector:d,popupPositionFromSelector:h}=sfe(this.beans.frameworkOverrides,e,t,n),p;const f=S=>{const x=this.registry.getUserComponent(o,S);x&&(l=x.componentFromFramework?void 0:x.component,c=x.componentFromFramework?x.component:void 0,p=x.params)};if(a!=null&&f(a),l==null&&c==null&&r!=null&&f(r),l&&s&&!I9e(l)&&(l=(b=this.agCompUtils)==null?void 0:b.adaptFunction(t,l)),!l&&!c){const{validation:S}=this.beans;i&&(a!==r||!r)?a?S!=null&&S.isProvidedUserComp(a)||yr(50,{compName:a}):r?S||yr(260,{...this.gos.getModuleErrorParams(),propName:o,compName:r}):yr(216,{name:o}):r&&!S&&yr(146,{comp:r});return}const g=this.mergeParams(e,t,n,u,p),m=l==null,v=l??c;return{componentFromFramework:m,componentClass:v,params:g,type:t,popupFromSelector:d,popupPositionFromSelector:h,newAgStackInstance:()=>this.newAgStackInstance(v,m,g,t)}}newAgStackInstance(e,t,r,n){var a;const i=!t;let o;i?o=new e:o=this.frameworkCompWrapper.wrap(e,n.mandatoryMethods,n.optionalMethods,n),this.createBean(o);const s=(a=o.init)==null?void 0:a.call(o,r);return s==null?lr.resolve(o):s.then(()=>o)}mergeParams(e,t,r,n=null,i){const o=this.gos.getGridCommonParams();Ii(o,r),i&&Ii(o,i);const s=e,a=s&&s[t.name+"Params"];if(typeof a=="function"){const l=a(r);Ii(o,l)}else typeof a=="object"&&Ii(o,a);return Ii(o,n),o}},A9e={name:"dateComponent",mandatoryMethods:["getDate","setDate"],optionalMethods:["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled","refresh"]},F9e={name:"dragAndDropImageComponent",mandatoryMethods:["setIcon","setLabel"]},L9e={name:"headerComponent",optionalMethods:["refresh"]},_9e={name:"innerHeaderComponent"},O9e={name:"innerHeaderGroupComponent"},k9e={name:"headerGroupComponent"},N9e={name:"innerRenderer",cellRenderer:!0,optionalMethods:["afterGuiAttached"]},B9e={name:"cellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},$9e={name:"cellRenderer",optionalMethods:["refresh","afterGuiAttached"]},G9e={name:"loadingCellRenderer",cellRenderer:!0},V9e={name:"cellEditor",mandatoryMethods:["getValue"],optionalMethods:["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached","refresh"]},z9e={name:"loadingOverlayComponent",optionalMethods:["refresh"]},H9e={name:"noRowsOverlayComponent",optionalMethods:["refresh"]},W9e={name:"tooltipComponent"},p5={name:"filter",mandatoryMethods:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethods:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},U9e={name:"floatingFilterComponent",mandatoryMethods:["onParentModelChanged"],optionalMethods:["afterGuiAttached","refresh"]},j9e={name:"fullWidthCellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},K9e={name:"loadingCellRenderer",cellRenderer:!0},q9e={name:"groupRowRenderer",optionalMethods:["afterGuiAttached"],cellRenderer:!0},X9e={name:"detailCellRenderer",optionalMethods:["refresh"],cellRenderer:!0};function Y9e(e,t){return e.getCompDetailsFromGridOptions(F9e,"agDragAndDropImage",t,!0)}function zO(e,t,r){return e.getCompDetails(t,N9e,void 0,r)}function Z9e(e,t,r){return e.getCompDetails(t,L9e,"agColumnHeader",r)}function Q9e(e,t,r){return e.getCompDetails(t,_9e,void 0,r)}function J9e(e,t){const r=t.columnGroup.getColGroupDef();return e.getCompDetails(r,k9e,"agColumnGroupHeader",t)}function eje(e,t,r){return e.getCompDetails(t,O9e,void 0,r)}function tje(e,t){return e.getCompDetailsFromGridOptions(j9e,void 0,t,!0)}function rje(e,t){return e.getCompDetailsFromGridOptions(K9e,"agLoadingCellRenderer",t,!0)}function nje(e,t){return e.getCompDetailsFromGridOptions(q9e,"agGroupRowRenderer",t,!0)}function ije(e,t){return e.getCompDetailsFromGridOptions(X9e,"agDetailCellRenderer",t,!0)}function JM(e,t,r){return e.getCompDetails(t,B9e,void 0,r)}function afe(e,t,r){return e.getCompDetails(t,$9e,void 0,r)}function oje(e,t,r){return e.getCompDetails(t,G9e,"agSkeletonCellRenderer",r,!0)}function _Y(e,t,r){return e.getCompDetails(t,V9e,"agCellEditor",r,!0)}function lfe(e,t,r,n){return e.getCompDetails(t,p5,n,r,!0)}function sje(e,t){return e.getCompDetailsFromGridOptions(A9e,"agDateInput",t,!0)}function aje(e,t){return e.getCompDetailsFromGridOptions(z9e,"agLoadingOverlay",t,!0)}function lje(e,t){return e.getCompDetailsFromGridOptions(H9e,"agNoRowsOverlay",t,!0)}function cje(e,t){return e.getCompDetails(t.colDef,W9e,"agTooltipComponent",t,!0)}function cfe(e,t,r,n){return e.getCompDetails(t,U9e,n,r)}function uje(e,t){return sfe(e,t,p5)}function dje(e,t,r){return e.mergeParams(t,p5,r)}function cm(e){const t=e;return t!=null&&t.getFrameworkComponentInstance!=null?t.getFrameworkComponentInstance():e}var ufe=new Set,eI={},Vg={},EP,dfe=!1;function hje(e){const[t,r]=e.version.split(".")||[],[n,i]=EP.split(".")||[];return t===n&&r===i}function pje(e){EP||(EP=e.version);const t=r=>`You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. ${r} Please update all modules to the same version.`;if(e.version?hje(e)||Ty(t(`'${e.moduleName}' is version ${e.version} but the other modules are version ${EP}.`)):Ty(t(`'${e.moduleName}' is incompatible.`)),e.validate){const r=e.validate();r.isValid||Ty(`${r.message}`)}}function k0(e,t){pje(e);const r=e.rowModels??["all"];ufe.add(e);let n;t!==void 0?(dfe=!0,Vg[t]===void 0&&(Vg[t]={}),n=Vg[t]):n=eI,r.forEach(i=>{n[i]===void 0&&(n[i]={}),n[i][e.moduleName]=e}),e.dependsOn&&e.dependsOn.forEach(i=>k0(i,t))}function fje(e){delete Vg[e]}function hfe(e,t,r){const n=i=>{var o,s,a;return!!((o=eI[i])!=null&&o[e])||!!((a=(s=Vg[t])==null?void 0:s[i])!=null&&a[e])};return n(r)||n("all")}function f5(){return dfe}function gje(e,t){const r=Vg[e]??{};return[...Object.values(eI.all??{}),...Object.values(r.all??{}),...Object.values(eI[t]??{}),...Object.values(r[t]??{})]}function mje(){return new Set(ufe)}function pfe(e,t){const r=Vg[e]??{};return[...Object.values(r.all??{}),...Object.values(r[t]??{})]}var b$t=class{static register(e){k0(e,void 0)}static registerModules(e){e.forEach(t=>k0(t,void 0))}},vje=class{constructor(e){this.beans={},this.createdBeans=[],this.destroyed=!1,!(!e||!e.beanClasses)&&(this.beanDestroyComparator=e.beanDestroyComparator,this.init(e))}init(e){var t;Object.entries(e.providedBeanInstances).forEach(([r,n])=>{this.beans[r]=n}),e.beanClasses.forEach(r=>{const n=new r;n.beanName?this.beans[n.beanName]=n:console.error(`Bean ${r.name} is missing beanName`),this.createdBeans.push(n)}),(t=e.derivedBeans)==null||t.forEach(r=>{const{beanName:n,bean:i}=r(this);this.beans[n]=i,this.createdBeans.push(i)}),e.beanInitComparator&&this.createdBeans.sort(e.beanInitComparator),this.initBeans(this.createdBeans)}getBeanInstances(){return Object.values(this.beans)}createBean(e,t){if(!e)throw Error("null bean");return this.initBeans([e],t),e}initBeans(e,t){e.forEach(r=>{var n,i;(n=r.preWireBeans)==null||n.call(r,this.beans),(i=r.wireBeans)==null||i.call(r,this.beans)}),e.forEach(r=>{var n;return(n=r.preConstruct)==null?void 0:n.call(r)}),t&&e.forEach(t),e.forEach(r=>{var n;return(n=r.postConstruct)==null?void 0:n.call(r)})}getBeans(){return this.beans}getBean(e){return this.beans[e]}destroy(){if(this.destroyed)return;this.destroyed=!0;const e=this.getBeanInstances();this.beanDestroyComparator&&e.sort(this.beanDestroyComparator),this.destroyBeans(e),this.beans={},this.createdBeans=[]}destroyBean(e){var t;(t=e==null?void 0:e.destroy)==null||t.call(e)}destroyBeans(e){if(e)for(let t=0;t=this.lastScrollTop,n&&e===0){const i=(r==null?void 0:r.getCurrentPage())??0;i!==this.lastPage&&(this.lastPage=i,this.scrollGoingDown=!0)}this.lastScrollTop=e}postConstruct(){this.active=!this.gos.get("suppressAnimationFrame")}verifyAnimationFrameOn(e){this.active===!1&&we(92,{methodName:e})}createTask(e,t,r){this.verifyAnimationFrameOn(r);const n={task:e,index:t,createOrder:++this.taskCount};this.addTaskToList(this[r],n),this.schedule()}cancelTask(e){this.cancelledTasks.add(e)}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;const t=this.scrollGoingDown?1:-1;e.list.sort((r,n)=>r.index!==n.index?t*(n.index-r.index):n.createOrder-r.createOrder),e.sorted=!0}addDestroyTask(e){this.verifyAnimationFrameOn("createTasksP3"),this.destroyTasks.push(e),this.schedule()}executeFrame(e){this.verifyAnimationFrameOn("executeFrame");const t=this.createTasksP1,r=t.list,n=this.createTasksP2,i=n.list,o=this.destroyTasks,s=new Date().getTime();let a=new Date().getTime()-s;const l=e<=0,c=this.beans.ctrlsSvc.getScrollFeature();for(;l||a0||(e.addEventListener("keydown",rI),e.addEventListener("mousedown",rI))}function Eje(e){tI>0||(e.removeEventListener("keydown",rI),e.removeEventListener("mousedown",rI))}function rI(e){const t=SV,r=e.type==="keydown";r&&(e.ctrlKey||e.metaKey||e.altKey)||t!==r&&(SV=r)}function Tje(e){const t=pn(e);return xje(t),tI++,()=>{tI--,Eje(t)}}function IA(){return SV}function vfe(e,t,r){t.addManagedElementListeners(r,{keydown:n=>{if(!n.defaultPrevented&&n.key===ge.TAB){const i=n.shiftKey;No(e,r,!1,i)||Ld(e,i)&&n.preventDefault()}}})}function ac(e,t,r=!1){const n=_7e;let i=hpe;t&&(i+=", "+t),r&&(i+=', [tabindex="-1"]');const o=Array.prototype.slice.apply(e.querySelectorAll(n)).filter(l=>ps(l)),s=Array.prototype.slice.apply(e.querySelectorAll(i));return s.length?((l,c)=>l.filter(u=>c.indexOf(u)===-1))(o,s):o}function co(e,t=!1,r=!1){const n=ac(e,null,r),i=t?er(n):n[0];return i?(i.focus({preventScroll:!0}),!0):!1}function No(e,t,r,n){const i=ac(t,r?':not([tabindex="-1"])':null),o=Gr(e);let s;r?s=i.findIndex(l=>l.contains(o)):s=i.indexOf(o);const a=s+(n?-1:1);return a<0||a>=i.length?null:i[a]}function m5(e,t=5){let r=0;for(;e&&fV(e)===null&&++r<=t;)e=e.parentElement;return fV(e)===null?null:e}function yfe(e,t){return e.ctrlsSvc.get("gridCtrl").focusInnerElement(t)}function Py(e){var t;return e.gos.get("suppressHeaderFocus")||!!((t=e.overlays)!=null&&t.isExclusive())}function Cfe(e){var t;return e.gos.get("suppressCellFocus")||!!((t=e.overlays)!=null&&t.isExclusive())}function Ld(e,t,r=!1){const n=e.ctrlsSvc.get("gridCtrl");return!r&&n.focusNextInnerContainer(t)?!0:((r||!t&&!n.isDetailGrid())&&n.forceFocusOutOfContainer(t),!1)}var Rje=/[&<>"']/g,Pje={"&":"&","<":"<",">":">",'"':""","'":"'"};function Sn(e,t){if(e==null)return null;const r=e.toString().toString();return t?r:r.replace(Rje,n=>Pje[n])}function Mje(e,t=!1){return e===ge.DELETE?!0:!t&&e===ge.BACKSPACE?cpe():!1}var Ije=class extends xe{constructor(e,t,r,n){super(),this.cellCtrl=e,this.rowNode=r,this.rowCtrl=n,this.beans=t}setComp(e){this.eGui=e}onKeyDown(e){const t=e.key;switch(t){case ge.ENTER:this.onEnterKeyDown(e);break;case ge.F2:this.onF2KeyDown(e);break;case ge.ESCAPE:this.onEscapeKeyDown(e);break;case ge.TAB:this.onTabKeyDown(e);break;case ge.BACKSPACE:case ge.DELETE:this.onBackspaceOrDeleteKeyDown(t,e);break;case ge.DOWN:case ge.UP:case ge.RIGHT:case ge.LEFT:this.onNavigationKeyDown(e,t);break}}onNavigationKeyDown(e,t){var r;this.cellCtrl.editing||(e.shiftKey&&this.cellCtrl.isRangeSelectionEnabled()?this.onShiftRangeSelect(e):(r=this.beans.navigation)==null||r.navigateToNextCell(e,t,this.cellCtrl.cellPosition,!0),e.preventDefault())}onShiftRangeSelect(e){const{rangeSvc:t,navigation:r}=this.beans;if(!t)return;const n=t.extendLatestRangeInDirection(e);n&&(r==null||r.ensureCellVisible(n))}onTabKeyDown(e){var t;(t=this.beans.navigation)==null||t.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){var l;const{cellCtrl:r,beans:n,rowNode:i}=this,{gos:o,rangeSvc:s,eventSvc:a}=n;if(!r.editing){if(a.dispatchEvent({type:"keyShortcutChangedCellStart"}),Mje(e,o.get("enableCellEditingOnBackspace"))){if(s&&Rs(o))s.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(r.isCellEditable()){const{column:c}=r,u=this.beans.valueSvc.getDeleteValue(c,i);i.setDataValue(c,u,"cellClear")}}else(l=n.editSvc)==null||l.startRowOrCellEdit(r,e,t);a.dispatchEvent({type:"keyShortcutChangedCellEnd"})}}onEnterKeyDown(e){var n,i;const{cellCtrl:t,beans:r}=this;if(t.editing||this.rowCtrl.editing)t.stopEditingAndFocus(!1,e.shiftKey);else if(r.gos.get("enterNavigatesVertically")){const o=e.shiftKey?ge.UP:ge.DOWN;(n=r.navigation)==null||n.navigateToNextCell(null,o,t.cellPosition,!1)}else(i=r.editSvc)==null||i.startRowOrCellEdit(t,ge.ENTER,e),t.editing&&e.preventDefault()}onF2KeyDown(e){var n;const{cellCtrl:t,beans:r}=this;t.editing||(n=r.editSvc)==null||n.startRowOrCellEdit(t,ge.F2,e)}onEscapeKeyDown(e){var n;const{cellCtrl:t,beans:r}=this;t.editing&&((n=r.editSvc)==null||n.stopRowOrCellEdit(t,!0),t.focusCell(!0))}processCharacter(e){var i;if(e.target!==this.eGui||this.cellCtrl.editing)return;const n=e.key;n===ge.SPACE?this.onSpaceKeyDown(e):(i=this.beans.editSvc)!=null&&i.startRowOrCellEdit(this.cellCtrl,n,e)&&e.preventDefault()}onSpaceKeyDown(e){var r;const{gos:t}=this.beans;!this.cellCtrl.editing&&Fa(t)&&((r=this.beans.selectionSvc)==null||r.handleSelectionEvent(e,this.rowNode,"spaceKey")),e.preventDefault()}destroy(){super.destroy()}},Dje=class extends xe{constructor(e,t,r){super(),this.cellCtrl=e,this.column=r,this.beans=t}onMouseEvent(e,t){if(!Na(t))switch(e){case"click":this.onCellClicked(t);break;case"mousedown":case"touchstart":this.onMouseDown(t);break;case"dblclick":this.onCellDoubleClicked(t);break;case"mouseout":this.onMouseOut(t);break;case"mouseover":this.onMouseOver(t);break}}onCellClicked(e){var c;if((c=this.beans.touchSvc)!=null&&c.handleCellDoubleClick(this,e))return;const{eventSvc:t,rangeSvc:r,gos:n,editSvc:i}=this.beans,o=e.ctrlKey||e.metaKey;r&&o&&r.getCellRangeCount(this.cellCtrl.cellPosition)>1&&r.intersectLastRange(!0);const s=this.cellCtrl.createEvent(e,"cellClicked");t.dispatchEvent(s);const a=this.column.getColDef();a.onCellClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{a.onCellClicked(s)})},0),(n.get("singleClickEdit")||a.singleClickEdit)&&!n.get("suppressClickEdit")&&!(e.shiftKey&&(r==null?void 0:r.getCellRanges().length)!=0)&&(i==null||i.startRowOrCellEdit(this.cellCtrl))}onCellDoubleClicked(e){const{column:t,beans:r,cellCtrl:n}=this,{eventSvc:i,frameworkOverrides:o,gos:s,editSvc:a}=r,l=t.getColDef(),c=n.createEvent(e,"cellDoubleClicked");i.dispatchEvent(c),typeof l.onCellDoubleClicked=="function"&&window.setTimeout(()=>{o.wrapOutgoing(()=>{l.onCellDoubleClicked(c)})},0),!s.get("singleClickEdit")&&!s.get("suppressClickEdit")&&(a==null||a.startRowOrCellEdit(n,null,e))}onMouseDown(e){const{ctrlKey:t,metaKey:r,shiftKey:n}=e,i=e.target,{cellCtrl:o,beans:s}=this,{eventSvc:a,rangeSvc:l,focusSvc:c,gos:u}=s;if(this.isRightClickInExistingRange(e))return;const d=l&&!l.isEmpty(),h=this.containsWidget(i),{cellPosition:p}=o;if(!n||!d){const g=u.get("enableCellTextSelection")&&e.defaultPrevented,m=(Im()||g)&&!o.editing&&!n5(i)&&!h;o.focusCell(m)}if(n&&d&&!c.isCellFocused(p)){e.preventDefault();const f=c.getFocusedCell();if(f){const{column:g,rowIndex:m,rowPinned:v}=f,b=s.rowRenderer.getRowByPosition({rowIndex:m,rowPinned:v}),S=b==null?void 0:b.getCellCtrl(g);S!=null&&S.editing&&S.stopEditing(),c.setFocusedCell({column:g,rowIndex:m,rowPinned:v,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}}if(!h){if(l)if(n)l.extendLatestRangeToCell(p);else{const f=t||r;l.setRangeToCell(p,f)}a.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseDown"))}}isRightClickInExistingRange(e){const{rangeSvc:t}=this.beans;if(t){const r=t.isCellInAnyRange(this.cellCtrl.cellPosition),n=e.button===2||e.ctrlKey&&this.beans.gos.get("allowContextMenuWithControlKey");if(r&&n)return!0}return!1}containsWidget(e){return Bg(e,"ag-selection-checkbox",3)||Bg(e,"ag-drag-handle",3)}onMouseOut(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:r}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOut")),r==null||r.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:r}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOver")),r==null||r.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;const{eGui:t}=this.cellCtrl,r=t.contains(e.target),n=t.contains(e.relatedTarget);return r&&n}destroy(){super.destroy()}},Aje=class extends xe{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.column=e.column,this.rowNode=e.rowNode}setupRowSpan(){this.rowSpan=this.column.getRowSpan(this.rowNode),this.addManagedListeners(this.beans.eventSvc,{newColumnsLoaded:()=>this.onNewColumnsLoaded()})}setComp(e){this.eGui=e,this.setupColSpan(),this.setupRowSpan(),this.onLeftChanged(),this.onWidthChanged(),this.applyRowSpan()}onNewColumnsLoaded(){const e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this.applyRowSpan(!0))}onDisplayColumnsChanged(){const e=this.getColSpanningList();ko(this.colsSpanning,e)||(this.colsSpanning=e,this.onWidthChanged(),this.onLeftChanged())}setupColSpan(){this.column.getColDef().colSpan!=null&&(this.colsSpanning=this.getColSpanningList(),this.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayColumnsChanged.bind(this),displayedColumnsWidthChanged:this.onWidthChanged.bind(this)}))}onWidthChanged(){if(!this.eGui)return;const e=this.getCellWidth();this.eGui.style.width=`${e}px`}getCellWidth(){return this.colsSpanning?this.colsSpanning.reduce((e,t)=>e+t.getActualWidth(),0):this.column.getActualWidth()}getColSpanningList(){const{column:e,rowNode:t}=this,r=e.getColSpan(t),n=[];if(r===1)n.push(e);else{let i=e;const o=e.getPinned();for(let s=0;i&&sthis.removeFeatures()),this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.onCellFocused(this.focusEventToRestore),this.applyStaticCssClasses(),this.setWrapText(),this.onFirstRightPinnedChanged(),this.onLastLeftPinnedChanged(),this.onColumnHover(),this.setupControlComps(),this.setupAutoHeight(r,o),this.refreshFirstAndLastStyles(),this.refreshAriaColIndex(),(s=this.positionFeature)==null||s.setComp(t),(a=this.customStyleFeature)==null||a.setComp(e),(l=this.tooltipFeature)==null||l.refreshTooltip(),(c=this.keyboardListener)==null||c.setComp(this.eGui),this.rangeFeature&&this.rangeFeature.setComp(e,t),i&&this.isCellEditable()?(u=this.beans.editSvc)==null||u.startEditing(this):this.showValue(),this.onCompAttachedFuncs.length&&(this.onCompAttachedFuncs.forEach(d=>d()),this.onCompAttachedFuncs=[])}setupAutoHeight(e,t){var r;this.isAutoHeight=this.column.isAutoHeight(),!(!this.isAutoHeight||!e)&&((r=this.beans.rowAutoHeight)==null||r.setupCellAutoHeight(this,e,t))}getCellAriaRole(){return this.column.getColDef().cellAriaRole??"gridcell"}isCellRenderer(){const e=this.column.getColDef();return e.cellRenderer!=null||e.cellRendererSelector!=null}getValueToDisplay(){return this.valueFormatted??this.value}showValue(e=!1){var c;const{beans:t,column:r,rowNode:n,rangeFeature:i}=this,{userCompFactory:o}=t,s=this.getValueToDisplay();let a;if(n.stub&&((c=n.groupData)==null?void 0:c[r.getId()])==null){const u=this.createCellRendererParams();a=oje(o,r.getColDef(),u)}else if(this.isCellRenderer()){const u=this.createCellRendererParams();a=JM(o,r.getColDef(),u)}this.comp.setRenderDetails(a,s,e),i&&Tl(t,()=>i==null?void 0:i.refreshHandle())}setupControlComps(){const e=this.column.getColDef();this.includeSelection=this.isIncludeControl(this.isCheckboxSelection(e)),this.includeRowDrag=this.isIncludeControl(e.rowDrag),this.includeDndSource=this.isIncludeControl(e.dndSource),this.comp.setIncludeSelection(this.includeSelection),this.comp.setIncludeDndSource(this.includeDndSource),this.comp.setIncludeRowDrag(this.includeRowDrag)}isForceWrapper(){return this.beans.gos.get("enableCellTextSelection")||this.column.isAutoHeight()}isIncludeControl(e){return this.rowNode.rowPinned!=null?!1:typeof e=="function"||e===!0}isCheckboxSelection(e){const{rowSelection:t}=this.beans.gridOptions;return e.checkboxSelection||lu(this.column)&&t&&typeof t!="string"&&$g(t)}refreshShouldDestroy(){const e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(this.isCheckboxSelection(e)),r=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),n=this.includeDndSource!=this.isIncludeControl(e.dndSource),i=this.isAutoHeight!=this.column.isAutoHeight();return t||r||n||i}onPopupEditorClosed(){this.editing&&this.stopEditingAndFocus()}stopEditing(e=!1){var t;return((t=this.beans.editSvc)==null?void 0:t.stopEditing(this,e))??!1}createCellRendererParams(){const{value:e,valueFormatted:t,column:r,rowNode:n,comp:i,eGui:o,beans:{valueSvc:s,gos:a}}=this;return a.addGridCommonParams({value:e,valueFormatted:t,getValue:()=>s.getValueForDisplay(r,n),setValue:c=>s.setValue(n,r,c),formatValue:this.formatValue.bind(this),data:n.data,node:n,pinned:r.getPinned(),colDef:r.getColDef(),column:r,refreshCell:this.refreshCell.bind(this),eGridCell:o,eParentOfValue:i.getParentOfValue(),registerRowDragger:(c,u,d,h)=>this.registerRowDragger(c,u,h),setTooltip:(c,u)=>{var d;a.assertModuleRegistered("Tooltip",3),this.tooltipFeature&&this.disableTooltipFeature(),this.enableTooltipFeature(c,u),(d=this.tooltipFeature)==null||d.refreshTooltip()}})}onCellChanged(e){e.column===this.column&&this.refreshCell({})}refreshOrDestroyCell(e){var t;this.refreshShouldDestroy()?(t=this.rowCtrl)==null||t.recreateCell(this):this.refreshCell(e)}refreshCell(e){var c,u,d,h,p,f;if(this.suppressRefreshCell||this.editing)return;const t=this.column.getColDef(),r=e!=null&&!!e.newData,n=e!=null&&!!e.suppressFlash,i=t.field==null&&t.valueGetter==null&&t.showRowGroup==null,o=e&&e.forceRefresh||i||r,s=!!this.comp,a=this.updateAndFormatValue(s),l=o||a;if(s){if(l){this.showValue(r);const g=(c=this.beans.filterManager)==null?void 0:c.isSuppressFlashingCellsBecauseFiltering();!n&&!g&&t.enableCellChangeFlash&&((u=this.beans.cellFlashSvc)==null||u.flashCell(this)),(d=this.customStyleFeature)==null||d.applyUserStyles(),(h=this.customStyleFeature)==null||h.applyClassesFromColDef()}(p=this.tooltipFeature)==null||p.refreshTooltip(),(f=this.customStyleFeature)==null||f.applyCellClassRules()}}stopEditingAndFocus(e=!1,t=!1){var r;(r=this.beans.editSvc)==null||r.stopEditingAndFocus(this,e,t)}isCellEditable(){return this.column.isCellEditable(this.rowNode)}formatValue(e){return this.callValueFormatter(e)??e}callValueFormatter(e){return this.beans.valueSvc.formatValue(this.column,this.rowNode,e)}updateAndFormatValue(e){const t=this.value,r=this.valueFormatted;return this.value=this.beans.valueSvc.getValueForDisplay(this.column,this.rowNode),this.valueFormatted=this.callValueFormatter(this.value),e?!this.valuesAreEqual(t,this.value)||this.valueFormatted!=r:!0}valuesAreEqual(e,t){const r=this.column.getColDef();return r.equals?r.equals(e,t):e===t}addDomData(e){const t=this.eGui;am(this.beans.gos,t,nI,this),e.addDestroyFunc(()=>am(this.beans.gos,t,nI,null))}createEvent(e,t){const{rowNode:r,column:n,value:i}=this;return this.beans.gos.addGridCommonParams({type:t,node:r,data:r.data,value:i,column:n,colDef:n.getColDef(),rowPinned:r.rowPinned,event:e,rowIndex:r.rowIndex})}processCharacter(e){var t;(t=this.keyboardListener)==null||t.processCharacter(e)}onKeyDown(e){var t;(t=this.keyboardListener)==null||t.onKeyDown(e)}onMouseEvent(e,t){var r;(r=this.mouseListener)==null||r.onMouseEvent(e,t)}getColSpanningList(){return this.positionFeature.getColSpanningList()}onLeftChanged(){var e;this.comp&&((e=this.positionFeature)==null||e.onLeftChanged())}onDisplayedColumnsChanged(){this.eGui&&(this.refreshAriaColIndex(),this.refreshFirstAndLastStyles())}refreshFirstAndLastStyles(){const{comp:e,column:t,beans:r}=this;gfe(e,t,r.visibleCols)}refreshAriaColIndex(){const e=this.beans.visibleCols.getAriaColIndex(this.column);e5(this.eGui,e)}onWidthChanged(){var e;return(e=this.positionFeature)==null?void 0:e.onWidthChanged()}getRowPosition(){const{rowIndex:e,rowPinned:t}=this.cellPosition;return{rowIndex:e,rowPinned:t}}updateRangeBordersIfRangeCount(){var e;this.comp&&((e=this.rangeFeature)==null||e.updateRangeBordersIfRangeCount())}onCellSelectionChanged(){var e;this.comp&&((e=this.rangeFeature)==null||e.onCellSelectionChanged())}isRangeSelectionEnabled(){return this.rangeFeature!=null}focusCell(e=!1){this.beans.focusSvc.setFocusedCell({rowIndex:this.cellPosition.rowIndex,column:this.column,rowPinned:this.rowNode.rowPinned,forceBrowserFocus:e})}onRowIndexChanged(){var e;this.createCellPosition(),this.onCellFocused(),(e=this.rangeFeature)==null||e.onCellSelectionChanged()}onSuppressCellFocusChanged(e){this.eGui&&vl(this.eGui,"tabindex",e?void 0:-1)}onFirstRightPinnedChanged(){if(!this.comp)return;const e=this.column.isFirstRightPinned();this.comp.addOrRemoveCssClass(kje,e)}onLastLeftPinnedChanged(){if(!this.comp)return;const e=this.column.isLastLeftPinned();this.comp.addOrRemoveCssClass(Nje,e)}onCellFocused(e){var i;const{beans:t}=this;if(Cfe(t))return;const r=t.focusSvc.isCellFocused(this.cellPosition);if(!this.comp){r&&(e!=null&&e.forceBrowserFocus)&&(this.focusEventToRestore=e);return}if(this.focusEventToRestore=void 0,this.comp.addOrRemoveCssClass(Oje,r),r&&e&&e.forceBrowserFocus){let o=this.comp.getFocusableElement();if(this.editing){const s=ac(o,null,!0);s.length&&(o=s[0])}o.focus({preventScroll:!!e.preventScrollOnBrowserFocus})}const n=t.gos.get("editType")==="fullRow";!r&&!n&&this.editing&&((i=t.editSvc)==null||i.stopRowOrCellEdit(this)),r&&this.rowCtrl.announceDescription()}createCellPosition(){const{rowIndex:e,rowPinned:t}=this.rowNode;this.cellPosition={rowIndex:e,rowPinned:Ai(t),column:this.column}}setInlineEditingCss(){var e;(e=this.beans.editSvc)==null||e.setInlineEditingCss(this.rowCtrl)}applyStaticCssClasses(){const{comp:e}=this;e.addOrRemoveCssClass(Fje,!0),e.addOrRemoveCssClass(Bje,!0);const t=this.column.isAutoHeight()==!0;e.addOrRemoveCssClass(Lje,t),e.addOrRemoveCssClass(_je,!t)}onColumnHover(){var e;(e=this.beans.colHover)==null||e.onCellColumnHover(this.column,this.comp)}onColDefChanged(){var e;this.comp&&(this.column.isTooltipEnabled()?(this.disableTooltipFeature(),this.enableTooltipFeature()):this.disableTooltipFeature(),this.setWrapText(),this.editing?(e=this.beans.editSvc)==null||e.handleColDefChanged(this):this.refreshOrDestroyCell({forceRefresh:!0,suppressFlash:!0}))}setWrapText(){const e=this.column.getColDef().wrapText==!0;this.comp.addOrRemoveCssClass($je,e)}dispatchCellContextMenuEvent(e){const t=this.column.getColDef(),r=this.createEvent(e,"cellContextMenu"),{beans:n}=this;n.eventSvc.dispatchEvent(r),t.onCellContextMenu&&window.setTimeout(()=>{n.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(r)})},0)}getCellRenderer(){var e;return((e=this.comp)==null?void 0:e.getCellRenderer())??null}destroy(){this.onCompAttachedFuncs=[],this.onEditorAttachedFuncs=[],super.destroy()}createSelectionCheckbox(){var t;const e=(t=this.beans.selectionSvc)==null?void 0:t.createCheckboxSelectionComponent();if(e)return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){const e=this.beans.registry.createDynamicBean("dndSourceComp",!1,this.rowNode,this.column,this.eGui);return e&&this.beans.context.createBean(e),e}registerRowDragger(e,t,r){if(this.customRowDragComp){this.customRowDragComp.setDragElement(e,t);return}const n=this.createRowDragComp(e,t,r);n&&(this.customRowDragComp=n,this.addDestroyFunc(()=>{this.beans.context.destroyBean(n),this.customRowDragComp=null}))}createRowDragComp(e,t,r){var i;const n=(i=this.beans.rowDragSvc)==null?void 0:i.createRowDragCompForCell(this.rowNode,this.column,()=>this.value,e,t,r);if(n)return this.beans.context.createBean(n),n}cellEditorAttached(){this.onEditorAttachedFuncs.forEach(e=>e()),this.onEditorAttachedFuncs=[]}},bfe="__ag_grid_instance";function Sfe(e,t){t[bfe]=e.gridInstanceId}function iI(e,t){return wfe(e,t.target)}function wfe(e,t){let r=t;for(;r;){const n=r[bfe];if(Qe(n))return n===e.gridInstanceId;r=r.parentElement}return!1}function xfe(e,t){var r;return((r=v5(e,t.target))==null?void 0:r.cellPosition)??null}function Hw(e,t){const r=Eo(e.gos,"normal"),n=t;let i,o;if(n.clientX!=null||n.clientY!=null?(i=n.clientX,o=n.clientY):(i=n.x,o=n.y),r){const s=e.ctrlsSvc.getScrollFeature(),a=s.getVScrollPosition(),l=s.getHScrollPosition();i+=l.left,o+=a.top}return{x:i,y:o}}var vc=(e=>(e[e.ToolPanel=0]="ToolPanel",e[e.HeaderCell=1]="HeaderCell",e[e.RowDrag=2]="RowDrag",e[e.ChartPanel=3]="ChartPanel",e[e.AdvancedFilterBuilder=4]="AdvancedFilterBuilder",e))(vc||{}),Vje=class extends xe{constructor(){super(...arguments),this.beanName="dragAndDrop",this.dragSourceAndParamsList=[],this.dropTargets=[]}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.dragSvc=e.dragSvc,this.environment=e.environment,this.userCompFactory=e.userCompFactory}addDragSource(e,t=!1){const r={eElement:e.eElement,dragStartPixels:e.dragStartPixels,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this),onDragging:this.onDragging.bind(this),onDragCancel:this.onDragCancel.bind(this),includeTouch:t};this.dragSourceAndParamsList.push({params:r,dragSource:e}),this.dragSvc.addDragSource(r)}getDragAndDropImageComponent(){const{dragAndDropImageComp:e}=this;return!e||!e.comp?null:e.comp}removeDragSource(e){const{dragSourceAndParamsList:t,dragSvc:r}=this,n=t.find(i=>i.dragSource===e);n&&(r.removeDragSource(n.params),Po(t,n))}destroy(){const{dragSourceAndParamsList:e,dragSvc:t,dropTargets:r}=this;e.forEach(n=>t.removeDragSource(n.params)),e.length=0,r.length=0,this.clearDragAndDropProperties(),super.destroy()}nudge(){this.dragging&&this.onDragging(this.eventLastTime,!0)}onDragStart(e,t){var r;this.dragging=!0,this.dragSource=e,this.eventLastTime=t,this.dragItem=e.getDragItem(),(r=e.onDragStarted)==null||r.call(e),this.createDragAndDropImageComponent()}onDragStop(e){var r,n;(n=(r=this.dragSource)==null?void 0:r.onDragStopped)==null||n.call(r);const{lastDropTarget:t}=this;if(t!=null&&t.onDragStop){const i=this.createDropTargetEvent(t,e,null,null,!1);t.onDragStop(i)}this.clearDragAndDropProperties()}onDragCancel(){var r;const{dragSource:e,lastDropTarget:t}=this;(r=e==null?void 0:e.onDragCancelled)==null||r.call(e),t!=null&&t.onDragCancel&&t.onDragCancel(this.createDropTargetEvent(t,this.eventLastTime,null,null,!1)),this.clearDragAndDropProperties()}clearDragAndDropProperties(){this.eventLastTime=null,this.dragging=!1,this.lastDropTarget=void 0,this.dragItem=null,this.dragSource=null,this.removeDragAndDropImageComponent()}onDragging(e,t=!1){var u,d;const r=this.getHorizontalDirection(e),n=this.getVerticalDirection(e);this.eventLastTime=e,this.positionDragAndDropImageComp(e);const i=this.dropTargets.filter(h=>this.isMouseOnDropTarget(e,h)),o=this.findCurrentDropTarget(e,i),{lastDropTarget:s,dragSource:a,dragAndDropImageComp:l,dragItem:c}=this;if(o!==s){if(this.leaveLastTargetIfExists(e,r,n,t),s!==null&&o===null&&((u=a==null?void 0:a.onGridExit)==null||u.call(a,c)),s===null&&o!==null&&((d=a==null?void 0:a.onGridEnter)==null||d.call(a,c)),this.enterDragTargetIfExists(o,e,r,n,t),o&&l){const{comp:h,promise:p}=l;h?h.setIcon(o.getIconName?o.getIconName():null,!1):p.then(f=>{f&&f.setIcon(o.getIconName?o.getIconName():null,!1)})}this.lastDropTarget=o}else if(o&&o.onDragging){const h=this.createDropTargetEvent(o,e,r,n,t);o.onDragging(h)}}getAllContainersFromDropTarget(e){const t=e.getSecondaryContainers?e.getSecondaryContainers():null,r=[[e.getContainer()]];return t?r.concat(t):r}isMouseOnDropTarget(e,t){const r=this.getAllContainersFromDropTarget(t);let n=!1;const i=(a,l)=>{for(const c of l){const{width:u,height:d,left:h,right:p,top:f,bottom:g}=c.getBoundingClientRect();if(u===0||d===0)return!1;const m=a.clientX>=h&&a.clientX=f&&a.clientYl).indexOf(o)!==-1)return s;return null}enterDragTargetIfExists(e,t,r,n,i){if(e&&e.onDragEnter){const o=this.createDropTargetEvent(e,t,r,n,i);e.onDragEnter(o)}}leaveLastTargetIfExists(e,t,r,n){const{lastDropTarget:i}=this;if(!i)return;if(i.onDragLeave){const s=this.createDropTargetEvent(i,e,t,r,n);i.onDragLeave(s)}const o=this.getDragAndDropImageComponent();o&&o.setIcon(null,!1)}addDropTarget(e){this.dropTargets.push(e)}removeDropTarget(e){this.dropTargets=this.dropTargets.filter(t=>t.getContainer()!==e.getContainer())}hasExternalDropZones(){return this.dropTargets.some(e=>e.external)}findExternalZone(e){return this.dropTargets.filter(r=>r.external).find(r=>r.getContainer()===e.getContainer())||null}isDropZoneWithinThisGrid(e){const r=this.ctrlsSvc.getGridBodyCtrl().eGridBody,{dropZoneTarget:n}=e;return r.contains(n)}getHorizontalDirection(e){var n;const t=(n=this.eventLastTime)==null?void 0:n.clientX,r=e.clientX;return t===r?null:t>r?"left":"right"}getVerticalDirection(e){var n;const t=(n=this.eventLastTime)==null?void 0:n.clientY,r=e.clientY;return t===r?null:t>r?"up":"down"}createDropTargetEvent(e,t,r,n,i){const o=e.getContainer(),s=o.getBoundingClientRect(),{dragItem:a,dragSource:l,gos:c}=this,u=t.clientX-s.left,d=t.clientY-s.top;return c.addGridCommonParams({event:t,x:u,y:d,vDirection:n,hDirection:r,dragSource:l,fromNudge:i,dragItem:a,dropZoneTarget:o})}positionDragAndDropImageComp(e){const t=this.getDragAndDropImageComponent();t&&yV(t.getGui(),e,this.beans)}removeDragAndDropImageComponent(){var t;const{dragAndDropImageComp:e}=this;if(e){const{comp:r}=e;if(r){const n=r.getGui();(t=this.dragAndDropImageParent)==null||t.removeChild(n),this.destroyBean(r)}}this.dragAndDropImageComp=null}createDragAndDropImageComponent(){const{dragSource:e}=this;if(!e)return;const t=Y9e(this.userCompFactory,{dragSource:e});if(!t)return;const r=t.newAgStackInstance();this.dragAndDropImageComp={promise:r},r.then(n=>{!n||!this.isAlive()||(this.processDragAndDropImageComponent(n),this.dragAndDropImageComp.comp=n)})}processDragAndDropImageComponent(e){const{dragSource:t,environment:r}=this;if(!t)return;const n=e.getGui();n.style.setProperty("position","absolute"),n.style.setProperty("z-index","9999"),Sfe(this.gos,n),r.applyThemeClasses(n),e.setIcon(null,!1);let{dragItemName:i}=t;typeof i=="function"&&(i=i()),e.setLabel(i||""),n.style.top="20px",n.style.left="20px";const o=xA(this.beans);this.dragAndDropImageParent=o,o?o.appendChild(n):we(54)}registerGridDropTarget(e,t){const r={getContainer:e,isInterestedIn:n=>n===1||n===0,getIconName:()=>"notAllowed"};this.addDropTarget(r),t.addDestroyFunc(()=>this.removeDropTarget(r))}},y5=class{constructor(e){this.tickingInterval=null,this.onScrollCallback=null,this.scrollContainer=e.scrollContainer,this.scrollHorizontally=e.scrollAxis.indexOf("x")!==-1,this.scrollVertically=e.scrollAxis.indexOf("y")!==-1,this.scrollByTick=e.scrollByTick!=null?e.scrollByTick:20,e.onScrollCallback&&(this.onScrollCallback=e.onScrollCallback),this.scrollVertically&&(this.getVerticalPosition=e.getVerticalPosition,this.setVerticalPosition=e.setVerticalPosition),this.scrollHorizontally&&(this.getHorizontalPosition=e.getHorizontalPosition,this.setHorizontalPosition=e.setHorizontalPosition),this.shouldSkipVerticalScroll=e.shouldSkipVerticalScroll||(()=>!1),this.shouldSkipHorizontalScroll=e.shouldSkipHorizontalScroll||(()=>!1)}check(e,t=!1){const r=t||this.shouldSkipVerticalScroll();if(r&&this.shouldSkipHorizontalScroll())return;const n=this.scrollContainer.getBoundingClientRect(),i=this.scrollByTick;this.tickLeft=e.clientXn.right-i,this.tickUp=e.clientYn.bottom-i&&!r,this.tickLeft||this.tickRight||this.tickUp||this.tickDown?this.ensureTickingStarted():this.ensureCleared()}ensureTickingStarted(){this.tickingInterval===null&&(this.tickingInterval=window.setInterval(this.doTick.bind(this),100),this.tickCount=0)}doTick(){this.tickCount++;const e=this.tickCount>20?200:this.tickCount>10?80:40;if(this.scrollVertically){const t=this.getVerticalPosition();this.tickUp&&this.setVerticalPosition(t-e),this.tickDown&&this.setVerticalPosition(t+e)}if(this.scrollHorizontally){const t=this.getHorizontalPosition();this.tickLeft&&this.setHorizontalPosition(t-e),this.tickRight&&this.setHorizontalPosition(t+e)}this.onScrollCallback&&this.onScrollCallback()}ensureCleared(){this.tickingInterval&&(window.clearInterval(this.tickingInterval),this.tickingInterval=null)}};function Hh(e){const{rowIndex:t,rowPinned:r,column:n}=e;return`${t}.${r??"null"}.${n.getId()}`}function rC(e,t){const r=e.column===t.column,n=e.rowPinned===t.rowPinned,i=e.rowIndex===t.rowIndex;return r&&n&&i}function Jo(e,t){switch(e.rowPinned){case"top":if(t.rowPinned!=="top")return!0;break;case"bottom":if(t.rowPinned!=="bottom")return!1;break;default:if(Qe(t.rowPinned))return t.rowPinned!=="top";break}return e.rowIndex{const i=n.gridBodyCtrl;this.autoScrollService=new y5({scrollContainer:i.eBodyViewport,scrollAxis:"y",getVerticalPosition:()=>i.scrollFeature.getVScrollPosition().top,setVerticalPosition:o=>i.scrollFeature.setVerticalScrollPosition(o),onScrollCallback:()=>{this.onDragging(this.lastDraggingEvent)}})})}getContainer(){return this.eContainer}isInterestedIn(e){return e===2}getIconName(){return this.gos.get("rowDragManaged")&&this.shouldPreventRowMove()?"notAllowed":"move"}shouldPreventRowMove(){const{rowGroupColsSvc:e,filterManager:t,sortSvc:r}=this.beans;return!!(((e==null?void 0:e.columns)??[]).length||(t==null?void 0:t.isAnyFilterPresent())||(r==null?void 0:r.isSortActive()))}getRowNodes(e){var n;if(!this.isFromThisGrid(e))return e.dragItem.rowNodes||[];const t=e.dragItem.rowNode;if(this.gos.get("rowDragMultiRow")){const i=[...((n=this.beans.selectionSvc)==null?void 0:n.getSelectedNodes())??[]].sort((o,s)=>o.rowIndex==null||s.rowIndex==null?0:this.getRowIndexNumber(o)-this.getRowIndexNumber(s));if(i.indexOf(t)!==-1)return i}return[t]}onDragEnter(e){e.dragItem.rowNodes=this.getRowNodes(e),this.dispatchGridEvent("rowDragEnter",e),this.getRowNodes(e).forEach(t=>{this.setRowNodeDragging(t,!0)}),this.onEnterOrDragging(e)}onDragging(e){this.onEnterOrDragging(e)}isFromThisGrid(e){const{dragSourceDomDataKey:t}=e.dragSource;return t===this.gos.getDomDataKey()}onEnterOrDragging(e){this.dispatchGridEvent("rowDragMove",e),this.lastDraggingEvent=e;const t=Hw(this.beans,e).y;this.gos.get("rowDragManaged")&&this.doManagedDrag(e,t),this.autoScrollService.check(e.event)}doManagedDrag(e,t){const{dragAndDrop:r,gos:n}=this.beans,i=this.isFromThisGrid(e),o=n.get("rowDragManaged"),s=e.dragItem.rowNodes;o&&this.shouldPreventRowMove()||(n.get("suppressMoveWhenRowDragging")||!i?r.isDropZoneWithinThisGrid(e)&&this.clientSideRowModel.highlightRowAtPixel(s[0],t):this.moveRows(s,t))}getRowIndexNumber(e){const t=e.getRowIndexString();return parseInt(er(t.split("-")),10)}moveRowAndClearHighlight(e){const t=this.clientSideRowModel,r=t.getLastHighlightedRowNode(),n=r&&r.highlighted==="Below",i=Hw(this.beans,e).y,o=e.dragItem.rowNodes;let s=n?1:0;if(this.isFromThisGrid(e))o.forEach(a=>{a.rowTop!t.getRowNode((a==null?void 0:a({data:c.data,level:0,rowPinned:c.rowPinned}))??c.data.id)).map(c=>c.data),addIndex:l})}this.clearRowHighlight()}clearRowHighlight(){this.clientSideRowModel.highlightRowAtPixel(null)}moveRows(e,t,r=0){const n=this.beans.focusSvc,i=n.getFocusedCell(),o=i&&Jc(this.beans,i);this.clientSideRowModel.ensureRowsAtPixel(e,t,r)&&(o?o.focusCell():n.clearFocusedCell())}addRowDropZone(e){if(!e.getContainer()){we(55);return}const t=this.beans.dragAndDrop;if(t.findExternalZone(e)){we(56);return}let r={getContainer:e.getContainer};e.fromGrid?r=e:(e.onDragEnter&&(r.onDragEnter=i=>{e.onDragEnter(this.draggingToRowDragEvent("rowDragEnter",i))}),e.onDragLeave&&(r.onDragLeave=i=>{e.onDragLeave(this.draggingToRowDragEvent("rowDragLeave",i))}),e.onDragging&&(r.onDragging=i=>{e.onDragging(this.draggingToRowDragEvent("rowDragMove",i))}),e.onDragStop&&(r.onDragStop=i=>{e.onDragStop(this.draggingToRowDragEvent("rowDragEnd",i))}),e.onDragCancel&&(r.onDragCancel=i=>{e.onDragCancel(this.draggingToRowDragEvent("rowDragCancel",i))}));const n={isInterestedIn:i=>i===2,getIconName:()=>"move",external:!0,...r};t.addDropTarget(n),this.addDestroyFunc(()=>t.removeDropTarget(n))}getRowDropZone(e){const t=this.getContainer.bind(this),r=this.onDragEnter.bind(this),n=this.onDragLeave.bind(this),i=this.onDragging.bind(this),o=this.onDragStop.bind(this),s=this.onDragCancel.bind(this);let a;return e?a={getContainer:t,onDragEnter:e.onDragEnter?l=>{r(l),e.onDragEnter(this.draggingToRowDragEvent("rowDragEnter",l))}:r,onDragLeave:e.onDragLeave?l=>{n(l),e.onDragLeave(this.draggingToRowDragEvent("rowDragLeave",l))}:n,onDragging:e.onDragging?l=>{i(l),e.onDragging(this.draggingToRowDragEvent("rowDragMove",l))}:i,onDragStop:e.onDragStop?l=>{o(l),e.onDragStop(this.draggingToRowDragEvent("rowDragEnd",l))}:o,onDragCancel:e.onDragCancel?l=>{s(l),e.onDragCancel(this.draggingToRowDragEvent("rowDragCancel",l))}:s,fromGrid:!0}:a={getContainer:t,onDragEnter:r,onDragLeave:n,onDragging:i,onDragStop:o,onDragCancel:s,fromGrid:!0},a}draggingToRowDragEvent(e,t){const r=this.beans,{pageBounds:n,rowModel:i,gos:o}=r,s=Hw(r,t).y,a=s>n.getCurrentPageHeight();let l=-1,c;return a||(l=i.getRowIndexAtPixel(s),c=i.getRow(l)),o.addGridCommonParams({type:e,event:t.event,node:t.dragItem.rowNode,nodes:t.dragItem.rowNodes,overIndex:l,overNode:c,y:s,vDirection:t.vDirection})}dispatchGridEvent(e,t){const r=this.draggingToRowDragEvent(e,t);this.eventSvc.dispatchEvent(r)}onDragLeave(e){this.dispatchGridEvent("rowDragLeave",e),this.stopDragging(e),this.gos.get("rowDragManaged")&&this.clearRowHighlight()}onDragStop(e){this.dispatchGridEvent("rowDragEnd",e),this.stopDragging(e);const{dragAndDrop:t,gos:r}=this.beans;r.get("rowDragManaged")&&(r.get("suppressMoveWhenRowDragging")||!this.isFromThisGrid(e))&&t.isDropZoneWithinThisGrid(e)&&this.moveRowAndClearHighlight(e)}onDragCancel(e){this.dispatchGridEvent("rowDragCancel",e),this.stopDragging(e);const{dragAndDrop:t,gos:r}=this.beans;r.get("rowDragManaged")&&(r.get("suppressMoveWhenRowDragging")||!this.isFromThisGrid(e))&&t.isDropZoneWithinThisGrid(e)&&this.clearRowHighlight()}stopDragging(e){this.autoScrollService.ensureCleared(),this.getRowNodes(e).forEach(t=>{this.setRowNodeDragging(t,!1)})}setRowNodeDragging(e,t){e.dragging!==t&&(e.dragging=t,e.dispatchRowEvent("draggingChanged"))}};function Efe(e,t,r){if(r===0)return!1;const n=Math.abs(e.clientX-t.clientX),i=Math.abs(e.clientY-t.clientY);return Math.max(n,i)<=r}var Uje=class extends xe{constructor(){super(...arguments),this.beanName="dragSvc",this.dragEndFunctions=[],this.dragSources=[]}destroy(){const{dragSources:e}=this;e.forEach(this.removeListener.bind(this)),e.length=0,super.destroy()}removeListener(e){const t=e.dragSource.eElement,r=e.mouseDownListener;if(t.removeEventListener("mousedown",r),e.touchEnabled){const n=e.touchStartListener;t.removeEventListener("touchstart",n,{passive:!0})}}removeDragSource(e){const{dragSources:t}=this,r=t.find(n=>n.dragSource===e);r&&(this.removeListener(r),Po(t,r))}addDragSource(e){const t=this.onMouseDown.bind(this,e),{eElement:r,includeTouch:n,stopPropagationForTouch:i}=e;r.addEventListener("mousedown",t);let o=null;const s=this.gos.get("suppressTouch");n&&!s&&(o=a=>{n5(a.target)||(i&&a.stopPropagation(),this.onTouchStart(e,a))},r.addEventListener("touchstart",o,{passive:!1})),this.dragSources.push({dragSource:e,mouseDownListener:t,touchStartListener:o,touchEnabled:!!n})}onTouchStart(e,t){this.currentDragParams=e,this.dragging=!1;const r=t.touches[0];this.touchLastTime=r,this.touchStart=r;const n=l=>this.onTouchMove(l,e.eElement),i=l=>this.onTouchUp(l,e.eElement),o=l=>{l.cancelable&&l.preventDefault()},s=t.target,a=[{target:Qy(this.beans),type:"touchmove",listener:o,options:{passive:!1}},{target:s,type:"touchmove",listener:n,options:{passive:!0}},{target:s,type:"touchend",listener:i,options:{passive:!0}},{target:s,type:"touchcancel",listener:i,options:{passive:!0}}];this.addTemporaryEvents(a),e.dragStartPixels===0&&this.onCommonMove(r,this.touchStart,e.eElement)}onMouseDown(e,t){const r=t;if(e.skipMouseEvent&&e.skipMouseEvent(t)||r._alreadyProcessedByDragService||(r._alreadyProcessedByDragService=!0,t.button!==0))return;this.shouldPreventMouseEvent(t)&&t.preventDefault(),this.currentDragParams=e,this.dragging=!1,this.mouseStartEvent=t,this.startTarget=t.target;const n=c=>this.onMouseMove(c,e.eElement),i=c=>this.onMouseUp(c,e.eElement),o=c=>c.preventDefault(),s=c=>{c.key===ge.ESCAPE&&this.cancelDrag(e.eElement)},a=Qy(this.beans),l=[{target:a,type:"mousemove",listener:n},{target:a,type:"mouseup",listener:i},{target:a,type:"contextmenu",listener:o},{target:a,type:"keydown",listener:s}];this.addTemporaryEvents(l),e.dragStartPixels===0&&this.onMouseMove(t,e.eElement)}addTemporaryEvents(e){e.forEach(t=>{const{target:r,type:n,listener:i,options:o}=t;r.addEventListener(n,i,o)}),this.dragEndFunctions.push(()=>{e.forEach(t=>{const{target:r,type:n,listener:i,options:o}=t;r.removeEventListener(n,i,o)})})}isEventNearStartEvent(e,t){const{dragStartPixels:r}=this.currentDragParams,n=Qe(r)?r:4;return Efe(e,t,n)}getFirstActiveTouch(e){for(let t=0;t{const s=o.target,a=s==null?void 0:s.tagName.toLocaleLowerCase();return!!(a!=null&&a.match("^a$|textarea|input|select|button"))};return r&&n&&e.cancelable&&iI(t,e)&&!i(e)}onTouchUp(e,t){let r=this.getFirstActiveTouch(e.changedTouches);r||(r=this.touchLastTime),this.onUpCommon(r,t)}onMouseUp(e,t){this.onUpCommon(e,t)}onUpCommon(e,t){this.dragging&&(this.dragging=!1,this.currentDragParams.onDragStop(e),this.eventSvc.dispatchEvent({type:"dragStopped",target:t})),this.resetDragProperties()}cancelDrag(e){var t,r;this.eventSvc.dispatchEvent({type:"dragCancelled",target:e}),(r=(t=this.currentDragParams)==null?void 0:t.onDragCancel)==null||r.call(t),this.resetDragProperties()}resetDragProperties(){this.mouseStartEvent=null,this.startTarget=null,this.touchStart=null,this.touchLastTime=null,this.currentDragParams=null;const{dragEndFunctions:e}=this;e.forEach(t=>t()),e.length=0}};function Tfe(e,t){return e+"_"+t}function ui(e){return e instanceof Rfe}var Rfe=class extends xe{constructor(e,t,r,n){super(),this.providedColumnGroup=e,this.groupId=t,this.partId=r,this.pinned=n,this.isColumn=!1,this.displayedChildren=[],this.autoHeaderHeight=null,this.parent=null}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}getUniqueId(){return Tfe(this.groupId,this.partId)}isEmptyGroup(){return this.displayedChildren.length===0}isMoving(){const e=this.getProvidedColumnGroup().getLeafColumns();return!e||e.length===0?!1:e.every(t=>t.isMoving())}checkLeft(){if(this.displayedChildren.forEach(e=>{ui(e)&&e.checkLeft()}),this.displayedChildren.length>0)if(this.gos.get("enableRtl")){const t=er(this.displayedChildren).getLeft();this.setLeft(t)}else{const e=this.displayedChildren[0].getLeft();this.setLeft(e)}else this.setLeft(null)}getLeft(){return this.left}getOldLeft(){return this.oldLeft}setLeft(e){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchLocalEvent({type:"leftChanged"}))}getPinned(){return this.pinned}getGroupId(){return this.groupId}getPartId(){return this.partId}getActualWidth(){var t;let e=0;return(t=this.displayedChildren)==null||t.forEach(r=>{e+=r.getActualWidth()}),e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;return this.displayedChildren.forEach(t=>{t.isResizable()&&(e=!0)}),e}getMinWidth(){let e=0;return this.displayedChildren.forEach(t=>{e+=t.getMinWidth()}),e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){const e=[];return this.addDisplayedLeafColumns(e),e}getDefinition(){return this.providedColumnGroup.getColGroupDef()}getColGroupDef(){return this.providedColumnGroup.getColGroupDef()}isPadding(){return this.providedColumnGroup.isPadding()}isExpandable(){return this.providedColumnGroup.isExpandable()}isExpanded(){return this.providedColumnGroup.isExpanded()}setExpanded(e){this.providedColumnGroup.setExpanded(e)}isAutoHeaderHeight(){var e;return!!((e=this.getColGroupDef())!=null&&e.autoHeaderHeight)}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}addDisplayedLeafColumns(e){this.displayedChildren.forEach(t=>{yu(t)?e.push(t):ui(t)&&t.addDisplayedLeafColumns(e)})}addLeafColumns(e){this.children.forEach(t=>{yu(t)?e.push(t):ui(t)&&t.addLeafColumns(e)})}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){const e=this.getParent();return!this.isPadding()||!e||!e.isPadding()?0:1+e.getPaddingLevel()}calculateDisplayedColumns(){this.displayedChildren=[];let e=this;for(;e!=null&&e.isPadding();)e=e.getParent();if(!(e?e.getProvidedColumnGroup().isExpandable():!1)){this.displayedChildren=this.children,this.dispatchLocalEvent({type:"displayedChildrenChanged"});return}this.children.forEach(r=>{if(ui(r)&&(!r.displayedChildren||!r.displayedChildren.length))return;switch(r.getColumnGroupShow()){case"open":e.getProvidedColumnGroup().isExpanded()&&this.displayedChildren.push(r);break;case"closed":e.getProvidedColumnGroup().isExpanded()||this.displayedChildren.push(r);break;default:this.displayedChildren.push(r);break}}),this.dispatchLocalEvent({type:"displayedChildrenChanged"})}},N0="row-group-",Pfe="t-",Mfe="b-",jje=0,da=class{constructor(e){this.master=!1,this.detail=void 0,this.rowIndex=null,this.key=null,this.sourceRowIndex=-1,this.childrenMapped={},this.treeNode=null,this.treeNodeFlags=0,this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=jje++,this.alreadyRendered=!1,this.highlighted=null,this.hovered=!1,this.__selected=!1,this.beans=e}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){var i,o,s;const r=this.data;this.data=e,(i=this.beans.valueCache)==null||i.onDataChanged(),this.updateDataOnDetailNode(),(o=this.beans.selectionSvc)==null||o.updateRowSelectable(this),this.resetQuickFilterAggregateText();const n=this.createDataChangedEvent(e,r,t);(s=this.__localEventService)==null||s.dispatchEvent(n)}updateDataOnDetailNode(){this.detailNode&&(this.detailNode.data=this.data)}createDataChangedEvent(e,t,r){return{type:"dataChanged",node:this,oldData:t,newData:e,update:r}}getRowIndexString(){return this.rowIndex==null?(yr(13),null):this.rowPinned==="top"?Pfe+this.rowIndex:this.rowPinned==="bottom"?Mfe+this.rowIndex:this.rowIndex.toString()}setDataAndId(e,t){var s,a;const{selectionSvc:r}=this.beans,n=(s=r==null?void 0:r.createDaemonNode)==null?void 0:s.call(r,this),i=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),r&&(r.updateRowSelectable(this),r.syncInRowNode(this,n));const o=this.createDataChangedEvent(e,i,!1);(a=this.__localEventService)==null||a.dispatchEvent(o)}setId(e){var r;const t=Fd(this.beans.gos);if(t)if(this.data){const n=((r=this.parent)==null?void 0:r.getRoute())??[];this.id=t({data:this.data,parentKeys:n.length>0?n:void 0,level:this.level,rowPinned:this.rowPinned}),this.id.startsWith(N0)&&yr(14,{groupPrefix:N0})}else this.id=void 0;else this.id=e}setRowTop(e){this.oldRowTop=this.rowTop,this.rowTop!==e&&(this.rowTop=e,this.dispatchRowEvent("topChanged"),this.setDisplayed(e!==null))}clearRowTopAndRowIndex(){this.oldRowTop=null,this.setRowTop(null),this.setRowIndex(null)}setHovered(e){this.hovered=e}isHovered(){return this.hovered}setRowHeight(e,t=!1){this.rowHeight=e,this.rowHeightEstimated=t,this.dispatchRowEvent("heightChanged")}setExpanded(e,t,r){var n;(n=this.beans.expansionSvc)==null||n.setExpanded(this,e,t,r)}setDataValue(e,t,r){const{colModel:n,valueSvc:i,gos:o,selectionSvc:s}=this.beans,a=typeof e!="string"?e:n.getCol(e)??n.getColDefCol(e);if(!a)return!1;const l=i.getValueForDisplay(a,this);if(o.get("readOnlyEdit")){const{beans:{eventSvc:u},data:d,rowIndex:h,rowPinned:p}=this;return u.dispatchEvent({type:"cellEditRequest",event:null,rowIndex:h,rowPinned:p,column:a,colDef:a.colDef,data:d,node:this,oldValue:l,newValue:t,value:t,source:r}),!1}const c=i.setValue(this,a,t,r);return this.dispatchCellChangedEvent(a,t,l),s==null||s.updateRowSelectable(this),c}updateHasChildren(){let e=this.group&&!this.footer||this.childrenAfterGroup&&this.childrenAfterGroup.length>0;const{rowChildrenSvc:t}=this.beans;t&&(e=t.getHasChildrenValue(this)),e!==this.__hasChildren&&(this.__hasChildren=!!e,this.dispatchRowEvent("hasChildrenChanged"))}hasChildren(){return this.__hasChildren==null&&this.updateHasChildren(),this.__hasChildren}dispatchCellChangedEvent(e,t,r){var i;const n={type:"cellChanged",node:this,column:e,newValue:t,oldValue:r};(i=this.__localEventService)==null||i.dispatchEvent(n)}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){var e;return((e=this.beans.expansionSvc)==null?void 0:e.isExpandable(this))??!1}isSelected(){return this.footer?this.sibling.isSelected():this.__selected}depthFirstSearch(e){var t;(t=this.childrenAfterGroup)==null||t.forEach(r=>r.depthFirstSearch(e)),e(this)}dispatchRowEvent(e){var t;(t=this.__localEventService)==null||t.dispatchEvent({type:e,node:this})}setSelected(e,t=!1,r="api"){var n;(n=this.beans.selectionSvc)==null||n.setNodesSelected({nodes:[this],newValue:e,clearSelection:t,source:r})}isRowPinned(){return!!this.rowPinned}addEventListener(e,t){var n,i,o,s;(n=this.beans.validation)==null||n.checkRowEvents(e),this.__localEventService||(this.__localEventService=new Kp),this.frameworkEventListenerService=(o=(i=this.beans.frameworkOverrides).createLocalEventListenerWrapper)==null?void 0:o.call(i,this.frameworkEventListenerService,this.__localEventService);const r=((s=this.frameworkEventListenerService)==null?void 0:s.wrap(t))??t;this.__localEventService.addEventListener(e,r)}removeEventListener(e,t){var n;if(!this.__localEventService)return;const r=((n=this.frameworkEventListenerService)==null?void 0:n.unwrap(t))??t;this.__localEventService.removeEventListener(e,r),this.__localEventService.noRegisteredListenersExist()&&(this.__localEventService=null)}isFullWidthCell(){if(we(61),this.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return e?e({rowNode:this}):!1}getRoute(){if(this.level===-1)return[];if(this.key==null)return;const e=[];let t=this;for(;t&&t.key!=null;)e.push(t.key),t=t.parent;return e.reverse()}setFirstChild(e){this.firstChild!==e&&(this.firstChild=e,this.dispatchRowEvent("firstChildChanged"))}setDisplayed(e){this.displayed!==e&&(this.displayed=e,this.dispatchRowEvent("displayedChanged"))}setRowIndex(e){this.rowIndex!==e&&(this.rowIndex=e,this.dispatchRowEvent("rowIndexChanged"))}setAllChildrenCount(e){this.allChildrenCount!==e&&(this.allChildrenCount=e,this.dispatchRowEvent("allChildrenCountChanged"))}setUiLevel(e){this.uiLevel!==e&&(this.uiLevel=e,this.dispatchRowEvent("uiLevelChanged"))}};function Ife(e,t,r){return t.addGridCommonParams({type:r,node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned})}var DA=class extends Je{constructor(e,t){super('
'),this.column=e,this.source=t,this.filterWrapper=null}postConstruct(){this.createFilter(!0),this.addManagedEventListeners({filterDestroyed:this.onFilterDestroyed.bind(this)})}hasFilter(){return!!this.filterWrapper}getFilter(){var e;return((e=this.filterWrapper)==null?void 0:e.filterPromise)??null}afterInit(){var e,t;return((t=(e=this.filterWrapper)==null?void 0:e.filterPromise)==null?void 0:t.then(()=>{}))??lr.resolve()}afterGuiAttached(e){var t,r;(r=(t=this.filterWrapper)==null?void 0:t.filterPromise)==null||r.then(n=>{var i;(i=n==null?void 0:n.afterGuiAttached)==null||i.call(n,e)})}afterGuiDetached(){var e,t;(t=(e=this.filterWrapper)==null?void 0:e.filterPromise)==null||t.then(r=>{var n;(n=r==null?void 0:r.afterGuiDetached)==null||n.call(r)})}createFilter(e){var n,i;const{column:t,source:r}=this;this.filterWrapper=((n=this.beans.filterManager)==null?void 0:n.getOrCreateFilterWrapper(t))??null,(i=this.filterWrapper)!=null&&i.filterPromise&&this.filterWrapper.filterPromise.then(o=>{const s=o.getGui();Qe(s)||we(69,{guiFromFilter:s}),this.appendChild(s),e&&this.eventSvc.dispatchEvent({type:"filterOpened",column:t,source:r,eGui:this.getGui()})})}onFilterDestroyed(e){(e.source==="api"||e.source==="paramsUpdated")&&e.column.getId()===this.column.getId()&&this.beans.colModel.getColDefCol(this.column)&&(Jr(this.getGui()),this.createFilter())}destroy(){this.filterWrapper=null,super.destroy()}},Dfe="ag-resizer-wrapper",wh=(e,t)=>`
`,Kje=`
${wh("eTopLeft","topLeft")} ${wh("eTop","top")} ${wh("eTopRight","topRight")} ${wh("eRight","right")} ${wh("eBottomRight","bottomRight")} ${wh("eBottom","bottom")} ${wh("eBottomLeft","bottomLeft")} ${wh("eLeft","left")}
`,AA=class extends xe{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0},this.lastSize={width:-1,height:-1},this.positioned=!1,this.resizersAdded=!1,this.resizeListeners=[],this.boundaryEl=null,this.isResizing=!1,this.isMoving=!1,this.resizable={},this.movable=!1,this.currentResizer=null,this.config=Object.assign({},{popup:!1},t)}wireBeans(e){this.popupSvc=e.popupSvc,this.dragSvc=e.dragSvc}center(){const{clientHeight:e,clientWidth:t}=this.offsetParent,r=t/2-this.getWidth()/2,n=e/2-this.getHeight()/2;this.offsetElement(r,n)}initialisePosition(){if(this.positioned)return;const{centered:e,forcePopupParentAsOffsetParent:t,minWidth:r,width:n,minHeight:i,height:o,x:s,y:a}=this.config;this.offsetParent||this.setOffsetParent();let l=0,c=0;const u=ps(this.element);if(u){const d=this.findBoundaryElement(),h=window.getComputedStyle(d);if(h.minWidth!=null){const p=d.offsetWidth-this.element.offsetWidth;c=parseInt(h.minWidth,10)-p}if(h.minHeight!=null){const p=d.offsetHeight-this.element.offsetHeight;l=parseInt(h.minHeight,10)-p}}if(this.minHeight=i||l,this.minWidth=r||c,n&&this.setWidth(n),o&&this.setHeight(o),(!n||!o)&&this.refreshSize(),e)this.center();else if(s||a)this.offsetElement(s,a);else if(u&&t){let d=this.boundaryEl,h=!0;if(d||(d=this.findBoundaryElement(),h=!1),d){const p=parseFloat(d.style.top),f=parseFloat(d.style.left);h?this.offsetElement(isNaN(f)?0:f,isNaN(p)?0:p):this.setPosition(f,p)}}this.positioned=!!this.offsetParent}isPositioned(){return this.positioned}getPosition(){return this.position}setMovable(e,t){var n,i;if(!this.config.popup||e===this.movable)return;this.movable=e;const r=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?((n=this.dragSvc)==null||n.addDragSource(r),this.moveElementDragListener=r):((i=this.dragSvc)==null||i.removeDragSource(r),this.moveElementDragListener=void 0)}setResizable(e){if(this.clearResizeListeners(),e?this.addResizers():this.removeResizers(),typeof e=="boolean"){if(e===!1)return;e={topLeft:e,top:e,topRight:e,right:e,bottomRight:e,bottom:e,bottomLeft:e,left:e}}Object.keys(e).forEach(t=>{var s;const n=!!e[t],i=this.getResizerElement(t),o={dragStartPixels:0,eElement:i,onDragStart:a=>this.onResizeStart(a,t),onDragging:this.onResize.bind(this),onDragStop:a=>this.onResizeEnd(a,t)};(n||!this.isAlive()&&!n)&&(n?((s=this.dragSvc)==null||s.addDragSource(o),this.resizeListeners.push(o),i.style.pointerEvents="all"):i.style.pointerEvents="none",this.resizable[t]=n)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";const{height:e,width:t}=this.lastSize;t!==-1&&(this.element.style.width=`${t}px`),e!==-1&&(this.element.style.height=`${e}px`)}getHeight(){return this.element.offsetHeight}setHeight(e){const{popup:t}=this.config,r=this.element;let n=!1;if(typeof e=="string"&&e.indexOf("%")!==-1)Gw(r,e),e=SA(r),n=!0;else if(e=Math.max(this.minHeight,e),this.positioned){const i=this.getAvailableHeight();i&&e>i&&(e=i)}this.getHeight()!==e&&(n?(r.style.maxHeight="unset",r.style.minHeight="unset"):t?Gw(r,e):(r.style.height=`${e}px`,r.style.flex="0 0 auto",this.lastSize.height=typeof e=="number"?e:parseFloat(e)))}getAvailableHeight(){const{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();const{clientHeight:r}=this.offsetParent;if(!r)return null;const n=this.element.getBoundingClientRect(),i=this.offsetParent.getBoundingClientRect(),o=e?this.position.y:n.top,s=e?0:i.top;let a=0;if(t){const c=this.element.parentElement;if(c){const{bottom:u}=c.getBoundingClientRect();a=u-n.bottom}}return r+s-o-a}getWidth(){return this.element.offsetWidth}setWidth(e){const t=this.element,{popup:r}=this.config;let n=!1;if(typeof e=="string"&&e.indexOf("%")!==-1)sc(t,e),e=sm(t),n=!0;else if(this.positioned){e=Math.max(this.minWidth,e);const{clientWidth:i}=this.offsetParent,o=r?this.position.x:this.element.getBoundingClientRect().left;i&&e+o>i&&(e=i-o)}this.getWidth()!==e&&(n?(t.style.maxWidth="unset",t.style.minWidth="unset"):this.config.popup?sc(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width=typeof e=="number"?e:parseFloat(e)))}offsetElement(e=0,t=0){var i;const{forcePopupParentAsOffsetParent:r}=this.config,n=r?this.boundaryEl:this.element;n&&((i=this.popupSvc)==null||i.positionPopup({ePopup:n,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t})}),this.setPosition(parseFloat(n.style.left),parseFloat(n.style.top)))}constrainSizeToAvailableHeight(e){var r;if(!this.config.forcePopupParentAsOffsetParent)return;const t=()=>{const n=this.getAvailableHeight();this.element.style.setProperty("max-height",`${n}px`)};e&&this.popupSvc?this.resizeObserverSubscriber=Ga(this.beans,(r=this.popupSvc)==null?void 0:r.getPopupParent(),t):(this.element.style.removeProperty("max-height"),this.resizeObserverSubscriber&&(this.resizeObserverSubscriber(),this.resizeObserverSubscriber=void 0))}setPosition(e,t){this.position.x=e,this.position.y=t}updateDragStartPosition(e,t){this.dragStartPosition={x:e,y:t}}calculateMouseMovement(e){const{e:t,isLeft:r,isTop:n,anywhereWithin:i,topBuffer:o}=e,s=t.clientX-this.dragStartPosition.x,a=t.clientY-this.dragStartPosition.y,l=this.shouldSkipX(t,!!r,!!i,s)?0:s,c=this.shouldSkipY(t,!!n,o,a)?0:a;return{movementX:l,movementY:c}}shouldSkipX(e,t,r,n){const i=this.element.getBoundingClientRect(),o=this.offsetParent.getBoundingClientRect(),s=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.x:i.left;let l=a<=0&&o.left>=e.clientX||o.right<=e.clientX&&o.right<=s.right;return l?!0:(t?l=n<0&&e.clientX>a+o.left||n>0&&e.clientXs.right||n>0&&e.clientXs.right||n>0&&e.clientX=e.clientY||o.bottom<=e.clientY&&o.bottom<=s.bottom;return l?!0:(t?l=n<0&&e.clientY>a+o.top+r||n>0&&e.clientYs.bottom||n>0&&e.clientY!r.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){const e=this.getSiblings()||[];let t=0,r=0;for(let n=0;ne)}onResize(e){if(!this.isResizing||!this.currentResizer)return;const{popup:t,forcePopupParentAsOffsetParent:r}=this.config,{isTop:n,isRight:i,isBottom:o,isLeft:s}=this.currentResizer,a=i||s,l=o||n,{movementX:c,movementY:u}=this.calculateMouseMovement({e,isLeft:s,isTop:n}),d=this.position.x,h=this.position.y;let p=0,f=0;if(a&&c){const g=s?-1:1,m=this.getWidth(),v=m+c*g;let b=!1;s&&(p=m-v,(d+p<=0||v<=this.minWidth)&&(b=!0,p=0)),b||this.setWidth(v)}if(l&&u){const g=n?-1:1,m=this.getHeight(),v=m+u*g;let b=!1;n?(f=m-v,(h+f<=0||v<=this.minHeight)&&(b=!0,f=0)):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&mthis.element.parentElement.offsetHeight&&(b=!0),b||this.setHeight(v)}this.updateDragStartPosition(e.clientX,e.clientY),((t||r)&&p||f)&&this.offsetElement(d+p,h+f)}onResizeEnd(e,t){this.isResizing=!1,this.currentResizer=null,this.boundaryEl=null,this.element.classList.remove("ag-resizing"),this.resizerMap[t].element.classList.remove("ag-active"),this.dispatchLocalEvent({type:"resize"})}refreshSize(){const e=this.element;this.config.popup&&(this.config.width||this.setWidth(e.offsetWidth),this.config.height||this.setHeight(e.offsetHeight))}onMoveStart(e){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.isMoving=!0,this.element.classList.add("ag-moving"),this.updateDragStartPosition(e.clientX,e.clientY)}onMove(e){if(!this.isMoving)return;const{x:t,y:r}=this.position;let n;this.config.calculateTopBuffer&&(n=this.config.calculateTopBuffer());const{movementX:i,movementY:o}=this.calculateMouseMovement({e,isTop:!0,anywhereWithin:!0,topBuffer:n});this.offsetElement(t+i,r+o),this.updateDragStartPosition(e.clientX,e.clientY)}onMoveEnd(){this.isMoving=!1,this.boundaryEl=null,this.element.classList.remove("ag-moving")}setOffsetParent(){this.config.forcePopupParentAsOffsetParent&&this.popupSvc?this.offsetParent=this.popupSvc.getPopupParent():this.offsetParent=this.element.offsetParent}findBoundaryElement(){let e=this.element;for(;e;){if(window.getComputedStyle(e).position!=="static")return e;e=e.parentElement}return this.element}clearResizeListeners(){var e;for(;this.resizeListeners.length;){const t=this.resizeListeners.pop();(e=this.dragSvc)==null||e.removeDragSource(t)}}destroy(){var e;super.destroy(),this.moveElementDragListener&&((e=this.dragSvc)==null||e.removeDragSource(this.moveElementDragListener)),this.constrainSizeToAvailableHeight(!1),this.clearResizeListeners(),this.removeResizers()}},Afe="ag-focus-managed",qp=class extends xe{constructor(e,t={}){super(),this.eFocusable=e,this.callbacks=t,this.callbacks={shouldStopEventPropagation:()=>!1,onTabKeyDown:r=>{if(r.defaultPrevented)return;const n=No(this.beans,this.eFocusable,!1,r.shiftKey);n&&(n.focus(),r.preventDefault())},...t}}postConstruct(){const{eFocusable:e,callbacks:{onFocusIn:t,onFocusOut:r}}=this;e.classList.add(Afe),this.addKeyDownListeners(e),t&&this.addManagedElementListeners(e,{focusin:t}),r&&this.addManagedElementListeners(e,{focusout:r})}addKeyDownListeners(e){this.addManagedElementListeners(e,{keydown:t=>{if(t.defaultPrevented||Na(t))return;const{callbacks:r}=this;if(r.shouldStopEventPropagation(t)){di(t);return}t.key===ge.TAB?r.onTabKeyDown(t):r.handleKeyDown&&r.handleKeyDown(t)}})}},Ffe={applyFilter:"Apply",clearFilter:"Clear",resetFilter:"Reset",cancelFilter:"Cancel",textFilter:"Text Filter",numberFilter:"Number Filter",dateFilter:"Date Filter",setFilter:"Set Filter",filterOoo:"Filter...",empty:"Choose one",equals:"Equals",notEqual:"Does not equal",lessThan:"Less than",greaterThan:"Greater than",inRange:"Between",inRangeStart:"From",inRangeEnd:"To",lessThanOrEqual:"Less than or equal to",greaterThanOrEqual:"Greater than or equal to",contains:"Contains",notContains:"Does not contain",startsWith:"Begins with",endsWith:"Ends with",blank:"Blank",notBlank:"Not blank",before:"Before",after:"After",andCondition:"AND",orCondition:"OR",dateFormatOoo:"yyyy-mm-dd"};function C5(e,t){const{debounceMs:r}=e;return oI(e)?(r!=null&&we(71),0):r??t}function oI(e){var t;return(((t=e.buttons)==null?void 0:t.indexOf("apply"))??-1)>=0}var FA=class extends Je{constructor(e){super(),this.filterNameKey=e,this.applyActive=!1,this.hidePopup=null,this.debouncePending=!1,this.appliedModel=null,this.eFilterBody=Ce,this.buttonListeners=[],this.defaultDebounceMs=0}postConstruct(){this.resetTemplate(),this.createManagedBean(new qp(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=new AA(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}),this.createBean(this.positionableFeature)}handleKeyDown(e){}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return!!this.appliedModel}resetTemplate(e){let t=this.getGui();t&&t.removeEventListener("submit",this.onFormSubmit);const r=`
${this.createBodyTemplate()}
`;this.setTemplate(r,this.getAgComponents(),e),t=this.getGui(),t==null||t.addEventListener("submit",this.onFormSubmit)}isReadOnly(){return!!this.params.readOnly}init(e){this.setParams(e),this.resetUiToDefaults(!0).then(()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}setParams(e){this.params=e,this.applyActive=oI(e),this.resetButtonsPanel(e)}updateParams(e){this.params=e,this.applyActive=oI(e),this.resetUiToActiveModel(this.getModel(),()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}resetButtonsPanel(e,t){const{buttons:r,readOnly:n}=t??{},{buttons:i,readOnly:o}=e;if(n===o&&Yy(r,i))return;const s=i&&i.length>0&&!this.isReadOnly();if(this.eButtonsPanel?(Jr(this.eButtonsPanel),this.buttonListeners.forEach(c=>c()),this.buttonListeners=[]):s&&(this.eButtonsPanel=document.createElement("div"),this.eButtonsPanel.classList.add("ag-filter-apply-panel")),!s){this.eButtonsPanel&&si(this.eButtonsPanel);return}const a=document.createDocumentFragment(),l=c=>{let u;const d=c?this.translate(`${c}Filter`):void 0;switch(c){case"apply":u=f=>this.onBtApply(!1,!1,f);break;case"clear":u=()=>this.onBtClear();break;case"reset":u=()=>this.onBtReset();break;case"cancel":u=f=>{this.onBtCancel(f)};break;default:we(75);return}const p=Ts(``);this.buttonListeners.push(...this.addManagedElementListeners(p,{click:u})),a.append(p)};i.forEach(c=>l(c)),this.eButtonsPanel.append(a),this.getGui().appendChild(this.eButtonsPanel)}setupOnBtApplyDebounce(){const e=C5(this.params,this.defaultDebounceMs),t=no(this,this.checkApplyDebounce.bind(this),e);this.onBtApplyDebounce=()=>{this.debouncePending=!0,t()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.onBtApply())}getModel(){return this.appliedModel??null}setModel(e){return(e!=null?this.setModelIntoUi(e):this.resetUiToDefaults()).then(()=>{this.updateUiVisibility(),this.applyModel("api")})}onBtCancel(e){this.resetUiToActiveModel(this.getModel(),()=>{this.handleCancelEnd(e)})}handleCancelEnd(e){this.params.closeOnApply&&this.close(e)}resetUiToActiveModel(e,t){const r=()=>{this.onUiChanged(!1,"prevent"),t==null||t()};e!=null?this.setModelIntoUi(e).then(r):this.resetUiToDefaults().then(r)}onBtClear(){this.resetUiToDefaults().then(()=>this.onUiChanged())}onBtReset(){this.onBtClear(),this.onBtApply()}applyModel(e="api"){const t=this.getModelFromUi();if(!this.isModelValid(t))return!1;const r=this.appliedModel;return this.appliedModel=t,!this.areModelsEqual(r,t)}isModelValid(e){return!0}onFormSubmit(e){e.preventDefault()}onBtApply(e=!1,t=!1,r){r&&r.preventDefault(),this.applyModel(t?"rowDataUpdated":"ui")&&this.params.filterChangedCallback({afterFloatingFilter:e,afterDataChange:t,source:"columnFilter"});const{closeOnApply:n}=this.params;n&&this.applyActive&&!e&&!t&&this.close(r)}onNewRowsLoaded(){}close(e){if(!this.hidePopup)return;const t=e,r=t&&t.key;let n;(r==="Enter"||r==="Space")&&(n={keyboardEvent:t}),this.hidePopup(n),this.hidePopup=null}onUiChanged(e=!1,t){if(this.updateUiVisibility(),this.params.filterModifiedCallback(),this.applyActive&&!this.isReadOnly()){const r=this.isModelValid(this.getModelFromUi()),n=this.queryForHtmlElement('[data-ref="applyFilterButton"]');n&&cl(n,!r)}e&&!t||t==="immediately"?this.onBtApply(e):(!this.applyActive&&!t||t==="debounce")&&this.onBtApplyDebounce()}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup),this.refreshFilterResizer(e==null?void 0:e.container)}refreshFilterResizer(e){const{positionableFeature:t,gos:r}=this;if(!t||e==="toolPanel")return;e==="floatingFilter"||e==="columnFilter"?(t.restoreLastSize(),t.setResizable(r.get("enableRtl")?{bottom:!0,bottomLeft:!0,left:!0}:{bottom:!0,bottomRight:!0,right:!0})):(t.removeSizeFromEl(),t.setResizable(!1)),t.constrainSizeToAvailableHeight(!0)}afterGuiDetached(){var e;this.checkApplyDebounce(),(e=this.positionableFeature)==null||e.constrainSizeToAvailableHeight(!1)}refresh(e){const t=this.params;return this.params=e,this.resetButtonsPanel(e,t),!0}destroy(){const e=this.getGui();e&&e.removeEventListener("submit",this.onFormSubmit),this.hidePopup=null,this.positionableFeature&&(this.positionableFeature=this.destroyBean(this.positionableFeature)),this.appliedModel=null,super.destroy()}translate(e){return this.getLocaleTextFunc()(e,Ffe[e])}getCellValue(e){return this.params.getValue(e)}getPositionableElement(){return this.eFilterBody}};function Lfe(e,t,r){if(t==null)return null;let n=null;const{compName:i,jsComp:o,fwComp:s}=uje(e,t);return i?n={agSetColumnFilter:"agSetColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"}[i]:o==null&&s==null&&t.filter===!0&&(n=r()),n}var tc={AUTO_HEIGHT:"ag-layout-auto-height",NORMAL:"ag-layout-normal",PRINT:"ag-layout-print"},b5=class extends xe{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){const e=this.gos.get("domLayout"),t={autoHeight:e==="autoHeight",normal:e==="normal",print:e==="print"},r=t.autoHeight?tc.AUTO_HEIGHT:t.print?tc.PRINT:tc.NORMAL;this.view.updateLayoutClasses(r,t)}},xh="Viewport",OY="fakeVScrollComp",kY=["fakeHScrollComp","centerHeader","topCenter","bottomCenter","stickyTopCenter","stickyBottomCenter"],qje=class extends xe{constructor(e){super(),this.lastScrollSource=[null,null],this.scrollLeft=-1,this.nextScrollTop=-1,this.scrollTop=-1,this.lastOffsetHeight=-1,this.lastScrollTop=-1,this.scrollTimer=0,this.needsRefreshedScrollPosition=!0,this.eBodyViewport=e,this.resetLastHScrollDebounced=no(this,()=>this.lastScrollSource[1]=null,500),this.resetLastVScrollDebounced=no(this,()=>this.lastScrollSource[0]=null,500)}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.animationFrameSvc=e.animationFrameSvc,this.visibleCols=e.visibleCols}destroy(){super.destroy(),window.clearTimeout(this.scrollTimer)}postConstruct(){this.enableRtl=this.gos.get("enableRtl");const e=this.requireUpdatedScrollPosition.bind(this);this.addManagedEventListeners({displayedColumnsWidthChanged:this.onDisplayedColumnsWidthChanged.bind(this),gridSizeChanged:e}),this.addManagedElementListeners(this.eBodyViewport,{scroll:e}),this.ctrlsSvc.whenReady(this,t=>{this.centerRowsCtrl=t.center,this.onDisplayedColumnsWidthChanged(),this.addScrollListener()})}requireUpdatedScrollPosition(){this.needsRefreshedScrollPosition=!0}addScrollListener(){this.addHorizontalScrollListeners(),this.addVerticalScrollListeners()}addHorizontalScrollListeners(){this.addManagedElementListeners(this.centerRowsCtrl.eViewport,{scroll:this.onHScroll.bind(this,xh)});for(const e of kY){const t=this.ctrlsSvc.get(e);this.registerScrollPartner(t,this.onHScroll.bind(this,e))}}addVerticalScrollListeners(){const e=this.ctrlsSvc.get("fakeVScrollComp"),t=this.gos.get("debounceVerticalScrollbar"),r=t?no(this,this.onVScroll.bind(this,xh),100):this.onVScroll.bind(this,xh),n=t?no(this,this.onVScroll.bind(this,OY),100):this.onVScroll.bind(this,OY);this.addManagedElementListeners(this.eBodyViewport,{scroll:r}),this.registerScrollPartner(e,n)}registerScrollPartner(e,t){e.onScrollCallback(t)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloatingCenter()}horizontallyScrollHeaderCenterAndFloatingCenter(e){this.centerRowsCtrl!=null&&(e===void 0&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft()),this.setScrollLeftForAllContainersExceptCurrent(Math.abs(e)))}setScrollLeftForAllContainersExceptCurrent(e){for(const t of[...kY,xh]){if(this.lastScrollSource[1]===t)continue;const r=this.getViewportForSource(t);UM(r,e,this.enableRtl)}}getViewportForSource(e){return e===xh?this.centerRowsCtrl.eViewport:this.ctrlsSvc.get(e).eViewport}isControllingScroll(e,t){return this.lastScrollSource[t]==null?(t===0?this.lastScrollSource[0]=e:this.lastScrollSource[1]=e,!0):this.lastScrollSource[t]===e}onHScroll(e){if(!this.isControllingScroll(e,1))return;const t=this.centerRowsCtrl.eViewport,{scrollLeft:r}=t;if(this.shouldBlockScrollUpdate(1,r,!0))return;const n=WM(this.getViewportForSource(e),this.enableRtl);this.doHorizontalScroll(n),this.resetLastHScrollDebounced()}onVScroll(e){if(!this.isControllingScroll(e,0))return;let t;if(e===xh?t=this.eBodyViewport.scrollTop:t=this.ctrlsSvc.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0))return;const{animationFrameSvc:r}=this;r==null||r.setScrollTop(t),this.nextScrollTop=t,e===xh?this.ctrlsSvc.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,!r||this.gos.get("suppressAnimationFrame")?this.scrollGridIfNeeded():r.schedule(),this.resetLastVScrollDebounced()}doHorizontalScroll(e){const t=this.ctrlsSvc.get("fakeHScrollComp").getScrollPosition();this.scrollLeft===e&&e===t||(this.scrollLeft=e,this.fireScrollEvent(1),this.horizontallyScrollHeaderCenterAndFloatingCenter(e),this.centerRowsCtrl.onHorizontalViewportChanged(!0))}fireScrollEvent(e){const t={type:"bodyScroll",direction:e===1?"horizontal":"vertical",left:this.scrollLeft,top:this.scrollTop};this.eventSvc.dispatchEvent(t),window.clearTimeout(this.scrollTimer),this.scrollTimer=window.setTimeout(()=>{this.scrollTimer=0,this.eventSvc.dispatchEvent({...t,type:"bodyScrollEnd"})},100)}shouldBlockScrollUpdate(e,t,r=!1){return r&&!fp()?!1:e===0?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t)}shouldBlockVerticalScroll(e){const t=bA(this.eBodyViewport),{scrollHeight:r}=this.eBodyViewport;return e<0||e+t>r}shouldBlockHorizontalScroll(e){const t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:r}=this.centerRowsCtrl.eViewport;if(this.enableRtl&&HM()){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>r}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){this.scrollLeft!==this.centerRowsCtrl.getCenterViewportScrollLeft()&&this.onHScroll(xh)}scrollGridIfNeeded(){const e=this.scrollTop!=this.nextScrollTop;return e&&(this.scrollTop=this.nextScrollTop,this.redrawRowsAfterScroll()),e}setHorizontalScrollPosition(e,t=!1){const n=this.centerRowsCtrl.eViewport.scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(this.enableRtl&&HM()?e=e>0?0:n:e=Math.min(Math.max(e,0),n)),UM(this.centerRowsCtrl.eViewport,Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.eBodyViewport.scrollTop=e}getVScrollPosition(){if(!this.needsRefreshedScrollPosition){const{lastOffsetHeight:r,lastScrollTop:n}=this;return{top:n,bottom:n+r}}this.needsRefreshedScrollPosition=!1;const{scrollTop:e,offsetHeight:t}=this.eBodyViewport;return this.lastScrollTop=e,this.lastOffsetHeight=t,{top:e,bottom:e+t}}getApproximateVScollPosition(){return this.lastScrollTop>=0&&this.lastOffsetHeight>=0?{top:this.scrollTop,bottom:this.scrollTop+this.lastOffsetHeight}:this.getVScrollPosition()}getHScrollPosition(){return this.centerRowsCtrl.getHScrollPosition()}isHorizontalScrollShowing(){return this.centerRowsCtrl.isHorizontalScrollShowing()}scrollHorizontally(e){const t=this.centerRowsCtrl.eViewport.scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.eViewport.scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){const{rowModel:r}=this.beans,n=r.getRowCount();let i=-1;for(let o=0;o=0&&this.ensureIndexVisible(i,t)}ensureIndexVisible(e,t){if(Eo(this.gos,"print"))return;const{rowModel:r}=this.beans,n=r.getRowCount();if(typeof e!="number"||e<0||e>=n){we(88,{index:e});return}const o=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel"),{frameworkOverrides:s,pagination:a,pageBounds:l,rowContainerHeight:c,rowRenderer:u}=this.beans;s.wrapIncoming(()=>{var m;o||a==null||a.goToPageWithIndex(e);const d=this.ctrlsSvc.getGridBodyCtrl(),h=d.stickyTopHeight,p=d.stickyBottomHeight,f=r.getRow(e);let g;do{const v=f.rowTop,b=f.rowHeight,S=l.getPixelOffset(),x=f.rowTop-S,E=x+f.rowHeight,R=this.getVScrollPosition(),T=c.divStretchOffset,M=R.top+T,D=R.bottom+T,A=D-M,I=c.getScrollPositionForPixel(x),L=c.getScrollPositionForPixel(E-A),F=Math.min((I+L)/2,x),k=M+h>x,O=D-p{var s;o!==null&&this.centerRowsCtrl.setCenterViewportScrollLeft(o),this.centerRowsCtrl.onHorizontalViewportChanged(),(s=this.animationFrameSvc)==null||s.flushAllFrames()})}getPositionedHorizontalScroll(e,t){const{columnBeforeStart:r,columnAfterEnd:n}=this.isColumnOutsideViewport(e),i=this.centerRowsCtrl.getCenterWidth()i:rn;return{columnBeforeStart:s,columnAfterEnd:a}}getColumnBounds(e){const t=this.enableRtl,r=this.visibleCols.bodyWidth,n=e.getActualWidth(),i=e.getLeft(),o=t?-1:1,s=t?r-i:i,a=s+n*o,l=s+n/2*o;return{colLeft:s,colMiddle:l,colRight:a}}getViewportBounds(){const e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft(),r=t,n=e+t;return{start:r,end:n,width:e}}},S5=class extends xe{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){const e=this.setWidth.bind(this);this.addManagedPropertyListener("domLayout",e),this.addManagedEventListeners({columnContainerWidthChanged:e,displayedColumnsChanged:e,leftPinnedWidthChanged:e}),this.addSpacer&&this.addManagedEventListeners({rightPinnedWidthChanged:e,scrollVisibilityChanged:e,scrollbarWidthChanged:e}),this.setWidth()}setWidth(){const e=Eo(this.gos,"print"),{visibleCols:t,scrollVisibleSvc:r}=this.beans,n=t.bodyWidth,i=t.getColsLeftWidth(),o=t.getDisplayedColumnsRightWidth();let s;e?s=n+i+o:(s=n,this.addSpacer&&(this.gos.get("enableRtl")?i:o)===0&&r.verticalScrollShowing&&(s+=r.getScrollbarWidth())),this.callback(s)}},Xje=class extends xe{constructor(e){super(),this.centerContainerCtrl=e}wireBeans(e){this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.listenForResize()}),this.addManagedEventListeners({scrollbarWidthChanged:this.onScrollbarWidthChanged.bind(this)}),this.addManagedPropertyListeners(["alwaysShowHorizontalScroll","alwaysShowVerticalScroll"],()=>{this.checkViewportAndScrolls()})}listenForResize(){const{beans:e,centerContainerCtrl:t,gridBodyCtrl:r}=this,n=()=>{Tl(e,()=>{this.onCenterViewportResized()})};t.registerViewportResizeListener(n),r.registerBodyViewportResizeListener(n)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.scrollVisibleSvc.updateScrollGap(),this.centerContainerCtrl.isViewportInTheDOMTree()){const{pinnedCols:e,colFlex:t}=this.beans;e==null||e.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();const r=this.centerContainerCtrl.getCenterWidth();r!==this.centerWidth&&(this.centerWidth=r,t==null||t.refreshFlexedColumns({viewportWidth:this.centerWidth,updateBodyWidths:!0,fireResizedEvent:!0}))}else this.bodyHeight=0}checkViewportAndScrolls(){this.updateScrollVisibleService(),this.checkBodyHeight(),this.onHorizontalViewportChanged(),this.gridBodyCtrl.scrollFeature.checkScrollLeft()}getBodyHeight(){return this.bodyHeight}checkBodyHeight(){const e=this.gridBodyCtrl.eBodyViewport,t=bA(e);this.bodyHeight!==t&&(this.bodyHeight=t,this.eventSvc.dispatchEvent({type:"bodyHeightChanged"}))}updateScrollVisibleService(){this.updateScrollVisibleServiceImpl(),setTimeout(this.updateScrollVisibleServiceImpl.bind(this),500)}updateScrollVisibleServiceImpl(){const e={horizontalScrollShowing:this.centerContainerCtrl.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleSvc.setScrollsVisible(e)}onHorizontalViewportChanged(){const e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.beans.colViewport.setScrollPosition(e,t)}};function w5(e,t,r,n,i,o){if(r==null&&t==null)return;const s={},a={},l=(c,u)=>{c.split(" ").forEach(d=>{d.trim()!=""&&u(d)})};if(r){const c=Object.keys(r);for(let u=0;u{p?s[f]=!0:a[f]=!0})}}t&&o&&Object.keys(t).forEach(c=>l(c,u=>{s[u]||(a[u]=!0)})),o&&Object.keys(a).forEach(o),Object.keys(s).forEach(i)}function NY(e){if(e.group)return e.level;const t=e.parent;return t?t.level+1:0}var Yje=class extends xe{constructor(){super(...arguments),this.beanName="rowStyleSvc"}processClassesFromGridOptions(e,t){const r=this.gos,n=s=>{typeof s=="string"?e.push(s):Array.isArray(s)&&s.forEach(a=>e.push(a))},i=r.get("rowClass");i&&n(i);const o=r.getCallback("getRowClass");if(o){const s={data:t.data,node:t,rowIndex:t.rowIndex},a=o(s);n(a)}}preProcessRowClassRules(e,t){this.processRowClassRules(t,r=>{e.push(r)},()=>{})}processRowClassRules(e,t,r){const{gos:n,expressionSvc:i}=this.beans,o=n.addGridCommonParams({data:e.data,node:e,rowIndex:e.rowIndex});w5(i,void 0,n.get("rowClassRules"),o,t,r)}processStylesFromGridOptions(e){const t=this.gos,r=t.get("rowStyle"),n=t.getCallback("getRowStyle");let i;if(n){const o={data:e.data,node:e,rowIndex:e.rowIndex};i=n(o)}if(i||r)return Object.assign({},r,i)}},Zje=0,B0="renderedRow",wV=class extends xe{constructor(e,t,r,n,i){var o;super(),this.rowNode=e,this.useAnimationFrameForCreate=n,this.printLayout=i,this.allRowGuis=[],this.active=!0,this.centerCellCtrls={list:[],map:{}},this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}},this.slideInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.fadeInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.rowDragComps=[],this.lastMouseDownOnDragger=!1,this.emptyStyle={},this.updateColumnListsPending=!1,this.rowId=null,this.businessKey=null,this.beans=t,this.gos=t.gos,this.paginationPage=((o=t.pagination)==null?void 0:o.getCurrentPage())??0,this.suppressRowTransform=this.gos.get("suppressRowTransform"),this.instanceId=e.id+"-"+Zje++,this.rowId=Sn(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusSvc.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=NY(this.rowNode),this.setRowType(),this.setAnimateFlags(r),this.rowStyles=this.processStylesFromGridOptions(),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if(typeof this.businessKeyForNodeFunc!="function")return;const e=this.businessKeyForNodeFunc(this.rowNode);this.businessKey=Sn(e)}updateGui(e,t){e==="left"?this.leftGui=t:e==="right"?this.rightGui=t:e==="fullWidth"?this.fullWidthGui=t:this.centerGui=t}setComp(e,t,r,n){n=a1(this,this.beans.context,n);const i={rowComp:e,element:t,containerType:r,compBean:n};this.allRowGuis.push(i),this.updateGui(r,i),this.initialiseRowComp(i),this.rowType!=="FullWidthLoading"&&!this.rowNode.rowPinned&&this.beans.rowRenderer.dispatchFirstDataRenderedEvent()}unsetComp(e){this.allRowGuis=this.allRowGuis.filter(t=>t.containerType!==e),this.updateGui(e,void 0)}isCacheable(){return this.rowType==="FullWidthDetail"&&this.gos.get("keepDetailRows")}setCached(e){const t=e?"none":"";this.allRowGuis.forEach(r=>r.element.style.display=t)}initialiseRowComp(e){var i;const t=this.gos;this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.listenOnDomOrder(e),(i=this.beans.rowAutoHeight)==null||i.checkAutoHeights(this.rowNode),this.onRowHeightChanged(e),this.updateRowIndexes(e),this.setFocusedClasses(e),this.setStylesFromGridOptions(!1,e),Fa(t)&&this.rowNode.selectable&&this.onRowSelected(e),this.updateColumnLists(!this.useAnimationFrameForCreate);const r=e.rowComp;this.getInitialRowClasses(e.containerType).forEach(o=>r.addOrRemoveCssClass(o,!0)),this.executeSlideAndFadeAnimations(e),this.rowNode.group&&Ds(e.element,this.rowNode.expanded==!0),this.setRowCompRowId(r),this.setRowCompRowBusinessKey(r),am(t,e.element,B0,this),e.compBean.addDestroyFunc(()=>am(t,e.element,B0,null)),this.useAnimationFrameForCreate?this.beans.animationFrameSvc.createTask(this.addHoverFunctionality.bind(this,e),this.rowNode.rowIndex,"createTasksP2"):this.addHoverFunctionality(e),this.isFullWidth()&&this.setupFullWidth(e),t.get("rowDragEntireRow")&&this.addRowDraggerToRow(e),this.useAnimationFrameForCreate&&this.beans.animationFrameSvc.addDestroyTask(()=>{this.isAlive()&&e.rowComp.addOrRemoveCssClass("ag-after-created",!0)}),this.executeProcessRowPostCreateFunc()}setRowCompRowBusinessKey(e){this.businessKey!=null&&e.setRowBusinessKey(this.businessKey)}setRowCompRowId(e){const t=Sn(this.rowNode.id);this.rowId=t,t!=null&&e.setRowId(t)}executeSlideAndFadeAnimations(e){const{containerType:t}=e;this.slideInAnimation[t]&&(RY(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1),this.fadeInAnimation[t]&&(RY(()=>{e.rowComp.addOrRemoveCssClass("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){var n;const t=(n=this.beans.rowDragSvc)==null?void 0:n.createRowDragCompForRow(this.rowNode,e.element);if(!t)return;const r=this.createBean(t,this.beans.context);this.rowDragComps.push(r),e.compBean.addDestroyFunc(()=>{this.rowDragComps=this.rowDragComps.filter(i=>i!==r),this.destroyBean(r,this.beans.context)})}setupFullWidth(e){const t=this.getPinnedForContainer(e.containerType),r=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(r)}getFullWidthCellRenderers(){var e,t;return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(r=>{var n;return(n=r==null?void 0:r.rowComp)==null?void 0:n.getFullWidthCellRenderer()}):[(t=(e=this.fullWidthGui)==null?void 0:e.rowComp)==null?void 0:t.getFullWidthCellRenderer()]}executeProcessRowPostCreateFunc(){const e=this.gos.getCallback("processRowPostCreate");if(!e||!this.areAllContainersReady())return;const t={eRow:this.centerGui.element,ePinnedLeftRow:this.leftGui?this.leftGui.element:void 0,ePinnedRightRow:this.rightGui?this.rightGui.element:void 0,node:this.rowNode,rowIndex:this.rowNode.rowIndex,addRenderedRowListener:this.addEventListener.bind(this)};e(t)}areAllContainersReady(){const{leftGui:e,centerGui:t,rightGui:r,beans:{visibleCols:n}}=this,i=!!e||!n.isPinningLeft(),o=!!t,s=!!r||!n.isPinningRight();return i&&o&&s}isNodeFullWidthCell(){if(this.rowNode.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return e?e({rowNode:this.rowNode}):!1}setRowType(){const e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow")&&!this.gos.get("groupHideOpenParents"),t=this.isNodeFullWidthCell(),r=this.gos.get("masterDetail")&&this.rowNode.detail,n=this.beans.colModel.isPivotMode(),o=!!this.rowNode.group&&!this.rowNode.footer&&RA(this.gos,n);e?this.rowType="FullWidthLoading":r?this.rowType="FullWidthDetail":t?this.rowType="FullWidth":o?this.rowType="FullWidthGroup":this.rowType="Normal"}updateColumnLists(e=!1,t=!1){if(this.isFullWidth())return;const{animationFrameSvc:r}=this.beans;if(!r||e||this.gos.get("suppressAnimationFrame")||this.printLayout){this.updateColumnListsImpl(t);return}this.updateColumnListsPending||(r.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"createTasksP1"),this.updateColumnListsPending=!0)}createCellCtrls(e,t,r=null){const n={list:[],map:{}},i=(o,s)=>{n.list.push(s),n.map[o]=s};return t.forEach(o=>{const s=o.getInstanceId();let a=e.map[s];a||(a=new TP(o,this.rowNode,this.beans,this)),i(s,a)}),e.list.forEach(o=>{const s=o.column.getInstanceId();if(n.map[s]!=null)return;if(!this.isCellEligibleToBeRemoved(o,r)){i(s,o);return}o.destroy()}),n}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){this.allRowGuis.forEach(t=>{const r=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(r,e)})}getCellCtrlsForContainer(e){switch(e){case"left":return this.leftCellCtrls.list;case"right":return this.rightCellCtrls.list;case"fullWidth":return[];case"center":return this.centerCellCtrls.list}}createAllCellCtrls(){const e=this.beans.colViewport,t=this.beans.visibleCols;if(this.printLayout)this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,t.allCols),this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}};else{const r=e.getColsWithinViewport(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,r);const n=t.getLeftColsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,n,"left");const i=t.getRightColsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,i,"right")}}isCellEligibleToBeRemoved(e,t){const{column:i}=e;if(i.getPinned()!=t)return!0;const{editing:o,cellPosition:s}=e,{focusSvc:a,visibleCols:l}=this.beans,c=a.isCellFocused(s);return o||c?!(l.allCols.indexOf(i)>=0):!0}getDomOrder(){return this.gos.get("ensureDomOrder")||Eo(this.gos,"print")}listenOnDomOrder(e){const t=()=>{e.rowComp.setDomOrder(this.getDomOrder())};e.compBean.addManagedPropertyListeners(["domLayout","ensureDomOrder"],t)}setAnimateFlags(e){if(this.rowNode.sticky||!e)return;const t=Qe(this.rowNode.oldRowTop),{visibleCols:r}=this.beans,n=r.isPinningLeft(),i=r.isPinningRight();if(t){const{slideInAnimation:o}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){o.fullWidth=!0;return}o.center=!0,o.left=n,o.right=i}else{const{fadeInAnimation:o}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){o.fullWidth=!0;return}o.center=!0,o.left=n,o.right=i}}isFullWidth(){return this.rowType!=="Normal"}refreshFullWidth(){const e=(s,a)=>s?s.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(s.element,a).params):!0,t=e(this.fullWidthGui,null),r=e(this.centerGui,null),n=e(this.leftGui,"left"),i=e(this.rightGui,"right");return t&&r&&n&&i}addListeners(){var e;this.addManagedListeners(this.rowNode,{heightChanged:()=>this.onRowHeightChanged(),rowSelected:()=>this.onRowSelected(),rowIndexChanged:this.onRowIndexChanged.bind(this),topChanged:this.onTopChanged.bind(this),...((e=this.beans.expansionSvc)==null?void 0:e.getRowExpandedListeners(this))??{}}),this.rowNode.detail&&this.addManagedListeners(this.rowNode.parent,{dataChanged:this.onRowNodeDataChanged.bind(this)}),this.addManagedListeners(this.rowNode,{dataChanged:this.onRowNodeDataChanged.bind(this),cellChanged:this.postProcessCss.bind(this),rowHighlightChanged:this.onRowNodeHighlightChanged.bind(this),draggingChanged:this.postProcessRowDragging.bind(this),uiLevelChanged:this.onUiLevelChanged.bind(this)}),this.addManagedListeners(this.beans.eventSvc,{paginationPixelOffsetChanged:this.onPaginationPixelOffsetChanged.bind(this),heightScaleChanged:this.onTopChanged.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),virtualColumnsChanged:this.onVirtualColumnsChanged.bind(this),cellFocused:this.onCellFocusChanged.bind(this),cellFocusCleared:this.onCellFocusChanged.bind(this),paginationChanged:this.onPaginationChanged.bind(this),modelUpdated:this.refreshFirstAndLastRowStyles.bind(this),columnMoved:()=>this.updateColumnLists()}),this.addDestroyFunc(()=>{this.rowDragComps=this.destroyBeans(this.rowDragComps,this.beans.context),this.tooltipFeature=this.destroyBean(this.tooltipFeature,this.beans.context)}),this.addManagedPropertyListeners(["rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules"],this.postProcessCss.bind(this)),this.addManagedPropertyListener("rowDragEntireRow",()=>{if(this.gos.get("rowDragEntireRow")){this.allRowGuis.forEach(r=>{this.addRowDraggerToRow(r)});return}this.rowDragComps=this.destroyBeans(this.rowDragComps,this.beans.context)}),this.addListenersForCellComps()}addListenersForCellComps(){this.addManagedListeners(this.rowNode,{rowIndexChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onRowIndexChanged())},cellChanged:e=>{this.getAllCellCtrls().forEach(t=>t.onCellChanged(e))}})}onRowNodeDataChanged(e){if(this.isFullWidth()!==!!this.isNodeFullWidthCell()){this.beans.rowRenderer.redrawRow(this.rowNode);return}if(this.isFullWidth()){this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode);return}this.getAllCellCtrls().forEach(r=>r.refreshCell({suppressFlash:!e.update,newData:!e.update})),this.allRowGuis.forEach(r=>{this.setRowCompRowId(r.rowComp),this.updateRowBusinessKey(),this.setRowCompRowBusinessKey(r.rowComp)}),this.onRowSelected(),this.postProcessCss()}postProcessCss(){this.setStylesFromGridOptions(!0),this.postProcessClassesFromGridOptions(),this.postProcessRowClassRules(),this.postProcessRowDragging()}onRowNodeHighlightChanged(){const e=this.rowNode.highlighted;this.allRowGuis.forEach(t=>{const r=e==="Above",n=e==="Below";t.rowComp.addOrRemoveCssClass("ag-row-highlight-above",r),t.rowComp.addOrRemoveCssClass("ag-row-highlight-below",n)})}postProcessRowDragging(){const e=this.rowNode.dragging;this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-dragging",e))}onDisplayedColumnsChanged(){var e;this.updateColumnLists(!0),(e=this.beans.rowAutoHeight)==null||e.checkAutoHeights(this.rowNode)}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:Ai(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}findFullWidthRowGui(e){return this.allRowGuis.find(t=>t.element.contains(e))}onKeyboardNavigate(e){const t=this.findFullWidthRowGui(e.target);if(!((t?t.element:null)===e.target))return;const i=this.rowNode,{focusSvc:o,navigation:s}=this.beans,a=o.getFocusedCell(),l={rowIndex:i.rowIndex,rowPinned:i.rowPinned,column:(a==null?void 0:a.column)??this.getColumnForFullWidth(t)};s==null||s.navigateToNextCell(e,e.key,l,!0),e.preventDefault()}onTabKeyDown(e){var a;if(e.defaultPrevented||Na(e))return;const t=this.allRowGuis.find(l=>l.element.contains(e.target)),r=t?t.element:null,n=r===e.target,i=Gr(this.beans);let o=!1;r&&i&&(o=r.contains(i)&&i.classList.contains("ag-cell"));let s=null;!n&&!o&&(s=No(this.beans,r,!1,e.shiftKey)),(this.isFullWidth()&&n||!s)&&((a=this.beans.navigation)==null||a.onTabKeyDown(this,e))}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){var t;const e=(t=this.allRowGuis.find(r=>ps(r.element)))==null?void 0:t.element;return e?e.getBoundingClientRect().top:0}onSuppressCellFocusChanged(e){const t=this.isFullWidth()&&e?void 0:-1;this.allRowGuis.forEach(r=>{vl(r.element,"tabindex",t)})}onFullWidthRowFocused(e){var i;const t=this.rowNode,r=e?this.isFullWidth()&&e.rowIndex===t.rowIndex&&e.rowPinned==t.rowPinned:!1,n=this.fullWidthGui?this.fullWidthGui.element:(i=this.centerGui)==null?void 0:i.element;n&&(n.classList.toggle("ag-full-width-focus",r),r&&(e!=null&&e.forceBrowserFocus)&&n.focus({preventScroll:!0}))}recreateCell(e){this.centerCellCtrls=this.removeCellCtrl(this.centerCellCtrls,e),this.leftCellCtrls=this.removeCellCtrl(this.leftCellCtrls,e),this.rightCellCtrls=this.removeCellCtrl(this.rightCellCtrls,e),e.destroy(),this.updateColumnLists()}removeCellCtrl(e,t){const r={list:[],map:{}};return e.list.forEach(n=>{n!==t&&(r.list.push(n),r.map[n.column.getInstanceId()]=n)}),r}onMouseEvent(e,t){switch(e){case"dblclick":this.onRowDblClick(t);break;case"click":this.onRowClick(t);break;case"touchstart":case"mousedown":this.onRowMouseDown(t);break}}createRowEvent(e,t){const{rowNode:r}=this;return this.gos.addGridCommonParams({type:e,node:r,data:r.data,rowIndex:r.rowIndex,rowPinned:r.rowPinned,event:t})}createRowEventWithSource(e,t){const r=this.createRowEvent(e,t);return r.source=this,r}onRowDblClick(e){Na(e)||this.beans.eventSvc.dispatchEvent(this.createRowEventWithSource("rowDoubleClicked",e))}getColumnForFullWidth(e){const{visibleCols:t}=this.beans;switch(e==null?void 0:e.containerType){case"center":return t.centerCols[0];case"left":return t.leftCols[0];case"right":return t.rightCols[0];default:return t.allCols[0]}}onRowMouseDown(e){if(this.lastMouseDownOnDragger=Bg(e.target,"ag-row-drag",3),!this.isFullWidth())return;const t=this.rowNode,{rangeSvc:r,focusSvc:n}=this.beans;r==null||r.removeAllCellRanges();const i=this.findFullWidthRowGui(e.target),o=i==null?void 0:i.element,s=e.target;let a=!0;o&&o.contains(s)&&n5(s)&&(a=!1),n.setFocusedCell({rowIndex:t.rowIndex,column:this.getColumnForFullWidth(i),rowPinned:t.rowPinned,forceBrowserFocus:a})}onRowClick(e){if(Na(e)||this.lastMouseDownOnDragger)return;const{eventSvc:r,selectionSvc:n}=this.beans;r.dispatchEvent(this.createRowEventWithSource("rowClicked",e)),n==null||n.handleSelectionEvent(e,this.rowNode,"rowClicked")}setupDetailRowAutoHeight(e){var t;this.rowType==="FullWidthDetail"&&((t=this.beans.masterDetailSvc)==null||t.setupDetailRowAutoHeight(this,e))}createFullWidthCompDetails(e,t){const{gos:r,rowNode:n}=this,i=r.addGridCommonParams({fullWidth:!0,data:n.data,node:n,value:n.key,valueFormatted:n.key,eGridCell:e,eParentOfValue:e,pinned:t,addRenderedRowListener:this.addEventListener.bind(this),registerRowDragger:(s,a,l,c)=>this.addFullWidthRowDragging(s,a,l,c),setTooltip:(s,a)=>{r.assertModuleRegistered("Tooltip",3),this.refreshRowTooltip(s,a)}}),o=this.beans.userCompFactory;switch(this.rowType){case"FullWidthDetail":return ije(o,i);case"FullWidthGroup":return nje(o,i);case"FullWidthLoading":return rje(o,i);default:return tje(o,i)}}refreshRowTooltip(e,t){var r;this.fullWidthGui&&(this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.refreshRowTooltip(this.tooltipFeature,this,e,t))}addFullWidthRowDragging(e,t,r="",n){const{rowDragSvc:i,context:o}=this.beans;if(!i||!this.isFullWidth())return;const s=i.createRowDragComp(()=>r,this.rowNode,void 0,e,t,n);this.createBean(s,o),this.addDestroyFunc(()=>{this.destroyBean(s,o)})}onUiLevelChanged(){const e=NY(this.rowNode);if(this.rowLevel!=e){const t="ag-row-level-"+e,r="ag-row-level-"+this.rowLevel;this.allRowGuis.forEach(n=>{n.rowComp.addOrRemoveCssClass(t,!0),n.rowComp.addOrRemoveCssClass(r,!1)})}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getLastRow()}refreshFirstAndLastRowStyles(){const e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();this.firstRowOnPage!==e&&(this.firstRowOnPage=e,this.allRowGuis.forEach(r=>r.rowComp.addOrRemoveCssClass("ag-row-first",e))),this.lastRowOnPage!==t&&(this.lastRowOnPage=t,this.allRowGuis.forEach(r=>r.rowComp.addOrRemoveCssClass("ag-row-last",t)))}getAllCellCtrls(){return this.leftCellCtrls.list.length===0&&this.rightCellCtrls.list.length===0?this.centerCellCtrls.list:[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){var t;const e=[];(t=this.beans.rowStyleSvc)==null||t.processClassesFromGridOptions(e,this.rowNode),e.length&&e.forEach(r=>{this.allRowGuis.forEach(n=>n.rowComp.addOrRemoveCssClass(r,!0))})}postProcessRowClassRules(){var e;(e=this.beans.rowStyleSvc)==null||e.processRowClassRules(this.rowNode,t=>{this.allRowGuis.forEach(r=>r.rowComp.addOrRemoveCssClass(t,!0))},t=>{this.allRowGuis.forEach(r=>r.rowComp.addOrRemoveCssClass(t,!1))})}setStylesFromGridOptions(e,t){e&&(this.rowStyles=this.processStylesFromGridOptions()),this.forEachGui(t,r=>r.rowComp.setUserStyles(this.rowStyles))}getPinnedForContainer(e){return e==="left"||e==="right"?e:null}getInitialRowClasses(e){var a;const t=this.getPinnedForContainer(e),r=this.isFullWidth(),{rowNode:n,beans:i}=this,o=[];o.push("ag-row"),o.push(this.rowFocused?"ag-row-focus":"ag-row-no-focus"),this.fadeInAnimation[e]&&o.push("ag-opacity-zero"),o.push(n.rowIndex%2===0?"ag-row-even":"ag-row-odd"),n.isRowPinned()&&o.push("ag-row-pinned"),n.isSelected()&&o.push("ag-row-selected"),n.footer&&o.push("ag-row-footer"),o.push("ag-row-level-"+this.rowLevel),n.stub&&o.push("ag-row-loading"),r&&o.push("ag-full-width-row"),(a=i.expansionSvc)==null||a.addExpandedCss(o,n),n.dragging&&o.push("ag-row-dragging");const{rowStyleSvc:s}=i;return s&&(s.processClassesFromGridOptions(o,n),s.preProcessRowClassRules(o,n)),o.push(this.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),this.isFirstRowOnPage()&&o.push("ag-row-first"),this.isLastRowOnPage()&&o.push("ag-row-last"),r&&(t==="left"&&o.push("ag-cell-last-left-pinned"),t==="right"&&o.push("ag-cell-first-right-pinned")),o}processStylesFromGridOptions(){var e;return((e=this.beans.rowStyleSvc)==null?void 0:e.processStylesFromGridOptions(this.rowNode))??this.emptyStyle}onRowSelected(e){var t;(t=this.beans.selectionSvc)==null||t.onRowCtrlSelected(this,r=>{(r===this.centerGui||r===this.fullWidthGui)&&this.announceDescription()},e)}announceDescription(){var e;(e=this.beans.selectionSvc)==null||e.announceAriaRowSelection(this.rowNode)}addHoverFunctionality(e){if(!this.active)return;const{element:t,compBean:r}=e,{rowNode:n,beans:i,gos:o}=this;r.addManagedListeners(t,{mouseenter:()=>n.dispatchRowEvent("mouseEnter"),mouseleave:()=>n.dispatchRowEvent("mouseLeave")}),r.addManagedListeners(n,{mouseEnter:()=>{var s;!((s=i.dragSvc)!=null&&s.dragging)&&!o.get("suppressRowHoverHighlight")&&(t.classList.add("ag-row-hover"),n.setHovered(!0))},mouseLeave:()=>{t.classList.remove("ag-row-hover"),n.setHovered(!1)}})}roundRowTopToBounds(e){const t=this.beans.ctrlsSvc.getScrollFeature().getApproximateVScollPosition(),r=this.applyPaginationOffset(t.top,!0)-100,n=this.applyPaginationOffset(t.bottom,!0)+100;return Math.min(Math.max(r,e),n)}forEachGui(e,t){e?t(e):this.allRowGuis.forEach(t)}onRowHeightChanged(e){if(this.rowNode.rowHeight==null)return;const t=this.rowNode.rowHeight,r=this.beans.environment.getDefaultRowHeight(),i=a5(this.gos)?ls(this.beans,this.rowNode).height:void 0,o=i?`${Math.min(r,i)-2}px`:void 0;this.forEachGui(e,s=>{s.element.style.height=`${t}px`,o&&s.element.style.setProperty("--ag-line-height",o)})}destroyFirstPass(e=!1){this.active=!1;const{rowNode:t}=this;if(!e&&Ry(this.gos)&&!t.sticky)if(t.rowTop!=null){const i=this.roundRowTopToBounds(t.rowTop);this.setRowTop(i)}else this.allRowGuis.forEach(i=>i.rowComp.addOrRemoveCssClass("ag-opacity-zero",!0));t.setHovered(!1);const r=this.createRowEvent("virtualRowRemoved");this.dispatchLocalEvent(r),this.beans.eventSvc.dispatchEvent(r),super.destroy()}destroySecondPass(){var t;this.allRowGuis.length=0,(t=this.beans.editSvc)==null||t.stopRowEditing(this);const e=r=>(r.list.forEach(n=>n.destroy()),{list:[],map:{}});this.centerCellCtrls=e(this.centerCellCtrls),this.leftCellCtrls=e(this.leftCellCtrls),this.rightCellCtrls=e(this.rightCellCtrls)}setFocusedClasses(e){this.forEachGui(e,t=>{t.rowComp.addOrRemoveCssClass("ag-row-focus",this.rowFocused),t.rowComp.addOrRemoveCssClass("ag-row-no-focus",!this.rowFocused)})}onCellFocusChanged(){const{focusSvc:e,editSvc:t}=this.beans,r=e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);r!==this.rowFocused&&(this.rowFocused=r,this.setFocusedClasses()),!r&&this.editing&&(t==null||t.stopRowEditing(this,!1))}onPaginationChanged(){var t;const e=((t=this.beans.pagination)==null?void 0:t.getCurrentPage())??0;this.paginationPage!==e&&(this.paginationPage=e,this.onTopChanged()),this.refreshFirstAndLastRowStyles()}onTopChanged(){this.setRowTop(this.rowNode.rowTop)}onPaginationPixelOffsetChanged(){this.onTopChanged()}applyPaginationOffset(e,t=!1){if(this.rowNode.isRowPinned()||this.rowNode.sticky)return e;const r=this.beans.pageBounds.getPixelOffset();return e+r*(t?1:-1)}setRowTop(e){if(!this.printLayout&&Qe(e)){const t=this.applyPaginationOffset(e),i=`${this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeight.getRealPixelPosition(t)}px`;this.setRowTopStyle(i)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){if(this.printLayout)return"";const t=this.rowNode;let r;if(t.sticky)r=t.stickyRowTop;else{const n=this.slideInAnimation[e]?this.roundRowTopToBounds(t.oldRowTop):t.rowTop,i=this.applyPaginationOffset(n);r=t.isRowPinned()?i:this.beans.rowContainerHeight.getRealPixelPosition(i)}return r+"px"}setRowTopStyle(e){this.allRowGuis.forEach(t=>this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`))}getCellCtrl(e,t=!1){let r=null;return this.getAllCellCtrls().forEach(n=>{n.column==e&&(r=n)}),r!=null||t||this.getAllCellCtrls().forEach(n=>{n.getColSpanningList().indexOf(e)>=0&&(r=n)}),r}onRowIndexChanged(){this.rowNode.rowIndex!=null&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}updateRowIndexes(e){var o,s;const t=this.rowNode.getRowIndexString();if(t===null)return;const r=(((o=this.beans.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:o.getRowCount())??0)+(((s=this.beans.filterManager)==null?void 0:s.getHeaderRowCount())??0),n=this.rowNode.rowIndex%2===0,i=r+this.rowNode.rowIndex+1;this.forEachGui(e,a=>{a.rowComp.setRowIndex(t),a.rowComp.addOrRemoveCssClass("ag-row-even",n),a.rowComp.addOrRemoveCssClass("ag-row-odd",!n),J4(a.element,i)})}};function x5(e){var r;return e.altKey||e.ctrlKey||e.metaKey?!1:((r=e.key)==null?void 0:r.length)===1}function xV(e,t,r,n,i){const o=n?n.getColDef().suppressKeyboardEvent:void 0;if(!o)return!1;const s=e.addGridCommonParams({event:t,editing:i,column:n,node:r,data:r.data,colDef:n.getColDef()});return!!(o&&o(s))}var Qje=65,Jje=67,eKe=86,tKe=68,rKe=90,nKe=89;function iKe(e){const{keyCode:t}=e;let r;switch(t){case Qje:r=ge.A;break;case Jje:r=ge.C;break;case eKe:r=ge.V;break;case tKe:r=ge.D;break;case rKe:r=ge.Z;break;case nKe:r=ge.Y;break;default:r=e.code}return r}var oKe=class extends xe{constructor(e){super(),this.element=e}postConstruct(){var e;this.addKeyboardListeners(),this.addMouseListeners(),(e=this.beans.touchSvc)==null||e.mockRowContextMenu(this)}addKeyboardListeners(){const e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})}addMouseListeners(){["dblclick","contextmenu","mouseover","mouseout","click",Npe("touchstart")?"touchstart":"mousedown"].forEach(r=>{const n=this.processMouseEvent.bind(this,r);this.addManagedElementListeners(this.element,{[r]:n})})}processMouseEvent(e,t){var i;if(!iI(this.gos,t)||Na(t))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);e==="contextmenu"?(r!=null&&r.column&&r.dispatchCellContextMenuEvent(t),(i=this.beans.contextMenuSvc)==null||i.handleContextMenuMouseEvent(t,void 0,n,r)):(r&&r.onMouseEvent(e,t),n&&n.onMouseEvent(e,t))}getControlsForEventTarget(e){const{gos:t}=this;return{cellCtrl:v5(t,e),rowCtrl:Bpe(t,e,B0)}}processKeyboardEvent(e,t){const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);t.defaultPrevented||(r?this.processCellKeyboardEvent(r,e,t):n&&n.isFullWidth()&&this.processFullWidthRowKeyboardEvent(n,e,t))}processCellKeyboardEvent(e,t,r){var a;const{rowNode:n,column:i,editing:o}=e;!xV(this.gos,r,n,i,o)&&t==="keydown"&&(!o&&((a=this.beans.navigation)!=null&&a.handlePageScrollingKey(r))||e.onKeyDown(r),this.doGridOperations(r,e.editing),x5(r)&&e.processCharacter(r)),t==="keydown"&&this.eventSvc.dispatchEvent(e.createEvent(r,"cellKeyDown"))}processFullWidthRowKeyboardEvent(e,t,r){const{rowNode:n}=e,{focusSvc:i,navigation:o}=this.beans,s=i.getFocusedCell(),a=s&&s.column;if(!xV(this.gos,r,n,a,!1)){const c=r.key;if(t==="keydown")switch(c){case ge.PAGE_HOME:case ge.PAGE_END:case ge.PAGE_UP:case ge.PAGE_DOWN:o==null||o.handlePageScrollingKey(r,!0);break;case ge.UP:case ge.DOWN:e.onKeyboardNavigate(r);break;case ge.TAB:e.onTabKeyDown(r);break}}t==="keydown"&&this.eventSvc.dispatchEvent(e.createRowEvent("cellKeyDown",r))}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey||t||!iI(this.gos,e))return;const r=iKe(e),{clipboardSvc:n,undoRedo:i}=this.beans;if(r===ge.A)return this.onCtrlAndA(e);if(r===ge.C)return this.onCtrlAndC(n,e);if(r===ge.D)return this.onCtrlAndD(n,e);if(r===ge.V)return this.onCtrlAndV(n,e);if(r===ge.X)return this.onCtrlAndX(n,e);if(r===ge.Y)return this.onCtrlAndY(i);if(r===ge.Z)return this.onCtrlAndZ(i,e)}onCtrlAndA(e){const{beans:{pinnedRowModel:t,rowModel:r,visibleCols:n,rangeSvc:i,selectionSvc:o},gos:s}=this;if(i&&Rs(s)&&r.isRowsToRender()){const[a,l]=[(t==null?void 0:t.isEmpty("top"))??!0,(t==null?void 0:t.isEmpty("bottom"))??!0],c=a?null:"top";let u,d;l?(u=null,d=r.getRowCount()-1):(u="bottom",d=(t==null?void 0:t.getPinnedBottomRowCount())??-1);const h=n.allCols;if(!(h!=null&&h.length))return;i.setCellRange({rowStartIndex:0,rowStartPinned:c,rowEndIndex:d,rowEndPinned:u,columnStart:h[0],columnEnd:er(h)})}else o&&(o==null||o.selectAllRowNodes({source:"keyboardSelectAll",selectAll:Lpe(s)}));e.preventDefault()}onCtrlAndC(e,t){if(!e||this.gos.get("enableCellTextSelection"))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||(t.preventDefault(),e.copyToClipboard())}onCtrlAndX(e,t){if(!e||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||(t.preventDefault(),e.cutToClipboard(void 0,"ui"))}onCtrlAndV(e,t){const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||e&&!this.gos.get("suppressClipboardPaste")&&e.pasteFromClipboard()}onCtrlAndD(e,t){e&&!this.gos.get("suppressClipboardPaste")&&e.copyRangeDown(),t.preventDefault()}onCtrlAndZ(e,t){!this.gos.get("undoRedoCellEditing")||!e||(t.preventDefault(),t.shiftKey?e.redo("ui"):e.undo("ui"))}onCtrlAndY(e){e==null||e.redo("ui")}},_fe=class extends xe{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedEventListeners({rowContainerHeightChanged:this.onHeightChanged.bind(this,this.beans.rowContainerHeight)})}onHeightChanged(e){const t=e.uiContainerHeight,r=t!=null?`${t}px`:"";this.eContainer.style.height=r,this.eViewport&&(this.eViewport.style.height=r)}},ET=e=>e.topRowCtrls,TT=e=>e.getStickyTopRowCtrls(),RT=e=>e.getStickyBottomRowCtrls(),PT=e=>e.bottomRowCtrls,MT=e=>e.allRowCtrls,sKe={center:{type:"center",container:"ag-center-cols-container",viewport:"ag-center-cols-viewport",getRowCtrls:MT},left:{type:"left",container:"ag-pinned-left-cols-container",pinnedType:"left",getRowCtrls:MT},right:{type:"right",container:"ag-pinned-right-cols-container",pinnedType:"right",getRowCtrls:MT},fullWidth:{type:"fullWidth",container:"ag-full-width-container",fullWidth:!0,getRowCtrls:MT},topCenter:{type:"center",container:"ag-floating-top-container",viewport:"ag-floating-top-viewport",getRowCtrls:ET},topLeft:{type:"left",container:"ag-pinned-left-floating-top",pinnedType:"left",getRowCtrls:ET},topRight:{type:"right",container:"ag-pinned-right-floating-top",pinnedType:"right",getRowCtrls:ET},topFullWidth:{type:"fullWidth",container:"ag-floating-top-full-width-container",fullWidth:!0,getRowCtrls:ET},stickyTopCenter:{type:"center",container:"ag-sticky-top-container",viewport:"ag-sticky-top-viewport",getRowCtrls:TT},stickyTopLeft:{type:"left",container:"ag-pinned-left-sticky-top",pinnedType:"left",getRowCtrls:TT},stickyTopRight:{type:"right",container:"ag-pinned-right-sticky-top",pinnedType:"right",getRowCtrls:TT},stickyTopFullWidth:{type:"fullWidth",container:"ag-sticky-top-full-width-container",fullWidth:!0,getRowCtrls:TT},stickyBottomCenter:{type:"center",container:"ag-sticky-bottom-container",viewport:"ag-sticky-bottom-viewport",getRowCtrls:RT},stickyBottomLeft:{type:"left",container:"ag-pinned-left-sticky-bottom",pinnedType:"left",getRowCtrls:RT},stickyBottomRight:{type:"right",container:"ag-pinned-right-sticky-bottom",pinnedType:"right",getRowCtrls:RT},stickyBottomFullWidth:{type:"fullWidth",container:"ag-sticky-bottom-full-width-container",fullWidth:!0,getRowCtrls:RT},bottomCenter:{type:"center",container:"ag-floating-bottom-container",viewport:"ag-floating-bottom-viewport",getRowCtrls:PT},bottomLeft:{type:"left",container:"ag-pinned-left-floating-bottom",pinnedType:"left",getRowCtrls:PT},bottomRight:{type:"right",container:"ag-pinned-right-floating-bottom",pinnedType:"right",getRowCtrls:PT},bottomFullWidth:{type:"fullWidth",container:"ag-floating-bottom-full-width-container",fullWidth:!0,getRowCtrls:PT}};function wg(e){return sKe[e]}var aKe=["topCenter","topLeft","topRight"],lKe=["bottomCenter","bottomLeft","bottomRight"],cKe=["center","left","right"],uKe=["center","left","right","fullWidth"],dKe=["stickyTopCenter","stickyBottomCenter","center","topCenter","bottomCenter"],hKe=["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],pKe=["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],Ofe=["stickyTopCenter","stickyTopLeft","stickyTopRight"],kfe=["stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],fKe=[...Ofe,"stickyTopFullWidth",...kfe,"stickyBottomFullWidth"],gKe=[...aKe,...lKe,...cKe,...Ofe,...kfe],Nfe=class extends xe{constructor(e){super(),this.name=e,this.visible=!0,this.EMPTY_CTRLS=[],this.options=wg(e)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>{this.viewportSizeFeature=this.createManagedBean(new Xje(this)),this.addManagedEventListeners({stickyTopOffsetChanged:this.onStickyTopOffsetChanged.bind(this)})})}onStickyTopOffsetChanged(e){this.comp.setOffsetTop(`${e.offset}px`)}registerWithCtrlsService(){this.options.fullWidth||this.beans.ctrlsSvc.register(this.name,this)}forContainers(e,t){e.indexOf(this.name)>=0&&t()}setComp(e,t,r){this.comp=e,this.eContainer=t,this.eViewport=r,this.createManagedBean(new oKe(this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder();const{pinnedCols:n,rangeSvc:i}=this.beans,o=()=>this.onPinnedWidthChanged();this.forContainers(hKe,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(n==null?void 0:n.createPinnedWidthFeature(this.eContainer,!0)),this.addManagedEventListeners({leftPinnedWidthChanged:o})}),this.forContainers(pKe,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(n==null?void 0:n.createPinnedWidthFeature(this.eContainer,!1)),this.addManagedEventListeners({rightPinnedWidthChanged:o})}),this.forContainers(uKe,()=>this.createManagedBean(new _fe(this.eContainer,this.name==="center"?r:void 0))),i&&this.forContainers(gKe,()=>this.createManagedBean(i.createDragListenerFeature(this.eContainer))),this.forContainers(dKe,()=>this.createManagedBean(new S5(s=>this.comp.setContainerWidth(`${s}px`)))),this.visible=this.isContainerVisible(),this.addListeners(),this.registerWithCtrlsService()}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}addListeners(){this.addManagedEventListeners({displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),displayedColumnsWidthChanged:this.onDisplayedColumnsChanged.bind(this),displayedRowsChanged:e=>this.onDisplayedRowsChanged(e.afterScroll)}),this.onDisplayedColumnsChanged(),this.onDisplayedRowsChanged()}listenOnDomOrder(){if(fKe.indexOf(this.name)>=0){this.comp.setDomOrder(!0);return}const t=()=>{const r=this.gos.get("ensureDomOrder"),n=Eo(this.gos,"print");this.comp.setDomOrder(r||n)};this.addManagedPropertyListener("domLayout",t),t()}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){const{dragSvc:e}=this.beans;if(!e)return;const t=r=>{e.dragging&&r.cancelable&&r.preventDefault()};this.eContainer.addEventListener("touchmove",t,{passive:!1}),this.addDestroyFunc(()=>this.eContainer.removeEventListener("touchmove",t))}onHorizontalViewportChanged(e=!1){const t=this.getCenterWidth(),r=this.getCenterViewportScrollLeft();this.beans.colViewport.setScrollPosition(t,r,e)}hasHorizontalScrollGap(){return this.eContainer.clientWidth-this.eViewport.clientWidth<0}hasVerticalScrollGap(){return this.eContainer.clientHeight-this.eViewport.clientHeight<0}getCenterWidth(){return Xy(this.eViewport)}getCenterViewportScrollLeft(){return WM(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){const t=Ga(this.beans,this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return gpe(this.eViewport)}getViewportScrollLeft(){return WM(this.eViewport,this.enableRtl)}isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||N7e(this.eViewport)}setHorizontalScroll(e){this.comp.setHorizontalScroll(e)}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){UM(this.eViewport,e,this.enableRtl)}isContainerVisible(){return!(this.options.pinnedType!=null)||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){const e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){const t=this.options.getRowCtrls(this.beans.rowRenderer);if(!this.visible||t.length===0){this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});return}const r=Eo(this.gos,"print"),i=this.gos.get("embedFullWidthRows")||r,o=t.filter(s=>{const a=s.isFullWidth();return this.options.fullWidth?!i&&a:i||!a});this.comp.setRowCtrls({rowCtrls:o,useFlushSync:e})}},Bfe="ag-force-vertical-scroll",mKe="ag-selectable",vKe="ag-column-moving",$fe=class extends xe{constructor(){super(...arguments),this.stickyTopHeight=0,this.stickyBottomHeight=0}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.colModel=e.colModel,this.scrollVisibleSvc=e.scrollVisibleSvc,this.pinnedRowModel=e.pinnedRowModel,this.filterManager=e.filterManager,this.rowGroupColsSvc=e.rowGroupColsSvc}setComp(e,t,r,n,i,o,s){var a,l;this.comp=e,this.eGridBody=t,this.eBodyViewport=r,this.eTop=n,this.eBottom=i,this.eStickyTop=o,this.eStickyBottom=s,this.eCenterColsViewport=r.querySelector(`.${wg("center").viewport}`),this.eFullWidthContainer=r.querySelector(`.${wg("fullWidth").container}`),this.eStickyTopFullWidthContainer=o.querySelector(`.${wg("stickyTopFullWidth").container}`),this.eStickyBottomFullWidthContainer=s.querySelector(`.${wg("stickyBottomFullWidth").container}`),this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",c=>this.setCellTextSelection(c.currentValue)),this.createManagedBean(new b5(this.comp)),this.scrollFeature=this.createManagedBean(new qje(this.eBodyViewport)),(a=this.beans.rowDragSvc)==null||a.setupRowDrag(this.eBodyViewport,this),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([n,r,i,o,s]),this.setGridRootRole(),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.updateScrollingClasses(),(l=this.filterManager)==null||l.setupAdvFilterHeaderComp(n),this.ctrlsSvc.register("gridBodyCtrl",this)}addEventListeners(){const e=this.setFloatingHeights.bind(this),t=this.setGridRootRole.bind(this);this.addManagedEventListeners({gridColumnsChanged:this.onGridColumnsChanged.bind(this),scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this),scrollGapChanged:this.updateScrollingClasses.bind(this),pinnedRowDataChanged:e,pinnedHeightChanged:e,headerHeightChanged:this.setStickyTopOffsetTop.bind(this),columnRowGroupChanged:t,columnPivotChanged:t}),this.addManagedPropertyListener("treeData",t)}onGridColumnsChanged(){const e=this.beans.colModel.getCols();this.comp.setColumnCount(e.length)}onScrollVisibilityChanged(){const{scrollVisibleSvc:e}=this,t=e.verticalScrollShowing;this.setVerticalScrollPaddingVisible(t),this.setStickyWidth(t),this.setStickyBottomOffsetBottom();const r=t&&e.getScrollbarWidth()||0,n=dpe()?16:0,i=`calc(100% + ${r+n}px)`;Tl(this.beans,()=>this.comp.setBodyViewportWidth(i)),this.updateScrollingClasses()}setGridRootRole(){const{rowGroupColsSvc:e,colModel:t}=this;let r=this.gos.get("treeData");if(!r){const n=t.isPivotMode();r=(e?e.columns.length:0)>=(n?2:1)}this.comp.setGridRootRole(r?"treegrid":"grid")}addFocusListeners(e){e.forEach(t=>{this.addManagedElementListeners(t,{focusin:r=>{const{target:n}=r,i=Bg(n,"ag-root",t);t.classList.toggle("ag-has-focus",!i)},focusout:r=>{const{target:n,relatedTarget:i}=r,o=t.contains(i),s=Bg(i,"ag-root",t);Bg(n,"ag-root",t)||(!o||s)&&t.classList.remove("ag-has-focus")}})})}setColumnMovingCss(e){this.comp.setColumnMovingCss(vKe,e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss(mKe,e)}updateScrollingClasses(){const{eGridBody:{classList:e},scrollVisibleSvc:t}=this;e.toggle("ag-body-vertical-content-no-gap",!t.verticalScrollGap),e.toggle("ag-body-horizontal-content-no-gap",!t.horizontalScrollGap)}disableBrowserDragging(){this.addManagedElementListeners(this.eGridBody,{dragstart:e=>{if(e.target instanceof HTMLImageElement)return e.preventDefault(),!1}})}addStopEditingWhenGridLosesFocus(){var e;(e=this.beans.editSvc)==null||e.addStopEditingWhenGridLosesFocus([this.eBodyViewport,this.eBottom,this.eTop,this.eStickyTop,this.eStickyBottom])}updateRowCount(){var i,o;const e=(((i=this.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:i.getRowCount())??0)+(((o=this.filterManager)==null?void 0:o.getHeaderRowCount())??0),{rowModel:t}=this.beans,r=t.isLastRowIndexKnown()?t.getRowCount():-1,n=r===-1?-1:e+r;this.comp.setRowCount(n)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){const t=e?"scroll":"hidden";this.comp.setPinnedTopBottomOverflowY(t)}isVerticalScrollShowing(){const e=this.gos.get("alwaysShowVerticalScroll"),t=e?Bfe:null,r=Eo(this.gos,"normal");return this.comp.setAlwaysVerticalScrollClass(t,e),e||r&&B7e(this.eBodyViewport)}setupRowAnimationCssClass(){const{rowContainerHeight:e,environment:t}=this.beans;let r=t.sizesMeasured;const n=()=>{const i=r&&Ry(this.gos)&&!e.stretching,o=i?"ag-row-animation":"ag-row-no-animation";this.comp.setRowAnimationCssOnBodyViewport(o,i)};n(),this.addManagedEventListeners({heightScaleChanged:n}),this.addManagedPropertyListener("animateRows",n),this.addManagedEventListeners({gridStylesChanged:()=>{!r&&t.sizesMeasured&&(r=!0,n())}})}addBodyViewportListener(){const{popupSvc:e,touchSvc:t}=this.beans,r=this.onBodyViewportContextMenu.bind(this);this.addManagedElementListeners(this.eBodyViewport,{contextmenu:r}),t==null||t.mockBodyContextMenu(this,r),this.addManagedElementListeners(this.eBodyViewport,{wheel:this.onBodyViewportWheel.bind(this,e)}),this.addManagedElementListeners(this.eStickyTop,{wheel:this.onStickyWheel.bind(this)}),this.addManagedElementListeners(this.eStickyBottom,{wheel:this.onStickyWheel.bind(this)}),this.addFullWidthContainerWheelListener()}addFullWidthContainerWheelListener(){this.addManagedElementListeners(this.eFullWidthContainer,{wheel:e=>this.onFullWidthContainerWheel(e)})}onFullWidthContainerWheel(e){const{deltaX:t,deltaY:r,shiftKey:n}=e;(n||Math.abs(t)>Math.abs(r))&&iI(this.gos,e)&&this.scrollGridBodyToMatchEvent(e)}onStickyWheel(e){const{deltaX:t,deltaY:r,shiftKey:n}=e,i=n||Math.abs(t)>Math.abs(r),o=e.target;i?(this.eStickyTopFullWidthContainer.contains(o)||this.eStickyBottomFullWidthContainer.contains(o))&&this.scrollGridBodyToMatchEvent(e):(e.preventDefault(),this.scrollVertically(r))}scrollGridBodyToMatchEvent(e){const{deltaX:t,deltaY:r}=e;e.preventDefault(),this.eCenterColsViewport.scrollBy({left:t||r})}onBodyViewportContextMenu(e,t,r){var i;if(!e&&!r)return;this.gos.get("preventDefaultOnContextMenu")&&(e||r).preventDefault();const{target:n}=e||t;(n===this.eBodyViewport||n===this.ctrlsSvc.get("center").eViewport)&&((i=this.beans.contextMenuSvc)==null||i.showContextMenu({mouseEvent:e,touchEvent:r,value:null,anchorToElement:this.eGridBody}))}onBodyViewportWheel(e,t){this.gos.get("suppressScrollWhenPopupsAreOpen")&&e!=null&&e.hasAnchoredPopup()&&t.preventDefault()}scrollVertically(e){const t=this.eBodyViewport.scrollTop;return this.scrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}setFloatingHeights(){const{pinnedRowModel:e}=this,t=(e==null?void 0:e.getPinnedTopTotalHeight())??0,r=(e==null?void 0:e.getPinnedBottomTotalHeight())??0;this.comp.setTopHeight(t),this.comp.setBottomHeight(r),this.comp.setTopDisplay(t?"inherit":"none"),this.comp.setBottomDisplay(r?"inherit":"none"),this.setStickyTopOffsetTop(),this.setStickyBottomOffsetBottom()}setStickyTopHeight(e=0){this.comp.setStickyTopHeight(`${e}px`),this.stickyTopHeight=e}setStickyBottomHeight(e=0){this.comp.setStickyBottomHeight(`${e}px`),this.stickyBottomHeight=e}setStickyWidth(e){if(!e)this.comp.setStickyTopWidth("100%"),this.comp.setStickyBottomWidth("100%");else{const t=this.scrollVisibleSvc.getScrollbarWidth();this.comp.setStickyTopWidth(`calc(100% - ${t}px)`),this.comp.setStickyBottomWidth(`calc(100% - ${t}px)`)}}setStickyTopOffsetTop(){var i,o;const t=this.ctrlsSvc.get("gridHeaderCtrl").headerHeight+(((i=this.filterManager)==null?void 0:i.getHeaderHeight())??0),r=((o=this.pinnedRowModel)==null?void 0:o.getPinnedTopTotalHeight())??0;let n=0;t>0&&(n+=t),r>0&&(n+=r),n>0&&(n+=1),this.comp.setStickyTopTop(`${n}px`)}setStickyBottomOffsetBottom(){const{pinnedRowModel:e,scrollVisibleSvc:t,comp:r}=this,n=(e==null?void 0:e.getPinnedBottomTotalHeight())??0,o=t.horizontalScrollShowing&&t.getScrollbarWidth()||0,s=n+o;r.setStickyBottomBottom(`${s}px`)}},Gfe=class extends Je{constructor(e,t){super(),this.direction=t,this.eViewport=Ce,this.eContainer=Ce,this.hideTimeout=0,this.setTemplate(e)}postConstruct(){this.addManagedEventListeners({scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this)}),this.onScrollVisibilityChanged(),this.addOrRemoveCssClass("ag-apple-scrollbar",cpe()||fp())}destroy(){super.destroy(),window.clearTimeout(this.hideTimeout)}initialiseInvisibleScrollbar(){this.invisibleScrollbar===void 0&&(this.invisibleScrollbar=dpe(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles()))}addActiveListenerToggles(){const e=this.getGui(),t=()=>this.addOrRemoveCssClass("ag-scrollbar-active",!0),r=()=>this.addOrRemoveCssClass("ag-scrollbar-active",!1);this.addManagedListeners(e,{mouseenter:t,mousedown:t,touchstart:t,mouseleave:r,touchend:r})}onScrollVisibilityChanged(){this.invisibleScrollbar===void 0&&this.initialiseInvisibleScrollbar(),Tl(this.beans,()=>this.setScrollVisible())}hideAndShowInvisibleScrollAsNeeded(){this.addManagedEventListeners({bodyScroll:e=>{e.direction===this.direction&&(this.hideTimeout&&(window.clearTimeout(this.hideTimeout),this.hideTimeout=0),this.addOrRemoveCssClass("ag-scrollbar-scrolling",!0))},bodyScrollEnd:()=>{this.hideTimeout=window.setTimeout(()=>{this.addOrRemoveCssClass("ag-scrollbar-scrolling",!1),this.hideTimeout=0},400)}})}attemptSettingScrollPosition(e){const t=this.eViewport;wpe(()=>ps(t),()=>this.setScrollPosition(e),100)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}},Vfe=class extends Gfe{constructor(){super(``,"horizontal"),this.eLeftSpacer=Ce,this.eRightSpacer=Ce,this.setScrollVisibleDebounce=0}wireBeans(e){this.visibleCols=e.visibleCols,this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){super.postConstruct();const e=this.setFakeHScrollSpacerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e,pinnedRowDataChanged:this.refreshCompBottom.bind(this)}),this.addManagedPropertyListener("domLayout",e),this.beans.ctrlsSvc.register("fakeHScrollComp",this),this.createManagedBean(new S5(t=>this.eContainer.style.width=`${t}px`)),this.addManagedPropertyListeners(["suppressHorizontalScroll"],this.onScrollVisibilityChanged.bind(this))}destroy(){window.clearTimeout(this.setScrollVisibleDebounce),super.destroy()}initialiseInvisibleScrollbar(){this.invisibleScrollbar===void 0&&(this.enableRtl=this.gos.get("enableRtl"),super.initialiseInvisibleScrollbar(),this.invisibleScrollbar&&this.refreshCompBottom())}refreshCompBottom(){var t;if(!this.invisibleScrollbar)return;const e=((t=this.beans.pinnedRowModel)==null?void 0:t.getPinnedBottomTotalHeight())??0;this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){const e=this.scrollVisibleSvc.verticalScrollShowing;let t=this.visibleCols.getDisplayedColumnsRightWidth();const r=!this.enableRtl&&e,n=this.scrollVisibleSvc.getScrollbarWidth();r&&(t+=n),sc(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=n);let i=this.visibleCols.getColsLeftWidth();this.enableRtl&&e&&(i+=n),sc(this.eLeftSpacer,i),this.eLeftSpacer.classList.toggle("ag-scroller-corner",i<=n)}setScrollVisible(){const e=this.scrollVisibleSvc.horizontalScrollShowing,t=this.invisibleScrollbar,r=this.gos.get("suppressHorizontalScroll"),n=e&&this.scrollVisibleSvc.getScrollbarWidth()||0,o=r?0:n===0&&t?16:n,s=()=>{this.setScrollVisibleDebounce=0,this.addOrRemoveCssClass("ag-scrollbar-invisible",t),Gw(this.getGui(),o),Gw(this.eViewport,o),Gw(this.eContainer,o),this.setDisplayed(e,{skipAriaHidden:!0})};window.clearTimeout(this.setScrollVisibleDebounce),e?this.setScrollVisibleDebounce=window.setTimeout(s,100):s()}getScrollPosition(){return WM(this.eViewport,this.enableRtl)}setScrollPosition(e){ps(this.eViewport)||this.attemptSettingScrollPosition(e),UM(this.eViewport,e,this.enableRtl)}},yKe={selector:"AG-FAKE-HORIZONTAL-SCROLL",component:Vfe},zfe=class extends Gfe{constructor(){super(``,"vertical")}postConstruct(){super.postConstruct(),this.createManagedBean(new _fe(this.eContainer));const{ctrlsSvc:e}=this.beans;e.register("fakeVScrollComp",this),this.addManagedEventListeners({rowContainerHeightChanged:this.onRowContainerHeightChanged.bind(this,e)})}setScrollVisible(){const{scrollVisibleSvc:e}=this.beans,t=e.verticalScrollShowing,r=this.invisibleScrollbar,n=t&&e.getScrollbarWidth()||0,i=n===0&&r?16:n;this.addOrRemoveCssClass("ag-scrollbar-invisible",r),sc(this.getGui(),i),sc(this.eViewport,i),sc(this.eContainer,i),this.setDisplayed(t,{skipAriaHidden:!0})}onRowContainerHeightChanged(e){const r=e.getGridBodyCtrl().eBodyViewport,n=this.getScrollPosition(),i=r.scrollTop;n!=i&&this.setScrollPosition(i,!0)}getScrollPosition(){return this.eViewport.scrollTop}setScrollPosition(e,t){!t&&!ps(this.eViewport)&&this.attemptSettingScrollPosition(e),this.eViewport.scrollTop=e}},CKe={selector:"AG-FAKE-VERTICAL-SCROLL",component:zfe};function Hfe(e){return e.cols?e.cols.treeDepth+1:-1}function dd(e){var t;return((t=e.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:t.getRowCount())??0}function E5(e){const t=[],r=e.ctrlsSvc.getHeaderRowContainerCtrls();for(const n of r){if(!n)continue;const i=n.getGroupRowCount()||0;for(let o=0;oa)&&(t[o]=l)}}}return t}function bKe(e,t){const r=e.colModel.isPivotMode()?wKe(e):Wfe(e);let n=0;const i=t.getHeaderCtrls();for(const o of i){const{column:s}=o;if(s.isAutoHeaderHeight()){const a=s.getAutoHeaderHeight();a!=null&&a>n&&(n=a)}}return Math.max(r,n)}function T5(e){const t=e.colModel.isPivotMode()?SKe(e):c1(e),n=e.visibleCols.allCols.filter(i=>i.isAutoHeaderHeight()).map(i=>i.getAutoHeaderHeight()||0);return Math.max(t,...n)}function c1(e){return e.gos.get("headerHeight")??e.environment.getDefaultHeaderHeight()}function R5(e){return e.gos.get("floatingFiltersHeight")??c1(e)}function Wfe(e){return e.gos.get("groupHeaderHeight")??c1(e)}function SKe(e){return e.gos.get("pivotHeaderHeight")??c1(e)}function wKe(e){return e.gos.get("pivotGroupHeaderHeight")??Wfe(e)}var Ufe=class extends xe{setComp(e,t,r){this.comp=e,this.eGui=t;const{beans:n}=this,{headerNavigation:i,touchSvc:o,ctrlsSvc:s}=n;i&&this.createManagedBean(new qp(r,{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addManagedEventListeners({columnPivotModeChanged:this.onPivotModeChanged.bind(this,n),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this,n)}),this.onPivotModeChanged(n),this.setupHeaderHeight();const a=this.onHeaderContextMenu.bind(this);this.addManagedElementListeners(this.eGui,{contextmenu:a}),o==null||o.mockHeaderContextMenu(this,a),s.register("gridHeaderCtrl",this)}setupHeaderHeight(){const e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],e),this.addManagedEventListeners({displayedColumnsChanged:e,columnHeaderHeightChanged:e,columnGroupHeaderHeightChanged:()=>Tl(this.beans,()=>e()),gridStylesChanged:e,advancedFilterEnabledChanged:e})}setHeaderHeight(){var o;const{beans:e}=this;let t=0;const r=E5(e).reduce((s,a)=>s+a,0),n=T5(e);if((o=e.filterManager)!=null&&o.hasFloatingFilters()&&(t+=R5(e)),t+=r,t+=n,this.headerHeight===t)return;this.headerHeight=t;const i=`${t+1}px`;this.comp.setHeightAndMinHeight(i),this.eventSvc.dispatchEvent({type:"headerHeightChanged"})}onPivotModeChanged(e){const t=e.colModel.isPivotMode();this.comp.addOrRemoveCssClass("ag-pivot-on",t),this.comp.addOrRemoveCssClass("ag-pivot-off",!t)}onDisplayedColumnsChanged(e){const r=e.visibleCols.allCols.some(n=>n.isSpanHeaderHeight());this.comp.addOrRemoveCssClass("ag-header-allow-overflow",r)}onTabKeyDown(e){const t=this.gos.get("enableRtl"),r=e.shiftKey,n=r!==t?"LEFT":"RIGHT",{beans:i}=this,{headerNavigation:o,focusSvc:s}=i;(o.navigateHorizontally(n,!0,e)||!r&&s.focusOverlay(!1)||Ld(i,r,!0))&&e.preventDefault()}handleKeyDown(e){let t=null;const{headerNavigation:r}=this.beans;switch(e.key){case ge.LEFT:t="LEFT";case ge.RIGHT:{Qe(t)||(t="RIGHT"),r.navigateHorizontally(t,!1,e)&&e.preventDefault();break}case ge.UP:t="UP";case ge.DOWN:{Qe(t)||(t="DOWN"),r.navigateVertically(t,null,e)&&e.preventDefault();break}default:return}}onFocusOut(e){const{relatedTarget:t}=e,{eGui:r,beans:n}=this;!t&&r.contains(Gr(n))||r.contains(t)||(n.focusSvc.focusedHeader=null)}onHeaderContextMenu(e,t,r){var s;const{menuSvc:n,ctrlsSvc:i}=this.beans;if(!e&&!r||!(n!=null&&n.isHeaderContextMenuEnabled()))return;const{target:o}=e??t;(o===this.eGui||o===((s=i.getHeaderRowContainerCtrl())==null?void 0:s.eViewport))&&n.showHeaderContextMenu(void 0,e,r)}},P5=class extends Je{constructor(e,t){super(e),this.ctrl=t}getCtrl(){return this.ctrl}},xKe=class extends P5{constructor(t){super(`
`,t),this.eResize=Ce,this.eHeaderCompWrapper=Ce,this.headerCompVersion=0}postConstruct(){const t=this.getGui();((o,s)=>{s!=null&&s!=""?t.setAttribute(o,s):t.removeAttribute(o)})("col-id",this.ctrl.column.getColId());const n={setWidth:o=>t.style.width=o,addOrRemoveCssClass:(o,s)=>this.addOrRemoveCssClass(o,s),setAriaSort:o=>o?ipe(t,o):ope(t),setUserCompDetails:o=>this.setUserCompDetails(o),getUserCompInstance:()=>this.headerComp};this.ctrl.setComp(n,this.getGui(),this.eResize,this.eHeaderCompWrapper,void 0);const i=this.ctrl.getSelectAllGui();i&&this.eResize.insertAdjacentElement("afterend",i)}destroy(){this.destroyHeaderComp(),super.destroy()}destroyHeaderComp(){this.headerComp&&(this.eHeaderCompWrapper.removeChild(this.headerCompGui),this.headerComp=this.destroyBean(this.headerComp),this.headerCompGui=void 0)}setUserCompDetails(t){this.headerCompVersion++;const r=this.headerCompVersion;t.newAgStackInstance().then(n=>this.afterCompCreated(r,n))}afterCompCreated(t,r){if(t!=this.headerCompVersion||!this.isAlive()){this.destroyBean(r);return}this.destroyHeaderComp(),this.headerComp=r,this.headerCompGui=r.getGui(),this.eHeaderCompWrapper.appendChild(this.headerCompGui),this.ctrl.setDragSource(this.getGui())}},EKe=class extends P5{constructor(t){super(`
`,t),this.eResize=Ce,this.eHeaderCompWrapper=Ce}postConstruct(){const t=this.getGui(),r=(i,o)=>o!=null?t.setAttribute(i,o):t.removeAttribute(i);t.setAttribute("col-id",this.ctrl.column.getUniqueId());const n={addOrRemoveCssClass:(i,o)=>this.addOrRemoveCssClass(i,o),setHeaderWrapperHidden:i=>{i?this.eHeaderCompWrapper.style.setProperty("display","none"):this.eHeaderCompWrapper.style.removeProperty("display")},setHeaderWrapperMaxHeight:i=>{i!=null?this.eHeaderCompWrapper.style.setProperty("max-height",`${i}px`):this.eHeaderCompWrapper.style.removeProperty("max-height"),this.eHeaderCompWrapper.classList.toggle("ag-header-cell-comp-wrapper-limited-height",i!=null)},setResizableDisplayed:i=>Pt(this.eResize,i),setWidth:i=>t.style.width=i,setAriaExpanded:i=>r("aria-expanded",i),setUserCompDetails:i=>this.setUserCompDetails(i),getUserCompInstance:()=>this.headerGroupComp};this.ctrl.setComp(n,t,this.eResize,this.eHeaderCompWrapper,void 0)}setUserCompDetails(t){t.newAgStackInstance().then(r=>this.afterHeaderCompCreated(r))}afterHeaderCompCreated(t){const r=()=>this.destroyBean(t);if(!this.isAlive()){r();return}const n=this.getGui(),i=t.getGui();this.eHeaderCompWrapper.appendChild(i),this.addDestroyFunc(r),this.headerGroupComp=t,this.ctrl.setDragSource(n)}addOrRemoveHeaderWrapperStyle(t,r){const{eHeaderCompWrapper:n}=this;r?n.style.setProperty(t,r):n.style.removeProperty(t)}},TKe=class extends P5{constructor(t){super(`
`,t),this.eFloatingFilterBody=Ce,this.eButtonWrapper=Ce,this.eButtonShowMainFilter=Ce}postConstruct(){const t=this.getGui(),r={addOrRemoveCssClass:(n,i)=>this.addOrRemoveCssClass(n,i),addOrRemoveBodyCssClass:(n,i)=>this.eFloatingFilterBody.classList.toggle(n,i),setButtonWrapperDisplayed:n=>Pt(this.eButtonWrapper,n),setCompDetails:n=>this.setCompDetails(n),getFloatingFilterComp:()=>this.compPromise,setWidth:n=>t.style.width=n,setMenuIcon:n=>this.eButtonShowMainFilter.appendChild(n)};this.ctrl.setComp(r,t,this.eButtonShowMainFilter,this.eFloatingFilterBody,void 0)}setCompDetails(t){if(!t){this.destroyFloatingFilterComp(),this.compPromise=null;return}this.compPromise=t.newAgStackInstance(),this.compPromise.then(r=>this.afterCompCreated(r))}destroy(){this.destroyFloatingFilterComp(),super.destroy()}destroyFloatingFilterComp(){this.floatingFilterComp&&(this.eFloatingFilterBody.removeChild(this.floatingFilterComp.getGui()),this.floatingFilterComp=this.destroyBean(this.floatingFilterComp))}afterCompCreated(t){if(t){if(!this.isAlive()){this.destroyBean(t);return}this.destroyFloatingFilterComp(),this.floatingFilterComp=t,this.eFloatingFilterBody.appendChild(t.getGui()),t.afterGuiAttached&&t.afterGuiAttached()}}},RKe=class extends Je{constructor(t){super(),this.headerComps={},this.ctrl=t,this.setTemplate(`
`)}postConstruct(){J4(this.getGui(),this.ctrl.getAriaRowIndex());const t={setHeight:r=>this.getGui().style.height=r,setTop:r=>this.getGui().style.top=r,setHeaderCtrls:(r,n)=>this.setHeaderCtrls(r,n),setWidth:r=>this.getGui().style.width=r};this.ctrl.setComp(t,void 0)}destroy(){this.setHeaderCtrls([],!1),super.destroy()}setHeaderCtrls(t,r){if(!this.isAlive())return;const n=this.headerComps;if(this.headerComps={},t.forEach(i=>{const o=i.instanceId;let s=n[o];delete n[o],s==null&&(s=this.createHeaderComp(i),this.getGui().appendChild(s.getGui())),this.headerComps[o]=s}),Object.values(n).forEach(i=>{this.getGui().removeChild(i.getGui()),this.destroyBean(i)}),r){const i=Object.values(this.headerComps);i.sort((s,a)=>{const l=s.getCtrl().column.getLeft(),c=a.getCtrl().column.getLeft();return l-c});const o=i.map(s=>s.getGui());vpe(this.getGui(),o)}}createHeaderComp(t){let r;switch(this.ctrl.type){case"group":r=new EKe(t);break;case"filter":r=new TKe(t);break;default:r=new xKe(t);break}return this.createBean(r),r.setParentComponent(this),r}},M5=class extends xe{constructor(e,t,r,n){super(),this.columnOrGroup=e,this.eCell=t,this.colsSpanning=n,this.columnOrGroup=e,this.ariaEl=t.querySelector("[role=columnheader]")||t,this.beans=r}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){const{beans:e,colsSpanning:t}=this;return e.gos.get("enableRtl")&&t?er(t):this.columnOrGroup}postConstruct(){const e=this.onLeftChanged.bind(this);this.addManagedListeners(this.columnOrGroup,{leftChanged:e}),this.setLeftFirstTime(),this.addManagedEventListeners({displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}setLeftFirstTime(){const{gos:e,colAnimation:t}=this.beans,r=e.get("suppressColumnMoveAnimation"),n=Qe(this.columnOrGroup.getOldLeft());(t==null?void 0:t.isActive())&&n&&!r?this.animateInLeft():this.onLeftChanged()}animateInLeft(){const e=this.getColumnOrGroup(),t=this.modifyLeftForPrintLayout(e,e.getOldLeft()),r=this.modifyLeftForPrintLayout(e,e.getLeft());this.setLeft(t),this.actualLeft=r,this.beans.colAnimation.executeNextVMTurn(()=>{this.actualLeft===r&&this.setLeft(r)})}onLeftChanged(){const e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){const{gos:r,visibleCols:n}=this.beans;if(!Eo(r,"print")||e.getPinned()==="left")return t;const o=n.getColsLeftWidth();if(e.getPinned()==="right"){const s=n.bodyWidth;return o+s+t}return o+t}setLeft(e){if(Qe(e)&&(this.eCell.style.left=`${e}px`),ui(this.columnOrGroup)){const t=this.columnOrGroup.getLeafColumns();if(!t.length)return;t.length>1&&npe(this.ariaEl,t.length)}}},PKe=0,jfe="headerCtrl",I5=class extends xe{constructor(e,t){super(),this.column=e,this.rowCtrl=t,this.resizeToggleTimeout=0,this.resizeMultiplier=1,this.resizeFeature=null,this.lastFocusEvent=null,this.dragSource=null,this.instanceId=e.getUniqueId()+"-"+PKe++}postConstruct(){const e=this.refreshTabIndex.bind(this);this.addManagedPropertyListeners(["suppressHeaderFocus"],e),this.addManagedEventListeners({overlayExclusiveChanged:e})}shouldStopEventPropagation(e){const{headerRowIndex:t,column:r}=this.beans.focusSvc.focusedHeader,n=r.getDefinition(),i=n&&n.suppressHeaderKeyboardEvent;if(!Qe(i))return!1;const o=this.gos.addGridCommonParams({colDef:n,column:r,headerRowIndex:t,event:e});return!!i(o)}getWrapperHasFocus(){return Gr(this.beans)===this.eGui}setGui(e,t){this.eGui=e,this.addDomData(t),t.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this)}),t.addManagedElementListeners(this.eGui,{focus:this.onGuiFocus.bind(this)}),this.onDisplayedColumnsChanged(),this.refreshTabIndex()}onGuiFocus(){this.eventSvc.dispatchEvent({type:"headerFocused",column:this.column})}setupAutoHeight(e){const{wrapperElement:t,checkMeasuringCallback:r,compBean:n}=e,{beans:i}=this,o=d=>{if(!this.isAlive()||!n.isAlive())return;const{paddingTop:h,paddingBottom:p,borderBottomWidth:f,borderTopWidth:g}=Dm(this.eGui),m=h+p+f+g,b=t.offsetHeight+m;if(d<5){const S=pn(i),x=!S||!S.contains(t),E=b==0;if(x||E){Tl(i,()=>o(d+1));return}}this.setColHeaderHeight(this.column,b)};let s=!1,a;const l=()=>{const d=this.column.isAutoHeaderHeight();d&&!s&&c(),!d&&s&&u()},c=()=>{s=!0,o(0),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!0),a=Ga(this.beans,t,()=>o(0))},u=()=>{s=!1,a&&a(),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!1),a=void 0};l(),n.addDestroyFunc(()=>u()),n.addManagedListeners(this.column,{widthChanged:()=>s&&o(0)}),n.addManagedEventListeners({sortChanged:()=>{s&&window.setTimeout(()=>o(0))}}),r&&r(l)}onDisplayedColumnsChanged(){const{comp:e,column:t,beans:r,eGui:n}=this;!e||!t||!n||(gfe(e,t,r.visibleCols),e5(n,r.visibleCols.getAriaColIndex(t)))}addResizeAndMoveKeyboardListeners(e){e.addManagedListeners(this.eGui,{keydown:this.onGuiKeyDown.bind(this),keyup:this.onGuiKeyUp.bind(this)})}refreshTabIndex(){const e=Py(this.beans);this.eGui&&vl(this.eGui,"tabindex",e?null:"-1")}onGuiKeyDown(e){var o;const t=Gr(this.beans),r=e.key===ge.LEFT||e.key===ge.RIGHT;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),t!==this.eGui||!e.shiftKey&&!e.altKey||((this.isResizing||r)&&(e.preventDefault(),e.stopImmediatePropagation()),!r))return;const i=e.key===ge.LEFT!==this.gos.get("enableRtl")?"left":"right";if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;const s=this.getViewportAdjustedResizeDiff(e);this.resizeHeader(s,e.shiftKey),(o=this.resizeFeature)==null||o.toggleColumnResizing(!0)}else this.moveHeader(i)}moveHeader(e){var t;(t=this.beans.colMoves)==null||t.moveHeader(e,this.eGui,this.column,this.rowCtrl.pinned,this)}getViewportAdjustedResizeDiff(e){const t=this.getResizeDiff(e),{pinnedCols:r}=this.beans;return r?r.getHeaderResizeDiff(t,this.column):t}getResizeDiff(e){const{gos:t,column:r}=this;let n=e.key===ge.LEFT!==t.get("enableRtl");const i=r.getPinned(),o=t.get("enableRtl");return i&&o!==(i==="right")&&(n=!n),(n?-1:1)*this.resizeMultiplier}onGuiKeyUp(){this.isResizing&&(this.resizeToggleTimeout&&(window.clearTimeout(this.resizeToggleTimeout),this.resizeToggleTimeout=0),this.isResizing=!1,this.resizeMultiplier=1,this.resizeToggleTimeout=window.setTimeout(()=>{var e;(e=this.resizeFeature)==null||e.toggleColumnResizing(!1)},150))}handleKeyDown(e){const t=this.getWrapperHasFocus();switch(e.key){case ge.PAGE_DOWN:case ge.PAGE_UP:case ge.PAGE_HOME:case ge.PAGE_END:t&&e.preventDefault()}}addDomData(e){const t=jfe,{eGui:r,gos:n}=this;am(n,r,t,this),e.addDestroyFunc(()=>am(n,r,t,null))}focus(e){const{eGui:t}=this;return t?(this.lastFocusEvent=e||null,t.focus(),!0):!1}focusThis(){this.beans.focusSvc.focusedHeader={headerRowIndex:this.rowCtrl.rowIndex,column:this.column}}removeDragSource(){var e;this.dragSource&&((e=this.beans.dragAndDrop)==null||e.removeDragSource(this.dragSource),this.dragSource=null)}handleContextMenuMouseEvent(e,t,r){const n=e??t,{menuSvc:i,gos:o}=this.beans;o.get("preventDefaultOnContextMenu")&&n.preventDefault(),i!=null&&i.isHeaderContextMenuEnabled(r)&&i.showHeaderContextMenu(r,e,t),this.dispatchColumnMouseEvent("columnHeaderContextMenu",r)}dispatchColumnMouseEvent(e,t){this.eventSvc.dispatchEvent({type:e,column:t})}setColHeaderHeight(e,t){if(!e.setAutoHeaderHeight(t))return;const{eventSvc:r}=this;e.isColumn?r.dispatchEvent({type:"columnHeaderHeightChanged",column:e,columns:[e],source:"autosizeColumnHeaderHeight"}):r.dispatchEvent({type:"columnGroupHeaderHeightChanged",columnGroup:e,source:"autosizeColumnGroupHeaderHeight"})}clearComponent(){this.removeDragSource(),this.resizeFeature=null,this.comp=null,this.eGui=null}destroy(){super.destroy(),this.column=null,this.lastFocusEvent=null,this.rowCtrl=null}},MKe=class extends I5{constructor(){super(...arguments),this.refreshFunctions={},this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map}setComp(e,t,r,n,i){this.comp=e;const{colResize:o,context:s,colHover:a}=this.beans,l=a1(this,s,i);this.setGui(t,l),this.updateState(),this.setupWidth(l),this.setupMovingCss(l),this.setupMenuClass(l),this.setupSortableClass(l),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight({wrapperElement:n,checkMeasuringCallback:u=>this.setRefreshFunction("measuring",u),compBean:l}),this.addColumnHoverListener(l),this.setupFilterClass(l),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(l),this.setupSelectAll(l),this.setupUserComp(),this.refreshAria(),o?this.resizeFeature=l.createManagedBean(o.createResizeFeature(this.rowCtrl.pinned,this.column,r,e,this)):Pt(r,!1),a==null||a.createHoverFeature(l,[this.column],t),l.createManagedBean(new M5(this.column,t,this.beans)),l.createManagedBean(new qp(t,{shouldStopEventPropagation:u=>this.shouldStopEventPropagation(u),onTabKeyDown:()=>null,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addResizeAndMoveKeyboardListeners(l),l.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader"],()=>this.refresh()),l.addManagedListeners(this.column,{colDefChanged:()=>this.refresh()}),l.addManagedListeners(this.column,{headerHighlightChanged:this.onHeaderHighlightChanged.bind(this)});const c=()=>this.checkDisplayName();l.addManagedEventListeners({columnValueChanged:c,columnRowGroupChanged:c,columnPivotChanged:c,headerHeightChanged:this.onHeaderHeightChanged.bind(this)}),l.addDestroyFunc(()=>{this.refreshFunctions={},this.selectAllFeature=null,this.dragSourceElement=void 0,this.userCompDetails=null,this.userHeaderClasses.clear(),this.ariaDescriptionProperties.clear(),this.clearComponent()})}resizeHeader(e,t){var r;(r=this.beans.colResize)==null||r.resizeHeader(this.column,e,t)}setupUserComp(){const e=this.lookupUserCompDetails();e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){const e=this.createParams(),t=this.column.getColDef();return Z9e(this.beans.userCompFactory,t,e)}createParams(){const{menuSvc:e,sortSvc:t,colFilter:r,gos:n}=this.beans;return n.addGridCommonParams({column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&!!(e!=null&&e.isHeaderFilterButtonEnabled(this.column)),enableFilterIcon:!!r&&(!this.openFilterEnabled||wo(this.gos)),showColumnMenu:o=>{e==null||e.showColumnMenu({column:this.column,buttonElement:o,positionBy:"button"})},showColumnMenuAfterMouseClick:o=>{e==null||e.showColumnMenu({column:this.column,mouseEvent:o,positionBy:"mouse"})},showFilter:o=>{e==null||e.showFilterMenu({column:this.column,buttonElement:o,containerType:"columnFilter",positionBy:"button"})},progressSort:o=>{t==null||t.progressSort(this.column,!!o,"uiColumnSorted")},setSort:(o,s)=>{t==null||t.setSortForColumn(this.column,o,!!s,"uiColumnSorted")},eGridHeader:this.eGui,setTooltip:(o,s)=>{n.assertModuleRegistered("Tooltip",3),this.setupTooltip(o,s)}})}setupSelectAll(e){const{selectionSvc:t}=this.beans;t&&(this.selectAllFeature=e.createManagedBean(t.createSelectAllFeature(this.column)),this.selectAllFeature.setComp(this))}getSelectAllGui(){var e;return(e=this.selectAllFeature)==null?void 0:e.getCheckboxGui()}handleKeyDown(e){var t;super.handleKeyDown(e),e.key===ge.SPACE&&((t=this.selectAllFeature)==null||t.onSpaceKeyDown(e)),e.key===ge.ENTER&&this.onEnterKeyDown(e),e.key===ge.DOWN&&e.altKey&&this.showMenuOnKeyPress(e,!1)}onEnterKeyDown(e){var t;e.ctrlKey||e.metaKey?this.showMenuOnKeyPress(e,!0):this.sortable&&((t=this.beans.sortSvc)==null||t.progressSort(this.column,e.shiftKey,"uiColumnSorted"))}showMenuOnKeyPress(e,t){const r=this.comp.getUserCompInstance();BY(r)&&r.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||(this.focusThis(),this.announceAriaDescription()),IA()&&this.setActiveHeader(!0)}onFocusOut(e){this.eGui.contains(e.relatedTarget)||this.setActiveHeader(!1)}setupTooltip(e,t){var r;this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.setupHeaderTooltip(this.tooltipFeature,this,e,t)}setupClassesFromColDef(){const e=()=>{const t=this.column.getColDef(),r=g5(t,this.gos,this.column,null),n=this.userHeaderClasses;this.userHeaderClasses=new Set(r),r.forEach(i=>{n.has(i)?n.delete(i):this.comp.addOrRemoveCssClass(i,!0)}),n.forEach(i=>this.comp.addOrRemoveCssClass(i,!1))};this.setRefreshFunction("headerClasses",e),e()}setDragSource(e){var t;this.dragSourceElement=e,this.removeDragSource(),!(!e||!this.draggable)&&(this.dragSource=((t=this.beans.colMoves)==null?void 0:t.setDragSourceForHeader(e,this.column,this.displayName))??null)}updateState(){const{menuSvc:e}=this.beans;this.menuEnabled=!!(e!=null&&e.isColumnMenuInHeaderEnabled(this.column)),this.openFilterEnabled=!!(e!=null&&e.isFilterMenuInHeaderEnabled(this.column)),this.sortable=this.column.isSortable(),this.displayName=this.calculateDisplayName(),this.draggable=this.workOutDraggable()}setRefreshFunction(e,t){this.refreshFunctions[e]=t}refresh(){this.updateState(),this.refreshHeaderComp(),this.refreshAria(),Object.values(this.refreshFunctions).forEach(e=>e())}refreshHeaderComp(){const e=this.lookupUserCompDetails();if(!e)return;(this.comp.getUserCompInstance()!=null&&this.userCompDetails.componentClass==e.componentClass?this.attemptHeaderCompRefresh(e.params):!1)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e)}attemptHeaderCompRefresh(e){const t=this.comp.getUserCompInstance();return!t||!t.refresh?!1:t.refresh(e)}calculateDisplayName(){return this.beans.colNames.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){const e=this.column.getColDef();return!!(!this.gos.get("suppressMovableColumns")&&!e.suppressMovable&&!e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}setupWidth(e){const t=()=>{const r=this.column.getActualWidth();this.comp.setWidth(`${r}px`)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupMovingCss(e){const t=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-moving",this.column.isMoving())};e.addManagedListeners(this.column,{movingChanged:t}),t()}setupMenuClass(e){const t=()=>{this.comp.addOrRemoveCssClass("ag-column-menu-visible",this.column.isMenuVisible())};e.addManagedListeners(this.column,{menuVisibleChanged:t}),t()}setupSortableClass(e){const t=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-sortable",!!this.sortable)};t(),this.setRefreshFunction("updateSortable",t),e.addManagedEventListeners({sortChanged:this.refreshAriaSort.bind(this)})}setupFilterClass(e){const t=()=>{const r=this.column.isFilterActive();this.comp.addOrRemoveCssClass("ag-header-cell-filtered",r),this.refreshAria()};e.addManagedListeners(this.column,{filterActiveChanged:t}),t()}setupWrapTextClass(){const e=()=>{const t=!!this.column.getColDef().wrapHeaderText;this.comp.addOrRemoveCssClass("ag-header-cell-wrap-text",t)};e(),this.setRefreshFunction("wrapText",e)}onHeaderHighlightChanged(){const e=this.column.getHighlighted(),t=e===0,r=e===1;this.comp.addOrRemoveCssClass("ag-header-highlight-before",t),this.comp.addOrRemoveCssClass("ag-header-highlight-after",r)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){const{eGui:e,column:t,comp:r,beans:n}=this,i=E5(this.beans),o=i.reduce((u,d)=>u+=d,0)===0;if(r.addOrRemoveCssClass("ag-header-parent-hidden",o),!t.isSpanHeaderHeight()){e.style.removeProperty("top"),e.style.removeProperty("height"),r.addOrRemoveCssClass("ag-header-span-height",!1),r.addOrRemoveCssClass("ag-header-span-total",!1);return}const{numberOfParents:s,isSpanningTotal:a}=this.column.getColumnGroupPaddingInfo();r.addOrRemoveCssClass("ag-header-span-height",s>0);const l=T5(n);if(s===0){r.addOrRemoveCssClass("ag-header-span-total",!1),e.style.setProperty("top","0px"),e.style.setProperty("height",`${l}px`);return}r.addOrRemoveCssClass("ag-header-span-total",a);let c=0;for(let u=0;ur==="filter"?-1:n.charCodeAt(0)-r.charCodeAt(0)).map(r=>this.ariaDescriptionProperties.get(r)).join(". ");(t=this.beans.ariaAnnounce)==null||t.announceValue(e,"columnHeader")}refreshAria(){this.refreshAriaSort(),this.refreshAriaMenu(),this.refreshAriaFilterButton(),this.refreshAriaFiltered()}addColumnHoverListener(e){var t;(t=this.beans.colHover)==null||t.addHeaderColumnHoverListener(e,this.comp,this.column)}addActiveHeaderMouseListeners(e){const t=i=>this.handleMouseOverChange(i.type==="mouseenter"),r=()=>this.dispatchColumnMouseEvent("columnHeaderClicked",this.column),n=i=>this.handleContextMenuMouseEvent(i,void 0,this.column);e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:r,contextmenu:n})}handleMouseOverChange(e){this.setActiveHeader(e),this.eventSvc.dispatchEvent({type:e?"columnHeaderMouseOver":"columnHeaderMouseLeave",column:this.column})}setActiveHeader(e){this.comp.addOrRemoveCssClass("ag-header-active",e)}getAnchorElementForMenu(e){const t=this.comp.getUserCompInstance();return BY(t)?t.getAnchorElementForMenu(e):this.eGui}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}};function BY(e){return typeof e.getAnchorElementForMenu=="function"&&typeof e.onMenuKeyboardShortcut=="function"}var IKe=0,HO=class extends xe{constructor(e,t,r){super(),this.rowIndex=e,this.pinned=t,this.type=r,this.instanceId=IKe++;const n=r=="group"?"ag-header-row-column-group":r=="filter"?"ag-header-row-column-filter":"ag-header-row-column";this.headerRowClass=`ag-header-row ${n}`}postConstruct(){this.isPrintLayout=Eo(this.gos,"print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}areCellsRendered(){return this.comp?this.getHeaderCellCtrls().every(e=>e.eGui!=null):!1}setComp(e,t,r=!0){this.comp=e,t=a1(this,this.beans.context,t),r&&(this.onRowHeightChanged(),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners(t)}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(e){const t=this.onRowHeightChanged.bind(this);e.addManagedEventListeners({columnResized:this.setWidth.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),virtualColumnsChanged:r=>this.onVirtualColumnsChanged(r.afterScroll),columnGroupHeaderHeightChanged:t,columnHeaderHeightChanged:t,gridStylesChanged:t,advancedFilterEnabledChanged:t}),e.addManagedPropertyListener("domLayout",this.onDisplayedColumnsChanged.bind(this)),e.addManagedPropertyListener("ensureDomOrder",r=>this.isEnsureDomOrder=r.currentValue),e.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],t)}getHeaderCellCtrl(e){if(this.headerCellCtrls){for(const t of this.headerCellCtrls.values())if(t.column===e)return t}}onDisplayedColumnsChanged(){this.isPrintLayout=Eo(this.gos,"print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}setWidth(){const e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){const{visibleCols:e}=this.beans;return this.isPrintLayout?this.pinned!=null?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null):e.getContainerWidth(this.pinned)}onRowHeightChanged(){const{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){const{filterManager:e}=this.beans,t=[],r=E5(this.beans),n=T5(this.beans);t.push(...r),t.push(n),e!=null&&e.hasFloatingFilters()&&t.push(R5(this.beans));let i=0;for(let s=0;s{const{focusSvc:i,visibleCols:o}=this.beans;return i.isHeaderWrapperFocused(n)?o.isVisible(n.column):!1};if(e)for(const[n,i]of e)r(i)?this.headerCellCtrls.set(n,i):this.destroyBean(i);return this.getHeaderCellCtrls()}getHeaderCellCtrls(){var e;return Array.from(((e=this.headerCellCtrls)==null?void 0:e.values())??[])}recycleAndCreateHeaderCtrls(e,t){if(!this.headerCellCtrls||e.isEmptyGroup())return;const r=e.getUniqueId();let n;if(t&&(n=t.get(r),t.delete(r)),n&&n.column!=e&&(this.destroyBean(n),n=void 0),n==null)switch(this.type){case"filter":{n=this.createBean(this.beans.registry.createDynamicBean("headerFilterCellCtrl",!0,e,this));break}case"group":n=this.createBean(this.beans.registry.createDynamicBean("headerGroupCellCtrl",!0,e,this));break;default:n=this.createBean(new MKe(e,this));break}this.headerCellCtrls.set(r,n)}getColumnsInViewport(){return this.isPrintLayout?this.getColumnsInViewportPrintLayout():this.getColumnsInViewportNormalLayout()}getColumnsInViewportPrintLayout(){if(this.pinned!=null)return[];let e=[];const t=this.getActualDepth(),{colViewport:r}=this.beans;return["left",null,"right"].forEach(n=>{const i=r.getHeadersToRender(n,t);e=e.concat(i)}),e}getActualDepth(){return this.type=="filter"?this.rowIndex-1:this.rowIndex}getColumnsInViewportNormalLayout(){return this.beans.colViewport.getHeadersToRender(this.pinned,this.getActualDepth())}findHeaderCellCtrl(e){if(!this.headerCellCtrls)return;const t=this.getHeaderCellCtrls();let r;return typeof e=="function"?r=t.find(e):r=t.find(n=>n.column==e),r}focusHeader(e,t){const r=this.findHeaderCellCtrl(e);return r?r.focus(t):!1}destroy(){var e;(e=this.headerCellCtrls)==null||e.forEach(t=>{this.destroyBean(t)}),this.headerCellCtrls=void 0,super.destroy()}},Kfe=class extends xe{constructor(e){super(),this.pinned=e,this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[]}setComp(e,t){this.comp=e,this.eViewport=t;const{pinnedCols:r,ctrlsSvc:n,colModel:i,colMoves:o,filterManager:s}=this.beans;this.setupCenterWidth(),r==null||r.setupHeaderPinnedWidth(this),this.setupDragAndDrop(o,this.eViewport);const a=this.onDisplayedColumnsChanged.bind(this,s);this.addManagedEventListeners({gridColumnsChanged:this.onGridColumnsChanged.bind(this),displayedColumnsChanged:a,advancedFilterEnabledChanged:a});const l=`${typeof this.pinned=="string"?this.pinned:"center"}Header`;n.register(l,this),i.ready&&this.refresh()}getAllCtrls(){const e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}refresh(e=!1){const{focusSvc:t,colModel:r,filterManager:n}=this.beans;let i=0;const o=t.getFocusHeaderToUseAfterRefresh(),s=()=>{const u=Hfe(r)-1;this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls);for(let d=0;d{const u=i++,d=!this.hidden&&(this.columnsRowCtrl==null||!e||this.columnsRowCtrl.rowIndex!==u);(d||this.hidden)&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),d&&(this.columnsRowCtrl=this.createBean(new HO(u,this.pinned,"column")))},l=()=>{this.includeFloatingFilter=!!(n!=null&&n.hasFloatingFilters())&&!this.hidden;const u=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter){u();return}const d=i++;if(this.filtersRowCtrl){const h=this.filtersRowCtrl.rowIndex!==d;(!e||h)&&u()}this.filtersRowCtrl||(this.filtersRowCtrl=this.createBean(new HO(d,this.pinned,"filter")))};s(),a(),l();const c=this.getAllCtrls();this.comp.setCtrls(c),this.restoreFocusOnHeader(t,o)}getHeaderCtrlForColumn(e){var t;if(yu(e))return(t=this.columnsRowCtrl)==null?void 0:t.getHeaderCellCtrl(e);if(this.groupsRowCtrls.length!==0)for(let r=0;rthis.comp.setCenterWidth(`${e}px`),!0))}},DKe=class extends xe{constructor(){super(...arguments),this.beanName="menuSvc"}postConstruct(){const{enterpriseMenuFactory:e,filterMenuFactory:t}=this.beans;this.activeMenuFactory=e??t}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){const{enterpriseMenuFactory:t,filterMenuFactory:r}=this.beans,n=t&&wo(this.gos)?t:r;this.showColumnMenuCommon(n,e,e.containerType,!0)}showHeaderContextMenu(e,t,r){var n;(n=this.activeMenuFactory)==null||n.showMenuAfterContextMenuEvent(e,t,r)}hidePopupMenu(){var e,t;(e=this.beans.contextMenuSvc)==null||e.hideActiveMenu(),(t=this.activeMenuFactory)==null||t.hideActiveMenu()}isColumnMenuInHeaderEnabled(e){var r;const{suppressHeaderMenuButton:t}=e.getColDef();return!t&&!!((r=this.activeMenuFactory)!=null&&r.isMenuEnabled(e))&&(wo(this.gos)||!!this.beans.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){var t;return!e.getColDef().suppressHeaderFilterButton&&!!((t=this.beans.filterManager)!=null&&t.isFilterAllowed(e))}isHeaderContextMenuEnabled(e){const t=e&&yu(e)?e.getColDef():e==null?void 0:e.getColGroupDef();return!(t!=null&&t.suppressHeaderContextMenu)&&this.gos.get("columnMenu")==="new"}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){const e=!this.isSuppressMenuHide();return!(fp()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!wo(this.gos)&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){var t;return!!((t=this.beans.filterManager)!=null&&t.isFilterAllowed(e))&&!wo(this.gos)&&!this.isFilterMenuInHeaderEnabled(e)&&!this.isFloatingFilterButtonDisplayed(e)}isFloatingFilterButtonEnabled(e){return!e.getColDef().suppressFloatingFilterButton}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){const e=this.gos,t=e.get("suppressMenuHide");return wo(e)?e.exists("suppressMenuHide")?t:!1:t}showColumnMenuCommon(e,t,r,n){const{positionBy:i}=t,o=t.column;if(i==="button"){const{buttonElement:s}=t;e==null||e.showMenuAfterButtonClick(o,s,r,n)}else if(i==="mouse"){const{mouseEvent:s}=t;e==null||e.showMenuAfterMouseEvent(o,s,r,n)}else if(o){const s=this.beans,a=s.ctrlsSvc;a.getScrollFeature().ensureColumnVisible(o,"auto"),Tl(s,()=>{var c;const l=(c=a.getHeaderRowContainerCtrl(o.getPinned()))==null?void 0:c.getHeaderCtrlForColumn(o);l&&(e==null||e.showMenuAfterButtonClick(o,l.getAnchorElementForMenu(n),r,!0))})}}};function sI(e,t,r){e.menuVisible!==t&&(e.menuVisible=t,e.dispatchColEvent("menuVisibleChanged",r))}var qfe=class extends Je{constructor(){super()}},AKe=class extends qfe{init(){var t;const e=Ai((t=this.gos.get("overlayLoadingTemplate"))==null?void 0:t.trim());if(this.setTemplate(e??''),!e){const r=this.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=r("loadingOoo","Loading...")})}}},FKe=class extends qfe{init(){var t;const e=Ai((t=this.gos.get("overlayNoRowsTemplate"))==null?void 0:t.trim());if(this.setTemplate(e??''),!e){const r=this.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=r("noRowsToShow","No Rows To Show")})}}};function gp(e,t,r){const n=Ht(e,t,r);if(n){const{className:o}=n;if(typeof o=="string"&&o.indexOf("ag-icon")>-1||typeof o=="object"&&o["ag-icon"])return n}const i=document.createElement("span");return i.appendChild(n),i}function Ht(e,t,r){var o;let n=null;e==="smallDown"?we(262):e==="smallLeft"?we(263):e==="smallRight"&&we(264);const i=r&&r.getColDef().icons;if(i&&(n=i[e]),t.gos&&!n){const s=t.gos.get("icons");s&&(n=s[e])}if(n){let s;if(typeof n=="function")s=n();else if(typeof n=="string")s=n;else{we(38,{iconName:e});return}if(typeof s=="string")return Ts(s);if(wA(s))return s;we(133,{iconName:e});return}else{const s=document.createElement("span"),a=t.registry.getIcon(e);a||(o=t.validation)==null||o.validateIcon(e);const l=a??e;return s.setAttribute("class",`ag-icon ag-icon-${l}`),s.setAttribute("unselectable","on"),Un(s,"presentation"),s}}var LKe=".ag-dnd-ghost{align-items:center;background-color:var(--ag-drag-and-drop-image-background-color);border:var(--ag-drag-and-drop-image-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-drag-and-drop-image-shadow);color:var(--ag-text-color);cursor:move;display:flex;font-weight:500;gap:var(--ag-cell-widget-spacing);height:var(--ag-header-height);overflow:hidden;padding-left:var(--ag-cell-horizontal-padding);padding-right:var(--ag-cell-horizontal-padding);text-overflow:ellipsis;transform:translateY(calc(var(--ag-spacing)*2));white-space:nowrap}",_Ke=class extends Je{constructor(){super(),this.dragSource=null,this.eIcon=Ce,this.eLabel=Ce,this.registerCSS(LKe)}postConstruct(){const e=t=>gp(t,this.beans,null);this.dropIconMap={pinned:e("columnMovePin"),hide:e("columnMoveHide"),move:e("columnMoveMove"),left:e("columnMoveLeft"),right:e("columnMoveRight"),group:e("columnMoveGroup"),aggregate:e("columnMoveValue"),pivot:e("columnMovePivot"),notAllowed:e("dropNotAllowed")}}init(e){this.dragSource=e.dragSource,this.setTemplate(`
`)}destroy(){this.dragSource=null,super.destroy()}setIcon(e,t){const{eIcon:r,dragSource:n,dropIconMap:i,gos:o}=this;Jr(r);let s=null;e||(e=n!=null&&n.getDefaultIconName?n.getDefaultIconName():"notAllowed"),s=i[e],r.classList.toggle("ag-shake-left-to-right",t),!(s===i.hide&&o.get("suppressDragLeaveHidesColumns"))&&s&&r.appendChild(s)}setLabel(e){this.eLabel.textContent=Sn(e)}},OKe=".ag-label{white-space:nowrap}:where(.ag-ltr) .ag-label{margin-right:var(--ag-spacing)}:where(.ag-rtl) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-label-align-right) .ag-label{order:1}:where(.ag-ltr) :where(.ag-label-align-right) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-rtl) :where(.ag-label-align-right) .ag-label{margin-right:var(--ag-spacing)}.ag-label-align-right>*{flex:none}.ag-label-align-top{align-items:flex-start;flex-direction:column;>*{align-self:stretch}}.ag-label-ellipsis{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:where(.ag-label-align-top) .ag-label{margin-bottom:calc(var(--ag-spacing)*.5)}",D5=class extends Je{constructor(e,t,r){super(t,r),this.labelSeparator="",this.labelAlignment="left",this.disabled=!1,this.label="",this.config=e||{},this.registerCSS(OKe)}postConstruct(){this.addCssClass("ag-labeled"),this.eLabel.classList.add("ag-label");const{labelSeparator:e,label:t,labelWidth:r,labelAlignment:n,disabled:i}=this.config;i!=null&&this.setDisabled(i),e!=null&&this.setLabelSeparator(e),t!=null&&this.setLabel(t),r!=null&&this.setLabelWidth(r),this.setLabelAlignment(n||this.labelAlignment),this.refreshLabel()}refreshLabel(){const{label:e,eLabel:t}=this;Jr(t),typeof e=="string"?t.innerText=e+this.labelSeparator:e&&t.appendChild(e),e===""?(Pt(t,!1),Un(t,"presentation")):(Pt(t,!0),Un(t,null))}setLabelSeparator(e){return this.labelSeparator===e?this:(this.labelSeparator=e,this.label!=null&&this.refreshLabel(),this)}getLabelId(){const e=this.eLabel;return e.id=e.id||`ag-${this.getCompId()}-label`,e.id}getLabel(){return this.label}setLabel(e){return this.label===e?this:(this.label=e,this.refreshLabel(),this)}setLabelAlignment(e){const r=this.getGui().classList;return r.toggle("ag-label-align-left",e==="left"),r.toggle("ag-label-align-right",e==="right"),r.toggle("ag-label-align-top",e==="top"),this}setLabelEllipsis(e){return this.eLabel.classList.toggle("ag-label-ellipsis",e),this}setLabelWidth(e){return this.label==null?this:(jM(this.eLabel,e),this)}setDisabled(e){e=!!e;const t=this.getGui();return cl(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}},Xfe=class extends D5{constructor(e,t,r,n){super(e,t,r),this.className=n}postConstruct(){super.postConstruct();const{width:e,value:t,onValueChange:r}=this.config;e!=null&&this.setWidth(e),t!=null&&this.setValue(t),r!=null&&this.onValueChange(r),this.className&&this.addCssClass(this.className),this.refreshAriaLabelledBy()}setLabel(e){return super.setLabel(e),this.refreshAriaLabelledBy(),this}refreshAriaLabelledBy(){const e=this.getAriaElement(),t=this.getLabelId(),r=this.getLabel();r==null||r==""||M7e(e)!==null?Mp(e,""):Mp(e,t??"")}setAriaLabel(e){return jn(this.getAriaElement(),e),this.refreshAriaLabelledBy(),this}onValueChange(e){return this.addManagedListeners(this,{fieldValueChanged:()=>e(this.getValue())}),this}getWidth(){return this.getGui().clientWidth}setWidth(e){return sc(this.getGui(),e),this}getPreviousValue(){return this.previousValue}getValue(){return this.value}setValue(e,t){return this.value===e?this:(this.previousValue=this.value,this.value=e,t||this.dispatchLocalEvent({type:"fieldValueChanged"}),this)}},rp=class extends Xfe{constructor(e,t,r="text",n="input"){super(e,(e==null?void 0:e.template)??`
`,[],t),this.inputType=r,this.displayFieldTag=n,this.eLabel=Ce,this.eWrapper=Ce,this.eInput=Ce}postConstruct(){super.postConstruct(),this.setInputType();const{eLabel:e,eWrapper:t,eInput:r,className:n}=this;e.classList.add(`${n}-label`),t.classList.add(`${n}-input-wrapper`),r.classList.add(`${n}-input`),this.addCssClass("ag-input-field"),r.id=r.id||`ag-${this.getCompId()}-input`;const{inputName:i,inputWidth:o}=this.config;i!=null&&this.setInputName(i),o!=null&&this.setInputWidth(o),this.addInputListeners(),this.activateTabIndex([r])}addInputListeners(){this.addManagedElementListeners(this.eInput,{input:e=>this.setValue(e.target.value)})}setInputType(){this.displayFieldTag==="input"&&this.eInput.setAttribute("type",this.inputType)}getInputElement(){return this.eInput}setInputWidth(e){return jM(this.eWrapper,e),this}setInputName(e){return this.getInputElement().setAttribute("name",e),this}getFocusableElement(){return this.eInput}setMaxLength(e){const t=this.eInput;return t.maxLength=e,this}setInputPlaceholder(e){return vl(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return jn(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return cl(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){if(e===!0)vl(this.eInput,"autocomplete",null);else{const t=typeof e=="string"?e:"off";vl(this.eInput,"autocomplete",t)}return this}},Am=class extends rp{constructor(e,t="ag-checkbox",r="checkbox"){super(e,t,r),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();const{readOnly:e,passive:t}=this.config;typeof e=="boolean"&&this.setReadOnly(e),typeof t=="boolean"&&this.setPassive(t)}addInputListeners(){this.addManagedElementListeners(this.eInput,{click:this.onCheckboxClick.bind(this)}),this.addManagedElementListeners(this.eLabel,{click:this.toggle.bind(this)})}getNextValue(){return this.selected===void 0?!0:!this.selected}setPassive(e){this.passive=e}isReadOnly(){return this.readOnly}setReadOnly(e){this.eWrapper.classList.toggle("ag-disabled",e),this.eInput.disabled=e,this.readOnly=e}setDisabled(e){return this.eWrapper.classList.toggle("ag-disabled",e),super.setDisabled(e)}toggle(){if(this.eInput.disabled)return;const e=this.isSelected(),t=this.getNextValue();this.passive?this.dispatchChange(t,e):this.setValue(t)}getValue(){return this.isSelected()}setValue(e,t){return this.refreshSelectedClass(e),this.setSelected(e,t),this}setName(e){const t=this.getInputElement();return t.name=e,this}isSelected(){return this.selected}setSelected(e,t){if(this.isSelected()===e)return;this.previousValue=this.isSelected(),e=this.selected=typeof e=="boolean"?e:void 0;const r=this.eInput;r.checked=e,r.indeterminate=e===void 0,t||this.dispatchChange(this.selected,this.previousValue)}dispatchChange(e,t,r){this.dispatchLocalEvent({type:"fieldValueChanged",selected:e,previousValue:t,event:r});const n=this.getInputElement();this.eventSvc.dispatchEvent({type:"checkboxChanged",id:n.id,name:n.name,selected:e,previousValue:t})}onCheckboxClick(e){if(this.passive||this.eInput.disabled)return;const t=this.isSelected(),r=this.selected=e.target.checked;this.refreshSelectedClass(r),this.dispatchChange(r,t,e)}refreshSelectedClass(e){const t=this.eWrapper.classList;t.toggle("ag-checked",e===!0),t.toggle("ag-indeterminate",e==null)}},Tc={selector:"AG-CHECKBOX",component:Am},kKe=".ag-checkbox-cell{height:100%}",NKe=class extends Je{constructor(){super(` `,[Tc]),this.eCheckbox=Ce,this.registerCSS(kKe)}init(e){this.refresh(e);const{eCheckbox:t,beans:r}=this,n=t.getInputElement();n.setAttribute("tabindex","-1"),Qhe(n,"polite"),this.addManagedListeners(n,{click:i=>{if(di(i),t.isDisabled())return;const o=t.getValue();this.onCheckboxChanged(o)},dblclick:i=>{di(i)}}),this.addManagedElementListeners(e.eGridCell,{keydown:i=>{if(i.key===ge.SPACE&&!t.isDisabled()){e.eGridCell===Gr(r)&&t.toggle();const o=t.getValue();this.onCheckboxChanged(o),i.preventDefault()}}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){let t,r=!0;const{value:n,column:i,node:o}=e;if(o.group&&i)if(typeof n=="boolean")t=n;else{const d=i.getColId();d.startsWith(Fp)?t=n==null||n===""?void 0:n==="true":o.aggData&&o.aggData[d]!==void 0?t=n??void 0:r=!1}else t=n??void 0;const{eCheckbox:s}=this;if(!r){s.setDisplayed(!1);return}s.setValue(t);const a=e.disabled??!(i!=null&&i.isCellEditable(o));s.setDisabled(a);const l=this.getLocaleTextFunc(),c=r5(l,t),u=a?c:`${l("ariaToggleCellValue","Press SPACE to toggle cell value")} (${c})`;s.setInputAriaLabel(u)}onCheckboxChanged(e){const{eventSvc:t,params:r}=this,{column:n,node:i,value:o}=r,s={column:n,colDef:n.getColDef(),data:i.data,node:i,rowIndex:i.rowIndex,rowPinned:i.rowPinned,value:o};t.dispatchEvent({type:"cellEditingStarted",...s});const a=i.setDataValue(n,e,"edit");t.dispatchEvent({type:"cellEditingStopped",...s,oldValue:o,newValue:e,valueChanged:a}),a||this.updateCheckbox(r)}},BKe="ROOT_NODE_ID",Yfe=class extends xe{constructor(){super(...arguments),this.nextId=0,this.allNodesMap={},this.rootNode=null}get treeData(){return!1}getRowNode(e){return this.allNodesMap[e]}extractRowData(){var e,t;return(t=(e=this.rootNode)==null?void 0:e.allLeafChildren)==null?void 0:t.map(r=>r.data)}activate(e){this.rootNode=e,e.group=!0,e.level=-1,e.id=BKe,e.allLeafChildren=[],e.childrenAfterGroup=[],e.childrenAfterSort=[],e.childrenAfterAggFilter=[],e.childrenAfterFilter=[],this.updateRootSiblingArrays(e)}deactivate(){this.rootNode&&(this.allNodesMap={},this.rootNode=null)}destroy(){super.destroy(),this.allNodesMap={},this.rootNode=null}setNewRowData(e){const t=this.rootNode;t&&(this.dispatchRowDataUpdateStartedEvent(e),t.childrenAfterFilter=null,t.childrenAfterGroup=null,t.childrenAfterAggFilter=null,t.childrenAfterSort=null,t.childrenMapped=null,t.updateHasChildren(),this.allNodesMap={},this.nextId=0,this.loadNewRowData(e),this.updateRootSiblingArrays(t))}updateRootSiblingArrays(e){const t=e.sibling;t&&(t.childrenAfterFilter=e.childrenAfterFilter,t.childrenAfterGroup=e.childrenAfterGroup,t.childrenAfterAggFilter=e.childrenAfterAggFilter,t.childrenAfterSort=e.childrenAfterSort,t.childrenMapped=e.childrenMapped,t.allLeafChildren=e.allLeafChildren)}loadNewRowData(e){this.rootNode.allLeafChildren=(e==null?void 0:e.map((t,r)=>this.createRowNode(t,r)))??[]}setImmutableRowData(e,t){const r=this.createTransactionForRowData(t),n=this.updateRowData(r,e.changedRowNodes);let i=!1;this.gos.get("suppressMaintainUnsortedOrder")||(i=this.updateRowOrderFromRowData(t));const{rowNodeTransaction:o,rowsInserted:s}=n,{add:a,remove:l,update:c}=o;(s||i||a.length||l.length||c.length)&&(e.step="group",e.rowDataUpdated=!0,e.rowNodeTransactions=[o],e.rowNodesOrderChanged=s||i)}updateRowData(e,t){this.dispatchRowDataUpdateStartedEvent(e.add);const r={changedRowNodes:t,rowNodeTransaction:{remove:[],update:[],add:[]},rowsInserted:!1},n=[],i=Fd(this.gos);return this.executeRemove(i,e,r,n),this.executeUpdate(i,e,r,n),this.executeAdd(e,r),this.deselectNodes(n),r}createTransactionForRowData(e){const t=Fd(this.gos),r={...this.allNodesMap},n=[],i=[],o=[];Qe(e)&&e.forEach(s=>{const a=t({data:s,level:0}),l=r[a];l?(l.data!==s&&i.push(s),r[a]=void 0):o.push(s)});for(const s of Object.values(r))s&&n.push(s.data);return{remove:n,update:i,add:o}}updateRowOrderFromRowData(e){var s;const t=(s=this.rootNode)==null?void 0:s.allLeafChildren,r=(t==null?void 0:t.length)??0,n=new Map;let i=-1,o=-1;for(let a=0;a0&&this.gos.get("treeData")&&this.gos.get("getDataPath")))for(let d=0;d{const h=this.lookupRowNode(e,d);h&&(h.isSelected()&&i.push(h),h.clearRowTopAndRowIndex(),s[h.id]=!0,delete this.allNodesMap[h.id],n.remove.push(h),r.remove(h))});const a=this.rootNode;a.allLeafChildren=((c=a.allLeafChildren)==null?void 0:c.filter(d=>!s[d.id]))??null,(u=a.allLeafChildren)==null||u.forEach((d,h)=>{d.sourceRowIndex=h});const l=a.sibling;l&&(l.allLeafChildren=a.allLeafChildren)}executeUpdate(e,t,{changedRowNodes:r,rowNodeTransaction:n},i){const{update:o}=t;o!=null&&o.length&&o.forEach(s=>{const a=this.lookupRowNode(e,s);a&&(a.updateData(s),!a.selectable&&a.isSelected()&&i.push(a),n.update.push(a),r.update(a))})}dispatchRowDataUpdateStartedEvent(e){this.eventSvc.dispatchEvent({type:"rowDataUpdateStarted",firstRowData:e!=null&&e.length?e[0]:null})}deselectNodes(e){var i;const t="rowDataChanged",r=this.beans.selectionSvc,n=e.length>0;n&&(r==null||r.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t})),(i=r==null?void 0:r.updateGroupsFromChildrenSelections)==null||i.call(r,t),n&&this.eventSvc.dispatchEvent({type:"selectionChanged",source:t})}sanitizeAddIndex(e){var r;const t=((r=this.rootNode.allLeafChildren)==null?void 0:r.length)??0;return e<0||e>=t||Number.isNaN(e)?t:Math.ceil(e)}createRowNode(e,t){const r=new da(this.beans);return r.parent=this.rootNode,r.level=0,r.group=!1,r.expanded=!1,r.sourceRowIndex=t,r.setDataAndId(e,String(this.nextId)),this.allNodesMap[r.id]&&we(2,{nodeId:r.id}),this.allNodesMap[r.id]=r,this.nextId++,r}lookupRowNode(e,t){var n,i;let r;if(e){const o=e({data:t,level:0});if(r=this.allNodesMap[o],!r)return yr(4,{id:o}),null}else if(r=(i=(n=this.rootNode)==null?void 0:n.allLeafChildren)==null?void 0:i.find(o=>o.data===t),!r)return yr(5,{data:t}),null;return r||null}},Xc=(e=>(e.Applied="Applied",e.StoreNotFound="StoreNotFound",e.StoreLoading="StoreLoading",e.StoreWaitingToLoad="StoreWaitingToLoad",e.StoreLoadingFailed="StoreLoadingFailed",e.StoreWrongType="StoreWrongType",e.Cancelled="Cancelled",e.StoreNotStarted="StoreNotStarted",e))(Xc||{}),$Ke=class extends Je{constructor(){super(` `,[Tc]),this.eCheckbox=Ce}postConstruct(){this.eCheckbox.setPassive(!0)}getCheckboxId(){return this.eCheckbox.getInputElement().id}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){const e=this.getLocaleTextFunc(),{rowNode:t,eCheckbox:r}=this,n=t.isSelected(),i=r5(e,n),[o,s]=t.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],a=e(o,s);r.setValue(n,!0),r.setInputAriaLabel(`${a} (${i})`)}init(e){if(this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListeners(this.eCheckbox.getInputElement(),{dblclick:di,click:n=>{var i;di(n),(i=this.beans.selectionSvc)==null||i.handleSelectionEvent(n,this.rowNode,"checkboxSelected")}}),this.addManagedListeners(this.rowNode,{rowSelected:this.onSelectionChanged.bind(this),dataChanged:this.onDataChanged.bind(this),selectableChanged:this.onSelectableChanged.bind(this)}),this.addManagedPropertyListener("rowSelection",({currentValue:n,previousValue:i})=>{const o=typeof n=="object"?BO(n):void 0,s=typeof i=="object"?BO(i):void 0;o!==s&&this.onSelectableChanged()}),CV(this.gos)||typeof this.getIsVisible()=="function"){const n=this.showOrHideSelect.bind(this);this.addManagedEventListeners({displayedColumnsChanged:n}),this.addManagedListeners(this.rowNode,{dataChanged:n,cellChanged:n}),this.showOrHideSelect()}this.eCheckbox.getInputElement().setAttribute("tabindex","-1")}showOrHideSelect(){const{column:e,rowNode:t,overrides:r,gos:n}=this;let i=t.selectable;const o=this.getIsVisible();if(i)if(typeof o=="function"){const l=r==null?void 0:r.callbackParams;if(!e)i=o({...l,node:t,data:t.data});else{const c=e.createColumnFunctionCallbackParams(t);i=o({...l,...c})}}else i=o??!1;const s=n.get("rowSelection");if(s&&typeof s!="string"?!BO(s):e==null?void 0:e.getColDef().showDisabledCheckboxes){this.eCheckbox.setDisabled(!i),this.setVisible(!0),this.setDisplayed(!0);return}if(r!=null&&r.removeHidden){this.setDisplayed(i);return}this.setVisible(i)}getIsVisible(){var r,n;const e=this.overrides;if(e)return e.isVisible;const t=this.gos.get("rowSelection");return t&&typeof t!="string"?$g(t):(n=(r=this.column)==null?void 0:r.getColDef())==null?void 0:n.checkboxSelection}},GKe=class{constructor(e){this.rootId=null,this.endId=null,this.cachedRange=[],this.rowModel=e}reset(){this.rootId=null,this.endId=null,this.cachedRange.length=0}setRoot(e){this.rootId=e.id,this.endId=null,this.cachedRange.length=0}setEndRange(e){this.endId=e.id,this.cachedRange.length=0}getRange(){if(this.cachedRange.length===0){const e=this.getRoot(),t=this.getEnd();if(e==null||t==null)return this.cachedRange;this.cachedRange=this.rowModel.getNodesInRangeForSelection(e,t)??[]}return this.cachedRange}isInRange(e){return this.rootId===null?!1:this.getRange().some(t=>t.id===e.id)}getRoot(){return this.rootId?this.rowModel.getRowNode(this.rootId)??null:null}getEnd(){return this.endId?this.rowModel.getRowNode(this.endId)??null:null}truncate(e){const t=this.getRange();if(t.length===0)return{keep:[],discard:[]};const r=t[0].id===this.rootId,n=t.findIndex(i=>i.id===e.id);if(n>-1){const i=t.slice(0,n),o=t.slice(n+1);return this.setEndRange(e),r?{keep:i,discard:o}:{keep:o,discard:i}}else return{keep:t,discard:[]}}extend(e,t=!1){const r=this.getRoot();if(r==null){const i=this.getRange().slice();return t&&e.depthFirstSearch(o=>!o.group&&i.push(o)),i.push(e),this.setRoot(e),{keep:i,discard:[]}}const n=this.rowModel.getNodesInRangeForSelection(r,e);if(!n)return this.setRoot(e),{keep:[e],discard:[]};if(n.find(i=>i.id===this.endId))return this.setEndRange(e),{keep:this.getRange(),discard:[]};{const i=this.getRange().slice();return this.setEndRange(e),{keep:this.getRange(),discard:i}}}},VKe=class extends xe{constructor(e){super(),this.column=e,this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1}onSpaceKeyDown(e){const t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(Gr(this.beans))&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e;const t=this.createManagedBean(new Am);this.cbSelectAll=t,t.addCssClass("ag-header-select-all"),Un(t.getGui(),"presentation"),this.showOrHideSelectAll(),this.addManagedEventListeners({newColumnsLoaded:this.showOrHideSelectAll.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),selectionChanged:this.onSelectionChanged.bind(this),paginationChanged:this.onSelectionChanged.bind(this),modelUpdated:this.onModelChanged.bind(this)}),this.addManagedListeners(t,{fieldValueChanged:this.onCbSelectAll.bind(this)}),t.getInputElement().setAttribute("tabindex","-1"),this.refreshSelectAllLabel()}onDisplayedColumnsChanged(){this.isAlive()&&this.showOrHideSelectAll()}showOrHideSelectAll(){const e=this.isCheckboxSelection();this.cbSelectAllVisible=e,this.cbSelectAll.setDisplayed(e),e&&(this.checkRightRowModelType("selectAllCheckbox"),this.checkSelectionType("selectAllCheckbox"),this.updateStateOfCheckbox()),this.refreshSelectAllLabel()}onModelChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}onSelectionChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}updateStateOfCheckbox(){if(this.processingEventFromCheckbox)return;this.processingEventFromCheckbox=!0;const e=this.getSelectAllMode(),t=this.beans.selectionSvc,r=this.cbSelectAll,n=t.getSelectAllState(e);r.setValue(n);const i=t.hasNodesToSelect(e);r.setDisabled(!i),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(){const e=this.getLocaleTextFunc(),{headerCellCtrl:t,cbSelectAll:r,cbSelectAllVisible:n}=this,o=r.getValue()?e("ariaChecked","checked"):e("ariaUnchecked","unchecked"),s=e("ariaRowSelectAll","Press Space to toggle all rows selection");t.setAriaDescriptionProperty("selectAll",n?`${s} (${o})`:null),r.setInputAriaLabel(e("ariaHeaderSelection","Column with Header Selection")),t.announceAriaDescription()}checkSelectionType(e){return Ap(this.gos)?!0:(we(128,{feature:e}),!1)}checkRightRowModelType(e){const{gos:t,rowModel:r}=this.beans;return En(t)||Ro(t)?!0:(we(129,{feature:e,rowModel:r.getType()}),!1)}onCbSelectAll(){if(this.processingEventFromCheckbox||!this.cbSelectAllVisible)return;const e=this.cbSelectAll.getValue(),t=this.getSelectAllMode();let r="uiSelectAll";t==="currentPage"?r="uiSelectAllCurrentPage":t==="filtered"&&(r="uiSelectAllFiltered");const n={source:r,selectAll:t},i=this.beans.selectionSvc;e?i.selectAllRowNodes(n):i.deselectAllRowNodes(n)}isCheckboxSelection(){var c;const{column:e,gos:t,beans:r}=this,n=t.get("rowSelection"),i=e.getColDef(),{headerCheckboxSelection:o}=i;let s=!1;const a=typeof n=="object";if(a){const u=lu(e),d=MA(e);(XM(n)==="autoGroupColumn"&&d||u&&((c=r.selectionColSvc)!=null&&c.isSelectionColumnEnabled()))&&(s=xP(n))}else typeof o=="function"?s=o(t.addGridCommonParams({column:e,colDef:i})):s=!!o;const l=a?"headerCheckbox":"headerCheckboxSelection";return s&&this.checkRightRowModelType(l)&&this.checkSelectionType(l)}getSelectAllMode(){const e=Lpe(this.gos,!1);if(e)return e;const{headerCheckboxSelectionCurrentPageOnly:t,headerCheckboxSelectionFilteredOnly:r}=this.column.getColDef();return t?"currentPage":r?"filtered":"all"}},Zfe=class extends xe{postConstruct(){const{gos:e,beans:t}=this;this.selectionCtx=new GKe(t.rowModel),this.addManagedPropertyListeners(["isRowSelectable","rowSelection"],()=>{const r=CV(e);r!==this.isRowSelectable&&(this.isRowSelectable=r,this.updateSelectable())}),this.isRowSelectable=CV(e)}destroy(){super.destroy(),this.selectionCtx.reset()}createCheckboxSelectionComponent(){return new $Ke}createSelectAllFeature(e){return new VKe(e)}isMultiSelect(){return Ap(this.gos)}onRowCtrlSelected(e,t,r){const n=!!e.rowNode.isSelected();e.forEachGui(r,i=>{i.rowComp.addOrRemoveCssClass("ag-row-selected",n);const o=i.element;L0(o,n),o.contains(Gr(this.beans))&&t(i)})}announceAriaRowSelection(e){var i;if(this.isRowSelectionBlocked(e))return;const t=e.isSelected();if(t&&!DY(this.gos))return;const n=this.getLocaleTextFunc()(t?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${t?"deselect":"select"} this row`);(i=this.beans.ariaAnnounce)==null||i.announceValue(n,"rowSelection")}dispatchSelectionChanged(e){this.eventSvc.dispatchEvent({type:"selectionChanged",source:e})}isRowSelectionBlocked(e){return!e.selectable||!!e.rowPinned||!Fa(this.gos)}updateRowSelectable(e,t){var n;const r=((n=this.isRowSelectable)==null?void 0:n.call(this,e))??!0;return this.setRowSelectable(e,r,t),r}setRowSelectable(e,t,r){if(e.selectable!==t){if(e.selectable=t,e.dispatchRowEvent("selectableChanged"),r)return;if(lm(this.gos)){const i=this.calculateSelectedFromChildren(e);this.setNodesSelected({nodes:[e],newValue:i??!1,source:"selectableChanged"});return}e.isSelected()&&!e.selectable&&this.setNodesSelected({nodes:[e],newValue:!1,source:"selectableChanged"})}}calculateSelectedFromChildren(e){var n;let t=!1,r=!1;if(!((n=e.childrenAfterGroup)!=null&&n.length))return e.selectable?e.__selected:null;for(let i=0;i{x5(r)&&r.key&&!e.test(r.key)&&r.preventDefault()};this.addManagedListeners(this.eInput,{keydown:t,paste:r=>{var i;const n=(i=r.clipboardData)==null?void 0:i.getData("text");n&&n.split("").some(o=>!e.test(o))&&r.preventDefault()}})}},Ll={selector:"AG-INPUT-TEXT-FIELD",component:Rc},UKe=class extends rp{constructor(e){super(e,"ag-text-area",null,"textarea")}setValue(e,t){const r=super.setValue(e,t);return this.eInput.value=e,r}setCols(e){return this.eInput.cols=e,this}setRows(e){return this.eInput.rows=e,this}},jKe={selector:"AG-INPUT-TEXT-AREA",component:UKe},LA=class extends Rc{constructor(e){super(e,"ag-number-field","number")}postConstruct(){super.postConstruct();const e=this.eInput;this.addManagedListeners(e,{blur:()=>{const o=parseFloat(e.value),s=isNaN(o)?"":this.normalizeValue(o.toString());this.value!==s&&this.setValue(s)},wheel:this.onWheel.bind(this)}),e.step="any";const{precision:t,min:r,max:n,step:i}=this.config;typeof t=="number"&&this.setPrecision(t),typeof r=="number"&&this.setMin(r),typeof n=="number"&&this.setMax(n),typeof i=="number"&&this.setStep(i)}onWheel(e){Gr(this.beans)===this.eInput&&e.preventDefault()}normalizeValue(e){if(e==="")return"";this.precision!=null&&(e=this.adjustPrecision(e));const t=parseFloat(e),{min:r,max:n}=this;return r!=null&&tn&&(e=n.toString()),e}adjustPrecision(e,t){const r=this.precision;if(r==null)return e;if(t){const i=parseFloat(e).toFixed(r);return parseFloat(i).toString()}const n=String(e).split(".");if(n.length>1){if(n[1].length<=r)return e;if(r>0)return`${n[0]}.${n[1].slice(0,r)}`}return n[0]}setMin(e){return this.min===e?this:(this.min=e,vl(this.eInput,"min",e),this)}setMax(e){return this.max===e?this:(this.max=e,vl(this.eInput,"max",e),this)}setPrecision(e){return this.precision=e,this}setStep(e){return this.step===e?this:(this.step=e,vl(this.eInput,"step",e),this)}setValue(e,t){return this.setValueOrInputValue(r=>super.setValue(r,t),()=>this,e)}setStartValue(e){return this.setValueOrInputValue(t=>super.setValue(t,!0),t=>{this.eInput.value=t},e)}setValueOrInputValue(e,t,r){if(Qe(r)){let n=this.isScientificNotation(r);if(n&&this.eInput.validity.valid)return e(r);if(!n){r=this.adjustPrecision(r);const i=this.normalizeValue(r);n=r!=i}if(n)return t(r)}return e(r)}getValue(){const e=this.eInput;if(!e.validity.valid)return;const t=e.value;return this.isScientificNotation(t)?this.adjustPrecision(t,!0):super.getValue()}isScientificNotation(e){return typeof e=="string"&&e.includes("e")}},_A={selector:"AG-INPUT-NUMBER-FIELD",component:LA};function Ww(e,t){return e.toString().padStart(t,"0")}function aa(e,t=!0,r="-"){if(!e)return null;let n=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(i=>Ww(i,2)).join(r);return t&&(n+=" "+[e.getHours(),e.getMinutes(),e.getSeconds()].map(i=>Ww(i,2)).join(":")),n}var WO=e=>{if(e>3&&e<21)return"th";switch(e%10){case 1:return"st";case 2:return"nd";case 3:return"rd"}return"th"};function Uw(e,t="YYYY-MM-DD"){const r=Ww(e.getFullYear(),4),n=["January","February","March","April","May","June","July","August","September","October","November","December"],i=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],o={YYYY:()=>r.slice(r.length-4,r.length),YY:()=>r.slice(r.length-2,r.length),Y:()=>`${e.getFullYear()}`,MMMM:()=>n[e.getMonth()],MMM:()=>n[e.getMonth()].slice(0,3),MM:()=>Ww(e.getMonth()+1,2),Mo:()=>`${e.getMonth()+1}${WO(e.getMonth()+1)}`,M:()=>`${e.getMonth()+1}`,Do:()=>`${e.getDate()}${WO(e.getDate())}`,DD:()=>Ww(e.getDate(),2),D:()=>`${e.getDate()}`,dddd:()=>i[e.getDay()],ddd:()=>i[e.getDay()].slice(0,3),dd:()=>i[e.getDay()].slice(0,2),do:()=>`${e.getDay()}${WO(e.getDay())}`,d:()=>`${e.getDay()}`},s=new RegExp(Object.keys(o).join("|"),"g");return t.replace(s,a=>a in o?o[a]():a)}function cs(e){if(!e)return null;const[t,r]=e.split(" ");if(!t)return null;const n=t.split("-").map(d=>parseInt(d,10));if(n.filter(d=>!isNaN(d)).length!==3)return null;const[i,o,s]=n,a=new Date(i,o-1,s);if(a.getFullYear()!==i||a.getMonth()!==o-1||a.getDate()!==s)return null;if(!r||r==="00:00:00")return a;const[l,c,u]=r.split(":").map(d=>parseInt(d,10));return l>=0&&l<24&&a.setHours(l),c>=0&&c<60&&a.setMinutes(c),u>=0&&u<60&&a.setSeconds(u),a}var Qfe=class extends Rc{constructor(e){super(e,"ag-date-field","date")}postConstruct(){super.postConstruct();const e=Im();this.addManagedListeners(this.eInput,{wheel:this.onWheel.bind(this),mousedown:()=>{this.isDisabled()||e||this.eInput.focus()}}),this.eInput.step="any"}onWheel(e){Gr(this.beans)===this.eInput&&e.preventDefault()}setMin(e){const t=e instanceof Date?aa(e??null,!1)??void 0:e;return this.min===t?this:(this.min=t,vl(this.eInput,"min",t),this)}setMax(e){const t=e instanceof Date?aa(e??null,!1)??void 0:e;return this.max===t?this:(this.max=t,vl(this.eInput,"max",t),this)}setStep(e){return this.step===e?this:(this.step=e,vl(this.eInput,"step",e),this)}getDate(){if(this.eInput.validity.valid)return cs(this.getValue())??void 0}setDate(e,t){this.setValue(aa(e??null,!1),t)}},Jfe={selector:"AG-INPUT-DATE-FIELD",component:Qfe},KKe=1e3,qKe=1e3,$Y=100,GY,IT=!1,XKe=class extends xe{constructor(e,t){super(),this.tooltipCtrl=e,this.getTooltipValue=t,this.interactionEnabled=!1,this.isInteractingWithTooltip=!1,this.state=0,this.tooltipInstanceCount=0,this.tooltipMouseTrack=!1}wireBeans(e){this.popupSvc=e.popupSvc,this.userCompFactory=e.userCompFactory}postConstruct(){this.gos.get("tooltipInteraction")&&(this.interactionEnabled=!0),this.tooltipTrigger=this.getTooltipTrigger(),this.tooltipMouseTrack=this.gos.get("tooltipMouseTrack");const e=this.tooltipCtrl.getGui();this.tooltipTrigger===0&&this.addManagedListeners(e,{mouseenter:this.onMouseEnter.bind(this),mouseleave:this.onMouseLeave.bind(this)}),this.tooltipTrigger===1&&this.addManagedListeners(e,{focusin:this.onFocusIn.bind(this),focusout:this.onFocusOut.bind(this)}),this.addManagedListeners(e,{mousemove:this.onMouseMove.bind(this)}),this.interactionEnabled||this.addManagedListeners(e,{mousedown:this.onMouseDown.bind(this),keydown:this.onKeyDown.bind(this)})}getGridOptionsTooltipDelay(e){const t=this.gos.get(e);return Math.max(200,t)}getTooltipDelay(e){var t,r,n,i;return e==="show"?((r=(t=this.tooltipCtrl).getTooltipShowDelayOverride)==null?void 0:r.call(t))??this.getGridOptionsTooltipDelay("tooltipShowDelay"):((i=(n=this.tooltipCtrl).getTooltipHideDelayOverride)==null?void 0:i.call(n))??this.getGridOptionsTooltipDelay("tooltipHideDelay")}destroy(){this.setToDoNothing(),super.destroy()}getTooltipTrigger(){const e=this.gos.get("tooltipTrigger");return!e||e==="hover"?0:1}onMouseEnter(e){this.interactionEnabled&&this.interactiveTooltipTimeoutId&&(this.unlockService(),this.startHideTimeout()),!fp()&&(IT?this.showTooltipTimeoutId=window.setTimeout(()=>{this.prepareToShowTooltip(e)},$Y):this.prepareToShowTooltip(e))}onMouseMove(e){this.lastMouseEvent&&(this.lastMouseEvent=e),this.tooltipMouseTrack&&this.state===2&&this.tooltipComp&&this.positionTooltip()}onMouseDown(){this.setToDoNothing()}onMouseLeave(){this.interactionEnabled?this.lockService():this.setToDoNothing()}onFocusIn(){this.prepareToShowTooltip()}onFocusOut(e){var i;const t=e.relatedTarget,r=this.tooltipCtrl.getGui(),n=(i=this.tooltipComp)==null?void 0:i.getGui();this.isInteractingWithTooltip||r.contains(t)||this.interactionEnabled&&(n!=null&&n.contains(t))||this.setToDoNothing()}onKeyDown(){this.isInteractingWithTooltip&&(this.isInteractingWithTooltip=!1),this.setToDoNothing()}prepareToShowTooltip(e){if(this.state!=0||IT)return;let t=0;e&&(t=this.isLastTooltipHiddenRecently()?200:this.getTooltipDelay("show")),this.lastMouseEvent=e||null,this.showTooltipTimeoutId=window.setTimeout(this.showTooltip.bind(this),t),this.state=1}isLastTooltipHiddenRecently(){return new Date().getTime()-GYthis.hideTooltip(!0),...((h=t.getAdditionalParams)==null?void 0:h.call(t))??{}};this.state=2,this.tooltipInstanceCount++;const i=this.newTooltipComponentCallback.bind(this,this.tooltipInstanceCount),o=cje(this.userCompFactory,n);o==null||o.newAgStackInstance().then(i)}hideTooltip(e){!e&&this.isInteractingWithTooltip||(this.tooltipComp&&(this.destroyTooltipComp(),GY=new Date().getTime()),this.eventSvc.dispatchEvent({type:"tooltipHide",parentGui:this.tooltipCtrl.getGui()}),e&&(this.isInteractingWithTooltip=!1),this.setToDoNothing(!0))}newTooltipComponentCallback(e,t){var s;if(this.state!==2||this.tooltipInstanceCount!==e){this.destroyBean(t);return}const n=t.getGui();this.tooltipComp=t,n.classList.contains("ag-tooltip")||n.classList.add("ag-tooltip-custom"),this.tooltipTrigger===0&&n.classList.add("ag-tooltip-animate"),this.interactionEnabled&&n.classList.add("ag-tooltip-interactive");const i=this.getLocaleTextFunc(),o=(s=this.popupSvc)==null?void 0:s.addPopup({eChild:n,ariaLabel:i("ariaLabelTooltip","Tooltip")});if(o&&(this.tooltipPopupDestroyFunc=o.hideFunc),this.positionTooltip(),this.tooltipTrigger===1){const a=()=>this.setToDoNothing();[this.onBodyScrollEventCallback,this.onColumnMovedEventCallback]=this.addManagedEventListeners({bodyScroll:a,columnMoved:a})}this.interactionEnabled&&([this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener]=this.addManagedElementListeners(n,{mouseenter:this.onTooltipMouseEnter.bind(this),mouseleave:this.onTooltipMouseLeave.bind(this)}),[this.onDocumentKeyDownCallback]=this.addManagedElementListeners(pn(this.beans),{keydown:a=>{n.contains(a==null?void 0:a.target)||this.onKeyDown()}}),this.tooltipTrigger===1&&([this.tooltipFocusInListener,this.tooltipFocusOutListener]=this.addManagedElementListeners(n,{focusin:this.onTooltipFocusIn.bind(this),focusout:this.onTooltipFocusOut.bind(this)}))),this.eventSvc.dispatchEvent({type:"tooltipShow",tooltipGui:n,parentGui:this.tooltipCtrl.getGui()}),this.startHideTimeout()}onTooltipMouseEnter(){this.isInteractingWithTooltip=!0,this.unlockService()}onTooltipMouseLeave(){this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,this.lockService())}onTooltipFocusIn(){this.isInteractingWithTooltip=!0}isTooltipFocused(){var r;const e=(r=this.tooltipComp)==null?void 0:r.getGui(),t=Gr(this.beans);return!!e&&e.contains(t)}onTooltipFocusOut(e){const t=this.tooltipCtrl.getGui();this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,t.contains(e.relatedTarget)?this.startHideTimeout():this.hideTooltip())}positionTooltip(){var t,r;const e={type:"tooltip",ePopup:this.tooltipComp.getGui(),nudgeY:18,skipObserver:this.tooltipMouseTrack};this.lastMouseEvent?(t=this.popupSvc)==null||t.positionPopupUnderMouseEvent({...e,mouseEvent:this.lastMouseEvent}):(r=this.popupSvc)==null||r.positionPopupByComponent({...e,eventSource:this.tooltipCtrl.getGui(),position:"under",keepWithinBounds:!0,nudgeY:5})}destroyTooltipComp(){this.tooltipComp.getGui().classList.add("ag-tooltip-hiding");const e=this.tooltipPopupDestroyFunc,t=this.tooltipComp,r=this.tooltipTrigger===0?qKe:0;window.setTimeout(()=>{e(),this.destroyBean(t)},r),this.clearTooltipListeners(),this.tooltipPopupDestroyFunc=void 0,this.tooltipComp=void 0}clearTooltipListeners(){[this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener,this.tooltipFocusInListener,this.tooltipFocusOutListener].forEach(e=>{e&&e()}),this.tooltipMouseEnterListener=this.tooltipMouseLeaveListener=this.tooltipFocusInListener=this.tooltipFocusOutListener=null}lockService(){IT=!0,this.interactiveTooltipTimeoutId=window.setTimeout(()=>{this.unlockService(),this.setToDoNothing()},$Y)}unlockService(){IT=!1,this.clearInteractiveTimeout()}startHideTimeout(){this.clearHideTimeout(),this.hideTooltipTimeoutId=window.setTimeout(this.hideTooltip.bind(this),this.getTooltipDelay("hide"))}clearShowTimeout(){this.showTooltipTimeoutId&&(window.clearTimeout(this.showTooltipTimeoutId),this.showTooltipTimeoutId=void 0)}clearHideTimeout(){this.hideTooltipTimeoutId&&(window.clearTimeout(this.hideTooltipTimeoutId),this.hideTooltipTimeoutId=void 0)}clearInteractiveTimeout(){this.interactiveTooltipTimeoutId&&(window.clearTimeout(this.interactiveTooltipTimeoutId),this.interactiveTooltipTimeoutId=void 0)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout(),this.clearInteractiveTimeout()}};function jw(e){return e.get("tooltipShowMode")==="whenTruncated"}function OA(e,t){return jw(e)?zg(t):void 0}function zg(e){return()=>{const t=e();return t?t.scrollWidth>t.clientWidth:!0}}var YKe=class extends xe{constructor(e,t){super(),this.ctrl=e,t&&(this.beans=t)}postConstruct(){this.refreshTooltip()}setBrowserTooltip(e){const t="title",r=this.ctrl.getGui();r&&(e!=null&&e!=""?r.setAttribute(t,e):r.removeAttribute(t))}updateTooltipText(){const{getTooltipValue:e}=this.ctrl;e&&(this.tooltip=e())}createTooltipFeatureIfNeeded(){this.tooltipManager==null&&(this.tooltipManager=this.createBean(new XKe(this.ctrl,()=>this.tooltip),this.beans.context))}setTooltipAndRefresh(e){this.tooltip=e,this.refreshTooltip()}refreshTooltip(){this.browserTooltips=this.beans.gos.get("enableBrowserTooltips"),this.updateTooltipText(),this.browserTooltips?(this.setBrowserTooltip(this.tooltip),this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context)):(this.setBrowserTooltip(null),this.createTooltipFeatureIfNeeded())}destroy(){this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context),super.destroy()}},ZKe=class extends Je{constructor(e="default",t=!1){super(`
`),this.cssIdentifier=e,this.unFocusable=t,this.activeClass="ag-active-item",this.options=[],this.itemEls=[]}postConstruct(){const e=this.getGui();this.addManagedElementListeners(e,{mouseleave:()=>this.clearHighlighted()}),!this.unFocusable&&this.addManagedElementListeners(e,{keydown:this.handleKeyDown.bind(this)})}handleKeyDown(e){const t=e.key;switch(t){case ge.ENTER:if(!this.highlightedEl)this.setValue(this.getValue());else{const r=this.itemEls.indexOf(this.highlightedEl);this.setValueByIndex(r)}break;case ge.DOWN:case ge.UP:e.preventDefault(),this.navigate(t);break;case ge.PAGE_DOWN:case ge.PAGE_UP:case ge.PAGE_HOME:case ge.PAGE_END:e.preventDefault(),this.navigateToPage(t);break}}navigate(e){const t=e===ge.DOWN;let r;const{itemEls:n,highlightedEl:i}=this;if(!i)r=n[t?0:n.length-1];else{let s=n.indexOf(i)+(t?1:-1);s=Math.min(Math.max(s,0),n.length-1),r=n[s]}this.highlightItem(r)}navigateToPage(e){const{itemEls:t,highlightedEl:r}=this;if(!r||t.length===0)return;const n=t.indexOf(r),i=this.options.length-1,o=t[0].clientHeight,s=Math.floor(this.getGui().clientHeight/o);let a=-1;e===ge.PAGE_HOME?a=0:e===ge.PAGE_END?a=i:e===ge.PAGE_DOWN?a=Math.min(n+s,i):e===ge.PAGE_UP&&(a=Math.max(n-s,0)),a!==-1&&this.highlightItem(t[a])}addOptions(e){return e.forEach(t=>this.addOption(t)),this}addOption(e){const{value:t,text:r}=e,n=r||t;return this.options.push({value:t,text:n}),this.renderOption(t,n),this.updateIndices(),this}clearOptions(){this.options=[],this.reset(!0),this.itemEls.forEach(e=>{si(e)}),this.itemEls=[]}updateIndices(){const e=this.getGui().querySelectorAll(".ag-list-item");e.forEach((t,r)=>{CA(t,r+1),yA(t,e.length)})}renderOption(e,t){const r=pn(this.beans),n=r.createElement("div");Un(n,"option"),n.classList.add("ag-list-item",`ag-${this.cssIdentifier}-list-item`);const i=r.createElement("span");n.appendChild(i),i.textContent=t,this.unFocusable||(n.tabIndex=-1),this.itemEls.push(n),this.addManagedListeners(n,{mouseover:()=>this.highlightItem(n),mousedown:o=>{o.preventDefault(),o.stopPropagation(),this.setValue(e)}}),this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{getTooltipValue:()=>t,getGui:()=>n,getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>i.scrollWidth>i.clientWidth})),this.getGui().appendChild(n)}setValue(e,t){if(this.value===e)return this.fireItemSelected(),this;if(e==null)return this.reset(t),this;const r=this.options.findIndex(n=>n.value===e);if(r!==-1){const n=this.options[r];this.value=n.value,this.displayValue=n.text,this.highlightItem(this.itemEls[r]),t||this.fireChangeEvent()}return this}setValueByIndex(e){return this.setValue(this.options[e].value)}getValue(){return this.value}getDisplayValue(){return this.displayValue}refreshHighlighted(){this.clearHighlighted();const e=this.options.findIndex(t=>t.value===this.value);e!==-1&&this.highlightItem(this.itemEls[e])}reset(e){this.value=null,this.displayValue=null,this.clearHighlighted(),e||this.fireChangeEvent()}highlightItem(e){if(!ps(e))return;this.clearHighlighted(),this.highlightedEl=e,e.classList.add(this.activeClass),L0(e,!0);const t=this.getGui(),{scrollTop:r,clientHeight:n}=t,{offsetTop:i,offsetHeight:o}=e;(i+o>r+n||i
`,(e==null?void 0:e.agComponents)||[],e==null?void 0:e.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.eLabel=Ce,this.eWrapper=Ce,this.eDisplayField=Ce,this.eIcon=Ce,this.registerCSS(QKe),this.ariaRole=e==null?void 0:e.ariaRole,this.onPickerFocusIn=this.onPickerFocusIn.bind(this),this.onPickerFocusOut=this.onPickerFocusOut.bind(this),!e)return;const{pickerGap:t,maxPickerHeight:r,variableWidth:n,minPickerWidth:i,maxPickerWidth:o}=e;t!=null&&(this.pickerGap=t),this.variableWidth=!!n,r!=null&&this.setPickerMaxHeight(r),i!=null&&this.setPickerMinWidth(i),o!=null&&this.setPickerMaxWidth(o)}postConstruct(){super.postConstruct(),this.setupAria();const e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);const t=this.getAriaElement();this.addManagedElementListeners(t,{keydown:this.onKeyDown.bind(this)}),this.addManagedElementListeners(this.eLabel,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)}),this.addManagedElementListeners(this.eWrapper,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)});const{pickerIcon:r,inputWidth:n}=this.config;if(r){const i=Ht(r,this.beans);i&&this.eIcon.appendChild(i)}n!=null&&this.setInputWidth(n)}setupAria(){const e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),Ds(e,!1),this.ariaRole&&Un(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){const t=this.getFocusableElement();if(t!==this.eWrapper&&(e==null?void 0:e.target)===t)return;e.preventDefault(),this.getFocusableElement().focus()}if(this.skipClick){this.skipClick=!1;return}this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case ge.UP:case ge.DOWN:case ge.ENTER:case ge.SPACE:e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case ge.ESCAPE:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker());break}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());const e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){const e=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||([this.destroyMouseWheelFunc]=this.addManagedEventListeners({bodyScroll:()=>{this.hidePicker()}}));const t=this.getLocaleTextFunc(),{config:{pickerAriaLabelKey:r,pickerAriaLabelValue:n,modalPicker:i=!0},maxPickerHeight:o,minPickerWidth:s,maxPickerWidth:a,variableWidth:l,beans:c,eWrapper:u}=this,d={modal:i,eChild:e,closeOnEsc:!0,closedCallback:()=>{const g=Dp(c);this.beforeHidePicker(),g&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:t(r,n),anchorToElement:u};e.style.position="absolute";const h=c.popupSvc,p=h.addPopup(d);l?(s&&(e.style.minWidth=s),e.style.width=i5(sm(u)),a&&(e.style.maxWidth=a)):jM(e,a??sm(u));const f=o??`${bA(h.getPopupParent())}px`;return e.style.setProperty("max-height",f),this.alignPickerToComponent(),p.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;const{pickerGap:e,config:{pickerType:t},beans:{popupSvc:r,gos:n},eWrapper:i,pickerComponent:o}=this,s=n.get("enableRtl")?"right":"left";r.positionPopupByComponent({type:t,eventSource:i,ePopup:o.getGui(),position:"under",alignSide:s,keepWithinBounds:!0,nudgeY:e})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);const e=this.pickerComponent.getGui();e.removeEventListener("focusin",this.onPickerFocusIn),e.removeEventListener("focusout",this.onPickerFocusOut),this.isPickerDisplayed=!1,this.pickerComponent=void 0,this.hideCurrentPicker=null}toggleExpandedStyles(e){if(!this.isAlive())return;const t=this.getAriaElement();Ds(t,e);const r=this.eWrapper.classList;r.toggle("ag-picker-expanded",e),r.toggle("ag-picker-collapsed",!e)}onPickerFocusIn(){this.togglePickerHasFocus(!0)}onPickerFocusOut(e){var t;(t=this.pickerComponent)!=null&&t.getGui().contains(e.relatedTarget)||this.togglePickerHasFocus(!1)}togglePickerHasFocus(e){this.pickerComponent&&this.eWrapper.classList.toggle("ag-picker-has-focus",e)}hidePicker(){var e;(e=this.hideCurrentPicker)==null||e.call(this)}setInputWidth(e){return jM(this.eWrapper,e),this}getFocusableElement(){return this.eWrapper}setPickerGap(e){return this.pickerGap=e,this}setPickerMinWidth(e){return typeof e=="number"&&(e=`${e}px`),this.minPickerWidth=e??void 0,this}setPickerMaxWidth(e){return typeof e=="number"&&(e=`${e}px`),this.maxPickerWidth=e??void 0,this}setPickerMaxHeight(e){return typeof e=="number"&&(e=`${e}px`),this.maxPickerHeight=e??void 0,this}destroy(){this.hidePicker(),super.destroy()}},JKe=".ag-select{align-items:center;display:flex;&.ag-disabled{opacity:.5}}:where(.ag-select){.ag-picker-field-wrapper{cursor:default}&.ag-disabled .ag-picker-field-wrapper:focus{box-shadow:none}&:not(.ag-cell-editor,.ag-label-align-top){min-height:var(--ag-list-item-height)}.ag-picker-field-display{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ag-picker-field-icon{align-items:center;display:flex}}:where(.ag-ltr) :where(.ag-select){.ag-picker-field-wrapper{padding-left:calc(var(--ag-cell-horizontal-padding)/2);padding-right:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-select){.ag-picker-field-wrapper{padding-left:var(--ag-spacing);padding-right:calc(var(--ag-cell-horizontal-padding)/2)}}",Ms=class extends A5{constructor(e){super({pickerAriaLabelKey:"ariaLabelSelectField",pickerAriaLabelValue:"Select Field",pickerType:"ag-list",className:"ag-select",pickerIcon:"selectOpen",ariaRole:"combobox",...e}),this.registerCSS(JKe)}postConstruct(){this.tooltipFeature=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{shouldDisplayTooltip:zg(()=>this.eDisplayField),getGui:()=>this.getGui()})),super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{options:e,value:t,placeholder:r}=this.config;e!=null&&this.addOptions(e),t!=null&&this.setValue(t,!0),r&&t==null&&(this.eDisplayField.textContent=r),this.addManagedElementListeners(this.eWrapper,{focusout:this.onWrapperFocusOut.bind(this)})}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){const e=this.createBean(new ZKe("select",!0));this.listComponent=e,e.setParentComponent(this);const t=e.getAriaElement(),r=`ag-select-list-${e.getCompId()}`;t.setAttribute("id",r),t5(this.getAriaElement(),t),e.addManagedListeners(e,{selectedItem:()=>{this.hidePicker(),this.dispatchLocalEvent({type:"selectedItem"})}}),e.addManagedListeners(e,{fieldValueChanged:()=>{this.listComponent&&(this.setValue(this.listComponent.getValue(),!1,!0),this.hidePicker())}})}createPickerComponent(){return this.listComponent}onKeyDown(e){var r;const{key:t}=e;switch(t===ge.TAB&&this.hidePicker(),t){case ge.ENTER:case ge.UP:case ge.DOWN:case ge.PAGE_UP:case ge.PAGE_DOWN:case ge.PAGE_HOME:case ge.PAGE_END:e.preventDefault(),this.isPickerDisplayed?(r=this.listComponent)==null||r.handleKeyDown(e):super.onKeyDown(e);break;case ge.ESCAPE:super.onKeyDown(e);break;case ge.SPACE:this.isPickerDisplayed?e.preventDefault():super.onKeyDown(e);break}}showPicker(){const e=this.listComponent;e&&(super.showPicker(),e.refreshHighlighted())}addOptions(e){return e.forEach(t=>this.addOption(t)),this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){var e;return(e=this.listComponent)==null||e.clearOptions(),this}setValue(e,t,r){const{listComponent:n,config:{placeholder:i},eDisplayField:o,tooltipFeature:s}=this;if(this.value===e||!n)return this;if(r||n.setValue(e,!0),n.getValue()===this.getValue())return this;let l=n.getDisplayValue();return l==null&&i&&(l=i),o.textContent=l,s==null||s.setTooltipAndRefresh(l??null),super.setValue(e,t)}destroy(){this.listComponent=this.destroyBean(this.listComponent),super.destroy()}},u1={selector:"AG-SELECT",component:Ms},Hg={TAB_GUARD:"ag-tab-guard",TAB_GUARD_TOP:"ag-tab-guard-top",TAB_GUARD_BOTTOM:"ag-tab-guard-bottom"},ege=class extends xe{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1,this.allowFocus=!1;const{comp:t,eTopGuard:r,eBottomGuard:n,focusTrapActive:i,forceFocusOutWhenTabGuardsAreEmpty:o,isFocusableContainer:s,focusInnerElement:a,onFocusIn:l,onFocusOut:c,shouldStopEventPropagation:u,onTabKeyDown:d,handleKeyDown:h,eFocusableElement:p}=e;this.comp=t,this.eTopGuard=r,this.eBottomGuard=n,this.providedFocusInnerElement=a,this.eFocusableElement=p,this.focusTrapActive=!!i,this.forceFocusOutWhenTabGuardsAreEmpty=!!o,this.isFocusableContainer=!!s,this.providedFocusIn=l,this.providedFocusOut=c,this.providedShouldStopEventPropagation=u,this.providedOnTabKeyDown=d,this.providedHandleKeyDown=h}postConstruct(){this.createManagedBean(new qp(this.eFocusableElement,{shouldStopEventPropagation:()=>this.shouldStopEventPropagation(),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e)})),this.activateTabGuards(),[this.eTopGuard,this.eBottomGuard].forEach(e=>this.addManagedElementListeners(e,{focus:this.onFocus.bind(this)}))}handleKeyDown(e){this.providedHandleKeyDown&&this.providedHandleKeyDown(e)}tabGuardsAreActive(){return!!this.eTopGuard&&this.eTopGuard.hasAttribute("tabIndex")}shouldStopEventPropagation(){return this.providedShouldStopEventPropagation?this.providedShouldStopEventPropagation():!1}activateTabGuards(){if(this.forcingFocusOut)return;const e=this.gos.get("tabIndex");this.comp.setTabIndex(e.toString())}deactivateTabGuards(){this.comp.setTabIndex()}onFocus(e){if(this.isFocusableContainer&&!this.eFocusableElement.contains(e.relatedTarget)&&!this.allowFocus){this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);return}if(this.skipTabGuardFocus){this.skipTabGuardFocus=!1;return}if(this.forceFocusOutWhenTabGuardsAreEmpty&&ac(this.eFocusableElement,".ag-tab-guard").length===0){this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);return}if(this.isFocusableContainer&&this.eFocusableElement.contains(e.relatedTarget))return;const t=e.target===this.eBottomGuard;this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t)}findNextElementOutsideAndFocus(e){var l;const t=pn(this.beans),r=ac(t.body,null,!0),n=r.indexOf(e?this.eTopGuard:this.eBottomGuard);if(n===-1)return;let i,o;e?(i=0,o=n):(i=n+1,o=r.length);const s=r.slice(i,o),a=this.gos.get("tabIndex");s.sort((c,u)=>{const d=parseInt(c.getAttribute("tabindex")||"0"),h=parseInt(u.getAttribute("tabindex")||"0");return h===a?1:d===a?-1:d===0?1:h===0?-1:d-h}),(l=s[e?s.length-1:0])==null||l.focus()}onFocusIn(e){this.focusTrapActive||this.forcingFocusOut||(this.providedFocusIn&&this.providedFocusIn(e),this.isFocusableContainer||this.deactivateTabGuards())}onFocusOut(e){this.focusTrapActive||(this.providedFocusOut&&this.providedFocusOut(e),this.eFocusableElement.contains(e.relatedTarget)||this.activateTabGuards())}onTabKeyDown(e){if(this.providedOnTabKeyDown){this.providedOnTabKeyDown(e);return}if(this.focusTrapActive||e.defaultPrevented)return;const t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();const r=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),r&&(r.focus(),e.preventDefault())}focusInnerElement(e=!1){const t=ac(this.eFocusableElement);this.tabGuardsAreActive()&&(t.splice(0,1),t.splice(t.length-1,1)),t.length&&t[e?t.length-1:0].focus({preventScroll:!0})}getNextFocusableElement(e){return No(this.beans,this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;const t=e?this.eTopGuard:this.eBottomGuard;this.activateTabGuards(),this.skipTabGuardFocus=!0,this.forcingFocusOut=!0,t.focus(),window.setTimeout(()=>{this.forcingFocusOut=!1,this.activateTabGuards()})}isTabGuard(e,t){return e===this.eTopGuard&&!t||e===this.eBottomGuard&&(t??!0)}setAllowFocus(e){this.allowFocus=e}},tge=class extends xe{constructor(e){super(),this.comp=e}initialiseTabGuard(e){this.eTopGuard=this.createTabGuard("top"),this.eBottomGuard=this.createTabGuard("bottom"),this.eFocusableElement=this.comp.getFocusableElement();const{eTopGuard:t,eBottomGuard:r,eFocusableElement:n}=this,i=[t,r],o={setTabIndex:g=>{i.forEach(m=>g!=null?m.setAttribute("tabindex",g):m.removeAttribute("tabindex"))}};this.addTabGuards(t,r);const{focusTrapActive:s=!1,onFocusIn:a,onFocusOut:l,focusInnerElement:c,handleKeyDown:u,onTabKeyDown:d,shouldStopEventPropagation:h,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:f}=e;this.tabGuardCtrl=this.createManagedBean(new ege({comp:o,focusTrapActive:s,eTopGuard:t,eBottomGuard:r,eFocusableElement:n,onFocusIn:a,onFocusOut:l,focusInnerElement:c,handleKeyDown:u,onTabKeyDown:d,shouldStopEventPropagation:h,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:f}))}getTabGuardCtrl(){return this.tabGuardCtrl}createTabGuard(e){const t=pn(this.beans).createElement("div"),r=e==="top"?Hg.TAB_GUARD_TOP:Hg.TAB_GUARD_BOTTOM;return t.classList.add(Hg.TAB_GUARD,r),Un(t,"presentation"),t}addTabGuards(e,t){const r=this.eFocusableElement;r.insertAdjacentElement("afterbegin",e),r.insertAdjacentElement("beforeend",t)}removeAllChildrenExceptTabGuards(){const e=[this.eTopGuard,this.eBottomGuard];Jr(this.comp.getFocusableElement()),this.addTabGuards(...e)}forceFocusOutOfContainer(e=!1){this.tabGuardCtrl.forceFocusOutOfContainer(e)}appendChild(e,t,r){wA(t)||(t=t.getGui());const{eBottomGuard:n}=this;n?n.insertAdjacentElement("beforebegin",t):e(t,r)}},Au=class extends Je{initialiseTabGuard(t){this.tabGuardFeature=this.createManagedBean(new tge(this)),this.tabGuardFeature.initialiseTabGuard(t)}forceFocusOutOfContainer(t=!1){this.tabGuardFeature.forceFocusOutOfContainer(t)}appendChild(t,r){this.tabGuardFeature.appendChild(super.appendChild.bind(this),t,r)}},Xp=class extends Je{isPopup(){return!0}setParentComponent(e){e.addCssClass("ag-has-popup"),super.setParentComponent(e)}destroy(){const e=this.parentComponent;e&&e.isAlive()&&e.getGui().classList.remove("ag-has-popup"),super.destroy()}},Qh=class{constructor(e,t=!1){this.DOUBLE_TAP_MILLIS=500,this.destroyFuncs=[],this.touching=!1,this.localEventService=new Kp,this.preventMouseClick=t;const r=this.onTouchStart.bind(this),n=this.onTouchMove.bind(this),i=this.onTouchEnd.bind(this);e.addEventListener("touchstart",r,{passive:!0}),e.addEventListener("touchmove",n,{passive:!0}),e.addEventListener("touchend",i,{passive:!1}),this.destroyFuncs.push(()=>{e.removeEventListener("touchstart",r,{passive:!0}),e.removeEventListener("touchmove",n,{passive:!0}),e.removeEventListener("touchend",i,{passive:!1})})}getActiveTouch(e){for(let t=0;t{const r=this.touchStart===t;if(this.touching&&r&&!this.moved){this.moved=!0;const n={type:"longTap",touchStart:this.touchStart,touchEvent:e};this.localEventService.dispatchEvent(n)}},500)}onTouchMove(e){if(!this.touching)return;const t=this.getActiveTouch(e.touches);if(!t)return;!Efe(t,this.touchStart,4)&&(this.moved=!0)}onTouchEnd(e){if(this.touching){if(!this.moved){const t={type:"tap",touchStart:this.touchStart};this.localEventService.dispatchEvent(t),this.checkForDoubleTap()}this.preventMouseClick&&e.cancelable&&e.preventDefault(),this.touching=!1}}checkForDoubleTap(){const e=new Date().getTime();if(this.lastTapTime&&this.lastTapTime>0)if(e-this.lastTapTime>this.DOUBLE_TAP_MILLIS){const r={type:"doubleTap",touchStart:this.touchStart};this.localEventService.dispatchEvent(r),this.lastTapTime=null}else this.lastTapTime=e;else this.lastTapTime=e}destroy(){this.destroyFuncs.forEach(e=>e())}},pl=(e=>(e[e.VALUE=0]="VALUE",e[e.DIMENSION=1]="DIMENSION",e))(pl||{}),rge=class{constructor(e="javascript"){this.frameworkName=e,this.renderingEngine="vanilla",this.wrapIncoming=t=>t(),this.wrapOutgoing=t=>t(),this.baseDocLink=`${Spe}/${this.frameworkName}-data-grid`,z7e(this.baseDocLink)}setInterval(e,t){return new lr(r=>{r(window.setInterval(e,t))})}addEventListener(e,t,r,n){let i={};if(typeof n=="object"?i=n:typeof n=="boolean"&&(i={capture:n}),i.passive==null){const o=$pe(t);o!=null&&(i.passive=o)}e.addEventListener(t,r,i)}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return`${this.baseDocLink}${e?`/${e}`:""}`}};function eqe(e){return{beanName:"gridApi",bean:e.getBean("apiFunctionSvc").api}}var tqe=["licenseManager","environment","eventSvc","gos","paginationAutoPageSizeSvc","apiFunctionSvc","gridApi","registry","agCompUtils","userCompFactory","rowContainerHeight","horizontalResizeSvc","localeSvc","pinnedRowModel","dragSvc","colGroupSvc","visibleCols","popupSvc","selectionSvc","colFilter","quickFilter","filterManager","colModel","headerNavigation","pageBounds","pagination","pageBoundsListener","stickyRowSvc","rowRenderer","expressionSvc","alignedGridsSvc","navigation","valueCache","valueSvc","autoWidthCalc","filterMenuFactory","dragAndDrop","focusSvc","cellNavigation","cellStyles","scrollVisibleSvc","sortSvc","colHover","colAnimation","autoColSvc","selectionColSvc","changeDetectionSvc","animationFrameSvc","undoRedo","colDefFactory","rowStyleSvc","rowNodeBlockLoader","rowNodeSorter","ctrlsSvc","pinnedCols","dataTypeSvc","syncSvc","overlays","stateSvc","expansionSvc","apiEventSvc","ariaAnnounce","menuSvc","colMoves","colAutosize","colFlex","colResize","pivotColsSvc","valueColsSvc","rowGroupColsSvc","funcColsSvc","colNames","colViewport","pivotResultCols","showRowGroupCols","validation"],VY=Object.fromEntries(tqe.map((e,t)=>[e,t]));function rqe(e,t){const r=(e.beanName?VY[e.beanName]:void 0)??Number.MAX_SAFE_INTEGER,n=(t.beanName?VY[t.beanName]:void 0)??Number.MAX_SAFE_INTEGER;return r-n}function nqe(e,t){return(e==null?void 0:e.beanName)==="gridDestroySvc"?-1:0}var iqe='
',oqe='
',sqe=``,UO=class extends Je{constructor(t){super(),this.eCenterContainer=Ce,this.headerRowComps={},this.rowCompsList=[],this.pinned=t}postConstruct(){this.selectAndSetTemplate();const t={setDisplayed:n=>this.setDisplayed(n),setCtrls:n=>this.setCtrls(n),setCenterWidth:n=>this.eCenterContainer.style.width=n,setViewportScrollLeft:n=>this.getGui().scrollLeft=n,setPinnedContainerWidth:n=>{const i=this.getGui();i.style.width=n,i.style.maxWidth=n,i.style.minWidth=n}};this.createManagedBean(new Kfe(this.pinned)).setComp(t,this.getGui())}selectAndSetTemplate(){const t=this.pinned=="left",r=this.pinned=="right",n=t?iqe:r?oqe:sqe;this.setTemplate(n),this.eRowContainer=this.eCenterContainer!==Ce?this.eCenterContainer:this.getGui()}destroy(){this.setCtrls([]),super.destroy()}destroyRowComp(t){this.destroyBean(t),this.eRowContainer.removeChild(t.getGui())}setCtrls(t){const r=this.headerRowComps;this.headerRowComps={},this.rowCompsList=[];let n;const i=o=>{const s=o.getGui();s.parentElement!=this.eRowContainer&&this.eRowContainer.appendChild(s),n&&mpe(this.eRowContainer,s,n),n=s};t.forEach(o=>{const s=o.instanceId,a=r[s];delete r[s];const l=a||this.createBean(new RKe(o));this.headerRowComps[s]=l,this.rowCompsList.push(l),i(l)}),Object.values(r).forEach(o=>this.destroyRowComp(o))}},aqe=class extends Je{constructor(){super('